@uniformdev/design-system 19.15.0 → 19.19.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.
- package/dist/esm/index.js +857 -504
- package/dist/index.d.ts +50 -10
- package/dist/index.js +1163 -817
- package/package.json +8 -7
package/dist/index.js
CHANGED
|
@@ -146,7 +146,9 @@ __export(src_exports, {
|
|
|
146
146
|
Tabs: () => Tabs,
|
|
147
147
|
Textarea: () => Textarea,
|
|
148
148
|
Theme: () => Theme,
|
|
149
|
+
Tile: () => Tile2,
|
|
149
150
|
TileContainer: () => TileContainer,
|
|
151
|
+
TileText: () => TileText2,
|
|
150
152
|
Tooltip: () => Tooltip,
|
|
151
153
|
TwoColumnLayout: () => TwoColumnLayout,
|
|
152
154
|
UniformBadge: () => UniformBadge,
|
|
@@ -188,6 +190,7 @@ __export(src_exports, {
|
|
|
188
190
|
inputError: () => inputError,
|
|
189
191
|
inputSelect: () => inputSelect,
|
|
190
192
|
isMacLike: () => isMacLike,
|
|
193
|
+
jsonIcon: () => jsonIcon,
|
|
191
194
|
labelText: () => labelText,
|
|
192
195
|
loaderAnimationData: () => loader_default,
|
|
193
196
|
macifyShortcut: () => macifyShortcut,
|
|
@@ -279,8 +282,8 @@ var Theme = ({ disableReset = false }) => {
|
|
|
279
282
|
--raspberry-beret-300: #ff6aba;
|
|
280
283
|
--raspberry-beret-400: #ff40a7;
|
|
281
284
|
--raspberry-beret-500: #f5168e;
|
|
282
|
-
--raspberry-beret-600: #
|
|
283
|
-
--raspberry-beret-700: #
|
|
285
|
+
--raspberry-beret-600: #cc006e;
|
|
286
|
+
--raspberry-beret-700: #a30058;
|
|
284
287
|
|
|
285
288
|
|
|
286
289
|
/* action colours */
|
|
@@ -802,10 +805,17 @@ var toggleInput = import_react4.css`
|
|
|
802
805
|
}
|
|
803
806
|
|
|
804
807
|
&:disabled {
|
|
808
|
+
filter: grayscale(100%);
|
|
805
809
|
cursor: not-allowed;
|
|
806
810
|
color: var(--gray-300);
|
|
807
811
|
border-color: var(--gray-300);
|
|
808
812
|
}
|
|
813
|
+
|
|
814
|
+
&:disabled:checked {
|
|
815
|
+
background: var(--white)
|
|
816
|
+
url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%0A%3E%3Cpath d='M10.5858 13.4142L7.75735 10.5858L6.34314 12L10.5858 16.2427L17.6568 9.1716L16.2426 7.75739L10.5858 13.4142Z' fill='%23000' /%3E%3C/svg%3E")
|
|
817
|
+
no-repeat center center;
|
|
818
|
+
}
|
|
809
819
|
`;
|
|
810
820
|
var inlineLabel = (fontWeight) => import_react4.css`
|
|
811
821
|
font-weight: ${fontWeight === "medium" ? "var(--fw-medium)" : fontWeight === "normal" ? "var(--fw-regular)" : "var(--fw-bold)"};
|
|
@@ -1718,6 +1728,74 @@ var formatSubscript = (0, import_react_icons.GenIcon)({
|
|
|
1718
1728
|
}
|
|
1719
1729
|
]
|
|
1720
1730
|
});
|
|
1731
|
+
var jsonIcon = (0, import_react_icons.GenIcon)({
|
|
1732
|
+
tag: "svg",
|
|
1733
|
+
attr: {
|
|
1734
|
+
role: "img",
|
|
1735
|
+
viewBox: "0 0 40 40"
|
|
1736
|
+
},
|
|
1737
|
+
child: [
|
|
1738
|
+
{
|
|
1739
|
+
tag: "path",
|
|
1740
|
+
attr: {
|
|
1741
|
+
fill: "currentColor",
|
|
1742
|
+
d: "M3.3335 20.0719V18.1118C4.82718 18.1118 5.87011 17.8113 6.46228 17.2102C7.05446 16.6005 7.35054 15.5943 7.35054 14.1918V10.4417C7.35054 9.10884 7.50079 7.98945 7.8013 7.08349C8.11064 6.16882 8.57908 5.43708 9.2066 4.88827C9.83413 4.33947 10.6296 3.94311 11.593 3.6992C12.5563 3.45528 13.6921 3.33333 15.0002 3.33333V6.43015C13.9749 6.43015 13.175 6.57824 12.6005 6.87442C12.026 7.1706 11.6239 7.6323 11.3941 8.2595C11.1731 8.878 11.0627 9.67071 11.0627 10.6377V15.394C11.0627 16.0647 10.961 16.6876 10.7577 17.2625C10.5545 17.8287 10.1788 18.3209 9.63084 18.7391C9.08286 19.1572 8.30067 19.4839 7.28425 19.7191C6.26784 19.9543 4.95092 20.0719 3.3335 20.0719ZM15.0002 36.6667C13.6921 36.6667 12.5563 36.5447 11.593 36.3008C10.6296 36.0569 9.83413 35.6605 9.2066 35.1117C8.57908 34.5629 8.11064 33.8312 7.8013 32.9165C7.50079 32.0105 7.35054 30.8911 7.35054 29.5583V25.7951C7.35054 24.4013 7.05446 23.3995 6.46228 22.7897C5.87011 22.18 4.82718 21.8751 3.3335 21.8751V19.9281C4.95092 19.9281 6.26784 20.0457 7.28425 20.2809C8.30067 20.5074 9.08286 20.8341 9.63084 21.2609C10.1788 21.6791 10.5545 22.1756 10.7577 22.7506C10.961 23.3168 11.0627 23.9353 11.0627 24.606V29.3623C11.0627 30.3206 11.1731 31.1089 11.3941 31.7274C11.6239 32.3546 12.026 32.8163 12.6005 33.1125C13.175 33.4174 13.9749 33.5698 15.0002 33.5698V36.6667ZM3.3335 21.8751V18.1118H7.00584V21.8751H3.3335Z"
|
|
1743
|
+
},
|
|
1744
|
+
child: []
|
|
1745
|
+
},
|
|
1746
|
+
{
|
|
1747
|
+
tag: "path",
|
|
1748
|
+
attr: {
|
|
1749
|
+
fill: "currentColor",
|
|
1750
|
+
d: "M14.9998 20C14.9998 20.9205 14.2536 21.6667 13.3332 21.6667C12.4127 21.6667 11.6665 20.9205 11.6665 20C11.6665 19.0795 12.4127 18.3333 13.3332 18.3333C14.2536 18.3333 14.9998 19.0795 14.9998 20Z"
|
|
1751
|
+
},
|
|
1752
|
+
child: []
|
|
1753
|
+
},
|
|
1754
|
+
{
|
|
1755
|
+
tag: "path",
|
|
1756
|
+
attr: {
|
|
1757
|
+
fill: "currentColor",
|
|
1758
|
+
d: "M21.6665 20C21.6665 20.9205 20.9203 21.6667 19.9998 21.6667C19.0794 21.6667 18.3332 20.9205 18.3332 20C18.3332 19.0795 19.0794 18.3333 19.9998 18.3333C20.9203 18.3333 21.6665 19.0795 21.6665 20Z"
|
|
1759
|
+
},
|
|
1760
|
+
child: []
|
|
1761
|
+
},
|
|
1762
|
+
{
|
|
1763
|
+
tag: "path",
|
|
1764
|
+
attr: {
|
|
1765
|
+
fill: "currentColor",
|
|
1766
|
+
d: "M28.3332 20C28.3332 20.9205 27.587 21.6667 26.6665 21.6667C25.746 21.6667 24.9998 20.9205 24.9998 20C24.9998 19.0795 25.746 18.3333 26.6665 18.3333C27.587 18.3333 28.3332 19.0795 28.3332 20Z"
|
|
1767
|
+
},
|
|
1768
|
+
child: []
|
|
1769
|
+
},
|
|
1770
|
+
{
|
|
1771
|
+
tag: "path",
|
|
1772
|
+
attr: {
|
|
1773
|
+
fill: "currentColor",
|
|
1774
|
+
d: "M36.6667 19.9281V21.8751C35.173 21.8751 34.1301 22.18 33.5379 22.7898C32.9457 23.3995 32.6496 24.4013 32.6496 25.7951V29.5583C32.6496 30.8912 32.4949 32.0105 32.1856 32.9165C31.8851 33.8312 31.4211 34.5629 30.7936 35.1117C30.166 35.6605 29.3706 36.0569 28.4072 36.3008C27.4438 36.5447 26.3081 36.6667 25 36.6667V33.5698C26.0253 33.5698 26.8251 33.4174 27.3996 33.1125C27.9741 32.8163 28.3718 32.3546 28.5928 31.7274C28.8226 31.1089 28.9375 30.3206 28.9375 29.3623V24.606C28.9375 23.9353 29.0391 23.3168 29.2424 22.7506C29.4457 22.1756 29.8213 21.6791 30.3693 21.2609C30.9173 20.8341 31.6995 20.5074 32.7159 20.2809C33.7323 20.0457 35.0492 19.9281 36.6667 19.9281ZM25 3.33333C26.3081 3.33333 27.4438 3.45528 28.4072 3.6992C29.3706 3.94311 30.166 4.33947 30.7936 4.88827C31.4211 5.43708 31.8851 6.16882 32.1856 7.08349C32.4949 7.98945 32.6496 9.10884 32.6496 10.4417V14.1918C32.6496 15.5943 32.9457 16.6005 33.5379 17.2102C34.1301 17.8113 35.173 18.1118 36.6667 18.1118V20.0719C35.0492 20.0719 33.7323 19.9543 32.7159 19.7191C31.6995 19.4839 30.9173 19.1572 30.3693 18.7391C29.8213 18.3209 29.4457 17.8287 29.2424 17.2625C29.0391 16.6876 28.9375 16.0647 28.9375 15.394V10.6377C28.9375 9.67071 28.8226 8.878 28.5928 8.2595C28.3718 7.6323 27.9741 7.1706 27.3996 6.87442C26.8251 6.57824 26.0253 6.43015 25 6.43015V3.33333ZM36.6667 18.1118V21.8751H32.9943V18.1118H36.6667Z"
|
|
1775
|
+
},
|
|
1776
|
+
child: []
|
|
1777
|
+
}
|
|
1778
|
+
]
|
|
1779
|
+
});
|
|
1780
|
+
var clearFormatting = (0, import_react_icons.GenIcon)({
|
|
1781
|
+
tag: "svg",
|
|
1782
|
+
attr: {
|
|
1783
|
+
role: "img",
|
|
1784
|
+
viewBox: "0 0 24 24"
|
|
1785
|
+
},
|
|
1786
|
+
child: [
|
|
1787
|
+
{
|
|
1788
|
+
tag: "path",
|
|
1789
|
+
attr: {
|
|
1790
|
+
fill: "currentColor",
|
|
1791
|
+
fillRule: "evenodd",
|
|
1792
|
+
clipRule: "evenodd",
|
|
1793
|
+
d: "M4.904 12.75a1.67 1.67 0 0 0 0 2.362l3.22 3.22h-2.73a.835.835 0 0 0 0 1.67H18.75a.835.835 0 1 0 0-1.67h-7.622l7.943-7.942a1.67 1.67 0 0 0 0-2.362L15.53 4.487a1.67 1.67 0 0 0-2.362 0L4.904 12.75Zm3.611-1.25-2.43 2.431 3.542 3.542 2.43-2.43L8.515 11.5Zm1.181-1.18 3.542 3.542L17.89 9.21l-3.542-3.542-4.653 4.653Z"
|
|
1794
|
+
},
|
|
1795
|
+
child: []
|
|
1796
|
+
}
|
|
1797
|
+
]
|
|
1798
|
+
});
|
|
1721
1799
|
var customIcons = {
|
|
1722
1800
|
"rectangle-rounded": rectangleRoundedIcon,
|
|
1723
1801
|
card: cardIcon,
|
|
@@ -1731,12 +1809,14 @@ var customIcons = {
|
|
|
1731
1809
|
"info-filled": infoFilledIcon,
|
|
1732
1810
|
settings,
|
|
1733
1811
|
"query-string": queryStringIcon,
|
|
1812
|
+
json: jsonIcon,
|
|
1734
1813
|
"format-bold": formatBoldIcon,
|
|
1735
1814
|
"format-code": formatCode,
|
|
1736
1815
|
"format-strike": formatStrike,
|
|
1737
1816
|
"format-superscript": formatSuperscript,
|
|
1738
1817
|
"format-subscript": formatSubscript,
|
|
1739
|
-
"layout-list-numbered": layoutListNumberedIcon
|
|
1818
|
+
"layout-list-numbered": layoutListNumberedIcon,
|
|
1819
|
+
"clear-formatting": clearFormatting
|
|
1740
1820
|
};
|
|
1741
1821
|
|
|
1742
1822
|
// src/components/AddListButton/AddListButton.styles.ts
|
|
@@ -11198,70 +11278,20 @@ var Button = React5.forwardRef(
|
|
|
11198
11278
|
var import_cg6 = require("react-icons/cg");
|
|
11199
11279
|
|
|
11200
11280
|
// src/components/Menu/Menu.tsx
|
|
11201
|
-
var
|
|
11281
|
+
var React7 = __toESM(require("react"));
|
|
11202
11282
|
var import_Menu = require("reakit/Menu");
|
|
11203
11283
|
var import_Portal = require("reakit/Portal");
|
|
11204
11284
|
|
|
11205
|
-
// src/components/Menu/
|
|
11206
|
-
var
|
|
11207
|
-
var menu = import_react27.css`
|
|
11208
|
-
box-shadow: var(--shadow-base);
|
|
11209
|
-
border-radius: var(--rounded-base);
|
|
11210
|
-
background: var(--gray-50);
|
|
11211
|
-
display: flex;
|
|
11212
|
-
flex-direction: column;
|
|
11213
|
-
padding: var(--spacing-sm);
|
|
11214
|
-
outline: none;
|
|
11215
|
-
overflow: hidden;
|
|
11216
|
-
position: relative;
|
|
11217
|
-
z-index: var(--z-50);
|
|
11218
|
-
`;
|
|
11219
|
-
|
|
11220
|
-
// src/components/Menu/Menu.tsx
|
|
11221
|
-
var import_jsx_runtime20 = require("@emotion/react/jsx-runtime");
|
|
11222
|
-
var MenuContext = React6.createContext({});
|
|
11223
|
-
var useMenuContext = () => {
|
|
11224
|
-
return React6.useContext(MenuContext);
|
|
11225
|
-
};
|
|
11226
|
-
var Menu = ({
|
|
11227
|
-
menuLabel,
|
|
11228
|
-
menuTrigger,
|
|
11229
|
-
placement = "auto",
|
|
11230
|
-
menuItemsContainerCssClasses,
|
|
11231
|
-
children,
|
|
11232
|
-
forceVisible
|
|
11233
|
-
}) => {
|
|
11234
|
-
const menuState = (0, import_Menu.useMenuState)({ placement, visible: forceVisible });
|
|
11235
|
-
React6.useEffect(() => {
|
|
11236
|
-
if (forceVisible !== void 0) {
|
|
11237
|
-
menuState.setVisible(forceVisible);
|
|
11238
|
-
}
|
|
11239
|
-
});
|
|
11240
|
-
return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(MenuContext.Provider, { value: menuState, children: [
|
|
11241
|
-
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_Menu.MenuButton, { ...menuState, ref: menuTrigger.ref, ...menuTrigger.props, children: (triggerProps) => React6.cloneElement(menuTrigger, triggerProps) }),
|
|
11242
|
-
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_Portal.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
|
|
11243
|
-
import_Menu.Menu,
|
|
11244
|
-
{
|
|
11245
|
-
...menuState,
|
|
11246
|
-
"aria-label": menuLabel,
|
|
11247
|
-
css: [
|
|
11248
|
-
menu,
|
|
11249
|
-
typeof menuItemsContainerCssClasses === "object" ? menuItemsContainerCssClasses : void 0
|
|
11250
|
-
],
|
|
11251
|
-
className: typeof menuItemsContainerCssClasses === "string" ? menuItemsContainerCssClasses : "",
|
|
11252
|
-
children
|
|
11253
|
-
}
|
|
11254
|
-
) })
|
|
11255
|
-
] });
|
|
11256
|
-
};
|
|
11285
|
+
// src/components/Menu/filterMenuSeparators.ts
|
|
11286
|
+
var import_react29 = __toESM(require("react"));
|
|
11257
11287
|
|
|
11258
11288
|
// src/components/Menu/MenuGroup.styles.ts
|
|
11259
|
-
var
|
|
11260
|
-
var MenuGroupContainer =
|
|
11289
|
+
var import_react27 = require("@emotion/react");
|
|
11290
|
+
var MenuGroupContainer = import_react27.css`
|
|
11261
11291
|
display: flex;
|
|
11262
11292
|
flex-direction: column;
|
|
11263
11293
|
`;
|
|
11264
|
-
var MenuTitle =
|
|
11294
|
+
var MenuTitle = import_react27.css`
|
|
11265
11295
|
color: var(--gray-400);
|
|
11266
11296
|
font-size: var(--fs-xs);
|
|
11267
11297
|
font-weight: var(--fw-bold);
|
|
@@ -11269,21 +11299,17 @@ var MenuTitle = import_react28.css`
|
|
|
11269
11299
|
`;
|
|
11270
11300
|
|
|
11271
11301
|
// src/components/Menu/MenuGroup.tsx
|
|
11272
|
-
var
|
|
11302
|
+
var import_jsx_runtime20 = require("@emotion/react/jsx-runtime");
|
|
11273
11303
|
var MenuGroup = ({ title, children }) => {
|
|
11274
|
-
return /* @__PURE__ */ (0,
|
|
11275
|
-
/* @__PURE__ */ (0,
|
|
11304
|
+
return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { css: MenuGroupContainer, "data-test-id": "menu-group", children: [
|
|
11305
|
+
/* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { css: MenuTitle, children: title }),
|
|
11276
11306
|
children
|
|
11277
11307
|
] });
|
|
11278
11308
|
};
|
|
11279
11309
|
|
|
11280
|
-
// src/components/Menu/MenuItem.tsx
|
|
11281
|
-
var React7 = __toESM(require("react"));
|
|
11282
|
-
var import_reakit = require("reakit");
|
|
11283
|
-
|
|
11284
11310
|
// src/components/Menu/MenuItem.styles.ts
|
|
11285
|
-
var
|
|
11286
|
-
var menuItem = (textTheme) =>
|
|
11311
|
+
var import_react28 = require("@emotion/react");
|
|
11312
|
+
var menuItem = (textTheme) => import_react28.css`
|
|
11287
11313
|
align-items: center;
|
|
11288
11314
|
border: none;
|
|
11289
11315
|
border-radius: var(--rounded-base);
|
|
@@ -11309,7 +11335,7 @@ var menuItem = (textTheme) => import_react29.css`
|
|
|
11309
11335
|
outline: none;
|
|
11310
11336
|
}
|
|
11311
11337
|
`;
|
|
11312
|
-
var menuItemWithIcon =
|
|
11338
|
+
var menuItemWithIcon = import_react28.css`
|
|
11313
11339
|
align-items: center;
|
|
11314
11340
|
display: flex;
|
|
11315
11341
|
justify-content: space-between;
|
|
@@ -11321,15 +11347,120 @@ var menuItemWithIcon = import_react29.css`
|
|
|
11321
11347
|
height: var(--spacing-base);
|
|
11322
11348
|
}
|
|
11323
11349
|
`;
|
|
11324
|
-
var menuItemSeparator =
|
|
11350
|
+
var menuItemSeparator = import_react28.css`
|
|
11325
11351
|
border-top: 1px solid var(--gray-300);
|
|
11326
11352
|
width: 100%;
|
|
11327
11353
|
margin-block: var(--spacing-sm);
|
|
11328
11354
|
`;
|
|
11329
11355
|
|
|
11330
|
-
// src/components/Menu/
|
|
11356
|
+
// src/components/Menu/MenuItemSeparator.tsx
|
|
11357
|
+
var import_jsx_runtime21 = require("@emotion/react/jsx-runtime");
|
|
11358
|
+
var MenuItemSeparator = () => /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("hr", { css: menuItemSeparator, "data-testid": "menu-separator" });
|
|
11359
|
+
|
|
11360
|
+
// src/components/Menu/filterMenuSeparators.ts
|
|
11361
|
+
function filterMenuSeparators(children, context) {
|
|
11362
|
+
const currentContext = context || { lastChildWasSeparator: false, effectiveIndex: 0 };
|
|
11363
|
+
if (!Array.isArray(children)) {
|
|
11364
|
+
return children;
|
|
11365
|
+
}
|
|
11366
|
+
const filteredList = [];
|
|
11367
|
+
children.forEach((child, index) => {
|
|
11368
|
+
if (child === null || child === false) {
|
|
11369
|
+
return;
|
|
11370
|
+
}
|
|
11371
|
+
const isSeparator = isMenuSeparator(child);
|
|
11372
|
+
if (currentContext.effectiveIndex === 0 && isSeparator) {
|
|
11373
|
+
return;
|
|
11374
|
+
}
|
|
11375
|
+
if (isSeparator && index === children.length - 1) {
|
|
11376
|
+
return;
|
|
11377
|
+
}
|
|
11378
|
+
if (isSeparator && currentContext.lastChildWasSeparator) {
|
|
11379
|
+
return;
|
|
11380
|
+
}
|
|
11381
|
+
if (isSubgroup(child)) {
|
|
11382
|
+
child = {
|
|
11383
|
+
...child,
|
|
11384
|
+
props: {
|
|
11385
|
+
...child.props,
|
|
11386
|
+
children: filterMenuSeparators(child.props.children, currentContext)
|
|
11387
|
+
}
|
|
11388
|
+
};
|
|
11389
|
+
filteredList.push(child);
|
|
11390
|
+
return;
|
|
11391
|
+
}
|
|
11392
|
+
currentContext.effectiveIndex++;
|
|
11393
|
+
currentContext.lastChildWasSeparator = isSeparator;
|
|
11394
|
+
filteredList.push(child);
|
|
11395
|
+
});
|
|
11396
|
+
return filteredList;
|
|
11397
|
+
}
|
|
11398
|
+
function isSubgroup(child) {
|
|
11399
|
+
return (0, import_react29.isValidElement)(child) && (child.type === import_react29.default.Fragment || child.type === MenuGroup);
|
|
11400
|
+
}
|
|
11401
|
+
function isMenuSeparator(child) {
|
|
11402
|
+
return (0, import_react29.isValidElement)(child) && child.type === MenuItemSeparator;
|
|
11403
|
+
}
|
|
11404
|
+
|
|
11405
|
+
// src/components/Menu/Menu.styles.ts
|
|
11406
|
+
var import_react30 = require("@emotion/react");
|
|
11407
|
+
var menu = import_react30.css`
|
|
11408
|
+
box-shadow: var(--shadow-base);
|
|
11409
|
+
border-radius: var(--rounded-base);
|
|
11410
|
+
background: var(--gray-50);
|
|
11411
|
+
display: flex;
|
|
11412
|
+
flex-direction: column;
|
|
11413
|
+
padding: var(--spacing-sm);
|
|
11414
|
+
outline: none;
|
|
11415
|
+
overflow: hidden;
|
|
11416
|
+
position: relative;
|
|
11417
|
+
z-index: var(--z-50);
|
|
11418
|
+
`;
|
|
11419
|
+
|
|
11420
|
+
// src/components/Menu/Menu.tsx
|
|
11331
11421
|
var import_jsx_runtime22 = require("@emotion/react/jsx-runtime");
|
|
11332
|
-
var
|
|
11422
|
+
var MenuContext = React7.createContext({});
|
|
11423
|
+
var useMenuContext = () => {
|
|
11424
|
+
return React7.useContext(MenuContext);
|
|
11425
|
+
};
|
|
11426
|
+
var Menu = ({
|
|
11427
|
+
menuLabel,
|
|
11428
|
+
menuTrigger,
|
|
11429
|
+
placement = "auto",
|
|
11430
|
+
menuItemsContainerCssClasses,
|
|
11431
|
+
children,
|
|
11432
|
+
forceVisible,
|
|
11433
|
+
disableAutoSeparatorManagement
|
|
11434
|
+
}) => {
|
|
11435
|
+
const menuState = (0, import_Menu.useMenuState)({ placement, visible: forceVisible });
|
|
11436
|
+
React7.useEffect(() => {
|
|
11437
|
+
if (forceVisible !== void 0) {
|
|
11438
|
+
menuState.setVisible(forceVisible);
|
|
11439
|
+
}
|
|
11440
|
+
});
|
|
11441
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(MenuContext.Provider, { value: menuState, children: [
|
|
11442
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_Menu.MenuButton, { ...menuState, ref: menuTrigger.ref, ...menuTrigger.props, children: (triggerProps) => React7.cloneElement(menuTrigger, triggerProps) }),
|
|
11443
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_Portal.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
11444
|
+
import_Menu.Menu,
|
|
11445
|
+
{
|
|
11446
|
+
...menuState,
|
|
11447
|
+
"aria-label": menuLabel,
|
|
11448
|
+
css: [
|
|
11449
|
+
menu,
|
|
11450
|
+
typeof menuItemsContainerCssClasses === "object" ? menuItemsContainerCssClasses : void 0
|
|
11451
|
+
],
|
|
11452
|
+
className: typeof menuItemsContainerCssClasses === "string" ? menuItemsContainerCssClasses : "",
|
|
11453
|
+
children: disableAutoSeparatorManagement ? children : filterMenuSeparators(children)
|
|
11454
|
+
}
|
|
11455
|
+
) })
|
|
11456
|
+
] });
|
|
11457
|
+
};
|
|
11458
|
+
|
|
11459
|
+
// src/components/Menu/MenuItem.tsx
|
|
11460
|
+
var React8 = __toESM(require("react"));
|
|
11461
|
+
var import_reakit = require("reakit");
|
|
11462
|
+
var import_jsx_runtime23 = require("@emotion/react/jsx-runtime");
|
|
11463
|
+
var MenuItem = React8.forwardRef(
|
|
11333
11464
|
({ children, className, hideMenuOnClick = true, icon, textColor = "base", ...props }, ref) => {
|
|
11334
11465
|
const menuState = useMenuContext();
|
|
11335
11466
|
const resolveProps = (originalProps) => {
|
|
@@ -11345,7 +11476,7 @@ var MenuItem = React7.forwardRef(
|
|
|
11345
11476
|
};
|
|
11346
11477
|
const resolvedProps = hideMenuOnClick ? resolveProps(props) : props;
|
|
11347
11478
|
const resolvedChildren = typeof children === "function" ? children(resolvedProps) : children;
|
|
11348
|
-
return /* @__PURE__ */ (0,
|
|
11479
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
11349
11480
|
import_reakit.MenuItem,
|
|
11350
11481
|
{
|
|
11351
11482
|
ref,
|
|
@@ -11361,20 +11492,16 @@ var MenuItem = React7.forwardRef(
|
|
|
11361
11492
|
}
|
|
11362
11493
|
);
|
|
11363
11494
|
function renderWithIcon(children, icon) {
|
|
11364
|
-
return /* @__PURE__ */ (0,
|
|
11495
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("span", { css: menuItemWithIcon, children: [
|
|
11365
11496
|
icon,
|
|
11366
11497
|
" ",
|
|
11367
11498
|
children
|
|
11368
11499
|
] });
|
|
11369
11500
|
}
|
|
11370
11501
|
|
|
11371
|
-
// src/components/Menu/MenuItemSeparator.tsx
|
|
11372
|
-
var import_jsx_runtime23 = require("@emotion/react/jsx-runtime");
|
|
11373
|
-
var MenuItemSeparator = () => /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("hr", { css: menuItemSeparator });
|
|
11374
|
-
|
|
11375
11502
|
// src/components/ButtonWithMenu/ButtonWithMenu.styles.ts
|
|
11376
|
-
var
|
|
11377
|
-
var ButtonWithMenuContainer =
|
|
11503
|
+
var import_react31 = require("@emotion/react");
|
|
11504
|
+
var ButtonWithMenuContainer = import_react31.css`
|
|
11378
11505
|
align-items: center;
|
|
11379
11506
|
border: 1px solid transparent;
|
|
11380
11507
|
border-radius: var(--rounded-sm);
|
|
@@ -11395,7 +11522,7 @@ var ButtonWithMenuContainer = import_react30.css`
|
|
|
11395
11522
|
border-color: var(--gray-700);
|
|
11396
11523
|
}
|
|
11397
11524
|
`;
|
|
11398
|
-
var ButtonWithMenuBtn =
|
|
11525
|
+
var ButtonWithMenuBtn = import_react31.css`
|
|
11399
11526
|
border: 1px solid transparent;
|
|
11400
11527
|
background: transparent;
|
|
11401
11528
|
border-radius: var(--rounded-base);
|
|
@@ -11418,19 +11545,19 @@ var ButtonWithMenuBtn = import_react30.css`
|
|
|
11418
11545
|
pointer-events: none;
|
|
11419
11546
|
}
|
|
11420
11547
|
`;
|
|
11421
|
-
var ButtonWithMenuIcon =
|
|
11548
|
+
var ButtonWithMenuIcon = import_react31.css`
|
|
11422
11549
|
padding: var(--spacing-sm);
|
|
11423
11550
|
border-left: 1px solid currentColor;
|
|
11424
11551
|
`;
|
|
11425
|
-
var buttonPrimary2 =
|
|
11552
|
+
var buttonPrimary2 = import_react31.css`
|
|
11426
11553
|
background: var(--brand-secondary-1);
|
|
11427
11554
|
color: var(--white);
|
|
11428
11555
|
`;
|
|
11429
|
-
var buttonPrimaryDisabled =
|
|
11556
|
+
var buttonPrimaryDisabled = import_react31.css`
|
|
11430
11557
|
background: var(--gray-300);
|
|
11431
11558
|
color: var(--white);
|
|
11432
11559
|
`;
|
|
11433
|
-
var buttonSecondary2 =
|
|
11560
|
+
var buttonSecondary2 = import_react31.css`
|
|
11434
11561
|
background: var(--primary-action-default);
|
|
11435
11562
|
color: var(--white);
|
|
11436
11563
|
|
|
@@ -11438,17 +11565,17 @@ var buttonSecondary2 = import_react30.css`
|
|
|
11438
11565
|
background: var(--primary-action-hover);
|
|
11439
11566
|
}
|
|
11440
11567
|
`;
|
|
11441
|
-
var buttonSecondaryDisabled =
|
|
11568
|
+
var buttonSecondaryDisabled = import_react31.css`
|
|
11442
11569
|
${buttonPrimaryDisabled}
|
|
11443
11570
|
`;
|
|
11444
|
-
var buttonUnimportant2 =
|
|
11571
|
+
var buttonUnimportant2 = import_react31.css`
|
|
11445
11572
|
background: var(--brand-secondary-2);
|
|
11446
11573
|
color: var(--brand-secondary-1);
|
|
11447
11574
|
`;
|
|
11448
|
-
var buttonUnimportantDisabled =
|
|
11575
|
+
var buttonUnimportantDisabled = import_react31.css`
|
|
11449
11576
|
${buttonPrimaryDisabled}
|
|
11450
11577
|
`;
|
|
11451
|
-
var buttonGhost2 =
|
|
11578
|
+
var buttonGhost2 = import_react31.css`
|
|
11452
11579
|
background: transparent;
|
|
11453
11580
|
color: var(--brand-secondary-3);
|
|
11454
11581
|
|
|
@@ -11456,7 +11583,7 @@ var buttonGhost2 = import_react30.css`
|
|
|
11456
11583
|
border-color: var(--brand-secondary-3);
|
|
11457
11584
|
}
|
|
11458
11585
|
`;
|
|
11459
|
-
var buttonGhostDisabled =
|
|
11586
|
+
var buttonGhostDisabled = import_react31.css`
|
|
11460
11587
|
border-color: var(--gray-400);
|
|
11461
11588
|
color: var(--gray-400);
|
|
11462
11589
|
`;
|
|
@@ -11517,18 +11644,18 @@ var ButtonWithMenu = ({
|
|
|
11517
11644
|
};
|
|
11518
11645
|
|
|
11519
11646
|
// src/components/Callout/Callout.tsx
|
|
11520
|
-
var
|
|
11647
|
+
var import_react33 = require("@emotion/react");
|
|
11521
11648
|
|
|
11522
11649
|
// src/components/Callout/Callout.styles.ts
|
|
11523
|
-
var
|
|
11524
|
-
var calloutContainer =
|
|
11650
|
+
var import_react32 = require("@emotion/react");
|
|
11651
|
+
var calloutContainer = import_react32.css`
|
|
11525
11652
|
${functionalColors}
|
|
11526
11653
|
|
|
11527
11654
|
font-size: var(--fs-sm);
|
|
11528
11655
|
border-radius: var(--rounded-base);
|
|
11529
11656
|
padding: var(--spacing-base);
|
|
11530
11657
|
`;
|
|
11531
|
-
var calloutContainerCompact =
|
|
11658
|
+
var calloutContainerCompact = import_react32.css`
|
|
11532
11659
|
font-size: var(--fs-xs);
|
|
11533
11660
|
padding: var(--spacing-sm);
|
|
11534
11661
|
border-radius: 0 var(--rounded-base) var(--rounded-base) 0;
|
|
@@ -11540,25 +11667,25 @@ var calloutContainerCompact = import_react31.css`
|
|
|
11540
11667
|
--note-desc: var(--brand-secondary-1);
|
|
11541
11668
|
--success-desc: var(--brand-secondary-1);
|
|
11542
11669
|
`;
|
|
11543
|
-
var calloutInner =
|
|
11670
|
+
var calloutInner = import_react32.css`
|
|
11544
11671
|
display: flex;
|
|
11545
11672
|
gap: var(--spacing-sm);
|
|
11546
11673
|
`;
|
|
11547
|
-
var calloutBody =
|
|
11674
|
+
var calloutBody = import_react32.css`
|
|
11548
11675
|
display: flex;
|
|
11549
11676
|
flex-direction: column;
|
|
11550
11677
|
gap: var(--spacing-base);
|
|
11551
11678
|
`;
|
|
11552
|
-
var calloutBodyCompact =
|
|
11679
|
+
var calloutBodyCompact = import_react32.css`
|
|
11553
11680
|
gap: var(--spacing-xs);
|
|
11554
11681
|
`;
|
|
11555
|
-
var calloutIconWrap =
|
|
11682
|
+
var calloutIconWrap = import_react32.css`
|
|
11556
11683
|
flex-shrink: 0;
|
|
11557
11684
|
`;
|
|
11558
|
-
var calloutTitle =
|
|
11685
|
+
var calloutTitle = import_react32.css`
|
|
11559
11686
|
font-weight: var(--fw-bold);
|
|
11560
11687
|
`;
|
|
11561
|
-
var calloutIcon =
|
|
11688
|
+
var calloutIcon = import_react32.css`
|
|
11562
11689
|
width: 1.25rem;
|
|
11563
11690
|
height: 1.25rem;
|
|
11564
11691
|
`;
|
|
@@ -11692,91 +11819,91 @@ var import_jsx_runtime26 = require("@emotion/react/jsx-runtime");
|
|
|
11692
11819
|
var calloutTypeDataMap = {
|
|
11693
11820
|
caution: {
|
|
11694
11821
|
icon: CautionIcon,
|
|
11695
|
-
descriptionColor:
|
|
11822
|
+
descriptionColor: import_react33.css`
|
|
11696
11823
|
color: var(--caution-desc);
|
|
11697
11824
|
`,
|
|
11698
|
-
iconColor:
|
|
11825
|
+
iconColor: import_react33.css`
|
|
11699
11826
|
color: var(--caution-icon);
|
|
11700
11827
|
`,
|
|
11701
|
-
containerStyles:
|
|
11828
|
+
containerStyles: import_react33.css`
|
|
11702
11829
|
color: var(--caution-title);
|
|
11703
11830
|
background-color: var(--caution-container);
|
|
11704
11831
|
`
|
|
11705
11832
|
},
|
|
11706
11833
|
danger: {
|
|
11707
11834
|
icon: DangerIcon,
|
|
11708
|
-
descriptionColor:
|
|
11835
|
+
descriptionColor: import_react33.css`
|
|
11709
11836
|
color: var(--danger-desc);
|
|
11710
11837
|
`,
|
|
11711
|
-
iconColor:
|
|
11838
|
+
iconColor: import_react33.css`
|
|
11712
11839
|
color: var(--danger-icon);
|
|
11713
11840
|
`,
|
|
11714
|
-
containerStyles:
|
|
11841
|
+
containerStyles: import_react33.css`
|
|
11715
11842
|
color: var(--danger-title);
|
|
11716
11843
|
background-color: var(--danger-container);
|
|
11717
11844
|
`
|
|
11718
11845
|
},
|
|
11719
11846
|
error: {
|
|
11720
11847
|
icon: CautionIcon,
|
|
11721
|
-
descriptionColor:
|
|
11848
|
+
descriptionColor: import_react33.css`
|
|
11722
11849
|
color: var(--danger-desc);
|
|
11723
11850
|
`,
|
|
11724
|
-
iconColor:
|
|
11851
|
+
iconColor: import_react33.css`
|
|
11725
11852
|
color: var(--danger-icon);
|
|
11726
11853
|
`,
|
|
11727
|
-
containerStyles:
|
|
11854
|
+
containerStyles: import_react33.css`
|
|
11728
11855
|
color: var(--danger-title);
|
|
11729
11856
|
background-color: var(--danger-container);
|
|
11730
11857
|
`
|
|
11731
11858
|
},
|
|
11732
11859
|
info: {
|
|
11733
11860
|
icon: InfoIcon,
|
|
11734
|
-
descriptionColor:
|
|
11861
|
+
descriptionColor: import_react33.css`
|
|
11735
11862
|
color: var(--info-desc);
|
|
11736
11863
|
`,
|
|
11737
|
-
iconColor:
|
|
11864
|
+
iconColor: import_react33.css`
|
|
11738
11865
|
color: var(--info-icon);
|
|
11739
11866
|
`,
|
|
11740
|
-
containerStyles:
|
|
11867
|
+
containerStyles: import_react33.css`
|
|
11741
11868
|
color: var(--info-title);
|
|
11742
11869
|
background-color: var(--info-container);
|
|
11743
11870
|
`
|
|
11744
11871
|
},
|
|
11745
11872
|
note: {
|
|
11746
11873
|
icon: NoteIcon,
|
|
11747
|
-
descriptionColor:
|
|
11874
|
+
descriptionColor: import_react33.css`
|
|
11748
11875
|
color: var(--note-desc);
|
|
11749
11876
|
`,
|
|
11750
|
-
iconColor:
|
|
11877
|
+
iconColor: import_react33.css`
|
|
11751
11878
|
color: var(--note-icon);
|
|
11752
11879
|
`,
|
|
11753
|
-
containerStyles:
|
|
11880
|
+
containerStyles: import_react33.css`
|
|
11754
11881
|
color: var(--note-title);
|
|
11755
11882
|
background-color: var(--note-container);
|
|
11756
11883
|
`
|
|
11757
11884
|
},
|
|
11758
11885
|
success: {
|
|
11759
11886
|
icon: SuccessIcon,
|
|
11760
|
-
descriptionColor:
|
|
11887
|
+
descriptionColor: import_react33.css`
|
|
11761
11888
|
color: var(--success-desc);
|
|
11762
11889
|
`,
|
|
11763
|
-
iconColor:
|
|
11890
|
+
iconColor: import_react33.css`
|
|
11764
11891
|
color: var(--success-icon);
|
|
11765
11892
|
`,
|
|
11766
|
-
containerStyles:
|
|
11893
|
+
containerStyles: import_react33.css`
|
|
11767
11894
|
color: var(--success-title);
|
|
11768
11895
|
background-color: var(--success-container);
|
|
11769
11896
|
`
|
|
11770
11897
|
},
|
|
11771
11898
|
tip: {
|
|
11772
11899
|
icon: TipIcon,
|
|
11773
|
-
descriptionColor:
|
|
11900
|
+
descriptionColor: import_react33.css`
|
|
11774
11901
|
color: var(--success-desc);
|
|
11775
11902
|
`,
|
|
11776
|
-
iconColor:
|
|
11903
|
+
iconColor: import_react33.css`
|
|
11777
11904
|
color: var(--success-icon);
|
|
11778
11905
|
`,
|
|
11779
|
-
containerStyles:
|
|
11906
|
+
containerStyles: import_react33.css`
|
|
11780
11907
|
color: var(--success-title);
|
|
11781
11908
|
background-color: var(--success-container);
|
|
11782
11909
|
`
|
|
@@ -11821,8 +11948,8 @@ var Callout = ({
|
|
|
11821
11948
|
var import_cg7 = require("react-icons/cg");
|
|
11822
11949
|
|
|
11823
11950
|
// src/components/Card/Card.styles.ts
|
|
11824
|
-
var
|
|
11825
|
-
var CardContainer =
|
|
11951
|
+
var import_react34 = require("@emotion/react");
|
|
11952
|
+
var CardContainer = import_react34.css`
|
|
11826
11953
|
background: var(--white);
|
|
11827
11954
|
border: 1px solid var(--gray-300);
|
|
11828
11955
|
border-radius: var(--rounded-base);
|
|
@@ -11835,7 +11962,7 @@ var CardContainer = import_react33.css`
|
|
|
11835
11962
|
background: var(--gray-50);
|
|
11836
11963
|
}
|
|
11837
11964
|
`;
|
|
11838
|
-
var CardTitle = (marginBottom) =>
|
|
11965
|
+
var CardTitle = (marginBottom) => import_react34.css`
|
|
11839
11966
|
display: flex;
|
|
11840
11967
|
margin: ${marginBottom ? "0 0 var(--spacing-base)" : "0"};
|
|
11841
11968
|
padding-right: var(--spacing-lg);
|
|
@@ -11843,7 +11970,7 @@ var CardTitle = (marginBottom) => import_react33.css`
|
|
|
11843
11970
|
gap: var(--spacing-xs);
|
|
11844
11971
|
font-weight: var(--fw-regular);
|
|
11845
11972
|
`;
|
|
11846
|
-
var CardMenu =
|
|
11973
|
+
var CardMenu = import_react34.css`
|
|
11847
11974
|
align-items: center;
|
|
11848
11975
|
background: transparent;
|
|
11849
11976
|
color: var(--gray-300);
|
|
@@ -11906,12 +12033,12 @@ var CardTitle2 = ({ title, titleWithMarginBottom, children }) => {
|
|
|
11906
12033
|
};
|
|
11907
12034
|
|
|
11908
12035
|
// src/components/Card/CardContainer.styles.ts
|
|
11909
|
-
var
|
|
11910
|
-
var CardContainerWrapper = (bgColor) =>
|
|
12036
|
+
var import_react35 = require("@emotion/react");
|
|
12037
|
+
var CardContainerWrapper = (bgColor) => import_react35.css`
|
|
11911
12038
|
background: ${bgColor === "gray" ? `var(--gray-50)` : `var(--white)`};
|
|
11912
12039
|
container-type: inline-size;
|
|
11913
12040
|
`;
|
|
11914
|
-
var CardContainerInner = ({ padding, withLastColumn }) =>
|
|
12041
|
+
var CardContainerInner = ({ padding, withLastColumn }) => import_react35.css`
|
|
11915
12042
|
display: grid;
|
|
11916
12043
|
gap: var(--spacing-lg);
|
|
11917
12044
|
max-width: var(--site-width);
|
|
@@ -11940,8 +12067,8 @@ var CardContainer2 = ({
|
|
|
11940
12067
|
var import_cg8 = require("react-icons/cg");
|
|
11941
12068
|
|
|
11942
12069
|
// src/components/Layout/styles/Container.styles.ts
|
|
11943
|
-
var
|
|
11944
|
-
var Container = ({ backgroundColor, border, rounded, padding, margin }) =>
|
|
12070
|
+
var import_react36 = require("@emotion/react");
|
|
12071
|
+
var Container = ({ backgroundColor, border, rounded, padding, margin }) => import_react36.css`
|
|
11945
12072
|
background: var(--${backgroundColor});
|
|
11946
12073
|
${border ? "border: 1px solid var(--gray-300)" : void 0};
|
|
11947
12074
|
${rounded ? `border-radius: var(--${rounded})` : void 0};
|
|
@@ -11979,11 +12106,11 @@ var Container2 = ({
|
|
|
11979
12106
|
};
|
|
11980
12107
|
|
|
11981
12108
|
// src/components/Layout/HorizontalRhythm.tsx
|
|
11982
|
-
var
|
|
12109
|
+
var import_react38 = require("@emotion/react");
|
|
11983
12110
|
|
|
11984
12111
|
// src/components/Layout/styles/HorizontalRhythm.styles.ts
|
|
11985
|
-
var
|
|
11986
|
-
var HorizontalRhythmContainer = (size) =>
|
|
12112
|
+
var import_react37 = require("@emotion/react");
|
|
12113
|
+
var HorizontalRhythmContainer = (size) => import_react37.css`
|
|
11987
12114
|
display: flex;
|
|
11988
12115
|
gap: var(--spacing-${size});
|
|
11989
12116
|
`;
|
|
@@ -11997,7 +12124,7 @@ var HorizontalRhythm = ({ align, tag = "div", gap = "base", children, ...props }
|
|
|
11997
12124
|
{
|
|
11998
12125
|
css: [
|
|
11999
12126
|
HorizontalRhythmContainer(gap),
|
|
12000
|
-
align ?
|
|
12127
|
+
align ? import_react38.css`
|
|
12001
12128
|
align-items: ${align};
|
|
12002
12129
|
` : void 0
|
|
12003
12130
|
],
|
|
@@ -12008,11 +12135,11 @@ var HorizontalRhythm = ({ align, tag = "div", gap = "base", children, ...props }
|
|
|
12008
12135
|
};
|
|
12009
12136
|
|
|
12010
12137
|
// src/components/Layout/styles/TwoColumnLayout.styles.ts
|
|
12011
|
-
var
|
|
12012
|
-
var TwoColumnLayoutContainer = (bgColor) =>
|
|
12138
|
+
var import_react39 = require("@emotion/react");
|
|
12139
|
+
var TwoColumnLayoutContainer = (bgColor) => import_react39.css`
|
|
12013
12140
|
background: ${bgColor};
|
|
12014
12141
|
`;
|
|
12015
|
-
var TwoColumnLayoutInner = (invertLayout) =>
|
|
12142
|
+
var TwoColumnLayoutInner = (invertLayout) => import_react39.css`
|
|
12016
12143
|
display: grid;
|
|
12017
12144
|
max-width: var(--site-width);
|
|
12018
12145
|
margin-inline: auto;
|
|
@@ -12028,8 +12155,8 @@ var TwoColumnLayoutInner = (invertLayout) => import_react38.css`
|
|
|
12028
12155
|
}`}
|
|
12029
12156
|
}
|
|
12030
12157
|
`;
|
|
12031
|
-
var TwoColumnLayoutMain =
|
|
12032
|
-
var TwoColumnLayoutSupporting =
|
|
12158
|
+
var TwoColumnLayoutMain = import_react39.css``;
|
|
12159
|
+
var TwoColumnLayoutSupporting = import_react39.css`
|
|
12033
12160
|
display: flex;
|
|
12034
12161
|
flex-direction: column;
|
|
12035
12162
|
gap: var(--spacing-lg);
|
|
@@ -12050,11 +12177,11 @@ var TwoColumnLayout = ({
|
|
|
12050
12177
|
};
|
|
12051
12178
|
|
|
12052
12179
|
// src/components/Layout/VerticalRhythm.tsx
|
|
12053
|
-
var
|
|
12180
|
+
var import_react41 = require("@emotion/react");
|
|
12054
12181
|
|
|
12055
12182
|
// src/components/Layout/styles/VerticalRhythm.styles.ts
|
|
12056
|
-
var
|
|
12057
|
-
var VerticalRhythmContainer = (size) =>
|
|
12183
|
+
var import_react40 = require("@emotion/react");
|
|
12184
|
+
var VerticalRhythmContainer = (size) => import_react40.css`
|
|
12058
12185
|
display: flex;
|
|
12059
12186
|
flex-direction: column;
|
|
12060
12187
|
gap: var(--spacing-${size});
|
|
@@ -12069,7 +12196,7 @@ var VerticalRhythm = ({ align, tag = "div", gap = "base", children, ...props })
|
|
|
12069
12196
|
{
|
|
12070
12197
|
css: [
|
|
12071
12198
|
VerticalRhythmContainer(gap),
|
|
12072
|
-
align ?
|
|
12199
|
+
align ? import_react41.css`
|
|
12073
12200
|
align-items: ${align};
|
|
12074
12201
|
` : void 0
|
|
12075
12202
|
],
|
|
@@ -12080,8 +12207,8 @@ var VerticalRhythm = ({ align, tag = "div", gap = "base", children, ...props })
|
|
|
12080
12207
|
};
|
|
12081
12208
|
|
|
12082
12209
|
// src/components/Card/LoadingCardSkeleton.styles.ts
|
|
12083
|
-
var
|
|
12084
|
-
var LoadingCardSkeleton =
|
|
12210
|
+
var import_react42 = require("@emotion/react");
|
|
12211
|
+
var LoadingCardSkeleton = import_react42.css`
|
|
12085
12212
|
animation: ${skeletonLoading} 1s linear infinite alternate;
|
|
12086
12213
|
color: var(--gray-400);
|
|
12087
12214
|
border-radius: var(--rounded-base);
|
|
@@ -12089,21 +12216,21 @@ var LoadingCardSkeleton = import_react41.css`
|
|
|
12089
12216
|
min-height: 160px;
|
|
12090
12217
|
position: relative;
|
|
12091
12218
|
`;
|
|
12092
|
-
var LoadingText =
|
|
12219
|
+
var LoadingText = import_react42.css`
|
|
12093
12220
|
animation: ${fadeIn} 1s linear infinite alternate;
|
|
12094
12221
|
border-radius: var(--rounded-base);
|
|
12095
12222
|
background: var(--gray-300);
|
|
12096
12223
|
display: block;
|
|
12097
12224
|
`;
|
|
12098
|
-
var LoadingTitle =
|
|
12225
|
+
var LoadingTitle = import_react42.css`
|
|
12099
12226
|
width: clamp(200px, 100vw, 60%);
|
|
12100
12227
|
height: var(--spacing-md);
|
|
12101
12228
|
`;
|
|
12102
|
-
var LoadingTimeStamp =
|
|
12229
|
+
var LoadingTimeStamp = import_react42.css`
|
|
12103
12230
|
width: clamp(200px, 100vw, 30%);
|
|
12104
12231
|
height: var(--spacing-sm);
|
|
12105
12232
|
`;
|
|
12106
|
-
var LoadingMenuIcon =
|
|
12233
|
+
var LoadingMenuIcon = import_react42.css`
|
|
12107
12234
|
animation: ${fadeIn} 1s linear infinite alternate;
|
|
12108
12235
|
position: absolute;
|
|
12109
12236
|
top: var(--spacing-md);
|
|
@@ -12124,17 +12251,19 @@ var LoadingCardSkeleton2 = () => {
|
|
|
12124
12251
|
var import_cg9 = require("react-icons/cg");
|
|
12125
12252
|
|
|
12126
12253
|
// src/components/Chip/Chip.styles.ts
|
|
12127
|
-
var
|
|
12128
|
-
var ChipContainer =
|
|
12254
|
+
var import_react43 = require("@emotion/react");
|
|
12255
|
+
var ChipContainer = import_react43.css`
|
|
12129
12256
|
border-radius: var(--rounded-full);
|
|
12130
12257
|
background: lime;
|
|
12131
|
-
cursor: pointer;
|
|
12132
12258
|
display: inline-flex;
|
|
12133
|
-
gap: var(--spacing-sm);
|
|
12134
12259
|
transition: background var(--duration-fast) var(--timing-ease-out),
|
|
12135
12260
|
color var(--duration-fast) var(--timing-ease-out);
|
|
12136
12261
|
position: relative;
|
|
12137
12262
|
|
|
12263
|
+
[role='button'] {
|
|
12264
|
+
cursor: pointer;
|
|
12265
|
+
}
|
|
12266
|
+
|
|
12138
12267
|
&:hover {
|
|
12139
12268
|
[role='presentation'],
|
|
12140
12269
|
[role='separator'] {
|
|
@@ -12143,150 +12272,166 @@ var ChipContainer = import_react42.css`
|
|
|
12143
12272
|
}
|
|
12144
12273
|
}
|
|
12145
12274
|
`;
|
|
12146
|
-
var ChipText =
|
|
12275
|
+
var ChipText = import_react43.css`
|
|
12276
|
+
align-self: center;
|
|
12147
12277
|
line-height: 1;
|
|
12148
12278
|
`;
|
|
12149
|
-
var ChipIcon =
|
|
12150
|
-
align-
|
|
12279
|
+
var ChipIcon = import_react43.css`
|
|
12280
|
+
align-self: center;
|
|
12281
|
+
justify-content: center;
|
|
12151
12282
|
display: flex;
|
|
12152
12283
|
opacity: var(--opacity-50);
|
|
12153
12284
|
`;
|
|
12154
|
-
var ChipSeparator =
|
|
12285
|
+
var ChipSeparator = import_react43.css`
|
|
12155
12286
|
display: flex;
|
|
12156
12287
|
border-right: 1px solid var(--white);
|
|
12157
12288
|
opacity: var(--opacity-50);
|
|
12289
|
+
margin-left: -1px;
|
|
12158
12290
|
`;
|
|
12159
|
-
var ChipTiny =
|
|
12291
|
+
var ChipTiny = (withIcon) => import_react43.css`
|
|
12160
12292
|
font-size: var(--fs-xs);
|
|
12161
|
-
padding-inline: var(--spacing-sm);
|
|
12293
|
+
padding-inline: ${withIcon ? "calc(var(--spacing-2xs) + 2px) var(--spacing-sm)" : "var(--spacing-sm)"};
|
|
12294
|
+
gap: var(--spacing-2xs);
|
|
12162
12295
|
|
|
12163
12296
|
> :where(span:last-of-type) {
|
|
12164
|
-
padding
|
|
12297
|
+
padding: var(--spacing-xs) var(--spacing-xs);
|
|
12165
12298
|
}
|
|
12166
12299
|
`;
|
|
12167
|
-
var ChipSmall =
|
|
12300
|
+
var ChipSmall = import_react43.css`
|
|
12168
12301
|
font-size: var(--fs-sm);
|
|
12169
|
-
padding-inline: var(--spacing-
|
|
12302
|
+
padding-inline: var(--spacing-sm);
|
|
12303
|
+
gap: var(--spacing-xs);
|
|
12170
12304
|
|
|
12171
12305
|
> :where(span:last-of-type) {
|
|
12172
|
-
padding
|
|
12306
|
+
padding: var(--spacing-sm) var(--spacing-xs);
|
|
12173
12307
|
}
|
|
12174
12308
|
`;
|
|
12175
|
-
var ChipMedium =
|
|
12309
|
+
var ChipMedium = import_react43.css`
|
|
12176
12310
|
font-size: var(--fs-base);
|
|
12177
|
-
padding-inline: var(--spacing-
|
|
12311
|
+
padding-inline: var(--spacing-sm);
|
|
12312
|
+
gap: var(--spacing-xs);
|
|
12178
12313
|
|
|
12179
12314
|
> :where(span:last-of-type) {
|
|
12180
|
-
padding
|
|
12315
|
+
padding: var(--spacing-sm) var(--spacing-xs);
|
|
12181
12316
|
}
|
|
12182
12317
|
`;
|
|
12183
|
-
var ChipThemeAccentLight =
|
|
12318
|
+
var ChipThemeAccentLight = import_react43.css`
|
|
12184
12319
|
background: var(--accent-light);
|
|
12185
12320
|
color: var(--brand-secondary-1);
|
|
12186
12321
|
|
|
12187
|
-
|
|
12188
|
-
|
|
12189
|
-
|
|
12190
|
-
|
|
12322
|
+
:where([role='button']) {
|
|
12323
|
+
&:hover,
|
|
12324
|
+
&:focus {
|
|
12325
|
+
background: var(--accent-light-hover);
|
|
12326
|
+
}
|
|
12191
12327
|
|
|
12192
|
-
|
|
12193
|
-
|
|
12194
|
-
|
|
12328
|
+
&:active {
|
|
12329
|
+
background: var(--accent-light-active);
|
|
12330
|
+
}
|
|
12195
12331
|
|
|
12196
|
-
|
|
12197
|
-
|
|
12198
|
-
|
|
12199
|
-
|
|
12332
|
+
&:hover,
|
|
12333
|
+
&:focus,
|
|
12334
|
+
&:active {
|
|
12335
|
+
color: var(--white);
|
|
12336
|
+
}
|
|
12200
12337
|
}
|
|
12201
12338
|
|
|
12202
12339
|
[data-icon] {
|
|
12203
12340
|
color: var(--accent-light);
|
|
12204
12341
|
}
|
|
12205
12342
|
`;
|
|
12206
|
-
var ChipThemeAccentDark =
|
|
12343
|
+
var ChipThemeAccentDark = import_react43.css`
|
|
12207
12344
|
background: var(--accent-dark);
|
|
12208
12345
|
color: var(--white);
|
|
12209
12346
|
|
|
12210
|
-
|
|
12211
|
-
|
|
12212
|
-
|
|
12213
|
-
|
|
12347
|
+
:where([role='button']) {
|
|
12348
|
+
&:hover,
|
|
12349
|
+
&:focus {
|
|
12350
|
+
background: var(--accent-dark-hover);
|
|
12351
|
+
}
|
|
12214
12352
|
|
|
12215
|
-
|
|
12216
|
-
|
|
12217
|
-
|
|
12353
|
+
&:active {
|
|
12354
|
+
background: var(--accent-dark-active);
|
|
12355
|
+
}
|
|
12218
12356
|
|
|
12219
|
-
|
|
12220
|
-
|
|
12221
|
-
|
|
12222
|
-
|
|
12357
|
+
&:hover,
|
|
12358
|
+
&:focus,
|
|
12359
|
+
&:active {
|
|
12360
|
+
color: var(--white);
|
|
12361
|
+
}
|
|
12223
12362
|
}
|
|
12224
12363
|
`;
|
|
12225
|
-
var ChipAltThemeAccentLight =
|
|
12364
|
+
var ChipAltThemeAccentLight = import_react43.css`
|
|
12226
12365
|
background: var(--accent-alt-light);
|
|
12227
12366
|
color: var(--brand-secondary-1);
|
|
12228
12367
|
|
|
12229
|
-
|
|
12230
|
-
|
|
12231
|
-
|
|
12232
|
-
|
|
12368
|
+
:where([role='button']) {
|
|
12369
|
+
&:hover,
|
|
12370
|
+
&:focus {
|
|
12371
|
+
background: var(--accent-alt-light-hover);
|
|
12372
|
+
}
|
|
12233
12373
|
|
|
12234
|
-
|
|
12235
|
-
|
|
12236
|
-
|
|
12374
|
+
&:active {
|
|
12375
|
+
background: var(--accent-alt-light-active);
|
|
12376
|
+
}
|
|
12237
12377
|
|
|
12238
|
-
|
|
12239
|
-
|
|
12240
|
-
|
|
12241
|
-
|
|
12378
|
+
&:hover,
|
|
12379
|
+
&:focus,
|
|
12380
|
+
&:active {
|
|
12381
|
+
color: var(--white);
|
|
12382
|
+
}
|
|
12242
12383
|
}
|
|
12243
12384
|
|
|
12244
12385
|
[data-icon] {
|
|
12245
12386
|
color: var(--accent-alt-light);
|
|
12246
12387
|
}
|
|
12247
12388
|
`;
|
|
12248
|
-
var ChipAltThemeAccentDark =
|
|
12389
|
+
var ChipAltThemeAccentDark = import_react43.css`
|
|
12249
12390
|
background: var(--accent-alt-dark);
|
|
12250
12391
|
color: var(--white);
|
|
12251
12392
|
|
|
12252
|
-
|
|
12253
|
-
|
|
12254
|
-
|
|
12255
|
-
|
|
12393
|
+
:where([role='button']) {
|
|
12394
|
+
&:hover,
|
|
12395
|
+
&:focus {
|
|
12396
|
+
background: var(--accent-alt-dark-hover);
|
|
12397
|
+
}
|
|
12256
12398
|
|
|
12257
|
-
|
|
12258
|
-
|
|
12259
|
-
|
|
12399
|
+
&:active {
|
|
12400
|
+
background: var(--accent-alt-dark-active);
|
|
12401
|
+
}
|
|
12260
12402
|
|
|
12261
|
-
|
|
12262
|
-
|
|
12263
|
-
|
|
12264
|
-
|
|
12403
|
+
&:hover,
|
|
12404
|
+
&:focus,
|
|
12405
|
+
&:active {
|
|
12406
|
+
color: var(--white);
|
|
12407
|
+
}
|
|
12265
12408
|
}
|
|
12266
12409
|
`;
|
|
12267
|
-
var ChipThemeNeutralLight =
|
|
12410
|
+
var ChipThemeNeutralLight = import_react43.css`
|
|
12268
12411
|
background: var(--gray-100);
|
|
12269
12412
|
color: var(--brand-secondary-1);
|
|
12270
|
-
|
|
12271
|
-
|
|
12272
|
-
|
|
12273
|
-
|
|
12413
|
+
:where([role='button']) {
|
|
12414
|
+
&:active,
|
|
12415
|
+
&:focus {
|
|
12416
|
+
background: var(--gray-400);
|
|
12417
|
+
}
|
|
12274
12418
|
}
|
|
12275
12419
|
`;
|
|
12276
|
-
var ChipThemeNeutralDark =
|
|
12420
|
+
var ChipThemeNeutralDark = import_react43.css`
|
|
12277
12421
|
background: var(--gray-700);
|
|
12278
12422
|
color: var(--white);
|
|
12423
|
+
:where([role='button']) {
|
|
12424
|
+
&:hover,
|
|
12425
|
+
&:focus {
|
|
12426
|
+
background: var(--gray-600);
|
|
12427
|
+
}
|
|
12279
12428
|
|
|
12280
|
-
|
|
12281
|
-
|
|
12282
|
-
|
|
12283
|
-
}
|
|
12284
|
-
|
|
12285
|
-
&:active {
|
|
12286
|
-
background: var(--gray-900);
|
|
12429
|
+
&:active {
|
|
12430
|
+
background: var(--gray-900);
|
|
12431
|
+
}
|
|
12287
12432
|
}
|
|
12288
12433
|
`;
|
|
12289
|
-
var ChipActionButton =
|
|
12434
|
+
var ChipActionButton = import_react43.css`
|
|
12290
12435
|
background: transparent;
|
|
12291
12436
|
border: none;
|
|
12292
12437
|
border-radius: 0 var(--rounded-full) var(--rounded-full) 0;
|
|
@@ -12304,7 +12449,7 @@ var Chip = ({
|
|
|
12304
12449
|
...props
|
|
12305
12450
|
}) => {
|
|
12306
12451
|
const chipSize = {
|
|
12307
|
-
xs: ChipTiny,
|
|
12452
|
+
xs: ChipTiny(Boolean(icon)),
|
|
12308
12453
|
sm: ChipSmall,
|
|
12309
12454
|
md: ChipMedium
|
|
12310
12455
|
};
|
|
@@ -12318,7 +12463,7 @@ var Chip = ({
|
|
|
12318
12463
|
};
|
|
12319
12464
|
return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("span", { css: [ChipContainer, chipSize[size], chipTheme[theme]], ...props, children: [
|
|
12320
12465
|
icon ? /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(import_jsx_runtime34.Fragment, { children: [
|
|
12321
|
-
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { role: "presentation", css: ChipIcon, children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(Icon, { icon, iconColor: "currentColor", size: "
|
|
12466
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { role: "presentation", css: [ChipIcon], children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(Icon, { icon, iconColor: "currentColor", size: "1rem" }) }),
|
|
12322
12467
|
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { role: "separator", css: ChipSeparator })
|
|
12323
12468
|
] }) : null,
|
|
12324
12469
|
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { css: ChipText, children: text }),
|
|
@@ -12340,8 +12485,8 @@ var DismissibleChipAction = ({ onDismiss, ...props }) => {
|
|
|
12340
12485
|
};
|
|
12341
12486
|
|
|
12342
12487
|
// src/components/Counter/Counter.styles.ts
|
|
12343
|
-
var
|
|
12344
|
-
var counterContainer = (bgColor) =>
|
|
12488
|
+
var import_react44 = require("@emotion/react");
|
|
12489
|
+
var counterContainer = (bgColor) => import_react44.css`
|
|
12345
12490
|
align-items: center;
|
|
12346
12491
|
border-radius: var(--rounded-full);
|
|
12347
12492
|
border: 1px solid var(--gray-300);
|
|
@@ -12354,16 +12499,16 @@ var counterContainer = (bgColor) => import_react43.css`
|
|
|
12354
12499
|
width: var(--spacing-base);
|
|
12355
12500
|
height: var(--spacing-base);
|
|
12356
12501
|
`;
|
|
12357
|
-
var counterZeroValue =
|
|
12502
|
+
var counterZeroValue = import_react44.css`
|
|
12358
12503
|
background: var(--brand-secondary-1);
|
|
12359
12504
|
border-radius: var(--rounded-full);
|
|
12360
12505
|
width: 2px;
|
|
12361
12506
|
height: 2px;
|
|
12362
12507
|
`;
|
|
12363
|
-
var counterTripleValue =
|
|
12508
|
+
var counterTripleValue = import_react44.css`
|
|
12364
12509
|
position: relative;
|
|
12365
12510
|
`;
|
|
12366
|
-
var counterIcon =
|
|
12511
|
+
var counterIcon = import_react44.css`
|
|
12367
12512
|
border-radius: var(--rounded-full);
|
|
12368
12513
|
background: var(--white);
|
|
12369
12514
|
color: var(--brand-secondary-3);
|
|
@@ -12388,7 +12533,7 @@ var Counter = ({ count, bgColor = "transparent", ...props }) => {
|
|
|
12388
12533
|
};
|
|
12389
12534
|
|
|
12390
12535
|
// src/components/DashedBox/DashedBox.styles.ts
|
|
12391
|
-
var
|
|
12536
|
+
var import_react45 = require("@emotion/react");
|
|
12392
12537
|
var minHeight = (prop) => {
|
|
12393
12538
|
const values = {
|
|
12394
12539
|
auto: "auto",
|
|
@@ -12407,7 +12552,7 @@ var alignItemsConvert = (props) => {
|
|
|
12407
12552
|
};
|
|
12408
12553
|
return alignment[props];
|
|
12409
12554
|
};
|
|
12410
|
-
var DashedBoxContainer = ({ textAlign, boxHeight, bgColor }) =>
|
|
12555
|
+
var DashedBoxContainer = ({ textAlign, boxHeight, bgColor }) => import_react45.css`
|
|
12411
12556
|
align-items: ${alignItemsConvert(textAlign)};
|
|
12412
12557
|
border: 2px dashed var(--gray-300);
|
|
12413
12558
|
border-radius: var(--rounded-base);
|
|
@@ -12434,11 +12579,11 @@ var DashedBox = ({
|
|
|
12434
12579
|
};
|
|
12435
12580
|
|
|
12436
12581
|
// src/components/Details/Details.tsx
|
|
12437
|
-
var
|
|
12582
|
+
var React9 = __toESM(require("react"));
|
|
12438
12583
|
|
|
12439
12584
|
// src/components/Details/Details.styles.ts
|
|
12440
|
-
var
|
|
12441
|
-
var details =
|
|
12585
|
+
var import_react46 = require("@emotion/react");
|
|
12586
|
+
var details = import_react46.css`
|
|
12442
12587
|
cursor: pointer;
|
|
12443
12588
|
&[open] {
|
|
12444
12589
|
& > summary svg {
|
|
@@ -12446,11 +12591,11 @@ var details = import_react45.css`
|
|
|
12446
12591
|
}
|
|
12447
12592
|
}
|
|
12448
12593
|
`;
|
|
12449
|
-
var detailsContent =
|
|
12594
|
+
var detailsContent = import_react46.css`
|
|
12450
12595
|
animation: ${fadeInRtl} var(--duration-fast) var(--timing-ease-out) forwards;
|
|
12451
12596
|
will-change: height;
|
|
12452
12597
|
`;
|
|
12453
|
-
var summary =
|
|
12598
|
+
var summary = import_react46.css`
|
|
12454
12599
|
align-items: center;
|
|
12455
12600
|
display: grid;
|
|
12456
12601
|
grid-template-columns: 1.25rem 1fr;
|
|
@@ -12463,20 +12608,20 @@ var summary = import_react45.css`
|
|
|
12463
12608
|
display: none;
|
|
12464
12609
|
}
|
|
12465
12610
|
`;
|
|
12466
|
-
var summaryIcon =
|
|
12611
|
+
var summaryIcon = import_react46.css`
|
|
12467
12612
|
transition: rotate var(--duration-fast) var(--timing-ease-out);
|
|
12468
12613
|
rotate: -90deg;
|
|
12469
12614
|
`;
|
|
12470
|
-
var summaryIconVisiblyHidden =
|
|
12615
|
+
var summaryIconVisiblyHidden = import_react46.css`
|
|
12471
12616
|
visibility: hidden;
|
|
12472
12617
|
`;
|
|
12473
12618
|
|
|
12474
12619
|
// src/components/Details/Details.tsx
|
|
12475
12620
|
var import_jsx_runtime37 = require("@emotion/react/jsx-runtime");
|
|
12476
12621
|
var Details = ({ summary: summary2, children, isOpenByDefault = false, ...props }) => {
|
|
12477
|
-
const detailsRef =
|
|
12478
|
-
const [open, setOpen] =
|
|
12479
|
-
|
|
12622
|
+
const detailsRef = React9.useRef(null);
|
|
12623
|
+
const [open, setOpen] = React9.useState(isOpenByDefault);
|
|
12624
|
+
React9.useEffect(() => {
|
|
12480
12625
|
var _a;
|
|
12481
12626
|
if (!detailsRef) {
|
|
12482
12627
|
return;
|
|
@@ -12510,12 +12655,12 @@ var Details = ({ summary: summary2, children, isOpenByDefault = false, ...props
|
|
|
12510
12655
|
};
|
|
12511
12656
|
|
|
12512
12657
|
// src/components/Drawer/Drawer.tsx
|
|
12513
|
-
var
|
|
12658
|
+
var import_react50 = __toESM(require("react"));
|
|
12514
12659
|
var import_cg10 = require("react-icons/cg");
|
|
12515
12660
|
|
|
12516
12661
|
// src/components/Drawer/Drawer.styles.ts
|
|
12517
|
-
var
|
|
12518
|
-
var drawerStyles = (bgColor = "var(--white)") =>
|
|
12662
|
+
var import_react47 = require("@emotion/react");
|
|
12663
|
+
var drawerStyles = (bgColor = "var(--white)") => import_react47.css`
|
|
12519
12664
|
background-color: ${bgColor};
|
|
12520
12665
|
display: flex;
|
|
12521
12666
|
gap: var(--spacing-sm);
|
|
@@ -12525,7 +12670,7 @@ var drawerStyles = (bgColor = "var(--white)") => import_react46.css`
|
|
|
12525
12670
|
padding-top: var(--spacing-sm);
|
|
12526
12671
|
height: 100%;
|
|
12527
12672
|
`;
|
|
12528
|
-
var drawerCloseButtonStyles =
|
|
12673
|
+
var drawerCloseButtonStyles = import_react47.css`
|
|
12529
12674
|
align-self: flex-end;
|
|
12530
12675
|
background: transparent;
|
|
12531
12676
|
border: none;
|
|
@@ -12533,23 +12678,23 @@ var drawerCloseButtonStyles = import_react46.css`
|
|
|
12533
12678
|
padding: var(--spacing-xs);
|
|
12534
12679
|
margin-right: var(--spacing-sm);
|
|
12535
12680
|
`;
|
|
12536
|
-
var drawerHeaderStyles =
|
|
12681
|
+
var drawerHeaderStyles = import_react47.css`
|
|
12537
12682
|
font-size: var(--fs-lg);
|
|
12538
12683
|
font-weight: var(--fw-bold);
|
|
12539
12684
|
padding-inline: var(--spacing-base);
|
|
12540
12685
|
`;
|
|
12541
|
-
var drawerRendererStyles =
|
|
12686
|
+
var drawerRendererStyles = import_react47.css`
|
|
12542
12687
|
inset: 0;
|
|
12543
12688
|
overflow: hidden;
|
|
12544
12689
|
z-index: var(--z-drawer);
|
|
12545
12690
|
`;
|
|
12546
|
-
var drawerInnerStyles =
|
|
12691
|
+
var drawerInnerStyles = import_react47.css`
|
|
12547
12692
|
height: 100%;
|
|
12548
12693
|
padding: 0 var(--spacing-base) var(--spacing-base);
|
|
12549
12694
|
overflow: auto;
|
|
12550
12695
|
${scrollbarStyles}
|
|
12551
12696
|
`;
|
|
12552
|
-
var slideDrawerIn =
|
|
12697
|
+
var slideDrawerIn = import_react47.keyframes`
|
|
12553
12698
|
0% {
|
|
12554
12699
|
transform: translate(0);
|
|
12555
12700
|
opacity: 0;
|
|
@@ -12564,7 +12709,7 @@ var slideDrawerIn = import_react46.keyframes`
|
|
|
12564
12709
|
transform: translate(0);
|
|
12565
12710
|
}
|
|
12566
12711
|
`;
|
|
12567
|
-
var drawerWrapperStyles =
|
|
12712
|
+
var drawerWrapperStyles = import_react47.css`
|
|
12568
12713
|
position: absolute;
|
|
12569
12714
|
inset-block: 0;
|
|
12570
12715
|
right: 0;
|
|
@@ -12575,7 +12720,7 @@ var drawerWrapperStyles = import_react46.css`
|
|
|
12575
12720
|
transition: width var(--duration-fast) ease-out;
|
|
12576
12721
|
box-shadow: 0 0 10px 5px rgba(0, 0, 0, 0.1);
|
|
12577
12722
|
`;
|
|
12578
|
-
var drawerWrapperOverlayStyles =
|
|
12723
|
+
var drawerWrapperOverlayStyles = import_react47.css`
|
|
12579
12724
|
position: absolute;
|
|
12580
12725
|
inset: 0;
|
|
12581
12726
|
background: rgba(31, 43, 52, 0.4);
|
|
@@ -12583,9 +12728,9 @@ var drawerWrapperOverlayStyles = import_react46.css`
|
|
|
12583
12728
|
`;
|
|
12584
12729
|
|
|
12585
12730
|
// src/components/Drawer/DrawerProvider.tsx
|
|
12586
|
-
var
|
|
12731
|
+
var import_react48 = require("react");
|
|
12587
12732
|
var import_jsx_runtime38 = require("@emotion/react/jsx-runtime");
|
|
12588
|
-
var DrawerContext = (0,
|
|
12733
|
+
var DrawerContext = (0, import_react48.createContext)({
|
|
12589
12734
|
drawersRegistry: [],
|
|
12590
12735
|
registerDrawer: () => {
|
|
12591
12736
|
},
|
|
@@ -12593,7 +12738,7 @@ var DrawerContext = (0, import_react47.createContext)({
|
|
|
12593
12738
|
}
|
|
12594
12739
|
});
|
|
12595
12740
|
var DrawerProvider = ({ children }) => {
|
|
12596
|
-
const [drawersRegistry, setDrawersRegistry] = (0,
|
|
12741
|
+
const [drawersRegistry, setDrawersRegistry] = (0, import_react48.useState)([]);
|
|
12597
12742
|
useShortcut({
|
|
12598
12743
|
handler: () => {
|
|
12599
12744
|
var _a, _b;
|
|
@@ -12601,7 +12746,7 @@ var DrawerProvider = ({ children }) => {
|
|
|
12601
12746
|
},
|
|
12602
12747
|
shortcut: "escape"
|
|
12603
12748
|
});
|
|
12604
|
-
const registerDrawer = (0,
|
|
12749
|
+
const registerDrawer = (0, import_react48.useCallback)(
|
|
12605
12750
|
({ drawer, onFirstRender }) => {
|
|
12606
12751
|
setDrawersRegistry((currentValue) => {
|
|
12607
12752
|
var _a;
|
|
@@ -12623,7 +12768,7 @@ var DrawerProvider = ({ children }) => {
|
|
|
12623
12768
|
},
|
|
12624
12769
|
[setDrawersRegistry]
|
|
12625
12770
|
);
|
|
12626
|
-
const unregisterDrawer = (0,
|
|
12771
|
+
const unregisterDrawer = (0, import_react48.useCallback)(
|
|
12627
12772
|
(drawer) => {
|
|
12628
12773
|
setDrawersRegistry((currentValue) => {
|
|
12629
12774
|
return currentValue.filter((d) => {
|
|
@@ -12636,7 +12781,7 @@ var DrawerProvider = ({ children }) => {
|
|
|
12636
12781
|
return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(DrawerContext.Provider, { value: { drawersRegistry, registerDrawer, unregisterDrawer }, children });
|
|
12637
12782
|
};
|
|
12638
12783
|
var useDrawer = () => {
|
|
12639
|
-
return (0,
|
|
12784
|
+
return (0, import_react48.useContext)(DrawerContext);
|
|
12640
12785
|
};
|
|
12641
12786
|
var useCloseCurrentDrawer = () => {
|
|
12642
12787
|
const context = useDrawer();
|
|
@@ -12653,13 +12798,13 @@ function isEqualDrawerInstance(a, b) {
|
|
|
12653
12798
|
}
|
|
12654
12799
|
|
|
12655
12800
|
// src/components/Drawer/DrawerRenderer.tsx
|
|
12656
|
-
var
|
|
12801
|
+
var import_react49 = require("react");
|
|
12657
12802
|
var import_jsx_runtime39 = require("@emotion/react/jsx-runtime");
|
|
12658
12803
|
var maxLayeringInPx = 64;
|
|
12659
12804
|
var idealDistanceBetweenLayersInPx = 16;
|
|
12660
|
-
var CurrentDrawerRendererContext = (0,
|
|
12805
|
+
var CurrentDrawerRendererContext = (0, import_react49.createContext)({});
|
|
12661
12806
|
var useCurrentDrawerRenderer = () => {
|
|
12662
|
-
return (0,
|
|
12807
|
+
return (0, import_react49.useContext)(CurrentDrawerRendererContext);
|
|
12663
12808
|
};
|
|
12664
12809
|
var DrawerRenderer = ({
|
|
12665
12810
|
stackId,
|
|
@@ -12723,7 +12868,7 @@ var DrawerWrapper = ({
|
|
|
12723
12868
|
// src/components/Drawer/Drawer.tsx
|
|
12724
12869
|
var import_jsx_runtime40 = require("@emotion/react/jsx-runtime");
|
|
12725
12870
|
var defaultSackId = "_default";
|
|
12726
|
-
var Drawer =
|
|
12871
|
+
var Drawer = import_react50.default.forwardRef(
|
|
12727
12872
|
({ width, minWidth, maxWidth, position, ...drawerProps }, ref) => {
|
|
12728
12873
|
const drawerRendererProps = { width, minWidth, maxWidth, position };
|
|
12729
12874
|
const { stackId: inheritedStackId } = useCurrentDrawerRenderer();
|
|
@@ -12745,8 +12890,8 @@ var DrawerInner = ({
|
|
|
12745
12890
|
testId = "side-dialog"
|
|
12746
12891
|
}) => {
|
|
12747
12892
|
const { registerDrawer, unregisterDrawer } = useDrawer();
|
|
12748
|
-
const closeButtonRef = (0,
|
|
12749
|
-
const component = (0,
|
|
12893
|
+
const closeButtonRef = (0, import_react50.useRef)(null);
|
|
12894
|
+
const component = (0, import_react50.useMemo)(() => {
|
|
12750
12895
|
const headerId = `dialog-header-${stackId}-${id}`;
|
|
12751
12896
|
return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(
|
|
12752
12897
|
"div",
|
|
@@ -12777,7 +12922,7 @@ var DrawerInner = ({
|
|
|
12777
12922
|
}
|
|
12778
12923
|
);
|
|
12779
12924
|
}, [children, header, id, stackId, bgColor, onRequestClose, ref, testId]);
|
|
12780
|
-
(0,
|
|
12925
|
+
(0, import_react50.useEffect)(() => {
|
|
12781
12926
|
registerDrawer({
|
|
12782
12927
|
drawer: {
|
|
12783
12928
|
id,
|
|
@@ -12794,15 +12939,15 @@ var DrawerInner = ({
|
|
|
12794
12939
|
}
|
|
12795
12940
|
});
|
|
12796
12941
|
}, [component, instanceKey, registerDrawer]);
|
|
12797
|
-
(0,
|
|
12942
|
+
(0, import_react50.useEffect)(() => {
|
|
12798
12943
|
return () => unregisterDrawer({ id, stackId, instanceKey });
|
|
12799
12944
|
}, [id, stackId, instanceKey, unregisterDrawer]);
|
|
12800
12945
|
return null;
|
|
12801
12946
|
};
|
|
12802
12947
|
|
|
12803
12948
|
// src/components/Input/styles/CaptionText.styles.ts
|
|
12804
|
-
var
|
|
12805
|
-
var CaptionText = (dynamicSize) =>
|
|
12949
|
+
var import_react51 = require("@emotion/react");
|
|
12950
|
+
var CaptionText = (dynamicSize) => import_react51.css`
|
|
12806
12951
|
color: var(--gray-500);
|
|
12807
12952
|
display: block;
|
|
12808
12953
|
font-size: ${dynamicSize ? "clamp(var(--fs-xs), 87.5%,var(--fs-sm))" : "var(--fs-sm)"};
|
|
@@ -12817,23 +12962,23 @@ var Caption = ({ children, testId, dynamicSize = false, ...props }) => {
|
|
|
12817
12962
|
};
|
|
12818
12963
|
|
|
12819
12964
|
// src/components/Input/CheckboxWithInfo.tsx
|
|
12820
|
-
var
|
|
12965
|
+
var import_react53 = require("react");
|
|
12821
12966
|
|
|
12822
12967
|
// src/components/Input/styles/CheckboxWithInfo.styles.ts
|
|
12823
|
-
var
|
|
12824
|
-
var CheckboxWithInfoContainer =
|
|
12968
|
+
var import_react52 = require("@emotion/react");
|
|
12969
|
+
var CheckboxWithInfoContainer = import_react52.css`
|
|
12825
12970
|
align-items: center;
|
|
12826
12971
|
display: flex;
|
|
12827
12972
|
gap: var(--spacing-sm);
|
|
12828
12973
|
`;
|
|
12829
|
-
var CheckboxWithInfoLabel =
|
|
12974
|
+
var CheckboxWithInfoLabel = import_react52.css`
|
|
12830
12975
|
align-items: center;
|
|
12831
12976
|
color: var(--gray-500);
|
|
12832
12977
|
display: flex;
|
|
12833
12978
|
font-size: var(--fs-xs);
|
|
12834
12979
|
gap: var(--spacing-sm);
|
|
12835
12980
|
`;
|
|
12836
|
-
var CheckboxWithInfoInput =
|
|
12981
|
+
var CheckboxWithInfoInput = import_react52.css`
|
|
12837
12982
|
appearance: none;
|
|
12838
12983
|
border: 1px solid var(--gray-300);
|
|
12839
12984
|
background: var(--white) no-repeat bottom center;
|
|
@@ -12866,7 +13011,7 @@ var CheckboxWithInfoInput = import_react51.css`
|
|
|
12866
13011
|
border-color: var(--gray-200);
|
|
12867
13012
|
}
|
|
12868
13013
|
`;
|
|
12869
|
-
var InfoDialogContainer =
|
|
13014
|
+
var InfoDialogContainer = import_react52.css`
|
|
12870
13015
|
position: relative;
|
|
12871
13016
|
|
|
12872
13017
|
&:hover {
|
|
@@ -12875,7 +13020,7 @@ var InfoDialogContainer = import_react51.css`
|
|
|
12875
13020
|
}
|
|
12876
13021
|
}
|
|
12877
13022
|
`;
|
|
12878
|
-
var InfoDialogMessage =
|
|
13023
|
+
var InfoDialogMessage = import_react52.css`
|
|
12879
13024
|
background: var(--white);
|
|
12880
13025
|
box-shadow: var(--shadow-base);
|
|
12881
13026
|
border-radius: var(--rounded-md);
|
|
@@ -12899,7 +13044,7 @@ var InfoDialog = ({ message }) => {
|
|
|
12899
13044
|
/* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { role: "paragraph", css: InfoDialogMessage, className: "info-message", children: message })
|
|
12900
13045
|
] });
|
|
12901
13046
|
};
|
|
12902
|
-
var CheckboxWithInfo = (0,
|
|
13047
|
+
var CheckboxWithInfo = (0, import_react53.forwardRef)(
|
|
12903
13048
|
({ label, name, info, ...props }, ref) => {
|
|
12904
13049
|
return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { css: CheckboxWithInfoContainer, children: [
|
|
12905
13050
|
/* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("label", { css: CheckboxWithInfoLabel, children: [
|
|
@@ -12915,8 +13060,8 @@ var CheckboxWithInfo = (0, import_react52.forwardRef)(
|
|
|
12915
13060
|
var import_md2 = require("react-icons/md");
|
|
12916
13061
|
|
|
12917
13062
|
// src/components/Input/styles/ErrorMessage.styles.ts
|
|
12918
|
-
var
|
|
12919
|
-
var ErrorText =
|
|
13063
|
+
var import_react54 = require("@emotion/react");
|
|
13064
|
+
var ErrorText = import_react54.css`
|
|
12920
13065
|
align-items: center;
|
|
12921
13066
|
color: var(--brand-secondary-5);
|
|
12922
13067
|
display: flex;
|
|
@@ -12933,12 +13078,12 @@ var ErrorMessage = ({ message, testId, ...otherProps }) => {
|
|
|
12933
13078
|
};
|
|
12934
13079
|
|
|
12935
13080
|
// src/components/Input/Fieldset.tsx
|
|
12936
|
-
var
|
|
13081
|
+
var React13 = __toESM(require("react"));
|
|
12937
13082
|
|
|
12938
13083
|
// src/components/Input/styles/Fieldset.styles.ts
|
|
12939
|
-
var
|
|
13084
|
+
var import_react55 = require("@emotion/react");
|
|
12940
13085
|
function fieldsetContainer(invert) {
|
|
12941
|
-
const base =
|
|
13086
|
+
const base = import_react55.css`
|
|
12942
13087
|
border-radius: var(--rounded-base);
|
|
12943
13088
|
border: 1px solid var(--gray-300);
|
|
12944
13089
|
|
|
@@ -12950,18 +13095,18 @@ function fieldsetContainer(invert) {
|
|
|
12950
13095
|
}
|
|
12951
13096
|
`;
|
|
12952
13097
|
return invert ? [
|
|
12953
|
-
|
|
13098
|
+
import_react55.css`
|
|
12954
13099
|
background: white;
|
|
12955
13100
|
`,
|
|
12956
13101
|
base
|
|
12957
13102
|
] : [
|
|
12958
|
-
|
|
13103
|
+
import_react55.css`
|
|
12959
13104
|
background: var(--gray-50);
|
|
12960
13105
|
`,
|
|
12961
13106
|
base
|
|
12962
13107
|
];
|
|
12963
13108
|
}
|
|
12964
|
-
var fieldsetLegend =
|
|
13109
|
+
var fieldsetLegend = import_react55.css`
|
|
12965
13110
|
align-items: center;
|
|
12966
13111
|
color: var(--brand-secondary-1);
|
|
12967
13112
|
display: flex;
|
|
@@ -12971,13 +13116,13 @@ var fieldsetLegend = import_react54.css`
|
|
|
12971
13116
|
margin-bottom: var(--spacing-base);
|
|
12972
13117
|
float: left; // allows the legend to be inside the fieldset and not sat on the border line
|
|
12973
13118
|
`;
|
|
12974
|
-
var fieldsetBody =
|
|
13119
|
+
var fieldsetBody = import_react55.css`
|
|
12975
13120
|
clear: left;
|
|
12976
13121
|
`;
|
|
12977
13122
|
|
|
12978
13123
|
// src/components/Input/Fieldset.tsx
|
|
12979
13124
|
var import_jsx_runtime44 = require("@emotion/react/jsx-runtime");
|
|
12980
|
-
var Fieldset =
|
|
13125
|
+
var Fieldset = React13.forwardRef(
|
|
12981
13126
|
({ legend, disabled, children, invert, ...props }, ref) => {
|
|
12982
13127
|
return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)("fieldset", { css: fieldsetContainer(Boolean(invert)), ref, disabled, ...props, children: [
|
|
12983
13128
|
legend,
|
|
@@ -12990,8 +13135,8 @@ var Fieldset = React12.forwardRef(
|
|
|
12990
13135
|
var import_md3 = require("react-icons/md");
|
|
12991
13136
|
|
|
12992
13137
|
// src/components/Input/styles/InfoMessage.styles.tsx
|
|
12993
|
-
var
|
|
12994
|
-
var InfoText =
|
|
13138
|
+
var import_react56 = require("@emotion/react");
|
|
13139
|
+
var InfoText = import_react56.css`
|
|
12995
13140
|
--info-desc: rgb(29, 78, 216);
|
|
12996
13141
|
--info-icon: rgb(96, 165, 250);
|
|
12997
13142
|
|
|
@@ -13000,7 +13145,7 @@ var InfoText = import_react55.css`
|
|
|
13000
13145
|
display: flex;
|
|
13001
13146
|
gap: var(--spacing-sm);
|
|
13002
13147
|
`;
|
|
13003
|
-
var InfoIcon2 =
|
|
13148
|
+
var InfoIcon2 = import_react56.css`
|
|
13004
13149
|
color: var(--info-icon);
|
|
13005
13150
|
`;
|
|
13006
13151
|
|
|
@@ -13014,7 +13159,7 @@ var InfoMessage = ({ message, testId, ...props }) => {
|
|
|
13014
13159
|
};
|
|
13015
13160
|
|
|
13016
13161
|
// src/components/Input/Input.tsx
|
|
13017
|
-
var
|
|
13162
|
+
var React14 = __toESM(require("react"));
|
|
13018
13163
|
|
|
13019
13164
|
// src/components/Input/Label.tsx
|
|
13020
13165
|
var import_jsx_runtime46 = require("@emotion/react/jsx-runtime");
|
|
@@ -13035,14 +13180,14 @@ var Label = ({ children, className, testId, ...props }) => {
|
|
|
13035
13180
|
var import_md4 = require("react-icons/md");
|
|
13036
13181
|
|
|
13037
13182
|
// src/components/Input/styles/WarningMessage.styles.tsx
|
|
13038
|
-
var
|
|
13039
|
-
var WarningText =
|
|
13183
|
+
var import_react57 = require("@emotion/react");
|
|
13184
|
+
var WarningText = import_react57.css`
|
|
13040
13185
|
align-items: center;
|
|
13041
13186
|
color: var(--alert-text);
|
|
13042
13187
|
display: flex;
|
|
13043
13188
|
gap: var(--spacing-sm);
|
|
13044
13189
|
`;
|
|
13045
|
-
var WarningIcon =
|
|
13190
|
+
var WarningIcon = import_react57.css`
|
|
13046
13191
|
color: var(--alert);
|
|
13047
13192
|
`;
|
|
13048
13193
|
|
|
@@ -13057,7 +13202,7 @@ var WarningMessage = ({ message, testId, ...props }) => {
|
|
|
13057
13202
|
|
|
13058
13203
|
// src/components/Input/Input.tsx
|
|
13059
13204
|
var import_jsx_runtime48 = require("@emotion/react/jsx-runtime");
|
|
13060
|
-
var Input =
|
|
13205
|
+
var Input = React14.forwardRef(
|
|
13061
13206
|
({
|
|
13062
13207
|
label,
|
|
13063
13208
|
icon,
|
|
@@ -13253,17 +13398,17 @@ function InputComboBox(props) {
|
|
|
13253
13398
|
}
|
|
13254
13399
|
|
|
13255
13400
|
// src/components/Input/InputInlineSelect.tsx
|
|
13256
|
-
var
|
|
13257
|
-
var
|
|
13401
|
+
var import_react59 = require("@emotion/react");
|
|
13402
|
+
var import_react60 = require("react");
|
|
13258
13403
|
var import_cg11 = require("react-icons/cg");
|
|
13259
13404
|
|
|
13260
13405
|
// src/components/Input/styles/InputInlineSelect.styles.ts
|
|
13261
|
-
var
|
|
13262
|
-
var inlineSelectContainer =
|
|
13406
|
+
var import_react58 = require("@emotion/react");
|
|
13407
|
+
var inlineSelectContainer = import_react58.css`
|
|
13263
13408
|
margin-inline: auto;
|
|
13264
13409
|
max-width: fit-content;
|
|
13265
13410
|
`;
|
|
13266
|
-
var inlineSelectBtn =
|
|
13411
|
+
var inlineSelectBtn = import_react58.css`
|
|
13267
13412
|
align-items: center;
|
|
13268
13413
|
background: var(--brand-secondary-3);
|
|
13269
13414
|
border: 2px solid var(--brand-secondary-3);
|
|
@@ -13287,7 +13432,7 @@ var inlineSelectBtn = import_react57.css`
|
|
|
13287
13432
|
outline: 2px solid var(--brand-secondary-1);
|
|
13288
13433
|
}
|
|
13289
13434
|
`;
|
|
13290
|
-
var inlineSelectMenu =
|
|
13435
|
+
var inlineSelectMenu = import_react58.css`
|
|
13291
13436
|
background: var(--white);
|
|
13292
13437
|
border: 1px solid var(--brand-secondary-3);
|
|
13293
13438
|
border-top: none;
|
|
@@ -13298,7 +13443,7 @@ var inlineSelectMenu = import_react57.css`
|
|
|
13298
13443
|
inset: auto 0;
|
|
13299
13444
|
transform: translateY(-0.2rem);
|
|
13300
13445
|
`;
|
|
13301
|
-
var inlineSelectBtnOptions =
|
|
13446
|
+
var inlineSelectBtnOptions = import_react58.css`
|
|
13302
13447
|
cursor: pointer;
|
|
13303
13448
|
display: block;
|
|
13304
13449
|
font-size: var(--fs-sm);
|
|
@@ -13314,7 +13459,7 @@ var inlineSelectBtnOptions = import_react57.css`
|
|
|
13314
13459
|
background: var(--gray-50);
|
|
13315
13460
|
}
|
|
13316
13461
|
`;
|
|
13317
|
-
var inlineSelectMenuClosed =
|
|
13462
|
+
var inlineSelectMenuClosed = import_react58.css`
|
|
13318
13463
|
position: absolute;
|
|
13319
13464
|
overflow: hidden;
|
|
13320
13465
|
height: 1px;
|
|
@@ -13334,15 +13479,15 @@ var InputInlineSelect = ({
|
|
|
13334
13479
|
...props
|
|
13335
13480
|
}) => {
|
|
13336
13481
|
var _a;
|
|
13337
|
-
const [menuVisible, setMenuVisible] = (0,
|
|
13338
|
-
const divRef = (0,
|
|
13482
|
+
const [menuVisible, setMenuVisible] = (0, import_react60.useState)(false);
|
|
13483
|
+
const divRef = (0, import_react60.useRef)(null);
|
|
13339
13484
|
useOutsideClick(divRef, () => setMenuVisible(false));
|
|
13340
13485
|
const selected = options.find((option) => option.value === value);
|
|
13341
13486
|
return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
|
|
13342
13487
|
"div",
|
|
13343
13488
|
{
|
|
13344
13489
|
ref: divRef,
|
|
13345
|
-
css: !classNameContainer ? inlineSelectContainer :
|
|
13490
|
+
css: !classNameContainer ? inlineSelectContainer : import_react59.css`
|
|
13346
13491
|
max-width: fit-content;
|
|
13347
13492
|
${typeof classNameContainer === "object" ? classNameContainer : void 0}
|
|
13348
13493
|
`,
|
|
@@ -13495,9 +13640,9 @@ var InputSelect = ({
|
|
|
13495
13640
|
};
|
|
13496
13641
|
|
|
13497
13642
|
// src/components/Input/InputToggle.tsx
|
|
13498
|
-
var
|
|
13643
|
+
var React15 = __toESM(require("react"));
|
|
13499
13644
|
var import_jsx_runtime53 = require("@emotion/react/jsx-runtime");
|
|
13500
|
-
var InputToggle =
|
|
13645
|
+
var InputToggle = React15.forwardRef(
|
|
13501
13646
|
({
|
|
13502
13647
|
label,
|
|
13503
13648
|
type,
|
|
@@ -13511,26 +13656,33 @@ var InputToggle = React14.forwardRef(
|
|
|
13511
13656
|
fontWeight = "medium",
|
|
13512
13657
|
...props
|
|
13513
13658
|
}, ref) => {
|
|
13514
|
-
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
|
|
13515
|
-
|
|
13516
|
-
|
|
13517
|
-
|
|
13518
|
-
|
|
13519
|
-
|
|
13520
|
-
|
|
13521
|
-
|
|
13522
|
-
|
|
13523
|
-
|
|
13524
|
-
|
|
13525
|
-
|
|
13526
|
-
|
|
13527
|
-
|
|
13528
|
-
|
|
13529
|
-
|
|
13530
|
-
|
|
13531
|
-
|
|
13532
|
-
|
|
13533
|
-
|
|
13659
|
+
return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
|
|
13660
|
+
Label,
|
|
13661
|
+
{
|
|
13662
|
+
css: [inputToggleLabel, disabled ? inputDisabled : void 0],
|
|
13663
|
+
"data-test-id": testId ? testId : "input-toggle",
|
|
13664
|
+
children: [
|
|
13665
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
13666
|
+
"input",
|
|
13667
|
+
{
|
|
13668
|
+
ref,
|
|
13669
|
+
type,
|
|
13670
|
+
css: toggleInput,
|
|
13671
|
+
checked,
|
|
13672
|
+
name,
|
|
13673
|
+
disabled,
|
|
13674
|
+
...props
|
|
13675
|
+
}
|
|
13676
|
+
),
|
|
13677
|
+
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { css: inlineLabel(fontWeight), children: label }),
|
|
13678
|
+
caption || errorMessage ? /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("span", { css: inputToggleMessageContainer, children: [
|
|
13679
|
+
caption ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(Caption, { children: caption }) : null,
|
|
13680
|
+
errorMessage ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(ErrorMessage, { message: errorMessage }) : null,
|
|
13681
|
+
warningMessage && !errorMessage ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(WarningMessage, { message: warningMessage }) : null
|
|
13682
|
+
] }) : null
|
|
13683
|
+
]
|
|
13684
|
+
}
|
|
13685
|
+
);
|
|
13534
13686
|
}
|
|
13535
13687
|
);
|
|
13536
13688
|
|
|
@@ -13544,8 +13696,8 @@ var Legend = ({ children }) => {
|
|
|
13544
13696
|
var import_cg12 = require("react-icons/cg");
|
|
13545
13697
|
|
|
13546
13698
|
// src/components/Input/styles/SuccessMessage.styles.ts
|
|
13547
|
-
var
|
|
13548
|
-
var SuccessText =
|
|
13699
|
+
var import_react61 = require("@emotion/react");
|
|
13700
|
+
var SuccessText = import_react61.css`
|
|
13549
13701
|
--info-desc: var(--brand-secondary-3);
|
|
13550
13702
|
--info-icon: var(--brand-secondary-3);
|
|
13551
13703
|
|
|
@@ -13554,7 +13706,7 @@ var SuccessText = import_react60.css`
|
|
|
13554
13706
|
display: flex;
|
|
13555
13707
|
gap: var(--spacing-sm);
|
|
13556
13708
|
`;
|
|
13557
|
-
var SuccessIcon2 =
|
|
13709
|
+
var SuccessIcon2 = import_react61.css`
|
|
13558
13710
|
color: var(--info-icon);
|
|
13559
13711
|
`;
|
|
13560
13712
|
|
|
@@ -13600,7 +13752,7 @@ var Textarea = ({
|
|
|
13600
13752
|
};
|
|
13601
13753
|
|
|
13602
13754
|
// src/components/JsonEditor/JsonEditor.tsx
|
|
13603
|
-
var
|
|
13755
|
+
var import_react62 = __toESM(require("@monaco-editor/react"));
|
|
13604
13756
|
var import_jsx_runtime57 = require("@emotion/react/jsx-runtime");
|
|
13605
13757
|
var minEditorHeightPx = 150;
|
|
13606
13758
|
var JsonEditor = ({ defaultValue, onChange, jsonSchema, height, readOnly }) => {
|
|
@@ -13612,7 +13764,7 @@ var JsonEditor = ({ defaultValue, onChange, jsonSchema, height, readOnly }) => {
|
|
|
13612
13764
|
effectiveHeight = minEditorHeightPx;
|
|
13613
13765
|
}
|
|
13614
13766
|
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
13615
|
-
|
|
13767
|
+
import_react62.default,
|
|
13616
13768
|
{
|
|
13617
13769
|
height: effectiveHeight,
|
|
13618
13770
|
className: "uniform-json-editor",
|
|
@@ -13648,34 +13800,34 @@ var JsonEditor = ({ defaultValue, onChange, jsonSchema, height, readOnly }) => {
|
|
|
13648
13800
|
};
|
|
13649
13801
|
|
|
13650
13802
|
// src/components/LimitsBar/LimitsBar.styles.ts
|
|
13651
|
-
var
|
|
13652
|
-
var LimitsBarContainer =
|
|
13803
|
+
var import_react63 = require("@emotion/react");
|
|
13804
|
+
var LimitsBarContainer = import_react63.css`
|
|
13653
13805
|
margin-block: var(--spacing-sm);
|
|
13654
13806
|
`;
|
|
13655
|
-
var LimitsBarProgressBar =
|
|
13807
|
+
var LimitsBarProgressBar = import_react63.css`
|
|
13656
13808
|
background: var(--gray-100);
|
|
13657
13809
|
margin-top: var(--spacing-sm);
|
|
13658
13810
|
position: relative;
|
|
13659
13811
|
overflow: hidden;
|
|
13660
13812
|
height: 0.25rem;
|
|
13661
13813
|
`;
|
|
13662
|
-
var LimitsBarProgressBarLine =
|
|
13814
|
+
var LimitsBarProgressBarLine = import_react63.css`
|
|
13663
13815
|
position: absolute;
|
|
13664
13816
|
inset: 0;
|
|
13665
13817
|
transition: transform var(--duration-fast) var(--timing-ease-out);
|
|
13666
13818
|
`;
|
|
13667
|
-
var LimitsBarLabelContainer =
|
|
13819
|
+
var LimitsBarLabelContainer = import_react63.css`
|
|
13668
13820
|
display: flex;
|
|
13669
13821
|
justify-content: space-between;
|
|
13670
13822
|
font-weight: var(--fw-bold);
|
|
13671
13823
|
`;
|
|
13672
|
-
var LimitsBarLabel =
|
|
13824
|
+
var LimitsBarLabel = import_react63.css`
|
|
13673
13825
|
font-size: var(--fs-baase);
|
|
13674
13826
|
`;
|
|
13675
|
-
var LimitsBarBgColor = (statusColor) =>
|
|
13827
|
+
var LimitsBarBgColor = (statusColor) => import_react63.css`
|
|
13676
13828
|
background: ${statusColor};
|
|
13677
13829
|
`;
|
|
13678
|
-
var LimitsBarTextColor = (statusColor) =>
|
|
13830
|
+
var LimitsBarTextColor = (statusColor) => import_react63.css`
|
|
13679
13831
|
color: ${statusColor};
|
|
13680
13832
|
`;
|
|
13681
13833
|
|
|
@@ -13725,8 +13877,8 @@ var LimitsBar = ({ current, max, label }) => {
|
|
|
13725
13877
|
};
|
|
13726
13878
|
|
|
13727
13879
|
// src/components/LinkList/LinkList.styles.ts
|
|
13728
|
-
var
|
|
13729
|
-
var LinkListContainer = (padding) =>
|
|
13880
|
+
var import_react64 = require("@emotion/react");
|
|
13881
|
+
var LinkListContainer = (padding) => import_react64.css`
|
|
13730
13882
|
padding: ${padding};
|
|
13731
13883
|
|
|
13732
13884
|
${mq("sm")} {
|
|
@@ -13734,7 +13886,7 @@ var LinkListContainer = (padding) => import_react63.css`
|
|
|
13734
13886
|
grid-row: 1 / last-line;
|
|
13735
13887
|
}
|
|
13736
13888
|
`;
|
|
13737
|
-
var LinkListTitle =
|
|
13889
|
+
var LinkListTitle = import_react64.css`
|
|
13738
13890
|
font-weight: var(--fw-bold);
|
|
13739
13891
|
font-size: var(--fs-sm);
|
|
13740
13892
|
text-transform: uppercase;
|
|
@@ -13750,14 +13902,14 @@ var LinkList = ({ title, padding = "var(--spacing-md)", children, ...props }) =>
|
|
|
13750
13902
|
};
|
|
13751
13903
|
|
|
13752
13904
|
// src/components/List/ScrollableList.tsx
|
|
13753
|
-
var
|
|
13905
|
+
var import_react66 = require("@emotion/react");
|
|
13754
13906
|
|
|
13755
13907
|
// src/components/List/styles/ScrollableList.styles.ts
|
|
13756
|
-
var
|
|
13757
|
-
var ScrollableListContainer =
|
|
13908
|
+
var import_react65 = require("@emotion/react");
|
|
13909
|
+
var ScrollableListContainer = import_react65.css`
|
|
13758
13910
|
position: relative;
|
|
13759
13911
|
`;
|
|
13760
|
-
var ScrollableListInner =
|
|
13912
|
+
var ScrollableListInner = import_react65.css`
|
|
13761
13913
|
background: var(--gray-50);
|
|
13762
13914
|
border-top: 1px solid var(--gray-200);
|
|
13763
13915
|
border-bottom: 1px solid var(--gray-200);
|
|
@@ -13786,7 +13938,7 @@ var ScrollableList = ({ label, children, ...props }) => {
|
|
|
13786
13938
|
label ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
|
|
13787
13939
|
"span",
|
|
13788
13940
|
{
|
|
13789
|
-
css:
|
|
13941
|
+
css: import_react66.css`
|
|
13790
13942
|
${labelText}
|
|
13791
13943
|
`,
|
|
13792
13944
|
children: label
|
|
@@ -13800,8 +13952,8 @@ var ScrollableList = ({ label, children, ...props }) => {
|
|
|
13800
13952
|
var import_cg13 = require("react-icons/cg");
|
|
13801
13953
|
|
|
13802
13954
|
// src/components/List/styles/ScrollableListItem.styles.ts
|
|
13803
|
-
var
|
|
13804
|
-
var ScrollableListItemContainer =
|
|
13955
|
+
var import_react67 = require("@emotion/react");
|
|
13956
|
+
var ScrollableListItemContainer = import_react67.css`
|
|
13805
13957
|
align-items: center;
|
|
13806
13958
|
background: var(--white);
|
|
13807
13959
|
border-radius: var(--rounded-base);
|
|
@@ -13810,13 +13962,13 @@ var ScrollableListItemContainer = import_react66.css`
|
|
|
13810
13962
|
min-height: 52px;
|
|
13811
13963
|
transition: border-color var(--duration-fast) var(--timing-ease-out);
|
|
13812
13964
|
`;
|
|
13813
|
-
var ScrollableListItemShadow =
|
|
13965
|
+
var ScrollableListItemShadow = import_react67.css`
|
|
13814
13966
|
box-shadow: var(--shadow-base);
|
|
13815
13967
|
`;
|
|
13816
|
-
var ScrollableListItemActive =
|
|
13968
|
+
var ScrollableListItemActive = import_react67.css`
|
|
13817
13969
|
border-color: var(--brand-secondary-3);
|
|
13818
13970
|
`;
|
|
13819
|
-
var ScrollableListItemBtn =
|
|
13971
|
+
var ScrollableListItemBtn = import_react67.css`
|
|
13820
13972
|
align-items: center;
|
|
13821
13973
|
border: none;
|
|
13822
13974
|
background: transparent;
|
|
@@ -13831,27 +13983,27 @@ var ScrollableListItemBtn = import_react66.css`
|
|
|
13831
13983
|
outline: none;
|
|
13832
13984
|
}
|
|
13833
13985
|
`;
|
|
13834
|
-
var ScrollableListInputLabel =
|
|
13986
|
+
var ScrollableListInputLabel = import_react67.css`
|
|
13835
13987
|
align-items: center;
|
|
13836
13988
|
cursor: pointer;
|
|
13837
13989
|
display: flex;
|
|
13838
13990
|
padding: var(--spacing-xs) var(--spacing-base) var(--spacing-xs);
|
|
13839
13991
|
flex-grow: 1;
|
|
13840
13992
|
`;
|
|
13841
|
-
var ScrollableListInputText =
|
|
13993
|
+
var ScrollableListInputText = import_react67.css`
|
|
13842
13994
|
align-items: center;
|
|
13843
13995
|
display: flex;
|
|
13844
13996
|
gap: var(--spacing-sm);
|
|
13845
13997
|
flex-grow: 1;
|
|
13846
13998
|
flex-wrap: wrap;
|
|
13847
13999
|
`;
|
|
13848
|
-
var ScrollableListHiddenInput =
|
|
14000
|
+
var ScrollableListHiddenInput = import_react67.css`
|
|
13849
14001
|
position: absolute;
|
|
13850
14002
|
height: 0;
|
|
13851
14003
|
width: 0;
|
|
13852
14004
|
opacity: 0;
|
|
13853
14005
|
`;
|
|
13854
|
-
var ScrollableListIcon =
|
|
14006
|
+
var ScrollableListIcon = import_react67.css`
|
|
13855
14007
|
border-radius: var(--rounded-full);
|
|
13856
14008
|
background: var(--brand-secondary-3);
|
|
13857
14009
|
color: var(--white);
|
|
@@ -13859,7 +14011,7 @@ var ScrollableListIcon = import_react66.css`
|
|
|
13859
14011
|
min-width: 24px;
|
|
13860
14012
|
opacity: 0;
|
|
13861
14013
|
`;
|
|
13862
|
-
var ScrollableListIconVisible =
|
|
14014
|
+
var ScrollableListIconVisible = import_react67.css`
|
|
13863
14015
|
animation: ${fadeInBottom} var(--duration-fast) var(--timing-ease-out) forwards;
|
|
13864
14016
|
`;
|
|
13865
14017
|
|
|
@@ -13939,8 +14091,8 @@ var ScrollableListItem = ({
|
|
|
13939
14091
|
};
|
|
13940
14092
|
|
|
13941
14093
|
// src/components/LoadingIndicator/LoadingIndicator.styles.ts
|
|
13942
|
-
var
|
|
13943
|
-
var bounceFade =
|
|
14094
|
+
var import_react68 = require("@emotion/react");
|
|
14095
|
+
var bounceFade = import_react68.keyframes`
|
|
13944
14096
|
0%, 100% {
|
|
13945
14097
|
opacity: 1.0;
|
|
13946
14098
|
transform: translateY(0);
|
|
@@ -13957,11 +14109,11 @@ var bounceFade = import_react67.keyframes`
|
|
|
13957
14109
|
transform: translateY(-5px);
|
|
13958
14110
|
}
|
|
13959
14111
|
`;
|
|
13960
|
-
var loader =
|
|
14112
|
+
var loader = import_react68.css`
|
|
13961
14113
|
display: inline-flex;
|
|
13962
14114
|
justify-content: center;
|
|
13963
14115
|
`;
|
|
13964
|
-
var loadingDot =
|
|
14116
|
+
var loadingDot = import_react68.css`
|
|
13965
14117
|
background-color: var(--gray-700);
|
|
13966
14118
|
display: block;
|
|
13967
14119
|
border-radius: var(--rounded-full);
|
|
@@ -13995,11 +14147,11 @@ var LoadingIndicator = ({ ...props }) => {
|
|
|
13995
14147
|
};
|
|
13996
14148
|
|
|
13997
14149
|
// src/components/LoadingOverlay/LoadingOverlay.tsx
|
|
13998
|
-
var
|
|
14150
|
+
var import_react70 = require("react");
|
|
13999
14151
|
|
|
14000
14152
|
// src/components/LoadingOverlay/LoadingOverlay.styles.ts
|
|
14001
|
-
var
|
|
14002
|
-
var loadingOverlayContainer =
|
|
14153
|
+
var import_react69 = require("@emotion/react");
|
|
14154
|
+
var loadingOverlayContainer = import_react69.css`
|
|
14003
14155
|
position: absolute;
|
|
14004
14156
|
inset: 0;
|
|
14005
14157
|
overflow: hidden;
|
|
@@ -14007,24 +14159,24 @@ var loadingOverlayContainer = import_react68.css`
|
|
|
14007
14159
|
padding: var(--spacing-xl);
|
|
14008
14160
|
overflow-y: auto;
|
|
14009
14161
|
`;
|
|
14010
|
-
var loadingOverlayVisible =
|
|
14162
|
+
var loadingOverlayVisible = import_react69.css`
|
|
14011
14163
|
display: flex;
|
|
14012
14164
|
`;
|
|
14013
|
-
var loadingOverlayHidden =
|
|
14165
|
+
var loadingOverlayHidden = import_react69.css`
|
|
14014
14166
|
display: none;
|
|
14015
14167
|
`;
|
|
14016
|
-
var loadingOverlayBackground = (bgColor) =>
|
|
14168
|
+
var loadingOverlayBackground = (bgColor) => import_react69.css`
|
|
14017
14169
|
background: ${bgColor};
|
|
14018
14170
|
opacity: 0.92;
|
|
14019
14171
|
position: absolute;
|
|
14020
14172
|
inset: 0 0;
|
|
14021
14173
|
`;
|
|
14022
|
-
var loadingOverlayBody =
|
|
14174
|
+
var loadingOverlayBody = import_react69.css`
|
|
14023
14175
|
align-items: center;
|
|
14024
14176
|
display: flex;
|
|
14025
14177
|
flex-direction: column;
|
|
14026
14178
|
`;
|
|
14027
|
-
var loadingOverlayMessage =
|
|
14179
|
+
var loadingOverlayMessage = import_react69.css`
|
|
14028
14180
|
color: var(--gray-600);
|
|
14029
14181
|
margin: var(--spacing-base) 0 0;
|
|
14030
14182
|
`;
|
|
@@ -14041,14 +14193,14 @@ var LoadingOverlay = ({
|
|
|
14041
14193
|
isPaused = false,
|
|
14042
14194
|
children
|
|
14043
14195
|
}) => {
|
|
14044
|
-
const lottieRef = (0,
|
|
14045
|
-
const onLoopComplete = (0,
|
|
14196
|
+
const lottieRef = (0, import_react70.useRef)(null);
|
|
14197
|
+
const onLoopComplete = (0, import_react70.useCallback)(() => {
|
|
14046
14198
|
var _a, _b, _c;
|
|
14047
14199
|
if (isPaused && !((_b = (_a = lottieRef.current) == null ? void 0 : _a.animationItem) == null ? void 0 : _b.isPaused)) {
|
|
14048
14200
|
(_c = lottieRef.current) == null ? void 0 : _c.stop();
|
|
14049
14201
|
}
|
|
14050
14202
|
}, [isPaused]);
|
|
14051
|
-
(0,
|
|
14203
|
+
(0, import_react70.useEffect)(() => {
|
|
14052
14204
|
var _a, _b, _c, _d, _e, _f;
|
|
14053
14205
|
if (!isPaused && ((_b = (_a = lottieRef.current) == null ? void 0 : _a.animationItem) == null ? void 0 : _b.isPaused)) {
|
|
14054
14206
|
(_c = lottieRef.current) == null ? void 0 : _c.play();
|
|
@@ -14119,12 +14271,12 @@ var LoadingIcon = ({ height, width, ...props }) => {
|
|
|
14119
14271
|
};
|
|
14120
14272
|
|
|
14121
14273
|
// src/components/Tiles/CreateTeamIntegrationTile.tsx
|
|
14122
|
-
var
|
|
14274
|
+
var import_react72 = require("@emotion/react");
|
|
14123
14275
|
var import_cg15 = require("react-icons/cg");
|
|
14124
14276
|
|
|
14125
14277
|
// src/components/Tiles/styles/IntegrationTile.styles.ts
|
|
14126
|
-
var
|
|
14127
|
-
var IntegrationTileContainer =
|
|
14278
|
+
var import_react71 = require("@emotion/react");
|
|
14279
|
+
var IntegrationTileContainer = import_react71.css`
|
|
14128
14280
|
align-items: center;
|
|
14129
14281
|
box-sizing: border-box;
|
|
14130
14282
|
border-radius: var(--rounded-base);
|
|
@@ -14155,22 +14307,22 @@ var IntegrationTileContainer = import_react70.css`
|
|
|
14155
14307
|
}
|
|
14156
14308
|
}
|
|
14157
14309
|
`;
|
|
14158
|
-
var IntegrationTileBtnDashedBorder =
|
|
14310
|
+
var IntegrationTileBtnDashedBorder = import_react71.css`
|
|
14159
14311
|
border: 1px dashed var(--brand-secondary-1);
|
|
14160
14312
|
`;
|
|
14161
|
-
var IntegrationTileTitle =
|
|
14313
|
+
var IntegrationTileTitle = import_react71.css`
|
|
14162
14314
|
display: block;
|
|
14163
14315
|
font-weight: var(--fw-bold);
|
|
14164
14316
|
margin: 0 0 var(--spacing-base);
|
|
14165
14317
|
max-width: 13rem;
|
|
14166
14318
|
`;
|
|
14167
|
-
var IntegrationTitleLogo =
|
|
14319
|
+
var IntegrationTitleLogo = import_react71.css`
|
|
14168
14320
|
display: block;
|
|
14169
14321
|
max-width: 10rem;
|
|
14170
14322
|
max-height: 4rem;
|
|
14171
14323
|
margin: 0 auto;
|
|
14172
14324
|
`;
|
|
14173
|
-
var IntegrationTileName =
|
|
14325
|
+
var IntegrationTileName = import_react71.css`
|
|
14174
14326
|
color: var(--gray-500);
|
|
14175
14327
|
display: -webkit-box;
|
|
14176
14328
|
-webkit-line-clamp: 1;
|
|
@@ -14183,7 +14335,7 @@ var IntegrationTileName = import_react70.css`
|
|
|
14183
14335
|
position: absolute;
|
|
14184
14336
|
bottom: calc(var(--spacing-base) * 3.8);
|
|
14185
14337
|
`;
|
|
14186
|
-
var IntegrationAddedText =
|
|
14338
|
+
var IntegrationAddedText = import_react71.css`
|
|
14187
14339
|
align-items: center;
|
|
14188
14340
|
background: var(--brand-secondary-3);
|
|
14189
14341
|
border-radius: 0 var(--rounded-md) 0 var(--rounded-md);
|
|
@@ -14198,7 +14350,7 @@ var IntegrationAddedText = import_react70.css`
|
|
|
14198
14350
|
top: 0;
|
|
14199
14351
|
right: 0;
|
|
14200
14352
|
`;
|
|
14201
|
-
var IntegrationCustomBadgeText = (theme) =>
|
|
14353
|
+
var IntegrationCustomBadgeText = (theme) => import_react71.css`
|
|
14202
14354
|
align-items: center;
|
|
14203
14355
|
border-radius: var(--rounded-sm) 0 var(--rounded-sm) 0;
|
|
14204
14356
|
background: ${theme === "gray" ? "var(--brand-secondary-2)" : "var(--brand-secondary-1)"};
|
|
@@ -14212,26 +14364,26 @@ var IntegrationCustomBadgeText = (theme) => import_react70.css`
|
|
|
14212
14364
|
top: 0;
|
|
14213
14365
|
left: 0;
|
|
14214
14366
|
`;
|
|
14215
|
-
var IntegrationAuthorBadgeIcon =
|
|
14367
|
+
var IntegrationAuthorBadgeIcon = import_react71.css`
|
|
14216
14368
|
position: absolute;
|
|
14217
14369
|
bottom: var(--spacing-sm);
|
|
14218
14370
|
right: var(--spacing-xs);
|
|
14219
14371
|
max-height: 1rem;
|
|
14220
14372
|
`;
|
|
14221
|
-
var IntegrationTitleFakeButton =
|
|
14373
|
+
var IntegrationTitleFakeButton = import_react71.css`
|
|
14222
14374
|
font-size: var(--fs-xs);
|
|
14223
14375
|
gap: var(--spacing-sm);
|
|
14224
14376
|
padding: var(--spacing-sm) var(--spacing-base);
|
|
14225
14377
|
text-transform: uppercase;
|
|
14226
14378
|
`;
|
|
14227
|
-
var IntegrationTileFloatingButton =
|
|
14379
|
+
var IntegrationTileFloatingButton = import_react71.css`
|
|
14228
14380
|
position: absolute;
|
|
14229
14381
|
bottom: var(--spacing-base);
|
|
14230
14382
|
gap: var(--spacing-sm);
|
|
14231
14383
|
font-size: var(--fs-xs);
|
|
14232
14384
|
overflow: hidden;
|
|
14233
14385
|
`;
|
|
14234
|
-
var IntegrationTileFloatingButtonMessage = (clicked) =>
|
|
14386
|
+
var IntegrationTileFloatingButtonMessage = (clicked) => import_react71.css`
|
|
14235
14387
|
strong,
|
|
14236
14388
|
span:first-of-type {
|
|
14237
14389
|
transition: opacity var(--duration-fast) var(--timing-ease-out);
|
|
@@ -14278,7 +14430,7 @@ var CreateTeamIntegrationTile = ({
|
|
|
14278
14430
|
icon: import_cg15.CgChevronRight,
|
|
14279
14431
|
iconColor: "currentColor",
|
|
14280
14432
|
size: 20,
|
|
14281
|
-
css:
|
|
14433
|
+
css: import_react72.css`
|
|
14282
14434
|
order: 1;
|
|
14283
14435
|
`
|
|
14284
14436
|
}
|
|
@@ -14288,7 +14440,7 @@ var CreateTeamIntegrationTile = ({
|
|
|
14288
14440
|
icon: import_cg15.CgAdd,
|
|
14289
14441
|
iconColor: "currentColor",
|
|
14290
14442
|
size: 16,
|
|
14291
|
-
css:
|
|
14443
|
+
css: import_react72.css`
|
|
14292
14444
|
order: -1;
|
|
14293
14445
|
`
|
|
14294
14446
|
}
|
|
@@ -14376,8 +14528,8 @@ var EditTeamIntegrationTile = ({
|
|
|
14376
14528
|
};
|
|
14377
14529
|
|
|
14378
14530
|
// src/components/Tiles/IntegrationComingSoon.tsx
|
|
14379
|
-
var
|
|
14380
|
-
var
|
|
14531
|
+
var import_react73 = require("@emotion/react");
|
|
14532
|
+
var import_react74 = require("react");
|
|
14381
14533
|
var import_cg17 = require("react-icons/cg");
|
|
14382
14534
|
var import_jsx_runtime69 = require("@emotion/react/jsx-runtime");
|
|
14383
14535
|
var IntegrationComingSoon = ({
|
|
@@ -14388,12 +14540,12 @@ var IntegrationComingSoon = ({
|
|
|
14388
14540
|
timing = 1e3,
|
|
14389
14541
|
...props
|
|
14390
14542
|
}) => {
|
|
14391
|
-
const [upVote, setUpVote] = (0,
|
|
14543
|
+
const [upVote, setUpVote] = (0, import_react74.useState)(false);
|
|
14392
14544
|
const handleUpVoteInteraction = () => {
|
|
14393
14545
|
setUpVote((prev) => !prev);
|
|
14394
14546
|
onUpVoteClick();
|
|
14395
14547
|
};
|
|
14396
|
-
(0,
|
|
14548
|
+
(0, import_react74.useEffect)(() => {
|
|
14397
14549
|
if (upVote) {
|
|
14398
14550
|
const timer = setTimeout(() => setUpVote(false), timing);
|
|
14399
14551
|
return () => {
|
|
@@ -14425,7 +14577,7 @@ var IntegrationComingSoon = ({
|
|
|
14425
14577
|
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
14426
14578
|
"span",
|
|
14427
14579
|
{
|
|
14428
|
-
css:
|
|
14580
|
+
css: import_react73.css`
|
|
14429
14581
|
text-transform: uppercase;
|
|
14430
14582
|
color: var(--gray-500);
|
|
14431
14583
|
`,
|
|
@@ -14445,8 +14597,8 @@ var IntegrationComingSoon = ({
|
|
|
14445
14597
|
};
|
|
14446
14598
|
|
|
14447
14599
|
// src/components/Tiles/styles/IntegrationLoadingTile.styles.ts
|
|
14448
|
-
var
|
|
14449
|
-
var IntegrationLoadingTileContainer =
|
|
14600
|
+
var import_react75 = require("@emotion/react");
|
|
14601
|
+
var IntegrationLoadingTileContainer = import_react75.css`
|
|
14450
14602
|
align-items: center;
|
|
14451
14603
|
box-sizing: border-box;
|
|
14452
14604
|
border-radius: var(--rounded-base);
|
|
@@ -14473,17 +14625,17 @@ var IntegrationLoadingTileContainer = import_react74.css`
|
|
|
14473
14625
|
}
|
|
14474
14626
|
}
|
|
14475
14627
|
`;
|
|
14476
|
-
var IntegrationLoadingTileImg =
|
|
14628
|
+
var IntegrationLoadingTileImg = import_react75.css`
|
|
14477
14629
|
width: 10rem;
|
|
14478
14630
|
height: 4rem;
|
|
14479
14631
|
margin: 0 auto;
|
|
14480
14632
|
`;
|
|
14481
|
-
var IntegrationLoadingTileText =
|
|
14633
|
+
var IntegrationLoadingTileText = import_react75.css`
|
|
14482
14634
|
width: 5rem;
|
|
14483
14635
|
height: var(--spacing-sm);
|
|
14484
14636
|
margin: var(--spacing-sm) 0;
|
|
14485
14637
|
`;
|
|
14486
|
-
var IntegrationLoadingFrame =
|
|
14638
|
+
var IntegrationLoadingFrame = import_react75.css`
|
|
14487
14639
|
animation: ${skeletonLoading} 1s linear infinite alternate;
|
|
14488
14640
|
border-radius: var(--rounded-base);
|
|
14489
14641
|
`;
|
|
@@ -14499,13 +14651,13 @@ var IntegrationLoadingTile = ({ count = 1 }) => {
|
|
|
14499
14651
|
};
|
|
14500
14652
|
|
|
14501
14653
|
// src/components/Tiles/styles/IntegrationModalIcon.styles.ts
|
|
14502
|
-
var
|
|
14503
|
-
var IntegrationModalIconContainer =
|
|
14654
|
+
var import_react76 = require("@emotion/react");
|
|
14655
|
+
var IntegrationModalIconContainer = import_react76.css`
|
|
14504
14656
|
position: relative;
|
|
14505
14657
|
width: 50px;
|
|
14506
14658
|
margin-bottom: var(--spacing-base);
|
|
14507
14659
|
`;
|
|
14508
|
-
var IntegrationModalImage =
|
|
14660
|
+
var IntegrationModalImage = import_react76.css`
|
|
14509
14661
|
position: absolute;
|
|
14510
14662
|
inset: 0;
|
|
14511
14663
|
margin: auto;
|
|
@@ -14593,59 +14745,118 @@ var IntegrationTile = ({
|
|
|
14593
14745
|
);
|
|
14594
14746
|
};
|
|
14595
14747
|
|
|
14596
|
-
// src/components/Tiles/styles/
|
|
14597
|
-
var
|
|
14598
|
-
var
|
|
14599
|
-
background: var(--
|
|
14748
|
+
// src/components/Tiles/styles/Tile.styles.ts
|
|
14749
|
+
var import_react77 = require("@emotion/react");
|
|
14750
|
+
var Tile = import_react77.css`
|
|
14751
|
+
background: var(--white);
|
|
14752
|
+
border: none;
|
|
14753
|
+
cursor: pointer;
|
|
14754
|
+
outline: 1px solid var(--gray-300);
|
|
14755
|
+
display: grid;
|
|
14600
14756
|
padding: var(--spacing-base);
|
|
14601
|
-
|
|
14757
|
+
place-items: center;
|
|
14758
|
+
place-content: flex-start center;
|
|
14759
|
+
gap: var(--spacing-sm);
|
|
14760
|
+
transition: background-color var(--duration-fast) var(--timing-ease-out);
|
|
14761
|
+
min-height: 128px;
|
|
14762
|
+
|
|
14763
|
+
&:hover,
|
|
14764
|
+
&:focus {
|
|
14765
|
+
background: var(--gray-50);
|
|
14766
|
+
}
|
|
14767
|
+
`;
|
|
14768
|
+
|
|
14769
|
+
// src/components/Tiles/Tile.tsx
|
|
14770
|
+
var import_jsx_runtime73 = require("@emotion/react/jsx-runtime");
|
|
14771
|
+
var Tile2 = ({ children, ...props }) => {
|
|
14772
|
+
return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("button", { type: "button", css: Tile, ...props, children });
|
|
14773
|
+
};
|
|
14774
|
+
|
|
14775
|
+
// src/components/Tiles/styles/TileContainer.styles.ts
|
|
14776
|
+
var import_react78 = require("@emotion/react");
|
|
14777
|
+
var TileContainerWrapper = (theme, padding) => import_react78.css`
|
|
14778
|
+
background: ${theme};
|
|
14779
|
+
padding: ${padding != "none" ? `var(--spacing-${padding})` : "0"};
|
|
14602
14780
|
`;
|
|
14603
|
-
var TileContainerInner =
|
|
14781
|
+
var TileContainerInner = (gap, templateColumns) => import_react78.css`
|
|
14604
14782
|
display: grid;
|
|
14605
|
-
grid-template-columns:
|
|
14606
|
-
gap: var(--spacing
|
|
14783
|
+
grid-template-columns: ${templateColumns};
|
|
14784
|
+
gap: var(--spacing-${gap});
|
|
14607
14785
|
`;
|
|
14608
14786
|
|
|
14609
14787
|
// src/components/Tiles/TileContainer.tsx
|
|
14610
|
-
var
|
|
14611
|
-
var TileContainer = ({
|
|
14612
|
-
|
|
14788
|
+
var import_jsx_runtime74 = require("@emotion/react/jsx-runtime");
|
|
14789
|
+
var TileContainer = ({
|
|
14790
|
+
bgColor = "var(--brand-secondary-2)",
|
|
14791
|
+
containerPadding = "base",
|
|
14792
|
+
gap = "base",
|
|
14793
|
+
gridTemplateColumns = "repeat(auto-fill, minmax(13rem, 1fr))",
|
|
14794
|
+
children,
|
|
14795
|
+
...props
|
|
14796
|
+
}) => {
|
|
14797
|
+
return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("div", { css: TileContainerWrapper(bgColor, containerPadding), ...props, children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("div", { css: TileContainerInner(gap, gridTemplateColumns), children }) });
|
|
14798
|
+
};
|
|
14799
|
+
|
|
14800
|
+
// src/components/Tiles/styles/TileText.styles.ts
|
|
14801
|
+
var import_react79 = require("@emotion/react");
|
|
14802
|
+
var TileHeading = import_react79.css`
|
|
14803
|
+
font-size: var(--fs-base);
|
|
14804
|
+
`;
|
|
14805
|
+
var TileText = import_react79.css`
|
|
14806
|
+
color: var(--gray-500);
|
|
14807
|
+
font-size: var(--fs-sm);
|
|
14808
|
+
line-height: 1.2;
|
|
14809
|
+
`;
|
|
14810
|
+
|
|
14811
|
+
// src/components/Tiles/TileText.tsx
|
|
14812
|
+
var import_jsx_runtime75 = require("@emotion/react/jsx-runtime");
|
|
14813
|
+
var TileText2 = ({ as = "heading", children, ...props }) => {
|
|
14814
|
+
const isHeading = as === "heading";
|
|
14815
|
+
return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(
|
|
14816
|
+
"span",
|
|
14817
|
+
{
|
|
14818
|
+
role: isHeading ? "heading" : void 0,
|
|
14819
|
+
css: isHeading ? TileHeading : TileText,
|
|
14820
|
+
...props,
|
|
14821
|
+
children
|
|
14822
|
+
}
|
|
14823
|
+
);
|
|
14613
14824
|
};
|
|
14614
14825
|
|
|
14615
14826
|
// src/components/Modal/IntegrationModalHeader.styles.ts
|
|
14616
|
-
var
|
|
14617
|
-
var IntegrationModalHeaderSVGBackground =
|
|
14827
|
+
var import_react80 = require("@emotion/react");
|
|
14828
|
+
var IntegrationModalHeaderSVGBackground = import_react80.css`
|
|
14618
14829
|
position: absolute;
|
|
14619
14830
|
top: 0;
|
|
14620
14831
|
left: 0;
|
|
14621
14832
|
`;
|
|
14622
|
-
var IntegrationModalHeaderGroup =
|
|
14833
|
+
var IntegrationModalHeaderGroup = import_react80.css`
|
|
14623
14834
|
align-items: center;
|
|
14624
14835
|
display: flex;
|
|
14625
14836
|
gap: var(--spacing-sm);
|
|
14626
14837
|
margin: 0 0 var(--spacing-md);
|
|
14627
14838
|
position: relative;
|
|
14628
14839
|
`;
|
|
14629
|
-
var IntegrationModalHeaderTitleGroup =
|
|
14840
|
+
var IntegrationModalHeaderTitleGroup = import_react80.css`
|
|
14630
14841
|
align-items: center;
|
|
14631
14842
|
display: flex;
|
|
14632
14843
|
gap: var(--spacing-base);
|
|
14633
14844
|
`;
|
|
14634
|
-
var IntegrationModalHeaderTitle =
|
|
14845
|
+
var IntegrationModalHeaderTitle = import_react80.css`
|
|
14635
14846
|
margin-top: 0;
|
|
14636
14847
|
`;
|
|
14637
|
-
var IntegrationModalHeaderMenuPlacement =
|
|
14848
|
+
var IntegrationModalHeaderMenuPlacement = import_react80.css`
|
|
14638
14849
|
margin-bottom: var(--spacing-base);
|
|
14639
14850
|
`;
|
|
14640
|
-
var IntegrationModalHeaderContentWrapper =
|
|
14851
|
+
var IntegrationModalHeaderContentWrapper = import_react80.css`
|
|
14641
14852
|
position: relative;
|
|
14642
14853
|
z-index: var(--z-10);
|
|
14643
14854
|
`;
|
|
14644
14855
|
|
|
14645
14856
|
// src/components/Modal/IntegrationModalHeader.tsx
|
|
14646
|
-
var
|
|
14857
|
+
var import_jsx_runtime76 = require("@emotion/react/jsx-runtime");
|
|
14647
14858
|
var HexModalBackground = ({ ...props }) => {
|
|
14648
|
-
return /* @__PURE__ */ (0,
|
|
14859
|
+
return /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(
|
|
14649
14860
|
"svg",
|
|
14650
14861
|
{
|
|
14651
14862
|
width: "236",
|
|
@@ -14655,7 +14866,7 @@ var HexModalBackground = ({ ...props }) => {
|
|
|
14655
14866
|
xmlns: "http://www.w3.org/2000/svg",
|
|
14656
14867
|
...props,
|
|
14657
14868
|
children: [
|
|
14658
|
-
/* @__PURE__ */ (0,
|
|
14869
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
|
|
14659
14870
|
"path",
|
|
14660
14871
|
{
|
|
14661
14872
|
fillRule: "evenodd",
|
|
@@ -14664,7 +14875,7 @@ var HexModalBackground = ({ ...props }) => {
|
|
|
14664
14875
|
fill: "url(#paint0_linear_196_2737)"
|
|
14665
14876
|
}
|
|
14666
14877
|
),
|
|
14667
|
-
/* @__PURE__ */ (0,
|
|
14878
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(
|
|
14668
14879
|
"linearGradient",
|
|
14669
14880
|
{
|
|
14670
14881
|
id: "paint0_linear_196_2737",
|
|
@@ -14674,8 +14885,8 @@ var HexModalBackground = ({ ...props }) => {
|
|
|
14674
14885
|
y2: "-95.2742",
|
|
14675
14886
|
gradientUnits: "userSpaceOnUse",
|
|
14676
14887
|
children: [
|
|
14677
|
-
/* @__PURE__ */ (0,
|
|
14678
|
-
/* @__PURE__ */ (0,
|
|
14888
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("stop", { stopColor: "#81DCDE" }),
|
|
14889
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("stop", { offset: "1", stopColor: "#428ED4" })
|
|
14679
14890
|
]
|
|
14680
14891
|
}
|
|
14681
14892
|
) })
|
|
@@ -14684,27 +14895,27 @@ var HexModalBackground = ({ ...props }) => {
|
|
|
14684
14895
|
);
|
|
14685
14896
|
};
|
|
14686
14897
|
var IntegrationModalHeader = ({ icon, name, menu: menu2, children }) => {
|
|
14687
|
-
return /* @__PURE__ */ (0,
|
|
14688
|
-
/* @__PURE__ */ (0,
|
|
14689
|
-
/* @__PURE__ */ (0,
|
|
14690
|
-
icon ? /* @__PURE__ */ (0,
|
|
14691
|
-
/* @__PURE__ */ (0,
|
|
14692
|
-
menu2 ? /* @__PURE__ */ (0,
|
|
14898
|
+
return /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(import_jsx_runtime76.Fragment, { children: [
|
|
14899
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)(HexModalBackground, { css: IntegrationModalHeaderSVGBackground, role: "presentation" }),
|
|
14900
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { css: IntegrationModalHeaderGroup, children: /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { css: IntegrationModalHeaderTitleGroup, children: [
|
|
14901
|
+
icon ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(IntegrationModalIcon, { icon, name: name || "" }) : null,
|
|
14902
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Heading, { level: 3, css: IntegrationModalHeaderTitle, "data-test-id": "integration-modal-title", children: name || "Create Team Integration" }),
|
|
14903
|
+
menu2 ? /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { css: IntegrationModalHeaderMenuPlacement, children: [
|
|
14693
14904
|
menu2,
|
|
14694
14905
|
" "
|
|
14695
14906
|
] }) : null
|
|
14696
14907
|
] }) }),
|
|
14697
|
-
/* @__PURE__ */ (0,
|
|
14908
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { css: IntegrationModalHeaderContentWrapper, children })
|
|
14698
14909
|
] });
|
|
14699
14910
|
};
|
|
14700
14911
|
|
|
14701
14912
|
// src/components/Tooltip/Tooltip.tsx
|
|
14702
|
-
var
|
|
14913
|
+
var import_react82 = __toESM(require("react"));
|
|
14703
14914
|
var import_Tooltip = require("reakit/Tooltip");
|
|
14704
14915
|
|
|
14705
14916
|
// src/components/Tooltip/Tooltip.styles.ts
|
|
14706
|
-
var
|
|
14707
|
-
var TooltipContainer =
|
|
14917
|
+
var import_react81 = require("@emotion/react");
|
|
14918
|
+
var TooltipContainer = import_react81.css`
|
|
14708
14919
|
z-index: var(--z-tooltip);
|
|
14709
14920
|
border: 2px solid var(--gray-300);
|
|
14710
14921
|
border-radius: var(--rounded-base);
|
|
@@ -14713,28 +14924,28 @@ var TooltipContainer = import_react78.css`
|
|
|
14713
14924
|
font-size: var(--fs-xs);
|
|
14714
14925
|
background: var(--white);
|
|
14715
14926
|
`;
|
|
14716
|
-
var TooltipArrowStyles =
|
|
14927
|
+
var TooltipArrowStyles = import_react81.css`
|
|
14717
14928
|
svg {
|
|
14718
14929
|
fill: var(--gray-300);
|
|
14719
14930
|
}
|
|
14720
14931
|
`;
|
|
14721
14932
|
|
|
14722
14933
|
// src/components/Tooltip/Tooltip.tsx
|
|
14723
|
-
var
|
|
14934
|
+
var import_jsx_runtime77 = require("@emotion/react/jsx-runtime");
|
|
14724
14935
|
function Tooltip({ children, title, placement = "bottom", visible, ...props }) {
|
|
14725
14936
|
const tooltip = (0, import_Tooltip.useTooltipState)({ placement });
|
|
14726
|
-
return !title ? children : /* @__PURE__ */ (0,
|
|
14727
|
-
/* @__PURE__ */ (0,
|
|
14728
|
-
/* @__PURE__ */ (0,
|
|
14729
|
-
/* @__PURE__ */ (0,
|
|
14937
|
+
return !title ? children : /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(import_jsx_runtime77.Fragment, { children: [
|
|
14938
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_Tooltip.TooltipReference, { ...tooltip, ...children.props, children: (referenceProps) => import_react82.default.cloneElement(children, referenceProps) }),
|
|
14939
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(import_Tooltip.Tooltip, { ...tooltip, ...props, css: TooltipContainer, visible: visible != null ? visible : tooltip.visible, children: [
|
|
14940
|
+
/* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_Tooltip.TooltipArrow, { ...tooltip, css: TooltipArrowStyles }),
|
|
14730
14941
|
title
|
|
14731
14942
|
] })
|
|
14732
14943
|
] });
|
|
14733
14944
|
}
|
|
14734
14945
|
|
|
14735
14946
|
// src/components/ParameterInputs/styles/ParameterBindingButton.styles.ts
|
|
14736
|
-
var
|
|
14737
|
-
var inputIconBtn =
|
|
14947
|
+
var import_react83 = require("@emotion/react");
|
|
14948
|
+
var inputIconBtn = import_react83.css`
|
|
14738
14949
|
align-items: center;
|
|
14739
14950
|
border: none;
|
|
14740
14951
|
border-radius: var(--rounded-base);
|
|
@@ -14758,7 +14969,7 @@ var inputIconBtn = import_react80.css`
|
|
|
14758
14969
|
`;
|
|
14759
14970
|
|
|
14760
14971
|
// src/components/ParameterInputs/ConnectToDataElementButton.tsx
|
|
14761
|
-
var
|
|
14972
|
+
var import_jsx_runtime78 = require("@emotion/react/jsx-runtime");
|
|
14762
14973
|
var ConnectToDataElementButton = ({
|
|
14763
14974
|
icon,
|
|
14764
14975
|
iconColor,
|
|
@@ -14768,7 +14979,7 @@ var ConnectToDataElementButton = ({
|
|
|
14768
14979
|
...props
|
|
14769
14980
|
}) => {
|
|
14770
14981
|
const title = isLocked ? "Read-only pattern parameter" : isBound ? "Connected to external content. Click to edit" : "Click to connect to external content";
|
|
14771
|
-
return /* @__PURE__ */ (0,
|
|
14982
|
+
return /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(Tooltip, { title, children: /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)(
|
|
14772
14983
|
"button",
|
|
14773
14984
|
{
|
|
14774
14985
|
css: inputIconBtn,
|
|
@@ -14777,7 +14988,7 @@ var ConnectToDataElementButton = ({
|
|
|
14777
14988
|
"aria-disabled": isLocked,
|
|
14778
14989
|
...props,
|
|
14779
14990
|
children: [
|
|
14780
|
-
/* @__PURE__ */ (0,
|
|
14991
|
+
/* @__PURE__ */ (0, import_jsx_runtime78.jsx)(
|
|
14781
14992
|
Icon,
|
|
14782
14993
|
{
|
|
14783
14994
|
icon: isLocked ? "lock" : icon ? icon : "arrows-expand-down-right",
|
|
@@ -14792,8 +15003,8 @@ var ConnectToDataElementButton = ({
|
|
|
14792
15003
|
};
|
|
14793
15004
|
|
|
14794
15005
|
// src/components/ParameterInputs/hooks/ParameterShellContext.tsx
|
|
14795
|
-
var
|
|
14796
|
-
var ParameterShellContext = (0,
|
|
15006
|
+
var import_react84 = require("react");
|
|
15007
|
+
var ParameterShellContext = (0, import_react84.createContext)({
|
|
14797
15008
|
id: "",
|
|
14798
15009
|
label: "",
|
|
14799
15010
|
hiddenLabel: void 0,
|
|
@@ -14802,7 +15013,7 @@ var ParameterShellContext = (0, import_react81.createContext)({
|
|
|
14802
15013
|
}
|
|
14803
15014
|
});
|
|
14804
15015
|
var useParameterShell = () => {
|
|
14805
|
-
const { id, label, hiddenLabel, errorMessage, handleManuallySetErrorMessage } = (0,
|
|
15016
|
+
const { id, label, hiddenLabel, errorMessage, handleManuallySetErrorMessage } = (0, import_react84.useContext)(ParameterShellContext);
|
|
14806
15017
|
return {
|
|
14807
15018
|
id,
|
|
14808
15019
|
label,
|
|
@@ -14813,8 +15024,8 @@ var useParameterShell = () => {
|
|
|
14813
15024
|
};
|
|
14814
15025
|
|
|
14815
15026
|
// src/components/ParameterInputs/styles/ParameterInput.styles.ts
|
|
14816
|
-
var
|
|
14817
|
-
var inputContainer2 =
|
|
15027
|
+
var import_react85 = require("@emotion/react");
|
|
15028
|
+
var inputContainer2 = import_react85.css`
|
|
14818
15029
|
position: relative;
|
|
14819
15030
|
|
|
14820
15031
|
&:hover,
|
|
@@ -14826,14 +15037,14 @@ var inputContainer2 = import_react82.css`
|
|
|
14826
15037
|
}
|
|
14827
15038
|
}
|
|
14828
15039
|
`;
|
|
14829
|
-
var labelText2 =
|
|
15040
|
+
var labelText2 = import_react85.css`
|
|
14830
15041
|
align-items: center;
|
|
14831
15042
|
display: flex;
|
|
14832
15043
|
gap: var(--spacing-xs);
|
|
14833
15044
|
font-weight: var(--fw-regular);
|
|
14834
15045
|
margin: 0 0 var(--spacing-xs);
|
|
14835
15046
|
`;
|
|
14836
|
-
var input2 =
|
|
15047
|
+
var input2 = import_react85.css`
|
|
14837
15048
|
display: block;
|
|
14838
15049
|
appearance: none;
|
|
14839
15050
|
box-sizing: border-box;
|
|
@@ -14877,18 +15088,18 @@ var input2 = import_react82.css`
|
|
|
14877
15088
|
color: var(--gray-400);
|
|
14878
15089
|
}
|
|
14879
15090
|
`;
|
|
14880
|
-
var selectInput =
|
|
15091
|
+
var selectInput = import_react85.css`
|
|
14881
15092
|
background-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%0A%3E%3Cpath d='M6.34317 7.75732L4.92896 9.17154L12 16.2426L19.0711 9.17157L17.6569 7.75735L12 13.4142L6.34317 7.75732Z' fill='currentColor' /%3E%3C/svg%3E");
|
|
14882
15093
|
background-position: right var(--spacing-sm) center;
|
|
14883
15094
|
background-repeat: no-repeat;
|
|
14884
15095
|
background-size: 1rem;
|
|
14885
15096
|
padding-right: var(--spacing-xl);
|
|
14886
15097
|
`;
|
|
14887
|
-
var inputWrapper =
|
|
15098
|
+
var inputWrapper = import_react85.css`
|
|
14888
15099
|
display: flex; // used to correct overflow with chrome textarea
|
|
14889
15100
|
position: relative;
|
|
14890
15101
|
`;
|
|
14891
|
-
var inputIcon2 =
|
|
15102
|
+
var inputIcon2 = import_react85.css`
|
|
14892
15103
|
align-items: center;
|
|
14893
15104
|
background: var(--white);
|
|
14894
15105
|
border-radius: var(--rounded-md) 0 0 var(--rounded-md);
|
|
@@ -14904,7 +15115,7 @@ var inputIcon2 = import_react82.css`
|
|
|
14904
15115
|
width: var(--spacing-lg);
|
|
14905
15116
|
z-index: var(--z-10);
|
|
14906
15117
|
`;
|
|
14907
|
-
var inputToggleLabel2 =
|
|
15118
|
+
var inputToggleLabel2 = import_react85.css`
|
|
14908
15119
|
align-items: center;
|
|
14909
15120
|
background: var(--white);
|
|
14910
15121
|
cursor: pointer;
|
|
@@ -14915,7 +15126,7 @@ var inputToggleLabel2 = import_react82.css`
|
|
|
14915
15126
|
min-height: var(--spacing-md);
|
|
14916
15127
|
position: relative;
|
|
14917
15128
|
`;
|
|
14918
|
-
var toggleInput2 =
|
|
15129
|
+
var toggleInput2 = import_react85.css`
|
|
14919
15130
|
appearance: none;
|
|
14920
15131
|
border: 1px solid var(--gray-300);
|
|
14921
15132
|
background: var(--white);
|
|
@@ -14954,7 +15165,7 @@ var toggleInput2 = import_react82.css`
|
|
|
14954
15165
|
border-color: var(--gray-300);
|
|
14955
15166
|
}
|
|
14956
15167
|
`;
|
|
14957
|
-
var inlineLabel2 =
|
|
15168
|
+
var inlineLabel2 = import_react85.css`
|
|
14958
15169
|
padding-left: var(--spacing-lg);
|
|
14959
15170
|
font-size: var(--fs-sm);
|
|
14960
15171
|
font-weight: var(--fw-regular);
|
|
@@ -14970,7 +15181,7 @@ var inlineLabel2 = import_react82.css`
|
|
|
14970
15181
|
}
|
|
14971
15182
|
}
|
|
14972
15183
|
`;
|
|
14973
|
-
var inputMenu =
|
|
15184
|
+
var inputMenu = import_react85.css`
|
|
14974
15185
|
background: none;
|
|
14975
15186
|
border: none;
|
|
14976
15187
|
padding: var(--spacing-2xs);
|
|
@@ -14986,14 +15197,14 @@ var inputMenu = import_react82.css`
|
|
|
14986
15197
|
background-color: var(--gray-200);
|
|
14987
15198
|
}
|
|
14988
15199
|
`;
|
|
14989
|
-
var textarea2 =
|
|
15200
|
+
var textarea2 = import_react85.css`
|
|
14990
15201
|
resize: vertical;
|
|
14991
15202
|
min-height: 2rem;
|
|
14992
15203
|
`;
|
|
14993
|
-
var imageWrapper =
|
|
15204
|
+
var imageWrapper = import_react85.css`
|
|
14994
15205
|
background: var(--white);
|
|
14995
15206
|
`;
|
|
14996
|
-
var img =
|
|
15207
|
+
var img = import_react85.css`
|
|
14997
15208
|
animation: ${fadeIn} var(--duration-fast) var(--timing-ease-out) forwards;
|
|
14998
15209
|
object-fit: contain;
|
|
14999
15210
|
max-width: 100%;
|
|
@@ -15001,7 +15212,7 @@ var img = import_react82.css`
|
|
|
15001
15212
|
opacity: var(--opacity-0);
|
|
15002
15213
|
margin: var(--spacing-sm) auto 0;
|
|
15003
15214
|
`;
|
|
15004
|
-
var dataConnectButton =
|
|
15215
|
+
var dataConnectButton = import_react85.css`
|
|
15005
15216
|
align-items: center;
|
|
15006
15217
|
appearance: none;
|
|
15007
15218
|
box-sizing: border-box;
|
|
@@ -15036,7 +15247,7 @@ var dataConnectButton = import_react82.css`
|
|
|
15036
15247
|
pointer-events: none;
|
|
15037
15248
|
}
|
|
15038
15249
|
`;
|
|
15039
|
-
var linkParameterBtn =
|
|
15250
|
+
var linkParameterBtn = import_react85.css`
|
|
15040
15251
|
border-radius: var(--rounded-base);
|
|
15041
15252
|
background: var(--white);
|
|
15042
15253
|
border: none;
|
|
@@ -15045,7 +15256,7 @@ var linkParameterBtn = import_react82.css`
|
|
|
15045
15256
|
font-size: var(--fs-sm);
|
|
15046
15257
|
line-height: 1;
|
|
15047
15258
|
`;
|
|
15048
|
-
var linkParameterControls =
|
|
15259
|
+
var linkParameterControls = import_react85.css`
|
|
15049
15260
|
position: absolute;
|
|
15050
15261
|
inset: 0 0 0 auto;
|
|
15051
15262
|
padding: 0 var(--spacing-base);
|
|
@@ -15054,13 +15265,13 @@ var linkParameterControls = import_react82.css`
|
|
|
15054
15265
|
justify-content: center;
|
|
15055
15266
|
gap: var(--spacing-base);
|
|
15056
15267
|
`;
|
|
15057
|
-
var linkParameterInput = (withExternalLinkIcon) =>
|
|
15268
|
+
var linkParameterInput = (withExternalLinkIcon) => import_react85.css`
|
|
15058
15269
|
padding-right: calc(
|
|
15059
15270
|
${withExternalLinkIcon ? "calc(var(--spacing-lg) * 2 + var(--spacing-xs))" : "var(--spacing-xl)"} +
|
|
15060
15271
|
var(--spacing-base)
|
|
15061
15272
|
);
|
|
15062
15273
|
`;
|
|
15063
|
-
var linkParameterIcon =
|
|
15274
|
+
var linkParameterIcon = import_react85.css`
|
|
15064
15275
|
align-items: center;
|
|
15065
15276
|
color: var(--brand-secondary-3);
|
|
15066
15277
|
display: flex;
|
|
@@ -15075,7 +15286,7 @@ var linkParameterIcon = import_react82.css`
|
|
|
15075
15286
|
`;
|
|
15076
15287
|
|
|
15077
15288
|
// src/components/ParameterInputs/ParameterDataResource.tsx
|
|
15078
|
-
var
|
|
15289
|
+
var import_jsx_runtime79 = require("@emotion/react/jsx-runtime");
|
|
15079
15290
|
function ParameterDataResource({
|
|
15080
15291
|
label,
|
|
15081
15292
|
labelLeadingIcon,
|
|
@@ -15085,12 +15296,12 @@ function ParameterDataResource({
|
|
|
15085
15296
|
disabled,
|
|
15086
15297
|
children
|
|
15087
15298
|
}) {
|
|
15088
|
-
return /* @__PURE__ */ (0,
|
|
15089
|
-
/* @__PURE__ */ (0,
|
|
15299
|
+
return /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("div", { "data-testid": "parameter-data-connect-button", children: [
|
|
15300
|
+
/* @__PURE__ */ (0, import_jsx_runtime79.jsxs)("span", { css: labelText2, children: [
|
|
15090
15301
|
labelLeadingIcon ? labelLeadingIcon : null,
|
|
15091
15302
|
label
|
|
15092
15303
|
] }),
|
|
15093
|
-
/* @__PURE__ */ (0,
|
|
15304
|
+
/* @__PURE__ */ (0, import_jsx_runtime79.jsxs)(
|
|
15094
15305
|
"button",
|
|
15095
15306
|
{
|
|
15096
15307
|
type: "button",
|
|
@@ -15099,30 +15310,30 @@ function ParameterDataResource({
|
|
|
15099
15310
|
disabled,
|
|
15100
15311
|
onClick: onConnectDatasource,
|
|
15101
15312
|
children: [
|
|
15102
|
-
/* @__PURE__ */ (0,
|
|
15313
|
+
/* @__PURE__ */ (0, import_jsx_runtime79.jsx)("span", { className: "advance-input-icon", css: [inputIcon2], children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(Icon, { icon: "stack", iconColor: "currentColor", size: "1rem" }) }),
|
|
15103
15314
|
children
|
|
15104
15315
|
]
|
|
15105
15316
|
}
|
|
15106
15317
|
),
|
|
15107
|
-
caption ? /* @__PURE__ */ (0,
|
|
15318
|
+
caption ? /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(Caption, { children: caption }) : null
|
|
15108
15319
|
] });
|
|
15109
15320
|
}
|
|
15110
15321
|
|
|
15111
15322
|
// src/components/ParameterInputs/styles/ParameterDrawerHeader.styles.ts
|
|
15112
|
-
var
|
|
15113
|
-
var ParameterDrawerHeaderContainer =
|
|
15323
|
+
var import_react86 = require("@emotion/react");
|
|
15324
|
+
var ParameterDrawerHeaderContainer = import_react86.css`
|
|
15114
15325
|
align-items: center;
|
|
15115
15326
|
display: flex;
|
|
15116
15327
|
gap: var(--spacing-base);
|
|
15117
15328
|
justify-content: space-between;
|
|
15118
15329
|
margin-bottom: var(--spacing-sm);
|
|
15119
15330
|
`;
|
|
15120
|
-
var ParameterDrawerHeaderTitleGroup =
|
|
15331
|
+
var ParameterDrawerHeaderTitleGroup = import_react86.css`
|
|
15121
15332
|
align-items: center;
|
|
15122
15333
|
display: flex;
|
|
15123
15334
|
gap: var(--spacing-sm);
|
|
15124
15335
|
`;
|
|
15125
|
-
var ParameterDrawerHeaderTitle =
|
|
15336
|
+
var ParameterDrawerHeaderTitle = import_react86.css`
|
|
15126
15337
|
text-overflow: ellipsis;
|
|
15127
15338
|
white-space: nowrap;
|
|
15128
15339
|
overflow: hidden;
|
|
@@ -15130,23 +15341,23 @@ var ParameterDrawerHeaderTitle = import_react83.css`
|
|
|
15130
15341
|
`;
|
|
15131
15342
|
|
|
15132
15343
|
// src/components/ParameterInputs/ParameterDrawerHeader.tsx
|
|
15133
|
-
var
|
|
15344
|
+
var import_jsx_runtime80 = require("@emotion/react/jsx-runtime");
|
|
15134
15345
|
var ParameterDrawerHeader = ({ title, iconBeforeTitle, children }) => {
|
|
15135
|
-
return /* @__PURE__ */ (0,
|
|
15136
|
-
/* @__PURE__ */ (0,
|
|
15346
|
+
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { css: ParameterDrawerHeaderContainer, children: [
|
|
15347
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("header", { css: ParameterDrawerHeaderTitleGroup, children: [
|
|
15137
15348
|
iconBeforeTitle,
|
|
15138
|
-
/* @__PURE__ */ (0,
|
|
15349
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Heading, { level: 3, withMarginBottom: false, css: ParameterDrawerHeaderTitle, title, children: title })
|
|
15139
15350
|
] }),
|
|
15140
15351
|
children
|
|
15141
15352
|
] });
|
|
15142
15353
|
};
|
|
15143
15354
|
|
|
15144
15355
|
// src/components/ParameterInputs/ParameterGroup.tsx
|
|
15145
|
-
var
|
|
15356
|
+
var import_react88 = require("react");
|
|
15146
15357
|
|
|
15147
15358
|
// src/components/ParameterInputs/styles/ParameterGroup.styles.ts
|
|
15148
|
-
var
|
|
15149
|
-
var fieldsetStyles =
|
|
15359
|
+
var import_react87 = require("@emotion/react");
|
|
15360
|
+
var fieldsetStyles = import_react87.css`
|
|
15150
15361
|
&:disabled,
|
|
15151
15362
|
[readonly] {
|
|
15152
15363
|
pointer-events: none;
|
|
@@ -15157,7 +15368,7 @@ var fieldsetStyles = import_react84.css`
|
|
|
15157
15368
|
}
|
|
15158
15369
|
}
|
|
15159
15370
|
`;
|
|
15160
|
-
var fieldsetLegend2 =
|
|
15371
|
+
var fieldsetLegend2 = import_react87.css`
|
|
15161
15372
|
display: block;
|
|
15162
15373
|
font-weight: var(--fw-medium);
|
|
15163
15374
|
margin-bottom: var(--spacing-sm);
|
|
@@ -15165,38 +15376,38 @@ var fieldsetLegend2 = import_react84.css`
|
|
|
15165
15376
|
`;
|
|
15166
15377
|
|
|
15167
15378
|
// src/components/ParameterInputs/ParameterGroup.tsx
|
|
15168
|
-
var
|
|
15169
|
-
var ParameterGroup = (0,
|
|
15379
|
+
var import_jsx_runtime81 = require("@emotion/react/jsx-runtime");
|
|
15380
|
+
var ParameterGroup = (0, import_react88.forwardRef)(
|
|
15170
15381
|
({ legend, isDisabled, children, ...props }, ref) => {
|
|
15171
|
-
return /* @__PURE__ */ (0,
|
|
15172
|
-
/* @__PURE__ */ (0,
|
|
15382
|
+
return /* @__PURE__ */ (0, import_jsx_runtime81.jsxs)("fieldset", { css: fieldsetStyles, disabled: isDisabled, ref, ...props, children: [
|
|
15383
|
+
/* @__PURE__ */ (0, import_jsx_runtime81.jsx)("legend", { css: fieldsetLegend2, children: legend }),
|
|
15173
15384
|
children
|
|
15174
15385
|
] });
|
|
15175
15386
|
}
|
|
15176
15387
|
);
|
|
15177
15388
|
|
|
15178
15389
|
// src/components/ParameterInputs/ParameterImage.tsx
|
|
15179
|
-
var
|
|
15390
|
+
var import_react92 = require("react");
|
|
15180
15391
|
|
|
15181
15392
|
// src/components/ParameterInputs/ParameterShell.tsx
|
|
15182
|
-
var
|
|
15393
|
+
var import_react91 = require("react");
|
|
15183
15394
|
|
|
15184
15395
|
// src/components/ParameterInputs/ParameterLabel.tsx
|
|
15185
|
-
var
|
|
15396
|
+
var import_jsx_runtime82 = require("@emotion/react/jsx-runtime");
|
|
15186
15397
|
var ParameterLabel = ({ id, asSpan, children, ...props }) => {
|
|
15187
|
-
return !asSpan ? /* @__PURE__ */ (0,
|
|
15398
|
+
return !asSpan ? /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("label", { ...props, htmlFor: id, css: labelText2, children }) : /* @__PURE__ */ (0, import_jsx_runtime82.jsx)("span", { "aria-labelledby": id, css: labelText2, children });
|
|
15188
15399
|
};
|
|
15189
15400
|
|
|
15190
15401
|
// src/components/ParameterInputs/ParameterMenuButton.tsx
|
|
15191
|
-
var
|
|
15192
|
-
var
|
|
15193
|
-
var ParameterMenuButton = (0,
|
|
15402
|
+
var import_react89 = require("react");
|
|
15403
|
+
var import_jsx_runtime83 = require("@emotion/react/jsx-runtime");
|
|
15404
|
+
var ParameterMenuButton = (0, import_react89.forwardRef)(
|
|
15194
15405
|
({ label, children }, ref) => {
|
|
15195
|
-
return /* @__PURE__ */ (0,
|
|
15406
|
+
return /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
|
|
15196
15407
|
Menu,
|
|
15197
15408
|
{
|
|
15198
15409
|
menuLabel: `${label} menu`,
|
|
15199
|
-
menuTrigger: /* @__PURE__ */ (0,
|
|
15410
|
+
menuTrigger: /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(
|
|
15200
15411
|
"button",
|
|
15201
15412
|
{
|
|
15202
15413
|
className: "parameter-menu",
|
|
@@ -15204,7 +15415,7 @@ var ParameterMenuButton = (0, import_react86.forwardRef)(
|
|
|
15204
15415
|
type: "button",
|
|
15205
15416
|
"aria-label": `${label} options`,
|
|
15206
15417
|
ref,
|
|
15207
|
-
children: /* @__PURE__ */ (0,
|
|
15418
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(Icon, { icon: "more-alt", iconColor: "currentColor", size: "0.9rem" })
|
|
15208
15419
|
}
|
|
15209
15420
|
),
|
|
15210
15421
|
children
|
|
@@ -15214,15 +15425,15 @@ var ParameterMenuButton = (0, import_react86.forwardRef)(
|
|
|
15214
15425
|
);
|
|
15215
15426
|
|
|
15216
15427
|
// src/components/ParameterInputs/styles/ParameterShell.styles.ts
|
|
15217
|
-
var
|
|
15218
|
-
var emptyParameterShell =
|
|
15428
|
+
var import_react90 = require("@emotion/react");
|
|
15429
|
+
var emptyParameterShell = import_react90.css`
|
|
15219
15430
|
border-radius: var(--rounded-sm);
|
|
15220
15431
|
background: var(--white);
|
|
15221
15432
|
flex-grow: 1;
|
|
15222
15433
|
padding: var(--spacing-xs);
|
|
15223
15434
|
position: relative;
|
|
15224
15435
|
`;
|
|
15225
|
-
var emptyParameterShellText =
|
|
15436
|
+
var emptyParameterShellText = import_react90.css`
|
|
15226
15437
|
background: var(--brand-secondary-6);
|
|
15227
15438
|
border-radius: var(--rounded-sm);
|
|
15228
15439
|
padding: var(--spacing-sm);
|
|
@@ -15230,7 +15441,7 @@ var emptyParameterShellText = import_react87.css`
|
|
|
15230
15441
|
font-size: var(--fs-sm);
|
|
15231
15442
|
margin: 0;
|
|
15232
15443
|
`;
|
|
15233
|
-
var overrideMarker =
|
|
15444
|
+
var overrideMarker = import_react90.css`
|
|
15234
15445
|
border-radius: var(--rounded-sm);
|
|
15235
15446
|
border: 10px solid var(--gray-300);
|
|
15236
15447
|
border-left-color: transparent;
|
|
@@ -15241,7 +15452,7 @@ var overrideMarker = import_react87.css`
|
|
|
15241
15452
|
`;
|
|
15242
15453
|
|
|
15243
15454
|
// src/components/ParameterInputs/ParameterShell.tsx
|
|
15244
|
-
var
|
|
15455
|
+
var import_jsx_runtime84 = require("@emotion/react/jsx-runtime");
|
|
15245
15456
|
var extractParameterProps = (props) => {
|
|
15246
15457
|
const {
|
|
15247
15458
|
id,
|
|
@@ -15255,7 +15466,6 @@ var extractParameterProps = (props) => {
|
|
|
15255
15466
|
hiddenLabel,
|
|
15256
15467
|
labelLeadingIcon,
|
|
15257
15468
|
menuItems,
|
|
15258
|
-
handleManuallySetErrorMessage,
|
|
15259
15469
|
title,
|
|
15260
15470
|
hasOverriddenValue,
|
|
15261
15471
|
onResetOverriddenValue,
|
|
@@ -15274,7 +15484,6 @@ var extractParameterProps = (props) => {
|
|
|
15274
15484
|
hiddenLabel,
|
|
15275
15485
|
labelLeadingIcon,
|
|
15276
15486
|
menuItems,
|
|
15277
|
-
handleManuallySetErrorMessage,
|
|
15278
15487
|
title,
|
|
15279
15488
|
hasOverriddenValue,
|
|
15280
15489
|
onResetOverriddenValue
|
|
@@ -15300,21 +15509,21 @@ var ParameterShell = ({
|
|
|
15300
15509
|
children,
|
|
15301
15510
|
...props
|
|
15302
15511
|
}) => {
|
|
15303
|
-
const [manualErrorMessage, setManualErrorMessage] = (0,
|
|
15512
|
+
const [manualErrorMessage, setManualErrorMessage] = (0, import_react91.useState)(void 0);
|
|
15304
15513
|
const setErrorMessage = (message) => setManualErrorMessage(message);
|
|
15305
15514
|
const errorMessaging = errorMessage || manualErrorMessage;
|
|
15306
|
-
return /* @__PURE__ */ (0,
|
|
15307
|
-
hiddenLabel || title ? null : /* @__PURE__ */ (0,
|
|
15515
|
+
return /* @__PURE__ */ (0, import_jsx_runtime84.jsxs)("div", { css: inputContainer2, ...props, children: [
|
|
15516
|
+
hiddenLabel || title ? null : /* @__PURE__ */ (0, import_jsx_runtime84.jsxs)(ParameterLabel, { id, css: labelText2, children: [
|
|
15308
15517
|
labelLeadingIcon ? labelLeadingIcon : null,
|
|
15309
15518
|
label
|
|
15310
15519
|
] }),
|
|
15311
|
-
!title ? null : /* @__PURE__ */ (0,
|
|
15520
|
+
!title ? null : /* @__PURE__ */ (0, import_jsx_runtime84.jsxs)(ParameterLabel, { id, asSpan: true, children: [
|
|
15312
15521
|
labelLeadingIcon ? labelLeadingIcon : null,
|
|
15313
15522
|
title
|
|
15314
15523
|
] }),
|
|
15315
|
-
/* @__PURE__ */ (0,
|
|
15316
|
-
menuItems ? /* @__PURE__ */ (0,
|
|
15317
|
-
/* @__PURE__ */ (0,
|
|
15524
|
+
/* @__PURE__ */ (0, import_jsx_runtime84.jsxs)("div", { css: inputWrapper, children: [
|
|
15525
|
+
menuItems ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(ParameterMenuButton, { label: `${label} menu`, children: menuItems }) : null,
|
|
15526
|
+
/* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
|
|
15318
15527
|
ParameterShellContext.Provider,
|
|
15319
15528
|
{
|
|
15320
15529
|
value: {
|
|
@@ -15324,32 +15533,32 @@ var ParameterShell = ({
|
|
|
15324
15533
|
errorMessage: errorMessaging,
|
|
15325
15534
|
handleManuallySetErrorMessage: (message) => setErrorMessage(message)
|
|
15326
15535
|
},
|
|
15327
|
-
children: /* @__PURE__ */ (0,
|
|
15536
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime84.jsxs)(ParameterShellPlaceholder, { children: [
|
|
15328
15537
|
children,
|
|
15329
|
-
hasOverriddenValue && onResetOverriddenValue ? /* @__PURE__ */ (0,
|
|
15538
|
+
hasOverriddenValue && onResetOverriddenValue ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(ParameterOverrideMarker, { onClick: onResetOverriddenValue }) : null
|
|
15330
15539
|
] })
|
|
15331
15540
|
}
|
|
15332
15541
|
)
|
|
15333
15542
|
] }),
|
|
15334
|
-
caption ? /* @__PURE__ */ (0,
|
|
15335
|
-
errorMessaging ? /* @__PURE__ */ (0,
|
|
15336
|
-
warningMessage ? /* @__PURE__ */ (0,
|
|
15337
|
-
infoMessage ? /* @__PURE__ */ (0,
|
|
15543
|
+
caption ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(Caption, { testId: captionTestId, children: caption }) : null,
|
|
15544
|
+
errorMessaging ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(ErrorMessage, { message: errorMessaging, testId: errorTestId }) : null,
|
|
15545
|
+
warningMessage ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(WarningMessage, { message: warningMessage }) : null,
|
|
15546
|
+
infoMessage ? /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(InfoMessage, { message: infoMessage }) : null
|
|
15338
15547
|
] });
|
|
15339
15548
|
};
|
|
15340
15549
|
var ParameterShellPlaceholder = ({ children }) => {
|
|
15341
|
-
return /* @__PURE__ */ (0,
|
|
15550
|
+
return /* @__PURE__ */ (0, import_jsx_runtime84.jsx)("div", { css: emptyParameterShell, children });
|
|
15342
15551
|
};
|
|
15343
|
-
var ParameterOverrideMarker = (props) => /* @__PURE__ */ (0,
|
|
15552
|
+
var ParameterOverrideMarker = (props) => /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(Tooltip, { title: "The default value has been overridden", children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)("button", { type: "button", css: overrideMarker, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)("span", { hidden: true, children: "reset overridden value to default" }) }) });
|
|
15344
15553
|
|
|
15345
15554
|
// src/components/ParameterInputs/ParameterImage.tsx
|
|
15346
|
-
var
|
|
15347
|
-
var ParameterImage = (0,
|
|
15555
|
+
var import_jsx_runtime85 = require("@emotion/react/jsx-runtime");
|
|
15556
|
+
var ParameterImage = (0, import_react92.forwardRef)((props, ref) => {
|
|
15348
15557
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
15349
|
-
return /* @__PURE__ */ (0,
|
|
15558
|
+
return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(ParameterShell, { "data-test-id": "parameter-image", ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(ParameterImageInner, { ref, ...innerProps }) });
|
|
15350
15559
|
});
|
|
15351
15560
|
var BrokenImage = ({ ...props }) => {
|
|
15352
|
-
return /* @__PURE__ */ (0,
|
|
15561
|
+
return /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)(
|
|
15353
15562
|
"svg",
|
|
15354
15563
|
{
|
|
15355
15564
|
role: "img",
|
|
@@ -15361,11 +15570,11 @@ var BrokenImage = ({ ...props }) => {
|
|
|
15361
15570
|
xmlnsXlink: "http://www.w3.org/1999/xlink",
|
|
15362
15571
|
...props,
|
|
15363
15572
|
children: [
|
|
15364
|
-
/* @__PURE__ */ (0,
|
|
15365
|
-
/* @__PURE__ */ (0,
|
|
15366
|
-
/* @__PURE__ */ (0,
|
|
15367
|
-
/* @__PURE__ */ (0,
|
|
15368
|
-
/* @__PURE__ */ (0,
|
|
15573
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsx)("rect", { width: "214", height: "214", fill: "#F9FAFB" }),
|
|
15574
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsx)("rect", { width: "214", height: "214", fill: "url(#pattern0)" }),
|
|
15575
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("defs", { children: [
|
|
15576
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsx)("pattern", { id: "pattern0", patternContentUnits: "objectBoundingBox", width: "1", height: "1", children: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)("use", { xlinkHref: "#image0_761_4353", transform: "scale(0.0025)" }) }),
|
|
15577
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
|
|
15369
15578
|
"image",
|
|
15370
15579
|
{
|
|
15371
15580
|
id: "image0_761_4353",
|
|
@@ -15379,14 +15588,14 @@ var BrokenImage = ({ ...props }) => {
|
|
|
15379
15588
|
}
|
|
15380
15589
|
);
|
|
15381
15590
|
};
|
|
15382
|
-
var ParameterImageInner = (0,
|
|
15591
|
+
var ParameterImageInner = (0, import_react92.forwardRef)(
|
|
15383
15592
|
({ ...props }, ref) => {
|
|
15384
15593
|
const { value } = props;
|
|
15385
15594
|
const { id, label, hiddenLabel, errorMessage, handleManuallySetErrorMessage } = useParameterShell();
|
|
15386
|
-
const [loading, setLoading] = (0,
|
|
15387
|
-
const deferredValue = (0,
|
|
15595
|
+
const [loading, setLoading] = (0, import_react92.useState)(false);
|
|
15596
|
+
const deferredValue = (0, import_react92.useDeferredValue)(value);
|
|
15388
15597
|
const errorText = "The text you provided is not a valid URL";
|
|
15389
|
-
const updateImageSrc = (0,
|
|
15598
|
+
const updateImageSrc = (0, import_react92.useCallback)(() => {
|
|
15390
15599
|
const validUrl = new RegExp(
|
|
15391
15600
|
"^(https?:\\/\\/)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*(\\?[;&a-z\\d%_.~+=-]*)?(\\#[-a-z\\d_]*)?$",
|
|
15392
15601
|
"i"
|
|
@@ -15421,11 +15630,11 @@ var ParameterImageInner = (0, import_react89.forwardRef)(
|
|
|
15421
15630
|
handleManuallySetErrorMessage(errorText);
|
|
15422
15631
|
}
|
|
15423
15632
|
};
|
|
15424
|
-
(0,
|
|
15633
|
+
(0, import_react92.useEffect)(() => {
|
|
15425
15634
|
updateImageSrc();
|
|
15426
15635
|
}, [deferredValue]);
|
|
15427
|
-
return /* @__PURE__ */ (0,
|
|
15428
|
-
/* @__PURE__ */ (0,
|
|
15636
|
+
return /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)(import_jsx_runtime85.Fragment, { children: [
|
|
15637
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
|
|
15429
15638
|
"input",
|
|
15430
15639
|
{
|
|
15431
15640
|
css: input2,
|
|
@@ -15437,8 +15646,8 @@ var ParameterImageInner = (0, import_react89.forwardRef)(
|
|
|
15437
15646
|
...props
|
|
15438
15647
|
}
|
|
15439
15648
|
),
|
|
15440
|
-
/* @__PURE__ */ (0,
|
|
15441
|
-
deferredValue && !errorMessage ? /* @__PURE__ */ (0,
|
|
15649
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { css: imageWrapper, children: [
|
|
15650
|
+
deferredValue && !errorMessage ? /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
|
|
15442
15651
|
"img",
|
|
15443
15652
|
{
|
|
15444
15653
|
src: deferredValue,
|
|
@@ -15449,24 +15658,24 @@ var ParameterImageInner = (0, import_react89.forwardRef)(
|
|
|
15449
15658
|
loading: "lazy"
|
|
15450
15659
|
}
|
|
15451
15660
|
) : null,
|
|
15452
|
-
deferredValue && errorMessage ? /* @__PURE__ */ (0,
|
|
15661
|
+
deferredValue && errorMessage ? /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(BrokenImage, { css: img }) : null
|
|
15453
15662
|
] }),
|
|
15454
|
-
loading ? /* @__PURE__ */ (0,
|
|
15663
|
+
loading ? /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(LoadingIcon, {}) : null
|
|
15455
15664
|
] });
|
|
15456
15665
|
}
|
|
15457
15666
|
);
|
|
15458
15667
|
|
|
15459
15668
|
// src/components/ParameterInputs/ParameterInput.tsx
|
|
15460
|
-
var
|
|
15461
|
-
var
|
|
15462
|
-
var ParameterInput = (0,
|
|
15669
|
+
var import_react93 = require("react");
|
|
15670
|
+
var import_jsx_runtime86 = require("@emotion/react/jsx-runtime");
|
|
15671
|
+
var ParameterInput = (0, import_react93.forwardRef)((props, ref) => {
|
|
15463
15672
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
15464
|
-
return /* @__PURE__ */ (0,
|
|
15673
|
+
return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(ParameterShell, { "data-test-id": "parameter-input", ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(ParameterInputInner, { ref, ...innerProps }) });
|
|
15465
15674
|
});
|
|
15466
|
-
var ParameterInputInner = (0,
|
|
15675
|
+
var ParameterInputInner = (0, import_react93.forwardRef)(
|
|
15467
15676
|
({ ...props }, ref) => {
|
|
15468
15677
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
15469
|
-
return /* @__PURE__ */ (0,
|
|
15678
|
+
return /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
15470
15679
|
"input",
|
|
15471
15680
|
{
|
|
15472
15681
|
css: input2,
|
|
@@ -15482,19 +15691,19 @@ var ParameterInputInner = (0, import_react90.forwardRef)(
|
|
|
15482
15691
|
);
|
|
15483
15692
|
|
|
15484
15693
|
// src/components/ParameterInputs/ParameterLink.tsx
|
|
15485
|
-
var
|
|
15486
|
-
var
|
|
15487
|
-
var ParameterLink = (0,
|
|
15694
|
+
var import_react94 = require("react");
|
|
15695
|
+
var import_jsx_runtime87 = require("@emotion/react/jsx-runtime");
|
|
15696
|
+
var ParameterLink = (0, import_react94.forwardRef)(
|
|
15488
15697
|
({ buttonText = "Select link", disabled, onConnectLink, externalLink, ...props }, ref) => {
|
|
15489
15698
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
15490
|
-
return /* @__PURE__ */ (0,
|
|
15699
|
+
return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
15491
15700
|
ParameterShell,
|
|
15492
15701
|
{
|
|
15493
15702
|
"data-test-id": "link-parameter-editor",
|
|
15494
15703
|
...shellProps,
|
|
15495
15704
|
label: innerProps.value ? shellProps.label : "",
|
|
15496
15705
|
title: !innerProps.value ? shellProps.label : void 0,
|
|
15497
|
-
children: !innerProps.value ? /* @__PURE__ */ (0,
|
|
15706
|
+
children: !innerProps.value ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("button", { type: "button", css: dataConnectButton, disabled, onClick: onConnectLink, children: buttonText }) : /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
15498
15707
|
ParameterLinkInner,
|
|
15499
15708
|
{
|
|
15500
15709
|
onConnectLink,
|
|
@@ -15507,11 +15716,11 @@ var ParameterLink = (0, import_react91.forwardRef)(
|
|
|
15507
15716
|
);
|
|
15508
15717
|
}
|
|
15509
15718
|
);
|
|
15510
|
-
var ParameterLinkInner = (0,
|
|
15719
|
+
var ParameterLinkInner = (0, import_react94.forwardRef)(
|
|
15511
15720
|
({ externalLink, onConnectLink, disabled, ...props }, ref) => {
|
|
15512
15721
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
15513
|
-
return /* @__PURE__ */ (0,
|
|
15514
|
-
/* @__PURE__ */ (0,
|
|
15722
|
+
return /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)("div", { css: inputWrapper, children: [
|
|
15723
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
15515
15724
|
"input",
|
|
15516
15725
|
{
|
|
15517
15726
|
type: "text",
|
|
@@ -15523,8 +15732,8 @@ var ParameterLinkInner = (0, import_react91.forwardRef)(
|
|
|
15523
15732
|
...props
|
|
15524
15733
|
}
|
|
15525
15734
|
),
|
|
15526
|
-
/* @__PURE__ */ (0,
|
|
15527
|
-
/* @__PURE__ */ (0,
|
|
15735
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsxs)("div", { css: linkParameterControls, children: [
|
|
15736
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
15528
15737
|
"button",
|
|
15529
15738
|
{
|
|
15530
15739
|
type: "button",
|
|
@@ -15535,7 +15744,7 @@ var ParameterLinkInner = (0, import_react91.forwardRef)(
|
|
|
15535
15744
|
children: "edit"
|
|
15536
15745
|
}
|
|
15537
15746
|
),
|
|
15538
|
-
externalLink ? /* @__PURE__ */ (0,
|
|
15747
|
+
externalLink ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
15539
15748
|
"a",
|
|
15540
15749
|
{
|
|
15541
15750
|
href: externalLink,
|
|
@@ -15543,7 +15752,7 @@ var ParameterLinkInner = (0, import_react91.forwardRef)(
|
|
|
15543
15752
|
title: "Open link in new tab",
|
|
15544
15753
|
target: "_blank",
|
|
15545
15754
|
rel: "noopener noreferrer",
|
|
15546
|
-
children: /* @__PURE__ */ (0,
|
|
15755
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(Icon, { icon: "arrows-expand-up-right", iconColor: "currentColor", size: "1rem" })
|
|
15547
15756
|
}
|
|
15548
15757
|
) : null
|
|
15549
15758
|
] })
|
|
@@ -15552,7 +15761,7 @@ var ParameterLinkInner = (0, import_react91.forwardRef)(
|
|
|
15552
15761
|
);
|
|
15553
15762
|
|
|
15554
15763
|
// src/components/ParameterInputs/ParameterNameAndPublicIdInput.tsx
|
|
15555
|
-
var
|
|
15764
|
+
var import_jsx_runtime88 = require("@emotion/react/jsx-runtime");
|
|
15556
15765
|
var ParameterNameAndPublicIdInput = ({
|
|
15557
15766
|
id,
|
|
15558
15767
|
onBlur,
|
|
@@ -15578,8 +15787,8 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
15578
15787
|
navigator.clipboard.writeText(values[publicIdFieldName]);
|
|
15579
15788
|
};
|
|
15580
15789
|
autoFocus == null ? void 0 : autoFocus();
|
|
15581
|
-
return /* @__PURE__ */ (0,
|
|
15582
|
-
/* @__PURE__ */ (0,
|
|
15790
|
+
return /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)(import_jsx_runtime88.Fragment, { children: [
|
|
15791
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
15583
15792
|
ParameterInput,
|
|
15584
15793
|
{
|
|
15585
15794
|
id: nameIdField,
|
|
@@ -15598,7 +15807,7 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
15598
15807
|
value: values[nameIdField]
|
|
15599
15808
|
}
|
|
15600
15809
|
),
|
|
15601
|
-
/* @__PURE__ */ (0,
|
|
15810
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
15602
15811
|
ParameterInput,
|
|
15603
15812
|
{
|
|
15604
15813
|
id: publicIdFieldName,
|
|
@@ -15612,11 +15821,11 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
15612
15821
|
caption: publicIdCaption,
|
|
15613
15822
|
placeholder: publicIdPlaceholderText,
|
|
15614
15823
|
errorMessage: publicIdError,
|
|
15615
|
-
menuItems: /* @__PURE__ */ (0,
|
|
15824
|
+
menuItems: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
15616
15825
|
MenuItem,
|
|
15617
15826
|
{
|
|
15618
15827
|
disabled: !values[publicIdFieldName],
|
|
15619
|
-
icon: /* @__PURE__ */ (0,
|
|
15828
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(Icon, { icon: "path-trim", iconColor: "currentColor" }),
|
|
15620
15829
|
onClick: handleCopyPidFieldValue,
|
|
15621
15830
|
children: "Copy"
|
|
15622
15831
|
}
|
|
@@ -15624,12 +15833,13 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
15624
15833
|
value: values[publicIdFieldName]
|
|
15625
15834
|
}
|
|
15626
15835
|
),
|
|
15627
|
-
(warnOverLength == null ? void 0 : warnOverLength.length) && values[publicIdFieldName].length > warnOverLength.length ? /* @__PURE__ */ (0,
|
|
15836
|
+
(warnOverLength == null ? void 0 : warnOverLength.length) && values[publicIdFieldName].length > warnOverLength.length ? /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(Callout, { type: "caution", children: warnOverLength.message }) : null
|
|
15628
15837
|
] });
|
|
15629
15838
|
};
|
|
15630
15839
|
|
|
15631
15840
|
// src/components/ParameterInputs/ParameterRichText.tsx
|
|
15632
|
-
var
|
|
15841
|
+
var import_react101 = require("@emotion/react");
|
|
15842
|
+
var import_code2 = require("@lexical/code");
|
|
15633
15843
|
var import_list3 = require("@lexical/list");
|
|
15634
15844
|
var import_LexicalComposer = require("@lexical/react/LexicalComposer");
|
|
15635
15845
|
var import_LexicalComposerContext4 = require("@lexical/react/LexicalComposerContext");
|
|
@@ -15641,7 +15851,7 @@ var import_LexicalRichTextPlugin = require("@lexical/react/LexicalRichTextPlugin
|
|
|
15641
15851
|
var import_rich_text2 = require("@lexical/rich-text");
|
|
15642
15852
|
var import_fast_equals2 = require("fast-equals");
|
|
15643
15853
|
var import_lexical5 = require("lexical");
|
|
15644
|
-
var
|
|
15854
|
+
var import_react102 = require("react");
|
|
15645
15855
|
|
|
15646
15856
|
// src/components/ParameterInputs/rich-text/builtInElements.ts
|
|
15647
15857
|
var richTextBuiltInElements = [
|
|
@@ -15680,6 +15890,14 @@ var richTextBuiltInElements = [
|
|
|
15680
15890
|
{
|
|
15681
15891
|
label: "Link",
|
|
15682
15892
|
type: "link"
|
|
15893
|
+
},
|
|
15894
|
+
{
|
|
15895
|
+
label: "Blockquote",
|
|
15896
|
+
type: "quote"
|
|
15897
|
+
},
|
|
15898
|
+
{
|
|
15899
|
+
label: "Code Block",
|
|
15900
|
+
type: "code"
|
|
15683
15901
|
}
|
|
15684
15902
|
];
|
|
15685
15903
|
|
|
@@ -15737,7 +15955,7 @@ var textCode = import_css.css`
|
|
|
15737
15955
|
border-radius: var(--rounded-sm);
|
|
15738
15956
|
display: inline-block;
|
|
15739
15957
|
font-family: var(--ff-mono);
|
|
15740
|
-
font-size:
|
|
15958
|
+
font-size: var(--fs-sm);
|
|
15741
15959
|
padding-left: var(--spacing-xs);
|
|
15742
15960
|
padding-right: var(--spacing-xs);
|
|
15743
15961
|
`;
|
|
@@ -15866,24 +16084,47 @@ var listItemElement = import_css.css`
|
|
|
15866
16084
|
var nestedListItemElement = import_css.css`
|
|
15867
16085
|
list-style-type: none;
|
|
15868
16086
|
`;
|
|
16087
|
+
var blockquoteElement = import_css.css`
|
|
16088
|
+
border-left: 0.25rem solid var(--gray-300);
|
|
16089
|
+
color: var(--gray-600);
|
|
16090
|
+
margin-bottom: var(--spacing-base);
|
|
16091
|
+
padding-left: var(--spacing-base);
|
|
16092
|
+
|
|
16093
|
+
&:last-child {
|
|
16094
|
+
margin-bottom: 0;
|
|
16095
|
+
}
|
|
16096
|
+
`;
|
|
16097
|
+
var codeElement = import_css.css`
|
|
16098
|
+
background-color: var(--gray-100);
|
|
16099
|
+
border-radius: var(--rounded-sm);
|
|
16100
|
+
display: block;
|
|
16101
|
+
font-family: var(--ff-mono);
|
|
16102
|
+
font-size: var(--fs-sm);
|
|
16103
|
+
margin-bottom: var(--spacing-base);
|
|
16104
|
+
padding: var(--spacing-sm);
|
|
16105
|
+
|
|
16106
|
+
&:last-child {
|
|
16107
|
+
margin-bottom: 0;
|
|
16108
|
+
}
|
|
16109
|
+
`;
|
|
15869
16110
|
|
|
15870
16111
|
// src/components/ParameterInputs/rich-text/LinkNodePlugin.tsx
|
|
15871
|
-
var
|
|
16112
|
+
var import_react96 = require("@emotion/react");
|
|
15872
16113
|
var import_LexicalComposerContext = require("@lexical/react/LexicalComposerContext");
|
|
15873
16114
|
var import_LexicalNodeEventPlugin = require("@lexical/react/LexicalNodeEventPlugin");
|
|
15874
16115
|
var import_utils2 = require("@lexical/utils");
|
|
15875
16116
|
var import_fast_equals = require("fast-equals");
|
|
15876
16117
|
var import_lexical2 = require("lexical");
|
|
15877
|
-
var
|
|
16118
|
+
var import_react97 = require("react");
|
|
15878
16119
|
|
|
15879
16120
|
// src/components/Popover/Popover.styles.ts
|
|
15880
|
-
var
|
|
15881
|
-
var PopoverBtn =
|
|
16121
|
+
var import_react95 = require("@emotion/react");
|
|
16122
|
+
var PopoverBtn = import_react95.css`
|
|
15882
16123
|
border: none;
|
|
15883
16124
|
background: none;
|
|
15884
16125
|
padding: 0;
|
|
15885
16126
|
`;
|
|
15886
|
-
var Popover =
|
|
16127
|
+
var Popover = import_react95.css`
|
|
15887
16128
|
border-left: var(--spacing-xs) solid var(--brand-secondary-3);
|
|
15888
16129
|
border-radius: var(--rounded-base);
|
|
15889
16130
|
box-shadow: var(--shadow-base);
|
|
@@ -15947,7 +16188,7 @@ var richTextIsValueConsideredEmpty = (value) => {
|
|
|
15947
16188
|
};
|
|
15948
16189
|
|
|
15949
16190
|
// src/components/ParameterInputs/rich-text/LinkNodePlugin.tsx
|
|
15950
|
-
var
|
|
16191
|
+
var import_jsx_runtime89 = require("@emotion/react/jsx-runtime");
|
|
15951
16192
|
var isProjectMapLinkValue = (value) => {
|
|
15952
16193
|
return (value == null ? void 0 : value.type) === "projectMapNode" && Boolean(
|
|
15953
16194
|
value.nodeId && value.path && value.projectMapId
|
|
@@ -16213,32 +16454,32 @@ var OPEN_LINK_NODE_MODAL_COMMAND = (0, import_lexical2.createCommand)(
|
|
|
16213
16454
|
);
|
|
16214
16455
|
var LINK_POPOVER_OFFSET_X = 0;
|
|
16215
16456
|
var LINK_POPOVER_OFFSET_Y = 8;
|
|
16216
|
-
var linkPopover =
|
|
16457
|
+
var linkPopover = import_react96.css`
|
|
16217
16458
|
position: absolute;
|
|
16218
16459
|
z-index: 5;
|
|
16219
16460
|
`;
|
|
16220
|
-
var linkPopoverContainer =
|
|
16461
|
+
var linkPopoverContainer = import_react96.css`
|
|
16221
16462
|
${Popover};
|
|
16222
16463
|
align-items: center;
|
|
16223
16464
|
display: flex;
|
|
16224
16465
|
`;
|
|
16225
|
-
var linkPopoverAnchor =
|
|
16466
|
+
var linkPopoverAnchor = import_react96.css`
|
|
16226
16467
|
${link}
|
|
16227
16468
|
${linkColorDefault}
|
|
16228
16469
|
`;
|
|
16229
16470
|
function LinkNodePlugin({ onConnectLink }) {
|
|
16230
16471
|
const [editor] = (0, import_LexicalComposerContext.useLexicalComposerContext)();
|
|
16231
|
-
const [linkPopoverState, setLinkPopoverState] = (0,
|
|
16232
|
-
const linkPopoverElRef = (0,
|
|
16233
|
-
const [isEditorFocused, setIsEditorFocused] = (0,
|
|
16234
|
-
const [isLinkPopoverFocused, setIsLinkPopoverFocused] = (0,
|
|
16235
|
-
(0,
|
|
16472
|
+
const [linkPopoverState, setLinkPopoverState] = (0, import_react97.useState)();
|
|
16473
|
+
const linkPopoverElRef = (0, import_react97.useRef)(null);
|
|
16474
|
+
const [isEditorFocused, setIsEditorFocused] = (0, import_react97.useState)(false);
|
|
16475
|
+
const [isLinkPopoverFocused, setIsLinkPopoverFocused] = (0, import_react97.useState)(false);
|
|
16476
|
+
(0, import_react97.useEffect)(() => {
|
|
16236
16477
|
if (!isEditorFocused && !isLinkPopoverFocused) {
|
|
16237
16478
|
setLinkPopoverState(void 0);
|
|
16238
16479
|
return;
|
|
16239
16480
|
}
|
|
16240
16481
|
}, [isEditorFocused, isLinkPopoverFocused]);
|
|
16241
|
-
(0,
|
|
16482
|
+
(0, import_react97.useEffect)(() => {
|
|
16242
16483
|
if (!editor.hasNodes([LinkNode])) {
|
|
16243
16484
|
throw new Error("LinkNode not registered on editor");
|
|
16244
16485
|
}
|
|
@@ -16299,7 +16540,7 @@ function LinkNodePlugin({ onConnectLink }) {
|
|
|
16299
16540
|
)
|
|
16300
16541
|
);
|
|
16301
16542
|
}, [editor, onConnectLink]);
|
|
16302
|
-
const maybeShowLinkToolbar = (0,
|
|
16543
|
+
const maybeShowLinkToolbar = (0, import_react97.useCallback)(() => {
|
|
16303
16544
|
if (!editor.isEditable()) {
|
|
16304
16545
|
return;
|
|
16305
16546
|
}
|
|
@@ -16331,7 +16572,7 @@ function LinkNodePlugin({ onConnectLink }) {
|
|
|
16331
16572
|
}
|
|
16332
16573
|
});
|
|
16333
16574
|
}, [editor]);
|
|
16334
|
-
(0,
|
|
16575
|
+
(0, import_react97.useEffect)(() => {
|
|
16335
16576
|
return editor.registerUpdateListener(({ editorState }) => {
|
|
16336
16577
|
requestAnimationFrame(() => {
|
|
16337
16578
|
editorState.read(() => {
|
|
@@ -16358,8 +16599,8 @@ function LinkNodePlugin({ onConnectLink }) {
|
|
|
16358
16599
|
});
|
|
16359
16600
|
});
|
|
16360
16601
|
};
|
|
16361
|
-
return /* @__PURE__ */ (0,
|
|
16362
|
-
/* @__PURE__ */ (0,
|
|
16602
|
+
return /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(import_jsx_runtime89.Fragment, { children: [
|
|
16603
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
16363
16604
|
import_LexicalNodeEventPlugin.NodeEventPlugin,
|
|
16364
16605
|
{
|
|
16365
16606
|
nodeType: LinkNode,
|
|
@@ -16369,7 +16610,7 @@ function LinkNodePlugin({ onConnectLink }) {
|
|
|
16369
16610
|
}
|
|
16370
16611
|
}
|
|
16371
16612
|
),
|
|
16372
|
-
linkPopoverState ? /* @__PURE__ */ (0,
|
|
16613
|
+
linkPopoverState ? /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
16373
16614
|
"div",
|
|
16374
16615
|
{
|
|
16375
16616
|
css: linkPopover,
|
|
@@ -16378,8 +16619,8 @@ function LinkNodePlugin({ onConnectLink }) {
|
|
|
16378
16619
|
top: linkPopoverState.position.y
|
|
16379
16620
|
},
|
|
16380
16621
|
ref: linkPopoverElRef,
|
|
16381
|
-
children: /* @__PURE__ */ (0,
|
|
16382
|
-
linkPopoverState.node.__link.type === "projectMapNode" ? linkPopoverState.node.__link.path : /* @__PURE__ */ (0,
|
|
16622
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { css: linkPopoverContainer, children: [
|
|
16623
|
+
linkPopoverState.node.__link.type === "projectMapNode" ? linkPopoverState.node.__link.path : /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
16383
16624
|
"a",
|
|
16384
16625
|
{
|
|
16385
16626
|
href: `${linkPopoverState.node.__link.type === "email" ? "mailto:" : linkPopoverState.node.__link.type === "tel" ? "tel:" : ""}${linkPopoverState.node.__link.path}`,
|
|
@@ -16389,7 +16630,7 @@ function LinkNodePlugin({ onConnectLink }) {
|
|
|
16389
16630
|
children: linkPopoverState.node.__link.path
|
|
16390
16631
|
}
|
|
16391
16632
|
),
|
|
16392
|
-
/* @__PURE__ */ (0,
|
|
16633
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
16393
16634
|
Button,
|
|
16394
16635
|
{
|
|
16395
16636
|
size: "xs",
|
|
@@ -16397,7 +16638,7 @@ function LinkNodePlugin({ onConnectLink }) {
|
|
|
16397
16638
|
onEditLinkNode(linkPopoverState.node);
|
|
16398
16639
|
},
|
|
16399
16640
|
buttonType: "ghost",
|
|
16400
|
-
children: /* @__PURE__ */ (0,
|
|
16641
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(Icon, { icon: "pen", size: "1rem", title: "Edit link" })
|
|
16401
16642
|
}
|
|
16402
16643
|
)
|
|
16403
16644
|
] })
|
|
@@ -16416,8 +16657,8 @@ var import_list = require("@lexical/list");
|
|
|
16416
16657
|
var import_LexicalComposerContext2 = require("@lexical/react/LexicalComposerContext");
|
|
16417
16658
|
var import_LexicalTabIndentationPlugin = require("@lexical/react/LexicalTabIndentationPlugin");
|
|
16418
16659
|
var import_lexical3 = require("lexical");
|
|
16419
|
-
var
|
|
16420
|
-
var
|
|
16660
|
+
var import_react98 = require("react");
|
|
16661
|
+
var import_jsx_runtime90 = require("@emotion/react/jsx-runtime");
|
|
16421
16662
|
function isIndentPermitted(maxDepth) {
|
|
16422
16663
|
const selection = (0, import_lexical3.$getSelection)();
|
|
16423
16664
|
if (!(0, import_lexical3.$isRangeSelection)(selection)) {
|
|
@@ -16440,27 +16681,29 @@ function isIndentPermitted(maxDepth) {
|
|
|
16440
16681
|
}
|
|
16441
16682
|
function ListIndentPlugin({ maxDepth }) {
|
|
16442
16683
|
const [editor] = (0, import_LexicalComposerContext2.useLexicalComposerContext)();
|
|
16443
|
-
(0,
|
|
16684
|
+
(0, import_react98.useEffect)(() => {
|
|
16444
16685
|
return editor.registerCommand(
|
|
16445
16686
|
import_lexical3.INDENT_CONTENT_COMMAND,
|
|
16446
16687
|
() => !isIndentPermitted(maxDepth),
|
|
16447
16688
|
import_lexical3.COMMAND_PRIORITY_CRITICAL
|
|
16448
16689
|
);
|
|
16449
16690
|
}, [editor, maxDepth]);
|
|
16450
|
-
return /* @__PURE__ */ (0,
|
|
16691
|
+
return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(import_LexicalTabIndentationPlugin.TabIndentationPlugin, {});
|
|
16451
16692
|
}
|
|
16452
16693
|
|
|
16453
16694
|
// src/components/ParameterInputs/rich-text/RichTextToolbar.tsx
|
|
16454
|
-
var
|
|
16695
|
+
var import_react99 = require("@emotion/react");
|
|
16696
|
+
var import_code = require("@lexical/code");
|
|
16455
16697
|
var import_list2 = require("@lexical/list");
|
|
16456
16698
|
var import_LexicalComposerContext3 = require("@lexical/react/LexicalComposerContext");
|
|
16699
|
+
var import_LexicalDecoratorBlockNode = require("@lexical/react/LexicalDecoratorBlockNode");
|
|
16457
16700
|
var import_rich_text = require("@lexical/rich-text");
|
|
16458
16701
|
var import_selection2 = require("@lexical/selection");
|
|
16459
16702
|
var import_utils5 = require("@lexical/utils");
|
|
16460
16703
|
var import_lexical4 = require("lexical");
|
|
16461
|
-
var
|
|
16462
|
-
var
|
|
16463
|
-
var toolbar =
|
|
16704
|
+
var import_react100 = require("react");
|
|
16705
|
+
var import_jsx_runtime91 = require("@emotion/react/jsx-runtime");
|
|
16706
|
+
var toolbar = import_react99.css`
|
|
16464
16707
|
background: var(--gray-50);
|
|
16465
16708
|
border-radius: var(--rounded-base);
|
|
16466
16709
|
display: flex;
|
|
@@ -16472,7 +16715,7 @@ var toolbar = import_react96.css`
|
|
|
16472
16715
|
top: 0;
|
|
16473
16716
|
z-index: 10;
|
|
16474
16717
|
`;
|
|
16475
|
-
var toolbarGroup =
|
|
16718
|
+
var toolbarGroup = import_react99.css`
|
|
16476
16719
|
display: flex;
|
|
16477
16720
|
gap: var(--spacing-xs);
|
|
16478
16721
|
position: relative;
|
|
@@ -16488,7 +16731,7 @@ var toolbarGroup = import_react96.css`
|
|
|
16488
16731
|
width: 1px;
|
|
16489
16732
|
}
|
|
16490
16733
|
`;
|
|
16491
|
-
var toolbarButton =
|
|
16734
|
+
var toolbarButton = import_react99.css`
|
|
16492
16735
|
align-items: center;
|
|
16493
16736
|
appearance: none;
|
|
16494
16737
|
border: 0;
|
|
@@ -16501,17 +16744,17 @@ var toolbarButton = import_react96.css`
|
|
|
16501
16744
|
min-width: 32px;
|
|
16502
16745
|
padding: 0 var(--spacing-sm);
|
|
16503
16746
|
`;
|
|
16504
|
-
var toolbarButtonActive =
|
|
16747
|
+
var toolbarButtonActive = import_react99.css`
|
|
16505
16748
|
background: var(--gray-200);
|
|
16506
16749
|
`;
|
|
16507
|
-
var toolbarIcon =
|
|
16750
|
+
var toolbarIcon = import_react99.css`
|
|
16508
16751
|
color: inherit;
|
|
16509
16752
|
`;
|
|
16510
|
-
var toolbarChevron =
|
|
16753
|
+
var toolbarChevron = import_react99.css`
|
|
16511
16754
|
margin-left: var(--spacing-xs);
|
|
16512
16755
|
`;
|
|
16513
16756
|
var ToolbarIcon = ({ icon }) => {
|
|
16514
|
-
return /* @__PURE__ */ (0,
|
|
16757
|
+
return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Icon, { icon, css: toolbarIcon, size: "1rem" });
|
|
16515
16758
|
};
|
|
16516
16759
|
var RichTextToolbar = ({ config }) => {
|
|
16517
16760
|
const [editor] = (0, import_LexicalComposerContext3.useLexicalComposerContext)();
|
|
@@ -16527,7 +16770,6 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16527
16770
|
return (_b = (_a = config == null ? void 0 : config.elements) == null ? void 0 : _a.builtIn) == null ? void 0 : _b.includes(element.type);
|
|
16528
16771
|
}
|
|
16529
16772
|
);
|
|
16530
|
-
const showToolbar = enabledBuiltInFormats.length > 0 || enabledBuiltInElements.length > 0;
|
|
16531
16773
|
const formatsWithIcon = /* @__PURE__ */ new Map([
|
|
16532
16774
|
["bold", "format-bold"],
|
|
16533
16775
|
["italic", "format-italic"],
|
|
@@ -16543,8 +16785,8 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16543
16785
|
const enabledBuiltInFormatsWithoutIcon = enabledBuiltInFormats.filter(
|
|
16544
16786
|
(format) => !formatsWithIcon.has(format.type)
|
|
16545
16787
|
);
|
|
16546
|
-
const [activeFormats, setActiveFormats] = (0,
|
|
16547
|
-
const [activeElement, setActiveElement] = (0,
|
|
16788
|
+
const [activeFormats, setActiveFormats] = (0, import_react100.useState)([]);
|
|
16789
|
+
const [activeElement, setActiveElement] = (0, import_react100.useState)("paragraph");
|
|
16548
16790
|
const enabledTextualElements = enabledBuiltInElements.filter(
|
|
16549
16791
|
(element) => ["h1", "h2", "h3", "h4", "h5", "h6"].includes(element.type)
|
|
16550
16792
|
);
|
|
@@ -16553,7 +16795,7 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16553
16795
|
if (type === "paragraph") {
|
|
16554
16796
|
return "Normal";
|
|
16555
16797
|
}
|
|
16556
|
-
const element =
|
|
16798
|
+
const element = richTextBuiltInElements.find((element2) => element2.type === type);
|
|
16557
16799
|
return (_a = element == null ? void 0 : element.label) != null ? _a : type;
|
|
16558
16800
|
};
|
|
16559
16801
|
const onSelectElement = (type) => {
|
|
@@ -16569,19 +16811,29 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16569
16811
|
(0, import_selection2.$setBlocksType)(selection, () => (0, import_rich_text.$createHeadingNode)(type));
|
|
16570
16812
|
} else if (type === "paragraph") {
|
|
16571
16813
|
(0, import_selection2.$setBlocksType)(selection, () => (0, import_lexical4.$createParagraphNode)());
|
|
16814
|
+
} else if (type === "quote") {
|
|
16815
|
+
(0, import_selection2.$setBlocksType)(selection, () => (0, import_rich_text.$createQuoteNode)());
|
|
16816
|
+
} else if (type === "code") {
|
|
16817
|
+
(0, import_selection2.$setBlocksType)(selection, () => (0, import_code.$createCodeNode)());
|
|
16572
16818
|
}
|
|
16573
16819
|
});
|
|
16574
16820
|
};
|
|
16575
|
-
const [isLink, setIsLink] = (0,
|
|
16576
|
-
const linkElementEnabled = (0,
|
|
16821
|
+
const [isLink, setIsLink] = (0, import_react100.useState)(false);
|
|
16822
|
+
const linkElementEnabled = (0, import_react100.useMemo)(() => {
|
|
16577
16823
|
return enabledBuiltInElements.some((element) => element.type === "link");
|
|
16578
16824
|
}, [enabledBuiltInElements]);
|
|
16579
|
-
const enabledLists = (0,
|
|
16825
|
+
const enabledLists = (0, import_react100.useMemo)(() => {
|
|
16580
16826
|
return new Set(
|
|
16581
16827
|
enabledBuiltInElements.filter((element) => ["orderedList", "unorderedList"].includes(element.type)).map((element) => element.type)
|
|
16582
16828
|
);
|
|
16583
16829
|
}, [enabledBuiltInElements]);
|
|
16584
|
-
const
|
|
16830
|
+
const quoteElementEnabled = (0, import_react100.useMemo)(() => {
|
|
16831
|
+
return enabledBuiltInElements.some((element) => element.type === "quote");
|
|
16832
|
+
}, [enabledBuiltInElements]);
|
|
16833
|
+
const codeElementEnabled = (0, import_react100.useMemo)(() => {
|
|
16834
|
+
return enabledBuiltInElements.some((element) => element.type === "code");
|
|
16835
|
+
}, [enabledBuiltInElements]);
|
|
16836
|
+
const updateToolbar = (0, import_react100.useCallback)(() => {
|
|
16585
16837
|
const selection = (0, import_lexical4.$getSelection)();
|
|
16586
16838
|
if (!(0, import_lexical4.$isRangeSelection)(selection)) {
|
|
16587
16839
|
return;
|
|
@@ -16620,7 +16872,7 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16620
16872
|
setIsLink(false);
|
|
16621
16873
|
}
|
|
16622
16874
|
}, [editor, enabledBuiltInFormats]);
|
|
16623
|
-
(0,
|
|
16875
|
+
(0, import_react100.useEffect)(() => {
|
|
16624
16876
|
return editor.registerCommand(
|
|
16625
16877
|
import_lexical4.SELECTION_CHANGE_COMMAND,
|
|
16626
16878
|
(_payload) => {
|
|
@@ -16630,7 +16882,7 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16630
16882
|
import_lexical4.COMMAND_PRIORITY_CRITICAL
|
|
16631
16883
|
);
|
|
16632
16884
|
}, [editor, updateToolbar]);
|
|
16633
|
-
(0,
|
|
16885
|
+
(0, import_react100.useEffect)(() => {
|
|
16634
16886
|
return editor.registerUpdateListener(({ editorState }) => {
|
|
16635
16887
|
requestAnimationFrame(() => {
|
|
16636
16888
|
editorState.read(() => {
|
|
@@ -16639,18 +16891,65 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16639
16891
|
});
|
|
16640
16892
|
});
|
|
16641
16893
|
}, [editor, updateToolbar]);
|
|
16642
|
-
|
|
16643
|
-
|
|
16644
|
-
|
|
16645
|
-
|
|
16646
|
-
|
|
16894
|
+
const clearFormatting2 = (0, import_react100.useCallback)(() => {
|
|
16895
|
+
editor.update(() => {
|
|
16896
|
+
const selection = (0, import_lexical4.$getSelection)();
|
|
16897
|
+
if ((0, import_lexical4.$isRangeSelection)(selection)) {
|
|
16898
|
+
const anchor = selection.anchor;
|
|
16899
|
+
const focus = selection.focus;
|
|
16900
|
+
const nodes = selection.getNodes();
|
|
16901
|
+
if (anchor.key === focus.key && anchor.offset === focus.offset) {
|
|
16902
|
+
return;
|
|
16903
|
+
}
|
|
16904
|
+
nodes.forEach((node, idx) => {
|
|
16905
|
+
if ((0, import_lexical4.$isTextNode)(node)) {
|
|
16906
|
+
if (idx === 0 && anchor.offset !== 0) {
|
|
16907
|
+
node = node.splitText(anchor.offset)[1] || node;
|
|
16908
|
+
}
|
|
16909
|
+
if (idx === nodes.length - 1) {
|
|
16910
|
+
node = node.splitText(focus.offset)[0] || node;
|
|
16911
|
+
}
|
|
16912
|
+
if (node.__style !== "") {
|
|
16913
|
+
node.setStyle("");
|
|
16914
|
+
}
|
|
16915
|
+
if (node.__format !== 0) {
|
|
16916
|
+
node.setFormat(0);
|
|
16917
|
+
(0, import_utils5.$getNearestBlockElementAncestorOrThrow)(node).setFormat("");
|
|
16918
|
+
}
|
|
16919
|
+
} else if ((0, import_rich_text.$isHeadingNode)(node) || (0, import_rich_text.$isQuoteNode)(node)) {
|
|
16920
|
+
node.replace((0, import_lexical4.$createParagraphNode)(), true);
|
|
16921
|
+
} else if ((0, import_LexicalDecoratorBlockNode.$isDecoratorBlockNode)(node)) {
|
|
16922
|
+
node.setFormat("");
|
|
16923
|
+
}
|
|
16924
|
+
});
|
|
16925
|
+
}
|
|
16926
|
+
updateToolbar();
|
|
16927
|
+
});
|
|
16928
|
+
}, [editor, updateToolbar]);
|
|
16929
|
+
const elementsThatShouldBeVisibleInDropdown = (0, import_react100.useMemo)(() => {
|
|
16930
|
+
if (activeElement === "paragraph") {
|
|
16931
|
+
return enabledTextualElements;
|
|
16932
|
+
}
|
|
16933
|
+
if (enabledBuiltInElements.some((element) => element.type === activeElement)) {
|
|
16934
|
+
return enabledTextualElements;
|
|
16935
|
+
}
|
|
16936
|
+
return [
|
|
16937
|
+
...enabledTextualElements,
|
|
16938
|
+
{
|
|
16939
|
+
label: elementTypeToLabel(activeElement),
|
|
16940
|
+
type: activeElement
|
|
16941
|
+
}
|
|
16942
|
+
];
|
|
16943
|
+
}, [enabledBuiltInElements, enabledTextualElements, activeElement]);
|
|
16944
|
+
return /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { css: toolbar, children: [
|
|
16945
|
+
elementsThatShouldBeVisibleInDropdown.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
16647
16946
|
Menu,
|
|
16648
16947
|
{
|
|
16649
16948
|
menuLabel: "Elements",
|
|
16650
|
-
menuTrigger: /* @__PURE__ */ (0,
|
|
16651
|
-
|
|
16949
|
+
menuTrigger: /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("button", { css: toolbarButton, title: "Text formatting", children: [
|
|
16950
|
+
elementsThatShouldBeVisibleInDropdown.some((element) => element.type === activeElement) ? elementTypeToLabel(activeElement) : elementTypeToLabel("paragraph"),
|
|
16652
16951
|
" ",
|
|
16653
|
-
/* @__PURE__ */ (0,
|
|
16952
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Icon, { icon: "chevron-down", css: [toolbarIcon, toolbarChevron], size: "1rem" })
|
|
16654
16953
|
] }),
|
|
16655
16954
|
placement: "bottom-start",
|
|
16656
16955
|
children: [
|
|
@@ -16658,8 +16957,8 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16658
16957
|
label: "Normal",
|
|
16659
16958
|
type: "paragraph"
|
|
16660
16959
|
},
|
|
16661
|
-
...
|
|
16662
|
-
].map((element) => /* @__PURE__ */ (0,
|
|
16960
|
+
...elementsThatShouldBeVisibleInDropdown
|
|
16961
|
+
].map((element) => /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
16663
16962
|
MenuItem,
|
|
16664
16963
|
{
|
|
16665
16964
|
onClick: () => {
|
|
@@ -16671,24 +16970,24 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16671
16970
|
))
|
|
16672
16971
|
}
|
|
16673
16972
|
) : null,
|
|
16674
|
-
enabledBuiltInFormatsWithIcon.length > 0 || enabledBuiltInFormatsWithoutIcon.length > 0 ? /* @__PURE__ */ (0,
|
|
16675
|
-
enabledBuiltInFormatsWithIcon.map((format) => /* @__PURE__ */ (0,
|
|
16973
|
+
enabledBuiltInFormatsWithIcon.length > 0 || enabledBuiltInFormatsWithoutIcon.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { css: toolbarGroup, children: [
|
|
16974
|
+
enabledBuiltInFormatsWithIcon.map((format) => /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Tooltip, { title: format.label, placement: "top", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
16676
16975
|
"button",
|
|
16677
16976
|
{
|
|
16678
16977
|
onClick: () => {
|
|
16679
16978
|
editor.dispatchCommand(import_lexical4.FORMAT_TEXT_COMMAND, format.type);
|
|
16680
16979
|
},
|
|
16681
16980
|
css: [toolbarButton, activeFormats.includes(format.type) ? toolbarButtonActive : null],
|
|
16682
|
-
children: /* @__PURE__ */ (0,
|
|
16981
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ToolbarIcon, { icon: formatsWithIcon.get(format.type) })
|
|
16683
16982
|
}
|
|
16684
16983
|
) }, format.type)),
|
|
16685
|
-
enabledBuiltInFormatsWithoutIcon.length > 0 ? /* @__PURE__ */ (0,
|
|
16984
|
+
enabledBuiltInFormatsWithoutIcon.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
16686
16985
|
Menu,
|
|
16687
16986
|
{
|
|
16688
16987
|
menuLabel: "Text formatting",
|
|
16689
|
-
menuTrigger: /* @__PURE__ */ (0,
|
|
16988
|
+
menuTrigger: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)("button", { css: toolbarButton, title: "Text formatting", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Icon, { icon: "more-alt", css: toolbarIcon }) }),
|
|
16690
16989
|
placement: "bottom-start",
|
|
16691
|
-
children: enabledBuiltInFormatsWithoutIcon.map((format) => /* @__PURE__ */ (0,
|
|
16990
|
+
children: enabledBuiltInFormatsWithoutIcon.map((format) => /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
16692
16991
|
MenuItem,
|
|
16693
16992
|
{
|
|
16694
16993
|
onClick: () => {
|
|
@@ -16701,46 +17000,87 @@ var RichTextToolbar = ({ config }) => {
|
|
|
16701
17000
|
}
|
|
16702
17001
|
) : null
|
|
16703
17002
|
] }) : null,
|
|
16704
|
-
linkElementEnabled || enabledLists.size > 0 ? /* @__PURE__ */ (0,
|
|
16705
|
-
linkElementEnabled ? /* @__PURE__ */ (0,
|
|
17003
|
+
linkElementEnabled || enabledLists.size > 0 || quoteElementEnabled || codeElementEnabled ? /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { css: toolbarGroup, children: [
|
|
17004
|
+
linkElementEnabled ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Tooltip, { title: "Link", placement: "top", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
16706
17005
|
"button",
|
|
16707
17006
|
{
|
|
16708
17007
|
onClick: () => {
|
|
16709
17008
|
editor.dispatchCommand(OPEN_LINK_NODE_MODAL_COMMAND, {});
|
|
16710
17009
|
},
|
|
16711
17010
|
css: [toolbarButton, isLink ? toolbarButtonActive : null],
|
|
16712
|
-
children: /* @__PURE__ */ (0,
|
|
17011
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ToolbarIcon, { icon: "link" })
|
|
16713
17012
|
}
|
|
16714
17013
|
) }) : null,
|
|
16715
|
-
enabledLists.size > 0 ? /* @__PURE__ */ (0,
|
|
16716
|
-
enabledLists.has("unorderedList") ? /* @__PURE__ */ (0,
|
|
17014
|
+
enabledLists.size > 0 ? /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)(import_jsx_runtime91.Fragment, { children: [
|
|
17015
|
+
enabledLists.has("unorderedList") ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Tooltip, { title: "Bullet list", placement: "top", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
16717
17016
|
"button",
|
|
16718
17017
|
{
|
|
16719
17018
|
onClick: () => {
|
|
16720
17019
|
activeElement === "unorderedList" ? editor.dispatchCommand(import_list2.REMOVE_LIST_COMMAND, void 0) : editor.dispatchCommand(import_list2.INSERT_UNORDERED_LIST_COMMAND, void 0);
|
|
16721
17020
|
},
|
|
16722
17021
|
css: [toolbarButton, activeElement === "unorderedList" ? toolbarButtonActive : null],
|
|
16723
|
-
children: /* @__PURE__ */ (0,
|
|
17022
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ToolbarIcon, { icon: "layout-list" })
|
|
16724
17023
|
}
|
|
16725
17024
|
) }) : null,
|
|
16726
|
-
enabledLists.has("orderedList") ? /* @__PURE__ */ (0,
|
|
17025
|
+
enabledLists.has("orderedList") ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Tooltip, { title: "Numbered list", placement: "top", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
16727
17026
|
"button",
|
|
16728
17027
|
{
|
|
16729
17028
|
onClick: () => {
|
|
16730
17029
|
activeElement === "orderedList" ? editor.dispatchCommand(import_list2.REMOVE_LIST_COMMAND, void 0) : editor.dispatchCommand(import_list2.INSERT_ORDERED_LIST_COMMAND, void 0);
|
|
16731
17030
|
},
|
|
16732
17031
|
css: [toolbarButton, activeElement === "orderedList" ? toolbarButtonActive : null],
|
|
16733
|
-
children: /* @__PURE__ */ (0,
|
|
17032
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ToolbarIcon, { icon: "layout-list-numbered" })
|
|
16734
17033
|
}
|
|
16735
17034
|
) }) : null
|
|
16736
|
-
] }) : null
|
|
16737
|
-
|
|
17035
|
+
] }) : null,
|
|
17036
|
+
quoteElementEnabled ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Tooltip, { title: "Blockquote", placement: "top", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
17037
|
+
"button",
|
|
17038
|
+
{
|
|
17039
|
+
onClick: () => {
|
|
17040
|
+
activeElement === "quote" ? onSelectElement("paragraph") : onSelectElement("quote");
|
|
17041
|
+
},
|
|
17042
|
+
css: [toolbarButton, activeElement === "quote" ? toolbarButtonActive : null],
|
|
17043
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ToolbarIcon, { icon: "quote" })
|
|
17044
|
+
}
|
|
17045
|
+
) }) : null,
|
|
17046
|
+
codeElementEnabled ? /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Tooltip, { title: "Code", placement: "top", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
17047
|
+
"button",
|
|
17048
|
+
{
|
|
17049
|
+
onClick: () => {
|
|
17050
|
+
activeElement === "code" ? onSelectElement("paragraph") : onSelectElement("code");
|
|
17051
|
+
},
|
|
17052
|
+
css: [toolbarButton, activeElement === "code" ? toolbarButtonActive : null],
|
|
17053
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ToolbarIcon, { icon: "code-slash" })
|
|
17054
|
+
}
|
|
17055
|
+
) }) : null
|
|
17056
|
+
] }) : null,
|
|
17057
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
17058
|
+
"div",
|
|
17059
|
+
{
|
|
17060
|
+
css: [
|
|
17061
|
+
toolbarGroup,
|
|
17062
|
+
{
|
|
17063
|
+
marginLeft: "auto"
|
|
17064
|
+
}
|
|
17065
|
+
],
|
|
17066
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Tooltip, { title: "Clear formatting", placement: "top", children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
17067
|
+
"button",
|
|
17068
|
+
{
|
|
17069
|
+
onClick: () => {
|
|
17070
|
+
clearFormatting2();
|
|
17071
|
+
},
|
|
17072
|
+
css: [toolbarButton],
|
|
17073
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(ToolbarIcon, { icon: "clear-formatting" })
|
|
17074
|
+
}
|
|
17075
|
+
) })
|
|
17076
|
+
}
|
|
17077
|
+
)
|
|
16738
17078
|
] });
|
|
16739
17079
|
};
|
|
16740
17080
|
var RichTextToolbar_default = RichTextToolbar;
|
|
16741
17081
|
|
|
16742
17082
|
// src/components/ParameterInputs/ParameterRichText.tsx
|
|
16743
|
-
var
|
|
17083
|
+
var import_jsx_runtime92 = require("@emotion/react/jsx-runtime");
|
|
16744
17084
|
var ParameterRichText = ({
|
|
16745
17085
|
label,
|
|
16746
17086
|
labelLeadingIcon,
|
|
@@ -16761,7 +17101,7 @@ var ParameterRichText = ({
|
|
|
16761
17101
|
editorInputClassName,
|
|
16762
17102
|
editorFooter
|
|
16763
17103
|
}) => {
|
|
16764
|
-
return /* @__PURE__ */ (0,
|
|
17104
|
+
return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(
|
|
16765
17105
|
ParameterShell,
|
|
16766
17106
|
{
|
|
16767
17107
|
"data-test-id": "parameter-input",
|
|
@@ -16775,7 +17115,7 @@ var ParameterRichText = ({
|
|
|
16775
17115
|
captionTestId,
|
|
16776
17116
|
menuItems,
|
|
16777
17117
|
children: [
|
|
16778
|
-
/* @__PURE__ */ (0,
|
|
17118
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
|
|
16779
17119
|
ParameterRichTextInner,
|
|
16780
17120
|
{
|
|
16781
17121
|
value,
|
|
@@ -16789,23 +17129,23 @@ var ParameterRichText = ({
|
|
|
16789
17129
|
editorFooter
|
|
16790
17130
|
}
|
|
16791
17131
|
),
|
|
16792
|
-
menuItems ? /* @__PURE__ */ (0,
|
|
17132
|
+
menuItems ? /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(ParameterMenuButton, { label: `${label} menu`, children: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_jsx_runtime92.Fragment, { children: menuItems }) }) : null
|
|
16793
17133
|
]
|
|
16794
17134
|
}
|
|
16795
17135
|
);
|
|
16796
17136
|
};
|
|
16797
|
-
var editorWrapper =
|
|
17137
|
+
var editorWrapper = import_react101.css`
|
|
16798
17138
|
display: flex;
|
|
16799
17139
|
flex-flow: column;
|
|
16800
17140
|
flex-grow: 1;
|
|
16801
17141
|
`;
|
|
16802
|
-
var editorContainer =
|
|
17142
|
+
var editorContainer = import_react101.css`
|
|
16803
17143
|
display: flex;
|
|
16804
17144
|
flex-flow: column;
|
|
16805
17145
|
flex-grow: 1;
|
|
16806
17146
|
position: relative;
|
|
16807
17147
|
`;
|
|
16808
|
-
var editorPlaceholder =
|
|
17148
|
+
var editorPlaceholder = import_react101.css`
|
|
16809
17149
|
color: var(--gray-500);
|
|
16810
17150
|
font-style: italic;
|
|
16811
17151
|
/* 1px is added to make sure caret is clearly visible when field is focused
|
|
@@ -16816,11 +17156,11 @@ var editorPlaceholder = import_react98.css`
|
|
|
16816
17156
|
top: var(--spacing-xs);
|
|
16817
17157
|
user-select: none;
|
|
16818
17158
|
`;
|
|
16819
|
-
var editorInput =
|
|
17159
|
+
var editorInput = import_react101.css`
|
|
16820
17160
|
background: var(--white);
|
|
16821
17161
|
border: 1px solid var(--white);
|
|
16822
17162
|
border-radius: var(--rounded-sm);
|
|
16823
|
-
color: var(--gray-
|
|
17163
|
+
color: var(--gray-900);
|
|
16824
17164
|
flex-grow: 1;
|
|
16825
17165
|
font-size: var(--fs-base);
|
|
16826
17166
|
line-height: 1.2;
|
|
@@ -16852,7 +17192,7 @@ var ParameterRichTextInner = ({
|
|
|
16852
17192
|
console.error(error);
|
|
16853
17193
|
},
|
|
16854
17194
|
editorState: value ? JSON.stringify(value) : void 0,
|
|
16855
|
-
nodes: [import_list3.ListNode, import_list3.ListItemNode, LinkNode, import_rich_text2.HeadingNode, import_lexical5.ParagraphNode],
|
|
17195
|
+
nodes: [import_list3.ListNode, import_list3.ListItemNode, LinkNode, import_rich_text2.HeadingNode, import_rich_text2.QuoteNode, import_code2.CodeNode, import_lexical5.ParagraphNode],
|
|
16856
17196
|
theme: {
|
|
16857
17197
|
text: {
|
|
16858
17198
|
bold: textBold,
|
|
@@ -16881,12 +17221,14 @@ var ParameterRichTextInner = ({
|
|
|
16881
17221
|
nested: {
|
|
16882
17222
|
listitem: nestedListItemElement
|
|
16883
17223
|
}
|
|
16884
|
-
}
|
|
17224
|
+
},
|
|
17225
|
+
quote: blockquoteElement,
|
|
17226
|
+
code: codeElement
|
|
16885
17227
|
},
|
|
16886
17228
|
editable: !readOnly
|
|
16887
17229
|
};
|
|
16888
|
-
return /* @__PURE__ */ (0,
|
|
16889
|
-
/* @__PURE__ */ (0,
|
|
17230
|
+
return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(import_jsx_runtime92.Fragment, { children: [
|
|
17231
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { css: [editorWrapper], className: editorWrapperClassName, children: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_LexicalComposer.LexicalComposer, { initialConfig: lexicalConfig, children: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
|
|
16890
17232
|
RichText,
|
|
16891
17233
|
{
|
|
16892
17234
|
onChange,
|
|
@@ -16908,14 +17250,14 @@ var RichText = ({
|
|
|
16908
17250
|
readOnly,
|
|
16909
17251
|
editorInputClassName
|
|
16910
17252
|
}) => {
|
|
16911
|
-
const editorContainerRef = (0,
|
|
17253
|
+
const editorContainerRef = (0, import_react102.useRef)(null);
|
|
16912
17254
|
const [editor] = (0, import_LexicalComposerContext4.useLexicalComposerContext)();
|
|
16913
|
-
(0,
|
|
17255
|
+
(0, import_react102.useEffect)(() => {
|
|
16914
17256
|
if (onRichTextInit) {
|
|
16915
17257
|
onRichTextInit(editor);
|
|
16916
17258
|
}
|
|
16917
17259
|
}, [editor, onRichTextInit]);
|
|
16918
|
-
(0,
|
|
17260
|
+
(0, import_react102.useEffect)(() => {
|
|
16919
17261
|
const removeUpdateListener = editor.registerUpdateListener(({ editorState, prevEditorState }) => {
|
|
16920
17262
|
requestAnimationFrame(() => {
|
|
16921
17263
|
if (!(0, import_fast_equals2.deepEqual)(editorState.toJSON(), prevEditorState.toJSON())) {
|
|
@@ -16927,38 +17269,38 @@ var RichText = ({
|
|
|
16927
17269
|
removeUpdateListener();
|
|
16928
17270
|
};
|
|
16929
17271
|
}, []);
|
|
16930
|
-
return /* @__PURE__ */ (0,
|
|
16931
|
-
readOnly ? null : /* @__PURE__ */ (0,
|
|
16932
|
-
/* @__PURE__ */ (0,
|
|
16933
|
-
/* @__PURE__ */ (0,
|
|
17272
|
+
return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(import_jsx_runtime92.Fragment, { children: [
|
|
17273
|
+
readOnly ? null : /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(RichTextToolbar_default, { config }),
|
|
17274
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("div", { css: editorContainer, ref: editorContainerRef, children: [
|
|
17275
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
|
|
16934
17276
|
import_LexicalRichTextPlugin.RichTextPlugin,
|
|
16935
17277
|
{
|
|
16936
|
-
contentEditable: /* @__PURE__ */ (0,
|
|
16937
|
-
placeholder: /* @__PURE__ */ (0,
|
|
17278
|
+
contentEditable: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_LexicalContentEditable.ContentEditable, { css: editorInput, className: editorInputClassName }),
|
|
17279
|
+
placeholder: /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("div", { css: editorPlaceholder, children: readOnly ? "empty" : "start editing..." }),
|
|
16938
17280
|
ErrorBoundary: import_LexicalErrorBoundary.default
|
|
16939
17281
|
}
|
|
16940
17282
|
),
|
|
16941
|
-
/* @__PURE__ */ (0,
|
|
16942
|
-
readOnly ? null : /* @__PURE__ */ (0,
|
|
16943
|
-
/* @__PURE__ */ (0,
|
|
16944
|
-
/* @__PURE__ */ (0,
|
|
17283
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_LexicalListPlugin.ListPlugin, {}),
|
|
17284
|
+
readOnly ? null : /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_LexicalHistoryPlugin.HistoryPlugin, {}),
|
|
17285
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)(LinkNodePlugin, { onConnectLink: onConnectLink ? onConnectLink : () => Promise.resolve() }),
|
|
17286
|
+
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)(ListIndentPlugin, { maxDepth: 4 })
|
|
16945
17287
|
] })
|
|
16946
17288
|
] });
|
|
16947
17289
|
};
|
|
16948
17290
|
|
|
16949
17291
|
// src/components/ParameterInputs/ParameterSelect.tsx
|
|
16950
|
-
var
|
|
16951
|
-
var
|
|
16952
|
-
var ParameterSelect = (0,
|
|
17292
|
+
var import_react103 = require("react");
|
|
17293
|
+
var import_jsx_runtime93 = require("@emotion/react/jsx-runtime");
|
|
17294
|
+
var ParameterSelect = (0, import_react103.forwardRef)(
|
|
16953
17295
|
({ defaultOption, options, ...props }, ref) => {
|
|
16954
17296
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
16955
|
-
return /* @__PURE__ */ (0,
|
|
17297
|
+
return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(ParameterShell, { ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(ParameterSelectInner, { options, defaultOption, ...innerProps, ref }) });
|
|
16956
17298
|
}
|
|
16957
17299
|
);
|
|
16958
|
-
var ParameterSelectInner = (0,
|
|
17300
|
+
var ParameterSelectInner = (0, import_react103.forwardRef)(
|
|
16959
17301
|
({ defaultOption, options, ...props }, ref) => {
|
|
16960
17302
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
16961
|
-
return /* @__PURE__ */ (0,
|
|
17303
|
+
return /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)(
|
|
16962
17304
|
"select",
|
|
16963
17305
|
{
|
|
16964
17306
|
css: [input2, selectInput],
|
|
@@ -16967,10 +17309,10 @@ var ParameterSelectInner = (0, import_react100.forwardRef)(
|
|
|
16967
17309
|
ref,
|
|
16968
17310
|
...props,
|
|
16969
17311
|
children: [
|
|
16970
|
-
defaultOption ? /* @__PURE__ */ (0,
|
|
17312
|
+
defaultOption ? /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("option", { value: "", children: defaultOption }) : null,
|
|
16971
17313
|
options.map((option) => {
|
|
16972
17314
|
var _a;
|
|
16973
|
-
return /* @__PURE__ */ (0,
|
|
17315
|
+
return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("option", { value: (_a = option.value) != null ? _a : option.label, children: option.label }, option.label);
|
|
16974
17316
|
})
|
|
16975
17317
|
]
|
|
16976
17318
|
}
|
|
@@ -16979,15 +17321,15 @@ var ParameterSelectInner = (0, import_react100.forwardRef)(
|
|
|
16979
17321
|
);
|
|
16980
17322
|
|
|
16981
17323
|
// src/components/ParameterInputs/ParameterTextarea.tsx
|
|
16982
|
-
var
|
|
16983
|
-
var
|
|
16984
|
-
var ParameterTextarea = (0,
|
|
17324
|
+
var import_react104 = require("react");
|
|
17325
|
+
var import_jsx_runtime94 = require("@emotion/react/jsx-runtime");
|
|
17326
|
+
var ParameterTextarea = (0, import_react104.forwardRef)((props, ref) => {
|
|
16985
17327
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
16986
|
-
return /* @__PURE__ */ (0,
|
|
17328
|
+
return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(ParameterShell, { "data-test-id": "parameter-textarea", ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(ParameterTextareaInner, { ref, ...innerProps }) });
|
|
16987
17329
|
});
|
|
16988
|
-
var ParameterTextareaInner = (0,
|
|
17330
|
+
var ParameterTextareaInner = (0, import_react104.forwardRef)(({ ...props }, ref) => {
|
|
16989
17331
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
16990
|
-
return /* @__PURE__ */ (0,
|
|
17332
|
+
return /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(
|
|
16991
17333
|
"textarea",
|
|
16992
17334
|
{
|
|
16993
17335
|
css: [input2, textarea2],
|
|
@@ -17000,18 +17342,18 @@ var ParameterTextareaInner = (0, import_react101.forwardRef)(({ ...props }, ref)
|
|
|
17000
17342
|
});
|
|
17001
17343
|
|
|
17002
17344
|
// src/components/ParameterInputs/ParameterToggle.tsx
|
|
17003
|
-
var
|
|
17004
|
-
var
|
|
17005
|
-
var ParameterToggle = (0,
|
|
17345
|
+
var import_react105 = require("react");
|
|
17346
|
+
var import_jsx_runtime95 = require("@emotion/react/jsx-runtime");
|
|
17347
|
+
var ParameterToggle = (0, import_react105.forwardRef)((props, ref) => {
|
|
17006
17348
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
17007
|
-
return /* @__PURE__ */ (0,
|
|
17349
|
+
return /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(ParameterShell, { ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(ParameterToggleInner, { ref, ...innerProps }) });
|
|
17008
17350
|
});
|
|
17009
|
-
var ParameterToggleInner = (0,
|
|
17351
|
+
var ParameterToggleInner = (0, import_react105.forwardRef)(
|
|
17010
17352
|
({ ...props }, ref) => {
|
|
17011
17353
|
const { id, label } = useParameterShell();
|
|
17012
|
-
return /* @__PURE__ */ (0,
|
|
17013
|
-
/* @__PURE__ */ (0,
|
|
17014
|
-
/* @__PURE__ */ (0,
|
|
17354
|
+
return /* @__PURE__ */ (0, import_jsx_runtime95.jsxs)("label", { css: inputToggleLabel2, children: [
|
|
17355
|
+
/* @__PURE__ */ (0, import_jsx_runtime95.jsx)("input", { css: toggleInput2, type: props.type, id, ref, ...props }),
|
|
17356
|
+
/* @__PURE__ */ (0, import_jsx_runtime95.jsx)("span", { css: inlineLabel2, children: label })
|
|
17015
17357
|
] });
|
|
17016
17358
|
}
|
|
17017
17359
|
);
|
|
@@ -17019,7 +17361,7 @@ var ParameterToggleInner = (0, import_react102.forwardRef)(
|
|
|
17019
17361
|
// src/components/Popover/Popover.tsx
|
|
17020
17362
|
var import_Popover = require("reakit/Popover");
|
|
17021
17363
|
var import_Portal2 = require("reakit/Portal");
|
|
17022
|
-
var
|
|
17364
|
+
var import_jsx_runtime96 = require("@emotion/react/jsx-runtime");
|
|
17023
17365
|
var Popover2 = ({
|
|
17024
17366
|
iconColor = "action",
|
|
17025
17367
|
icon = "info",
|
|
@@ -17031,38 +17373,38 @@ var Popover2 = ({
|
|
|
17031
17373
|
children
|
|
17032
17374
|
}) => {
|
|
17033
17375
|
const popover = (0, import_Popover.usePopoverState)({ placement });
|
|
17034
|
-
return /* @__PURE__ */ (0,
|
|
17035
|
-
/* @__PURE__ */ (0,
|
|
17036
|
-
/* @__PURE__ */ (0,
|
|
17037
|
-
/* @__PURE__ */ (0,
|
|
17376
|
+
return /* @__PURE__ */ (0, import_jsx_runtime96.jsxs)(import_jsx_runtime96.Fragment, { children: [
|
|
17377
|
+
/* @__PURE__ */ (0, import_jsx_runtime96.jsxs)(import_Popover.PopoverDisclosure, { ...popover, css: PopoverBtn, title: buttonText, "data-test-id": testId, children: [
|
|
17378
|
+
/* @__PURE__ */ (0, import_jsx_runtime96.jsx)(Icon, { icon, iconColor, size: iconSize }),
|
|
17379
|
+
/* @__PURE__ */ (0, import_jsx_runtime96.jsx)("span", { hidden: true, children: buttonText })
|
|
17038
17380
|
] }),
|
|
17039
|
-
/* @__PURE__ */ (0,
|
|
17381
|
+
/* @__PURE__ */ (0, import_jsx_runtime96.jsx)(import_Portal2.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(import_Popover.Popover, { css: Popover, ...popover, "aria-label": ariaLabel, children }) })
|
|
17040
17382
|
] });
|
|
17041
17383
|
};
|
|
17042
17384
|
|
|
17043
17385
|
// src/components/ProgressList/ProgressList.tsx
|
|
17044
|
-
var
|
|
17045
|
-
var
|
|
17386
|
+
var import_react107 = require("@emotion/react");
|
|
17387
|
+
var import_react108 = require("react");
|
|
17046
17388
|
var import_cg18 = require("react-icons/cg");
|
|
17047
17389
|
|
|
17048
17390
|
// src/components/ProgressList/styles/ProgressList.styles.ts
|
|
17049
|
-
var
|
|
17050
|
-
var progressListStyles =
|
|
17391
|
+
var import_react106 = require("@emotion/react");
|
|
17392
|
+
var progressListStyles = import_react106.css`
|
|
17051
17393
|
display: flex;
|
|
17052
17394
|
flex-direction: column;
|
|
17053
17395
|
gap: var(--spacing-sm);
|
|
17054
17396
|
list-style-type: none;
|
|
17055
17397
|
`;
|
|
17056
|
-
var progressListItemStyles =
|
|
17398
|
+
var progressListItemStyles = import_react106.css`
|
|
17057
17399
|
display: flex;
|
|
17058
17400
|
gap: var(--spacing-base);
|
|
17059
17401
|
align-items: center;
|
|
17060
17402
|
`;
|
|
17061
17403
|
|
|
17062
17404
|
// src/components/ProgressList/ProgressList.tsx
|
|
17063
|
-
var
|
|
17405
|
+
var import_jsx_runtime97 = require("@emotion/react/jsx-runtime");
|
|
17064
17406
|
var ProgressList = ({ inProgressId, items, autoEllipsis, ...htmlProps }) => {
|
|
17065
|
-
const itemsWithStatus = (0,
|
|
17407
|
+
const itemsWithStatus = (0, import_react108.useMemo)(() => {
|
|
17066
17408
|
const indexOfInProgressItem = items.findIndex(({ id }) => id === inProgressId);
|
|
17067
17409
|
return items.map((item, index) => {
|
|
17068
17410
|
let status = "queued";
|
|
@@ -17074,8 +17416,8 @@ var ProgressList = ({ inProgressId, items, autoEllipsis, ...htmlProps }) => {
|
|
|
17074
17416
|
return { ...item, status };
|
|
17075
17417
|
});
|
|
17076
17418
|
}, [items, inProgressId]);
|
|
17077
|
-
return /* @__PURE__ */ (0,
|
|
17078
|
-
return /* @__PURE__ */ (0,
|
|
17419
|
+
return /* @__PURE__ */ (0, import_jsx_runtime97.jsx)("ol", { css: progressListStyles, ...htmlProps, children: itemsWithStatus.map(({ id, label, status, error, errorLevel }) => {
|
|
17420
|
+
return /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(
|
|
17079
17421
|
ProgressListItem,
|
|
17080
17422
|
{
|
|
17081
17423
|
status,
|
|
@@ -17095,7 +17437,7 @@ var ProgressListItem = ({
|
|
|
17095
17437
|
errorLevel = "danger",
|
|
17096
17438
|
autoEllipsis = false
|
|
17097
17439
|
}) => {
|
|
17098
|
-
const Icon2 = (0,
|
|
17440
|
+
const Icon2 = (0, import_react108.useMemo)(() => {
|
|
17099
17441
|
if (error) {
|
|
17100
17442
|
return warningIcon;
|
|
17101
17443
|
}
|
|
@@ -17106,14 +17448,14 @@ var ProgressListItem = ({
|
|
|
17106
17448
|
};
|
|
17107
17449
|
return iconPerStatus[status];
|
|
17108
17450
|
}, [status, error]);
|
|
17109
|
-
const statusStyles = (0,
|
|
17451
|
+
const statusStyles = (0, import_react108.useMemo)(() => {
|
|
17110
17452
|
if (error) {
|
|
17111
|
-
return errorLevel === "caution" ?
|
|
17453
|
+
return errorLevel === "caution" ? import_react107.css`
|
|
17112
17454
|
color: rgb(161, 98, 7);
|
|
17113
17455
|
& svg {
|
|
17114
17456
|
color: rgb(250, 204, 21);
|
|
17115
17457
|
}
|
|
17116
|
-
` :
|
|
17458
|
+
` : import_react107.css`
|
|
17117
17459
|
color: rgb(185, 28, 28);
|
|
17118
17460
|
& svg {
|
|
17119
17461
|
color: var(--brand-primary-2);
|
|
@@ -17121,35 +17463,35 @@ var ProgressListItem = ({
|
|
|
17121
17463
|
`;
|
|
17122
17464
|
}
|
|
17123
17465
|
const colorPerStatus = {
|
|
17124
|
-
completed:
|
|
17466
|
+
completed: import_react107.css`
|
|
17125
17467
|
opacity: 0.75;
|
|
17126
17468
|
`,
|
|
17127
|
-
inProgress:
|
|
17469
|
+
inProgress: import_react107.css`
|
|
17128
17470
|
-webkit-text-stroke-width: thin;
|
|
17129
17471
|
`,
|
|
17130
|
-
queued:
|
|
17472
|
+
queued: import_react107.css`
|
|
17131
17473
|
opacity: 0.5;
|
|
17132
17474
|
`
|
|
17133
17475
|
};
|
|
17134
17476
|
return colorPerStatus[status];
|
|
17135
17477
|
}, [status, error, errorLevel]);
|
|
17136
|
-
return /* @__PURE__ */ (0,
|
|
17137
|
-
/* @__PURE__ */ (0,
|
|
17138
|
-
/* @__PURE__ */ (0,
|
|
17478
|
+
return /* @__PURE__ */ (0, import_jsx_runtime97.jsxs)("li", { css: [progressListItemStyles, statusStyles], children: [
|
|
17479
|
+
/* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Tooltip, { title: error != null ? error : "", children: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Icon2, { size: 20 }) }) }),
|
|
17480
|
+
/* @__PURE__ */ (0, import_jsx_runtime97.jsxs)("div", { children: [
|
|
17139
17481
|
children,
|
|
17140
|
-
/* @__PURE__ */ (0,
|
|
17482
|
+
/* @__PURE__ */ (0, import_jsx_runtime97.jsx)("span", { css: { visibility: autoEllipsis && status === "inProgress" && !error ? "visible" : "hidden" }, children: "..." })
|
|
17141
17483
|
] })
|
|
17142
17484
|
] });
|
|
17143
17485
|
};
|
|
17144
17486
|
|
|
17145
17487
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
17146
|
-
var
|
|
17147
|
-
var
|
|
17488
|
+
var import_react110 = require("@emotion/react");
|
|
17489
|
+
var import_react111 = require("react");
|
|
17148
17490
|
var import_cg19 = require("react-icons/cg");
|
|
17149
17491
|
|
|
17150
17492
|
// src/components/SegmentedControl/SegmentedControl.styles.ts
|
|
17151
|
-
var
|
|
17152
|
-
var segmentedControlStyles =
|
|
17493
|
+
var import_react109 = require("@emotion/react");
|
|
17494
|
+
var segmentedControlStyles = import_react109.css`
|
|
17153
17495
|
--segmented-control-rounded-value: var(--rounded-base);
|
|
17154
17496
|
--segmented-control-border-width: 1px;
|
|
17155
17497
|
--segmented-control-selected-color: var(--brand-secondary-3);
|
|
@@ -17168,14 +17510,14 @@ var segmentedControlStyles = import_react106.css`
|
|
|
17168
17510
|
border-radius: calc(var(--segmented-control-rounded-value) + var(--segmented-control-border-width));
|
|
17169
17511
|
font-size: var(--fs-xs);
|
|
17170
17512
|
`;
|
|
17171
|
-
var segmentedControlVerticalStyles =
|
|
17513
|
+
var segmentedControlVerticalStyles = import_react109.css`
|
|
17172
17514
|
flex-direction: column;
|
|
17173
17515
|
--segmented-control-first-border-radius: var(--segmented-control-rounded-value)
|
|
17174
17516
|
var(--segmented-control-rounded-value) 0 0;
|
|
17175
17517
|
--segmented-control-last-border-radius: 0 0 var(--segmented-control-rounded-value)
|
|
17176
17518
|
var(--segmented-control-rounded-value);
|
|
17177
17519
|
`;
|
|
17178
|
-
var segmentedControlItemStyles =
|
|
17520
|
+
var segmentedControlItemStyles = import_react109.css`
|
|
17179
17521
|
&:first-of-type label {
|
|
17180
17522
|
border-radius: var(--segmented-control-first-border-radius);
|
|
17181
17523
|
}
|
|
@@ -17183,10 +17525,10 @@ var segmentedControlItemStyles = import_react106.css`
|
|
|
17183
17525
|
border-radius: var(--segmented-control-last-border-radius);
|
|
17184
17526
|
}
|
|
17185
17527
|
`;
|
|
17186
|
-
var segmentedControlInputStyles =
|
|
17528
|
+
var segmentedControlInputStyles = import_react109.css`
|
|
17187
17529
|
${accessibleHidden}
|
|
17188
17530
|
`;
|
|
17189
|
-
var segmentedControlLabelStyles =
|
|
17531
|
+
var segmentedControlLabelStyles = import_react109.css`
|
|
17190
17532
|
position: relative;
|
|
17191
17533
|
display: flex;
|
|
17192
17534
|
align-items: center;
|
|
@@ -17223,23 +17565,23 @@ var segmentedControlLabelStyles = import_react106.css`
|
|
|
17223
17565
|
background-color: var(--gray-400);
|
|
17224
17566
|
}
|
|
17225
17567
|
`;
|
|
17226
|
-
var segmentedControlLabelIconOnlyStyles =
|
|
17568
|
+
var segmentedControlLabelIconOnlyStyles = import_react109.css`
|
|
17227
17569
|
padding-inline: 0.5em;
|
|
17228
17570
|
`;
|
|
17229
|
-
var segmentedControlLabelCheckStyles =
|
|
17571
|
+
var segmentedControlLabelCheckStyles = import_react109.css`
|
|
17230
17572
|
opacity: 0.5;
|
|
17231
17573
|
`;
|
|
17232
|
-
var segmentedControlLabelContentStyles =
|
|
17574
|
+
var segmentedControlLabelContentStyles = import_react109.css`
|
|
17233
17575
|
display: flex;
|
|
17234
17576
|
align-items: center;
|
|
17235
17577
|
justify-content: center;
|
|
17236
17578
|
gap: var(--spacing-sm);
|
|
17237
17579
|
height: 100%;
|
|
17238
17580
|
`;
|
|
17239
|
-
var segmentedControlLabelTextStyles =
|
|
17581
|
+
var segmentedControlLabelTextStyles = import_react109.css``;
|
|
17240
17582
|
|
|
17241
17583
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
17242
|
-
var
|
|
17584
|
+
var import_jsx_runtime98 = require("@emotion/react/jsx-runtime");
|
|
17243
17585
|
var SegmentedControl = ({
|
|
17244
17586
|
name,
|
|
17245
17587
|
options,
|
|
@@ -17251,7 +17593,7 @@ var SegmentedControl = ({
|
|
|
17251
17593
|
size = "md",
|
|
17252
17594
|
...props
|
|
17253
17595
|
}) => {
|
|
17254
|
-
const onOptionChange = (0,
|
|
17596
|
+
const onOptionChange = (0, import_react111.useCallback)(
|
|
17255
17597
|
(event) => {
|
|
17256
17598
|
if (event.target.checked) {
|
|
17257
17599
|
onChange == null ? void 0 : onChange(options[parseInt(event.target.value)].value);
|
|
@@ -17259,18 +17601,18 @@ var SegmentedControl = ({
|
|
|
17259
17601
|
},
|
|
17260
17602
|
[options, onChange]
|
|
17261
17603
|
);
|
|
17262
|
-
const sizeStyles = (0,
|
|
17604
|
+
const sizeStyles = (0, import_react111.useMemo)(() => {
|
|
17263
17605
|
const map = {
|
|
17264
|
-
sm: (0,
|
|
17265
|
-
md: (0,
|
|
17266
|
-
lg: (0,
|
|
17606
|
+
sm: (0, import_react110.css)({ height: "calc(24px - 2px)", fontSize: "var(--fs-xs)" }),
|
|
17607
|
+
md: (0, import_react110.css)({ height: "calc(32px - 2px)", fontSize: "var(--fs-sm)" }),
|
|
17608
|
+
lg: (0, import_react110.css)({ height: "calc(40px - 2px)", fontSize: "var(--fs-base)" })
|
|
17267
17609
|
};
|
|
17268
17610
|
return map[size];
|
|
17269
17611
|
}, [size]);
|
|
17270
|
-
const isIconOnly = (0,
|
|
17612
|
+
const isIconOnly = (0, import_react111.useMemo)(() => {
|
|
17271
17613
|
return options.every((option) => option.icon && !option.label);
|
|
17272
17614
|
}, [options]);
|
|
17273
|
-
return /* @__PURE__ */ (0,
|
|
17615
|
+
return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(
|
|
17274
17616
|
"div",
|
|
17275
17617
|
{
|
|
17276
17618
|
css: [segmentedControlStyles, orientation === "vertical" ? segmentedControlVerticalStyles : void 0],
|
|
@@ -17278,11 +17620,11 @@ var SegmentedControl = ({
|
|
|
17278
17620
|
children: options.map((option, index) => {
|
|
17279
17621
|
const text = option.label ? option.label : option.icon ? null : String(option.value);
|
|
17280
17622
|
const isDisabled = disabled || option.disabled;
|
|
17281
|
-
return /* @__PURE__ */ (0,
|
|
17623
|
+
return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(
|
|
17282
17624
|
Tooltip,
|
|
17283
17625
|
{
|
|
17284
17626
|
title: isDisabled || !option.tooltip ? "" : option.tooltip,
|
|
17285
|
-
children: /* @__PURE__ */ (0,
|
|
17627
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime98.jsx)("div", { css: segmentedControlItemStyles, "data-test-id": "container-segmented-control", children: /* @__PURE__ */ (0, import_jsx_runtime98.jsxs)(
|
|
17286
17628
|
"label",
|
|
17287
17629
|
{
|
|
17288
17630
|
css: [
|
|
@@ -17291,7 +17633,7 @@ var SegmentedControl = ({
|
|
|
17291
17633
|
isIconOnly ? segmentedControlLabelIconOnlyStyles : void 0
|
|
17292
17634
|
],
|
|
17293
17635
|
children: [
|
|
17294
|
-
/* @__PURE__ */ (0,
|
|
17636
|
+
/* @__PURE__ */ (0, import_jsx_runtime98.jsx)(
|
|
17295
17637
|
"input",
|
|
17296
17638
|
{
|
|
17297
17639
|
css: segmentedControlInputStyles,
|
|
@@ -17303,10 +17645,10 @@ var SegmentedControl = ({
|
|
|
17303
17645
|
disabled: isDisabled
|
|
17304
17646
|
}
|
|
17305
17647
|
),
|
|
17306
|
-
option.value !== value || noCheckmark ? null : /* @__PURE__ */ (0,
|
|
17307
|
-
/* @__PURE__ */ (0,
|
|
17308
|
-
!option.icon ? null : /* @__PURE__ */ (0,
|
|
17309
|
-
!text ? null : /* @__PURE__ */ (0,
|
|
17648
|
+
option.value !== value || noCheckmark ? null : /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(import_cg19.CgCheck, { css: segmentedControlLabelCheckStyles, "aria-label": "Selected", size: "1.5em" }),
|
|
17649
|
+
/* @__PURE__ */ (0, import_jsx_runtime98.jsxs)("span", { css: segmentedControlLabelContentStyles, children: [
|
|
17650
|
+
!option.icon ? null : /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(option.icon, { size: "1.5em" }),
|
|
17651
|
+
!text ? null : /* @__PURE__ */ (0, import_jsx_runtime98.jsx)("span", { css: segmentedControlLabelTextStyles, children: text })
|
|
17310
17652
|
] })
|
|
17311
17653
|
]
|
|
17312
17654
|
}
|
|
@@ -17320,18 +17662,18 @@ var SegmentedControl = ({
|
|
|
17320
17662
|
};
|
|
17321
17663
|
|
|
17322
17664
|
// src/components/Skeleton/Skeleton.styles.ts
|
|
17323
|
-
var
|
|
17324
|
-
var lightFadingOut =
|
|
17665
|
+
var import_react112 = require("@emotion/react");
|
|
17666
|
+
var lightFadingOut = import_react112.keyframes`
|
|
17325
17667
|
from { opacity: 0.1; }
|
|
17326
17668
|
to { opacity: 0.025; }
|
|
17327
17669
|
`;
|
|
17328
|
-
var skeletonStyles =
|
|
17670
|
+
var skeletonStyles = import_react112.css`
|
|
17329
17671
|
animation: ${lightFadingOut} 1s ease-out infinite alternate;
|
|
17330
17672
|
background-color: var(--gray-900);
|
|
17331
17673
|
`;
|
|
17332
17674
|
|
|
17333
17675
|
// src/components/Skeleton/Skeleton.tsx
|
|
17334
|
-
var
|
|
17676
|
+
var import_jsx_runtime99 = require("@emotion/react/jsx-runtime");
|
|
17335
17677
|
var Skeleton = ({
|
|
17336
17678
|
width = "100%",
|
|
17337
17679
|
height = "1.25rem",
|
|
@@ -17339,7 +17681,7 @@ var Skeleton = ({
|
|
|
17339
17681
|
circle = false,
|
|
17340
17682
|
children,
|
|
17341
17683
|
...otherProps
|
|
17342
|
-
}) => /* @__PURE__ */ (0,
|
|
17684
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(
|
|
17343
17685
|
"div",
|
|
17344
17686
|
{
|
|
17345
17687
|
css: [
|
|
@@ -17359,11 +17701,11 @@ var Skeleton = ({
|
|
|
17359
17701
|
);
|
|
17360
17702
|
|
|
17361
17703
|
// src/components/Switch/Switch.tsx
|
|
17362
|
-
var
|
|
17704
|
+
var React20 = __toESM(require("react"));
|
|
17363
17705
|
|
|
17364
17706
|
// src/components/Switch/Switch.styles.ts
|
|
17365
|
-
var
|
|
17366
|
-
var SwitchInputContainer =
|
|
17707
|
+
var import_react113 = require("@emotion/react");
|
|
17708
|
+
var SwitchInputContainer = import_react113.css`
|
|
17367
17709
|
cursor: pointer;
|
|
17368
17710
|
display: inline-block;
|
|
17369
17711
|
position: relative;
|
|
@@ -17372,7 +17714,7 @@ var SwitchInputContainer = import_react110.css`
|
|
|
17372
17714
|
vertical-align: middle;
|
|
17373
17715
|
user-select: none;
|
|
17374
17716
|
`;
|
|
17375
|
-
var SwitchInput =
|
|
17717
|
+
var SwitchInput = import_react113.css`
|
|
17376
17718
|
appearance: none;
|
|
17377
17719
|
border-radius: var(--rounded-full);
|
|
17378
17720
|
background-color: var(--white);
|
|
@@ -17410,7 +17752,7 @@ var SwitchInput = import_react110.css`
|
|
|
17410
17752
|
cursor: not-allowed;
|
|
17411
17753
|
}
|
|
17412
17754
|
`;
|
|
17413
|
-
var SwitchInputDisabled =
|
|
17755
|
+
var SwitchInputDisabled = import_react113.css`
|
|
17414
17756
|
opacity: var(--opacity-50);
|
|
17415
17757
|
cursor: not-allowed;
|
|
17416
17758
|
|
|
@@ -17418,7 +17760,7 @@ var SwitchInputDisabled = import_react110.css`
|
|
|
17418
17760
|
cursor: not-allowed;
|
|
17419
17761
|
}
|
|
17420
17762
|
`;
|
|
17421
|
-
var SwitchInputLabel =
|
|
17763
|
+
var SwitchInputLabel = import_react113.css`
|
|
17422
17764
|
align-items: center;
|
|
17423
17765
|
color: var(--brand-secondary-1);
|
|
17424
17766
|
display: inline-flex;
|
|
@@ -17440,103 +17782,103 @@ var SwitchInputLabel = import_react110.css`
|
|
|
17440
17782
|
top: 0;
|
|
17441
17783
|
}
|
|
17442
17784
|
`;
|
|
17443
|
-
var SwitchText =
|
|
17785
|
+
var SwitchText = import_react113.css`
|
|
17444
17786
|
color: var(--gray-500);
|
|
17445
17787
|
font-size: var(--fs-sm);
|
|
17446
17788
|
padding-inline: var(--spacing-2xl) 0;
|
|
17447
17789
|
`;
|
|
17448
17790
|
|
|
17449
17791
|
// src/components/Switch/Switch.tsx
|
|
17450
|
-
var
|
|
17451
|
-
var Switch =
|
|
17792
|
+
var import_jsx_runtime100 = require("@emotion/react/jsx-runtime");
|
|
17793
|
+
var Switch = React20.forwardRef(
|
|
17452
17794
|
({ label, infoText, toggleText, children, ...inputProps }, ref) => {
|
|
17453
17795
|
let additionalText = infoText;
|
|
17454
17796
|
if (infoText && toggleText) {
|
|
17455
17797
|
additionalText = inputProps.checked ? toggleText : infoText;
|
|
17456
17798
|
}
|
|
17457
|
-
return /* @__PURE__ */ (0,
|
|
17458
|
-
/* @__PURE__ */ (0,
|
|
17459
|
-
/* @__PURE__ */ (0,
|
|
17460
|
-
/* @__PURE__ */ (0,
|
|
17799
|
+
return /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)(import_jsx_runtime100.Fragment, { children: [
|
|
17800
|
+
/* @__PURE__ */ (0, import_jsx_runtime100.jsxs)("label", { css: [SwitchInputContainer, inputProps.disabled ? SwitchInputDisabled : void 0], children: [
|
|
17801
|
+
/* @__PURE__ */ (0, import_jsx_runtime100.jsx)("input", { type: "checkbox", css: SwitchInput, ...inputProps, ref }),
|
|
17802
|
+
/* @__PURE__ */ (0, import_jsx_runtime100.jsx)("span", { css: SwitchInputLabel, children: label })
|
|
17461
17803
|
] }),
|
|
17462
|
-
additionalText ? /* @__PURE__ */ (0,
|
|
17804
|
+
additionalText ? /* @__PURE__ */ (0, import_jsx_runtime100.jsx)("p", { css: SwitchText, children: additionalText }) : null,
|
|
17463
17805
|
children
|
|
17464
17806
|
] });
|
|
17465
17807
|
}
|
|
17466
17808
|
);
|
|
17467
17809
|
|
|
17468
17810
|
// src/components/Table/Table.tsx
|
|
17469
|
-
var
|
|
17811
|
+
var React21 = __toESM(require("react"));
|
|
17470
17812
|
|
|
17471
17813
|
// src/components/Table/Table.styles.ts
|
|
17472
|
-
var
|
|
17473
|
-
var table =
|
|
17814
|
+
var import_react114 = require("@emotion/react");
|
|
17815
|
+
var table = import_react114.css`
|
|
17474
17816
|
border-bottom: 1px solid var(--gray-400);
|
|
17475
17817
|
border-collapse: collapse;
|
|
17476
17818
|
min-width: 100%;
|
|
17477
17819
|
table-layout: auto;
|
|
17478
17820
|
`;
|
|
17479
|
-
var tableHead =
|
|
17821
|
+
var tableHead = import_react114.css`
|
|
17480
17822
|
background: var(--gray-100);
|
|
17481
17823
|
color: var(--brand-secondary-1);
|
|
17482
17824
|
text-align: left;
|
|
17483
17825
|
`;
|
|
17484
|
-
var tableRow =
|
|
17826
|
+
var tableRow = import_react114.css`
|
|
17485
17827
|
border-bottom: 1px solid var(--gray-200);
|
|
17486
17828
|
`;
|
|
17487
|
-
var tableCellHead =
|
|
17829
|
+
var tableCellHead = import_react114.css`
|
|
17488
17830
|
font-size: var(--fs-sm);
|
|
17489
17831
|
padding: var(--spacing-base) var(--spacing-md);
|
|
17490
17832
|
text-transform: uppercase;
|
|
17491
17833
|
font-weight: var(--fw-bold);
|
|
17492
17834
|
`;
|
|
17493
|
-
var tableCellData =
|
|
17835
|
+
var tableCellData = import_react114.css`
|
|
17494
17836
|
padding: var(--spacing-base) var(--spacing-md);
|
|
17495
17837
|
`;
|
|
17496
17838
|
|
|
17497
17839
|
// src/components/Table/Table.tsx
|
|
17498
|
-
var
|
|
17499
|
-
var Table =
|
|
17500
|
-
return /* @__PURE__ */ (0,
|
|
17840
|
+
var import_jsx_runtime101 = require("@emotion/react/jsx-runtime");
|
|
17841
|
+
var Table = React21.forwardRef(({ children, ...otherProps }, ref) => {
|
|
17842
|
+
return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)("table", { ref, css: table, ...otherProps, children });
|
|
17501
17843
|
});
|
|
17502
|
-
var TableHead =
|
|
17844
|
+
var TableHead = React21.forwardRef(
|
|
17503
17845
|
({ children, ...otherProps }, ref) => {
|
|
17504
|
-
return /* @__PURE__ */ (0,
|
|
17846
|
+
return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)("thead", { ref, css: tableHead, ...otherProps, children });
|
|
17505
17847
|
}
|
|
17506
17848
|
);
|
|
17507
|
-
var TableBody =
|
|
17849
|
+
var TableBody = React21.forwardRef(
|
|
17508
17850
|
({ children, ...otherProps }, ref) => {
|
|
17509
|
-
return /* @__PURE__ */ (0,
|
|
17851
|
+
return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)("tbody", { ref, ...otherProps, children });
|
|
17510
17852
|
}
|
|
17511
17853
|
);
|
|
17512
|
-
var TableFoot =
|
|
17854
|
+
var TableFoot = React21.forwardRef(
|
|
17513
17855
|
({ children, ...otherProps }, ref) => {
|
|
17514
|
-
return /* @__PURE__ */ (0,
|
|
17856
|
+
return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)("tfoot", { ref, ...otherProps, children });
|
|
17515
17857
|
}
|
|
17516
17858
|
);
|
|
17517
|
-
var TableRow =
|
|
17859
|
+
var TableRow = React21.forwardRef(
|
|
17518
17860
|
({ children, ...otherProps }, ref) => {
|
|
17519
|
-
return /* @__PURE__ */ (0,
|
|
17861
|
+
return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)("tr", { ref, css: tableRow, ...otherProps, children });
|
|
17520
17862
|
}
|
|
17521
17863
|
);
|
|
17522
|
-
var TableCellHead =
|
|
17864
|
+
var TableCellHead = React21.forwardRef(
|
|
17523
17865
|
({ children, ...otherProps }, ref) => {
|
|
17524
|
-
return /* @__PURE__ */ (0,
|
|
17866
|
+
return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)("th", { ref, css: tableCellHead, ...otherProps, children });
|
|
17525
17867
|
}
|
|
17526
17868
|
);
|
|
17527
|
-
var TableCellData =
|
|
17869
|
+
var TableCellData = React21.forwardRef(
|
|
17528
17870
|
({ children, ...otherProps }, ref) => {
|
|
17529
|
-
return /* @__PURE__ */ (0,
|
|
17871
|
+
return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)("td", { ref, css: tableCellData, ...otherProps, children });
|
|
17530
17872
|
}
|
|
17531
17873
|
);
|
|
17532
17874
|
|
|
17533
17875
|
// src/components/Tabs/Tabs.tsx
|
|
17534
|
-
var
|
|
17876
|
+
var import_react116 = require("react");
|
|
17535
17877
|
var import_Tab = require("reakit/Tab");
|
|
17536
17878
|
|
|
17537
17879
|
// src/components/Tabs/Tabs.styles.ts
|
|
17538
|
-
var
|
|
17539
|
-
var tabButtonStyles =
|
|
17880
|
+
var import_react115 = require("@emotion/react");
|
|
17881
|
+
var tabButtonStyles = import_react115.css`
|
|
17540
17882
|
align-items: center;
|
|
17541
17883
|
border: 0;
|
|
17542
17884
|
height: 2.5rem;
|
|
@@ -17553,30 +17895,30 @@ var tabButtonStyles = import_react112.css`
|
|
|
17553
17895
|
box-shadow: inset 0 -2px 0 var(--brand-secondary-3);
|
|
17554
17896
|
}
|
|
17555
17897
|
`;
|
|
17556
|
-
var tabButtonGroupStyles =
|
|
17898
|
+
var tabButtonGroupStyles = import_react115.css`
|
|
17557
17899
|
display: flex;
|
|
17558
17900
|
gap: var(--spacing-base);
|
|
17559
17901
|
border-bottom: 1px solid var(--gray-300);
|
|
17560
17902
|
`;
|
|
17561
17903
|
|
|
17562
17904
|
// src/components/Tabs/Tabs.tsx
|
|
17563
|
-
var
|
|
17564
|
-
var CurrentTabContext = (0,
|
|
17905
|
+
var import_jsx_runtime102 = require("@emotion/react/jsx-runtime");
|
|
17906
|
+
var CurrentTabContext = (0, import_react116.createContext)(null);
|
|
17565
17907
|
var useCurrentTab = () => {
|
|
17566
|
-
const context = (0,
|
|
17908
|
+
const context = (0, import_react116.useContext)(CurrentTabContext);
|
|
17567
17909
|
if (!context) {
|
|
17568
17910
|
throw new Error("This component can only be used inside <Tabs>");
|
|
17569
17911
|
}
|
|
17570
17912
|
return context;
|
|
17571
17913
|
};
|
|
17572
17914
|
var Tabs = ({ children, onSelectedIdChange, useHashForState, selectedId, ...props }) => {
|
|
17573
|
-
const selected = (0,
|
|
17915
|
+
const selected = (0, import_react116.useMemo)(() => {
|
|
17574
17916
|
if (selectedId)
|
|
17575
17917
|
return selectedId;
|
|
17576
17918
|
return useHashForState && typeof window !== "undefined" && window.location.hash ? window.location.hash.substring(1) : void 0;
|
|
17577
17919
|
}, [selectedId, useHashForState]);
|
|
17578
17920
|
const tab = (0, import_Tab.useTabState)({ ...props, selectedId: selected });
|
|
17579
|
-
(0,
|
|
17921
|
+
(0, import_react116.useEffect)(() => {
|
|
17580
17922
|
var _a;
|
|
17581
17923
|
const selectedValueWithoutNull = (_a = tab.selectedId) != null ? _a : void 0;
|
|
17582
17924
|
onSelectedIdChange == null ? void 0 : onSelectedIdChange(selectedValueWithoutNull);
|
|
@@ -17584,29 +17926,29 @@ var Tabs = ({ children, onSelectedIdChange, useHashForState, selectedId, ...prop
|
|
|
17584
17926
|
window.location.hash = selectedValueWithoutNull != null ? selectedValueWithoutNull : "";
|
|
17585
17927
|
}
|
|
17586
17928
|
}, [tab.selectedId, onSelectedIdChange, useHashForState]);
|
|
17587
|
-
(0,
|
|
17929
|
+
(0, import_react116.useEffect)(() => {
|
|
17588
17930
|
if (selected && selected !== tab.selectedId) {
|
|
17589
17931
|
tab.setSelectedId(selected);
|
|
17590
17932
|
}
|
|
17591
17933
|
}, [selected]);
|
|
17592
|
-
return /* @__PURE__ */ (0,
|
|
17934
|
+
return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(CurrentTabContext.Provider, { value: tab, children });
|
|
17593
17935
|
};
|
|
17594
17936
|
var TabButtonGroup = ({ children, ...props }) => {
|
|
17595
17937
|
const currentTab = useCurrentTab();
|
|
17596
|
-
return /* @__PURE__ */ (0,
|
|
17938
|
+
return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_Tab.TabList, { ...props, ...currentTab, css: tabButtonGroupStyles, children });
|
|
17597
17939
|
};
|
|
17598
17940
|
var TabButton = ({ children, id, ...props }) => {
|
|
17599
17941
|
const currentTab = useCurrentTab();
|
|
17600
|
-
return /* @__PURE__ */ (0,
|
|
17942
|
+
return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_Tab.Tab, { type: "button", id, ...currentTab, ...props, css: tabButtonStyles, children });
|
|
17601
17943
|
};
|
|
17602
17944
|
var TabContent = ({ children, ...props }) => {
|
|
17603
17945
|
const currentTab = useCurrentTab();
|
|
17604
|
-
return /* @__PURE__ */ (0,
|
|
17946
|
+
return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_Tab.TabPanel, { ...props, ...currentTab, children });
|
|
17605
17947
|
};
|
|
17606
17948
|
|
|
17607
17949
|
// src/components/Validation/StatusBullet.styles.ts
|
|
17608
|
-
var
|
|
17609
|
-
var StatusBulletContainer =
|
|
17950
|
+
var import_react117 = require("@emotion/react");
|
|
17951
|
+
var StatusBulletContainer = import_react117.css`
|
|
17610
17952
|
align-items: center;
|
|
17611
17953
|
align-self: center;
|
|
17612
17954
|
color: var(--gray-500);
|
|
@@ -17623,51 +17965,51 @@ var StatusBulletContainer = import_react114.css`
|
|
|
17623
17965
|
display: block;
|
|
17624
17966
|
}
|
|
17625
17967
|
`;
|
|
17626
|
-
var StatusBulletBase =
|
|
17968
|
+
var StatusBulletBase = import_react117.css`
|
|
17627
17969
|
font-size: var(--fs-sm);
|
|
17628
17970
|
&:before {
|
|
17629
17971
|
width: var(--fs-xs);
|
|
17630
17972
|
height: var(--fs-xs);
|
|
17631
17973
|
}
|
|
17632
17974
|
`;
|
|
17633
|
-
var StatusBulletSmall =
|
|
17975
|
+
var StatusBulletSmall = import_react117.css`
|
|
17634
17976
|
font-size: var(--fs-xs);
|
|
17635
17977
|
&:before {
|
|
17636
17978
|
width: var(--fs-xxs);
|
|
17637
17979
|
height: var(--fs-xxs);
|
|
17638
17980
|
}
|
|
17639
17981
|
`;
|
|
17640
|
-
var StatusDraft =
|
|
17982
|
+
var StatusDraft = import_react117.css`
|
|
17641
17983
|
&:before {
|
|
17642
17984
|
background: var(--white);
|
|
17643
17985
|
box-shadow: inset 0 0 0 0.125rem var(--primary-action-default);
|
|
17644
17986
|
}
|
|
17645
17987
|
`;
|
|
17646
|
-
var StatusModified =
|
|
17988
|
+
var StatusModified = import_react117.css`
|
|
17647
17989
|
&:before {
|
|
17648
17990
|
background: linear-gradient(to right, var(--white) 50%, var(--primary-action-default) 50% 100%);
|
|
17649
17991
|
box-shadow: inset 0 0 0 0.125rem var(--primary-action-default);
|
|
17650
17992
|
}
|
|
17651
17993
|
`;
|
|
17652
|
-
var StatusError =
|
|
17994
|
+
var StatusError = import_react117.css`
|
|
17653
17995
|
color: var(--error);
|
|
17654
17996
|
&:before {
|
|
17655
17997
|
background: linear-gradient(120deg, var(--error) 40%, var(--white) 50%, var(--error) 60%);
|
|
17656
17998
|
}
|
|
17657
17999
|
`;
|
|
17658
|
-
var StatusPublished =
|
|
18000
|
+
var StatusPublished = import_react117.css`
|
|
17659
18001
|
&:before {
|
|
17660
18002
|
background: var(--primary-action-default);
|
|
17661
18003
|
}
|
|
17662
18004
|
`;
|
|
17663
|
-
var StatusOrphan =
|
|
18005
|
+
var StatusOrphan = import_react117.css`
|
|
17664
18006
|
&:before {
|
|
17665
18007
|
background: var(--brand-secondary-5);
|
|
17666
18008
|
}
|
|
17667
18009
|
`;
|
|
17668
18010
|
|
|
17669
18011
|
// src/components/Validation/StatusBullet.tsx
|
|
17670
|
-
var
|
|
18012
|
+
var import_jsx_runtime103 = require("@emotion/react/jsx-runtime");
|
|
17671
18013
|
var StatusBullet = ({
|
|
17672
18014
|
status,
|
|
17673
18015
|
hideText = false,
|
|
@@ -17681,10 +18023,11 @@ var StatusBullet = ({
|
|
|
17681
18023
|
Unsaved: StatusDraft,
|
|
17682
18024
|
Orphan: StatusOrphan,
|
|
17683
18025
|
Published: StatusPublished,
|
|
17684
|
-
Draft: StatusDraft
|
|
18026
|
+
Draft: StatusDraft,
|
|
18027
|
+
Previous: StatusDraft
|
|
17685
18028
|
};
|
|
17686
18029
|
const statusSize = size === "base" ? StatusBulletBase : StatusBulletSmall;
|
|
17687
|
-
return /* @__PURE__ */ (0,
|
|
18030
|
+
return /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(
|
|
17688
18031
|
"span",
|
|
17689
18032
|
{
|
|
17690
18033
|
role: "status",
|
|
@@ -17813,7 +18156,9 @@ var StatusBullet = ({
|
|
|
17813
18156
|
Tabs,
|
|
17814
18157
|
Textarea,
|
|
17815
18158
|
Theme,
|
|
18159
|
+
Tile,
|
|
17816
18160
|
TileContainer,
|
|
18161
|
+
TileText,
|
|
17817
18162
|
Tooltip,
|
|
17818
18163
|
TwoColumnLayout,
|
|
17819
18164
|
UniformBadge,
|
|
@@ -17855,6 +18200,7 @@ var StatusBullet = ({
|
|
|
17855
18200
|
inputError,
|
|
17856
18201
|
inputSelect,
|
|
17857
18202
|
isMacLike,
|
|
18203
|
+
jsonIcon,
|
|
17858
18204
|
labelText,
|
|
17859
18205
|
loaderAnimationData,
|
|
17860
18206
|
macifyShortcut,
|