@tiny-design/react 1.4.0 → 1.5.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 (198) hide show
  1. package/es/alert/alert.js +2 -2
  2. package/es/alert/alert.js.map +1 -1
  3. package/es/alert/style/_index.scss +8 -4
  4. package/es/alert/style/index.css +7 -4
  5. package/es/auto-complete/style/_index.scss +4 -5
  6. package/es/auto-complete/style/index.css +4 -5
  7. package/es/breadcrumb/style/index.css +1 -1
  8. package/es/breadcrumb/types.d.ts +1 -1
  9. package/es/button/style/index.css +14 -14
  10. package/es/calendar/style/_index.scss +9 -9
  11. package/es/calendar/style/index.css +9 -9
  12. package/es/card/style/index.css +3 -3
  13. package/es/cascader/style/_index.scss +9 -9
  14. package/es/cascader/style/index.css +9 -9
  15. package/es/checkbox/style/_index.scss +9 -12
  16. package/es/checkbox/style/index.css +9 -12
  17. package/es/collapse/collapse-panel.js +20 -20
  18. package/es/collapse/collapse-panel.js.map +1 -1
  19. package/es/collapse/style/_index.scss +27 -10
  20. package/es/collapse/style/index.css +27 -12
  21. package/es/color-picker/style/_index.scss +7 -7
  22. package/es/color-picker/style/index.css +4 -4
  23. package/es/date-picker/style/_index.scss +1 -1
  24. package/es/date-picker/style/index.css +1 -1
  25. package/es/descriptions/style/_index.scss +5 -6
  26. package/es/descriptions/style/index.css +6 -6
  27. package/es/empty/style/_index.scss +1 -1
  28. package/es/empty/style/index.css +1 -1
  29. package/es/form/style/_index.scss +5 -6
  30. package/es/form/style/index.css +4 -4
  31. package/es/index.d.ts +2 -1
  32. package/es/index.js +2 -1
  33. package/es/input/style/_index.scss +5 -4
  34. package/es/input/style/_mixin.scss +1 -1
  35. package/es/input/style/index.css +21 -20
  36. package/es/input-number/input-number.js +11 -5
  37. package/es/input-number/input-number.js.map +1 -1
  38. package/es/input-number/style/_index.scss +5 -3
  39. package/es/input-number/style/index.css +13 -11
  40. package/es/input-otp/input-otp.js +5 -7
  41. package/es/input-otp/input-otp.js.map +1 -1
  42. package/es/input-otp/style/_index.scss +1 -1
  43. package/es/input-otp/style/index.css +8 -8
  44. package/es/list/list.js +2 -2
  45. package/es/list/list.js.map +1 -1
  46. package/es/list/style/_index.scss +3 -3
  47. package/es/list/style/index.css +3 -3
  48. package/es/marquee/index.d.ts +1 -0
  49. package/es/marquee/index.js +9 -0
  50. package/es/marquee/index.js.map +1 -0
  51. package/es/marquee/marquee.d.ts +8 -0
  52. package/es/marquee/marquee.js +42 -0
  53. package/es/marquee/marquee.js.map +1 -0
  54. package/es/marquee/style/_index.scss +77 -0
  55. package/es/marquee/style/index.css +64 -0
  56. package/es/marquee/style/index.d.ts +1 -0
  57. package/es/marquee/style/index.js +1 -0
  58. package/es/marquee/types.d.ts +21 -0
  59. package/es/native-select/style/index.css +4 -4
  60. package/es/notification/style/_index.scss +1 -1
  61. package/es/notification/style/index.css +1 -1
  62. package/es/pop-confirm/style/_index.scss +1 -1
  63. package/es/pop-confirm/style/index.css +1 -1
  64. package/es/popup/style/_index.scss +9 -9
  65. package/es/popup/style/index.css +10 -10
  66. package/es/radio/style/_index.scss +5 -8
  67. package/es/radio/style/index.css +5 -8
  68. package/es/segmented/style/_index.scss +10 -10
  69. package/es/segmented/style/index.css +9 -9
  70. package/es/select/style/_index.scss +16 -17
  71. package/es/select/style/index.css +15 -16
  72. package/es/speed-dial/style/_index.scss +2 -2
  73. package/es/speed-dial/style/index.css +2 -2
  74. package/es/statistic/style/_index.scss +2 -2
  75. package/es/statistic/style/index.css +2 -2
  76. package/es/strength-indicator/strength-indicator.js +4 -3
  77. package/es/strength-indicator/strength-indicator.js.map +1 -1
  78. package/es/style/_component.scss +1 -0
  79. package/es/style/base.css +57 -0
  80. package/es/table/style/_index.scss +6 -6
  81. package/es/table/style/index.css +5 -5
  82. package/es/tag/style/index.css +1 -1
  83. package/es/tag/tag.js +5 -5
  84. package/es/tag/tag.js.map +1 -1
  85. package/es/textarea/style/index.css +2 -2
  86. package/es/time-picker/style/_index.scss +1 -1
  87. package/es/time-picker/style/index.css +1 -1
  88. package/es/timeline/style/_index.scss +3 -3
  89. package/es/timeline/style/index.css +3 -3
  90. package/es/tooltip/style/index.css +1 -1
  91. package/es/transfer/style/_index.scss +4 -4
  92. package/es/transfer/style/index.css +4 -4
  93. package/es/tree/style/index.css +1 -1
  94. package/es/typography/style/_index.scss +2 -2
  95. package/es/typography/style/index.css +2 -2
  96. package/es/upload/style/_index.scss +4 -4
  97. package/es/upload/style/index.css +4 -4
  98. package/es/waterfall/waterfall.js +7 -2
  99. package/es/waterfall/waterfall.js.map +1 -1
  100. package/lib/alert/alert.js +2 -2
  101. package/lib/alert/alert.js.map +1 -1
  102. package/lib/alert/style/_index.scss +8 -4
  103. package/lib/alert/style/index.css +7 -4
  104. package/lib/auto-complete/style/_index.scss +4 -5
  105. package/lib/auto-complete/style/index.css +4 -5
  106. package/lib/breadcrumb/style/index.css +1 -1
  107. package/lib/breadcrumb/types.d.ts +1 -1
  108. package/lib/button/style/index.css +14 -14
  109. package/lib/calendar/style/_index.scss +9 -9
  110. package/lib/calendar/style/index.css +9 -9
  111. package/lib/card/style/index.css +3 -3
  112. package/lib/cascader/style/_index.scss +9 -9
  113. package/lib/cascader/style/index.css +9 -9
  114. package/lib/checkbox/style/_index.scss +9 -12
  115. package/lib/checkbox/style/index.css +9 -12
  116. package/lib/collapse/collapse-panel.js +20 -20
  117. package/lib/collapse/collapse-panel.js.map +1 -1
  118. package/lib/collapse/style/_index.scss +27 -10
  119. package/lib/collapse/style/index.css +27 -12
  120. package/lib/color-picker/style/_index.scss +7 -7
  121. package/lib/color-picker/style/index.css +4 -4
  122. package/lib/date-picker/style/_index.scss +1 -1
  123. package/lib/date-picker/style/index.css +1 -1
  124. package/lib/descriptions/style/_index.scss +5 -6
  125. package/lib/descriptions/style/index.css +6 -6
  126. package/lib/empty/style/_index.scss +1 -1
  127. package/lib/empty/style/index.css +1 -1
  128. package/lib/form/style/_index.scss +5 -6
  129. package/lib/form/style/index.css +4 -4
  130. package/lib/index.d.ts +2 -1
  131. package/lib/index.js +76 -74
  132. package/lib/input/style/_index.scss +5 -4
  133. package/lib/input/style/_mixin.scss +1 -1
  134. package/lib/input/style/index.css +21 -20
  135. package/lib/input-number/input-number.js +11 -5
  136. package/lib/input-number/input-number.js.map +1 -1
  137. package/lib/input-number/style/_index.scss +5 -3
  138. package/lib/input-number/style/index.css +13 -11
  139. package/lib/input-otp/input-otp.js +5 -7
  140. package/lib/input-otp/input-otp.js.map +1 -1
  141. package/lib/input-otp/style/_index.scss +1 -1
  142. package/lib/input-otp/style/index.css +8 -8
  143. package/lib/list/list.js +2 -2
  144. package/lib/list/list.js.map +1 -1
  145. package/lib/list/style/_index.scss +3 -3
  146. package/lib/list/style/index.css +3 -3
  147. package/lib/marquee/index.js +8 -0
  148. package/lib/marquee/index.js.map +1 -0
  149. package/lib/marquee/marquee.d.ts +8 -0
  150. package/lib/marquee/marquee.js +45 -0
  151. package/lib/marquee/marquee.js.map +1 -0
  152. package/lib/marquee/style/_index.scss +77 -0
  153. package/lib/marquee/style/index.css +64 -0
  154. package/lib/marquee/style/index.d.ts +1 -0
  155. package/lib/marquee/style/index.js +1 -0
  156. package/lib/marquee/types.d.ts +21 -0
  157. package/lib/native-select/style/index.css +4 -4
  158. package/lib/notification/style/_index.scss +1 -1
  159. package/lib/notification/style/index.css +1 -1
  160. package/lib/pop-confirm/style/_index.scss +1 -1
  161. package/lib/pop-confirm/style/index.css +1 -1
  162. package/lib/popup/style/_index.scss +9 -9
  163. package/lib/popup/style/index.css +10 -10
  164. package/lib/radio/style/_index.scss +5 -8
  165. package/lib/radio/style/index.css +5 -8
  166. package/lib/segmented/style/_index.scss +10 -10
  167. package/lib/segmented/style/index.css +9 -9
  168. package/lib/select/style/_index.scss +16 -17
  169. package/lib/select/style/index.css +15 -16
  170. package/lib/speed-dial/style/_index.scss +2 -2
  171. package/lib/speed-dial/style/index.css +2 -2
  172. package/lib/statistic/style/_index.scss +2 -2
  173. package/lib/statistic/style/index.css +2 -2
  174. package/lib/strength-indicator/strength-indicator.js +4 -3
  175. package/lib/strength-indicator/strength-indicator.js.map +1 -1
  176. package/lib/style/_component.scss +1 -0
  177. package/lib/style/base.css +57 -0
  178. package/lib/table/style/_index.scss +6 -6
  179. package/lib/table/style/index.css +5 -5
  180. package/lib/tag/style/index.css +1 -1
  181. package/lib/tag/tag.js +5 -5
  182. package/lib/tag/tag.js.map +1 -1
  183. package/lib/textarea/style/index.css +2 -2
  184. package/lib/time-picker/style/_index.scss +1 -1
  185. package/lib/time-picker/style/index.css +1 -1
  186. package/lib/timeline/style/_index.scss +3 -3
  187. package/lib/timeline/style/index.css +3 -3
  188. package/lib/tooltip/style/index.css +1 -1
  189. package/lib/transfer/style/_index.scss +4 -4
  190. package/lib/transfer/style/index.css +4 -4
  191. package/lib/tree/style/index.css +1 -1
  192. package/lib/typography/style/_index.scss +2 -2
  193. package/lib/typography/style/index.css +2 -2
  194. package/lib/upload/style/_index.scss +4 -4
  195. package/lib/upload/style/index.css +4 -4
  196. package/lib/waterfall/waterfall.js +7 -2
  197. package/lib/waterfall/waterfall.js.map +1 -1
  198. package/package.json +3 -3
