@wistia/ui 0.20.16 → 0.20.17-beta.db84371d.0109ccc
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/index.d.ts +116 -59
- package/dist/index.js +767 -527
- package/dist/index.js.map +1 -1
- package/package.json +12 -12
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
/*
|
|
3
|
-
* @license @wistia/ui v0.20.
|
|
3
|
+
* @license @wistia/ui v0.20.17-beta.db84371d.0109ccc
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2024-2026, Wistia, Inc. and its affiliates.
|
|
6
6
|
*
|
|
@@ -14287,11 +14287,32 @@ var ContextMenu = ({
|
|
|
14287
14287
|
return menu;
|
|
14288
14288
|
};
|
|
14289
14289
|
|
|
14290
|
+
// src/components/CustomizableThemeWrapper/CustomizableThemeWrapper.tsx
|
|
14291
|
+
import { styled as styled58 } from "styled-components";
|
|
14292
|
+
import { jsx as jsx289 } from "react/jsx-runtime";
|
|
14293
|
+
var StyledCustomizableThemeWrapper = styled58.div(
|
|
14294
|
+
(props) => props.$overrides
|
|
14295
|
+
);
|
|
14296
|
+
var CustomizableThemeWrapper = ({
|
|
14297
|
+
children,
|
|
14298
|
+
overrides,
|
|
14299
|
+
...props
|
|
14300
|
+
}) => /* @__PURE__ */ jsx289(
|
|
14301
|
+
StyledCustomizableThemeWrapper,
|
|
14302
|
+
{
|
|
14303
|
+
...props,
|
|
14304
|
+
$overrides: overrides,
|
|
14305
|
+
"data-wui-theme": "true",
|
|
14306
|
+
children
|
|
14307
|
+
}
|
|
14308
|
+
);
|
|
14309
|
+
CustomizableThemeWrapper.displayName = "CustomizableThemeWrapper_UI";
|
|
14310
|
+
|
|
14290
14311
|
// src/components/DataCards/DataCard.tsx
|
|
14291
14312
|
import { useRef as useRef16 } from "react";
|
|
14292
|
-
import { styled as
|
|
14313
|
+
import { styled as styled59, keyframes as keyframes4 } from "styled-components";
|
|
14293
14314
|
import { isNotNil as isNotNil25 } from "@wistia/type-guards";
|
|
14294
|
-
import { jsx as
|
|
14315
|
+
import { jsx as jsx290, jsxs as jsxs41 } from "react/jsx-runtime";
|
|
14295
14316
|
var pulse = keyframes4`
|
|
14296
14317
|
0%,
|
|
14297
14318
|
100% {
|
|
@@ -14301,7 +14322,7 @@ var pulse = keyframes4`
|
|
|
14301
14322
|
opacity: 0.5;
|
|
14302
14323
|
}
|
|
14303
14324
|
`;
|
|
14304
|
-
var StyledDataCard =
|
|
14325
|
+
var StyledDataCard = styled59.div`
|
|
14305
14326
|
--wui-data-card-text: var(--wui-color-text-button);
|
|
14306
14327
|
--wui-color-text: var(--wui-data-card-text);
|
|
14307
14328
|
--wui-data-card-background: var(--wui-color-bg-surface-secondary);
|
|
@@ -14387,7 +14408,7 @@ var StyledDataCard = styled58.div`
|
|
|
14387
14408
|
${({ $colorScheme }) => getColorScheme($colorScheme)}
|
|
14388
14409
|
}
|
|
14389
14410
|
`;
|
|
14390
|
-
var StyledLabel3 =
|
|
14411
|
+
var StyledLabel3 = styled59(Heading)`
|
|
14391
14412
|
grid-area: label;
|
|
14392
14413
|
|
|
14393
14414
|
&[data-wui-data-card-skeleton='true'] {
|
|
@@ -14398,25 +14419,25 @@ var StyledLabel3 = styled58(Heading)`
|
|
|
14398
14419
|
text-align: left;
|
|
14399
14420
|
}
|
|
14400
14421
|
`;
|
|
14401
|
-
var StyledValue =
|
|
14422
|
+
var StyledValue = styled59(Heading)`
|
|
14402
14423
|
grid-area: value;
|
|
14403
14424
|
|
|
14404
14425
|
&[data-wui-data-card-skeleton='true'] {
|
|
14405
14426
|
width: min(90%, 156px);
|
|
14406
14427
|
}
|
|
14407
14428
|
`;
|
|
14408
|
-
var StyledSlot =
|
|
14429
|
+
var StyledSlot = styled59.div`
|
|
14409
14430
|
display: flex;
|
|
14410
14431
|
justify-content: flex-end;
|
|
14411
14432
|
grid-area: slot;
|
|
14412
14433
|
align-self: center;
|
|
14413
14434
|
`;
|
|
14414
|
-
var StyledDataCardTrendContainer =
|
|
14435
|
+
var StyledDataCardTrendContainer = styled59.div`
|
|
14415
14436
|
position: absolute;
|
|
14416
14437
|
bottom: var(--wui-space-01);
|
|
14417
14438
|
right: var(--wui-space-01);
|
|
14418
14439
|
`;
|
|
14419
|
-
var StyledSubtitle =
|
|
14440
|
+
var StyledSubtitle = styled59(Text)`
|
|
14420
14441
|
grid-area: subtitle;
|
|
14421
14442
|
`;
|
|
14422
14443
|
var DataCardInner = ({
|
|
@@ -14434,7 +14455,7 @@ var DataCardInner = ({
|
|
|
14434
14455
|
$colorScheme: colorScheme,
|
|
14435
14456
|
...props,
|
|
14436
14457
|
children: [
|
|
14437
|
-
/* @__PURE__ */
|
|
14458
|
+
/* @__PURE__ */ jsx290(
|
|
14438
14459
|
StyledLabel3,
|
|
14439
14460
|
{
|
|
14440
14461
|
"data-wui-data-card-skeleton": isLoading,
|
|
@@ -14443,7 +14464,7 @@ var DataCardInner = ({
|
|
|
14443
14464
|
children: label
|
|
14444
14465
|
}
|
|
14445
14466
|
),
|
|
14446
|
-
/* @__PURE__ */
|
|
14467
|
+
/* @__PURE__ */ jsx290(
|
|
14447
14468
|
StyledValue,
|
|
14448
14469
|
{
|
|
14449
14470
|
"data-wui-data-card-skeleton": isLoading,
|
|
@@ -14452,8 +14473,8 @@ var DataCardInner = ({
|
|
|
14452
14473
|
children: value
|
|
14453
14474
|
}
|
|
14454
14475
|
),
|
|
14455
|
-
isNotNil25(upperRightSlot) && !isLoading && /* @__PURE__ */
|
|
14456
|
-
isNotNil25(subtitle) && !isLoading && /* @__PURE__ */
|
|
14476
|
+
isNotNil25(upperRightSlot) && !isLoading && /* @__PURE__ */ jsx290(StyledSlot, { children: upperRightSlot }),
|
|
14477
|
+
isNotNil25(subtitle) && !isLoading && /* @__PURE__ */ jsx290(
|
|
14457
14478
|
StyledSubtitle,
|
|
14458
14479
|
{
|
|
14459
14480
|
"data-wui-data-card-subtitle": true,
|
|
@@ -14461,7 +14482,7 @@ var DataCardInner = ({
|
|
|
14461
14482
|
children: subtitle
|
|
14462
14483
|
}
|
|
14463
14484
|
),
|
|
14464
|
-
isNotNil25(trend) && !isLoading && /* @__PURE__ */
|
|
14485
|
+
isNotNil25(trend) && !isLoading && /* @__PURE__ */ jsx290(StyledDataCardTrendContainer, { children: trend })
|
|
14465
14486
|
]
|
|
14466
14487
|
}
|
|
14467
14488
|
);
|
|
@@ -14469,12 +14490,12 @@ var DataCard = (props) => {
|
|
|
14469
14490
|
const ref = useRef16(null);
|
|
14470
14491
|
if (isNotNil25(props.href) || isNotNil25(props.onClick)) {
|
|
14471
14492
|
const { "aria-pressed": ariaPressed, ...dataCardProps } = props;
|
|
14472
|
-
return /* @__PURE__ */
|
|
14493
|
+
return /* @__PURE__ */ jsx290(ClickRegion, { targetRef: ref, children: /* @__PURE__ */ jsx290(
|
|
14473
14494
|
DataCardInner,
|
|
14474
14495
|
{
|
|
14475
14496
|
upperRightSlot: props.upperRightSlot,
|
|
14476
14497
|
...dataCardProps,
|
|
14477
|
-
label: /* @__PURE__ */
|
|
14498
|
+
label: /* @__PURE__ */ jsx290(
|
|
14478
14499
|
Button,
|
|
14479
14500
|
{
|
|
14480
14501
|
ref,
|
|
@@ -14491,14 +14512,14 @@ var DataCard = (props) => {
|
|
|
14491
14512
|
}
|
|
14492
14513
|
) });
|
|
14493
14514
|
}
|
|
14494
|
-
return /* @__PURE__ */
|
|
14515
|
+
return /* @__PURE__ */ jsx290(DataCardInner, { ...props });
|
|
14495
14516
|
};
|
|
14496
14517
|
DataCard.displayName = "DataCard_UI";
|
|
14497
14518
|
|
|
14498
14519
|
// src/components/DataCards/DataCards.tsx
|
|
14499
|
-
import { styled as
|
|
14500
|
-
import { jsx as
|
|
14501
|
-
var StyledDataCards =
|
|
14520
|
+
import { styled as styled60 } from "styled-components";
|
|
14521
|
+
import { jsx as jsx291 } from "react/jsx-runtime";
|
|
14522
|
+
var StyledDataCards = styled60(Box)`
|
|
14502
14523
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
14503
14524
|
--wui-data-cards-column-count: ${({ $columns }) => $columns === "auto" ? void 0 : $columns};
|
|
14504
14525
|
--wui-data-cards-total-column-gap-width: calc(var(--wui-data-cards-column-count) - 1) *
|
|
@@ -14522,7 +14543,7 @@ var DataCards = ({
|
|
|
14522
14543
|
}) => {
|
|
14523
14544
|
const responsiveCardMaxWidth = useResponsiveProp(cardMaxWidth);
|
|
14524
14545
|
const responsiveColumns = useResponsiveProp(columns);
|
|
14525
|
-
return /* @__PURE__ */
|
|
14546
|
+
return /* @__PURE__ */ jsx291(
|
|
14526
14547
|
StyledDataCards,
|
|
14527
14548
|
{
|
|
14528
14549
|
...props,
|
|
@@ -14541,9 +14562,9 @@ var DataCards = ({
|
|
|
14541
14562
|
DataCards.displayName = "DataCards_UI";
|
|
14542
14563
|
|
|
14543
14564
|
// src/components/DataCards/DataCardTrend.tsx
|
|
14544
|
-
import { styled as
|
|
14545
|
-
import { jsx as
|
|
14546
|
-
var StyledDataCardTrend =
|
|
14565
|
+
import { styled as styled61 } from "styled-components";
|
|
14566
|
+
import { jsx as jsx292, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
14567
|
+
var StyledDataCardTrend = styled61.div`
|
|
14547
14568
|
${({ $outlook }) => getColorScheme($outlook === "positive" ? "success" : "error")};
|
|
14548
14569
|
background: var(--wui-color-bg-app);
|
|
14549
14570
|
border-radius: var(--wui-border-radius-rounded);
|
|
@@ -14559,7 +14580,7 @@ var DataCardTrend = ({
|
|
|
14559
14580
|
...props
|
|
14560
14581
|
}) => {
|
|
14561
14582
|
return /* @__PURE__ */ jsxs42(StyledDataCardTrend, { $outlook: outlook, children: [
|
|
14562
|
-
/* @__PURE__ */
|
|
14583
|
+
/* @__PURE__ */ jsx292(
|
|
14563
14584
|
Icon,
|
|
14564
14585
|
{
|
|
14565
14586
|
size: "md",
|
|
@@ -14567,7 +14588,7 @@ var DataCardTrend = ({
|
|
|
14567
14588
|
...props
|
|
14568
14589
|
}
|
|
14569
14590
|
),
|
|
14570
|
-
/* @__PURE__ */
|
|
14591
|
+
/* @__PURE__ */ jsx292(
|
|
14571
14592
|
Text,
|
|
14572
14593
|
{
|
|
14573
14594
|
prominence: "secondary",
|
|
@@ -14579,15 +14600,15 @@ var DataCardTrend = ({
|
|
|
14579
14600
|
};
|
|
14580
14601
|
|
|
14581
14602
|
// src/components/DataCards/DataCardHoverArrow.tsx
|
|
14582
|
-
import { styled as
|
|
14583
|
-
import { jsx as
|
|
14584
|
-
var StyledIconContainer =
|
|
14603
|
+
import { styled as styled62 } from "styled-components";
|
|
14604
|
+
import { jsx as jsx293 } from "react/jsx-runtime";
|
|
14605
|
+
var StyledIconContainer = styled62.div`
|
|
14585
14606
|
display: flex;
|
|
14586
14607
|
align-items: center;
|
|
14587
14608
|
align-self: center;
|
|
14588
14609
|
height: 0;
|
|
14589
14610
|
`;
|
|
14590
|
-
var DataCardHoverArrow = () => /* @__PURE__ */
|
|
14611
|
+
var DataCardHoverArrow = () => /* @__PURE__ */ jsx293(StyledIconContainer, { children: /* @__PURE__ */ jsx293(
|
|
14591
14612
|
Icon,
|
|
14592
14613
|
{
|
|
14593
14614
|
"data-wui-data-card-hover-icon": true,
|
|
@@ -14597,9 +14618,9 @@ var DataCardHoverArrow = () => /* @__PURE__ */ jsx292(StyledIconContainer, { chi
|
|
|
14597
14618
|
DataCardHoverArrow.displayName = "DataCardHoverArrow_UI";
|
|
14598
14619
|
|
|
14599
14620
|
// src/components/DataList/DataList.tsx
|
|
14600
|
-
import { styled as
|
|
14601
|
-
import { jsx as
|
|
14602
|
-
var StyledDataList =
|
|
14621
|
+
import { styled as styled63 } from "styled-components";
|
|
14622
|
+
import { jsx as jsx294 } from "react/jsx-runtime";
|
|
14623
|
+
var StyledDataList = styled63.dl`
|
|
14603
14624
|
display: grid;
|
|
14604
14625
|
grid-template-columns: auto 1fr;
|
|
14605
14626
|
column-gap: var(--wui-space-02);
|
|
@@ -14627,7 +14648,7 @@ var DataList = ({
|
|
|
14627
14648
|
labelProminence = "primary",
|
|
14628
14649
|
...props
|
|
14629
14650
|
}) => {
|
|
14630
|
-
return /* @__PURE__ */
|
|
14651
|
+
return /* @__PURE__ */ jsx294(
|
|
14631
14652
|
StyledDataList,
|
|
14632
14653
|
{
|
|
14633
14654
|
role: "list",
|
|
@@ -14650,9 +14671,9 @@ var DataListItem = ({ children }) => {
|
|
|
14650
14671
|
DataListItem.displayName = "DataListItem_UI";
|
|
14651
14672
|
|
|
14652
14673
|
// src/components/DataList/DataListItemLabel.tsx
|
|
14653
|
-
import { jsx as
|
|
14674
|
+
import { jsx as jsx295 } from "react/jsx-runtime";
|
|
14654
14675
|
var DataListItemLabel = (props) => {
|
|
14655
|
-
return /* @__PURE__ */
|
|
14676
|
+
return /* @__PURE__ */ jsx295(
|
|
14656
14677
|
Text,
|
|
14657
14678
|
{
|
|
14658
14679
|
variant: "label4",
|
|
@@ -14664,9 +14685,9 @@ var DataListItemLabel = (props) => {
|
|
|
14664
14685
|
DataListItemLabel.displayName = "DataListItemLabel_UI";
|
|
14665
14686
|
|
|
14666
14687
|
// src/components/DataList/DataListItemValue.tsx
|
|
14667
|
-
import { jsx as
|
|
14688
|
+
import { jsx as jsx296 } from "react/jsx-runtime";
|
|
14668
14689
|
var DataListItemValue = (props) => {
|
|
14669
|
-
return /* @__PURE__ */
|
|
14690
|
+
return /* @__PURE__ */ jsx296(
|
|
14670
14691
|
Text,
|
|
14671
14692
|
{
|
|
14672
14693
|
variant: "body3",
|
|
@@ -14678,8 +14699,8 @@ var DataListItemValue = (props) => {
|
|
|
14678
14699
|
DataListItemValue.displayName = "DataListItemValue_UI";
|
|
14679
14700
|
|
|
14680
14701
|
// src/components/Divider/Divider.tsx
|
|
14681
|
-
import { styled as
|
|
14682
|
-
import { jsx as
|
|
14702
|
+
import { styled as styled64, css as css33 } from "styled-components";
|
|
14703
|
+
import { jsx as jsx297 } from "react/jsx-runtime";
|
|
14683
14704
|
var horizontalBorderCss = css33`
|
|
14684
14705
|
border-top-color: var(--wui-color-border);
|
|
14685
14706
|
border-top-style: solid;
|
|
@@ -14697,7 +14718,7 @@ var verticalBorderCss = css33`
|
|
|
14697
14718
|
margin-top: var(--wui-divider-inset);
|
|
14698
14719
|
margin-bottom: var(--wui-divider-inset);
|
|
14699
14720
|
`;
|
|
14700
|
-
var DividerComponent =
|
|
14721
|
+
var DividerComponent = styled64.div`
|
|
14701
14722
|
${({ $orientation }) => {
|
|
14702
14723
|
switch ($orientation) {
|
|
14703
14724
|
case "vertical":
|
|
@@ -14718,7 +14739,7 @@ var Divider = ({
|
|
|
14718
14739
|
}) => {
|
|
14719
14740
|
const responsiveOrientation = useResponsiveProp(orientation);
|
|
14720
14741
|
const responsiveInset = useResponsiveProp(inset);
|
|
14721
|
-
return /* @__PURE__ */
|
|
14742
|
+
return /* @__PURE__ */ jsx297(
|
|
14722
14743
|
DividerComponent,
|
|
14723
14744
|
{
|
|
14724
14745
|
$inset: responsiveInset,
|
|
@@ -14732,10 +14753,10 @@ var Divider = ({
|
|
|
14732
14753
|
Divider.displayName = "Divider_UI";
|
|
14733
14754
|
|
|
14734
14755
|
// src/components/EditableHeading/EditableHeading.tsx
|
|
14735
|
-
import { styled as
|
|
14756
|
+
import { styled as styled65, css as css34 } from "styled-components";
|
|
14736
14757
|
import { useState as useState19, useRef as useRef17 } from "react";
|
|
14737
|
-
import { Fragment as Fragment8, jsx as
|
|
14738
|
-
var StyledInput =
|
|
14758
|
+
import { Fragment as Fragment8, jsx as jsx298, jsxs as jsxs43 } from "react/jsx-runtime";
|
|
14759
|
+
var StyledInput = styled65(Input)`
|
|
14739
14760
|
&:not([rows]) {
|
|
14740
14761
|
min-height: unset;
|
|
14741
14762
|
}
|
|
@@ -14770,7 +14791,7 @@ var editableStyles = css34`
|
|
|
14770
14791
|
cursor: pointer;
|
|
14771
14792
|
}
|
|
14772
14793
|
`;
|
|
14773
|
-
var StyledHeading2 =
|
|
14794
|
+
var StyledHeading2 = styled65(Heading)`
|
|
14774
14795
|
width: 100%;
|
|
14775
14796
|
border-radius: var(--wui-border-radius-02);
|
|
14776
14797
|
padding: var(--wui-space-02);
|
|
@@ -14827,7 +14848,7 @@ var EditableHeading = ({
|
|
|
14827
14848
|
handleSetEditing(false);
|
|
14828
14849
|
}
|
|
14829
14850
|
};
|
|
14830
|
-
const HeadingComponent2 = /* @__PURE__ */
|
|
14851
|
+
const HeadingComponent2 = /* @__PURE__ */ jsx298(
|
|
14831
14852
|
StyledHeading2,
|
|
14832
14853
|
{
|
|
14833
14854
|
ref: headingRef,
|
|
@@ -14841,7 +14862,7 @@ var EditableHeading = ({
|
|
|
14841
14862
|
return HeadingComponent2;
|
|
14842
14863
|
}
|
|
14843
14864
|
if (isEditing || __forceEditing) {
|
|
14844
|
-
return /* @__PURE__ */
|
|
14865
|
+
return /* @__PURE__ */ jsx298(
|
|
14845
14866
|
StyledInput,
|
|
14846
14867
|
{
|
|
14847
14868
|
$height: headingHeight,
|
|
@@ -14861,8 +14882,8 @@ var EditableHeading = ({
|
|
|
14861
14882
|
);
|
|
14862
14883
|
}
|
|
14863
14884
|
return /* @__PURE__ */ jsxs43(Fragment8, { children: [
|
|
14864
|
-
/* @__PURE__ */
|
|
14865
|
-
/* @__PURE__ */
|
|
14885
|
+
/* @__PURE__ */ jsx298(Tooltip, { content: tooltipText, children: HeadingComponent2 }),
|
|
14886
|
+
/* @__PURE__ */ jsx298(ScreenReaderOnly, { children: /* @__PURE__ */ jsx298(
|
|
14866
14887
|
"button",
|
|
14867
14888
|
{
|
|
14868
14889
|
"aria-label": ariaLabel,
|
|
@@ -14875,14 +14896,14 @@ var EditableHeading = ({
|
|
|
14875
14896
|
|
|
14876
14897
|
// src/components/EditableText/EditableTextDisplay.tsx
|
|
14877
14898
|
import { useContext as useContext6, useRef as useRef18, forwardRef as forwardRef21 } from "react";
|
|
14878
|
-
import { styled as
|
|
14899
|
+
import { styled as styled67, css as css35 } from "styled-components";
|
|
14879
14900
|
import { isNotNil as isNotNil26 } from "@wistia/type-guards";
|
|
14880
14901
|
|
|
14881
14902
|
// src/components/EditableText/EditableTextRoot.tsx
|
|
14882
14903
|
import { createContext as createContext7, useMemo as useMemo13, useState as useState20, useCallback as useCallback16, useId as useId4 } from "react";
|
|
14883
14904
|
import { isNonEmptyString as isNonEmptyString6 } from "@wistia/type-guards";
|
|
14884
|
-
import { styled as
|
|
14885
|
-
import { jsx as
|
|
14905
|
+
import { styled as styled66 } from "styled-components";
|
|
14906
|
+
import { jsx as jsx299 } from "react/jsx-runtime";
|
|
14886
14907
|
var LARGE_PADDING = "var(--wui-space-02)";
|
|
14887
14908
|
var SMALL_PADDING = "var(--wui-space-01)";
|
|
14888
14909
|
var getPaddingForVariant = (variant) => {
|
|
@@ -14917,7 +14938,7 @@ var getPaddingForVariant = (variant) => {
|
|
|
14917
14938
|
}
|
|
14918
14939
|
return SMALL_PADDING;
|
|
14919
14940
|
};
|
|
14920
|
-
var StyledEditableTextRoot =
|
|
14941
|
+
var StyledEditableTextRoot = styled66.div`
|
|
14921
14942
|
display: contents;
|
|
14922
14943
|
|
|
14923
14944
|
--wui-editable-text-padding: ${({ $typographicVariant }) => getPaddingForVariant($typographicVariant)};
|
|
@@ -15015,7 +15036,7 @@ var EditableTextRoot = ({
|
|
|
15015
15036
|
}
|
|
15016
15037
|
return "idle";
|
|
15017
15038
|
};
|
|
15018
|
-
return /* @__PURE__ */
|
|
15039
|
+
return /* @__PURE__ */ jsx299(
|
|
15019
15040
|
StyledEditableTextRoot,
|
|
15020
15041
|
{
|
|
15021
15042
|
$typographicVariant: typographicVariant,
|
|
@@ -15023,14 +15044,14 @@ var EditableTextRoot = ({
|
|
|
15023
15044
|
"data-wui-editable-text-root": true,
|
|
15024
15045
|
"data-wui-editable-text-state": getState(),
|
|
15025
15046
|
...props,
|
|
15026
|
-
children: /* @__PURE__ */
|
|
15047
|
+
children: /* @__PURE__ */ jsx299(EditableTextContext.Provider, { value: context, children })
|
|
15027
15048
|
}
|
|
15028
15049
|
);
|
|
15029
15050
|
};
|
|
15030
15051
|
|
|
15031
15052
|
// src/components/EditableText/EditableTextDisplay.tsx
|
|
15032
|
-
import { jsx as
|
|
15033
|
-
var StyledEditableTextDisplay =
|
|
15053
|
+
import { jsx as jsx300, jsxs as jsxs44 } from "react/jsx-runtime";
|
|
15054
|
+
var StyledEditableTextDisplay = styled67.div`
|
|
15034
15055
|
${({ $typographicVariant }) => getTypographicStyles($typographicVariant)}
|
|
15035
15056
|
padding: var(--wui-editable-text-padding);
|
|
15036
15057
|
border-radius: var(--wui-editable-text-border-radius);
|
|
@@ -15083,7 +15104,7 @@ var EditableTextDisplayComponent = forwardRef21(
|
|
|
15083
15104
|
return null;
|
|
15084
15105
|
}
|
|
15085
15106
|
if (asTrigger && !context.readOnly) {
|
|
15086
|
-
return /* @__PURE__ */
|
|
15107
|
+
return /* @__PURE__ */ jsx300(ClickRegion, { targetRef: triggerButtonRef, children: /* @__PURE__ */ jsxs44(
|
|
15087
15108
|
StyledEditableTextDisplay,
|
|
15088
15109
|
{
|
|
15089
15110
|
ref,
|
|
@@ -15095,7 +15116,7 @@ var EditableTextDisplayComponent = forwardRef21(
|
|
|
15095
15116
|
...props,
|
|
15096
15117
|
children: [
|
|
15097
15118
|
displayText,
|
|
15098
|
-
/* @__PURE__ */
|
|
15119
|
+
/* @__PURE__ */ jsx300(
|
|
15099
15120
|
"button",
|
|
15100
15121
|
{
|
|
15101
15122
|
ref: triggerButtonRef,
|
|
@@ -15109,7 +15130,7 @@ var EditableTextDisplayComponent = forwardRef21(
|
|
|
15109
15130
|
}
|
|
15110
15131
|
) });
|
|
15111
15132
|
}
|
|
15112
|
-
return /* @__PURE__ */
|
|
15133
|
+
return /* @__PURE__ */ jsx300(
|
|
15113
15134
|
StyledEditableTextDisplay,
|
|
15114
15135
|
{
|
|
15115
15136
|
ref,
|
|
@@ -15133,10 +15154,10 @@ var EditableTextDisplay = makePolymorphic(
|
|
|
15133
15154
|
|
|
15134
15155
|
// src/components/EditableText/EditableTextInput.tsx
|
|
15135
15156
|
import { useContext as useContext7, useEffect as useEffect18, useRef as useRef19 } from "react";
|
|
15136
|
-
import { styled as
|
|
15157
|
+
import { styled as styled68 } from "styled-components";
|
|
15137
15158
|
import { isNotNil as isNotNil27 } from "@wistia/type-guards";
|
|
15138
|
-
import { jsx as
|
|
15139
|
-
var StyledInput2 =
|
|
15159
|
+
import { jsx as jsx301 } from "react/jsx-runtime";
|
|
15160
|
+
var StyledInput2 = styled68(Input)`
|
|
15140
15161
|
&& {
|
|
15141
15162
|
${({ $minLines }) => isNotNil27($minLines) && `min-height: calc(${$minLines}lh + calc(var(--wui-editable-text-padding) * 2));`}
|
|
15142
15163
|
${({ $maxLines }) => isNotNil27($maxLines) && `max-height: calc(${$maxLines}lh + calc(var(--wui-editable-text-padding) * 2));`}
|
|
@@ -15226,7 +15247,7 @@ var EditableTextInput = (props) => {
|
|
|
15226
15247
|
if (!isEditing) {
|
|
15227
15248
|
return null;
|
|
15228
15249
|
}
|
|
15229
|
-
return /* @__PURE__ */
|
|
15250
|
+
return /* @__PURE__ */ jsx301(
|
|
15230
15251
|
StyledInput2,
|
|
15231
15252
|
{
|
|
15232
15253
|
ref: inputRef,
|
|
@@ -15252,14 +15273,14 @@ var EditableTextInput = (props) => {
|
|
|
15252
15273
|
|
|
15253
15274
|
// src/components/EditableText/EditableTextLabel.tsx
|
|
15254
15275
|
import { useContext as useContext8 } from "react";
|
|
15255
|
-
import { jsx as
|
|
15276
|
+
import { jsx as jsx302 } from "react/jsx-runtime";
|
|
15256
15277
|
var EditableTextLabel = ({ ...props }) => {
|
|
15257
15278
|
const context = useContext8(EditableTextContext);
|
|
15258
15279
|
if (!context) {
|
|
15259
15280
|
throw new Error("EditableTextLabel must be used within an EditableTextRoot context");
|
|
15260
15281
|
}
|
|
15261
15282
|
const { id, label, isEditing } = context;
|
|
15262
|
-
return /* @__PURE__ */
|
|
15283
|
+
return /* @__PURE__ */ jsx302(
|
|
15263
15284
|
Label,
|
|
15264
15285
|
{
|
|
15265
15286
|
...isEditing && { htmlFor: id },
|
|
@@ -15270,11 +15291,11 @@ var EditableTextLabel = ({ ...props }) => {
|
|
|
15270
15291
|
};
|
|
15271
15292
|
|
|
15272
15293
|
// src/components/EditableText/EditableText.tsx
|
|
15273
|
-
import { jsx as
|
|
15294
|
+
import { jsx as jsx303, jsxs as jsxs45 } from "react/jsx-runtime";
|
|
15274
15295
|
var EditableText = ({ hideLabel = true, ...props }) => /* @__PURE__ */ jsxs45(EditableTextRoot, { ...props, children: [
|
|
15275
|
-
/* @__PURE__ */
|
|
15276
|
-
/* @__PURE__ */
|
|
15277
|
-
/* @__PURE__ */
|
|
15296
|
+
/* @__PURE__ */ jsx303(EditableTextLabel, { screenReaderOnly: hideLabel }),
|
|
15297
|
+
/* @__PURE__ */ jsx303(EditableTextInput, {}),
|
|
15298
|
+
/* @__PURE__ */ jsx303(EditableTextDisplay, { asTrigger: true })
|
|
15278
15299
|
] });
|
|
15279
15300
|
EditableText.displayName = "EditableText_UI";
|
|
15280
15301
|
|
|
@@ -15409,9 +15430,9 @@ var useFormState = (action, initialData = {}) => {
|
|
|
15409
15430
|
// src/components/Form/FormErrorSummary.tsx
|
|
15410
15431
|
import { useContext as useContext12, useRef as useRef20 } from "react";
|
|
15411
15432
|
import { isArray as isArray3, isNotUndefined as isNotUndefined11 } from "@wistia/type-guards";
|
|
15412
|
-
import { jsx as
|
|
15433
|
+
import { jsx as jsx304, jsxs as jsxs46 } from "react/jsx-runtime";
|
|
15413
15434
|
var ErrorItem = ({ name, error, formId }) => {
|
|
15414
|
-
return /* @__PURE__ */
|
|
15435
|
+
return /* @__PURE__ */ jsx304("li", { children: /* @__PURE__ */ jsx304(Link, { href: `#${formId}-${name}`, children: error }) }, name);
|
|
15415
15436
|
};
|
|
15416
15437
|
var FormErrorSummary = ({ description }) => {
|
|
15417
15438
|
const ref = useRef20(null);
|
|
@@ -15421,9 +15442,9 @@ var FormErrorSummary = ({ description }) => {
|
|
|
15421
15442
|
return null;
|
|
15422
15443
|
}
|
|
15423
15444
|
return /* @__PURE__ */ jsxs46("div", { ref, children: [
|
|
15424
|
-
/* @__PURE__ */
|
|
15425
|
-
/* @__PURE__ */
|
|
15426
|
-
([name, error]) => isArray3(error) ? error.map((err) => /* @__PURE__ */
|
|
15445
|
+
/* @__PURE__ */ jsx304("p", { children: description }),
|
|
15446
|
+
/* @__PURE__ */ jsx304("ul", { children: Object.entries(errors).filter(([, error]) => isNotUndefined11(error)).map(
|
|
15447
|
+
([name, error]) => isArray3(error) ? error.map((err) => /* @__PURE__ */ jsx304(
|
|
15427
15448
|
ErrorItem,
|
|
15428
15449
|
{
|
|
15429
15450
|
error: err,
|
|
@@ -15431,7 +15452,7 @@ var FormErrorSummary = ({ description }) => {
|
|
|
15431
15452
|
name
|
|
15432
15453
|
},
|
|
15433
15454
|
err
|
|
15434
|
-
)) : /* @__PURE__ */
|
|
15455
|
+
)) : /* @__PURE__ */ jsx304(
|
|
15435
15456
|
ErrorItem,
|
|
15436
15457
|
{
|
|
15437
15458
|
error: error ?? "",
|
|
@@ -15470,9 +15491,9 @@ var validateWithYup = (schema) => {
|
|
|
15470
15491
|
|
|
15471
15492
|
// src/components/FormField/FormField.tsx
|
|
15472
15493
|
import { Children as Children10, cloneElement as cloneElement8, useContext as useContext13 } from "react";
|
|
15473
|
-
import { styled as
|
|
15494
|
+
import { styled as styled69, css as css36 } from "styled-components";
|
|
15474
15495
|
import { isArray as isArray4, isNotNil as isNotNil28, isNotUndefined as isNotUndefined13, isUndefined as isUndefined4 } from "@wistia/type-guards";
|
|
15475
|
-
import { jsx as
|
|
15496
|
+
import { jsx as jsx305, jsxs as jsxs47 } from "react/jsx-runtime";
|
|
15476
15497
|
var inlineErrorStyles = css36`
|
|
15477
15498
|
grid-template-rows: 1fr auto;
|
|
15478
15499
|
grid-template-areas: 'label-description input' '. error';
|
|
@@ -15485,7 +15506,7 @@ var blockGridErrorStyles = css36`
|
|
|
15485
15506
|
grid-template-rows: auto 1fr auto;
|
|
15486
15507
|
grid-template-areas: 'label-description' 'input' 'error';
|
|
15487
15508
|
`;
|
|
15488
|
-
var StyledFormField =
|
|
15509
|
+
var StyledFormField = styled69.div`
|
|
15489
15510
|
--form-field-spacing: var(--wui-space-02);
|
|
15490
15511
|
--form-field-spacing-inline: var(--wui-space-02);
|
|
15491
15512
|
--form-field-error-color: var(--wui-color-text-secondary-error);
|
|
@@ -15519,10 +15540,10 @@ var StyledFormField = styled68.div`
|
|
|
15519
15540
|
${({ $hasError }) => $hasError && blockGridErrorStyles}
|
|
15520
15541
|
}
|
|
15521
15542
|
`;
|
|
15522
|
-
var ErrorText =
|
|
15543
|
+
var ErrorText = styled69(Text)`
|
|
15523
15544
|
grid-area: error;
|
|
15524
15545
|
`;
|
|
15525
|
-
var StyledErrorList =
|
|
15546
|
+
var StyledErrorList = styled69.ul`
|
|
15526
15547
|
margin: 0;
|
|
15527
15548
|
padding: 0;
|
|
15528
15549
|
padding-left: var(--wui-space-04);
|
|
@@ -15535,7 +15556,7 @@ var ErrorMessages = ({ errors, id }) => {
|
|
|
15535
15556
|
const isErrorArray = isArray4(errors);
|
|
15536
15557
|
const isMultipleErrors = isErrorArray && errors.length > 1;
|
|
15537
15558
|
if (!isErrorArray) {
|
|
15538
|
-
return /* @__PURE__ */
|
|
15559
|
+
return /* @__PURE__ */ jsx305(
|
|
15539
15560
|
ErrorText,
|
|
15540
15561
|
{
|
|
15541
15562
|
colorScheme: "error",
|
|
@@ -15548,7 +15569,7 @@ var ErrorMessages = ({ errors, id }) => {
|
|
|
15548
15569
|
);
|
|
15549
15570
|
}
|
|
15550
15571
|
if (!isMultipleErrors) {
|
|
15551
|
-
return /* @__PURE__ */
|
|
15572
|
+
return /* @__PURE__ */ jsx305(
|
|
15552
15573
|
ErrorText,
|
|
15553
15574
|
{
|
|
15554
15575
|
colorScheme: "error",
|
|
@@ -15560,7 +15581,7 @@ var ErrorMessages = ({ errors, id }) => {
|
|
|
15560
15581
|
id
|
|
15561
15582
|
);
|
|
15562
15583
|
}
|
|
15563
|
-
return /* @__PURE__ */
|
|
15584
|
+
return /* @__PURE__ */ jsx305(StyledErrorList, { children: errors.map((error, index) => /* @__PURE__ */ jsx305(
|
|
15564
15585
|
Text,
|
|
15565
15586
|
{
|
|
15566
15587
|
colorScheme: "error",
|
|
@@ -15645,7 +15666,7 @@ var FormField = ({
|
|
|
15645
15666
|
gridArea: "label-description"
|
|
15646
15667
|
},
|
|
15647
15668
|
children: [
|
|
15648
|
-
!isIntegratedLabel && /* @__PURE__ */
|
|
15669
|
+
!isIntegratedLabel && /* @__PURE__ */ jsx305(
|
|
15649
15670
|
Label,
|
|
15650
15671
|
{
|
|
15651
15672
|
htmlFor: computedId,
|
|
@@ -15653,12 +15674,12 @@ var FormField = ({
|
|
|
15653
15674
|
children: label
|
|
15654
15675
|
}
|
|
15655
15676
|
),
|
|
15656
|
-
hasDescription ? /* @__PURE__ */
|
|
15677
|
+
hasDescription ? /* @__PURE__ */ jsx305(FormControlLabelDescription, { id: descriptionId, children: description }) : null
|
|
15657
15678
|
]
|
|
15658
15679
|
}
|
|
15659
15680
|
) : null,
|
|
15660
15681
|
cloneElement8(children, childProps),
|
|
15661
|
-
hasError ? /* @__PURE__ */
|
|
15682
|
+
hasError ? /* @__PURE__ */ jsx305(
|
|
15662
15683
|
ErrorMessages,
|
|
15663
15684
|
{
|
|
15664
15685
|
errors: computedError,
|
|
@@ -15673,7 +15694,7 @@ FormField.displayName = "FormField_UI";
|
|
|
15673
15694
|
|
|
15674
15695
|
// src/components/FormGroup/RadioGroup.tsx
|
|
15675
15696
|
import { createContext as createContext8, useMemo as useMemo14, useContext as useContext14 } from "react";
|
|
15676
|
-
import { jsx as
|
|
15697
|
+
import { jsx as jsx306 } from "react/jsx-runtime";
|
|
15677
15698
|
var RadioGroupContext = createContext8(null);
|
|
15678
15699
|
var useRadioGroup = () => {
|
|
15679
15700
|
return useContext14(RadioGroupContext);
|
|
@@ -15694,15 +15715,15 @@ var RadioGroup = ({
|
|
|
15694
15715
|
value: derivedValue
|
|
15695
15716
|
};
|
|
15696
15717
|
}, [name, derivedValue, onChange]);
|
|
15697
|
-
return /* @__PURE__ */
|
|
15718
|
+
return /* @__PURE__ */ jsx306(RadioGroupContext.Provider, { value: context, children: /* @__PURE__ */ jsx306(FormGroup, { ...props, children }) });
|
|
15698
15719
|
};
|
|
15699
15720
|
RadioGroup.displayName = "RadioGroup_UI";
|
|
15700
15721
|
|
|
15701
15722
|
// src/components/Grid/Grid.tsx
|
|
15702
15723
|
import { forwardRef as forwardRef22 } from "react";
|
|
15703
|
-
import { styled as
|
|
15724
|
+
import { styled as styled70, css as css37 } from "styled-components";
|
|
15704
15725
|
import { isRecord as isRecord5 } from "@wistia/type-guards";
|
|
15705
|
-
import { jsx as
|
|
15726
|
+
import { jsx as jsx307 } from "react/jsx-runtime";
|
|
15706
15727
|
var DEFAULT_ELEMENT5 = "div";
|
|
15707
15728
|
var getGridTemplateColumns = (maxColumns, minChildWidth, expandItems) => {
|
|
15708
15729
|
if (minChildWidth === "auto" && maxColumns === "auto") {
|
|
@@ -15730,7 +15751,7 @@ var getGridTemplateColumns = (maxColumns, minChildWidth, expandItems) => {
|
|
|
15730
15751
|
);
|
|
15731
15752
|
`;
|
|
15732
15753
|
};
|
|
15733
|
-
var StyledGrid =
|
|
15754
|
+
var StyledGrid = styled70.div`
|
|
15734
15755
|
--wui-grid-column-gap: ${({ $columnGap }) => `var(--wui-${$columnGap})`};
|
|
15735
15756
|
--wui-grid-row-gap: ${({ $rowGap }) => `var(--wui-${$rowGap})`};
|
|
15736
15757
|
|
|
@@ -15754,7 +15775,7 @@ var GridComponent = forwardRef22(
|
|
|
15754
15775
|
const { column, row } = isRecord5(responsiveGap) ? responsiveGap : { column: responsiveGap, row: responsiveGap };
|
|
15755
15776
|
const responsiveColumns = useResponsiveProp(columns);
|
|
15756
15777
|
const responsiveMinChildWidth = useResponsiveProp(minChildWidth);
|
|
15757
|
-
return /* @__PURE__ */
|
|
15778
|
+
return /* @__PURE__ */ jsx307(
|
|
15758
15779
|
StyledGrid,
|
|
15759
15780
|
{
|
|
15760
15781
|
ref,
|
|
@@ -15774,11 +15795,11 @@ GridComponent.displayName = "Grid_UI";
|
|
|
15774
15795
|
var Grid = makePolymorphic(GridComponent);
|
|
15775
15796
|
|
|
15776
15797
|
// src/components/InputClickToCopy/InputClickToCopy.tsx
|
|
15777
|
-
import { styled as
|
|
15798
|
+
import { styled as styled71 } from "styled-components";
|
|
15778
15799
|
import { forwardRef as forwardRef23, useEffect as useEffect19, useState as useState22 } from "react";
|
|
15779
15800
|
import { isFunction as isFunction3 } from "@wistia/type-guards";
|
|
15780
|
-
import { jsx as
|
|
15781
|
-
var StyledIconButton =
|
|
15801
|
+
import { jsx as jsx308 } from "react/jsx-runtime";
|
|
15802
|
+
var StyledIconButton = styled71(IconButton)`
|
|
15782
15803
|
/* override size for icon button since prop gets changed by Input */
|
|
15783
15804
|
height: var(--icon-button-size-sm);
|
|
15784
15805
|
width: var(--icon-button-size-sm);
|
|
@@ -15817,7 +15838,7 @@ var InputClickToCopy = forwardRef23(
|
|
|
15817
15838
|
return value;
|
|
15818
15839
|
});
|
|
15819
15840
|
};
|
|
15820
|
-
return /* @__PURE__ */
|
|
15841
|
+
return /* @__PURE__ */ jsx308(
|
|
15821
15842
|
Input,
|
|
15822
15843
|
{
|
|
15823
15844
|
"aria-label": "Click to Copy",
|
|
@@ -15825,7 +15846,7 @@ var InputClickToCopy = forwardRef23(
|
|
|
15825
15846
|
ref,
|
|
15826
15847
|
disabled,
|
|
15827
15848
|
readOnly: true,
|
|
15828
|
-
rightIcon: /* @__PURE__ */
|
|
15849
|
+
rightIcon: /* @__PURE__ */ jsx308(
|
|
15829
15850
|
StyledIconButton,
|
|
15830
15851
|
{
|
|
15831
15852
|
colorScheme: isCopied ? "success" : "inherit",
|
|
@@ -15833,7 +15854,7 @@ var InputClickToCopy = forwardRef23(
|
|
|
15833
15854
|
label: "Copy to clipboard",
|
|
15834
15855
|
onClick: handleClick,
|
|
15835
15856
|
variant: "ghost",
|
|
15836
|
-
children: isCopied ? /* @__PURE__ */
|
|
15857
|
+
children: isCopied ? /* @__PURE__ */ jsx308(Icon, { type: "checkmark-circle" }) : /* @__PURE__ */ jsx308(Icon, { type: "save-as-copy" })
|
|
15837
15858
|
}
|
|
15838
15859
|
),
|
|
15839
15860
|
value
|
|
@@ -15844,11 +15865,11 @@ var InputClickToCopy = forwardRef23(
|
|
|
15844
15865
|
InputClickToCopy.displayName = "InputClickToCopy_UI";
|
|
15845
15866
|
|
|
15846
15867
|
// src/components/InputPassword/InputPassword.tsx
|
|
15847
|
-
import { styled as
|
|
15868
|
+
import { styled as styled72 } from "styled-components";
|
|
15848
15869
|
import { forwardRef as forwardRef24, useState as useState23 } from "react";
|
|
15849
15870
|
import { isFunction as isFunction4 } from "@wistia/type-guards";
|
|
15850
|
-
import { jsx as
|
|
15851
|
-
var StyledIconButton2 =
|
|
15871
|
+
import { jsx as jsx309 } from "react/jsx-runtime";
|
|
15872
|
+
var StyledIconButton2 = styled72(IconButton)`
|
|
15852
15873
|
/* override size for icon button since prop gets changed by Input */
|
|
15853
15874
|
height: var(--icon-button-size-sm);
|
|
15854
15875
|
width: var(--icon-button-size-sm);
|
|
@@ -15866,13 +15887,13 @@ var InputPassword = forwardRef24(
|
|
|
15866
15887
|
onVisibilityToggle(newVisibility);
|
|
15867
15888
|
}
|
|
15868
15889
|
};
|
|
15869
|
-
return /* @__PURE__ */
|
|
15890
|
+
return /* @__PURE__ */ jsx309(
|
|
15870
15891
|
Input,
|
|
15871
15892
|
{
|
|
15872
15893
|
...props,
|
|
15873
15894
|
ref,
|
|
15874
15895
|
disabled,
|
|
15875
|
-
rightIcon: /* @__PURE__ */
|
|
15896
|
+
rightIcon: /* @__PURE__ */ jsx309(
|
|
15876
15897
|
StyledIconButton2,
|
|
15877
15898
|
{
|
|
15878
15899
|
disabled,
|
|
@@ -15880,7 +15901,7 @@ var InputPassword = forwardRef24(
|
|
|
15880
15901
|
onClick: handleClick,
|
|
15881
15902
|
tabIndex: disabled ? -1 : 0,
|
|
15882
15903
|
variant: "ghost",
|
|
15883
|
-
children: /* @__PURE__ */
|
|
15904
|
+
children: /* @__PURE__ */ jsx309(Icon, { type: isVisible ? "preview" : "hide" })
|
|
15884
15905
|
}
|
|
15885
15906
|
),
|
|
15886
15907
|
type: isVisible ? "text" : "password"
|
|
@@ -15891,16 +15912,16 @@ var InputPassword = forwardRef24(
|
|
|
15891
15912
|
InputPassword.displayName = "InputPassword_UI";
|
|
15892
15913
|
|
|
15893
15914
|
// src/components/KeyboardShortcut/KeyboardShortcut.tsx
|
|
15894
|
-
import { styled as
|
|
15915
|
+
import { styled as styled73 } from "styled-components";
|
|
15895
15916
|
import { isNotNil as isNotNil29 } from "@wistia/type-guards";
|
|
15896
|
-
import { jsx as
|
|
15897
|
-
var StyledKeyboardShortcut =
|
|
15917
|
+
import { jsx as jsx310, jsxs as jsxs48 } from "react/jsx-runtime";
|
|
15918
|
+
var StyledKeyboardShortcut = styled73.div`
|
|
15898
15919
|
align-items: center;
|
|
15899
15920
|
display: flex;
|
|
15900
15921
|
gap: var(--wui-space-02);
|
|
15901
15922
|
${({ $fullWidth }) => $fullWidth && "width: 100%; justify-content: space-between;"}
|
|
15902
15923
|
`;
|
|
15903
|
-
var StyledKey =
|
|
15924
|
+
var StyledKey = styled73.kbd`
|
|
15904
15925
|
align-items: center;
|
|
15905
15926
|
background: var(--wui-color-bg-surface-secondary);
|
|
15906
15927
|
border-bottom: 1px solid var(--wui-color-border-secondary);
|
|
@@ -15923,11 +15944,11 @@ var StyledKey = styled72.kbd`
|
|
|
15923
15944
|
min-width: 20px;
|
|
15924
15945
|
padding: 0 var(--wui-space-01);
|
|
15925
15946
|
`;
|
|
15926
|
-
var Label2 =
|
|
15947
|
+
var Label2 = styled73.span`
|
|
15927
15948
|
color: var(--wui-color-text);
|
|
15928
15949
|
font-size: 12px;
|
|
15929
15950
|
`;
|
|
15930
|
-
var KeysContainer =
|
|
15951
|
+
var KeysContainer = styled73.div`
|
|
15931
15952
|
display: flex;
|
|
15932
15953
|
gap: var(--wui-space-01);
|
|
15933
15954
|
`;
|
|
@@ -15986,8 +16007,8 @@ var KeyboardShortcut = ({
|
|
|
15986
16007
|
$fullWidth: fullWidth,
|
|
15987
16008
|
...otherProps,
|
|
15988
16009
|
children: [
|
|
15989
|
-
isNotNil29(label) && /* @__PURE__ */
|
|
15990
|
-
/* @__PURE__ */
|
|
16010
|
+
isNotNil29(label) && /* @__PURE__ */ jsx310(Label2, { children: label }),
|
|
16011
|
+
/* @__PURE__ */ jsx310(KeysContainer, { children: (Array.isArray(keyboardKeys) ? keyboardKeys : [keyboardKeys]).map((keyboardKey, index) => /* @__PURE__ */ jsx310(
|
|
15991
16012
|
StyledKey,
|
|
15992
16013
|
{
|
|
15993
16014
|
children: keyToString(keyboardKey)
|
|
@@ -16001,25 +16022,25 @@ KeyboardShortcut.displayName = "KeyboardShortcut_UI";
|
|
|
16001
16022
|
|
|
16002
16023
|
// src/components/List/List.tsx
|
|
16003
16024
|
import { isNotNil as isNotNil30 } from "@wistia/type-guards";
|
|
16004
|
-
import { styled as
|
|
16025
|
+
import { styled as styled75, css as css38 } from "styled-components";
|
|
16005
16026
|
|
|
16006
16027
|
// src/components/List/ListItem.tsx
|
|
16007
|
-
import { styled as
|
|
16028
|
+
import { styled as styled74 } from "styled-components";
|
|
16008
16029
|
import { isNil as isNil17 } from "@wistia/type-guards";
|
|
16009
|
-
import { jsx as
|
|
16010
|
-
var ListItemComponent =
|
|
16030
|
+
import { jsx as jsx311 } from "react/jsx-runtime";
|
|
16031
|
+
var ListItemComponent = styled74.li`
|
|
16011
16032
|
margin-bottom: var(--wui-space-02);
|
|
16012
16033
|
`;
|
|
16013
16034
|
var ListItem = ({ children }) => {
|
|
16014
16035
|
if (isNil17(children)) {
|
|
16015
16036
|
return null;
|
|
16016
16037
|
}
|
|
16017
|
-
return /* @__PURE__ */
|
|
16038
|
+
return /* @__PURE__ */ jsx311(ListItemComponent, { children });
|
|
16018
16039
|
};
|
|
16019
16040
|
ListItem.displayName = "ListItem_UI";
|
|
16020
16041
|
|
|
16021
16042
|
// src/components/List/List.tsx
|
|
16022
|
-
import { jsx as
|
|
16043
|
+
import { jsx as jsx312, jsxs as jsxs49 } from "react/jsx-runtime";
|
|
16023
16044
|
var spacesStyle = css38`
|
|
16024
16045
|
overflow: hidden;
|
|
16025
16046
|
padding-left: 0;
|
|
@@ -16078,7 +16099,7 @@ var unbulletedStyle = css38`
|
|
|
16078
16099
|
list-style: none;
|
|
16079
16100
|
padding-left: 0;
|
|
16080
16101
|
`;
|
|
16081
|
-
var ListComponent =
|
|
16102
|
+
var ListComponent = styled75.ul`
|
|
16082
16103
|
list-style-position: outside;
|
|
16083
16104
|
margin: 0 0 var(--wui-space-01);
|
|
16084
16105
|
padding: 0 0 0 var(--wui-space-04);
|
|
@@ -16105,7 +16126,7 @@ var ListComponent = styled74.ul`
|
|
|
16105
16126
|
`;
|
|
16106
16127
|
var renderListComponent = (listItems, variant, { ...otherProps }) => {
|
|
16107
16128
|
const elementType = variant === "ordered" ? "ol" : "ul";
|
|
16108
|
-
return /* @__PURE__ */
|
|
16129
|
+
return /* @__PURE__ */ jsx312(
|
|
16109
16130
|
ListComponent,
|
|
16110
16131
|
{
|
|
16111
16132
|
as: elementType,
|
|
@@ -16130,7 +16151,7 @@ var renderListFromArray = (listItems, variant, otherProps) => {
|
|
|
16130
16151
|
if (Array.isArray(item)) {
|
|
16131
16152
|
return null;
|
|
16132
16153
|
}
|
|
16133
|
-
return /* @__PURE__ */
|
|
16154
|
+
return /* @__PURE__ */ jsx312(ListItem, { children: item }, key);
|
|
16134
16155
|
});
|
|
16135
16156
|
return renderListComponent(items, variant, otherProps);
|
|
16136
16157
|
};
|
|
@@ -16158,9 +16179,9 @@ var List = ({
|
|
|
16158
16179
|
List.displayName = "List_UI";
|
|
16159
16180
|
|
|
16160
16181
|
// src/components/Mark/Mark.tsx
|
|
16161
|
-
import { styled as
|
|
16162
|
-
import { jsx as
|
|
16163
|
-
var StyledMark =
|
|
16182
|
+
import { styled as styled76 } from "styled-components";
|
|
16183
|
+
import { jsx as jsx313 } from "react/jsx-runtime";
|
|
16184
|
+
var StyledMark = styled76.mark`
|
|
16164
16185
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
16165
16186
|
background-color: var(--wui-color-bg-surface-tertiary);
|
|
16166
16187
|
color: var(--wui-color-text);
|
|
@@ -16168,7 +16189,7 @@ var StyledMark = styled75.mark`
|
|
|
16168
16189
|
padding-inline: 0.1em;
|
|
16169
16190
|
margin-inline: -0.1em;
|
|
16170
16191
|
`;
|
|
16171
|
-
var Mark = ({ children, colorScheme = "inherit", ...props }) => /* @__PURE__ */
|
|
16192
|
+
var Mark = ({ children, colorScheme = "inherit", ...props }) => /* @__PURE__ */ jsx313(
|
|
16172
16193
|
StyledMark,
|
|
16173
16194
|
{
|
|
16174
16195
|
$colorScheme: colorScheme,
|
|
@@ -16179,7 +16200,7 @@ var Mark = ({ children, colorScheme = "inherit", ...props }) => /* @__PURE__ */
|
|
|
16179
16200
|
Mark.displayName = "Mark_UI";
|
|
16180
16201
|
|
|
16181
16202
|
// src/components/Markdown/Markdown.tsx
|
|
16182
|
-
import { styled as
|
|
16203
|
+
import { styled as styled77 } from "styled-components";
|
|
16183
16204
|
import ReactMarkdown from "react-markdown";
|
|
16184
16205
|
|
|
16185
16206
|
// src/css/baseMarkdownCss.tsx
|
|
@@ -16307,8 +16328,8 @@ var baseMarkdownCss = (textSize = "body2") => css39`
|
|
|
16307
16328
|
`;
|
|
16308
16329
|
|
|
16309
16330
|
// src/components/Markdown/Markdown.tsx
|
|
16310
|
-
import { jsx as
|
|
16311
|
-
var StyledMarkdownWrapper =
|
|
16331
|
+
import { jsx as jsx314 } from "react/jsx-runtime";
|
|
16332
|
+
var StyledMarkdownWrapper = styled77.div`
|
|
16312
16333
|
${({ $textSize }) => baseMarkdownCss($textSize)}
|
|
16313
16334
|
`;
|
|
16314
16335
|
var Markdown = ({
|
|
@@ -16317,49 +16338,250 @@ var Markdown = ({
|
|
|
16317
16338
|
...otherProps
|
|
16318
16339
|
}) => {
|
|
16319
16340
|
const responsiveTextSize = useResponsiveProp(textSize);
|
|
16320
|
-
return /* @__PURE__ */
|
|
16341
|
+
return /* @__PURE__ */ jsx314(
|
|
16321
16342
|
StyledMarkdownWrapper,
|
|
16322
16343
|
{
|
|
16323
16344
|
$textSize: responsiveTextSize,
|
|
16324
16345
|
...otherProps,
|
|
16325
|
-
children: /* @__PURE__ */
|
|
16346
|
+
children: /* @__PURE__ */ jsx314(ReactMarkdown, { children })
|
|
16326
16347
|
}
|
|
16327
16348
|
);
|
|
16328
16349
|
};
|
|
16329
16350
|
Markdown.displayName = "Markdown_UI";
|
|
16330
16351
|
|
|
16352
|
+
// src/components/Meter/Meter.tsx
|
|
16353
|
+
import { styled as styled78 } from "styled-components";
|
|
16354
|
+
import { useId as useId5 } from "react";
|
|
16355
|
+
import { isNotNil as isNotNil31 } from "@wistia/type-guards";
|
|
16356
|
+
import { jsx as jsx315, jsxs as jsxs50 } from "react/jsx-runtime";
|
|
16357
|
+
var MeterWrapper = styled78.div`
|
|
16358
|
+
--meter-height: 16px;
|
|
16359
|
+
|
|
16360
|
+
display: flex;
|
|
16361
|
+
flex-direction: column;
|
|
16362
|
+
gap: var(--wui-space-02);
|
|
16363
|
+
`;
|
|
16364
|
+
var MeterLabelContainer = styled78.div`
|
|
16365
|
+
display: flex;
|
|
16366
|
+
justify-content: space-between;
|
|
16367
|
+
align-items: baseline;
|
|
16368
|
+
`;
|
|
16369
|
+
var MeterLabel = styled78.div`
|
|
16370
|
+
font-family: var(--wui-typography-heading-5-family);
|
|
16371
|
+
line-height: var(--wui-typography-heading-5-line-height);
|
|
16372
|
+
font-size: var(--wui-typography-heading-5-size);
|
|
16373
|
+
font-weight: var(--wui-typography-heading-5-weight);
|
|
16374
|
+
`;
|
|
16375
|
+
var MeterLabelMeta = styled78.div`
|
|
16376
|
+
font-family: var(--wui-typography-heading-5-family);
|
|
16377
|
+
line-height: var(--wui-typography-heading-5-line-height);
|
|
16378
|
+
font-size: var(--wui-typography-heading-5-size);
|
|
16379
|
+
font-weight: var(--wui-typography-heading-5-weight);
|
|
16380
|
+
`;
|
|
16381
|
+
var MeterBarContainer = styled78.div`
|
|
16382
|
+
position: relative;
|
|
16383
|
+
overflow: hidden;
|
|
16384
|
+
background-color: var(--wui-color-bg-surface-secondary);
|
|
16385
|
+
border-radius: var(--wui-border-radius-rounded);
|
|
16386
|
+
width: 100%;
|
|
16387
|
+
height: var(--meter-height);
|
|
16388
|
+
transform: translateZ(0);
|
|
16389
|
+
`;
|
|
16390
|
+
var MeterSegmentBar = styled78.div`
|
|
16391
|
+
position: absolute;
|
|
16392
|
+
top: 0;
|
|
16393
|
+
left: ${({ $offset }) => $offset}%;
|
|
16394
|
+
width: ${({ $width }) => $width}%;
|
|
16395
|
+
height: 100%;
|
|
16396
|
+
background-color: ${({ $color }) => `var(--wui-${$color})`};
|
|
16397
|
+
|
|
16398
|
+
&:first-child {
|
|
16399
|
+
border-top-left-radius: var(--wui-border-radius-rounded);
|
|
16400
|
+
border-bottom-left-radius: var(--wui-border-radius-rounded);
|
|
16401
|
+
}
|
|
16402
|
+
|
|
16403
|
+
&:last-child {
|
|
16404
|
+
border-top-right-radius: var(--wui-border-radius-rounded);
|
|
16405
|
+
border-bottom-right-radius: var(--wui-border-radius-rounded);
|
|
16406
|
+
}
|
|
16407
|
+
`;
|
|
16408
|
+
var MeterDescription = styled78.div`
|
|
16409
|
+
line-height: var(--wui-typography-label-3-line-height);
|
|
16410
|
+
font-size: var(--wui-typography-label-3-size);
|
|
16411
|
+
font-weight: var(--wui-typography-label-3-weight);
|
|
16412
|
+
color: var(--wui-color-text-secondary);
|
|
16413
|
+
`;
|
|
16414
|
+
var MeterKey = styled78.div`
|
|
16415
|
+
display: flex;
|
|
16416
|
+
flex-wrap: wrap;
|
|
16417
|
+
gap: var(--wui-space-03);
|
|
16418
|
+
`;
|
|
16419
|
+
var MeterKeyItem = styled78.div`
|
|
16420
|
+
display: flex;
|
|
16421
|
+
align-items: center;
|
|
16422
|
+
gap: var(--wui-space-01);
|
|
16423
|
+
`;
|
|
16424
|
+
var MeterKeyColorIndicator = styled78.div`
|
|
16425
|
+
width: 8px;
|
|
16426
|
+
height: 8px;
|
|
16427
|
+
border-radius: 50%;
|
|
16428
|
+
background-color: ${({ $color }) => `var(--wui-${$color})`};
|
|
16429
|
+
flex-shrink: 0;
|
|
16430
|
+
`;
|
|
16431
|
+
var MeterKeyLabel = styled78.span`
|
|
16432
|
+
line-height: var(--wui-typography-label-3-line-height);
|
|
16433
|
+
font-size: var(--wui-typography-label-3-size);
|
|
16434
|
+
font-weight: var(--wui-typography-label-3-weight);
|
|
16435
|
+
color: var(--wui-color-text-secondary);
|
|
16436
|
+
`;
|
|
16437
|
+
var nodeToString = (node) => {
|
|
16438
|
+
if (typeof node === "string") {
|
|
16439
|
+
return node;
|
|
16440
|
+
}
|
|
16441
|
+
if (typeof node === "number") {
|
|
16442
|
+
return String(node);
|
|
16443
|
+
}
|
|
16444
|
+
if (node == null || typeof node === "boolean") {
|
|
16445
|
+
return "";
|
|
16446
|
+
}
|
|
16447
|
+
if (Array.isArray(node)) {
|
|
16448
|
+
return node.map(nodeToString).join("");
|
|
16449
|
+
}
|
|
16450
|
+
if (typeof node === "object" && "props" in node) {
|
|
16451
|
+
const element = node;
|
|
16452
|
+
if (element.props?.children != null) {
|
|
16453
|
+
return nodeToString(element.props.children);
|
|
16454
|
+
}
|
|
16455
|
+
}
|
|
16456
|
+
return "";
|
|
16457
|
+
};
|
|
16458
|
+
var Meter = ({
|
|
16459
|
+
segments,
|
|
16460
|
+
label,
|
|
16461
|
+
labelMeta,
|
|
16462
|
+
description,
|
|
16463
|
+
hideKey = false,
|
|
16464
|
+
max = 100,
|
|
16465
|
+
"aria-label": ariaLabel,
|
|
16466
|
+
...props
|
|
16467
|
+
}) => {
|
|
16468
|
+
const labelId = useId5();
|
|
16469
|
+
const descriptionId = useId5();
|
|
16470
|
+
const segmentsWithOffsets = segments.reduce((acc, segment) => {
|
|
16471
|
+
const offset = acc.reduce((sum, prev) => sum + prev.widthPercent, 0);
|
|
16472
|
+
const widthPercent = segment.value / max * 100;
|
|
16473
|
+
acc.push({ ...segment, offset, widthPercent });
|
|
16474
|
+
return acc;
|
|
16475
|
+
}, []);
|
|
16476
|
+
const keySegments = segmentsWithOffsets.filter(
|
|
16477
|
+
(segment) => isNotNil31(segment.label)
|
|
16478
|
+
);
|
|
16479
|
+
const totalValue = segments.reduce((sum, segment) => sum + segment.value, 0);
|
|
16480
|
+
const generateAriaDescription = () => {
|
|
16481
|
+
const segmentDescriptions = segments.filter((segment) => isNotNil31(segment.label)).map((segment) => `${nodeToString(segment.label)}: ${segment.value}%`).join(", ");
|
|
16482
|
+
const totalDescription = `Total: ${totalValue} out of ${max}`;
|
|
16483
|
+
return segmentDescriptions ? `${segmentDescriptions}. ${totalDescription}` : totalDescription;
|
|
16484
|
+
};
|
|
16485
|
+
const effectiveAriaLabel = ariaLabel ?? (isNotNil31(label) ? nodeToString(label) : "Data meter");
|
|
16486
|
+
return /* @__PURE__ */ jsxs50(MeterWrapper, { ...props, children: [
|
|
16487
|
+
/* @__PURE__ */ jsx315(
|
|
16488
|
+
ScreenReaderOnly,
|
|
16489
|
+
{
|
|
16490
|
+
id: descriptionId,
|
|
16491
|
+
text: generateAriaDescription()
|
|
16492
|
+
}
|
|
16493
|
+
),
|
|
16494
|
+
isNotNil31(label) || isNotNil31(labelMeta) ? /* @__PURE__ */ jsxs50(MeterLabelContainer, { id: labelId, children: [
|
|
16495
|
+
isNotNil31(label) ? /* @__PURE__ */ jsx315(MeterLabel, { children: label }) : null,
|
|
16496
|
+
isNotNil31(labelMeta) ? /* @__PURE__ */ jsx315(MeterLabelMeta, { children: labelMeta }) : null
|
|
16497
|
+
] }) : null,
|
|
16498
|
+
/* @__PURE__ */ jsx315(
|
|
16499
|
+
MeterBarContainer,
|
|
16500
|
+
{
|
|
16501
|
+
"aria-describedby": descriptionId,
|
|
16502
|
+
"aria-label": effectiveAriaLabel,
|
|
16503
|
+
"aria-labelledby": isNotNil31(label) || isNotNil31(labelMeta) ? labelId : void 0,
|
|
16504
|
+
"aria-valuemax": max,
|
|
16505
|
+
"aria-valuemin": 0,
|
|
16506
|
+
"aria-valuenow": totalValue,
|
|
16507
|
+
role: "meter",
|
|
16508
|
+
children: segmentsWithOffsets.map((segment) => /* @__PURE__ */ jsx315(
|
|
16509
|
+
MeterSegmentBar,
|
|
16510
|
+
{
|
|
16511
|
+
$color: segment.color,
|
|
16512
|
+
$offset: segment.offset,
|
|
16513
|
+
$width: segment.widthPercent,
|
|
16514
|
+
"aria-hidden": "true"
|
|
16515
|
+
},
|
|
16516
|
+
`${segment.color}-${segment.value}-${segment.offset}`
|
|
16517
|
+
))
|
|
16518
|
+
}
|
|
16519
|
+
),
|
|
16520
|
+
isNotNil31(description) ? /* @__PURE__ */ jsx315(MeterDescription, { children: description }) : null,
|
|
16521
|
+
!hideKey && keySegments.length > 0 ? /* @__PURE__ */ jsx315(
|
|
16522
|
+
MeterKey,
|
|
16523
|
+
{
|
|
16524
|
+
"aria-label": "Meter legend",
|
|
16525
|
+
role: "list",
|
|
16526
|
+
children: keySegments.map((segment) => /* @__PURE__ */ jsxs50(
|
|
16527
|
+
MeterKeyItem,
|
|
16528
|
+
{
|
|
16529
|
+
role: "listitem",
|
|
16530
|
+
children: [
|
|
16531
|
+
/* @__PURE__ */ jsx315(
|
|
16532
|
+
MeterKeyColorIndicator,
|
|
16533
|
+
{
|
|
16534
|
+
$color: segment.color,
|
|
16535
|
+
"aria-hidden": "true"
|
|
16536
|
+
}
|
|
16537
|
+
),
|
|
16538
|
+
/* @__PURE__ */ jsx315(MeterKeyLabel, { children: segment.label })
|
|
16539
|
+
]
|
|
16540
|
+
},
|
|
16541
|
+
`${segment.color}-${segment.value}-${segment.offset}-${nodeToString(segment.label)}`
|
|
16542
|
+
))
|
|
16543
|
+
}
|
|
16544
|
+
) : null
|
|
16545
|
+
] });
|
|
16546
|
+
};
|
|
16547
|
+
Meter.displayName = "Meter_UI";
|
|
16548
|
+
|
|
16331
16549
|
// src/components/Modal/Modal.tsx
|
|
16332
16550
|
import { forwardRef as forwardRef26 } from "react";
|
|
16333
|
-
import { styled as
|
|
16334
|
-
import {
|
|
16335
|
-
|
|
16551
|
+
import { styled as styled83 } from "styled-components";
|
|
16552
|
+
import {
|
|
16553
|
+
Root as DialogRoot,
|
|
16554
|
+
Portal as DialogPortal,
|
|
16555
|
+
Description as DialogDescription
|
|
16556
|
+
} from "@radix-ui/react-dialog";
|
|
16557
|
+
import { isNotNil as isNotNil33 } from "@wistia/type-guards";
|
|
16336
16558
|
|
|
16337
16559
|
// src/components/Modal/ModalHeader.tsx
|
|
16338
|
-
import { styled as
|
|
16560
|
+
import { styled as styled80 } from "styled-components";
|
|
16339
16561
|
import { Title as DialogTitle } from "@radix-ui/react-dialog";
|
|
16340
16562
|
|
|
16341
16563
|
// src/components/Modal/ModalCloseButton.tsx
|
|
16342
|
-
import { styled as
|
|
16564
|
+
import { styled as styled79 } from "styled-components";
|
|
16343
16565
|
import { Close as DialogClose } from "@radix-ui/react-dialog";
|
|
16344
|
-
import { jsx as
|
|
16345
|
-
var CloseButton =
|
|
16566
|
+
import { jsx as jsx316 } from "react/jsx-runtime";
|
|
16567
|
+
var CloseButton = styled79(DialogClose)`
|
|
16346
16568
|
align-self: start;
|
|
16347
16569
|
`;
|
|
16348
16570
|
var ModalCloseButton = () => {
|
|
16349
|
-
return /* @__PURE__ */
|
|
16571
|
+
return /* @__PURE__ */ jsx316(CloseButton, { asChild: true, children: /* @__PURE__ */ jsx316(
|
|
16350
16572
|
IconButton,
|
|
16351
16573
|
{
|
|
16352
16574
|
label: "Dismiss modal",
|
|
16353
16575
|
size: "sm",
|
|
16354
16576
|
variant: "ghost",
|
|
16355
|
-
children: /* @__PURE__ */
|
|
16577
|
+
children: /* @__PURE__ */ jsx316(Icon, { type: "close" })
|
|
16356
16578
|
}
|
|
16357
16579
|
) });
|
|
16358
16580
|
};
|
|
16359
16581
|
|
|
16360
16582
|
// src/components/Modal/ModalHeader.tsx
|
|
16361
|
-
import { jsx as
|
|
16362
|
-
var Header =
|
|
16583
|
+
import { jsx as jsx317, jsxs as jsxs51 } from "react/jsx-runtime";
|
|
16584
|
+
var Header = styled80.header`
|
|
16363
16585
|
display: flex;
|
|
16364
16586
|
order: 1;
|
|
16365
16587
|
padding: 0 var(--wui-space-05);
|
|
@@ -16379,7 +16601,7 @@ var Header = styled78.header`
|
|
|
16379
16601
|
top: var(--wui-space-03);
|
|
16380
16602
|
}
|
|
16381
16603
|
`;
|
|
16382
|
-
var Title =
|
|
16604
|
+
var Title = styled80(DialogTitle)`
|
|
16383
16605
|
font-family: var(--wui-typography-heading-2-family);
|
|
16384
16606
|
line-height: var(--wui-typography-heading-2-line-height);
|
|
16385
16607
|
font-size: var(--wui-typography-heading-2-size);
|
|
@@ -16390,15 +16612,15 @@ var ModalHeader = ({
|
|
|
16390
16612
|
hideTitle,
|
|
16391
16613
|
hideCloseButton
|
|
16392
16614
|
}) => {
|
|
16393
|
-
const TitleComponent = hideTitle ? /* @__PURE__ */
|
|
16394
|
-
return /* @__PURE__ */
|
|
16615
|
+
const TitleComponent = hideTitle ? /* @__PURE__ */ jsx317(ScreenReaderOnly, { children: /* @__PURE__ */ jsx317(Title, { children: title }) }) : /* @__PURE__ */ jsx317(Title, { children: title });
|
|
16616
|
+
return /* @__PURE__ */ jsxs51(
|
|
16395
16617
|
Header,
|
|
16396
16618
|
{
|
|
16397
16619
|
$hideCloseButon: hideCloseButton,
|
|
16398
16620
|
$hideTitle: hideTitle,
|
|
16399
16621
|
children: [
|
|
16400
16622
|
TitleComponent,
|
|
16401
|
-
hideCloseButton ? null : /* @__PURE__ */
|
|
16623
|
+
hideCloseButton ? null : /* @__PURE__ */ jsx317(ModalCloseButton, {})
|
|
16402
16624
|
]
|
|
16403
16625
|
}
|
|
16404
16626
|
);
|
|
@@ -16406,7 +16628,7 @@ var ModalHeader = ({
|
|
|
16406
16628
|
|
|
16407
16629
|
// src/components/Modal/ModalContent.tsx
|
|
16408
16630
|
import { forwardRef as forwardRef25 } from "react";
|
|
16409
|
-
import { styled as
|
|
16631
|
+
import { styled as styled81, css as css40, keyframes as keyframes5 } from "styled-components";
|
|
16410
16632
|
import { Content as DialogContent } from "@radix-ui/react-dialog";
|
|
16411
16633
|
|
|
16412
16634
|
// src/components/Modal/constants.ts
|
|
@@ -16414,7 +16636,7 @@ var DEFAULT_MODAL_WIDTH = "532px";
|
|
|
16414
16636
|
|
|
16415
16637
|
// src/private/hooks/useFocusRestore/useFocusRestore.ts
|
|
16416
16638
|
import { useRef as useRef21, useEffect as useEffect20 } from "react";
|
|
16417
|
-
import { isNotNil as
|
|
16639
|
+
import { isNotNil as isNotNil32 } from "@wistia/type-guards";
|
|
16418
16640
|
var useFocusRestore = () => {
|
|
16419
16641
|
const previouslyFocusedRef = useRef21(null);
|
|
16420
16642
|
useEffect20(() => {
|
|
@@ -16422,7 +16644,7 @@ var useFocusRestore = () => {
|
|
|
16422
16644
|
}, []);
|
|
16423
16645
|
useEffect20(() => {
|
|
16424
16646
|
return () => {
|
|
16425
|
-
if (
|
|
16647
|
+
if (isNotNil32(previouslyFocusedRef.current)) {
|
|
16426
16648
|
setTimeout(() => {
|
|
16427
16649
|
previouslyFocusedRef.current?.focus();
|
|
16428
16650
|
}, 0);
|
|
@@ -16432,7 +16654,7 @@ var useFocusRestore = () => {
|
|
|
16432
16654
|
};
|
|
16433
16655
|
|
|
16434
16656
|
// src/components/Modal/ModalContent.tsx
|
|
16435
|
-
import { jsx as
|
|
16657
|
+
import { jsx as jsx318 } from "react/jsx-runtime";
|
|
16436
16658
|
var modalEnter = keyframes5`
|
|
16437
16659
|
from {
|
|
16438
16660
|
opacity: 0;
|
|
@@ -16530,7 +16752,7 @@ var positionStyleMap = {
|
|
|
16530
16752
|
"fixed-top": fixedTopModalStyles,
|
|
16531
16753
|
"right-side-panel": rightSidePanelModalStyles
|
|
16532
16754
|
};
|
|
16533
|
-
var StyledModalContent =
|
|
16755
|
+
var StyledModalContent = styled81(DialogContent)`
|
|
16534
16756
|
position: fixed;
|
|
16535
16757
|
display: flex;
|
|
16536
16758
|
flex-direction: column;
|
|
@@ -16560,13 +16782,12 @@ var StyledModalContent = styled79(DialogContent)`
|
|
|
16560
16782
|
var ModalContent = forwardRef25(
|
|
16561
16783
|
({ width, positionVariant = "fixed-top", children, ...props }, ref) => {
|
|
16562
16784
|
useFocusRestore();
|
|
16563
|
-
return /* @__PURE__ */
|
|
16785
|
+
return /* @__PURE__ */ jsx318(
|
|
16564
16786
|
StyledModalContent,
|
|
16565
16787
|
{
|
|
16566
16788
|
ref,
|
|
16567
16789
|
$positionVariant: positionVariant,
|
|
16568
16790
|
$width: width,
|
|
16569
|
-
"aria-describedby": void 0,
|
|
16570
16791
|
...props,
|
|
16571
16792
|
children
|
|
16572
16793
|
}
|
|
@@ -16576,7 +16797,7 @@ var ModalContent = forwardRef25(
|
|
|
16576
16797
|
|
|
16577
16798
|
// src/components/Modal/ModalOverlay.tsx
|
|
16578
16799
|
import { DialogOverlay } from "@radix-ui/react-dialog";
|
|
16579
|
-
import { styled as
|
|
16800
|
+
import { styled as styled82, keyframes as keyframes6 } from "styled-components";
|
|
16580
16801
|
var backdropShow = keyframes6`
|
|
16581
16802
|
from {
|
|
16582
16803
|
opacity: 0;
|
|
@@ -16595,7 +16816,7 @@ var backdropHide = keyframes6`
|
|
|
16595
16816
|
opacity: 0;
|
|
16596
16817
|
}
|
|
16597
16818
|
`;
|
|
16598
|
-
var ModalOverlay =
|
|
16819
|
+
var ModalOverlay = styled82(DialogOverlay)`
|
|
16599
16820
|
animation: ${backdropShow} var(--wui-motion-duration-02);
|
|
16600
16821
|
background: var(--wui-color-backdrop);
|
|
16601
16822
|
inset: 0;
|
|
@@ -16608,19 +16829,20 @@ var ModalOverlay = styled80(DialogOverlay)`
|
|
|
16608
16829
|
`;
|
|
16609
16830
|
|
|
16610
16831
|
// src/components/Modal/Modal.tsx
|
|
16611
|
-
import { jsx as
|
|
16612
|
-
var
|
|
16832
|
+
import { jsx as jsx319, jsxs as jsxs52 } from "react/jsx-runtime";
|
|
16833
|
+
var ModalHiddenDescription = styled83(DialogDescription)({ ...visuallyHiddenStyle });
|
|
16834
|
+
var ModalBody = styled83.div`
|
|
16613
16835
|
flex-direction: column;
|
|
16614
16836
|
display: flex;
|
|
16615
16837
|
flex: 1 0 0;
|
|
16616
16838
|
padding: 0 var(--wui-space-05);
|
|
16617
16839
|
`;
|
|
16618
|
-
var ModalScrollArea =
|
|
16840
|
+
var ModalScrollArea = styled83.div`
|
|
16619
16841
|
order: 2;
|
|
16620
16842
|
max-height: 90vh;
|
|
16621
16843
|
overflow-y: auto;
|
|
16622
16844
|
`;
|
|
16623
|
-
var ModalFooter =
|
|
16845
|
+
var ModalFooter = styled83.footer`
|
|
16624
16846
|
padding: 0 var(--wui-space-05);
|
|
16625
16847
|
order: 3;
|
|
16626
16848
|
`;
|
|
@@ -16638,23 +16860,23 @@ var Modal = forwardRef26(
|
|
|
16638
16860
|
width = DEFAULT_MODAL_WIDTH,
|
|
16639
16861
|
...props
|
|
16640
16862
|
}, ref) => {
|
|
16641
|
-
return /* @__PURE__ */
|
|
16863
|
+
return /* @__PURE__ */ jsx319(
|
|
16642
16864
|
DialogRoot,
|
|
16643
16865
|
{
|
|
16644
16866
|
onOpenChange: (open2) => {
|
|
16645
|
-
if (!open2 &&
|
|
16867
|
+
if (!open2 && isNotNil33(onRequestClose)) {
|
|
16646
16868
|
onRequestClose();
|
|
16647
16869
|
}
|
|
16648
16870
|
},
|
|
16649
16871
|
open: isOpen,
|
|
16650
|
-
children: /* @__PURE__ */
|
|
16651
|
-
/* @__PURE__ */
|
|
16652
|
-
/* @__PURE__ */
|
|
16872
|
+
children: /* @__PURE__ */ jsxs52(DialogPortal, { children: [
|
|
16873
|
+
/* @__PURE__ */ jsx319(ModalOverlay, {}),
|
|
16874
|
+
/* @__PURE__ */ jsxs52(
|
|
16653
16875
|
ModalContent,
|
|
16654
16876
|
{
|
|
16655
16877
|
ref,
|
|
16656
16878
|
onOpenAutoFocus: (event) => {
|
|
16657
|
-
if (
|
|
16879
|
+
if (isNotNil33(initialFocusRef) && initialFocusRef.current) {
|
|
16658
16880
|
event.preventDefault();
|
|
16659
16881
|
requestAnimationFrame(() => {
|
|
16660
16882
|
initialFocusRef.current?.focus();
|
|
@@ -16665,16 +16887,17 @@ var Modal = forwardRef26(
|
|
|
16665
16887
|
width,
|
|
16666
16888
|
...props,
|
|
16667
16889
|
children: [
|
|
16668
|
-
/* @__PURE__ */
|
|
16669
|
-
|
|
16670
|
-
hideCloseButton && hideTitle ? null : /* @__PURE__ */
|
|
16890
|
+
/* @__PURE__ */ jsx319(ModalScrollArea, { children: /* @__PURE__ */ jsx319(ModalBody, { children }) }),
|
|
16891
|
+
isNotNil33(footer) ? /* @__PURE__ */ jsx319(ModalFooter, { children: footer }) : null,
|
|
16892
|
+
hideCloseButton && hideTitle ? null : /* @__PURE__ */ jsx319(
|
|
16671
16893
|
ModalHeader,
|
|
16672
16894
|
{
|
|
16673
16895
|
hideCloseButton,
|
|
16674
16896
|
hideTitle,
|
|
16675
16897
|
title
|
|
16676
16898
|
}
|
|
16677
|
-
)
|
|
16899
|
+
),
|
|
16900
|
+
/* @__PURE__ */ jsx319(ModalHiddenDescription, {})
|
|
16678
16901
|
]
|
|
16679
16902
|
}
|
|
16680
16903
|
)
|
|
@@ -16686,9 +16909,9 @@ var Modal = forwardRef26(
|
|
|
16686
16909
|
Modal.displayName = "Modal_UI";
|
|
16687
16910
|
|
|
16688
16911
|
// src/components/Modal/ModalCallouts.tsx
|
|
16689
|
-
import { jsx as
|
|
16912
|
+
import { jsx as jsx320, jsxs as jsxs53 } from "react/jsx-runtime";
|
|
16690
16913
|
var ModalCallouts = ({ children }) => {
|
|
16691
|
-
return /* @__PURE__ */
|
|
16914
|
+
return /* @__PURE__ */ jsx320(
|
|
16692
16915
|
Stack,
|
|
16693
16916
|
{
|
|
16694
16917
|
direction: "horizontal",
|
|
@@ -16699,9 +16922,9 @@ var ModalCallouts = ({ children }) => {
|
|
|
16699
16922
|
};
|
|
16700
16923
|
ModalCallouts.displayName = "ModalCallouts_UI";
|
|
16701
16924
|
var ModalCallout = ({ title, image, children }) => {
|
|
16702
|
-
return /* @__PURE__ */
|
|
16925
|
+
return /* @__PURE__ */ jsxs53(Stack, { direction: "vertical", children: [
|
|
16703
16926
|
image,
|
|
16704
|
-
/* @__PURE__ */
|
|
16927
|
+
/* @__PURE__ */ jsx320(Heading, { variant: "heading4", children: title }),
|
|
16705
16928
|
children
|
|
16706
16929
|
] });
|
|
16707
16930
|
};
|
|
@@ -16709,19 +16932,19 @@ ModalCallout.displayName = "ModalCallout_UI";
|
|
|
16709
16932
|
|
|
16710
16933
|
// src/components/Popover/Popover.tsx
|
|
16711
16934
|
import { Root as Root2, Trigger as Trigger2, Portal, Content as Content2, Close } from "@radix-ui/react-popover";
|
|
16712
|
-
import { styled as
|
|
16935
|
+
import { styled as styled85, css as css42 } from "styled-components";
|
|
16713
16936
|
|
|
16714
16937
|
// src/private/helpers/getControls/getControlProps.tsx
|
|
16715
|
-
import { isNotNil as
|
|
16938
|
+
import { isNotNil as isNotNil34 } from "@wistia/type-guards";
|
|
16716
16939
|
var getControlProps = (isOpen, onOpenChange) => {
|
|
16717
|
-
return
|
|
16940
|
+
return isNotNil34(onOpenChange) && isNotNil34(isOpen) ? { open: isOpen, onOpenChange } : {};
|
|
16718
16941
|
};
|
|
16719
16942
|
|
|
16720
16943
|
// src/components/Popover/PopoverArrow.tsx
|
|
16721
16944
|
import { PopoverArrow as RadixPopoverArrow } from "@radix-ui/react-popover";
|
|
16722
|
-
import { styled as
|
|
16723
|
-
import { jsx as
|
|
16724
|
-
var StyledPath =
|
|
16945
|
+
import { styled as styled84, css as css41, keyframes as keyframes7 } from "styled-components";
|
|
16946
|
+
import { jsx as jsx321, jsxs as jsxs54 } from "react/jsx-runtime";
|
|
16947
|
+
var StyledPath = styled84.path`
|
|
16725
16948
|
fill: var(--wui-color-border-secondary);
|
|
16726
16949
|
`;
|
|
16727
16950
|
var circleAnimation = keyframes7`
|
|
@@ -16732,7 +16955,7 @@ var circleAnimation = keyframes7`
|
|
|
16732
16955
|
opacity: 0;
|
|
16733
16956
|
}
|
|
16734
16957
|
`;
|
|
16735
|
-
var StyledCircle =
|
|
16958
|
+
var StyledCircle = styled84.circle`
|
|
16736
16959
|
stroke: var(--wui-color-border-active);
|
|
16737
16960
|
animation-duration: 2s;
|
|
16738
16961
|
animation-iteration-count: infinite;
|
|
@@ -16759,7 +16982,7 @@ var StyledCircle = styled82.circle`
|
|
|
16759
16982
|
}
|
|
16760
16983
|
`;
|
|
16761
16984
|
var PopoverArrow = ({ isAnimated }) => {
|
|
16762
|
-
return /* @__PURE__ */
|
|
16985
|
+
return /* @__PURE__ */ jsx321(RadixPopoverArrow, { asChild: true, children: /* @__PURE__ */ jsxs54(
|
|
16763
16986
|
"svg",
|
|
16764
16987
|
{
|
|
16765
16988
|
fill: "none",
|
|
@@ -16768,8 +16991,8 @@ var PopoverArrow = ({ isAnimated }) => {
|
|
|
16768
16991
|
width: "48",
|
|
16769
16992
|
xmlns: "http://www.w3.org/2000/svg",
|
|
16770
16993
|
children: [
|
|
16771
|
-
/* @__PURE__ */
|
|
16772
|
-
/* @__PURE__ */
|
|
16994
|
+
/* @__PURE__ */ jsx321(StyledPath, { d: "M24 26.6667C21.0545 26.6667 18.6667 29.0545 18.6667 32C18.6667 34.9455 21.0545 37.3333 24 37.3333C26.9455 37.3333 29.3333 34.9455 29.3333 32C29.3333 29.0545 26.9455 26.6667 24 26.6667ZM23 0V32H25V0H23Z" }),
|
|
16995
|
+
/* @__PURE__ */ jsx321(
|
|
16773
16996
|
StyledCircle,
|
|
16774
16997
|
{
|
|
16775
16998
|
$isAnimated: isAnimated,
|
|
@@ -16780,7 +17003,7 @@ var PopoverArrow = ({ isAnimated }) => {
|
|
|
16780
17003
|
strokeWidth: "4"
|
|
16781
17004
|
}
|
|
16782
17005
|
),
|
|
16783
|
-
/* @__PURE__ */
|
|
17006
|
+
/* @__PURE__ */ jsx321(
|
|
16784
17007
|
StyledCircle,
|
|
16785
17008
|
{
|
|
16786
17009
|
$isAnimated: isAnimated,
|
|
@@ -16798,8 +17021,8 @@ var PopoverArrow = ({ isAnimated }) => {
|
|
|
16798
17021
|
PopoverArrow.displayName = "PopoverArrow_UI";
|
|
16799
17022
|
|
|
16800
17023
|
// src/components/Popover/Popover.tsx
|
|
16801
|
-
import { jsx as
|
|
16802
|
-
var StyledContent2 =
|
|
17024
|
+
import { jsx as jsx322, jsxs as jsxs55 } from "react/jsx-runtime";
|
|
17025
|
+
var StyledContent2 = styled85(Content2)`
|
|
16803
17026
|
z-index: var(--wui-zindex-popover);
|
|
16804
17027
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
16805
17028
|
${({ $unstyled }) => !$unstyled && css42`
|
|
@@ -16838,9 +17061,9 @@ var Popover = ({
|
|
|
16838
17061
|
"--wui-popover-max-width": maxWidth,
|
|
16839
17062
|
"--wui-popover-max-height": maxHeight
|
|
16840
17063
|
};
|
|
16841
|
-
return /* @__PURE__ */
|
|
16842
|
-
/* @__PURE__ */
|
|
16843
|
-
/* @__PURE__ */
|
|
17064
|
+
return /* @__PURE__ */ jsxs55(Root2, { ...getControlProps(isOpen, onOpenChange), children: [
|
|
17065
|
+
/* @__PURE__ */ jsx322(Trigger2, { asChild: true, children: trigger }),
|
|
17066
|
+
/* @__PURE__ */ jsx322(Portal, { children: /* @__PURE__ */ jsxs55(
|
|
16844
17067
|
StyledContent2,
|
|
16845
17068
|
{
|
|
16846
17069
|
$colorScheme: colorScheme,
|
|
@@ -16849,17 +17072,17 @@ var Popover = ({
|
|
|
16849
17072
|
$unstyled: unstyled,
|
|
16850
17073
|
style,
|
|
16851
17074
|
children: [
|
|
16852
|
-
!hideCloseButton && /* @__PURE__ */
|
|
17075
|
+
!hideCloseButton && /* @__PURE__ */ jsx322(Close, { asChild: true, children: /* @__PURE__ */ jsx322(
|
|
16853
17076
|
IconButton,
|
|
16854
17077
|
{
|
|
16855
17078
|
"data-wui-popover-close": true,
|
|
16856
17079
|
label: "Close",
|
|
16857
17080
|
variant: "ghost",
|
|
16858
|
-
children: /* @__PURE__ */
|
|
17081
|
+
children: /* @__PURE__ */ jsx322(Icon, { type: "close" })
|
|
16859
17082
|
}
|
|
16860
17083
|
) }),
|
|
16861
|
-
withArrow ? /* @__PURE__ */
|
|
16862
|
-
/* @__PURE__ */
|
|
17084
|
+
withArrow ? /* @__PURE__ */ jsx322(PopoverArrow, { isAnimated }) : null,
|
|
17085
|
+
/* @__PURE__ */ jsx322("div", { children })
|
|
16863
17086
|
]
|
|
16864
17087
|
}
|
|
16865
17088
|
) })
|
|
@@ -16868,11 +17091,11 @@ var Popover = ({
|
|
|
16868
17091
|
Popover.displayName = "Popover_UI";
|
|
16869
17092
|
|
|
16870
17093
|
// src/components/ProgressBar/ProgressBar.tsx
|
|
16871
|
-
import { styled as
|
|
17094
|
+
import { styled as styled86 } from "styled-components";
|
|
16872
17095
|
import { Root as ProgressRoot, Indicator as ProgressIndicator } from "@radix-ui/react-progress";
|
|
16873
|
-
import { isNotNil as
|
|
16874
|
-
import { jsx as
|
|
16875
|
-
var ProgressBarWrapper =
|
|
17096
|
+
import { isNotNil as isNotNil35 } from "@wistia/type-guards";
|
|
17097
|
+
import { jsx as jsx323, jsxs as jsxs56 } from "react/jsx-runtime";
|
|
17098
|
+
var ProgressBarWrapper = styled86.div`
|
|
16876
17099
|
--progress-bar-height: 8px;
|
|
16877
17100
|
|
|
16878
17101
|
display: flex;
|
|
@@ -16886,7 +17109,7 @@ var getTranslateValue = (progress, max) => {
|
|
|
16886
17109
|
const progressPercentage = progress / max * 100;
|
|
16887
17110
|
return `translateX(-${100 - progressPercentage}%)`;
|
|
16888
17111
|
};
|
|
16889
|
-
var ProgressBarLabel =
|
|
17112
|
+
var ProgressBarLabel = styled86.div`
|
|
16890
17113
|
display: flex;
|
|
16891
17114
|
line-height: var(--wui-typography-label-3-line-height);
|
|
16892
17115
|
font-size: var(--wui-typography-label-3-size);
|
|
@@ -16894,7 +17117,7 @@ var ProgressBarLabel = styled84.div`
|
|
|
16894
17117
|
color: var(--wui-color-text-secondary);
|
|
16895
17118
|
flex-shrink: 0;
|
|
16896
17119
|
`;
|
|
16897
|
-
var StyledProgressIndicator =
|
|
17120
|
+
var StyledProgressIndicator = styled86(ProgressIndicator)`
|
|
16898
17121
|
${({ $colorScheme }) => getColorScheme($colorScheme)}
|
|
16899
17122
|
background-color: var(--wui-color-bg-fill);
|
|
16900
17123
|
width: 100%;
|
|
@@ -16904,7 +17127,7 @@ var StyledProgressIndicator = styled84(ProgressIndicator)`
|
|
|
16904
17127
|
transition: transform 660ms cubic-bezier(0.65, 0, 0.35, 1);
|
|
16905
17128
|
transform: ${({ $progress, $max }) => getTranslateValue($progress, $max)};
|
|
16906
17129
|
`;
|
|
16907
|
-
var StyledProgressBar =
|
|
17130
|
+
var StyledProgressBar = styled86(ProgressRoot)`
|
|
16908
17131
|
${({ $colorScheme }) => getColorScheme($colorScheme)}
|
|
16909
17132
|
position: relative;
|
|
16910
17133
|
overflow: hidden;
|
|
@@ -16925,16 +17148,16 @@ var ProgressBar = ({
|
|
|
16925
17148
|
colorScheme = "inherit",
|
|
16926
17149
|
...props
|
|
16927
17150
|
}) => {
|
|
16928
|
-
return /* @__PURE__ */
|
|
16929
|
-
|
|
16930
|
-
/* @__PURE__ */
|
|
17151
|
+
return /* @__PURE__ */ jsxs56(ProgressBarWrapper, { children: [
|
|
17152
|
+
isNotNil35(labelLeft) ? /* @__PURE__ */ jsx323(ProgressBarLabel, { children: labelLeft }) : null,
|
|
17153
|
+
/* @__PURE__ */ jsx323(
|
|
16931
17154
|
StyledProgressBar,
|
|
16932
17155
|
{
|
|
16933
17156
|
$colorScheme: colorScheme,
|
|
16934
17157
|
max,
|
|
16935
17158
|
value: progress,
|
|
16936
17159
|
...props,
|
|
16937
|
-
children: /* @__PURE__ */
|
|
17160
|
+
children: /* @__PURE__ */ jsx323(
|
|
16938
17161
|
StyledProgressIndicator,
|
|
16939
17162
|
{
|
|
16940
17163
|
$colorScheme: colorScheme,
|
|
@@ -16944,16 +17167,16 @@ var ProgressBar = ({
|
|
|
16944
17167
|
)
|
|
16945
17168
|
}
|
|
16946
17169
|
),
|
|
16947
|
-
|
|
17170
|
+
isNotNil35(labelRight) ? /* @__PURE__ */ jsx323(ProgressBarLabel, { children: labelRight }) : null
|
|
16948
17171
|
] });
|
|
16949
17172
|
};
|
|
16950
17173
|
ProgressBar.displayName = "ProgressBar_UI";
|
|
16951
17174
|
|
|
16952
17175
|
// src/components/Radio/Radio.tsx
|
|
16953
17176
|
import { isNonEmptyString as isNonEmptyString7, isNotUndefined as isNotUndefined14 } from "@wistia/type-guards";
|
|
16954
|
-
import { forwardRef as forwardRef27, useId as
|
|
16955
|
-
import { styled as
|
|
16956
|
-
import { jsx as
|
|
17177
|
+
import { forwardRef as forwardRef27, useId as useId6 } from "react";
|
|
17178
|
+
import { styled as styled87, css as css43 } from "styled-components";
|
|
17179
|
+
import { jsx as jsx324, jsxs as jsxs57 } from "react/jsx-runtime";
|
|
16957
17180
|
var sizeSmall2 = css43`
|
|
16958
17181
|
--wui-radio-size: 14px;
|
|
16959
17182
|
--wui-radio-icon-size: 7px;
|
|
@@ -16975,7 +17198,7 @@ var getSizeCss3 = (size) => {
|
|
|
16975
17198
|
}
|
|
16976
17199
|
return sizeMedium2;
|
|
16977
17200
|
};
|
|
16978
|
-
var StyledRadioWrapper =
|
|
17201
|
+
var StyledRadioWrapper = styled87.div`
|
|
16979
17202
|
--wui-radio-background-color: var(--wui-color-bg-surface);
|
|
16980
17203
|
--wui-radio-border-color: var(--wui-color-border-secondary);
|
|
16981
17204
|
--wui-radio-icon-color: transparent;
|
|
@@ -17009,7 +17232,7 @@ var StyledRadioWrapper = styled85.div`
|
|
|
17009
17232
|
/* TODO this solves a problem but potentially causes and a11y issue */
|
|
17010
17233
|
user-select: none;
|
|
17011
17234
|
`;
|
|
17012
|
-
var StyledRadioInput =
|
|
17235
|
+
var StyledRadioInput = styled87.div`
|
|
17013
17236
|
${({ $size }) => getSizeCss3($size)}
|
|
17014
17237
|
width: var(--wui-radio-size);
|
|
17015
17238
|
height: var(--wui-radio-size);
|
|
@@ -17035,7 +17258,7 @@ var StyledRadioInput = styled85.div`
|
|
|
17035
17258
|
transform: translate(-50%, -50%);
|
|
17036
17259
|
}
|
|
17037
17260
|
`;
|
|
17038
|
-
var StyledHiddenRadioInput =
|
|
17261
|
+
var StyledHiddenRadioInput = styled87.input`
|
|
17039
17262
|
${visuallyHiddenStyle}
|
|
17040
17263
|
`;
|
|
17041
17264
|
var Radio = forwardRef27(
|
|
@@ -17053,7 +17276,7 @@ var Radio = forwardRef27(
|
|
|
17053
17276
|
hideLabel = false,
|
|
17054
17277
|
...props
|
|
17055
17278
|
}, ref) => {
|
|
17056
|
-
const generatedId =
|
|
17279
|
+
const generatedId = useId6();
|
|
17057
17280
|
const computedId = isNonEmptyString7(id) ? id : `wistia-ui-radio-${generatedId}`;
|
|
17058
17281
|
const radioGroupContext = useRadioGroup();
|
|
17059
17282
|
const contextName = radioGroupContext?.name;
|
|
@@ -17062,14 +17285,14 @@ var Radio = forwardRef27(
|
|
|
17062
17285
|
const radioName = name ?? contextName;
|
|
17063
17286
|
const handleOnChange = onChange ?? contextOnChange;
|
|
17064
17287
|
const isChecked = isNotUndefined14(value) && isNotUndefined14(contextValue) ? contextValue === value : checked;
|
|
17065
|
-
return /* @__PURE__ */
|
|
17288
|
+
return /* @__PURE__ */ jsxs57(
|
|
17066
17289
|
StyledRadioWrapper,
|
|
17067
17290
|
{
|
|
17068
17291
|
$disabled: disabled,
|
|
17069
17292
|
$hideLabel: hideLabel,
|
|
17070
17293
|
"aria-invalid": props["aria-invalid"],
|
|
17071
17294
|
children: [
|
|
17072
|
-
/* @__PURE__ */
|
|
17295
|
+
/* @__PURE__ */ jsx324(
|
|
17073
17296
|
StyledHiddenRadioInput,
|
|
17074
17297
|
{
|
|
17075
17298
|
...props,
|
|
@@ -17084,10 +17307,10 @@ var Radio = forwardRef27(
|
|
|
17084
17307
|
value
|
|
17085
17308
|
}
|
|
17086
17309
|
),
|
|
17087
|
-
/* @__PURE__ */
|
|
17310
|
+
/* @__PURE__ */ jsx324(
|
|
17088
17311
|
FormControlLabel,
|
|
17089
17312
|
{
|
|
17090
|
-
controlSlot: /* @__PURE__ */
|
|
17313
|
+
controlSlot: /* @__PURE__ */ jsx324(StyledRadioInput, { $size: size }),
|
|
17091
17314
|
description,
|
|
17092
17315
|
disabled,
|
|
17093
17316
|
hideLabel,
|
|
@@ -17106,10 +17329,10 @@ Radio.displayName = "Radio_UI";
|
|
|
17106
17329
|
import { forwardRef as forwardRef29 } from "react";
|
|
17107
17330
|
|
|
17108
17331
|
// src/components/RadioCard/RadioCardRoot.tsx
|
|
17109
|
-
import { forwardRef as forwardRef28, useId as
|
|
17110
|
-
import { styled as
|
|
17332
|
+
import { forwardRef as forwardRef28, useId as useId7 } from "react";
|
|
17333
|
+
import { styled as styled88, css as css44 } from "styled-components";
|
|
17111
17334
|
import { isNonEmptyString as isNonEmptyString8, isNotUndefined as isNotUndefined15 } from "@wistia/type-guards";
|
|
17112
|
-
import { jsx as
|
|
17335
|
+
import { jsx as jsx325, jsxs as jsxs58 } from "react/jsx-runtime";
|
|
17113
17336
|
var checkedStyles = css44`
|
|
17114
17337
|
--wui-radio-card-border-color: var(--wui-color-focus-ring);
|
|
17115
17338
|
--wui-color-icon: var(--wui-color-icon-selected);
|
|
@@ -17125,6 +17348,17 @@ var disabledStyles = css44`
|
|
|
17125
17348
|
--wui-color-text: var(--wui-color-text-disabled);
|
|
17126
17349
|
--wui-color-text-secondary: var(--wui-color-text-disabled);
|
|
17127
17350
|
`;
|
|
17351
|
+
var gatedStyles = css44`
|
|
17352
|
+
--wui-radio-card-background-color: var(--wui-color-bg-surface-purple);
|
|
17353
|
+
--wui-radio-card-border-color: var(--wui-color-border-purple);
|
|
17354
|
+
`;
|
|
17355
|
+
var gatedCheckedStyles = css44`
|
|
17356
|
+
--wui-radio-card-background-color: var(--wui-color-bg-surface-purple);
|
|
17357
|
+
--wui-radio-card-border-color: var(--wui-color-focus-ring);
|
|
17358
|
+
--wui-color-icon: var(--wui-color-icon-selected);
|
|
17359
|
+
--wui-color-text: var(--wui-color-text-info);
|
|
17360
|
+
--wui-color-text-secondary: var(--wui-color-text-info);
|
|
17361
|
+
`;
|
|
17128
17362
|
var focusStyles = css44`
|
|
17129
17363
|
outline: 2px solid var(--wui-color-focus-ring);
|
|
17130
17364
|
`;
|
|
@@ -17159,7 +17393,7 @@ var imageCoverStyles = css44`
|
|
|
17159
17393
|
transition: all var(--wui-motion-duration-02) var(--wui-motion-ease);
|
|
17160
17394
|
}
|
|
17161
17395
|
`;
|
|
17162
|
-
var StyledCard2 =
|
|
17396
|
+
var StyledCard2 = styled88.label`
|
|
17163
17397
|
--wui-radio-card-border-color: var(--wui-color-border-secondary);
|
|
17164
17398
|
--wui-radio-card-background-color: var(--wui-color-bg-surface);
|
|
17165
17399
|
--wui-radio-card-cursor: pointer;
|
|
@@ -17189,7 +17423,15 @@ var StyledCard2 = styled86.label`
|
|
|
17189
17423
|
--wui-radio-card-border-color: var(--wui-color-border-secondary-active);
|
|
17190
17424
|
}
|
|
17191
17425
|
|
|
17192
|
-
&:has(
|
|
17426
|
+
&:has([data-wui-radio-card-gated]) {
|
|
17427
|
+
${gatedStyles}
|
|
17428
|
+
}
|
|
17429
|
+
|
|
17430
|
+
&:has([data-wui-radio-card-gated]):has(input:checked) {
|
|
17431
|
+
${gatedCheckedStyles}
|
|
17432
|
+
}
|
|
17433
|
+
|
|
17434
|
+
&:has(input:checked):not(:has([data-wui-radio-card-gated])) {
|
|
17193
17435
|
${checkedStyles}
|
|
17194
17436
|
}
|
|
17195
17437
|
|
|
@@ -17213,7 +17455,7 @@ var StyledCard2 = styled86.label`
|
|
|
17213
17455
|
}
|
|
17214
17456
|
}
|
|
17215
17457
|
`;
|
|
17216
|
-
var StyledHiddenInput =
|
|
17458
|
+
var StyledHiddenInput = styled88.input`
|
|
17217
17459
|
${visuallyHiddenStyle}
|
|
17218
17460
|
`;
|
|
17219
17461
|
var RadioCardRoot = forwardRef28(
|
|
@@ -17221,6 +17463,7 @@ var RadioCardRoot = forwardRef28(
|
|
|
17221
17463
|
children,
|
|
17222
17464
|
disabled = false,
|
|
17223
17465
|
id,
|
|
17466
|
+
isGated = false,
|
|
17224
17467
|
name,
|
|
17225
17468
|
onChange,
|
|
17226
17469
|
value,
|
|
@@ -17229,7 +17472,7 @@ var RadioCardRoot = forwardRef28(
|
|
|
17229
17472
|
checked,
|
|
17230
17473
|
...props
|
|
17231
17474
|
}, ref) => {
|
|
17232
|
-
const generatedId =
|
|
17475
|
+
const generatedId = useId7();
|
|
17233
17476
|
const computedId = isNonEmptyString8(id) ? id : `wistia-ui-radio-${generatedId}`;
|
|
17234
17477
|
const radioGroupContext = useRadioGroup();
|
|
17235
17478
|
const contextName = radioGroupContext?.name;
|
|
@@ -17238,14 +17481,14 @@ var RadioCardRoot = forwardRef28(
|
|
|
17238
17481
|
const radioName = name ?? contextName;
|
|
17239
17482
|
const handleOnChange = onChange ?? contextOnChange;
|
|
17240
17483
|
const isChecked = isNotUndefined15(value) && isNotUndefined15(contextValue) ? contextValue === value : checked;
|
|
17241
|
-
return /* @__PURE__ */
|
|
17484
|
+
return /* @__PURE__ */ jsxs58(
|
|
17242
17485
|
StyledCard2,
|
|
17243
17486
|
{
|
|
17244
17487
|
$aspectRatio: aspectRatio,
|
|
17245
17488
|
$padding: padding,
|
|
17246
17489
|
htmlFor: computedId,
|
|
17247
17490
|
children: [
|
|
17248
|
-
/* @__PURE__ */
|
|
17491
|
+
/* @__PURE__ */ jsx325(
|
|
17249
17492
|
StyledHiddenInput,
|
|
17250
17493
|
{
|
|
17251
17494
|
...props,
|
|
@@ -17259,6 +17502,7 @@ var RadioCardRoot = forwardRef28(
|
|
|
17259
17502
|
value
|
|
17260
17503
|
}
|
|
17261
17504
|
),
|
|
17505
|
+
isGated && /* @__PURE__ */ jsx325("div", { "data-wui-radio-card-gated": true, style: { display: "none" } }),
|
|
17262
17506
|
children
|
|
17263
17507
|
]
|
|
17264
17508
|
}
|
|
@@ -17268,12 +17512,12 @@ var RadioCardRoot = forwardRef28(
|
|
|
17268
17512
|
RadioCardRoot.displayName = "RadioCardRoot_UI";
|
|
17269
17513
|
|
|
17270
17514
|
// src/components/RadioCard/RadioCardDefaultLayout.tsx
|
|
17271
|
-
import { styled as
|
|
17272
|
-
import { isNotNil as
|
|
17515
|
+
import { styled as styled90 } from "styled-components";
|
|
17516
|
+
import { isNotNil as isNotNil36 } from "@wistia/type-guards";
|
|
17273
17517
|
|
|
17274
17518
|
// src/components/RadioCard/RadioCardIndicator.tsx
|
|
17275
|
-
import { styled as
|
|
17276
|
-
var RadioCardIndicator =
|
|
17519
|
+
import { styled as styled89 } from "styled-components";
|
|
17520
|
+
var RadioCardIndicator = styled89.div`
|
|
17277
17521
|
--wui-radio-card-indicator-size: 14px;
|
|
17278
17522
|
--wui-radio-card-indicator-background-color: var(--wui-color-bg-surface);
|
|
17279
17523
|
--wui-radio-card-indicator-fill-color: var(--wui-color-bg-fill);
|
|
@@ -17322,16 +17566,22 @@ var RadioCardIndicator = styled87.div`
|
|
|
17322
17566
|
RadioCardIndicator.displayName = "RadioCardIndicator_UI";
|
|
17323
17567
|
|
|
17324
17568
|
// src/components/RadioCard/RadioCardDefaultLayout.tsx
|
|
17325
|
-
import { jsx as
|
|
17326
|
-
var StyledCardContent =
|
|
17569
|
+
import { jsx as jsx326, jsxs as jsxs59 } from "react/jsx-runtime";
|
|
17570
|
+
var StyledCardContent = styled90.div`
|
|
17327
17571
|
display: grid;
|
|
17328
17572
|
grid-auto-flow: column;
|
|
17329
17573
|
gap: var(--wui-space-02);
|
|
17330
17574
|
`;
|
|
17331
|
-
var StyledCardIcon =
|
|
17575
|
+
var StyledCardIcon = styled90.div`
|
|
17332
17576
|
display: contents;
|
|
17333
17577
|
`;
|
|
17334
|
-
var
|
|
17578
|
+
var StyledGatedIcon = styled90.div`
|
|
17579
|
+
position: absolute;
|
|
17580
|
+
right: 10px;
|
|
17581
|
+
top: 10px;
|
|
17582
|
+
z-index: 1;
|
|
17583
|
+
`;
|
|
17584
|
+
var StyledIndicatorContainer = styled90.div`
|
|
17335
17585
|
height: ${({ $hasIcon }) => $hasIcon ? "24px" : "16px"};
|
|
17336
17586
|
display: flex;
|
|
17337
17587
|
align-items: center;
|
|
@@ -17340,20 +17590,28 @@ var RadioCardDefaultLayout = ({
|
|
|
17340
17590
|
icon,
|
|
17341
17591
|
label,
|
|
17342
17592
|
description,
|
|
17343
|
-
showIndicator = true
|
|
17593
|
+
showIndicator = true,
|
|
17594
|
+
isGated = false
|
|
17344
17595
|
}) => {
|
|
17345
|
-
return /* @__PURE__ */
|
|
17346
|
-
showIndicator ? /* @__PURE__ */
|
|
17347
|
-
/* @__PURE__ */
|
|
17348
|
-
|
|
17349
|
-
|
|
17596
|
+
return /* @__PURE__ */ jsxs59(StyledCardContent, { children: [
|
|
17597
|
+
showIndicator ? /* @__PURE__ */ jsx326(StyledIndicatorContainer, { $hasIcon: isNotNil36(icon), children: /* @__PURE__ */ jsx326(RadioCardIndicator, { "data-testid": "wui-radio-card-indicator" }) }) : null,
|
|
17598
|
+
isGated && /* @__PURE__ */ jsx326(StyledGatedIcon, { "data-testid": "wui-radio-gated-icon", children: /* @__PURE__ */ jsx326(
|
|
17599
|
+
Icon,
|
|
17600
|
+
{
|
|
17601
|
+
colorScheme: "purple",
|
|
17602
|
+
type: "sparkle"
|
|
17603
|
+
}
|
|
17604
|
+
) }),
|
|
17605
|
+
/* @__PURE__ */ jsxs59(Stack, { gap: "space-02", children: [
|
|
17606
|
+
isNotNil36(icon) && /* @__PURE__ */ jsx326(StyledCardIcon, { "data-wui-radio-card-icon": true, children: icon }),
|
|
17607
|
+
/* @__PURE__ */ jsxs59(
|
|
17350
17608
|
Stack,
|
|
17351
17609
|
{
|
|
17352
17610
|
gap: "space-01",
|
|
17353
|
-
style:
|
|
17611
|
+
style: isNotNil36(icon) ? { paddingLeft: 2 } : void 0,
|
|
17354
17612
|
children: [
|
|
17355
|
-
|
|
17356
|
-
|
|
17613
|
+
isNotNil36(label) && /* @__PURE__ */ jsx326(Text, { variant: "label3", children: /* @__PURE__ */ jsx326("strong", { children: label }) }),
|
|
17614
|
+
isNotNil36(description) && /* @__PURE__ */ jsx326(
|
|
17357
17615
|
Text,
|
|
17358
17616
|
{
|
|
17359
17617
|
prominence: "secondary",
|
|
@@ -17370,28 +17628,30 @@ var RadioCardDefaultLayout = ({
|
|
|
17370
17628
|
RadioCardDefaultLayout.displayName = "RadioCardDefaultLayout_UI";
|
|
17371
17629
|
|
|
17372
17630
|
// src/components/RadioCard/RadioCardChildrenContainer.tsx
|
|
17373
|
-
import { styled as
|
|
17374
|
-
var RadioCardChildrenContainer =
|
|
17631
|
+
import { styled as styled91 } from "styled-components";
|
|
17632
|
+
var RadioCardChildrenContainer = styled91.div`
|
|
17375
17633
|
flex: 1 1 auto;
|
|
17376
17634
|
`;
|
|
17377
17635
|
|
|
17378
17636
|
// src/components/RadioCard/RadioCard.tsx
|
|
17379
|
-
import { jsx as
|
|
17637
|
+
import { jsx as jsx327 } from "react/jsx-runtime";
|
|
17380
17638
|
var RadioCard = forwardRef29(
|
|
17381
|
-
({ icon, label, description, showIndicator, children, ...rootProps }, ref) => {
|
|
17382
|
-
return /* @__PURE__ */
|
|
17639
|
+
({ icon, label, description, showIndicator, isGated, children, ...rootProps }, ref) => {
|
|
17640
|
+
return /* @__PURE__ */ jsx327(
|
|
17383
17641
|
RadioCardRoot,
|
|
17384
17642
|
{
|
|
17385
17643
|
ref,
|
|
17644
|
+
isGated,
|
|
17386
17645
|
padding: children != null ? "space-00" : "space-04",
|
|
17387
17646
|
...rootProps,
|
|
17388
|
-
children: children != null ? /* @__PURE__ */
|
|
17647
|
+
children: children != null ? /* @__PURE__ */ jsx327(RadioCardChildrenContainer, { "data-wui-radio-card-image": "cover", children }) : /* @__PURE__ */ jsx327(
|
|
17389
17648
|
RadioCardDefaultLayout,
|
|
17390
17649
|
{
|
|
17391
17650
|
description,
|
|
17392
17651
|
icon,
|
|
17393
17652
|
label,
|
|
17394
|
-
showIndicator
|
|
17653
|
+
showIndicator,
|
|
17654
|
+
isGated
|
|
17395
17655
|
}
|
|
17396
17656
|
)
|
|
17397
17657
|
}
|
|
@@ -17402,17 +17662,17 @@ RadioCard.displayName = "RadioCard_UI";
|
|
|
17402
17662
|
|
|
17403
17663
|
// src/components/RadioCard/RadioCardImage.tsx
|
|
17404
17664
|
import { forwardRef as forwardRef30 } from "react";
|
|
17405
|
-
import { jsx as
|
|
17665
|
+
import { jsx as jsx328 } from "react/jsx-runtime";
|
|
17406
17666
|
var RadioCardImage = forwardRef30(
|
|
17407
17667
|
({ label, imageSrc, aspectRatio, padding = "space-04", ...rootProps }, ref) => {
|
|
17408
|
-
return /* @__PURE__ */
|
|
17668
|
+
return /* @__PURE__ */ jsx328(
|
|
17409
17669
|
RadioCardRoot,
|
|
17410
17670
|
{
|
|
17411
17671
|
ref,
|
|
17412
17672
|
...rootProps,
|
|
17413
17673
|
aspectRatio,
|
|
17414
17674
|
padding,
|
|
17415
|
-
children: /* @__PURE__ */
|
|
17675
|
+
children: /* @__PURE__ */ jsx328(
|
|
17416
17676
|
Image,
|
|
17417
17677
|
{
|
|
17418
17678
|
alt: label,
|
|
@@ -17430,49 +17690,49 @@ RadioCardImage.displayName = "RadioCardImage_UI";
|
|
|
17430
17690
|
|
|
17431
17691
|
// src/components/ScrollArea/ScrollArea.tsx
|
|
17432
17692
|
import { forwardRef as forwardRef31, useCallback as useCallback18, useEffect as useEffect21, useMemo as useMemo15, useRef as useRef22, useState as useState24 } from "react";
|
|
17433
|
-
import { styled as
|
|
17693
|
+
import { styled as styled92 } from "styled-components";
|
|
17434
17694
|
import { throttle } from "throttle-debounce";
|
|
17435
|
-
import { jsx as
|
|
17695
|
+
import { jsx as jsx329, jsxs as jsxs60 } from "react/jsx-runtime";
|
|
17436
17696
|
var SHADOW_SIZE_PX = 8;
|
|
17437
|
-
var Container10 =
|
|
17697
|
+
var Container10 = styled92.div`
|
|
17438
17698
|
overflow: hidden;
|
|
17439
17699
|
position: relative;
|
|
17440
17700
|
flex: 1 1 auto;
|
|
17441
17701
|
`;
|
|
17442
|
-
var ScrollContainer =
|
|
17702
|
+
var ScrollContainer = styled92.div`
|
|
17443
17703
|
overflow: ${({ $locked }) => $locked ? "hidden" : "auto"};
|
|
17444
17704
|
height: 100%;
|
|
17445
17705
|
width: 100%;
|
|
17446
17706
|
`;
|
|
17447
|
-
var Shadow =
|
|
17707
|
+
var Shadow = styled92.div`
|
|
17448
17708
|
pointer-events: none;
|
|
17449
17709
|
position: absolute;
|
|
17450
17710
|
transition: box-shadow var(--wui-motion-duration-04) var(--wui-motion-ease);
|
|
17451
17711
|
box-shadow: ${({ $isVisible }) => $isVisible ? `0 0 ${SHADOW_SIZE_PX}px ${SHADOW_SIZE_PX}px var(--wui-color-drop-shadow)` : "none"};
|
|
17452
17712
|
z-index: 1;
|
|
17453
17713
|
`;
|
|
17454
|
-
var ShadowAtTop =
|
|
17714
|
+
var ShadowAtTop = styled92(Shadow)`
|
|
17455
17715
|
transform: translateY(-${SHADOW_SIZE_PX}px);
|
|
17456
17716
|
height: 0;
|
|
17457
17717
|
left: 0;
|
|
17458
17718
|
right: 0;
|
|
17459
17719
|
top: 0;
|
|
17460
17720
|
`;
|
|
17461
|
-
var ShadowAtBottom =
|
|
17721
|
+
var ShadowAtBottom = styled92(Shadow)`
|
|
17462
17722
|
transform: translateY(${SHADOW_SIZE_PX}px);
|
|
17463
17723
|
bottom: 0;
|
|
17464
17724
|
height: 0;
|
|
17465
17725
|
left: 0;
|
|
17466
17726
|
right: 0;
|
|
17467
17727
|
`;
|
|
17468
|
-
var ShadowAtLeft =
|
|
17728
|
+
var ShadowAtLeft = styled92(Shadow)`
|
|
17469
17729
|
transform: translateX(-${SHADOW_SIZE_PX}px);
|
|
17470
17730
|
bottom: 0;
|
|
17471
17731
|
left: 0;
|
|
17472
17732
|
top: 0;
|
|
17473
17733
|
width: 0;
|
|
17474
17734
|
`;
|
|
17475
|
-
var ShadowAtRight =
|
|
17735
|
+
var ShadowAtRight = styled92(Shadow)`
|
|
17476
17736
|
transform: translateX(${SHADOW_SIZE_PX}px);
|
|
17477
17737
|
bottom: 0;
|
|
17478
17738
|
right: 0;
|
|
@@ -17512,12 +17772,12 @@ var ScrollArea = forwardRef31(
|
|
|
17512
17772
|
useEffect21(() => {
|
|
17513
17773
|
updateShadows();
|
|
17514
17774
|
}, [updateShadows]);
|
|
17515
|
-
return /* @__PURE__ */
|
|
17516
|
-
/* @__PURE__ */
|
|
17517
|
-
/* @__PURE__ */
|
|
17518
|
-
/* @__PURE__ */
|
|
17519
|
-
/* @__PURE__ */
|
|
17520
|
-
/* @__PURE__ */
|
|
17775
|
+
return /* @__PURE__ */ jsxs60(Container10, { style, children: [
|
|
17776
|
+
/* @__PURE__ */ jsx329(ShadowAtTop, { $isVisible: shadowState.canScrollUp }),
|
|
17777
|
+
/* @__PURE__ */ jsx329(ShadowAtBottom, { $isVisible: shadowState.canScrollDown }),
|
|
17778
|
+
/* @__PURE__ */ jsx329(ShadowAtLeft, { $isVisible: shadowState.canScrollLeft }),
|
|
17779
|
+
/* @__PURE__ */ jsx329(ShadowAtRight, { $isVisible: shadowState.canScrollRight }),
|
|
17780
|
+
/* @__PURE__ */ jsx329(
|
|
17521
17781
|
ScrollContainer,
|
|
17522
17782
|
{
|
|
17523
17783
|
ref: scrollContainerRef,
|
|
@@ -17534,13 +17794,13 @@ ScrollArea.displayName = "ScrollArea_UI";
|
|
|
17534
17794
|
|
|
17535
17795
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
17536
17796
|
import { forwardRef as forwardRef32 } from "react";
|
|
17537
|
-
import { styled as
|
|
17797
|
+
import { styled as styled94, css as css46 } from "styled-components";
|
|
17538
17798
|
import { Root as ToggleGroupRoot2 } from "@radix-ui/react-toggle-group";
|
|
17539
17799
|
import { isNil as isNil18 } from "@wistia/type-guards";
|
|
17540
17800
|
|
|
17541
17801
|
// src/components/SegmentedControl/useSelectedItemStyle.tsx
|
|
17542
17802
|
import { createContext as createContext9, useContext as useContext15, useMemo as useMemo16, useState as useState25 } from "react";
|
|
17543
|
-
import { jsx as
|
|
17803
|
+
import { jsx as jsx330 } from "react/jsx-runtime";
|
|
17544
17804
|
var SelectedItemStyleContext = createContext9(null);
|
|
17545
17805
|
var SelectedItemStyleProvider = ({
|
|
17546
17806
|
children
|
|
@@ -17561,7 +17821,7 @@ var SelectedItemStyleProvider = ({
|
|
|
17561
17821
|
}),
|
|
17562
17822
|
[selectedItemIndicatorStyle]
|
|
17563
17823
|
);
|
|
17564
|
-
return /* @__PURE__ */
|
|
17824
|
+
return /* @__PURE__ */ jsx330(SelectedItemStyleContext.Provider, { value: contextValue, children });
|
|
17565
17825
|
};
|
|
17566
17826
|
var useSelectedItemStyle = () => {
|
|
17567
17827
|
const context = useContext15(SelectedItemStyleContext);
|
|
@@ -17572,7 +17832,7 @@ var useSelectedItemStyle = () => {
|
|
|
17572
17832
|
};
|
|
17573
17833
|
|
|
17574
17834
|
// src/components/SegmentedControl/SelectedItemIndicator.tsx
|
|
17575
|
-
import { styled as
|
|
17835
|
+
import { styled as styled93, css as css45 } from "styled-components";
|
|
17576
17836
|
import { isUndefined as isUndefined5 } from "@wistia/type-guards";
|
|
17577
17837
|
|
|
17578
17838
|
// src/components/SegmentedControl/useSegmentedControlValue.tsx
|
|
@@ -17588,13 +17848,13 @@ var useSegmentedControlValue = () => {
|
|
|
17588
17848
|
};
|
|
17589
17849
|
|
|
17590
17850
|
// src/components/SegmentedControl/SelectedItemIndicator.tsx
|
|
17591
|
-
import { jsx as
|
|
17851
|
+
import { jsx as jsx331 } from "react/jsx-runtime";
|
|
17592
17852
|
var selectedItemIndicatorStyles = css45`
|
|
17593
17853
|
background-color: var(--wui-color-bg-fill-white);
|
|
17594
17854
|
border-radius: var(--wui-border-radius-rounded);
|
|
17595
17855
|
box-shadow: var(--wui-elevation-01);
|
|
17596
17856
|
`;
|
|
17597
|
-
var SelectedItemIndicatorDiv =
|
|
17857
|
+
var SelectedItemIndicatorDiv = styled93.div`
|
|
17598
17858
|
${selectedItemIndicatorStyles}
|
|
17599
17859
|
left: 0;
|
|
17600
17860
|
position: absolute;
|
|
@@ -17610,7 +17870,7 @@ var SelectedItemIndicator = () => {
|
|
|
17610
17870
|
if (!selectedValue || isUndefined5(selectedItemIndicatorStyle)) {
|
|
17611
17871
|
return null;
|
|
17612
17872
|
}
|
|
17613
|
-
return /* @__PURE__ */
|
|
17873
|
+
return /* @__PURE__ */ jsx331(
|
|
17614
17874
|
SelectedItemIndicatorDiv,
|
|
17615
17875
|
{
|
|
17616
17876
|
"data-wui-selected-item-indicator": true,
|
|
@@ -17620,7 +17880,7 @@ var SelectedItemIndicator = () => {
|
|
|
17620
17880
|
};
|
|
17621
17881
|
|
|
17622
17882
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
17623
|
-
import { jsx as
|
|
17883
|
+
import { jsx as jsx332, jsxs as jsxs61 } from "react/jsx-runtime";
|
|
17624
17884
|
var segmentedControlStyles = css46`
|
|
17625
17885
|
${({ $colorScheme }) => $colorScheme && getColorScheme($colorScheme)};
|
|
17626
17886
|
${({ $colorScheme }) => $colorScheme !== "nav" && `--wui-color-text-selected: var(--wui-color-text-link);`}
|
|
@@ -17635,7 +17895,7 @@ var segmentedControlStyles = css46`
|
|
|
17635
17895
|
position: relative;
|
|
17636
17896
|
width: ${({ $fullWidth }) => $fullWidth ? "100%" : "auto"};
|
|
17637
17897
|
`;
|
|
17638
|
-
var StyledSegmentedControl =
|
|
17898
|
+
var StyledSegmentedControl = styled94(ToggleGroupRoot2)`
|
|
17639
17899
|
${segmentedControlStyles}
|
|
17640
17900
|
`;
|
|
17641
17901
|
var SegmentedControl = forwardRef32(
|
|
@@ -17651,7 +17911,7 @@ var SegmentedControl = forwardRef32(
|
|
|
17651
17911
|
if (isNil18(children)) {
|
|
17652
17912
|
return null;
|
|
17653
17913
|
}
|
|
17654
|
-
return /* @__PURE__ */
|
|
17914
|
+
return /* @__PURE__ */ jsx332(
|
|
17655
17915
|
StyledSegmentedControl,
|
|
17656
17916
|
{
|
|
17657
17917
|
ref,
|
|
@@ -17664,9 +17924,9 @@ var SegmentedControl = forwardRef32(
|
|
|
17664
17924
|
type: "single",
|
|
17665
17925
|
value: selectedValue,
|
|
17666
17926
|
...props,
|
|
17667
|
-
children: /* @__PURE__ */
|
|
17927
|
+
children: /* @__PURE__ */ jsx332(SegmentedControlValueProvider, { value: selectedValue, children: /* @__PURE__ */ jsxs61(SelectedItemStyleProvider, { children: [
|
|
17668
17928
|
children,
|
|
17669
|
-
/* @__PURE__ */
|
|
17929
|
+
/* @__PURE__ */ jsx332(SelectedItemIndicator, {})
|
|
17670
17930
|
] }) })
|
|
17671
17931
|
}
|
|
17672
17932
|
);
|
|
@@ -17676,10 +17936,10 @@ SegmentedControl.displayName = "SegmentedControl_UI";
|
|
|
17676
17936
|
|
|
17677
17937
|
// src/components/SegmentedControl/SegmentedControlItem.tsx
|
|
17678
17938
|
import { forwardRef as forwardRef33, useEffect as useEffect22, useRef as useRef23 } from "react";
|
|
17679
|
-
import { styled as
|
|
17939
|
+
import { styled as styled95, css as css47 } from "styled-components";
|
|
17680
17940
|
import { Item as ToggleGroupItem2 } from "@radix-ui/react-toggle-group";
|
|
17681
|
-
import { isNotNil as
|
|
17682
|
-
import { jsxs as
|
|
17941
|
+
import { isNotNil as isNotNil37 } from "@wistia/type-guards";
|
|
17942
|
+
import { jsxs as jsxs62 } from "react/jsx-runtime";
|
|
17683
17943
|
var segmentedControlItemStyles = css47`
|
|
17684
17944
|
all: unset; /* ToggleGroupItem is a button element */
|
|
17685
17945
|
align-items: center;
|
|
@@ -17748,7 +18008,7 @@ var segmentedControlItemStyles = css47`
|
|
|
17748
18008
|
}
|
|
17749
18009
|
}
|
|
17750
18010
|
`;
|
|
17751
|
-
var StyledSegmentedControlItem =
|
|
18011
|
+
var StyledSegmentedControlItem = styled95(ToggleGroupItem2)`
|
|
17752
18012
|
${segmentedControlItemStyles}
|
|
17753
18013
|
`;
|
|
17754
18014
|
var SegmentedControlItem = forwardRef33(
|
|
@@ -17789,13 +18049,13 @@ var SegmentedControlItem = forwardRef33(
|
|
|
17789
18049
|
resizeObserver.disconnect();
|
|
17790
18050
|
};
|
|
17791
18051
|
}, [selectedValue, setSelectedItemMeasurements, value]);
|
|
17792
|
-
return /* @__PURE__ */
|
|
18052
|
+
return /* @__PURE__ */ jsxs62(
|
|
17793
18053
|
StyledSegmentedControlItem,
|
|
17794
18054
|
{
|
|
17795
18055
|
ref: combinedRef,
|
|
17796
18056
|
...otherProps,
|
|
17797
|
-
$hasLabel:
|
|
17798
|
-
"aria-label":
|
|
18057
|
+
$hasLabel: isNotNil37(label),
|
|
18058
|
+
"aria-label": isNotNil37(label) ? void 0 : ariaLabel,
|
|
17799
18059
|
disabled,
|
|
17800
18060
|
onClick: handleClick,
|
|
17801
18061
|
value,
|
|
@@ -17821,9 +18081,9 @@ import {
|
|
|
17821
18081
|
ScrollDownButton
|
|
17822
18082
|
} from "@radix-ui/react-select";
|
|
17823
18083
|
import { forwardRef as forwardRef34 } from "react";
|
|
17824
|
-
import { styled as
|
|
17825
|
-
import { jsx as
|
|
17826
|
-
var StyledTrigger2 =
|
|
18084
|
+
import { styled as styled96, css as css48 } from "styled-components";
|
|
18085
|
+
import { jsx as jsx333, jsxs as jsxs63 } from "react/jsx-runtime";
|
|
18086
|
+
var StyledTrigger2 = styled96(Trigger3)`
|
|
17827
18087
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
17828
18088
|
${inputCss};
|
|
17829
18089
|
padding: var(--wui-input-vertical-padding) var(--wui-input-horizontal-padding);
|
|
@@ -17869,7 +18129,7 @@ var StyledTrigger2 = styled94(Trigger3)`
|
|
|
17869
18129
|
color: var(--wui-input-placeholder);
|
|
17870
18130
|
}
|
|
17871
18131
|
`;
|
|
17872
|
-
var StyledContent3 =
|
|
18132
|
+
var StyledContent3 = styled96(Content3)`
|
|
17873
18133
|
--wui-select-content-border: var(--wui-color-border);
|
|
17874
18134
|
--wui-select-content-bg: var(--wui-color-bg-surface);
|
|
17875
18135
|
--wui-select-content-border-radius: var(--wui-border-radius-02);
|
|
@@ -17896,10 +18156,10 @@ var scrollButtonStyles = css48`
|
|
|
17896
18156
|
display: flex;
|
|
17897
18157
|
justify-content: center;
|
|
17898
18158
|
`;
|
|
17899
|
-
var StyledScrollDownButton =
|
|
18159
|
+
var StyledScrollDownButton = styled96(ScrollDownButton)`
|
|
17900
18160
|
${scrollButtonStyles}
|
|
17901
18161
|
`;
|
|
17902
|
-
var StyledScrollUpButton =
|
|
18162
|
+
var StyledScrollUpButton = styled96(ScrollUpButton)`
|
|
17903
18163
|
${scrollButtonStyles}
|
|
17904
18164
|
`;
|
|
17905
18165
|
var Select = forwardRef34(
|
|
@@ -17922,8 +18182,8 @@ var Select = forwardRef34(
|
|
|
17922
18182
|
if (forceOpen) {
|
|
17923
18183
|
rootProps["open"] = true;
|
|
17924
18184
|
}
|
|
17925
|
-
return /* @__PURE__ */
|
|
17926
|
-
/* @__PURE__ */
|
|
18185
|
+
return /* @__PURE__ */ jsxs63(Root3, { ...rootProps, children: [
|
|
18186
|
+
/* @__PURE__ */ jsxs63(
|
|
17927
18187
|
StyledTrigger2,
|
|
17928
18188
|
{
|
|
17929
18189
|
ref: forwardedRef,
|
|
@@ -17931,8 +18191,8 @@ var Select = forwardRef34(
|
|
|
17931
18191
|
$fullWidth: responsiveFullWidth,
|
|
17932
18192
|
...props,
|
|
17933
18193
|
children: [
|
|
17934
|
-
/* @__PURE__ */
|
|
17935
|
-
/* @__PURE__ */
|
|
18194
|
+
/* @__PURE__ */ jsx333(Value, { placeholder }),
|
|
18195
|
+
/* @__PURE__ */ jsx333(
|
|
17936
18196
|
Icon,
|
|
17937
18197
|
{
|
|
17938
18198
|
size: "md",
|
|
@@ -17942,21 +18202,21 @@ var Select = forwardRef34(
|
|
|
17942
18202
|
]
|
|
17943
18203
|
}
|
|
17944
18204
|
),
|
|
17945
|
-
/* @__PURE__ */
|
|
18205
|
+
/* @__PURE__ */ jsx333(Portal2, { children: /* @__PURE__ */ jsxs63(
|
|
17946
18206
|
StyledContent3,
|
|
17947
18207
|
{
|
|
17948
18208
|
position: "popper",
|
|
17949
18209
|
sideOffset: 8,
|
|
17950
18210
|
children: [
|
|
17951
|
-
/* @__PURE__ */
|
|
18211
|
+
/* @__PURE__ */ jsx333(StyledScrollUpButton, { children: /* @__PURE__ */ jsx333(
|
|
17952
18212
|
Icon,
|
|
17953
18213
|
{
|
|
17954
18214
|
size: "sm",
|
|
17955
18215
|
type: "caret-up"
|
|
17956
18216
|
}
|
|
17957
18217
|
) }),
|
|
17958
|
-
/* @__PURE__ */
|
|
17959
|
-
/* @__PURE__ */
|
|
18218
|
+
/* @__PURE__ */ jsx333(Viewport, { children }),
|
|
18219
|
+
/* @__PURE__ */ jsx333(StyledScrollDownButton, { children: /* @__PURE__ */ jsx333(
|
|
17960
18220
|
Icon,
|
|
17961
18221
|
{
|
|
17962
18222
|
size: "sm",
|
|
@@ -17974,10 +18234,10 @@ Select.displayName = "Select_UI";
|
|
|
17974
18234
|
// src/components/Select/SelectOption.tsx
|
|
17975
18235
|
import { Item, ItemText, ItemIndicator } from "@radix-ui/react-select";
|
|
17976
18236
|
import { forwardRef as forwardRef35 } from "react";
|
|
17977
|
-
import { styled as
|
|
17978
|
-
import { isNotNil as
|
|
17979
|
-
import { jsx as
|
|
17980
|
-
var StyledItem =
|
|
18237
|
+
import { styled as styled97 } from "styled-components";
|
|
18238
|
+
import { isNotNil as isNotNil38 } from "@wistia/type-guards";
|
|
18239
|
+
import { jsx as jsx334, jsxs as jsxs64 } from "react/jsx-runtime";
|
|
18240
|
+
var StyledItem = styled97(Item)`
|
|
17981
18241
|
${getTypographicStyles("label3")}
|
|
17982
18242
|
align-items: ${({ $checkmarkVerticalAlign }) => $checkmarkVerticalAlign === "center" ? "center" : "flex-start"};
|
|
17983
18243
|
background-color: transparent;
|
|
@@ -18005,18 +18265,18 @@ var StyledItem = styled95(Item)`
|
|
|
18005
18265
|
`;
|
|
18006
18266
|
var SelectOption = forwardRef35(
|
|
18007
18267
|
({ children, selectedDisplayValue, checkmarkVerticalAlign = "center", ...props }, forwardedRef) => {
|
|
18008
|
-
return /* @__PURE__ */
|
|
18268
|
+
return /* @__PURE__ */ jsxs64(
|
|
18009
18269
|
StyledItem,
|
|
18010
18270
|
{
|
|
18011
18271
|
...props,
|
|
18012
18272
|
ref: forwardedRef,
|
|
18013
18273
|
$checkmarkVerticalAlign: checkmarkVerticalAlign,
|
|
18014
18274
|
children: [
|
|
18015
|
-
|
|
18275
|
+
isNotNil38(selectedDisplayValue) ? /* @__PURE__ */ jsxs64("div", { children: [
|
|
18016
18276
|
children,
|
|
18017
|
-
/* @__PURE__ */
|
|
18018
|
-
] }) : /* @__PURE__ */
|
|
18019
|
-
/* @__PURE__ */
|
|
18277
|
+
/* @__PURE__ */ jsx334("div", { style: { display: "none" }, children: /* @__PURE__ */ jsx334(ItemText, { children: selectedDisplayValue }) })
|
|
18278
|
+
] }) : /* @__PURE__ */ jsx334(ItemText, { children }),
|
|
18279
|
+
/* @__PURE__ */ jsx334(ItemIndicator, { children: /* @__PURE__ */ jsx334(
|
|
18020
18280
|
Icon,
|
|
18021
18281
|
{
|
|
18022
18282
|
size: "md",
|
|
@@ -18032,14 +18292,14 @@ SelectOption.displayName = "SelectOption_UI";
|
|
|
18032
18292
|
|
|
18033
18293
|
// src/components/Select/SelectOptionGroup.tsx
|
|
18034
18294
|
import { Group, Label as Label3 } from "@radix-ui/react-select";
|
|
18035
|
-
import { styled as
|
|
18036
|
-
import { jsx as
|
|
18037
|
-
var StyledLabel4 =
|
|
18295
|
+
import { styled as styled98 } from "styled-components";
|
|
18296
|
+
import { jsx as jsx335, jsxs as jsxs65 } from "react/jsx-runtime";
|
|
18297
|
+
var StyledLabel4 = styled98(Label3)`
|
|
18038
18298
|
padding: var(--wui-select-option-padding);
|
|
18039
18299
|
`;
|
|
18040
18300
|
var SelectOptionGroup = ({ children, label, ...props }) => {
|
|
18041
|
-
return /* @__PURE__ */
|
|
18042
|
-
/* @__PURE__ */
|
|
18301
|
+
return /* @__PURE__ */ jsxs65(Group, { ...props, children: [
|
|
18302
|
+
/* @__PURE__ */ jsx335(StyledLabel4, { children: /* @__PURE__ */ jsx335(
|
|
18043
18303
|
Heading,
|
|
18044
18304
|
{
|
|
18045
18305
|
renderAs: "span",
|
|
@@ -18058,10 +18318,10 @@ import {
|
|
|
18058
18318
|
Range as RadixSliderRange,
|
|
18059
18319
|
Thumb as RadixSliderThumb
|
|
18060
18320
|
} from "@radix-ui/react-slider";
|
|
18061
|
-
import { styled as
|
|
18321
|
+
import { styled as styled99 } from "styled-components";
|
|
18062
18322
|
import { isNonEmptyString as isNonEmptyString9 } from "@wistia/type-guards";
|
|
18063
|
-
import { jsx as
|
|
18064
|
-
var SliderContainer =
|
|
18323
|
+
import { jsx as jsx336, jsxs as jsxs66 } from "react/jsx-runtime";
|
|
18324
|
+
var SliderContainer = styled99.div`
|
|
18065
18325
|
--wui-slider-track-color: var(--wui-gray-6);
|
|
18066
18326
|
--wui-slider-track-border-radius: var(--wui-border-radius-rounded);
|
|
18067
18327
|
--wui-slider-range-color: var(--wui-color-bg-fill);
|
|
@@ -18077,7 +18337,7 @@ var SliderContainer = styled97.div`
|
|
|
18077
18337
|
pointer-events: none;
|
|
18078
18338
|
}
|
|
18079
18339
|
`;
|
|
18080
|
-
var StyledSliderRoot =
|
|
18340
|
+
var StyledSliderRoot = styled99(RadixSliderRoot)`
|
|
18081
18341
|
position: relative;
|
|
18082
18342
|
display: flex;
|
|
18083
18343
|
align-items: center;
|
|
@@ -18085,20 +18345,20 @@ var StyledSliderRoot = styled97(RadixSliderRoot)`
|
|
|
18085
18345
|
touch-action: none;
|
|
18086
18346
|
width: 100%;
|
|
18087
18347
|
`;
|
|
18088
|
-
var StyledSliderTrack =
|
|
18348
|
+
var StyledSliderTrack = styled99(RadixSliderTrack)`
|
|
18089
18349
|
background-color: var(--wui-slider-track-color);
|
|
18090
18350
|
border-radius: var(--wui-slider-track-border-radius);
|
|
18091
18351
|
flex-grow: 1;
|
|
18092
18352
|
height: 6px;
|
|
18093
18353
|
position: relative;
|
|
18094
18354
|
`;
|
|
18095
|
-
var StyledSliderRange =
|
|
18355
|
+
var StyledSliderRange = styled99(RadixSliderRange)`
|
|
18096
18356
|
background-color: var(--wui-slider-range-color);
|
|
18097
18357
|
border-radius: var(--wui-slider-track-border-radius);
|
|
18098
18358
|
height: 100%;
|
|
18099
18359
|
position: absolute;
|
|
18100
18360
|
`;
|
|
18101
|
-
var StyledSliderThumb =
|
|
18361
|
+
var StyledSliderThumb = styled99(RadixSliderThumb)`
|
|
18102
18362
|
background-color: var(--wui-slider-thumb-color);
|
|
18103
18363
|
border-radius: var(--wui-border-radius-rounded);
|
|
18104
18364
|
cursor: grab;
|
|
@@ -18149,12 +18409,12 @@ var Slider = ({
|
|
|
18149
18409
|
onChange(newValue);
|
|
18150
18410
|
}
|
|
18151
18411
|
};
|
|
18152
|
-
return /* @__PURE__ */
|
|
18412
|
+
return /* @__PURE__ */ jsx336(
|
|
18153
18413
|
SliderContainer,
|
|
18154
18414
|
{
|
|
18155
18415
|
...otherProps,
|
|
18156
18416
|
"data-testid": dataTestId,
|
|
18157
|
-
children: /* @__PURE__ */
|
|
18417
|
+
children: /* @__PURE__ */ jsxs66(
|
|
18158
18418
|
StyledSliderRoot,
|
|
18159
18419
|
{
|
|
18160
18420
|
"aria-label": ariaLabel,
|
|
@@ -18167,8 +18427,8 @@ var Slider = ({
|
|
|
18167
18427
|
step,
|
|
18168
18428
|
...value ? { value } : {},
|
|
18169
18429
|
children: [
|
|
18170
|
-
/* @__PURE__ */
|
|
18171
|
-
values.map((_, index) => /* @__PURE__ */
|
|
18430
|
+
/* @__PURE__ */ jsx336(StyledSliderTrack, { "data-testid": `${dataTestId}-track`, children: /* @__PURE__ */ jsx336(StyledSliderRange, { "data-testid": `${dataTestId}-range` }) }),
|
|
18431
|
+
values.map((_, index) => /* @__PURE__ */ jsx336(
|
|
18172
18432
|
StyledSliderThumb,
|
|
18173
18433
|
{
|
|
18174
18434
|
"data-testid": `${dataTestId}-thumb-${index}`
|
|
@@ -18183,10 +18443,83 @@ var Slider = ({
|
|
|
18183
18443
|
};
|
|
18184
18444
|
Slider.displayName = "Slider_UI";
|
|
18185
18445
|
|
|
18446
|
+
// src/components/SplitButton/SplitButton.tsx
|
|
18447
|
+
import { styled as styled100 } from "styled-components";
|
|
18448
|
+
import { isNotNil as isNotNil39 } from "@wistia/type-guards";
|
|
18449
|
+
import { cloneElement as cloneElement9 } from "react";
|
|
18450
|
+
import { jsx as jsx337, jsxs as jsxs67 } from "react/jsx-runtime";
|
|
18451
|
+
var StyledSplitButton = styled100.span`
|
|
18452
|
+
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
18453
|
+
white-space: nowrap;
|
|
18454
|
+
|
|
18455
|
+
&:has(:nth-child(2)) {
|
|
18456
|
+
> [data-wui-button='true']:first-child {
|
|
18457
|
+
border-top-right-radius: 0;
|
|
18458
|
+
border-bottom-right-radius: 0;
|
|
18459
|
+
padding-right: 0;
|
|
18460
|
+
}
|
|
18461
|
+
|
|
18462
|
+
> [data-wui-button='true']:last-child {
|
|
18463
|
+
border-top-left-radius: 0;
|
|
18464
|
+
border-bottom-left-radius: 0;
|
|
18465
|
+
display: inline-flex;
|
|
18466
|
+
}
|
|
18467
|
+
}
|
|
18468
|
+
`;
|
|
18469
|
+
var SplitButton = ({
|
|
18470
|
+
children,
|
|
18471
|
+
menuLabel = "Select an option",
|
|
18472
|
+
menuIcon = /* @__PURE__ */ jsx337(Icon, { type: "caret-down" }),
|
|
18473
|
+
menuItems,
|
|
18474
|
+
disabled = false,
|
|
18475
|
+
colorScheme = "inherit",
|
|
18476
|
+
variant = "solid",
|
|
18477
|
+
secondaryAction,
|
|
18478
|
+
size = "md",
|
|
18479
|
+
unstyled = false,
|
|
18480
|
+
menuProps = {},
|
|
18481
|
+
...props
|
|
18482
|
+
}) => {
|
|
18483
|
+
return /* @__PURE__ */ jsxs67(StyledSplitButton, { $colorScheme: colorScheme, children: [
|
|
18484
|
+
/* @__PURE__ */ jsx337(
|
|
18485
|
+
Button,
|
|
18486
|
+
{
|
|
18487
|
+
disabled,
|
|
18488
|
+
size,
|
|
18489
|
+
unstyled,
|
|
18490
|
+
variant,
|
|
18491
|
+
...props,
|
|
18492
|
+
children
|
|
18493
|
+
}
|
|
18494
|
+
),
|
|
18495
|
+
isNotNil39(menuItems) && /* @__PURE__ */ jsx337(
|
|
18496
|
+
Menu,
|
|
18497
|
+
{
|
|
18498
|
+
...menuProps,
|
|
18499
|
+
disabled,
|
|
18500
|
+
trigger: /* @__PURE__ */ jsx337(
|
|
18501
|
+
IconButton,
|
|
18502
|
+
{
|
|
18503
|
+
disabled,
|
|
18504
|
+
label: menuLabel,
|
|
18505
|
+
size,
|
|
18506
|
+
unstyled,
|
|
18507
|
+
variant,
|
|
18508
|
+
children: menuIcon
|
|
18509
|
+
}
|
|
18510
|
+
),
|
|
18511
|
+
children: menuItems
|
|
18512
|
+
}
|
|
18513
|
+
),
|
|
18514
|
+
isNotNil39(secondaryAction) && cloneElement9(secondaryAction, { disabled, size, unstyled, variant, colorScheme })
|
|
18515
|
+
] });
|
|
18516
|
+
};
|
|
18517
|
+
SplitButton.displayName = "SplitButton_UI";
|
|
18518
|
+
|
|
18186
18519
|
// src/components/Table/Table.tsx
|
|
18187
|
-
import { styled as
|
|
18188
|
-
import { jsx as
|
|
18189
|
-
var StyledTable =
|
|
18520
|
+
import { styled as styled101, css as css49 } from "styled-components";
|
|
18521
|
+
import { jsx as jsx338 } from "react/jsx-runtime";
|
|
18522
|
+
var StyledTable = styled101.table`
|
|
18190
18523
|
width: 100%;
|
|
18191
18524
|
border-collapse: collapse;
|
|
18192
18525
|
|
|
@@ -18215,7 +18548,7 @@ var Table = ({
|
|
|
18215
18548
|
visuallyHiddenHeader = false,
|
|
18216
18549
|
...props
|
|
18217
18550
|
}) => {
|
|
18218
|
-
return /* @__PURE__ */
|
|
18551
|
+
return /* @__PURE__ */ jsx338(
|
|
18219
18552
|
StyledTable,
|
|
18220
18553
|
{
|
|
18221
18554
|
$divided: divided,
|
|
@@ -18228,37 +18561,37 @@ var Table = ({
|
|
|
18228
18561
|
};
|
|
18229
18562
|
|
|
18230
18563
|
// src/components/Table/TableBody.tsx
|
|
18231
|
-
import { styled as
|
|
18564
|
+
import { styled as styled102 } from "styled-components";
|
|
18232
18565
|
|
|
18233
18566
|
// src/components/Table/TableSectionContext.ts
|
|
18234
18567
|
import { createContext as createContext11 } from "react";
|
|
18235
18568
|
var TableSectionContext = createContext11(null);
|
|
18236
18569
|
|
|
18237
18570
|
// src/components/Table/TableBody.tsx
|
|
18238
|
-
import { jsx as
|
|
18239
|
-
var StyledTableBody =
|
|
18571
|
+
import { jsx as jsx339 } from "react/jsx-runtime";
|
|
18572
|
+
var StyledTableBody = styled102.tbody`
|
|
18240
18573
|
width: 100%;
|
|
18241
18574
|
`;
|
|
18242
18575
|
var TableBody = ({ children, ...props }) => {
|
|
18243
|
-
return /* @__PURE__ */
|
|
18576
|
+
return /* @__PURE__ */ jsx339(TableSectionContext.Provider, { value: "body", children: /* @__PURE__ */ jsx339(StyledTableBody, { ...props, children }) });
|
|
18244
18577
|
};
|
|
18245
18578
|
|
|
18246
18579
|
// src/components/Table/TableCell.tsx
|
|
18247
18580
|
import { useContext as useContext17 } from "react";
|
|
18248
|
-
import { styled as
|
|
18249
|
-
import { jsx as
|
|
18581
|
+
import { styled as styled103, css as css50 } from "styled-components";
|
|
18582
|
+
import { jsx as jsx340 } from "react/jsx-runtime";
|
|
18250
18583
|
var sharedStyles = css50`
|
|
18251
18584
|
color: var(--wui-color-text);
|
|
18252
18585
|
padding: var(--wui-space-02);
|
|
18253
18586
|
text-align: left;
|
|
18254
18587
|
`;
|
|
18255
|
-
var StyledTh =
|
|
18588
|
+
var StyledTh = styled103.th`
|
|
18256
18589
|
${sharedStyles}
|
|
18257
18590
|
font-size: var(--wui-typography-body-4-size);
|
|
18258
18591
|
font-weight: var(--wui-typography-weight-label-bold);
|
|
18259
18592
|
line-height: var(--wui-typography-body-4-line-height);
|
|
18260
18593
|
`;
|
|
18261
|
-
var StyledTd =
|
|
18594
|
+
var StyledTd = styled103.td`
|
|
18262
18595
|
${sharedStyles}
|
|
18263
18596
|
font-size: var(--wui-typography-body-2-size);
|
|
18264
18597
|
font-weight: var(--wui-typography-body-2-weight);
|
|
@@ -18267,45 +18600,45 @@ var StyledTd = styled100.td`
|
|
|
18267
18600
|
var TableCell = ({ children, ...props }) => {
|
|
18268
18601
|
const section = useContext17(TableSectionContext);
|
|
18269
18602
|
if (section === "head") {
|
|
18270
|
-
return /* @__PURE__ */
|
|
18603
|
+
return /* @__PURE__ */ jsx340(StyledTh, { ...props, children });
|
|
18271
18604
|
}
|
|
18272
|
-
return /* @__PURE__ */
|
|
18605
|
+
return /* @__PURE__ */ jsx340(StyledTd, { ...props, children });
|
|
18273
18606
|
};
|
|
18274
18607
|
|
|
18275
18608
|
// src/components/Table/TableFoot.tsx
|
|
18276
|
-
import { styled as
|
|
18277
|
-
import { jsx as
|
|
18278
|
-
var StyledTableFoot =
|
|
18609
|
+
import { styled as styled104 } from "styled-components";
|
|
18610
|
+
import { jsx as jsx341 } from "react/jsx-runtime";
|
|
18611
|
+
var StyledTableFoot = styled104.tfoot`
|
|
18279
18612
|
width: 100%;
|
|
18280
18613
|
`;
|
|
18281
18614
|
var TableFoot = ({ children, ...props }) => {
|
|
18282
|
-
return /* @__PURE__ */
|
|
18615
|
+
return /* @__PURE__ */ jsx341(TableSectionContext.Provider, { value: "footer", children: /* @__PURE__ */ jsx341(StyledTableFoot, { ...props, children }) });
|
|
18283
18616
|
};
|
|
18284
18617
|
|
|
18285
18618
|
// src/components/Table/TableHead.tsx
|
|
18286
|
-
import { styled as
|
|
18287
|
-
import { jsx as
|
|
18288
|
-
var StyledThead =
|
|
18619
|
+
import { styled as styled105 } from "styled-components";
|
|
18620
|
+
import { jsx as jsx342 } from "react/jsx-runtime";
|
|
18621
|
+
var StyledThead = styled105.thead`
|
|
18289
18622
|
width: 100%;
|
|
18290
18623
|
`;
|
|
18291
18624
|
var TableHead = ({ children, ...props }) => {
|
|
18292
|
-
return /* @__PURE__ */
|
|
18625
|
+
return /* @__PURE__ */ jsx342(TableSectionContext.Provider, { value: "head", children: /* @__PURE__ */ jsx342(StyledThead, { ...props, children }) });
|
|
18293
18626
|
};
|
|
18294
18627
|
|
|
18295
18628
|
// src/components/Table/TableRow.tsx
|
|
18296
|
-
import { styled as
|
|
18297
|
-
import { jsx as
|
|
18298
|
-
var StyledTableRow =
|
|
18629
|
+
import { styled as styled106 } from "styled-components";
|
|
18630
|
+
import { jsx as jsx343 } from "react/jsx-runtime";
|
|
18631
|
+
var StyledTableRow = styled106.tr`
|
|
18299
18632
|
width: 100%;
|
|
18300
18633
|
`;
|
|
18301
18634
|
var TableRow = ({ children, ...props }) => {
|
|
18302
|
-
return /* @__PURE__ */
|
|
18635
|
+
return /* @__PURE__ */ jsx343(StyledTableRow, { ...props, children });
|
|
18303
18636
|
};
|
|
18304
18637
|
|
|
18305
18638
|
// src/components/Tabs/Tabs.tsx
|
|
18306
18639
|
import { Root as RadixTabsRoot } from "@radix-ui/react-tabs";
|
|
18307
18640
|
import { useCallback as useCallback19, useState as useState26 } from "react";
|
|
18308
|
-
import { isNotNil as
|
|
18641
|
+
import { isNotNil as isNotNil40 } from "@wistia/type-guards";
|
|
18309
18642
|
|
|
18310
18643
|
// src/components/Tabs/useTabsValue.tsx
|
|
18311
18644
|
import { createContext as createContext12, useContext as useContext18 } from "react";
|
|
@@ -18320,7 +18653,7 @@ var useTabsValue = () => {
|
|
|
18320
18653
|
};
|
|
18321
18654
|
|
|
18322
18655
|
// src/components/Tabs/Tabs.tsx
|
|
18323
|
-
import { jsx as
|
|
18656
|
+
import { jsx as jsx344 } from "react/jsx-runtime";
|
|
18324
18657
|
var Tabs = ({
|
|
18325
18658
|
children,
|
|
18326
18659
|
value: valueProp,
|
|
@@ -18342,48 +18675,48 @@ var Tabs = ({
|
|
|
18342
18675
|
...props,
|
|
18343
18676
|
onValueChange
|
|
18344
18677
|
};
|
|
18345
|
-
if (
|
|
18678
|
+
if (isNotNil40(value)) {
|
|
18346
18679
|
rootProps.value = value;
|
|
18347
18680
|
}
|
|
18348
|
-
if (
|
|
18681
|
+
if (isNotNil40(defaultValue)) {
|
|
18349
18682
|
rootProps.defaultValue = defaultValue;
|
|
18350
18683
|
}
|
|
18351
|
-
return /* @__PURE__ */
|
|
18684
|
+
return /* @__PURE__ */ jsx344(RadixTabsRoot, { ...rootProps, children: /* @__PURE__ */ jsx344(TabsValueProvider, { value: value ?? defaultValue, children: /* @__PURE__ */ jsx344(SelectedItemStyleProvider, { children }) }) });
|
|
18352
18685
|
};
|
|
18353
18686
|
Tabs.displayName = "Tabs_UI";
|
|
18354
18687
|
|
|
18355
18688
|
// src/components/Tabs/TabsContent.tsx
|
|
18356
18689
|
import { Content as RadixTabsContent } from "@radix-ui/react-tabs";
|
|
18357
|
-
import { jsx as
|
|
18690
|
+
import { jsx as jsx345 } from "react/jsx-runtime";
|
|
18358
18691
|
var TabsContent = ({ children, value }) => {
|
|
18359
|
-
return /* @__PURE__ */
|
|
18692
|
+
return /* @__PURE__ */ jsx345(RadixTabsContent, { value, children });
|
|
18360
18693
|
};
|
|
18361
18694
|
TabsContent.displayName = "TabsContent_UI";
|
|
18362
18695
|
|
|
18363
18696
|
// src/components/Tabs/TabsList.tsx
|
|
18364
18697
|
import { List as RadixTabList } from "@radix-ui/react-tabs";
|
|
18365
|
-
import { styled as
|
|
18698
|
+
import { styled as styled108 } from "styled-components";
|
|
18366
18699
|
|
|
18367
18700
|
// src/components/Tabs/SelectedTabIndicator.tsx
|
|
18368
18701
|
import { isUndefined as isUndefined6 } from "@wistia/type-guards";
|
|
18369
18702
|
|
|
18370
18703
|
// src/components/Tabs/TabsSelectedItemIndicatorDiv.tsx
|
|
18371
|
-
import { styled as
|
|
18372
|
-
var TabsSelectedItemIndicatorDiv =
|
|
18704
|
+
import { styled as styled107 } from "styled-components";
|
|
18705
|
+
var TabsSelectedItemIndicatorDiv = styled107(SelectedItemIndicatorDiv)`
|
|
18373
18706
|
:has(button[role='tab']:focus-visible) > & {
|
|
18374
18707
|
outline: 2px solid var(--wui-color-focus-ring);
|
|
18375
18708
|
}
|
|
18376
18709
|
`;
|
|
18377
18710
|
|
|
18378
18711
|
// src/components/Tabs/SelectedTabIndicator.tsx
|
|
18379
|
-
import { jsx as
|
|
18712
|
+
import { jsx as jsx346 } from "react/jsx-runtime";
|
|
18380
18713
|
var SelectedTabIndicator = () => {
|
|
18381
18714
|
const { selectedItemIndicatorStyle } = useSelectedItemStyle();
|
|
18382
18715
|
const selectedValue = useTabsValue();
|
|
18383
18716
|
if (selectedValue == null || isUndefined6(selectedItemIndicatorStyle)) {
|
|
18384
18717
|
return null;
|
|
18385
18718
|
}
|
|
18386
|
-
return /* @__PURE__ */
|
|
18719
|
+
return /* @__PURE__ */ jsx346(
|
|
18387
18720
|
TabsSelectedItemIndicatorDiv,
|
|
18388
18721
|
{
|
|
18389
18722
|
"data-wui-selected-item-indicator": true,
|
|
@@ -18393,19 +18726,19 @@ var SelectedTabIndicator = () => {
|
|
|
18393
18726
|
};
|
|
18394
18727
|
|
|
18395
18728
|
// src/components/Tabs/TabsList.tsx
|
|
18396
|
-
import { jsx as
|
|
18397
|
-
var StyledRadixTabsList =
|
|
18729
|
+
import { jsx as jsx347, jsxs as jsxs68 } from "react/jsx-runtime";
|
|
18730
|
+
var StyledRadixTabsList = styled108(RadixTabList)`
|
|
18398
18731
|
${segmentedControlStyles}
|
|
18399
18732
|
`;
|
|
18400
18733
|
var TabsList = ({ children, fullWidth = true, ...props }) => {
|
|
18401
|
-
return /* @__PURE__ */
|
|
18734
|
+
return /* @__PURE__ */ jsxs68(
|
|
18402
18735
|
StyledRadixTabsList,
|
|
18403
18736
|
{
|
|
18404
18737
|
$fullWidth: fullWidth,
|
|
18405
18738
|
"aria-label": props["aria-label"],
|
|
18406
18739
|
children: [
|
|
18407
18740
|
children,
|
|
18408
|
-
/* @__PURE__ */
|
|
18741
|
+
/* @__PURE__ */ jsx347(SelectedTabIndicator, {})
|
|
18409
18742
|
]
|
|
18410
18743
|
}
|
|
18411
18744
|
);
|
|
@@ -18414,12 +18747,12 @@ TabsList.displayName = "TabsList_UI";
|
|
|
18414
18747
|
|
|
18415
18748
|
// src/components/Tabs/TabsTrigger.tsx
|
|
18416
18749
|
import { forwardRef as forwardRef36, useEffect as useEffect23, useRef as useRef24 } from "react";
|
|
18417
|
-
import { isNotNil as
|
|
18750
|
+
import { isNotNil as isNotNil41 } from "@wistia/type-guards";
|
|
18418
18751
|
|
|
18419
18752
|
// src/components/Tabs/StyledRadixTabsTrigger.tsx
|
|
18420
|
-
import { styled as
|
|
18753
|
+
import { styled as styled109 } from "styled-components";
|
|
18421
18754
|
import { Trigger as RadixTabsTrigger } from "@radix-ui/react-tabs";
|
|
18422
|
-
var StyledRadixTabsTrigger =
|
|
18755
|
+
var StyledRadixTabsTrigger = styled109(RadixTabsTrigger)`
|
|
18423
18756
|
${segmentedControlItemStyles}
|
|
18424
18757
|
|
|
18425
18758
|
&:focus-visible {
|
|
@@ -18428,7 +18761,7 @@ var StyledRadixTabsTrigger = styled106(RadixTabsTrigger)`
|
|
|
18428
18761
|
`;
|
|
18429
18762
|
|
|
18430
18763
|
// src/components/Tabs/TabsTrigger.tsx
|
|
18431
|
-
import { jsxs as
|
|
18764
|
+
import { jsxs as jsxs69 } from "react/jsx-runtime";
|
|
18432
18765
|
var TabsTrigger = forwardRef36(
|
|
18433
18766
|
({ disabled = false, icon, label, "aria-label": ariaLabel, value, ...otherProps }, forwardedRef) => {
|
|
18434
18767
|
const selectedValue = useTabsValue();
|
|
@@ -18460,13 +18793,13 @@ var TabsTrigger = forwardRef36(
|
|
|
18460
18793
|
resizeObserver.disconnect();
|
|
18461
18794
|
};
|
|
18462
18795
|
}, [selectedValue, setSelectedItemMeasurements, value]);
|
|
18463
|
-
return /* @__PURE__ */
|
|
18796
|
+
return /* @__PURE__ */ jsxs69(
|
|
18464
18797
|
StyledRadixTabsTrigger,
|
|
18465
18798
|
{
|
|
18466
18799
|
...otherProps,
|
|
18467
18800
|
ref: combinedRef,
|
|
18468
|
-
$hasLabel:
|
|
18469
|
-
"aria-label":
|
|
18801
|
+
$hasLabel: isNotNil41(label),
|
|
18802
|
+
"aria-label": isNotNil41(label) ? void 0 : ariaLabel,
|
|
18470
18803
|
disabled,
|
|
18471
18804
|
value,
|
|
18472
18805
|
children: [
|
|
@@ -18480,10 +18813,10 @@ var TabsTrigger = forwardRef36(
|
|
|
18480
18813
|
TabsTrigger.displayName = "TabsTrigger_UI";
|
|
18481
18814
|
|
|
18482
18815
|
// src/components/Thumbnail/ThumbnailBadge.tsx
|
|
18483
|
-
import { styled as
|
|
18484
|
-
import { isNotNil as
|
|
18485
|
-
import { jsx as
|
|
18486
|
-
var StyledThumbnailBadge =
|
|
18816
|
+
import { styled as styled110 } from "styled-components";
|
|
18817
|
+
import { isNotNil as isNotNil42 } from "@wistia/type-guards";
|
|
18818
|
+
import { jsx as jsx348, jsxs as jsxs70 } from "react/jsx-runtime";
|
|
18819
|
+
var StyledThumbnailBadge = styled110.div`
|
|
18487
18820
|
align-items: center;
|
|
18488
18821
|
background-color: rgb(0 0 0 / 50%);
|
|
18489
18822
|
border-radius: var(--wui-border-radius-01);
|
|
@@ -18509,19 +18842,19 @@ var StyledThumbnailBadge = styled107.div`
|
|
|
18509
18842
|
}
|
|
18510
18843
|
`;
|
|
18511
18844
|
var ThumbnailBadge = ({ icon, label, ...props }) => {
|
|
18512
|
-
return /* @__PURE__ */
|
|
18513
|
-
|
|
18514
|
-
/* @__PURE__ */
|
|
18845
|
+
return /* @__PURE__ */ jsxs70(StyledThumbnailBadge, { ...props, children: [
|
|
18846
|
+
isNotNil42(icon) && icon,
|
|
18847
|
+
/* @__PURE__ */ jsx348("span", { children: label })
|
|
18515
18848
|
] });
|
|
18516
18849
|
};
|
|
18517
18850
|
ThumbnailBadge.displayName = "ThumbnailBadge_UI";
|
|
18518
18851
|
|
|
18519
18852
|
// src/components/Thumbnail/Thumbnail.tsx
|
|
18520
18853
|
import { forwardRef as forwardRef37, useState as useState27, useRef as useRef25, useCallback as useCallback20, useMemo as useMemo17 } from "react";
|
|
18521
|
-
import { styled as
|
|
18854
|
+
import { styled as styled112 } from "styled-components";
|
|
18522
18855
|
import {
|
|
18523
18856
|
isNil as isNil19,
|
|
18524
|
-
isNotNil as
|
|
18857
|
+
isNotNil as isNotNil45,
|
|
18525
18858
|
isUndefined as isUndefined7,
|
|
18526
18859
|
isEmptyString as isEmptyString2,
|
|
18527
18860
|
isString as isString4,
|
|
@@ -18529,7 +18862,7 @@ import {
|
|
|
18529
18862
|
} from "@wistia/type-guards";
|
|
18530
18863
|
|
|
18531
18864
|
// src/private/helpers/getBackgroundGradient/getBackgroundGradient.ts
|
|
18532
|
-
import { isNotNil as
|
|
18865
|
+
import { isNotNil as isNotNil43 } from "@wistia/type-guards";
|
|
18533
18866
|
import { css as css51 } from "styled-components";
|
|
18534
18867
|
var gradients = {
|
|
18535
18868
|
defaultDarkOne: css51`
|
|
@@ -18657,14 +18990,14 @@ var gradients = {
|
|
|
18657
18990
|
};
|
|
18658
18991
|
var gradientMap = Object.keys(gradients);
|
|
18659
18992
|
var getBackgroundGradient = (gradientName = void 0) => {
|
|
18660
|
-
return
|
|
18993
|
+
return isNotNil43(gradientName) ? gradients[gradientName] : gradients.defaultDarkOne;
|
|
18661
18994
|
};
|
|
18662
18995
|
|
|
18663
18996
|
// src/components/Thumbnail/ThumbnailStoryboardViewer.tsx
|
|
18664
|
-
import { styled as
|
|
18665
|
-
import { isNotNil as
|
|
18666
|
-
import { jsx as
|
|
18667
|
-
var ScrubLine =
|
|
18997
|
+
import { styled as styled111 } from "styled-components";
|
|
18998
|
+
import { isNotNil as isNotNil44 } from "@wistia/type-guards";
|
|
18999
|
+
import { jsx as jsx349, jsxs as jsxs71 } from "react/jsx-runtime";
|
|
19000
|
+
var ScrubLine = styled111.div`
|
|
18668
19001
|
position: absolute;
|
|
18669
19002
|
top: 0;
|
|
18670
19003
|
height: 100%;
|
|
@@ -18756,8 +19089,8 @@ var ThumbnailStoryboardViewer = ({
|
|
|
18756
19089
|
);
|
|
18757
19090
|
const backgroundSize = `${scaledStoryboardWidth}px ${scaledStoryboardHeight}px`;
|
|
18758
19091
|
const backgroundImage = `url(${storyboardUrl})`;
|
|
18759
|
-
const showScrubLine =
|
|
18760
|
-
const scrubLinePosition =
|
|
19092
|
+
const showScrubLine = isNotNil44(cursorPosition);
|
|
19093
|
+
const scrubLinePosition = isNotNil44(cursorPosition) ? `${cursorPosition - 1}px` : "0";
|
|
18761
19094
|
const viewerStyles = {
|
|
18762
19095
|
position: "relative",
|
|
18763
19096
|
overflow: "hidden",
|
|
@@ -18775,14 +19108,14 @@ var ThumbnailStoryboardViewer = ({
|
|
|
18775
19108
|
backgroundPosition,
|
|
18776
19109
|
backgroundSize
|
|
18777
19110
|
};
|
|
18778
|
-
return /* @__PURE__ */
|
|
19111
|
+
return /* @__PURE__ */ jsxs71(
|
|
18779
19112
|
"div",
|
|
18780
19113
|
{
|
|
18781
19114
|
...props,
|
|
18782
19115
|
style: viewerStyles,
|
|
18783
19116
|
children: [
|
|
18784
|
-
/* @__PURE__ */
|
|
18785
|
-
showScrubLine ? /* @__PURE__ */
|
|
19117
|
+
/* @__PURE__ */ jsx349("div", { style: storyboardStyles }),
|
|
19118
|
+
showScrubLine ? /* @__PURE__ */ jsx349(
|
|
18786
19119
|
ScrubLine,
|
|
18787
19120
|
{
|
|
18788
19121
|
style: {
|
|
@@ -18796,7 +19129,7 @@ var ThumbnailStoryboardViewer = ({
|
|
|
18796
19129
|
};
|
|
18797
19130
|
|
|
18798
19131
|
// src/components/Thumbnail/Thumbnail.tsx
|
|
18799
|
-
import { jsx as
|
|
19132
|
+
import { jsx as jsx350, jsxs as jsxs72 } from "react/jsx-runtime";
|
|
18800
19133
|
var WIDE_ASPECT_RATIO = 16 / 9;
|
|
18801
19134
|
var SQUARE_ASPECT_RATIO = 1;
|
|
18802
19135
|
var getAspectRatioValue = (aspectRatio) => {
|
|
@@ -18805,19 +19138,19 @@ var getAspectRatioValue = (aspectRatio) => {
|
|
|
18805
19138
|
}
|
|
18806
19139
|
return WIDE_ASPECT_RATIO;
|
|
18807
19140
|
};
|
|
18808
|
-
var WideThumbnailImage =
|
|
19141
|
+
var WideThumbnailImage = styled112.img`
|
|
18809
19142
|
height: 100%;
|
|
18810
19143
|
object-fit: cover;
|
|
18811
19144
|
width: 100%;
|
|
18812
19145
|
`;
|
|
18813
|
-
var SquareThumbnailImage =
|
|
19146
|
+
var SquareThumbnailImage = styled112.img`
|
|
18814
19147
|
backdrop-filter: blur(8px);
|
|
18815
19148
|
object-fit: contain;
|
|
18816
19149
|
width: 100%;
|
|
18817
19150
|
`;
|
|
18818
19151
|
var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
|
|
18819
19152
|
if (thumbnailImageType === "wide") {
|
|
18820
|
-
return /* @__PURE__ */
|
|
19153
|
+
return /* @__PURE__ */ jsx350(
|
|
18821
19154
|
WideThumbnailImage,
|
|
18822
19155
|
{
|
|
18823
19156
|
alt: "",
|
|
@@ -18826,7 +19159,7 @@ var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
|
|
|
18826
19159
|
}
|
|
18827
19160
|
);
|
|
18828
19161
|
}
|
|
18829
|
-
return /* @__PURE__ */
|
|
19162
|
+
return /* @__PURE__ */ jsx350(
|
|
18830
19163
|
SquareThumbnailImage,
|
|
18831
19164
|
{
|
|
18832
19165
|
alt: "",
|
|
@@ -18835,7 +19168,7 @@ var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
|
|
|
18835
19168
|
}
|
|
18836
19169
|
);
|
|
18837
19170
|
};
|
|
18838
|
-
var StyledThumbnailContainer =
|
|
19171
|
+
var StyledThumbnailContainer = styled112.div`
|
|
18839
19172
|
container-type: size;
|
|
18840
19173
|
aspect-ratio: ${({ $aspectRatio }) => getAspectRatioValue($aspectRatio)};
|
|
18841
19174
|
width: ${({ $width }) => $width};
|
|
@@ -18843,10 +19176,10 @@ var StyledThumbnailContainer = styled109.div`
|
|
|
18843
19176
|
overflow: hidden;
|
|
18844
19177
|
${({ $isScrubbable }) => $isScrubbable && "cursor: pointer;"}
|
|
18845
19178
|
`;
|
|
18846
|
-
var StyledThumbnail =
|
|
19179
|
+
var StyledThumbnail = styled112.div`
|
|
18847
19180
|
--wui-thumbnail-badge-offset: var(--wui-space-01);
|
|
18848
19181
|
|
|
18849
|
-
background-image: ${({ $backgroundUrl }) =>
|
|
19182
|
+
background-image: ${({ $backgroundUrl }) => isNotNil45($backgroundUrl) ? `url('${$backgroundUrl}')` : void 0};
|
|
18850
19183
|
${({ $backgroundUrl, $gradientBackground }) => (
|
|
18851
19184
|
// if we don't have $backgroundUrl show a gradient
|
|
18852
19185
|
isNil19($backgroundUrl) ? getBackgroundGradient($gradientBackground) : void 0
|
|
@@ -18878,7 +19211,7 @@ var StoryboardRenderer = ({
|
|
|
18878
19211
|
const { url, width: sbWidth, height: sbHeight, frameHeight, frameWidth, frameCount } = storyboard;
|
|
18879
19212
|
const targetWidth = isString4(width) ? parseInt(width, 10) : Number(width);
|
|
18880
19213
|
const effectiveCursorPosition = isStoryboardReady ? cursorPosition : null;
|
|
18881
|
-
return /* @__PURE__ */
|
|
19214
|
+
return /* @__PURE__ */ jsx350(
|
|
18882
19215
|
ThumbnailStoryboardViewer,
|
|
18883
19216
|
{
|
|
18884
19217
|
cursorPosition: effectiveCursorPosition,
|
|
@@ -18904,7 +19237,7 @@ var getRelativeMousePosition = (elem, mouseEvent) => {
|
|
|
18904
19237
|
};
|
|
18905
19238
|
};
|
|
18906
19239
|
var hasValidThumbnailUrl = (thumbnailUrl) => {
|
|
18907
|
-
return
|
|
19240
|
+
return isNotNil45(thumbnailUrl) && isNonEmptyString10(thumbnailUrl);
|
|
18908
19241
|
};
|
|
18909
19242
|
var Thumbnail = forwardRef37(
|
|
18910
19243
|
({
|
|
@@ -18927,7 +19260,7 @@ var Thumbnail = forwardRef37(
|
|
|
18927
19260
|
() => thumbnailImageType === "square" && hasValidThumbnailUrl(thumbnailUrl) ? thumbnailUrl : void 0,
|
|
18928
19261
|
[thumbnailImageType, thumbnailUrl]
|
|
18929
19262
|
);
|
|
18930
|
-
const isScrubbable =
|
|
19263
|
+
const isScrubbable = isNotNil45(storyboard);
|
|
18931
19264
|
const trackStoryboardLoadStatus = useCallback20(() => {
|
|
18932
19265
|
if (storyboardElementRef.current || !storyboard) {
|
|
18933
19266
|
return storyboardElementRef.current;
|
|
@@ -18968,7 +19301,7 @@ var Thumbnail = forwardRef37(
|
|
|
18968
19301
|
}, [isScrubbable, isMouseOver, isStoryboardReady, storyboard, height]);
|
|
18969
19302
|
let thumbnailContent = null;
|
|
18970
19303
|
if (storyboard && shouldRenderStoryboard) {
|
|
18971
|
-
thumbnailContent = /* @__PURE__ */
|
|
19304
|
+
thumbnailContent = /* @__PURE__ */ jsx350(
|
|
18972
19305
|
StoryboardRenderer,
|
|
18973
19306
|
{
|
|
18974
19307
|
aspectRatio,
|
|
@@ -18980,7 +19313,7 @@ var Thumbnail = forwardRef37(
|
|
|
18980
19313
|
}
|
|
18981
19314
|
);
|
|
18982
19315
|
} else if (hasValidThumbnailUrl(thumbnailUrl)) {
|
|
18983
|
-
thumbnailContent = /* @__PURE__ */
|
|
19316
|
+
thumbnailContent = /* @__PURE__ */ jsx350(
|
|
18984
19317
|
ThumbnailImage,
|
|
18985
19318
|
{
|
|
18986
19319
|
thumbnailImageType,
|
|
@@ -18990,7 +19323,7 @@ var Thumbnail = forwardRef37(
|
|
|
18990
19323
|
} else {
|
|
18991
19324
|
thumbnailContent = null;
|
|
18992
19325
|
}
|
|
18993
|
-
return /* @__PURE__ */
|
|
19326
|
+
return /* @__PURE__ */ jsx350(
|
|
18994
19327
|
StyledThumbnailContainer,
|
|
18995
19328
|
{
|
|
18996
19329
|
ref,
|
|
@@ -19003,14 +19336,14 @@ var Thumbnail = forwardRef37(
|
|
|
19003
19336
|
onMouseOut: handleMouseOut,
|
|
19004
19337
|
role: "presentation",
|
|
19005
19338
|
...props,
|
|
19006
|
-
children: /* @__PURE__ */
|
|
19339
|
+
children: /* @__PURE__ */ jsxs72(
|
|
19007
19340
|
StyledThumbnail,
|
|
19008
19341
|
{
|
|
19009
19342
|
$backgroundUrl: backgroundUrl,
|
|
19010
19343
|
$gradientBackground: gradientBackground,
|
|
19011
19344
|
"data-testid": "thumbnail-inner",
|
|
19012
19345
|
children: [
|
|
19013
|
-
|
|
19346
|
+
isNotNil45(children) ? children : null,
|
|
19014
19347
|
thumbnailContent
|
|
19015
19348
|
]
|
|
19016
19349
|
}
|
|
@@ -19022,17 +19355,17 @@ var Thumbnail = forwardRef37(
|
|
|
19022
19355
|
Thumbnail.displayName = "Thumbnail_UI";
|
|
19023
19356
|
|
|
19024
19357
|
// src/components/ThumbnailCollage/ThumbnailCollage.tsx
|
|
19025
|
-
import { cloneElement as
|
|
19026
|
-
import { styled as
|
|
19358
|
+
import { cloneElement as cloneElement10, Children as Children11 } from "react";
|
|
19359
|
+
import { styled as styled113 } from "styled-components";
|
|
19027
19360
|
import { isNonEmptyArray } from "@wistia/type-guards";
|
|
19028
|
-
import { jsx as
|
|
19029
|
-
var ThumbnailCollageContainer =
|
|
19361
|
+
import { jsx as jsx351 } from "react/jsx-runtime";
|
|
19362
|
+
var ThumbnailCollageContainer = styled113.div`
|
|
19030
19363
|
container-type: size;
|
|
19031
19364
|
width: 100%;
|
|
19032
19365
|
aspect-ratio: 16 / 9;
|
|
19033
19366
|
display: flex;
|
|
19034
19367
|
`;
|
|
19035
|
-
var StyledThumbnailCollage =
|
|
19368
|
+
var StyledThumbnailCollage = styled113.div`
|
|
19036
19369
|
display: grid;
|
|
19037
19370
|
gap: var(--wui-space-01);
|
|
19038
19371
|
width: 100%;
|
|
@@ -19084,13 +19417,13 @@ var ThumbnailCollage = ({
|
|
|
19084
19417
|
const thumbnailArray = Children11.toArray(children);
|
|
19085
19418
|
const truncatedThumbnails = thumbnailArray.slice(0, 3);
|
|
19086
19419
|
const thumbnails = isNonEmptyArray(thumbnailArray) ? truncatedThumbnails.map((child) => {
|
|
19087
|
-
return
|
|
19420
|
+
return cloneElement10(child, {
|
|
19088
19421
|
...child.props,
|
|
19089
19422
|
children: void 0
|
|
19090
19423
|
});
|
|
19091
19424
|
}) : [
|
|
19092
19425
|
// ThumbnailCollage will fallback to a Thumbnail with a gradient background if no children are provided
|
|
19093
|
-
/* @__PURE__ */
|
|
19426
|
+
/* @__PURE__ */ jsx351(
|
|
19094
19427
|
Thumbnail,
|
|
19095
19428
|
{
|
|
19096
19429
|
gradientBackground,
|
|
@@ -19099,7 +19432,7 @@ var ThumbnailCollage = ({
|
|
|
19099
19432
|
"fallback"
|
|
19100
19433
|
)
|
|
19101
19434
|
];
|
|
19102
|
-
return /* @__PURE__ */
|
|
19435
|
+
return /* @__PURE__ */ jsx351(ThumbnailCollageContainer, { children: /* @__PURE__ */ jsx351(
|
|
19103
19436
|
StyledThumbnailCollage,
|
|
19104
19437
|
{
|
|
19105
19438
|
$gradientBackground: gradientBackground,
|
|
@@ -19111,26 +19444,26 @@ var ThumbnailCollage = ({
|
|
|
19111
19444
|
};
|
|
19112
19445
|
|
|
19113
19446
|
// src/components/WistiaLogo/WistiaLogo.tsx
|
|
19114
|
-
import { styled as
|
|
19115
|
-
import { isNotNil as
|
|
19116
|
-
import { jsx as
|
|
19447
|
+
import { styled as styled114, css as css52 } from "styled-components";
|
|
19448
|
+
import { isNotNil as isNotNil46 } from "@wistia/type-guards";
|
|
19449
|
+
import { jsx as jsx352, jsxs as jsxs73 } from "react/jsx-runtime";
|
|
19117
19450
|
var renderBrandmark = (brandmarkColor, iconOnly) => {
|
|
19118
19451
|
if (iconOnly) {
|
|
19119
|
-
return /* @__PURE__ */
|
|
19452
|
+
return /* @__PURE__ */ jsx352(
|
|
19120
19453
|
"g",
|
|
19121
19454
|
{
|
|
19122
19455
|
"data-testid": "ui-wistia-logo-brandmark",
|
|
19123
19456
|
fill: brandmarkColor,
|
|
19124
|
-
children: /* @__PURE__ */
|
|
19457
|
+
children: /* @__PURE__ */ jsx352("path", { d: "M16.09 17.1h-5.2c-1.58 0-3.08.68-4.11 1.87L.21 26.53c4.78.25 9.78.25 13.3.25 18.31 0 20.89-11.27 20.89-16.55-1.59 1.93-6.06 6.87-18.32 6.87ZM32.14 0c-.08.92-.59 4.69-11.31 4.69-8.72 0-12.24 0-20.83-.17l6.44 7.4a6.657 6.657 0 0 0 4.96 2.3c2.13.03 5.05.06 5.53.06 11.01 0 17.19-5.05 17.19-9.89 0-2.01-.67-3.44-1.97-4.4Z" })
|
|
19125
19458
|
}
|
|
19126
19459
|
);
|
|
19127
19460
|
}
|
|
19128
|
-
return /* @__PURE__ */
|
|
19461
|
+
return /* @__PURE__ */ jsx352(
|
|
19129
19462
|
"g",
|
|
19130
19463
|
{
|
|
19131
19464
|
"data-testid": "ui-wistia-logo-brandmark",
|
|
19132
19465
|
fill: brandmarkColor,
|
|
19133
|
-
children: /* @__PURE__ */
|
|
19466
|
+
children: /* @__PURE__ */ jsx352("path", { d: "M16.09 21.37h-5.2c-1.58 0-3.08.68-4.11 1.87L.21 30.8c4.78.25 9.78.25 13.3.25 18.31 0 20.89-11.27 20.89-16.55-1.59 1.93-6.06 6.87-18.32 6.87Zm16.05-17.1c-.08.92-.59 4.69-11.31 4.69-8.72 0-12.24 0-20.83-.17l6.44 7.4a6.657 6.657 0 0 0 4.96 2.3c2.13.03 5.05.06 5.53.06 11.01 0 17.19-5.05 17.19-9.89 0-2.01-.67-3.44-1.97-4.4Z" })
|
|
19134
19467
|
}
|
|
19135
19468
|
);
|
|
19136
19469
|
};
|
|
@@ -19138,12 +19471,12 @@ var renderLogotype = (logotypeColor, iconOnly) => {
|
|
|
19138
19471
|
if (iconOnly) {
|
|
19139
19472
|
return null;
|
|
19140
19473
|
}
|
|
19141
|
-
return /* @__PURE__ */
|
|
19474
|
+
return /* @__PURE__ */ jsx352(
|
|
19142
19475
|
"g",
|
|
19143
19476
|
{
|
|
19144
19477
|
"data-testid": "ui-wistia-logo-logotype",
|
|
19145
19478
|
fill: logotypeColor,
|
|
19146
|
-
children: /* @__PURE__ */
|
|
19479
|
+
children: /* @__PURE__ */ jsx352("path", { d: "M70.16 8.66v15.18c0 1.68-.35 3.09-1.05 4.23a6.612 6.612 0 0 1-2.85 2.54c-1.19.55-2.52.82-4.01.82s-2.8-.28-4.01-.85a6.655 6.655 0 0 1-3.11-2.96c-.08.15-.16.29-.24.42a6.552 6.552 0 0 1-2.87 2.54c-1.2.56-2.54.85-4.01.85s-2.8-.27-3.94-.82a6.214 6.214 0 0 1-2.71-2.52c-.67-1.14-1.01-2.56-1.02-4.25l-.22-15.18h7.34V22.3c0 .82.19 1.37.56 1.67.39.28.85.42 1.38.42s1.02-.15 1.45-.45c.43-.3.65-.85.65-1.65V8.65h7.3v13.64c0 .8.22 1.35.65 1.65.43.3.91.45 1.45.45s.99-.14 1.36-.42c.39-.3.58-.85.58-1.67V8.66h7.34Zm2.45 0v22.26h7.34V8.66h-7.34Zm5.67-1.87c.61-.3 1.08-.71 1.42-1.25.36-.55.53-1.19.53-1.94s-.18-1.34-.53-1.89A3.43 3.43 0 0 0 78.28.44c-.59-.3-1.25-.45-1.98-.45s-1.42.15-2.02.45c-.59.3-1.07.72-1.42 1.27-.36.55-.53 1.18-.53 1.89 0 1.1.38 1.97 1.13 2.63.76.65 1.71.98 2.85.98.73 0 1.39-.14 1.98-.42Zm8.86 1.96c-1.42.4-2.6 1.11-3.54 2.14-.93 1.02-1.4 2.4-1.4 4.12 0 1.11.17 2.09.51 2.94.36.85.82 1.62 1.38 2.34.22.28.55.65.98 1.11.37.4.64.72.8.96.18.24.27.47.27.69 0 .5-.4.87-1.2 1.09-.8.21-1.62.31-2.47.31-.1-.01-.22-.02-.33-.02l1.02 6.94c.42.07.92.11 1.51.11 1.9 0 3.6-.28 5.1-.85 1.5-.56 2.68-1.42 3.54-2.56.88-1.14 1.31-2.55 1.31-4.23 0-.68-.07-1.31-.22-1.87-.13-.58-.32-1.09-.56-1.54a6.64 6.64 0 0 0-.8-1.27c-.3-.37-.74-.82-1.34-1.36-.39-.33-.67-.59-.85-.8-.18-.22-.27-.45-.27-.67 0-.46.26-.79.78-.98.53-.19 1.17-.29 1.91-.29.25 0 .51.01.78.04l-.71-6.88a10.4 10.4 0 0 0-1.56-.11c-1.66 0-3.21.21-4.65.62Zm19.54 15.71c-.99 0-1.71-.23-2.14-.69-.42-.47-.62-1.18-.62-2.11v-6.57h4.21V8.66h-4.21V3.38l-7.34 1.85V24.1c0 2.45.47 4.29 1.4 5.52.95 1.22 2.45 1.83 4.49 1.83.95 0 1.86-.07 2.74-.22.88-.13 1.62-.34 2.25-.62l1.38-6.3c-.55.1-1.27.16-2.16.16Zm4.13-15.8v22.26h7.34V8.66h-7.34Zm5.67-1.87c.61-.3 1.08-.71 1.42-1.25.36-.55.53-1.19.53-1.94s-.18-1.34-.53-1.89a3.43 3.43 0 0 0-1.42-1.27c-.59-.3-1.25-.45-1.98-.45s-1.42.15-2.02.45c-.59.3-1.07.72-1.42 1.27-.36.55-.53 1.18-.53 1.89 0 1.1.38 1.97 1.14 2.63.76.65 1.71.98 2.85.98.73 0 1.39-.14 1.98-.42Zm27.51 1.87v22.26h-7.34v-2.28c-.41.43-.85.83-1.34 1.19-1.44 1.07-3.12 1.6-5.05 1.6s-3.61-.52-5.1-1.56c-1.48-1.05-2.63-2.47-3.45-4.25-.82-1.78-1.22-3.73-1.22-5.85s.41-4.07 1.22-5.83c.82-1.78 1.97-3.19 3.45-4.23 1.48-1.05 3.18-1.58 5.1-1.58s3.61.53 5.05 1.6c.48.36.93.75 1.34 1.19V8.66h7.34Zm-7.1 11.11c0-.8-.19-1.53-.56-2.18-.37-.67-.88-1.19-1.54-1.58-.64-.39-1.34-.58-2.09-.58s-1.45.19-2.09.58c-.64.39-1.15.91-1.54 1.58-.37.67-.56 1.39-.56 2.18s.19 1.51.56 2.18c.39.67.9 1.19 1.54 1.58.64.39 1.34.58 2.09.58s1.45-.19 2.09-.58c.65-.39 1.16-.91 1.54-1.56.37-.67.56-1.4.56-2.2Z" })
|
|
19147
19480
|
}
|
|
19148
19481
|
);
|
|
19149
19482
|
};
|
|
@@ -19153,7 +19486,7 @@ var computedViewBox = (iconOnly) => {
|
|
|
19153
19486
|
}
|
|
19154
19487
|
return "0 0 144 31.47";
|
|
19155
19488
|
};
|
|
19156
|
-
var WistiaLogoComponent =
|
|
19489
|
+
var WistiaLogoComponent = styled114.svg`
|
|
19157
19490
|
height: ${({ height }) => `${height}px`};
|
|
19158
19491
|
|
|
19159
19492
|
/* ensure it will always fit on mobile */
|
|
@@ -19211,7 +19544,7 @@ var WistiaLogo = ({
|
|
|
19211
19544
|
};
|
|
19212
19545
|
const brandmarkColor = VARIANT_COLORS[variant].brandmark;
|
|
19213
19546
|
const logotypeColor = VARIANT_COLORS[variant].logotype;
|
|
19214
|
-
const Logo = /* @__PURE__ */
|
|
19547
|
+
const Logo = /* @__PURE__ */ jsxs73(
|
|
19215
19548
|
WistiaLogoComponent,
|
|
19216
19549
|
{
|
|
19217
19550
|
$hoverColor: hoverColor,
|
|
@@ -19224,110 +19557,16 @@ var WistiaLogo = ({
|
|
|
19224
19557
|
xmlns: "http://www.w3.org/2000/svg",
|
|
19225
19558
|
...props,
|
|
19226
19559
|
children: [
|
|
19227
|
-
/* @__PURE__ */
|
|
19228
|
-
|
|
19560
|
+
/* @__PURE__ */ jsx352("title", { children: title }),
|
|
19561
|
+
isNotNil46(description) ? /* @__PURE__ */ jsx352("desc", { children: description }) : null,
|
|
19229
19562
|
renderBrandmark(brandmarkColor, iconOnly),
|
|
19230
19563
|
renderLogotype(logotypeColor, iconOnly)
|
|
19231
19564
|
]
|
|
19232
19565
|
}
|
|
19233
19566
|
);
|
|
19234
|
-
return href !== void 0 ? /* @__PURE__ */
|
|
19567
|
+
return href !== void 0 ? /* @__PURE__ */ jsx352("a", { href, children: Logo }) : Logo;
|
|
19235
19568
|
};
|
|
19236
19569
|
WistiaLogo.displayName = "WistiaLogo_UI";
|
|
19237
|
-
|
|
19238
|
-
// src/components/SplitButton/SplitButton.tsx
|
|
19239
|
-
import { styled as styled112 } from "styled-components";
|
|
19240
|
-
import { isNotNil as isNotNil45 } from "@wistia/type-guards";
|
|
19241
|
-
import { cloneElement as cloneElement10 } from "react";
|
|
19242
|
-
import { jsx as jsx350, jsxs as jsxs72 } from "react/jsx-runtime";
|
|
19243
|
-
var StyledSplitButton = styled112.span`
|
|
19244
|
-
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
19245
|
-
white-space: nowrap;
|
|
19246
|
-
|
|
19247
|
-
&:has(:nth-child(2)) {
|
|
19248
|
-
> [data-wui-button='true']:first-child {
|
|
19249
|
-
border-top-right-radius: 0;
|
|
19250
|
-
border-bottom-right-radius: 0;
|
|
19251
|
-
padding-right: 0;
|
|
19252
|
-
}
|
|
19253
|
-
|
|
19254
|
-
> [data-wui-button='true']:last-child {
|
|
19255
|
-
border-top-left-radius: 0;
|
|
19256
|
-
border-bottom-left-radius: 0;
|
|
19257
|
-
display: inline-flex;
|
|
19258
|
-
}
|
|
19259
|
-
}
|
|
19260
|
-
`;
|
|
19261
|
-
var SplitButton = ({
|
|
19262
|
-
children,
|
|
19263
|
-
menuLabel = "Select an option",
|
|
19264
|
-
menuIcon = /* @__PURE__ */ jsx350(Icon, { type: "caret-down" }),
|
|
19265
|
-
menuItems,
|
|
19266
|
-
disabled = false,
|
|
19267
|
-
colorScheme = "inherit",
|
|
19268
|
-
variant = "solid",
|
|
19269
|
-
secondaryAction,
|
|
19270
|
-
size = "md",
|
|
19271
|
-
unstyled = false,
|
|
19272
|
-
menuProps = {},
|
|
19273
|
-
...props
|
|
19274
|
-
}) => {
|
|
19275
|
-
return /* @__PURE__ */ jsxs72(StyledSplitButton, { $colorScheme: colorScheme, children: [
|
|
19276
|
-
/* @__PURE__ */ jsx350(
|
|
19277
|
-
Button,
|
|
19278
|
-
{
|
|
19279
|
-
disabled,
|
|
19280
|
-
size,
|
|
19281
|
-
unstyled,
|
|
19282
|
-
variant,
|
|
19283
|
-
...props,
|
|
19284
|
-
children
|
|
19285
|
-
}
|
|
19286
|
-
),
|
|
19287
|
-
isNotNil45(menuItems) && /* @__PURE__ */ jsx350(
|
|
19288
|
-
Menu,
|
|
19289
|
-
{
|
|
19290
|
-
...menuProps,
|
|
19291
|
-
disabled,
|
|
19292
|
-
trigger: /* @__PURE__ */ jsx350(
|
|
19293
|
-
IconButton,
|
|
19294
|
-
{
|
|
19295
|
-
disabled,
|
|
19296
|
-
label: menuLabel,
|
|
19297
|
-
size,
|
|
19298
|
-
unstyled,
|
|
19299
|
-
variant,
|
|
19300
|
-
children: menuIcon
|
|
19301
|
-
}
|
|
19302
|
-
),
|
|
19303
|
-
children: menuItems
|
|
19304
|
-
}
|
|
19305
|
-
),
|
|
19306
|
-
isNotNil45(secondaryAction) && cloneElement10(secondaryAction, { disabled, size, unstyled, variant, colorScheme })
|
|
19307
|
-
] });
|
|
19308
|
-
};
|
|
19309
|
-
SplitButton.displayName = "SplitButton_UI";
|
|
19310
|
-
|
|
19311
|
-
// src/components/CustomizableThemeWrapper/CustomizableThemeWrapper.tsx
|
|
19312
|
-
import { styled as styled113 } from "styled-components";
|
|
19313
|
-
import { jsx as jsx351 } from "react/jsx-runtime";
|
|
19314
|
-
var StyledCustomizableThemeWrapper = styled113.div(
|
|
19315
|
-
(props) => props.$overrides
|
|
19316
|
-
);
|
|
19317
|
-
var CustomizableThemeWrapper = ({
|
|
19318
|
-
children,
|
|
19319
|
-
overrides,
|
|
19320
|
-
...props
|
|
19321
|
-
}) => /* @__PURE__ */ jsx351(
|
|
19322
|
-
StyledCustomizableThemeWrapper,
|
|
19323
|
-
{
|
|
19324
|
-
...props,
|
|
19325
|
-
$overrides: overrides,
|
|
19326
|
-
"data-wui-theme": "true",
|
|
19327
|
-
children
|
|
19328
|
-
}
|
|
19329
|
-
);
|
|
19330
|
-
CustomizableThemeWrapper.displayName = "CustomizableThemeWrapper_UI";
|
|
19331
19570
|
export {
|
|
19332
19571
|
ActionButton,
|
|
19333
19572
|
Avatar,
|
|
@@ -19417,6 +19656,7 @@ export {
|
|
|
19417
19656
|
MenuItemLabel,
|
|
19418
19657
|
MenuLabel,
|
|
19419
19658
|
MenuRadioGroup,
|
|
19659
|
+
Meter,
|
|
19420
19660
|
Modal,
|
|
19421
19661
|
ModalCallout,
|
|
19422
19662
|
ModalCallouts,
|