@react-ui-org/react-ui 0.44.1 → 0.47.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (192) hide show
  1. package/CONTRIBUTING.md +7 -0
  2. package/README.md +15 -16
  3. package/dist/lib.development.js +271 -415
  4. package/dist/lib.js +1 -1
  5. package/package.json +11 -13
  6. package/src/lib/components/Alert/Alert.jsx +45 -44
  7. package/src/lib/components/Alert/Alert.scss +48 -48
  8. package/src/lib/components/Alert/README.mdx +2 -5
  9. package/src/lib/components/Alert/_settings.scss +4 -4
  10. package/src/lib/components/Alert/_theme.scss +50 -50
  11. package/src/lib/components/Alert/_tools.scss +6 -6
  12. package/src/lib/components/Badge/Badge.jsx +9 -11
  13. package/src/lib/components/Badge/Badge.scss +57 -57
  14. package/src/lib/components/Button/Button.jsx +14 -13
  15. package/src/lib/components/Button/Button.scss +2 -2
  16. package/src/lib/components/Button/README.mdx +11 -6
  17. package/src/lib/components/Button/_base.scss +69 -69
  18. package/src/lib/components/Button/_priorities.scss +49 -49
  19. package/src/lib/components/Button/_settings.scss +10 -10
  20. package/src/lib/components/Button/_theme.scss +18 -15
  21. package/src/lib/components/Button/_tools.scss +98 -100
  22. package/src/lib/components/Button/helpers/getRootLabelVisibilityClassName.js +4 -4
  23. package/src/lib/components/ButtonGroup/ButtonGroup.jsx +41 -25
  24. package/src/lib/components/ButtonGroup/ButtonGroup.scss +3 -3
  25. package/src/lib/components/ButtonGroup/README.mdx +1 -1
  26. package/src/lib/components/Card/Card.jsx +10 -9
  27. package/src/lib/components/Card/Card.scss +28 -28
  28. package/src/lib/components/Card/CardBody.jsx +17 -12
  29. package/src/lib/components/Card/CardFooter.jsx +22 -9
  30. package/src/lib/components/Card/_theme.scss +50 -50
  31. package/src/lib/components/Card/_tools.scss +6 -6
  32. package/src/lib/components/CheckboxField/CheckboxField.jsx +21 -20
  33. package/src/lib/components/CheckboxField/CheckboxField.scss +20 -20
  34. package/src/lib/components/CheckboxField/README.mdx +1 -1
  35. package/src/lib/components/FileInputField/FileInputField.jsx +16 -15
  36. package/src/lib/components/FileInputField/FileInputField.scss +19 -19
  37. package/src/lib/components/FileInputField/README.mdx +1 -1
  38. package/src/lib/components/FormLayout/FormLayout.jsx +19 -17
  39. package/src/lib/components/FormLayout/FormLayout.scss +17 -17
  40. package/src/lib/components/FormLayout/FormLayoutCustomField.jsx +18 -12
  41. package/src/lib/components/FormLayout/FormLayoutCustomField.scss +18 -18
  42. package/src/lib/components/FormLayout/README.mdx +26 -49
  43. package/src/lib/components/Grid/Grid.jsx +25 -24
  44. package/src/lib/components/Grid/Grid.scss +33 -29
  45. package/src/lib/components/Grid/GridSpan.jsx +11 -10
  46. package/src/lib/components/Grid/README.mdx +46 -20
  47. package/src/lib/components/Grid/{helpers → _helpers}/generateResponsiveCustomProperties.js +0 -2
  48. package/src/lib/components/Grid/_theme.scss +9 -9
  49. package/src/lib/components/Grid/_tools.scss +20 -20
  50. package/src/lib/components/Modal/Modal.jsx +38 -32
  51. package/src/lib/components/Modal/Modal.scss +73 -73
  52. package/src/lib/components/Modal/README.mdx +2 -5
  53. package/src/lib/components/Modal/_settings.scss +5 -5
  54. package/src/lib/components/Modal/_theme.scss +17 -17
  55. package/src/lib/components/Paper/Paper.jsx +9 -9
  56. package/src/lib/components/Paper/Paper.scss +8 -8
  57. package/src/lib/components/Popover/Popover.jsx +94 -0
  58. package/src/lib/components/Popover/Popover.scss +235 -0
  59. package/src/lib/components/Popover/PopoverWrapper.jsx +46 -0
  60. package/src/lib/components/Popover/README.mdx +333 -0
  61. package/src/lib/components/Popover/_helpers/getRootAlignmentClassName.js +13 -0
  62. package/src/lib/components/Popover/_helpers/getRootSideClassName.js +17 -0
  63. package/src/lib/components/Popover/_theme.scss +16 -0
  64. package/src/lib/components/Popover/index.js +2 -0
  65. package/src/lib/components/Radio/README.mdx +1 -1
  66. package/src/lib/components/Radio/Radio.jsx +15 -14
  67. package/src/lib/components/Radio/Radio.scss +26 -26
  68. package/src/lib/components/ScrollView/README.mdx +5 -5
  69. package/src/lib/components/ScrollView/ScrollView.jsx +22 -22
  70. package/src/lib/components/ScrollView/ScrollView.scss +113 -113
  71. package/src/lib/{services/elementPositionService.js → components/ScrollView/_helpers/getElementsPositionDifference.js} +0 -2
  72. package/src/lib/{hooks → components/ScrollView/_hooks}/useLoadResizeHook.js +1 -1
  73. package/src/lib/{hooks → components/ScrollView/_hooks}/useScrollPositionHook.js +1 -1
  74. package/src/lib/components/SelectField/README.mdx +1 -1
  75. package/src/lib/components/SelectField/SelectField.jsx +17 -16
  76. package/src/lib/components/SelectField/SelectField.scss +30 -30
  77. package/src/lib/components/Table/README.mdx +1 -1
  78. package/src/lib/components/Table/Table.jsx +3 -3
  79. package/src/lib/components/Table/Table.scss +28 -35
  80. package/src/lib/components/Table/_settings.scss +5 -5
  81. package/src/lib/components/Tabs/Tabs.jsx +4 -5
  82. package/src/lib/components/Tabs/Tabs.scss +21 -21
  83. package/src/lib/components/Tabs/TabsItem.jsx +7 -6
  84. package/src/lib/components/Tabs/TabsItem.scss +78 -78
  85. package/src/lib/components/Text/README.mdx +3 -3
  86. package/src/lib/components/Text/Text.jsx +16 -9
  87. package/src/lib/components/Text/Text.scss +23 -13
  88. package/src/lib/components/Text/_helpers/getRootClampClassName.js +11 -0
  89. package/src/lib/components/Text/{helpers → _helpers}/getRootHyphensClassName.js +1 -1
  90. package/src/lib/components/Text/{helpers → _helpers}/getRootWordWrappingClassName.js +1 -1
  91. package/src/lib/components/TextArea/README.mdx +1 -1
  92. package/src/lib/components/TextArea/TextArea.jsx +21 -17
  93. package/src/lib/components/TextArea/TextArea.scss +27 -27
  94. package/src/lib/components/TextField/README.mdx +1 -1
  95. package/src/lib/components/TextField/TextField.jsx +19 -18
  96. package/src/lib/components/TextField/TextField.scss +28 -28
  97. package/src/lib/components/TextLink/README.mdx +77 -0
  98. package/src/lib/components/TextLink/TextLink.jsx +44 -0
  99. package/src/lib/components/TextLink/TextLink.scss +11 -0
  100. package/src/lib/components/TextLink/_theme.scss +4 -0
  101. package/src/lib/components/TextLink/index.js +1 -0
  102. package/src/lib/components/Toggle/README.mdx +1 -1
  103. package/src/lib/components/Toggle/Toggle.jsx +21 -20
  104. package/src/lib/components/Toggle/Toggle.scss +20 -20
  105. package/src/lib/components/Toolbar/README.mdx +33 -5
  106. package/src/lib/components/Toolbar/Toolbar.jsx +33 -17
  107. package/src/lib/components/Toolbar/Toolbar.scss +29 -42
  108. package/src/lib/components/Toolbar/ToolbarGroup.jsx +28 -16
  109. package/src/lib/components/Toolbar/ToolbarItem.jsx +36 -10
  110. package/src/lib/{helpers → components/_helpers}/getRootColorClassName.js +1 -1
  111. package/src/lib/{helpers → components/_helpers}/getRootSizeClassName.js +1 -1
  112. package/src/lib/{helpers → components/_helpers}/getRootValidationStateClassName.js +1 -1
  113. package/src/lib/components/_helpers/isChildrenEmpty.js +3 -0
  114. package/src/lib/{helpers → components/_helpers}/resolveContextOrProp.js +0 -0
  115. package/src/lib/{utils → components/_helpers}/transferProps.js +1 -1
  116. package/src/lib/foundation.scss +11 -11
  117. package/src/lib/helpers.scss +2 -2
  118. package/src/lib/index.js +8 -17
  119. package/src/lib/provider/index.js +2 -1
  120. package/src/lib/provider/withGlobalProps.jsx +21 -0
  121. package/src/lib/styles/_utilities.scss +13 -13
  122. package/src/lib/styles/elements/_code.scss +7 -7
  123. package/src/lib/styles/elements/_links.scss +8 -8
  124. package/src/lib/styles/elements/_lists.scss +3 -3
  125. package/src/lib/styles/elements/_page.scss +14 -14
  126. package/src/lib/styles/elements/_rulers.scss +6 -6
  127. package/src/lib/styles/elements/_small.scss +2 -2
  128. package/src/lib/styles/generic/_box-sizing.scss +3 -2
  129. package/src/lib/styles/generic/_forms.scss +3 -3
  130. package/src/lib/styles/generic/_reset.scss +6 -6
  131. package/src/lib/styles/generic/_shared.scss +3 -3
  132. package/src/lib/styles/helpers/_animation.scss +8 -8
  133. package/src/lib/styles/settings/_breakpoints.scss +7 -7
  134. package/src/lib/styles/settings/_escaped-characters.scss +5 -5
  135. package/src/lib/styles/settings/_form-fields.scss +24 -24
  136. package/src/lib/styles/settings/_utilities.scss +112 -100
  137. package/src/lib/styles/theme/_colors.scss +50 -50
  138. package/src/lib/styles/theme/_form-fields.scss +32 -32
  139. package/src/lib/styles/theme/_spacing.scss +11 -11
  140. package/src/lib/styles/theme/_typography.scss +12 -11
  141. package/src/lib/styles/theme-constants/_breakpoints.scss +4 -4
  142. package/src/lib/styles/theme-constants/_colors.scss +2 -2
  143. package/src/lib/styles/theme-constants/_svg.scss +1 -2
  144. package/src/lib/styles/tools/_accessibility.scss +29 -29
  145. package/src/lib/styles/tools/_breakpoint.scss +11 -14
  146. package/src/lib/styles/tools/_caret.scss +8 -8
  147. package/src/lib/styles/tools/_colors.scss +3 -3
  148. package/src/lib/styles/tools/_reset.scss +24 -21
  149. package/src/lib/styles/tools/_scrollbar.scss +4 -4
  150. package/src/lib/styles/tools/_spacing.scss +14 -22
  151. package/src/lib/styles/tools/_string.scss +9 -9
  152. package/src/lib/styles/tools/_svg.scss +13 -16
  153. package/src/lib/styles/tools/_transition.scss +42 -44
  154. package/src/lib/styles/tools/_utilities.scss +19 -19
  155. package/src/lib/styles/tools/form-fields/_box-field-elements.scss +88 -88
  156. package/src/lib/styles/tools/form-fields/_box-field-layout.scss +147 -147
  157. package/src/lib/styles/tools/form-fields/_box-field-sizes.scss +13 -15
  158. package/src/lib/styles/tools/form-fields/_foundation.scss +12 -12
  159. package/src/lib/styles/tools/form-fields/_inline-field-elements.scss +82 -71
  160. package/src/lib/styles/tools/form-fields/_inline-field-layout.scss +88 -47
  161. package/src/lib/styles/tools/form-fields/_variants.scss +104 -106
  162. package/src/lib/theme.scss +959 -954
  163. package/src/lib/utils/classNames.js +8 -0
  164. package/src/lib/components/CTA/CTA.jsx +0 -60
  165. package/src/lib/components/CTA/CTA.scss +0 -71
  166. package/src/lib/components/CTA/CTACenter.jsx +0 -27
  167. package/src/lib/components/CTA/CTAEnd.jsx +0 -27
  168. package/src/lib/components/CTA/CTAStart.jsx +0 -27
  169. package/src/lib/components/CTA/README.mdx +0 -119
  170. package/src/lib/components/CTA/index.js +0 -4
  171. package/src/lib/components/Center/Center.jsx +0 -27
  172. package/src/lib/components/Center/Center.scss +0 -7
  173. package/src/lib/components/Center/README.mdx +0 -52
  174. package/src/lib/components/Center/index.js +0 -1
  175. package/src/lib/components/Link/Link.jsx +0 -45
  176. package/src/lib/components/Link/Link.scss +0 -11
  177. package/src/lib/components/Link/README.mdx +0 -85
  178. package/src/lib/components/Link/_theme.scss +0 -4
  179. package/src/lib/components/Link/index.js +0 -1
  180. package/src/lib/components/List/List.jsx +0 -71
  181. package/src/lib/components/List/List.scss +0 -53
  182. package/src/lib/components/List/ListItem.jsx +0 -31
  183. package/src/lib/components/List/README.mdx +0 -114
  184. package/src/lib/components/List/_theme.scss +0 -1
  185. package/src/lib/components/List/index.js +0 -2
  186. package/src/lib/components/Media/Media.jsx +0 -29
  187. package/src/lib/components/Media/Media.scss +0 -16
  188. package/src/lib/components/Media/MediaBody.jsx +0 -21
  189. package/src/lib/components/Media/MediaObject.jsx +0 -21
  190. package/src/lib/components/Media/README.mdx +0 -63
  191. package/src/lib/components/Media/index.js +0 -3
  192. package/src/lib/provider/withProviderContext.jsx +0 -32