@@ -0,0 +1,77 @@
1
+ @use '../../style/variables' as *;
2
+
3
+ .#{$prefix}-marquee {
4
+ overflow: hidden;
5
+ width: 0;
6
+ min-width: 100%;
7
+
8
+ &_fade {
9
+ mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
10
+ mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
11
+ }
12
+
13
+ &__track {
14
+ display: flex;
15
+ gap: var(--ty-marquee-gap, 16px);
16
+ width: max-content;
17
+ animation: ty-marquee-left var(--ty-marquee-duration, 50s) linear infinite;
18
+
19
+ &_reverse {
20
+ animation-name: ty-marquee-right;
21
+ }
22
+
23
+ &_pause-on-hover:hover {
24
+ animation-play-state: paused;
25
+ }
26
+
27
+ &_once {
28
+ animation-iteration-count: 1;
29
+ animation-fill-mode: forwards;
30
+ animation-name: ty-marquee-once-left;
31
+
32
+ &.#{$prefix}-marquee__track_reverse {
33
+ animation-name: ty-marquee-once-right;
34
+ }
35
+ }
36
+ }
37
+ }
38
+
39
+ @keyframes ty-marquee-left {
40
+ from {
41
+ transform: translateX(0);
42
+ }
43
+
44
+ to {
45
+ transform: translateX(-50%);
46
+ }
47
+ }
48
+
49
+ @keyframes ty-marquee-right {
50
+ from {
51
+ transform: translateX(-50%);
52
+ }
53
+
54
+ to {
55
+ transform: translateX(0);
56
+ }
57
+ }
58
+
59
+ @keyframes ty-marquee-once-left {
60
+ from {
61
+ transform: translateX(0);
62
+ }
63
+
64
+ to {
65
+ transform: translateX(-100%);
66
+ }
67
+ }
68
+
69
+ @keyframes ty-marquee-once-right {
70
+ from {
71
+ transform: translateX(-100%);
72
+ }
73
+
74
+ to {
75
+ transform: translateX(0);
76
+ }
77
+ }
@@ -0,0 +1,64 @@
1
+ .ty-marquee {
2
+ overflow: hidden;
3
+ width: 0;
4
+ min-width: 100%;
5
+ }
6
+ .ty-marquee_fade {
7
+ -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
8
+ mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
9
+ mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
10
+ }
11
+ .ty-marquee__track {
12
+ display: flex;
13
+ gap: var(--ty-marquee-gap, 16px);
14
+ width: -moz-max-content;
15
+ width: max-content;
16
+ animation: ty-marquee-left var(--ty-marquee-duration, 50s) linear infinite;
17
+ }
18
+ .ty-marquee__track_reverse {
19
+ animation-name: ty-marquee-right;
20
+ }
21
+ .ty-marquee__track_pause-on-hover:hover {
22
+ animation-play-state: paused;
23
+ }
24
+ .ty-marquee__track_once {
25
+ animation-iteration-count: 1;
26
+ animation-fill-mode: forwards;
27
+ animation-name: ty-marquee-once-left;
28
+ }
29
+ .ty-marquee__track_once.ty-marquee__track_reverse {
30
+ animation-name: ty-marquee-once-right;
31
+ }
32
+
33
+ @keyframes ty-marquee-left {
34
+ from {
35
+ transform: translateX(0);
36
+ }
37
+ to {
38
+ transform: translateX(-50%);
39
+ }
40
+ }
41
+ @keyframes ty-marquee-right {
42
+ from {
43
+ transform: translateX(-50%);
44
+ }
45
+ to {
46
+ transform: translateX(0);
47
+ }
48
+ }
49
+ @keyframes ty-marquee-once-left {
50
+ from {
51
+ transform: translateX(0);
52
+ }
53
+ to {
54
+ transform: translateX(-100%);
55
+ }
56
+ }
57
+ @keyframes ty-marquee-once-right {
58
+ from {
59
+ transform: translateX(-100%);
60
+ }
61
+ to {
62
+ transform: translateX(0);
63
+ }
64
+ }
@@ -0,0 +1 @@
1
+ export { };
@@ -0,0 +1 @@
1
+ import "./_index.css";
@@ -0,0 +1,21 @@
1
+ import { BaseProps } from "../_utils/props.js";
2
+ import React from "react";
3
+
4
+ //#region src/marquee/types.d.ts
5
+ interface MarqueeProps extends BaseProps, React.PropsWithoutRef<JSX.IntrinsicElements['div']> {
6
+ /** Scroll direction */
7
+ direction?: 'left' | 'right';
8
+ /** Animation duration in seconds */
9
+ duration?: number;
10
+ /** Pause animation on hover */
11
+ pauseOnHover?: boolean;
12
+ /** Gap between items in pixels */
13
+ gap?: number;
14
+ /** Apply edge fade mask */
15
+ fade?: boolean;
16
+ /** Loop the animation infinitely (duplicates children for seamless loop) */
17
+ infinite?: boolean;
18
+ }
19
+ //#endregion
20
+ export { MarqueeProps };
21
+ //# sourceMappingURL=types.d.ts.map
@@ -9,7 +9,7 @@
9
9
  vertical-align: middle;
