@dynamic-framework/ui-react 2.7.0 → 2.9.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 (58) hide show
  1. package/dist/css/dynamic-ui.css +276 -22
  2. package/dist/css/dynamic-ui.min.css +2 -2
  3. package/dist/index.esm.js +677 -298
  4. package/dist/index.esm.js.map +1 -1
  5. package/dist/index.js +683 -297
  6. package/dist/index.js.map +1 -1
  7. package/dist/types/components/DDropdown/DDropdown.d.ts +10 -2
  8. package/dist/types/components/DInputCheck/DInputCheck.d.ts +1 -0
  9. package/dist/types/components/DInputSwitch/DInputSwitch.d.ts +2 -1
  10. package/dist/types/components/DModal/components/DModalHeader.d.ts +5 -1
  11. package/dist/types/components/DOffcanvas/components/DOffcanvasHeader.d.ts +5 -1
  12. package/dist/types/components/DOtp/DOtp.d.ts +1 -0
  13. package/dist/types/components/DOtp/components/OtpCountdown.d.ts +3 -2
  14. package/dist/types/components/DTooltip/DTooltip.d.ts +38 -3
  15. package/dist/types/components/DVoucher/DVoucher.d.ts +3 -1
  16. package/dist/types/components/DVoucher/hooks/useScreenshotDownload.d.ts +1 -1
  17. package/dist/types/components/DVoucher/hooks/useScreenshotDownload.spec.d.ts +1 -0
  18. package/dist/types/components/DVoucher/hooks/useScreenshotWebShare.d.ts +1 -1
  19. package/dist/types/components/DVoucher/hooks/useScreenshotWebShare.spec.d.ts +1 -0
  20. package/dist/types/components/DVoucher/index.d.ts +3 -0
  21. package/dist/types/components/index.d.ts +1 -1
  22. package/dist/types/hooks/index.d.ts +3 -0
  23. package/dist/types/hooks/tests/useCountdown.spec.d.ts +1 -0
  24. package/dist/types/hooks/useCountdown.d.ts +14 -0
  25. package/dist/types/hooks/useInputCurrency.d.ts +1 -6
  26. package/dist/types/hooks/useOtp.d.ts +98 -0
  27. package/dist/types/utils/buildUrl.d.ts +32 -0
  28. package/dist/types/utils/index.d.ts +2 -0
  29. package/dist/types/utils/sanitizeHref.d.ts +37 -0
  30. package/dist/types/utils/tests/buildUrl.spec.d.ts +1 -0
  31. package/dist/types/utils/tests/sanitizeHref.spec.d.ts +1 -0
  32. package/package.json +9 -6
  33. package/src/style/_shame.scss +1 -5
  34. package/src/style/abstracts/variables/_+import.scss +2 -0
  35. package/src/style/abstracts/variables/_box.scss +7 -0
  36. package/src/style/abstracts/variables/_forms.scss +1 -3
  37. package/src/style/abstracts/variables/_input-currency.scss +1 -0
  38. package/src/style/abstracts/variables/_shadow.scss +12 -1
  39. package/src/style/base/_+import.scss +0 -1
  40. package/src/style/base/_form-check.scss +4 -2
  41. package/src/style/components/_+import.scss +7 -0
  42. package/src/style/components/_d-box-file.scss +5 -0
  43. package/src/style/components/_d-box.scss +5 -5
  44. package/src/style/components/_d-close.scss +1 -0
  45. package/src/style/components/_d-confirm-modal.scss +17 -0
  46. package/src/style/components/_d-data-state-wrapper.scss +47 -0
  47. package/src/style/components/_d-datepicker.scss +11 -0
  48. package/src/style/components/_d-error-boundary.scss +7 -0
  49. package/src/style/components/_d-input-currency.scss +5 -0
  50. package/src/style/components/_d-otp.scss +54 -0
  51. package/src/style/components/_d-password-strength-meter.scss +76 -0
  52. package/src/style/components/_d-popover.scss +4 -0
  53. package/src/style/components/_d-stepper.scss +8 -0
  54. package/src/style/components/_d-tabs.scss +18 -0
  55. package/src/style/components/_d-voucher.scss +30 -0
  56. package/dist/types/components/DOtp/DOtpspec.d.ts +0 -0
  57. package/dist/types/components/DOtp/hooks/useCountdown.d.ts +0 -4
  58. package/src/style/base/_form-text.scss +0 -12
