@oruga-ui/theme-oruga 0.0.1 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. package/dist/oruga-full.css +530 -388
  2. package/dist/oruga-full.min.css +1 -1
  3. package/dist/oruga.css +364 -225
  4. package/dist/oruga.min.css +1 -1
  5. package/dist/scss/components/_autocomplete.scss +0 -62
  6. package/dist/scss/components/_carousel.scss +10 -6
  7. package/dist/scss/components/_checkbox.scss +4 -4
  8. package/dist/scss/components/_datepicker.scss +11 -11
  9. package/dist/scss/components/_dropdown.scss +144 -31
  10. package/dist/scss/components/_field.scss +8 -8
  11. package/dist/scss/components/_icon.scss +3 -1
  12. package/dist/scss/components/_input.scss +38 -40
  13. package/dist/scss/components/_menu.scss +68 -68
  14. package/dist/scss/components/_pagination.scss +22 -22
  15. package/dist/scss/components/_radio.scss +8 -10
  16. package/dist/scss/components/_sidebar.scss +147 -42
  17. package/dist/scss/components/_switch.scss +4 -2
  18. package/dist/scss/components/_table.scss +14 -10
  19. package/dist/scss/components/_taginput.scss +163 -0
  20. package/dist/scss/components/_tooltip.scss +422 -218
  21. package/dist/scss/oruga-common.scss +1 -1
  22. package/dist/scss/oruga.scss +15 -20
  23. package/dist/scss/utils/_helpers.scss +3 -7
  24. package/dist/scss/utils/_variables.scss +0 -1
  25. package/package.json +28 -28
  26. package/src/App.vue +1 -0
  27. package/src/assets/scss/components/_autocomplete.scss +0 -62
  28. package/src/assets/scss/components/_carousel.scss +10 -6
  29. package/src/assets/scss/components/_checkbox.scss +4 -4
  30. package/src/assets/scss/components/_datepicker.scss +11 -11
  31. package/src/assets/scss/components/_dropdown.scss +144 -31
  32. package/src/assets/scss/components/_field.scss +8 -8
  33. package/src/assets/scss/components/_icon.scss +3 -1
  34. package/src/assets/scss/components/_input.scss +38 -40
  35. package/src/assets/scss/components/_menu.scss +68 -68
  36. package/src/assets/scss/components/_pagination.scss +22 -22
  37. package/src/assets/scss/components/_radio.scss +8 -10
  38. package/src/assets/scss/components/_sidebar.scss +147 -42
  39. package/src/assets/scss/components/_switch.scss +4 -2
  40. package/src/assets/scss/components/_table.scss +14 -10
  41. package/src/assets/scss/components/_taginput.scss +163 -0
  42. package/src/assets/scss/components/_tooltip.scss +422 -218
  43. package/src/assets/scss/oruga-common.scss +1 -1
  44. package/src/assets/scss/oruga.scss +15 -20
  45. package/src/assets/scss/utils/_helpers.scss +3 -7
  46. package/src/assets/scss/utils/_variables.scss +0 -1
  47. package/src/components/Autocomplete.vue +7 -7
  48. package/src/components/Button.vue +28 -28
  49. package/src/components/Carousel.vue +19 -20
  50. package/src/components/Checkbox.vue +43 -42
  51. package/src/components/Collapse.vue +3 -1
  52. package/src/components/Datepicker.vue +7 -10
  53. package/src/components/Datetimepicker.vue +4 -4
  54. package/src/components/Dropdown.vue +146 -101
  55. package/src/components/Field.vue +35 -43
  56. package/src/components/Icon.vue +1 -1
  57. package/src/components/Input.vue +9 -1
  58. package/src/components/Loading.vue +13 -14
  59. package/src/components/Menu.vue +42 -0
  60. package/src/components/Modal.vue +59 -0
  61. package/src/components/Notification.vue +6 -6
  62. package/src/components/Pagination.vue +5 -6
  63. package/src/components/Radio.vue +55 -39
  64. package/src/components/Sidebar.vue +34 -17
  65. package/src/components/Skeleton.vue +43 -25
  66. package/src/components/Slider.vue +2 -2
  67. package/src/components/Steps.vue +13 -14
  68. package/src/components/Switch.vue +22 -19
  69. package/src/components/Table.vue +30 -37
  70. package/src/components/Tabs.vue +3 -2
  71. package/src/components/Taginput.vue +14 -14
  72. package/src/components/Timepicker.vue +4 -6
  73. package/src/components/Tooltip.vue +54 -16
  74. package/dist/scss/components/_inputitems.scss +0 -175
  75. package/src/assets/scss/components/_inputitems.scss +0 -175