10
10
  box-sizing: border-box;
11
11
  border: 1px solid var(--ty-input-border);
12
- border-radius: 2px;
12
+ border-radius: var(--ty-border-radius);
13
13
  background-color: var(--ty-native-select-bg);
14
14
  background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMiIgaGVpZ2h0PSIxNiIgdmlld0JveD0iMCAwIDEyIDE2Ij4gIDxwYXRoIGZpbGw9IiMzOTNFNDgiIGQ9Ik0wLjIyMiw1LjYxMyBMNS40NTEsMC4yMjMgQzUuNzU2MjEyMDksLTAuMDc0MzYzMjMzMyA2LjI0Mjc4NzkxLC0wLjA3NDM2MzIzMzMgNi41NDgsMC4yMjMgTDExLjc3OCw1LjYxMyBDMTIuMTgsNi4wMjcgMTIuMDI1LDYuNjY3IDExLjQwNyw2LjY2NyBMMC41OTIsNi42NjcgQy0wLjAyNCw2LjY2NyAtMC4xOCw2LjAyNyAwLjIyMiw1LjYxMyBaIE0wLjU5Miw5LjMzMyBMMTEuNDA3LDkuMzMzIEMxMi4wMjUsOS4zMzMgMTIuMTgsOS45NzMgMTEuNzc3LDEwLjM4NyBMNi41NDcsMTUuNzc3IEM2LjI0MTkxMjU4LDE2LjA3MzcxNDMgNS43NTYwODc0MiwxNi4wNzM3MTQzIDUuNDUxLDE1Ljc3NyBMMC4yMjIsMTAuMzg3IEMtMC4xOCw5Ljk3MyAtMC4wMjQsOS4zMzMgMC41OTIsOS4zMzMgWiIvPjwvc3ZnPg==");
