@uniformdev/design-system 19.55.1-alpha.8 → 19.56.1-alpha.10
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 +267 -216
- package/dist/index.d.mts +18 -4
- package/dist/index.d.ts +18 -4
- package/dist/index.js +354 -305
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -1570,7 +1570,7 @@ init_emotion_jsx_shim();
|
|
|
1570
1570
|
// src/styles/Theme.tsx
|
|
1571
1571
|
init_emotion_jsx_shim();
|
|
1572
1572
|
var import_jsx_runtime = require("@emotion/react/jsx-runtime");
|
|
1573
|
-
var Theme = ({ disableReset = false }) => {
|
|
1573
|
+
var Theme = ({ disableReset = false, disableGlobalReset = false }) => {
|
|
1574
1574
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
|
|
1575
1575
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
1576
1576
|
"link",
|
|
@@ -1636,7 +1636,7 @@ var Theme = ({ disableReset = false }) => {
|
|
|
1636
1636
|
--tertiary-action-hover: var(--gray-600);
|
|
1637
1637
|
--tertiary-action-active: var(--gray-50);
|
|
1638
1638
|
--tertiary-action-disabled: var(--gray-400);
|
|
1639
|
-
|
|
1639
|
+
|
|
1640
1640
|
/* accent dark */
|
|
1641
1641
|
--accent-dark: var(--purple-rain-500);
|
|
1642
1642
|
--accent-dark-hover: var(--purple-rain-400);
|
|
@@ -1761,64 +1761,72 @@ var Theme = ({ disableReset = false }) => {
|
|
|
1761
1761
|
--duration-fast: 0.25s;
|
|
1762
1762
|
--duration-xfast: 0.15s;
|
|
1763
1763
|
}
|
|
1764
|
-
|
|
1765
|
-
html,
|
|
1766
|
-
body {
|
|
1767
|
-
color: var(--brand-secondary-1);
|
|
1768
|
-
font-family: var(--ff-base);
|
|
1769
|
-
scroll-behavior: smooth;
|
|
1770
|
-
font-weight: var(--fw-regular);
|
|
1771
|
-
line-height: 1.5;
|
|
1764
|
+
`
|
|
1772
1765
|
}
|
|
1766
|
+
}
|
|
1767
|
+
),
|
|
1768
|
+
disableGlobalReset ? null : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
1769
|
+
"style",
|
|
1770
|
+
{
|
|
1771
|
+
dangerouslySetInnerHTML: {
|
|
1772
|
+
__html: `
|
|
1773
|
+
html,
|
|
1774
|
+
body {
|
|
1775
|
+
color: var(--brand-secondary-1);
|
|
1776
|
+
font-family: var(--ff-base);
|
|
1777
|
+
scroll-behavior: smooth;
|
|
1778
|
+
font-weight: var(--fw-regular);
|
|
1779
|
+
line-height: 1.5;
|
|
1780
|
+
}
|
|
1773
1781
|
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1782
|
+
li {
|
|
1783
|
+
line-height: 1.5rem;
|
|
1784
|
+
}
|
|
1777
1785
|
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1786
|
+
a, button {
|
|
1787
|
+
cursor: pointer;
|
|
1788
|
+
}
|
|
1781
1789
|
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1790
|
+
fieldset {
|
|
1791
|
+
border: 0;
|
|
1792
|
+
padding: 0;
|
|
1793
|
+
margin: 0;
|
|
1794
|
+
min-width: 0;
|
|
1795
|
+
}
|
|
1788
1796
|
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1797
|
+
legend {
|
|
1798
|
+
margin: 0;
|
|
1799
|
+
padding: 0;
|
|
1800
|
+
}
|
|
1793
1801
|
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1802
|
+
button, input, optgroup, select, textarea {
|
|
1803
|
+
font-family: inherit;
|
|
1804
|
+
font-size: inherit;
|
|
1805
|
+
color: inherit;
|
|
1806
|
+
line-height: 1.25rem;
|
|
1807
|
+
}
|
|
1800
1808
|
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1809
|
+
[role=button], button {
|
|
1810
|
+
cursor: pointer;
|
|
1811
|
+
}
|
|
1804
1812
|
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1813
|
+
audio, canvas, embed, iframe, img, object, svg, video {
|
|
1814
|
+
display: block;
|
|
1815
|
+
vertical-align: middle;
|
|
1816
|
+
}
|
|
1809
1817
|
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1818
|
+
pre {
|
|
1819
|
+
white-space: pre;
|
|
1820
|
+
}
|
|
1813
1821
|
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1822
|
+
*:where(ul, ol) {
|
|
1823
|
+
all: unset;
|
|
1824
|
+
}
|
|
1817
1825
|
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1826
|
+
ul, ol {
|
|
1827
|
+
list-style: none;
|
|
1828
|
+
}
|
|
1829
|
+
`
|
|
1822
1830
|
}
|
|
1823
1831
|
}
|
|
1824
1832
|
)
|
|
@@ -1845,7 +1853,7 @@ var cq = (size) => `@container (min-width: ${size})`;
|
|
|
1845
1853
|
|
|
1846
1854
|
// src/utils/replaceUnderscoreInString.ts
|
|
1847
1855
|
init_emotion_jsx_shim();
|
|
1848
|
-
var replaceUnderscoreInString = (
|
|
1856
|
+
var replaceUnderscoreInString = (title2) => (title2 == null ? void 0 : title2.includes("_")) ? title2.replaceAll("_", " ") : title2;
|
|
1849
1857
|
|
|
1850
1858
|
// src/utils/url.ts
|
|
1851
1859
|
init_emotion_jsx_shim();
|
|
@@ -3874,7 +3882,7 @@ var IntegrationHeaderSectionHexImage = ({ ...props }) => {
|
|
|
3874
3882
|
] });
|
|
3875
3883
|
};
|
|
3876
3884
|
var IntegrationHeaderSection = ({
|
|
3877
|
-
title,
|
|
3885
|
+
title: title2,
|
|
3878
3886
|
description,
|
|
3879
3887
|
icon,
|
|
3880
3888
|
docsLink,
|
|
@@ -3889,10 +3897,10 @@ var IntegrationHeaderSection = ({
|
|
|
3889
3897
|
/* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { css: IntegrationHeaderSectionTitleContainer, children: [
|
|
3890
3898
|
icon ? /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { css: IntegrationHeaderSectionIconContainer, children: [
|
|
3891
3899
|
/* @__PURE__ */ (0, import_jsx_runtime12.jsx)(IntegrationHeaderSectionHexImage, { css: IntegrationHeaderSectionHexIcon }),
|
|
3892
|
-
CompIcon ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(CompIcon, { css: IntegrationHeaderSectionIcon }) : icon ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("img", { src: icon, alt:
|
|
3900
|
+
CompIcon ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(CompIcon, { css: IntegrationHeaderSectionIcon }) : icon ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("img", { src: icon, alt: title2, css: IntegrationHeaderSectionIcon }) : null
|
|
3893
3901
|
] }) : null,
|
|
3894
3902
|
/* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { css: IntegrationHeaderSectionTitleGroup, "data-testid": "integration-header-text", children: [
|
|
3895
|
-
/* @__PURE__ */ (0, import_jsx_runtime12.jsx)("h1", { css: IntegrationHeaderSectionTitle, children:
|
|
3903
|
+
/* @__PURE__ */ (0, import_jsx_runtime12.jsx)("h1", { css: IntegrationHeaderSectionTitle, children: title2 }),
|
|
3896
3904
|
badgeText ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Badge, { text: badgeText }) : null,
|
|
3897
3905
|
menu2 ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { children: menu2 }) : null,
|
|
3898
3906
|
docsLink ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
@@ -3994,7 +4002,7 @@ var PageHeaderSectionTitle = import_react22.css`
|
|
|
3994
4002
|
// src/components/Typography/PageHeaderSection.tsx
|
|
3995
4003
|
var import_jsx_runtime13 = require("@emotion/react/jsx-runtime");
|
|
3996
4004
|
var PageHeaderSection = ({
|
|
3997
|
-
title,
|
|
4005
|
+
title: title2,
|
|
3998
4006
|
desc,
|
|
3999
4007
|
children,
|
|
4000
4008
|
linkText,
|
|
@@ -4021,7 +4029,7 @@ var PageHeaderSection = ({
|
|
|
4021
4029
|
}
|
|
4022
4030
|
)
|
|
4023
4031
|
] }) : null,
|
|
4024
|
-
/* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Heading, { level, css: PageHeaderSectionTitle, ...htmlProps, "data-testid": "page-header-section", children:
|
|
4032
|
+
/* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Heading, { level, css: PageHeaderSectionTitle, ...htmlProps, "data-testid": "page-header-section", children: title2 }),
|
|
4025
4033
|
desc
|
|
4026
4034
|
] }),
|
|
4027
4035
|
children ? /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { css: PageHeaderSectionChildContainer, children }) : null
|
|
@@ -4117,7 +4125,7 @@ var InlineAlertParagraph = import_react23.css`
|
|
|
4117
4125
|
var import_jsx_runtime14 = require("@emotion/react/jsx-runtime");
|
|
4118
4126
|
var InlineAlert = ({
|
|
4119
4127
|
id,
|
|
4120
|
-
title,
|
|
4128
|
+
title: title2,
|
|
4121
4129
|
text,
|
|
4122
4130
|
arrowPosition = "left-top",
|
|
4123
4131
|
positionCss,
|
|
@@ -4125,7 +4133,7 @@ var InlineAlert = ({
|
|
|
4125
4133
|
}) => {
|
|
4126
4134
|
return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { role: "alert", id, css: [InlineAlertContainer, InlineAlertTriangle(arrowPosition), positionCss], children: [
|
|
4127
4135
|
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)("button", { type: "button", "aria-controls": id, title: "close alert", css: InlineAlertCloseBtn, ...btnProps, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Icon, { icon: import_CgClose2.CgClose, iconColor: "currentColor", size: 24 }) }),
|
|
4128
|
-
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Heading, { level: 3, css: InlineAlertTitle, children:
|
|
4136
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Heading, { level: 3, css: InlineAlertTitle, children: title2 }),
|
|
4129
4137
|
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)("p", { css: InlineAlertParagraph, children: text })
|
|
4130
4138
|
] });
|
|
4131
4139
|
};
|
|
@@ -12622,13 +12630,13 @@ var TooltipArrowStyles = import_react24.css`
|
|
|
12622
12630
|
|
|
12623
12631
|
// src/components/Tooltip/Tooltip.tsx
|
|
12624
12632
|
var import_jsx_runtime16 = require("@emotion/react/jsx-runtime");
|
|
12625
|
-
function Tooltip({ children, title, placement = "bottom", visible, ...props }) {
|
|
12633
|
+
function Tooltip({ children, title: title2, placement = "bottom", visible, ...props }) {
|
|
12626
12634
|
const tooltip = (0, import_Tooltip.useTooltipState)({ placement });
|
|
12627
|
-
return !
|
|
12635
|
+
return !title2 ? children : /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_jsx_runtime16.Fragment, { children: [
|
|
12628
12636
|
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_Tooltip.TooltipReference, { ...tooltip, ...children.props, children: (referenceProps) => import_react25.default.cloneElement(children, referenceProps) }),
|
|
12629
12637
|
/* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_Tooltip.Tooltip, { ...tooltip, ...props, css: TooltipContainer, visible: visible != null ? visible : tooltip.visible, children: [
|
|
12630
12638
|
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_Tooltip.TooltipArrow, { ...tooltip, css: TooltipArrowStyles }),
|
|
12631
|
-
|
|
12639
|
+
title2
|
|
12632
12640
|
] })
|
|
12633
12641
|
] });
|
|
12634
12642
|
}
|
|
@@ -13117,9 +13125,9 @@ var MenuTitle = import_react31.css`
|
|
|
13117
13125
|
|
|
13118
13126
|
// src/components/Menu/MenuGroup.tsx
|
|
13119
13127
|
var import_jsx_runtime23 = require("@emotion/react/jsx-runtime");
|
|
13120
|
-
var MenuGroup = ({ title, children }) => {
|
|
13121
|
-
return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { css: MenuGroupContainer(!!
|
|
13122
|
-
|
|
13128
|
+
var MenuGroup = ({ title: title2, children }) => {
|
|
13129
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { css: MenuGroupContainer(!!title2), "data-testid": "menu-group", children: [
|
|
13130
|
+
title2 ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { css: MenuTitle, children: title2 }) : null,
|
|
13123
13131
|
children
|
|
13124
13132
|
] });
|
|
13125
13133
|
};
|
|
@@ -13852,7 +13860,7 @@ var calloutTypeDataMap = {
|
|
|
13852
13860
|
var Callout = ({
|
|
13853
13861
|
type = "info",
|
|
13854
13862
|
compact = false,
|
|
13855
|
-
title,
|
|
13863
|
+
title: title2,
|
|
13856
13864
|
children,
|
|
13857
13865
|
className,
|
|
13858
13866
|
testId
|
|
@@ -13876,7 +13884,7 @@ var Callout = ({
|
|
|
13876
13884
|
children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { css: calloutInner, children: [
|
|
13877
13885
|
compact ? null : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { css: calloutIconWrap, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Icon2, { css: [calloutIcon, calloutTypeData.iconColor] }) }),
|
|
13878
13886
|
/* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { css: [calloutBody, compact ? calloutBodyCompact : void 0], children: [
|
|
13879
|
-
|
|
13887
|
+
title2 ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { css: [calloutTitle], "data-testid": "callout-title", children: title2 }) : null,
|
|
13880
13888
|
children ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { css: [calloutTypeData.descriptionColor], "data-testid": "callout-description", children }) : null
|
|
13881
13889
|
] })
|
|
13882
13890
|
] })
|
|
@@ -13935,7 +13943,7 @@ var CardMenu = import_react38.css`
|
|
|
13935
13943
|
// src/components/Card/Card.tsx
|
|
13936
13944
|
var import_jsx_runtime30 = require("@emotion/react/jsx-runtime");
|
|
13937
13945
|
var Card = ({
|
|
13938
|
-
title,
|
|
13946
|
+
title: title2,
|
|
13939
13947
|
menuItems,
|
|
13940
13948
|
children,
|
|
13941
13949
|
titleWithMarginBottom = true,
|
|
@@ -13945,7 +13953,7 @@ var Card = ({
|
|
|
13945
13953
|
...props
|
|
13946
13954
|
}) => {
|
|
13947
13955
|
return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(Tag, { css: CardContainer, ...props, children: [
|
|
13948
|
-
|
|
13956
|
+
title2 ? /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(CardTitle2, { title: title2, titleWithMarginBottom }) : null,
|
|
13949
13957
|
menuItems ? /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
|
|
13950
13958
|
Menu,
|
|
13951
13959
|
{
|
|
@@ -13967,8 +13975,8 @@ var Card = ({
|
|
|
13967
13975
|
children
|
|
13968
13976
|
] });
|
|
13969
13977
|
};
|
|
13970
|
-
var CardTitle2 = ({ title, titleWithMarginBottom, children }) => {
|
|
13971
|
-
const normalizeTitle = replaceUnderscoreInString(
|
|
13978
|
+
var CardTitle2 = ({ title: title2, titleWithMarginBottom, children }) => {
|
|
13979
|
+
const normalizeTitle = replaceUnderscoreInString(title2);
|
|
13972
13980
|
return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(Heading, { level: 3, css: CardTitle(titleWithMarginBottom), children: [
|
|
13973
13981
|
normalizeTitle,
|
|
13974
13982
|
children
|
|
@@ -16489,14 +16497,14 @@ var IntegrationTileFloatingButtonMessage = (clicked) => import_react73.css`
|
|
|
16489
16497
|
// src/components/Tiles/CreateTeamIntegrationTile.tsx
|
|
16490
16498
|
var import_jsx_runtime66 = require("@emotion/react/jsx-runtime");
|
|
16491
16499
|
var CreateTeamIntegrationTile = ({
|
|
16492
|
-
title = "Create a custom integration for your team",
|
|
16500
|
+
title: title2 = "Create a custom integration for your team",
|
|
16493
16501
|
buttonText = "Add Integration",
|
|
16494
16502
|
onClick,
|
|
16495
16503
|
asDeepLink = false,
|
|
16496
16504
|
...props
|
|
16497
16505
|
}) => {
|
|
16498
16506
|
return /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { css: [IntegrationTileContainer, IntegrationTileBtnDashedBorder], ...props, children: [
|
|
16499
|
-
/* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { css: IntegrationTileTitle, title, children:
|
|
16507
|
+
/* @__PURE__ */ (0, import_jsx_runtime66.jsx)("span", { css: IntegrationTileTitle, title: title2, children: title2 }),
|
|
16500
16508
|
/* @__PURE__ */ (0, import_jsx_runtime66.jsxs)(
|
|
16501
16509
|
Button,
|
|
16502
16510
|
{
|
|
@@ -17186,9 +17194,9 @@ var LinkListTitle = import_react85.css`
|
|
|
17186
17194
|
|
|
17187
17195
|
// src/components/LinkList/LinkList.tsx
|
|
17188
17196
|
var import_jsx_runtime80 = require("@emotion/react/jsx-runtime");
|
|
17189
|
-
var LinkList = ({ title, padding = "var(--spacing-md)", children, ...props }) => {
|
|
17197
|
+
var LinkList = ({ title: title2, padding = "var(--spacing-md)", children, ...props }) => {
|
|
17190
17198
|
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { css: LinkListContainer(padding), ...props, children: [
|
|
17191
|
-
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Heading, { level: 3, css: LinkListTitle, children:
|
|
17199
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Heading, { level: 3, css: LinkListTitle, children: title2 }),
|
|
17192
17200
|
children
|
|
17193
17201
|
] });
|
|
17194
17202
|
};
|
|
@@ -17591,6 +17599,7 @@ init_emotion_jsx_shim();
|
|
|
17591
17599
|
|
|
17592
17600
|
// src/components/MediaCard/MediaCard.tsx
|
|
17593
17601
|
init_emotion_jsx_shim();
|
|
17602
|
+
var import_react94 = require("react");
|
|
17594
17603
|
|
|
17595
17604
|
// src/components/Popover/Popover.tsx
|
|
17596
17605
|
init_emotion_jsx_shim();
|
|
@@ -17662,7 +17671,7 @@ var Popover2 = ({
|
|
|
17662
17671
|
// src/components/MediaCard/MediaCard.styles.ts
|
|
17663
17672
|
init_emotion_jsx_shim();
|
|
17664
17673
|
var import_react93 = require("@emotion/react");
|
|
17665
|
-
var
|
|
17674
|
+
var cardBase = import_react93.css`
|
|
17666
17675
|
display: flex;
|
|
17667
17676
|
flex-direction: column;
|
|
17668
17677
|
justify-content: flex-start;
|
|
@@ -17671,12 +17680,9 @@ var cardBaseStyles = import_react93.css`
|
|
|
17671
17680
|
padding: 0;
|
|
17672
17681
|
min-height: unset;
|
|
17673
17682
|
outline: none;
|
|
17674
|
-
|
|
17675
|
-
&:focus-visible {
|
|
17676
|
-
outline: 2px solid var(--primary-action-default);
|
|
17677
|
-
}
|
|
17683
|
+
cursor: pointer;
|
|
17678
17684
|
`;
|
|
17679
|
-
var
|
|
17685
|
+
var coverWrapper = import_react93.css`
|
|
17680
17686
|
position: relative;
|
|
17681
17687
|
display: flex;
|
|
17682
17688
|
align-items: center;
|
|
@@ -17686,27 +17692,43 @@ var cardBaseCoverIconWrapperStyles = import_react93.css`
|
|
|
17686
17692
|
overflow: hidden;
|
|
17687
17693
|
border-radius: 3px 3px 0 0;
|
|
17688
17694
|
padding: var(--spacing-sm);
|
|
17689
|
-
|
|
17695
|
+
outline: none;
|
|
17696
|
+
border: 0;
|
|
17690
17697
|
`;
|
|
17691
|
-
var
|
|
17698
|
+
var contentWrapper = import_react93.css`
|
|
17692
17699
|
padding: var(--spacing-sm);
|
|
17693
17700
|
`;
|
|
17694
|
-
var
|
|
17701
|
+
var title = import_react93.css`
|
|
17695
17702
|
font-size: var(--fs-sm);
|
|
17696
17703
|
color: var(--gray-500);
|
|
17697
|
-
cursor: pointer;
|
|
17698
17704
|
white-space: nowrap;
|
|
17699
17705
|
overflow: hidden;
|
|
17700
17706
|
text-overflow: ellipsis;
|
|
17707
|
+
outline: none;
|
|
17708
|
+
border: 0;
|
|
17709
|
+
background-color: transparent;
|
|
17710
|
+
|
|
17711
|
+
&:focus-visible {
|
|
17712
|
+
outline: 2px solid var(--primary-action-default);
|
|
17713
|
+
}
|
|
17701
17714
|
`;
|
|
17702
|
-
var
|
|
17715
|
+
var subtitle = import_react93.css`
|
|
17703
17716
|
font-size: var(--fs-xs);
|
|
17704
17717
|
color: var(--gray-500);
|
|
17705
17718
|
white-space: nowrap;
|
|
17706
17719
|
overflow: hidden;
|
|
17707
17720
|
text-overflow: ellipsis;
|
|
17721
|
+
outline: none;
|
|
17722
|
+
border: 0;
|
|
17723
|
+
background-color: transparent;
|
|
17724
|
+
`;
|
|
17725
|
+
var sideSection = import_react93.css`
|
|
17726
|
+
cursor: default;
|
|
17727
|
+
`;
|
|
17728
|
+
var menuSection = import_react93.css`
|
|
17729
|
+
cursor: default;
|
|
17708
17730
|
`;
|
|
17709
|
-
var
|
|
17731
|
+
var menuButton = import_react93.css`
|
|
17710
17732
|
padding: var(--spacing-2xs);
|
|
17711
17733
|
border-radius: var(--rounded-sm);
|
|
17712
17734
|
border-width: 0;
|
|
@@ -17720,25 +17742,29 @@ var cardBaseMenuButtonStyles = import_react93.css`
|
|
|
17720
17742
|
// src/components/MediaCard/MediaCard.tsx
|
|
17721
17743
|
var import_jsx_runtime87 = require("@emotion/react/jsx-runtime");
|
|
17722
17744
|
var MediaCard = ({
|
|
17723
|
-
title,
|
|
17724
|
-
subtitle,
|
|
17745
|
+
title: title2,
|
|
17746
|
+
subtitle: subtitle2,
|
|
17725
17747
|
infoPopover,
|
|
17726
17748
|
cover,
|
|
17727
17749
|
menuItems,
|
|
17728
|
-
sideSection,
|
|
17750
|
+
sideSection: sideSection2,
|
|
17729
17751
|
onClick,
|
|
17730
17752
|
...cardProps
|
|
17731
17753
|
}) => {
|
|
17732
|
-
|
|
17733
|
-
|
|
17734
|
-
|
|
17754
|
+
const onStopPropogation = (0, import_react94.useCallback)((e) => {
|
|
17755
|
+
e.stopPropagation();
|
|
17756
|
+
}, []);
|
|
17757
|
+
const hasMenuItems = Array.isArray(menuItems) ? menuItems.length > 0 : Boolean(menuItems);
|
|
17758
|
+
return /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(Card, { css: cardBase, ...cardProps, onClick, children: [
|
|
17759
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)("button", { tabIndex: -1, css: coverWrapper, children: cover }),
|
|
17760
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { css: contentWrapper, children: /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(HorizontalRhythm, { gap: "sm", justify: "space-between", align: "center", css: { width: "100%" }, children: [
|
|
17735
17761
|
/* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(VerticalRhythm, { gap: "0", align: "flex-start", css: { flex: 1, minWidth: 0 }, children: [
|
|
17736
17762
|
/* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(HorizontalRhythm, { gap: "xs", align: "center", css: { maxWidth: "100%" }, children: [
|
|
17737
|
-
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)("
|
|
17738
|
-
!infoPopover ? null : /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { css: { display: "flex", cursor: "default" }, onClick:
|
|
17763
|
+
/* @__PURE__ */ (0, import_jsx_runtime87.jsx)("button", { css: title, "data-testid": "card-title", children: title2 }),
|
|
17764
|
+
!infoPopover ? null : /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { css: { display: "flex", cursor: "default" }, onClick: onStopPropogation, children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
17739
17765
|
Popover2,
|
|
17740
17766
|
{
|
|
17741
|
-
baseId: `info-of-${
|
|
17767
|
+
baseId: `info-of-${title2}`,
|
|
17742
17768
|
buttonText: "Details",
|
|
17743
17769
|
ariaLabel: "Details",
|
|
17744
17770
|
iconColor: "default",
|
|
@@ -17748,17 +17774,26 @@ var MediaCard = ({
|
|
|
17748
17774
|
}
|
|
17749
17775
|
) })
|
|
17750
17776
|
] }),
|
|
17751
|
-
|
|
17777
|
+
subtitle2 ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("button", { tabIndex: -1, css: subtitle, children: subtitle2 }) : null
|
|
17752
17778
|
] }),
|
|
17753
|
-
|
|
17754
|
-
|
|
17755
|
-
|
|
17779
|
+
sideSection2 ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("div", { css: sideSection, onClick: onStopPropogation, children: sideSection2 }) : null,
|
|
17780
|
+
hasMenuItems ? /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
17781
|
+
VerticalRhythm,
|
|
17756
17782
|
{
|
|
17757
|
-
|
|
17758
|
-
|
|
17759
|
-
|
|
17783
|
+
css: menuSection,
|
|
17784
|
+
align: "center",
|
|
17785
|
+
justify: "center",
|
|
17786
|
+
onClick: onStopPropogation,
|
|
17787
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(
|
|
17788
|
+
Menu,
|
|
17789
|
+
{
|
|
17790
|
+
menuTrigger: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)("button", { type: "button", "aria-label": "More options", css: menuButton, children: /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(Icon, { icon: "more-alt", iconColor: "gray", size: 16 }) }),
|
|
17791
|
+
menuLabel: `Menu of ${title2}`,
|
|
17792
|
+
children: menuItems
|
|
17793
|
+
}
|
|
17794
|
+
)
|
|
17760
17795
|
}
|
|
17761
|
-
)
|
|
17796
|
+
) : null
|
|
17762
17797
|
] }) })
|
|
17763
17798
|
] });
|
|
17764
17799
|
};
|
|
@@ -17766,12 +17801,12 @@ var MediaCard = ({
|
|
|
17766
17801
|
// src/components/Modal/Modal.tsx
|
|
17767
17802
|
init_emotion_jsx_shim();
|
|
17768
17803
|
var import_CgClose6 = require("@react-icons/all-files/cg/CgClose");
|
|
17769
|
-
var
|
|
17804
|
+
var import_react96 = __toESM(require("react"));
|
|
17770
17805
|
|
|
17771
17806
|
// src/components/Modal/Modal.styles.ts
|
|
17772
17807
|
init_emotion_jsx_shim();
|
|
17773
|
-
var
|
|
17774
|
-
var modalWrapperStyles =
|
|
17808
|
+
var import_react95 = require("@emotion/react");
|
|
17809
|
+
var modalWrapperStyles = import_react95.css`
|
|
17775
17810
|
position: fixed;
|
|
17776
17811
|
inset: 0;
|
|
17777
17812
|
display: flex;
|
|
@@ -17779,13 +17814,13 @@ var modalWrapperStyles = import_react94.css`
|
|
|
17779
17814
|
justify-content: center;
|
|
17780
17815
|
z-index: var(--z-drawer);
|
|
17781
17816
|
`;
|
|
17782
|
-
var modalBackdropStyles =
|
|
17817
|
+
var modalBackdropStyles = import_react95.css`
|
|
17783
17818
|
position: absolute;
|
|
17784
17819
|
inset: 0;
|
|
17785
17820
|
background-color: var(--brand-secondary-1);
|
|
17786
17821
|
opacity: 0.4;
|
|
17787
17822
|
`;
|
|
17788
|
-
var modalStyles =
|
|
17823
|
+
var modalStyles = import_react95.css`
|
|
17789
17824
|
position: relative;
|
|
17790
17825
|
display: flex;
|
|
17791
17826
|
flex-direction: column;
|
|
@@ -17800,21 +17835,21 @@ var modalStyles = import_react94.css`
|
|
|
17800
17835
|
color: unset;
|
|
17801
17836
|
z-index: 1;
|
|
17802
17837
|
`;
|
|
17803
|
-
var modalHeaderStyles =
|
|
17838
|
+
var modalHeaderStyles = import_react95.css`
|
|
17804
17839
|
display: flex;
|
|
17805
17840
|
align-items: flex-start;
|
|
17806
17841
|
gap: var(--spacing-base);
|
|
17807
17842
|
font-size: var(--fs-md);
|
|
17808
17843
|
line-height: 1.2;
|
|
17809
17844
|
`;
|
|
17810
|
-
var modalCloseButtonStyles =
|
|
17845
|
+
var modalCloseButtonStyles = import_react95.css`
|
|
17811
17846
|
display: block;
|
|
17812
17847
|
padding: 0;
|
|
17813
17848
|
background: transparent;
|
|
17814
17849
|
border: none;
|
|
17815
17850
|
margin-left: auto;
|
|
17816
17851
|
`;
|
|
17817
|
-
var modalContentStyles =
|
|
17852
|
+
var modalContentStyles = import_react95.css`
|
|
17818
17853
|
flex: 1;
|
|
17819
17854
|
background-color: white;
|
|
17820
17855
|
padding: var(--spacing-md);
|
|
@@ -17826,7 +17861,7 @@ var modalContentStyles = import_react94.css`
|
|
|
17826
17861
|
var import_jsx_runtime88 = require("@emotion/react/jsx-runtime");
|
|
17827
17862
|
var defaultModalWidth = "75rem";
|
|
17828
17863
|
var defaultModalHeight = "51rem";
|
|
17829
|
-
var Modal =
|
|
17864
|
+
var Modal = import_react96.default.forwardRef(
|
|
17830
17865
|
({
|
|
17831
17866
|
header,
|
|
17832
17867
|
children,
|
|
@@ -17870,8 +17905,8 @@ Modal.displayName = "Modal";
|
|
|
17870
17905
|
|
|
17871
17906
|
// src/components/ParameterInputs/hooks/ParameterShellContext.tsx
|
|
17872
17907
|
init_emotion_jsx_shim();
|
|
17873
|
-
var
|
|
17874
|
-
var ParameterShellContext = (0,
|
|
17908
|
+
var import_react97 = require("react");
|
|
17909
|
+
var ParameterShellContext = (0, import_react97.createContext)({
|
|
17875
17910
|
id: "",
|
|
17876
17911
|
label: "",
|
|
17877
17912
|
hiddenLabel: void 0,
|
|
@@ -17880,7 +17915,7 @@ var ParameterShellContext = (0, import_react96.createContext)({
|
|
|
17880
17915
|
}
|
|
17881
17916
|
});
|
|
17882
17917
|
var useParameterShell = () => {
|
|
17883
|
-
const { id, label, hiddenLabel, errorMessage, handleManuallySetErrorMessage } = (0,
|
|
17918
|
+
const { id, label, hiddenLabel, errorMessage, handleManuallySetErrorMessage } = (0, import_react97.useContext)(ParameterShellContext);
|
|
17884
17919
|
return {
|
|
17885
17920
|
id,
|
|
17886
17921
|
label,
|
|
@@ -17895,8 +17930,8 @@ init_emotion_jsx_shim();
|
|
|
17895
17930
|
|
|
17896
17931
|
// src/components/ParameterInputs/styles/LabelLeadingIcon.styles.ts
|
|
17897
17932
|
init_emotion_jsx_shim();
|
|
17898
|
-
var
|
|
17899
|
-
var inputIconBtn =
|
|
17933
|
+
var import_react98 = require("@emotion/react");
|
|
17934
|
+
var inputIconBtn = import_react98.css`
|
|
17900
17935
|
align-items: center;
|
|
17901
17936
|
border: none;
|
|
17902
17937
|
border-radius: var(--rounded-base);
|
|
@@ -17930,10 +17965,10 @@ var LabelLeadingIcon = ({
|
|
|
17930
17965
|
isBound,
|
|
17931
17966
|
isActive,
|
|
17932
17967
|
isLocked,
|
|
17933
|
-
title,
|
|
17968
|
+
title: title2,
|
|
17934
17969
|
...props
|
|
17935
17970
|
}) => {
|
|
17936
|
-
const titleFr =
|
|
17971
|
+
const titleFr = title2 != null ? title2 : isLocked ? "Read-only pattern parameter" : isBound ? "Connected to external content. Click to edit" : "Click to connect to external content";
|
|
17937
17972
|
return /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(Tooltip, { title: titleFr, children: /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)(
|
|
17938
17973
|
"button",
|
|
17939
17974
|
{
|
|
@@ -17963,8 +17998,8 @@ init_emotion_jsx_shim();
|
|
|
17963
17998
|
|
|
17964
17999
|
// src/components/ParameterInputs/styles/ParameterInput.styles.ts
|
|
17965
18000
|
init_emotion_jsx_shim();
|
|
17966
|
-
var
|
|
17967
|
-
var inputContainer2 =
|
|
18001
|
+
var import_react99 = require("@emotion/react");
|
|
18002
|
+
var inputContainer2 = import_react99.css`
|
|
17968
18003
|
position: relative;
|
|
17969
18004
|
|
|
17970
18005
|
&:hover,
|
|
@@ -17976,14 +18011,14 @@ var inputContainer2 = import_react98.css`
|
|
|
17976
18011
|
}
|
|
17977
18012
|
}
|
|
17978
18013
|
`;
|
|
17979
|
-
var labelText2 =
|
|
18014
|
+
var labelText2 = import_react99.css`
|
|
17980
18015
|
align-items: center;
|
|
17981
18016
|
display: flex;
|
|
17982
18017
|
gap: var(--spacing-xs);
|
|
17983
18018
|
font-weight: var(--fw-regular);
|
|
17984
18019
|
margin: 0 0 var(--spacing-xs);
|
|
17985
18020
|
`;
|
|
17986
|
-
var input2 =
|
|
18021
|
+
var input2 = import_react99.css`
|
|
17987
18022
|
display: block;
|
|
17988
18023
|
appearance: none;
|
|
17989
18024
|
box-sizing: border-box;
|
|
@@ -18027,18 +18062,18 @@ var input2 = import_react98.css`
|
|
|
18027
18062
|
color: var(--gray-400);
|
|
18028
18063
|
}
|
|
18029
18064
|
`;
|
|
18030
|
-
var selectInput =
|
|
18065
|
+
var selectInput = import_react99.css`
|
|
18031
18066
|
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");
|
|
18032
18067
|
background-position: right var(--spacing-sm) center;
|
|
18033
18068
|
background-repeat: no-repeat;
|
|
18034
18069
|
background-size: 1rem;
|
|
18035
18070
|
padding-right: var(--spacing-xl);
|
|
18036
18071
|
`;
|
|
18037
|
-
var inputWrapper =
|
|
18072
|
+
var inputWrapper = import_react99.css`
|
|
18038
18073
|
display: flex; // used to correct overflow with chrome textarea
|
|
18039
18074
|
position: relative;
|
|
18040
18075
|
`;
|
|
18041
|
-
var inputIcon2 =
|
|
18076
|
+
var inputIcon2 = import_react99.css`
|
|
18042
18077
|
align-items: center;
|
|
18043
18078
|
background: var(--white);
|
|
18044
18079
|
border-radius: var(--rounded-md) 0 0 var(--rounded-md);
|
|
@@ -18054,7 +18089,7 @@ var inputIcon2 = import_react98.css`
|
|
|
18054
18089
|
width: var(--spacing-lg);
|
|
18055
18090
|
z-index: var(--z-10);
|
|
18056
18091
|
`;
|
|
18057
|
-
var inputToggleLabel2 =
|
|
18092
|
+
var inputToggleLabel2 = import_react99.css`
|
|
18058
18093
|
align-items: center;
|
|
18059
18094
|
background: var(--white);
|
|
18060
18095
|
cursor: pointer;
|
|
@@ -18065,7 +18100,7 @@ var inputToggleLabel2 = import_react98.css`
|
|
|
18065
18100
|
min-height: var(--spacing-md);
|
|
18066
18101
|
position: relative;
|
|
18067
18102
|
`;
|
|
18068
|
-
var toggleInput2 =
|
|
18103
|
+
var toggleInput2 = import_react99.css`
|
|
18069
18104
|
appearance: none;
|
|
18070
18105
|
border: 1px solid var(--gray-300);
|
|
18071
18106
|
background: var(--white);
|
|
@@ -18104,7 +18139,7 @@ var toggleInput2 = import_react98.css`
|
|
|
18104
18139
|
border-color: var(--gray-300);
|
|
18105
18140
|
}
|
|
18106
18141
|
`;
|
|
18107
|
-
var inlineLabel2 =
|
|
18142
|
+
var inlineLabel2 = import_react99.css`
|
|
18108
18143
|
padding-left: var(--spacing-lg);
|
|
18109
18144
|
font-size: var(--fs-sm);
|
|
18110
18145
|
font-weight: var(--fw-regular);
|
|
@@ -18120,7 +18155,7 @@ var inlineLabel2 = import_react98.css`
|
|
|
18120
18155
|
}
|
|
18121
18156
|
}
|
|
18122
18157
|
`;
|
|
18123
|
-
var inputMenu =
|
|
18158
|
+
var inputMenu = import_react99.css`
|
|
18124
18159
|
background: none;
|
|
18125
18160
|
border: none;
|
|
18126
18161
|
padding: var(--spacing-2xs);
|
|
@@ -18136,11 +18171,11 @@ var inputMenu = import_react98.css`
|
|
|
18136
18171
|
background-color: var(--gray-200);
|
|
18137
18172
|
}
|
|
18138
18173
|
`;
|
|
18139
|
-
var textarea2 =
|
|
18174
|
+
var textarea2 = import_react99.css`
|
|
18140
18175
|
resize: vertical;
|
|
18141
18176
|
min-height: 2rem;
|
|
18142
18177
|
`;
|
|
18143
|
-
var dataConnectButton =
|
|
18178
|
+
var dataConnectButton = import_react99.css`
|
|
18144
18179
|
align-items: center;
|
|
18145
18180
|
appearance: none;
|
|
18146
18181
|
box-sizing: border-box;
|
|
@@ -18175,7 +18210,7 @@ var dataConnectButton = import_react98.css`
|
|
|
18175
18210
|
pointer-events: none;
|
|
18176
18211
|
}
|
|
18177
18212
|
`;
|
|
18178
|
-
var linkParameterBtn =
|
|
18213
|
+
var linkParameterBtn = import_react99.css`
|
|
18179
18214
|
border-radius: var(--rounded-base);
|
|
18180
18215
|
background: var(--white);
|
|
18181
18216
|
border: none;
|
|
@@ -18184,7 +18219,7 @@ var linkParameterBtn = import_react98.css`
|
|
|
18184
18219
|
font-size: var(--fs-sm);
|
|
18185
18220
|
line-height: 1;
|
|
18186
18221
|
`;
|
|
18187
|
-
var linkParameterControls =
|
|
18222
|
+
var linkParameterControls = import_react99.css`
|
|
18188
18223
|
position: absolute;
|
|
18189
18224
|
inset: 0 0 0 auto;
|
|
18190
18225
|
padding: 0 var(--spacing-base);
|
|
@@ -18193,7 +18228,7 @@ var linkParameterControls = import_react98.css`
|
|
|
18193
18228
|
justify-content: center;
|
|
18194
18229
|
gap: var(--spacing-base);
|
|
18195
18230
|
`;
|
|
18196
|
-
var linkParameterInput = (withExternalLinkIcon) =>
|
|
18231
|
+
var linkParameterInput = (withExternalLinkIcon) => import_react99.css`
|
|
18197
18232
|
padding-right: calc(
|
|
18198
18233
|
${withExternalLinkIcon ? "calc(var(--spacing-lg) * 2 + var(--spacing-xs))" : "var(--spacing-xl)"} +
|
|
18199
18234
|
var(--spacing-base)
|
|
@@ -18206,7 +18241,7 @@ var linkParameterInput = (withExternalLinkIcon) => import_react98.css`
|
|
|
18206
18241
|
}
|
|
18207
18242
|
}
|
|
18208
18243
|
`;
|
|
18209
|
-
var linkParameterIcon =
|
|
18244
|
+
var linkParameterIcon = import_react99.css`
|
|
18210
18245
|
align-items: center;
|
|
18211
18246
|
color: var(--brand-secondary-3);
|
|
18212
18247
|
display: flex;
|
|
@@ -18259,20 +18294,20 @@ init_emotion_jsx_shim();
|
|
|
18259
18294
|
|
|
18260
18295
|
// src/components/ParameterInputs/styles/ParameterDrawerHeader.styles.ts
|
|
18261
18296
|
init_emotion_jsx_shim();
|
|
18262
|
-
var
|
|
18263
|
-
var ParameterDrawerHeaderContainer =
|
|
18297
|
+
var import_react100 = require("@emotion/react");
|
|
18298
|
+
var ParameterDrawerHeaderContainer = import_react100.css`
|
|
18264
18299
|
align-items: center;
|
|
18265
18300
|
display: flex;
|
|
18266
18301
|
gap: var(--spacing-base);
|
|
18267
18302
|
justify-content: space-between;
|
|
18268
18303
|
margin-bottom: var(--spacing-sm);
|
|
18269
18304
|
`;
|
|
18270
|
-
var ParameterDrawerHeaderTitleGroup =
|
|
18305
|
+
var ParameterDrawerHeaderTitleGroup = import_react100.css`
|
|
18271
18306
|
align-items: center;
|
|
18272
18307
|
display: flex;
|
|
18273
18308
|
gap: var(--spacing-sm);
|
|
18274
18309
|
`;
|
|
18275
|
-
var ParameterDrawerHeaderTitle =
|
|
18310
|
+
var ParameterDrawerHeaderTitle = import_react100.css`
|
|
18276
18311
|
text-overflow: ellipsis;
|
|
18277
18312
|
white-space: nowrap;
|
|
18278
18313
|
overflow: hidden;
|
|
@@ -18281,11 +18316,11 @@ var ParameterDrawerHeaderTitle = import_react99.css`
|
|
|
18281
18316
|
|
|
18282
18317
|
// src/components/ParameterInputs/ParameterDrawerHeader.tsx
|
|
18283
18318
|
var import_jsx_runtime91 = require("@emotion/react/jsx-runtime");
|
|
18284
|
-
var ParameterDrawerHeader = ({ title, iconBeforeTitle, children }) => {
|
|
18319
|
+
var ParameterDrawerHeader = ({ title: title2, iconBeforeTitle, children }) => {
|
|
18285
18320
|
return /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { css: ParameterDrawerHeaderContainer, children: [
|
|
18286
18321
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("header", { css: ParameterDrawerHeaderTitleGroup, children: [
|
|
18287
18322
|
iconBeforeTitle,
|
|
18288
|
-
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Heading, { level: 3, withMarginBottom: false, css: ParameterDrawerHeaderTitle, title, children:
|
|
18323
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Heading, { level: 3, withMarginBottom: false, css: ParameterDrawerHeaderTitle, title: title2, children: title2 })
|
|
18289
18324
|
] }),
|
|
18290
18325
|
children
|
|
18291
18326
|
] });
|
|
@@ -18293,12 +18328,12 @@ var ParameterDrawerHeader = ({ title, iconBeforeTitle, children }) => {
|
|
|
18293
18328
|
|
|
18294
18329
|
// src/components/ParameterInputs/ParameterGroup.tsx
|
|
18295
18330
|
init_emotion_jsx_shim();
|
|
18296
|
-
var
|
|
18331
|
+
var import_react102 = require("react");
|
|
18297
18332
|
|
|
18298
18333
|
// src/components/ParameterInputs/styles/ParameterGroup.styles.ts
|
|
18299
18334
|
init_emotion_jsx_shim();
|
|
18300
|
-
var
|
|
18301
|
-
var fieldsetStyles =
|
|
18335
|
+
var import_react101 = require("@emotion/react");
|
|
18336
|
+
var fieldsetStyles = import_react101.css`
|
|
18302
18337
|
&:disabled,
|
|
18303
18338
|
[readonly] {
|
|
18304
18339
|
pointer-events: none;
|
|
@@ -18309,7 +18344,7 @@ var fieldsetStyles = import_react100.css`
|
|
|
18309
18344
|
}
|
|
18310
18345
|
}
|
|
18311
18346
|
`;
|
|
18312
|
-
var fieldsetLegend2 =
|
|
18347
|
+
var fieldsetLegend2 = import_react101.css`
|
|
18313
18348
|
display: block;
|
|
18314
18349
|
font-weight: var(--fw-medium);
|
|
18315
18350
|
margin-bottom: var(--spacing-sm);
|
|
@@ -18318,7 +18353,7 @@ var fieldsetLegend2 = import_react100.css`
|
|
|
18318
18353
|
|
|
18319
18354
|
// src/components/ParameterInputs/ParameterGroup.tsx
|
|
18320
18355
|
var import_jsx_runtime92 = require("@emotion/react/jsx-runtime");
|
|
18321
|
-
var ParameterGroup = (0,
|
|
18356
|
+
var ParameterGroup = (0, import_react102.forwardRef)(
|
|
18322
18357
|
({ legend, isDisabled, children, ...props }, ref) => {
|
|
18323
18358
|
return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)("fieldset", { css: fieldsetStyles, disabled: isDisabled, ref, ...props, children: [
|
|
18324
18359
|
/* @__PURE__ */ (0, import_jsx_runtime92.jsx)("legend", { css: fieldsetLegend2, children: legend }),
|
|
@@ -18329,24 +18364,24 @@ var ParameterGroup = (0, import_react101.forwardRef)(
|
|
|
18329
18364
|
|
|
18330
18365
|
// src/components/ParameterInputs/ParameterImage.tsx
|
|
18331
18366
|
init_emotion_jsx_shim();
|
|
18332
|
-
var
|
|
18367
|
+
var import_react109 = require("react");
|
|
18333
18368
|
|
|
18334
18369
|
// src/components/ParameterInputs/ParameterImagePreview.tsx
|
|
18335
18370
|
init_emotion_jsx_shim();
|
|
18336
|
-
var
|
|
18371
|
+
var import_react104 = require("react");
|
|
18337
18372
|
var import_react_dom2 = require("react-dom");
|
|
18338
18373
|
|
|
18339
18374
|
// src/components/ParameterInputs/styles/ParameterImage.styles.ts
|
|
18340
18375
|
init_emotion_jsx_shim();
|
|
18341
|
-
var
|
|
18342
|
-
var previewWrapper =
|
|
18376
|
+
var import_react103 = require("@emotion/react");
|
|
18377
|
+
var previewWrapper = import_react103.css`
|
|
18343
18378
|
margin-top: var(--spacing-xs);
|
|
18344
18379
|
background: var(--gray-50);
|
|
18345
18380
|
padding: var(--spacing-sm);
|
|
18346
18381
|
border: solid 1px var(--gray-300);
|
|
18347
18382
|
border-radius: var(--rounded-sm);
|
|
18348
18383
|
`;
|
|
18349
|
-
var previewLink =
|
|
18384
|
+
var previewLink = import_react103.css`
|
|
18350
18385
|
display: block;
|
|
18351
18386
|
width: 100%;
|
|
18352
18387
|
|
|
@@ -18354,7 +18389,7 @@ var previewLink = import_react102.css`
|
|
|
18354
18389
|
max-height: 9rem;
|
|
18355
18390
|
}
|
|
18356
18391
|
`;
|
|
18357
|
-
var previewModalWrapper =
|
|
18392
|
+
var previewModalWrapper = import_react103.css`
|
|
18358
18393
|
background: var(--gray-50);
|
|
18359
18394
|
display: flex;
|
|
18360
18395
|
height: 100%;
|
|
@@ -18363,7 +18398,7 @@ var previewModalWrapper = import_react102.css`
|
|
|
18363
18398
|
border: solid 1px var(--gray-300);
|
|
18364
18399
|
border-radius: var(--rounded-sm);
|
|
18365
18400
|
`;
|
|
18366
|
-
var previewModalImage =
|
|
18401
|
+
var previewModalImage = import_react103.css`
|
|
18367
18402
|
display: flex;
|
|
18368
18403
|
height: 100%;
|
|
18369
18404
|
width: 100%;
|
|
@@ -18377,7 +18412,7 @@ var previewModalImage = import_react102.css`
|
|
|
18377
18412
|
// src/components/ParameterInputs/ParameterImagePreview.tsx
|
|
18378
18413
|
var import_jsx_runtime93 = require("@emotion/react/jsx-runtime");
|
|
18379
18414
|
function ParameterImagePreview({ imageSrc }) {
|
|
18380
|
-
const [showModal, setShowModal] = (0,
|
|
18415
|
+
const [showModal, setShowModal] = (0, import_react104.useState)(false);
|
|
18381
18416
|
return imageSrc ? /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)("div", { css: previewWrapper, children: [
|
|
18382
18417
|
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)(PreviewImageModal, { open: showModal, imageSrc, onRequestClose: () => setShowModal(false) }),
|
|
18383
18418
|
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
|
|
@@ -18410,7 +18445,8 @@ var PreviewImageModal = ({ open, onRequestClose, imageSrc }) => {
|
|
|
18410
18445
|
|
|
18411
18446
|
// src/components/ParameterInputs/ParameterShell.tsx
|
|
18412
18447
|
init_emotion_jsx_shim();
|
|
18413
|
-
var
|
|
18448
|
+
var import_react107 = require("@emotion/react");
|
|
18449
|
+
var import_react108 = require("react");
|
|
18414
18450
|
|
|
18415
18451
|
// src/components/ParameterInputs/ParameterLabel.tsx
|
|
18416
18452
|
init_emotion_jsx_shim();
|
|
@@ -18421,9 +18457,9 @@ var ParameterLabel = ({ id, asSpan, children, ...props }) => {
|
|
|
18421
18457
|
|
|
18422
18458
|
// src/components/ParameterInputs/ParameterMenuButton.tsx
|
|
18423
18459
|
init_emotion_jsx_shim();
|
|
18424
|
-
var
|
|
18460
|
+
var import_react105 = require("react");
|
|
18425
18461
|
var import_jsx_runtime95 = require("@emotion/react/jsx-runtime");
|
|
18426
|
-
var ParameterMenuButton = (0,
|
|
18462
|
+
var ParameterMenuButton = (0, import_react105.forwardRef)(
|
|
18427
18463
|
({ label, children }, ref) => {
|
|
18428
18464
|
return /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(
|
|
18429
18465
|
Menu,
|
|
@@ -18448,8 +18484,8 @@ var ParameterMenuButton = (0, import_react104.forwardRef)(
|
|
|
18448
18484
|
|
|
18449
18485
|
// src/components/ParameterInputs/styles/ParameterShell.styles.ts
|
|
18450
18486
|
init_emotion_jsx_shim();
|
|
18451
|
-
var
|
|
18452
|
-
var emptyParameterShell =
|
|
18487
|
+
var import_react106 = require("@emotion/react");
|
|
18488
|
+
var emptyParameterShell = import_react106.css`
|
|
18453
18489
|
border-radius: var(--rounded-sm);
|
|
18454
18490
|
background: var(--white);
|
|
18455
18491
|
flex-grow: 1;
|
|
@@ -18457,7 +18493,7 @@ var emptyParameterShell = import_react105.css`
|
|
|
18457
18493
|
position: relative;
|
|
18458
18494
|
max-width: 100%;
|
|
18459
18495
|
`;
|
|
18460
|
-
var emptyParameterShellText =
|
|
18496
|
+
var emptyParameterShellText = import_react106.css`
|
|
18461
18497
|
background: var(--brand-secondary-6);
|
|
18462
18498
|
border-radius: var(--rounded-sm);
|
|
18463
18499
|
padding: var(--spacing-sm);
|
|
@@ -18465,7 +18501,7 @@ var emptyParameterShellText = import_react105.css`
|
|
|
18465
18501
|
font-size: var(--fs-sm);
|
|
18466
18502
|
margin: 0;
|
|
18467
18503
|
`;
|
|
18468
|
-
var overrideMarker =
|
|
18504
|
+
var overrideMarker = import_react106.css`
|
|
18469
18505
|
border-radius: var(--rounded-sm);
|
|
18470
18506
|
border: 10px solid var(--gray-300);
|
|
18471
18507
|
border-left-color: transparent;
|
|
@@ -18490,7 +18526,7 @@ var extractParameterProps = (props) => {
|
|
|
18490
18526
|
hiddenLabel,
|
|
18491
18527
|
labelLeadingIcon,
|
|
18492
18528
|
menuItems,
|
|
18493
|
-
title,
|
|
18529
|
+
title: title2,
|
|
18494
18530
|
hasOverriddenValue,
|
|
18495
18531
|
onResetOverriddenValue,
|
|
18496
18532
|
...innerProps
|
|
@@ -18508,7 +18544,7 @@ var extractParameterProps = (props) => {
|
|
|
18508
18544
|
hiddenLabel,
|
|
18509
18545
|
labelLeadingIcon,
|
|
18510
18546
|
menuItems,
|
|
18511
|
-
title,
|
|
18547
|
+
title: title2,
|
|
18512
18548
|
hasOverriddenValue,
|
|
18513
18549
|
onResetOverriddenValue
|
|
18514
18550
|
},
|
|
@@ -18528,27 +18564,40 @@ var ParameterShell = ({
|
|
|
18528
18564
|
errorTestId,
|
|
18529
18565
|
captionTestId,
|
|
18530
18566
|
menuItems,
|
|
18567
|
+
actionItems,
|
|
18531
18568
|
hasOverriddenValue,
|
|
18532
18569
|
onResetOverriddenValue,
|
|
18533
|
-
title,
|
|
18570
|
+
title: title2,
|
|
18534
18571
|
children,
|
|
18535
18572
|
...props
|
|
18536
18573
|
}) => {
|
|
18537
|
-
const [manualErrorMessage, setManualErrorMessage] = (0,
|
|
18574
|
+
const [manualErrorMessage, setManualErrorMessage] = (0, import_react108.useState)(void 0);
|
|
18538
18575
|
const setErrorMessage = (message) => setManualErrorMessage(message);
|
|
18539
18576
|
const errorMessaging = errorMessage || manualErrorMessage;
|
|
18540
18577
|
return /* @__PURE__ */ (0, import_jsx_runtime96.jsxs)("div", { css: inputContainer2, ...props, children: [
|
|
18541
|
-
hiddenLabel ||
|
|
18578
|
+
hiddenLabel || title2 ? null : /* @__PURE__ */ (0, import_jsx_runtime96.jsxs)(ParameterLabel, { id, css: labelText2, children: [
|
|
18542
18579
|
labelLeadingIcon != null ? labelLeadingIcon : null,
|
|
18543
18580
|
label,
|
|
18544
18581
|
labelTrailingIcon != null ? labelTrailingIcon : null
|
|
18545
18582
|
] }),
|
|
18546
|
-
!
|
|
18583
|
+
!title2 ? null : /* @__PURE__ */ (0, import_jsx_runtime96.jsxs)(ParameterLabel, { id, asSpan: true, children: [
|
|
18547
18584
|
labelLeadingIcon != null ? labelLeadingIcon : null,
|
|
18548
|
-
|
|
18585
|
+
title2,
|
|
18549
18586
|
labelTrailingIcon != null ? labelTrailingIcon : null
|
|
18550
18587
|
] }),
|
|
18551
18588
|
/* @__PURE__ */ (0, import_jsx_runtime96.jsxs)("div", { css: inputWrapper, children: [
|
|
18589
|
+
actionItems ? /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(
|
|
18590
|
+
"div",
|
|
18591
|
+
{
|
|
18592
|
+
css: [
|
|
18593
|
+
inputMenu,
|
|
18594
|
+
menuItems ? import_react107.css`
|
|
18595
|
+
right: var(--spacing-md);
|
|
18596
|
+
` : void 0
|
|
18597
|
+
],
|
|
18598
|
+
children: actionItems
|
|
18599
|
+
}
|
|
18600
|
+
) : null,
|
|
18552
18601
|
menuItems ? /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(ParameterMenuButton, { label: `${label} menu`, children: menuItems }) : null,
|
|
18553
18602
|
/* @__PURE__ */ (0, import_jsx_runtime96.jsx)(
|
|
18554
18603
|
ParameterShellContext.Provider,
|
|
@@ -18580,7 +18629,7 @@ var ParameterOverrideMarker = (props) => /* @__PURE__ */ (0, import_jsx_runtime9
|
|
|
18580
18629
|
|
|
18581
18630
|
// src/components/ParameterInputs/ParameterImage.tsx
|
|
18582
18631
|
var import_jsx_runtime97 = require("@emotion/react/jsx-runtime");
|
|
18583
|
-
var ParameterImage = (0,
|
|
18632
|
+
var ParameterImage = (0, import_react109.forwardRef)(
|
|
18584
18633
|
({ children, ...props }, ref) => {
|
|
18585
18634
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
18586
18635
|
return /* @__PURE__ */ (0, import_jsx_runtime97.jsxs)(ParameterShell, { "data-test-id": "parameter-image", ...shellProps, children: [
|
|
@@ -18589,10 +18638,10 @@ var ParameterImage = (0, import_react107.forwardRef)(
|
|
|
18589
18638
|
] });
|
|
18590
18639
|
}
|
|
18591
18640
|
);
|
|
18592
|
-
var ParameterImageInner = (0,
|
|
18641
|
+
var ParameterImageInner = (0, import_react109.forwardRef)((props, ref) => {
|
|
18593
18642
|
const { value } = props;
|
|
18594
18643
|
const { id, label, hiddenLabel, errorMessage } = useParameterShell();
|
|
18595
|
-
const deferredValue = (0,
|
|
18644
|
+
const deferredValue = (0, import_react109.useDeferredValue)(value);
|
|
18596
18645
|
return /* @__PURE__ */ (0, import_jsx_runtime97.jsxs)(import_jsx_runtime97.Fragment, { children: [
|
|
18597
18646
|
/* @__PURE__ */ (0, import_jsx_runtime97.jsx)(
|
|
18598
18647
|
"input",
|
|
@@ -18612,13 +18661,13 @@ var ParameterImageInner = (0, import_react107.forwardRef)((props, ref) => {
|
|
|
18612
18661
|
|
|
18613
18662
|
// src/components/ParameterInputs/ParameterInput.tsx
|
|
18614
18663
|
init_emotion_jsx_shim();
|
|
18615
|
-
var
|
|
18664
|
+
var import_react110 = require("react");
|
|
18616
18665
|
var import_jsx_runtime98 = require("@emotion/react/jsx-runtime");
|
|
18617
|
-
var ParameterInput = (0,
|
|
18666
|
+
var ParameterInput = (0, import_react110.forwardRef)((props, ref) => {
|
|
18618
18667
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
18619
18668
|
return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(ParameterShell, { "data-testid": "parameter-input", ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(ParameterInputInner, { ref, ...innerProps }) });
|
|
18620
18669
|
});
|
|
18621
|
-
var ParameterInputInner = (0,
|
|
18670
|
+
var ParameterInputInner = (0, import_react110.forwardRef)(
|
|
18622
18671
|
({ ...props }, ref) => {
|
|
18623
18672
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
18624
18673
|
return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(
|
|
@@ -18638,9 +18687,9 @@ var ParameterInputInner = (0, import_react108.forwardRef)(
|
|
|
18638
18687
|
|
|
18639
18688
|
// src/components/ParameterInputs/ParameterLink.tsx
|
|
18640
18689
|
init_emotion_jsx_shim();
|
|
18641
|
-
var
|
|
18690
|
+
var import_react111 = require("react");
|
|
18642
18691
|
var import_jsx_runtime99 = require("@emotion/react/jsx-runtime");
|
|
18643
|
-
var ParameterLink = (0,
|
|
18692
|
+
var ParameterLink = (0, import_react111.forwardRef)(
|
|
18644
18693
|
({ disabled, onConnectLink, externalLink, ...props }, ref) => {
|
|
18645
18694
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
18646
18695
|
return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(
|
|
@@ -18663,7 +18712,7 @@ var ParameterLink = (0, import_react109.forwardRef)(
|
|
|
18663
18712
|
);
|
|
18664
18713
|
}
|
|
18665
18714
|
);
|
|
18666
|
-
var ParameterLinkInner = (0,
|
|
18715
|
+
var ParameterLinkInner = (0, import_react111.forwardRef)(
|
|
18667
18716
|
({ externalLink, onConnectLink, disabled, buttonText = "Select link", ...props }, ref) => {
|
|
18668
18717
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
18669
18718
|
if (!props.value)
|
|
@@ -18789,7 +18838,7 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
18789
18838
|
|
|
18790
18839
|
// src/components/ParameterInputs/ParameterRichText.tsx
|
|
18791
18840
|
init_emotion_jsx_shim();
|
|
18792
|
-
var
|
|
18841
|
+
var import_react118 = require("@emotion/react");
|
|
18793
18842
|
var import_list3 = require("@lexical/list");
|
|
18794
18843
|
var import_markdown = require("@lexical/markdown");
|
|
18795
18844
|
var import_LexicalComposer = require("@lexical/react/LexicalComposer");
|
|
@@ -18896,7 +18945,7 @@ var getLabelForElement = (type) => {
|
|
|
18896
18945
|
// src/components/ParameterInputs/ParameterRichText.tsx
|
|
18897
18946
|
var import_fast_equals2 = require("fast-equals");
|
|
18898
18947
|
var import_lexical6 = require("lexical");
|
|
18899
|
-
var
|
|
18948
|
+
var import_react119 = require("react");
|
|
18900
18949
|
|
|
18901
18950
|
// src/components/ParameterInputs/rich-text/CustomCodeNode.ts
|
|
18902
18951
|
init_emotion_jsx_shim();
|
|
@@ -18919,10 +18968,10 @@ init_emotion_jsx_shim();
|
|
|
18919
18968
|
var import_LexicalComposerContext = require("@lexical/react/LexicalComposerContext");
|
|
18920
18969
|
var import_utils2 = require("@lexical/utils");
|
|
18921
18970
|
var import_lexical = require("lexical");
|
|
18922
|
-
var
|
|
18971
|
+
var import_react112 = require("react");
|
|
18923
18972
|
function DisableStylesPlugin() {
|
|
18924
18973
|
const [editor] = (0, import_LexicalComposerContext.useLexicalComposerContext)();
|
|
18925
|
-
(0,
|
|
18974
|
+
(0, import_react112.useEffect)(() => {
|
|
18926
18975
|
return (0, import_utils2.mergeRegister)(
|
|
18927
18976
|
// Disable text alignment on paragraph nodes
|
|
18928
18977
|
editor.registerNodeTransform(import_lexical.ParagraphNode, (node) => {
|
|
@@ -19117,13 +19166,13 @@ var codeElement = import_css.css`
|
|
|
19117
19166
|
|
|
19118
19167
|
// src/components/ParameterInputs/rich-text/LinkNodePlugin.tsx
|
|
19119
19168
|
init_emotion_jsx_shim();
|
|
19120
|
-
var
|
|
19169
|
+
var import_react113 = require("@emotion/react");
|
|
19121
19170
|
var import_LexicalComposerContext2 = require("@lexical/react/LexicalComposerContext");
|
|
19122
19171
|
var import_LexicalNodeEventPlugin = require("@lexical/react/LexicalNodeEventPlugin");
|
|
19123
19172
|
var import_utils3 = require("@lexical/utils");
|
|
19124
19173
|
var import_fast_equals = require("fast-equals");
|
|
19125
19174
|
var import_lexical3 = require("lexical");
|
|
19126
|
-
var
|
|
19175
|
+
var import_react114 = require("react");
|
|
19127
19176
|
|
|
19128
19177
|
// src/components/ParameterInputs/rich-text/utils.ts
|
|
19129
19178
|
init_emotion_jsx_shim();
|
|
@@ -19449,16 +19498,16 @@ var OPEN_LINK_NODE_MODAL_COMMAND = (0, import_lexical3.createCommand)(
|
|
|
19449
19498
|
);
|
|
19450
19499
|
var LINK_POPOVER_OFFSET_X = 0;
|
|
19451
19500
|
var LINK_POPOVER_OFFSET_Y = 8;
|
|
19452
|
-
var linkPopover =
|
|
19501
|
+
var linkPopover = import_react113.css`
|
|
19453
19502
|
position: absolute;
|
|
19454
19503
|
z-index: 5;
|
|
19455
19504
|
`;
|
|
19456
|
-
var linkPopoverContainer =
|
|
19505
|
+
var linkPopoverContainer = import_react113.css`
|
|
19457
19506
|
${Popover};
|
|
19458
19507
|
align-items: center;
|
|
19459
19508
|
display: flex;
|
|
19460
19509
|
`;
|
|
19461
|
-
var linkPopoverAnchor =
|
|
19510
|
+
var linkPopoverAnchor = import_react113.css`
|
|
19462
19511
|
${link}
|
|
19463
19512
|
${linkColorDefault}
|
|
19464
19513
|
`;
|
|
@@ -19467,17 +19516,17 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
19467
19516
|
return path;
|
|
19468
19517
|
};
|
|
19469
19518
|
const [editor] = (0, import_LexicalComposerContext2.useLexicalComposerContext)();
|
|
19470
|
-
const [linkPopoverState, setLinkPopoverState] = (0,
|
|
19471
|
-
const linkPopoverElRef = (0,
|
|
19472
|
-
const [isEditorFocused, setIsEditorFocused] = (0,
|
|
19473
|
-
const [isLinkPopoverFocused, setIsLinkPopoverFocused] = (0,
|
|
19474
|
-
(0,
|
|
19519
|
+
const [linkPopoverState, setLinkPopoverState] = (0, import_react114.useState)();
|
|
19520
|
+
const linkPopoverElRef = (0, import_react114.useRef)(null);
|
|
19521
|
+
const [isEditorFocused, setIsEditorFocused] = (0, import_react114.useState)(false);
|
|
19522
|
+
const [isLinkPopoverFocused, setIsLinkPopoverFocused] = (0, import_react114.useState)(false);
|
|
19523
|
+
(0, import_react114.useEffect)(() => {
|
|
19475
19524
|
if (!isEditorFocused && !isLinkPopoverFocused) {
|
|
19476
19525
|
setLinkPopoverState(void 0);
|
|
19477
19526
|
return;
|
|
19478
19527
|
}
|
|
19479
19528
|
}, [isEditorFocused, isLinkPopoverFocused]);
|
|
19480
|
-
(0,
|
|
19529
|
+
(0, import_react114.useEffect)(() => {
|
|
19481
19530
|
if (!editor.hasNodes([LinkNode])) {
|
|
19482
19531
|
throw new Error("LinkNode not registered on editor");
|
|
19483
19532
|
}
|
|
@@ -19546,7 +19595,7 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
19546
19595
|
)
|
|
19547
19596
|
);
|
|
19548
19597
|
}, [editor, onConnectLink]);
|
|
19549
|
-
const maybeShowLinkToolbar = (0,
|
|
19598
|
+
const maybeShowLinkToolbar = (0, import_react114.useCallback)(() => {
|
|
19550
19599
|
if (!editor.isEditable()) {
|
|
19551
19600
|
return;
|
|
19552
19601
|
}
|
|
@@ -19578,7 +19627,7 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
19578
19627
|
}
|
|
19579
19628
|
});
|
|
19580
19629
|
}, [editor]);
|
|
19581
|
-
(0,
|
|
19630
|
+
(0, import_react114.useEffect)(() => {
|
|
19582
19631
|
return editor.registerUpdateListener(({ editorState }) => {
|
|
19583
19632
|
requestAnimationFrame(() => {
|
|
19584
19633
|
editorState.read(() => {
|
|
@@ -19666,7 +19715,7 @@ var import_list = require("@lexical/list");
|
|
|
19666
19715
|
var import_LexicalComposerContext3 = require("@lexical/react/LexicalComposerContext");
|
|
19667
19716
|
var import_LexicalTabIndentationPlugin = require("@lexical/react/LexicalTabIndentationPlugin");
|
|
19668
19717
|
var import_lexical4 = require("lexical");
|
|
19669
|
-
var
|
|
19718
|
+
var import_react115 = require("react");
|
|
19670
19719
|
var import_jsx_runtime102 = require("@emotion/react/jsx-runtime");
|
|
19671
19720
|
function isIndentPermitted(maxDepth) {
|
|
19672
19721
|
const selection = (0, import_lexical4.$getSelection)();
|
|
@@ -19690,7 +19739,7 @@ function isIndentPermitted(maxDepth) {
|
|
|
19690
19739
|
}
|
|
19691
19740
|
function ListIndentPlugin({ maxDepth }) {
|
|
19692
19741
|
const [editor] = (0, import_LexicalComposerContext3.useLexicalComposerContext)();
|
|
19693
|
-
(0,
|
|
19742
|
+
(0, import_react115.useEffect)(() => {
|
|
19694
19743
|
return editor.registerCommand(
|
|
19695
19744
|
import_lexical4.INDENT_CONTENT_COMMAND,
|
|
19696
19745
|
() => !isIndentPermitted(maxDepth),
|
|
@@ -19702,7 +19751,7 @@ function ListIndentPlugin({ maxDepth }) {
|
|
|
19702
19751
|
|
|
19703
19752
|
// src/components/ParameterInputs/rich-text/RichTextToolbar.tsx
|
|
19704
19753
|
init_emotion_jsx_shim();
|
|
19705
|
-
var
|
|
19754
|
+
var import_react116 = require("@emotion/react");
|
|
19706
19755
|
var import_code2 = require("@lexical/code");
|
|
19707
19756
|
var import_list2 = require("@lexical/list");
|
|
19708
19757
|
var import_LexicalComposerContext4 = require("@lexical/react/LexicalComposerContext");
|
|
@@ -19710,9 +19759,9 @@ var import_rich_text = require("@lexical/rich-text");
|
|
|
19710
19759
|
var import_selection2 = require("@lexical/selection");
|
|
19711
19760
|
var import_utils6 = require("@lexical/utils");
|
|
19712
19761
|
var import_lexical5 = require("lexical");
|
|
19713
|
-
var
|
|
19762
|
+
var import_react117 = require("react");
|
|
19714
19763
|
var import_jsx_runtime103 = require("@emotion/react/jsx-runtime");
|
|
19715
|
-
var toolbar =
|
|
19764
|
+
var toolbar = import_react116.css`
|
|
19716
19765
|
background: var(--gray-50);
|
|
19717
19766
|
border-radius: var(--rounded-base);
|
|
19718
19767
|
display: flex;
|
|
@@ -19724,7 +19773,7 @@ var toolbar = import_react114.css`
|
|
|
19724
19773
|
top: calc(var(--spacing-sm) * -2);
|
|
19725
19774
|
z-index: 10;
|
|
19726
19775
|
`;
|
|
19727
|
-
var toolbarGroup =
|
|
19776
|
+
var toolbarGroup = import_react116.css`
|
|
19728
19777
|
display: flex;
|
|
19729
19778
|
gap: var(--spacing-xs);
|
|
19730
19779
|
position: relative;
|
|
@@ -19740,7 +19789,7 @@ var toolbarGroup = import_react114.css`
|
|
|
19740
19789
|
width: 1px;
|
|
19741
19790
|
}
|
|
19742
19791
|
`;
|
|
19743
|
-
var richTextToolbarButton =
|
|
19792
|
+
var richTextToolbarButton = import_react116.css`
|
|
19744
19793
|
align-items: center;
|
|
19745
19794
|
appearance: none;
|
|
19746
19795
|
border: 0;
|
|
@@ -19753,13 +19802,13 @@ var richTextToolbarButton = import_react114.css`
|
|
|
19753
19802
|
min-width: 32px;
|
|
19754
19803
|
padding: 0 var(--spacing-sm);
|
|
19755
19804
|
`;
|
|
19756
|
-
var richTextToolbarButtonActive =
|
|
19805
|
+
var richTextToolbarButtonActive = import_react116.css`
|
|
19757
19806
|
background: var(--gray-200);
|
|
19758
19807
|
`;
|
|
19759
|
-
var toolbarIcon =
|
|
19808
|
+
var toolbarIcon = import_react116.css`
|
|
19760
19809
|
color: inherit;
|
|
19761
19810
|
`;
|
|
19762
|
-
var toolbarChevron =
|
|
19811
|
+
var toolbarChevron = import_react116.css`
|
|
19763
19812
|
margin-left: var(--spacing-xs);
|
|
19764
19813
|
`;
|
|
19765
19814
|
var RichTextToolbarIcon = ({ icon }) => {
|
|
@@ -19814,7 +19863,7 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
19814
19863
|
}
|
|
19815
19864
|
});
|
|
19816
19865
|
};
|
|
19817
|
-
const updateToolbar = (0,
|
|
19866
|
+
const updateToolbar = (0, import_react117.useCallback)(() => {
|
|
19818
19867
|
const selection = (0, import_lexical5.$getSelection)();
|
|
19819
19868
|
if (!(0, import_lexical5.$isRangeSelection)(selection)) {
|
|
19820
19869
|
return;
|
|
@@ -19853,7 +19902,7 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
19853
19902
|
setIsLink(false);
|
|
19854
19903
|
}
|
|
19855
19904
|
}, [editor, setActiveElement, setActiveFormats, setIsLink]);
|
|
19856
|
-
(0,
|
|
19905
|
+
(0, import_react117.useEffect)(() => {
|
|
19857
19906
|
return editor.registerCommand(
|
|
19858
19907
|
import_lexical5.SELECTION_CHANGE_COMMAND,
|
|
19859
19908
|
(_payload) => {
|
|
@@ -19863,7 +19912,7 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
19863
19912
|
import_lexical5.COMMAND_PRIORITY_CRITICAL
|
|
19864
19913
|
);
|
|
19865
19914
|
}, [editor, updateToolbar]);
|
|
19866
|
-
(0,
|
|
19915
|
+
(0, import_react117.useEffect)(() => {
|
|
19867
19916
|
return editor.registerUpdateListener(({ editorState }) => {
|
|
19868
19917
|
requestAnimationFrame(() => {
|
|
19869
19918
|
editorState.read(() => {
|
|
@@ -20003,26 +20052,26 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
20003
20052
|
var RichTextToolbar_default = RichTextToolbar;
|
|
20004
20053
|
var useRichTextToolbarState = ({ config }) => {
|
|
20005
20054
|
var _a;
|
|
20006
|
-
const enabledBuiltInFormats = (0,
|
|
20055
|
+
const enabledBuiltInFormats = (0, import_react117.useMemo)(() => {
|
|
20007
20056
|
return richTextBuiltInFormats.filter((format) => {
|
|
20008
20057
|
var _a2, _b;
|
|
20009
20058
|
return (_b = (_a2 = config == null ? void 0 : config.formatting) == null ? void 0 : _a2.builtIn) == null ? void 0 : _b.includes(format.type);
|
|
20010
20059
|
});
|
|
20011
20060
|
}, [config]);
|
|
20012
|
-
const enabledBuiltInElements = (0,
|
|
20061
|
+
const enabledBuiltInElements = (0, import_react117.useMemo)(() => {
|
|
20013
20062
|
return richTextBuiltInElements.filter((element) => {
|
|
20014
20063
|
var _a2, _b;
|
|
20015
20064
|
return (_b = (_a2 = config == null ? void 0 : config.elements) == null ? void 0 : _a2.builtIn) == null ? void 0 : _b.includes(element.type);
|
|
20016
20065
|
});
|
|
20017
20066
|
}, [config]);
|
|
20018
|
-
const enabledBuiltInFormatsWithIcon = (0,
|
|
20067
|
+
const enabledBuiltInFormatsWithIcon = (0, import_react117.useMemo)(() => {
|
|
20019
20068
|
return enabledBuiltInFormats.filter((format) => FORMATS_WITH_ICON.has(format.type));
|
|
20020
20069
|
}, [enabledBuiltInFormats]);
|
|
20021
20070
|
const enabledBuiltInFormatsWithoutIcon = enabledBuiltInFormats.filter(
|
|
20022
20071
|
(format) => !FORMATS_WITH_ICON.has(format.type)
|
|
20023
20072
|
);
|
|
20024
|
-
const [activeFormats, setActiveFormats] = (0,
|
|
20025
|
-
const visibleFormatsWithIcon = (0,
|
|
20073
|
+
const [activeFormats, setActiveFormats] = (0, import_react117.useState)([]);
|
|
20074
|
+
const visibleFormatsWithIcon = (0, import_react117.useMemo)(() => {
|
|
20026
20075
|
const visibleFormats = /* @__PURE__ */ new Set();
|
|
20027
20076
|
activeFormats.filter((type) => FORMATS_WITH_ICON.has(type)).forEach((type) => {
|
|
20028
20077
|
visibleFormats.add(type);
|
|
@@ -20032,7 +20081,7 @@ var useRichTextToolbarState = ({ config }) => {
|
|
|
20032
20081
|
});
|
|
20033
20082
|
return richTextBuiltInFormats.filter((format) => visibleFormats.has(format.type));
|
|
20034
20083
|
}, [activeFormats, enabledBuiltInFormatsWithIcon]);
|
|
20035
|
-
const visibleFormatsWithoutIcon = (0,
|
|
20084
|
+
const visibleFormatsWithoutIcon = (0, import_react117.useMemo)(() => {
|
|
20036
20085
|
const visibleFormats = /* @__PURE__ */ new Set();
|
|
20037
20086
|
activeFormats.filter((type) => !FORMATS_WITH_ICON.has(type)).forEach((type) => {
|
|
20038
20087
|
visibleFormats.add(type);
|
|
@@ -20042,11 +20091,11 @@ var useRichTextToolbarState = ({ config }) => {
|
|
|
20042
20091
|
});
|
|
20043
20092
|
return richTextBuiltInFormats.filter((format) => visibleFormats.has(format.type));
|
|
20044
20093
|
}, [activeFormats, enabledBuiltInFormatsWithoutIcon]);
|
|
20045
|
-
const [activeElement, setActiveElement] = (0,
|
|
20094
|
+
const [activeElement, setActiveElement] = (0, import_react117.useState)("paragraph");
|
|
20046
20095
|
const enabledTextualElements = enabledBuiltInElements.filter(
|
|
20047
20096
|
(element) => TEXTUAL_ELEMENTS.includes(element.type)
|
|
20048
20097
|
);
|
|
20049
|
-
const visibleTextualElements = (0,
|
|
20098
|
+
const visibleTextualElements = (0, import_react117.useMemo)(() => {
|
|
20050
20099
|
if (!TEXTUAL_ELEMENTS.includes(activeElement)) {
|
|
20051
20100
|
return enabledTextualElements;
|
|
20052
20101
|
}
|
|
@@ -20057,24 +20106,24 @@ var useRichTextToolbarState = ({ config }) => {
|
|
|
20057
20106
|
}
|
|
20058
20107
|
);
|
|
20059
20108
|
}, [activeElement, (_a = config == null ? void 0 : config.elements) == null ? void 0 : _a.builtIn, enabledTextualElements]);
|
|
20060
|
-
const [isLink, setIsLink] = (0,
|
|
20061
|
-
const linkElementVisible = (0,
|
|
20109
|
+
const [isLink, setIsLink] = (0, import_react117.useState)(false);
|
|
20110
|
+
const linkElementVisible = (0, import_react117.useMemo)(() => {
|
|
20062
20111
|
return enabledBuiltInElements.some((element) => element.type === "link") || isLink;
|
|
20063
20112
|
}, [isLink, enabledBuiltInElements]);
|
|
20064
|
-
const visibleLists = (0,
|
|
20113
|
+
const visibleLists = (0, import_react117.useMemo)(() => {
|
|
20065
20114
|
return new Set(
|
|
20066
20115
|
["orderedList", "unorderedList"].filter(
|
|
20067
20116
|
(type) => enabledBuiltInElements.some((element) => element.type === type) || activeElement === type
|
|
20068
20117
|
)
|
|
20069
20118
|
);
|
|
20070
20119
|
}, [activeElement, enabledBuiltInElements]);
|
|
20071
|
-
const quoteElementVisible = (0,
|
|
20120
|
+
const quoteElementVisible = (0, import_react117.useMemo)(() => {
|
|
20072
20121
|
return enabledBuiltInElements.some((element) => element.type === "quote") || activeElement === "quote";
|
|
20073
20122
|
}, [activeElement, enabledBuiltInElements]);
|
|
20074
|
-
const codeElementVisible = (0,
|
|
20123
|
+
const codeElementVisible = (0, import_react117.useMemo)(() => {
|
|
20075
20124
|
return enabledBuiltInElements.some((element) => element.type === "code") || activeElement === "code";
|
|
20076
20125
|
}, [activeElement, enabledBuiltInElements]);
|
|
20077
|
-
const visibleElementsWithIcons = (0,
|
|
20126
|
+
const visibleElementsWithIcons = (0, import_react117.useMemo)(() => {
|
|
20078
20127
|
const visibleElements = /* @__PURE__ */ new Set();
|
|
20079
20128
|
if (linkElementVisible) {
|
|
20080
20129
|
visibleElements.add("link");
|
|
@@ -20173,18 +20222,18 @@ var ParameterRichText = ({
|
|
|
20173
20222
|
}
|
|
20174
20223
|
);
|
|
20175
20224
|
};
|
|
20176
|
-
var editorWrapper =
|
|
20225
|
+
var editorWrapper = import_react118.css`
|
|
20177
20226
|
display: flex;
|
|
20178
20227
|
flex-flow: column;
|
|
20179
20228
|
flex-grow: 1;
|
|
20180
20229
|
`;
|
|
20181
|
-
var editorContainer =
|
|
20230
|
+
var editorContainer = import_react118.css`
|
|
20182
20231
|
display: flex;
|
|
20183
20232
|
flex-flow: column;
|
|
20184
20233
|
flex-grow: 1;
|
|
20185
20234
|
position: relative;
|
|
20186
20235
|
`;
|
|
20187
|
-
var editorPlaceholder =
|
|
20236
|
+
var editorPlaceholder = import_react118.css`
|
|
20188
20237
|
color: var(--gray-500);
|
|
20189
20238
|
font-style: italic;
|
|
20190
20239
|
/* 1px is added to make sure caret is clearly visible when field is focused
|
|
@@ -20195,7 +20244,7 @@ var editorPlaceholder = import_react116.css`
|
|
|
20195
20244
|
top: var(--spacing-xs);
|
|
20196
20245
|
user-select: none;
|
|
20197
20246
|
`;
|
|
20198
|
-
var editorInput =
|
|
20247
|
+
var editorInput = import_react118.css`
|
|
20199
20248
|
background: var(--white);
|
|
20200
20249
|
border: 1px solid var(--white);
|
|
20201
20250
|
border-radius: var(--rounded-sm);
|
|
@@ -20317,14 +20366,14 @@ var RichText = ({
|
|
|
20317
20366
|
variables,
|
|
20318
20367
|
customControls
|
|
20319
20368
|
}) => {
|
|
20320
|
-
const editorContainerRef = (0,
|
|
20369
|
+
const editorContainerRef = (0, import_react119.useRef)(null);
|
|
20321
20370
|
const [editor] = (0, import_LexicalComposerContext5.useLexicalComposerContext)();
|
|
20322
|
-
(0,
|
|
20371
|
+
(0, import_react119.useEffect)(() => {
|
|
20323
20372
|
if (onRichTextInit) {
|
|
20324
20373
|
onRichTextInit(editor);
|
|
20325
20374
|
}
|
|
20326
20375
|
}, [editor, onRichTextInit]);
|
|
20327
|
-
(0,
|
|
20376
|
+
(0, import_react119.useEffect)(() => {
|
|
20328
20377
|
const removeUpdateListener = editor.registerUpdateListener(({ editorState, prevEditorState }) => {
|
|
20329
20378
|
requestAnimationFrame(() => {
|
|
20330
20379
|
if (!(0, import_fast_equals2.deepEqual)(editorState.toJSON(), prevEditorState.toJSON())) {
|
|
@@ -20369,15 +20418,15 @@ var RichText = ({
|
|
|
20369
20418
|
|
|
20370
20419
|
// src/components/ParameterInputs/ParameterSelect.tsx
|
|
20371
20420
|
init_emotion_jsx_shim();
|
|
20372
|
-
var
|
|
20421
|
+
var import_react120 = require("react");
|
|
20373
20422
|
var import_jsx_runtime105 = require("@emotion/react/jsx-runtime");
|
|
20374
|
-
var ParameterSelect = (0,
|
|
20423
|
+
var ParameterSelect = (0, import_react120.forwardRef)(
|
|
20375
20424
|
({ defaultOption, options, ...props }, ref) => {
|
|
20376
20425
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
20377
20426
|
return /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(ParameterShell, { ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(ParameterSelectInner, { options, defaultOption, ...innerProps, ref }) });
|
|
20378
20427
|
}
|
|
20379
20428
|
);
|
|
20380
|
-
var ParameterSelectInner = (0,
|
|
20429
|
+
var ParameterSelectInner = (0, import_react120.forwardRef)(
|
|
20381
20430
|
({ defaultOption, options, ...props }, ref) => {
|
|
20382
20431
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
20383
20432
|
return /* @__PURE__ */ (0, import_jsx_runtime105.jsxs)(
|
|
@@ -20402,13 +20451,13 @@ var ParameterSelectInner = (0, import_react118.forwardRef)(
|
|
|
20402
20451
|
|
|
20403
20452
|
// src/components/ParameterInputs/ParameterTextarea.tsx
|
|
20404
20453
|
init_emotion_jsx_shim();
|
|
20405
|
-
var
|
|
20454
|
+
var import_react121 = require("react");
|
|
20406
20455
|
var import_jsx_runtime106 = require("@emotion/react/jsx-runtime");
|
|
20407
|
-
var ParameterTextarea = (0,
|
|
20456
|
+
var ParameterTextarea = (0, import_react121.forwardRef)((props, ref) => {
|
|
20408
20457
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
20409
20458
|
return /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(ParameterShell, { "data-testid": "parameter-textarea", ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(ParameterTextareaInner, { ref, ...innerProps }) });
|
|
20410
20459
|
});
|
|
20411
|
-
var ParameterTextareaInner = (0,
|
|
20460
|
+
var ParameterTextareaInner = (0, import_react121.forwardRef)(({ ...props }, ref) => {
|
|
20412
20461
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
20413
20462
|
return /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(
|
|
20414
20463
|
"textarea",
|
|
@@ -20424,13 +20473,13 @@ var ParameterTextareaInner = (0, import_react119.forwardRef)(({ ...props }, ref)
|
|
|
20424
20473
|
|
|
20425
20474
|
// src/components/ParameterInputs/ParameterToggle.tsx
|
|
20426
20475
|
init_emotion_jsx_shim();
|
|
20427
|
-
var
|
|
20476
|
+
var import_react122 = require("react");
|
|
20428
20477
|
var import_jsx_runtime107 = require("@emotion/react/jsx-runtime");
|
|
20429
|
-
var ParameterToggle = (0,
|
|
20478
|
+
var ParameterToggle = (0, import_react122.forwardRef)((props, ref) => {
|
|
20430
20479
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
20431
20480
|
return /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(ParameterShell, { ...shellProps, children: /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(ParameterToggleInner, { ref, ...innerProps }) });
|
|
20432
20481
|
});
|
|
20433
|
-
var ParameterToggleInner = (0,
|
|
20482
|
+
var ParameterToggleInner = (0, import_react122.forwardRef)(
|
|
20434
20483
|
({ ...props }, ref) => {
|
|
20435
20484
|
const { id, label } = useParameterShell();
|
|
20436
20485
|
return /* @__PURE__ */ (0, import_jsx_runtime107.jsxs)("label", { css: inputToggleLabel2, children: [
|
|
@@ -20445,8 +20494,8 @@ init_emotion_jsx_shim();
|
|
|
20445
20494
|
|
|
20446
20495
|
// src/components/ProgressBar/ProgressBar.styles.ts
|
|
20447
20496
|
init_emotion_jsx_shim();
|
|
20448
|
-
var
|
|
20449
|
-
var container =
|
|
20497
|
+
var import_react123 = require("@emotion/react");
|
|
20498
|
+
var container = import_react123.css`
|
|
20450
20499
|
background: var(--gray-50);
|
|
20451
20500
|
margin-block: var(--spacing-sm);
|
|
20452
20501
|
position: relative;
|
|
@@ -20456,14 +20505,14 @@ var container = import_react121.css`
|
|
|
20456
20505
|
border: solid 1px var(--gray-300);
|
|
20457
20506
|
`;
|
|
20458
20507
|
var themeMap = {
|
|
20459
|
-
primary:
|
|
20508
|
+
primary: import_react123.css`
|
|
20460
20509
|
background-color: var(--accent-light);
|
|
20461
20510
|
`,
|
|
20462
|
-
secondary:
|
|
20511
|
+
secondary: import_react123.css`
|
|
20463
20512
|
background-color: var(--brand-secondary-5);
|
|
20464
20513
|
`
|
|
20465
20514
|
};
|
|
20466
|
-
var bar =
|
|
20515
|
+
var bar = import_react123.css`
|
|
20467
20516
|
position: absolute;
|
|
20468
20517
|
inset: 0;
|
|
20469
20518
|
transition: transform var(--duration-fast) var(--timing-ease-out);
|
|
@@ -20502,22 +20551,22 @@ function ProgressBar({ className, current, max, theme = "primary" }) {
|
|
|
20502
20551
|
|
|
20503
20552
|
// src/components/ProgressList/ProgressList.tsx
|
|
20504
20553
|
init_emotion_jsx_shim();
|
|
20505
|
-
var
|
|
20554
|
+
var import_react125 = require("@emotion/react");
|
|
20506
20555
|
var import_CgCheckO3 = require("@react-icons/all-files/cg/CgCheckO");
|
|
20507
20556
|
var import_CgRadioCheck2 = require("@react-icons/all-files/cg/CgRadioCheck");
|
|
20508
20557
|
var import_CgRecord2 = require("@react-icons/all-files/cg/CgRecord");
|
|
20509
|
-
var
|
|
20558
|
+
var import_react126 = require("react");
|
|
20510
20559
|
|
|
20511
20560
|
// src/components/ProgressList/styles/ProgressList.styles.ts
|
|
20512
20561
|
init_emotion_jsx_shim();
|
|
20513
|
-
var
|
|
20514
|
-
var progressListStyles =
|
|
20562
|
+
var import_react124 = require("@emotion/react");
|
|
20563
|
+
var progressListStyles = import_react124.css`
|
|
20515
20564
|
display: flex;
|
|
20516
20565
|
flex-direction: column;
|
|
20517
20566
|
gap: var(--spacing-sm);
|
|
20518
20567
|
list-style-type: none;
|
|
20519
20568
|
`;
|
|
20520
|
-
var progressListItemStyles =
|
|
20569
|
+
var progressListItemStyles = import_react124.css`
|
|
20521
20570
|
display: flex;
|
|
20522
20571
|
gap: var(--spacing-base);
|
|
20523
20572
|
align-items: center;
|
|
@@ -20526,7 +20575,7 @@ var progressListItemStyles = import_react122.css`
|
|
|
20526
20575
|
// src/components/ProgressList/ProgressList.tsx
|
|
20527
20576
|
var import_jsx_runtime109 = require("@emotion/react/jsx-runtime");
|
|
20528
20577
|
var ProgressList = ({ inProgressId, items, autoEllipsis, ...htmlProps }) => {
|
|
20529
|
-
const itemsWithStatus = (0,
|
|
20578
|
+
const itemsWithStatus = (0, import_react126.useMemo)(() => {
|
|
20530
20579
|
const indexOfInProgressItem = items.findIndex(({ id }) => id === inProgressId);
|
|
20531
20580
|
return items.map((item, index) => {
|
|
20532
20581
|
let status = "queued";
|
|
@@ -20559,7 +20608,7 @@ var ProgressListItem = ({
|
|
|
20559
20608
|
errorLevel = "danger",
|
|
20560
20609
|
autoEllipsis = false
|
|
20561
20610
|
}) => {
|
|
20562
|
-
const icon = (0,
|
|
20611
|
+
const icon = (0, import_react126.useMemo)(() => {
|
|
20563
20612
|
if (error) {
|
|
20564
20613
|
return warningIcon;
|
|
20565
20614
|
}
|
|
@@ -20570,14 +20619,14 @@ var ProgressListItem = ({
|
|
|
20570
20619
|
};
|
|
20571
20620
|
return iconPerStatus[status];
|
|
20572
20621
|
}, [status, error]);
|
|
20573
|
-
const statusStyles = (0,
|
|
20622
|
+
const statusStyles = (0, import_react126.useMemo)(() => {
|
|
20574
20623
|
if (error) {
|
|
20575
|
-
return errorLevel === "caution" ?
|
|
20624
|
+
return errorLevel === "caution" ? import_react125.css`
|
|
20576
20625
|
color: rgb(161, 98, 7);
|
|
20577
20626
|
& svg {
|
|
20578
20627
|
color: rgb(250, 204, 21);
|
|
20579
20628
|
}
|
|
20580
|
-
` :
|
|
20629
|
+
` : import_react125.css`
|
|
20581
20630
|
color: rgb(185, 28, 28);
|
|
20582
20631
|
& svg {
|
|
20583
20632
|
color: var(--brand-primary-2);
|
|
@@ -20585,13 +20634,13 @@ var ProgressListItem = ({
|
|
|
20585
20634
|
`;
|
|
20586
20635
|
}
|
|
20587
20636
|
const colorPerStatus = {
|
|
20588
|
-
completed:
|
|
20637
|
+
completed: import_react125.css`
|
|
20589
20638
|
opacity: 0.75;
|
|
20590
20639
|
`,
|
|
20591
|
-
inProgress:
|
|
20640
|
+
inProgress: import_react125.css`
|
|
20592
20641
|
-webkit-text-stroke-width: thin;
|
|
20593
20642
|
`,
|
|
20594
|
-
queued:
|
|
20643
|
+
queued: import_react125.css`
|
|
20595
20644
|
opacity: 0.5;
|
|
20596
20645
|
`
|
|
20597
20646
|
};
|
|
@@ -20608,14 +20657,14 @@ var ProgressListItem = ({
|
|
|
20608
20657
|
|
|
20609
20658
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
20610
20659
|
init_emotion_jsx_shim();
|
|
20611
|
-
var
|
|
20660
|
+
var import_react128 = require("@emotion/react");
|
|
20612
20661
|
var import_CgCheck5 = require("@react-icons/all-files/cg/CgCheck");
|
|
20613
|
-
var
|
|
20662
|
+
var import_react129 = require("react");
|
|
20614
20663
|
|
|
20615
20664
|
// src/components/SegmentedControl/SegmentedControl.styles.ts
|
|
20616
20665
|
init_emotion_jsx_shim();
|
|
20617
|
-
var
|
|
20618
|
-
var segmentedControlStyles =
|
|
20666
|
+
var import_react127 = require("@emotion/react");
|
|
20667
|
+
var segmentedControlStyles = import_react127.css`
|
|
20619
20668
|
--segmented-control-rounded-value: var(--rounded-base);
|
|
20620
20669
|
--segmented-control-border-width: 1px;
|
|
20621
20670
|
--segmented-control-selected-color: var(--brand-secondary-3);
|
|
@@ -20634,14 +20683,14 @@ var segmentedControlStyles = import_react125.css`
|
|
|
20634
20683
|
border-radius: calc(var(--segmented-control-rounded-value) + var(--segmented-control-border-width));
|
|
20635
20684
|
font-size: var(--fs-xs);
|
|
20636
20685
|
`;
|
|
20637
|
-
var segmentedControlVerticalStyles =
|
|
20686
|
+
var segmentedControlVerticalStyles = import_react127.css`
|
|
20638
20687
|
flex-direction: column;
|
|
20639
20688
|
--segmented-control-first-border-radius: var(--segmented-control-rounded-value)
|
|
20640
20689
|
var(--segmented-control-rounded-value) 0 0;
|
|
20641
20690
|
--segmented-control-last-border-radius: 0 0 var(--segmented-control-rounded-value)
|
|
20642
20691
|
var(--segmented-control-rounded-value);
|
|
20643
20692
|
`;
|
|
20644
|
-
var segmentedControlItemStyles =
|
|
20693
|
+
var segmentedControlItemStyles = import_react127.css`
|
|
20645
20694
|
&:first-of-type label {
|
|
20646
20695
|
border-radius: var(--segmented-control-first-border-radius);
|
|
20647
20696
|
}
|
|
@@ -20649,10 +20698,10 @@ var segmentedControlItemStyles = import_react125.css`
|
|
|
20649
20698
|
border-radius: var(--segmented-control-last-border-radius);
|
|
20650
20699
|
}
|
|
20651
20700
|
`;
|
|
20652
|
-
var segmentedControlInputStyles =
|
|
20701
|
+
var segmentedControlInputStyles = import_react127.css`
|
|
20653
20702
|
${accessibleHidden}
|
|
20654
20703
|
`;
|
|
20655
|
-
var segmentedControlLabelStyles = (checked, disabled) =>
|
|
20704
|
+
var segmentedControlLabelStyles = (checked, disabled) => import_react127.css`
|
|
20656
20705
|
position: relative;
|
|
20657
20706
|
display: flex;
|
|
20658
20707
|
align-items: center;
|
|
@@ -20719,20 +20768,20 @@ var segmentedControlLabelStyles = (checked, disabled) => import_react125.css`
|
|
|
20719
20768
|
`}
|
|
20720
20769
|
}
|
|
20721
20770
|
`;
|
|
20722
|
-
var segmentedControlLabelIconOnlyStyles =
|
|
20771
|
+
var segmentedControlLabelIconOnlyStyles = import_react127.css`
|
|
20723
20772
|
padding-inline: 0.5em;
|
|
20724
20773
|
`;
|
|
20725
|
-
var segmentedControlLabelCheckStyles =
|
|
20774
|
+
var segmentedControlLabelCheckStyles = import_react127.css`
|
|
20726
20775
|
opacity: 0.5;
|
|
20727
20776
|
`;
|
|
20728
|
-
var segmentedControlLabelContentStyles =
|
|
20777
|
+
var segmentedControlLabelContentStyles = import_react127.css`
|
|
20729
20778
|
display: flex;
|
|
20730
20779
|
align-items: center;
|
|
20731
20780
|
justify-content: center;
|
|
20732
20781
|
gap: var(--spacing-sm);
|
|
20733
20782
|
height: 100%;
|
|
20734
20783
|
`;
|
|
20735
|
-
var segmentedControlLabelTextStyles =
|
|
20784
|
+
var segmentedControlLabelTextStyles = import_react127.css``;
|
|
20736
20785
|
|
|
20737
20786
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
20738
20787
|
var import_jsx_runtime110 = require("@emotion/react/jsx-runtime");
|
|
@@ -20747,7 +20796,7 @@ var SegmentedControl = ({
|
|
|
20747
20796
|
size = "md",
|
|
20748
20797
|
...props
|
|
20749
20798
|
}) => {
|
|
20750
|
-
const onOptionChange = (0,
|
|
20799
|
+
const onOptionChange = (0, import_react129.useCallback)(
|
|
20751
20800
|
(event) => {
|
|
20752
20801
|
if (event.target.checked) {
|
|
20753
20802
|
onChange == null ? void 0 : onChange(options[parseInt(event.target.value)].value);
|
|
@@ -20755,15 +20804,15 @@ var SegmentedControl = ({
|
|
|
20755
20804
|
},
|
|
20756
20805
|
[options, onChange]
|
|
20757
20806
|
);
|
|
20758
|
-
const sizeStyles = (0,
|
|
20807
|
+
const sizeStyles = (0, import_react129.useMemo)(() => {
|
|
20759
20808
|
const map = {
|
|
20760
|
-
sm: (0,
|
|
20761
|
-
md: (0,
|
|
20762
|
-
lg: (0,
|
|
20809
|
+
sm: (0, import_react128.css)({ height: "calc(24px - 2px)", fontSize: "var(--fs-xs)" }),
|
|
20810
|
+
md: (0, import_react128.css)({ height: "calc(32px - 2px)", fontSize: "var(--fs-sm)" }),
|
|
20811
|
+
lg: (0, import_react128.css)({ height: "calc(40px - 2px)", fontSize: "var(--fs-base)" })
|
|
20763
20812
|
};
|
|
20764
20813
|
return map[size];
|
|
20765
20814
|
}, [size]);
|
|
20766
|
-
const isIconOnly = (0,
|
|
20815
|
+
const isIconOnly = (0, import_react129.useMemo)(() => {
|
|
20767
20816
|
return options.every((option) => option.icon && !option.label);
|
|
20768
20817
|
}, [options]);
|
|
20769
20818
|
return /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(
|
|
@@ -20820,12 +20869,12 @@ init_emotion_jsx_shim();
|
|
|
20820
20869
|
|
|
20821
20870
|
// src/components/Skeleton/Skeleton.styles.ts
|
|
20822
20871
|
init_emotion_jsx_shim();
|
|
20823
|
-
var
|
|
20824
|
-
var lightFadingOut =
|
|
20872
|
+
var import_react130 = require("@emotion/react");
|
|
20873
|
+
var lightFadingOut = import_react130.keyframes`
|
|
20825
20874
|
from { opacity: 0.1; }
|
|
20826
20875
|
to { opacity: 0.025; }
|
|
20827
20876
|
`;
|
|
20828
|
-
var skeletonStyles =
|
|
20877
|
+
var skeletonStyles = import_react130.css`
|
|
20829
20878
|
animation: ${lightFadingOut} 1s ease-out infinite alternate;
|
|
20830
20879
|
background-color: var(--gray-900);
|
|
20831
20880
|
`;
|
|
@@ -20864,8 +20913,8 @@ var React23 = __toESM(require("react"));
|
|
|
20864
20913
|
|
|
20865
20914
|
// src/components/Switch/Switch.styles.ts
|
|
20866
20915
|
init_emotion_jsx_shim();
|
|
20867
|
-
var
|
|
20868
|
-
var SwitchInputContainer =
|
|
20916
|
+
var import_react131 = require("@emotion/react");
|
|
20917
|
+
var SwitchInputContainer = import_react131.css`
|
|
20869
20918
|
cursor: pointer;
|
|
20870
20919
|
display: inline-block;
|
|
20871
20920
|
position: relative;
|
|
@@ -20874,7 +20923,7 @@ var SwitchInputContainer = import_react129.css`
|
|
|
20874
20923
|
vertical-align: middle;
|
|
20875
20924
|
user-select: none;
|
|
20876
20925
|
`;
|
|
20877
|
-
var SwitchInput =
|
|
20926
|
+
var SwitchInput = import_react131.css`
|
|
20878
20927
|
appearance: none;
|
|
20879
20928
|
border-radius: var(--rounded-full);
|
|
20880
20929
|
background-color: var(--white);
|
|
@@ -20912,7 +20961,7 @@ var SwitchInput = import_react129.css`
|
|
|
20912
20961
|
cursor: not-allowed;
|
|
20913
20962
|
}
|
|
20914
20963
|
`;
|
|
20915
|
-
var SwitchInputDisabled =
|
|
20964
|
+
var SwitchInputDisabled = import_react131.css`
|
|
20916
20965
|
opacity: var(--opacity-50);
|
|
20917
20966
|
cursor: not-allowed;
|
|
20918
20967
|
|
|
@@ -20920,7 +20969,7 @@ var SwitchInputDisabled = import_react129.css`
|
|
|
20920
20969
|
cursor: not-allowed;
|
|
20921
20970
|
}
|
|
20922
20971
|
`;
|
|
20923
|
-
var SwitchInputLabel =
|
|
20972
|
+
var SwitchInputLabel = import_react131.css`
|
|
20924
20973
|
align-items: center;
|
|
20925
20974
|
color: var(--brand-secondary-1);
|
|
20926
20975
|
display: inline-flex;
|
|
@@ -20942,7 +20991,7 @@ var SwitchInputLabel = import_react129.css`
|
|
|
20942
20991
|
top: 0;
|
|
20943
20992
|
}
|
|
20944
20993
|
`;
|
|
20945
|
-
var SwitchText =
|
|
20994
|
+
var SwitchText = import_react131.css`
|
|
20946
20995
|
color: var(--gray-500);
|
|
20947
20996
|
font-size: var(--fs-sm);
|
|
20948
20997
|
padding-inline: var(--spacing-2xl) 0;
|
|
@@ -20973,8 +21022,8 @@ var React24 = __toESM(require("react"));
|
|
|
20973
21022
|
|
|
20974
21023
|
// src/components/Table/Table.styles.ts
|
|
20975
21024
|
init_emotion_jsx_shim();
|
|
20976
|
-
var
|
|
20977
|
-
var table = ({ cellPadding = "var(--spacing-base) var(--spacing-md)" }) =>
|
|
21025
|
+
var import_react132 = require("@emotion/react");
|
|
21026
|
+
var table = ({ cellPadding = "var(--spacing-base) var(--spacing-md)" }) => import_react132.css`
|
|
20978
21027
|
border-bottom: 1px solid var(--gray-400);
|
|
20979
21028
|
border-collapse: collapse;
|
|
20980
21029
|
min-width: 100%;
|
|
@@ -20985,15 +21034,15 @@ var table = ({ cellPadding = "var(--spacing-base) var(--spacing-md)" }) => impor
|
|
|
20985
21034
|
padding: ${cellPadding};
|
|
20986
21035
|
}
|
|
20987
21036
|
`;
|
|
20988
|
-
var tableHead =
|
|
21037
|
+
var tableHead = import_react132.css`
|
|
20989
21038
|
background: var(--gray-100);
|
|
20990
21039
|
color: var(--brand-secondary-1);
|
|
20991
21040
|
text-align: left;
|
|
20992
21041
|
`;
|
|
20993
|
-
var tableRow =
|
|
21042
|
+
var tableRow = import_react132.css`
|
|
20994
21043
|
border-bottom: 1px solid var(--gray-200);
|
|
20995
21044
|
`;
|
|
20996
|
-
var tableCellHead =
|
|
21045
|
+
var tableCellHead = import_react132.css`
|
|
20997
21046
|
font-size: var(--fs-sm);
|
|
20998
21047
|
text-transform: uppercase;
|
|
20999
21048
|
font-weight: var(--fw-bold);
|
|
@@ -21039,13 +21088,13 @@ var TableCellData = React24.forwardRef(
|
|
|
21039
21088
|
|
|
21040
21089
|
// src/components/Tabs/Tabs.tsx
|
|
21041
21090
|
init_emotion_jsx_shim();
|
|
21042
|
-
var
|
|
21091
|
+
var import_react134 = require("react");
|
|
21043
21092
|
var import_Tab = require("reakit/Tab");
|
|
21044
21093
|
|
|
21045
21094
|
// src/components/Tabs/Tabs.styles.ts
|
|
21046
21095
|
init_emotion_jsx_shim();
|
|
21047
|
-
var
|
|
21048
|
-
var tabButtonStyles =
|
|
21096
|
+
var import_react133 = require("@emotion/react");
|
|
21097
|
+
var tabButtonStyles = import_react133.css`
|
|
21049
21098
|
align-items: center;
|
|
21050
21099
|
border: 0;
|
|
21051
21100
|
height: 2.5rem;
|
|
@@ -21062,7 +21111,7 @@ var tabButtonStyles = import_react131.css`
|
|
|
21062
21111
|
box-shadow: inset 0 -2px 0 var(--brand-secondary-3);
|
|
21063
21112
|
}
|
|
21064
21113
|
`;
|
|
21065
|
-
var tabButtonGroupStyles =
|
|
21114
|
+
var tabButtonGroupStyles = import_react133.css`
|
|
21066
21115
|
display: flex;
|
|
21067
21116
|
gap: var(--spacing-base);
|
|
21068
21117
|
border-bottom: 1px solid var(--gray-300);
|
|
@@ -21070,22 +21119,22 @@ var tabButtonGroupStyles = import_react131.css`
|
|
|
21070
21119
|
|
|
21071
21120
|
// src/components/Tabs/Tabs.tsx
|
|
21072
21121
|
var import_jsx_runtime114 = require("@emotion/react/jsx-runtime");
|
|
21073
|
-
var CurrentTabContext = (0,
|
|
21122
|
+
var CurrentTabContext = (0, import_react134.createContext)(null);
|
|
21074
21123
|
var useCurrentTab = () => {
|
|
21075
|
-
const context = (0,
|
|
21124
|
+
const context = (0, import_react134.useContext)(CurrentTabContext);
|
|
21076
21125
|
if (!context) {
|
|
21077
21126
|
throw new Error("This component can only be used inside <Tabs>");
|
|
21078
21127
|
}
|
|
21079
21128
|
return context;
|
|
21080
21129
|
};
|
|
21081
21130
|
var Tabs = ({ children, onSelectedIdChange, useHashForState, selectedId, ...props }) => {
|
|
21082
|
-
const selected = (0,
|
|
21131
|
+
const selected = (0, import_react134.useMemo)(() => {
|
|
21083
21132
|
if (selectedId)
|
|
21084
21133
|
return selectedId;
|
|
21085
21134
|
return useHashForState && typeof window !== "undefined" && window.location.hash ? window.location.hash.substring(1) : void 0;
|
|
21086
21135
|
}, [selectedId, useHashForState]);
|
|
21087
21136
|
const tab = (0, import_Tab.useTabState)({ ...props, selectedId: selected });
|
|
21088
|
-
(0,
|
|
21137
|
+
(0, import_react134.useEffect)(() => {
|
|
21089
21138
|
var _a;
|
|
21090
21139
|
const selectedValueWithoutNull = (_a = tab.selectedId) != null ? _a : void 0;
|
|
21091
21140
|
onSelectedIdChange == null ? void 0 : onSelectedIdChange(selectedValueWithoutNull);
|
|
@@ -21093,7 +21142,7 @@ var Tabs = ({ children, onSelectedIdChange, useHashForState, selectedId, ...prop
|
|
|
21093
21142
|
window.location.hash = selectedValueWithoutNull != null ? selectedValueWithoutNull : "";
|
|
21094
21143
|
}
|
|
21095
21144
|
}, [tab.selectedId, onSelectedIdChange, useHashForState]);
|
|
21096
|
-
(0,
|
|
21145
|
+
(0, import_react134.useEffect)(() => {
|
|
21097
21146
|
if (selected && selected !== tab.selectedId) {
|
|
21098
21147
|
tab.setSelectedId(selected);
|
|
21099
21148
|
}
|
|
@@ -21118,8 +21167,8 @@ init_emotion_jsx_shim();
|
|
|
21118
21167
|
|
|
21119
21168
|
// src/components/Validation/StatusBullet.styles.ts
|
|
21120
21169
|
init_emotion_jsx_shim();
|
|
21121
|
-
var
|
|
21122
|
-
var StatusBulletContainer =
|
|
21170
|
+
var import_react135 = require("@emotion/react");
|
|
21171
|
+
var StatusBulletContainer = import_react135.css`
|
|
21123
21172
|
align-items: center;
|
|
21124
21173
|
align-self: center;
|
|
21125
21174
|
color: var(--gray-500);
|
|
@@ -21136,33 +21185,33 @@ var StatusBulletContainer = import_react133.css`
|
|
|
21136
21185
|
display: block;
|
|
21137
21186
|
}
|
|
21138
21187
|
`;
|
|
21139
|
-
var StatusBulletBase =
|
|
21188
|
+
var StatusBulletBase = import_react135.css`
|
|
21140
21189
|
font-size: var(--fs-sm);
|
|
21141
21190
|
&:before {
|
|
21142
21191
|
width: var(--fs-xs);
|
|
21143
21192
|
height: var(--fs-xs);
|
|
21144
21193
|
}
|
|
21145
21194
|
`;
|
|
21146
|
-
var StatusBulletSmall =
|
|
21195
|
+
var StatusBulletSmall = import_react135.css`
|
|
21147
21196
|
font-size: var(--fs-xs);
|
|
21148
21197
|
&:before {
|
|
21149
21198
|
width: var(--fs-xxs);
|
|
21150
21199
|
height: var(--fs-xxs);
|
|
21151
21200
|
}
|
|
21152
21201
|
`;
|
|
21153
|
-
var StatusDraft =
|
|
21202
|
+
var StatusDraft = import_react135.css`
|
|
21154
21203
|
&:before {
|
|
21155
21204
|
background: var(--white);
|
|
21156
21205
|
box-shadow: inset 0 0 0 0.125rem var(--primary-action-default);
|
|
21157
21206
|
}
|
|
21158
21207
|
`;
|
|
21159
|
-
var StatusModified =
|
|
21208
|
+
var StatusModified = import_react135.css`
|
|
21160
21209
|
&:before {
|
|
21161
21210
|
background: linear-gradient(to right, var(--white) 50%, var(--primary-action-default) 50% 100%);
|
|
21162
21211
|
box-shadow: inset 0 0 0 0.125rem var(--primary-action-default);
|
|
21163
21212
|
}
|
|
21164
21213
|
`;
|
|
21165
|
-
var StatusError =
|
|
21214
|
+
var StatusError = import_react135.css`
|
|
21166
21215
|
color: var(--error);
|
|
21167
21216
|
&:before {
|
|
21168
21217
|
/* TODO: replace this with an svg icon */
|
|
@@ -21175,12 +21224,12 @@ var StatusError = import_react133.css`
|
|
|
21175
21224
|
);
|
|
21176
21225
|
}
|
|
21177
21226
|
`;
|
|
21178
|
-
var StatusPublished =
|
|
21227
|
+
var StatusPublished = import_react135.css`
|
|
21179
21228
|
&:before {
|
|
21180
21229
|
background: var(--primary-action-default);
|
|
21181
21230
|
}
|
|
21182
21231
|
`;
|
|
21183
|
-
var StatusOrphan =
|
|
21232
|
+
var StatusOrphan = import_react135.css`
|
|
21184
21233
|
&:before {
|
|
21185
21234
|
background: var(--brand-secondary-5);
|
|
21186
21235
|
}
|