@@ -20,7 +20,7 @@ const passive = ref(null);
20
20
  <h3>Base</h3>
21
21
 
22
22
  <o-field>
23
- <o-switch>Default </o-switch>
23
+ <o-switch label="Default" />
24
24
  </o-field>
25
25
  <o-field>
26
26
  <o-switch v-model="isSwitched">
@@ -33,7 +33,7 @@ const passive = ref(null);
33
33
  </o-switch>
34
34
  </o-field>
35
35
  <o-field>
36
- <o-switch disabled>Disabled</o-switch>
36
+ <o-switch disabled label="Disabled" />
37
37
  </o-field>
38
38
  </section>
39
39
 
@@ -41,25 +41,25 @@ const passive = ref(null);
41
41
  <h3>Variant</h3>
42
42
 
43
43
  <o-field>
44
- <o-switch :value="true"> Default </o-switch>
44
+ <o-switch :model-value="true" label="Default" />
45
45
  </o-field>
46
46
  <o-field>
47
- <o-switch :value="true" variant="primary"> Primary </o-switch>
47
+ <o-switch :model-value="true" variant="primary" label="Primary" />
48
48
  </o-field>
49
49
  <o-field>
50
- <o-switch :value="true" variant="secondary"> Secondary </o-switch>
50
+ <o-switch :model-value="true" variant="secondary" label="Secondary" />
51
51
  </o-field>
52
52
  <o-field>
53
- <o-switch :value="true" variant="info"> Info </o-switch>
53
+ <o-switch :model-value="true" variant="info" label="Info" />
54
54
  </o-field>
55
55
  <o-field>
56
- <o-switch :value="true" variant="success"> Success </o-switch>
56
+ <o-switch :model-value="true" variant="success" label="Success" />
57
57
  </o-field>
58
58
  <o-field>
59
- <o-switch :value="true" variant="danger"> Danger </o-switch>
59
+ <o-switch :model-value="true" variant="danger" label="Danger" />
60
60
  </o-field>
61
61
  <o-field>
62
- <o-switch :value="true" variant="warning"> Warning </o-switch>
62
+ <o-switch :model-value="true" variant="warning" label="Warning" />
63
63
  </o-field>
64
64
  </section>
65
65
 
@@ -67,16 +67,16 @@ const passive = ref(null);
67
67
  <h3>Size</h3>
68
68
 
69
69
  <o-field>
70
- <o-switch size="small">Small</o-switch>
70
+ <o-switch size="small" label="Small" />
71
71
  </o-field>
72
72
  <o-field>
73
- <o-switch>Default</o-switch>
73
+ <o-switch label="Default" />
74
74
  </o-field>
75
75
  <o-field>
76
- <o-switch size="medium">Medium</o-switch>
76
+ <o-switch size="medium" label="Medium" />
77
77
  </o-field>
78
78
  <o-field>
79
- <o-switch size="large">Large</o-switch>
79
+ <o-switch size="large" label="Large" />
80
80
  </o-field>
81
81
  </section>
82
82
 
@@ -84,10 +84,14 @@ const passive = ref(null);
84
84
  <h3>Style variants</h3>
85
85
 
86
86
  <o-field grouped>
87
- <o-switch v-model="isRounded">Rounded</o-switch>
88
- <o-switch v-model="position" true-value="left" false-value="right">
87
+ <o-switch v-model="isRounded" label="Rounded" />
88
+ <o-switch
89
+ v-model="position"
90
+ true-value="left"
91
+ false-value="right"
92
+ label="
89
93
  Label on left
90
- </o-switch>
94
+ " />
91
95
  </o-field>
92
96
  <o-field grouped>
93
97
  <o-field label="Variant">
@@ -127,8 +131,7 @@ const passive = ref(null);
127
131
  :position="position"
128
132
  :size="size"
129
133
  :variant="variant"
130
- :passive-variant="passive">
131
- Sample
132
- </o-switch>
134
+ :passive-variant="passive"
135
+ label="Sample" />
133
136
  </section>
