@telefonica/mistica 12.11.1 → 12.13.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 (337) hide show
  1. package/css/mistica.css +1 -1
  2. package/dist/avatar.css-mistica.js +2 -2
  3. package/dist/avatar.d.ts +3 -2
  4. package/dist/avatar.js +72 -17
  5. package/dist/avatar.js.flow +2 -1
  6. package/dist/badge.css-mistica.js +4 -4
  7. package/dist/badge.d.ts +2 -0
  8. package/dist/badge.js +49 -8
  9. package/dist/badge.js.flow +2 -0
  10. package/dist/boxed.js +5 -5
  11. package/dist/button-group.css-mistica.js +1 -1
  12. package/dist/button-group.js +7 -7
  13. package/dist/button-layout.css-mistica.js +12 -12
  14. package/dist/button-layout.js +1 -1
  15. package/dist/button.css-mistica.js +26 -26
  16. package/dist/button.js +127 -77
  17. package/dist/callout.css-mistica.js +2 -2
  18. package/dist/callout.d.ts +2 -1
  19. package/dist/callout.js +68 -16
  20. package/dist/callout.js.flow +2 -1
  21. package/dist/card.css-mistica.js +5 -5
  22. package/dist/card.js +47 -41
  23. package/dist/carousel.css-mistica.js +23 -25
  24. package/dist/carousel.css.d.ts +1 -0
  25. package/dist/carousel.css.js.flow +4 -0
  26. package/dist/carousel.d.ts +7 -1
  27. package/dist/carousel.js +237 -209
  28. package/dist/carousel.js.flow +9 -1
  29. package/dist/checkbox.css-mistica.js +6 -6
  30. package/dist/checkbox.js +1 -1
  31. package/dist/chip.css-mistica.js +2 -2
  32. package/dist/chip.d.ts +7 -11
  33. package/dist/chip.js +65 -22
  34. package/dist/chip.js.flow +11 -6
  35. package/dist/circle.css-mistica.js +1 -1
  36. package/dist/credit-card-number-field.css-mistica.js +3 -3
  37. package/dist/cvv-field.css-mistica.js +1 -1
  38. package/dist/date-time-picker.js +2 -2
  39. package/dist/desktop-container-type-context.js +14 -4
  40. package/dist/dialog.css-mistica.js +6 -6
  41. package/dist/dialog.d.ts +2 -10
  42. package/dist/dialog.js +1 -0
  43. package/dist/dialog.js.flow +6 -4
  44. package/dist/double-field.css-mistica.js +5 -4
  45. package/dist/empty-state-card.css-mistica.js +1 -1
  46. package/dist/empty-state.css-mistica.js +2 -2
  47. package/dist/empty-state.js +5 -5
  48. package/dist/fade-in.d.ts +2 -0
  49. package/dist/fade-in.js +59 -6
  50. package/dist/fade-in.js.flow +2 -0
  51. package/dist/feedback.css-mistica.js +1 -1
  52. package/dist/feedback.js +130 -115
  53. package/dist/fixed-footer-layout.css-mistica.js +36 -0
  54. package/dist/fixed-footer-layout.css.d.ts +9 -0
  55. package/dist/fixed-footer-layout.css.js.flow +17 -0
  56. package/dist/fixed-footer-layout.css.ts.vanilla.js +11 -0
  57. package/dist/fixed-footer-layout.js +35 -84
  58. package/dist/header.js +99 -129
  59. package/dist/highlighted-card.css-mistica.js +5 -5
  60. package/dist/highlighted-card.d.ts +1 -1
  61. package/dist/highlighted-card.js +20 -15
  62. package/dist/highlighted-card.js.flow +1 -1
  63. package/dist/icon-button.css-mistica.js +13 -0
  64. package/dist/icon-button.css.d.ts +1 -0
  65. package/dist/icon-button.css.js.flow +3 -0
  66. package/dist/icon-button.css.ts.vanilla.js +11 -0
  67. package/dist/icon-button.d.ts +2 -1
  68. package/dist/icon-button.js +51 -28
  69. package/dist/icon-button.js.flow +2 -1
  70. package/dist/icons/icon-error.css-mistica.js +20 -0
  71. package/dist/icons/icon-error.css.d.ts +2 -0
  72. package/dist/icons/icon-error.css.js.flow +4 -0
  73. package/dist/icons/icon-error.css.ts.vanilla.js +11 -0
  74. package/dist/icons/icon-error.js +22 -33
  75. package/dist/icons/icon-info.js +16 -28
  76. package/dist/icons/icon-success-vivo.js +10 -20
  77. package/dist/icons/icon-success.js +28 -44
  78. package/dist/image.css-mistica.js +3 -3
  79. package/dist/index.d.ts +2 -0
  80. package/dist/index.js +8 -0
  81. package/dist/index.js.flow +2 -0
  82. package/dist/list.css-mistica.js +7 -7
  83. package/dist/list.js +112 -71
  84. package/dist/loading-bar.css-mistica.js +6 -6
  85. package/dist/loading-bar.d.ts +2 -0
  86. package/dist/loading-bar.js +60 -6
  87. package/dist/loading-bar.js.flow +5 -1
  88. package/dist/maybe-dismissable.css-mistica.js +24 -0
  89. package/dist/maybe-dismissable.css.d.ts +3 -0
  90. package/dist/maybe-dismissable.css.js.flow +5 -0
  91. package/dist/maybe-dismissable.css.ts.vanilla.js +11 -0
  92. package/dist/maybe-dismissable.js +16 -51
  93. package/dist/media-queries.css-mistica.js +37 -5
  94. package/dist/menu.css-mistica.js +34 -0
  95. package/dist/menu.css.d.ts +11 -0
  96. package/dist/menu.css.js.flow +19 -0
  97. package/dist/menu.css.ts.vanilla.js +11 -0
  98. package/dist/menu.d.ts +2 -0
  99. package/dist/menu.js +53 -99
  100. package/dist/menu.js.flow +2 -0
  101. package/dist/navigation-bar.css-mistica.js +79 -0
  102. package/dist/navigation-bar.css.d.ts +17 -0
  103. package/dist/navigation-bar.css.js.flow +26 -0
  104. package/dist/navigation-bar.css.ts.vanilla.js +11 -0
  105. package/dist/navigation-bar.js +206 -334
  106. package/dist/navigation-breadcrumbs.css-mistica.js +27 -0
  107. package/dist/navigation-breadcrumbs.css.d.ts +5 -0
  108. package/dist/navigation-breadcrumbs.css.js.flow +7 -0
  109. package/dist/navigation-breadcrumbs.css.ts.vanilla.js +11 -0
  110. package/dist/navigation-breadcrumbs.js +20 -38
  111. package/dist/overlay.d.ts +2 -0
  112. package/dist/overlay.js +37 -11
  113. package/dist/overlay.js.flow +2 -0
  114. package/dist/package-version.js +1 -1
  115. package/dist/password-field.css-mistica.js +13 -0
  116. package/dist/password-field.css.d.ts +1 -0
  117. package/dist/password-field.css.js.flow +3 -0
  118. package/dist/password-field.css.ts.vanilla.js +11 -0
  119. package/dist/password-field.js +39 -55
  120. package/dist/popover.css-mistica.js +51 -0
  121. package/dist/popover.css.d.ts +12 -0
  122. package/dist/popover.css.js.flow +14 -0
  123. package/dist/popover.css.ts.vanilla.js +11 -0
  124. package/dist/popover.d.ts +2 -1
  125. package/dist/popover.js +97 -118
  126. package/dist/popover.js.flow +2 -1
  127. package/dist/progress-bar.css-mistica.js +3 -3
  128. package/dist/progress-bar.d.ts +2 -0
  129. package/dist/progress-bar.js +60 -7
  130. package/dist/progress-bar.js.flow +2 -0
  131. package/dist/radio-button.css-mistica.js +39 -0
  132. package/dist/radio-button.css.d.ts +6 -0
  133. package/dist/radio-button.css.js.flow +8 -0
  134. package/dist/radio-button.css.ts.vanilla.js +11 -0
  135. package/dist/radio-button.d.ts +1 -0
  136. package/dist/radio-button.js +81 -125
  137. package/dist/radio-button.js.flow +1 -0
  138. package/dist/responsive-layout.css-mistica.js +7 -4
  139. package/dist/responsive-layout.css.d.ts +1 -0
  140. package/dist/responsive-layout.css.js.flow +1 -0
  141. package/dist/responsive-layout.d.ts +2 -0
  142. package/dist/responsive-layout.js +19 -11
  143. package/dist/responsive-layout.js.flow +2 -0
  144. package/dist/screen-reader-only.css-mistica.js +2 -2
  145. package/dist/select.css-mistica.js +60 -0
  146. package/dist/select.css.d.ts +16 -0
  147. package/dist/select.css.js.flow +30 -0
  148. package/dist/select.css.ts.vanilla.js +11 -0
  149. package/dist/select.js +150 -272
  150. package/dist/skeleton-base.js +13 -32
  151. package/dist/skeletons.css-mistica.js +1 -1
  152. package/dist/skeletons.js +63 -42
  153. package/dist/skins/skin-contract.css.js.flow +1 -0
  154. package/dist/snackbar.css-mistica.js +4 -4
  155. package/dist/snackbar.d.ts +2 -0
  156. package/dist/snackbar.js +70 -23
  157. package/dist/snackbar.js.flow +2 -0
  158. package/dist/spinner.css-mistica.js +2 -2
  159. package/dist/spinner.js +14 -11
  160. package/dist/sprinkles.css-mistica.js +217 -479
  161. package/dist/sprinkles.css.d.ts +0 -25
  162. package/dist/stepper.css-mistica.js +7 -7
  163. package/dist/stepper.d.ts +2 -0
  164. package/dist/stepper.js +52 -11
  165. package/dist/stepper.js.flow +2 -0
  166. package/dist/switch-component.css-mistica.js +54 -0
  167. package/dist/switch-component.css.d.ts +14 -0
  168. package/dist/switch-component.css.js.flow +43 -0
  169. package/dist/switch-component.css.ts.vanilla.js +11 -0
  170. package/dist/switch-component.js +35 -96
  171. package/dist/tabs.css-mistica.js +6 -6
  172. package/dist/tabs.js +16 -15
  173. package/dist/tag.css-mistica.js +2 -2
  174. package/dist/tag.js +5 -5
  175. package/dist/text-field-base.css-mistica.js +63 -0
  176. package/dist/text-field-base.css.d.ts +17 -0
  177. package/dist/text-field-base.css.js.flow +19 -0
  178. package/dist/text-field-base.css.ts.vanilla.js +11 -0
  179. package/dist/text-field-base.js +120 -314
  180. package/dist/text-field-components.css-mistica.js +69 -0
  181. package/dist/text-field-components.css.d.ts +18 -0
  182. package/dist/text-field-components.css.js.flow +20 -0
  183. package/dist/text-field-components.css.ts.vanilla.js +11 -0
  184. package/dist/text-field-components.d.ts +0 -4
  185. package/dist/text-field-components.js +46 -159
  186. package/dist/text-field-components.js.flow +0 -4
  187. package/dist/text-link.css-mistica.js +3 -3
  188. package/dist/text.js +159 -92
  189. package/dist/theme-context-provider.js +1 -1
  190. package/dist/title.js +44 -12
  191. package/dist/tooltip.css-mistica.js +7 -7
  192. package/dist/tooltip.d.ts +2 -0
  193. package/dist/tooltip.js +62 -36
  194. package/dist/tooltip.js.flow +2 -0
  195. package/dist/touchable.css-mistica.js +3 -3
  196. package/dist/touchable.js +10 -10
  197. package/dist/utils/animation.d.ts +0 -6
  198. package/dist/utils/animation.js +18 -55
  199. package/dist/utils/animation.js.flow +0 -8
  200. package/dist/utils/aspect-ratio-support.css-mistica.js +29 -0
  201. package/dist/utils/aspect-ratio-support.css.d.ts +6 -0
  202. package/dist/utils/aspect-ratio-support.css.js.flow +11 -0
  203. package/dist/utils/aspect-ratio-support.css.ts.vanilla.js +11 -0
  204. package/dist/utils/aspect-ratio-support.js +37 -56
  205. package/dist/utils/color.d.ts +1 -1
  206. package/dist/utils/color.js.flow +1 -1
  207. package/dist/utils/dom.d.ts +1 -1
  208. package/dist/utils/dom.js +7 -5
  209. package/dist/utils/dom.js.flow +2 -1
  210. package/dist/video.css-mistica.js +2 -2
  211. package/dist-es/avatar.css-mistica.js +2 -2
  212. package/dist-es/avatar.js +77 -22
  213. package/dist-es/badge.css-mistica.js +2 -2
  214. package/dist-es/badge.js +56 -15
  215. package/dist-es/boxed.js +5 -5
  216. package/dist-es/button-group.css-mistica.js +1 -1
  217. package/dist-es/button-group.js +10 -10
  218. package/dist-es/button-layout.css-mistica.js +7 -7
  219. package/dist-es/button-layout.js +4 -4
  220. package/dist-es/button.css-mistica.js +9 -9
  221. package/dist-es/button.js +152 -102
  222. package/dist-es/callout.css-mistica.js +2 -2
  223. package/dist-es/callout.js +79 -27
  224. package/dist-es/card.css-mistica.js +2 -2
  225. package/dist-es/card.js +78 -72
  226. package/dist-es/carousel.css-mistica.js +8 -7
  227. package/dist-es/carousel.js +286 -258
  228. package/dist-es/checkbox.css-mistica.js +5 -5
  229. package/dist-es/checkbox.js +1 -1
  230. package/dist-es/chip.css-mistica.js +2 -2
  231. package/dist-es/chip.js +79 -36
  232. package/dist-es/circle.css-mistica.js +1 -1
  233. package/dist-es/credit-card-number-field.css-mistica.js +3 -3
  234. package/dist-es/cvv-field.css-mistica.js +1 -1
  235. package/dist-es/date-time-picker.js +1 -1
  236. package/dist-es/desktop-container-type-context.js +4 -2
  237. package/dist-es/dialog.css-mistica.js +5 -5
  238. package/dist-es/dialog.js +1 -0
  239. package/dist-es/double-field.css-mistica.js +5 -4
  240. package/dist-es/empty-state-card.css-mistica.js +1 -1
  241. package/dist-es/empty-state.css-mistica.js +2 -2
  242. package/dist-es/empty-state.js +18 -18
  243. package/dist-es/fade-in.js +60 -7
  244. package/dist-es/feedback.css-mistica.js +1 -1
  245. package/dist-es/feedback.js +170 -155
  246. package/dist-es/fixed-footer-layout.css-mistica.js +7 -0
  247. package/dist-es/fixed-footer-layout.css.ts.vanilla.js +2 -0
  248. package/dist-es/fixed-footer-layout.js +47 -96
  249. package/dist-es/header.js +116 -146
  250. package/dist-es/highlighted-card.css-mistica.js +5 -5
  251. package/dist-es/highlighted-card.js +44 -39
  252. package/dist-es/icon-button.css-mistica.js +4 -0
  253. package/dist-es/icon-button.css.ts.vanilla.js +2 -0
  254. package/dist-es/icon-button.js +41 -26
  255. package/dist-es/icons/icon-error.css-mistica.js +3 -0
  256. package/dist-es/icons/icon-error.css.ts.vanilla.js +2 -0
  257. package/dist-es/icons/icon-error.js +46 -57
  258. package/dist-es/icons/icon-info.js +28 -40
  259. package/dist-es/icons/icon-success-vivo.js +18 -28
  260. package/dist-es/icons/icon-success.js +45 -56
  261. package/dist-es/image.css-mistica.js +2 -2
  262. package/dist-es/index.js +1738 -1736
  263. package/dist-es/list.css-mistica.js +2 -2
  264. package/dist-es/list.js +126 -85
  265. package/dist-es/loading-bar.css-mistica.js +2 -2
  266. package/dist-es/loading-bar.js +73 -19
  267. package/dist-es/maybe-dismissable.css-mistica.js +4 -0
  268. package/dist-es/maybe-dismissable.css.ts.vanilla.js +2 -0
  269. package/dist-es/maybe-dismissable.js +24 -59
  270. package/dist-es/media-queries.css-mistica.js +3 -3
  271. package/dist-es/menu.css-mistica.js +11 -0
  272. package/dist-es/menu.css.ts.vanilla.js +2 -0
  273. package/dist-es/menu.js +61 -107
  274. package/dist-es/navigation-bar.css-mistica.js +17 -0
  275. package/dist-es/navigation-bar.css.ts.vanilla.js +2 -0
  276. package/dist-es/navigation-bar.js +253 -381
  277. package/dist-es/navigation-breadcrumbs.css-mistica.js +4 -0
  278. package/dist-es/navigation-breadcrumbs.css.ts.vanilla.js +2 -0
  279. package/dist-es/navigation-breadcrumbs.js +34 -52
  280. package/dist-es/overlay.js +41 -15
  281. package/dist-es/package-version.js +1 -1
  282. package/dist-es/password-field.css-mistica.js +4 -0
  283. package/dist-es/password-field.css.ts.vanilla.js +2 -0
  284. package/dist-es/password-field.js +45 -61
  285. package/dist-es/popover.css-mistica.js +4 -0
  286. package/dist-es/popover.css.ts.vanilla.js +2 -0
  287. package/dist-es/popover.js +121 -141
  288. package/dist-es/progress-bar.css-mistica.js +2 -2
  289. package/dist-es/progress-bar.js +68 -15
  290. package/dist-es/radio-button.css-mistica.js +10 -0
  291. package/dist-es/radio-button.css.ts.vanilla.js +2 -0
  292. package/dist-es/radio-button.js +99 -143
  293. package/dist-es/responsive-layout.css-mistica.js +2 -2
  294. package/dist-es/responsive-layout.js +23 -15
  295. package/dist-es/screen-reader-only.css-mistica.js +2 -2
  296. package/dist-es/select.css-mistica.js +22 -0
  297. package/dist-es/select.css.ts.vanilla.js +2 -0
  298. package/dist-es/select.js +177 -299
  299. package/dist-es/skeleton-base.js +17 -36
  300. package/dist-es/skeletons.css-mistica.js +1 -1
  301. package/dist-es/skeletons.js +78 -57
  302. package/dist-es/snackbar.css-mistica.js +2 -2
  303. package/dist-es/snackbar.js +89 -42
  304. package/dist-es/spinner.css-mistica.js +2 -2
  305. package/dist-es/spinner.js +14 -11
  306. package/dist-es/sprinkles.css-mistica.js +217 -479
  307. package/dist-es/stepper.css-mistica.js +2 -2
  308. package/dist-es/stepper.js +68 -27
  309. package/dist-es/style.css +1 -1
  310. package/dist-es/switch-component.css-mistica.js +22 -0
  311. package/dist-es/switch-component.css.ts.vanilla.js +2 -0
  312. package/dist-es/switch-component.js +51 -112
  313. package/dist-es/tabs.css-mistica.js +6 -6
  314. package/dist-es/tabs.js +24 -23
  315. package/dist-es/tag.css-mistica.js +2 -2
  316. package/dist-es/tag.js +11 -11
  317. package/dist-es/text-field-base.css-mistica.js +4 -0
  318. package/dist-es/text-field-base.css.ts.vanilla.js +2 -0
  319. package/dist-es/text-field-base.js +134 -328
  320. package/dist-es/text-field-components.css-mistica.js +4 -0
  321. package/dist-es/text-field-components.css.ts.vanilla.js +2 -0
  322. package/dist-es/text-field-components.js +56 -157
  323. package/dist-es/text-link.css-mistica.js +3 -3
  324. package/dist-es/text.js +159 -92
  325. package/dist-es/theme-context-provider.js +1 -1
  326. package/dist-es/title.js +50 -18
  327. package/dist-es/tooltip.css-mistica.js +3 -3
  328. package/dist-es/tooltip.js +90 -64
  329. package/dist-es/touchable.css-mistica.js +2 -2
  330. package/dist-es/touchable.js +10 -10
  331. package/dist-es/utils/animation.js +28 -62
  332. package/dist-es/utils/aspect-ratio-support.css-mistica.js +6 -0
  333. package/dist-es/utils/aspect-ratio-support.css.ts.vanilla.js +2 -0
  334. package/dist-es/utils/aspect-ratio-support.js +34 -58
  335. package/dist-es/utils/dom.js +7 -5
  336. package/dist-es/video.css-mistica.js +2 -2
  337. package/package.json +2 -1
