@dynamic-framework/ui-react 1.25.0 → 1.27.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 (66) hide show
  1. package/dist/css/dynamic-ui-non-root.css +313 -934
  2. package/dist/css/dynamic-ui-non-root.min.css +2 -2
  3. package/dist/css/dynamic-ui-root.css +228 -152
  4. package/dist/css/dynamic-ui-root.min.css +2 -2
  5. package/dist/css/dynamic-ui.css +540 -1085
  6. package/dist/css/dynamic-ui.min.css +2 -2
  7. package/dist/index.esm.js +230 -63
  8. package/dist/index.esm.js.map +1 -1
  9. package/dist/index.js +230 -59
  10. package/dist/index.js.map +1 -1
  11. package/dist/types/components/DButtonIcon/DButtonIcon.d.ts +19 -0
  12. package/dist/types/components/DButtonIcon/index.d.ts +2 -0
  13. package/dist/types/components/DInput/DInput.d.ts +3 -2
  14. package/dist/types/components/DInputCheck/DInputCheck.d.ts +4 -2
  15. package/dist/types/components/DInputCounter/DInputCounter.d.ts +2 -1
  16. package/dist/types/components/DInputCurrency/DInputCurrency.d.ts +2 -1
  17. package/dist/types/components/DInputCurrencyBase/DInputCurrencyBase.d.ts +2 -1
  18. package/dist/types/components/DInputMask/DInputMask.d.ts +2 -1
  19. package/dist/types/components/DInputPin/DInputPin.d.ts +2 -2
  20. package/dist/types/components/DInputRange/DInputRange.d.ts +8 -0
  21. package/dist/types/components/DInputRange/index.d.ts +2 -0
  22. package/dist/types/components/DInputSearch/DInputSearch.d.ts +2 -1
  23. package/dist/types/components/DInputSelect/DInputSelect.d.ts +6 -3
  24. package/dist/types/components/DInputSwitch/DInputSwitch.d.ts +4 -2
  25. package/dist/types/components/DQuickActionCheck/DQuickActionCheck.d.ts +2 -2
  26. package/dist/types/components/DQuickActionSelect/DQuickActionSelect.d.ts +2 -2
  27. package/dist/types/components/DQuickActionSwitch/DQuickActionSwitch.d.ts +2 -2
  28. package/dist/types/components/DSelect/DSelect.d.ts +3 -3
  29. package/dist/types/components/DStepper/DStepper.d.ts +2 -1
  30. package/dist/types/components/DStepperDesktop/DStepperDesktop.d.ts +2 -1
  31. package/dist/types/components/DTableHead/DTableHead.d.ts +9 -0
  32. package/dist/types/components/DTableHead/index.d.ts +2 -0
  33. package/dist/types/components/DTabs/DTabs.d.ts +2 -1
  34. package/dist/types/components/DToast/DToast.d.ts +11 -0
  35. package/dist/types/components/DToast/components/DToastBody.d.ts +5 -0
  36. package/dist/types/components/DToast/components/DToastHeader.d.ts +5 -0
  37. package/dist/types/components/DToast/index.d.ts +4 -0
  38. package/dist/types/components/DToastContainer/DToastContainer.d.ts +2 -14
  39. package/dist/types/components/DToastContainer/useDToast.d.ts +11 -12
  40. package/dist/types/components/index.d.ts +4 -0
  41. package/dist/types/contexts/DContext.d.ts +1 -1
  42. package/dist/types/hooks/useFormatCurrency.d.ts +2 -1
  43. package/package.json +4 -5
  44. package/src/style/abstracts/_mixins.scss +41 -21
  45. package/src/style/abstracts/variables/_+import.scss +12 -3
  46. package/src/style/abstracts/variables/_border.scss +1 -1
  47. package/src/style/abstracts/variables/_buttons.scss +3 -5
  48. package/src/style/abstracts/variables/_colors.scss +10 -10
  49. package/src/style/abstracts/variables/_forms.scss +28 -50
  50. package/src/style/abstracts/variables/_quick-action-switch.scss +0 -2
  51. package/src/style/base/_+import.scss +1 -0
  52. package/src/style/base/_alert.scss +1 -1
  53. package/src/style/base/_buttons.scss +41 -16
  54. package/src/style/base/_form-check.scss +2 -19
  55. package/src/style/base/_form-range.scss +52 -0
  56. package/src/style/base/_form-switch.scss +4 -53
  57. package/src/style/base/_input-group.scss +1 -1
  58. package/src/style/components/_+import.scss +3 -2
  59. package/src/style/components/_d-button-icon.scss +26 -0
  60. package/src/style/components/_d-close.scss +11 -0
  61. package/src/style/components/_d-modal.scss +0 -11
  62. package/src/style/components/_d-offcanvas.scss +0 -11
  63. package/src/style/components/_d-quick-action-switch.scss +0 -7
  64. package/src/style/components/_d-select.scss +2 -0
  65. package/src/style/components/_d-table-head.scss +18 -0
  66. package/src/style/root/_root.scss +42 -36