@@ -0,0 +1,17 @@
1
+ .confirm-modal {
2
+ --#{$prefix}confirm-modal-body-padding-y: var(--#{$prefix}ref-spacer-3);
3
+ --#{$prefix}confirm-modal-body-padding-x: var(--#{$prefix}ref-spacer-5);
4
+ --#{$prefix}confirm-modal-field-gap: var(--#{$prefix}ref-spacer-4);
5
+ }
6
+
7
+ .d-confirm-modal-body {
8
+ padding: var(--#{$prefix}confirm-modal-body-padding-y) var(--#{$prefix}confirm-modal-body-padding-x);
9
+ }
10
+
11
+ .d-confirm-modal-message {
12
+ margin-bottom: var(--#{$prefix}confirm-modal-field-gap);
13
+ }
14
+
15
+ .d-confirm-modal-field {
16
+ margin-bottom: var(--#{$prefix}confirm-modal-field-gap);
17
+ }
@@ -0,0 +1,47 @@
1
+ .d-empty-state {
2
+ --#{$prefix}empty-state-padding: var(--#{$prefix}ref-spacer-5);
3
+ --#{$prefix}empty-state-spacing: var(--#{$prefix}ref-spacer-3);
4
+ --#{$prefix}empty-state-color: var(--#{$prefix}secondary);
5
+
6
+ display: flex;
7
+ flex-direction: column;
8
+ align-items: center;
9
+ justify-content: center;
10
+ padding: var(--#{$prefix}empty-state-padding);
11
+ text-align: center;
12
+ }
13
+
14
+ .d-empty-state-icon {
15
+ margin-bottom: var(--#{$prefix}empty-state-spacing);
16
+ color: var(--#{$prefix}empty-state-color);
17
+ }
18
+
19
+ .d-empty-state-message {
20
+ margin-bottom: var(--#{$prefix}empty-state-spacing);
21
+ color: var(--#{$prefix}empty-state-color);
22
+ }
23
+
24
+ .d-error-state {
25
+ --#{$prefix}error-state-gap: var(--#{$prefix}ref-spacer-3);
26
+
27
+ display: flex;
28
+ gap: var(--#{$prefix}error-state-gap);
29
+ align-items: center;
30
+ }
31
+
32
+ .d-error-state-content {
33
+ flex: 1 1 auto;
34
+ }
35
+
36
+ .d-error-state-message {
37
+ margin-bottom: 0;
38
+ }
39
+
40
+ .d-loading-state {
41
+ --#{$prefix}loading-state-padding: var(--#{$prefix}ref-spacer-4);
42
+
43
+ display: flex;
44
+ align-items: center;
45
+ justify-content: center;
46
+ padding: var(--#{$prefix}loading-state-padding);
47
+ }
@@ -215,6 +215,12 @@
215
215
  }
216
216
  }
217
217
 
218
+ &-year-selector {
219
+ display: flex;
220
+ flex-grow: 1;
221
+ justify-content: center;
222
+ }
223
+
218
224
  &-day-selector {
219
225
  margin-bottom: var(--#{$prefix}ref-spacer-4);
220
226
 
@@ -287,6 +293,11 @@
287
293
  margin-top: -.5rem;
288
294
  }
289
295
 
296
+ .datepicker-top-header-title {
297
+ margin-bottom: 0;
298
+ font-weight: var(--#{$prefix}fw-normal);
299
+ }
300
+
290
301
  .react-datepicker__year,
291
302
  .react-datepicker__quarterPicker {
292
303
  --#{$prefix}datepicker-body-gap: 1rem;
@@ -0,0 +1,7 @@
1
+ .d-error-boundary-content {
2
+ --#{$prefix}error-boundary-gap: var(--#{$prefix}ref-spacer-2);
3
+
4
+ display: flex;
5
+ gap: var(--#{$prefix}error-boundary-gap);
6
+ align-items: center;
7
+ }
@@ -0,0 +1,5 @@
1
+ .d-input-currency-symbol {
2
+ --#{$prefix}input-currency-symbol-color: var(--#{$prefix}input-currency-component-symbol-color, #{$input-currency-symbol-color});
3
+
4
+ color: var(--#{$prefix}input-currency-symbol-color);
5
+ }
@@ -0,0 +1,54 @@
1
+ .d-otp {
2
+ --#{$prefix}otp-content-gap: var(--#{$prefix}ref-spacer-6);
3
+ --#{$prefix}otp-content-padding-x: var(--#{$prefix}ref-spacer-3);
4
+ --#{$prefix}otp-content-padding-bottom: var(--#{$prefix}ref-spacer-4);
5
+ --#{$prefix}otp-footer-gap: var(--#{$prefix}ref-spacer-4);
6
+ }
7
+
8
+ .d-otp-content {
9
+ display: flex;
10
+ flex-direction: column;
11
+ gap: var(--#{$prefix}otp-content-gap);
12
+ padding: 0 var(--#{$prefix}otp-content-padding-x) var(--#{$prefix}otp-content-padding-bottom);
13
+ }
14
+
15
+ .d-otp-fields {
16
+ display: flex;
17
+ flex-direction: column;
18
+ gap: var(--#{$prefix}otp-content-gap);
19
+ }
20
+
21
+ .d-otp-divider {
22
+ margin: 0;
23
+ }
24
+
25
+ .d-otp-footer {
26
+ display: flex;
27
+ flex-direction: column;
28
+ gap: var(--#{$prefix}otp-footer-gap);
29
+ align-items: center;
30
+
31
+ @include media-breakpoint-up(lg) {
32
+ flex-direction: row;
33
+ }
34
+ }
35
+
36
+ .d-otp-contact {
37
+ margin-bottom: 0;
38
+ font-size: .875em;
39
+
40
+ @include media-breakpoint-up(lg) {
41
+ margin-left: auto;
42
+ }
43
+ }
44
+
45
+ .d-otp-countdown {
46
+ display: flex;
47
+ gap: var(--#{$prefix}ref-spacer-2);
48
+ align-items: center;
49
+ }
50
+
51
+ .d-otp-countdown-text {
52
+ flex: 1 1 auto;
53
+ margin-bottom: 0;
54
+ }
@@ -0,0 +1,76 @@
1
+ .d-password-strength-meter {
2
+ --#{$prefix}password-strength-meter-margin-top: var(--#{$prefix}ref-spacer-2);
3
+
4
+ margin-top: var(--#{$prefix}password-strength-meter-margin-top);
5
+ }
6
+
7
+ .d-password-strength-bar {
8
+ --#{$prefix}password-strength-bar-height: 8px;
9
+ --#{$prefix}password-strength-bar-radius: var(--#{$prefix}border-radius-lg);
10
+ --#{$prefix}password-strength-bar-bg: var(--#{$prefix}gray-100);
11
+ --#{$prefix}password-strength-bar-margin-bottom: var(--#{$prefix}ref-spacer-2);
12
+
13
+ width: 100%;
14
+ height: var(--#{$prefix}password-strength-bar-height);
15
+ margin-bottom: var(--#{$prefix}password-strength-bar-margin-bottom);
16
+ overflow: hidden;
17
+ background: var(--#{$prefix}password-strength-bar-bg);
18
+ border-radius: var(--#{$prefix}password-strength-bar-radius);
19
+ }
20
+
21
+ .d-password-strength-bar-fill {
22
+ height: 100%;
23
+ transition: width .3s ease-in-out;
24
+
25
+ &.is-empty {
26
+ background: var(--#{$prefix}gray-200);
27
+ }
28
+
29
+ &.is-weak {
30
+ background: var(--#{$prefix}danger);
31
+ }
32
+
33
+ &.is-fair {
34
+ background: var(--#{$prefix}warning);
35
+ }
36
+
37
+ &.is-good {
38
+ background: var(--#{$prefix}info);
39
+ }
40
+
41
+ &.is-strong {
42
+ background: var(--#{$prefix}success);
43
+ }
44
+ }
45
+
46
+ .d-password-check-list {
47
+ display: flex;
48
+ flex-direction: column;
49
+ gap: var(--#{$prefix}ref-spacer-2);
50
+ padding-left: 0;
51
+ margin: 0;
52
+ list-style: none;
53
+ }
54
+
55
+ .d-password-check-item {
56
+ --#{$prefix}password-check-item-color: var(--#{$prefix}gray-600);
57
+
58
+ display: flex;
59
+ gap: var(--#{$prefix}ref-spacer-2);
60
+ align-items: flex-start;
61
+ font-size: .875em;
62
+ color: var(--#{$prefix}password-check-item-color);
63
+
64
+ &.is-valid {
65
+ color: var(--#{$prefix}success);
66
+ }
67
+ }
68
+
69
+ .d-password-check-item-icon {
70
+ flex-shrink: 0;
71
+ color: var(--#{$prefix}gray-300);
72
+ }
73
+
74
+ .d-password-check-item.is-valid .d-password-check-item-icon {
75
+ color: var(--#{$prefix}success);
76
+ }
@@ -11,5 +11,9 @@
11
11
  &:focus-visible {
12
12
  outline: 0;
13
13
  }
14
+
15
+ &.d-popover-content-fill {
16
+ width: 100%;
17
+ }
14
18
  }
15
19
  }
@@ -0,0 +1,8 @@
1
+ // Semantic hook classes for theming. The mobile/desktop toggle itself relies on
2
+ // Bootstrap's responsive display utilities (d-{breakpoint}-none / d-{breakpoint}-block)
3
+ // because the breakpoint is dynamic (component prop) and CSS custom properties
4
+ // cannot be read inside media queries.
5
+ .d-stepper-mobile,
6
+ .d-stepper-desktop {
7
+ width: 100%;
8
+ }
@@ -1,3 +1,21 @@
1
+ .d-tabs {
2
+ display: flex;
3
+ width: 100%;
4
+ }
5
+
6
+ .d-tabs-column {
7
+ flex-direction: column;
8
+ }
9
+
10
+ .d-tabs-nav-vertical {
11
+ flex-direction: column;
12
+ align-items: center;
13
+ }
14
+
15
+ .d-tabs-content {
16
+ width: 100%;
17
+ }
18
+
1
19
  .nav-toggle-button-group {
2
20
  --#{$prefix}toggle-button-group-border-color: var(--#{$prefix}gray-50);
3
21
  --#{$prefix}toggle-button-group-border-radius: 4rem;
@@ -5,6 +5,9 @@
5
5
  --#{$prefix}voucher-amount-rounded: var(--#{$prefix}ref-spacer-4);
6
6
  --#{$prefix}voucher-footer-gap: var(--#{$prefix}ref-spacer-4);
7
7
  --#{$prefix}voucher-margin: 0 0 var(--#{$prefix}ref-spacer-4) 0;
8
+ --#{$prefix}voucher-title-margin-bottom: var(--#{$prefix}ref-spacer-2);
9
+ --#{$prefix}voucher-amount-value-margin: var(--#{$prefix}ref-spacer-1);
10
+ --#{$prefix}voucher-divider-margin: var(--#{$prefix}ref-spacer-4);
8
11
  }
9
12
 
10
13
  .d-voucher-header {
@@ -28,3 +31,30 @@
28
31
  gap: var(--#{$prefix}voucher-footer-gap);
29
32
  justify-content: flex-start;
30
33
  }
34
+
35
+ .d-voucher-title-group {
36
+ text-align: center;
37
+ }
38
+
39
+ .d-voucher-title {
40
+ margin-bottom: var(--#{$prefix}voucher-title-margin-bottom);
41
+ }
42
+
43
+ .d-voucher-message {
44
+ margin: 0;
45
+ }
46
+
47
+ .d-voucher-amount-value {
48
+ margin: 0;
49
+ font-size: var(--#{$prefix}fs-3);
50
+ font-weight: var(--#{$prefix}fw-bold);
51
+ text-align: center;
52
+
53
+ &.d-voucher-amount-value-with-details {
54
+ margin-bottom: var(--#{$prefix}voucher-amount-value-margin);
55
+ }
56
+ }
57
+
58
+ .d-voucher-divider {
59
+ margin: var(--#{$prefix}voucher-divider-margin) 0;
60
+ }
File without changes
@@ -1,4 +0,0 @@
1
- export default function useCountdown(seconds: number): {
2
- secondsLeft: number;
3
- restartCountdown: () => void;
4
- };
@@ -1,12 +0,0 @@
1
- .form-text {
2
- --#{$prefix}form-text-padding: #{$form-text-padding-y} #{$form-text-padding-x};
3
- --#{$prefix}form-text-gap: var(--#{$prefix}ref-spacer-1);
4
- --#{$prefix}form-text-color: #{$form-text-color};
5
-
6
- display: inline-flex;
7
- flex-direction: row;
8
- gap: var(--#{$prefix}form-text-gap);
9
- align-items: center;
10
- padding: var(--#{$prefix}form-text-padding);
11
- color: var(--#{$prefix}form-text-color);
12
- }