@easypost/easy-ui 1.0.0-alpha.4 → 1.0.0-alpha.6

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 (133) hide show
  1. package/Badge/index.js +32 -26
  2. package/Badge/index.mjs +32 -26
  3. package/Banner/index.js +15 -16
  4. package/Banner/index.mjs +15 -16
  5. package/Button/Button.d.ts +61 -0
  6. package/Button/Button.d.ts.map +1 -1
  7. package/Button/index.js +34 -69
  8. package/Button/index.mjs +33 -68
  9. package/CHANGELOG.md +21 -0
  10. package/Card/index.js +84 -5
  11. package/Card/index.mjs +84 -5
  12. package/Checkbox/index.js +84 -72
  13. package/Checkbox/index.mjs +84 -72
  14. package/CodeBlock/index.js +43 -49
  15. package/CodeBlock/index.mjs +43 -49
  16. package/DropdownButton/DropdownButton.d.ts +48 -0
  17. package/DropdownButton/DropdownButton.d.ts.map +1 -1
  18. package/DropdownButton/index.js +29 -101
  19. package/DropdownButton/index.mjs +29 -85
  20. package/HorizontalGrid/index.js +11 -31
  21. package/HorizontalGrid/index.mjs +11 -31
  22. package/HorizontalStack/index.js +48 -4
  23. package/HorizontalStack/index.mjs +48 -4
  24. package/Icon/Icon.d.ts +51 -0
  25. package/Icon/Icon.d.ts.map +1 -1
  26. package/Icon/index.js +38 -4
  27. package/Icon/index.mjs +38 -4
  28. package/IconButton/IconButton.d.ts +62 -0
  29. package/IconButton/IconButton.d.ts.map +1 -1
  30. package/IconButton/index.js +26 -43
  31. package/IconButton/index.mjs +25 -42
  32. package/InputField/Label.d.ts +2 -2
  33. package/InputField/index.js +282 -10
  34. package/InputField/index.mjs +266 -10
  35. package/InputField/utilities.d.ts +1 -1
  36. package/InputField/utilities.d.ts.map +1 -1
  37. package/Menu/MenuOverlay.d.ts.map +1 -1
  38. package/Menu/index.js +178 -1958
  39. package/Menu/index.mjs +168 -1948
  40. package/Menu/utilities.d.ts +11 -0
  41. package/Menu/utilities.d.ts.map +1 -0
  42. package/Notification/index.js +1534 -14
  43. package/Notification/index.mjs +1518 -14
  44. package/Provider/index.js +15 -15
  45. package/Provider/index.mjs +15 -15
  46. package/RadioGroup/index.js +63 -63
  47. package/RadioGroup/index.mjs +63 -63
  48. package/Select/Select.d.ts +88 -0
  49. package/Select/Select.d.ts.map +1 -0
  50. package/Select/Select.stories.d.ts +17 -0
  51. package/Select/Select.stories.d.ts.map +1 -0
  52. package/Select/Select.test.d.ts +2 -0
  53. package/Select/Select.test.d.ts.map +1 -0
  54. package/Select/SelectContext.d.ts +14 -0
  55. package/Select/SelectContext.d.ts.map +1 -0
  56. package/Select/SelectField.d.ts +62 -0
  57. package/Select/SelectField.d.ts.map +1 -0
  58. package/Select/SelectOption.d.ts +23 -0
  59. package/Select/SelectOption.d.ts.map +1 -0
  60. package/Select/SelectOverlay.d.ts +3 -0
  61. package/Select/SelectOverlay.d.ts.map +1 -0
  62. package/Select/SelectSection.d.ts +22 -0
  63. package/Select/SelectSection.d.ts.map +1 -0
  64. package/Select/SelectTrigger.d.ts +30 -0
  65. package/Select/SelectTrigger.d.ts.map +1 -0
  66. package/Select/index.d.ts +2 -0
  67. package/Select/index.d.ts.map +1 -0
  68. package/Select/index.js +816 -0
  69. package/Select/index.mjs +816 -0
  70. package/SelectorErrorTooltip/index.js +102 -11
  71. package/SelectorErrorTooltip/index.mjs +86 -11
  72. package/Text/index.js +85 -4
  73. package/Text/index.mjs +85 -4
  74. package/TextField/index.js +19 -38
  75. package/TextField/index.mjs +19 -38
  76. package/Textarea/index.js +20 -37
  77. package/Textarea/index.mjs +20 -37
  78. package/Theme/index.js +145 -9
  79. package/Theme/index.mjs +145 -9
  80. package/Toggle/index.js +51 -50
  81. package/Toggle/index.mjs +51 -50
  82. package/Tooltip/index.js +299 -10
  83. package/Tooltip/index.mjs +299 -10
  84. package/UnstyledButton/index.js +4 -4
  85. package/UnstyledButton/index.mjs +3 -3
  86. package/VerticalStack/index.js +13 -47
  87. package/VerticalStack/index.mjs +13 -47
  88. package/__chunks__/ExpandMore400-7c5263a4.mjs +49 -0
  89. package/__chunks__/ExpandMore400-92646971.js +65 -0
  90. package/__chunks__/InputIcon-2317befd.mjs +148 -0
  91. package/__chunks__/InputIcon-d3963cf8.js +147 -0
  92. package/__chunks__/{import-e7f45c7e.mjs → import-0561e1ba.mjs} +3 -3
  93. package/__chunks__/{import-b7971a11.mjs → import-19bc38ac.mjs} +72 -34
  94. package/__chunks__/{import-01299af6.js → import-24a482e1.js} +3 -2
  95. package/__chunks__/{import-baa3cd0c.mjs → import-29af6941.mjs} +4 -3
  96. package/__chunks__/{import-0d1b4d93.js → import-2b302763.js} +193 -141
  97. package/__chunks__/{import-ab878fb6.mjs → import-3d962a94.mjs} +205 -153
  98. package/__chunks__/{import-86330a7c.mjs → import-6a831ca1.mjs} +16 -15
  99. package/__chunks__/{import-7545401a.js → import-8b6c0bc7.js} +3 -3
  100. package/__chunks__/{import-63bf0645.js → import-a1e0f814.js} +47 -9
  101. package/__chunks__/{import-3ab42f86.js → import-a2023d8f.js} +35 -22
  102. package/__chunks__/{import-76076ca6.js → import-dea5a24d.js} +15 -14
  103. package/__chunks__/{import-856e0385.mjs → import-f1f4792a.mjs} +36 -23
  104. package/__chunks__/{UnstyledButton-883f0c6c.mjs → index-29d7bca9.mjs} +17 -42
  105. package/__chunks__/{UnstyledButton-96172ec0.js → index-3985350a.js} +17 -42
  106. package/__chunks__/{overlayscrollbars-react.es-c8369a03.mjs → overlayscrollbars-react.es-7f332a3b.mjs} +4 -4
  107. package/__chunks__/{overlayscrollbars-react.es-20563393.js → overlayscrollbars-react.es-f2a0bcff.js} +4 -4
  108. package/__chunks__/{real-module-e4cd2301.mjs → real-module-515df21d.mjs} +1 -1
  109. package/__chunks__/{real-module-ae2a4342.js → real-module-e36b1436.js} +1 -1
  110. package/__chunks__/useTriggerWidth-156b038a.js +2030 -0
  111. package/__chunks__/useTriggerWidth-addcd1d6.mjs +2031 -0
  112. package/package.json +11 -11
  113. package/style.css +1423 -1196
  114. package/utilities/css.js +14 -58
  115. package/utilities/css.mjs +14 -58
  116. package/__chunks__/Card-7bbd41e0.mjs +0 -110
  117. package/__chunks__/Card-dac53c75.js +0 -109
  118. package/__chunks__/HorizontalStack-a441c63f.mjs +0 -80
  119. package/__chunks__/HorizontalStack-a862839b.js +0 -79
  120. package/__chunks__/Icon-3d00481a.js +0 -44
  121. package/__chunks__/Icon-a75b5201.mjs +0 -45
  122. package/__chunks__/InputField-4fbaae06.js +0 -487
  123. package/__chunks__/InputField-a272f602.mjs +0 -472
  124. package/__chunks__/Notification-b8eafec6.mjs +0 -1456
  125. package/__chunks__/Notification-c5b34eb3.js +0 -1471
  126. package/__chunks__/SelectorErrorTooltip-43c5e29e.js +0 -84
  127. package/__chunks__/SelectorErrorTooltip-b6204987.mjs +0 -69
  128. package/__chunks__/Text-1ae70c19.js +0 -102
  129. package/__chunks__/Text-4ae50d5c.mjs +0 -103
  130. package/__chunks__/Theme-4e498252.mjs +0 -132
  131. package/__chunks__/Theme-751e5575.js +0 -131
  132. package/__chunks__/Tooltip-bd55165e.js +0 -317
  133. package/__chunks__/Tooltip-f7e67b21.mjs +0 -318