@@ -1,58 +1,9 @@
1
1
  .form-switch {
2
- --#{$prefix}input-switch-bg: var(--#{$prefix}gray-300);
3
- --#{$prefix}input-switch-border-color: var(--#{$prefix}gray-500);
4
- --#{$prefix}input-switch-dot: #{escape-svg($form-switch-bg-image)};
5
- --#{$prefix}input-switch-hover-border-color: var(--#{$prefix}focus-ring-color);
6
- --#{$prefix}input-switch-focus-outline-color: var(--#{$prefix}focus-ring-color);
7
- --#{$prefix}input-switch-active-border-color: var(--#{$prefix}focus-ring-color);
8
- --#{$prefix}input-switch-active-bg: var(--#{$prefix}focus-ring-color);
9
- --#{$prefix}input-switch-disabled-border-color: var(--#{$prefix}gray-300);
10
- --#{$prefix}input-switch-disabled-bg: var(--#{$prefix}gray-100);
11
- --#{$prefix}input-switch-disabled-dot: #{escape-svg($form-switch-disabled-bg-image)};
12
- --#{$prefix}input-switch-label-color: #{$form-switch-label-color};
13
- --#{$prefix}input-switch-active-label-color: #{$form-switch-active-label-color};
14
-
15
- .form-check-label {
16
- color: var(--#{$prefix}input-switch-label-color);
17
- }
18
-
19
- .form-check-input:checked ~ .form-check-label {
20
- color: var(--#{$prefix}input-switch-active-label-color);
21
- }
22
-
23
- .form-check-input {
24
- background-color: var(--#{$prefix}input-switch-bg);
25
- background-image: var(--#{$prefix}input-switch-dot);
26
- border: 1px solid var(--#{$prefix}input-switch-border-color);
27
-
28
- &:checked {
29
- background-color: var(--#{$prefix}input-switch-active-bg);
30
- border-color: var(--#{$prefix}input-switch-active-border-color);
31
- }
32
-
33
- &[disabled]:not(:checked),
34
- &:disabled:not(:checked) {
35
- background-color: var(--#{$prefix}input-switch-disabled-bg);
36
- background-image: var(--#{$prefix}input-switch-disabled-dot);
37
- border-color: var(--#{$prefix}input-switch-disabled-border-color);
38
- }
39
- }
40
-
41
- &:hover {
42
- &.form-switch {
43
- .form-check-input:not([disabled]),
44
- .form-check-input:not(:disabled) {
45
- border-color: var(--#{$prefix}input-switch-hover-border-color);
46
- }
47
- }
2
+ .form-check-input.is-valid:not(:checked) {
3
+ --bs-form-switch-bg: #{escape-svg($form-switch-valid-bg-image)};
48
4
  }
49
5
 
50
- &:focus-within {
51
- &.form-switch {
52
- .form-check-input {
53
- outline: 2px solid var(--#{$prefix}input-switch-focus-outline-color);
54
- outline-offset: 2px;
55
- }
56
- }
6
+ .form-check-input.is-invalid:not(:checked) {
7
+ --bs-form-switch-bg: #{escape-svg($form-switch-invalid-bg-image)};
57
8
  }
58
9
  }
@@ -76,7 +76,7 @@
76
76
  $tooltip-bg-color: map-get($data, "tooltip-bg-color");
77
77
  $box-shadow: map-get($data, "focus-box-shadow");
78
78
 
79
- &:has(.form-control.is-#{$state}) {
79
+ &:has(.form-control.is-#{$state}, .form-select.is-#{$state}) {
80
80
  border-color: $border-color;
81
81
  box-shadow: $box-shadow;
82
82
 
@@ -1,7 +1,6 @@
1
- @import "node_modules/react-toastify/scss/main";
2
-
3
1
  @import "d-icon";
4
2
  @import "d-input-pin";
3
+ @import "d-button-icon";
5
4
  @import "d-quick-action-button";
6
5
  @import "d-quick-action-select";
7
6
  @import "d-quick-action-check";
@@ -13,6 +12,7 @@
13
12
  @import "d-datepicker";
14
13
  @import "d-timepicker";
15
14
  @import "d-tabs";
15
+ @import "d-close";
16
16
  @import "d-popover";
17
17
  @import "d-box-file";
18
18
  @import "d-carousel";
@@ -20,3 +20,4 @@
20
20
  @import "d-stepper-mobile";
21
21
  @import "d-card-account";
22
22
  @import "d-select";
23
+ @import "d-table-head";
@@ -0,0 +1,26 @@
1
+ .d-button-icon {
2
+ --#{$prefix}btn-padding-x: var(--#{$prefix}ref-spacer-3);
3
+ --#{$prefix}btn-padding-y: var(--#{$prefix}ref-spacer-3);
4
+ --#{$prefix}btn-lg-padding-y: var(--#{$prefix}ref-spacer-4);
5
+ --#{$prefix}btn-lg-padding-x: var(--#{$prefix}ref-spacer-4);
6
+ --#{$prefix}btn-sm-padding-y: var(--#{$prefix}ref-spacer-2);
7
+ --#{$prefix}btn-sm-padding-x: var(--#{$prefix}ref-spacer-2);
8
+ }
9
+
10
+ .btn-lg {
11
+ @include button-size(
12
+ var(--#{$prefix}btn-lg-padding-y),
13
+ var(--#{$prefix}btn-lg-padding-x),
14
+ var(--#{$prefix}btn-lg-font-size),
15
+ var(--#{$prefix}btn-lg-border-radius),
16
+ );
17
+ }
18
+
19
+ .btn-sm {
20
+ @include button-size(
21
+ var(--#{$prefix}btn-sm-padding-y),
22
+ var(--#{$prefix}btn-sm-padding-x),
23
+ var(--#{$prefix}btn-sm-font-size),
24
+ var(--#{$prefix}btn-sm-border-radius),
25
+ );
26
+ }
@@ -0,0 +1,11 @@
1
+ .d-close {
2
+ display: flex;
3
+ align-self: center;
4
+ padding: 0;
5
+ background: transparent;
6
+ border: 0;
7
+
8
+ .d-icon {
9
+ --#{$prefix}icon-size: var(--#{$prefix}ref-spacer-4);
10
+ }
11
+ }
@@ -16,17 +16,6 @@
16
16
  }
17
17
  }
18
18
 
19
- .d-modal-close {
20
- align-self: flex-start;
21
- padding: 0;
22
- background: transparent;
23
- border: 0;
24
-
25
- .d-icon {
26
- --#{$prefix}icon-size: var(--#{$prefix}ref-spacer-4);
27
- }
28
- }
29
-
30
19
  .d-modal-separator {
31
20
  height: var(--#{$prefix}modal-separator-height);
32
21
  margin: 0 var(--#{$prefix}modal-separator-margin-x);
@@ -23,17 +23,6 @@
23
23
  padding: var(--#{$prefix}offcanvas-padding-y) var(--#{$prefix}offcanvas-padding-x);
24
24
  }
25
25
 
26
- .d-offcanvas-close {
27
- align-self: flex-start;
28
- padding: 0;
29
- background: transparent;
30
- border: 0;
31
-
32
- .d-icon {
33
- --#{$prefix}icon-size: var(--#{$prefix}ref-spacer-4);
34
- }
35
- }
36
-
37
26
  .d-offcanvas-action-fill > * {
38
27
  flex: 1;
39
28
  }
@@ -8,7 +8,6 @@
8
8
 
9
9
  --#{$prefix}quick-action-switch-label-font-size: #{$quick-action-switch-label-font-size};
10
10
  --#{$prefix}quick-action-switch-label-font-weight: #{$quick-action-switch-label-font-weight};
11
- --#{$prefix}quick-action-switch-label-color: #{$quick-action-switch-label-color};
12
11
 
13
12
  --#{$prefix}quick-action-switch-hint-font-size: #{$quick-action-switch-hint-font-size};
14
13
  --#{$prefix}quick-action-switch-hint-font-weight: #{$quick-action-switch-hint-font-weight};
@@ -17,7 +16,6 @@
17
16
  --#{$prefix}quick-action-switch-hover-bg: #{$quick-action-switch-hover-bg};
18
17
 
19
18
  --#{$prefix}quick-action-switch-checked-bg: #{$quick-action-switch-checked-bg};
20
- --#{$prefix}quick-action-switch-checked-label-color: #{$quick-action-switch-checked-label-color};
21
19
  --#{$prefix}quick-action-switch-checked-hint-color: #{$quick-action-switch-checked-hint-color};
22
20
 
23
21
  display: flex;
@@ -38,10 +36,6 @@
38
36
  &:has(input:checked) {
39
37
  background: var(--#{$prefix}quick-action-switch-checked-bg);
40
38
 
41
- .d-quick-action-switch-label {
42
- color: var(--#{$prefix}quick-action-switch-checked-label-color);
43
- }
44
-
45
39
  .d-quick-action-switch-hint {
46
40
  color: var(--#{$prefix}quick-action-switch-checked-hint-color);
47
41
  }
@@ -56,7 +50,6 @@
56
50
  label {
57
51
  --#{$prefix}label-font-size: var(--#{$prefix}quick-action-switch-label-font-size);
58
52
  --#{$prefix}label-font-weight: var(--#{$prefix}quick-action-switch-label-font-weight);
59
- --#{$prefix}label-color: var(--#{$prefix}quick-action-switch-label-color);
60
53
  }
61
54
 
62
55
  .d-quick-action-switch-hint {
@@ -5,6 +5,7 @@
5
5
 
6
6
  // select
7
7
  --#{$prefix}select-menu-shadow: #{$box-shadow-sm};
8
+ --#{$prefix}select-menu-z-index: #{$zindex-dropdown};
8
9
  --#{$prefix}select-option-focus-bg: var(--#{$prefix}gray-100);
9
10
  --#{$prefix}select-option-selected-color: var(--#{$prefix}secondary);
10
11
  --#{$prefix}select-option-selected-bg: var(--#{$prefix}gray-100);
@@ -101,6 +102,7 @@
101
102
  // select menu
102
103
  .d-select__menu-list {
103
104
  top: calc(var(--#{$prefix}input-border-width) * 2);
105
+ z-index: var(--#{$prefix}select-menu-z-index);
104
106
  margin: calc(var(--#{$prefix}input-border-width) * -1);
105
107
  background: $input-bg;
106
108
  border-radius: var(--#{$prefix}input-border-radius);
@@ -0,0 +1,18 @@
1
+ .d-table-head {
2
+ button {
3
+ display: inline-flex;
4
+ flex: 1;
5
+ align-items: center;
6
+ justify-content: space-between;
7
+ width: 100%;
8
+ padding: 0;
9
+ font-size: inherit;
10
+ font-weight: inherit;
11
+ background: transparent;
12
+ border: unset;
13
+
14
+ .d-icon {
15
+ --#{$prefix}icon-size: var(--#{$prefix}fs-small);
16
+ }
17
+ }
18
+ }
@@ -167,7 +167,11 @@
167
167
  // scss-docs-start root-focus-variables
168
168
  --#{$prefix}focus-ring-width: #{$focus-ring-width};
169
169
  --#{$prefix}focus-ring-opacity: #{$focus-ring-opacity};
170
- --#{$prefix}focus-ring-color: rgba(var(--#{$prefix}#{$focus-ring-color-mapping}), var(--#{$prefix}focus-ring-opacity));
170
+ --#{$prefix}focus-ring-border-color-rgb: #{$focus-ring-border-color};
171
+ --#{$prefix}focus-ring-border-color: rgb(var(--#{$prefix}focus-ring-border-color-rgb));
172
+ --#{$prefix}focus-ring-base-color-rgb: var(--#{$prefix}#{$focus-ring-color-mapping});
173
+ --#{$prefix}focus-ring-base-color: rgb(var(--#{$prefix}focus-ring-base-color-rgb));
174
+ --#{$prefix}focus-ring-color: rgba(var(--#{$prefix}focus-ring-base-color-rgb), var(--#{$prefix}focus-ring-opacity));
171
175
  // scss-docs-end root-focus-variables
172
176
 
173
177
  // scss-docs-start root-form-validation-variables
@@ -207,7 +211,7 @@
207
211
  --#{$prefix}label-padding-x: var(--#{$prefix}ref-spacer-2);
208
212
  --#{$prefix}label-font-size: var(--#{$prefix}fs-small);
209
213
  --#{$prefix}label-font-weight: var(--#{$prefix}fw-normal);
210
- --#{$prefix}label-color: var(--#{$prefix}gray);
214
+ --#{$prefix}label-color: var(--#{$prefix}gray-700);
211
215
 
212
216
  --#{$prefix}btn-border-radius: #{$btn-border-radius};
213
217
  --#{$prefix}btn-lg-border-radius: #{$btn-border-radius-lg};
@@ -217,66 +221,68 @@
217
221
  @if $color == "light" {
218
222
  @include df-button-variant-variables(
219
223
  "light",
220
- $default-color: var(--#{$prefix}light),
224
+ $default-color: var(--#{$prefix}gray-100),
225
+ $default-text-color: color-contrast-var(map-get($all-colors, gray-100)),
221
226
  $hover-color: var(--#{$prefix}gray-200),
222
- $focus-color: var(--#{$prefix}light),
223
- $active-color: var(--#{$prefix}gray-300),
224
- $default-text-color: color-contrast-var(map-get($all-colors, light)),
225
227
  $hover-text-color: color-contrast-var(map-get($all-colors, gray-200)),
228
+ $focus-color: var(--#{$prefix}gray-200),
226
229
  $focus-text-color: color-contrast-var(map-get($all-colors, gray-200)),
230
+ $active-color: var(--#{$prefix}gray-300),
227
231
  $active-text-color: color-contrast-var(map-get($all-colors, gray-300)),
228
- $disabled-opacity: .65
232
+ $focus-shadow-rgb: var(--#{$prefix}gray-100-rgb),
229
233
  );
230
234
  @include df-button-outline-variant-variables(
231
235
  "light",
232
- $default-color: var(--#{$prefix}light),
233
- $hover-bg-color: var(--#{$prefix}light),
234
- $hover-text-color: color-contrast-var(map-get($all-colors, light)),
235
- $focus-text-color: var(--#{$prefix}light),
236
- $active-text-color: color-contrast-var(map-get($all-colors, light)),
236
+ $default-color: var(--#{$prefix}gray-100),
237
+ $hover-bg-color: var(--#{$prefix}gray-200),
238
+ $hover-text-color: color-contrast-var(map-get($all-colors, gray-200)),
239
+ $focus-bg-color: var(--#{$prefix}gray-200),
240
+ $focus-text-color: color-contrast-var(map-get($all-colors, gray-200)),
237
241
  $active-bg-color: var(--#{$prefix}gray-300),
238
- $active-border-color: var(--#{$prefix}gray-300)
242
+ $active-text-color: color-contrast-var(map-get($all-colors, gray-300)),
243
+ $focus-shadow-rgb: var(--#{$prefix}gray-100-rgb),
239
244
  );
240
245
  @include df-button-link-variant-variables(
241
246
  "light",
242
- $default-color: var(--#{$prefix}light),
243
- $hover-bg-color: var(--#{$prefix}light),
244
- $hover-text-color: color-contrast-var(map-get($all-colors, light)),
245
- $focus-text-color: var(--#{$prefix}light),
246
- $active-text-color: color-contrast-var(map-get($all-colors, light)),
247
- $active-bg-color: var(--#{$prefix}gray-300)
247
+ $default-color: var(--#{$prefix}gray-100),
248
+ $hover-text-color: var(--#{$prefix}gray-200),
249
+ $focus-text-color: var(--#{$prefix}gray-200),
250
+ $active-text-color: color-contrast-var(map-get($all-colors, gray-300)),
251
+ $active-bg-color: var(--#{$prefix}gray-300),
252
+ $focus-shadow-rgb: var(--#{$prefix}gray-100-rgb),
248
253
  );
249
254
  } @else if $color == "dark" {
250
255
  @include df-button-variant-variables(
251
256
  "dark",
252
- $default-color: var(--#{$prefix}dark),
257
+ $default-color: var(--#{$prefix}gray-900),
258
+ $default-text-color: color-contrast-var(map-get($all-colors, gray-900)),
253
259
  $hover-color: var(--#{$prefix}gray-800),
254
- $focus-color: var(--#{$prefix}dark),
255
- $active-color: var(--#{$prefix}gray-700),
256
- $default-text-color: color-contrast-var(map-get($all-colors, dark)),
257
260
  $hover-text-color: color-contrast-var(map-get($all-colors, gray-800)),
261
+ $focus-color: var(--#{$prefix}gray-800),
258
262
  $focus-text-color: color-contrast-var(map-get($all-colors, gray-800)),
263
+ $active-color: var(--#{$prefix}gray-700),
259
264
  $active-text-color: color-contrast-var(map-get($all-colors, gray-700)),
260
- $disabled-opacity: .65
265
+ $focus-shadow-rgb: var(--#{$prefix}gray-900-rgb),
261
266
  );
262
267
  @include df-button-outline-variant-variables(
263
268
  "dark",
264
- $default-color: var(--#{$prefix}dark),
265
- $hover-bg-color: var(--#{$prefix}dark),
266
- $hover-text-color: color-contrast-var(map-get($all-colors, dark)),
267
- $focus-text-color: var(--#{$prefix}dark),
268
- $active-text-color: color-contrast-var(map-get($all-colors, dark)),
269
+ $default-color: var(--#{$prefix}gray-900),
270
+ $hover-bg-color: var(--#{$prefix}gray-800),
271
+ $hover-text-color: color-contrast-var(map-get($all-colors, gray-800)),
272
+ $focus-bg-color: var(--#{$prefix}gray-800),
273
+ $focus-text-color: color-contrast-var(map-get($all-colors, gray-800)),
269
274
  $active-bg-color: var(--#{$prefix}gray-700),
270
- $active-border-color: var(--#{$prefix}gray-700)
275
+ $active-text-color: color-contrast-var(map-get($all-colors, gray-700)),
276
+ $focus-shadow-rgb: var(--#{$prefix}gray-900-rgb),
271
277
  );
272
278
  @include df-button-link-variant-variables(
273
279
  "dark",
274
- $default-color: var(--#{$prefix}dark),
275
- $hover-bg-color: var(--#{$prefix}dark),
276
- $hover-text-color: color-contrast-var(map-get($all-colors, dark)),
277
- $focus-text-color: var(--#{$prefix}dark),
278
- $active-text-color: color-contrast-var(map-get($all-colors, dark)),
279
- $active-bg-color: var(--#{$prefix}gray-700)
280
+ $default-color: var(--#{$prefix}gray-900),
281
+ $hover-text-color: var(--#{$prefix}gray-800),
282
+ $focus-text-color: var(--#{$prefix}gray-800),
283
+ $active-text-color: color-contrast-var(map-get($all-colors, gray-700)),
284
+ $active-bg-color: var(--#{$prefix}gray-700),
285
+ $focus-shadow-rgb: var(--#{$prefix}gray-900-rgb),
280
286
  );
281
287
  } @else {
282
288
  @include df-button-variant-variables($color);