@dynamic-framework/ui-react 1.35.1 → 1.36.1

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 (42) hide show
  1. package/dist/css/bootstrap-icons.css +31 -3
  2. package/dist/css/bootstrap-icons.json +29 -1
  3. package/dist/css/bootstrap-icons.min.css +2 -2
  4. package/dist/css/bootstrap-icons.scss +29 -1
  5. package/dist/css/dynamic-ui-non-root.css +373 -85
  6. package/dist/css/dynamic-ui-non-root.min.css +2 -2
  7. package/dist/css/dynamic-ui-root.css +4 -1
  8. package/dist/css/dynamic-ui-root.min.css +2 -2
  9. package/dist/css/dynamic-ui.css +376 -85
  10. package/dist/css/dynamic-ui.min.css +2 -2
  11. package/dist/css/fonts/bootstrap-icons.woff +0 -0
  12. package/dist/css/fonts/bootstrap-icons.woff2 +0 -0
  13. package/dist/index.esm.js +125 -19
  14. package/dist/index.esm.js.map +1 -1
  15. package/dist/index.js +126 -18
  16. package/dist/index.js.map +1 -1
  17. package/dist/types/components/DBoxFile/useDBoxFile.d.ts +1 -1
  18. package/dist/types/components/DDatePicker/DDatePicker.d.ts +4 -3
  19. package/dist/types/components/DDatePicker/components/DDatePickerHeaderSelector.d.ts +3 -1
  20. package/dist/types/components/DDatePicker/components/DDatePickerTime.d.ts +5 -7
  21. package/dist/types/components/DInputPhone/DInputPhone.d.ts +26 -0
  22. package/dist/types/components/DInputPhone/index.d.ts +2 -0
  23. package/dist/types/components/DSelect/DSelect.d.ts +2 -1
  24. package/dist/types/components/index.d.ts +1 -0
  25. package/dist/types/utils/index.d.ts +1 -0
  26. package/dist/types/utils/validatePhoneNumber.d.ts +1 -0
  27. package/jest/setup.js +15 -0
  28. package/package.json +10 -4
  29. package/src/style/abstracts/_utilities.scss +11 -1
  30. package/src/style/abstracts/variables/_+import.scss +2 -1
  31. package/src/style/abstracts/variables/_datepicker.scss +5 -8
  32. package/src/style/abstracts/variables/_input-phone.scss +62 -0
  33. package/src/style/abstracts/variables/_navs.scss +3 -1
  34. package/src/style/abstracts/variables/_typography.scss +2 -0
  35. package/src/style/base/_form-switch.scss +1 -1
  36. package/src/style/base/_nav.scss +9 -13
  37. package/src/style/components/_+import.scss +1 -0
  38. package/src/style/components/_d-datepicker.scss +79 -152
  39. package/src/style/components/_d-input-phone.scss +286 -0
  40. package/src/style/components/_d-select.scss +22 -2
  41. package/src/style/components/_d-timepicker.scss +43 -29
  42. package/src/style/root/_root.scss +4 -0