15
15
  background-repeat: no-repeat, repeat;
@@ -43,13 +43,13 @@
43
43
  }
44
44
  .ty-select-native_sm {
45
45
  padding: 3px 25px 3px 7px;
46
- font-size: 0.875rem;
46
+ font-size: var(--ty-font-size-sm);
47
47
  }
48
48
  .ty-select-native_md {
49
49
  padding: 6px 25px 6px 7px;
50
- font-size: 1rem;
50
+ font-size: var(--ty-font-size-base);
51
51
  }
52
52
  .ty-select-native_lg {
53
53
  padding: 9px 25px 9px 7px;
54
- font-size: 1.25rem;
54
+ font-size: var(--ty-font-size-lg);
55
55
  }
@@ -5,7 +5,7 @@
5
5
  padding: 16px 24px;
6
6
  border-radius: 3px;
7
7
  color: var(--ty-color-text-secondary);
8
- font-size: $font-size-base;
8
+ font-size: var(--ty-font-size-base);
9
9
  box-shadow: var(--ty-shadow-modal);
10
10
  box-sizing: border-box;
11
11
  display: flex;
@@ -3,7 +3,7 @@
3
3
  padding: 16px 24px;
4
4
  border-radius: 3px;
5
5
  color: var(--ty-color-text-secondary);