package/Card/index.js CHANGED
@@ -1,7 +1,86 @@
1
1
  "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
6
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
7
+ var __spreadValues = (a, b) => {
8
+ for (var prop in b || (b = {}))
9
+ if (__hasOwnProp.call(b, prop))
10
+ __defNormalProp(a, prop, b[prop]);
11
+ if (__getOwnPropSymbols)
12
+ for (var prop of __getOwnPropSymbols(b)) {
13
+ if (__propIsEnum.call(b, prop))
14
+ __defNormalProp(a, prop, b[prop]);
15
+ }
16
+ return a;
17
+ };
18
+ var __objRest = (source, exclude) => {
19
+ var target = {};
20
+ for (var prop in source)
21
+ if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
22
+ target[prop] = source[prop];
23
+ if (source != null && __getOwnPropSymbols)
24
+ for (var prop of __getOwnPropSymbols(source)) {
25
+ if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
26
+ target[prop] = source[prop];
27
+ }
28
+ return target;
29
+ };
2
30
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const Card = require("../__chunks__/Card-dac53c75.js");
4
- require("../__chunks__/omit-fca26542.js");
5
- require("react");
6
- require("../utilities/css.js");
7
- exports.Card = Card.Card;
31
+ const omit = require("../__chunks__/omit-fca26542.js");
32
+ const React = require("react");
33
+ const utilities_css = require("../utilities/css.js");
34
+ const container = "_container_p14mb_5";
35
+ const area = "_area_p14mb_22";
36
+ const variantOutlined = "_variantOutlined_p14mb_58";
37
+ const variantFlagged = "_variantFlagged_p14mb_59";
38
+ const selected = "_selected_p14mb_71";
39
+ const disabled = "_disabled_p14mb_75";
40
+ const statusDanger = "_statusDanger_p14mb_79";
41
+ const statusWarning = "_statusWarning_p14mb_83";
42
+ const statusSuccess = "_statusSuccess_p14mb_87";
43
+ const styles = {
44
+ container,
45
+ area,
46
+ variantOutlined,
47
+ variantFlagged,
48
+ selected,
49
+ disabled,
50
+ statusDanger,
51
+ statusWarning,
52
+ statusSuccess
53
+ };
54
+ const DEFAULT_ELEMENT_TYPE = "div";
55
+ const DEFAULT_VARIANT = "outlined";
56
+ function CardContainer(props) {
57
+ const _a = props, { as: As = DEFAULT_ELEMENT_TYPE, children, isDisabled, isSelected, status, variant = DEFAULT_VARIANT } = _a, restProps = __objRest(_a, ["as", "children", "isDisabled", "isSelected", "status", "variant"]);
58
+ const className = utilities_css.classNames(styles.container, styles[utilities_css.variationName("variant", variant)], variant === "flagged" && status && styles[utilities_css.variationName("status", status)], variant === "outlined" && isDisabled && styles.disabled, variant === "outlined" && isSelected && styles.selected);
59
+ if (variant !== "flagged" && status) {
60
+ console.warn("status is only applicable for flagged cards");
61
+ }
62
+ if (variant !== "outlined" && isSelected) {
63
+ console.warn("isSelected is only applicable for outlined cards");
64
+ }
65
+ return React.createElement(As, __spreadValues({
66
+ className,
67
+ disabled: isDisabled
68
+ }, omit.omit(restProps, ["className"])), children);
69
+ }
70
+ function CardArea({ background, children, padding = "2" }) {
71
+ const style = __spreadValues(__spreadValues({}, utilities_css.getComponentThemeToken("card-area", "background", "color.surface.card", background)), utilities_css.getResponsiveDesignToken("card-area", "padding", "space", padding));
72
+ return React.createElement("div", {
73
+ className: styles.area,
74
+ style
75
+ }, children);
76
+ }
77
+ function Card(props) {
78
+ const _a = props, { background, children, padding } = _a, containerProps = __objRest(_a, ["background", "children", "padding"]);
79
+ return React.createElement(CardContainer, __spreadValues({}, containerProps), React.createElement(CardArea, {
80
+ background,
81
+ padding
82
+ }, children));
83
+ }
84
+ Card.Container = CardContainer;
85
+ Card.Area = CardArea;
86
+ exports.Card = Card;
package/Card/index.mjs CHANGED
@@ -1,7 +1,86 @@
1
- import { C } from "../__chunks__/Card-7bbd41e0.mjs";
2
- import "../__chunks__/omit-f17deb8f.mjs";
3
- import "react";
4
- import "../utilities/css.mjs";
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
3
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
4
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
5
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6
+ var __spreadValues = (a, b) => {
7
+ for (var prop in b || (b = {}))
8
+ if (__hasOwnProp.call(b, prop))
9
+ __defNormalProp(a, prop, b[prop]);
10
+ if (__getOwnPropSymbols)
11
+ for (var prop of __getOwnPropSymbols(b)) {
12
+ if (__propIsEnum.call(b, prop))
13
+ __defNormalProp(a, prop, b[prop]);
14
+ }
15
+ return a;
16
+ };
17
+ var __objRest = (source, exclude) => {
18
+ var target = {};
19
+ for (var prop in source)
20
+ if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
21
+ target[prop] = source[prop];
22
+ if (source != null && __getOwnPropSymbols)
23
+ for (var prop of __getOwnPropSymbols(source)) {
24
+ if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
25
+ target[prop] = source[prop];
26
+ }
27
+ return target;
28
+ };
29
+ import { o as omit } from "../__chunks__/omit-f17deb8f.mjs";
30
+ import React__default from "react";
31
+ import { classNames, variationName, getComponentThemeToken, getResponsiveDesignToken } from "../utilities/css.mjs";
32
+ const container = "_container_p14mb_5";
33
+ const area = "_area_p14mb_22";
34
+ const variantOutlined = "_variantOutlined_p14mb_58";
35
+ const variantFlagged = "_variantFlagged_p14mb_59";
36
+ const selected = "_selected_p14mb_71";
37
+ const disabled = "_disabled_p14mb_75";
38
+ const statusDanger = "_statusDanger_p14mb_79";
39
+ const statusWarning = "_statusWarning_p14mb_83";
40
+ const statusSuccess = "_statusSuccess_p14mb_87";
41
+ const styles = {
42
+ container,
43
+ area,
44
+ variantOutlined,
45
+ variantFlagged,
46
+ selected,
47
+ disabled,
48
+ statusDanger,
49
+ statusWarning,
50
+ statusSuccess
51
+ };
52
+ const DEFAULT_ELEMENT_TYPE = "div";
53
+ const DEFAULT_VARIANT = "outlined";
54
+ function CardContainer(props) {
55
+ const _a = props, { as: As = DEFAULT_ELEMENT_TYPE, children, isDisabled, isSelected, status, variant = DEFAULT_VARIANT } = _a, restProps = __objRest(_a, ["as", "children", "isDisabled", "isSelected", "status", "variant"]);
56
+ const className = classNames(styles.container, styles[variationName("variant", variant)], variant === "flagged" && status && styles[variationName("status", status)], variant === "outlined" && isDisabled && styles.disabled, variant === "outlined" && isSelected && styles.selected);
57
+ if (variant !== "flagged" && status) {
58
+ console.warn("status is only applicable for flagged cards");
59
+ }
60
+ if (variant !== "outlined" && isSelected) {
61
+ console.warn("isSelected is only applicable for outlined cards");
62
+ }
63
+ return React__default.createElement(As, __spreadValues({
64
+ className,
65
+ disabled: isDisabled
66
+ }, omit(restProps, ["className"])), children);
67
+ }
68
+ function CardArea({ background, children, padding = "2" }) {
69
+ const style = __spreadValues(__spreadValues({}, getComponentThemeToken("card-area", "background", "color.surface.card", background)), getResponsiveDesignToken("card-area", "padding", "space", padding));
70
+ return React__default.createElement("div", {
71
+ className: styles.area,
72
+ style
73
+ }, children);
74
+ }
75
+ function Card(props) {
76
+ const _a = props, { background, children, padding } = _a, containerProps = __objRest(_a, ["background", "children", "padding"]);
77
+ return React__default.createElement(CardContainer, __spreadValues({}, containerProps), React__default.createElement(CardArea, {
78
+ background,
79
+ padding
80
+ }, children));
81
+ }
82
+ Card.Container = CardContainer;
83
+ Card.Area = CardArea;
5
84
  export {
6
- C as Card
85
+ Card
7
86
  };