@@ -8,10 +8,18 @@ declare type PageBulletsProps = {
8
8
  onPress?: (index: number) => void,
9
9
  };
10
10
  declare export var PageBullets: React.ComponentType<PageBulletsProps>;
11
+ declare type DesktopItemsPerPage =
12
+ | {
13
+ small?: number,
14
+ medium?: number,
15
+ large?: number,
16
+ }
17
+ | number;
11
18
  declare type ItemsPerPageProp =
12
19
  | {
13
20
  mobile?: number,
14
- desktop?: number,
21
+ tablet?: number,
22
+ desktop?: DesktopItemsPerPage,
15
23
  }
16
24
  | number;
17
25
  declare type MobilePageOffset =
@@ -16,10 +16,10 @@ _export(exports, {
16
16
  return n;
17
17
  },
18
18
  checkChecked: function() {
19
- return r;
19
+ return y;
20
20
  },
21
21
  checkboxContainer: function() {
22
- return y;
22
+ return r;
23
23
  },
24
24
  disabled: function() {
25
25
  return b;
@@ -28,7 +28,7 @@ _export(exports, {
28
28
  require("./sprinkles.css.ts.vanilla.js");
29
29
  require("./checkbox.css.ts.vanilla.js");
30
30
  var f = {
31
- ios: "_1rz9b14 _1rz9b13 _1y2v1nf7c _1y2v1nf7k _1y2v1nf7q _1y2v1nf7t _1y2v1nfbb _1y2v1nf2f",
32
- rest: "_1rz9b15 _1rz9b13 _1y2v1nf7c _1y2v1nf7k _1y2v1nf7q _1y2v1nf7t _1y2v1nfbb _1y2v1nf2f",
33
- checked: "_1rz9b16 _1rz9b13 _1y2v1nf7c _1y2v1nf7k _1y2v1nf7q _1y2v1nf7t _1y2v1nfbb _1y2v1nf2f"
34
- }, n = "_1rz9b18 _1y2v1nf7d", r = "_1rz9b19", y = "_1rz9b11 _1y2v1nf7e", b = "_1rz9b1a";
31
+ ios: "_1rz9b14 _1rz9b13 _1y2v1nf4z _1y2v1nf57 _1y2v1nf5d _1y2v1nf5g _1y2v1nf8y _1y2v1nf2f",
32
+ rest: "_1rz9b15 _1rz9b13 _1y2v1nf4z _1y2v1nf57 _1y2v1nf5d _1y2v1nf5g _1y2v1nf8y _1y2v1nf2f",
33
+ checked: "_1rz9b16 _1rz9b13 _1y2v1nf4z _1y2v1nf57 _1y2v1nf5d _1y2v1nf5g _1y2v1nf8y _1y2v1nf2f"
34
+ }, n = "_1rz9b18 _1y2v1nf50", y = "_1rz9b19", r = "_1rz9b11 _1y2v1nf51", b = "_1rz9b1a";
package/dist/checkbox.js CHANGED
@@ -212,7 +212,7 @@ var V = function V(param) {
212
212
  "aria-label": t,
213
213
  "aria-labelledby": t ? void 0 : l,
214
214
  "aria-disabled": d
215
- }, (0, _domJs.getPrefixedDataAttributes)(e.dataAttributes)), {
215
+ }, (0, _domJs.getPrefixedDataAttributes)(e.dataAttributes, "Checkbox")), {
216
216
  children: e.render ? e.render({
217
217
  controlElement: m,
218
218
  labelId: l,
@@ -28,6 +28,6 @@ var t = {
28
28
  light: "cc7htn8 cc7htn7",
29
29
  dark: "cc7htn9 cc7htn7"
30
30
  }, v = {
31
- default: "cc7htn1 _1y2v1nf7c _1y2v1nf7k _1y2v1nf7q _1y2v1nfb8 _1y2v1nf4u _1y2v1nf1i",
32
- active: "cc7htn6 cc7htn2 cc7htn1 _1y2v1nf7c _1y2v1nf7k _1y2v1nf7q _1y2v1nfb8 _1y2v1nfu _1y2v1nf6z"
31
+ default: "cc7htn1 _1y2v1nf4z _1y2v1nf57 _1y2v1nf5d _1y2v1nf8v _1y2v1nf2g _1y2v1nf1i",
32
+ active: "cc7htn6 cc7htn2 cc7htn1 _1y2v1nf4z _1y2v1nf57 _1y2v1nf5d _1y2v1nf8v _1y2v1nfu _1y2v1nf4l"
33
33
  }, a = "cc7htna", f = "cc7htnb";
package/dist/chip.d.ts CHANGED
@@ -1,22 +1,18 @@
1
1
  import * as React from 'react';
2
- import type { IconProps } from './utils/types';
3
- interface ChipBaseProps {
2
+ import type { ExclusifyUnion } from './utils/utility-types';
3
+ import type { DataAttributes, IconProps } from './utils/types';
4
+ interface SimpleChipProps {
4
5
  children: string;
5
6
  Icon?: React.FC<IconProps>;
6
7
  id?: string;
8
+ dataAttributes?: DataAttributes;
7
9
  }
8
- interface SimpleChipProps extends ChipBaseProps {
9
- onClose?: undefined;
10
- active?: undefined;
11
- }
12
- interface ClosableChipProps extends ChipBaseProps {
10
+ interface ClosableChipProps extends SimpleChipProps {
13
11
  onClose: () => void;
14
- active?: undefined;
15
12
  }
16
- interface ToggleChipProps extends ChipBaseProps {
13
+ interface ToggleChipProps extends SimpleChipProps {
17
14
  active: boolean;
18
- onClose?: undefined;
19
15
  }
20
- declare type ChipProps = SimpleChipProps | ClosableChipProps | ToggleChipProps;
16
+ declare type ChipProps = ExclusifyUnion<SimpleChipProps | ClosableChipProps | ToggleChipProps>;
21
17
  declare const Chip: React.FC<ChipProps>;
22
18
  export default Chip;
package/dist/chip.js CHANGED
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  Object.defineProperty(exports, "default", {
6
6
  enumerable: true,
7
7
  get: function() {
8
- return A;
8
+ return q;
9
9
  }
10
10
  });
11
11
  var _classnames = /*#__PURE__*/ _interopRequireDefault(require("classnames"));
@@ -16,6 +16,7 @@ var _iconButtonJs = /*#__PURE__*/ _interopRequireDefault(require("./icon-button.
16
16
  var _iconCloseRegularJs = /*#__PURE__*/ _interopRequireDefault(require("./generated/mistica-icons/icon-close-regular.js"));
17
17
  var _cssJs = require("./utils/css.js");
18
18
  var _chipCssMisticaJs = require("./chip.css-mistica.js");
19
+ var _domJs = require("./utils/dom.js");
19
20
  var _jsxRuntimeJs = require("./_virtual/jsx-runtime.js");
20
21
  function _interopRequireDefault(obj) {
21
22
  return obj && obj.__esModule ? obj : {
@@ -35,31 +36,72 @@ function _defineProperty(obj, key, value) {
35
36
  }
36
37
  return obj;
37
38
  }
38
- var A = function A(t) {
39
- var ref = (0, _hooksJs.useTheme)(), l = ref.texts, s = ref.isDarkMode, m = ref.colors, i = t.Icon, d = t.children, f = t.id, r = /* @__PURE__ */ (0, _jsxRuntimeJs.jsxs)(_jsxRuntimeJs.Fragment, {
39
+ function _objectSpread(target) {
40
+ for(var i = 1; i < arguments.length; i++){
41
+ var source = arguments[i] != null ? arguments[i] : {};
42
+ var ownKeys = Object.keys(source);
43
+ if (typeof Object.getOwnPropertySymbols === "function") {
44
+ ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
45
+ return Object.getOwnPropertyDescriptor(source, sym).enumerable;
46
+ }));
47
+ }
48
+ ownKeys.forEach(function(key) {
49
+ _defineProperty(target, key, source[key]);
50
+ });
51
+ }
52
+ return target;
53
+ }
54
+ function ownKeys(object, enumerableOnly) {
55
+ var keys = Object.keys(object);
56
+ if (Object.getOwnPropertySymbols) {
57
+ var symbols = Object.getOwnPropertySymbols(object);
58
+ if (enumerableOnly) {
59
+ symbols = symbols.filter(function(sym) {
60
+ return Object.getOwnPropertyDescriptor(object, sym).enumerable;
61
+ });
62
+ }
63
+ keys.push.apply(keys, symbols);
64
+ }
65
+ return keys;
66
+ }
67
+ function _objectSpreadProps(target, source) {
68
+ source = source != null ? source : {};
69
+ if (Object.getOwnPropertyDescriptors) {
70
+ Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
71
+ } else {
72
+ ownKeys(Object(source)).forEach(function(key) {
73
+ Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
74
+ });
75
+ }
76
+ return target;
77
+ }
78
+ var q = function q(param) {
79
+ var t = param.Icon, d = param.children, p = param.id, i = param.dataAttributes, o = param.active, n = param.onClose;
80
+ var ref = (0, _hooksJs.useTheme)(), f = ref.texts, u = ref.isDarkMode, h = ref.colors, s = /* @__PURE__ */ (0, _jsxRuntimeJs.jsxs)(_jsxRuntimeJs.Fragment, {
40
81
  children: [
41
- i && /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_boxJs.default, {
82
+ t && /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_boxJs.default, {
42
83
  paddingRight: 4,
43
- className: t.active ? _chipCssMisticaJs.iconActive : _chipCssMisticaJs.icon,
44
- children: /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(i, {
84
+ className: o ? _chipCssMisticaJs.iconActive : _chipCssMisticaJs.icon,
85
+ children: /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(t, {
45
86
  color: "currentColor",
46
87
  size: (0, _cssJs.pxToRem)(16)
47
88
  })
48
89
  }),
49
90
  /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_textJs.Text2, {
50
- id: f,
91
+ id: p,
51
92
  medium: !0,
52
93
  truncate: 1,
53
94
  color: "currentColor",
54
95
  children: d
55
96
  })
56
97
  ]
57
- }), n = i ? 8 : 12;
58
- if (t.onClose) return /* @__PURE__ */ (0, _jsxRuntimeJs.jsxs)(_boxJs.default, {
98
+ }), a = t ? 8 : 12;
99
+ if (n) return /* @__PURE__ */ (0, _jsxRuntimeJs.jsxs)(_boxJs.default, _objectSpreadProps(_objectSpread({
59
100
  className: _chipCssMisticaJs.chipVariants.default,
60
- paddingLeft: n,
101
+ paddingLeft: a
102
+ }, (0, _domJs.getPrefixedDataAttributes)(i, "Chip")), {
61
103
  children: [
62
- r,
104
+ s,
63
105
  /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_boxJs.default, {
64
106
  paddingLeft: 4,
65
107
  children: /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_iconButtonJs.default, {
@@ -69,25 +111,26 @@ var A = function A(t) {
69
111
  justifyContent: "center",
70
112
  alignItems: "center"
71
113
  },
72
- "aria-label": l.closeButtonLabel,
114
+ "aria-label": f.closeButtonLabel,
73
115
  onPress: function onPress() {
74
- return t.onClose();
116
+ return n();
75
117
  },
76
118
  children: /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_iconCloseRegularJs.default, {
77
119
  size: 16,
78
- color: m.neutralMedium
120
+ color: h.neutralMedium
79
121
  })
80
122
  })
81
123
  })
82
124
  ]
83
- });
125
+ }));
84
126
  {
85
- var u = t.active !== void 0;
86
- return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_boxJs.default, {
87
- className: (0, _classnames.default)(_chipCssMisticaJs.chipVariants[t.active ? "active" : "default"], _defineProperty({}, _chipCssMisticaJs.chipInteractiveVariants[s ? "dark" : "light"], u)),
88
- paddingLeft: n,
89
- paddingRight: 12,
90
- children: r
91
- });
127
+ var g = o !== void 0;
128
+ return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_boxJs.default, _objectSpreadProps(_objectSpread({
129
+ className: (0, _classnames.default)(_chipCssMisticaJs.chipVariants[o ? "active" : "default"], _defineProperty({}, _chipCssMisticaJs.chipInteractiveVariants[u ? "dark" : "light"], g)),
130
+ paddingLeft: a,
131
+ paddingRight: 12
132
+ }, (0, _domJs.getPrefixedDataAttributes)(i, "Chip")), {
133
+ children: s
134
+ }));
92
135
  }
93
136
  };
package/dist/chip.js.flow CHANGED
@@ -1,21 +1,26 @@
1
1
  // @flow
2
2
 
3
3
  import * as React from "react";
4
- import type { IconProps } from "./utils/types";
5
- declare type ChipBaseProps = {
4
+ import type { ExclusifyUnion } from "./utils/utility-types";
5
+ import type { DataAttributes, IconProps } from "./utils/types";
6
+ declare type SimpleChipProps = {
6
7
  children: string,
7
8
  Icon?: React.ComponentType<IconProps>,
8
9
  id?: string,
10
+ dataAttributes?: DataAttributes,
9
11
  };
10
- declare type SimpleChipProps = { ...$Exact<ChipBaseProps> };
11
12
  declare type ClosableChipProps = {
12
- ...$Exact<ChipBaseProps>,
13
+ ...$Exact<SimpleChipProps>,
14
+
13
15
  onClose: () => void,
14
16
  };
15
17
  declare type ToggleChipProps = {
16
- ...$Exact<ChipBaseProps>,
18
+ ...$Exact<SimpleChipProps>,
19
+
17
20
  active: boolean,
18
21
  };
19
- declare type ChipProps = SimpleChipProps | ClosableChipProps | ToggleChipProps;
22
+ declare type ChipProps = ExclusifyUnion<
23
+ SimpleChipProps | ClosableChipProps | ToggleChipProps
24
+ >;
20
25
  declare var Chip: React.ComponentType<ChipProps>;
21
26
  declare export default typeof Chip;
@@ -10,4 +10,4 @@ Object.defineProperty(exports, "circle", {
10
10
  });
11
11
  require("./sprinkles.css.ts.vanilla.js");
12
12
  require("./circle.css.ts.vanilla.js");
13
- var r = "_1wpwyyp1 _1y2v1nf7b _1y2v1nf7q _1y2v1nf7k _1y2v1nfba";
13
+ var r = "_1wpwyyp1 _1y2v1nf4y _1y2v1nf5d _1y2v1nf57 _1y2v1nf8x";
@@ -24,7 +24,7 @@ _export(exports, {
24
24
  });
25
25
  require("./sprinkles.css.ts.vanilla.js");
26
26
  require("./credit-card-number-field.css.ts.vanilla.js");
27
- var a = "yvyo3q0", o = "yvyo3q2", r = "_1y2v1nf77", f = {
28
- default: "yvyo3q4 _1y2v1nf76 yvyo3q5",
29
- backface: "yvyo3q4 _1y2v1nf76 yvyo3q6"
27
+ var a = "yvyo3q0", o = "yvyo3q2", r = "_1y2v1nf4u", f = {
28
+ default: "yvyo3q4 _1y2v1nf4t yvyo3q5",
29
+ backface: "yvyo3q4 _1y2v1nf4t yvyo3q6"
30
30
  };
@@ -18,4 +18,4 @@ _export(exports, {
18
18
  });
19
19
  require("./sprinkles.css.ts.vanilla.js");
20
20
  require("./cvv-field.css.ts.vanilla.js");
21
- var v = "_10ijton2 _1y2v1nf1i", i = "_1y2v1nf7b _1y2v1nf7q";
21
+ var v = "_10ijton2 _1y2v1nf1i", i = "_1y2v1nf4y _1y2v1nf5d";
@@ -13,7 +13,7 @@ var _textFieldBaseJs = require("./text-field-base.js");
13
13
  var _iconCalendarRegularJs = /*#__PURE__*/ _interopRequireDefault(require("./generated/mistica-icons/icon-calendar-regular.js"));
14
14
  var _reactDatetime = /*#__PURE__*/ _interopRequireDefault(require("react-datetime"));
15
15
  var _overlayJs = /*#__PURE__*/ _interopRequireDefault(require("./overlay.js"));
16
- var _textFieldComponentsJs = require("./text-field-components.js");
16
+ var _textFieldComponentsCssMisticaJs = require("./text-field-components.css-mistica.js");
17
17
  var _iconButtonJs = /*#__PURE__*/ _interopRequireDefault(require("./icon-button.js"));
18
18
  var _domJs = require("./utils/dom.js");
19
19
  var _hooksJs = require("./hooks.js");
@@ -206,7 +206,7 @@ var Q = function Q(_param) {
206
206
  var p;
207
207
  var ref = ((p = n.current) == null ? void 0 : p.getBoundingClientRect()) || {}, tmp = ref.top, e = tmp === void 0 ? 0 : tmp, tmp1 = ref.bottom, o = tmp1 === void 0 ? 0 : tmp1, tmp2 = ref.left, i = tmp2 === void 0 ? 0 : tmp2, P = 260 + o < window.innerHeight;
208
208
  return {
209
- width: _textFieldComponentsJs.DEFAULT_WIDTH,
209
+ width: _textFieldComponentsCssMisticaJs.DEFAULT_WIDTH,
210
210
  top: P ? o : e - k,
211
211
  left: i,
212
212
  position: "absolute",
@@ -2,10 +2,18 @@
2
2
  Object.defineProperty(exports, "__esModule", {
3
3
  value: true
4
4
  });
5
- Object.defineProperty(exports, "default", {
6
- enumerable: true,
7
- get: function() {
5
+ function _export(target, all) {
6
+ for(var name in all)Object.defineProperty(target, name, {
7
+ enumerable: true,
8
+ get: all[name]
9
+ });
10
+ }
11
+ _export(exports, {
12
+ default: function() {
8
13
  return e;
14
+ },
15
+ useDesktopContainerType: function() {
16
+ return o;
9
17
  }
10
18
  });
11
19
  var _react = /*#__PURE__*/ _interopRequireWildcard(require("react"));
@@ -48,4 +56,6 @@ function _interopRequireWildcard(obj, nodeInterop) {
48
56
  }
49
57
  return newObj;
50
58
  }
51
- var e = /*#__PURE__*/ _react.createContext(null);
59
+ var e = /*#__PURE__*/ _react.createContext(null), o = function o() {
60
+ return _react.useContext(e);
61
+ };
@@ -28,10 +28,10 @@ _export(exports, {
28
28
  return d;
29
29
  },
30
30
  modalContent: function() {
31
- return o;
31
+ return r;
32
32
  },
33
33
  modalOpacityLayer: function() {
34
- return r;
34
+ return o;
35
35
  },
36
36
  variants: function() {
37
37
  return t;
@@ -42,7 +42,7 @@ _export(exports, {
42
42
  });
43
43
  require("./sprinkles.css.ts.vanilla.js");
44
44
  require("./dialog.css.ts.vanilla.js");
45
- var _ = "_3dl29lb", y = "_3dl29l6", f = "_3dl29ll _1y2v1nf84", l = "_3dl29lj _1y2v1nf7x _1y2v1nfas", a = "_3dl29lm", d = "_3dl29l8 _1y2v1nf83 _1y2v1nf8h _1y2v1nf8v _1y2v1nf99 _1y2v1nf77 _1y2v1nfbj _1y2v1nfcb", o = "_3dl29la _1y2v1nf2f _1y2v1nfbd", r = "_3dl29l5 _1y2v1nf78 _1y2v1nf7b _1y2v1nf7k _1y2v1nf7q _1y2v1nf7h _1y2v1nfbj _1y2v1nfcb _1y2v1nfcp _1y2v1nfbx _1y2v1nf2i", t = {
46
- dialog: "_3dl29ld _1y2v1nf7b _1y2v1nf7h _1y2v1nf7n _1y2v1nf8w _1y2v1nf9a _1y2v1nf86 _1y2v1nf8i",
47
- default: "_3dl29ld _1y2v1nf7b _1y2v1nf7h _1y2v1nf7n _1y2v1nf84 _1y2v1nf8i _1y2v1nf8w _1y2v1nf9a"
48
- }, i = "_3dl29l3 _1y2v1nf76";
45
+ var _ = "_3dl29lb", y = "_3dl29l6", f = "_3dl29ll _1y2v1nf5r", l = "_3dl29lj _1y2v1nf5k _1y2v1nf8f", a = "_3dl29lm", d = "_3dl29l8 _1y2v1nf5q _1y2v1nf64 _1y2v1nf6i _1y2v1nf6w _1y2v1nf4u _1y2v1nf96 _1y2v1nf9y", r = "_3dl29la _1y2v1nf2f _1y2v1nf90", o = "_3dl29l5 _1y2v1nf4v _1y2v1nf4y _1y2v1nf57 _1y2v1nf5d _1y2v1nf54 _1y2v1nf96 _1y2v1nf9y _1y2v1nfac _1y2v1nf9k _1y2v1nf2i", t = {
46
+ dialog: "_3dl29ld _1y2v1nf4y _1y2v1nf54 _1y2v1nf5a _1y2v1nf6j _1y2v1nf6x _1y2v1nf5t _1y2v1nf65",
47
+ default: "_3dl29ld _1y2v1nf4y _1y2v1nf54 _1y2v1nf5a _1y2v1nf5r _1y2v1nf65 _1y2v1nf6j _1y2v1nf6x"
48
+ }, i = "_3dl29l3 _1y2v1nf4t";
package/dist/dialog.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import { ButtonLink } from './button';
3
3
  import type { RendersNullableElement } from './utils/types';
4
+ import type { ExclusifyUnion } from './utils/utility-types';
4
5
  interface BaseDialogProps {
5
6
  className?: string;
6
7
  title?: string;
@@ -11,18 +12,9 @@ interface BaseDialogProps {
11
12
  destructive?: boolean;
12
13
  }
13
14
  interface AlertProps extends BaseDialogProps {
14
- subtitle?: undefined;
15
- extra?: undefined;
16
- forceWeb?: undefined;
17
15
  showClose?: boolean;
18
- showCancel?: never;
19
- cancelText?: never;
20
- onCancel?: never;
21
16
  }
22
17
  interface ConfirmProps extends BaseDialogProps {
23
- subtitle?: undefined;
24
- extra?: undefined;
25
- forceWeb?: undefined;
26
18
  showClose?: boolean;
27
19
  showCancel?: boolean;
28
20
  cancelText?: string;
@@ -38,7 +30,7 @@ interface ExtendedDialogProps extends BaseDialogProps {
38
30
  onCancel?: () => void;
39
31
  link?: RendersNullableElement<typeof ButtonLink>;
40
32
  }
41
- declare type DialogProps = AlertProps | ConfirmProps | ExtendedDialogProps;
33
+ declare type DialogProps = ExclusifyUnion<AlertProps | ConfirmProps | ExtendedDialogProps>;
42
34
  declare type DialogRootProps = {
43
35
  children?: React.ReactNode;
44
36
  };
package/dist/dialog.js CHANGED
@@ -439,6 +439,7 @@ var A = function A(e) {
439
439
  onClick: B,
440
440
  className: (0, _classnames.default)(_dialogCssMisticaJs.modalOpacityLayer, _defineProperty({}, _dialogCssMisticaJs.closedOpactityLayer, a)),
441
441
  role: "dialog",
442
+ "data-component-name": "Dialog",
442
443
  children: /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)("div", {
443
444
  onClick: function onClick(h) {
444
445
  return h.stopPropagation();
@@ -3,6 +3,7 @@
3
3
  import * as React from "react";
4
4
  import { ButtonLink } from "./button";
5
5
  import type { RendersNullableElement } from "./utils/types";
6
+ import type { ExclusifyUnion } from "./utils/utility-types";
6
7
  declare type BaseDialogProps = {
7
8
  className?: string,
8
9
  title?: string,
@@ -14,13 +15,12 @@ declare type BaseDialogProps = {
14
15
  };
15
16
  declare type AlertProps = {
16
17
  ...$Exact<BaseDialogProps>,
18
+
17
19
  showClose?: boolean,
18
- showCancel?: empty,
19
- cancelText?: empty,
20
- onCancel?: empty,
21
20
  };
22
21
  declare type ConfirmProps = {
23
22
  ...$Exact<BaseDialogProps>,
23
+
24
24
  showClose?: boolean,
25
25
  showCancel?: boolean,
26
26
  cancelText?: string,
@@ -38,7 +38,9 @@ declare type ExtendedDialogProps = {
38
38
  onCancel?: () => void,
39
39
  link?: RendersNullableElement<typeof ButtonLink>,
40
40
  };
41
- declare type DialogProps = AlertProps | ConfirmProps | ExtendedDialogProps;
41
+ declare type DialogProps = ExclusifyUnion<
42
+ AlertProps | ConfirmProps | ExtendedDialogProps
43
+ >;
42
44
  declare type DialogRootProps = {
43
45
  children?: React.Node,
44
46
  };
@@ -5,12 +5,13 @@ Object.defineProperty(exports, "__esModule", {
5
5
  Object.defineProperty(exports, "variants", {
6
6
  enumerable: true,
7
7
  get: function() {
8
- return n;
8
+ return y;
9
9
  }
10
10
  });
11
11
  require("./sprinkles.css.ts.vanilla.js");
12
+ require("./text-field-components.css.ts.vanilla.js");
12
13
  require("./double-field.css.ts.vanilla.js");
13
- var n = {
14
- default: "skrulh1 _1y2v1nf7b _1y2v1nf7g _1y2v1nf9i",
15
- fullWidth: "skrulh2 _1y2v1nf7b _1y2v1nf7g _1y2v1nf9i"
14
+ var y = {
15
+ default: "skrulh1 _1y2v1nf4y _1y2v1nf53 _1y2v1nf75",
16
+ fullWidth: "skrulh2 _1y2v1nf4y _1y2v1nf53 _1y2v1nf75"
16
17
  };
@@ -21,4 +21,4 @@ _export(exports, {
21
21
  });
22
22
  require("./sprinkles.css.ts.vanilla.js");
23
23
  require("./empty-state-card.css.ts.vanilla.js");
24
- var n = "_1azor6p0", o = "_1azor6p4 _1y2v1nf9t _1y2v1nfa8", v = "_1azor6p2 _1y2v1nf7d _1y2v1nfaa";
24
+ var n = "_1azor6p0", o = "_1azor6p4 _1y2v1nf7g _1y2v1nf7v", v = "_1azor6p2 _1y2v1nf50 _1y2v1nf7x";
@@ -36,9 +36,9 @@ _export(exports, {
36
36
  });
37
37
  require("./sprinkles.css.ts.vanilla.js");
38
38
  require("./empty-state.css.ts.vanilla.js");
39
- var n = "_13fzrua2 _1y2v1nf7b _1y2v1nf74", v = {
39
+ var n = "_13fzrua2 _1y2v1nf4y _1y2v1nf4s", v = {
40
40
  default: "_13fzrua3",
41
41
  largeImage: "_13fzrua4"
42
- }, e = "_13fzrua9 _1y2v1nf9v _1y2v1nfaa", f = "_13fzruac", _ = "_13fzrua7 _1y2v1nf9y", o = "_13fzrua5", u = "_13fzruab _1y2v1nf7d", t = {
42
+ }, e = "_13fzrua9 _1y2v1nf7i _1y2v1nf7x", f = "_13fzruac", _ = "_13fzrua7 _1y2v1nf7l", o = "_13fzrua5", u = "_13fzruab _1y2v1nf50", t = {
43
43
  backgroundColor: "var(--_13fzrua0)"
44
44
  };
@@ -80,11 +80,11 @@ function _objectSpreadProps(target, source) {
80
80
  return target;
81
81
  }
82
82
  var Z = function Z(param) {
83
- var p = param.title, f = param.description, e = param.button, v = param.buttonLink, a = param.largeImageUrl, t = param.imageUrl, n = param.icon, g = param["aria-label"], h = param.dataAttributes;
84
- var ref = (0, _hooksJs.useTheme)(), l = ref.colors, u = ref.isDarkMode, o = (0, _themeVariantContextJs.useIsInverseVariant)(), s = t ? /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)("img", {
83
+ var p = param.title, f = param.description, e = param.button, v = param.buttonLink, a = param.largeImageUrl, i = param.imageUrl, n = param.icon, g = param["aria-label"], h = param.dataAttributes;
84
+ var ref = (0, _hooksJs.useTheme)(), m = ref.colors, u = ref.isDarkMode, o = (0, _themeVariantContextJs.useIsInverseVariant)(), s = i ? /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)("img", {
85
85
  className: _emptyStateCssMisticaJs.smallImage,
86
86
  alt: "",
87
- src: t
87
+ src: i
88
88
  }) : void 0, y = _objectSpreadProps(_objectSpread({}, (e == null ? void 0 : e.type) === _buttonJs.ButtonPrimary ? {
89
89
  primaryButton: e
90
90
  } : {
@@ -99,7 +99,7 @@ var Z = function Z(param) {
99
99
  style: (0, _dynamic.assignInlineVars)(_defineProperty({}, _emptyStateCssMisticaJs.vars.backgroundColor, o && !u ? _skinContractCssMisticaJs.vars.colors.backgroundBrand : _skinContractCssMisticaJs.vars.colors.backgroundContainer)),
100
100
  "aria-label": g,
101
101
  role: "region"
102
- }, (0, _domJs.getPrefixedDataAttributes)(h)), {
102
+ }, (0, _domJs.getPrefixedDataAttributes)(h, "EmptyState")), {
103
103
  children: [
104
104
  /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)("div", {
105
105
  style: {
@@ -123,7 +123,7 @@ var Z = function Z(param) {
123
123
  /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)(_textJs.Text3, {
124
124
  regular: !0,
125
125
  as: "p",
126
- color: o ? l.inverse : l.textSecondary,
126
+ color: o ? m.inverse : m.textSecondary,
127
127
  children: f
128
128
  })
129
129
  ]
package/dist/fade-in.d.ts CHANGED
@@ -1,9 +1,11 @@
1
1
  import * as React from 'react';
2
+ import type { DataAttributes } from './utils/types';
2
3
  declare type Props = {
3
4
  children?: React.ReactNode;
4
5
  className?: string;
5
6
  delay?: string;
6
7
  duration?: string;
8
+ dataAttributes?: DataAttributes;
7
9
  };
8
10
  declare const FadeIn: React.FC<Props>;
9
11
  export default FadeIn;
package/dist/fade-in.js CHANGED
@@ -5,15 +5,68 @@ Object.defineProperty(exports, "__esModule", {
5
5
  Object.defineProperty(exports, "default", {
6
6
  enumerable: true,
7
7
  get: function() {
8
- return l;
8
+ return D;
9
9
  }
10
10
  });
11
11
  var _fadeInCssMisticaJs = require("./fade-in.css-mistica.js");
12
+ var _domJs = require("./utils/dom.js");
12
13
  var _jsxRuntimeJs = require("./_virtual/jsx-runtime.js");
13
- var r = "0.3s", l = function l(param) {
14
- var i = param.children, tmp = param.className, n = tmp === void 0 ? "" : tmp, tmp1 = param.duration, t = tmp1 === void 0 ? r : tmp1, tmp2 = param.delay, a = tmp2 === void 0 ? "0" : tmp2;
15
- return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)("div", {
16
- className: "".concat(_fadeInCssMisticaJs.wrapper, " ").concat(n),
14
+ function _defineProperty(obj, key, value) {
15
+ if (key in obj) {
16
+ Object.defineProperty(obj, key, {
17
+ value: value,
18
+ enumerable: true,
19
+ configurable: true,
20
+ writable: true
21
+ });
22
+ } else {
23
+ obj[key] = value;
24
+ }
25
+ return obj;
26
+ }
27
+ function _objectSpread(target) {
28
+ for(var i = 1; i < arguments.length; i++){
29
+ var source = arguments[i] != null ? arguments[i] : {};
30
+ var ownKeys = Object.keys(source);
31
+ if (typeof Object.getOwnPropertySymbols === "function") {
32
+ ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
33
+ return Object.getOwnPropertyDescriptor(source, sym).enumerable;
34
+ }));
35
+ }
36
+ ownKeys.forEach(function(key) {
37
+ _defineProperty(target, key, source[key]);
38
+ });
39
+ }
40
+ return target;
41
+ }
42
+ function ownKeys(object, enumerableOnly) {
43
+ var keys = Object.keys(object);
44
+ if (Object.getOwnPropertySymbols) {
45
+ var symbols = Object.getOwnPropertySymbols(object);
46
+ if (enumerableOnly) {
47
+ symbols = symbols.filter(function(sym) {
48
+ return Object.getOwnPropertyDescriptor(object, sym).enumerable;
49
+ });
50
+ }
51
+ keys.push.apply(keys, symbols);
52
+ }
53
+ return keys;
54
+ }
55
+ function _objectSpreadProps(target, source) {
56
+ source = source != null ? source : {};
57
+ if (Object.getOwnPropertyDescriptors) {
58
+ Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
59
+ } else {
60
+ ownKeys(Object(source)).forEach(function(key) {
61
+ Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
62
+ });
63
+ }
64
+ return target;
65
+ }
66
+ var s = "0.3s", D = function D(param) {
67
+ var i = param.children, tmp = param.className, e = tmp === void 0 ? "" : tmp, tmp1 = param.duration, t = tmp1 === void 0 ? s : tmp1, tmp2 = param.delay, a = tmp2 === void 0 ? "0" : tmp2, n = param.dataAttributes;
68
+ return /* @__PURE__ */ (0, _jsxRuntimeJs.jsx)("div", _objectSpreadProps(_objectSpread({}, (0, _domJs.getPrefixedDataAttributes)(n, "FadeIn")), {
69
+ className: "".concat(_fadeInCssMisticaJs.wrapper, " ").concat(e),
17
70
  style: {
18
71
  animationDelay: a,
19
72
  WebkitAnimationDelay: a,
@@ -21,5 +74,5 @@ var r = "0.3s", l = function l(param) {
21
74
  WebkitAnimationDuration: t
22
75
  },
23
76
  children: i
24
- });
77
+ }));
25
78
  };
@@ -1,11 +1,13 @@
1
1
  // @flow
2
2
 
3
3
  import * as React from "react";
4
+ import type { DataAttributes } from "./utils/types";
4
5
  declare type Props = {
5
6
  children?: React.Node,
6
7
  className?: string,
7
8
  delay?: string,
8
9
  duration?: string,
10
+ dataAttributes?: DataAttributes,
9
11
  };
10
12
  declare var FadeIn: React.ComponentType<Props>;
11
13
  declare export default typeof FadeIn;
@@ -33,4 +33,4 @@ _export(exports, {
33
33
  });
34
34
  require("./sprinkles.css.ts.vanilla.js");
35
35
  require("./feedback.css.ts.vanilla.js");
36
- var n = "gx6h6a3 _1y2v1nf7b _1y2v1nf9y _1y2v1nf9i", r = "_1y2v1nfbe _1y2v1nf7b _1y2v1nf7n", t = "gx6h6a1", v = "gx6h6a7", f = "gx6h6a5", o = "gx6h6a6", p = "gx6h6a4";
36
+ var n = "gx6h6a3 _1y2v1nf4y _1y2v1nf7l _1y2v1nf75", r = "_1y2v1nf91 _1y2v1nf4y _1y2v1nf5a", t = "gx6h6a1", v = "gx6h6a7", f = "gx6h6a5", o = "gx6h6a6", p = "gx6h6a4";