@@ -1,70 +1,68 @@
1
- @use 'sass:list';
2
- @use 'sass:meta';
3
- @use 'sass:string';
4
- @use '../settings/animations';
1
+ @use "sass:list";
2
+ @use "sass:meta";
3
+ @use "sass:string";
4
+ @use "../settings/animations";
5
5
 
6
6
  $_allowed-transitions: (
7
- border-color,
8
- background-color,
9
- background-position,
10
- box-shadow,
11
- color,
12
- opacity,
13
- transform,
14
- visibility,
7
+ border-color,
8
+ background-color,
9
+ background-position,
10
+ box-shadow,
11
+ color,
12
+ opacity,
13
+ transform,
14
+ visibility,
15
15
  );
16
16
 
17
17
  $_reduced-motion-disallowed-transitions: (transform);
18
18
 
19
19
  @function _validate-transitions($properties) {
20
- @each $property in $properties {
21
- $is-allowed: list.index($_allowed-transitions, $property);
20
+ @each $property in $properties {
21
+ $is-allowed: list.index($_allowed-transitions, $property);
22
22
 
23
- @if not $is-allowed {
24
- @return false;
23
+ @if not $is-allowed {
24
+ @return false;
25
+ }
25
26
  }
26
- }
27
27
 
28
- @return true;
28
+ @return true;
29
29
  }
30
30
 
31
31
  @function _reduce-motion-transitions($properties) {
32
- $reduced-properties: ();
33
- $separator: list.separator($properties);
32
+ $reduced-properties: ();
33
+ $separator: list.separator($properties);
34
34
 
35
- @each $property in $properties {
36
- @if not list.index($_reduced-motion-disallowed-transitions, $property) {
37
- $reduced-properties: list.append($reduced-properties, $property, $separator: $separator);
35
+ @each $property in $properties {
36
+ @if not list.index($_reduced-motion-disallowed-transitions, $property) {
37
+ $reduced-properties: list.append($reduced-properties, $property, $separator: $separator);
38
+ }
38
39
  }
39
- }
40
40
 
41
- @return $reduced-properties;
41
+ @return $reduced-properties;
42
42
  }
43
43
 
44
44
  @mixin add($properties, $duration: 150ms) {
45
- $property-list: ();
45
+ $property-list: ();
46
46
 
47
- @if meta.type-of($properties) != 'string' and meta.type-of($properties) != 'list' {
48
- @error "Transition properties must be a string or a Sass list, `#{$properties}` given.";
49
- }
50
-
51
- $property-list: list.join($property-list, $properties);
47
+ @if meta.type-of($properties) != "string" and meta.type-of($properties) != "list" {
48
+ @error "Transition properties must be a string or a Sass list, `#{$properties}` given.";
49
+ }
52
50
 
53
- @if not _validate-transitions($property-list) {
54
- @error "Only [#{$_allowed-transitions}] transitions are allowed, [#{$properties}] given.";
55
- }
51
+ $property-list: list.join($property-list, $properties);
56
52
 
57
- @else {
58
- $reduced-property-list: _reduce-motion-transitions($property-list);
53
+ @if not _validate-transitions($property-list) {
54
+ @error "Only [#{$_allowed-transitions}] transitions are allowed, [#{$properties}] given.";
55
+ } @else {
56
+ $reduced-property-list: _reduce-motion-transitions($property-list);
59
57
 
60
- transition-property: $property-list;
61
- transition-duration: $duration;
62
- transition-timing-function: animations.$standard-timing-function;
58
+ transition-property: $property-list;
59
+ transition-duration: $duration;
60
+ transition-timing-function: animations.$standard-timing-function;
63
61
 
64
- @if (list.length($reduced-property-list) > 0) {
65
- @media (prefers-reduced-motion: reduce) {
66
- transition-property: $reduced-property-list;
67
- }
62
+ @if list.length($reduced-property-list) > 0 {
63
+ @media (prefers-reduced-motion: reduce) {
64
+ transition-property: $reduced-property-list;
65
+ }
66
+ }
68
67
  }
69
- }
70
68
  }
@@ -1,30 +1,30 @@
1
1
  // Utility generator
2
2
  // Inspired by Bootstrap 4
3
3
 
4
- @use 'sass:list';
5
- @use 'sass:map';
6
- @use 'sass:meta';
4
+ @use "sass:list";
5
+ @use "sass:map";
6
+ @use "sass:meta";
7
7
 
8
8
  @mixin generate($utility, $infix) {
9
- $values: map.get($utility, values);
9
+ $values: map.get($utility, values);
10
10
 
11
- // If the values are a list or string, convert it into a map
12
- @if meta.type-of($values) == 'string' or meta.type-of(list.nth($values, 1)) != 'list' {
13
- $values: list.zip($values, $values);
14
- }
11
+ // If the values are a list or string, convert it into a map
12
+ @if meta.type-of($values) == "string" or meta.type-of(list.nth($values, 1)) != "list" {
13
+ $values: list.zip($values, $values);
14
+ }
15
15
 
16
- @each $key, $value in $values {
17
- $properties: map.get($utility, property);
18
- $property-class: map.get($utility, class);
16
+ @each $key, $value in $values {
17
+ $properties: map.get($utility, property);
18
+ $property-class: map.get($utility, class);
19
19
 
20
- // Don't prefix if value key is null (e.g. with shadow class)
21
- $property-class-modifier: if($key, '-' + $key, '');
20
+ // Don't prefix if value key is null (e.g. with shadow class)
21
+ $property-class-modifier: if($key, "-" + $key, "");
22
22
 
23
- :global(.#{$property-class + $infix + $property-class-modifier}) {
24
- @each $property in $properties {
25
- // stylelint-disable-next-line declaration-no-important
26
- #{$property}: $value !important;
27
- }
23
+ :global(.#{$property-class + $infix + $property-class-modifier}) {
24
+ @each $property in $properties {
25
+ // stylelint-disable-next-line declaration-no-important
26
+ #{$property}: $value !important;
27
+ }
28
+ }
28
29
  }
29
- }
30
30
  }
@@ -4,121 +4,121 @@
4
4
  // 3. Let inputs properly fit various layout scenarios.
5
5
  // 4. Leave out space for SelectField caret.
6
6
 
7
- @use '../../settings/form-fields' as settings;
8
- @use '../../theme/form-fields' as theme;
9
- @use '../../tools/caret';
10
- @use '../spacing';
11
- @use '../transition';
7
+ @use "../../settings/form-fields" as settings;
8
+ @use "../../theme/form-fields" as theme;
9
+ @use "../../tools/caret";
10
+ @use "../spacing";
11
+ @use "../transition";
12
12
 
13
13
  @mixin input-container() {
14
- position: relative; // 1.
15
- display: inline-flex;
16
- min-width: 0; // 3.
17
- max-width: 100%; // 3.
14
+ position: relative; // 1.
15
+ display: inline-flex;
16
+ min-width: 0; // 3.
17
+ max-width: 100%; // 3.
18
18
  }
19
19
 
20
20
  @mixin input() {
21
- @include transition.add((opacity, color, border-color, background-color, box-shadow));
22
-
23
- appearance: none;
24
- width: theme.$box-input-width;
25
- min-width: theme.$box-input-min-width;
26
- max-width: 100%; // 3.
27
- height: var(--rui-local-height);
28
- padding: var(--rui-local-padding-y) var(--rui-local-padding-x);
29
- font-weight: settings.$box-input-font-weight;
30
- font-size: var(--rui-local-font-size);
31
- line-height: settings.$box-input-line-height;
32
- font-family: settings.$box-input-font-family;
33
- vertical-align: middle;
34
- color: var(--rui-local-color);
35
- border: theme.$box-border-width solid var(--rui-local-border-color);
36
- border-radius: theme.$box-border-radius;
37
- background: var(--rui-local-background);
38
- box-shadow: var(--rui-local-box-shadow);
39
-
40
- &::placeholder {
41
- color: theme.$box-placeholder-color;
42
- opacity: 1;
43
- }
21
+ @include transition.add((opacity, color, border-color, background-color, box-shadow));
22
+
23
+ appearance: none;
24
+ width: theme.$box-input-width;
25
+ min-width: theme.$box-input-min-width;
26
+ max-width: 100%; // 3.
27
+ height: var(--rui-local-height);
28
+ padding: var(--rui-local-padding-y) var(--rui-local-padding-x);
29
+ font-weight: settings.$box-input-font-weight;
30
+ font-size: var(--rui-local-font-size);
31
+ line-height: settings.$box-input-line-height;
32
+ font-family: settings.$box-input-font-family;
33
+ vertical-align: middle;
34
+ color: var(--rui-local-color);
35
+ border: theme.$box-border-width solid var(--rui-local-border-color);
36
+ border-radius: theme.$box-border-radius;
37
+ background: var(--rui-local-background);
38
+ box-shadow: var(--rui-local-box-shadow);
39
+
40
+ &::placeholder {
41
+ color: theme.$box-placeholder-color;
42
+ opacity: 1;
43
+ }
44
44
  }
45
45
 
46
46
  @mixin input-size() {
47
- width:
48
- calc(
49
- 1ch * var(--rui-custom-input-size)
50
- + var(--rui-local-arrows-width, 0)
51
- + 2 * var(--rui-local-padding-x)
52
- + 2 * #{theme.$box-border-width}
53
- ); // 2.
54
-
55
- min-width: auto; // 2.
56
-
57
- &[type="number"] {
58
- --rui-local-arrows-width: #{settings.$box-field-input-number-arrows-width};
59
- }
47
+ width:
48
+ calc(
49
+ 1ch * var(--rui-custom-input-size)
50
+ + var(--rui-local-arrows-width, 0)
51
+ + 2 * var(--rui-local-padding-x)
52
+ + 2 * #{theme.$box-border-width}
53
+ ); // 2.
54
+
55
+ min-width: auto; // 2.
56
+
57
+ &[type="number"] {
58
+ --rui-local-arrows-width: #{settings.$box-field-input-number-arrows-width};
59
+ }
60
60
  }
61
61
 
62
62
  @mixin input-textarea() {
63
- resize: vertical;
63
+ resize: vertical;
64
64
 
65
- &[cols] {
66
- min-width: auto;
67
- }
65
+ &[cols] {
66
+ min-width: auto;
67
+ }
68
68
  }
69
69
 
70
70
  @mixin input-select() {
71
- appearance: none;
72
- padding-right: calc(#{settings.$box-field-caret-size} + #{spacing.of(2)}); // 4.
71
+ appearance: none;
72
+ padding-right: calc(#{settings.$box-field-caret-size} + #{spacing.of(2)}); // 4.
73
73
 
74
- &::-ms-expand {
75
- display: none;
76
- }
74
+ &::-ms-expand {
75
+ display: none;
76
+ }
77
77
  }
78
78
 
79
79
  @mixin input-select-option() {
80
- option:disabled {
81
- color: theme.$box-select-option-disabled-color;
82
- }
80
+ option:disabled {
81
+ color: theme.$box-select-option-disabled-color;
82
+ }
83
83
  }
84
84
 
85
85
  @mixin caret() {
86
- @include transition.add((border-color));
87
-
88
- position: absolute; // 1.
89
- top: theme.$box-border-width;
90
- right: theme.$box-border-width;
91
- bottom: theme.$box-border-width;
92
- display: flex;
93
- align-items: center;
94
- justify-content: center;
95
- width: calc(#{settings.$box-field-caret-size} - 2 * #{theme.$box-border-width});
96
- border-top-right-radius: theme.$box-border-radius;
97
- border-bottom-right-radius: theme.$box-border-radius;
98
- pointer-events: none;
86
+ @include transition.add((border-color));
87
+
88
+ position: absolute; // 1.
89
+ top: theme.$box-border-width;
90
+ right: theme.$box-border-width;
91
+ bottom: theme.$box-border-width;
92
+ display: flex;
93
+ align-items: center;
94
+ justify-content: center;
95
+ width: calc(#{settings.$box-field-caret-size} - 2 * #{theme.$box-border-width});
96
+ border-top-right-radius: theme.$box-border-radius;
97
+ border-bottom-right-radius: theme.$box-border-radius;
98
+ pointer-events: none;
99
99
  }
100
100
 
101
101
  @mixin caret-icon() {
102
- @include caret.create();
102
+ @include caret.create();
103
103
 
104
- border-color: var(--rui-local-color);
104
+ border-color: var(--rui-local-color);
105
105
  }
106
106
 
107
107
  @mixin bottom-line() {
108
- @include transition.add((transform, opacity), 180ms);
109
-
110
- position: absolute; // 1.
111
- bottom: 0;
112
- width: 100%;
113
- height: settings.$box-field-bottom-line-height;
114
- opacity: 0;
115
- transform: scaleX(0);
116
- transform-origin: center center;
117
- pointer-events: none;
118
-
119
- .input:focus ~ & {
120
- background-color: var(--rui-local-border-color);
121
- opacity: 1;
122
- transform: scaleX(1);
123
- }
108
+ @include transition.add((transform, opacity), 180ms);
109
+
110
+ position: absolute; // 1.
111
+ bottom: 0;
112
+ width: 100%;
113
+ height: settings.$box-field-bottom-line-height;
114
+ opacity: 0;
115
+ transform: scaleX(0);
116
+ transform-origin: center center;
117
+ pointer-events: none;
118
+
119
+ .input:focus ~ & {
120
+ background-color: var(--rui-local-border-color);
121
+ opacity: 1;
122
+ transform: scaleX(1);
123
+ }
124
124
  }