@ably/ui 14.0.0-dev.968e4a2 → 14.0.0-dev.b96df46

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 (192) hide show
  1. package/README.md +8 -10
  2. package/core/.DS_Store +0 -0
  3. package/core/Accordion.js +1 -1
  4. package/core/Code.js +1 -1
  5. package/core/ConnectStateWrapper.js +1 -1
  6. package/core/ContactFooter/component.css +9 -7
  7. package/core/ContactFooter.js +1 -1
  8. package/core/CookieMessage/component.css +12 -10
  9. package/core/CookieMessage.js +1 -1
  10. package/core/DropdownMenu.js +1 -1
  11. package/core/Expander.js +1 -0
  12. package/core/FeaturedLink.js +1 -1
  13. package/core/Flash/component.css +21 -19
  14. package/core/Flash.js +1 -1
  15. package/core/Footer/component.css +24 -22
  16. package/core/Footer.js +1 -1
  17. package/core/Meganav/component.css +105 -103
  18. package/core/Meganav/component.js +1 -1
  19. package/core/Meganav.js +1 -1
  20. package/core/MeganavBlogPostsList.js +1 -1
  21. package/core/MeganavContentCompany.js +1 -1
  22. package/core/MeganavContentDevelopers.js +1 -1
  23. package/core/MeganavContentProducts.js +1 -1
  24. package/core/MeganavContentUseCases.js +1 -1
  25. package/core/MeganavControl.js +1 -1
  26. package/core/MeganavControlMobileDropdown.js +1 -1
  27. package/core/MeganavControlMobilePanelClose.js +1 -1
  28. package/core/MeganavControlMobilePanelOpen.js +1 -1
  29. package/core/MeganavItemsDesktop.js +1 -1
  30. package/core/MeganavItemsMobile.js +1 -1
  31. package/core/MeganavItemsSignedIn.js +1 -1
  32. package/core/MeganavSearch.js +1 -1
  33. package/core/MeganavSearchPanel.js +1 -1
  34. package/core/MeganavSearchSuggestions.js +1 -1
  35. package/core/Notice/component.css +6 -4
  36. package/core/Notice/component.js +1 -1
  37. package/core/Notice.js +1 -1
  38. package/core/Slider/component.css +38 -4
  39. package/core/Slider/component.js +1 -1
  40. package/core/Slider.js +1 -1
  41. package/core/Table/Table.js +1 -1
  42. package/core/Table/TableCell.js +4 -4
  43. package/core/Table/data.js +1 -1
  44. package/core/Table.js +1 -1
  45. package/core/Tooltip.js +1 -1
  46. package/core/icons/icon-gui-partial.svg +4 -0
  47. package/core/scripts.js +1 -1
  48. package/core/sprites.svg +1 -1
  49. package/core/styles/buttons.css +123 -121
  50. package/core/styles/forms.css +51 -49
  51. package/core/styles/layout.css +16 -14
  52. package/core/styles/properties.css +252 -250
  53. package/core/styles/text.css +167 -165
  54. package/core/styles.components.css +24 -22
  55. package/core/utils/syntax-highlighter.css +59 -55
  56. package/package.json +2 -3
  57. package/src/.DS_Store +0 -0
  58. package/src/core/.DS_Store +0 -0
  59. package/src/core/Accordion/Accordion.stories.tsx +1 -1
  60. package/src/core/Accordion.tsx +6 -6
  61. package/src/core/Code/Code.stories.tsx +1 -1
  62. package/src/core/Code.tsx +2 -3
  63. package/src/core/ConnectStateWrapper.tsx +1 -1
  64. package/src/core/ContactFooter/ContactFooter.stories.tsx +1 -1
  65. package/src/core/ContactFooter/component.css +9 -7
  66. package/src/core/ContactFooter.tsx +3 -4
  67. package/src/core/CookieMessage/CookieMessage.stories.tsx +1 -1
  68. package/src/core/CookieMessage/component.css +12 -10
  69. package/src/core/CookieMessage.tsx +1 -2
  70. package/src/core/CustomerLogos/CustomerLogos.stories.tsx +1 -1
  71. package/src/core/DropdownMenu/DropdownMenu.stories.tsx +2 -2
  72. package/src/core/DropdownMenu.tsx +1 -1
  73. package/src/core/Expander/Expander.stories.tsx +132 -0
  74. package/src/core/Expander.tsx +54 -0
  75. package/src/core/FeaturedLink/FeaturedLink.stories.tsx +1 -1
  76. package/src/core/FeaturedLink.tsx +1 -1
  77. package/src/core/Flash/Flash.stories.tsx +1 -1
  78. package/src/core/Flash/component.css +21 -19
  79. package/src/core/Flash.tsx +3 -4
  80. package/src/core/Footer/Footer.stories.tsx +1 -1
  81. package/src/core/Footer/component.css +24 -22
  82. package/src/core/Footer.tsx +2 -3
  83. package/src/core/Icon/Icon.stories.tsx +2 -1
  84. package/src/core/Loader/Loader.stories.tsx +1 -1
  85. package/src/core/Logo/Logo.stories.tsx +1 -1
  86. package/src/core/Meganav/Meganav.stories.tsx +1 -1
  87. package/src/core/Meganav/component.css +105 -103
  88. package/src/core/Meganav/component.js +0 -2
  89. package/src/core/Meganav.tsx +16 -19
  90. package/src/core/MeganavBlogPostsList.tsx +2 -2
  91. package/src/core/MeganavContentCompany.tsx +5 -5
  92. package/src/core/MeganavContentDevelopers.tsx +2 -2
  93. package/src/core/MeganavContentProducts.tsx +2 -2
  94. package/src/core/MeganavContentUseCases.tsx +2 -2
  95. package/src/core/MeganavControl.tsx +2 -2
  96. package/src/core/MeganavControlMobileDropdown.tsx +2 -2
  97. package/src/core/MeganavControlMobilePanelClose.tsx +1 -2
  98. package/src/core/MeganavControlMobilePanelOpen.tsx +1 -2
  99. package/src/core/MeganavItemsDesktop.tsx +3 -3
  100. package/src/core/MeganavItemsMobile.tsx +9 -9
  101. package/src/core/MeganavItemsSignedIn.tsx +4 -8
  102. package/src/core/MeganavSearch.tsx +3 -3
  103. package/src/core/MeganavSearchPanel.tsx +4 -4
  104. package/src/core/MeganavSearchSuggestions.tsx +2 -2
  105. package/src/core/Notice/component.css +6 -4
  106. package/src/core/Notice/component.js +1 -2
  107. package/src/core/Notice.tsx +2 -4
  108. package/src/core/SignOutLink.tsx +1 -1
  109. package/src/core/Slider/Slider.stories.tsx +83 -30
  110. package/src/core/Slider/component.css +38 -4
  111. package/src/core/Slider/component.js +0 -2
  112. package/src/core/Slider.tsx +164 -84
  113. package/src/core/Table/Table.tsx +38 -9
  114. package/src/core/Table/TableCell.tsx +31 -6
  115. package/src/core/Table/data.tsx +3 -3
  116. package/src/core/Table.tsx +5 -3
  117. package/src/core/Tooltip/Tooltip.stories.tsx +1 -1
  118. package/src/core/Tooltip.tsx +34 -6
  119. package/src/core/icons/icon-gui-partial.svg +4 -0
  120. package/src/core/scripts.js +0 -2
  121. package/src/core/styles/buttons.css +123 -121
  122. package/src/core/styles/forms.css +51 -49
  123. package/src/core/styles/layout.css +16 -14
  124. package/src/core/styles/properties.css +252 -250
  125. package/src/core/styles/text.css +167 -165
  126. package/src/core/styles.components.css +24 -22
  127. package/src/core/utils/syntax-highlighter.css +59 -55
  128. package/src/pages/Buttons.mdx +1 -1
  129. package/src/pages/Chips.mdx +1 -1
  130. package/src/pages/Forms.mdx +2 -2
  131. package/core/Accordion/component.js +0 -0
  132. package/core/ConnectStateWrapper/component.js +0 -0
  133. package/core/CookieMessage/component.js +0 -1
  134. package/core/CustomerLogos/component.js +0 -0
  135. package/core/DropdownMenu/component.js +0 -0
  136. package/core/FeaturedLink/component.js +0 -0
  137. package/core/Flash/component.js +0 -1
  138. package/core/Footer/component.js +0 -1
  139. package/core/Icon/component.js +0 -0
  140. package/core/Loader/component.js +0 -0
  141. package/core/Logo/component.js +0 -0
  142. package/core/MeganavContentCompany/component.js +0 -0
  143. package/core/MeganavContentDevelopers/component.js +0 -0
  144. package/core/MeganavContentProducts/.DS_Store +0 -0
  145. package/core/MeganavContentProducts/component.js +0 -0
  146. package/core/MeganavContentUseCases/.DS_Store +0 -0
  147. package/core/MeganavContentUseCases/component.js +0 -0
  148. package/core/MeganavItemsDesktop/.DS_Store +0 -0
  149. package/core/MeganavItemsDesktop/component.js +0 -0
  150. package/core/MeganavItemsMobile/.DS_Store +0 -0
  151. package/core/MeganavItemsMobile/component.js +0 -0
  152. package/core/MeganavItemsSignedIn/.DS_Store +0 -0
  153. package/core/MeganavItemsSignedIn/component.js +0 -0
  154. package/core/MeganavSearch/.DS_Store +0 -0
  155. package/core/MeganavSearch/component.js +0 -0
  156. package/core/MeganavSearchPanel/.DS_Store +0 -0
  157. package/core/MeganavSearchPanel/component.js +0 -0
  158. package/core/SignOutLink/.DS_Store +0 -0
  159. package/core/SignOutLink/component.js +0 -0
  160. package/src/core/Accordion/component.js +0 -0
  161. package/src/core/ConnectStateWrapper/component.js +0 -0
  162. package/src/core/CookieMessage/component.js +0 -1
  163. package/src/core/CustomerLogos/component.js +0 -0
  164. package/src/core/DropdownMenu/component.js +0 -0
  165. package/src/core/FeaturedLink/component.js +0 -0
  166. package/src/core/Flash/component.js +0 -1
  167. package/src/core/Footer/component.js +0 -1
  168. package/src/core/Icon/component.js +0 -0
  169. package/src/core/Loader/component.js +0 -0
  170. package/src/core/Logo/component.js +0 -0
  171. package/src/core/MeganavContentCompany/.DS_Store +0 -0
  172. package/src/core/MeganavContentCompany/component.js +0 -0
  173. package/src/core/MeganavContentDevelopers/.DS_Store +0 -0
  174. package/src/core/MeganavContentDevelopers/component.js +0 -0
  175. package/src/core/MeganavContentProducts/.DS_Store +0 -0
  176. package/src/core/MeganavContentProducts/component.js +0 -0
  177. package/src/core/MeganavContentUseCases/.DS_Store +0 -0
  178. package/src/core/MeganavContentUseCases/component.js +0 -1
  179. package/src/core/MeganavItemsDesktop/.DS_Store +0 -0
  180. package/src/core/MeganavItemsDesktop/component.js +0 -0
  181. package/src/core/MeganavItemsMobile/.DS_Store +0 -0
  182. package/src/core/MeganavItemsMobile/component.js +0 -0
  183. package/src/core/MeganavItemsSignedIn/.DS_Store +0 -0
  184. package/src/core/MeganavItemsSignedIn/component.js +0 -0
  185. package/src/core/MeganavSearch/.DS_Store +0 -0
  186. package/src/core/MeganavSearch/component.js +0 -0
  187. package/src/core/MeganavSearchPanel/.DS_Store +0 -0
  188. package/src/core/MeganavSearchPanel/component.js +0 -0
  189. package/src/core/SignOutLink/.DS_Store +0 -0
  190. package/src/core/SignOutLink/component.js +0 -0
  191. /package/core/{MeganavContentCompany → Tooltip}/.DS_Store +0 -0
  192. /package/{core/MeganavContentDevelopers → src/core/Tooltip}/.DS_Store +0 -0