6
- font-size: 1rem;
6
+ font-size: var(--ty-font-size-base);
7
7
  box-shadow: var(--ty-shadow-modal);
8
8
  box-sizing: border-box;
9
9
  display: flex;
@@ -9,7 +9,7 @@
9
9
 
10
10
  &__messages {
11
11
  padding: 0 0 12px;
12
- font-size: $font-size-base;
12
+ font-size: var(--ty-font-size-base);
13
13
  display: flex;
14
14
  align-items: center;
15
15
  }
@@ -6,7 +6,7 @@
6
6
  }
7
7
  .ty-pop-confirm__messages {
8
8
  padding: 0 0 12px;
9
- font-size: 1rem;
9
+ font-size: var(--ty-font-size-base);
10
10
  display: flex;
11
11
  align-items: center;
12
12
  }
@@ -5,19 +5,19 @@
5
5
  box-sizing: border-box;
6
6
  border-radius: $popover-border-radius;
7
7
  white-space: nowrap;
8
- font-size: $font-size-base;
8
+ font-size: var(--ty-font-size-base);
9
9
  text-align: left;
10
10
  box-shadow: var(--ty-shadow-popup);
11
11
  z-index: 999;
12
12
 
13
- &__arrow, &__arrow:before {
13
+ &__arrow, &__arrow::before {
14
14
  width: $popover-arrow-size;
15
15
  height: $popover-arrow-size;
16
16
  box-sizing: border-box;
17
17
  position: absolute;
18
18
  }
19
19
 
20
- &__arrow:before {
20
+ &__arrow::before {
21
21
  content: '';
22
22
  transform: rotate(45deg);
23
23
  }
@@ -26,7 +26,7 @@
26
26
  background-color: var(--ty-popup-light-bg);
27
27
  color: var(--ty-color-text-secondary);
28
28
  .#{$prefix}-popup {
29
- &__arrow:before {
29
+ &__arrow::before {
30
30
  background: var(--ty-popup-light-bg);
31
31
  }
32
32
  }
@@ -36,7 +36,7 @@
36
36
  background-color: var(--ty-popup-dark-bg);
37
37
  color: #fff;
38
38
  .#{$prefix}-popup {
39
- &__arrow:before {
39
+ &__arrow::before {
40
40
  background: var(--ty-popup-dark-bg);
41
41
  }
42
42
  }
@@ -46,7 +46,7 @@
46
46
  & > .#{$prefix}-popup__arrow {
47
47
  bottom: math.div(-$popover-arrow-size, 2);
48
48
 
49
- &:before {
49
+ &::before {
50
50
  box-shadow: 3px 3px 7px var(--ty-popup-arrow-shadow);
51
51
  }
52
52
  }
@@ -56,7 +56,7 @@
56
56
  > .#{$prefix}-popup__arrow {
57
57
  top: math.div(-$popover-arrow-size, 2);
58
58
 
59
- &:before {
59
+ &::before {
60
60
  box-shadow: -2px -2px 5px var(--ty-popup-arrow-shadow);
61
61
  }
62
62
  }
@@ -66,7 +66,7 @@
66
66
  > .#{$prefix}-popup__arrow {
67
67
  right: math.div(-$popover-arrow-size, 2);
68
68
 
69
- &:before {
69
+ &::before {
70
70
  box-shadow: 3px -3px 7px var(--ty-popup-arrow-shadow);
71
71
  }
72
72
  }
@@ -76,7 +76,7 @@
76
76
  > .#{$prefix}-popup__arrow {
77
77
  left: math.div(-$popover-arrow-size, 2);
78
78
 
79
- &:before {
79
+ &::before {
80
80
  box-shadow: -3px 3px 7px var(--ty-popup-arrow-shadow);
81
81
  }
82
82
  }
@@ -1,19 +1,19 @@
1
1
  .ty-popup {
2
2
  box-sizing: border-box;
3
- border-radius: 2px;
3
+ border-radius: var(--ty-border-radius);
4
4
  white-space: nowrap;
5
- font-size: 1rem;
5
+ font-size: var(--ty-font-size-base);
6
6
  text-align: left;
7
7
  box-shadow: var(--ty-shadow-popup);
8
8
  z-index: 999;
9
9
  }
10
- .ty-popup__arrow, .ty-popup__arrow:before {
10
+ .ty-popup__arrow, .ty-popup__arrow::before {
11
11
  width: 8px;
12
12
  height: 8px;
13
13
  box-sizing: border-box;
14
14
  position: absolute;
15
15
  }
16
- .ty-popup__arrow:before {
16
+ .ty-popup__arrow::before {
17
17
  content: "";
18
18
  transform: rotate(45deg);
19
19
  }
@@ -21,37 +21,37 @@
21
21
  background-color: var(--ty-popup-light-bg);
22
22
  color: var(--ty-color-text-secondary);
23
23
  }
24
- .ty-popup_light .ty-popup__arrow:before {
24
+ .ty-popup_light .ty-popup__arrow::before {
25
25
  background: var(--ty-popup-light-bg);
26
26
  }
27
27
  .ty-popup_dark {
28
28
  background-color: var(--ty-popup-dark-bg);
29
29
  color: #fff;
30
30
  }
31
- .ty-popup_dark .ty-popup__arrow:before {
31
+ .ty-popup_dark .ty-popup__arrow::before {
32
32
  background: var(--ty-popup-dark-bg);
33
33
  }
34
34
  .ty-popup[data-popper-placement^=top] > .ty-popup__arrow {
35
35
  bottom: -4px;
36
36
  }
37
- .ty-popup[data-popper-placement^=top] > .ty-popup__arrow:before {
37
+ .ty-popup[data-popper-placement^=top] > .ty-popup__arrow::before {
38
38
  box-shadow: 3px 3px 7px var(--ty-popup-arrow-shadow);
39
39
  }
40
40
  .ty-popup[data-popper-placement^=bottom] > .ty-popup__arrow {
41
41
  top: -4px;
42
42
  }
43
- .ty-popup[data-popper-placement^=bottom] > .ty-popup__arrow:before {
43
+ .ty-popup[data-popper-placement^=bottom] > .ty-popup__arrow::before {
44
44
  box-shadow: -2px -2px 5px var(--ty-popup-arrow-shadow);
45
45
  }
46
46
  .ty-popup[data-popper-placement^=left] > .ty-popup__arrow {
47
47
  right: -4px;
48
48
  }
49
- .ty-popup[data-popper-placement^=left] > .ty-popup__arrow:before {
49
+ .ty-popup[data-popper-placement^=left] > .ty-popup__arrow::before {
50
50
  box-shadow: 3px -3px 7px var(--ty-popup-arrow-shadow);
51
51
  }
52
52
  .ty-popup[data-popper-placement^=right] > .ty-popup__arrow {
53
53
  left: -4px;
54
54
  }
55
- .ty-popup[data-popper-placement^=right] > .ty-popup__arrow:before {
55
+ .ty-popup[data-popper-placement^=right] > .ty-popup__arrow::before {
56
56
  box-shadow: -3px 3px 7px var(--ty-popup-arrow-shadow);
57
57
  }
@@ -4,16 +4,13 @@
4
4
  position: relative;
5
5
  display: inline-flex;
6
6
  align-items: center;
7
- font-size: $font-size-base;
7
+ font-size: var(--ty-font-size-base);
8
8
  margin-right: 8px;
9
9
  color: var(--ty-color-text);
10
10
 
11
11
  &__native {
12
12
  position: absolute;
13
- top: 0;
14
- right: 0;
15
- bottom: 0;
16
- left: 0;
13
+ inset: 0;
17
14
  width: 100%;
18
15
  height: 100%;
19
16
  z-index: 1;
@@ -34,7 +31,7 @@
34
31
  align-items: center;
35
32
  justify-content: center;
36
33
 
37
- &:after {
34
+ &::after {
38
35
  box-sizing: border-box;
39
36
  display: inline-block;
40
37
  content: '';
@@ -54,7 +51,7 @@
54
51
 
55
52
  &_checked {
56
53
  .#{$prefix}-radio {
57
- &__inner:after {
54
+ &__inner::after {
58
55
  transform: scale(1);
59
56
  }
60
57
  }
@@ -69,7 +66,7 @@
69
66
  &__inner {
70
67
  border-color: var(--ty-radio-disabled-border);
71
68
 
72
- &:after {
69
+ &::after {
73
70
  background-color: var(--ty-radio-disabled-dot);
74
71
  }
75
72
 
@@ -2,16 +2,13 @@
2
2
  position: relative;
3
3
  display: inline-flex;
4
4
  align-items: center;
5
- font-size: 1rem;
5
+ font-size: var(--ty-font-size-base);
6
6
  margin-right: 8px;
7
7
  color: var(--ty-color-text);
8
8
  }
9
9
  .ty-radio__native {
10
10
  position: absolute;
11
- top: 0;
12
- right: 0;
13
- bottom: 0;
14
- left: 0;
11
+ inset: 0;
15
12
  width: 100%;
16
13
  height: 100%;
17
14
  z-index: 1;
@@ -31,7 +28,7 @@
31
28
  align-items: center;
32
29
  justify-content: center;
33
30
  }
34
- .ty-radio__inner:after {
31
+ .ty-radio__inner::after {
35
32
  box-sizing: border-box;
36
33
  display: inline-block;
37
34
  content: "";
@@ -46,7 +43,7 @@
46
43
  padding: 0 5px;
47
44
  line-height: 16px;
48
45
  }
49
- .ty-radio_checked .ty-radio__inner:after {
46
+ .ty-radio_checked .ty-radio__inner::after {
50
47
  transform: scale(1);
51
48
  }
52
49
  .ty-radio_disabled .ty-radio__native {
@@ -55,7 +52,7 @@
55
52
  .ty-radio_disabled .ty-radio__inner {
56
53
  border-color: var(--ty-radio-disabled-border);
57
54
  }
58
- .ty-radio_disabled .ty-radio__inner:after {
55
+ .ty-radio_disabled .ty-radio__inner::after {
59
56
  background-color: var(--ty-radio-disabled-dot);
60
57
  }
61
58
  .ty-radio_disabled .ty-radio__inner + span {
@@ -5,7 +5,7 @@
5
5
  align-items: center;
6
6
  padding: 2px;
7
7
  background: var(--ty-segmented-bg, #{$gray-200});
8
- border-radius: $border-radius;
8
+ border-radius: var(--ty-border-radius);
9
9
  box-sizing: border-box;
10
10
 
11
11
  &_block {
@@ -30,20 +30,20 @@
30
30
 
31
31
  &_sm .#{$prefix}-segmented__item {
32
32
  padding: 0 8px;
33
- height: calc(#{$height-sm} - 4px);
34
- font-size: $font-size-sm;
33
+ height: calc(var(--ty-height-sm) - 4px);
34
+ font-size: var(--ty-font-size-sm);
35
35
  }
36
36
 
37
37
  &_md .#{$prefix}-segmented__item {
38
38
  padding: 0 12px;
39
- height: calc(#{$height-md} - 4px);
40
- font-size: $font-size-base;
39
+ height: calc(var(--ty-height-md) - 4px);
40
+ font-size: var(--ty-font-size-base);
41
41
  }
42
42
 
43
43
  &_lg .#{$prefix}-segmented__item {
44
44
  padding: 0 16px;
45
- height: calc(#{$height-lg} - 4px);
46
- font-size: $font-size-lg;
45
+ height: calc(var(--ty-height-lg) - 4px);
46
+ font-size: var(--ty-font-size-lg);
47
47
  }
48
48
 
49
49
  &__item {
@@ -52,19 +52,19 @@
52
52
  align-items: center;
53
53
  gap: 4px;
54
54
  cursor: pointer;
55
- border-radius: $border-radius;
55
+ border-radius: var(--ty-border-radius);
56
56
  transition: all 0.2s;
57
57
  user-select: none;
58
58
  white-space: nowrap;
59
59
 
60
- &:hover:not(&_active):not(&_disabled) {
60
+ &:hover:not(&_active, &_disabled) {
61
61
  color: var(--ty-color-text, #{$gray-900});
62
62
  }
63
63
 
64
64
  &_active {
65
65
  background: var(--ty-segmented-active-bg, #fff);
66
66
  color: var(--ty-color-text, #{$gray-900});
67
- box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.06), 0 1px 3px 0 rgba(0, 0, 0, 0.1);
67
+ box-shadow: 0 1px 2px 0 rgb(0 0 0 / 6%), 0 1px 3px 0 rgb(0 0 0 / 10%);
68
68
  font-weight: 500;
69
69
  }
70
70
 
@@ -3,7 +3,7 @@
3
3
  align-items: center;
4
4
  padding: 2px;
5
5
  background: var(--ty-segmented-bg, #e9ecef);
6
- border-radius: 2px;
6
+ border-radius: var(--ty-border-radius);
7
7
  box-sizing: border-box;
8
8
  }
9
9
  .ty-segmented_block {
@@ -24,18 +24,18 @@
24
24
  }
25
25
  .ty-segmented_sm .ty-segmented__item {
26
26
  padding: 0 8px;
27
- height: calc(24px - 4px);
28
- font-size: 0.875rem;
27
+ height: calc(var(--ty-height-sm) - 4px);
28
+ font-size: var(--ty-font-size-sm);
29
29
  }
30
30
  .ty-segmented_md .ty-segmented__item {
31
31
  padding: 0 12px;
32
- height: calc(32px - 4px);
33
- font-size: 1rem;
32
+ height: calc(var(--ty-height-md) - 4px);
33
+ font-size: var(--ty-font-size-base);
34
34
  }
35
35
  .ty-segmented_lg .ty-segmented__item {
36
36
  padding: 0 16px;
37
- height: calc(42px - 4px);
38
- font-size: 1.25rem;
37
+ height: calc(var(--ty-height-lg) - 4px);
38
+ font-size: var(--ty-font-size-lg);
39
39
  }
40
40
  .ty-segmented__item {
41
41
  position: relative;
@@ -43,14 +43,14 @@
43
43
  align-items: center;
44
44
  gap: 4px;
45
45
  cursor: pointer;
46
- border-radius: 2px;
46
+ border-radius: var(--ty-border-radius);
47
47
  transition: all 0.2s;
48
48
  -webkit-user-select: none;
49
49
  -moz-user-select: none;
50
50
  user-select: none;
51
51
  white-space: nowrap;
52
52
  }
53
- .ty-segmented__item:hover:not(.ty-segmented__item_active):not(.ty-segmented__item_disabled) {
53
+ .ty-segmented__item:hover:not(.ty-segmented__item_active, .ty-segmented__item_disabled) {
54
54
  color: var(--ty-color-text, #212529);
55
55
  }
56
56
  .ty-segmented__item_active {
@@ -4,7 +4,7 @@
4
4
  position: relative;
5
5
  display: inline-block;
6
6
  width: 100%;
7
- font-size: $font-size-base;
7
+ font-size: var(--ty-font-size-base);
8
8
  cursor: pointer;
9
9
  outline: none;
10
10
 
@@ -20,20 +20,20 @@
20
20
 
21
21
  // Sizes
22
22
  &_sm .#{$prefix}-select__selector {
23
- min-height: $height-sm;
24
- font-size: $font-size-sm;
23
+ min-height: var(--ty-height-sm);
24
+ font-size: var(--ty-font-size-sm);
25
25
  padding: 0 24px 0 8px;
26
26
  }
27
27
 
28
28
  &_md .#{$prefix}-select__selector {
29
- min-height: $height-md;
30
- font-size: $font-size-base;
29
+ min-height: var(--ty-height-md);
30
+ font-size: var(--ty-font-size-base);
31
31
  padding: 0 28px 0 10px;
32
32
  }
33
33
 
34
34
  &_lg .#{$prefix}-select__selector {
35
- min-height: $height-lg;
36
- font-size: $font-size-lg;
35
+ min-height: var(--ty-height-lg);
36
+ font-size: var(--ty-font-size-lg);
37
37
  padding: 0 32px 0 12px;
38
38
  }
39
39
 
@@ -62,7 +62,7 @@
62
62
  align-items: center;
63
63
  width: 100%;
64
64
  border: $border-width solid var(--ty-input-border);
65
- border-radius: $border-radius;
65
+ border-radius: var(--ty-border-radius);
66
66
  background-color: var(--ty-input-bg);
67
67
  box-sizing: border-box;
68
68
  transition: all 0.3s;
@@ -173,9 +173,9 @@
173
173
  max-width: 100%;
174
174
  height: 22px;
175
175
  padding: 0 4px 0 8px;
176
- border-radius: $border-radius;
176
+ border-radius: var(--ty-border-radius);
177
177
  background-color: var(--ty-color-fill-secondary);
178
- font-size: $font-size-sm;
178
+ font-size: var(--ty-font-size-sm);
179
179
  line-height: 20px;
180
180
  color: var(--ty-color-text);
181
181
  box-sizing: border-box;
@@ -212,12 +212,11 @@
212
212
  list-style-type: none;
213
213
  background-color: var(--ty-select-dropdown-bg);
214
214
  box-sizing: border-box;
215
- overflow-x: hidden;
216
- overflow-y: auto;
215
+ overflow: hidden auto;
217
216
  z-index: 10;
218
217
  box-shadow: var(--ty-shadow-popup);
219
- border-radius: $border-radius;
220
- font-size: $font-size-base;
218
+ border-radius: var(--ty-border-radius);
219
+ font-size: var(--ty-font-size-base);
221
220
  max-height: $select-dropdown-max-height;
222
221
  }
223
222
 
@@ -238,7 +237,7 @@
238
237
  padding: 16px;
239
238
  text-align: center;
240
239
  color: var(--ty-color-text-quaternary);
241
- font-size: $font-size-sm;
240
+ font-size: var(--ty-font-size-sm);
242
241
  }
243
242
  }
244
243
 
@@ -284,9 +283,8 @@
284
283
  }
285
284
 
286
285
  .#{$prefix}-select-group {
287
-
288
286
  &__title {
289
- font-size: $font-size-sm;
287
+ font-size: var(--ty-font-size-sm);
290
288
  cursor: default;
291
289
  color: $gray-600;
292
290
  padding: 7px 12px;
@@ -307,6 +305,7 @@
307
305
  from {
308
306
  transform: rotate(0deg);
309
307
  }
308
+
310
309
  to {
311
310
  transform: rotate(360deg);
312
311
  }