134
137
  </template>
@@ -141,15 +141,16 @@ const selected = ref(null);
141
141
  <h3>Sandbox</h3>
142
142
 
143
143
  <o-field grouped group-multiline>
144
- <o-switch v-model="isBordered" :rounded="true">Bordered</o-switch>
145
- <o-switch v-model="isStriped" :rounded="true">Striped</o-switch>
146
- <o-switch v-model="isNarrowed" :rounded="true">Narrowed</o-switch>
147
- <o-switch v-model="isHoverable" :rounded="true">Hoverable</o-switch>
148
- <o-switch v-model="isFocusable" :rounded="true">Focusable</o-switch>
149
- <o-switch v-model="isLoading" :rounded="true">Loading state</o-switch>
150
- <o-switch v-model="isEmpty" :rounded="true">Empty</o-switch>
144
+ <o-switch v-model="isBordered" :rounded="true" label="Bordered" />
145
+ <o-switch v-model="isStriped" :rounded="true" label="Striped" />
146
+ <o-switch v-model="isNarrowed" :rounded="true" label="Narrowed" />
147
+ <o-switch v-model="isHoverable" :rounded="true" label="Hoverable" />
148
+ <o-switch v-model="isFocusable" :rounded="true" label="Focusable" />
149
+ <o-switch v-model="isLoading" :rounded="true" label="Loading state" />
150
+ <o-switch v-model="isEmpty" :rounded="true" label="Empty" />
151
151
  <o-switch v-model="hasMobileCards" :rounded="true">
152
- Mobile cards <small>(collapsed rows)</small>
152
+ Mobile cards
153
+ <small>(collapsed rows)</small>
153
154
  </o-switch>
154
155
  </o-field>
155
156
 
@@ -171,17 +172,13 @@ const selected = ref(null);
171
172
  :key="idx"
172
173
  v-slot="{ row }"
173
174
  v-bind="column">
174
- <span>
175
- <component
176
- :is="column.component(row[column.field]).is"
177
- v-if="column.component"
178
- v-bind="column.component(row[column.field])" />
179
- {{
180
- column.display
181
- ? column.display(row[column.field])
182
- : row[column.field]
183
- }}
184
- </span>
175
+ <component
176
+ :is="column.component(row[column.field]).is"
177
+ v-if="column.component"
178
+ v-bind="column.component(row[column.field])" />
179
+ {{
180
+ column.display ? column.display(row[column.field]) : row[column.field]
181
+ }}
185
182
  </o-table-column>
186
183
 
187
184
  <template #detail="props">
@@ -203,10 +200,11 @@ const selected = ref(null);
203
200
  <h3>Paginated</h3>
204
201
 
205
202
  <o-field grouped group-multiline>
206
- <o-switch v-model="isPaginated" :rounded="true"> Paginated </o-switch>
207
- <o-switch v-model="isPaginationSimple" :rounded="true">
208
- Simple Paginated
209
- </o-switch>
203
+ <o-switch v-model="isPaginated" :rounded="true" label="Paginated " />
204
+ <o-switch
205
+ v-model="isPaginationSimple"
206
+ :rounded="true"
207
+ label="Simple Paginated" />
210
208
  <o-select v-model="perPage" :disabled="!isPaginated">
211
209
  <option value="3">3 per page</option>
212
210
  <option value="5">5 per page</option>
@@ -234,17 +232,13 @@ const selected = ref(null);
234
232
  :key="idx"
235
233
  v-slot="{ row }"
236
234
  v-bind="column">
237
- <span>
238
- <component
239
- :is="column.component(row[column.field]).is"
240
- v-if="column.component"
241
- v-bind="column.component(row[column.field])" />
242
- {{
243
- column.display
244
- ? column.display(row[column.field])
245
- : row[column.field]
246
- }}
247
- </span>
235
+ <component
236
+ :is="column.component(row[column.field]).is"
237
+ v-if="column.component"
238
+ v-bind="column.component(row[column.field])" />
239
+ {{
240
+ column.display ? column.display(row[column.field]) : row[column.field]
241
+ }}
248
242
  </o-table-column>
249
243
  </o-table>
250
244
  </section>
@@ -256,9 +250,8 @@ const selected = ref(null);
256
250
  variant="danger"