package/Checkbox/index.js CHANGED
@@ -20,18 +20,18 @@ var __spreadValues = (a, b) => {
20
20
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
21
21
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
22
22
  const React = require("react");
23
- const Icon = require("../__chunks__/Icon-3d00481a.js");
24
- const SelectorErrorTooltip = require("../__chunks__/SelectorErrorTooltip-43c5e29e.js");
25
- const Text = require("../__chunks__/Text-1ae70c19.js");
23
+ const Icon_index = require("../Icon/index.js");
24
+ const SelectorErrorTooltip_index = require("../SelectorErrorTooltip/index.js");
25
+ const Text_index = require("../Text/index.js");
26
26
  const utilities_css = require("../utilities/css.js");
27
- const _import = require("../__chunks__/import-7545401a.js");
28
- const _import$1 = require("../__chunks__/import-0d1b4d93.js");
29
- require("../__chunks__/Tooltip-bd55165e.js");
30
- require("../__chunks__/import-3ab42f86.js");
31
- require("../__chunks__/import-63bf0645.js");
27
+ const _import = require("../__chunks__/import-8b6c0bc7.js");
28
+ const _import$1 = require("../__chunks__/import-2b302763.js");
29
+ require("../Tooltip/index.js");
30
+ require("../__chunks__/import-a2023d8f.js");
31
+ require("../__chunks__/import-a1e0f814.js");
32
32
  require("react-dom");
33
- require("../__chunks__/import-76076ca6.js");
34
- require("../__chunks__/real-module-ae2a4342.js");
33
+ require("../__chunks__/import-dea5a24d.js");
34
+ require("../__chunks__/real-module-e36b1436.js");
35
35
  function _interopNamespaceDefault(e) {
36
36
  const n = Object.create(null, { [Symbol.toStringTag]: { value: "Module" } });
37
37
  if (e) {
@@ -70,7 +70,12 @@ var __defProp$1 = Object.defineProperty;
70
70
  var __getOwnPropSymbols$1 = Object.getOwnPropertySymbols;
71
71
  var __hasOwnProp$1 = Object.prototype.hasOwnProperty;
72
72
  var __propIsEnum$1 = Object.prototype.propertyIsEnumerable;
73
- var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
73
+ var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, {
74
+ enumerable: true,
75
+ configurable: true,
76
+ writable: true,
77
+ value
78
+ }) : obj[key] = value;
74
79
  var __spreadValues$1 = (a, b) => {
75
80
  for (var prop in b || (b = {}))
76
81
  if (__hasOwnProp$1.call(b, prop))
@@ -95,20 +100,27 @@ var __objRest$1 = (source, exclude) => {
95
100
  return target;
96
101
  };
97
102
  const Check600 = (_a) => {
98
- var _b = _a, {
99
- title,
100
- titleId
101
- } = _b, props = __objRest$1(_b, [
102
- "title",
103
- "titleId"
104
- ]);
105
- return /* @__PURE__ */ React__namespace.createElement("svg", __spreadValues$1({ xmlns: "http://www.w3.org/2000/svg", viewBox: "0 -960 960 960", "aria-labelledby": titleId }, props), title ? /* @__PURE__ */ React__namespace.createElement("title", { id: titleId }, title) : null, /* @__PURE__ */ React__namespace.createElement("path", { d: "M378-248.391q-7.696 0-14.674-2.848t-13.109-8.978l-181-181Q157.391-453.043 157.391-470t11.826-28.783q11.826-11.826 28.066-11.826 16.239 0 28.63 11.826L378-346.696l355.652-355.087q11.826-11.826 28.283-12.109 16.456-.282 28.283 12.109 11.826 11.826 11.826 28.566 0 16.739-11.826 28.565L405.783-260.217q-6.131 6.13-13.109 8.978T378-248.391Z" }));
103
+ var _b = _a, { title, titleId } = _b, props = __objRest$1(_b, ["title", "titleId"]);
104
+ return React__namespace.createElement("svg", __spreadValues$1({
105
+ xmlns: "http://www.w3.org/2000/svg",
106
+ viewBox: "0 -960 960 960",
107
+ "aria-labelledby": titleId
108
+ }, props), title ? React__namespace.createElement("title", {
109
+ id: titleId
110
+ }, title) : null, React__namespace.createElement("path", {
111
+ d: "M378-248.391q-7.696 0-14.674-2.848t-13.109-8.978l-181-181Q157.391-453.043 157.391-470t11.826-28.783q11.826-11.826 28.066-11.826 16.239 0 28.63 11.826L378-346.696l355.652-355.087q11.826-11.826 28.283-12.109 16.456-.282 28.283 12.109 11.826 11.826 11.826 28.566 0 16.739-11.826 28.565L405.783-260.217q-6.131 6.13-13.109 8.978T378-248.391Z"
112
+ }));
106
113
  };
107
114
  var __defProp2 = Object.defineProperty;
108
115
  var __getOwnPropSymbols2 = Object.getOwnPropertySymbols;
109
116
  var __hasOwnProp2 = Object.prototype.hasOwnProperty;
110
117
  var __propIsEnum2 = Object.prototype.propertyIsEnumerable;
111
- var __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
118
+ var __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, {
119
+ enumerable: true,
120
+ configurable: true,
121
+ writable: true,
122
+ value
123
+ }) : obj[key] = value;
112
124
  var __spreadValues2 = (a, b) => {
113
125
  for (var prop in b || (b = {}))
114
126
  if (__hasOwnProp2.call(b, prop))
@@ -133,30 +145,32 @@ var __objRest = (source, exclude) => {
133
145
  return target;
134
146
  };
135
147
  const Remove600 = (_a) => {
136
- var _b = _a, {
137
- title,
138
- titleId
139
- } = _b, props = __objRest(_b, [
140
- "title",
141
- "titleId"
142
- ]);
143
- return /* @__PURE__ */ React__namespace.createElement("svg", __spreadValues2({ xmlns: "http://www.w3.org/2000/svg", viewBox: "0 -960 960 960", "aria-labelledby": titleId }, props), title ? /* @__PURE__ */ React__namespace.createElement("title", { id: titleId }, title) : null, /* @__PURE__ */ React__namespace.createElement("path", { d: "M190.391-440.391v-79.218h579.218v79.218H190.391Z" }));
148
+ var _b = _a, { title, titleId } = _b, props = __objRest(_b, ["title", "titleId"]);
149
+ return React__namespace.createElement("svg", __spreadValues2({
150
+ xmlns: "http://www.w3.org/2000/svg",
151
+ viewBox: "0 -960 960 960",
152
+ "aria-labelledby": titleId
153
+ }, props), title ? React__namespace.createElement("title", {
154
+ id: titleId
155
+ }, title) : null, React__namespace.createElement("path", {
156
+ d: "M190.391-440.391v-79.218h579.218v79.218H190.391Z"
157
+ }));
144
158
  };
145
- const Checkbox$1 = "_Checkbox_4i67n_5";
146
- const label = "_label_4i67n_17";
147
- const box = "_box_4i67n_40";
148
- const check = "_check_4i67n_41";
149
- const focusVisible = "_focusVisible_4i67n_56";
150
- const text = "_text_4i67n_72";
151
- const indeterminateSvg = "_indeterminateSvg_4i67n_77";
152
- const nested = "_nested_4i67n_81";
153
- const sizeLg = "_sizeLg_4i67n_85";
154
- const invalid = "_invalid_4i67n_91";
155
- const disabled = "_disabled_4i67n_95";
156
- const indeterminate = "_indeterminate_4i67n_77";
157
- const selected = "_selected_4i67n_100";
158
- const hovered = "_hovered_4i67n_116";
159
- const readOnly = "_readOnly_4i67n_116";
159
+ const Checkbox$1 = "_Checkbox_1r930_5";
160
+ const label = "_label_1r930_17";
161
+ const box = "_box_1r930_40";
162
+ const check = "_check_1r930_41";
163
+ const focusVisible = "_focusVisible_1r930_56";
164
+ const text = "_text_1r930_72";
165
+ const indeterminateSvg = "_indeterminateSvg_1r930_77";
166
+ const nested = "_nested_1r930_81";
167
+ const sizeLg = "_sizeLg_1r930_85";
168
+ const invalid = "_invalid_1r930_91";
169
+ const disabled = "_disabled_1r930_95";
170
+ const indeterminate = "_indeterminate_1r930_77";
171
+ const selected = "_selected_1r930_100";
172
+ const hovered = "_hovered_1r930_116";
173
+ const readOnly = "_readOnly_1r930_116";
160
174
  const styles = {
161
175
  Checkbox: Checkbox$1,
162
176
  label,
@@ -176,46 +190,44 @@ const styles = {
176
190
  };
177
191
  const DEFAULT_SIZE = "md";
178
192
  function Checkbox(props) {
179
- const {
180
- children,
181
- errorText,
182
- isDisabled,
183
- isIndeterminate,
184
- isReadOnly,
185
- isNested,
186
- size = DEFAULT_SIZE,
187
- validationState
188
- } = props;
193
+ const { children, errorText, isDisabled, isIndeterminate, isReadOnly, isNested, size = DEFAULT_SIZE, validationState } = props;
189
194
  const ref = React.useRef(null);
190
195
  const state = _import.$3017fa7ffdddec74$export$8042c6c013fd5226(props);
191
196
  const { inputProps } = $406796ff087fe49b$export$e375f10ce42261c5(props, state, ref);
192
197
  const { isFocusVisible, focusProps } = _import$1.$f7dceffc5ad7768b$export$4e328f61c538687f();
193
198
  const { isHovered, hoverProps } = _import$1.$6179b936705e76d3$export$ae780daf29e6d456(props);
194
199
  const isSelected = state.isSelected && !isIndeterminate;
195
- const className = utilities_css.classNames(
196
- styles.Checkbox,
197
- isIndeterminate && styles.indeterminate,
198
- isSelected && styles.selected,
199
- isDisabled && styles.disabled,
200
- isReadOnly && styles.readOnly,
201
- isNested && styles.nested,
202
- isFocusVisible && styles.focusVisible,
203
- isHovered && styles.hovered,
204
- styles[utilities_css.variationName("size", size)],
205
- validationState === "invalid" && styles.invalid
206
- );
200
+ const className = utilities_css.classNames(styles.Checkbox, isIndeterminate && styles.indeterminate, isSelected && styles.selected, isDisabled && styles.disabled, isReadOnly && styles.readOnly, isNested && styles.nested, isFocusVisible && styles.focusVisible, isHovered && styles.hovered, styles[utilities_css.variationName("size", size)], validationState === "invalid" && styles.invalid);
207
201
  const textVariant = size === "lg" ? "subtitle1" : isNested ? "body2" : "body1";
208
202
  const textColor = isDisabled ? "disabled" : validationState === "invalid" ? "danger" : "primary";
209
203
  if (size === "lg" && isNested) {
210
204
  console.warn("isNested is incompatible with lg Checkbox");
211
205
  }
212
- return /* @__PURE__ */ React.createElement("span", { className, "data-testid": "root" }, /* @__PURE__ */ React.createElement("label", __spreadValues({ className: styles.label }, hoverProps), /* @__PURE__ */ React.createElement(
213
- "input",
214
- __spreadProps(__spreadValues(__spreadValues({}, inputProps), focusProps), {
215
- className: styles.input,
216
- ref
217
- })
218
- ), /* @__PURE__ */ React.createElement("span", { className: styles.box }, (isIndeterminate || isSelected) && /* @__PURE__ */ React.createElement("span", { className: styles.check }, isIndeterminate ? /* @__PURE__ */ React.createElement(Icon.Icon, { symbol: Remove600, size: size === "lg" ? "md" : "xs" }) : /* @__PURE__ */ React.createElement(Icon.Icon, { symbol: Check600, size: size === "lg" ? "md" : "xs" }))), /* @__PURE__ */ React.createElement("span", { className: styles.text }, /* @__PURE__ */ React.createElement(Text.Text, { variant: textVariant, color: textColor }, children))), validationState === "invalid" && errorText && /* @__PURE__ */ React.createElement(SelectorErrorTooltip.SelectorErrorTooltip, { content: errorText }));
206
+ return React.createElement("span", {
207
+ className
208
+ }, React.createElement("label", __spreadValues({
209
+ className: styles.label
210
+ }, hoverProps), React.createElement("input", __spreadProps(__spreadValues(__spreadValues({}, inputProps), focusProps), {
211
+ className: styles.input,
212
+ ref
213
+ })), React.createElement("span", {
214
+ className: styles.box
215
+ }, (isIndeterminate || isSelected) && React.createElement("span", {
216
+ className: styles.check
217
+ }, isIndeterminate ? React.createElement(Icon_index.Icon, {
218
+ symbol: Remove600,
219
+ size: size === "lg" ? "md" : "xs"
220
+ }) : React.createElement(Icon_index.Icon, {
221
+ symbol: Check600,
222
+ size: size === "lg" ? "md" : "xs"
223
+ }))), React.createElement("span", {
224
+ className: styles.text
225
+ }, React.createElement(Text_index.Text, {
226
+ variant: textVariant,
227
+ color: textColor
228
+ }, children))), validationState === "invalid" && errorText && React.createElement(SelectorErrorTooltip_index.SelectorErrorTooltip, {
229
+ content: errorText
230
+ }));
219
231
  }
220
232
  exports.Checkbox = Checkbox;
221
233
  exports.DEFAULT_SIZE = DEFAULT_SIZE;
@@ -19,18 +19,18 @@ var __spreadValues = (a, b) => {
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  import * as React from "react";
21
21
  import React__default, { useEffect } from "react";
22
- import { I as Icon } from "../__chunks__/Icon-a75b5201.mjs";
23
- import { S as SelectorErrorTooltip } from "../__chunks__/SelectorErrorTooltip-b6204987.mjs";
24
- import { T as Text } from "../__chunks__/Text-4ae50d5c.mjs";
22
+ import { Icon } from "../Icon/index.mjs";
23
+ import { SelectorErrorTooltip } from "../SelectorErrorTooltip/index.mjs";
24
+ import { Text } from "../Text/index.mjs";
25
25
  import { classNames, variationName } from "../utilities/css.mjs";
26
- import { $ as $d2c8e2b0480f3f34$export$cbe85ee05b554577, a as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../__chunks__/import-e7f45c7e.mjs";
27
- import { $ as $f7dceffc5ad7768b$export$4e328f61c538687f, a as $6179b936705e76d3$export$ae780daf29e6d456 } from "../__chunks__/import-ab878fb6.mjs";
28
- import "../__chunks__/Tooltip-f7e67b21.mjs";
29
- import "../__chunks__/import-856e0385.mjs";
30
- import "../__chunks__/import-b7971a11.mjs";
26
+ import { $ as $d2c8e2b0480f3f34$export$cbe85ee05b554577, a as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../__chunks__/import-0561e1ba.mjs";
27
+ import { e as $f7dceffc5ad7768b$export$4e328f61c538687f, f as $6179b936705e76d3$export$ae780daf29e6d456 } from "../__chunks__/import-3d962a94.mjs";
28
+ import "../Tooltip/index.mjs";
29
+ import "../__chunks__/import-f1f4792a.mjs";
30
+ import "../__chunks__/import-19bc38ac.mjs";
31
31
  import "react-dom";
32
- import "../__chunks__/import-86330a7c.mjs";
33
- import "../__chunks__/real-module-e4cd2301.mjs";
32
+ import "../__chunks__/import-6a831ca1.mjs";
33
+ import "../__chunks__/real-module-515df21d.mjs";
34
34
  function $406796ff087fe49b$export$e375f10ce42261c5(props, state, inputRef) {
35
35
  let { inputProps, isSelected, isPressed, isDisabled, isReadOnly } = $d2c8e2b0480f3f34$export$cbe85ee05b554577(props, state, inputRef);
36
36
  let { isIndeterminate } = props;
@@ -52,7 +52,12 @@ var __defProp$1 = Object.defineProperty;
52
52
  var __getOwnPropSymbols$1 = Object.getOwnPropertySymbols;
53
53
  var __hasOwnProp$1 = Object.prototype.hasOwnProperty;
54
54
  var __propIsEnum$1 = Object.prototype.propertyIsEnumerable;
55
- var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
55
+ var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, {
56
+ enumerable: true,
57
+ configurable: true,
58
+ writable: true,
59
+ value
60
+ }) : obj[key] = value;
56
61
  var __spreadValues$1 = (a, b) => {
57
62
  for (var prop in b || (b = {}))
58
63
  if (__hasOwnProp$1.call(b, prop))
@@ -77,20 +82,27 @@ var __objRest$1 = (source, exclude) => {
77
82
  return target;
78
83
  };
79
84
  const Check600 = (_a) => {
80
- var _b = _a, {
81
- title,
82
- titleId
83
- } = _b, props = __objRest$1(_b, [
84
- "title",
85
- "titleId"
86
- ]);
87
- return /* @__PURE__ */ React.createElement("svg", __spreadValues$1({ xmlns: "http://www.w3.org/2000/svg", viewBox: "0 -960 960 960", "aria-labelledby": titleId }, props), title ? /* @__PURE__ */ React.createElement("title", { id: titleId }, title) : null, /* @__PURE__ */ React.createElement("path", { d: "M378-248.391q-7.696 0-14.674-2.848t-13.109-8.978l-181-181Q157.391-453.043 157.391-470t11.826-28.783q11.826-11.826 28.066-11.826 16.239 0 28.63 11.826L378-346.696l355.652-355.087q11.826-11.826 28.283-12.109 16.456-.282 28.283 12.109 11.826 11.826 11.826 28.566 0 16.739-11.826 28.565L405.783-260.217q-6.131 6.13-13.109 8.978T378-248.391Z" }));
85
+ var _b = _a, { title, titleId } = _b, props = __objRest$1(_b, ["title", "titleId"]);
86
+ return React.createElement("svg", __spreadValues$1({
87
+ xmlns: "http://www.w3.org/2000/svg",
88
+ viewBox: "0 -960 960 960",
89
+ "aria-labelledby": titleId
90
+ }, props), title ? React.createElement("title", {
91
+ id: titleId
92
+ }, title) : null, React.createElement("path", {
93
+ d: "M378-248.391q-7.696 0-14.674-2.848t-13.109-8.978l-181-181Q157.391-453.043 157.391-470t11.826-28.783q11.826-11.826 28.066-11.826 16.239 0 28.63 11.826L378-346.696l355.652-355.087q11.826-11.826 28.283-12.109 16.456-.282 28.283 12.109 11.826 11.826 11.826 28.566 0 16.739-11.826 28.565L405.783-260.217q-6.131 6.13-13.109 8.978T378-248.391Z"
94
+ }));
88
95
  };
89
96
  var __defProp2 = Object.defineProperty;
90
97
  var __getOwnPropSymbols2 = Object.getOwnPropertySymbols;
91
98
  var __hasOwnProp2 = Object.prototype.hasOwnProperty;
92
99
  var __propIsEnum2 = Object.prototype.propertyIsEnumerable;
93
- var __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
100
+ var __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, {
101
+ enumerable: true,
102
+ configurable: true,
103
+ writable: true,
104
+ value
105
+ }) : obj[key] = value;
94
106
  var __spreadValues2 = (a, b) => {
95
107
  for (var prop in b || (b = {}))
96
108
  if (__hasOwnProp2.call(b, prop))
@@ -115,30 +127,32 @@ var __objRest = (source, exclude) => {
115
127
  return target;
116
128
  };
117
129
  const Remove600 = (_a) => {
118
- var _b = _a, {
119
- title,
120
- titleId
121
- } = _b, props = __objRest(_b, [
122
- "title",
123
- "titleId"
124
- ]);
125
- return /* @__PURE__ */ React.createElement("svg", __spreadValues2({ xmlns: "http://www.w3.org/2000/svg", viewBox: "0 -960 960 960", "aria-labelledby": titleId }, props), title ? /* @__PURE__ */ React.createElement("title", { id: titleId }, title) : null, /* @__PURE__ */ React.createElement("path", { d: "M190.391-440.391v-79.218h579.218v79.218H190.391Z" }));
130
+ var _b = _a, { title, titleId } = _b, props = __objRest(_b, ["title", "titleId"]);
131
+ return React.createElement("svg", __spreadValues2({
132
+ xmlns: "http://www.w3.org/2000/svg",
133
+ viewBox: "0 -960 960 960",
134
+ "aria-labelledby": titleId
135
+ }, props), title ? React.createElement("title", {
136
+ id: titleId
137
+ }, title) : null, React.createElement("path", {
138
+ d: "M190.391-440.391v-79.218h579.218v79.218H190.391Z"
139
+ }));
126
140
  };
127
- const Checkbox$1 = "_Checkbox_4i67n_5";
128
- const label = "_label_4i67n_17";
129
- const box = "_box_4i67n_40";
130
- const check = "_check_4i67n_41";
131
- const focusVisible = "_focusVisible_4i67n_56";
132
- const text = "_text_4i67n_72";
133
- const indeterminateSvg = "_indeterminateSvg_4i67n_77";
134
- const nested = "_nested_4i67n_81";
135
- const sizeLg = "_sizeLg_4i67n_85";
136
- const invalid = "_invalid_4i67n_91";
137
- const disabled = "_disabled_4i67n_95";
138
- const indeterminate = "_indeterminate_4i67n_77";
139
- const selected = "_selected_4i67n_100";
140
- const hovered = "_hovered_4i67n_116";
141
- const readOnly = "_readOnly_4i67n_116";
141
+ const Checkbox$1 = "_Checkbox_1r930_5";
142
+ const label = "_label_1r930_17";
143
+ const box = "_box_1r930_40";
144
+ const check = "_check_1r930_41";
145
+ const focusVisible = "_focusVisible_1r930_56";
146
+ const text = "_text_1r930_72";
147
+ const indeterminateSvg = "_indeterminateSvg_1r930_77";
148
+ const nested = "_nested_1r930_81";
149
+ const sizeLg = "_sizeLg_1r930_85";
150
+ const invalid = "_invalid_1r930_91";
151
+ const disabled = "_disabled_1r930_95";
152
+ const indeterminate = "_indeterminate_1r930_77";
153
+ const selected = "_selected_1r930_100";
154
+ const hovered = "_hovered_1r930_116";
155
+ const readOnly = "_readOnly_1r930_116";
142
156
  const styles = {
143
157
  Checkbox: Checkbox$1,
144
158
  label,
@@ -158,46 +172,44 @@ const styles = {
158
172
  };
159
173
  const DEFAULT_SIZE = "md";
160
174
  function Checkbox(props) {
161
- const {
162
- children,
163
- errorText,
164
- isDisabled,
165
- isIndeterminate,
166
- isReadOnly,
167
- isNested,
168
- size = DEFAULT_SIZE,
169
- validationState
170
- } = props;
175
+ const { children, errorText, isDisabled, isIndeterminate, isReadOnly, isNested, size = DEFAULT_SIZE, validationState } = props;
171
176
  const ref = React__default.useRef(null);
172
177
  const state = $3017fa7ffdddec74$export$8042c6c013fd5226(props);
173
178
  const { inputProps } = $406796ff087fe49b$export$e375f10ce42261c5(props, state, ref);
174
179
  const { isFocusVisible, focusProps } = $f7dceffc5ad7768b$export$4e328f61c538687f();
175
180
  const { isHovered, hoverProps } = $6179b936705e76d3$export$ae780daf29e6d456(props);
176
181
  const isSelected = state.isSelected && !isIndeterminate;
177
- const className = classNames(
178
- styles.Checkbox,
179
- isIndeterminate && styles.indeterminate,
180
- isSelected && styles.selected,
181
- isDisabled && styles.disabled,
182
- isReadOnly && styles.readOnly,
183
- isNested && styles.nested,
184
- isFocusVisible && styles.focusVisible,
185
- isHovered && styles.hovered,
186
- styles[variationName("size", size)],
187
- validationState === "invalid" && styles.invalid
188
- );
182
+ const className = classNames(styles.Checkbox, isIndeterminate && styles.indeterminate, isSelected && styles.selected, isDisabled && styles.disabled, isReadOnly && styles.readOnly, isNested && styles.nested, isFocusVisible && styles.focusVisible, isHovered && styles.hovered, styles[variationName("size", size)], validationState === "invalid" && styles.invalid);
189
183
  const textVariant = size === "lg" ? "subtitle1" : isNested ? "body2" : "body1";
190
184
  const textColor = isDisabled ? "disabled" : validationState === "invalid" ? "danger" : "primary";
191
185
  if (size === "lg" && isNested) {
192
186
  console.warn("isNested is incompatible with lg Checkbox");
193
187
  }
194
- return /* @__PURE__ */ React__default.createElement("span", { className, "data-testid": "root" }, /* @__PURE__ */ React__default.createElement("label", __spreadValues({ className: styles.label }, hoverProps), /* @__PURE__ */ React__default.createElement(
195
- "input",
196
- __spreadProps(__spreadValues(__spreadValues({}, inputProps), focusProps), {
197
- className: styles.input,
198
- ref
199
- })
200
- ), /* @__PURE__ */ React__default.createElement("span", { className: styles.box }, (isIndeterminate || isSelected) && /* @__PURE__ */ React__default.createElement("span", { className: styles.check }, isIndeterminate ? /* @__PURE__ */ React__default.createElement(Icon, { symbol: Remove600, size: size === "lg" ? "md" : "xs" }) : /* @__PURE__ */ React__default.createElement(Icon, { symbol: Check600, size: size === "lg" ? "md" : "xs" }))), /* @__PURE__ */ React__default.createElement("span", { className: styles.text }, /* @__PURE__ */ React__default.createElement(Text, { variant: textVariant, color: textColor }, children))), validationState === "invalid" && errorText && /* @__PURE__ */ React__default.createElement(SelectorErrorTooltip, { content: errorText }));
188
+ return React__default.createElement("span", {
189
+ className
190
+ }, React__default.createElement("label", __spreadValues({
191
+ className: styles.label
192
+ }, hoverProps), React__default.createElement("input", __spreadProps(__spreadValues(__spreadValues({}, inputProps), focusProps), {
193
+ className: styles.input,
194
+ ref
195
+ })), React__default.createElement("span", {
196
+ className: styles.box
197
+ }, (isIndeterminate || isSelected) && React__default.createElement("span", {
198
+ className: styles.check
199
+ }, isIndeterminate ? React__default.createElement(Icon, {
200
+ symbol: Remove600,
201
+ size: size === "lg" ? "md" : "xs"
202
+ }) : React__default.createElement(Icon, {
203
+ symbol: Check600,
204
+ size: size === "lg" ? "md" : "xs"
205
+ }))), React__default.createElement("span", {
206
+ className: styles.text
207
+ }, React__default.createElement(Text, {
208
+ variant: textVariant,
209
+ color: textColor
210
+ }, children))), validationState === "invalid" && errorText && React__default.createElement(SelectorErrorTooltip, {
211
+ content: errorText
212
+ }));
201
213
  }
202
214
  export {
203
215
  Checkbox,