@uniformdev/design-system 19.67.0 → 19.68.1-alpha.27
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 +761 -567
- package/dist/index.d.mts +30 -8
- package/dist/index.d.ts +30 -8
- package/dist/index.js +1084 -884
- package/package.json +6 -5
package/dist/esm/index.js
CHANGED
|
@@ -1887,9 +1887,9 @@ var AddListButtonBtnSmall = css9`
|
|
|
1887
1887
|
font-weight: var(--fw-regular);
|
|
1888
1888
|
margin-block: var(--spacing-md) 0;
|
|
1889
1889
|
`;
|
|
1890
|
-
var AddListButtonIconMathPlus = (
|
|
1890
|
+
var AddListButtonIconMathPlus = (disabled2, theme) => css9`
|
|
1891
1891
|
box-sizing: border-box;
|
|
1892
|
-
background: ${
|
|
1892
|
+
background: ${disabled2 ? "var(--gray-300)" : theme};
|
|
1893
1893
|
color: var(--white);
|
|
1894
1894
|
padding: calc(var(--spacing-xs) - 0.15rem);
|
|
1895
1895
|
`;
|
|
@@ -1903,7 +1903,7 @@ import { jsx as jsx8, jsxs as jsxs3 } from "@emotion/react/jsx-runtime";
|
|
|
1903
1903
|
var AddListButton = ({
|
|
1904
1904
|
buttonText = "Add Item",
|
|
1905
1905
|
onButtonClick,
|
|
1906
|
-
disabled,
|
|
1906
|
+
disabled: disabled2,
|
|
1907
1907
|
icon = "math-plus",
|
|
1908
1908
|
variant = "regular",
|
|
1909
1909
|
theme = "var(--primary-action-default)",
|
|
@@ -1925,7 +1925,7 @@ var AddListButton = ({
|
|
|
1925
1925
|
css: [variantStylesMap[variant], AddListButtonTheme(theme)],
|
|
1926
1926
|
onClick: onButtonClick,
|
|
1927
1927
|
title: buttonText,
|
|
1928
|
-
disabled,
|
|
1928
|
+
disabled: disabled2,
|
|
1929
1929
|
...buttonProps,
|
|
1930
1930
|
children: [
|
|
1931
1931
|
icon === "math-plus" ? /* @__PURE__ */ jsx8(
|
|
@@ -1934,7 +1934,7 @@ var AddListButton = ({
|
|
|
1934
1934
|
icon: mapIcon[icon],
|
|
1935
1935
|
iconColor: "currentColor",
|
|
1936
1936
|
size: "1.25em",
|
|
1937
|
-
css: [AddListButtonIcon, AddListButtonIconMathPlus(
|
|
1937
|
+
css: [AddListButtonIcon, AddListButtonIconMathPlus(disabled2, theme)]
|
|
1938
1938
|
}
|
|
1939
1939
|
) : /* @__PURE__ */ jsx8(Icon, { icon: mapIcon[icon], iconColor: "currentColor", size: "1.25em", css: AddListButtonIcon }),
|
|
1940
1940
|
buttonText
|
|
@@ -1980,12 +1980,13 @@ var commonLineHeight = css10`
|
|
|
1980
1980
|
import { jsx as jsx9 } from "@emotion/react/jsx-runtime";
|
|
1981
1981
|
var Heading = ({
|
|
1982
1982
|
level = 2,
|
|
1983
|
+
as,
|
|
1983
1984
|
asSpan,
|
|
1984
1985
|
withMarginBottom = true,
|
|
1985
1986
|
children,
|
|
1986
1987
|
...hAttributes
|
|
1987
1988
|
}) => {
|
|
1988
|
-
const Heading2 = asSpan ? "span" : `h${level}`;
|
|
1989
|
+
const Heading2 = (as != null ? as : asSpan) ? "span" : `h${level}`;
|
|
1989
1990
|
const headingStyle = {
|
|
1990
1991
|
1: h1,
|
|
1991
1992
|
2: h2,
|
|
@@ -1998,6 +1999,7 @@ var Heading = ({
|
|
|
1998
1999
|
Heading2,
|
|
1999
2000
|
{
|
|
2000
2001
|
...hAttributes,
|
|
2002
|
+
role: typeof as === "string" && /^h/.test(as) ? "heading" : void 0,
|
|
2001
2003
|
css: [headingStyle[level], commonHeadingAttr(withMarginBottom), commonLineHeight],
|
|
2002
2004
|
children
|
|
2003
2005
|
}
|
|
@@ -11742,7 +11744,7 @@ import * as React9 from "react";
|
|
|
11742
11744
|
import { MenuItem as BaseMenuItem } from "reakit";
|
|
11743
11745
|
import { jsx as jsx27, jsxs as jsxs16 } from "@emotion/react/jsx-runtime";
|
|
11744
11746
|
var MenuItem = React9.forwardRef(
|
|
11745
|
-
({ children, className, hideMenuOnClick = true, icon, textColor = "base", active, ...props }, ref) => {
|
|
11747
|
+
({ children, className, hideMenuOnClick = true, icon, textColor = "base", active: active2, ...props }, ref) => {
|
|
11746
11748
|
const menuState = useMenuContext();
|
|
11747
11749
|
const resolveProps = (originalProps) => {
|
|
11748
11750
|
const resolvedProps2 = { ...originalProps };
|
|
@@ -11766,7 +11768,7 @@ var MenuItem = React9.forwardRef(
|
|
|
11766
11768
|
"data-testid": "button-menu",
|
|
11767
11769
|
...menuState,
|
|
11768
11770
|
...resolvedProps,
|
|
11769
|
-
css: [menuItem(textColor,
|
|
11771
|
+
css: [menuItem(textColor, active2), typeof className === "object" ? className : void 0],
|
|
11770
11772
|
className: typeof className === "string" ? className : void 0,
|
|
11771
11773
|
children: icon ? renderWithIcon(resolvedChildren, icon) : resolvedChildren
|
|
11772
11774
|
}
|
|
@@ -11945,7 +11947,7 @@ var ButtonWithMenu = ({
|
|
|
11945
11947
|
buttonType = "secondary",
|
|
11946
11948
|
buttonText,
|
|
11947
11949
|
icon,
|
|
11948
|
-
disabled,
|
|
11950
|
+
disabled: disabled2,
|
|
11949
11951
|
children,
|
|
11950
11952
|
placement,
|
|
11951
11953
|
size = "lg",
|
|
@@ -11981,7 +11983,7 @@ var ButtonWithMenu = ({
|
|
|
11981
11983
|
css: [
|
|
11982
11984
|
sizes2[size],
|
|
11983
11985
|
ButtonWithMenuContainer,
|
|
11984
|
-
|
|
11986
|
+
disabled2 ? buttonDisabledTheme[buttonType] : buttonTheme[buttonType]
|
|
11985
11987
|
],
|
|
11986
11988
|
"data-testid": "multioptions-button",
|
|
11987
11989
|
children: onButtonClick ? /* @__PURE__ */ jsxs17(Fragment6, { children: [
|
|
@@ -11990,7 +11992,7 @@ var ButtonWithMenu = ({
|
|
|
11990
11992
|
{
|
|
11991
11993
|
type: "button",
|
|
11992
11994
|
css: ButtonWithMenuBtn,
|
|
11993
|
-
disabled,
|
|
11995
|
+
disabled: disabled2,
|
|
11994
11996
|
onClick: onButtonClick,
|
|
11995
11997
|
"data-testid": "multioptions-button-main",
|
|
11996
11998
|
...buttonProps,
|
|
@@ -12000,8 +12002,8 @@ var ButtonWithMenu = ({
|
|
|
12000
12002
|
]
|
|
12001
12003
|
}
|
|
12002
12004
|
),
|
|
12003
|
-
|
|
12004
|
-
] }) : /* @__PURE__ */ jsx28(Fragment6, { children:
|
|
12005
|
+
disabled2 ? clickableButton : /* @__PURE__ */ jsx28(Menu, { menuLabel: "buttonMenu", placement, menuTrigger: clickableButton, children })
|
|
12006
|
+
] }) : /* @__PURE__ */ jsx28(Fragment6, { children: disabled2 ? dropdownButton : /* @__PURE__ */ jsx28(Menu, { menuLabel: "buttonMenu", placement, menuTrigger: dropdownButton, children }) })
|
|
12005
12007
|
}
|
|
12006
12008
|
);
|
|
12007
12009
|
};
|
|
@@ -12361,7 +12363,7 @@ var Card = ({
|
|
|
12361
12363
|
menuItems,
|
|
12362
12364
|
children,
|
|
12363
12365
|
titleWithMarginBottom = true,
|
|
12364
|
-
disabled,
|
|
12366
|
+
disabled: disabled2,
|
|
12365
12367
|
tag: Tag = "div",
|
|
12366
12368
|
menuButtonTestId,
|
|
12367
12369
|
...props
|
|
@@ -12377,7 +12379,7 @@ var Card = ({
|
|
|
12377
12379
|
{
|
|
12378
12380
|
"aria-label": "More options",
|
|
12379
12381
|
type: "button",
|
|
12380
|
-
disabled,
|
|
12382
|
+
disabled: disabled2,
|
|
12381
12383
|
css: CardMenu,
|
|
12382
12384
|
"data-testid": menuButtonTestId != null ? menuButtonTestId : "list-card-menu",
|
|
12383
12385
|
children: /* @__PURE__ */ jsx31(Icon, { icon: CgMoreAlt, iconColor: "currentColor", size: 32 })
|
|
@@ -13021,15 +13023,24 @@ import React10 from "react";
|
|
|
13021
13023
|
|
|
13022
13024
|
// src/components/DescriptionList/DescriptionList.styles.ts
|
|
13023
13025
|
import { css as css40 } from "@emotion/react";
|
|
13024
|
-
var
|
|
13026
|
+
var descriptionListHorizontal = css40`
|
|
13025
13027
|
display: grid;
|
|
13026
13028
|
grid-template-columns: max-content auto;
|
|
13027
13029
|
gap: var(--spacing-xs) var(--spacing-md);
|
|
13028
13030
|
`;
|
|
13031
|
+
var descriptionListVertical = css40`
|
|
13032
|
+
display: flex;
|
|
13033
|
+
flex-direction: column;
|
|
13034
|
+
gap: var(--spacing-xs);
|
|
13035
|
+
`;
|
|
13029
13036
|
var descriptionListLabelStyles = css40`
|
|
13030
13037
|
display: flex;
|
|
13031
13038
|
align-items: center;
|
|
13032
13039
|
color: var(--gray-500);
|
|
13040
|
+
|
|
13041
|
+
dd + & {
|
|
13042
|
+
margin-top: var(--spacing-sm);
|
|
13043
|
+
}
|
|
13033
13044
|
`;
|
|
13034
13045
|
var descriptionListValueStyles = css40`
|
|
13035
13046
|
display: flex;
|
|
@@ -13040,14 +13051,22 @@ var descriptionListValueStyles = css40`
|
|
|
13040
13051
|
// src/components/DescriptionList/DescriptionList.tsx
|
|
13041
13052
|
import { jsx as jsx41, jsxs as jsxs24 } from "@emotion/react/jsx-runtime";
|
|
13042
13053
|
var DescriptionList = React10.forwardRef(
|
|
13043
|
-
({ items, ...listProps }, ref) => {
|
|
13054
|
+
({ items, variant = "horizontal", ...listProps }, ref) => {
|
|
13044
13055
|
if (!(items == null ? void 0 : items.length)) {
|
|
13045
13056
|
return null;
|
|
13046
13057
|
}
|
|
13047
|
-
return /* @__PURE__ */ jsx41(
|
|
13048
|
-
|
|
13049
|
-
|
|
13050
|
-
|
|
13058
|
+
return /* @__PURE__ */ jsx41(
|
|
13059
|
+
"dl",
|
|
13060
|
+
{
|
|
13061
|
+
ref,
|
|
13062
|
+
css: variant === "vertical" ? descriptionListVertical : descriptionListHorizontal,
|
|
13063
|
+
...listProps,
|
|
13064
|
+
children: items == null ? void 0 : items.map(({ label, value }) => /* @__PURE__ */ jsxs24(React10.Fragment, { children: [
|
|
13065
|
+
/* @__PURE__ */ jsx41("dt", { css: descriptionListLabelStyles, children: label }),
|
|
13066
|
+
/* @__PURE__ */ jsx41("dd", { css: descriptionListValueStyles, children: typeof value === "boolean" ? /* @__PURE__ */ jsx41(DescriptionListValueBoolean, { value }) : value })
|
|
13067
|
+
] }, label))
|
|
13068
|
+
}
|
|
13069
|
+
);
|
|
13051
13070
|
}
|
|
13052
13071
|
);
|
|
13053
13072
|
DescriptionList.displayName = "DescriptionList";
|
|
@@ -13262,6 +13281,10 @@ var DrawerContext = createContext3({
|
|
|
13262
13281
|
registerDrawer: () => {
|
|
13263
13282
|
},
|
|
13264
13283
|
unregisterDrawer: () => {
|
|
13284
|
+
},
|
|
13285
|
+
registerTakeoverStackId: () => {
|
|
13286
|
+
},
|
|
13287
|
+
unregisterTakeoverStackId: () => {
|
|
13265
13288
|
}
|
|
13266
13289
|
});
|
|
13267
13290
|
function renderDrawerId(drawer) {
|
|
@@ -13270,6 +13293,7 @@ function renderDrawerId(drawer) {
|
|
|
13270
13293
|
var DrawerProvider = ({ children }) => {
|
|
13271
13294
|
const [drawersRegistry, setDrawersRegistry] = useState5([]);
|
|
13272
13295
|
const providerId = useRef2(crypto.randomUUID());
|
|
13296
|
+
const [drawerTakeoverStackId, setDrawerTakeoverStackId] = useState5(void 0);
|
|
13273
13297
|
useShortcut({
|
|
13274
13298
|
handler: () => {
|
|
13275
13299
|
var _a, _b;
|
|
@@ -13327,6 +13351,22 @@ var DrawerProvider = ({ children }) => {
|
|
|
13327
13351
|
},
|
|
13328
13352
|
[setDrawersRegistry]
|
|
13329
13353
|
);
|
|
13354
|
+
const registerTakeoverStackId = useCallback(
|
|
13355
|
+
(stackId) => {
|
|
13356
|
+
if (drawerTakeoverStackId !== stackId) {
|
|
13357
|
+
setDrawerTakeoverStackId(stackId);
|
|
13358
|
+
}
|
|
13359
|
+
},
|
|
13360
|
+
[drawerTakeoverStackId]
|
|
13361
|
+
);
|
|
13362
|
+
const unregisterTakeoverStackId = useCallback(
|
|
13363
|
+
(stackId) => {
|
|
13364
|
+
if (drawerTakeoverStackId === stackId) {
|
|
13365
|
+
setDrawerTakeoverStackId(void 0);
|
|
13366
|
+
}
|
|
13367
|
+
},
|
|
13368
|
+
[drawerTakeoverStackId]
|
|
13369
|
+
);
|
|
13330
13370
|
return /* @__PURE__ */ jsx43(
|
|
13331
13371
|
DrawerContext.Provider,
|
|
13332
13372
|
{
|
|
@@ -13334,7 +13374,10 @@ var DrawerProvider = ({ children }) => {
|
|
|
13334
13374
|
drawersRegistry,
|
|
13335
13375
|
registerDrawer,
|
|
13336
13376
|
unregisterDrawer,
|
|
13337
|
-
providerId: providerId.current
|
|
13377
|
+
providerId: providerId.current,
|
|
13378
|
+
drawerTakeoverStackId,
|
|
13379
|
+
registerTakeoverStackId,
|
|
13380
|
+
unregisterTakeoverStackId
|
|
13338
13381
|
},
|
|
13339
13382
|
children
|
|
13340
13383
|
}
|
|
@@ -13367,8 +13410,9 @@ var useCurrentDrawer = () => {
|
|
|
13367
13410
|
var Drawer = React13.forwardRef(
|
|
13368
13411
|
({ minWidth, maxWidth, position, leftAligned, ...drawerProps }, ref) => {
|
|
13369
13412
|
const { stackId: inheritedStackId } = useCurrentDrawer();
|
|
13413
|
+
const { drawerTakeoverStackId } = useDrawer();
|
|
13370
13414
|
const drawerRendererProps = { width: drawerProps.width, minWidth, maxWidth, position, leftAligned };
|
|
13371
|
-
return drawerProps.stackId ? /* @__PURE__ */ jsx44(DrawerInner, { ref, ...drawerProps }) : inheritedStackId ? /* @__PURE__ */ jsx44(DrawerInner, { ref, ...drawerProps, stackId: inheritedStackId }) : /* @__PURE__ */ jsxs26(DrawerProvider, { children: [
|
|
13415
|
+
return drawerTakeoverStackId ? /* @__PURE__ */ jsx44(DrawerInner, { ref, ...drawerProps, stackId: drawerTakeoverStackId }) : drawerProps.stackId ? /* @__PURE__ */ jsx44(DrawerInner, { ref, ...drawerProps }) : inheritedStackId ? /* @__PURE__ */ jsx44(DrawerInner, { ref, ...drawerProps, stackId: inheritedStackId }) : /* @__PURE__ */ jsxs26(DrawerProvider, { children: [
|
|
13372
13416
|
/* @__PURE__ */ jsx44(DrawerInner, { ref, ...drawerProps }),
|
|
13373
13417
|
/* @__PURE__ */ jsx44(DrawerRenderer, { stackId: defaultSackId, ...drawerRendererProps })
|
|
13374
13418
|
] });
|
|
@@ -13607,6 +13651,21 @@ var getDrawerAttributes = ({
|
|
|
13607
13651
|
return { "data-drawer-id": `${providerId}-${stackId}-${id}`, "data-testid": "container-drawer" };
|
|
13608
13652
|
};
|
|
13609
13653
|
|
|
13654
|
+
// src/components/Drawer/TakeoverDrawerRenderer.tsx
|
|
13655
|
+
import { useEffect as useEffect7 } from "react";
|
|
13656
|
+
import { jsx as jsx47 } from "@emotion/react/jsx-runtime";
|
|
13657
|
+
var TAKEOVER_STACK_ID = "takeover-stack";
|
|
13658
|
+
var TakeoverDrawerRenderer = (props) => {
|
|
13659
|
+
const { registerTakeoverStackId, unregisterTakeoverStackId } = useDrawer();
|
|
13660
|
+
useEffect7(() => {
|
|
13661
|
+
registerTakeoverStackId(TAKEOVER_STACK_ID);
|
|
13662
|
+
return () => {
|
|
13663
|
+
unregisterTakeoverStackId(TAKEOVER_STACK_ID);
|
|
13664
|
+
};
|
|
13665
|
+
}, [registerTakeoverStackId, unregisterTakeoverStackId]);
|
|
13666
|
+
return /* @__PURE__ */ jsx47(DrawerRenderer, { ...props, stackId: TAKEOVER_STACK_ID });
|
|
13667
|
+
};
|
|
13668
|
+
|
|
13610
13669
|
// src/components/IconButton/IconButton.tsx
|
|
13611
13670
|
import { forwardRef as forwardRef4 } from "react";
|
|
13612
13671
|
|
|
@@ -13638,16 +13697,16 @@ var variants = {
|
|
|
13638
13697
|
};
|
|
13639
13698
|
|
|
13640
13699
|
// src/components/IconButton/IconButton.tsx
|
|
13641
|
-
import { jsx as
|
|
13700
|
+
import { jsx as jsx48 } from "@emotion/react/jsx-runtime";
|
|
13642
13701
|
var IconButton = forwardRef4(
|
|
13643
13702
|
({ children, size = "md", variant = "square", ...props }, ref) => {
|
|
13644
|
-
return /* @__PURE__ */
|
|
13703
|
+
return /* @__PURE__ */ jsx48(Button, { ref, css: [iconButton, variants[variant], sizes[size]], ...props, children });
|
|
13645
13704
|
}
|
|
13646
13705
|
);
|
|
13647
13706
|
IconButton.displayName = "IconButton";
|
|
13648
13707
|
|
|
13649
13708
|
// src/components/Image/Image.tsx
|
|
13650
|
-
import { useCallback as useCallback2, useEffect as
|
|
13709
|
+
import { useCallback as useCallback2, useEffect as useEffect8, useState as useState8 } from "react";
|
|
13651
13710
|
|
|
13652
13711
|
// src/components/Input/styles/CaptionText.styles.ts
|
|
13653
13712
|
import { css as css45 } from "@emotion/react";
|
|
@@ -13660,9 +13719,9 @@ var CaptionText = (dynamicSize) => css45`
|
|
|
13660
13719
|
`;
|
|
13661
13720
|
|
|
13662
13721
|
// src/components/Input/Caption.tsx
|
|
13663
|
-
import { jsx as
|
|
13722
|
+
import { jsx as jsx49 } from "@emotion/react/jsx-runtime";
|
|
13664
13723
|
var Caption = ({ children, testId, dynamicSize = false, ...props }) => {
|
|
13665
|
-
return /* @__PURE__ */
|
|
13724
|
+
return /* @__PURE__ */ jsx49("small", { css: CaptionText(dynamicSize), "data-testid": testId, ...props, children });
|
|
13666
13725
|
};
|
|
13667
13726
|
|
|
13668
13727
|
// src/components/Input/CheckboxWithInfo.tsx
|
|
@@ -13741,21 +13800,21 @@ var InfoDialogMessage = css46`
|
|
|
13741
13800
|
`;
|
|
13742
13801
|
|
|
13743
13802
|
// src/components/Input/CheckboxWithInfo.tsx
|
|
13744
|
-
import { jsx as
|
|
13803
|
+
import { jsx as jsx50, jsxs as jsxs29 } from "@emotion/react/jsx-runtime";
|
|
13745
13804
|
var InfoDialog = ({ message }) => {
|
|
13746
13805
|
return /* @__PURE__ */ jsxs29("div", { "data-testid": "info-dialog", css: InfoDialogContainer, children: [
|
|
13747
|
-
/* @__PURE__ */
|
|
13748
|
-
/* @__PURE__ */
|
|
13806
|
+
/* @__PURE__ */ jsx50(Icon, { icon: "info", iconColor: "action", size: "0.9rem" }),
|
|
13807
|
+
/* @__PURE__ */ jsx50("div", { role: "paragraph", css: InfoDialogMessage, className: "info-message", children: message })
|
|
13749
13808
|
] });
|
|
13750
13809
|
};
|
|
13751
13810
|
var CheckboxWithInfo = forwardRef5(
|
|
13752
13811
|
({ label, name, info, ...props }, ref) => {
|
|
13753
13812
|
return /* @__PURE__ */ jsxs29("div", { css: CheckboxWithInfoContainer, children: [
|
|
13754
13813
|
/* @__PURE__ */ jsxs29("label", { css: CheckboxWithInfoLabel, children: [
|
|
13755
|
-
/* @__PURE__ */
|
|
13756
|
-
/* @__PURE__ */
|
|
13814
|
+
/* @__PURE__ */ jsx50("input", { type: "checkbox", name, ref, css: CheckboxWithInfoInput, ...props }),
|
|
13815
|
+
/* @__PURE__ */ jsx50("span", { children: label })
|
|
13757
13816
|
] }),
|
|
13758
|
-
info ? /* @__PURE__ */
|
|
13817
|
+
info ? /* @__PURE__ */ jsx50(InfoDialog, { message: info }) : null
|
|
13759
13818
|
] });
|
|
13760
13819
|
}
|
|
13761
13820
|
);
|
|
@@ -13773,10 +13832,10 @@ var ErrorText = css47`
|
|
|
13773
13832
|
`;
|
|
13774
13833
|
|
|
13775
13834
|
// src/components/Input/ErrorMessage.tsx
|
|
13776
|
-
import { jsx as
|
|
13835
|
+
import { jsx as jsx51, jsxs as jsxs30 } from "@emotion/react/jsx-runtime";
|
|
13777
13836
|
var ErrorMessage = ({ message, testId, ...otherProps }) => {
|
|
13778
13837
|
return message ? /* @__PURE__ */ jsxs30("span", { role: "alert", css: ErrorText, "data-testid": testId, ...otherProps, children: [
|
|
13779
|
-
/* @__PURE__ */
|
|
13838
|
+
/* @__PURE__ */ jsx51("span", { children: /* @__PURE__ */ jsx51(Icon, { icon: MdWarning, size: "1rem", iconColor: "currentColor" }) }),
|
|
13780
13839
|
message
|
|
13781
13840
|
] }) : null;
|
|
13782
13841
|
};
|
|
@@ -13825,12 +13884,12 @@ var fieldsetBody = css48`
|
|
|
13825
13884
|
`;
|
|
13826
13885
|
|
|
13827
13886
|
// src/components/Input/Fieldset.tsx
|
|
13828
|
-
import { jsx as
|
|
13887
|
+
import { jsx as jsx52, jsxs as jsxs31 } from "@emotion/react/jsx-runtime";
|
|
13829
13888
|
var Fieldset = React15.forwardRef(
|
|
13830
|
-
({ legend, disabled, children, invert, ...props }, ref) => {
|
|
13831
|
-
return /* @__PURE__ */ jsxs31("fieldset", { css: fieldsetContainer(Boolean(invert)), ref, disabled, ...props, children: [
|
|
13889
|
+
({ legend, disabled: disabled2, children, invert, ...props }, ref) => {
|
|
13890
|
+
return /* @__PURE__ */ jsxs31("fieldset", { css: fieldsetContainer(Boolean(invert)), ref, disabled: disabled2, ...props, children: [
|
|
13832
13891
|
legend,
|
|
13833
|
-
/* @__PURE__ */
|
|
13892
|
+
/* @__PURE__ */ jsx52("div", { css: fieldsetBody, children })
|
|
13834
13893
|
] });
|
|
13835
13894
|
}
|
|
13836
13895
|
);
|
|
@@ -13854,10 +13913,10 @@ var InfoIcon2 = css49`
|
|
|
13854
13913
|
`;
|
|
13855
13914
|
|
|
13856
13915
|
// src/components/Input/InfoMessage.tsx
|
|
13857
|
-
import { jsx as
|
|
13916
|
+
import { jsx as jsx53, jsxs as jsxs32 } from "@emotion/react/jsx-runtime";
|
|
13858
13917
|
var InfoMessage = ({ message, testId, ...props }) => {
|
|
13859
13918
|
return message ? /* @__PURE__ */ jsxs32("span", { role: "status", css: InfoText, "data-testid": testId, ...props, children: [
|
|
13860
|
-
/* @__PURE__ */
|
|
13919
|
+
/* @__PURE__ */ jsx53("span", { children: /* @__PURE__ */ jsx53(Icon, { css: InfoIcon2, icon: MdInfoOutline, size: "1rem", iconColor: "currentColor" }) }),
|
|
13861
13920
|
message
|
|
13862
13921
|
] }) : null;
|
|
13863
13922
|
};
|
|
@@ -13866,9 +13925,9 @@ var InfoMessage = ({ message, testId, ...props }) => {
|
|
|
13866
13925
|
import * as React16 from "react";
|
|
13867
13926
|
|
|
13868
13927
|
// src/components/Input/Label.tsx
|
|
13869
|
-
import { jsx as
|
|
13928
|
+
import { jsx as jsx54 } from "@emotion/react/jsx-runtime";
|
|
13870
13929
|
var Label = ({ children, className, testId, ...props }) => {
|
|
13871
|
-
return /* @__PURE__ */
|
|
13930
|
+
return /* @__PURE__ */ jsx54(
|
|
13872
13931
|
"label",
|
|
13873
13932
|
{
|
|
13874
13933
|
css: [labelText, typeof className === "object" ? className : void 0],
|
|
@@ -13896,16 +13955,16 @@ var WarningIcon = css50`
|
|
|
13896
13955
|
`;
|
|
13897
13956
|
|
|
13898
13957
|
// src/components/Input/WarningMessage.tsx
|
|
13899
|
-
import { jsx as
|
|
13958
|
+
import { jsx as jsx55, jsxs as jsxs33 } from "@emotion/react/jsx-runtime";
|
|
13900
13959
|
var WarningMessage = ({ message, testId, ...props }) => {
|
|
13901
13960
|
return message ? /* @__PURE__ */ jsxs33("span", { role: "status", css: WarningText, "data-testid": testId, ...props, children: [
|
|
13902
|
-
/* @__PURE__ */
|
|
13961
|
+
/* @__PURE__ */ jsx55("span", { children: /* @__PURE__ */ jsx55(Icon, { css: WarningIcon, icon: MdWarning2, size: "1rem", iconColor: "currentColor" }) }),
|
|
13903
13962
|
message
|
|
13904
13963
|
] }) : null;
|
|
13905
13964
|
};
|
|
13906
13965
|
|
|
13907
13966
|
// src/components/Input/Input.tsx
|
|
13908
|
-
import { jsx as
|
|
13967
|
+
import { jsx as jsx56, jsxs as jsxs34 } from "@emotion/react/jsx-runtime";
|
|
13909
13968
|
var Input = React16.forwardRef(
|
|
13910
13969
|
({
|
|
13911
13970
|
label,
|
|
@@ -13931,7 +13990,7 @@ var Input = React16.forwardRef(
|
|
|
13931
13990
|
css: [inputContainer, typeof classNameRoot === "object" ? classNameRoot : void 0],
|
|
13932
13991
|
"data-testid": containerTestId ? containerTestId : "container-input-field",
|
|
13933
13992
|
children: [
|
|
13934
|
-
showLabel ? /* @__PURE__ */
|
|
13993
|
+
showLabel ? /* @__PURE__ */ jsx56(
|
|
13935
13994
|
Label,
|
|
13936
13995
|
{
|
|
13937
13996
|
htmlFor: id,
|
|
@@ -13947,7 +14006,7 @@ var Input = React16.forwardRef(
|
|
|
13947
14006
|
css: [inputContainer, typeof classNameContainer === "object" ? classNameContainer : void 0],
|
|
13948
14007
|
className: typeof classNameContainer === "string" ? classNameContainer : "",
|
|
13949
14008
|
children: [
|
|
13950
|
-
/* @__PURE__ */
|
|
14009
|
+
/* @__PURE__ */ jsx56(
|
|
13951
14010
|
"input",
|
|
13952
14011
|
{
|
|
13953
14012
|
id,
|
|
@@ -13963,13 +14022,13 @@ var Input = React16.forwardRef(
|
|
|
13963
14022
|
ref
|
|
13964
14023
|
}
|
|
13965
14024
|
),
|
|
13966
|
-
icon ? /* @__PURE__ */
|
|
14025
|
+
icon ? /* @__PURE__ */ jsx56("div", { css: inputIcon, children: icon }) : null
|
|
13967
14026
|
]
|
|
13968
14027
|
}
|
|
13969
14028
|
),
|
|
13970
|
-
caption ? /* @__PURE__ */
|
|
13971
|
-
errorMessage ? /* @__PURE__ */
|
|
13972
|
-
warningMessage && !errorMessage ? /* @__PURE__ */
|
|
14029
|
+
caption ? /* @__PURE__ */ jsx56(Caption, { testId: captionTestId, children: caption }) : null,
|
|
14030
|
+
errorMessage ? /* @__PURE__ */ jsx56(ErrorMessage, { message: errorMessage, testId: errorTestId }) : null,
|
|
14031
|
+
warningMessage && !errorMessage ? /* @__PURE__ */ jsx56(WarningMessage, { message: warningMessage }) : null
|
|
13973
14032
|
]
|
|
13974
14033
|
}
|
|
13975
14034
|
);
|
|
@@ -13978,10 +14037,10 @@ var Input = React16.forwardRef(
|
|
|
13978
14037
|
|
|
13979
14038
|
// src/components/Input/InputComboBox.tsx
|
|
13980
14039
|
import Select from "react-select";
|
|
13981
|
-
import { jsx as
|
|
14040
|
+
import { jsx as jsx57 } from "@emotion/react/jsx-runtime";
|
|
13982
14041
|
function InputComboBox(props) {
|
|
13983
14042
|
var _a;
|
|
13984
|
-
return /* @__PURE__ */
|
|
14043
|
+
return /* @__PURE__ */ jsx57(
|
|
13985
14044
|
Select,
|
|
13986
14045
|
{
|
|
13987
14046
|
...props,
|
|
@@ -14181,13 +14240,13 @@ var inlineSelectMenuClosed = css51`
|
|
|
14181
14240
|
`;
|
|
14182
14241
|
|
|
14183
14242
|
// src/components/Input/InputInlineSelect.tsx
|
|
14184
|
-
import { jsx as
|
|
14243
|
+
import { jsx as jsx58, jsxs as jsxs35 } from "@emotion/react/jsx-runtime";
|
|
14185
14244
|
var InputInlineSelect = ({
|
|
14186
14245
|
classNameContainer,
|
|
14187
14246
|
options,
|
|
14188
14247
|
value,
|
|
14189
14248
|
onChange,
|
|
14190
|
-
disabled,
|
|
14249
|
+
disabled: disabled2,
|
|
14191
14250
|
...props
|
|
14192
14251
|
}) => {
|
|
14193
14252
|
var _a;
|
|
@@ -14213,24 +14272,24 @@ var InputInlineSelect = ({
|
|
|
14213
14272
|
"aria-expanded": menuVisible,
|
|
14214
14273
|
css: inlineSelectBtn,
|
|
14215
14274
|
onClick: () => {
|
|
14216
|
-
if (!
|
|
14275
|
+
if (!disabled2)
|
|
14217
14276
|
setMenuVisible((prev) => !prev);
|
|
14218
14277
|
},
|
|
14219
|
-
disabled,
|
|
14278
|
+
disabled: disabled2,
|
|
14220
14279
|
...props,
|
|
14221
14280
|
children: [
|
|
14222
|
-
/* @__PURE__ */
|
|
14223
|
-
|
|
14281
|
+
/* @__PURE__ */ jsx58("span", { children: (_a = selected == null ? void 0 : selected.label) != null ? _a : value }),
|
|
14282
|
+
disabled2 ? null : /* @__PURE__ */ jsx58(Icon, { icon: CgChevronDown2, iconColor: "currentColor", size: 24 })
|
|
14224
14283
|
]
|
|
14225
14284
|
}
|
|
14226
14285
|
),
|
|
14227
|
-
/* @__PURE__ */
|
|
14286
|
+
/* @__PURE__ */ jsx58(
|
|
14228
14287
|
"div",
|
|
14229
14288
|
{
|
|
14230
14289
|
id: `and-or-${props.id}`,
|
|
14231
14290
|
css: [inlineSelectMenu, menuVisible ? void 0 : inlineSelectMenuClosed],
|
|
14232
14291
|
"aria-hidden": !menuVisible,
|
|
14233
|
-
children: options.map((opt) => /* @__PURE__ */
|
|
14292
|
+
children: options.map((opt) => /* @__PURE__ */ jsx58(
|
|
14234
14293
|
"button",
|
|
14235
14294
|
{
|
|
14236
14295
|
type: "button",
|
|
@@ -14253,10 +14312,10 @@ var InputInlineSelect = ({
|
|
|
14253
14312
|
// src/components/Input/InputKeywordSearch.tsx
|
|
14254
14313
|
import { CgClose as CgClose4 } from "@react-icons/all-files/cg/CgClose";
|
|
14255
14314
|
import { CgSearch } from "@react-icons/all-files/cg/CgSearch";
|
|
14256
|
-
import { jsx as
|
|
14315
|
+
import { jsx as jsx59 } from "@emotion/react/jsx-runtime";
|
|
14257
14316
|
var InputKeywordSearch = ({
|
|
14258
14317
|
onSearchTextChanged,
|
|
14259
|
-
disabled = false,
|
|
14318
|
+
disabled: disabled2 = false,
|
|
14260
14319
|
placeholder = "Keyword search",
|
|
14261
14320
|
inputFieldName = "keywordSearch",
|
|
14262
14321
|
disabledFieldSubmission = false,
|
|
@@ -14274,7 +14333,7 @@ var InputKeywordSearch = ({
|
|
|
14274
14333
|
e.preventDefault();
|
|
14275
14334
|
}
|
|
14276
14335
|
};
|
|
14277
|
-
return /* @__PURE__ */
|
|
14336
|
+
return /* @__PURE__ */ jsx59(
|
|
14278
14337
|
Input,
|
|
14279
14338
|
{
|
|
14280
14339
|
type: "text",
|
|
@@ -14282,10 +14341,10 @@ var InputKeywordSearch = ({
|
|
|
14282
14341
|
placeholder,
|
|
14283
14342
|
showLabel: false,
|
|
14284
14343
|
value,
|
|
14285
|
-
icon: value ? /* @__PURE__ */
|
|
14344
|
+
icon: value ? /* @__PURE__ */ jsx59("button", { css: inputSearchCloseBtn, onClick: onClear, type: "button", children: /* @__PURE__ */ jsx59(Icon, { icon: CgClose4, iconColor: "red", size: "1rem" }) }) : /* @__PURE__ */ jsx59(Icon, { icon: CgSearch, iconColor: "gray", size: "1rem" }),
|
|
14286
14345
|
onChange: handleSearchTextChanged,
|
|
14287
14346
|
onKeyPress: preventSubmitOnField,
|
|
14288
|
-
disabled,
|
|
14347
|
+
disabled: disabled2,
|
|
14289
14348
|
"aria-label": placeholder,
|
|
14290
14349
|
css: [
|
|
14291
14350
|
compact ? {
|
|
@@ -14294,13 +14353,14 @@ var InputKeywordSearch = ({
|
|
|
14294
14353
|
} : null,
|
|
14295
14354
|
rounded ? { borderRadius: "var(--rounded-full)" } : null
|
|
14296
14355
|
],
|
|
14356
|
+
"data-testid": "input-search",
|
|
14297
14357
|
...props
|
|
14298
14358
|
}
|
|
14299
14359
|
);
|
|
14300
14360
|
};
|
|
14301
14361
|
|
|
14302
14362
|
// src/components/Input/InputSelect.tsx
|
|
14303
|
-
import { Fragment as Fragment9, jsx as
|
|
14363
|
+
import { Fragment as Fragment9, jsx as jsx60, jsxs as jsxs36 } from "@emotion/react/jsx-runtime";
|
|
14304
14364
|
var InputSelect = ({
|
|
14305
14365
|
label,
|
|
14306
14366
|
defaultOption,
|
|
@@ -14322,7 +14382,7 @@ var InputSelect = ({
|
|
|
14322
14382
|
css: [inputContainer, typeof classNameContainer === "object" ? classNameContainer : void 0],
|
|
14323
14383
|
className: typeof classNameContainer === "string" ? classNameContainer : "",
|
|
14324
14384
|
children: [
|
|
14325
|
-
showLabel ? /* @__PURE__ */
|
|
14385
|
+
showLabel ? /* @__PURE__ */ jsx60(Fragment9, { children: /* @__PURE__ */ jsxs36(
|
|
14326
14386
|
Label,
|
|
14327
14387
|
{
|
|
14328
14388
|
htmlFor: props.id,
|
|
@@ -14349,14 +14409,14 @@ var InputSelect = ({
|
|
|
14349
14409
|
className: typeof classNameControl === "string" ? classNameControl : "",
|
|
14350
14410
|
...props,
|
|
14351
14411
|
children: [
|
|
14352
|
-
defaultOption ? /* @__PURE__ */
|
|
14353
|
-
options.map((opt, index) => /* @__PURE__ */
|
|
14412
|
+
defaultOption ? /* @__PURE__ */ jsx60("option", { value: "", children: defaultOption }) : null,
|
|
14413
|
+
options.map((opt, index) => /* @__PURE__ */ jsx60("option", { value: opt.label, ...opt }, index))
|
|
14354
14414
|
]
|
|
14355
14415
|
}
|
|
14356
14416
|
),
|
|
14357
|
-
caption ? /* @__PURE__ */
|
|
14358
|
-
errorMessage ? /* @__PURE__ */
|
|
14359
|
-
warningMessage && !errorMessage ? /* @__PURE__ */
|
|
14417
|
+
caption ? /* @__PURE__ */ jsx60(Caption, { children: caption }) : null,
|
|
14418
|
+
errorMessage ? /* @__PURE__ */ jsx60(ErrorMessage, { message: errorMessage }) : null,
|
|
14419
|
+
warningMessage && !errorMessage ? /* @__PURE__ */ jsx60(WarningMessage, { message: warningMessage }) : null
|
|
14360
14420
|
]
|
|
14361
14421
|
}
|
|
14362
14422
|
);
|
|
@@ -14364,12 +14424,12 @@ var InputSelect = ({
|
|
|
14364
14424
|
|
|
14365
14425
|
// src/components/Input/InputToggle.tsx
|
|
14366
14426
|
import * as React17 from "react";
|
|
14367
|
-
import { jsx as
|
|
14427
|
+
import { jsx as jsx61, jsxs as jsxs37 } from "@emotion/react/jsx-runtime";
|
|
14368
14428
|
var InputToggle = React17.forwardRef(
|
|
14369
14429
|
({
|
|
14370
14430
|
label,
|
|
14371
14431
|
type,
|
|
14372
|
-
disabled,
|
|
14432
|
+
disabled: disabled2,
|
|
14373
14433
|
checked,
|
|
14374
14434
|
name,
|
|
14375
14435
|
caption,
|
|
@@ -14387,10 +14447,10 @@ var InputToggle = React17.forwardRef(
|
|
|
14387
14447
|
return /* @__PURE__ */ jsxs37(
|
|
14388
14448
|
Label,
|
|
14389
14449
|
{
|
|
14390
|
-
css: [inputToggleLabel,
|
|
14450
|
+
css: [inputToggleLabel, disabled2 ? inputDisabled : void 0],
|
|
14391
14451
|
"data-testid": testId ? testId : "input-toggle",
|
|
14392
14452
|
children: [
|
|
14393
|
-
/* @__PURE__ */
|
|
14453
|
+
/* @__PURE__ */ jsx61(
|
|
14394
14454
|
"input",
|
|
14395
14455
|
{
|
|
14396
14456
|
ref,
|
|
@@ -14398,15 +14458,15 @@ var InputToggle = React17.forwardRef(
|
|
|
14398
14458
|
css: toggleInput,
|
|
14399
14459
|
checked,
|
|
14400
14460
|
name,
|
|
14401
|
-
disabled,
|
|
14461
|
+
disabled: disabled2,
|
|
14402
14462
|
...props
|
|
14403
14463
|
}
|
|
14404
14464
|
),
|
|
14405
|
-
/* @__PURE__ */
|
|
14465
|
+
/* @__PURE__ */ jsx61("span", { css: [inlineLabel, fontWeightStyles[fontWeight]], children: label }),
|
|
14406
14466
|
caption || errorMessage ? /* @__PURE__ */ jsxs37("span", { css: inputToggleMessageContainer, children: [
|
|
14407
|
-
caption ? /* @__PURE__ */
|
|
14408
|
-
errorMessage ? /* @__PURE__ */
|
|
14409
|
-
warningMessage && !errorMessage ? /* @__PURE__ */
|
|
14467
|
+
caption ? /* @__PURE__ */ jsx61(Caption, { children: caption }) : null,
|
|
14468
|
+
errorMessage ? /* @__PURE__ */ jsx61(ErrorMessage, { message: errorMessage }) : null,
|
|
14469
|
+
warningMessage && !errorMessage ? /* @__PURE__ */ jsx61(WarningMessage, { message: warningMessage }) : null
|
|
14410
14470
|
] }) : null
|
|
14411
14471
|
]
|
|
14412
14472
|
}
|
|
@@ -14415,9 +14475,9 @@ var InputToggle = React17.forwardRef(
|
|
|
14415
14475
|
);
|
|
14416
14476
|
|
|
14417
14477
|
// src/components/Input/Legend.tsx
|
|
14418
|
-
import { jsx as
|
|
14478
|
+
import { jsx as jsx62 } from "@emotion/react/jsx-runtime";
|
|
14419
14479
|
var Legend = ({ children }) => {
|
|
14420
|
-
return /* @__PURE__ */
|
|
14480
|
+
return /* @__PURE__ */ jsx62("legend", { css: fieldsetLegend, children });
|
|
14421
14481
|
};
|
|
14422
14482
|
|
|
14423
14483
|
// src/components/Input/SuccessMessage.tsx
|
|
@@ -14439,23 +14499,23 @@ var SuccessIcon2 = css53`
|
|
|
14439
14499
|
`;
|
|
14440
14500
|
|
|
14441
14501
|
// src/components/Input/SuccessMessage.tsx
|
|
14442
|
-
import { jsx as
|
|
14502
|
+
import { jsx as jsx63, jsxs as jsxs38 } from "@emotion/react/jsx-runtime";
|
|
14443
14503
|
var SuccessMessage = ({ message, testId, ...props }) => {
|
|
14444
14504
|
return message ? /* @__PURE__ */ jsxs38("span", { role: "status", css: SuccessText, "data-testid": testId, ...props, children: [
|
|
14445
|
-
/* @__PURE__ */
|
|
14505
|
+
/* @__PURE__ */ jsx63("span", { children: /* @__PURE__ */ jsx63(Icon, { css: SuccessIcon2, icon: CgCheckO, size: "1rem", iconColor: "currentColor" }) }),
|
|
14446
14506
|
message
|
|
14447
14507
|
] }) : null;
|
|
14448
14508
|
};
|
|
14449
14509
|
|
|
14450
14510
|
// src/components/Input/Textarea.tsx
|
|
14451
14511
|
import { forwardRef as forwardRef9 } from "react";
|
|
14452
|
-
import { Fragment as Fragment10, jsx as
|
|
14512
|
+
import { Fragment as Fragment10, jsx as jsx64, jsxs as jsxs39 } from "@emotion/react/jsx-runtime";
|
|
14453
14513
|
var Textarea = forwardRef9(
|
|
14454
14514
|
({ label, icon, id, caption, showLabel = true, errorMessage, warningMessage, ...props }, ref) => {
|
|
14455
14515
|
return /* @__PURE__ */ jsxs39(Fragment10, { children: [
|
|
14456
|
-
showLabel ? /* @__PURE__ */
|
|
14516
|
+
showLabel ? /* @__PURE__ */ jsx64("label", { htmlFor: id, css: [labelText], children: label }) : null,
|
|
14457
14517
|
/* @__PURE__ */ jsxs39("div", { css: [inputContainer], children: [
|
|
14458
|
-
/* @__PURE__ */
|
|
14518
|
+
/* @__PURE__ */ jsx64(
|
|
14459
14519
|
"textarea",
|
|
14460
14520
|
{
|
|
14461
14521
|
ref,
|
|
@@ -14470,11 +14530,11 @@ var Textarea = forwardRef9(
|
|
|
14470
14530
|
...props
|
|
14471
14531
|
}
|
|
14472
14532
|
),
|
|
14473
|
-
icon ? /* @__PURE__ */
|
|
14533
|
+
icon ? /* @__PURE__ */ jsx64("div", { css: inputIcon, children: icon }) : null
|
|
14474
14534
|
] }),
|
|
14475
|
-
caption ? /* @__PURE__ */
|
|
14476
|
-
errorMessage ? /* @__PURE__ */
|
|
14477
|
-
warningMessage && !errorMessage ? /* @__PURE__ */
|
|
14535
|
+
caption ? /* @__PURE__ */ jsx64(Caption, { children: caption }) : null,
|
|
14536
|
+
errorMessage ? /* @__PURE__ */ jsx64(ErrorMessage, { message: errorMessage }) : null,
|
|
14537
|
+
warningMessage && !errorMessage ? /* @__PURE__ */ jsx64(WarningMessage, { message: warningMessage }) : null
|
|
14478
14538
|
] });
|
|
14479
14539
|
}
|
|
14480
14540
|
);
|
|
@@ -14504,7 +14564,7 @@ var imgLoading = css54`
|
|
|
14504
14564
|
opacity: 0;
|
|
14505
14565
|
`;
|
|
14506
14566
|
var imgLoaded = css54`
|
|
14507
|
-
animation: ${fadeIn} var(--duration-
|
|
14567
|
+
animation: ${fadeIn} var(--duration-fast) var(--timing-ease-out) forwards;
|
|
14508
14568
|
opacity: 1;
|
|
14509
14569
|
`;
|
|
14510
14570
|
var brokenImage = css54`
|
|
@@ -14521,7 +14581,7 @@ var variantFillImageImg = css54`
|
|
|
14521
14581
|
`;
|
|
14522
14582
|
|
|
14523
14583
|
// src/components/Image/ImageBroken.tsx
|
|
14524
|
-
import { jsx as
|
|
14584
|
+
import { jsx as jsx65, jsxs as jsxs40 } from "@emotion/react/jsx-runtime";
|
|
14525
14585
|
var ImageBroken = ({ width, height, ...props }) => {
|
|
14526
14586
|
return /* @__PURE__ */ jsxs40(
|
|
14527
14587
|
"svg",
|
|
@@ -14536,11 +14596,11 @@ var ImageBroken = ({ width, height, ...props }) => {
|
|
|
14536
14596
|
"data-testid": "broken-image",
|
|
14537
14597
|
...props,
|
|
14538
14598
|
children: [
|
|
14539
|
-
/* @__PURE__ */
|
|
14540
|
-
/* @__PURE__ */
|
|
14599
|
+
/* @__PURE__ */ jsx65("rect", { width: "214", height: "214", fill: "#F9FAFB" }),
|
|
14600
|
+
/* @__PURE__ */ jsx65("rect", { width: "214", height: "214", fill: "url(#pattern0)" }),
|
|
14541
14601
|
/* @__PURE__ */ jsxs40("defs", { children: [
|
|
14542
|
-
/* @__PURE__ */
|
|
14543
|
-
/* @__PURE__ */
|
|
14602
|
+
/* @__PURE__ */ jsx65("pattern", { id: "pattern0", patternContentUnits: "objectBoundingBox", width: "1", height: "1", children: /* @__PURE__ */ jsx65("use", { xlinkHref: "#image0_761_4353", transform: "scale(0.0025)" }) }),
|
|
14603
|
+
/* @__PURE__ */ jsx65(
|
|
14544
14604
|
"image",
|
|
14545
14605
|
{
|
|
14546
14606
|
id: "image0_761_4353",
|
|
@@ -14556,8 +14616,8 @@ var ImageBroken = ({ width, height, ...props }) => {
|
|
|
14556
14616
|
};
|
|
14557
14617
|
|
|
14558
14618
|
// src/components/Image/Image.tsx
|
|
14559
|
-
import { Fragment as Fragment11, jsx as
|
|
14560
|
-
var MIN_LOADING_MS =
|
|
14619
|
+
import { Fragment as Fragment11, jsx as jsx66, jsxs as jsxs41 } from "@emotion/react/jsx-runtime";
|
|
14620
|
+
var MIN_LOADING_MS = 100;
|
|
14561
14621
|
function Image({
|
|
14562
14622
|
alt,
|
|
14563
14623
|
src,
|
|
@@ -14589,7 +14649,7 @@ function Image({
|
|
|
14589
14649
|
}
|
|
14590
14650
|
setLoadErrorText(message);
|
|
14591
14651
|
}, [setLoadErrorText, src]);
|
|
14592
|
-
|
|
14652
|
+
useEffect8(() => {
|
|
14593
14653
|
updateImageSrc();
|
|
14594
14654
|
}, [src]);
|
|
14595
14655
|
const handleLoadEvent = () => {
|
|
@@ -14616,7 +14676,7 @@ function Image({
|
|
|
14616
14676
|
variant === "fill-container" ? variantFillImageWrapper : null
|
|
14617
14677
|
],
|
|
14618
14678
|
children: [
|
|
14619
|
-
src && !loadErrorText ? /* @__PURE__ */
|
|
14679
|
+
src && !loadErrorText ? /* @__PURE__ */ jsx66(
|
|
14620
14680
|
"img",
|
|
14621
14681
|
{
|
|
14622
14682
|
...imgAttribs,
|
|
@@ -14636,7 +14696,7 @@ function Image({
|
|
|
14636
14696
|
}
|
|
14637
14697
|
) : null,
|
|
14638
14698
|
src && loadErrorText ? /* @__PURE__ */ jsxs41(Fragment11, { children: [
|
|
14639
|
-
/* @__PURE__ */
|
|
14699
|
+
/* @__PURE__ */ jsx66(
|
|
14640
14700
|
ImageBroken,
|
|
14641
14701
|
{
|
|
14642
14702
|
css: [brokenImage, img, imgLoaded],
|
|
@@ -14645,7 +14705,7 @@ function Image({
|
|
|
14645
14705
|
"data-testid": "broken-image"
|
|
14646
14706
|
}
|
|
14647
14707
|
),
|
|
14648
|
-
/* @__PURE__ */
|
|
14708
|
+
/* @__PURE__ */ jsx66(ErrorMessage, { message: loadErrorText })
|
|
14649
14709
|
] }) : null
|
|
14650
14710
|
]
|
|
14651
14711
|
}
|
|
@@ -14787,7 +14847,7 @@ var IntegrationTileFloatingButtonMessage = (clicked) => css55`
|
|
|
14787
14847
|
`;
|
|
14788
14848
|
|
|
14789
14849
|
// src/components/Tiles/CreateTeamIntegrationTile.tsx
|
|
14790
|
-
import { jsx as
|
|
14850
|
+
import { jsx as jsx67, jsxs as jsxs42 } from "@emotion/react/jsx-runtime";
|
|
14791
14851
|
var CreateTeamIntegrationTile = ({
|
|
14792
14852
|
title: title2 = "Create a custom integration for your team",
|
|
14793
14853
|
buttonText = "Add Integration",
|
|
@@ -14796,7 +14856,7 @@ var CreateTeamIntegrationTile = ({
|
|
|
14796
14856
|
...props
|
|
14797
14857
|
}) => {
|
|
14798
14858
|
return /* @__PURE__ */ jsxs42("div", { css: [IntegrationTileContainer, IntegrationTileBtnDashedBorder], ...props, children: [
|
|
14799
|
-
/* @__PURE__ */
|
|
14859
|
+
/* @__PURE__ */ jsx67("span", { css: IntegrationTileTitle, title: title2, children: title2 }),
|
|
14800
14860
|
/* @__PURE__ */ jsxs42(
|
|
14801
14861
|
Button,
|
|
14802
14862
|
{
|
|
@@ -14807,7 +14867,7 @@ var CreateTeamIntegrationTile = ({
|
|
|
14807
14867
|
css: IntegrationTitleFakeButton,
|
|
14808
14868
|
children: [
|
|
14809
14869
|
buttonText,
|
|
14810
|
-
asDeepLink ? /* @__PURE__ */
|
|
14870
|
+
asDeepLink ? /* @__PURE__ */ jsx67(
|
|
14811
14871
|
Icon,
|
|
14812
14872
|
{
|
|
14813
14873
|
icon: CgChevronRight2,
|
|
@@ -14817,7 +14877,7 @@ var CreateTeamIntegrationTile = ({
|
|
|
14817
14877
|
order: 1;
|
|
14818
14878
|
`
|
|
14819
14879
|
}
|
|
14820
|
-
) : /* @__PURE__ */
|
|
14880
|
+
) : /* @__PURE__ */ jsx67(
|
|
14821
14881
|
Icon,
|
|
14822
14882
|
{
|
|
14823
14883
|
icon: CgAdd2,
|
|
@@ -14838,31 +14898,31 @@ var CreateTeamIntegrationTile = ({
|
|
|
14838
14898
|
import { CgCheck } from "@react-icons/all-files/cg/CgCheck";
|
|
14839
14899
|
import { CgLock } from "@react-icons/all-files/cg/CgLock";
|
|
14840
14900
|
import { CgSandClock } from "@react-icons/all-files/cg/CgSandClock";
|
|
14841
|
-
import { jsx as
|
|
14901
|
+
import { jsx as jsx68, jsxs as jsxs43 } from "@emotion/react/jsx-runtime";
|
|
14842
14902
|
var IntegrationedAddedBadge = ({ text = "Added" }) => {
|
|
14843
14903
|
return /* @__PURE__ */ jsxs43("span", { "data-testid": "integration-icon-installed", css: IntegrationAddedText, children: [
|
|
14844
|
-
/* @__PURE__ */
|
|
14904
|
+
/* @__PURE__ */ jsx68(Icon, { icon: CgCheck, iconColor: "currentColor" }),
|
|
14845
14905
|
text
|
|
14846
14906
|
] });
|
|
14847
14907
|
};
|
|
14848
14908
|
var IntegrationCustomBadge = ({ text = "Custom" }) => {
|
|
14849
|
-
return /* @__PURE__ */
|
|
14909
|
+
return /* @__PURE__ */ jsx68("span", { "data-testid": "integration-is-private", css: IntegrationCustomBadgeText("gray"), children: text });
|
|
14850
14910
|
};
|
|
14851
14911
|
var IntegrationPremiumBadge = ({ text = "Premium" }) => {
|
|
14852
14912
|
return /* @__PURE__ */ jsxs43("span", { css: IntegrationCustomBadgeText("blue"), children: [
|
|
14853
|
-
/* @__PURE__ */
|
|
14913
|
+
/* @__PURE__ */ jsx68(Icon, { icon: CgLock, iconColor: "currentColor", size: 12 }),
|
|
14854
14914
|
text
|
|
14855
14915
|
] });
|
|
14856
14916
|
};
|
|
14857
14917
|
var IntegrationComingSoonBadge = ({ text = "Coming soon" }) => {
|
|
14858
14918
|
return /* @__PURE__ */ jsxs43("span", { css: IntegrationCustomBadgeText("blue"), children: [
|
|
14859
|
-
/* @__PURE__ */
|
|
14919
|
+
/* @__PURE__ */ jsx68(Icon, { icon: CgSandClock, iconColor: "currentColor", size: 12 }),
|
|
14860
14920
|
text
|
|
14861
14921
|
] });
|
|
14862
14922
|
};
|
|
14863
14923
|
|
|
14864
14924
|
// src/components/Tiles/ResolveIcon.tsx
|
|
14865
|
-
import { jsx as
|
|
14925
|
+
import { jsx as jsx69 } from "@emotion/react/jsx-runtime";
|
|
14866
14926
|
var ResolveIcon = ({ icon, name, styleType = "logo", ...props }) => {
|
|
14867
14927
|
const CompIcon = icon && typeof icon !== "string" ? icon : null;
|
|
14868
14928
|
const mapClassName = {
|
|
@@ -14870,13 +14930,13 @@ var ResolveIcon = ({ icon, name, styleType = "logo", ...props }) => {
|
|
|
14870
14930
|
logo: IntegrationTitleLogo
|
|
14871
14931
|
};
|
|
14872
14932
|
if (icon) {
|
|
14873
|
-
return CompIcon ? /* @__PURE__ */
|
|
14933
|
+
return CompIcon ? /* @__PURE__ */ jsx69(CompIcon, { css: mapClassName[styleType], ...props }) : /* @__PURE__ */ jsx69("img", { src: icon, alt: name, css: mapClassName[styleType], ...props });
|
|
14874
14934
|
}
|
|
14875
14935
|
return null;
|
|
14876
14936
|
};
|
|
14877
14937
|
|
|
14878
14938
|
// src/components/Tiles/EditTeamIntegrationTile.tsx
|
|
14879
|
-
import { jsx as
|
|
14939
|
+
import { jsx as jsx70, jsxs as jsxs44 } from "@emotion/react/jsx-runtime";
|
|
14880
14940
|
var EditTeamIntegrationTile = ({
|
|
14881
14941
|
id,
|
|
14882
14942
|
icon,
|
|
@@ -14892,10 +14952,10 @@ var EditTeamIntegrationTile = ({
|
|
|
14892
14952
|
"data-testid": "configure-integration-container",
|
|
14893
14953
|
"integration-id": `${id.toLocaleLowerCase()}`,
|
|
14894
14954
|
children: [
|
|
14895
|
-
/* @__PURE__ */
|
|
14896
|
-
/* @__PURE__ */
|
|
14897
|
-
!isPublic ? /* @__PURE__ */
|
|
14898
|
-
canEdit ? /* @__PURE__ */
|
|
14955
|
+
/* @__PURE__ */ jsx70(ResolveIcon, { icon, name, "data-testid": "integration-logo" }),
|
|
14956
|
+
/* @__PURE__ */ jsx70("span", { css: IntegrationTileName, "data-testid": "integration-card-name", children: name }),
|
|
14957
|
+
!isPublic ? /* @__PURE__ */ jsx70(IntegrationCustomBadge, {}) : null,
|
|
14958
|
+
canEdit ? /* @__PURE__ */ jsx70(
|
|
14899
14959
|
Button,
|
|
14900
14960
|
{
|
|
14901
14961
|
buttonType: "unimportant",
|
|
@@ -14915,8 +14975,8 @@ var EditTeamIntegrationTile = ({
|
|
|
14915
14975
|
// src/components/Tiles/IntegrationComingSoon.tsx
|
|
14916
14976
|
import { css as css57 } from "@emotion/react";
|
|
14917
14977
|
import { CgHeart } from "@react-icons/all-files/cg/CgHeart";
|
|
14918
|
-
import { useEffect as
|
|
14919
|
-
import { jsx as
|
|
14978
|
+
import { useEffect as useEffect9, useState as useState9 } from "react";
|
|
14979
|
+
import { jsx as jsx71, jsxs as jsxs45 } from "@emotion/react/jsx-runtime";
|
|
14920
14980
|
var IntegrationComingSoon = ({
|
|
14921
14981
|
name,
|
|
14922
14982
|
icon,
|
|
@@ -14930,7 +14990,7 @@ var IntegrationComingSoon = ({
|
|
|
14930
14990
|
setUpVote((prev) => !prev);
|
|
14931
14991
|
onUpVoteClick();
|
|
14932
14992
|
};
|
|
14933
|
-
|
|
14993
|
+
useEffect9(() => {
|
|
14934
14994
|
if (upVote) {
|
|
14935
14995
|
const timer = setTimeout(() => setUpVote(false), timing);
|
|
14936
14996
|
return () => {
|
|
@@ -14945,9 +15005,9 @@ var IntegrationComingSoon = ({
|
|
|
14945
15005
|
"data-testid": `coming-soon-${id.toLowerCase()}-integration`,
|
|
14946
15006
|
...props,
|
|
14947
15007
|
children: [
|
|
14948
|
-
/* @__PURE__ */
|
|
14949
|
-
/* @__PURE__ */
|
|
14950
|
-
/* @__PURE__ */
|
|
15008
|
+
/* @__PURE__ */ jsx71(IntegrationComingSoonBadge, {}),
|
|
15009
|
+
/* @__PURE__ */ jsx71(ResolveIcon, { icon, name }),
|
|
15010
|
+
/* @__PURE__ */ jsx71("span", { css: IntegrationTileName, title: name, children: name }),
|
|
14951
15011
|
/* @__PURE__ */ jsxs45(
|
|
14952
15012
|
Button,
|
|
14953
15013
|
{
|
|
@@ -14958,8 +15018,8 @@ var IntegrationComingSoon = ({
|
|
|
14958
15018
|
role: "link",
|
|
14959
15019
|
css: [IntegrationTileFloatingButton, IntegrationTileFloatingButtonMessage(upVote)],
|
|
14960
15020
|
children: [
|
|
14961
|
-
/* @__PURE__ */
|
|
14962
|
-
/* @__PURE__ */
|
|
15021
|
+
/* @__PURE__ */ jsx71("strong", { children: "+1" }),
|
|
15022
|
+
/* @__PURE__ */ jsx71(
|
|
14963
15023
|
"span",
|
|
14964
15024
|
{
|
|
14965
15025
|
css: css57`
|
|
@@ -14970,7 +15030,7 @@ var IntegrationComingSoon = ({
|
|
|
14970
15030
|
}
|
|
14971
15031
|
),
|
|
14972
15032
|
/* @__PURE__ */ jsxs45("span", { "aria-hidden": !upVote, children: [
|
|
14973
|
-
/* @__PURE__ */
|
|
15033
|
+
/* @__PURE__ */ jsx71(Icon, { icon: CgHeart, iconColor: "currentColor", size: 18 }),
|
|
14974
15034
|
"Thanks!"
|
|
14975
15035
|
] })
|
|
14976
15036
|
]
|
|
@@ -15026,12 +15086,12 @@ var IntegrationLoadingFrame = css58`
|
|
|
15026
15086
|
`;
|
|
15027
15087
|
|
|
15028
15088
|
// src/components/Tiles/IntegrationLoadingTile.tsx
|
|
15029
|
-
import { Fragment as Fragment12, jsx as
|
|
15089
|
+
import { Fragment as Fragment12, jsx as jsx72, jsxs as jsxs46 } from "@emotion/react/jsx-runtime";
|
|
15030
15090
|
var IntegrationLoadingTile = ({ count = 1 }) => {
|
|
15031
15091
|
const componentCount = Array.from(Array(count).keys());
|
|
15032
|
-
return /* @__PURE__ */
|
|
15033
|
-
/* @__PURE__ */
|
|
15034
|
-
/* @__PURE__ */
|
|
15092
|
+
return /* @__PURE__ */ jsx72(Fragment12, { children: componentCount.map((i) => /* @__PURE__ */ jsxs46("div", { css: IntegrationLoadingTileContainer, children: [
|
|
15093
|
+
/* @__PURE__ */ jsx72("div", { css: [IntegrationLoadingTileImg, IntegrationLoadingFrame], role: "presentation" }),
|
|
15094
|
+
/* @__PURE__ */ jsx72("div", { css: [IntegrationLoadingTileText, IntegrationLoadingFrame] })
|
|
15035
15095
|
] }, i)) });
|
|
15036
15096
|
};
|
|
15037
15097
|
|
|
@@ -15051,7 +15111,7 @@ var IntegrationModalImage = css59`
|
|
|
15051
15111
|
`;
|
|
15052
15112
|
|
|
15053
15113
|
// src/components/Tiles/IntegrationModalIcon.tsx
|
|
15054
|
-
import { jsx as
|
|
15114
|
+
import { jsx as jsx73, jsxs as jsxs47 } from "@emotion/react/jsx-runtime";
|
|
15055
15115
|
var IntegrationModalIcon = ({ icon, name, ...imgProps }) => {
|
|
15056
15116
|
const CompIcon = icon && typeof icon !== "string" ? icon : null;
|
|
15057
15117
|
let iconSrc = void 0;
|
|
@@ -15069,7 +15129,7 @@ var IntegrationModalIcon = ({ icon, name, ...imgProps }) => {
|
|
|
15069
15129
|
}
|
|
15070
15130
|
return /* @__PURE__ */ jsxs47("div", { css: IntegrationModalIconContainer, children: [
|
|
15071
15131
|
/* @__PURE__ */ jsxs47("svg", { width: "49", height: "57", fill: "none", xmlns: "http://www.w3.org/2000/svg", role: "img", children: [
|
|
15072
|
-
/* @__PURE__ */
|
|
15132
|
+
/* @__PURE__ */ jsx73(
|
|
15073
15133
|
"path",
|
|
15074
15134
|
{
|
|
15075
15135
|
d: "m24.367 1.813 22.786 13.322V41.78L24.367 55.102 1.581 41.78V15.135L24.367 1.814Z",
|
|
@@ -15078,12 +15138,12 @@ var IntegrationModalIcon = ({ icon, name, ...imgProps }) => {
|
|
|
15078
15138
|
strokeWidth: "2"
|
|
15079
15139
|
}
|
|
15080
15140
|
),
|
|
15081
|
-
/* @__PURE__ */
|
|
15082
|
-
/* @__PURE__ */
|
|
15083
|
-
/* @__PURE__ */
|
|
15141
|
+
/* @__PURE__ */ jsx73("defs", { children: /* @__PURE__ */ jsxs47("linearGradient", { id: "a", x1: "41.353", y1: "49.107", x2: "8.048", y2: "4.478", gradientUnits: "userSpaceOnUse", children: [
|
|
15142
|
+
/* @__PURE__ */ jsx73("stop", { stopColor: "#1768B2" }),
|
|
15143
|
+
/* @__PURE__ */ jsx73("stop", { offset: "1", stopColor: "#B3EFE4" })
|
|
15084
15144
|
] }) })
|
|
15085
15145
|
] }),
|
|
15086
|
-
CompIcon ? /* @__PURE__ */
|
|
15146
|
+
CompIcon ? /* @__PURE__ */ jsx73(CompIcon, { role: "img", css: IntegrationModalImage, ...imgProps }) : iconSrc ? /* @__PURE__ */ jsx73(
|
|
15087
15147
|
"img",
|
|
15088
15148
|
{
|
|
15089
15149
|
src: iconSrc,
|
|
@@ -15097,7 +15157,7 @@ var IntegrationModalIcon = ({ icon, name, ...imgProps }) => {
|
|
|
15097
15157
|
};
|
|
15098
15158
|
|
|
15099
15159
|
// src/components/Tiles/IntegrationTile.tsx
|
|
15100
|
-
import { jsx as
|
|
15160
|
+
import { jsx as jsx74, jsxs as jsxs48 } from "@emotion/react/jsx-runtime";
|
|
15101
15161
|
var IntegrationTile = ({
|
|
15102
15162
|
id,
|
|
15103
15163
|
icon,
|
|
@@ -15119,12 +15179,12 @@ var IntegrationTile = ({
|
|
|
15119
15179
|
"aria-label": name,
|
|
15120
15180
|
...btnProps,
|
|
15121
15181
|
children: [
|
|
15122
|
-
/* @__PURE__ */
|
|
15123
|
-
/* @__PURE__ */
|
|
15124
|
-
isInstalled ? /* @__PURE__ */
|
|
15125
|
-
requiedEntitlement && isPublic ? /* @__PURE__ */
|
|
15126
|
-
!isPublic ? /* @__PURE__ */
|
|
15127
|
-
authorIcon ? /* @__PURE__ */
|
|
15182
|
+
/* @__PURE__ */ jsx74(ResolveIcon, { icon, name }),
|
|
15183
|
+
/* @__PURE__ */ jsx74("span", { css: IntegrationTileName, title: name, children: name }),
|
|
15184
|
+
isInstalled ? /* @__PURE__ */ jsx74(IntegrationedAddedBadge, {}) : null,
|
|
15185
|
+
requiedEntitlement && isPublic ? /* @__PURE__ */ jsx74(IntegrationPremiumBadge, {}) : null,
|
|
15186
|
+
!isPublic ? /* @__PURE__ */ jsx74(IntegrationCustomBadge, {}) : null,
|
|
15187
|
+
authorIcon ? /* @__PURE__ */ jsx74(ResolveIcon, { icon: authorIcon, name }) : null
|
|
15128
15188
|
]
|
|
15129
15189
|
}
|
|
15130
15190
|
);
|
|
@@ -15157,9 +15217,9 @@ var Tile = css60`
|
|
|
15157
15217
|
`;
|
|
15158
15218
|
|
|
15159
15219
|
// src/components/Tiles/Tile.tsx
|
|
15160
|
-
import { jsx as
|
|
15161
|
-
var Tile2 = ({ children, disabled, ...props }) => {
|
|
15162
|
-
return /* @__PURE__ */
|
|
15220
|
+
import { jsx as jsx75 } from "@emotion/react/jsx-runtime";
|
|
15221
|
+
var Tile2 = ({ children, disabled: disabled2, ...props }) => {
|
|
15222
|
+
return /* @__PURE__ */ jsx75("button", { type: "button", css: Tile, disabled: disabled2, ...props, children });
|
|
15163
15223
|
};
|
|
15164
15224
|
|
|
15165
15225
|
// src/components/Tiles/styles/TileContainer.styles.ts
|
|
@@ -15182,7 +15242,7 @@ var TileContainerInner = (gap, templateColumns) => css61`
|
|
|
15182
15242
|
`;
|
|
15183
15243
|
|
|
15184
15244
|
// src/components/Tiles/TileContainer.tsx
|
|
15185
|
-
import { jsx as
|
|
15245
|
+
import { jsx as jsx76 } from "@emotion/react/jsx-runtime";
|
|
15186
15246
|
var TileContainer = ({
|
|
15187
15247
|
bgColor = "var(--brand-secondary-2)",
|
|
15188
15248
|
containerPadding = "base",
|
|
@@ -15191,7 +15251,7 @@ var TileContainer = ({
|
|
|
15191
15251
|
children,
|
|
15192
15252
|
...props
|
|
15193
15253
|
}) => {
|
|
15194
|
-
return /* @__PURE__ */
|
|
15254
|
+
return /* @__PURE__ */ jsx76("div", { css: TileContainerWrapper(bgColor, containerPadding), ...props, children: /* @__PURE__ */ jsx76("div", { css: TileContainerInner(gap, gridTemplateColumns), children }) });
|
|
15195
15255
|
};
|
|
15196
15256
|
|
|
15197
15257
|
// src/components/Tiles/styles/TileText.styles.ts
|
|
@@ -15206,10 +15266,10 @@ var TileText = css62`
|
|
|
15206
15266
|
`;
|
|
15207
15267
|
|
|
15208
15268
|
// src/components/Tiles/TileText.tsx
|
|
15209
|
-
import { jsx as
|
|
15269
|
+
import { jsx as jsx77 } from "@emotion/react/jsx-runtime";
|
|
15210
15270
|
var TileText2 = ({ as = "heading", children, ...props }) => {
|
|
15211
15271
|
const isHeading = as === "heading";
|
|
15212
|
-
return /* @__PURE__ */
|
|
15272
|
+
return /* @__PURE__ */ jsx77(
|
|
15213
15273
|
"span",
|
|
15214
15274
|
{
|
|
15215
15275
|
role: isHeading ? "heading" : void 0,
|
|
@@ -15238,6 +15298,7 @@ var IntegrationModalHeaderTitleGroup = css63`
|
|
|
15238
15298
|
align-items: center;
|
|
15239
15299
|
display: flex;
|
|
15240
15300
|
gap: var(--spacing-base);
|
|
15301
|
+
padding: 0 var(--spacing-base);
|
|
15241
15302
|
`;
|
|
15242
15303
|
var IntegrationModalHeaderTitle = css63`
|
|
15243
15304
|
margin-top: 0;
|
|
@@ -15246,12 +15307,18 @@ var IntegrationModalHeaderMenuPlacement = css63`
|
|
|
15246
15307
|
margin-bottom: var(--spacing-base);
|
|
15247
15308
|
`;
|
|
15248
15309
|
var IntegrationModalHeaderContentWrapper = css63`
|
|
15310
|
+
background: var(--white);
|
|
15311
|
+
display: flex;
|
|
15312
|
+
padding: var(--spacing-base);
|
|
15313
|
+
flex-direction: column;
|
|
15314
|
+
gap: var(--spacing-base);
|
|
15315
|
+
height: 100%;
|
|
15249
15316
|
position: relative;
|
|
15250
15317
|
z-index: var(--z-10);
|
|
15251
15318
|
`;
|
|
15252
15319
|
|
|
15253
15320
|
// src/components/IntegrationModalHeader/IntegrationModalHeader.tsx
|
|
15254
|
-
import { Fragment as Fragment13, jsx as
|
|
15321
|
+
import { Fragment as Fragment13, jsx as jsx78, jsxs as jsxs49 } from "@emotion/react/jsx-runtime";
|
|
15255
15322
|
var HexModalBackground = ({ ...props }) => {
|
|
15256
15323
|
return /* @__PURE__ */ jsxs49(
|
|
15257
15324
|
"svg",
|
|
@@ -15263,7 +15330,7 @@ var HexModalBackground = ({ ...props }) => {
|
|
|
15263
15330
|
xmlns: "http://www.w3.org/2000/svg",
|
|
15264
15331
|
...props,
|
|
15265
15332
|
children: [
|
|
15266
|
-
/* @__PURE__ */
|
|
15333
|
+
/* @__PURE__ */ jsx78(
|
|
15267
15334
|
"path",
|
|
15268
15335
|
{
|
|
15269
15336
|
fillRule: "evenodd",
|
|
@@ -15272,7 +15339,7 @@ var HexModalBackground = ({ ...props }) => {
|
|
|
15272
15339
|
fill: "url(#paint0_linear_196_2737)"
|
|
15273
15340
|
}
|
|
15274
15341
|
),
|
|
15275
|
-
/* @__PURE__ */
|
|
15342
|
+
/* @__PURE__ */ jsx78("defs", { children: /* @__PURE__ */ jsxs49(
|
|
15276
15343
|
"linearGradient",
|
|
15277
15344
|
{
|
|
15278
15345
|
id: "paint0_linear_196_2737",
|
|
@@ -15282,8 +15349,8 @@ var HexModalBackground = ({ ...props }) => {
|
|
|
15282
15349
|
y2: "-95.2742",
|
|
15283
15350
|
gradientUnits: "userSpaceOnUse",
|
|
15284
15351
|
children: [
|
|
15285
|
-
/* @__PURE__ */
|
|
15286
|
-
/* @__PURE__ */
|
|
15352
|
+
/* @__PURE__ */ jsx78("stop", { stopColor: "#81DCDE" }),
|
|
15353
|
+
/* @__PURE__ */ jsx78("stop", { offset: "1", stopColor: "#428ED4" })
|
|
15287
15354
|
]
|
|
15288
15355
|
}
|
|
15289
15356
|
) })
|
|
@@ -15293,22 +15360,22 @@ var HexModalBackground = ({ ...props }) => {
|
|
|
15293
15360
|
};
|
|
15294
15361
|
var IntegrationModalHeader = ({ icon, name, menu: menu2, children }) => {
|
|
15295
15362
|
return /* @__PURE__ */ jsxs49(Fragment13, { children: [
|
|
15296
|
-
/* @__PURE__ */
|
|
15297
|
-
/* @__PURE__ */
|
|
15298
|
-
icon ? /* @__PURE__ */
|
|
15299
|
-
/* @__PURE__ */
|
|
15363
|
+
/* @__PURE__ */ jsx78(HexModalBackground, { css: IntegrationModalHeaderSVGBackground, role: "presentation" }),
|
|
15364
|
+
/* @__PURE__ */ jsx78("div", { css: IntegrationModalHeaderGroup, children: /* @__PURE__ */ jsxs49("div", { css: IntegrationModalHeaderTitleGroup, children: [
|
|
15365
|
+
icon ? /* @__PURE__ */ jsx78(IntegrationModalIcon, { icon, name: name || "" }) : null,
|
|
15366
|
+
/* @__PURE__ */ jsx78(Heading, { level: 3, css: IntegrationModalHeaderTitle, "data-testid": "integration-modal-title", children: name || "Create Team Integration" }),
|
|
15300
15367
|
menu2 ? /* @__PURE__ */ jsxs49("div", { css: IntegrationModalHeaderMenuPlacement, children: [
|
|
15301
15368
|
menu2,
|
|
15302
15369
|
" "
|
|
15303
15370
|
] }) : null
|
|
15304
15371
|
] }) }),
|
|
15305
|
-
/* @__PURE__ */
|
|
15372
|
+
/* @__PURE__ */ jsx78("div", { css: IntegrationModalHeaderContentWrapper, children })
|
|
15306
15373
|
] });
|
|
15307
15374
|
};
|
|
15308
15375
|
|
|
15309
15376
|
// src/components/JsonEditor/JsonEditor.tsx
|
|
15310
15377
|
import MonacoEditor from "@monaco-editor/react";
|
|
15311
|
-
import { jsx as
|
|
15378
|
+
import { jsx as jsx79 } from "@emotion/react/jsx-runtime";
|
|
15312
15379
|
var minEditorHeightPx = 150;
|
|
15313
15380
|
var JsonEditor = ({ defaultValue, onChange, jsonSchema, height, readOnly }) => {
|
|
15314
15381
|
let effectiveHeight = height;
|
|
@@ -15318,7 +15385,7 @@ var JsonEditor = ({ defaultValue, onChange, jsonSchema, height, readOnly }) => {
|
|
|
15318
15385
|
if (typeof effectiveHeight === "number" && effectiveHeight < minEditorHeightPx) {
|
|
15319
15386
|
effectiveHeight = minEditorHeightPx;
|
|
15320
15387
|
}
|
|
15321
|
-
return /* @__PURE__ */
|
|
15388
|
+
return /* @__PURE__ */ jsx79(
|
|
15322
15389
|
MonacoEditor,
|
|
15323
15390
|
{
|
|
15324
15391
|
height: effectiveHeight,
|
|
@@ -15387,7 +15454,7 @@ var LimitsBarTextColor = (statusColor) => css64`
|
|
|
15387
15454
|
`;
|
|
15388
15455
|
|
|
15389
15456
|
// src/components/LimitsBar/LimitsBar.tsx
|
|
15390
|
-
import { jsx as
|
|
15457
|
+
import { jsx as jsx80, jsxs as jsxs50 } from "@emotion/react/jsx-runtime";
|
|
15391
15458
|
var LimitsBar = ({ current, max, label }) => {
|
|
15392
15459
|
const maxPercentage = 100;
|
|
15393
15460
|
const progressBarValue = Math.ceil(current / max * maxPercentage);
|
|
@@ -15400,14 +15467,14 @@ var LimitsBar = ({ current, max, label }) => {
|
|
|
15400
15467
|
const statusColor = progressBarValue === 100 ? colorMap.danger : progressBarValue >= 75 ? colorMap.warn : colorMap.base;
|
|
15401
15468
|
return /* @__PURE__ */ jsxs50("div", { css: LimitsBarContainer, children: [
|
|
15402
15469
|
/* @__PURE__ */ jsxs50("div", { css: LimitsBarLabelContainer, children: [
|
|
15403
|
-
/* @__PURE__ */
|
|
15470
|
+
/* @__PURE__ */ jsx80("span", { css: LimitsBarLabel, children: label }),
|
|
15404
15471
|
/* @__PURE__ */ jsxs50("span", { css: [LimitsBarLabel, LimitsBarTextColor(statusColor)], children: [
|
|
15405
15472
|
current,
|
|
15406
15473
|
" of ",
|
|
15407
15474
|
max
|
|
15408
15475
|
] })
|
|
15409
15476
|
] }),
|
|
15410
|
-
/* @__PURE__ */
|
|
15477
|
+
/* @__PURE__ */ jsx80(
|
|
15411
15478
|
"div",
|
|
15412
15479
|
{
|
|
15413
15480
|
role: "progressbar",
|
|
@@ -15416,7 +15483,7 @@ var LimitsBar = ({ current, max, label }) => {
|
|
|
15416
15483
|
"aria-valuemax": max,
|
|
15417
15484
|
"aria-valuetext": `${current} of ${max}`,
|
|
15418
15485
|
css: LimitsBarProgressBar,
|
|
15419
|
-
children: /* @__PURE__ */
|
|
15486
|
+
children: /* @__PURE__ */ jsx80(
|
|
15420
15487
|
"span",
|
|
15421
15488
|
{
|
|
15422
15489
|
role: "presentation",
|
|
@@ -15448,10 +15515,10 @@ var LinkListTitle = css65`
|
|
|
15448
15515
|
`;
|
|
15449
15516
|
|
|
15450
15517
|
// src/components/LinkList/LinkList.tsx
|
|
15451
|
-
import { jsx as
|
|
15518
|
+
import { jsx as jsx81, jsxs as jsxs51 } from "@emotion/react/jsx-runtime";
|
|
15452
15519
|
var LinkList = ({ title: title2, padding = "var(--spacing-md)", children, ...props }) => {
|
|
15453
15520
|
return /* @__PURE__ */ jsxs51("div", { css: LinkListContainer(padding), ...props, children: [
|
|
15454
|
-
/* @__PURE__ */
|
|
15521
|
+
/* @__PURE__ */ jsx81(Heading, { level: 3, css: LinkListTitle, children: title2 }),
|
|
15455
15522
|
children
|
|
15456
15523
|
] });
|
|
15457
15524
|
};
|
|
@@ -15487,10 +15554,10 @@ var ScrollableListInner = css66`
|
|
|
15487
15554
|
`;
|
|
15488
15555
|
|
|
15489
15556
|
// src/components/List/ScrollableList.tsx
|
|
15490
|
-
import { jsx as
|
|
15557
|
+
import { jsx as jsx82, jsxs as jsxs52 } from "@emotion/react/jsx-runtime";
|
|
15491
15558
|
var ScrollableList = ({ label, children, ...props }) => {
|
|
15492
15559
|
return /* @__PURE__ */ jsxs52("div", { css: [ScrollableListContainer, scrollbarStyles], ...props, children: [
|
|
15493
|
-
label ? /* @__PURE__ */
|
|
15560
|
+
label ? /* @__PURE__ */ jsx82(
|
|
15494
15561
|
"span",
|
|
15495
15562
|
{
|
|
15496
15563
|
css: css67`
|
|
@@ -15499,7 +15566,7 @@ var ScrollableList = ({ label, children, ...props }) => {
|
|
|
15499
15566
|
children: label
|
|
15500
15567
|
}
|
|
15501
15568
|
) : null,
|
|
15502
|
-
/* @__PURE__ */
|
|
15569
|
+
/* @__PURE__ */ jsx82("div", { css: [ScrollableListInner, scrollbarStyles], children })
|
|
15503
15570
|
] });
|
|
15504
15571
|
};
|
|
15505
15572
|
|
|
@@ -15571,23 +15638,23 @@ var ScrollableListIconVisible = css68`
|
|
|
15571
15638
|
`;
|
|
15572
15639
|
|
|
15573
15640
|
// src/components/List/ScrollableListInputItem.tsx
|
|
15574
|
-
import { jsx as
|
|
15641
|
+
import { jsx as jsx83, jsxs as jsxs53 } from "@emotion/react/jsx-runtime";
|
|
15575
15642
|
var ScrollableListInputItem = ({
|
|
15576
15643
|
label,
|
|
15577
15644
|
icon,
|
|
15578
|
-
active,
|
|
15645
|
+
active: active2,
|
|
15579
15646
|
disableShadow = false,
|
|
15580
15647
|
children,
|
|
15581
15648
|
labelTestId,
|
|
15582
15649
|
...props
|
|
15583
15650
|
}) => {
|
|
15584
|
-
return /* @__PURE__ */
|
|
15651
|
+
return /* @__PURE__ */ jsx83(
|
|
15585
15652
|
"div",
|
|
15586
15653
|
{
|
|
15587
15654
|
css: [
|
|
15588
15655
|
ScrollableListItemContainer,
|
|
15589
15656
|
disableShadow ? void 0 : ScrollableListItemShadow,
|
|
15590
|
-
|
|
15657
|
+
active2 ? ScrollableListItemActive : void 0
|
|
15591
15658
|
],
|
|
15592
15659
|
...props,
|
|
15593
15660
|
children: /* @__PURE__ */ jsxs53("label", { "data-testid": labelTestId, css: ScrollableListInputLabel, children: [
|
|
@@ -15595,16 +15662,16 @@ var ScrollableListInputItem = ({
|
|
|
15595
15662
|
icon,
|
|
15596
15663
|
label
|
|
15597
15664
|
] }),
|
|
15598
|
-
/* @__PURE__ */
|
|
15599
|
-
/* @__PURE__ */
|
|
15665
|
+
/* @__PURE__ */ jsx83("div", { css: ScrollableListHiddenInput, children }),
|
|
15666
|
+
/* @__PURE__ */ jsx83(
|
|
15600
15667
|
Icon,
|
|
15601
15668
|
{
|
|
15602
15669
|
icon: CgCheck2,
|
|
15603
15670
|
iconColor: "currentColor",
|
|
15604
|
-
css: [ScrollableListIcon,
|
|
15671
|
+
css: [ScrollableListIcon, active2 ? ScrollableListIconVisible : void 0],
|
|
15605
15672
|
size: 24,
|
|
15606
15673
|
"data-testid": "check-mark",
|
|
15607
|
-
"data-test-active":
|
|
15674
|
+
"data-test-active": active2
|
|
15608
15675
|
}
|
|
15609
15676
|
)
|
|
15610
15677
|
] })
|
|
@@ -15614,33 +15681,33 @@ var ScrollableListInputItem = ({
|
|
|
15614
15681
|
|
|
15615
15682
|
// src/components/List/ScrollableListItem.tsx
|
|
15616
15683
|
import { CgCheck as CgCheck3 } from "@react-icons/all-files/cg/CgCheck";
|
|
15617
|
-
import { jsx as
|
|
15684
|
+
import { jsx as jsx84, jsxs as jsxs54 } from "@emotion/react/jsx-runtime";
|
|
15618
15685
|
var ScrollableListItem = ({
|
|
15619
15686
|
buttonText,
|
|
15620
15687
|
icon,
|
|
15621
|
-
active,
|
|
15688
|
+
active: active2,
|
|
15622
15689
|
disableShadow,
|
|
15623
15690
|
...props
|
|
15624
15691
|
}) => {
|
|
15625
|
-
return /* @__PURE__ */
|
|
15692
|
+
return /* @__PURE__ */ jsx84(
|
|
15626
15693
|
"div",
|
|
15627
15694
|
{
|
|
15628
15695
|
css: [
|
|
15629
15696
|
ScrollableListItemContainer,
|
|
15630
15697
|
disableShadow ? void 0 : ScrollableListItemShadow,
|
|
15631
|
-
|
|
15698
|
+
active2 ? ScrollableListItemActive : void 0
|
|
15632
15699
|
],
|
|
15633
15700
|
children: /* @__PURE__ */ jsxs54("button", { css: ScrollableListItemBtn, type: "button", ...props, children: [
|
|
15634
15701
|
/* @__PURE__ */ jsxs54(HorizontalRhythm, { gap: "xs", align: "center", children: [
|
|
15635
15702
|
icon,
|
|
15636
|
-
/* @__PURE__ */
|
|
15703
|
+
/* @__PURE__ */ jsx84("span", { children: buttonText })
|
|
15637
15704
|
] }),
|
|
15638
|
-
/* @__PURE__ */
|
|
15705
|
+
/* @__PURE__ */ jsx84(
|
|
15639
15706
|
Icon,
|
|
15640
15707
|
{
|
|
15641
15708
|
icon: CgCheck3,
|
|
15642
15709
|
iconColor: "currentColor",
|
|
15643
|
-
css: [ScrollableListIcon,
|
|
15710
|
+
css: [ScrollableListIcon, active2 ? ScrollableListIconVisible : void 0],
|
|
15644
15711
|
size: 24
|
|
15645
15712
|
}
|
|
15646
15713
|
)
|
|
@@ -15702,21 +15769,21 @@ function loadingDot(size) {
|
|
|
15702
15769
|
}
|
|
15703
15770
|
|
|
15704
15771
|
// src/components/LoadingIndicator/LoadingIndicator.tsx
|
|
15705
|
-
import { jsx as
|
|
15772
|
+
import { jsx as jsx85, jsxs as jsxs55 } from "@emotion/react/jsx-runtime";
|
|
15706
15773
|
var LoadingIndicator = ({
|
|
15707
15774
|
size = "lg",
|
|
15708
15775
|
...props
|
|
15709
15776
|
}) => {
|
|
15710
15777
|
const dotStyle = loadingDot(size);
|
|
15711
15778
|
return /* @__PURE__ */ jsxs55("div", { role: "alert", css: loader, "data-testid": "loading-indicator", ...props, children: [
|
|
15712
|
-
/* @__PURE__ */
|
|
15713
|
-
/* @__PURE__ */
|
|
15714
|
-
/* @__PURE__ */
|
|
15779
|
+
/* @__PURE__ */ jsx85("span", { css: dotStyle }),
|
|
15780
|
+
/* @__PURE__ */ jsx85("span", { css: dotStyle }),
|
|
15781
|
+
/* @__PURE__ */ jsx85("span", { css: dotStyle })
|
|
15715
15782
|
] });
|
|
15716
15783
|
};
|
|
15717
15784
|
|
|
15718
15785
|
// src/components/LoadingOverlay/LoadingOverlay.tsx
|
|
15719
|
-
import { useCallback as useCallback3, useEffect as
|
|
15786
|
+
import { useCallback as useCallback3, useEffect as useEffect10, useRef as useRef5 } from "react";
|
|
15720
15787
|
|
|
15721
15788
|
// src/components/LoadingOverlay/LoadingOverlay.styles.ts
|
|
15722
15789
|
import { css as css70 } from "@emotion/react";
|
|
@@ -15751,7 +15818,7 @@ var loadingOverlayMessage = css70`
|
|
|
15751
15818
|
`;
|
|
15752
15819
|
|
|
15753
15820
|
// src/components/LoadingOverlay/LoadingOverlay.tsx
|
|
15754
|
-
import { jsx as
|
|
15821
|
+
import { jsx as jsx86, jsxs as jsxs56 } from "@emotion/react/jsx-runtime";
|
|
15755
15822
|
var LoadingOverlay = ({
|
|
15756
15823
|
isActive,
|
|
15757
15824
|
statusMessage,
|
|
@@ -15769,7 +15836,7 @@ var LoadingOverlay = ({
|
|
|
15769
15836
|
(_c = lottieRef.current) == null ? void 0 : _c.stop();
|
|
15770
15837
|
}
|
|
15771
15838
|
}, [isPaused]);
|
|
15772
|
-
|
|
15839
|
+
useEffect10(() => {
|
|
15773
15840
|
var _a, _b, _c, _d, _e, _f;
|
|
15774
15841
|
if (!isPaused && ((_b = (_a = lottieRef.current) == null ? void 0 : _a.animationItem) == null ? void 0 : _b.isPaused)) {
|
|
15775
15842
|
(_c = lottieRef.current) == null ? void 0 : _c.play();
|
|
@@ -15785,9 +15852,9 @@ var LoadingOverlay = ({
|
|
|
15785
15852
|
"aria-hidden": !isActive,
|
|
15786
15853
|
"aria-busy": isActive && !isPaused,
|
|
15787
15854
|
children: [
|
|
15788
|
-
/* @__PURE__ */
|
|
15789
|
-
/* @__PURE__ */
|
|
15790
|
-
/* @__PURE__ */
|
|
15855
|
+
/* @__PURE__ */ jsx86("div", { css: loadingOverlayBackground(overlayBackgroundColor) }),
|
|
15856
|
+
/* @__PURE__ */ jsx86("div", { css: { position: "relative", maxWidth: "100%", margin: isTopAligned ? "0" : "auto" }, children: /* @__PURE__ */ jsxs56("div", { css: loadingOverlayBody, children: [
|
|
15857
|
+
/* @__PURE__ */ jsx86(
|
|
15791
15858
|
AnimationFile,
|
|
15792
15859
|
{
|
|
15793
15860
|
lottieRef,
|
|
@@ -15802,15 +15869,15 @@ var LoadingOverlay = ({
|
|
|
15802
15869
|
}
|
|
15803
15870
|
}
|
|
15804
15871
|
),
|
|
15805
|
-
statusMessage ? /* @__PURE__ */
|
|
15806
|
-
/* @__PURE__ */
|
|
15872
|
+
statusMessage ? /* @__PURE__ */ jsx86("div", { css: loadingOverlayMessage, children: statusMessage }) : null,
|
|
15873
|
+
/* @__PURE__ */ jsx86("div", { css: { width: "100%", marginTop: "var(--spacing-md)" }, children })
|
|
15807
15874
|
] }) })
|
|
15808
15875
|
]
|
|
15809
15876
|
}
|
|
15810
15877
|
);
|
|
15811
15878
|
};
|
|
15812
15879
|
var LoadingIcon = ({ height, width, ...props }) => {
|
|
15813
|
-
return /* @__PURE__ */
|
|
15880
|
+
return /* @__PURE__ */ jsx86(
|
|
15814
15881
|
"svg",
|
|
15815
15882
|
{
|
|
15816
15883
|
viewBox: "0 0 38 38",
|
|
@@ -15820,9 +15887,9 @@ var LoadingIcon = ({ height, width, ...props }) => {
|
|
|
15820
15887
|
stroke: "currentColor",
|
|
15821
15888
|
...props,
|
|
15822
15889
|
"data-testid": "loading-icon",
|
|
15823
|
-
children: /* @__PURE__ */
|
|
15824
|
-
/* @__PURE__ */
|
|
15825
|
-
/* @__PURE__ */
|
|
15890
|
+
children: /* @__PURE__ */ jsx86("g", { fill: "none", fillRule: "evenodd", children: /* @__PURE__ */ jsxs56("g", { transform: "translate(1 1)", strokeWidth: "2", children: [
|
|
15891
|
+
/* @__PURE__ */ jsx86("circle", { strokeOpacity: ".25", cx: "18", cy: "18", r: "18" }),
|
|
15892
|
+
/* @__PURE__ */ jsx86("path", { d: "M36 18c0-9.94-8.06-18-18-18", transform: "rotate(166.645 18 18)", children: /* @__PURE__ */ jsx86(
|
|
15826
15893
|
"animateTransform",
|
|
15827
15894
|
{
|
|
15828
15895
|
attributeName: "transform",
|
|
@@ -15878,7 +15945,7 @@ var Popover = css71`
|
|
|
15878
15945
|
`;
|
|
15879
15946
|
|
|
15880
15947
|
// src/components/Popover/Popover.tsx
|
|
15881
|
-
import { Fragment as Fragment14, jsx as
|
|
15948
|
+
import { Fragment as Fragment14, jsx as jsx87, jsxs as jsxs57 } from "@emotion/react/jsx-runtime";
|
|
15882
15949
|
var Popover2 = ({
|
|
15883
15950
|
iconColor = "action",
|
|
15884
15951
|
icon = "info",
|
|
@@ -15893,7 +15960,7 @@ var Popover2 = ({
|
|
|
15893
15960
|
}) => {
|
|
15894
15961
|
const popover = usePopoverState({ placement });
|
|
15895
15962
|
return /* @__PURE__ */ jsxs57(Fragment14, { children: [
|
|
15896
|
-
/* @__PURE__ */
|
|
15963
|
+
/* @__PURE__ */ jsx87(
|
|
15897
15964
|
PopoverDisclosure,
|
|
15898
15965
|
{
|
|
15899
15966
|
...popover,
|
|
@@ -15901,18 +15968,19 @@ var Popover2 = ({
|
|
|
15901
15968
|
title: buttonText,
|
|
15902
15969
|
"data-testid": testId,
|
|
15903
15970
|
children: trigger ? trigger : /* @__PURE__ */ jsxs57(Fragment14, { children: [
|
|
15904
|
-
/* @__PURE__ */
|
|
15905
|
-
/* @__PURE__ */
|
|
15971
|
+
/* @__PURE__ */ jsx87(Icon, { icon, iconColor, size: iconSize }),
|
|
15972
|
+
/* @__PURE__ */ jsx87("span", { hidden: true, children: buttonText })
|
|
15906
15973
|
] })
|
|
15907
15974
|
}
|
|
15908
15975
|
),
|
|
15909
|
-
/* @__PURE__ */
|
|
15976
|
+
/* @__PURE__ */ jsx87(ReakitPopover, { css: Popover, ...otherProps, ...popover, role: "tooltip", "aria-label": ariaLabel, children })
|
|
15910
15977
|
] });
|
|
15911
15978
|
};
|
|
15912
15979
|
|
|
15913
15980
|
// src/components/MediaCard/MediaCard.styles.ts
|
|
15914
15981
|
import { css as css72 } from "@emotion/react";
|
|
15915
15982
|
var cardBase = css72`
|
|
15983
|
+
--mediacard-title-color: var(--gray-500);
|
|
15916
15984
|
display: flex;
|
|
15917
15985
|
flex-direction: column;
|
|
15918
15986
|
justify-content: flex-start;
|
|
@@ -15922,6 +15990,10 @@ var cardBase = css72`
|
|
|
15922
15990
|
min-height: unset;
|
|
15923
15991
|
outline: none;
|
|
15924
15992
|
cursor: pointer;
|
|
15993
|
+
|
|
15994
|
+
&:hover {
|
|
15995
|
+
--mediacard-title-color: var(--brand-secondary-1);
|
|
15996
|
+
}
|
|
15925
15997
|
`;
|
|
15926
15998
|
var coverWrapper = css72`
|
|
15927
15999
|
position: relative;
|
|
@@ -15941,13 +16013,14 @@ var contentWrapper = css72`
|
|
|
15941
16013
|
`;
|
|
15942
16014
|
var title = css72`
|
|
15943
16015
|
font-size: var(--fs-sm);
|
|
15944
|
-
color: var(--
|
|
16016
|
+
color: var(--mediacard-title-color);
|
|
15945
16017
|
white-space: nowrap;
|
|
15946
16018
|
overflow: hidden;
|
|
15947
16019
|
text-overflow: ellipsis;
|
|
15948
16020
|
outline: none;
|
|
15949
16021
|
border: 0;
|
|
15950
16022
|
background-color: transparent;
|
|
16023
|
+
transition: color var(--duration-fast) var(--timing-ease-out);
|
|
15951
16024
|
|
|
15952
16025
|
&:focus-visible {
|
|
15953
16026
|
outline: 2px solid var(--primary-action-default);
|
|
@@ -15981,7 +16054,7 @@ var menuButton = css72`
|
|
|
15981
16054
|
`;
|
|
15982
16055
|
|
|
15983
16056
|
// src/components/MediaCard/MediaCard.tsx
|
|
15984
|
-
import { jsx as
|
|
16057
|
+
import { jsx as jsx88, jsxs as jsxs58 } from "@emotion/react/jsx-runtime";
|
|
15985
16058
|
var MediaCard = ({
|
|
15986
16059
|
title: title2,
|
|
15987
16060
|
subtitle: subtitle2,
|
|
@@ -15997,12 +16070,12 @@ var MediaCard = ({
|
|
|
15997
16070
|
}, []);
|
|
15998
16071
|
const hasMenuItems = Array.isArray(menuItems) ? menuItems.length > 0 : Boolean(menuItems);
|
|
15999
16072
|
return /* @__PURE__ */ jsxs58(Card, { css: cardBase, ...cardProps, onClick, children: [
|
|
16000
|
-
/* @__PURE__ */
|
|
16001
|
-
/* @__PURE__ */
|
|
16073
|
+
/* @__PURE__ */ jsx88("button", { tabIndex: -1, css: coverWrapper, children: cover }),
|
|
16074
|
+
/* @__PURE__ */ jsx88("div", { css: contentWrapper, children: /* @__PURE__ */ jsxs58(HorizontalRhythm, { gap: "sm", justify: "space-between", align: "center", css: { width: "100%" }, children: [
|
|
16002
16075
|
/* @__PURE__ */ jsxs58(VerticalRhythm, { gap: "0", align: "flex-start", css: { flex: 1, minWidth: 0 }, children: [
|
|
16003
16076
|
/* @__PURE__ */ jsxs58(HorizontalRhythm, { gap: "xs", align: "center", css: { maxWidth: "100%" }, children: [
|
|
16004
|
-
/* @__PURE__ */
|
|
16005
|
-
!infoPopover ? null : /* @__PURE__ */
|
|
16077
|
+
/* @__PURE__ */ jsx88("button", { css: title, "data-testid": "card-title", children: title2 }),
|
|
16078
|
+
!infoPopover ? null : /* @__PURE__ */ jsx88("div", { css: { display: "flex", cursor: "default" }, onClick: onStopPropogation, children: /* @__PURE__ */ jsx88(
|
|
16006
16079
|
Popover2,
|
|
16007
16080
|
{
|
|
16008
16081
|
baseId: `info-of-${title2}`,
|
|
@@ -16011,24 +16084,24 @@ var MediaCard = ({
|
|
|
16011
16084
|
iconColor: "default",
|
|
16012
16085
|
tabIndex: 0,
|
|
16013
16086
|
css: { display: "block" },
|
|
16014
|
-
children: /* @__PURE__ */
|
|
16087
|
+
children: /* @__PURE__ */ jsx88("div", { children: infoPopover })
|
|
16015
16088
|
}
|
|
16016
16089
|
) })
|
|
16017
16090
|
] }),
|
|
16018
|
-
subtitle2 ? /* @__PURE__ */
|
|
16091
|
+
subtitle2 ? /* @__PURE__ */ jsx88("button", { tabIndex: -1, css: subtitle, children: subtitle2 }) : null
|
|
16019
16092
|
] }),
|
|
16020
|
-
sideSection2 ? /* @__PURE__ */
|
|
16021
|
-
hasMenuItems ? /* @__PURE__ */
|
|
16093
|
+
sideSection2 ? /* @__PURE__ */ jsx88("div", { css: sideSection, onClick: onStopPropogation, children: sideSection2 }) : null,
|
|
16094
|
+
hasMenuItems ? /* @__PURE__ */ jsx88(
|
|
16022
16095
|
VerticalRhythm,
|
|
16023
16096
|
{
|
|
16024
16097
|
css: menuSection,
|
|
16025
16098
|
align: "center",
|
|
16026
16099
|
justify: "center",
|
|
16027
16100
|
onClick: onStopPropogation,
|
|
16028
|
-
children: /* @__PURE__ */
|
|
16101
|
+
children: /* @__PURE__ */ jsx88(
|
|
16029
16102
|
Menu,
|
|
16030
16103
|
{
|
|
16031
|
-
menuTrigger: /* @__PURE__ */
|
|
16104
|
+
menuTrigger: /* @__PURE__ */ jsx88("button", { type: "button", "aria-label": "More options", css: menuButton, children: /* @__PURE__ */ jsx88(Icon, { icon: "more-alt", iconColor: "gray", size: 16 }) }),
|
|
16032
16105
|
menuLabel: `Menu of ${title2}`,
|
|
16033
16106
|
children: menuItems
|
|
16034
16107
|
}
|
|
@@ -16089,6 +16162,7 @@ var modalCloseButtonStyles = css73`
|
|
|
16089
16162
|
margin-left: auto;
|
|
16090
16163
|
`;
|
|
16091
16164
|
var modalContentStyles = css73`
|
|
16165
|
+
position: relative;
|
|
16092
16166
|
flex: 1;
|
|
16093
16167
|
background-color: white;
|
|
16094
16168
|
padding: var(--spacing-md);
|
|
@@ -16097,7 +16171,7 @@ var modalContentStyles = css73`
|
|
|
16097
16171
|
`;
|
|
16098
16172
|
|
|
16099
16173
|
// src/components/Modal/Modal.tsx
|
|
16100
|
-
import { jsx as
|
|
16174
|
+
import { jsx as jsx89, jsxs as jsxs59 } from "@emotion/react/jsx-runtime";
|
|
16101
16175
|
var defaultModalWidth = "75rem";
|
|
16102
16176
|
var defaultModalHeight = "51rem";
|
|
16103
16177
|
var Modal = React19.forwardRef(
|
|
@@ -16117,31 +16191,111 @@ var Modal = React19.forwardRef(
|
|
|
16117
16191
|
shortcut: "escape"
|
|
16118
16192
|
});
|
|
16119
16193
|
return /* @__PURE__ */ jsxs59("div", { css: [modalWrapperStyles, wrapperClassName], children: [
|
|
16120
|
-
/* @__PURE__ */
|
|
16121
|
-
/* @__PURE__ */ jsxs59(
|
|
16122
|
-
|
|
16123
|
-
|
|
16124
|
-
|
|
16125
|
-
|
|
16126
|
-
|
|
16127
|
-
|
|
16128
|
-
|
|
16129
|
-
|
|
16130
|
-
|
|
16131
|
-
|
|
16132
|
-
|
|
16133
|
-
|
|
16134
|
-
|
|
16135
|
-
|
|
16136
|
-
|
|
16137
|
-
|
|
16138
|
-
|
|
16139
|
-
|
|
16194
|
+
/* @__PURE__ */ jsx89("div", { onClick: onRequestClose, css: modalBackdropStyles }),
|
|
16195
|
+
/* @__PURE__ */ jsxs59(
|
|
16196
|
+
"dialog",
|
|
16197
|
+
{
|
|
16198
|
+
ref,
|
|
16199
|
+
css: modalStyles,
|
|
16200
|
+
style: { width, height },
|
|
16201
|
+
"data-testid": "side-dialog",
|
|
16202
|
+
...modalProps,
|
|
16203
|
+
children: [
|
|
16204
|
+
/* @__PURE__ */ jsxs59("div", { css: modalHeaderStyles, children: [
|
|
16205
|
+
/* @__PURE__ */ jsx89("div", { children: header }),
|
|
16206
|
+
/* @__PURE__ */ jsx89(
|
|
16207
|
+
Button,
|
|
16208
|
+
{
|
|
16209
|
+
type: "button",
|
|
16210
|
+
onClick: onRequestClose,
|
|
16211
|
+
css: modalCloseButtonStyles,
|
|
16212
|
+
title: "Close dialog",
|
|
16213
|
+
buttonType: "ghost",
|
|
16214
|
+
"data-testid": "close-dialog",
|
|
16215
|
+
children: /* @__PURE__ */ jsx89(Icon, { icon: CgClose5, iconColor: "gray", size: 24 })
|
|
16216
|
+
}
|
|
16217
|
+
)
|
|
16218
|
+
] }),
|
|
16219
|
+
/* @__PURE__ */ jsx89("div", { css: [modalContentStyles, !withoutContentPadding ? null : { padding: 0 }], children }),
|
|
16220
|
+
buttonGroup ? /* @__PURE__ */ jsx89(HorizontalRhythm, { children: buttonGroup }) : null
|
|
16221
|
+
]
|
|
16222
|
+
}
|
|
16223
|
+
)
|
|
16140
16224
|
] });
|
|
16141
16225
|
}
|
|
16142
16226
|
);
|
|
16143
16227
|
Modal.displayName = "Modal";
|
|
16144
16228
|
|
|
16229
|
+
// src/components/Pagination/Pagination.tsx
|
|
16230
|
+
import Paginate from "react-paginate";
|
|
16231
|
+
|
|
16232
|
+
// src/components/Pagination/Pagniation.styles.ts
|
|
16233
|
+
import { css as css74 } from "@emotion/css";
|
|
16234
|
+
var container = css74`
|
|
16235
|
+
align-items: center;
|
|
16236
|
+
display: flex;
|
|
16237
|
+
`;
|
|
16238
|
+
var disabled = css74`
|
|
16239
|
+
opacity: var(--opacity-50);
|
|
16240
|
+
`;
|
|
16241
|
+
var disabledLink = css74`
|
|
16242
|
+
cursor: pointer-default;
|
|
16243
|
+
`;
|
|
16244
|
+
var pageLink = css74`
|
|
16245
|
+
display: block;
|
|
16246
|
+
padding: var(--spacing-sm) var(--spacing-base);
|
|
16247
|
+
`;
|
|
16248
|
+
var prevNextControls = css74`
|
|
16249
|
+
padding: var(--spacing-sm) var(--spacing-base);
|
|
16250
|
+
`;
|
|
16251
|
+
var active = css74`
|
|
16252
|
+
border-radius: var(--rounded-base);
|
|
16253
|
+
background: var(--gray-200);
|
|
16254
|
+
`;
|
|
16255
|
+
var page = css74`
|
|
16256
|
+
margin-left: var(--spacing-xs);
|
|
16257
|
+
margin-right: var(--spacing-xs);
|
|
16258
|
+
`;
|
|
16259
|
+
|
|
16260
|
+
// src/components/Pagination/Pagination.tsx
|
|
16261
|
+
import { jsx as jsx90 } from "@emotion/react/jsx-runtime";
|
|
16262
|
+
function Pagination({
|
|
16263
|
+
limit,
|
|
16264
|
+
offset,
|
|
16265
|
+
total,
|
|
16266
|
+
onPageChange
|
|
16267
|
+
}) {
|
|
16268
|
+
if (limit < 1) {
|
|
16269
|
+
return null;
|
|
16270
|
+
}
|
|
16271
|
+
const pageCount = Math.ceil(total / limit);
|
|
16272
|
+
const currentPage = Math.ceil(offset / limit);
|
|
16273
|
+
if (pageCount <= 1) {
|
|
16274
|
+
return null;
|
|
16275
|
+
}
|
|
16276
|
+
return /* @__PURE__ */ jsx90(
|
|
16277
|
+
Paginate,
|
|
16278
|
+
{
|
|
16279
|
+
forcePage: currentPage,
|
|
16280
|
+
previousLabel: /* @__PURE__ */ jsx90("div", { className: prevNextControls, children: "<" }),
|
|
16281
|
+
nextLabel: /* @__PURE__ */ jsx90("div", { className: prevNextControls, children: ">" }),
|
|
16282
|
+
breakLabel: "...",
|
|
16283
|
+
pageCount,
|
|
16284
|
+
marginPagesDisplayed: 2,
|
|
16285
|
+
pageRangeDisplayed: 5,
|
|
16286
|
+
onPageChange: ({ selected }) => {
|
|
16287
|
+
onPageChange(limit, selected * limit);
|
|
16288
|
+
},
|
|
16289
|
+
containerClassName: container,
|
|
16290
|
+
disabledClassName: disabled,
|
|
16291
|
+
disabledLinkClassName: disabledLink,
|
|
16292
|
+
pageLinkClassName: pageLink,
|
|
16293
|
+
activeClassName: active,
|
|
16294
|
+
pageClassName: page
|
|
16295
|
+
}
|
|
16296
|
+
);
|
|
16297
|
+
}
|
|
16298
|
+
|
|
16145
16299
|
// src/components/ParameterInputs/hooks/ParameterShellContext.tsx
|
|
16146
16300
|
import { createContext as createContext5, useContext as useContext6 } from "react";
|
|
16147
16301
|
var ParameterShellContext = createContext5({
|
|
@@ -16164,8 +16318,8 @@ var useParameterShell = () => {
|
|
|
16164
16318
|
};
|
|
16165
16319
|
|
|
16166
16320
|
// src/components/ParameterInputs/styles/LabelLeadingIcon.styles.ts
|
|
16167
|
-
import { css as
|
|
16168
|
-
var inputIconBtn =
|
|
16321
|
+
import { css as css75 } from "@emotion/react";
|
|
16322
|
+
var inputIconBtn = css75`
|
|
16169
16323
|
align-items: center;
|
|
16170
16324
|
border: none;
|
|
16171
16325
|
border-radius: var(--rounded-base);
|
|
@@ -16191,7 +16345,7 @@ var inputIconBtn = css74`
|
|
|
16191
16345
|
`;
|
|
16192
16346
|
|
|
16193
16347
|
// src/components/ParameterInputs/LabelLeadingIcon.tsx
|
|
16194
|
-
import { jsx as
|
|
16348
|
+
import { jsx as jsx91, jsxs as jsxs60 } from "@emotion/react/jsx-runtime";
|
|
16195
16349
|
var LabelLeadingIcon = ({
|
|
16196
16350
|
icon,
|
|
16197
16351
|
iconColor,
|
|
@@ -16203,7 +16357,7 @@ var LabelLeadingIcon = ({
|
|
|
16203
16357
|
...props
|
|
16204
16358
|
}) => {
|
|
16205
16359
|
const titleFr = title2 != null ? title2 : isLocked ? "Read-only pattern parameter" : isBound ? "Connected to external content. Click to edit" : "Click to connect to external content";
|
|
16206
|
-
return /* @__PURE__ */
|
|
16360
|
+
return /* @__PURE__ */ jsx91(Tooltip, { title: titleFr, children: /* @__PURE__ */ jsxs60(
|
|
16207
16361
|
"button",
|
|
16208
16362
|
{
|
|
16209
16363
|
css: inputIconBtn,
|
|
@@ -16212,7 +16366,7 @@ var LabelLeadingIcon = ({
|
|
|
16212
16366
|
"aria-disabled": isLocked,
|
|
16213
16367
|
...props,
|
|
16214
16368
|
children: [
|
|
16215
|
-
/* @__PURE__ */
|
|
16369
|
+
/* @__PURE__ */ jsx91(
|
|
16216
16370
|
Icon,
|
|
16217
16371
|
{
|
|
16218
16372
|
icon: isLocked ? "lock" : icon ? icon : "arrows-expand-down-right",
|
|
@@ -16228,8 +16382,8 @@ var LabelLeadingIcon = ({
|
|
|
16228
16382
|
var ConnectToDataElementButton = LabelLeadingIcon;
|
|
16229
16383
|
|
|
16230
16384
|
// src/components/ParameterInputs/styles/ParameterInput.styles.ts
|
|
16231
|
-
import { css as
|
|
16232
|
-
var inputContainer2 =
|
|
16385
|
+
import { css as css76 } from "@emotion/react";
|
|
16386
|
+
var inputContainer2 = css76`
|
|
16233
16387
|
position: relative;
|
|
16234
16388
|
scroll-margin: var(--spacing-2xl);
|
|
16235
16389
|
|
|
@@ -16242,14 +16396,14 @@ var inputContainer2 = css75`
|
|
|
16242
16396
|
}
|
|
16243
16397
|
}
|
|
16244
16398
|
`;
|
|
16245
|
-
var labelText2 =
|
|
16399
|
+
var labelText2 = css76`
|
|
16246
16400
|
align-items: center;
|
|
16247
16401
|
display: flex;
|
|
16248
16402
|
gap: var(--spacing-xs);
|
|
16249
16403
|
font-weight: var(--fw-regular);
|
|
16250
16404
|
margin: 0 0 var(--spacing-xs);
|
|
16251
16405
|
`;
|
|
16252
|
-
var input2 =
|
|
16406
|
+
var input2 = css76`
|
|
16253
16407
|
display: block;
|
|
16254
16408
|
appearance: none;
|
|
16255
16409
|
box-sizing: border-box;
|
|
@@ -16293,18 +16447,18 @@ var input2 = css75`
|
|
|
16293
16447
|
color: var(--gray-400);
|
|
16294
16448
|
}
|
|
16295
16449
|
`;
|
|
16296
|
-
var selectInput =
|
|
16450
|
+
var selectInput = css76`
|
|
16297
16451
|
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");
|
|
16298
16452
|
background-position: right var(--spacing-sm) center;
|
|
16299
16453
|
background-repeat: no-repeat;
|
|
16300
16454
|
background-size: 1rem;
|
|
16301
16455
|
padding-right: var(--spacing-xl);
|
|
16302
16456
|
`;
|
|
16303
|
-
var inputWrapper =
|
|
16457
|
+
var inputWrapper = css76`
|
|
16304
16458
|
display: flex; // used to correct overflow with chrome textarea
|
|
16305
16459
|
position: relative;
|
|
16306
16460
|
`;
|
|
16307
|
-
var inputIcon2 =
|
|
16461
|
+
var inputIcon2 = css76`
|
|
16308
16462
|
align-items: center;
|
|
16309
16463
|
background: var(--white);
|
|
16310
16464
|
border-radius: var(--rounded-md) 0 0 var(--rounded-md);
|
|
@@ -16320,7 +16474,7 @@ var inputIcon2 = css75`
|
|
|
16320
16474
|
width: var(--spacing-lg);
|
|
16321
16475
|
z-index: var(--z-10);
|
|
16322
16476
|
`;
|
|
16323
|
-
var inputToggleLabel2 =
|
|
16477
|
+
var inputToggleLabel2 = css76`
|
|
16324
16478
|
align-items: center;
|
|
16325
16479
|
background: var(--white);
|
|
16326
16480
|
cursor: pointer;
|
|
@@ -16331,7 +16485,7 @@ var inputToggleLabel2 = css75`
|
|
|
16331
16485
|
min-height: var(--spacing-md);
|
|
16332
16486
|
position: relative;
|
|
16333
16487
|
`;
|
|
16334
|
-
var toggleInput2 =
|
|
16488
|
+
var toggleInput2 = css76`
|
|
16335
16489
|
appearance: none;
|
|
16336
16490
|
border: 1px solid var(--gray-300);
|
|
16337
16491
|
background: var(--white);
|
|
@@ -16370,7 +16524,7 @@ var toggleInput2 = css75`
|
|
|
16370
16524
|
border-color: var(--gray-300);
|
|
16371
16525
|
}
|
|
16372
16526
|
`;
|
|
16373
|
-
var inlineLabel2 =
|
|
16527
|
+
var inlineLabel2 = css76`
|
|
16374
16528
|
padding-left: var(--spacing-lg);
|
|
16375
16529
|
font-size: var(--fs-sm);
|
|
16376
16530
|
font-weight: var(--fw-regular);
|
|
@@ -16386,7 +16540,7 @@ var inlineLabel2 = css75`
|
|
|
16386
16540
|
}
|
|
16387
16541
|
}
|
|
16388
16542
|
`;
|
|
16389
|
-
var inputMenu =
|
|
16543
|
+
var inputMenu = css76`
|
|
16390
16544
|
background: none;
|
|
16391
16545
|
border: none;
|
|
16392
16546
|
padding: var(--spacing-2xs);
|
|
@@ -16402,11 +16556,11 @@ var inputMenu = css75`
|
|
|
16402
16556
|
background-color: var(--gray-200);
|
|
16403
16557
|
}
|
|
16404
16558
|
`;
|
|
16405
|
-
var textarea2 =
|
|
16559
|
+
var textarea2 = css76`
|
|
16406
16560
|
resize: vertical;
|
|
16407
16561
|
min-height: 2rem;
|
|
16408
16562
|
`;
|
|
16409
|
-
var dataConnectButton =
|
|
16563
|
+
var dataConnectButton = css76`
|
|
16410
16564
|
align-items: center;
|
|
16411
16565
|
appearance: none;
|
|
16412
16566
|
box-sizing: border-box;
|
|
@@ -16441,7 +16595,7 @@ var dataConnectButton = css75`
|
|
|
16441
16595
|
pointer-events: none;
|
|
16442
16596
|
}
|
|
16443
16597
|
`;
|
|
16444
|
-
var linkParameterBtn =
|
|
16598
|
+
var linkParameterBtn = css76`
|
|
16445
16599
|
border-radius: var(--rounded-base);
|
|
16446
16600
|
background: var(--white);
|
|
16447
16601
|
border: none;
|
|
@@ -16450,7 +16604,7 @@ var linkParameterBtn = css75`
|
|
|
16450
16604
|
font-size: var(--fs-sm);
|
|
16451
16605
|
line-height: 1;
|
|
16452
16606
|
`;
|
|
16453
|
-
var linkParameterControls =
|
|
16607
|
+
var linkParameterControls = css76`
|
|
16454
16608
|
position: absolute;
|
|
16455
16609
|
inset: 0 0 0 auto;
|
|
16456
16610
|
padding: 0 var(--spacing-base);
|
|
@@ -16459,7 +16613,7 @@ var linkParameterControls = css75`
|
|
|
16459
16613
|
justify-content: center;
|
|
16460
16614
|
gap: var(--spacing-base);
|
|
16461
16615
|
`;
|
|
16462
|
-
var linkParameterInput = (withExternalLinkIcon) =>
|
|
16616
|
+
var linkParameterInput = (withExternalLinkIcon) => css76`
|
|
16463
16617
|
padding-right: calc(
|
|
16464
16618
|
${withExternalLinkIcon ? "calc(var(--spacing-lg) * 2 + var(--spacing-xs))" : "var(--spacing-xl)"} +
|
|
16465
16619
|
var(--spacing-base)
|
|
@@ -16472,7 +16626,7 @@ var linkParameterInput = (withExternalLinkIcon) => css75`
|
|
|
16472
16626
|
}
|
|
16473
16627
|
}
|
|
16474
16628
|
`;
|
|
16475
|
-
var linkParameterIcon =
|
|
16629
|
+
var linkParameterIcon = css76`
|
|
16476
16630
|
align-items: center;
|
|
16477
16631
|
color: var(--brand-secondary-3);
|
|
16478
16632
|
display: flex;
|
|
@@ -16487,14 +16641,14 @@ var linkParameterIcon = css75`
|
|
|
16487
16641
|
`;
|
|
16488
16642
|
|
|
16489
16643
|
// src/components/ParameterInputs/ParameterDataResource.tsx
|
|
16490
|
-
import { jsx as
|
|
16644
|
+
import { jsx as jsx92, jsxs as jsxs61 } from "@emotion/react/jsx-runtime";
|
|
16491
16645
|
function ParameterDataResource({
|
|
16492
16646
|
label,
|
|
16493
16647
|
labelLeadingIcon,
|
|
16494
16648
|
id,
|
|
16495
16649
|
onConnectDatasource,
|
|
16496
16650
|
caption,
|
|
16497
|
-
disabled,
|
|
16651
|
+
disabled: disabled2,
|
|
16498
16652
|
children
|
|
16499
16653
|
}) {
|
|
16500
16654
|
return /* @__PURE__ */ jsxs61("div", { "data-testid": "parameter-data-connect-button", children: [
|
|
@@ -16508,33 +16662,33 @@ function ParameterDataResource({
|
|
|
16508
16662
|
type: "button",
|
|
16509
16663
|
css: dataConnectButton,
|
|
16510
16664
|
"aria-controls": id,
|
|
16511
|
-
disabled,
|
|
16665
|
+
disabled: disabled2,
|
|
16512
16666
|
onClick: onConnectDatasource,
|
|
16513
16667
|
children: [
|
|
16514
|
-
/* @__PURE__ */
|
|
16668
|
+
/* @__PURE__ */ jsx92("span", { className: "advance-input-icon", css: [inputIcon2], children: /* @__PURE__ */ jsx92(Icon, { icon: "stack", iconColor: "currentColor", size: "1rem" }) }),
|
|
16515
16669
|
children
|
|
16516
16670
|
]
|
|
16517
16671
|
}
|
|
16518
16672
|
),
|
|
16519
|
-
caption ? /* @__PURE__ */
|
|
16673
|
+
caption ? /* @__PURE__ */ jsx92(Caption, { children: caption }) : null
|
|
16520
16674
|
] });
|
|
16521
16675
|
}
|
|
16522
16676
|
|
|
16523
16677
|
// src/components/ParameterInputs/styles/ParameterDrawerHeader.styles.ts
|
|
16524
|
-
import { css as
|
|
16525
|
-
var ParameterDrawerHeaderContainer =
|
|
16678
|
+
import { css as css77 } from "@emotion/react";
|
|
16679
|
+
var ParameterDrawerHeaderContainer = css77`
|
|
16526
16680
|
align-items: center;
|
|
16527
16681
|
display: flex;
|
|
16528
16682
|
gap: var(--spacing-base);
|
|
16529
16683
|
justify-content: space-between;
|
|
16530
16684
|
margin-bottom: var(--spacing-sm);
|
|
16531
16685
|
`;
|
|
16532
|
-
var ParameterDrawerHeaderTitleGroup =
|
|
16686
|
+
var ParameterDrawerHeaderTitleGroup = css77`
|
|
16533
16687
|
align-items: center;
|
|
16534
16688
|
display: flex;
|
|
16535
16689
|
gap: var(--spacing-sm);
|
|
16536
16690
|
`;
|
|
16537
|
-
var ParameterDrawerHeaderTitle =
|
|
16691
|
+
var ParameterDrawerHeaderTitle = css77`
|
|
16538
16692
|
text-overflow: ellipsis;
|
|
16539
16693
|
white-space: nowrap;
|
|
16540
16694
|
overflow: hidden;
|
|
@@ -16542,12 +16696,12 @@ var ParameterDrawerHeaderTitle = css76`
|
|
|
16542
16696
|
`;
|
|
16543
16697
|
|
|
16544
16698
|
// src/components/ParameterInputs/ParameterDrawerHeader.tsx
|
|
16545
|
-
import { jsx as
|
|
16699
|
+
import { jsx as jsx93, jsxs as jsxs62 } from "@emotion/react/jsx-runtime";
|
|
16546
16700
|
var ParameterDrawerHeader = ({ title: title2, iconBeforeTitle, children }) => {
|
|
16547
16701
|
return /* @__PURE__ */ jsxs62("div", { css: ParameterDrawerHeaderContainer, children: [
|
|
16548
16702
|
/* @__PURE__ */ jsxs62("header", { css: ParameterDrawerHeaderTitleGroup, children: [
|
|
16549
16703
|
iconBeforeTitle,
|
|
16550
|
-
/* @__PURE__ */
|
|
16704
|
+
/* @__PURE__ */ jsx93(Heading, { level: 3, withMarginBottom: false, css: ParameterDrawerHeaderTitle, title: title2, children: title2 })
|
|
16551
16705
|
] }),
|
|
16552
16706
|
children
|
|
16553
16707
|
] });
|
|
@@ -16557,8 +16711,8 @@ var ParameterDrawerHeader = ({ title: title2, iconBeforeTitle, children }) => {
|
|
|
16557
16711
|
import { forwardRef as forwardRef10 } from "react";
|
|
16558
16712
|
|
|
16559
16713
|
// src/components/ParameterInputs/styles/ParameterGroup.styles.ts
|
|
16560
|
-
import { css as
|
|
16561
|
-
var fieldsetStyles =
|
|
16714
|
+
import { css as css78 } from "@emotion/react";
|
|
16715
|
+
var fieldsetStyles = css78`
|
|
16562
16716
|
&:disabled,
|
|
16563
16717
|
[readonly] {
|
|
16564
16718
|
pointer-events: none;
|
|
@@ -16569,7 +16723,7 @@ var fieldsetStyles = css77`
|
|
|
16569
16723
|
}
|
|
16570
16724
|
}
|
|
16571
16725
|
`;
|
|
16572
|
-
var fieldsetLegend2 =
|
|
16726
|
+
var fieldsetLegend2 = css78`
|
|
16573
16727
|
display: block;
|
|
16574
16728
|
font-weight: var(--fw-medium);
|
|
16575
16729
|
margin-bottom: var(--spacing-sm);
|
|
@@ -16577,11 +16731,11 @@ var fieldsetLegend2 = css77`
|
|
|
16577
16731
|
`;
|
|
16578
16732
|
|
|
16579
16733
|
// src/components/ParameterInputs/ParameterGroup.tsx
|
|
16580
|
-
import { jsx as
|
|
16734
|
+
import { jsx as jsx94, jsxs as jsxs63 } from "@emotion/react/jsx-runtime";
|
|
16581
16735
|
var ParameterGroup = forwardRef10(
|
|
16582
16736
|
({ legend, isDisabled, children, ...props }, ref) => {
|
|
16583
16737
|
return /* @__PURE__ */ jsxs63("fieldset", { css: fieldsetStyles, disabled: isDisabled, ref, ...props, children: [
|
|
16584
|
-
/* @__PURE__ */
|
|
16738
|
+
/* @__PURE__ */ jsx94("legend", { css: fieldsetLegend2, children: legend }),
|
|
16585
16739
|
children
|
|
16586
16740
|
] });
|
|
16587
16741
|
}
|
|
@@ -16595,15 +16749,15 @@ import { useState as useState10 } from "react";
|
|
|
16595
16749
|
import { createPortal as createPortal2 } from "react-dom";
|
|
16596
16750
|
|
|
16597
16751
|
// src/components/ParameterInputs/styles/ParameterImage.styles.ts
|
|
16598
|
-
import { css as
|
|
16599
|
-
var previewWrapper =
|
|
16752
|
+
import { css as css79 } from "@emotion/react";
|
|
16753
|
+
var previewWrapper = css79`
|
|
16600
16754
|
margin-top: var(--spacing-xs);
|
|
16601
16755
|
background: var(--gray-50);
|
|
16602
16756
|
padding: var(--spacing-sm);
|
|
16603
16757
|
border: solid 1px var(--gray-300);
|
|
16604
16758
|
border-radius: var(--rounded-sm);
|
|
16605
16759
|
`;
|
|
16606
|
-
var previewLink =
|
|
16760
|
+
var previewLink = css79`
|
|
16607
16761
|
display: block;
|
|
16608
16762
|
width: 100%;
|
|
16609
16763
|
|
|
@@ -16611,7 +16765,7 @@ var previewLink = css78`
|
|
|
16611
16765
|
max-height: 9rem;
|
|
16612
16766
|
}
|
|
16613
16767
|
`;
|
|
16614
|
-
var previewModalWrapper =
|
|
16768
|
+
var previewModalWrapper = css79`
|
|
16615
16769
|
background: var(--gray-50);
|
|
16616
16770
|
display: flex;
|
|
16617
16771
|
height: 100%;
|
|
@@ -16620,7 +16774,7 @@ var previewModalWrapper = css78`
|
|
|
16620
16774
|
border: solid 1px var(--gray-300);
|
|
16621
16775
|
border-radius: var(--rounded-sm);
|
|
16622
16776
|
`;
|
|
16623
|
-
var previewModalImage =
|
|
16777
|
+
var previewModalImage = css79`
|
|
16624
16778
|
display: flex;
|
|
16625
16779
|
height: 100%;
|
|
16626
16780
|
width: 100%;
|
|
@@ -16632,33 +16786,33 @@ var previewModalImage = css78`
|
|
|
16632
16786
|
`;
|
|
16633
16787
|
|
|
16634
16788
|
// src/components/ParameterInputs/ParameterImagePreview.tsx
|
|
16635
|
-
import { Fragment as Fragment15, jsx as
|
|
16789
|
+
import { Fragment as Fragment15, jsx as jsx95, jsxs as jsxs64 } from "@emotion/react/jsx-runtime";
|
|
16636
16790
|
function ParameterImagePreview({ imageSrc }) {
|
|
16637
16791
|
const [showModal, setShowModal] = useState10(false);
|
|
16638
16792
|
return imageSrc ? /* @__PURE__ */ jsxs64("div", { css: previewWrapper, children: [
|
|
16639
|
-
/* @__PURE__ */
|
|
16640
|
-
/* @__PURE__ */
|
|
16793
|
+
/* @__PURE__ */ jsx95(PreviewImageModal, { open: showModal, imageSrc, onRequestClose: () => setShowModal(false) }),
|
|
16794
|
+
/* @__PURE__ */ jsx95(
|
|
16641
16795
|
"button",
|
|
16642
16796
|
{
|
|
16643
16797
|
css: previewLink,
|
|
16644
16798
|
onClick: () => {
|
|
16645
16799
|
setShowModal(true);
|
|
16646
16800
|
},
|
|
16647
|
-
children: /* @__PURE__ */
|
|
16801
|
+
children: /* @__PURE__ */ jsx95(Image, { src: imageSrc, "data-testid": "parameter-image-preview" })
|
|
16648
16802
|
}
|
|
16649
16803
|
)
|
|
16650
16804
|
] }) : null;
|
|
16651
16805
|
}
|
|
16652
16806
|
var PreviewImageModal = ({ open, onRequestClose, imageSrc }) => {
|
|
16653
|
-
return open ? /* @__PURE__ */
|
|
16654
|
-
/* @__PURE__ */
|
|
16807
|
+
return open ? /* @__PURE__ */ jsx95(Fragment15, { children: createPortal2(
|
|
16808
|
+
/* @__PURE__ */ jsx95(
|
|
16655
16809
|
Modal,
|
|
16656
16810
|
{
|
|
16657
16811
|
header: "Image Preview",
|
|
16658
16812
|
onRequestClose,
|
|
16659
16813
|
withoutContentPadding: true,
|
|
16660
|
-
buttonGroup: /* @__PURE__ */
|
|
16661
|
-
children: /* @__PURE__ */
|
|
16814
|
+
buttonGroup: /* @__PURE__ */ jsx95(Button, { buttonType: "secondary", onClick: onRequestClose, children: "Ok" }),
|
|
16815
|
+
children: /* @__PURE__ */ jsx95("div", { css: previewModalWrapper, children: /* @__PURE__ */ jsx95(Image, { src: imageSrc, css: previewModalImage, "data-testid": "parameter-image-preview" }) })
|
|
16662
16816
|
}
|
|
16663
16817
|
),
|
|
16664
16818
|
document.body
|
|
@@ -16666,25 +16820,25 @@ var PreviewImageModal = ({ open, onRequestClose, imageSrc }) => {
|
|
|
16666
16820
|
};
|
|
16667
16821
|
|
|
16668
16822
|
// src/components/ParameterInputs/ParameterShell.tsx
|
|
16669
|
-
import { css as
|
|
16823
|
+
import { css as css81 } from "@emotion/react";
|
|
16670
16824
|
import { useState as useState11 } from "react";
|
|
16671
16825
|
|
|
16672
16826
|
// src/components/ParameterInputs/ParameterLabel.tsx
|
|
16673
|
-
import { jsx as
|
|
16827
|
+
import { jsx as jsx96 } from "@emotion/react/jsx-runtime";
|
|
16674
16828
|
var ParameterLabel = ({ id, asSpan, children, ...props }) => {
|
|
16675
|
-
return !asSpan ? /* @__PURE__ */
|
|
16829
|
+
return !asSpan ? /* @__PURE__ */ jsx96("label", { ...props, htmlFor: id, css: labelText2, children }) : /* @__PURE__ */ jsx96("span", { "aria-labelledby": id, css: labelText2, children });
|
|
16676
16830
|
};
|
|
16677
16831
|
|
|
16678
16832
|
// src/components/ParameterInputs/ParameterMenuButton.tsx
|
|
16679
16833
|
import { forwardRef as forwardRef11 } from "react";
|
|
16680
|
-
import { jsx as
|
|
16834
|
+
import { jsx as jsx97 } from "@emotion/react/jsx-runtime";
|
|
16681
16835
|
var ParameterMenuButton = forwardRef11(
|
|
16682
16836
|
({ label, children }, ref) => {
|
|
16683
|
-
return /* @__PURE__ */
|
|
16837
|
+
return /* @__PURE__ */ jsx97(
|
|
16684
16838
|
Menu,
|
|
16685
16839
|
{
|
|
16686
16840
|
menuLabel: `${label} menu`,
|
|
16687
|
-
menuTrigger: /* @__PURE__ */
|
|
16841
|
+
menuTrigger: /* @__PURE__ */ jsx97(
|
|
16688
16842
|
"button",
|
|
16689
16843
|
{
|
|
16690
16844
|
className: "parameter-menu",
|
|
@@ -16692,7 +16846,7 @@ var ParameterMenuButton = forwardRef11(
|
|
|
16692
16846
|
type: "button",
|
|
16693
16847
|
"aria-label": `${label} options`,
|
|
16694
16848
|
ref,
|
|
16695
|
-
children: /* @__PURE__ */
|
|
16849
|
+
children: /* @__PURE__ */ jsx97(Icon, { icon: "more-alt", iconColor: "currentColor", size: "0.9rem" })
|
|
16696
16850
|
}
|
|
16697
16851
|
),
|
|
16698
16852
|
children
|
|
@@ -16702,8 +16856,8 @@ var ParameterMenuButton = forwardRef11(
|
|
|
16702
16856
|
);
|
|
16703
16857
|
|
|
16704
16858
|
// src/components/ParameterInputs/styles/ParameterShell.styles.ts
|
|
16705
|
-
import { css as
|
|
16706
|
-
var emptyParameterShell =
|
|
16859
|
+
import { css as css80 } from "@emotion/react";
|
|
16860
|
+
var emptyParameterShell = css80`
|
|
16707
16861
|
border-radius: var(--rounded-sm);
|
|
16708
16862
|
background: var(--white);
|
|
16709
16863
|
flex-grow: 1;
|
|
@@ -16711,7 +16865,7 @@ var emptyParameterShell = css79`
|
|
|
16711
16865
|
position: relative;
|
|
16712
16866
|
max-width: 100%;
|
|
16713
16867
|
`;
|
|
16714
|
-
var emptyParameterShellText =
|
|
16868
|
+
var emptyParameterShellText = css80`
|
|
16715
16869
|
background: var(--brand-secondary-6);
|
|
16716
16870
|
border-radius: var(--rounded-sm);
|
|
16717
16871
|
padding: var(--spacing-sm);
|
|
@@ -16719,7 +16873,7 @@ var emptyParameterShellText = css79`
|
|
|
16719
16873
|
font-size: var(--fs-sm);
|
|
16720
16874
|
margin: 0;
|
|
16721
16875
|
`;
|
|
16722
|
-
var overrideMarker =
|
|
16876
|
+
var overrideMarker = css80`
|
|
16723
16877
|
border-radius: var(--rounded-sm);
|
|
16724
16878
|
border: 10px solid var(--gray-300);
|
|
16725
16879
|
border-left-color: transparent;
|
|
@@ -16730,7 +16884,7 @@ var overrideMarker = css79`
|
|
|
16730
16884
|
`;
|
|
16731
16885
|
|
|
16732
16886
|
// src/components/ParameterInputs/ParameterShell.tsx
|
|
16733
|
-
import { jsx as
|
|
16887
|
+
import { jsx as jsx98, jsxs as jsxs65 } from "@emotion/react/jsx-runtime";
|
|
16734
16888
|
var extractParameterProps = (props) => {
|
|
16735
16889
|
const {
|
|
16736
16890
|
id,
|
|
@@ -16804,23 +16958,23 @@ var ParameterShell = ({
|
|
|
16804
16958
|
labelTrailingIcon != null ? labelTrailingIcon : null
|
|
16805
16959
|
] }),
|
|
16806
16960
|
/* @__PURE__ */ jsxs65("div", { css: inputWrapper, children: [
|
|
16807
|
-
actionItems ? /* @__PURE__ */
|
|
16961
|
+
actionItems ? /* @__PURE__ */ jsx98(
|
|
16808
16962
|
"div",
|
|
16809
16963
|
{
|
|
16810
16964
|
css: [
|
|
16811
16965
|
inputMenu,
|
|
16812
|
-
|
|
16966
|
+
css81`
|
|
16813
16967
|
opacity: var(--opacity-100);
|
|
16814
16968
|
`,
|
|
16815
|
-
menuItems ?
|
|
16969
|
+
menuItems ? css81`
|
|
16816
16970
|
right: var(--spacing-md);
|
|
16817
16971
|
` : void 0
|
|
16818
16972
|
],
|
|
16819
16973
|
children: actionItems
|
|
16820
16974
|
}
|
|
16821
16975
|
) : null,
|
|
16822
|
-
menuItems ? /* @__PURE__ */
|
|
16823
|
-
/* @__PURE__ */
|
|
16976
|
+
menuItems ? /* @__PURE__ */ jsx98(ParameterMenuButton, { label: `${label} menu`, children: menuItems }) : null,
|
|
16977
|
+
/* @__PURE__ */ jsx98(
|
|
16824
16978
|
ParameterShellContext.Provider,
|
|
16825
16979
|
{
|
|
16826
16980
|
value: {
|
|
@@ -16832,29 +16986,29 @@ var ParameterShell = ({
|
|
|
16832
16986
|
},
|
|
16833
16987
|
children: /* @__PURE__ */ jsxs65(ParameterShellPlaceholder, { children: [
|
|
16834
16988
|
children,
|
|
16835
|
-
hasOverriddenValue && onResetOverriddenValue ? /* @__PURE__ */
|
|
16989
|
+
hasOverriddenValue && onResetOverriddenValue ? /* @__PURE__ */ jsx98(ParameterOverrideMarker, { onClick: onResetOverriddenValue }) : null
|
|
16836
16990
|
] })
|
|
16837
16991
|
}
|
|
16838
16992
|
)
|
|
16839
16993
|
] }),
|
|
16840
|
-
caption ? /* @__PURE__ */
|
|
16841
|
-
errorMessaging ? /* @__PURE__ */
|
|
16842
|
-
warningMessage ? /* @__PURE__ */
|
|
16843
|
-
infoMessage ? /* @__PURE__ */
|
|
16994
|
+
caption ? /* @__PURE__ */ jsx98(Caption, { testId: captionTestId, children: caption }) : null,
|
|
16995
|
+
errorMessaging ? /* @__PURE__ */ jsx98(ErrorMessage, { message: errorMessaging, testId: errorTestId }) : null,
|
|
16996
|
+
warningMessage ? /* @__PURE__ */ jsx98(WarningMessage, { message: warningMessage }) : null,
|
|
16997
|
+
infoMessage ? /* @__PURE__ */ jsx98(InfoMessage, { message: infoMessage }) : null
|
|
16844
16998
|
] });
|
|
16845
16999
|
};
|
|
16846
17000
|
var ParameterShellPlaceholder = ({ children }) => {
|
|
16847
|
-
return /* @__PURE__ */
|
|
17001
|
+
return /* @__PURE__ */ jsx98("div", { css: emptyParameterShell, children });
|
|
16848
17002
|
};
|
|
16849
|
-
var ParameterOverrideMarker = (props) => /* @__PURE__ */
|
|
17003
|
+
var ParameterOverrideMarker = (props) => /* @__PURE__ */ jsx98(Tooltip, { title: "The default value has been overridden", children: /* @__PURE__ */ jsx98("button", { type: "button", css: overrideMarker, ...props, children: /* @__PURE__ */ jsx98("span", { hidden: true, children: "reset overridden value to default" }) }) });
|
|
16850
17004
|
|
|
16851
17005
|
// src/components/ParameterInputs/ParameterImage.tsx
|
|
16852
|
-
import { Fragment as Fragment16, jsx as
|
|
17006
|
+
import { Fragment as Fragment16, jsx as jsx99, jsxs as jsxs66 } from "@emotion/react/jsx-runtime";
|
|
16853
17007
|
var ParameterImage = forwardRef12(
|
|
16854
17008
|
({ children, ...props }, ref) => {
|
|
16855
17009
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
16856
17010
|
return /* @__PURE__ */ jsxs66(ParameterShell, { "data-test-id": "parameter-image", ...shellProps, children: [
|
|
16857
|
-
/* @__PURE__ */
|
|
17011
|
+
/* @__PURE__ */ jsx99(ParameterImageInner, { ref, ...innerProps }),
|
|
16858
17012
|
children
|
|
16859
17013
|
] });
|
|
16860
17014
|
}
|
|
@@ -16864,7 +17018,7 @@ var ParameterImageInner = forwardRef12((props, ref) => {
|
|
|
16864
17018
|
const { id, label, hiddenLabel, errorMessage } = useParameterShell();
|
|
16865
17019
|
const deferredValue = useDeferredValue(value);
|
|
16866
17020
|
return /* @__PURE__ */ jsxs66(Fragment16, { children: [
|
|
16867
|
-
/* @__PURE__ */
|
|
17021
|
+
/* @__PURE__ */ jsx99(
|
|
16868
17022
|
"input",
|
|
16869
17023
|
{
|
|
16870
17024
|
css: input2,
|
|
@@ -16876,21 +17030,21 @@ var ParameterImageInner = forwardRef12((props, ref) => {
|
|
|
16876
17030
|
...props
|
|
16877
17031
|
}
|
|
16878
17032
|
),
|
|
16879
|
-
errorMessage || props.disablePreview ? null : /* @__PURE__ */
|
|
17033
|
+
errorMessage || props.disablePreview ? null : /* @__PURE__ */ jsx99(ParameterImagePreview, { imageSrc: deferredValue })
|
|
16880
17034
|
] });
|
|
16881
17035
|
});
|
|
16882
17036
|
|
|
16883
17037
|
// src/components/ParameterInputs/ParameterInput.tsx
|
|
16884
17038
|
import { forwardRef as forwardRef13 } from "react";
|
|
16885
|
-
import { jsx as
|
|
17039
|
+
import { jsx as jsx100 } from "@emotion/react/jsx-runtime";
|
|
16886
17040
|
var ParameterInput = forwardRef13((props, ref) => {
|
|
16887
17041
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
16888
|
-
return /* @__PURE__ */
|
|
17042
|
+
return /* @__PURE__ */ jsx100(ParameterShell, { "data-testid": "parameter-input", ...shellProps, children: /* @__PURE__ */ jsx100(ParameterInputInner, { ref, ...innerProps }) });
|
|
16889
17043
|
});
|
|
16890
17044
|
var ParameterInputInner = forwardRef13(
|
|
16891
17045
|
({ ...props }, ref) => {
|
|
16892
17046
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
16893
|
-
return /* @__PURE__ */
|
|
17047
|
+
return /* @__PURE__ */ jsx100(
|
|
16894
17048
|
"input",
|
|
16895
17049
|
{
|
|
16896
17050
|
css: input2,
|
|
@@ -16907,18 +17061,18 @@ var ParameterInputInner = forwardRef13(
|
|
|
16907
17061
|
|
|
16908
17062
|
// src/components/ParameterInputs/ParameterLink.tsx
|
|
16909
17063
|
import { forwardRef as forwardRef14 } from "react";
|
|
16910
|
-
import { jsx as
|
|
17064
|
+
import { jsx as jsx101, jsxs as jsxs67 } from "@emotion/react/jsx-runtime";
|
|
16911
17065
|
var ParameterLink = forwardRef14(
|
|
16912
|
-
({ disabled, onConnectLink, externalLink, ...props }, ref) => {
|
|
17066
|
+
({ disabled: disabled2, onConnectLink, externalLink, ...props }, ref) => {
|
|
16913
17067
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
16914
|
-
return /* @__PURE__ */
|
|
17068
|
+
return /* @__PURE__ */ jsx101(
|
|
16915
17069
|
ParameterShell,
|
|
16916
17070
|
{
|
|
16917
17071
|
"data-testid": "link-parameter-editor",
|
|
16918
17072
|
...shellProps,
|
|
16919
17073
|
label: innerProps.value ? shellProps.label : "",
|
|
16920
17074
|
title: !innerProps.value ? shellProps.label : void 0,
|
|
16921
|
-
children: /* @__PURE__ */
|
|
17075
|
+
children: /* @__PURE__ */ jsx101(
|
|
16922
17076
|
ParameterLinkInner,
|
|
16923
17077
|
{
|
|
16924
17078
|
onConnectLink,
|
|
@@ -16932,12 +17086,12 @@ var ParameterLink = forwardRef14(
|
|
|
16932
17086
|
}
|
|
16933
17087
|
);
|
|
16934
17088
|
var ParameterLinkInner = forwardRef14(
|
|
16935
|
-
({ externalLink, onConnectLink, disabled, buttonText = "Select link", ...props }, ref) => {
|
|
17089
|
+
({ externalLink, onConnectLink, disabled: disabled2, buttonText = "Select link", ...props }, ref) => {
|
|
16936
17090
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
16937
17091
|
if (!props.value)
|
|
16938
|
-
return /* @__PURE__ */
|
|
17092
|
+
return /* @__PURE__ */ jsx101("button", { type: "button", css: dataConnectButton, disabled: disabled2, onClick: onConnectLink, children: buttonText });
|
|
16939
17093
|
return /* @__PURE__ */ jsxs67("div", { css: inputWrapper, children: [
|
|
16940
|
-
/* @__PURE__ */
|
|
17094
|
+
/* @__PURE__ */ jsx101(
|
|
16941
17095
|
"input",
|
|
16942
17096
|
{
|
|
16943
17097
|
type: "text",
|
|
@@ -16950,18 +17104,18 @@ var ParameterLinkInner = forwardRef14(
|
|
|
16950
17104
|
}
|
|
16951
17105
|
),
|
|
16952
17106
|
/* @__PURE__ */ jsxs67("div", { css: linkParameterControls, children: [
|
|
16953
|
-
/* @__PURE__ */
|
|
17107
|
+
/* @__PURE__ */ jsx101(
|
|
16954
17108
|
"button",
|
|
16955
17109
|
{
|
|
16956
17110
|
type: "button",
|
|
16957
17111
|
css: linkParameterBtn,
|
|
16958
|
-
disabled,
|
|
17112
|
+
disabled: disabled2,
|
|
16959
17113
|
onClick: onConnectLink,
|
|
16960
17114
|
title: "edit current selection",
|
|
16961
17115
|
children: "edit"
|
|
16962
17116
|
}
|
|
16963
17117
|
),
|
|
16964
|
-
externalLink ? /* @__PURE__ */
|
|
17118
|
+
externalLink ? /* @__PURE__ */ jsx101(
|
|
16965
17119
|
"a",
|
|
16966
17120
|
{
|
|
16967
17121
|
href: externalLink,
|
|
@@ -16969,7 +17123,7 @@ var ParameterLinkInner = forwardRef14(
|
|
|
16969
17123
|
title: "Open link in new tab",
|
|
16970
17124
|
target: "_blank",
|
|
16971
17125
|
rel: "noopener noreferrer",
|
|
16972
|
-
children: /* @__PURE__ */
|
|
17126
|
+
children: /* @__PURE__ */ jsx101(Icon, { icon: "arrows-expand-up-right", iconColor: "currentColor", size: "1rem" })
|
|
16973
17127
|
}
|
|
16974
17128
|
) : null
|
|
16975
17129
|
] })
|
|
@@ -16978,7 +17132,7 @@ var ParameterLinkInner = forwardRef14(
|
|
|
16978
17132
|
);
|
|
16979
17133
|
|
|
16980
17134
|
// src/components/ParameterInputs/ParameterNameAndPublicIdInput.tsx
|
|
16981
|
-
import { Fragment as Fragment17, jsx as
|
|
17135
|
+
import { Fragment as Fragment17, jsx as jsx102, jsxs as jsxs68 } from "@emotion/react/jsx-runtime";
|
|
16982
17136
|
var ParameterNameAndPublicIdInput = ({
|
|
16983
17137
|
id,
|
|
16984
17138
|
onBlur,
|
|
@@ -17005,7 +17159,7 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
17005
17159
|
};
|
|
17006
17160
|
autoFocus == null ? void 0 : autoFocus();
|
|
17007
17161
|
return /* @__PURE__ */ jsxs68(Fragment17, { children: [
|
|
17008
|
-
/* @__PURE__ */
|
|
17162
|
+
/* @__PURE__ */ jsx102(
|
|
17009
17163
|
ParameterInput,
|
|
17010
17164
|
{
|
|
17011
17165
|
id: nameIdField,
|
|
@@ -17024,7 +17178,7 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
17024
17178
|
value: values[nameIdField]
|
|
17025
17179
|
}
|
|
17026
17180
|
),
|
|
17027
|
-
/* @__PURE__ */
|
|
17181
|
+
/* @__PURE__ */ jsx102(
|
|
17028
17182
|
ParameterInput,
|
|
17029
17183
|
{
|
|
17030
17184
|
id: publicIdFieldName,
|
|
@@ -17038,11 +17192,11 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
17038
17192
|
caption: publicIdCaption,
|
|
17039
17193
|
placeholder: publicIdPlaceholderText,
|
|
17040
17194
|
errorMessage: publicIdError,
|
|
17041
|
-
menuItems: /* @__PURE__ */
|
|
17195
|
+
menuItems: /* @__PURE__ */ jsx102(
|
|
17042
17196
|
MenuItem,
|
|
17043
17197
|
{
|
|
17044
17198
|
disabled: !values[publicIdFieldName],
|
|
17045
|
-
icon: /* @__PURE__ */
|
|
17199
|
+
icon: /* @__PURE__ */ jsx102(Icon, { icon: "path-trim", iconColor: "currentColor" }),
|
|
17046
17200
|
onClick: handleCopyPidFieldValue,
|
|
17047
17201
|
children: "Copy"
|
|
17048
17202
|
}
|
|
@@ -17050,12 +17204,12 @@ var ParameterNameAndPublicIdInput = ({
|
|
|
17050
17204
|
value: values[publicIdFieldName]
|
|
17051
17205
|
}
|
|
17052
17206
|
),
|
|
17053
|
-
(warnOverLength == null ? void 0 : warnOverLength.length) && values[publicIdFieldName].length > warnOverLength.length ? /* @__PURE__ */
|
|
17207
|
+
(warnOverLength == null ? void 0 : warnOverLength.length) && values[publicIdFieldName].length > warnOverLength.length ? /* @__PURE__ */ jsx102(Callout, { type: "caution", children: warnOverLength.message }) : null
|
|
17054
17208
|
] });
|
|
17055
17209
|
};
|
|
17056
17210
|
|
|
17057
17211
|
// src/components/ParameterInputs/ParameterRichText.tsx
|
|
17058
|
-
import { css as
|
|
17212
|
+
import { css as css85 } from "@emotion/react";
|
|
17059
17213
|
import { ListItemNode, ListNode as ListNode2 } from "@lexical/list";
|
|
17060
17214
|
import {
|
|
17061
17215
|
CODE,
|
|
@@ -17169,7 +17323,7 @@ var getLabelForElement = (type) => {
|
|
|
17169
17323
|
// src/components/ParameterInputs/ParameterRichText.tsx
|
|
17170
17324
|
import { deepEqual as deepEqual2 } from "fast-equals";
|
|
17171
17325
|
import { ParagraphNode as ParagraphNode2 } from "lexical";
|
|
17172
|
-
import { useEffect as
|
|
17326
|
+
import { useEffect as useEffect15, useRef as useRef7 } from "react";
|
|
17173
17327
|
|
|
17174
17328
|
// src/components/ParameterInputs/rich-text/CustomCodeNode.ts
|
|
17175
17329
|
import { CodeNode } from "@lexical/code";
|
|
@@ -17190,10 +17344,10 @@ CustomCodeNode.importDOM = function() {
|
|
|
17190
17344
|
import { useLexicalComposerContext } from "@lexical/react/LexicalComposerContext";
|
|
17191
17345
|
import { mergeRegister } from "@lexical/utils";
|
|
17192
17346
|
import { ParagraphNode } from "lexical";
|
|
17193
|
-
import { useEffect as
|
|
17347
|
+
import { useEffect as useEffect11 } from "react";
|
|
17194
17348
|
function DisableStylesPlugin() {
|
|
17195
17349
|
const [editor] = useLexicalComposerContext();
|
|
17196
|
-
|
|
17350
|
+
useEffect11(() => {
|
|
17197
17351
|
return mergeRegister(
|
|
17198
17352
|
// Disable text alignment on paragraph nodes
|
|
17199
17353
|
editor.registerNodeTransform(ParagraphNode, (node) => {
|
|
@@ -17207,23 +17361,23 @@ function DisableStylesPlugin() {
|
|
|
17207
17361
|
}
|
|
17208
17362
|
|
|
17209
17363
|
// src/components/ParameterInputs/rich-text/editorStyles.ts
|
|
17210
|
-
import { css as
|
|
17211
|
-
var textBold =
|
|
17364
|
+
import { css as css82 } from "@emotion/css";
|
|
17365
|
+
var textBold = css82`
|
|
17212
17366
|
font-weight: 700;
|
|
17213
17367
|
`;
|
|
17214
|
-
var textItalic =
|
|
17368
|
+
var textItalic = css82`
|
|
17215
17369
|
font-style: italic;
|
|
17216
17370
|
`;
|
|
17217
|
-
var textUnderline =
|
|
17371
|
+
var textUnderline = css82`
|
|
17218
17372
|
text-decoration: underline;
|
|
17219
17373
|
`;
|
|
17220
|
-
var textStrikethrough =
|
|
17374
|
+
var textStrikethrough = css82`
|
|
17221
17375
|
text-decoration: line-through;
|
|
17222
17376
|
`;
|
|
17223
|
-
var textUnderlineStrikethrough =
|
|
17377
|
+
var textUnderlineStrikethrough = css82`
|
|
17224
17378
|
text-decoration: underline line-through;
|
|
17225
17379
|
`;
|
|
17226
|
-
var textCode =
|
|
17380
|
+
var textCode = css82`
|
|
17227
17381
|
background-color: var(--gray-100);
|
|
17228
17382
|
border-radius: var(--rounded-sm);
|
|
17229
17383
|
display: inline-block;
|
|
@@ -17234,68 +17388,68 @@ var textCode = css81`
|
|
|
17234
17388
|
padding-left: var(--spacing-xs);
|
|
17235
17389
|
padding-right: var(--spacing-xs);
|
|
17236
17390
|
`;
|
|
17237
|
-
var textSuperscript =
|
|
17391
|
+
var textSuperscript = css82`
|
|
17238
17392
|
vertical-align: super;
|
|
17239
17393
|
font-size: smaller;
|
|
17240
17394
|
`;
|
|
17241
|
-
var textSubscript =
|
|
17395
|
+
var textSubscript = css82`
|
|
17242
17396
|
vertical-align: sub;
|
|
17243
17397
|
font-size: smaller;
|
|
17244
17398
|
`;
|
|
17245
|
-
var linkElement =
|
|
17399
|
+
var linkElement = css82`
|
|
17246
17400
|
${link}
|
|
17247
17401
|
${linkColorDefault}
|
|
17248
17402
|
text-decoration: underline;
|
|
17249
17403
|
`;
|
|
17250
|
-
var h12 =
|
|
17404
|
+
var h12 = css82`
|
|
17251
17405
|
font-size: clamp(1.35rem, var(--fluid-font-base), 1.7rem);
|
|
17252
17406
|
`;
|
|
17253
|
-
var h22 =
|
|
17407
|
+
var h22 = css82`
|
|
17254
17408
|
font-size: clamp(1.35rem, var(--fluid-font-base), 1.6rem);
|
|
17255
17409
|
`;
|
|
17256
|
-
var h32 =
|
|
17410
|
+
var h32 = css82`
|
|
17257
17411
|
font-size: clamp(1.25rem, var(--fluid-font-base), 1.5rem);
|
|
17258
17412
|
`;
|
|
17259
|
-
var h42 =
|
|
17413
|
+
var h42 = css82`
|
|
17260
17414
|
font-size: clamp(1.15rem, var(--fluid-font-base), 1.25rem);
|
|
17261
17415
|
`;
|
|
17262
|
-
var h52 =
|
|
17416
|
+
var h52 = css82`
|
|
17263
17417
|
font-size: clamp(var(--fs-base), var(--fluid-font-base), 1.15rem);
|
|
17264
17418
|
`;
|
|
17265
|
-
var h62 =
|
|
17419
|
+
var h62 = css82`
|
|
17266
17420
|
font-size: var(--fs-base);
|
|
17267
17421
|
`;
|
|
17268
|
-
var heading1Element =
|
|
17422
|
+
var heading1Element = css82`
|
|
17269
17423
|
${h12}
|
|
17270
17424
|
${commonHeadingAttr(true)}
|
|
17271
17425
|
${commonLineHeight}
|
|
17272
17426
|
`;
|
|
17273
|
-
var heading2Element =
|
|
17427
|
+
var heading2Element = css82`
|
|
17274
17428
|
${h22}
|
|
17275
17429
|
${commonHeadingAttr(true)}
|
|
17276
17430
|
${commonLineHeight}
|
|
17277
17431
|
`;
|
|
17278
|
-
var heading3Element =
|
|
17432
|
+
var heading3Element = css82`
|
|
17279
17433
|
${h32}
|
|
17280
17434
|
${commonHeadingAttr(true)}
|
|
17281
17435
|
${commonLineHeight}
|
|
17282
17436
|
`;
|
|
17283
|
-
var heading4Element =
|
|
17437
|
+
var heading4Element = css82`
|
|
17284
17438
|
${h42}
|
|
17285
17439
|
${commonHeadingAttr(true)}
|
|
17286
17440
|
${commonLineHeight}
|
|
17287
17441
|
`;
|
|
17288
|
-
var heading5Element =
|
|
17442
|
+
var heading5Element = css82`
|
|
17289
17443
|
${h52}
|
|
17290
17444
|
${commonHeadingAttr(true)}
|
|
17291
17445
|
${commonLineHeight}
|
|
17292
17446
|
`;
|
|
17293
|
-
var heading6Element =
|
|
17447
|
+
var heading6Element = css82`
|
|
17294
17448
|
${h62}
|
|
17295
17449
|
${commonHeadingAttr(true)}
|
|
17296
17450
|
${commonLineHeight}
|
|
17297
17451
|
`;
|
|
17298
|
-
var paragraphElement =
|
|
17452
|
+
var paragraphElement = css82`
|
|
17299
17453
|
line-height: 1.5;
|
|
17300
17454
|
margin-bottom: var(--spacing-base);
|
|
17301
17455
|
|
|
@@ -17303,7 +17457,7 @@ var paragraphElement = css81`
|
|
|
17303
17457
|
margin-bottom: 0;
|
|
17304
17458
|
}
|
|
17305
17459
|
`;
|
|
17306
|
-
var orderedListElement =
|
|
17460
|
+
var orderedListElement = css82`
|
|
17307
17461
|
${commonLineHeight}
|
|
17308
17462
|
display: block;
|
|
17309
17463
|
list-style: decimal;
|
|
@@ -17332,7 +17486,7 @@ var orderedListElement = css81`
|
|
|
17332
17486
|
}
|
|
17333
17487
|
}
|
|
17334
17488
|
`;
|
|
17335
|
-
var unorderedListElement =
|
|
17489
|
+
var unorderedListElement = css82`
|
|
17336
17490
|
${commonLineHeight}
|
|
17337
17491
|
display: block;
|
|
17338
17492
|
list-style: disc;
|
|
@@ -17353,13 +17507,13 @@ var unorderedListElement = css81`
|
|
|
17353
17507
|
}
|
|
17354
17508
|
}
|
|
17355
17509
|
`;
|
|
17356
|
-
var listItemElement =
|
|
17510
|
+
var listItemElement = css82`
|
|
17357
17511
|
margin-left: var(--spacing-md);
|
|
17358
17512
|
`;
|
|
17359
|
-
var nestedListItemElement =
|
|
17513
|
+
var nestedListItemElement = css82`
|
|
17360
17514
|
list-style-type: none;
|
|
17361
17515
|
`;
|
|
17362
|
-
var blockquoteElement =
|
|
17516
|
+
var blockquoteElement = css82`
|
|
17363
17517
|
border-left: 0.25rem solid var(--gray-300);
|
|
17364
17518
|
color: var(--gray-600);
|
|
17365
17519
|
margin-bottom: var(--spacing-base);
|
|
@@ -17369,7 +17523,7 @@ var blockquoteElement = css81`
|
|
|
17369
17523
|
margin-bottom: 0;
|
|
17370
17524
|
}
|
|
17371
17525
|
`;
|
|
17372
|
-
var codeElement =
|
|
17526
|
+
var codeElement = css82`
|
|
17373
17527
|
background-color: var(--gray-100);
|
|
17374
17528
|
border-radius: var(--rounded-sm);
|
|
17375
17529
|
display: block;
|
|
@@ -17386,7 +17540,7 @@ var codeElement = css81`
|
|
|
17386
17540
|
`;
|
|
17387
17541
|
|
|
17388
17542
|
// src/components/ParameterInputs/rich-text/LinkNodePlugin.tsx
|
|
17389
|
-
import { css as
|
|
17543
|
+
import { css as css83 } from "@emotion/react";
|
|
17390
17544
|
import { useLexicalComposerContext as useLexicalComposerContext2 } from "@lexical/react/LexicalComposerContext";
|
|
17391
17545
|
import { NodeEventPlugin } from "@lexical/react/LexicalNodeEventPlugin";
|
|
17392
17546
|
import { addClassNamesToElement, isHTMLAnchorElement, mergeRegister as mergeRegister2 } from "@lexical/utils";
|
|
@@ -17402,7 +17556,7 @@ import {
|
|
|
17402
17556
|
ElementNode as ElementNode2,
|
|
17403
17557
|
FOCUS_COMMAND
|
|
17404
17558
|
} from "lexical";
|
|
17405
|
-
import { useCallback as useCallback5, useEffect as
|
|
17559
|
+
import { useCallback as useCallback5, useEffect as useEffect12, useRef as useRef6, useState as useState12 } from "react";
|
|
17406
17560
|
|
|
17407
17561
|
// src/components/ParameterInputs/rich-text/utils.ts
|
|
17408
17562
|
import { $isAtNodeEnd } from "@lexical/selection";
|
|
@@ -17440,7 +17594,7 @@ var getSelectedNode = (selection) => {
|
|
|
17440
17594
|
};
|
|
17441
17595
|
|
|
17442
17596
|
// src/components/ParameterInputs/rich-text/LinkNodePlugin.tsx
|
|
17443
|
-
import { Fragment as Fragment18, jsx as
|
|
17597
|
+
import { Fragment as Fragment18, jsx as jsx103, jsxs as jsxs69 } from "@emotion/react/jsx-runtime";
|
|
17444
17598
|
var isProjectMapLinkValue = (value) => {
|
|
17445
17599
|
return (value == null ? void 0 : value.type) === "projectMapNode" && Boolean(
|
|
17446
17600
|
value.nodeId && value.path && value.projectMapId
|
|
@@ -17727,16 +17881,16 @@ var OPEN_LINK_NODE_MODAL_COMMAND = createCommand(
|
|
|
17727
17881
|
);
|
|
17728
17882
|
var LINK_POPOVER_OFFSET_X = 0;
|
|
17729
17883
|
var LINK_POPOVER_OFFSET_Y = 8;
|
|
17730
|
-
var linkPopover =
|
|
17884
|
+
var linkPopover = css83`
|
|
17731
17885
|
position: absolute;
|
|
17732
17886
|
z-index: 5;
|
|
17733
17887
|
`;
|
|
17734
|
-
var linkPopoverContainer =
|
|
17888
|
+
var linkPopoverContainer = css83`
|
|
17735
17889
|
${Popover};
|
|
17736
17890
|
align-items: center;
|
|
17737
17891
|
display: flex;
|
|
17738
17892
|
`;
|
|
17739
|
-
var linkPopoverAnchor =
|
|
17893
|
+
var linkPopoverAnchor = css83`
|
|
17740
17894
|
${link}
|
|
17741
17895
|
${linkColorDefault}
|
|
17742
17896
|
`;
|
|
@@ -17749,13 +17903,13 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
17749
17903
|
const linkPopoverElRef = useRef6(null);
|
|
17750
17904
|
const [isEditorFocused, setIsEditorFocused] = useState12(false);
|
|
17751
17905
|
const [isLinkPopoverFocused, setIsLinkPopoverFocused] = useState12(false);
|
|
17752
|
-
|
|
17906
|
+
useEffect12(() => {
|
|
17753
17907
|
if (!isEditorFocused && !isLinkPopoverFocused) {
|
|
17754
17908
|
setLinkPopoverState(void 0);
|
|
17755
17909
|
return;
|
|
17756
17910
|
}
|
|
17757
17911
|
}, [isEditorFocused, isLinkPopoverFocused]);
|
|
17758
|
-
|
|
17912
|
+
useEffect12(() => {
|
|
17759
17913
|
if (!editor.hasNodes([LinkNode])) {
|
|
17760
17914
|
throw new Error("LinkNode not registered on editor");
|
|
17761
17915
|
}
|
|
@@ -17856,7 +18010,7 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
17856
18010
|
}
|
|
17857
18011
|
});
|
|
17858
18012
|
}, [editor]);
|
|
17859
|
-
|
|
18013
|
+
useEffect12(() => {
|
|
17860
18014
|
return editor.registerUpdateListener(({ editorState }) => {
|
|
17861
18015
|
requestAnimationFrame(() => {
|
|
17862
18016
|
editorState.read(() => {
|
|
@@ -17884,7 +18038,7 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
17884
18038
|
});
|
|
17885
18039
|
};
|
|
17886
18040
|
return /* @__PURE__ */ jsxs69(Fragment18, { children: [
|
|
17887
|
-
/* @__PURE__ */
|
|
18041
|
+
/* @__PURE__ */ jsx103(
|
|
17888
18042
|
NodeEventPlugin,
|
|
17889
18043
|
{
|
|
17890
18044
|
nodeType: LinkNode,
|
|
@@ -17894,7 +18048,7 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
17894
18048
|
}
|
|
17895
18049
|
}
|
|
17896
18050
|
),
|
|
17897
|
-
linkPopoverState ? /* @__PURE__ */
|
|
18051
|
+
linkPopoverState ? /* @__PURE__ */ jsx103(
|
|
17898
18052
|
"div",
|
|
17899
18053
|
{
|
|
17900
18054
|
css: linkPopover,
|
|
@@ -17904,7 +18058,7 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
17904
18058
|
},
|
|
17905
18059
|
ref: linkPopoverElRef,
|
|
17906
18060
|
children: /* @__PURE__ */ jsxs69("div", { css: linkPopoverContainer, children: [
|
|
17907
|
-
linkPopoverState.node.__link.type === "projectMapNode" ? linkPopoverState.node.__link.path : /* @__PURE__ */
|
|
18061
|
+
linkPopoverState.node.__link.type === "projectMapNode" ? linkPopoverState.node.__link.path : /* @__PURE__ */ jsx103(
|
|
17908
18062
|
"a",
|
|
17909
18063
|
{
|
|
17910
18064
|
href: parsePath(
|
|
@@ -17916,7 +18070,7 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
17916
18070
|
children: parsePath(linkPopoverState.node.__link.path)
|
|
17917
18071
|
}
|
|
17918
18072
|
),
|
|
17919
|
-
/* @__PURE__ */
|
|
18073
|
+
/* @__PURE__ */ jsx103(
|
|
17920
18074
|
Button,
|
|
17921
18075
|
{
|
|
17922
18076
|
size: "xs",
|
|
@@ -17924,7 +18078,7 @@ function LinkNodePlugin({ onConnectLink, getBoundPath }) {
|
|
|
17924
18078
|
onEditLinkNode(linkPopoverState.node);
|
|
17925
18079
|
},
|
|
17926
18080
|
buttonType: "ghost",
|
|
17927
|
-
children: /* @__PURE__ */
|
|
18081
|
+
children: /* @__PURE__ */ jsx103(Icon, { icon: "pen", size: "1rem", title: "Edit link" })
|
|
17928
18082
|
}
|
|
17929
18083
|
)
|
|
17930
18084
|
] })
|
|
@@ -17948,8 +18102,8 @@ import {
|
|
|
17948
18102
|
COMMAND_PRIORITY_CRITICAL,
|
|
17949
18103
|
INDENT_CONTENT_COMMAND
|
|
17950
18104
|
} from "lexical";
|
|
17951
|
-
import { useEffect as
|
|
17952
|
-
import { jsx as
|
|
18105
|
+
import { useEffect as useEffect13 } from "react";
|
|
18106
|
+
import { jsx as jsx104 } from "@emotion/react/jsx-runtime";
|
|
17953
18107
|
function isIndentPermitted(maxDepth) {
|
|
17954
18108
|
const selection = $getSelection2();
|
|
17955
18109
|
if (!$isRangeSelection2(selection)) {
|
|
@@ -17972,18 +18126,18 @@ function isIndentPermitted(maxDepth) {
|
|
|
17972
18126
|
}
|
|
17973
18127
|
function ListIndentPlugin({ maxDepth }) {
|
|
17974
18128
|
const [editor] = useLexicalComposerContext3();
|
|
17975
|
-
|
|
18129
|
+
useEffect13(() => {
|
|
17976
18130
|
return editor.registerCommand(
|
|
17977
18131
|
INDENT_CONTENT_COMMAND,
|
|
17978
18132
|
() => !isIndentPermitted(maxDepth),
|
|
17979
18133
|
COMMAND_PRIORITY_CRITICAL
|
|
17980
18134
|
);
|
|
17981
18135
|
}, [editor, maxDepth]);
|
|
17982
|
-
return /* @__PURE__ */
|
|
18136
|
+
return /* @__PURE__ */ jsx104(TabIndentationPlugin, {});
|
|
17983
18137
|
}
|
|
17984
18138
|
|
|
17985
18139
|
// src/components/ParameterInputs/rich-text/RichTextToolbar.tsx
|
|
17986
|
-
import { css as
|
|
18140
|
+
import { css as css84 } from "@emotion/react";
|
|
17987
18141
|
import { $createCodeNode } from "@lexical/code";
|
|
17988
18142
|
import {
|
|
17989
18143
|
$isListNode as $isListNode2,
|
|
@@ -18005,9 +18159,9 @@ import {
|
|
|
18005
18159
|
FORMAT_TEXT_COMMAND,
|
|
18006
18160
|
SELECTION_CHANGE_COMMAND
|
|
18007
18161
|
} from "lexical";
|
|
18008
|
-
import { useCallback as useCallback6, useEffect as
|
|
18009
|
-
import { Fragment as Fragment19, jsx as
|
|
18010
|
-
var toolbar =
|
|
18162
|
+
import { useCallback as useCallback6, useEffect as useEffect14, useMemo as useMemo3, useState as useState13 } from "react";
|
|
18163
|
+
import { Fragment as Fragment19, jsx as jsx105, jsxs as jsxs70 } from "@emotion/react/jsx-runtime";
|
|
18164
|
+
var toolbar = css84`
|
|
18011
18165
|
background: var(--gray-50);
|
|
18012
18166
|
border-radius: var(--rounded-base);
|
|
18013
18167
|
display: flex;
|
|
@@ -18019,7 +18173,7 @@ var toolbar = css83`
|
|
|
18019
18173
|
top: calc(var(--spacing-sm) * -2);
|
|
18020
18174
|
z-index: 10;
|
|
18021
18175
|
`;
|
|
18022
|
-
var toolbarGroup =
|
|
18176
|
+
var toolbarGroup = css84`
|
|
18023
18177
|
display: flex;
|
|
18024
18178
|
gap: var(--spacing-xs);
|
|
18025
18179
|
position: relative;
|
|
@@ -18035,7 +18189,7 @@ var toolbarGroup = css83`
|
|
|
18035
18189
|
width: 1px;
|
|
18036
18190
|
}
|
|
18037
18191
|
`;
|
|
18038
|
-
var richTextToolbarButton =
|
|
18192
|
+
var richTextToolbarButton = css84`
|
|
18039
18193
|
align-items: center;
|
|
18040
18194
|
appearance: none;
|
|
18041
18195
|
border: 0;
|
|
@@ -18048,17 +18202,17 @@ var richTextToolbarButton = css83`
|
|
|
18048
18202
|
min-width: 32px;
|
|
18049
18203
|
padding: 0 var(--spacing-sm);
|
|
18050
18204
|
`;
|
|
18051
|
-
var richTextToolbarButtonActive =
|
|
18205
|
+
var richTextToolbarButtonActive = css84`
|
|
18052
18206
|
background: var(--gray-200);
|
|
18053
18207
|
`;
|
|
18054
|
-
var toolbarIcon =
|
|
18208
|
+
var toolbarIcon = css84`
|
|
18055
18209
|
color: inherit;
|
|
18056
18210
|
`;
|
|
18057
|
-
var toolbarChevron =
|
|
18211
|
+
var toolbarChevron = css84`
|
|
18058
18212
|
margin-left: var(--spacing-xs);
|
|
18059
18213
|
`;
|
|
18060
18214
|
var RichTextToolbarIcon = ({ icon }) => {
|
|
18061
|
-
return /* @__PURE__ */
|
|
18215
|
+
return /* @__PURE__ */ jsx105(Icon, { icon, css: toolbarIcon, size: "1rem" });
|
|
18062
18216
|
};
|
|
18063
18217
|
var FORMATS_WITH_ICON = /* @__PURE__ */ new Map([
|
|
18064
18218
|
["bold", "format-bold"],
|
|
@@ -18148,7 +18302,7 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18148
18302
|
setIsLink(false);
|
|
18149
18303
|
}
|
|
18150
18304
|
}, [editor, setActiveElement, setActiveFormats, setIsLink]);
|
|
18151
|
-
|
|
18305
|
+
useEffect14(() => {
|
|
18152
18306
|
return editor.registerCommand(
|
|
18153
18307
|
SELECTION_CHANGE_COMMAND,
|
|
18154
18308
|
(_payload) => {
|
|
@@ -18158,7 +18312,7 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18158
18312
|
COMMAND_PRIORITY_CRITICAL2
|
|
18159
18313
|
);
|
|
18160
18314
|
}, [editor, updateToolbar]);
|
|
18161
|
-
|
|
18315
|
+
useEffect14(() => {
|
|
18162
18316
|
return editor.registerUpdateListener(({ editorState }) => {
|
|
18163
18317
|
requestAnimationFrame(() => {
|
|
18164
18318
|
editorState.read(() => {
|
|
@@ -18175,7 +18329,7 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18175
18329
|
menuTrigger: /* @__PURE__ */ jsxs70("button", { css: richTextToolbarButton, title: "Text styles", children: [
|
|
18176
18330
|
visibleTextualElements.some((element) => element.type === activeElement) ? getLabelForElement(activeElement) : getLabelForElement("paragraph"),
|
|
18177
18331
|
" ",
|
|
18178
|
-
/* @__PURE__ */
|
|
18332
|
+
/* @__PURE__ */ jsx105(Icon, { icon: "chevron-down", css: [toolbarIcon, toolbarChevron], size: "1rem" })
|
|
18179
18333
|
] }),
|
|
18180
18334
|
placement: "bottom-start",
|
|
18181
18335
|
children: [
|
|
@@ -18185,7 +18339,7 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18185
18339
|
type: "paragraph"
|
|
18186
18340
|
},
|
|
18187
18341
|
...visibleTextualElements
|
|
18188
|
-
].map((element) => /* @__PURE__ */
|
|
18342
|
+
].map((element) => /* @__PURE__ */ jsx105(
|
|
18189
18343
|
MenuItem,
|
|
18190
18344
|
{
|
|
18191
18345
|
onClick: () => {
|
|
@@ -18195,12 +18349,12 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18195
18349
|
},
|
|
18196
18350
|
element.type
|
|
18197
18351
|
)),
|
|
18198
|
-
visibleTextualElements.length === 0 ? /* @__PURE__ */
|
|
18352
|
+
visibleTextualElements.length === 0 ? /* @__PURE__ */ jsx105(MenuItem, { disabled: true, children: "Alternative text styles are not available" }) : null
|
|
18199
18353
|
]
|
|
18200
18354
|
}
|
|
18201
18355
|
),
|
|
18202
18356
|
visibleFormatsWithIcon.length > 0 || visibleFormatsWithoutIcon.length > 0 ? /* @__PURE__ */ jsxs70("div", { css: toolbarGroup, children: [
|
|
18203
|
-
visibleFormatsWithIcon.map((format) => /* @__PURE__ */
|
|
18357
|
+
visibleFormatsWithIcon.map((format) => /* @__PURE__ */ jsx105(Tooltip, { title: format.label, placement: "top", children: /* @__PURE__ */ jsx105(
|
|
18204
18358
|
"button",
|
|
18205
18359
|
{
|
|
18206
18360
|
onClick: () => {
|
|
@@ -18210,16 +18364,16 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18210
18364
|
richTextToolbarButton,
|
|
18211
18365
|
activeFormats.includes(format.type) ? richTextToolbarButtonActive : null
|
|
18212
18366
|
],
|
|
18213
|
-
children: /* @__PURE__ */
|
|
18367
|
+
children: /* @__PURE__ */ jsx105(RichTextToolbarIcon, { icon: FORMATS_WITH_ICON.get(format.type) })
|
|
18214
18368
|
}
|
|
18215
18369
|
) }, format.type)),
|
|
18216
|
-
visibleFormatsWithoutIcon.length > 0 ? /* @__PURE__ */
|
|
18370
|
+
visibleFormatsWithoutIcon.length > 0 ? /* @__PURE__ */ jsx105(
|
|
18217
18371
|
Menu,
|
|
18218
18372
|
{
|
|
18219
18373
|
menuLabel: "Alternative text styles",
|
|
18220
|
-
menuTrigger: /* @__PURE__ */
|
|
18374
|
+
menuTrigger: /* @__PURE__ */ jsx105("button", { css: richTextToolbarButton, title: "Alternative text styles", children: /* @__PURE__ */ jsx105(Icon, { icon: "more-alt", css: toolbarIcon }) }),
|
|
18221
18375
|
placement: "bottom-start",
|
|
18222
|
-
children: visibleFormatsWithoutIcon.map((format) => /* @__PURE__ */
|
|
18376
|
+
children: visibleFormatsWithoutIcon.map((format) => /* @__PURE__ */ jsx105(
|
|
18223
18377
|
MenuItem,
|
|
18224
18378
|
{
|
|
18225
18379
|
onClick: () => {
|
|
@@ -18233,18 +18387,18 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18233
18387
|
) : null
|
|
18234
18388
|
] }) : null,
|
|
18235
18389
|
visibleElementsWithIcons.size > 0 ? /* @__PURE__ */ jsxs70("div", { css: toolbarGroup, children: [
|
|
18236
|
-
linkElementVisible ? /* @__PURE__ */
|
|
18390
|
+
linkElementVisible ? /* @__PURE__ */ jsx105(Tooltip, { title: "Link", placement: "top", children: /* @__PURE__ */ jsx105(
|
|
18237
18391
|
"button",
|
|
18238
18392
|
{
|
|
18239
18393
|
onClick: () => {
|
|
18240
18394
|
isLink ? editor.dispatchCommand(REMOVE_LINK_NODE_COMMAND, {}) : editor.dispatchCommand(OPEN_LINK_NODE_MODAL_COMMAND, {});
|
|
18241
18395
|
},
|
|
18242
18396
|
css: [richTextToolbarButton, isLink ? richTextToolbarButtonActive : null],
|
|
18243
|
-
children: /* @__PURE__ */
|
|
18397
|
+
children: /* @__PURE__ */ jsx105(RichTextToolbarIcon, { icon: "link" })
|
|
18244
18398
|
}
|
|
18245
18399
|
) }) : null,
|
|
18246
18400
|
visibleLists.size > 0 ? /* @__PURE__ */ jsxs70(Fragment19, { children: [
|
|
18247
|
-
visibleLists.has("unorderedList") ? /* @__PURE__ */
|
|
18401
|
+
visibleLists.has("unorderedList") ? /* @__PURE__ */ jsx105(Tooltip, { title: "Bullet List", placement: "top", children: /* @__PURE__ */ jsx105(
|
|
18248
18402
|
"button",
|
|
18249
18403
|
{
|
|
18250
18404
|
onClick: () => {
|
|
@@ -18254,10 +18408,10 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18254
18408
|
richTextToolbarButton,
|
|
18255
18409
|
activeElement === "unorderedList" ? richTextToolbarButtonActive : null
|
|
18256
18410
|
],
|
|
18257
|
-
children: /* @__PURE__ */
|
|
18411
|
+
children: /* @__PURE__ */ jsx105(RichTextToolbarIcon, { icon: "layout-list" })
|
|
18258
18412
|
}
|
|
18259
18413
|
) }) : null,
|
|
18260
|
-
visibleLists.has("orderedList") ? /* @__PURE__ */
|
|
18414
|
+
visibleLists.has("orderedList") ? /* @__PURE__ */ jsx105(Tooltip, { title: "Ordered List", placement: "top", children: /* @__PURE__ */ jsx105(
|
|
18261
18415
|
"button",
|
|
18262
18416
|
{
|
|
18263
18417
|
onClick: () => {
|
|
@@ -18267,32 +18421,32 @@ var RichTextToolbar = ({ config, customControls }) => {
|
|
|
18267
18421
|
richTextToolbarButton,
|
|
18268
18422
|
activeElement === "orderedList" ? richTextToolbarButtonActive : null
|
|
18269
18423
|
],
|
|
18270
|
-
children: /* @__PURE__ */
|
|
18424
|
+
children: /* @__PURE__ */ jsx105(RichTextToolbarIcon, { icon: "layout-list-numbered" })
|
|
18271
18425
|
}
|
|
18272
18426
|
) }) : null
|
|
18273
18427
|
] }) : null,
|
|
18274
|
-
quoteElementVisible ? /* @__PURE__ */
|
|
18428
|
+
quoteElementVisible ? /* @__PURE__ */ jsx105(Tooltip, { title: "Blockquote", placement: "top", children: /* @__PURE__ */ jsx105(
|
|
18275
18429
|
"button",
|
|
18276
18430
|
{
|
|
18277
18431
|
onClick: () => {
|
|
18278
18432
|
activeElement === "quote" ? onSelectElement("paragraph") : onSelectElement("quote");
|
|
18279
18433
|
},
|
|
18280
18434
|
css: [richTextToolbarButton, activeElement === "quote" ? richTextToolbarButtonActive : null],
|
|
18281
|
-
children: /* @__PURE__ */
|
|
18435
|
+
children: /* @__PURE__ */ jsx105(RichTextToolbarIcon, { icon: "quote" })
|
|
18282
18436
|
}
|
|
18283
18437
|
) }) : null,
|
|
18284
|
-
codeElementVisible ? /* @__PURE__ */
|
|
18438
|
+
codeElementVisible ? /* @__PURE__ */ jsx105(Tooltip, { title: "Code Block", placement: "top", children: /* @__PURE__ */ jsx105(
|
|
18285
18439
|
"button",
|
|
18286
18440
|
{
|
|
18287
18441
|
onClick: () => {
|
|
18288
18442
|
activeElement === "code" ? onSelectElement("paragraph") : onSelectElement("code");
|
|
18289
18443
|
},
|
|
18290
18444
|
css: [richTextToolbarButton, activeElement === "code" ? richTextToolbarButtonActive : null],
|
|
18291
|
-
children: /* @__PURE__ */
|
|
18445
|
+
children: /* @__PURE__ */ jsx105(RichTextToolbarIcon, { icon: "code-slash" })
|
|
18292
18446
|
}
|
|
18293
18447
|
) }) : null
|
|
18294
18448
|
] }) : null,
|
|
18295
|
-
customControls ? /* @__PURE__ */
|
|
18449
|
+
customControls ? /* @__PURE__ */ jsx105("div", { css: toolbarGroup, children: customControls }) : null
|
|
18296
18450
|
] });
|
|
18297
18451
|
};
|
|
18298
18452
|
var RichTextToolbar_default = RichTextToolbar;
|
|
@@ -18406,7 +18560,7 @@ var useRichTextToolbarState = ({ config }) => {
|
|
|
18406
18560
|
};
|
|
18407
18561
|
|
|
18408
18562
|
// src/components/ParameterInputs/ParameterRichText.tsx
|
|
18409
|
-
import { Fragment as Fragment20, jsx as
|
|
18563
|
+
import { Fragment as Fragment20, jsx as jsx106, jsxs as jsxs71 } from "@emotion/react/jsx-runtime";
|
|
18410
18564
|
var ParameterRichText = ({
|
|
18411
18565
|
label,
|
|
18412
18566
|
labelLeadingIcon,
|
|
@@ -18445,7 +18599,7 @@ var ParameterRichText = ({
|
|
|
18445
18599
|
captionTestId,
|
|
18446
18600
|
menuItems,
|
|
18447
18601
|
children: [
|
|
18448
|
-
/* @__PURE__ */
|
|
18602
|
+
/* @__PURE__ */ jsx106(
|
|
18449
18603
|
ParameterRichTextInner,
|
|
18450
18604
|
{
|
|
18451
18605
|
value,
|
|
@@ -18463,23 +18617,23 @@ var ParameterRichText = ({
|
|
|
18463
18617
|
children
|
|
18464
18618
|
}
|
|
18465
18619
|
),
|
|
18466
|
-
menuItems ? /* @__PURE__ */
|
|
18620
|
+
menuItems ? /* @__PURE__ */ jsx106(ParameterMenuButton, { label: `${label} menu`, children: /* @__PURE__ */ jsx106(Fragment20, { children: menuItems }) }) : null
|
|
18467
18621
|
]
|
|
18468
18622
|
}
|
|
18469
18623
|
);
|
|
18470
18624
|
};
|
|
18471
|
-
var editorWrapper =
|
|
18625
|
+
var editorWrapper = css85`
|
|
18472
18626
|
display: flex;
|
|
18473
18627
|
flex-flow: column;
|
|
18474
18628
|
flex-grow: 1;
|
|
18475
18629
|
`;
|
|
18476
|
-
var editorContainer =
|
|
18630
|
+
var editorContainer = css85`
|
|
18477
18631
|
display: flex;
|
|
18478
18632
|
flex-flow: column;
|
|
18479
18633
|
flex-grow: 1;
|
|
18480
18634
|
position: relative;
|
|
18481
18635
|
`;
|
|
18482
|
-
var editorPlaceholder =
|
|
18636
|
+
var editorPlaceholder = css85`
|
|
18483
18637
|
color: var(--gray-500);
|
|
18484
18638
|
font-style: italic;
|
|
18485
18639
|
/* 1px is added to make sure caret is clearly visible when field is focused
|
|
@@ -18490,7 +18644,7 @@ var editorPlaceholder = css84`
|
|
|
18490
18644
|
top: var(--spacing-xs);
|
|
18491
18645
|
user-select: none;
|
|
18492
18646
|
`;
|
|
18493
|
-
var editorInput =
|
|
18647
|
+
var editorInput = css85`
|
|
18494
18648
|
background: var(--white);
|
|
18495
18649
|
border: 1px solid var(--white);
|
|
18496
18650
|
border-radius: var(--rounded-sm);
|
|
@@ -18575,7 +18729,7 @@ var ParameterRichTextInner = ({
|
|
|
18575
18729
|
editable: !readOnly
|
|
18576
18730
|
};
|
|
18577
18731
|
return /* @__PURE__ */ jsxs71(Fragment20, { children: [
|
|
18578
|
-
/* @__PURE__ */
|
|
18732
|
+
/* @__PURE__ */ jsx106("div", { css: [editorWrapper], className: editorWrapperClassName, children: /* @__PURE__ */ jsx106(LexicalComposer, { initialConfig: lexicalConfig, children: /* @__PURE__ */ jsx106(
|
|
18579
18733
|
RichText,
|
|
18580
18734
|
{
|
|
18581
18735
|
onChange,
|
|
@@ -18614,12 +18768,12 @@ var RichText = ({
|
|
|
18614
18768
|
}) => {
|
|
18615
18769
|
const editorContainerRef = useRef7(null);
|
|
18616
18770
|
const [editor] = useLexicalComposerContext5();
|
|
18617
|
-
|
|
18771
|
+
useEffect15(() => {
|
|
18618
18772
|
if (onRichTextInit) {
|
|
18619
18773
|
onRichTextInit(editor);
|
|
18620
18774
|
}
|
|
18621
18775
|
}, [editor, onRichTextInit]);
|
|
18622
|
-
|
|
18776
|
+
useEffect15(() => {
|
|
18623
18777
|
const removeUpdateListener = editor.registerUpdateListener(({ editorState, prevEditorState }) => {
|
|
18624
18778
|
requestAnimationFrame(() => {
|
|
18625
18779
|
if (!deepEqual2(editorState.toJSON(), prevEditorState.toJSON())) {
|
|
@@ -18632,19 +18786,19 @@ var RichText = ({
|
|
|
18632
18786
|
};
|
|
18633
18787
|
}, []);
|
|
18634
18788
|
return /* @__PURE__ */ jsxs71(Fragment20, { children: [
|
|
18635
|
-
readOnly ? null : /* @__PURE__ */
|
|
18789
|
+
readOnly ? null : /* @__PURE__ */ jsx106(RichTextToolbar_default, { config, customControls }),
|
|
18636
18790
|
/* @__PURE__ */ jsxs71("div", { css: editorContainer, ref: editorContainerRef, "data-testid": "value-container", children: [
|
|
18637
|
-
/* @__PURE__ */
|
|
18791
|
+
/* @__PURE__ */ jsx106(
|
|
18638
18792
|
RichTextPlugin,
|
|
18639
18793
|
{
|
|
18640
|
-
contentEditable: /* @__PURE__ */
|
|
18641
|
-
placeholder: /* @__PURE__ */
|
|
18794
|
+
contentEditable: /* @__PURE__ */ jsx106(ContentEditable, { css: editorInput, className: editorInputClassName }),
|
|
18795
|
+
placeholder: /* @__PURE__ */ jsx106("div", { css: editorPlaceholder, children: readOnly ? "empty" : "start editing..." }),
|
|
18642
18796
|
ErrorBoundary: LexicalErrorBoundary
|
|
18643
18797
|
}
|
|
18644
18798
|
),
|
|
18645
|
-
/* @__PURE__ */
|
|
18646
|
-
readOnly ? null : /* @__PURE__ */
|
|
18647
|
-
/* @__PURE__ */
|
|
18799
|
+
/* @__PURE__ */ jsx106(ListPlugin, {}),
|
|
18800
|
+
readOnly ? null : /* @__PURE__ */ jsx106(HistoryPlugin, {}),
|
|
18801
|
+
/* @__PURE__ */ jsx106(
|
|
18648
18802
|
LinkNodePlugin,
|
|
18649
18803
|
{
|
|
18650
18804
|
onConnectLink: onConnectLink ? onConnectLink : () => Promise.resolve(),
|
|
@@ -18654,21 +18808,21 @@ var RichText = ({
|
|
|
18654
18808
|
} : void 0
|
|
18655
18809
|
}
|
|
18656
18810
|
),
|
|
18657
|
-
/* @__PURE__ */
|
|
18658
|
-
/* @__PURE__ */
|
|
18659
|
-
/* @__PURE__ */
|
|
18660
|
-
/* @__PURE__ */
|
|
18811
|
+
/* @__PURE__ */ jsx106(ListIndentPlugin, { maxDepth: 4 }),
|
|
18812
|
+
/* @__PURE__ */ jsx106(DisableStylesPlugin, {}),
|
|
18813
|
+
/* @__PURE__ */ jsx106(MarkdownShortcutPlugin, { transformers: MARKDOWN_TRANSFORMERS }),
|
|
18814
|
+
/* @__PURE__ */ jsx106(Fragment20, { children })
|
|
18661
18815
|
] })
|
|
18662
18816
|
] });
|
|
18663
18817
|
};
|
|
18664
18818
|
|
|
18665
18819
|
// src/components/ParameterInputs/ParameterSelect.tsx
|
|
18666
18820
|
import { forwardRef as forwardRef15 } from "react";
|
|
18667
|
-
import { jsx as
|
|
18821
|
+
import { jsx as jsx107, jsxs as jsxs72 } from "@emotion/react/jsx-runtime";
|
|
18668
18822
|
var ParameterSelect = forwardRef15(
|
|
18669
18823
|
({ defaultOption, options, ...props }, ref) => {
|
|
18670
18824
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
18671
|
-
return /* @__PURE__ */
|
|
18825
|
+
return /* @__PURE__ */ jsx107(ParameterShell, { ...shellProps, children: /* @__PURE__ */ jsx107(ParameterSelectInner, { options, defaultOption, ...innerProps, ref }) });
|
|
18672
18826
|
}
|
|
18673
18827
|
);
|
|
18674
18828
|
var ParameterSelectInner = forwardRef15(
|
|
@@ -18683,10 +18837,10 @@ var ParameterSelectInner = forwardRef15(
|
|
|
18683
18837
|
ref,
|
|
18684
18838
|
...props,
|
|
18685
18839
|
children: [
|
|
18686
|
-
defaultOption ? /* @__PURE__ */
|
|
18840
|
+
defaultOption ? /* @__PURE__ */ jsx107("option", { value: "", children: defaultOption }) : null,
|
|
18687
18841
|
options.map((option) => {
|
|
18688
18842
|
var _a;
|
|
18689
|
-
return /* @__PURE__ */
|
|
18843
|
+
return /* @__PURE__ */ jsx107("option", { value: (_a = option.value) != null ? _a : option.label, children: option.label }, option.label);
|
|
18690
18844
|
})
|
|
18691
18845
|
]
|
|
18692
18846
|
}
|
|
@@ -18696,14 +18850,14 @@ var ParameterSelectInner = forwardRef15(
|
|
|
18696
18850
|
|
|
18697
18851
|
// src/components/ParameterInputs/ParameterTextarea.tsx
|
|
18698
18852
|
import { forwardRef as forwardRef16 } from "react";
|
|
18699
|
-
import { jsx as
|
|
18853
|
+
import { jsx as jsx108 } from "@emotion/react/jsx-runtime";
|
|
18700
18854
|
var ParameterTextarea = forwardRef16((props, ref) => {
|
|
18701
18855
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
18702
|
-
return /* @__PURE__ */
|
|
18856
|
+
return /* @__PURE__ */ jsx108(ParameterShell, { "data-testid": "parameter-textarea", ...shellProps, children: /* @__PURE__ */ jsx108(ParameterTextareaInner, { ref, ...innerProps }) });
|
|
18703
18857
|
});
|
|
18704
18858
|
var ParameterTextareaInner = forwardRef16(({ ...props }, ref) => {
|
|
18705
18859
|
const { id, label, hiddenLabel } = useParameterShell();
|
|
18706
|
-
return /* @__PURE__ */
|
|
18860
|
+
return /* @__PURE__ */ jsx108(
|
|
18707
18861
|
"textarea",
|
|
18708
18862
|
{
|
|
18709
18863
|
css: [input2, textarea2],
|
|
@@ -18717,24 +18871,24 @@ var ParameterTextareaInner = forwardRef16(({ ...props }, ref) => {
|
|
|
18717
18871
|
|
|
18718
18872
|
// src/components/ParameterInputs/ParameterToggle.tsx
|
|
18719
18873
|
import { forwardRef as forwardRef17 } from "react";
|
|
18720
|
-
import { jsx as
|
|
18874
|
+
import { jsx as jsx109, jsxs as jsxs73 } from "@emotion/react/jsx-runtime";
|
|
18721
18875
|
var ParameterToggle = forwardRef17((props, ref) => {
|
|
18722
18876
|
const { shellProps, innerProps } = extractParameterProps(props);
|
|
18723
|
-
return /* @__PURE__ */
|
|
18877
|
+
return /* @__PURE__ */ jsx109(ParameterShell, { ...shellProps, children: /* @__PURE__ */ jsx109(ParameterToggleInner, { ref, ...innerProps }) });
|
|
18724
18878
|
});
|
|
18725
18879
|
var ParameterToggleInner = forwardRef17(
|
|
18726
18880
|
({ ...props }, ref) => {
|
|
18727
18881
|
const { id, label } = useParameterShell();
|
|
18728
18882
|
return /* @__PURE__ */ jsxs73("label", { css: inputToggleLabel2, children: [
|
|
18729
|
-
/* @__PURE__ */
|
|
18730
|
-
/* @__PURE__ */
|
|
18883
|
+
/* @__PURE__ */ jsx109("input", { css: toggleInput2, type: props.type, id, ref, ...props }),
|
|
18884
|
+
/* @__PURE__ */ jsx109("span", { css: inlineLabel2, children: label })
|
|
18731
18885
|
] });
|
|
18732
18886
|
}
|
|
18733
18887
|
);
|
|
18734
18888
|
|
|
18735
18889
|
// src/components/ProgressBar/ProgressBar.styles.ts
|
|
18736
|
-
import { css as
|
|
18737
|
-
var
|
|
18890
|
+
import { css as css86, keyframes as keyframes4 } from "@emotion/react";
|
|
18891
|
+
var container2 = css86`
|
|
18738
18892
|
background: var(--gray-50);
|
|
18739
18893
|
margin-block: var(--spacing-sm);
|
|
18740
18894
|
position: relative;
|
|
@@ -18744,14 +18898,42 @@ var container = css85`
|
|
|
18744
18898
|
border: solid 1px var(--gray-300);
|
|
18745
18899
|
`;
|
|
18746
18900
|
var themeMap = {
|
|
18747
|
-
primary:
|
|
18748
|
-
|
|
18901
|
+
primary: css86`
|
|
18902
|
+
--progress-color: var(--accent-light);
|
|
18903
|
+
`,
|
|
18904
|
+
secondary: css86`
|
|
18905
|
+
--progress-color: var(--accent-alt-light);
|
|
18749
18906
|
`,
|
|
18750
|
-
|
|
18751
|
-
|
|
18907
|
+
destructive: css86`
|
|
18908
|
+
--progress-color: var(--brand-secondary-5);
|
|
18752
18909
|
`
|
|
18753
18910
|
};
|
|
18754
|
-
var
|
|
18911
|
+
var slidingBackgroundPosition = keyframes4`
|
|
18912
|
+
from {
|
|
18913
|
+
background-position: 0 0;
|
|
18914
|
+
}
|
|
18915
|
+
to {
|
|
18916
|
+
background-position: 64px 0;
|
|
18917
|
+
}
|
|
18918
|
+
`;
|
|
18919
|
+
var determinate = css86`
|
|
18920
|
+
background-color: var(--progress-color);
|
|
18921
|
+
`;
|
|
18922
|
+
var indeterminate = css86`
|
|
18923
|
+
background-image: linear-gradient(
|
|
18924
|
+
45deg,
|
|
18925
|
+
var(--progress-color) 25%,
|
|
18926
|
+
transparent 25%,
|
|
18927
|
+
transparent 50%,
|
|
18928
|
+
var(--progress-color) 50%,
|
|
18929
|
+
var(--progress-color) 75%,
|
|
18930
|
+
transparent 75%,
|
|
18931
|
+
transparent
|
|
18932
|
+
);
|
|
18933
|
+
background-size: 64px 64px;
|
|
18934
|
+
animation: ${slidingBackgroundPosition} 1s linear infinite;
|
|
18935
|
+
`;
|
|
18936
|
+
var bar = css86`
|
|
18755
18937
|
position: absolute;
|
|
18756
18938
|
inset: 0;
|
|
18757
18939
|
transition: transform var(--duration-fast) var(--timing-ease-out);
|
|
@@ -18759,25 +18941,35 @@ var bar = css85`
|
|
|
18759
18941
|
`;
|
|
18760
18942
|
|
|
18761
18943
|
// src/components/ProgressBar/ProgressBar.tsx
|
|
18762
|
-
import { jsx as
|
|
18763
|
-
function ProgressBar({
|
|
18944
|
+
import { jsx as jsx110 } from "@emotion/react/jsx-runtime";
|
|
18945
|
+
function ProgressBar({
|
|
18946
|
+
current,
|
|
18947
|
+
max,
|
|
18948
|
+
theme = "primary",
|
|
18949
|
+
variant = "determinate",
|
|
18950
|
+
...props
|
|
18951
|
+
}) {
|
|
18764
18952
|
const valueNow = Math.min(current, max);
|
|
18765
18953
|
const valuePercentage = max > 0 ? Math.ceil(100 / max * valueNow) : 0;
|
|
18766
|
-
return /* @__PURE__ */
|
|
18954
|
+
return /* @__PURE__ */ jsx110(
|
|
18767
18955
|
"div",
|
|
18768
18956
|
{
|
|
18769
|
-
|
|
18770
|
-
css: container,
|
|
18957
|
+
css: container2,
|
|
18771
18958
|
role: "progressbar",
|
|
18772
18959
|
"aria-busy": valuePercentage !== 100,
|
|
18773
18960
|
"aria-invalid": false,
|
|
18774
18961
|
"aria-valuemin": 0,
|
|
18775
18962
|
"aria-valuemax": max,
|
|
18776
18963
|
"aria-valuenow": valueNow,
|
|
18777
|
-
|
|
18964
|
+
...props,
|
|
18965
|
+
children: /* @__PURE__ */ jsx110(
|
|
18778
18966
|
"div",
|
|
18779
18967
|
{
|
|
18780
|
-
css: [
|
|
18968
|
+
css: [
|
|
18969
|
+
themeMap[theme],
|
|
18970
|
+
variant === "indeterminate" ? indeterminate : determinate,
|
|
18971
|
+
bar
|
|
18972
|
+
],
|
|
18781
18973
|
style: {
|
|
18782
18974
|
transform: `scaleX(${valuePercentage / 100})`
|
|
18783
18975
|
},
|
|
@@ -18789,28 +18981,28 @@ function ProgressBar({ className, current, max, theme = "primary" }) {
|
|
|
18789
18981
|
}
|
|
18790
18982
|
|
|
18791
18983
|
// src/components/ProgressList/ProgressList.tsx
|
|
18792
|
-
import { css as
|
|
18984
|
+
import { css as css88 } from "@emotion/react";
|
|
18793
18985
|
import { CgCheckO as CgCheckO2 } from "@react-icons/all-files/cg/CgCheckO";
|
|
18794
18986
|
import { CgRadioCheck } from "@react-icons/all-files/cg/CgRadioCheck";
|
|
18795
18987
|
import { CgRecord } from "@react-icons/all-files/cg/CgRecord";
|
|
18796
18988
|
import { useMemo as useMemo4 } from "react";
|
|
18797
18989
|
|
|
18798
18990
|
// src/components/ProgressList/styles/ProgressList.styles.ts
|
|
18799
|
-
import { css as
|
|
18800
|
-
var progressListStyles =
|
|
18991
|
+
import { css as css87 } from "@emotion/react";
|
|
18992
|
+
var progressListStyles = css87`
|
|
18801
18993
|
display: flex;
|
|
18802
18994
|
flex-direction: column;
|
|
18803
18995
|
gap: var(--spacing-sm);
|
|
18804
18996
|
list-style-type: none;
|
|
18805
18997
|
`;
|
|
18806
|
-
var progressListItemStyles =
|
|
18998
|
+
var progressListItemStyles = css87`
|
|
18807
18999
|
display: flex;
|
|
18808
19000
|
gap: var(--spacing-base);
|
|
18809
19001
|
align-items: center;
|
|
18810
19002
|
`;
|
|
18811
19003
|
|
|
18812
19004
|
// src/components/ProgressList/ProgressList.tsx
|
|
18813
|
-
import { jsx as
|
|
19005
|
+
import { jsx as jsx111, jsxs as jsxs74 } from "@emotion/react/jsx-runtime";
|
|
18814
19006
|
var ProgressList = ({ inProgressId, items, autoEllipsis, ...htmlProps }) => {
|
|
18815
19007
|
const itemsWithStatus = useMemo4(() => {
|
|
18816
19008
|
const indexOfInProgressItem = items.findIndex(({ id }) => id === inProgressId);
|
|
@@ -18824,8 +19016,8 @@ var ProgressList = ({ inProgressId, items, autoEllipsis, ...htmlProps }) => {
|
|
|
18824
19016
|
return { ...item, status };
|
|
18825
19017
|
});
|
|
18826
19018
|
}, [items, inProgressId]);
|
|
18827
|
-
return /* @__PURE__ */
|
|
18828
|
-
return /* @__PURE__ */
|
|
19019
|
+
return /* @__PURE__ */ jsx111("ol", { css: progressListStyles, ...htmlProps, children: itemsWithStatus.map(({ id, label, status, error, errorLevel }) => {
|
|
19020
|
+
return /* @__PURE__ */ jsx111(
|
|
18829
19021
|
ProgressListItem,
|
|
18830
19022
|
{
|
|
18831
19023
|
status,
|
|
@@ -18858,12 +19050,12 @@ var ProgressListItem = ({
|
|
|
18858
19050
|
}, [status, error]);
|
|
18859
19051
|
const statusStyles = useMemo4(() => {
|
|
18860
19052
|
if (error) {
|
|
18861
|
-
return errorLevel === "caution" ?
|
|
19053
|
+
return errorLevel === "caution" ? css88`
|
|
18862
19054
|
color: rgb(161, 98, 7);
|
|
18863
19055
|
& svg {
|
|
18864
19056
|
color: rgb(250, 204, 21);
|
|
18865
19057
|
}
|
|
18866
|
-
` :
|
|
19058
|
+
` : css88`
|
|
18867
19059
|
color: rgb(185, 28, 28);
|
|
18868
19060
|
& svg {
|
|
18869
19061
|
color: var(--brand-primary-2);
|
|
@@ -18871,35 +19063,35 @@ var ProgressListItem = ({
|
|
|
18871
19063
|
`;
|
|
18872
19064
|
}
|
|
18873
19065
|
const colorPerStatus = {
|
|
18874
|
-
completed:
|
|
19066
|
+
completed: css88`
|
|
18875
19067
|
opacity: 0.75;
|
|
18876
19068
|
`,
|
|
18877
|
-
inProgress:
|
|
19069
|
+
inProgress: css88`
|
|
18878
19070
|
-webkit-text-stroke-width: thin;
|
|
18879
19071
|
`,
|
|
18880
|
-
queued:
|
|
19072
|
+
queued: css88`
|
|
18881
19073
|
opacity: 0.5;
|
|
18882
19074
|
`
|
|
18883
19075
|
};
|
|
18884
19076
|
return colorPerStatus[status];
|
|
18885
19077
|
}, [status, error, errorLevel]);
|
|
18886
19078
|
return /* @__PURE__ */ jsxs74("li", { css: [progressListItemStyles, statusStyles], children: [
|
|
18887
|
-
/* @__PURE__ */
|
|
19079
|
+
/* @__PURE__ */ jsx111(Tooltip, { title: error != null ? error : "", children: /* @__PURE__ */ jsx111("div", { children: /* @__PURE__ */ jsx111(Icon, { icon, size: 20, iconColor: "currentColor" }) }) }),
|
|
18888
19080
|
/* @__PURE__ */ jsxs74("div", { children: [
|
|
18889
19081
|
children,
|
|
18890
|
-
/* @__PURE__ */
|
|
19082
|
+
/* @__PURE__ */ jsx111("span", { css: { visibility: autoEllipsis && status === "inProgress" && !error ? "visible" : "hidden" }, children: "..." })
|
|
18891
19083
|
] })
|
|
18892
19084
|
] });
|
|
18893
19085
|
};
|
|
18894
19086
|
|
|
18895
19087
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
18896
|
-
import { css as
|
|
19088
|
+
import { css as css90 } from "@emotion/react";
|
|
18897
19089
|
import { CgCheck as CgCheck4 } from "@react-icons/all-files/cg/CgCheck";
|
|
18898
19090
|
import { useCallback as useCallback7, useMemo as useMemo5 } from "react";
|
|
18899
19091
|
|
|
18900
19092
|
// src/components/SegmentedControl/SegmentedControl.styles.ts
|
|
18901
|
-
import { css as
|
|
18902
|
-
var segmentedControlStyles =
|
|
19093
|
+
import { css as css89 } from "@emotion/react";
|
|
19094
|
+
var segmentedControlStyles = css89`
|
|
18903
19095
|
--segmented-control-rounded-value: var(--rounded-base);
|
|
18904
19096
|
--segmented-control-border-width: 1px;
|
|
18905
19097
|
--segmented-control-selected-color: var(--brand-secondary-3);
|
|
@@ -18918,14 +19110,14 @@ var segmentedControlStyles = css88`
|
|
|
18918
19110
|
border-radius: calc(var(--segmented-control-rounded-value) + var(--segmented-control-border-width));
|
|
18919
19111
|
font-size: var(--fs-xs);
|
|
18920
19112
|
`;
|
|
18921
|
-
var segmentedControlVerticalStyles =
|
|
19113
|
+
var segmentedControlVerticalStyles = css89`
|
|
18922
19114
|
flex-direction: column;
|
|
18923
19115
|
--segmented-control-first-border-radius: var(--segmented-control-rounded-value)
|
|
18924
19116
|
var(--segmented-control-rounded-value) 0 0;
|
|
18925
19117
|
--segmented-control-last-border-radius: 0 0 var(--segmented-control-rounded-value)
|
|
18926
19118
|
var(--segmented-control-rounded-value);
|
|
18927
19119
|
`;
|
|
18928
|
-
var segmentedControlItemStyles =
|
|
19120
|
+
var segmentedControlItemStyles = css89`
|
|
18929
19121
|
&:first-of-type label {
|
|
18930
19122
|
border-radius: var(--segmented-control-first-border-radius);
|
|
18931
19123
|
}
|
|
@@ -18933,10 +19125,10 @@ var segmentedControlItemStyles = css88`
|
|
|
18933
19125
|
border-radius: var(--segmented-control-last-border-radius);
|
|
18934
19126
|
}
|
|
18935
19127
|
`;
|
|
18936
|
-
var segmentedControlInputStyles =
|
|
19128
|
+
var segmentedControlInputStyles = css89`
|
|
18937
19129
|
${accessibleHidden}
|
|
18938
19130
|
`;
|
|
18939
|
-
var segmentedControlLabelStyles = (checked,
|
|
19131
|
+
var segmentedControlLabelStyles = (checked, disabled2) => css89`
|
|
18940
19132
|
position: relative;
|
|
18941
19133
|
display: flex;
|
|
18942
19134
|
align-items: center;
|
|
@@ -18978,7 +19170,7 @@ var segmentedControlLabelStyles = (checked, disabled) => css88`
|
|
|
18978
19170
|
// once Firefox supports :has selector
|
|
18979
19171
|
@supports not selector(:has(*)) {
|
|
18980
19172
|
// equivalent to &:has(:checked:not(:disabled))
|
|
18981
|
-
${checked && !
|
|
19173
|
+
${checked && !disabled2 ? `
|
|
18982
19174
|
background-color: var(--segmented-control-selected-color);
|
|
18983
19175
|
outline: var(--segmented-control-border-width) solid var(--segmented-control-selected-color);
|
|
18984
19176
|
box-shadow: 0 0.43em 1.7em 0 rgba(0, 0, 0, 0.15);
|
|
@@ -18988,45 +19180,45 @@ var segmentedControlLabelStyles = (checked, disabled) => css88`
|
|
|
18988
19180
|
|
|
18989
19181
|
// equivalent to &:hover:not(:has(:disabled, :checked))
|
|
18990
19182
|
&:hover {
|
|
18991
|
-
${!checked && !
|
|
19183
|
+
${!checked && !disabled2 ? `background-color: var(--gray-100);` : void 0}
|
|
18992
19184
|
}
|
|
18993
19185
|
|
|
18994
19186
|
// equivalent to &:has(:disabled)
|
|
18995
|
-
${
|
|
19187
|
+
${disabled2 ? `
|
|
18996
19188
|
color: var(--gray-400);
|
|
18997
19189
|
cursor: default;` : void 0}
|
|
18998
19190
|
|
|
18999
19191
|
// equivalent to &:has(:checked:disabled)
|
|
19000
|
-
${checked &&
|
|
19192
|
+
${checked && disabled2 && `
|
|
19001
19193
|
color: var(--gray-50);
|
|
19002
19194
|
background-color: var(--gray-400);
|
|
19003
19195
|
`}
|
|
19004
19196
|
}
|
|
19005
19197
|
`;
|
|
19006
|
-
var segmentedControlLabelIconOnlyStyles =
|
|
19198
|
+
var segmentedControlLabelIconOnlyStyles = css89`
|
|
19007
19199
|
padding-inline: 0.5em;
|
|
19008
19200
|
`;
|
|
19009
|
-
var segmentedControlLabelCheckStyles =
|
|
19201
|
+
var segmentedControlLabelCheckStyles = css89`
|
|
19010
19202
|
opacity: 0.5;
|
|
19011
19203
|
`;
|
|
19012
|
-
var segmentedControlLabelContentStyles =
|
|
19204
|
+
var segmentedControlLabelContentStyles = css89`
|
|
19013
19205
|
display: flex;
|
|
19014
19206
|
align-items: center;
|
|
19015
19207
|
justify-content: center;
|
|
19016
19208
|
gap: var(--spacing-sm);
|
|
19017
19209
|
height: 100%;
|
|
19018
19210
|
`;
|
|
19019
|
-
var segmentedControlLabelTextStyles =
|
|
19211
|
+
var segmentedControlLabelTextStyles = css89``;
|
|
19020
19212
|
|
|
19021
19213
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
19022
|
-
import { jsx as
|
|
19214
|
+
import { jsx as jsx112, jsxs as jsxs75 } from "@emotion/react/jsx-runtime";
|
|
19023
19215
|
var SegmentedControl = ({
|
|
19024
19216
|
name,
|
|
19025
19217
|
options,
|
|
19026
19218
|
value,
|
|
19027
19219
|
onChange,
|
|
19028
19220
|
noCheckmark = false,
|
|
19029
|
-
disabled = false,
|
|
19221
|
+
disabled: disabled2 = false,
|
|
19030
19222
|
orientation = "horizontal",
|
|
19031
19223
|
size = "md",
|
|
19032
19224
|
...props
|
|
@@ -19041,28 +19233,28 @@ var SegmentedControl = ({
|
|
|
19041
19233
|
);
|
|
19042
19234
|
const sizeStyles = useMemo5(() => {
|
|
19043
19235
|
const map = {
|
|
19044
|
-
sm:
|
|
19045
|
-
md:
|
|
19046
|
-
lg:
|
|
19236
|
+
sm: css90({ height: "calc(24px - 2px)", fontSize: "var(--fs-xs)" }),
|
|
19237
|
+
md: css90({ height: "calc(32px - 2px)", fontSize: "var(--fs-sm)" }),
|
|
19238
|
+
lg: css90({ height: "calc(40px - 2px)", fontSize: "var(--fs-base)" })
|
|
19047
19239
|
};
|
|
19048
19240
|
return map[size];
|
|
19049
19241
|
}, [size]);
|
|
19050
19242
|
const isIconOnly = useMemo5(() => {
|
|
19051
19243
|
return options.every((option) => option.icon && !option.label);
|
|
19052
19244
|
}, [options]);
|
|
19053
|
-
return /* @__PURE__ */
|
|
19245
|
+
return /* @__PURE__ */ jsx112(
|
|
19054
19246
|
"div",
|
|
19055
19247
|
{
|
|
19056
19248
|
css: [segmentedControlStyles, orientation === "vertical" ? segmentedControlVerticalStyles : void 0],
|
|
19057
19249
|
...props,
|
|
19058
19250
|
children: options.map((option, index) => {
|
|
19059
19251
|
const text = option.label ? option.label : option.icon ? null : String(option.value);
|
|
19060
|
-
const isDisabled =
|
|
19061
|
-
return /* @__PURE__ */
|
|
19252
|
+
const isDisabled = disabled2 || option.disabled;
|
|
19253
|
+
return /* @__PURE__ */ jsx112(
|
|
19062
19254
|
Tooltip,
|
|
19063
19255
|
{
|
|
19064
19256
|
title: isDisabled || !option.tooltip ? "" : option.tooltip,
|
|
19065
|
-
children: /* @__PURE__ */
|
|
19257
|
+
children: /* @__PURE__ */ jsx112("div", { css: segmentedControlItemStyles, "data-testid": "container-segmented-control", children: /* @__PURE__ */ jsxs75(
|
|
19066
19258
|
"label",
|
|
19067
19259
|
{
|
|
19068
19260
|
css: [
|
|
@@ -19071,7 +19263,7 @@ var SegmentedControl = ({
|
|
|
19071
19263
|
isIconOnly ? segmentedControlLabelIconOnlyStyles : void 0
|
|
19072
19264
|
],
|
|
19073
19265
|
children: [
|
|
19074
|
-
/* @__PURE__ */
|
|
19266
|
+
/* @__PURE__ */ jsx112(
|
|
19075
19267
|
"input",
|
|
19076
19268
|
{
|
|
19077
19269
|
css: segmentedControlInputStyles,
|
|
@@ -19083,10 +19275,10 @@ var SegmentedControl = ({
|
|
|
19083
19275
|
disabled: isDisabled
|
|
19084
19276
|
}
|
|
19085
19277
|
),
|
|
19086
|
-
option.value !== value || noCheckmark ? null : /* @__PURE__ */
|
|
19278
|
+
option.value !== value || noCheckmark ? null : /* @__PURE__ */ jsx112(CgCheck4, { css: segmentedControlLabelCheckStyles, "aria-label": "Selected", size: "1.5em" }),
|
|
19087
19279
|
/* @__PURE__ */ jsxs75("span", { css: segmentedControlLabelContentStyles, children: [
|
|
19088
|
-
!option.icon ? null : /* @__PURE__ */
|
|
19089
|
-
!text ? null : /* @__PURE__ */
|
|
19280
|
+
!option.icon ? null : /* @__PURE__ */ jsx112(Icon, { icon: option.icon, size: "1.5em", iconColor: "currentColor" }),
|
|
19281
|
+
!text ? null : /* @__PURE__ */ jsx112("span", { css: segmentedControlLabelTextStyles, children: text })
|
|
19090
19282
|
] })
|
|
19091
19283
|
]
|
|
19092
19284
|
}
|
|
@@ -19100,18 +19292,18 @@ var SegmentedControl = ({
|
|
|
19100
19292
|
};
|
|
19101
19293
|
|
|
19102
19294
|
// src/components/Skeleton/Skeleton.styles.ts
|
|
19103
|
-
import { css as
|
|
19104
|
-
var lightFadingOut =
|
|
19295
|
+
import { css as css91, keyframes as keyframes5 } from "@emotion/react";
|
|
19296
|
+
var lightFadingOut = keyframes5`
|
|
19105
19297
|
from { opacity: 0.1; }
|
|
19106
19298
|
to { opacity: 0.025; }
|
|
19107
19299
|
`;
|
|
19108
|
-
var skeletonStyles =
|
|
19300
|
+
var skeletonStyles = css91`
|
|
19109
19301
|
animation: ${lightFadingOut} 1s ease-out infinite alternate;
|
|
19110
19302
|
background-color: var(--gray-900);
|
|
19111
19303
|
`;
|
|
19112
19304
|
|
|
19113
19305
|
// src/components/Skeleton/Skeleton.tsx
|
|
19114
|
-
import { jsx as
|
|
19306
|
+
import { jsx as jsx113 } from "@emotion/react/jsx-runtime";
|
|
19115
19307
|
var Skeleton = ({
|
|
19116
19308
|
width = "100%",
|
|
19117
19309
|
height = "1.25rem",
|
|
@@ -19119,7 +19311,7 @@ var Skeleton = ({
|
|
|
19119
19311
|
circle = false,
|
|
19120
19312
|
children,
|
|
19121
19313
|
...otherProps
|
|
19122
|
-
}) => /* @__PURE__ */
|
|
19314
|
+
}) => /* @__PURE__ */ jsx113(
|
|
19123
19315
|
"div",
|
|
19124
19316
|
{
|
|
19125
19317
|
css: [
|
|
@@ -19142,8 +19334,8 @@ var Skeleton = ({
|
|
|
19142
19334
|
import * as React23 from "react";
|
|
19143
19335
|
|
|
19144
19336
|
// src/components/Switch/Switch.styles.ts
|
|
19145
|
-
import { css as
|
|
19146
|
-
var SwitchInputContainer =
|
|
19337
|
+
import { css as css92 } from "@emotion/react";
|
|
19338
|
+
var SwitchInputContainer = css92`
|
|
19147
19339
|
cursor: pointer;
|
|
19148
19340
|
display: inline-block;
|
|
19149
19341
|
position: relative;
|
|
@@ -19152,7 +19344,7 @@ var SwitchInputContainer = css91`
|
|
|
19152
19344
|
vertical-align: middle;
|
|
19153
19345
|
user-select: none;
|
|
19154
19346
|
`;
|
|
19155
|
-
var SwitchInput =
|
|
19347
|
+
var SwitchInput = css92`
|
|
19156
19348
|
appearance: none;
|
|
19157
19349
|
border-radius: var(--rounded-full);
|
|
19158
19350
|
background-color: var(--white);
|
|
@@ -19190,7 +19382,7 @@ var SwitchInput = css91`
|
|
|
19190
19382
|
cursor: not-allowed;
|
|
19191
19383
|
}
|
|
19192
19384
|
`;
|
|
19193
|
-
var SwitchInputDisabled =
|
|
19385
|
+
var SwitchInputDisabled = css92`
|
|
19194
19386
|
opacity: var(--opacity-50);
|
|
19195
19387
|
cursor: not-allowed;
|
|
19196
19388
|
|
|
@@ -19198,11 +19390,10 @@ var SwitchInputDisabled = css91`
|
|
|
19198
19390
|
cursor: not-allowed;
|
|
19199
19391
|
}
|
|
19200
19392
|
`;
|
|
19201
|
-
var SwitchInputLabel =
|
|
19393
|
+
var SwitchInputLabel = css92`
|
|
19202
19394
|
align-items: center;
|
|
19203
19395
|
color: var(--brand-secondary-1);
|
|
19204
19396
|
display: inline-flex;
|
|
19205
|
-
font-weight: var(--fw-bold);
|
|
19206
19397
|
line-height: 1.25;
|
|
19207
19398
|
padding-inline: var(--spacing-2xl) 0;
|
|
19208
19399
|
|
|
@@ -19220,14 +19411,14 @@ var SwitchInputLabel = css91`
|
|
|
19220
19411
|
top: 0;
|
|
19221
19412
|
}
|
|
19222
19413
|
`;
|
|
19223
|
-
var SwitchText =
|
|
19414
|
+
var SwitchText = css92`
|
|
19224
19415
|
color: var(--gray-500);
|
|
19225
19416
|
font-size: var(--fs-sm);
|
|
19226
19417
|
padding-inline: var(--spacing-2xl) 0;
|
|
19227
19418
|
`;
|
|
19228
19419
|
|
|
19229
19420
|
// src/components/Switch/Switch.tsx
|
|
19230
|
-
import { Fragment as Fragment21, jsx as
|
|
19421
|
+
import { Fragment as Fragment21, jsx as jsx114, jsxs as jsxs76 } from "@emotion/react/jsx-runtime";
|
|
19231
19422
|
var Switch = React23.forwardRef(
|
|
19232
19423
|
({ label, infoText, toggleText, children, ...inputProps }, ref) => {
|
|
19233
19424
|
let additionalText = infoText;
|
|
@@ -19236,10 +19427,10 @@ var Switch = React23.forwardRef(
|
|
|
19236
19427
|
}
|
|
19237
19428
|
return /* @__PURE__ */ jsxs76(Fragment21, { children: [
|
|
19238
19429
|
/* @__PURE__ */ jsxs76("label", { css: [SwitchInputContainer, inputProps.disabled ? SwitchInputDisabled : void 0], children: [
|
|
19239
|
-
/* @__PURE__ */
|
|
19240
|
-
/* @__PURE__ */
|
|
19430
|
+
/* @__PURE__ */ jsx114("input", { type: "checkbox", css: SwitchInput, ...inputProps, ref }),
|
|
19431
|
+
/* @__PURE__ */ jsx114("span", { css: SwitchInputLabel, children: label })
|
|
19241
19432
|
] }),
|
|
19242
|
-
additionalText ? /* @__PURE__ */
|
|
19433
|
+
additionalText ? /* @__PURE__ */ jsx114("p", { css: SwitchText, children: additionalText }) : null,
|
|
19243
19434
|
children
|
|
19244
19435
|
] });
|
|
19245
19436
|
}
|
|
@@ -19249,8 +19440,8 @@ var Switch = React23.forwardRef(
|
|
|
19249
19440
|
import * as React24 from "react";
|
|
19250
19441
|
|
|
19251
19442
|
// src/components/Table/Table.styles.ts
|
|
19252
|
-
import { css as
|
|
19253
|
-
var table = ({ cellPadding = "var(--spacing-base) var(--spacing-md)" }) =>
|
|
19443
|
+
import { css as css93 } from "@emotion/react";
|
|
19444
|
+
var table = ({ cellPadding = "var(--spacing-base) var(--spacing-md)" }) => css93`
|
|
19254
19445
|
border-bottom: 1px solid var(--gray-400);
|
|
19255
19446
|
border-collapse: collapse;
|
|
19256
19447
|
min-width: 100%;
|
|
@@ -19261,60 +19452,60 @@ var table = ({ cellPadding = "var(--spacing-base) var(--spacing-md)" }) => css92
|
|
|
19261
19452
|
padding: ${cellPadding};
|
|
19262
19453
|
}
|
|
19263
19454
|
`;
|
|
19264
|
-
var tableHead =
|
|
19455
|
+
var tableHead = css93`
|
|
19265
19456
|
background: var(--gray-100);
|
|
19266
19457
|
color: var(--brand-secondary-1);
|
|
19267
19458
|
text-align: left;
|
|
19268
19459
|
`;
|
|
19269
|
-
var tableRow =
|
|
19460
|
+
var tableRow = css93`
|
|
19270
19461
|
border-bottom: 1px solid var(--gray-200);
|
|
19271
19462
|
`;
|
|
19272
|
-
var tableCellHead =
|
|
19463
|
+
var tableCellHead = css93`
|
|
19273
19464
|
font-size: var(--fs-sm);
|
|
19274
19465
|
text-transform: uppercase;
|
|
19275
19466
|
font-weight: var(--fw-bold);
|
|
19276
19467
|
`;
|
|
19277
19468
|
|
|
19278
19469
|
// src/components/Table/Table.tsx
|
|
19279
|
-
import { jsx as
|
|
19470
|
+
import { jsx as jsx115 } from "@emotion/react/jsx-runtime";
|
|
19280
19471
|
var Table = React24.forwardRef(
|
|
19281
19472
|
({ children, cellPadding, ...otherProps }, ref) => {
|
|
19282
|
-
return /* @__PURE__ */
|
|
19473
|
+
return /* @__PURE__ */ jsx115("table", { ref, css: table({ cellPadding }), ...otherProps, children });
|
|
19283
19474
|
}
|
|
19284
19475
|
);
|
|
19285
19476
|
var TableHead = React24.forwardRef(
|
|
19286
19477
|
({ children, ...otherProps }, ref) => {
|
|
19287
|
-
return /* @__PURE__ */
|
|
19478
|
+
return /* @__PURE__ */ jsx115("thead", { ref, css: tableHead, ...otherProps, children });
|
|
19288
19479
|
}
|
|
19289
19480
|
);
|
|
19290
19481
|
var TableBody = React24.forwardRef(
|
|
19291
19482
|
({ children, ...otherProps }, ref) => {
|
|
19292
|
-
return /* @__PURE__ */
|
|
19483
|
+
return /* @__PURE__ */ jsx115("tbody", { ref, ...otherProps, children });
|
|
19293
19484
|
}
|
|
19294
19485
|
);
|
|
19295
19486
|
var TableFoot = React24.forwardRef(
|
|
19296
19487
|
({ children, ...otherProps }, ref) => {
|
|
19297
|
-
return /* @__PURE__ */
|
|
19488
|
+
return /* @__PURE__ */ jsx115("tfoot", { ref, ...otherProps, children });
|
|
19298
19489
|
}
|
|
19299
19490
|
);
|
|
19300
19491
|
var TableRow = React24.forwardRef(
|
|
19301
19492
|
({ children, ...otherProps }, ref) => {
|
|
19302
|
-
return /* @__PURE__ */
|
|
19493
|
+
return /* @__PURE__ */ jsx115("tr", { ref, css: tableRow, ...otherProps, children });
|
|
19303
19494
|
}
|
|
19304
19495
|
);
|
|
19305
19496
|
var TableCellHead = React24.forwardRef(
|
|
19306
19497
|
({ children, ...otherProps }, ref) => {
|
|
19307
|
-
return /* @__PURE__ */
|
|
19498
|
+
return /* @__PURE__ */ jsx115("th", { ref, css: tableCellHead, ...otherProps, children });
|
|
19308
19499
|
}
|
|
19309
19500
|
);
|
|
19310
19501
|
var TableCellData = React24.forwardRef(
|
|
19311
19502
|
({ children, ...otherProps }, ref) => {
|
|
19312
|
-
return /* @__PURE__ */
|
|
19503
|
+
return /* @__PURE__ */ jsx115("td", { ref, ...otherProps, children });
|
|
19313
19504
|
}
|
|
19314
19505
|
);
|
|
19315
19506
|
|
|
19316
19507
|
// src/components/Tabs/Tabs.tsx
|
|
19317
|
-
import { createContext as createContext6, useContext as useContext7, useEffect as
|
|
19508
|
+
import { createContext as createContext6, useContext as useContext7, useEffect as useEffect16, useMemo as useMemo6 } from "react";
|
|
19318
19509
|
import {
|
|
19319
19510
|
Tab as ReakitTab,
|
|
19320
19511
|
TabList as ReakitTabList,
|
|
@@ -19323,8 +19514,8 @@ import {
|
|
|
19323
19514
|
} from "reakit/Tab";
|
|
19324
19515
|
|
|
19325
19516
|
// src/components/Tabs/Tabs.styles.ts
|
|
19326
|
-
import { css as
|
|
19327
|
-
var tabButtonStyles =
|
|
19517
|
+
import { css as css94 } from "@emotion/react";
|
|
19518
|
+
var tabButtonStyles = css94`
|
|
19328
19519
|
align-items: center;
|
|
19329
19520
|
border: 0;
|
|
19330
19521
|
height: 2.5rem;
|
|
@@ -19341,14 +19532,14 @@ var tabButtonStyles = css93`
|
|
|
19341
19532
|
box-shadow: inset 0 -2px 0 var(--brand-secondary-3);
|
|
19342
19533
|
}
|
|
19343
19534
|
`;
|
|
19344
|
-
var tabButtonGroupStyles =
|
|
19535
|
+
var tabButtonGroupStyles = css94`
|
|
19345
19536
|
display: flex;
|
|
19346
19537
|
gap: var(--spacing-base);
|
|
19347
19538
|
border-bottom: 1px solid var(--gray-300);
|
|
19348
19539
|
`;
|
|
19349
19540
|
|
|
19350
19541
|
// src/components/Tabs/Tabs.tsx
|
|
19351
|
-
import { jsx as
|
|
19542
|
+
import { jsx as jsx116 } from "@emotion/react/jsx-runtime";
|
|
19352
19543
|
var CurrentTabContext = createContext6(null);
|
|
19353
19544
|
var useCurrentTab = () => {
|
|
19354
19545
|
const context = useContext7(CurrentTabContext);
|
|
@@ -19364,7 +19555,7 @@ var Tabs = ({ children, onSelectedIdChange, useHashForState, selectedId, ...prop
|
|
|
19364
19555
|
return useHashForState && typeof window !== "undefined" && window.location.hash ? window.location.hash.substring(1) : void 0;
|
|
19365
19556
|
}, [selectedId, useHashForState]);
|
|
19366
19557
|
const tab = useTabState({ ...props, selectedId: selected });
|
|
19367
|
-
|
|
19558
|
+
useEffect16(() => {
|
|
19368
19559
|
var _a;
|
|
19369
19560
|
const selectedValueWithoutNull = (_a = tab.selectedId) != null ? _a : void 0;
|
|
19370
19561
|
onSelectedIdChange == null ? void 0 : onSelectedIdChange(selectedValueWithoutNull);
|
|
@@ -19373,29 +19564,29 @@ var Tabs = ({ children, onSelectedIdChange, useHashForState, selectedId, ...prop
|
|
|
19373
19564
|
window.history.pushState(null, "", hashValue);
|
|
19374
19565
|
}
|
|
19375
19566
|
}, [tab.selectedId, onSelectedIdChange, useHashForState]);
|
|
19376
|
-
|
|
19567
|
+
useEffect16(() => {
|
|
19377
19568
|
if (selected && selected !== tab.selectedId) {
|
|
19378
19569
|
tab.setSelectedId(selected);
|
|
19379
19570
|
}
|
|
19380
19571
|
}, [selected]);
|
|
19381
|
-
return /* @__PURE__ */
|
|
19572
|
+
return /* @__PURE__ */ jsx116(CurrentTabContext.Provider, { value: tab, children });
|
|
19382
19573
|
};
|
|
19383
19574
|
var TabButtonGroup = ({ children, ...props }) => {
|
|
19384
19575
|
const currentTab = useCurrentTab();
|
|
19385
|
-
return /* @__PURE__ */
|
|
19576
|
+
return /* @__PURE__ */ jsx116(ReakitTabList, { ...props, ...currentTab, css: tabButtonGroupStyles, children });
|
|
19386
19577
|
};
|
|
19387
19578
|
var TabButton = ({ children, id, ...props }) => {
|
|
19388
19579
|
const currentTab = useCurrentTab();
|
|
19389
|
-
return /* @__PURE__ */
|
|
19580
|
+
return /* @__PURE__ */ jsx116(ReakitTab, { type: "button", id, ...currentTab, ...props, css: tabButtonStyles, children });
|
|
19390
19581
|
};
|
|
19391
19582
|
var TabContent = ({ children, ...props }) => {
|
|
19392
19583
|
const currentTab = useCurrentTab();
|
|
19393
|
-
return /* @__PURE__ */
|
|
19584
|
+
return /* @__PURE__ */ jsx116(ReakitTabPanel, { ...props, ...currentTab, children });
|
|
19394
19585
|
};
|
|
19395
19586
|
|
|
19396
19587
|
// src/components/Validation/StatusBullet.styles.ts
|
|
19397
|
-
import { css as
|
|
19398
|
-
var StatusBulletContainer =
|
|
19588
|
+
import { css as css95 } from "@emotion/react";
|
|
19589
|
+
var StatusBulletContainer = css95`
|
|
19399
19590
|
align-items: center;
|
|
19400
19591
|
align-self: center;
|
|
19401
19592
|
color: var(--gray-500);
|
|
@@ -19412,33 +19603,33 @@ var StatusBulletContainer = css94`
|
|
|
19412
19603
|
display: block;
|
|
19413
19604
|
}
|
|
19414
19605
|
`;
|
|
19415
|
-
var StatusBulletBase =
|
|
19606
|
+
var StatusBulletBase = css95`
|
|
19416
19607
|
font-size: var(--fs-sm);
|
|
19417
19608
|
&:before {
|
|
19418
19609
|
width: var(--fs-xs);
|
|
19419
19610
|
height: var(--fs-xs);
|
|
19420
19611
|
}
|
|
19421
19612
|
`;
|
|
19422
|
-
var StatusBulletSmall =
|
|
19613
|
+
var StatusBulletSmall = css95`
|
|
19423
19614
|
font-size: var(--fs-xs);
|
|
19424
19615
|
&:before {
|
|
19425
19616
|
width: var(--fs-xxs);
|
|
19426
19617
|
height: var(--fs-xxs);
|
|
19427
19618
|
}
|
|
19428
19619
|
`;
|
|
19429
|
-
var StatusDraft =
|
|
19620
|
+
var StatusDraft = css95`
|
|
19430
19621
|
&:before {
|
|
19431
19622
|
background: var(--white);
|
|
19432
19623
|
box-shadow: inset 0 0 0 0.125rem var(--primary-action-default);
|
|
19433
19624
|
}
|
|
19434
19625
|
`;
|
|
19435
|
-
var StatusModified =
|
|
19626
|
+
var StatusModified = css95`
|
|
19436
19627
|
&:before {
|
|
19437
19628
|
background: linear-gradient(to right, var(--white) 50%, var(--primary-action-default) 50% 100%);
|
|
19438
19629
|
box-shadow: inset 0 0 0 0.125rem var(--primary-action-default);
|
|
19439
19630
|
}
|
|
19440
19631
|
`;
|
|
19441
|
-
var StatusError =
|
|
19632
|
+
var StatusError = css95`
|
|
19442
19633
|
color: var(--error);
|
|
19443
19634
|
&:before {
|
|
19444
19635
|
/* TODO: replace this with an svg icon */
|
|
@@ -19451,24 +19642,24 @@ var StatusError = css94`
|
|
|
19451
19642
|
);
|
|
19452
19643
|
}
|
|
19453
19644
|
`;
|
|
19454
|
-
var StatusPublished =
|
|
19645
|
+
var StatusPublished = css95`
|
|
19455
19646
|
&:before {
|
|
19456
19647
|
background: var(--primary-action-default);
|
|
19457
19648
|
}
|
|
19458
19649
|
`;
|
|
19459
|
-
var StatusOrphan =
|
|
19650
|
+
var StatusOrphan = css95`
|
|
19460
19651
|
&:before {
|
|
19461
19652
|
background: var(--brand-secondary-5);
|
|
19462
19653
|
}
|
|
19463
19654
|
`;
|
|
19464
|
-
var StatusUnknown =
|
|
19655
|
+
var StatusUnknown = css95`
|
|
19465
19656
|
&:before {
|
|
19466
19657
|
background: var(--brand-secondary-1);
|
|
19467
19658
|
}
|
|
19468
19659
|
`;
|
|
19469
19660
|
|
|
19470
19661
|
// src/components/Validation/StatusBullet.tsx
|
|
19471
|
-
import { jsx as
|
|
19662
|
+
import { jsx as jsx117 } from "@emotion/react/jsx-runtime";
|
|
19472
19663
|
var StatusBullet = ({
|
|
19473
19664
|
status,
|
|
19474
19665
|
hideText = false,
|
|
@@ -19487,7 +19678,7 @@ var StatusBullet = ({
|
|
|
19487
19678
|
Unknown: StatusUnknown
|
|
19488
19679
|
};
|
|
19489
19680
|
const statusSize = size === "base" ? StatusBulletBase : StatusBulletSmall;
|
|
19490
|
-
return /* @__PURE__ */
|
|
19681
|
+
return /* @__PURE__ */ jsx117(
|
|
19491
19682
|
"span",
|
|
19492
19683
|
{
|
|
19493
19684
|
role: "status",
|
|
@@ -19575,6 +19766,7 @@ export {
|
|
|
19575
19766
|
Modal,
|
|
19576
19767
|
MultilineChip,
|
|
19577
19768
|
PageHeaderSection,
|
|
19769
|
+
Pagination,
|
|
19578
19770
|
Paragraph,
|
|
19579
19771
|
ParameterDataResource,
|
|
19580
19772
|
ParameterDrawerHeader,
|
|
@@ -19617,6 +19809,7 @@ export {
|
|
|
19617
19809
|
StatusBullet,
|
|
19618
19810
|
SuccessMessage,
|
|
19619
19811
|
Switch,
|
|
19812
|
+
TAKEOVER_STACK_ID,
|
|
19620
19813
|
TabButton,
|
|
19621
19814
|
TabButtonGroup,
|
|
19622
19815
|
TabContent,
|
|
@@ -19628,6 +19821,7 @@ export {
|
|
|
19628
19821
|
TableHead,
|
|
19629
19822
|
TableRow,
|
|
19630
19823
|
Tabs,
|
|
19824
|
+
TakeoverDrawerRenderer,
|
|
19631
19825
|
Textarea,
|
|
19632
19826
|
Theme,
|
|
19633
19827
|
Tile2 as Tile,
|