257
251
  :disabled="!selected"
258
252
  icon-left="times"
259
- @click="selected = null">
260
- <span>Clear selected</span>
261
- </o-button>
253
+ label="Clear selected"
254
+ @click="selected = null" />
262
255
 
263
256
  <p><b>Selected:</b> {{ selected }}</p>
264
257
 
@@ -165,12 +165,13 @@ const type = ref("default");
165
165
 
166
166
  <section>
167
167
  <h3>Vertical</h3>
168
+
168
169
  <o-field grouped group-multiline>
169
170
  <o-field>
170
- <o-switch v-model="atRight"> Right position </o-switch>
171
+ <o-switch v-model="atRight" label="Right position" />
171
172
  </o-field>
172
173
  <o-field>
173
- <o-switch v-model="expanded"> Expanded </o-switch>
174
+ <o-switch v-model="expanded" label="Expanded" />
174
175
  </o-field>
175
176
  <o-field label="Size">
176
177
  <o-select v-model="size">
@@ -397,11 +397,11 @@ function getFilteredTags(text: string) {
397
397
  <section>
398
398
  <h3>Base</h3>
399
399
 
400
- <o-switch v-model="allowNew"> Allow new items </o-switch>
401
- <o-switch v-model="openOnFocus"> Open on focus </o-switch>
400
+ <o-switch v-model="allowNew" label="Allow new items" />
401
+ <o-switch v-model="openOnFocus" label="Open on focus" />
402
402
 
403
403
  <o-field label="Enter some items">
404
- <o-inputitems
404
+ <o-taginput
405
405
  v-model="tags"
406
406
  variant="primary"
407
407
  :data="filteredTags"
@@ -419,7 +419,7 @@ function getFilteredTags(text: string) {
419
419
  <p><b>Items:</b> {{ tags }}</p>
420
420
 
421
421
  <o-field label="Disabled">
422
- <o-inputitems
422
+ <o-taginput
423
423
  variant="primary"
424
424
  disabled
425
425
  :model-value="['One']"
@@ -438,18 +438,18 @@ function getFilteredTags(text: string) {
438
438
  <h3>Limits</h3>
439
439
 
440
440
  <o-field label="Limited to 10 characters">
441
- <o-inputitems maxlength="10" :value="['Oruga', 'Vue', 'CSS']" />
441
+ <o-taginput maxlength="10" :model-value="['Oruga', 'Vue', 'CSS']" />
442
442
  </o-field>
443
443
 
444
444
  <o-field label="Limited to 5 tags">
445
- <o-inputitems maxitems="5" :value="['One', 'Two', 'Three', 'Four']" />
445
+ <o-taginput maxitems="5" :model-value="['One', 'Two', 'Three', 'Four']" />
446
446
  </o-field>
447
447
 
448
448
  <o-field label="Limited to 10 characters and 5 tags">
449
- <o-inputitems
449
+ <o-taginput
450
450
  maxlength="10"
451
451
  maxitems="5"
452
- :value="['Red', 'Green', 'Blue', 'White']" />
452
+ :model-value="['Red', 'Green', 'Blue', 'White']" />
453
453
  </o-field>
454
454
  </section>
455
455
 
@@ -457,7 +457,7 @@ function getFilteredTags(text: string) {
457
457
  <h3>Variant</h3>
458
458
 
459
459
  <o-field label="Primary">
460
- <o-inputitems
460
+ <o-taginput
461
461
  :model-value="['One']"
462
462
  :data="['One', 'Two', 'Three', 'Four']"
463
463
  :allow-new="false"
@@ -465,7 +465,7 @@ function getFilteredTags(text: string) {
465
465
  </o-field>
466
466
 
467
467
  <o-field label="Secondary">
468
- <o-inputitems
468
+ <o-taginput
469
469
  :model-value="['One']"
470
470
  :data="['One', 'Two', 'Three', 'Four']"
471
471
  :allow-new="false"
@@ -473,7 +473,7 @@ function getFilteredTags(text: string) {
473
473
  </o-field>
474
474
 
475
475
  <o-field label="Success">
476
- <o-inputitems
476
+ <o-taginput
477
477
  :model-value="['One']"
478
478
  :data="['One', 'Two', 'Three', 'Four']"
479
479
  :allow-new="false"
@@ -481,7 +481,7 @@ function getFilteredTags(text: string) {
481
481
  </o-field>
482
482
 
483
483
  <o-field label="Info">
484
- <o-inputitems
484
+ <o-taginput
485
485
  :model-value="['One']"
486
486
  :data="['One', 'Two', 'Three', 'Four']"
487
487
  :allow-new="false"
@@ -489,7 +489,7 @@ function getFilteredTags(text: string) {
489
489
  </o-field>
490
490
 
491
491
  <o-field label="Warning">
492
- <o-inputitems
492
+ <o-taginput
493
493
  :model-value="['One']"
494
494
  :data="['One', 'Two', 'Three', 'Four']"
495
495
  :allow-new="false"
@@ -497,7 +497,7 @@ function getFilteredTags(text: string) {
497
497
  </o-field>
498
498
 
499
499
  <o-field label="Danger">
500
- <o-inputitems
500
+ <o-taginput
501
501
  :model-value="['One']"
502
502
  :data="['One', 'Two', 'Three', 'Four']"
503
503
  :allow-new="false"
@@ -31,7 +31,7 @@ const hoursGranularity = ref(2);
31
31
 
32
32
  <o-field grouped>
33
33
  <o-field>
34
- <o-switch v-model="enableSeconds">Enable seconds</o-switch>
34
+ <o-switch v-model="enableSeconds" label="Enable seconds" />
35
35
  </o-field>
36
36
  <o-field label="Locale">
37
37
  <o-select v-model="locale">
@@ -67,15 +67,14 @@ const hoursGranularity = ref(2);
67
67
  icon="clock"
68
68
  :enable-seconds="enableSeconds"
69
69
  :hour-format="hourFormat"
70
- :locale="locale">
71
- </o-timepicker>
70
+ :locale="locale" />
72
71
  </o-field>
73
72
  </section>
74
73
 
75
74
  <section>
76
75
  <h3>Inline</h3>
77
76
 
78
- <o-timepicker v-model="time" inline></o-timepicker>
77
+ <o-timepicker v-model="time" inline />
79
78
  </section>
80
79
 
81
80
  <section>
@@ -117,8 +116,7 @@ const hoursGranularity = ref(2);
117
116
  placeholder="Click to select"
118
117
  icon="clock"
119
118
  :increment-minutes="minutesGranularity"
120
- :increment-hours="hoursGranularity">
121
- </o-timepicker>
119
+ :increment-hours="hoursGranularity" />
122
120
  </o-field>
123
121
  </section>
124
122
  </template>
@@ -2,6 +2,7 @@
2
2
  import { ref } from "vue";
3
3
 
4
4
  const active = ref(true);
5
+ const teleport = ref(false);
5
6
  </script>
6
7
 
7
8
  <template>
@@ -13,56 +14,92 @@ const active = ref(true);
13
14
  <section>
14
15
  <h3>Base</h3>
15
16
 
16
- <o-tooltip label="Tooltip right" position="right">
17
+ <o-tooltip label="Tooltip">
18
+ <o-button label="Hover me! " />
19
+ </o-tooltip>
20
+
21
+ <o-tooltip label="delayed by 1000ms" :delay="1000">
22
+ <o-button variant="warning" label="Delayed" />
23
+ </o-tooltip>
24
+
25
+ <o-tooltip label="I'm on body" teleport>
26
+ <o-button variant="info" label="Append on body" />
27
+ </o-tooltip>
28
+ </section>
29
+
30
+ <section>
31
+ <h3>Position</h3>
32
+
33
+ <o-field>
34
+ <o-switch v-model="teleport" label="teleport" />
35
+ </o-field>
36
+
37
+ <o-tooltip label="Tooltip right" :teleport="teleport" position="right">
17
38
  <o-button label="Right" />
18
39
  </o-tooltip>
19
40
 
20
- <o-tooltip label="Tooltip top" variant="dark">
21
- <o-button label="Top (default)" />
41
+ <o-tooltip label="Tooltip top" :teleport="teleport" position="top">
42
+ <o-button label="Top" />
22
43
  </o-tooltip>
23
44
 
24
- <o-tooltip label="Tooltip bottom" variant="dark" position="bottom">
45
+ <o-tooltip label="Tooltip bottom" :teleport="teleport" position="bottom">
25
46
  <o-button label="Bottom" />
26
47
  </o-tooltip>
27
48
 
28
- <o-tooltip label="Tooltip left" variant="dark" position="left">
49
+ <o-tooltip label="Tooltip left" :teleport="teleport" position="left">
29
50
  <o-button label="Left" />
30
51
  </o-tooltip>
31
52
 
32
- <o-tooltip label="delayed by 1000ms" variant="dark" :delay="1000">
33
- <o-button variant="warning" label="Delayed" />
53
+ <hr />
54
+
55
+ <o-tooltip label="Tooltip right" :teleport="teleport" position="top-right">
56
+ <o-button label="Top Right" />
57
+ </o-tooltip>
58
+
59
+ <o-tooltip label="Tooltip top" :teleport="teleport" position="top-left">
60
+ <o-button label="Top Left" />
34
61
  </o-tooltip>
35
- </section>
36
62
 
63
+ <o-tooltip
64
+ label="Tooltip bottom"
65
+ :teleport="teleport"
66
+ position="bottom-right">
67
+ <o-button label="Bottom Right" />
68
+ </o-tooltip>
69
+
70
+ <o-tooltip label="Tooltip left" :teleport="teleport" position="bottom-left">
71
+ <o-button label="Bottom Left" />
72
+ </o-tooltip>
73
+ </section>
37
74
  <section>
38
- <h3>Colors</h3>
75
+ <h3>Variants</h3>
39
76
 
40
77
  <o-tooltip label="Default">
41
78
  <o-button label="Default" />
42
79
  </o-tooltip>
43
80
 
44
81
  <o-tooltip label="Primary" variant="primary">
45
- <o-button label="Primary" />
82
+ <o-button label="Primary" variant="primary" />
46
83
  </o-tooltip>
47
84
 
48
85
  <o-tooltip label="Secondary" variant="secondary">
49
- <o-button label="Secondary" />
86
+ <o-button label="Secondary" variant="secondary" />
50
87
  </o-tooltip>
51
88
 
52
89
  <o-tooltip label="Success" variant="success">
53
- <o-button label="Success" />
90
+ <o-button label="Success" variant="success" />
54
91
  </o-tooltip>
55
92
 
56
93
  <o-tooltip label="Danger" variant="danger">
57
- <o-button label="Danger" />
94
+ <o-button label="Danger" variant="danger" />
58
95
  </o-tooltip>
59
96
 
60
97
  <o-tooltip label="Warning" variant="warning">
61
- <o-button label="Warning" />
98
+ <o-button label="Warning" variant="warning" />
62
99
  </o-tooltip>
63
100
 
64
101
  <o-tooltip label="Info" variant="info">
65
- <o-button label="Info" />
102
+ <o-button label="Info" variant="info" />
66
103
  </o-tooltip>
67
104
  </section>
68
105
 
@@ -121,8 +158,9 @@ const active = ref(true);
121
158
  <h3>Toggle</h3>
122
159
 
123
160
  <o-field>
124
- <o-switch v-model="active"> Toggle Always </o-switch>
161
+ <o-switch v-model="active" label="Toggle Always" />
125
162
  </o-field>
163
+
126
164
  <o-tooltip
127
165
  variant="danger"
128
166
  label="I'm never closing"
@@ -1,175 +0,0 @@
1
- @use "sass:list";
2
-
3
- /* @docs */
4
- $inputitems-background-color: $input-background-color !default;
5
- $inputitems-height: calc(2em - 1px) !default;
6
- $inputitems-padding: calc(0.275em - 1px) 0 0 !default;
7
- $inputitems-border-color: $grey-lighter !default;
8
- $inputitems-border-style: solid !default;
9
- $inputitems-border-width: 1px !default;
10
- $inputitems-border-radius: $base-border-radius !default;
11
- $inputitems-color: #363636 !default;
12
- $inputitems-line-height: $base-line-height !default;
13
- $inputitems-box-shadow: inset 0 1px 2px hsla(0, 0%, 4%, 0.1) !default;
14
- $inputitems-max-width: 100% !default;
15
- $inputitems-width: 100% !default;
16
- $inputitems-counter-font-size: 0.75rem !default;
17
- $inputitems-counter-margin: 0.25rem 0 0 0.5rem !default;
18
- $inputitems-item-background-color: $primary !default;
19
- $inputitems-item-color: $primary-invert !default;
20
- $inputitems-item-border-radius: $base-border-radius !default;
21
- $inputitems-item-margin: 0 0 0 0.275em !default;
22
- $inputitems-item-padding: 0 0.75em 0 0.75em !default;
23
- $inputitems-margin-icon-to-text: 0.1875em !default;
24
- /* @docs */
25
-
26
- .o-inputit {
27
- display: block;
28
-
29
- &__container {
30
- display: flex;
31
- align-items: center;
32
- justify-content: flex-start;
33
- position: relative;
34
- vertical-align: top;
35
- flex-wrap: wrap;
36
-
37
- @include avariable(
38
- "max-width",
39
- "inputitems-max-width",
40
- $inputitems-max-width
41
- );
42
- @include avariable("width", "inputitems-width", $inputitems-width);
43
- @include avariable("padding", "inputitems-padding", $inputitems-padding);
44
- @include avariable(
45
- "background-color",
46
- "inputitems-background-color",
47
- $inputitems-background-color
48
- );
49
- @include avariable(
50
- "border-color",
51
- "inputitems-border-color",
52
- $inputitems-border-color
53
- );
54
- @include avariable(
55
- "border-style",
56
- "inputitems-border-style",
57
- $inputitems-border-style
58
- );
59
- @include avariable(
60
- "border-width",
61
- "inputitems-border-width",
62
- $inputitems-border-width
63
- );
64
- @include avariable(
65
- "border-radius",
66
- "inputitems-border-radius",
67
- $inputitems-border-radius
68
- );
69
- @include avariable("color", "inputitems-color", $inputitems-color);
70
- @include avariable("font-size", "base-font-size", $base-font-size);
71
- @include avariable(
72
- "line-height",
73
- "inputitems-line-height",
74
- $inputitems-line-height
75
- );
76
- @include avariable(
77
- "box-shadow",
78
- "inputitems-box-shadow",
79
- $inputitems-box-shadow
80
- );
81
-
82
- @each $name, $value in $sizes {
83
- &--#{$name} {
84
- @include avariable(
85
- "font-size",
86
- ("inputitems-font-size-" + #{$name}),
87
- $value
88
- );
89
- }
90
- }
91
- }
92
-
93
- &__autocomplete {
94
- position: static;
95
- flex: 1;
96
- }
97
-
98
- &__input {
99
- border: none;
100
- box-shadow: none;
101
-
102
- &:focus {
103
- box-shadow: none;
104
- }
105
- }
106
-
107
- &__item {
108
- display: inline-flex;
109
- justify-content: center;
110
- align-items: center;
111
- position: relative;
112
-
113
- @include side-flex-gap($inputitems-margin-icon-to-text);
114
- @include avariable(
115
- "background-color",
116
- "inputitems-item-background-color",
117
- $inputitems-item-background-color
118
- );
119
- @include avariable(
120
- "color",
121
- "inputitems-item-color",
122
- $inputitems-item-color
123
- );
124
- @include avariable(
125
- "border-radius",
126
- "inputitems-item-border-radius",
127
- $inputitems-item-border-radius
128
- );
129
- @include avariable(
130
- "margin",
131
- "inputitems-item-margin",
132
- $inputitems-item-margin
133
- );
134
- @include avariable(
135
- "padding",
136
- "inputitems-item-padding",
137
- $inputitems-item-padding
138
- );
139
-
140
- @each $name, $pair in $colors {
141
- $color: list.nth($pair, 1);
142
- $color-invert: list.nth($pair, 2);
143
- &--#{$name} {
144
- @include avariable("background-color", ("variant-" + #{$name}), $color);
145
- @include avariable(
146
- "color",
147
- ("variant-invert-" + #{$name}),
148
- $color-invert
149
- );
150
- }
151
- }
152
- }
153
-
154
- &__counter {
155
- display: block;
156
- float: right;
157
-
158
- @include avariable(
159
- "font-size",
160
- "inputitems-counter-font-size",
161
- $inputitems-counter-font-size
162
- );
163
- @include avariable(
164
- "margin",
165
- "inputitems-counter-margin",
166
- $inputitems-counter-margin
167
- );
168
- }
169
-
170
- &--expanded {
171
- width: 100%;
172
- flex-grow: 1;
173
- flex-shrink: 1;
174
- }
175
- }