@@ -1,7 +1,24 @@
1
- import React, { PropsWithChildren, useEffect, useRef, useState } from "react";
2
- import Icon from "../Icon/component.tsx";
1
+ import React, {
2
+ ButtonHTMLAttributes,
3
+ HTMLAttributes,
4
+ PropsWithChildren,
5
+ useEffect,
6
+ useRef,
7
+ useState,
8
+ } from "react";
9
+ import Icon from "./Icon";
3
10
 
4
- const Tooltip = ({ children }: PropsWithChildren) => {
11
+ type TooltipProps = {
12
+ triggerProps?: ButtonHTMLAttributes<HTMLButtonElement>;
13
+ tooltipProps?: HTMLAttributes<HTMLDivElement>;
14
+ } & HTMLAttributes<HTMLDivElement>;
15
+
16
+ const Tooltip = ({
17
+ children,
18
+ triggerProps,
19
+ tooltipProps,
20
+ ...rest
21
+ }: PropsWithChildren<TooltipProps>) => {
5
22
  const [open, setOpen] = useState(false);
6
23
  const [position, setPosition] = useState({ x: 0, y: 0 });
7
24
  const offset = 8;
@@ -27,21 +44,28 @@ const Tooltip = ({ children }: PropsWithChildren) => {
27
44
  }, [open]);
28
45
 
29
46
  return (
30
- <div className="relative inline-block align-top h-16">
47
+ <div
48
+ {...rest}
49
+ className={`relative inline-block align-top h-16 ${
50
+ rest?.className ?? ""
51
+ }`}
52
+ >
31
53
  <button
32
54
  onMouseEnter={() => setOpen(true)}
33
55
  onMouseLeave={() => setOpen(false)}
34
- className="ml-8 p-0 relative top-1 focus:outline-none"
35
56
  type="button"
36
57
  ref={reference}
37
58
  aria-describedby="tooltip"
59
+ {...triggerProps}
60
+ className={`ml-8 p-0 relative top-1 focus:outline-none ${
61
+ triggerProps?.className ?? ""
62
+ }`}
38
63
  >
39
64
  <Icon name="icon-gui-info" size="1rem" />
40
65
  </button>
41
66
 
42
67
  {open ? (
43
68
  <div
44
- className="bg-light-grey p-12 rounded pointer-events-none absolute z-20"
45
69
  role="tooltip"
46
70
  ref={floating}
47
71
  style={{
@@ -49,6 +73,10 @@ const Tooltip = ({ children }: PropsWithChildren) => {
49
73
  left: -position.x,
50
74
  boxShadow: "4px 4px 15px rgba(0, 0, 0, 0.2)",
51
75
  }}
76
+ {...tooltipProps}
77
+ className={`bg-light-grey p-12 rounded pointer-events-none absolute z-20 ${
78
+ tooltipProps?.className ?? ""
79
+ }`}
52
80
  >
53
81
  <div className="w-256">{children}</div>
54
82
  </div>
@@ -0,0 +1,4 @@
1
+ <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M1.5 12C1.5 17.799 6.20101 22.5 12 22.5C17.799 22.5 22.5 17.799 22.5 12C22.5 6.20101 17.799 1.5 12 1.5C6.20101 1.5 1.5 6.20101 1.5 12ZM1.2779e-06 12C9.30272e-07 18.6274 5.37258 24 12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 -1.95703e-07 12 -4.37114e-07C5.37259 -6.78525e-07 1.62554e-06 5.37258 1.2779e-06 12Z" fill="#03020D"/>
3
+ <path d="M11.5833 23.576C5.37903 23.3566 0.416667 18.2578 0.416667 12C0.416668 5.74218 5.37903 0.643381 11.5833 0.424021L11.5833 23.576Z" fill="#03020D" stroke="#03020D" stroke-width="0.833333"/>
4
+ </svg>
@@ -1,7 +1,5 @@
1
1
  import "array-flat-polyfill";
2
2
 
3
- import "./styles.css";
4
-
5
3
  export { default as reactRenderer, renderComponent } from "./react-renderer";
6
4
  export { default as loadSprites } from "./load-sprites";
7
5
  export { default as toggleChatWidget } from "./hubspot-chat-toggle";
@@ -1,122 +1,124 @@
1
- .ui-btn {
2
- @apply text-white bg-cool-black text-btn2 font-sans font-bold inline-block rounded p-btn;
3
- @apply hover:text-white hover:bg-active-orange;
4
- @apply active:text-white active:bg-red-orange;
5
- @apply focus:text-white focus:bg-cool-black focus:outline-gui-focus;
6
- @apply disabled:text-mid-grey disabled:bg-gui-unavailable disabled:cursor-not-allowed;
7
- @apply transition-colors;
8
- @apply inline-flex items-center justify-center;
9
- }
10
-
11
- .ui-btn-alt {
12
- transition: background-position 0.2s;
13
- background: linear-gradient(
14
- 61.2deg,
15
- var(--color-active-orange) 5%,
16
- #fe5215 19%,
17
- #fc4a13 27%,
18
- #f73c10 33%,
19
- #f1280a 39%,
20
- #e90f04 44%,
21
- var(--color-red-orange) 50%
22
- );
23
- background-size: 200% 100%;
24
- background-position: 0% 0%;
25
-
26
- @apply text-white text-btn2 font-sans font-bold inline-block rounded p-btn;
27
- @apply focus:outline-gui-focus;
28
- @apply inline-flex items-center justify-center;
29
- }
30
-
31
- .ui-btn-alt:hover,
32
- .ui-btn-alt:focus {
33
- background-position: 100% 0%;
34
- }
35
-
36
- .ui-btn-alt:disabled {
37
- background: linear-gradient(var(--gradient-transparent));
38
- @apply bg-gui-unavailable text-mid-grey cursor-not-allowed;
39
- }
40
-
41
- .ui-btn-invert {
42
- @apply text-cool-black bg-white text-btn2 font-sans font-bold inline-block rounded p-btn;
43
- @apply hover:text-white hover:bg-active-orange;
44
- @apply active:text-white active:bg-red-orange;
45
- @apply focus:text-white focus:bg-cool-black focus:outline-gui-focus;
46
- @apply disabled:text-mid-grey disabled:bg-gui-unavailable disabled:cursor-not-allowed;
47
- @apply transition-colors;
48
- @apply inline-flex items-center justify-center;
49
- }
50
-
51
- .ui-btn-secondary {
52
- @apply text-cool-black bg-white text-btn2 font-sans font-bold inline-block border-btn border-cool-black rounded p-btn;
53
- @apply hover:text-cool-black hover:border-active-orange hover:bg-white;
54
- @apply active:border-red-orange active:bg-white;
55
- @apply focus:border-cool-black focus:bg-white focus:outline-gui-focus;
56
- @apply disabled:text-gui-unavailable disabled:border-gui-unavailable disabled:bg-white disabled:cursor-not-allowed;
57
- @apply transition-colors;
58
- @apply inline-flex items-center justify-center;
59
- }
60
-
61
- .ui-btn-secondary-invert {
62
- @apply text-white bg-cool-black text-btn2 font-sans font-bold inline-block border-btn border-mid-grey rounded p-btn;
63
- @apply hover:text-white hover:border-active-orange;
64
- @apply active:border-red-orange;
65
- @apply focus:outline-gui-focus;
66
- @apply disabled:text-gui-unavailable disabled:border-gui-unavailable disabled:cursor-not-allowed;
67
- @apply transition-colors;
68
- @apply inline-flex items-center justify-center;
69
- }
70
-
71
- .ui-btn-icon {
72
- @apply w-24 h-24 mr-16;
73
- }
74
-
75
- .ui-btn-icon-small {
76
- @apply w-20 h-20 mr-12;
77
- }
78
-
79
- .ui-btn-icon-xsmall {
80
- @apply w-16 h-16 mr-8;
81
- }
82
-
83
- .ui-chip {
84
- @apply text-btn3 p-chip rounded text-cool-black;
85
- @apply hover:bg-mid-grey;
86
- @apply active:bg-red-orange active:text-white;
87
- @apply focus:bg-red-orange focus:text-white focus:outline-none;
88
- @apply disabled:text-mid-grey disabled:bg-gui-unavailable disabled:cursor-not-allowed;
89
- @apply transition-colors;
90
- }
91
-
92
- .ui-chip[data-selected] {
93
- @apply bg-active-orange text-white;
94
- }
95
-
96
- .ui-chip[data-selected]:hover {
97
- @apply bg-mid-grey text-cool-black;
98
- }
99
-
100
- .ui-chip[data-selected]:focus {
101
- @apply bg-red-orange text-white;
102
- }
103
-
104
- .ui-chip-alt {
105
- @apply text-btn3 p-chip rounded text-white;
106
- @apply hover:bg-gui-hover;
107
- @apply active:bg-gui-active active:text-white;
108
- @apply focus:bg-gui-active focus:text-white focus:outline-none;
109
- @apply disabled:text-mid-grey disabled:bg-gui-unavailable disabled:cursor-not-allowed;
110
- @apply transition-colors;
111
- }
112
-
113
- .ui-chip-alt[data-selected] {
114
- @apply bg-dark-grey text-white;
115
- }
116
- .ui-chip-alt[data-selected]:hover {
117
- @apply bg-gui-hover text-white;
118
- }
119
-
120
- .ui-chip-alt[data-selected]:focus {
121
- @apply bg-gui-active text-white;
1
+ @layer components {
2
+ .ui-btn {
3
+ @apply text-white bg-cool-black text-btn2 font-sans font-bold inline-block rounded p-btn;
4
+ @apply hover:text-white hover:bg-active-orange;
5
+ @apply active:text-white active:bg-red-orange;
6
+ @apply focus:text-white focus:bg-cool-black focus:outline-gui-focus;
7
+ @apply disabled:text-mid-grey disabled:bg-gui-unavailable disabled:cursor-not-allowed;
8
+ @apply transition-colors;
9
+ @apply inline-flex items-center justify-center;
10
+ }
11
+
12
+ .ui-btn-alt {
13
+ transition: background-position 0.2s;
14
+ background: linear-gradient(
15
+ 61.2deg,
16
+ var(--color-active-orange) 5%,
17
+ #fe5215 19%,
18
+ #fc4a13 27%,
19
+ #f73c10 33%,
20
+ #f1280a 39%,
21
+ #e90f04 44%,
22
+ var(--color-red-orange) 50%
23
+ );
24
+ background-size: 200% 100%;
25
+ background-position: 0% 0%;
26
+
27
+ @apply text-white text-btn2 font-sans font-bold inline-block rounded p-btn;
28
+ @apply focus:outline-gui-focus;
29
+ @apply inline-flex items-center justify-center;
30
+ }
31
+
32
+ .ui-btn-alt:hover,
33
+ .ui-btn-alt:focus {
34
+ background-position: 100% 0%;
35
+ }
36
+
37
+ .ui-btn-alt:disabled {
38
+ background: linear-gradient(var(--gradient-transparent));
39
+ @apply bg-gui-unavailable text-mid-grey cursor-not-allowed;
40
+ }
41
+
42
+ .ui-btn-invert {
43
+ @apply text-cool-black bg-white text-btn2 font-sans font-bold inline-block rounded p-btn;
44
+ @apply hover:text-white hover:bg-active-orange;
45
+ @apply active:text-white active:bg-red-orange;
46
+ @apply focus:text-white focus:bg-cool-black focus:outline-gui-focus;
47
+ @apply disabled:text-mid-grey disabled:bg-gui-unavailable disabled:cursor-not-allowed;
48
+ @apply transition-colors;
49
+ @apply inline-flex items-center justify-center;
50
+ }
51
+
52
+ .ui-btn-secondary {
53
+ @apply text-cool-black bg-white text-btn2 font-sans font-bold inline-block border-btn border-cool-black rounded p-btn;
54
+ @apply hover:text-cool-black hover:border-active-orange hover:bg-white;
55
+ @apply active:border-red-orange active:bg-white;
56
+ @apply focus:border-cool-black focus:bg-white focus:outline-gui-focus;
57
+ @apply disabled:text-gui-unavailable disabled:border-gui-unavailable disabled:bg-white disabled:cursor-not-allowed;
58
+ @apply transition-colors;
59
+ @apply inline-flex items-center justify-center;
60
+ }
61
+
62
+ .ui-btn-secondary-invert {
63
+ @apply text-white bg-cool-black text-btn2 font-sans font-bold inline-block border-btn border-mid-grey rounded p-btn;
64
+ @apply hover:text-white hover:border-active-orange;
65
+ @apply active:border-red-orange;
66
+ @apply focus:outline-gui-focus;
67
+ @apply disabled:text-gui-unavailable disabled:border-gui-unavailable disabled:cursor-not-allowed;
68
+ @apply transition-colors;
69
+ @apply inline-flex items-center justify-center;
70
+ }
71
+
72
+ .ui-btn-icon {
73
+ @apply w-24 h-24 mr-16;
74
+ }
75
+
76
+ .ui-btn-icon-small {
77
+ @apply w-20 h-20 mr-12;
78
+ }
79
+
80
+ .ui-btn-icon-xsmall {
81
+ @apply w-16 h-16 mr-8;
82
+ }
83
+
84
+ .ui-chip {
85
+ @apply text-btn3 p-chip rounded text-cool-black;
86
+ @apply hover:bg-mid-grey;
87
+ @apply active:bg-red-orange active:text-white;
88
+ @apply focus:bg-red-orange focus:text-white focus:outline-none;
89
+ @apply disabled:text-mid-grey disabled:bg-gui-unavailable disabled:cursor-not-allowed;
90
+ @apply transition-colors;
91
+ }
92
+
93
+ .ui-chip[data-selected] {
94
+ @apply bg-active-orange text-white;
95
+ }
96
+
97
+ .ui-chip[data-selected]:hover {
98
+ @apply bg-mid-grey text-cool-black;
99
+ }
100
+
101
+ .ui-chip[data-selected]:focus {
102
+ @apply bg-red-orange text-white;
103
+ }
104
+
105
+ .ui-chip-alt {
106
+ @apply text-btn3 p-chip rounded text-white;
107
+ @apply hover:bg-gui-hover;
108
+ @apply active:bg-gui-active active:text-white;
109
+ @apply focus:bg-gui-active focus:text-white focus:outline-none;
110
+ @apply disabled:text-mid-grey disabled:bg-gui-unavailable disabled:cursor-not-allowed;
111
+ @apply transition-colors;
112
+ }
113
+
114
+ .ui-chip-alt[data-selected] {
115
+ @apply bg-dark-grey text-white;
116
+ }
117
+ .ui-chip-alt[data-selected]:hover {
118
+ @apply bg-gui-hover text-white;
119
+ }
120
+
121
+ .ui-chip-alt[data-selected]:focus {
122
+ @apply bg-gui-active text-white;
123
+ }
122
124
  }
@@ -1,62 +1,64 @@
1
- .ui-checkbox-p1 {
2
- @apply flex items-start mb-16 font-sans font-medium;
3
- }
1
+ @layer components {
2
+ .ui-checkbox-p1 {
3
+ @apply flex items-start mb-16 font-sans font-medium;
4
+ }
4
5
 
5
- .ui-checkbox-p2 {
6
- @apply flex items-start mb-12 font-sans font-medium;
7
- }
6
+ .ui-checkbox-p2 {
7
+ @apply flex items-start mb-12 font-sans font-medium;
8
+ }
8
9
 
9
- .ui-checkbox-input {
10
- @apply opacity-0 absolute h-20 w-20;
11
- }
10
+ .ui-checkbox-input {
11
+ @apply opacity-0 absolute h-20 w-20;
12
+ }
12
13
 
13
- .ui-checkbox-styled {
14
- @apply w-20 h-20 mr-16;
15
- @apply bg-white flex flex-shrink-0 justify-center items-center;
16
- @apply border border-dark-grey rounded-md focus-within:border-active-orange;
17
- }
14
+ .ui-checkbox-styled {
15
+ @apply w-20 h-20 mr-16;
16
+ @apply bg-white flex flex-shrink-0 justify-center items-center;
17
+ @apply border border-dark-grey rounded-md focus-within:border-active-orange;
18
+ }
18
19
 
19
- .ui-checkbox-styled-tick {
20
- @apply hidden text-white;
21
- }
20
+ .ui-checkbox-styled-tick {
21
+ @apply hidden text-white;
22
+ }
22
23
 
23
- .ui-checkbox-label-p1 {
24
- @apply select-none;
25
- @apply text-p1 font-medium text-cool-black;
26
- }
24
+ .ui-checkbox-label-p1 {
25
+ @apply select-none;
26
+ @apply text-p1 font-medium text-cool-black;
27
+ }
27
28
 
28
- .ui-checkbox-label-p2 {
29
- @apply select-none;
30
- @apply text-p2 font-medium text-cool-black;
31
- }
29
+ .ui-checkbox-label-p2 {
30
+ @apply select-none;
31
+ @apply text-p2 font-medium text-cool-black;
32
+ }
32
33
 
33
- .ui-checkbox-input:disabled + .ui-checkbox-styled {
34
- @apply bg-gui-unavailable border;
35
- }
34
+ .ui-checkbox-input:disabled + .ui-checkbox-styled {
35
+ @apply bg-gui-unavailable border;
36
+ }
36
37
 
37
- .ui-checkbox-input:focus + .ui-checkbox-styled {
38
- border-width: 0.125rem;
39
- @apply border-gui-focus;
40
- }
38
+ .ui-checkbox-input:focus + .ui-checkbox-styled {
39
+ border-width: 0.125rem;
40
+ @apply border-gui-focus;
41
+ }
41
42
 
42
- .ui-checkbox-input:checked + .ui-checkbox-styled {
43
- @apply bg-active-orange border-dark-grey border;
44
- }
43
+ .ui-checkbox-input:checked + .ui-checkbox-styled {
44
+ @apply bg-active-orange border-dark-grey border;
45
+ }
45
46
 
46
- .ui-checkbox-input:checked + .ui-checkbox-styled svg {
47
- @apply block;
48
- }
47
+ .ui-checkbox-input:checked + .ui-checkbox-styled svg {
48
+ @apply block;
49
+ }
49
50
 
50
- .ui-textarea {
51
- @apply font-sans font-medium text-cool-black text-p1;
52
- @apply p-input mb-16;
53
- @apply bg-light-grey border-mid-grey transition-input border rounded block w-full;
54
- @apply hover:bg-white hover:shadow-input hover:border-transparent;
55
- @apply focus:bg-white focus:shadow-input focus:border-transparent focus:outline-gui-focus;
56
- }
51
+ .ui-textarea {
52
+ @apply font-sans font-medium text-cool-black text-p1;
53
+ @apply p-input mb-16;
54
+ @apply bg-light-grey border-mid-grey transition-input border rounded block w-full;
55
+ @apply hover:bg-white hover:shadow-input hover:border-transparent;
56
+ @apply focus:bg-white focus:shadow-input focus:border-transparent focus:outline-gui-focus;
57
+ }
57
58
 
58
- .ui-textarea::placeholder {
59
- /* CSS vars don't work in ::placeholder in Webkit :( */
60
- /* color: var(--text-dark-grey); */
61
- color: #76767c;
59
+ .ui-textarea::placeholder {
60
+ /* CSS vars don't work in ::placeholder in Webkit :( */
61
+ /* color: var(--text-dark-grey); */
62
+ color: #76767c;
63
+ }
62
64
  }
@@ -1,19 +1,21 @@
1
- .ui-standard-container {
2
- @apply w-full max-w-screen-xl mx-auto px-24 sm:px-32 md:px-40 lg:px-64;
3
- }
1
+ @layer components {
2
+ .ui-standard-container {
3
+ @apply w-full max-w-screen-xl mx-auto px-24 sm:px-32 md:px-40 lg:px-64;
4
+ }
4
5
 
5
- .ui-grid-gap {
6
- @apply gap-8 sm:gap-16 md:gap-24 xl:gap-32;
7
- }
6
+ .ui-grid-gap {
7
+ @apply gap-8 sm:gap-16 md:gap-24 xl:gap-32;
8
+ }
8
9
 
9
- .ui-grid-gap-x {
10
- @apply gap-x-8 sm:gap-x-16 md:gap-x-24 xl:gap-x-32;
11
- }
10
+ .ui-grid-gap-x {
11
+ @apply gap-x-8 sm:gap-x-16 md:gap-x-24 xl:gap-x-32;
12
+ }
12
13
 
13
- .ui-grid-px {
14
- @apply px-24 sm:px-32 md:px-40 lg:px-64;
15
- }
14
+ .ui-grid-px {
15
+ @apply px-24 sm:px-32 md:px-40 lg:px-64;
16
+ }
16
17
 
17
- .ui-grid-mx {
18
- @apply mx-24 sm:mx-32 md:mx-40 lg:mx-64;
18
+ .ui-grid-mx {
19
+ @apply mx-24 sm:mx-32 md:mx-40 lg:mx-64;
20
+ }
19
21
  }