File tree 4 files changed +41
-7
lines changed
site/src/routes/demo/autocomplete
4 files changed +41
-7
lines changed Original file line number Diff line number Diff line change 23
23
<slot >
24
24
<Textfield
25
25
{label }
26
+ {disabled }
26
27
bind:value ={text }
27
28
{...prefixFilter ($$restProps , ' textfield$' )}
28
29
/>
116
117
option == null ? ' ' : ` ${option } ` ;
117
118
export let text = getOptionLabel (value );
118
119
export let label: string | undefined = undefined ;
120
+ export let disabled = false ;
119
121
export let toggle = false ;
120
122
export let combobox = false ;
121
123
export let clearOnBlur = ! combobox ;
Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ export declare class AutocompleteComponentDev extends Component {
20
20
| 'getOptionLabel'
21
21
| 'text'
22
22
| 'label'
23
+ | 'disabled'
23
24
| 'toggle'
24
25
| 'combobox'
25
26
| 'clearOnBlur'
Original file line number Diff line number Diff line change 1
1
<div class =" columns margins" >
2
2
<div >
3
- Standard:<br />
4
3
<Autocomplete
5
4
options ={fruits }
6
5
bind:value ={valueStandard }
7
- label =" Fruit "
6
+ label =" Standard "
8
7
class =" demo-autocomplete-width"
9
8
/>
10
9
11
10
<pre class ="status" >Selected: {valueStandard || ' ' }</pre >
12
11
</div >
13
12
14
13
<div >
15
- Filled:<br />
16
14
<Autocomplete
17
15
options ={fruits }
18
16
textfield $variant =" filled"
19
17
bind:value ={valueFilled }
20
- label =" Fruit "
18
+ label =" Filled "
21
19
class =" demo-autocomplete-width"
22
20
/>
23
21
24
22
<pre class ="status" >Selected: {valueFilled || ' ' }</pre >
25
23
</div >
26
24
27
25
<div >
28
- Outlined:<br />
29
26
<Autocomplete
30
27
options ={fruits }
31
28
textfield $variant =" outlined"
32
29
bind:value ={valueOutlined }
33
- label =" Fruit "
30
+ label =" Outlined "
34
31
class =" demo-autocomplete-width"
35
32
/>
36
33
37
34
<pre class ="status" >Selected: {valueOutlined || ' ' }</pre >
38
35
</div >
39
36
</div >
40
37
38
+ <div >
39
+ Disabled:
40
+ <div class =" columns margins" >
41
+ <div >
42
+ <Autocomplete
43
+ options ={fruits }
44
+ disabled
45
+ label =" Standard"
46
+ class =" demo-autocomplete-width"
47
+ />
48
+ </div >
49
+
50
+ <div >
51
+ <Autocomplete
52
+ options ={fruits }
53
+ textfield $variant =" filled"
54
+ disabled
55
+ label =" Filled"
56
+ class =" demo-autocomplete-width"
57
+ />
58
+ </div >
59
+
60
+ <div >
61
+ <Autocomplete
62
+ options ={fruits }
63
+ textfield $variant =" outlined"
64
+ disabled
65
+ label =" Outlined"
66
+ class =" demo-autocomplete-width"
67
+ />
68
+ </div >
69
+ </div >
70
+ </div >
71
+
41
72
<script lang =" ts" >
42
73
import Autocomplete from ' @smui-extra/autocomplete' ;
43
74
Original file line number Diff line number Diff line change 3
3
</svelte:head >
4
4
5
5
<section >
6
- <h2 >Autocomplete </h2 >
6
+ <h2 >Auto< wbr />complete </h2 >
7
7
8
8
<h5 >Installation</h5 >
9
9
You can’t perform that action at this time.
0 commit comments