@@ -1,4 +1,4 @@
1
- /* stylelint-disable */
1
+ // stylelint-disable
2
2
  .react-datepicker-wrapper {
3
3
  display: inline-block;
4
4
  padding: 0;
@@ -11,16 +11,18 @@
11
11
  // General
12
12
  --#{$prefix}datepicker-bg: #{$datepicker-bg};
13
13
  --#{$prefix}datepicker-border-color: #{$datepicker-border-color};
14
- --#{$prefix}datepicker-border: 1px solid #{$datepicker-border-color};
14
+ --#{$prefix}datepicker-border: 0px solid #{$datepicker-border-color};
15
15
  --#{$prefix}datepicker-border-radius: #{$datepicker-border-radius};
16
+ --#{$prefix}datepicker-box-shadow: var(--#{$prefix}box-shadow);
16
17
 
17
18
  // Header
18
19
  --#{$prefix}datepicker-header-bg: #{$datepicker-header-bg};
19
- --#{$prefix}datepicker-header-border-bottom: 1px solid #{$datepicker-border-color};
20
+ --#{$prefix}datepicker-header-border-bottom: 0px solid #{$datepicker-border-color};
20
21
  --#{$prefix}datepicker-header-padding: #{$datepicker-header-padding};
21
22
  --#{$prefix}datepicker-header-font-weight: #{$datepicker-header-font-weight};
22
23
  --#{$prefix}datepicker-day-names-color: #{$datepicker-day-names-color};
23
24
  --#{$prefix}datepicker-day-names-font-size: #{$datepicker-day-names-font-size};
25
+ --#{$prefix}datepicker-day-names-font-weight: var(--#{$prefix}fw-bold);
24
26
 
25
27
  // Body
26
28
  --#{$prefix}datepicker-body-margin: #{$datepicker-body-margin};
@@ -42,6 +44,7 @@
42
44
  --#{$prefix}datepicker-day-bg: #{$datepicker-day-bg};
43
45
  --#{$prefix}datepicker-day-hover-bg: #{$datepicker-day-hover-bg};
44
46
  --#{$prefix}datepicker-day-width: #{$datepicker-day-width};
47
+ --#{$prefix}datepicker-day-color: #{$datepicker-day-color};
45
48
 
46
49
  // Day selected
47
50
  --#{$prefix}datepicker-day-selected-color: #{$datepicker-day-selected-color};
@@ -70,12 +73,15 @@
70
73
  --#{$prefix}datepicker-in-range-disabled-color: #{$datepicker-in-range-disabled-color};
71
74
  --#{$prefix}datepicker-in-range-disabled-bg: #{$datepicker-in-range-disabled-bg};
72
75
 
73
- // Portal
74
- --#{$prefix}datepicker-portal-bg: #{$datepicker-portal-bg};
76
+ // Time
77
+ --#{$prefix}datepicker-time-list-item-width: 85px;
78
+ --#{$prefix}datepicker-time-list-item-padding: var(--#{$prefix}ref-spacer-2) var(--#{$prefix}ref-spacer-1);
79
+
75
80
 
76
81
  background-color: var(--#{$prefix}datepicker-bg);
77
82
  border: var(--#{$prefix}datepicker-border);
78
83
  border-radius: var(--#{$prefix}datepicker-border-radius);
84
+ box-shadow: var(--#{$prefix}datepicker-box-shadow);
79
85
  display: inline-block;
80
86
  position: relative;
81
87
  line-height: initial;
@@ -98,13 +104,13 @@
98
104
  line-height: 0;
99
105
 
100
106
  .react-datepicker__triangle {
101
- --#{$prefix}datepicker-border-color: var(--#{$prefix}gray-400);
107
+ --#{$prefix}datepicker-border-color: var(--#{$prefix}gray-100);
102
108
  stroke: var(--#{$prefix}datepicker-border-color);
103
109
  }
104
110
 
105
111
  &[data-placement^="bottom"] {
106
112
  .react-datepicker__triangle {
107
- --#{$prefix}datepicker-header-bg: var(--#{$prefix}gray-100);
113
+ --#{$prefix}datepicker-header-bg: var(--#{$prefix}secondary-soft);
108
114
  fill: var(--#{$prefix}datepicker-header-bg);
109
115
  color: var(--#{$prefix}datepicker-header-bg);
110
116
  }
@@ -148,10 +154,10 @@
148
154
 
149
155
  .d-select {
150
156
  --#{$prefix}select-option-selected-bg: var(--#{$prefix}datepicker-bg);
151
- --#{$prefix}select-option-selected-color: var(--#{$prefix}datepicker-text-color);
152
157
 
153
158
  .d-select__control {
154
159
  padding: var(--#{$prefix}ref-spacer-1) var(--#{$prefix}ref-spacer-2);
160
+ flex-wrap: nowrap;
155
161
  }
156
162
 
157
163
  .d-select__menu-list {
@@ -222,6 +228,7 @@
222
228
  text-overflow: ellipsis;
223
229
  white-space: nowrap;
224
230
  overflow: hidden;
231
+ color: var(--#{$prefix}datepicker-day-names-color);
225
232
  }
226
233
 
227
234
  .react-datepicker__month-container {
@@ -270,111 +277,59 @@
270
277
  width: 6ch;
271
278
  }
272
279
  }
280
+ // START TODO: Revisar con Mati diseño del time
281
+ .react-datepicker__time-container {
282
+ float: right;
283
+ border-left: 1px solid var(--#{$prefix}gray-100);
284
+ width: var(--#{$prefix}datepicker-time-list-item-width);
285
+
286
+ .react-datepicker__time {
287
+ position: relative;
288
+ background: var(--#{$prefix}datepicker-bg);
289
+ border-bottom-right-radius: var(--#{$prefix}datepicker-border-radius);
273
290
 
274
- // .react-datepicker__input-time-container {
275
- // clear: both;
276
- // width: 100%;
277
- // float: left;
278
- // margin: var(--#{$prefix}ref-spacer-2);
279
- // text-align: left;
280
-
281
- // .react-datepicker-time__caption {
282
- // display: inline-block;
283
- // }
284
-
285
- // .react-datepicker-time__input-container {
286
- // display: inline-block;
287
-
288
- // .react-datepicker-time__input {
289
- // display: inline-block;
290
- // margin-left: var(--#{$prefix}ref-spacer-2);
291
-
292
- // input {
293
- // width: auto;
294
- // }
295
-
296
- // input[type="time"]::-webkit-inner-spin-button,
297
- // input[type="time"]::-webkit-outer-spin-button {
298
- // -webkit-appearance: none;
299
- // margin: 0;
300
- // }
301
-
302
- // input[type="time"] {
303
- // -moz-appearance: textfield;
304
- // }
305
- // }
306
- // }
307
- // }
291
+ .react-datepicker__time-box {
292
+ width: var(--#{$prefix}datepicker-time-list-item-width);
293
+ overflow-x: hidden;
294
+ margin: 0 auto;
295
+ text-align: center;
296
+ border-bottom-right-radius: var(--#{$prefix}datepicker-border-radius);
297
+
298
+ ul.react-datepicker__time-list {
299
+ list-style: none;
300
+ margin: 0;
301
+ height: calc(195px + (32px / 2));
302
+ overflow-y: scroll;
303
+ padding-right: 0;
304
+ padding-left: 0;
305
+ width: 100%;
306
+ box-sizing: border-box;
307
+
308
+ li.react-datepicker__time-list-item {
309
+ padding: var(--#{$prefix}datepicker-time-list-item-padding);
310
+ white-space: nowrap;
311
+ display: block;
308
312
 
309
- // .react-datepicker__time-container {
310
- // float: right;
311
- // border-left: $datepicker__border;
312
- // width: 85px;
313
-
314
- // &--with-today-button {
315
- // display: inline;
316
- // border: 1px solid #aeaeae;
317
- // border-radius: 0.3rem;
318
- // position: absolute;
319
- // right: -87px;
320
- // top: 0;
321
- // }
322
-
323
- // .react-datepicker__time {
324
- // position: relative;
325
- // background: white;
326
- // border-bottom-right-radius: 0.3rem;
327
-
328
- // .react-datepicker__time-box {
329
- // width: 85px;
330
- // overflow-x: hidden;
331
- // margin: 0 auto;
332
- // text-align: center;
333
- // border-bottom-right-radius: 0.3rem;
334
-
335
- // ul.react-datepicker__time-list {
336
- // list-style: none;
337
- // margin: 0;
338
- // height: calc(195px + (#{$datepicker__item-size} / 2));
339
- // overflow-y: scroll;
340
- // padding-right: 0;
341
- // padding-left: 0;
342
- // width: 100%;
343
- // box-sizing: content-box;
344
-
345
- // li.react-datepicker__time-list-item {
346
- // height: 30px;
347
- // padding: 5px 10px;
348
- // white-space: nowrap;
349
-
350
- // &:hover {
351
- // cursor: pointer;
352
- // background-color: $datepicker__background-color;
353
- // }
354
-
355
- // &--selected {
356
- // background-color: $datepicker__selected-color;
357
- // color: white;
358
- // font-weight: bold;
359
-
360
- // &:hover {
361
- // background-color: $datepicker__selected-color;
362
- // }
363
- // }
364
-
365
- // &--disabled {
366
- // color: $datepicker__muted-color;
367
-
368
- // &:hover {
369
- // cursor: default;
370
- // background-color: transparent;
371
- // }
372
- // }
373
- // }
374
- // }
375
- // }
376
- // }
377
- // }
313
+ &:hover {
314
+ cursor: pointer;
315
+ background-color: var(--#{$prefix}datepicker-day-hover-bg);
316
+ }
317
+
318
+ &--selected, &--selected:hover {
319
+ background-color: var(--#{$prefix}datepicker-day-selected-bg);
320
+ color: var(--#{$prefix}datepicker-day-selected-color);
321
+ }
322
+
323
+ &--disabled, &--disabled:hover {
324
+ cursor: default;
325
+ color: var(--#{$prefix}datepicker-day-disabled-color);
326
+ background-color: unset;
327
+ }
328
+ }
329
+ }
330
+ }
331
+ }
332
+ }
378
333
  // END TODO: Revisar con Mati diseño del time
379
334
 
380
335
  .react-datepicker__week-number {
@@ -403,12 +358,6 @@
403
358
  }
404
359
  }
405
360
 
406
- .react-datepicker__day-names {
407
- white-space: nowrap;
408
- display: inline-flex;
409
- gap: var(--#{$prefix}datepicker-body-gap);
410
- }
411
-
412
361
  .react-datepicker__week {
413
362
  white-space: nowrap;
414
363
  display: inline-flex;
@@ -420,13 +369,24 @@
420
369
  .react-datepicker__day-name,
421
370
  .react-datepicker__day,
422
371
  .react-datepicker__time-name {
423
- color: var(--#{$prefix}datepicker-day-names-color);
424
372
  display: inline-block;
425
373
  text-align: center;
426
374
  width: var(--#{$prefix}datepicker-day-width);
427
375
  line-height: var(--#{$prefix}datepicker-day-width);
428
376
  font-size: var(--#{$prefix}datepicker-day-names-font-size);
377
+ }
429
378
 
379
+ .react-datepicker__day-names {
380
+ white-space: nowrap;
381
+ display: inline-flex;
382
+ gap: var(--#{$prefix}datepicker-body-gap);
383
+ color: var(--#{$prefix}datepicker-day-names-color);
384
+ font-weight: var(--#{$prefix}datepicker-day-names-font-weight);
385
+ }
386
+
387
+ .react-datepicker__day,
388
+ .react-datepicker__time-name {
389
+ color: var(--#{$prefix}datepicker-day-color);
430
390
  }
431
391
 
432
392
  .react-datepicker__day--outside-month {
@@ -584,39 +544,6 @@ react-datepicker__navigation
584
544
  // clear: left;
585
545
  // }
586
546
 
587
- .react-datepicker__portal {
588
- --#{$prefix}datepicker-portal-bg: rgba(var(--#{$prefix}black-rgb), 0.3);
589
-
590
- position: fixed;
591
- width: 100vw;
592
- height: 100vh;
593
- background-color: var(--#{$prefix}datepicker-portal-bg);
594
- left: 0;
595
- top: 0;
596
- justify-content: center;
597
- align-items: center;
598
- display: flex;
599
- z-index: 1060;
600
-
601
- .react-datepicker__day-name,
602
- .react-datepicker__day,
603
- .react-datepicker__time-name {
604
- width: 3rem;
605
- line-height: 3rem;
606
- }
607
-
608
- @media (max-width: 400px),
609
- (max-height: 550px) {
610
-
611
- .react-datepicker__day-name,
612
- .react-datepicker__day,
613
- .react-datepicker__time-name {
614
- width: 2rem;
615
- line-height: 2rem;
616
- }
617
- }
618
- }
619
-
620
547
  .react-datepicker__children-container {
621
548
  width: 13.8rem;
622
549
  margin: 0.4rem;
@@ -637,4 +564,4 @@ react-datepicker__navigation
637
564
  white-space: nowrap;
638
565
  }
639
566
 
640
- /* stylelint-enable */
567
+ // stylelint-enable
@@ -0,0 +1,286 @@
1
+ // stylelint-disable selector-class-pattern
2
+ // stylelint-disable scss/selector-no-union-class-name
3
+
4
+ .d-input-phone {
5
+ // General sizes
6
+ --#{$prefix}input-phone-height: #{$input-phone-height};
7
+ --#{$prefix}input-phone-font-size: #{$input-phone-font-size};
8
+ --#{$prefix}input-phone-border-radius: #{$input-phone-border-radius};
9
+
10
+ // Base and state colors
11
+ --#{$prefix}input-phone-border-color: #{$input-phone-border-color};
12
+ --#{$prefix}input-phone-background-color: #{$input-phone-background-color};
13
+ --#{$prefix}input-phone-text-color: #{$input-phone-text-color};
14
+ --#{$prefix}input-phone-disabled-background-color: #{$input-phone-disabled-background-color};
15
+ --#{$prefix}input-phone-disabled-text-color: #{$input-phone-disabled-text-color};
16
+
17
+ // Country selector
18
+ --#{$prefix}input-phone-country-selector-border-color: #{$input-phone-country-selector-border-color};
19
+ --#{$prefix}input-phone-country-selector-background-color: #{$input-phone-country-selector-background-color};
20
+ --#{$prefix}input-phone-country-selector-background-color-hover: #{$input-phone-country-selector-background-color-hover};
21
+ --#{$prefix}input-phone-disabled-country-selector-background-color: #{$input-phone-disabled-country-selector-background-color};
22
+
23
+ // Country selector arrow
24
+ --#{$prefix}input-phone-country-selector-arrow-size: #{$input-phone-country-selector-arrow-size};
25
+ --#{$prefix}input-phone-country-selector-arrow-color: #{$input-phone-country-selector-arrow-color};
26
+ --#{$prefix}input-phone-disabled-country-selector-arrow-color: #{$input-phone-disabled-country-selector-arrow-color};
27
+
28
+ // Flag
29
+ --#{$prefix}input-phone-flag-width: #{$input-phone-flag-width};
30
+ --#{$prefix}input-phone-flag-height: #{$input-phone-flag-height};
31
+
32
+ // Dropdown (country list)
33
+ --#{$prefix}input-phone-dropdown-top: #{$input-phone-dropdown-top};
34
+ --#{$prefix}input-phone-dropdown-left: #{$input-phone-dropdown-left};
35
+ --#{$prefix}input-phone-dropdown-border-radius: #{$input-phone-dropdown-border-radius};
36
+ --#{$prefix}input-phone-dropdown-border: #{$input-phone-dropdown-border};
37
+ --#{$prefix}input-phone-dropdown-shadow: #{$input-phone-dropdown-shadow};
38
+
39
+ // Dropdown items
40
+ --#{$prefix}input-phone-dropdown-item-height: #{$input-phone-dropdown-item-height};
41
+ --#{$prefix}input-phone-dropdown-item-padding: #{$input-phone-dropdown-item-padding};
42
+ --#{$prefix}input-phone-dropdown-item-font-size: #{$input-phone-dropdown-item-font-size};
43
+ --#{$prefix}input-phone-dropdown-item-font-weight: #{$input-phone-dropdown-item-font-weight};
44
+ --#{$prefix}input-phone-dropdown-item-background-color: #{$input-phone-dropdown-item-background-color};
45
+ --#{$prefix}input-phone-dropdown-item-text-color: #{$input-phone-dropdown-item-text-color};
46
+ --#{$prefix}input-phone-dropdown-item-dial-code-color: #{$input-phone-dropdown-item-dial-code-color};
47
+
48
+ // Selected / hover items
49
+ --#{$prefix}input-phone-hover-dropdown-item-background-color: #{$input-phone-hover-dropdown-item-background-color};
50
+ --#{$prefix}input-phone-selected-dropdown-item-background-color: #{$input-phone-selected-dropdown-item-background-color};
51
+ --#{$prefix}input-phone-selected-dropdown-item-color: #{$input-phone-selected-dropdown-item-color};
52
+ --#{$prefix}input-phone-selected-dropdown-item-font-weight: #{$input-phone-selected-dropdown-item-font-weight};
53
+ --#{$prefix}input-phone-selected-dropdown-item-dial-code-color: #{$input-phone-selected-dropdown-item-dial-code-color};
54
+
55
+ // Preferred list
56
+ --#{$prefix}input-phone-dropdown-preferred-list-item-background-color: #{$input-phone-dropdown-preferred-list-item-background-color};
57
+
58
+ // Preferred list separator
59
+ --#{$prefix}input-phone-dropdown-preferred-list-divider-margin: #{$input-phone-dropdown-preferred-list-divider-margin};
60
+ --#{$prefix}input-phone-dropdown-preferred-list-divider-color: #{$input-phone-dropdown-preferred-list-divider-color};
61
+
62
+ // Country code preview
63
+ --#{$prefix}input-phone-dial-code-preview-border-color: #{$input-phone-dial-code-preview-border-color};
64
+ --#{$prefix}input-phone-dial-code-preview-background-color: #{$input-phone-dial-code-preview-background-color};
65
+ --#{$prefix}input-phone-dial-code-preview-text-color: #{$input-phone-dial-code-preview-text-color};
66
+ --#{$prefix}input-phone-dial-code-preview-font-size: #{$input-phone-dial-code-preview-font-size};
67
+ --#{$prefix}input-phone-dial-code-preview-disabled-background-color: #{$input-phone-dial-code-preview-disabled-background-color};
68
+ --#{$prefix}input-phone-dial-code-preview-disabled-text-color: #{$input-phone-dial-code-preview-disabled-text-color};
69
+
70
+ :has(:disabled, .disabled) {
71
+ --#{$prefix}input-phone-background-color: var(--#{$prefix}input-phone-disabled-background-color);
72
+ }
73
+
74
+ .react-international-phone-country-selector {
75
+ position: relative;
76
+
77
+ &.input-group-text {
78
+ padding-block: 0;
79
+ }
80
+ }
81
+
82
+ .react-international-phone-country-selector-button {
83
+ box-sizing: border-box;
84
+ display: flex;
85
+ align-items: center;
86
+ justify-content: center;
87
+ height: var(--#{$prefix}input-phone-height);
88
+ padding: 0;
89
+ margin: 0;
90
+ text-transform: none;
91
+ appearance: button;
92
+ cursor: pointer;
93
+ user-select: none;
94
+ background-color: var(--#{$prefix}input-phone-country-selector-background-color, var(--#{$prefix}input-phone-background-color));
95
+ border: 0;
96
+
97
+ &:hover {
98
+ background-color: var(--#{$prefix}input-phone-country-selector-background-color-hover);
99
+ }
100
+
101
+ &--hide-dropdown {
102
+ cursor: auto;
103
+
104
+ &:hover {
105
+ background-color: transparent;
106
+ }
107
+ }
108
+
109
+ &__button-content {
110
+ display: flex;
111
+ align-items: center;
112
+ justify-content: center;
113
+ }
114
+
115
+ &__flag-emoji {
116
+ margin: 0 4px;
117
+
118
+ &--disabled {
119
+ opacity: .75;
120
+ }
121
+ }
122
+
123
+ &__dropdown-arrow {
124
+ margin-right: 4px;
125
+ border-top: var(--#{$prefix}input-phone-country-selector-arrow-size) solid var(--#{$prefix}input-phone-country-selector-arrow-color);
126
+ border-right: var(--#{$prefix}input-phone-country-selector-arrow-size) solid transparent;
127
+ border-left: var(--#{$prefix}input-phone-country-selector-arrow-size) solid transparent;
128
+ transition: all .1s ease-out;
129
+
130
+ &--active {
131
+ transform: rotateX(180deg);
132
+ }
133
+
134
+ &--disabled {
135
+ border-top-color: var(--#{$prefix}input-phone-disabled-country-selector-arrow-color);
136
+ }
137
+ }
138
+
139
+ &--disabled {
140
+ cursor: auto;
141
+ background-color: var(--#{$prefix}input-phone-disabled-country-selector-background-color, var(--#{$prefix}input-phone-disabled-background-color));
142
+
143
+ &:hover {
144
+ background-color: var(--#{$prefix}input-phone-disabled-country-selector-background-color, var(--#{$prefix}input-phone-disabled-background-color));
145
+ }
146
+ }
147
+ }
148
+
149
+ .react-international-phone-flag-emoji {
150
+ box-sizing: border-box;
151
+ width: var(--#{$prefix}input-phone-flag-width);
152
+ height: var(--#{$prefix}input-phone-flag-height);
153
+ }
154
+
155
+ .react-international-phone-country-selector-dropdown {
156
+ position: absolute;
157
+ top: var(--#{$prefix}input-phone-dropdown-top);
158
+ left: var(--#{$prefix}input-phone-dropdown-left);
159
+ z-index: 1;
160
+ display: flex;
161
+ flex-direction: column;
162
+ width: 300px;
163
+ max-height: 200px;
164
+ padding: 0;
165
+ margin: 0;
166
+ overflow-y: scroll;
167
+ color: var(--#{$prefix}input-phone-dropdown-item-text-color, var(--#{$prefix}input-phone-text-color));
168
+ list-style: none;
169
+ background-color: var(--#{$prefix}input-phone-dropdown-item-background-color, var(--#{$prefix}input-phone-background-color));
170
+ border: var(--#{$prefix}input-phone-dropdown-border);
171
+ border-radius: var(--#{$prefix}input-phone-dropdown-border-radius);
172
+ outline: 0;
173
+ box-shadow: var(--#{$prefix}input-phone-dropdown-shadow);
174
+ }
175
+
176
+ .react-international-phone-country-selector-dropdown__list-item--preferred {
177
+ background-color: var(--#{$prefix}input-phone-dropdown-preferred-list-item-background-color);
178
+ }
179
+
180
+ .react-international-phone-country-selector-dropdown__preferred-list-divider {
181
+ height: 1px;
182
+ margin: var(--#{$prefix}input-phone-dropdown-preferred-list-divider-margin);
183
+ background: var(--#{$prefix}input-phone-dropdown-preferred-list-divider-color, var(--#{$prefix}input-phone-border-color));
184
+ border: 0;
185
+ }
186
+
187
+ .react-international-phone-country-selector-dropdown__list-item {
188
+ box-sizing: border-box;
189
+ display: flex;
190
+ align-items: center;
191
+ min-height: var(--#{$prefix}input-phone-dropdown-item-height);
192
+ padding: var(--#{$prefix}input-phone-dropdown-item-padding);
193
+ cursor: pointer;
194
+
195
+ &:hover {
196
+ background-color: var(--#{$prefix}input-phone-hover-dropdown-item-background-color);
197
+ }
198
+
199
+ &-flag-emoji {
200
+ margin-right: 8px;
201
+ }
202
+
203
+ &-country-name {
204
+ margin-right: 8px;
205
+ overflow: hidden;
206
+ font-size: var(--#{$prefix}input-phone-dropdown-item-font-size);
207
+ text-overflow: ellipsis;
208
+ white-space: nowrap;
209
+ }
210
+
211
+ &-dial-code {
212
+ font-size: var(--#{$prefix}input-phone-dropdown-item-font-size);
213
+ font-weight: var(--#{$prefix}input-phone-dropdown-item-font-weight);
214
+ color: var(--#{$prefix}input-phone-dropdown-item-dial-code-color);
215
+ }
216
+
217
+ &--selected,
218
+ &--focused {
219
+ font-weight: var(--#{$prefix}input-phone-selected-dropdown-item-font-weight);
220
+ color: var(--#{$prefix}input-phone-selected-dropdown-item-color, var(--#{$prefix}input-phone-text-color));
221
+ background-color: var(--#{$prefix}input-phone-selected-dropdown-item-background-color);
222
+
223
+ .react-international-phone-country-selector-dropdown__list-item-dial-code {
224
+ --#{$prefix}input-phone-dropdown-item-font-weight: var(--#{$prefix}input-phone-selected-dropdown-item-font-weight);
225
+ --#{$prefix}input-phone-dropdown-item-dial-code-color: var(--#{$prefix}input-phone-selected-dropdown-item-dial-code-color);
226
+ }
227
+ }
228
+
229
+ &--focused {
230
+ background-color: var(--#{$prefix}input-phone-selected-dropdown-item-background-color);
231
+ }
232
+ }
233
+
234
+ .react-international-phone-dial-code-preview {
235
+ display: flex;
236
+ align-items: center;
237
+ justify-content: center;
238
+ padding: 0 8px;
239
+ margin-right: -1px;
240
+ font-size: var(--#{$prefix}input-phone-dial-code-preview-font-size, var(--#{$prefix}input-phone-font-size));
241
+ color: var(--#{$prefix}input-phone-dial-code-preview-text-color, var(--#{$prefix}input-phone-text-color));
242
+ background-color: var(--#{$prefix}input-phone-dial-code-preview-background-color, var(--#{$prefix}input-phone-background-color));
243
+ border: 1px solid var(--#{$prefix}input-phone-dial-code-preview-border-color, var(--#{$prefix}input-phone-border-color));
244
+
245
+ &--disabled {
246
+ color: var(--#{$prefix}input-phone-dial-code-preview-disabled-text-color, var(--#{$prefix}input-phone-disabled-text-color));
247
+ background-color: var(--#{$prefix}input-phone-dial-code-preview-disabled-background-color, var(--#{$prefix}input-phone-disabled-background-color));
248
+ }
249
+ }
250
+
251
+ .react-international-phone-input-container {
252
+ display: flex;
253
+
254
+ .react-international-phone-country-selector-button {
255
+ margin-right: -1px;
256
+ border-radius: var(--#{$prefix}input-phone-border-radius);
257
+ border-top-right-radius: 0;
258
+ border-bottom-right-radius: 0;
259
+ }
260
+
261
+ .react-international-phone-input {
262
+ box-sizing: border-box;
263
+ height: var(--#{$prefix}input-phone-height);
264
+ padding: 0 8px;
265
+ margin: 0;
266
+ overflow: visible;
267
+ font-family: inherit;
268
+ font-size: var(--#{$prefix}input-phone-font-size);
269
+ color: var(--#{$prefix}input-phone-text-color);
270
+ background-color: var(--#{$prefix}input-phone-background-color);
271
+ border: 1px solid var(--#{$prefix}input-phone-border-color);
272
+ border-radius: var(--#{$prefix}input-phone-border-radius);
273
+ border-top-left-radius: 0;
274
+ border-bottom-left-radius: 0;
275
+
276
+ &:focus {
277
+ outline: 0;
278
+ }
279
+
280
+ .react-international-phone-input--disabled {
281
+ color: var(--#{$prefix}input-phone-disabled-text-color);
282
+ background-color: var(--#{$prefix}input-phone-disabled-background-color);
283
+ }
284
+ }
285
+ }
286
+ }
@@ -8,7 +8,8 @@
8
8
  --#{$prefix}select-menu-z-index: #{$zindex-dropdown};
9
9
  --#{$prefix}select-option-focus-bg: var(--#{$prefix}gray-100);
10
10
  --#{$prefix}select-option-selected-color: var(--#{$prefix}secondary);
11
- --#{$prefix}select-option-selected-bg: var(--#{$prefix}gray-100);
11
+ --#{$prefix}select-option-selected-bg: unset;
12
+ --#{$prefix}select-option-selected-font-weight: var(--#{$prefix}fw-bold);
12
13
  --#{$prefix}select-option-is-checkbox-font-size: var(--#{$prefix}body-font-size);
13
14
  --#{$prefix}select-option-is-checkbox-font-weight: var(--#{$prefix}fw-normal);
14
15
  --#{$prefix}select-option-is-checkbox-color: var(--#{$prefix}gray-900);
@@ -42,6 +43,20 @@
42
43
  gap: var(--#{$prefix}select-gap);
43
44
  }
44
45
 
46
+ &.d-select-floating {
47
+ label {
48
+ position: absolute;
49
+ top: 8px;
50
+ left: 16px;
51
+ z-index: 10;
52
+ font-size: calc(var(--#{$prefix}body-font-size) * .85);
53
+ color: rgba(var(--#{$prefix}body-color-rgb), .65);
54
+ }
55
+ .d-select__value-container {
56
+ padding-top: 1rem;
57
+ }
58
+ }
59
+
45
60
  // input with elements
46
61
  .input-group {
47
62
  border: var(--#{$prefix}input-border-width) solid var(--#{$prefix}input-border-color);
@@ -86,7 +101,7 @@
86
101
  width: 100%;
87
102
  padding: $input-padding-y $input-padding-x;
88
103
  font-family: $input-font-family;
89
- @include rfs($input-font-size, $input-font-size);
104
+ @include rfs($input-font-size);
90
105
  font-weight: $input-font-weight;
91
106
  line-height: $input-line-height;
92
107
  color: $input-color;
@@ -138,8 +153,13 @@
138
153
  }
139
154
 
140
155
  .d-select__option--is-selected {
156
+ font-weight: var(--#{$prefix}select-option-selected-font-weight);
141
157
  color: var(--#{$prefix}select-option-selected-color);
142
158
  background: var(--#{$prefix}select-option-selected-bg);
159
+
160
+ &:hover {
161
+ --#{$prefix}select-option-selected-bg: var(--#{$prefix}gray-100);
162
+ }
143
163
  }
144
164
 
145
165
  // select option with checkbox