@wistia/ui 0.8.23 → 0.8.24-beta.1e7a5400.7fa7419
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.cjs +453 -346
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +11 -6
- package/dist/index.d.ts +11 -6
- package/dist/index.mjs +399 -292
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
/*
|
|
3
|
-
* @license @wistia/ui v0.8.
|
|
3
|
+
* @license @wistia/ui v0.8.24-beta.1e7a5400.7fa7419
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
|
|
6
6
|
*
|
|
@@ -8593,6 +8593,7 @@ var CollapsibleContent = ({ clamp, children }) => {
|
|
|
8593
8593
|
};
|
|
8594
8594
|
|
|
8595
8595
|
// src/components/DataCards/DataCard.tsx
|
|
8596
|
+
var import_react33 = require("react");
|
|
8596
8597
|
var import_styled_components40 = __toESM(require("styled-components"));
|
|
8597
8598
|
var import_type_guards29 = require("@wistia/type-guards");
|
|
8598
8599
|
|
|
@@ -8782,7 +8783,7 @@ var StyledDataCardTrendContainer = import_styled_components40.default.div`
|
|
|
8782
8783
|
bottom: var(--wui-space-01);
|
|
8783
8784
|
right: var(--wui-space-01);
|
|
8784
8785
|
`;
|
|
8785
|
-
var
|
|
8786
|
+
var DataCardInner = ({
|
|
8786
8787
|
label,
|
|
8787
8788
|
value,
|
|
8788
8789
|
upperRightSlot,
|
|
@@ -8817,6 +8818,28 @@ var DataCard = ({
|
|
|
8817
8818
|
]
|
|
8818
8819
|
}
|
|
8819
8820
|
);
|
|
8821
|
+
var DataCard = (props) => {
|
|
8822
|
+
const ref = (0, import_react33.useRef)(null);
|
|
8823
|
+
if ((0, import_type_guards29.isNotNil)(props.href) || (0, import_type_guards29.isNotNil)(props.onClick)) {
|
|
8824
|
+
return /* @__PURE__ */ (0, import_jsx_runtime213.jsx)(ClickRegion, { targetRef: ref, children: /* @__PURE__ */ (0, import_jsx_runtime213.jsx)(
|
|
8825
|
+
DataCardInner,
|
|
8826
|
+
{
|
|
8827
|
+
...props,
|
|
8828
|
+
label: /* @__PURE__ */ (0, import_jsx_runtime213.jsx)(
|
|
8829
|
+
Button,
|
|
8830
|
+
{
|
|
8831
|
+
ref,
|
|
8832
|
+
href: props.href,
|
|
8833
|
+
onClick: props.onClick,
|
|
8834
|
+
unstyled: true,
|
|
8835
|
+
children: props.label
|
|
8836
|
+
}
|
|
8837
|
+
)
|
|
8838
|
+
}
|
|
8839
|
+
) });
|
|
8840
|
+
}
|
|
8841
|
+
return /* @__PURE__ */ (0, import_jsx_runtime213.jsx)(DataCardInner, { ...props });
|
|
8842
|
+
};
|
|
8820
8843
|
DataCard.displayName = "DataCard";
|
|
8821
8844
|
|
|
8822
8845
|
// src/components/DataCards/DataCards.tsx
|
|
@@ -8857,7 +8880,7 @@ DataCards.displayName = "DataCards";
|
|
|
8857
8880
|
var import_styled_components43 = __toESM(require("styled-components"));
|
|
8858
8881
|
|
|
8859
8882
|
// src/components/Text/Text.tsx
|
|
8860
|
-
var
|
|
8883
|
+
var import_react34 = require("react");
|
|
8861
8884
|
var import_styled_components42 = __toESM(require("styled-components"));
|
|
8862
8885
|
var import_type_guards30 = require("@wistia/type-guards");
|
|
8863
8886
|
var import_jsx_runtime215 = require("react/jsx-runtime");
|
|
@@ -9032,7 +9055,7 @@ var StyledText = import_styled_components42.default.div`
|
|
|
9032
9055
|
}
|
|
9033
9056
|
`}
|
|
9034
9057
|
`;
|
|
9035
|
-
var TextComponent = (0,
|
|
9058
|
+
var TextComponent = (0, import_react34.forwardRef)(
|
|
9036
9059
|
({
|
|
9037
9060
|
align = "left",
|
|
9038
9061
|
colorScheme = "inherit",
|
|
@@ -9145,7 +9168,7 @@ Divider.displayName = "Divider";
|
|
|
9145
9168
|
|
|
9146
9169
|
// src/components/EditableHeading/EditableHeading.tsx
|
|
9147
9170
|
var import_styled_components48 = __toESM(require("styled-components"));
|
|
9148
|
-
var
|
|
9171
|
+
var import_react36 = require("react");
|
|
9149
9172
|
|
|
9150
9173
|
// src/components/Tooltip/Tooltip.tsx
|
|
9151
9174
|
var import_react_tooltip2 = require("@radix-ui/react-tooltip");
|
|
@@ -9297,7 +9320,7 @@ var Tooltip = ({
|
|
|
9297
9320
|
Tooltip.displayName = "Tooltip";
|
|
9298
9321
|
|
|
9299
9322
|
// src/components/Input/Input.tsx
|
|
9300
|
-
var
|
|
9323
|
+
var import_react35 = require("react");
|
|
9301
9324
|
var import_styled_components47 = __toESM(require("styled-components"));
|
|
9302
9325
|
var import_type_guards31 = require("@wistia/type-guards");
|
|
9303
9326
|
|
|
@@ -9432,7 +9455,7 @@ var StyledInputContainer = import_styled_components47.default.div`
|
|
|
9432
9455
|
padding-right: 32px;
|
|
9433
9456
|
}
|
|
9434
9457
|
`;
|
|
9435
|
-
var Input = (0,
|
|
9458
|
+
var Input = (0, import_react35.forwardRef)(
|
|
9436
9459
|
({
|
|
9437
9460
|
fullWidth = true,
|
|
9438
9461
|
monospace = false,
|
|
@@ -9442,7 +9465,7 @@ var Input = (0, import_react34.forwardRef)(
|
|
|
9442
9465
|
rightIcon,
|
|
9443
9466
|
...props
|
|
9444
9467
|
}, externalRef) => {
|
|
9445
|
-
const internalRef = (0,
|
|
9468
|
+
const internalRef = (0, import_react35.useRef)();
|
|
9446
9469
|
const ref = (
|
|
9447
9470
|
// eslint-disable-next-line react-compiler/react-compiler
|
|
9448
9471
|
(0, import_type_guards31.isNotNil)(externalRef) && (0, import_type_guards31.isRecord)(externalRef) && "current" in externalRef ? externalRef : internalRef
|
|
@@ -9452,14 +9475,14 @@ var Input = (0, import_react34.forwardRef)(
|
|
|
9452
9475
|
leftIconToDisplay = /* @__PURE__ */ (0, import_jsx_runtime219.jsx)(Icon, { type: "search" });
|
|
9453
9476
|
}
|
|
9454
9477
|
if ((0, import_type_guards31.isNotNil)(leftIconToDisplay)) {
|
|
9455
|
-
leftIconToDisplay = (0,
|
|
9478
|
+
leftIconToDisplay = (0, import_react35.cloneElement)(leftIconToDisplay, {
|
|
9456
9479
|
size: "md",
|
|
9457
9480
|
className: "wui-input-left-icon"
|
|
9458
9481
|
});
|
|
9459
9482
|
}
|
|
9460
9483
|
let rightIconToDisplay = rightIcon;
|
|
9461
9484
|
if ((0, import_type_guards31.isNotNil)(rightIconToDisplay)) {
|
|
9462
|
-
rightIconToDisplay = (0,
|
|
9485
|
+
rightIconToDisplay = (0, import_react35.cloneElement)(rightIconToDisplay, {
|
|
9463
9486
|
size: "md",
|
|
9464
9487
|
className: "wui-input-right-icon"
|
|
9465
9488
|
});
|
|
@@ -9551,11 +9574,11 @@ var EditableHeading = ({
|
|
|
9551
9574
|
__forceEditing = false,
|
|
9552
9575
|
editingDisabled = false
|
|
9553
9576
|
}) => {
|
|
9554
|
-
const [isEditing, setIsEditing] = (0,
|
|
9555
|
-
const [value, setValue] = (0,
|
|
9556
|
-
const [previousValue, setPreviousValue] = (0,
|
|
9557
|
-
const [headingHeight, setHeadingHeight] = (0,
|
|
9558
|
-
const headingRef = (0,
|
|
9577
|
+
const [isEditing, setIsEditing] = (0, import_react36.useState)(false);
|
|
9578
|
+
const [value, setValue] = (0, import_react36.useState)(children);
|
|
9579
|
+
const [previousValue, setPreviousValue] = (0, import_react36.useState)(children);
|
|
9580
|
+
const [headingHeight, setHeadingHeight] = (0, import_react36.useState)("60");
|
|
9581
|
+
const headingRef = (0, import_react36.useRef)(null);
|
|
9559
9582
|
const handleSetEditing = (editing) => {
|
|
9560
9583
|
if (editingDisabled) return;
|
|
9561
9584
|
if (editing && headingRef.current) {
|
|
@@ -9634,12 +9657,12 @@ var EditableHeading = ({
|
|
|
9634
9657
|
};
|
|
9635
9658
|
|
|
9636
9659
|
// src/components/Form/Form.tsx
|
|
9637
|
-
var
|
|
9660
|
+
var import_react38 = require("react");
|
|
9638
9661
|
var import_styled_components50 = __toESM(require("styled-components"));
|
|
9639
9662
|
var import_type_guards32 = require("@wistia/type-guards");
|
|
9640
9663
|
|
|
9641
9664
|
// src/components/Stack/Stack.tsx
|
|
9642
|
-
var
|
|
9665
|
+
var import_react37 = require("react");
|
|
9643
9666
|
var import_styled_components49 = __toESM(require("styled-components"));
|
|
9644
9667
|
var import_jsx_runtime221 = require("react/jsx-runtime");
|
|
9645
9668
|
var DEFAULT_ELEMENT4 = "div";
|
|
@@ -9649,7 +9672,7 @@ var StyledStack = import_styled_components49.default.div`
|
|
|
9649
9672
|
gap: ${({ $gap }) => `var(--wui-${$gap})`};
|
|
9650
9673
|
align-items: ${({ $alignItems }) => $alignItems};
|
|
9651
9674
|
`;
|
|
9652
|
-
var StackComponent = (0,
|
|
9675
|
+
var StackComponent = (0, import_react37.forwardRef)(
|
|
9653
9676
|
({ renderAs, direction = "vertical", gap = "space-02", alignItems = "stretch", ...props }, ref) => {
|
|
9654
9677
|
const responsiveGap = useResponsiveProp(gap);
|
|
9655
9678
|
const responsiveDirection = useResponsiveProp(direction);
|
|
@@ -9678,7 +9701,7 @@ var StyledForm = import_styled_components50.default.form`
|
|
|
9678
9701
|
max-width: ${({ $fullWidth }) => $fullWidth ? "auto" : "var(--form-default-width)"};
|
|
9679
9702
|
align-items: ${({ $fullWidth }) => $fullWidth ? "stretch" : "flex-start"};
|
|
9680
9703
|
`;
|
|
9681
|
-
var FormContext = (0,
|
|
9704
|
+
var FormContext = (0, import_react38.createContext)({
|
|
9682
9705
|
values: {},
|
|
9683
9706
|
errors: {},
|
|
9684
9707
|
hasSubmitted: false,
|
|
@@ -9694,11 +9717,11 @@ var FormComponent = ({
|
|
|
9694
9717
|
fullWidth = false,
|
|
9695
9718
|
...props
|
|
9696
9719
|
}, forwardedRef) => {
|
|
9697
|
-
const [errors, setErrors] = (0,
|
|
9698
|
-
const [hasSubmitted, setHasSubmitted] = (0,
|
|
9699
|
-
const innerRef = (0,
|
|
9720
|
+
const [errors, setErrors] = (0, import_react38.useState)({});
|
|
9721
|
+
const [hasSubmitted, setHasSubmitted] = (0, import_react38.useState)(false);
|
|
9722
|
+
const innerRef = (0, import_react38.useRef)();
|
|
9700
9723
|
const ref = forwardedRef ?? innerRef;
|
|
9701
|
-
const autoId = (0,
|
|
9724
|
+
const autoId = (0, import_react38.useId)();
|
|
9702
9725
|
const id = props.id ?? autoId;
|
|
9703
9726
|
const handleValidate = (nextFormData) => {
|
|
9704
9727
|
const nextData = Object.fromEntries(nextFormData.entries());
|
|
@@ -9740,7 +9763,7 @@ var FormComponent = ({
|
|
|
9740
9763
|
void action(null);
|
|
9741
9764
|
}
|
|
9742
9765
|
};
|
|
9743
|
-
const context = (0,
|
|
9766
|
+
const context = (0, import_react38.useMemo)(() => {
|
|
9744
9767
|
return {
|
|
9745
9768
|
values,
|
|
9746
9769
|
errors,
|
|
@@ -9769,15 +9792,15 @@ var FormComponent = ({
|
|
|
9769
9792
|
);
|
|
9770
9793
|
};
|
|
9771
9794
|
FormComponent.displayName = "Form";
|
|
9772
|
-
var Form = (0,
|
|
9795
|
+
var Form = (0, import_react38.forwardRef)(FormComponent);
|
|
9773
9796
|
|
|
9774
9797
|
// src/components/Form/useFormState.tsx
|
|
9775
|
-
var
|
|
9798
|
+
var import_react39 = require("react");
|
|
9776
9799
|
var useFormState = (action, initialData = {}) => {
|
|
9777
|
-
const [data, setData] = (0,
|
|
9778
|
-
const [isPending, setIsPending] = (0,
|
|
9779
|
-
const [error, setError] = (0,
|
|
9780
|
-
const formAction = (0,
|
|
9800
|
+
const [data, setData] = (0, import_react39.useState)(initialData);
|
|
9801
|
+
const [isPending, setIsPending] = (0, import_react39.useState)(false);
|
|
9802
|
+
const [error, setError] = (0, import_react39.useState)(null);
|
|
9803
|
+
const formAction = (0, import_react39.useCallback)(
|
|
9781
9804
|
async (nextFormData) => {
|
|
9782
9805
|
if (nextFormData === null) {
|
|
9783
9806
|
setData(initialData);
|
|
@@ -9808,15 +9831,15 @@ var useFormState = (action, initialData = {}) => {
|
|
|
9808
9831
|
};
|
|
9809
9832
|
|
|
9810
9833
|
// src/components/Form/FormErrorSummary.tsx
|
|
9811
|
-
var
|
|
9834
|
+
var import_react40 = require("react");
|
|
9812
9835
|
var import_type_guards33 = require("@wistia/type-guards");
|
|
9813
9836
|
var import_jsx_runtime223 = require("react/jsx-runtime");
|
|
9814
9837
|
var ErrorItem = ({ name, error, formId }) => {
|
|
9815
9838
|
return /* @__PURE__ */ (0, import_jsx_runtime223.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime223.jsx)(Link, { href: `#${formId}-${name}`, children: error }) }, name);
|
|
9816
9839
|
};
|
|
9817
9840
|
var FormErrorSummary = ({ description }) => {
|
|
9818
|
-
const ref = (0,
|
|
9819
|
-
const { formId, errors, hasSubmitted } = (0,
|
|
9841
|
+
const ref = (0, import_react40.useRef)(null);
|
|
9842
|
+
const { formId, errors, hasSubmitted } = (0, import_react40.useContext)(FormContext);
|
|
9820
9843
|
const isValid = Object.keys(errors).length === 0;
|
|
9821
9844
|
if (isValid || !hasSubmitted) {
|
|
9822
9845
|
return null;
|
|
@@ -9846,7 +9869,7 @@ var FormErrorSummary = ({ description }) => {
|
|
|
9846
9869
|
};
|
|
9847
9870
|
|
|
9848
9871
|
// src/components/FormField/FormField.tsx
|
|
9849
|
-
var
|
|
9872
|
+
var import_react43 = require("react");
|
|
9850
9873
|
var import_styled_components53 = __toESM(require("styled-components"));
|
|
9851
9874
|
var import_type_guards34 = require("@wistia/type-guards");
|
|
9852
9875
|
|
|
@@ -9911,11 +9934,11 @@ var Label = ({
|
|
|
9911
9934
|
Label.displayName = "Label";
|
|
9912
9935
|
|
|
9913
9936
|
// src/components/FormGroup/CheckboxGroup.tsx
|
|
9914
|
-
var
|
|
9937
|
+
var import_react42 = require("react");
|
|
9915
9938
|
|
|
9916
9939
|
// src/components/FormGroup/FormGroup.tsx
|
|
9917
9940
|
var import_styled_components52 = __toESM(require("styled-components"));
|
|
9918
|
-
var
|
|
9941
|
+
var import_react41 = require("react");
|
|
9919
9942
|
var import_jsx_runtime225 = require("react/jsx-runtime");
|
|
9920
9943
|
var StyledFieldset = import_styled_components52.default.fieldset`
|
|
9921
9944
|
border: 0;
|
|
@@ -9924,7 +9947,7 @@ var StyledLegend = import_styled_components52.default.legend`
|
|
|
9924
9947
|
margin-bottom: var(--space-01);
|
|
9925
9948
|
`;
|
|
9926
9949
|
var FormGroup = ({ children, label, ...props }) => {
|
|
9927
|
-
const ref = (0,
|
|
9950
|
+
const ref = (0, import_react41.useRef)();
|
|
9928
9951
|
return /* @__PURE__ */ (0, import_jsx_runtime225.jsxs)(
|
|
9929
9952
|
Stack,
|
|
9930
9953
|
{
|
|
@@ -9949,7 +9972,7 @@ FormGroup.displayName = "FormGroup";
|
|
|
9949
9972
|
|
|
9950
9973
|
// src/components/FormGroup/CheckboxGroup.tsx
|
|
9951
9974
|
var import_jsx_runtime226 = require("react/jsx-runtime");
|
|
9952
|
-
var CheckboxGroupContext = (0,
|
|
9975
|
+
var CheckboxGroupContext = (0, import_react42.createContext)(null);
|
|
9953
9976
|
var CheckboxGroup = ({
|
|
9954
9977
|
children,
|
|
9955
9978
|
name,
|
|
@@ -9957,7 +9980,7 @@ var CheckboxGroup = ({
|
|
|
9957
9980
|
value,
|
|
9958
9981
|
...props
|
|
9959
9982
|
}) => {
|
|
9960
|
-
const context = (0,
|
|
9983
|
+
const context = (0, import_react42.useMemo)(() => {
|
|
9961
9984
|
return {
|
|
9962
9985
|
name,
|
|
9963
9986
|
onChange
|
|
@@ -10042,8 +10065,8 @@ var FormField = ({
|
|
|
10042
10065
|
value,
|
|
10043
10066
|
...props
|
|
10044
10067
|
}) => {
|
|
10045
|
-
const formState = (0,
|
|
10046
|
-
const checkboxGroup = (0,
|
|
10068
|
+
const formState = (0, import_react43.useContext)(FormContext);
|
|
10069
|
+
const checkboxGroup = (0, import_react43.useContext)(CheckboxGroupContext);
|
|
10047
10070
|
const defaultValue = formState.values[name];
|
|
10048
10071
|
const isIntegratedLabel = children.type === Checkbox;
|
|
10049
10072
|
const computedId = id ?? `${formState.formId}-${name}`;
|
|
@@ -10081,7 +10104,7 @@ var FormField = ({
|
|
|
10081
10104
|
"aria-invalid": (0, import_type_guards34.isNotNil)(error)
|
|
10082
10105
|
};
|
|
10083
10106
|
}
|
|
10084
|
-
|
|
10107
|
+
import_react43.Children.only(children);
|
|
10085
10108
|
return /* @__PURE__ */ (0, import_jsx_runtime227.jsxs)(
|
|
10086
10109
|
StyledFormField,
|
|
10087
10110
|
{
|
|
@@ -10090,7 +10113,7 @@ var FormField = ({
|
|
|
10090
10113
|
children: [
|
|
10091
10114
|
!isIntegratedLabel && /* @__PURE__ */ (0, import_jsx_runtime227.jsx)(Label, { htmlFor: computedId, children: label }),
|
|
10092
10115
|
(0, import_type_guards34.isNotNil)(description) ? /* @__PURE__ */ (0, import_jsx_runtime227.jsx)(FormControlLabelDescription, { id: descriptionId, children: description }) : null,
|
|
10093
|
-
(0,
|
|
10116
|
+
(0, import_react43.cloneElement)(children, childProps),
|
|
10094
10117
|
(0, import_type_guards34.isNotNil)(computedError) ? /* @__PURE__ */ (0, import_jsx_runtime227.jsxs)(import_jsx_runtime227.Fragment, { children: [
|
|
10095
10118
|
/* @__PURE__ */ (0, import_jsx_runtime227.jsx)("div", {}),
|
|
10096
10119
|
/* @__PURE__ */ (0, import_jsx_runtime227.jsx)(
|
|
@@ -10108,9 +10131,9 @@ var FormField = ({
|
|
|
10108
10131
|
FormField.displayName = "FormField";
|
|
10109
10132
|
|
|
10110
10133
|
// src/components/FormGroup/RadioGroup.tsx
|
|
10111
|
-
var
|
|
10134
|
+
var import_react44 = require("react");
|
|
10112
10135
|
var import_jsx_runtime228 = require("react/jsx-runtime");
|
|
10113
|
-
var RadioGroupContext = (0,
|
|
10136
|
+
var RadioGroupContext = (0, import_react44.createContext)(null);
|
|
10114
10137
|
var RadioGroup = ({
|
|
10115
10138
|
children,
|
|
10116
10139
|
name,
|
|
@@ -10118,7 +10141,7 @@ var RadioGroup = ({
|
|
|
10118
10141
|
value,
|
|
10119
10142
|
...props
|
|
10120
10143
|
}) => {
|
|
10121
|
-
const context = (0,
|
|
10144
|
+
const context = (0, import_react44.useMemo)(() => {
|
|
10122
10145
|
return {
|
|
10123
10146
|
name,
|
|
10124
10147
|
onChange
|
|
@@ -10129,7 +10152,7 @@ var RadioGroup = ({
|
|
|
10129
10152
|
RadioGroup.displayName = "RadioGroup";
|
|
10130
10153
|
|
|
10131
10154
|
// src/components/IconButton/IconButton.tsx
|
|
10132
|
-
var
|
|
10155
|
+
var import_react45 = require("react");
|
|
10133
10156
|
var import_styled_components54 = __toESM(require("styled-components"));
|
|
10134
10157
|
var import_jsx_runtime229 = require("react/jsx-runtime");
|
|
10135
10158
|
var StyledButton2 = (0, import_styled_components54.default)(Button)`
|
|
@@ -10146,7 +10169,7 @@ var StyledButton2 = (0, import_styled_components54.default)(Button)`
|
|
|
10146
10169
|
align-items: center;
|
|
10147
10170
|
line-height: 1;
|
|
10148
10171
|
`;
|
|
10149
|
-
var IconButton = (0,
|
|
10172
|
+
var IconButton = (0, import_react45.forwardRef)(
|
|
10150
10173
|
({ children, label, size = "md", ...props }, ref) => {
|
|
10151
10174
|
const responsiveSize = useResponsiveProp(size);
|
|
10152
10175
|
return /* @__PURE__ */ (0, import_jsx_runtime229.jsx)(
|
|
@@ -10157,7 +10180,7 @@ var IconButton = (0, import_react44.forwardRef)(
|
|
|
10157
10180
|
"aria-label": label,
|
|
10158
10181
|
"data-wistia-ui-icon-button": true,
|
|
10159
10182
|
size: responsiveSize,
|
|
10160
|
-
children: (0,
|
|
10183
|
+
children: (0, import_react45.cloneElement)(import_react45.Children.only(children), {
|
|
10161
10184
|
size: responsiveSize
|
|
10162
10185
|
})
|
|
10163
10186
|
}
|
|
@@ -10168,7 +10191,7 @@ IconButton.displayName = "IconButton";
|
|
|
10168
10191
|
|
|
10169
10192
|
// src/components/InputClickToCopy/InputClickToCopy.tsx
|
|
10170
10193
|
var import_styled_components55 = __toESM(require("styled-components"));
|
|
10171
|
-
var
|
|
10194
|
+
var import_react46 = require("react");
|
|
10172
10195
|
var import_type_guards35 = require("@wistia/type-guards");
|
|
10173
10196
|
var import_jsx_runtime230 = require("react/jsx-runtime");
|
|
10174
10197
|
var StyledInput2 = (0, import_styled_components55.default)(Input)`
|
|
@@ -10181,10 +10204,10 @@ var StyledInput2 = (0, import_styled_components55.default)(Input)`
|
|
|
10181
10204
|
}
|
|
10182
10205
|
`;
|
|
10183
10206
|
var COPY_SUCCESS_DURATION = 2e3;
|
|
10184
|
-
var InputClickToCopy = (0,
|
|
10207
|
+
var InputClickToCopy = (0, import_react46.forwardRef)(
|
|
10185
10208
|
({ value, onCopy, ...props }, ref) => {
|
|
10186
|
-
const [isCopied, setIsCopied] = (0,
|
|
10187
|
-
(0,
|
|
10209
|
+
const [isCopied, setIsCopied] = (0, import_react46.useState)(false);
|
|
10210
|
+
(0, import_react46.useEffect)(() => {
|
|
10188
10211
|
if (isCopied) {
|
|
10189
10212
|
const timeout = setTimeout(() => {
|
|
10190
10213
|
setIsCopied(false);
|
|
@@ -10343,12 +10366,12 @@ KeyboardShortcut.displayName = "KeyboardShortcut";
|
|
|
10343
10366
|
var import_styled_components57 = __toESM(require("styled-components"));
|
|
10344
10367
|
var import_react_dropdown_menu = require("@radix-ui/react-dropdown-menu");
|
|
10345
10368
|
var import_type_guards37 = require("@wistia/type-guards");
|
|
10346
|
-
var
|
|
10369
|
+
var import_react48 = require("react");
|
|
10347
10370
|
|
|
10348
10371
|
// src/components/Menu/MenuContext.tsx
|
|
10349
|
-
var
|
|
10350
|
-
var MenuContext = (0,
|
|
10351
|
-
var useMenuContext = () => (0,
|
|
10372
|
+
var import_react47 = require("react");
|
|
10373
|
+
var MenuContext = (0, import_react47.createContext)({ compact: false });
|
|
10374
|
+
var useMenuContext = () => (0, import_react47.useContext)(MenuContext);
|
|
10352
10375
|
|
|
10353
10376
|
// src/components/Menu/Menu.tsx
|
|
10354
10377
|
var import_jsx_runtime232 = require("react/jsx-runtime");
|
|
@@ -10452,7 +10475,7 @@ var Menu = ({
|
|
|
10452
10475
|
onInteractOutside,
|
|
10453
10476
|
...props
|
|
10454
10477
|
}) => {
|
|
10455
|
-
const contextValue = (0,
|
|
10478
|
+
const contextValue = (0, import_react48.useMemo)(() => ({ compact }), [compact]);
|
|
10456
10479
|
let controlProps = {
|
|
10457
10480
|
...(0, import_type_guards37.isNotNil)(onOpenChange) && (0, import_type_guards37.isNotNil)(isOpen) ? { open: isOpen, onOpenChange } : {}
|
|
10458
10481
|
};
|
|
@@ -10526,13 +10549,13 @@ var MenuLabel = ({ children, ...props }) => {
|
|
|
10526
10549
|
MenuLabel.displayName = "MenuLabel";
|
|
10527
10550
|
|
|
10528
10551
|
// src/components/Menu/SubMenu.tsx
|
|
10529
|
-
var
|
|
10552
|
+
var import_react50 = require("react");
|
|
10530
10553
|
var import_styled_components61 = __toESM(require("styled-components"));
|
|
10531
10554
|
var import_react_dropdown_menu3 = require("@radix-ui/react-dropdown-menu");
|
|
10532
10555
|
var import_type_guards39 = require("@wistia/type-guards");
|
|
10533
10556
|
|
|
10534
10557
|
// src/components/Menu/MenuItemButton.tsx
|
|
10535
|
-
var
|
|
10558
|
+
var import_react49 = require("react");
|
|
10536
10559
|
var import_styled_components59 = __toESM(require("styled-components"));
|
|
10537
10560
|
var import_type_guards38 = require("@wistia/type-guards");
|
|
10538
10561
|
var import_jsx_runtime234 = require("react/jsx-runtime");
|
|
@@ -10609,7 +10632,7 @@ var StyledBadgeContainer = import_styled_components59.default.div`
|
|
|
10609
10632
|
font-size: var(--wui-typography-label-4-size);
|
|
10610
10633
|
color: var(--wui-color-text-secondary);
|
|
10611
10634
|
`;
|
|
10612
|
-
var MenuItemButton = (0,
|
|
10635
|
+
var MenuItemButton = (0, import_react49.forwardRef)(({ children, appearance, command, icon, ...props }, ref) => {
|
|
10613
10636
|
let { colorScheme, badge } = props;
|
|
10614
10637
|
if (appearance === "dangerous") {
|
|
10615
10638
|
if ((0, import_type_guards38.isNotUndefined)(colorScheme)) {
|
|
@@ -10709,7 +10732,7 @@ var SubMenu = ({
|
|
|
10709
10732
|
...props
|
|
10710
10733
|
}) => {
|
|
10711
10734
|
const { isSmAndUp } = useMq();
|
|
10712
|
-
const [isExpanded, setIsExpanded] = (0,
|
|
10735
|
+
const [isExpanded, setIsExpanded] = (0, import_react50.useState)(false);
|
|
10713
10736
|
const { compact } = useMenuContext();
|
|
10714
10737
|
return isSmAndUp ? /* @__PURE__ */ (0, import_jsx_runtime236.jsxs)(import_react_dropdown_menu3.DropdownMenuSub, { onOpenChange, children: [
|
|
10715
10738
|
/* @__PURE__ */ (0, import_jsx_runtime236.jsxs)(SubMenuTrigger, { ...props, children: [
|
|
@@ -10738,10 +10761,10 @@ var SubMenu = ({
|
|
|
10738
10761
|
SubMenu.displayName = "SubMenu";
|
|
10739
10762
|
|
|
10740
10763
|
// src/components/Menu/MenuItem.tsx
|
|
10741
|
-
var
|
|
10764
|
+
var import_react51 = require("react");
|
|
10742
10765
|
var import_react_dropdown_menu4 = require("@radix-ui/react-dropdown-menu");
|
|
10743
10766
|
var import_jsx_runtime237 = require("react/jsx-runtime");
|
|
10744
|
-
var MenuItem = (0,
|
|
10767
|
+
var MenuItem = (0, import_react51.forwardRef)(
|
|
10745
10768
|
({ onSelect = () => null, ...props }, ref) => {
|
|
10746
10769
|
return /* @__PURE__ */ (0, import_jsx_runtime237.jsx)(
|
|
10747
10770
|
import_react_dropdown_menu4.DropdownMenuItem,
|
|
@@ -10893,7 +10916,7 @@ var CheckboxMenuItem = ({
|
|
|
10893
10916
|
CheckboxMenuItem.displayName = "CheckboxMenuItem";
|
|
10894
10917
|
|
|
10895
10918
|
// src/components/Modal/Modal.tsx
|
|
10896
|
-
var
|
|
10919
|
+
var import_react55 = require("react");
|
|
10897
10920
|
var import_styled_components66 = __toESM(require("styled-components"));
|
|
10898
10921
|
var import_react_dialog4 = require("@radix-ui/react-dialog");
|
|
10899
10922
|
var import_type_guards42 = require("@wistia/type-guards");
|
|
@@ -10953,19 +10976,19 @@ var ModalHeader = ({
|
|
|
10953
10976
|
};
|
|
10954
10977
|
|
|
10955
10978
|
// src/components/Modal/ModalContent.tsx
|
|
10956
|
-
var
|
|
10979
|
+
var import_react53 = require("react");
|
|
10957
10980
|
var import_styled_components64 = __toESM(require("styled-components"));
|
|
10958
10981
|
var import_react_dialog3 = require("@radix-ui/react-dialog");
|
|
10959
10982
|
|
|
10960
10983
|
// src/private/hooks/useFocusRestore/useFocusRestore.ts
|
|
10961
|
-
var
|
|
10984
|
+
var import_react52 = require("react");
|
|
10962
10985
|
var import_type_guards41 = require("@wistia/type-guards");
|
|
10963
10986
|
var useFocusRestore = () => {
|
|
10964
|
-
const previouslyFocusedRef = (0,
|
|
10965
|
-
(0,
|
|
10987
|
+
const previouslyFocusedRef = (0, import_react52.useRef)(null);
|
|
10988
|
+
(0, import_react52.useEffect)(() => {
|
|
10966
10989
|
previouslyFocusedRef.current = document.activeElement;
|
|
10967
10990
|
}, []);
|
|
10968
|
-
(0,
|
|
10991
|
+
(0, import_react52.useEffect)(() => {
|
|
10969
10992
|
return () => {
|
|
10970
10993
|
if ((0, import_type_guards41.isNotNil)(previouslyFocusedRef.current)) {
|
|
10971
10994
|
setTimeout(() => {
|
|
@@ -11019,7 +11042,7 @@ var StyledModalContent = (0, import_styled_components64.default)(import_react_di
|
|
|
11019
11042
|
}
|
|
11020
11043
|
}
|
|
11021
11044
|
`;
|
|
11022
|
-
var ModalContent = (0,
|
|
11045
|
+
var ModalContent = (0, import_react53.forwardRef)(
|
|
11023
11046
|
({ fullHeight, width, children, ...props }, ref) => {
|
|
11024
11047
|
useFocusRestore();
|
|
11025
11048
|
return /* @__PURE__ */ (0, import_jsx_runtime243.jsx)(
|
|
@@ -11037,7 +11060,7 @@ var ModalContent = (0, import_react52.forwardRef)(
|
|
|
11037
11060
|
);
|
|
11038
11061
|
|
|
11039
11062
|
// src/private/components/Backdrop/Backdrop.tsx
|
|
11040
|
-
var
|
|
11063
|
+
var import_react54 = require("react");
|
|
11041
11064
|
var import_styled_components65 = __toESM(require("styled-components"));
|
|
11042
11065
|
var import_jsx_runtime244 = require("react/jsx-runtime");
|
|
11043
11066
|
var backdropAnimationDuration = 150;
|
|
@@ -11080,7 +11103,7 @@ var BackdropComponent = import_styled_components65.default.div`
|
|
|
11080
11103
|
}
|
|
11081
11104
|
}
|
|
11082
11105
|
`;
|
|
11083
|
-
var Backdrop = (0,
|
|
11106
|
+
var Backdrop = (0, import_react54.forwardRef)(
|
|
11084
11107
|
({ alignHorizontal = "center", alignVertical = "center", children, ...otherProps }, ref) => /* @__PURE__ */ (0, import_jsx_runtime244.jsx)(
|
|
11085
11108
|
BackdropComponent,
|
|
11086
11109
|
{
|
|
@@ -11102,7 +11125,7 @@ var ModalBody = import_styled_components66.default.div`
|
|
|
11102
11125
|
display: flex;
|
|
11103
11126
|
order: 2;
|
|
11104
11127
|
`;
|
|
11105
|
-
var Modal = (0,
|
|
11128
|
+
var Modal = (0, import_react55.forwardRef)(
|
|
11106
11129
|
({
|
|
11107
11130
|
children,
|
|
11108
11131
|
fullHeight = false,
|
|
@@ -11162,8 +11185,8 @@ var Modal = (0, import_react54.forwardRef)(
|
|
|
11162
11185
|
Modal.displayName = "Modal";
|
|
11163
11186
|
|
|
11164
11187
|
// src/components/Popover/Popover.tsx
|
|
11165
|
-
var
|
|
11166
|
-
var
|
|
11188
|
+
var import_react_popover2 = require("@radix-ui/react-popover");
|
|
11189
|
+
var import_styled_components68 = __toESM(require("styled-components"));
|
|
11167
11190
|
|
|
11168
11191
|
// src/private/helpers/getControls/getControlProps.tsx
|
|
11169
11192
|
var import_type_guards43 = require("@wistia/type-guards");
|
|
@@ -11171,11 +11194,91 @@ var getControlProps = (isOpen, onOpenChange) => {
|
|
|
11171
11194
|
return (0, import_type_guards43.isNotNil)(onOpenChange) && (0, import_type_guards43.isNotNil)(isOpen) ? { open: isOpen, onOpenChange } : {};
|
|
11172
11195
|
};
|
|
11173
11196
|
|
|
11174
|
-
// src/components/Popover/
|
|
11197
|
+
// src/components/Popover/PopoverArrow.tsx
|
|
11198
|
+
var import_react_popover = require("@radix-ui/react-popover");
|
|
11199
|
+
var import_styled_components67 = __toESM(require("styled-components"));
|
|
11175
11200
|
var import_jsx_runtime246 = require("react/jsx-runtime");
|
|
11176
|
-
var
|
|
11201
|
+
var StyledPath = import_styled_components67.default.path`
|
|
11202
|
+
fill: var(--wui-color-border-secondary);
|
|
11203
|
+
`;
|
|
11204
|
+
var circleAnimation = import_styled_components67.keyframes`
|
|
11205
|
+
0% {
|
|
11206
|
+
opacity: var(--wui-popover-arrow-circle-starting-opacity);
|
|
11207
|
+
}
|
|
11208
|
+
100% {
|
|
11209
|
+
opacity: 0;
|
|
11210
|
+
}
|
|
11211
|
+
`;
|
|
11212
|
+
var StyledCircle = import_styled_components67.default.circle`
|
|
11213
|
+
stroke: var(--wui-color-border-active);
|
|
11214
|
+
animation-duration: 2s;
|
|
11215
|
+
animation-iteration-count: infinite;
|
|
11216
|
+
animation-direction: alternate;
|
|
11217
|
+
animation-timing-function: ease-in-out;
|
|
11218
|
+
|
|
11219
|
+
&[data-wui-popover-arrow-inner-circle] {
|
|
11220
|
+
--wui-popover-arrow-circle-starting-opacity: 0.36;
|
|
11221
|
+
|
|
11222
|
+
opacity: var(--wui-popover-arrow-circle-starting-opacity);
|
|
11223
|
+
}
|
|
11224
|
+
|
|
11225
|
+
&[data-wui-popover-arrow-outer-circle] {
|
|
11226
|
+
--wui-popover-arrow-circle-starting-opacity: 0.2;
|
|
11227
|
+
|
|
11228
|
+
animation-direction: alternate-reverse;
|
|
11229
|
+
opacity: 0.11;
|
|
11230
|
+
}
|
|
11231
|
+
|
|
11232
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
11233
|
+
${({ $isAnimated }) => $isAnimated && import_styled_components67.css`
|
|
11234
|
+
animation-name: ${circleAnimation};
|
|
11235
|
+
`}
|
|
11236
|
+
}
|
|
11237
|
+
`;
|
|
11238
|
+
var PopoverArrow = ({ isAnimated }) => {
|
|
11239
|
+
return /* @__PURE__ */ (0, import_jsx_runtime246.jsx)(import_react_popover.PopoverArrow, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime246.jsxs)(
|
|
11240
|
+
"svg",
|
|
11241
|
+
{
|
|
11242
|
+
fill: "none",
|
|
11243
|
+
height: "56",
|
|
11244
|
+
viewBox: "0 0 48 56",
|
|
11245
|
+
width: "48",
|
|
11246
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
11247
|
+
children: [
|
|
11248
|
+
/* @__PURE__ */ (0, import_jsx_runtime246.jsx)(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" }),
|
|
11249
|
+
/* @__PURE__ */ (0, import_jsx_runtime246.jsx)(
|
|
11250
|
+
StyledCircle,
|
|
11251
|
+
{
|
|
11252
|
+
$isAnimated: isAnimated,
|
|
11253
|
+
cx: "24",
|
|
11254
|
+
cy: "32",
|
|
11255
|
+
"data-wui-popover-arrow-inner-circle": true,
|
|
11256
|
+
r: "10",
|
|
11257
|
+
strokeWidth: "4"
|
|
11258
|
+
}
|
|
11259
|
+
),
|
|
11260
|
+
/* @__PURE__ */ (0, import_jsx_runtime246.jsx)(
|
|
11261
|
+
StyledCircle,
|
|
11262
|
+
{
|
|
11263
|
+
$isAnimated: isAnimated,
|
|
11264
|
+
cx: "24",
|
|
11265
|
+
cy: "32",
|
|
11266
|
+
"data-wui-popover-arrow-outer-circle": true,
|
|
11267
|
+
r: "20",
|
|
11268
|
+
strokeWidth: "8"
|
|
11269
|
+
}
|
|
11270
|
+
)
|
|
11271
|
+
]
|
|
11272
|
+
}
|
|
11273
|
+
) });
|
|
11274
|
+
};
|
|
11275
|
+
PopoverArrow.displayName = "PopoverArrow";
|
|
11276
|
+
|
|
11277
|
+
// src/components/Popover/Popover.tsx
|
|
11278
|
+
var import_jsx_runtime247 = require("react/jsx-runtime");
|
|
11279
|
+
var StyledContent2 = (0, import_styled_components68.default)(import_react_popover2.Content)`
|
|
11177
11280
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
11178
|
-
${({ $unstyled }) => !$unstyled &&
|
|
11281
|
+
${({ $unstyled }) => !$unstyled && import_styled_components68.css`
|
|
11179
11282
|
border-radius: var(--wui-border-radius-02);
|
|
11180
11283
|
padding: var(--wui-space-04);
|
|
11181
11284
|
max-width: var(--wui-popover-max-width, 320px);
|
|
@@ -11201,34 +11304,38 @@ var Popover = ({
|
|
|
11201
11304
|
maxHeight = "auto",
|
|
11202
11305
|
onOpenChange,
|
|
11203
11306
|
unstyled = false,
|
|
11307
|
+
withArrow = false,
|
|
11308
|
+
isAnimated = false,
|
|
11204
11309
|
colorScheme = "inherit",
|
|
11205
11310
|
...props
|
|
11206
11311
|
}) => {
|
|
11312
|
+
const sideOffset = withArrow ? -24 : 8;
|
|
11207
11313
|
const style = {
|
|
11208
11314
|
"--wui-popover-max-width": maxWidth,
|
|
11209
11315
|
"--wui-popover-max-height": maxHeight
|
|
11210
11316
|
};
|
|
11211
|
-
return /* @__PURE__ */ (0,
|
|
11212
|
-
/* @__PURE__ */ (0,
|
|
11213
|
-
/* @__PURE__ */ (0,
|
|
11317
|
+
return /* @__PURE__ */ (0, import_jsx_runtime247.jsxs)(import_react_popover2.Root, { ...getControlProps(isOpen, onOpenChange), children: [
|
|
11318
|
+
/* @__PURE__ */ (0, import_jsx_runtime247.jsx)(import_react_popover2.Trigger, { asChild: true, children: trigger }),
|
|
11319
|
+
/* @__PURE__ */ (0, import_jsx_runtime247.jsx)(import_react_popover2.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime247.jsxs)(
|
|
11214
11320
|
StyledContent2,
|
|
11215
11321
|
{
|
|
11216
11322
|
$colorScheme: colorScheme,
|
|
11217
|
-
sideOffset
|
|
11323
|
+
sideOffset,
|
|
11218
11324
|
...props,
|
|
11219
11325
|
$unstyled: unstyled,
|
|
11220
11326
|
style,
|
|
11221
11327
|
children: [
|
|
11222
|
-
!hideCloseButton && /* @__PURE__ */ (0,
|
|
11328
|
+
!hideCloseButton && /* @__PURE__ */ (0, import_jsx_runtime247.jsx)(import_react_popover2.Close, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime247.jsx)(
|
|
11223
11329
|
IconButton,
|
|
11224
11330
|
{
|
|
11225
11331
|
"data-wui-popover-close": true,
|
|
11226
11332
|
label: "Close",
|
|
11227
11333
|
variant: "ghost",
|
|
11228
|
-
children: /* @__PURE__ */ (0,
|
|
11334
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime247.jsx)(Icon, { type: "close" })
|
|
11229
11335
|
}
|
|
11230
11336
|
) }),
|
|
11231
|
-
/* @__PURE__ */ (0,
|
|
11337
|
+
withArrow ? /* @__PURE__ */ (0, import_jsx_runtime247.jsx)(PopoverArrow, { isAnimated }) : null,
|
|
11338
|
+
/* @__PURE__ */ (0, import_jsx_runtime247.jsx)("div", { children })
|
|
11232
11339
|
]
|
|
11233
11340
|
}
|
|
11234
11341
|
) })
|
|
@@ -11237,11 +11344,11 @@ var Popover = ({
|
|
|
11237
11344
|
Popover.displayName = "Popover";
|
|
11238
11345
|
|
|
11239
11346
|
// src/components/ProgressBar/ProgressBar.tsx
|
|
11240
|
-
var
|
|
11347
|
+
var import_styled_components69 = __toESM(require("styled-components"));
|
|
11241
11348
|
var import_react_progress = require("@radix-ui/react-progress");
|
|
11242
11349
|
var import_type_guards44 = require("@wistia/type-guards");
|
|
11243
|
-
var
|
|
11244
|
-
var ProgressBarWrapper =
|
|
11350
|
+
var import_jsx_runtime248 = require("react/jsx-runtime");
|
|
11351
|
+
var ProgressBarWrapper = import_styled_components69.default.div`
|
|
11245
11352
|
--progress-bar-height: 8px;
|
|
11246
11353
|
--progress-bar-indicator-color: var(--wui-color-bg-fill);
|
|
11247
11354
|
--progress-bar-background-color: var(--wui-color-bg-surface-secondary);
|
|
@@ -11257,7 +11364,7 @@ var getTranslateValue = (progress, max) => {
|
|
|
11257
11364
|
const progressPercentage = progress / max * 100;
|
|
11258
11365
|
return `translateX(-${100 - progressPercentage}%)`;
|
|
11259
11366
|
};
|
|
11260
|
-
var ProgressBarLabel =
|
|
11367
|
+
var ProgressBarLabel = import_styled_components69.default.div`
|
|
11261
11368
|
display: flex;
|
|
11262
11369
|
line-height: var(--wui-typography-label-3-line-height);
|
|
11263
11370
|
font-size: var(--wui-typography-label-3-size);
|
|
@@ -11265,7 +11372,7 @@ var ProgressBarLabel = import_styled_components68.default.div`
|
|
|
11265
11372
|
color: var(--wui-color-text-secondary);
|
|
11266
11373
|
flex-shrink: 0;
|
|
11267
11374
|
`;
|
|
11268
|
-
var StyledProgressIndicator = (0,
|
|
11375
|
+
var StyledProgressIndicator = (0, import_styled_components69.default)(import_react_progress.Indicator)`
|
|
11269
11376
|
background-color: var(--progress-bar-indicator-color);
|
|
11270
11377
|
width: 100%;
|
|
11271
11378
|
height: 100%;
|
|
@@ -11274,7 +11381,7 @@ var StyledProgressIndicator = (0, import_styled_components68.default)(import_rea
|
|
|
11274
11381
|
transition: transform 660ms cubic-bezier(0.65, 0, 0.35, 1);
|
|
11275
11382
|
transform: ${({ $progress, $max }) => getTranslateValue($progress, $max)};
|
|
11276
11383
|
`;
|
|
11277
|
-
var StyledProgressBar = (0,
|
|
11384
|
+
var StyledProgressBar = (0, import_styled_components69.default)(import_react_progress.Root)`
|
|
11278
11385
|
position: relative;
|
|
11279
11386
|
overflow: hidden;
|
|
11280
11387
|
background: var(--progress-bar-background-color);
|
|
@@ -11293,15 +11400,15 @@ var ProgressBar = ({
|
|
|
11293
11400
|
labelRight,
|
|
11294
11401
|
...props
|
|
11295
11402
|
}) => {
|
|
11296
|
-
return /* @__PURE__ */ (0,
|
|
11297
|
-
(0, import_type_guards44.isNotNil)(labelLeft) ? /* @__PURE__ */ (0,
|
|
11298
|
-
/* @__PURE__ */ (0,
|
|
11403
|
+
return /* @__PURE__ */ (0, import_jsx_runtime248.jsxs)(ProgressBarWrapper, { children: [
|
|
11404
|
+
(0, import_type_guards44.isNotNil)(labelLeft) ? /* @__PURE__ */ (0, import_jsx_runtime248.jsx)(ProgressBarLabel, { children: labelLeft }) : null,
|
|
11405
|
+
/* @__PURE__ */ (0, import_jsx_runtime248.jsx)(
|
|
11299
11406
|
StyledProgressBar,
|
|
11300
11407
|
{
|
|
11301
11408
|
max,
|
|
11302
11409
|
value: progress,
|
|
11303
11410
|
...props,
|
|
11304
|
-
children: /* @__PURE__ */ (0,
|
|
11411
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime248.jsx)(
|
|
11305
11412
|
StyledProgressIndicator,
|
|
11306
11413
|
{
|
|
11307
11414
|
$max: max,
|
|
@@ -11310,17 +11417,17 @@ var ProgressBar = ({
|
|
|
11310
11417
|
)
|
|
11311
11418
|
}
|
|
11312
11419
|
),
|
|
11313
|
-
(0, import_type_guards44.isNotNil)(labelRight) ? /* @__PURE__ */ (0,
|
|
11420
|
+
(0, import_type_guards44.isNotNil)(labelRight) ? /* @__PURE__ */ (0, import_jsx_runtime248.jsx)(ProgressBarLabel, { children: labelRight }) : null
|
|
11314
11421
|
] });
|
|
11315
11422
|
};
|
|
11316
11423
|
ProgressBar.displayName = "ProgressBar";
|
|
11317
11424
|
|
|
11318
11425
|
// src/components/Radio/Radio.tsx
|
|
11319
|
-
var
|
|
11320
|
-
var
|
|
11426
|
+
var import_react56 = require("react");
|
|
11427
|
+
var import_styled_components70 = __toESM(require("styled-components"));
|
|
11321
11428
|
var import_type_guards45 = require("@wistia/type-guards");
|
|
11322
|
-
var
|
|
11323
|
-
var RadioIcon = () => /* @__PURE__ */ (0,
|
|
11429
|
+
var import_jsx_runtime249 = require("react/jsx-runtime");
|
|
11430
|
+
var RadioIcon = () => /* @__PURE__ */ (0, import_jsx_runtime249.jsx)(
|
|
11324
11431
|
"svg",
|
|
11325
11432
|
{
|
|
11326
11433
|
fill: "inherit",
|
|
@@ -11328,7 +11435,7 @@ var RadioIcon = () => /* @__PURE__ */ (0, import_jsx_runtime248.jsx)(
|
|
|
11328
11435
|
viewBox: "0 0 1 1",
|
|
11329
11436
|
width: "1",
|
|
11330
11437
|
xmlns: "http://www.w3.org/2000/svg",
|
|
11331
|
-
children: /* @__PURE__ */ (0,
|
|
11438
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime249.jsx)(
|
|
11332
11439
|
"circle",
|
|
11333
11440
|
{
|
|
11334
11441
|
cx: "0.5",
|
|
@@ -11339,7 +11446,7 @@ var RadioIcon = () => /* @__PURE__ */ (0, import_jsx_runtime248.jsx)(
|
|
|
11339
11446
|
)
|
|
11340
11447
|
}
|
|
11341
11448
|
);
|
|
11342
|
-
var sizeSmall2 =
|
|
11449
|
+
var sizeSmall2 = import_styled_components70.css`
|
|
11343
11450
|
width: 14px;
|
|
11344
11451
|
height: 14px;
|
|
11345
11452
|
min-width: 14px;
|
|
@@ -11350,7 +11457,7 @@ var sizeSmall2 = import_styled_components69.css`
|
|
|
11350
11457
|
height: 7px;
|
|
11351
11458
|
}
|
|
11352
11459
|
`;
|
|
11353
|
-
var sizeMedium2 =
|
|
11460
|
+
var sizeMedium2 = import_styled_components70.css`
|
|
11354
11461
|
width: 16px;
|
|
11355
11462
|
height: 16px;
|
|
11356
11463
|
min-width: 16px;
|
|
@@ -11361,7 +11468,7 @@ var sizeMedium2 = import_styled_components69.css`
|
|
|
11361
11468
|
height: 8px;
|
|
11362
11469
|
}
|
|
11363
11470
|
`;
|
|
11364
|
-
var sizeLarge2 =
|
|
11471
|
+
var sizeLarge2 = import_styled_components70.css`
|
|
11365
11472
|
width: 20px;
|
|
11366
11473
|
height: 20px;
|
|
11367
11474
|
min-width: 20px;
|
|
@@ -11377,14 +11484,14 @@ var getSizeCss2 = (size) => {
|
|
|
11377
11484
|
if (size === "lg") return sizeLarge2;
|
|
11378
11485
|
return sizeMedium2;
|
|
11379
11486
|
};
|
|
11380
|
-
var StyledRadioWrapper =
|
|
11487
|
+
var StyledRadioWrapper = import_styled_components70.default.div`
|
|
11381
11488
|
display: flex;
|
|
11382
11489
|
margin: 0;
|
|
11383
11490
|
|
|
11384
11491
|
/* TODO this solves a problem but potentially causes and a11y issue */
|
|
11385
11492
|
user-select: none;
|
|
11386
11493
|
`;
|
|
11387
|
-
var StyledRadioInput =
|
|
11494
|
+
var StyledRadioInput = import_styled_components70.default.div`
|
|
11388
11495
|
${({ $size }) => getSizeCss2($size)}
|
|
11389
11496
|
line-height: 0;
|
|
11390
11497
|
margin: 0;
|
|
@@ -11406,7 +11513,7 @@ var StyledRadioInput = import_styled_components69.default.div`
|
|
|
11406
11513
|
}
|
|
11407
11514
|
}
|
|
11408
11515
|
`;
|
|
11409
|
-
var StyledHiddenRadioInput =
|
|
11516
|
+
var StyledHiddenRadioInput = import_styled_components70.default.input`
|
|
11410
11517
|
${visuallyHiddenStyle}
|
|
11411
11518
|
|
|
11412
11519
|
/* toggles display of faux-input border-color */
|
|
@@ -11419,7 +11526,7 @@ var StyledHiddenRadioInput = import_styled_components69.default.input`
|
|
|
11419
11526
|
display: block;
|
|
11420
11527
|
}
|
|
11421
11528
|
`;
|
|
11422
|
-
var Radio = (0,
|
|
11529
|
+
var Radio = (0, import_react56.forwardRef)(
|
|
11423
11530
|
({
|
|
11424
11531
|
checked,
|
|
11425
11532
|
disabled = false,
|
|
@@ -11434,15 +11541,15 @@ var Radio = (0, import_react55.forwardRef)(
|
|
|
11434
11541
|
hideLabel = false,
|
|
11435
11542
|
...props
|
|
11436
11543
|
}, ref) => {
|
|
11437
|
-
const generatedId = (0,
|
|
11544
|
+
const generatedId = (0, import_react56.useId)();
|
|
11438
11545
|
const computedId = (0, import_type_guards45.isNonEmptyString)(id) ? id : `wistia-ui-radio-${generatedId}`;
|
|
11439
|
-
return /* @__PURE__ */ (0,
|
|
11546
|
+
return /* @__PURE__ */ (0, import_jsx_runtime249.jsxs)(
|
|
11440
11547
|
StyledRadioWrapper,
|
|
11441
11548
|
{
|
|
11442
11549
|
$disabled: disabled,
|
|
11443
11550
|
"aria-invalid": props["aria-invalid"],
|
|
11444
11551
|
children: [
|
|
11445
|
-
/* @__PURE__ */ (0,
|
|
11552
|
+
/* @__PURE__ */ (0, import_jsx_runtime249.jsx)(
|
|
11446
11553
|
StyledHiddenRadioInput,
|
|
11447
11554
|
{
|
|
11448
11555
|
...props,
|
|
@@ -11457,16 +11564,16 @@ var Radio = (0, import_react55.forwardRef)(
|
|
|
11457
11564
|
value
|
|
11458
11565
|
}
|
|
11459
11566
|
),
|
|
11460
|
-
/* @__PURE__ */ (0,
|
|
11567
|
+
/* @__PURE__ */ (0, import_jsx_runtime249.jsx)(
|
|
11461
11568
|
FormControlLabel,
|
|
11462
11569
|
{
|
|
11463
|
-
controlSlot: /* @__PURE__ */ (0,
|
|
11570
|
+
controlSlot: /* @__PURE__ */ (0, import_jsx_runtime249.jsx)(
|
|
11464
11571
|
StyledRadioInput,
|
|
11465
11572
|
{
|
|
11466
11573
|
$disabled: disabled,
|
|
11467
11574
|
$size: size,
|
|
11468
11575
|
"data-wui-faux-input": "true",
|
|
11469
|
-
children: /* @__PURE__ */ (0,
|
|
11576
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime249.jsx)(RadioIcon, {})
|
|
11470
11577
|
}
|
|
11471
11578
|
),
|
|
11472
11579
|
description,
|
|
@@ -11484,20 +11591,20 @@ var Radio = (0, import_react55.forwardRef)(
|
|
|
11484
11591
|
Radio.displayName = "Radio";
|
|
11485
11592
|
|
|
11486
11593
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
11487
|
-
var
|
|
11488
|
-
var
|
|
11594
|
+
var import_react59 = require("react");
|
|
11595
|
+
var import_styled_components72 = __toESM(require("styled-components"));
|
|
11489
11596
|
var import_react_toggle_group = require("@radix-ui/react-toggle-group");
|
|
11490
11597
|
var import_type_guards46 = require("@wistia/type-guards");
|
|
11491
11598
|
|
|
11492
11599
|
// src/components/SegmentedControl/useSelectedItemStyle.tsx
|
|
11493
|
-
var
|
|
11494
|
-
var
|
|
11495
|
-
var SelectedItemStyleContext = (0,
|
|
11600
|
+
var import_react57 = require("react");
|
|
11601
|
+
var import_jsx_runtime250 = require("react/jsx-runtime");
|
|
11602
|
+
var SelectedItemStyleContext = (0, import_react57.createContext)(null);
|
|
11496
11603
|
var SelectedItemStyleProvider = ({
|
|
11497
11604
|
children
|
|
11498
11605
|
}) => {
|
|
11499
|
-
const [selectedItemMeasurements, setSelectedItemMeasurements] = (0,
|
|
11500
|
-
const selectedItemIndicatorStyle = (0,
|
|
11606
|
+
const [selectedItemMeasurements, setSelectedItemMeasurements] = (0, import_react57.useState)(null);
|
|
11607
|
+
const selectedItemIndicatorStyle = (0, import_react57.useMemo)(
|
|
11501
11608
|
() => selectedItemMeasurements != null ? {
|
|
11502
11609
|
height: `${selectedItemMeasurements.offsetHeight}px`,
|
|
11503
11610
|
transform: `translateX(${selectedItemMeasurements.offsetLeft}px) translateY(-50%)`,
|
|
@@ -11507,17 +11614,17 @@ var SelectedItemStyleProvider = ({
|
|
|
11507
11614
|
},
|
|
11508
11615
|
[selectedItemMeasurements]
|
|
11509
11616
|
);
|
|
11510
|
-
const contextValue = (0,
|
|
11617
|
+
const contextValue = (0, import_react57.useMemo)(
|
|
11511
11618
|
() => ({
|
|
11512
11619
|
setSelectedItemMeasurements,
|
|
11513
11620
|
selectedItemIndicatorStyle
|
|
11514
11621
|
}),
|
|
11515
11622
|
[selectedItemIndicatorStyle]
|
|
11516
11623
|
);
|
|
11517
|
-
return /* @__PURE__ */ (0,
|
|
11624
|
+
return /* @__PURE__ */ (0, import_jsx_runtime250.jsx)(SelectedItemStyleContext.Provider, { value: contextValue, children });
|
|
11518
11625
|
};
|
|
11519
11626
|
var useSelectedItemStyle = () => {
|
|
11520
|
-
const context = (0,
|
|
11627
|
+
const context = (0, import_react57.useContext)(SelectedItemStyleContext);
|
|
11521
11628
|
if (context === null) {
|
|
11522
11629
|
throw new Error("useSelectedItemStyle must be used within a SelectedItemStyleProvider");
|
|
11523
11630
|
}
|
|
@@ -11525,14 +11632,14 @@ var useSelectedItemStyle = () => {
|
|
|
11525
11632
|
};
|
|
11526
11633
|
|
|
11527
11634
|
// src/components/SegmentedControl/SelectedItemIndicator.tsx
|
|
11528
|
-
var
|
|
11635
|
+
var import_styled_components71 = __toESM(require("styled-components"));
|
|
11529
11636
|
|
|
11530
11637
|
// src/components/SegmentedControl/useSegmentedControlValue.tsx
|
|
11531
|
-
var
|
|
11532
|
-
var SegmentedControlValueContext = (0,
|
|
11638
|
+
var import_react58 = require("react");
|
|
11639
|
+
var SegmentedControlValueContext = (0, import_react58.createContext)(null);
|
|
11533
11640
|
var SegmentedControlValueProvider = SegmentedControlValueContext.Provider;
|
|
11534
11641
|
var useSegmentedControlValue = () => {
|
|
11535
|
-
const context = (0,
|
|
11642
|
+
const context = (0, import_react58.useContext)(SegmentedControlValueContext);
|
|
11536
11643
|
if (context === null) {
|
|
11537
11644
|
throw new Error("useSegmentedControlValue must be used within a SegmentedControlValueProvider");
|
|
11538
11645
|
}
|
|
@@ -11540,8 +11647,8 @@ var useSegmentedControlValue = () => {
|
|
|
11540
11647
|
};
|
|
11541
11648
|
|
|
11542
11649
|
// src/components/SegmentedControl/SelectedItemIndicator.tsx
|
|
11543
|
-
var
|
|
11544
|
-
var SelectedItemIndicatorDiv =
|
|
11650
|
+
var import_jsx_runtime251 = require("react/jsx-runtime");
|
|
11651
|
+
var SelectedItemIndicatorDiv = import_styled_components71.default.div`
|
|
11545
11652
|
background-color: var(--wui-color-bg-fill-white);
|
|
11546
11653
|
border-radius: var(--wui-border-radius-rounded);
|
|
11547
11654
|
left: 0;
|
|
@@ -11559,12 +11666,12 @@ var SelectedItemIndicator = () => {
|
|
|
11559
11666
|
if (!selectedValue) {
|
|
11560
11667
|
return null;
|
|
11561
11668
|
}
|
|
11562
|
-
return /* @__PURE__ */ (0,
|
|
11669
|
+
return /* @__PURE__ */ (0, import_jsx_runtime251.jsx)(SelectedItemIndicatorDiv, { style: selectedItemIndicatorStyle });
|
|
11563
11670
|
};
|
|
11564
11671
|
|
|
11565
11672
|
// src/components/SegmentedControl/SegmentedControl.tsx
|
|
11566
|
-
var
|
|
11567
|
-
var segmentedControlStyles =
|
|
11673
|
+
var import_jsx_runtime252 = require("react/jsx-runtime");
|
|
11674
|
+
var segmentedControlStyles = import_styled_components72.css`
|
|
11568
11675
|
display: inline-flex;
|
|
11569
11676
|
background-color: var(--wui-color-bg-surface-secondary);
|
|
11570
11677
|
border-radius: var(--wui-border-radius-rounded);
|
|
@@ -11575,10 +11682,10 @@ var segmentedControlStyles = import_styled_components71.css`
|
|
|
11575
11682
|
position: relative;
|
|
11576
11683
|
width: ${({ $fullWidth }) => $fullWidth ? "100%" : "auto"};
|
|
11577
11684
|
`;
|
|
11578
|
-
var StyledSegmentedControl = (0,
|
|
11685
|
+
var StyledSegmentedControl = (0, import_styled_components72.default)(import_react_toggle_group.Root)`
|
|
11579
11686
|
${segmentedControlStyles}
|
|
11580
11687
|
`;
|
|
11581
|
-
var SegmentedControl = (0,
|
|
11688
|
+
var SegmentedControl = (0, import_react59.forwardRef)(
|
|
11582
11689
|
({
|
|
11583
11690
|
children,
|
|
11584
11691
|
disabled = false,
|
|
@@ -11590,7 +11697,7 @@ var SegmentedControl = (0, import_react58.forwardRef)(
|
|
|
11590
11697
|
if ((0, import_type_guards46.isNil)(children)) {
|
|
11591
11698
|
return null;
|
|
11592
11699
|
}
|
|
11593
|
-
return /* @__PURE__ */ (0,
|
|
11700
|
+
return /* @__PURE__ */ (0, import_jsx_runtime252.jsx)(
|
|
11594
11701
|
StyledSegmentedControl,
|
|
11595
11702
|
{
|
|
11596
11703
|
ref,
|
|
@@ -11602,8 +11709,8 @@ var SegmentedControl = (0, import_react58.forwardRef)(
|
|
|
11602
11709
|
type: "single",
|
|
11603
11710
|
value: selectedValue,
|
|
11604
11711
|
...props,
|
|
11605
|
-
children: /* @__PURE__ */ (0,
|
|
11606
|
-
/* @__PURE__ */ (0,
|
|
11712
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime252.jsx)(SegmentedControlValueProvider, { value: selectedValue, children: /* @__PURE__ */ (0, import_jsx_runtime252.jsxs)(SelectedItemStyleProvider, { children: [
|
|
11713
|
+
/* @__PURE__ */ (0, import_jsx_runtime252.jsx)(SelectedItemIndicator, {}),
|
|
11607
11714
|
children
|
|
11608
11715
|
] }) })
|
|
11609
11716
|
}
|
|
@@ -11613,12 +11720,12 @@ var SegmentedControl = (0, import_react58.forwardRef)(
|
|
|
11613
11720
|
SegmentedControl.displayName = "SegmentedControl";
|
|
11614
11721
|
|
|
11615
11722
|
// src/components/SegmentedControl/SegmentedControlItem.tsx
|
|
11616
|
-
var
|
|
11617
|
-
var
|
|
11723
|
+
var import_react60 = require("react");
|
|
11724
|
+
var import_styled_components73 = __toESM(require("styled-components"));
|
|
11618
11725
|
var import_react_toggle_group2 = require("@radix-ui/react-toggle-group");
|
|
11619
11726
|
var import_type_guards47 = require("@wistia/type-guards");
|
|
11620
|
-
var
|
|
11621
|
-
var segmentedControlItemStyles =
|
|
11727
|
+
var import_jsx_runtime253 = require("react/jsx-runtime");
|
|
11728
|
+
var segmentedControlItemStyles = import_styled_components73.css`
|
|
11622
11729
|
all: unset; /* ToggleGroupItem is a button element */
|
|
11623
11730
|
align-items: center;
|
|
11624
11731
|
border-radius: var(--wui-border-radius-rounded);
|
|
@@ -11678,14 +11785,14 @@ var segmentedControlItemStyles = import_styled_components72.css`
|
|
|
11678
11785
|
}
|
|
11679
11786
|
}
|
|
11680
11787
|
`;
|
|
11681
|
-
var StyledSegmentedControlItem = (0,
|
|
11788
|
+
var StyledSegmentedControlItem = (0, import_styled_components73.default)(import_react_toggle_group2.Item)`
|
|
11682
11789
|
${segmentedControlItemStyles}
|
|
11683
11790
|
`;
|
|
11684
|
-
var SegmentedControlItem = (0,
|
|
11791
|
+
var SegmentedControlItem = (0, import_react60.forwardRef)(
|
|
11685
11792
|
({ disabled, icon, label, "aria-label": ariaLabel, value }, forwardedRef) => {
|
|
11686
11793
|
const selectedValue = useSegmentedControlValue();
|
|
11687
11794
|
const { setSelectedItemMeasurements } = useSelectedItemStyle();
|
|
11688
|
-
const buttonRef = (0,
|
|
11795
|
+
const buttonRef = (0, import_react60.useRef)(null);
|
|
11689
11796
|
const combinedRef = mergeRefs([buttonRef, forwardedRef]);
|
|
11690
11797
|
const handleClick = (event) => {
|
|
11691
11798
|
const target = event.target;
|
|
@@ -11694,7 +11801,7 @@ var SegmentedControlItem = (0, import_react59.forwardRef)(
|
|
|
11694
11801
|
event.preventDefault();
|
|
11695
11802
|
}
|
|
11696
11803
|
};
|
|
11697
|
-
(0,
|
|
11804
|
+
(0, import_react60.useEffect)(() => {
|
|
11698
11805
|
const buttonElem = buttonRef.current;
|
|
11699
11806
|
if (!buttonElem) {
|
|
11700
11807
|
return void 0;
|
|
@@ -11719,7 +11826,7 @@ var SegmentedControlItem = (0, import_react59.forwardRef)(
|
|
|
11719
11826
|
resizeObserver.disconnect();
|
|
11720
11827
|
};
|
|
11721
11828
|
}, [selectedValue, setSelectedItemMeasurements, value]);
|
|
11722
|
-
return /* @__PURE__ */ (0,
|
|
11829
|
+
return /* @__PURE__ */ (0, import_jsx_runtime253.jsxs)(
|
|
11723
11830
|
StyledSegmentedControlItem,
|
|
11724
11831
|
{
|
|
11725
11832
|
ref: combinedRef,
|
|
@@ -11740,10 +11847,10 @@ SegmentedControlItem.displayName = "SegmentedControlItem";
|
|
|
11740
11847
|
|
|
11741
11848
|
// src/components/Select/Select.tsx
|
|
11742
11849
|
var import_react_select = require("@radix-ui/react-select");
|
|
11743
|
-
var
|
|
11744
|
-
var
|
|
11745
|
-
var
|
|
11746
|
-
var StyledTrigger = (0,
|
|
11850
|
+
var import_react61 = require("react");
|
|
11851
|
+
var import_styled_components74 = __toESM(require("styled-components"));
|
|
11852
|
+
var import_jsx_runtime254 = require("react/jsx-runtime");
|
|
11853
|
+
var StyledTrigger = (0, import_styled_components74.default)(import_react_select.Trigger)`
|
|
11747
11854
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
11748
11855
|
${inputCssVariables};
|
|
11749
11856
|
padding: var(--wui-input-vertical-padding) var(--wui-input-horizontal-padding);
|
|
@@ -11787,7 +11894,7 @@ var StyledTrigger = (0, import_styled_components73.default)(import_react_select.
|
|
|
11787
11894
|
color: var(--wui-input-placeholder);
|
|
11788
11895
|
}
|
|
11789
11896
|
`;
|
|
11790
|
-
var StyledContent3 = (0,
|
|
11897
|
+
var StyledContent3 = (0, import_styled_components74.default)(import_react_select.Content)`
|
|
11791
11898
|
--wui-select-content-border: var(--wui-color-border);
|
|
11792
11899
|
--wui-select-content-bg: var(--wui-color-bg-surface);
|
|
11793
11900
|
--wui-select-content-border-radius: var(--wui-border-radius-02);
|
|
@@ -11805,7 +11912,7 @@ var StyledContent3 = (0, import_styled_components73.default)(import_react_select
|
|
|
11805
11912
|
max-height: var(--radix-select-content-available-height);
|
|
11806
11913
|
z-index: var(--wui-zindex-select);
|
|
11807
11914
|
`;
|
|
11808
|
-
var Select = (0,
|
|
11915
|
+
var Select = (0, import_react61.forwardRef)(
|
|
11809
11916
|
({
|
|
11810
11917
|
colorScheme = "inherit",
|
|
11811
11918
|
children,
|
|
@@ -11815,13 +11922,13 @@ var Select = (0, import_react60.forwardRef)(
|
|
|
11815
11922
|
...props
|
|
11816
11923
|
}, forwardedRef) => {
|
|
11817
11924
|
const responsiveFullWidth = useResponsiveProp(fullWidth);
|
|
11818
|
-
return /* @__PURE__ */ (0,
|
|
11925
|
+
return /* @__PURE__ */ (0, import_jsx_runtime254.jsxs)(
|
|
11819
11926
|
import_react_select.Root,
|
|
11820
11927
|
{
|
|
11821
11928
|
...props,
|
|
11822
11929
|
onValueChange: onChange,
|
|
11823
11930
|
children: [
|
|
11824
|
-
/* @__PURE__ */ (0,
|
|
11931
|
+
/* @__PURE__ */ (0, import_jsx_runtime254.jsxs)(
|
|
11825
11932
|
StyledTrigger,
|
|
11826
11933
|
{
|
|
11827
11934
|
ref: forwardedRef,
|
|
@@ -11829,8 +11936,8 @@ var Select = (0, import_react60.forwardRef)(
|
|
|
11829
11936
|
$fullWidth: responsiveFullWidth,
|
|
11830
11937
|
...props,
|
|
11831
11938
|
children: [
|
|
11832
|
-
/* @__PURE__ */ (0,
|
|
11833
|
-
/* @__PURE__ */ (0,
|
|
11939
|
+
/* @__PURE__ */ (0, import_jsx_runtime254.jsx)(import_react_select.Value, { placeholder }),
|
|
11940
|
+
/* @__PURE__ */ (0, import_jsx_runtime254.jsx)(
|
|
11834
11941
|
Icon,
|
|
11835
11942
|
{
|
|
11836
11943
|
size: "md",
|
|
@@ -11840,10 +11947,10 @@ var Select = (0, import_react60.forwardRef)(
|
|
|
11840
11947
|
]
|
|
11841
11948
|
}
|
|
11842
11949
|
),
|
|
11843
|
-
/* @__PURE__ */ (0,
|
|
11844
|
-
/* @__PURE__ */ (0,
|
|
11845
|
-
/* @__PURE__ */ (0,
|
|
11846
|
-
/* @__PURE__ */ (0,
|
|
11950
|
+
/* @__PURE__ */ (0, import_jsx_runtime254.jsx)(import_react_select.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime254.jsxs)(StyledContent3, { position: "popper", children: [
|
|
11951
|
+
/* @__PURE__ */ (0, import_jsx_runtime254.jsx)(import_react_select.ScrollUpButton, { children: /* @__PURE__ */ (0, import_jsx_runtime254.jsx)(Icon, { type: "caret-up" }) }),
|
|
11952
|
+
/* @__PURE__ */ (0, import_jsx_runtime254.jsx)(import_react_select.Viewport, { children }),
|
|
11953
|
+
/* @__PURE__ */ (0, import_jsx_runtime254.jsx)(import_react_select.ScrollDownButton, { children: /* @__PURE__ */ (0, import_jsx_runtime254.jsx)(Icon, { type: "caret-down" }) })
|
|
11847
11954
|
] }) })
|
|
11848
11955
|
]
|
|
11849
11956
|
}
|
|
@@ -11854,11 +11961,11 @@ Select.displayName = "Select";
|
|
|
11854
11961
|
|
|
11855
11962
|
// src/components/Select/SelectOption.tsx
|
|
11856
11963
|
var import_react_select2 = require("@radix-ui/react-select");
|
|
11857
|
-
var
|
|
11858
|
-
var
|
|
11964
|
+
var import_react62 = require("react");
|
|
11965
|
+
var import_styled_components75 = __toESM(require("styled-components"));
|
|
11859
11966
|
var import_type_guards48 = require("@wistia/type-guards");
|
|
11860
|
-
var
|
|
11861
|
-
var StyledItem = (0,
|
|
11967
|
+
var import_jsx_runtime255 = require("react/jsx-runtime");
|
|
11968
|
+
var StyledItem = (0, import_styled_components75.default)(import_react_select2.Item)`
|
|
11862
11969
|
${variantStyleMap2.body3};
|
|
11863
11970
|
display: flex;
|
|
11864
11971
|
padding: var(--wui-select-option-padding);
|
|
@@ -11882,28 +11989,28 @@ var StyledItem = (0, import_styled_components74.default)(import_react_select2.It
|
|
|
11882
11989
|
background-color: transparent;
|
|
11883
11990
|
}
|
|
11884
11991
|
`;
|
|
11885
|
-
var StyledIconContainer =
|
|
11992
|
+
var StyledIconContainer = import_styled_components75.default.span`
|
|
11886
11993
|
width: 12px;
|
|
11887
11994
|
`;
|
|
11888
|
-
var SelectOption = (0,
|
|
11995
|
+
var SelectOption = (0, import_react62.forwardRef)(
|
|
11889
11996
|
({ children, selectedDisplayValue, ...props }, forwardedRef) => {
|
|
11890
|
-
return /* @__PURE__ */ (0,
|
|
11997
|
+
return /* @__PURE__ */ (0, import_jsx_runtime255.jsxs)(
|
|
11891
11998
|
StyledItem,
|
|
11892
11999
|
{
|
|
11893
12000
|
...props,
|
|
11894
12001
|
ref: forwardedRef,
|
|
11895
12002
|
children: [
|
|
11896
|
-
/* @__PURE__ */ (0,
|
|
12003
|
+
/* @__PURE__ */ (0, import_jsx_runtime255.jsx)(StyledIconContainer, { "data-indicator": true, children: /* @__PURE__ */ (0, import_jsx_runtime255.jsx)(import_react_select2.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime255.jsx)(
|
|
11897
12004
|
Icon,
|
|
11898
12005
|
{
|
|
11899
12006
|
size: "sm",
|
|
11900
12007
|
type: "checkmark"
|
|
11901
12008
|
}
|
|
11902
12009
|
) }) }),
|
|
11903
|
-
(0, import_type_guards48.isNotNil)(selectedDisplayValue) ? /* @__PURE__ */ (0,
|
|
12010
|
+
(0, import_type_guards48.isNotNil)(selectedDisplayValue) ? /* @__PURE__ */ (0, import_jsx_runtime255.jsxs)("div", { children: [
|
|
11904
12011
|
children,
|
|
11905
|
-
/* @__PURE__ */ (0,
|
|
11906
|
-
] }) : /* @__PURE__ */ (0,
|
|
12012
|
+
/* @__PURE__ */ (0, import_jsx_runtime255.jsx)("div", { style: { display: "none" }, children: /* @__PURE__ */ (0, import_jsx_runtime255.jsx)(import_react_select2.ItemText, { children: selectedDisplayValue }) })
|
|
12013
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime255.jsx)(import_react_select2.ItemText, { children })
|
|
11907
12014
|
]
|
|
11908
12015
|
}
|
|
11909
12016
|
);
|
|
@@ -11913,14 +12020,14 @@ SelectOption.displayName = "SelectOption";
|
|
|
11913
12020
|
|
|
11914
12021
|
// src/components/Select/SelectOptionGroup.tsx
|
|
11915
12022
|
var import_react_select3 = require("@radix-ui/react-select");
|
|
11916
|
-
var
|
|
11917
|
-
var
|
|
11918
|
-
var StyledLabel4 = (0,
|
|
12023
|
+
var import_styled_components76 = __toESM(require("styled-components"));
|
|
12024
|
+
var import_jsx_runtime256 = require("react/jsx-runtime");
|
|
12025
|
+
var StyledLabel4 = (0, import_styled_components76.default)(import_react_select3.Label)`
|
|
11919
12026
|
padding: var(--wui-select-option-padding);
|
|
11920
12027
|
`;
|
|
11921
12028
|
var SelectOptionGroup = ({ children, label, ...props }) => {
|
|
11922
|
-
return /* @__PURE__ */ (0,
|
|
11923
|
-
/* @__PURE__ */ (0,
|
|
12029
|
+
return /* @__PURE__ */ (0, import_jsx_runtime256.jsxs)(import_react_select3.Group, { ...props, children: [
|
|
12030
|
+
/* @__PURE__ */ (0, import_jsx_runtime256.jsx)(StyledLabel4, { children: /* @__PURE__ */ (0, import_jsx_runtime256.jsx)(
|
|
11924
12031
|
Text,
|
|
11925
12032
|
{
|
|
11926
12033
|
prominence: "secondary",
|
|
@@ -11933,11 +12040,11 @@ var SelectOptionGroup = ({ children, label, ...props }) => {
|
|
|
11933
12040
|
};
|
|
11934
12041
|
|
|
11935
12042
|
// src/components/Switch/Switch.tsx
|
|
11936
|
-
var
|
|
11937
|
-
var
|
|
12043
|
+
var import_react63 = require("react");
|
|
12044
|
+
var import_styled_components77 = __toESM(require("styled-components"));
|
|
11938
12045
|
var import_type_guards49 = require("@wistia/type-guards");
|
|
11939
|
-
var
|
|
11940
|
-
var sizeSmall3 =
|
|
12046
|
+
var import_jsx_runtime257 = require("react/jsx-runtime");
|
|
12047
|
+
var sizeSmall3 = import_styled_components77.css`
|
|
11941
12048
|
--wui-size-small-width: 24px;
|
|
11942
12049
|
--wui-size-small-height: 14px;
|
|
11943
12050
|
|
|
@@ -11952,7 +12059,7 @@ var sizeSmall3 = import_styled_components76.css`
|
|
|
11952
12059
|
height: calc(var(--wui-size-small-width) / 2);
|
|
11953
12060
|
}
|
|
11954
12061
|
`;
|
|
11955
|
-
var sizeMedium3 =
|
|
12062
|
+
var sizeMedium3 = import_styled_components77.css`
|
|
11956
12063
|
--wui-size-medium-width: 32px;
|
|
11957
12064
|
--wui-size-medium-height: 18px;
|
|
11958
12065
|
|
|
@@ -11967,7 +12074,7 @@ var sizeMedium3 = import_styled_components76.css`
|
|
|
11967
12074
|
height: calc(var(--wui-size-medium-width) / 2);
|
|
11968
12075
|
}
|
|
11969
12076
|
`;
|
|
11970
|
-
var sizeLarge3 =
|
|
12077
|
+
var sizeLarge3 = import_styled_components77.css`
|
|
11971
12078
|
--wui-size-large-width: 40px;
|
|
11972
12079
|
--wui-size-large-height: 22px;
|
|
11973
12080
|
|
|
@@ -11987,14 +12094,14 @@ var getSizeCss3 = (size) => {
|
|
|
11987
12094
|
if (size === "lg") return sizeLarge3;
|
|
11988
12095
|
return sizeMedium3;
|
|
11989
12096
|
};
|
|
11990
|
-
var StyledSwitchWrapper =
|
|
12097
|
+
var StyledSwitchWrapper = import_styled_components77.default.div`
|
|
11991
12098
|
display: flex;
|
|
11992
12099
|
margin: 0;
|
|
11993
12100
|
|
|
11994
12101
|
/* TODO this solves a problem but potentially causes and a11y issue */
|
|
11995
12102
|
user-select: none;
|
|
11996
12103
|
`;
|
|
11997
|
-
var StyledSwitchInput =
|
|
12104
|
+
var StyledSwitchInput = import_styled_components77.default.div`
|
|
11998
12105
|
${({ $size }) => getSizeCss3($size)}
|
|
11999
12106
|
line-height: 0;
|
|
12000
12107
|
margin: 0;
|
|
@@ -12022,7 +12129,7 @@ var StyledSwitchInput = import_styled_components76.default.div`
|
|
|
12022
12129
|
transition: all 0.2s ease-in-out;
|
|
12023
12130
|
}
|
|
12024
12131
|
`;
|
|
12025
|
-
var StyledHiddenSwitchInput =
|
|
12132
|
+
var StyledHiddenSwitchInput = import_styled_components77.default.input`
|
|
12026
12133
|
${visuallyHiddenStyle}
|
|
12027
12134
|
|
|
12028
12135
|
/* toggles display of faux-input background-color and toggle position */
|
|
@@ -12038,7 +12145,7 @@ var StyledHiddenSwitchInput = import_styled_components76.default.input`
|
|
|
12038
12145
|
}
|
|
12039
12146
|
}
|
|
12040
12147
|
`;
|
|
12041
|
-
var Switch = (0,
|
|
12148
|
+
var Switch = (0, import_react63.forwardRef)(
|
|
12042
12149
|
({
|
|
12043
12150
|
checked,
|
|
12044
12151
|
disabled = false,
|
|
@@ -12053,10 +12160,10 @@ var Switch = (0, import_react62.forwardRef)(
|
|
|
12053
12160
|
hideLabel = false,
|
|
12054
12161
|
...props
|
|
12055
12162
|
}, ref) => {
|
|
12056
|
-
const generatedId = (0,
|
|
12163
|
+
const generatedId = (0, import_react63.useId)();
|
|
12057
12164
|
const computedId = (0, import_type_guards49.isNonEmptyString)(id) ? id : `wistia-ui-switch-${generatedId}`;
|
|
12058
|
-
return /* @__PURE__ */ (0,
|
|
12059
|
-
/* @__PURE__ */ (0,
|
|
12165
|
+
return /* @__PURE__ */ (0, import_jsx_runtime257.jsxs)(StyledSwitchWrapper, { $disabled: disabled, children: [
|
|
12166
|
+
/* @__PURE__ */ (0, import_jsx_runtime257.jsx)(
|
|
12060
12167
|
StyledHiddenSwitchInput,
|
|
12061
12168
|
{
|
|
12062
12169
|
...props,
|
|
@@ -12071,10 +12178,10 @@ var Switch = (0, import_react62.forwardRef)(
|
|
|
12071
12178
|
value
|
|
12072
12179
|
}
|
|
12073
12180
|
),
|
|
12074
|
-
/* @__PURE__ */ (0,
|
|
12181
|
+
/* @__PURE__ */ (0, import_jsx_runtime257.jsx)(
|
|
12075
12182
|
FormControlLabel,
|
|
12076
12183
|
{
|
|
12077
|
-
controlSlot: /* @__PURE__ */ (0,
|
|
12184
|
+
controlSlot: /* @__PURE__ */ (0, import_jsx_runtime257.jsx)(
|
|
12078
12185
|
StyledSwitchInput,
|
|
12079
12186
|
{
|
|
12080
12187
|
$disabled: disabled,
|
|
@@ -12096,25 +12203,25 @@ var Switch = (0, import_react62.forwardRef)(
|
|
|
12096
12203
|
Switch.displayName = "Switch";
|
|
12097
12204
|
|
|
12098
12205
|
// src/components/Table/Table.tsx
|
|
12099
|
-
var
|
|
12100
|
-
var
|
|
12101
|
-
var StyledTable =
|
|
12206
|
+
var import_styled_components78 = __toESM(require("styled-components"));
|
|
12207
|
+
var import_jsx_runtime258 = require("react/jsx-runtime");
|
|
12208
|
+
var StyledTable = import_styled_components78.default.table`
|
|
12102
12209
|
width: 100%;
|
|
12103
12210
|
border-collapse: collapse;
|
|
12104
12211
|
|
|
12105
|
-
${({ $divided }) => $divided &&
|
|
12212
|
+
${({ $divided }) => $divided && import_styled_components78.css`
|
|
12106
12213
|
tr {
|
|
12107
12214
|
border-bottom: 1px solid var(--wui-color-border);
|
|
12108
12215
|
}
|
|
12109
12216
|
`}
|
|
12110
12217
|
|
|
12111
|
-
${({ $striped }) => $striped &&
|
|
12218
|
+
${({ $striped }) => $striped && import_styled_components78.css`
|
|
12112
12219
|
tbody tr:nth-child(even) {
|
|
12113
12220
|
background-color: var(--wui-color-bg-surface-secondary);
|
|
12114
12221
|
}
|
|
12115
12222
|
`}
|
|
12116
12223
|
|
|
12117
|
-
${({ $visuallyHiddenHeader }) => $visuallyHiddenHeader &&
|
|
12224
|
+
${({ $visuallyHiddenHeader }) => $visuallyHiddenHeader && import_styled_components78.css`
|
|
12118
12225
|
thead {
|
|
12119
12226
|
${visuallyHiddenStyle}
|
|
12120
12227
|
}
|
|
@@ -12127,7 +12234,7 @@ var Table = ({
|
|
|
12127
12234
|
visuallyHiddenHeader = false,
|
|
12128
12235
|
...props
|
|
12129
12236
|
}) => {
|
|
12130
|
-
return /* @__PURE__ */ (0,
|
|
12237
|
+
return /* @__PURE__ */ (0, import_jsx_runtime258.jsx)(
|
|
12131
12238
|
StyledTable,
|
|
12132
12239
|
{
|
|
12133
12240
|
$divided: divided,
|
|
@@ -12140,88 +12247,88 @@ var Table = ({
|
|
|
12140
12247
|
};
|
|
12141
12248
|
|
|
12142
12249
|
// src/components/Table/TableBody.tsx
|
|
12143
|
-
var
|
|
12250
|
+
var import_styled_components79 = __toESM(require("styled-components"));
|
|
12144
12251
|
|
|
12145
12252
|
// src/components/Table/TableSectionContext.ts
|
|
12146
|
-
var
|
|
12147
|
-
var TableSectionContext = (0,
|
|
12253
|
+
var import_react64 = require("react");
|
|
12254
|
+
var TableSectionContext = (0, import_react64.createContext)(null);
|
|
12148
12255
|
|
|
12149
12256
|
// src/components/Table/TableBody.tsx
|
|
12150
|
-
var
|
|
12151
|
-
var StyledTableBody =
|
|
12257
|
+
var import_jsx_runtime259 = require("react/jsx-runtime");
|
|
12258
|
+
var StyledTableBody = import_styled_components79.default.tbody``;
|
|
12152
12259
|
var TableBody = ({ children, ...props }) => {
|
|
12153
|
-
return /* @__PURE__ */ (0,
|
|
12260
|
+
return /* @__PURE__ */ (0, import_jsx_runtime259.jsx)(TableSectionContext.Provider, { value: "body", children: /* @__PURE__ */ (0, import_jsx_runtime259.jsx)(StyledTableBody, { ...props, children }) });
|
|
12154
12261
|
};
|
|
12155
12262
|
|
|
12156
12263
|
// src/components/Table/TableCell.tsx
|
|
12157
|
-
var
|
|
12158
|
-
var
|
|
12159
|
-
var
|
|
12160
|
-
var sharedStyles =
|
|
12264
|
+
var import_react65 = require("react");
|
|
12265
|
+
var import_styled_components80 = __toESM(require("styled-components"));
|
|
12266
|
+
var import_jsx_runtime260 = require("react/jsx-runtime");
|
|
12267
|
+
var sharedStyles = import_styled_components80.css`
|
|
12161
12268
|
color: var(--wui-color-text);
|
|
12162
12269
|
padding: var(--wui-space-02);
|
|
12163
12270
|
text-align: left;
|
|
12164
12271
|
`;
|
|
12165
|
-
var StyledTh =
|
|
12272
|
+
var StyledTh = import_styled_components80.default.th`
|
|
12166
12273
|
${sharedStyles}
|
|
12167
12274
|
font-size: var(--wui-typography-body-4-size);
|
|
12168
12275
|
font-weight: var(--wui-typography-weight-label-bold);
|
|
12169
12276
|
line-height: var(--wui-typography-body-4-line-height);
|
|
12170
12277
|
`;
|
|
12171
|
-
var StyledTd =
|
|
12278
|
+
var StyledTd = import_styled_components80.default.td`
|
|
12172
12279
|
${sharedStyles}
|
|
12173
12280
|
font-size: var(--wui-typography-body-2-size);
|
|
12174
12281
|
font-weight: var(--wui-typography-body-2-weight);
|
|
12175
12282
|
line-height: var(--wui-typography-body-2-line-height);
|
|
12176
12283
|
`;
|
|
12177
12284
|
var TableCell = ({ children, ...props }) => {
|
|
12178
|
-
const section = (0,
|
|
12285
|
+
const section = (0, import_react65.useContext)(TableSectionContext);
|
|
12179
12286
|
if (section === "head") {
|
|
12180
|
-
return /* @__PURE__ */ (0,
|
|
12287
|
+
return /* @__PURE__ */ (0, import_jsx_runtime260.jsx)(StyledTh, { ...props, children });
|
|
12181
12288
|
}
|
|
12182
|
-
return /* @__PURE__ */ (0,
|
|
12289
|
+
return /* @__PURE__ */ (0, import_jsx_runtime260.jsx)(StyledTd, { ...props, children });
|
|
12183
12290
|
};
|
|
12184
12291
|
|
|
12185
12292
|
// src/components/Table/TableFoot.tsx
|
|
12186
|
-
var
|
|
12187
|
-
var
|
|
12188
|
-
var StyledTableFoot =
|
|
12293
|
+
var import_styled_components81 = __toESM(require("styled-components"));
|
|
12294
|
+
var import_jsx_runtime261 = require("react/jsx-runtime");
|
|
12295
|
+
var StyledTableFoot = import_styled_components81.default.tfoot``;
|
|
12189
12296
|
var TableFoot = ({ children, ...props }) => {
|
|
12190
|
-
return /* @__PURE__ */ (0,
|
|
12297
|
+
return /* @__PURE__ */ (0, import_jsx_runtime261.jsx)(TableSectionContext.Provider, { value: "footer", children: /* @__PURE__ */ (0, import_jsx_runtime261.jsx)(StyledTableFoot, { ...props, children }) });
|
|
12191
12298
|
};
|
|
12192
12299
|
|
|
12193
12300
|
// src/components/Table/TableHead.tsx
|
|
12194
|
-
var
|
|
12195
|
-
var
|
|
12196
|
-
var StyledThead =
|
|
12301
|
+
var import_styled_components82 = __toESM(require("styled-components"));
|
|
12302
|
+
var import_jsx_runtime262 = require("react/jsx-runtime");
|
|
12303
|
+
var StyledThead = import_styled_components82.default.thead``;
|
|
12197
12304
|
var TableHead = ({ children, ...props }) => {
|
|
12198
|
-
return /* @__PURE__ */ (0,
|
|
12305
|
+
return /* @__PURE__ */ (0, import_jsx_runtime262.jsx)(TableSectionContext.Provider, { value: "head", children: /* @__PURE__ */ (0, import_jsx_runtime262.jsx)(StyledThead, { ...props, children }) });
|
|
12199
12306
|
};
|
|
12200
12307
|
|
|
12201
12308
|
// src/components/Table/TableRow.tsx
|
|
12202
|
-
var
|
|
12203
|
-
var
|
|
12204
|
-
var StyledTableRow =
|
|
12309
|
+
var import_styled_components83 = __toESM(require("styled-components"));
|
|
12310
|
+
var import_jsx_runtime263 = require("react/jsx-runtime");
|
|
12311
|
+
var StyledTableRow = import_styled_components83.default.tr``;
|
|
12205
12312
|
var TableRow = ({ children, ...props }) => {
|
|
12206
|
-
return /* @__PURE__ */ (0,
|
|
12313
|
+
return /* @__PURE__ */ (0, import_jsx_runtime263.jsx)(StyledTableRow, { ...props, children });
|
|
12207
12314
|
};
|
|
12208
12315
|
|
|
12209
12316
|
// src/components/Tabs/Tabs.tsx
|
|
12210
|
-
var
|
|
12317
|
+
var import_react69 = require("react");
|
|
12211
12318
|
var import_react_tabs4 = require("@radix-ui/react-tabs");
|
|
12212
12319
|
var import_type_guards51 = require("@wistia/type-guards");
|
|
12213
|
-
var
|
|
12320
|
+
var import_styled_components88 = __toESM(require("styled-components"));
|
|
12214
12321
|
|
|
12215
12322
|
// src/components/Tabs/TabPanel.tsx
|
|
12216
|
-
var
|
|
12323
|
+
var import_styled_components84 = __toESM(require("styled-components"));
|
|
12217
12324
|
var import_react_tabs = require("@radix-ui/react-tabs");
|
|
12218
|
-
var
|
|
12219
|
-
var StyledTabPanel = (0,
|
|
12325
|
+
var import_jsx_runtime264 = require("react/jsx-runtime");
|
|
12326
|
+
var StyledTabPanel = (0, import_styled_components84.default)(import_react_tabs.Content)`
|
|
12220
12327
|
display: flex;
|
|
12221
12328
|
flex-direction: column;
|
|
12222
12329
|
`;
|
|
12223
12330
|
var TabPanel = ({ children, value, ...props }) => {
|
|
12224
|
-
return /* @__PURE__ */ (0,
|
|
12331
|
+
return /* @__PURE__ */ (0, import_jsx_runtime264.jsx)(
|
|
12225
12332
|
StyledTabPanel,
|
|
12226
12333
|
{
|
|
12227
12334
|
value,
|
|
@@ -12233,10 +12340,10 @@ var TabPanel = ({ children, value, ...props }) => {
|
|
|
12233
12340
|
TabPanel.displayName = "TabPanel";
|
|
12234
12341
|
|
|
12235
12342
|
// src/components/Tabs/TabList.tsx
|
|
12236
|
-
var
|
|
12343
|
+
var import_styled_components85 = __toESM(require("styled-components"));
|
|
12237
12344
|
var import_react_tabs2 = require("@radix-ui/react-tabs");
|
|
12238
|
-
var
|
|
12239
|
-
var StyledTabList = (0,
|
|
12345
|
+
var import_jsx_runtime265 = require("react/jsx-runtime");
|
|
12346
|
+
var StyledTabList = (0, import_styled_components85.default)(import_react_tabs2.List)`
|
|
12240
12347
|
${segmentedControlStyles}
|
|
12241
12348
|
|
|
12242
12349
|
margin-bottom: var(--wui-space-04);
|
|
@@ -12249,7 +12356,7 @@ var TabList = ({
|
|
|
12249
12356
|
ariaLabel,
|
|
12250
12357
|
...props
|
|
12251
12358
|
}) => {
|
|
12252
|
-
return /* @__PURE__ */ (0,
|
|
12359
|
+
return /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(
|
|
12253
12360
|
StyledTabList,
|
|
12254
12361
|
{
|
|
12255
12362
|
$fullWidth: fullWidth,
|
|
@@ -12262,17 +12369,17 @@ var TabList = ({
|
|
|
12262
12369
|
TabList.displayName = "TabList";
|
|
12263
12370
|
|
|
12264
12371
|
// src/components/Tabs/TabItem.tsx
|
|
12265
|
-
var
|
|
12266
|
-
var
|
|
12372
|
+
var import_react67 = require("react");
|
|
12373
|
+
var import_styled_components86 = __toESM(require("styled-components"));
|
|
12267
12374
|
var import_react_tabs3 = require("@radix-ui/react-tabs");
|
|
12268
12375
|
var import_type_guards50 = require("@wistia/type-guards");
|
|
12269
12376
|
|
|
12270
12377
|
// src/components/Tabs/useTabsValue.tsx
|
|
12271
|
-
var
|
|
12272
|
-
var TabsValueContext = (0,
|
|
12378
|
+
var import_react66 = require("react");
|
|
12379
|
+
var TabsValueContext = (0, import_react66.createContext)(null);
|
|
12273
12380
|
var TabsValueProvider = TabsValueContext.Provider;
|
|
12274
12381
|
var useTabsValue = () => {
|
|
12275
|
-
const context = (0,
|
|
12382
|
+
const context = (0, import_react66.useContext)(TabsValueContext);
|
|
12276
12383
|
if (context === null) {
|
|
12277
12384
|
throw new Error("useTabsValue must be used within a TabsValueProvider");
|
|
12278
12385
|
}
|
|
@@ -12280,21 +12387,21 @@ var useTabsValue = () => {
|
|
|
12280
12387
|
};
|
|
12281
12388
|
|
|
12282
12389
|
// src/components/Tabs/TabItem.tsx
|
|
12283
|
-
var
|
|
12284
|
-
var StyledTabItem = (0,
|
|
12390
|
+
var import_jsx_runtime266 = require("react/jsx-runtime");
|
|
12391
|
+
var StyledTabItem = (0, import_styled_components86.default)(import_react_tabs3.Trigger)`
|
|
12285
12392
|
${segmentedControlItemStyles}
|
|
12286
12393
|
|
|
12287
12394
|
&:focus-visible {
|
|
12288
12395
|
outline: none;
|
|
12289
12396
|
}
|
|
12290
12397
|
`;
|
|
12291
|
-
var TabItem = (0,
|
|
12398
|
+
var TabItem = (0, import_react67.forwardRef)(
|
|
12292
12399
|
({ disabled = false, icon, label, "aria-label": ariaLabel, value }, forwardedRef) => {
|
|
12293
12400
|
const selectedValue = useTabsValue();
|
|
12294
12401
|
const { setSelectedItemMeasurements } = useSelectedItemStyle();
|
|
12295
|
-
const buttonRef = (0,
|
|
12402
|
+
const buttonRef = (0, import_react67.useRef)(null);
|
|
12296
12403
|
const combinedRef = mergeRefs([buttonRef, forwardedRef]);
|
|
12297
|
-
(0,
|
|
12404
|
+
(0, import_react67.useEffect)(() => {
|
|
12298
12405
|
const buttonElem = buttonRef.current;
|
|
12299
12406
|
if (!buttonElem) {
|
|
12300
12407
|
return void 0;
|
|
@@ -12319,7 +12426,7 @@ var TabItem = (0, import_react66.forwardRef)(
|
|
|
12319
12426
|
resizeObserver.disconnect();
|
|
12320
12427
|
};
|
|
12321
12428
|
}, [selectedValue, setSelectedItemMeasurements, value]);
|
|
12322
|
-
return /* @__PURE__ */ (0,
|
|
12429
|
+
return /* @__PURE__ */ (0, import_jsx_runtime266.jsxs)(
|
|
12323
12430
|
StyledTabItem,
|
|
12324
12431
|
{
|
|
12325
12432
|
ref: combinedRef,
|
|
@@ -12338,16 +12445,16 @@ var TabItem = (0, import_react66.forwardRef)(
|
|
|
12338
12445
|
TabItem.displayName = "TabItem";
|
|
12339
12446
|
|
|
12340
12447
|
// src/components/Tabs/extractTabItems.ts
|
|
12341
|
-
var
|
|
12448
|
+
var import_react68 = require("react");
|
|
12342
12449
|
var extractTabItems = (children) => {
|
|
12343
12450
|
const tabItems = [];
|
|
12344
|
-
|
|
12345
|
-
if (!(0,
|
|
12451
|
+
import_react68.Children.forEach(children, (child) => {
|
|
12452
|
+
if (!(0, import_react68.isValidElement)(child)) {
|
|
12346
12453
|
return;
|
|
12347
12454
|
}
|
|
12348
12455
|
if (typeof child.type !== "string" && child.type.displayName === "Tab") {
|
|
12349
12456
|
tabItems.push(child);
|
|
12350
|
-
} else if (child.type ===
|
|
12457
|
+
} else if (child.type === import_react68.Fragment) {
|
|
12351
12458
|
const fragmentElement = child;
|
|
12352
12459
|
tabItems.push(...extractTabItems(fragmentElement.props.children));
|
|
12353
12460
|
} else if ((child.props.children ?? null) != null) {
|
|
@@ -12360,9 +12467,9 @@ var extractTabItems = (children) => {
|
|
|
12360
12467
|
};
|
|
12361
12468
|
|
|
12362
12469
|
// src/components/Tabs/SelectedItemIndicator.tsx
|
|
12363
|
-
var
|
|
12364
|
-
var
|
|
12365
|
-
var TabsSelectedItemIndicatorDiv = (0,
|
|
12470
|
+
var import_styled_components87 = __toESM(require("styled-components"));
|
|
12471
|
+
var import_jsx_runtime267 = require("react/jsx-runtime");
|
|
12472
|
+
var TabsSelectedItemIndicatorDiv = (0, import_styled_components87.default)(SelectedItemIndicatorDiv)`
|
|
12366
12473
|
&:has(~ ${StyledTabItem}:focus-visible) {
|
|
12367
12474
|
outline: 2px solid var(--wui-color-focus-ring);
|
|
12368
12475
|
}
|
|
@@ -12373,28 +12480,28 @@ var SelectedItemIndicator2 = () => {
|
|
|
12373
12480
|
if (selectedValue == null) {
|
|
12374
12481
|
return null;
|
|
12375
12482
|
}
|
|
12376
|
-
return /* @__PURE__ */ (0,
|
|
12483
|
+
return /* @__PURE__ */ (0, import_jsx_runtime267.jsx)(TabsSelectedItemIndicatorDiv, { style: selectedItemIndicatorStyle });
|
|
12377
12484
|
};
|
|
12378
12485
|
|
|
12379
12486
|
// src/components/Tabs/Tabs.tsx
|
|
12380
|
-
var
|
|
12381
|
-
var TabsContainer =
|
|
12487
|
+
var import_jsx_runtime268 = require("react/jsx-runtime");
|
|
12488
|
+
var TabsContainer = import_styled_components88.default.div`
|
|
12382
12489
|
display: flex;
|
|
12383
12490
|
flex-direction: column;
|
|
12384
12491
|
height: ${({ $stickyHeaders }) => $stickyHeaders ? "100%" : "auto"};
|
|
12385
12492
|
overflow: ${({ $stickyHeaders }) => $stickyHeaders ? "hidden" : "visible"};
|
|
12386
12493
|
`;
|
|
12387
|
-
var StickyTabContent =
|
|
12494
|
+
var StickyTabContent = import_styled_components88.default.div`
|
|
12388
12495
|
flex: ${({ $stickyHeaders }) => $stickyHeaders ? "1" : "initial"};
|
|
12389
12496
|
overflow-y: ${({ $stickyHeaders }) => $stickyHeaders ? "auto" : "visible"};
|
|
12390
12497
|
overflow-x: ${({ $stickyHeaders }) => $stickyHeaders ? "hidden" : "visible"};
|
|
12391
12498
|
`;
|
|
12392
|
-
var StyledTabsRoot = (0,
|
|
12499
|
+
var StyledTabsRoot = (0, import_styled_components88.default)(import_react_tabs4.Root)`
|
|
12393
12500
|
display: flex;
|
|
12394
12501
|
flex-direction: column;
|
|
12395
12502
|
height: ${({ $stickyHeaders }) => $stickyHeaders ? "100%" : "auto"};
|
|
12396
12503
|
`;
|
|
12397
|
-
var Tabs = (0,
|
|
12504
|
+
var Tabs = (0, import_react69.forwardRef)(
|
|
12398
12505
|
({
|
|
12399
12506
|
children,
|
|
12400
12507
|
fullWidth = true,
|
|
@@ -12406,13 +12513,13 @@ var Tabs = (0, import_react68.forwardRef)(
|
|
|
12406
12513
|
...props
|
|
12407
12514
|
}, ref) => {
|
|
12408
12515
|
const tabItems = extractTabItems(children);
|
|
12409
|
-
const [internalSelectedValue, setInternalSelectedValue] = (0,
|
|
12516
|
+
const [internalSelectedValue, setInternalSelectedValue] = (0, import_react69.useState)(defaultSelectedValue);
|
|
12410
12517
|
const modeProps = defaultSelectedValue !== void 0 ? {
|
|
12411
12518
|
defaultValue: defaultSelectedValue,
|
|
12412
12519
|
onValueChange: setInternalSelectedValue
|
|
12413
12520
|
} : { value: selectedValue, onValueChange: onSelectedValueChange };
|
|
12414
12521
|
const currentValue = defaultSelectedValue !== void 0 ? internalSelectedValue : selectedValue;
|
|
12415
|
-
return /* @__PURE__ */ (0,
|
|
12522
|
+
return /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(TabsContainer, { $stickyHeaders: stickyHeaders, children: /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(
|
|
12416
12523
|
StyledTabsRoot,
|
|
12417
12524
|
{
|
|
12418
12525
|
ref,
|
|
@@ -12420,14 +12527,14 @@ var Tabs = (0, import_react68.forwardRef)(
|
|
|
12420
12527
|
activationMode: "automatic",
|
|
12421
12528
|
...props,
|
|
12422
12529
|
...modeProps,
|
|
12423
|
-
children: /* @__PURE__ */ (0,
|
|
12424
|
-
/* @__PURE__ */ (0,
|
|
12530
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(TabsValueProvider, { value: currentValue, children: /* @__PURE__ */ (0, import_jsx_runtime268.jsxs)(SelectedItemStyleProvider, { children: [
|
|
12531
|
+
/* @__PURE__ */ (0, import_jsx_runtime268.jsxs)(
|
|
12425
12532
|
TabList,
|
|
12426
12533
|
{
|
|
12427
12534
|
ariaLabel,
|
|
12428
12535
|
fullWidth,
|
|
12429
12536
|
children: [
|
|
12430
|
-
/* @__PURE__ */ (0,
|
|
12537
|
+
/* @__PURE__ */ (0, import_jsx_runtime268.jsx)(SelectedItemIndicator2, {}),
|
|
12431
12538
|
tabItems.map((tab) => {
|
|
12432
12539
|
const {
|
|
12433
12540
|
value,
|
|
@@ -12437,7 +12544,7 @@ var Tabs = (0, import_react68.forwardRef)(
|
|
|
12437
12544
|
"aria-label": ariaLabelForTab
|
|
12438
12545
|
} = tab.props;
|
|
12439
12546
|
if ((0, import_type_guards51.isNil)(icon)) {
|
|
12440
|
-
return /* @__PURE__ */ (0,
|
|
12547
|
+
return /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(
|
|
12441
12548
|
TabItem,
|
|
12442
12549
|
{
|
|
12443
12550
|
disabled,
|
|
@@ -12448,7 +12555,7 @@ var Tabs = (0, import_react68.forwardRef)(
|
|
|
12448
12555
|
);
|
|
12449
12556
|
}
|
|
12450
12557
|
if ((0, import_type_guards51.isNotNil)(label)) {
|
|
12451
|
-
return /* @__PURE__ */ (0,
|
|
12558
|
+
return /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(
|
|
12452
12559
|
TabItem,
|
|
12453
12560
|
{
|
|
12454
12561
|
disabled,
|
|
@@ -12460,7 +12567,7 @@ var Tabs = (0, import_react68.forwardRef)(
|
|
|
12460
12567
|
);
|
|
12461
12568
|
}
|
|
12462
12569
|
if ((0, import_type_guards51.isNotNil)(ariaLabelForTab)) {
|
|
12463
|
-
return /* @__PURE__ */ (0,
|
|
12570
|
+
return /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(
|
|
12464
12571
|
TabItem,
|
|
12465
12572
|
{
|
|
12466
12573
|
"aria-label": ariaLabelForTab,
|
|
@@ -12476,7 +12583,7 @@ var Tabs = (0, import_react68.forwardRef)(
|
|
|
12476
12583
|
]
|
|
12477
12584
|
}
|
|
12478
12585
|
),
|
|
12479
|
-
/* @__PURE__ */ (0,
|
|
12586
|
+
/* @__PURE__ */ (0, import_jsx_runtime268.jsx)(StickyTabContent, { $stickyHeaders: stickyHeaders, children: tabItems.map((tab) => /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(
|
|
12480
12587
|
TabPanel,
|
|
12481
12588
|
{
|
|
12482
12589
|
value: tab.props.value,
|
|
@@ -12492,19 +12599,19 @@ var Tabs = (0, import_react68.forwardRef)(
|
|
|
12492
12599
|
Tabs.displayName = "Tabs";
|
|
12493
12600
|
|
|
12494
12601
|
// src/components/Tabs/Tab.tsx
|
|
12495
|
-
var
|
|
12496
|
-
var
|
|
12497
|
-
var Tab = (0,
|
|
12498
|
-
return /* @__PURE__ */ (0,
|
|
12602
|
+
var import_react70 = require("react");
|
|
12603
|
+
var import_jsx_runtime269 = require("react/jsx-runtime");
|
|
12604
|
+
var Tab = (0, import_react70.forwardRef)(({ children }, ref) => {
|
|
12605
|
+
return /* @__PURE__ */ (0, import_jsx_runtime269.jsx)("div", { ref, children });
|
|
12499
12606
|
});
|
|
12500
12607
|
Tab.displayName = "Tab";
|
|
12501
12608
|
|
|
12502
12609
|
// src/components/Tag/Tag.tsx
|
|
12503
|
-
var
|
|
12504
|
-
var
|
|
12610
|
+
var import_react71 = require("react");
|
|
12611
|
+
var import_styled_components89 = __toESM(require("styled-components"));
|
|
12505
12612
|
var import_type_guards52 = require("@wistia/type-guards");
|
|
12506
|
-
var
|
|
12507
|
-
var TagLabel =
|
|
12613
|
+
var import_jsx_runtime270 = require("react/jsx-runtime");
|
|
12614
|
+
var TagLabel = import_styled_components89.default.a`
|
|
12508
12615
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
12509
12616
|
font-size: var(--wui-typography-label-4-size);
|
|
12510
12617
|
font-weight: var(--wui-typography-label-4-weight);
|
|
@@ -12539,14 +12646,14 @@ var TagLabel = import_styled_components88.default.a`
|
|
|
12539
12646
|
box-shadow: inset 0 0 0 2px var(--wui-color-border-secondary);
|
|
12540
12647
|
}
|
|
12541
12648
|
`;
|
|
12542
|
-
var TagDivider =
|
|
12649
|
+
var TagDivider = import_styled_components89.default.div`
|
|
12543
12650
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
12544
12651
|
border-left: 1px solid var(--wui-color-border);
|
|
12545
12652
|
display: flex;
|
|
12546
12653
|
height: 14px;
|
|
12547
12654
|
width: 1px;
|
|
12548
12655
|
`;
|
|
12549
|
-
var StyledRemoveButton =
|
|
12656
|
+
var StyledRemoveButton = import_styled_components89.default.button`
|
|
12550
12657
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
12551
12658
|
all: unset;
|
|
12552
12659
|
cursor: pointer;
|
|
@@ -12574,7 +12681,7 @@ var StyledRemoveButton = import_styled_components88.default.button`
|
|
|
12574
12681
|
box-shadow: inset 0 0 0 2px var(--wui-color-border-secondary);
|
|
12575
12682
|
}
|
|
12576
12683
|
`;
|
|
12577
|
-
var StyledTag =
|
|
12684
|
+
var StyledTag = import_styled_components89.default.div`
|
|
12578
12685
|
${({ $colorScheme }) => getColorScheme($colorScheme)};
|
|
12579
12686
|
align-items: center;
|
|
12580
12687
|
background-color: var(--wui-color-bg-surface-secondary);
|
|
@@ -12595,40 +12702,40 @@ var RemoveButton = ({ onClickRemove, onClickRemoveLabel, colorScheme }) => {
|
|
|
12595
12702
|
"for accessibility, onClickRemoveLabel must be provided if onClickRemove is provided"
|
|
12596
12703
|
);
|
|
12597
12704
|
}
|
|
12598
|
-
return /* @__PURE__ */ (0,
|
|
12599
|
-
/* @__PURE__ */ (0,
|
|
12600
|
-
/* @__PURE__ */ (0,
|
|
12705
|
+
return /* @__PURE__ */ (0, import_jsx_runtime270.jsxs)(import_jsx_runtime270.Fragment, { children: [
|
|
12706
|
+
/* @__PURE__ */ (0, import_jsx_runtime270.jsx)(TagDivider, { $colorScheme: colorScheme }),
|
|
12707
|
+
/* @__PURE__ */ (0, import_jsx_runtime270.jsxs)(
|
|
12601
12708
|
StyledRemoveButton,
|
|
12602
12709
|
{
|
|
12603
12710
|
$colorScheme: colorScheme,
|
|
12604
12711
|
onClick: onClickRemove,
|
|
12605
12712
|
type: "button",
|
|
12606
12713
|
children: [
|
|
12607
|
-
/* @__PURE__ */ (0,
|
|
12714
|
+
/* @__PURE__ */ (0, import_jsx_runtime270.jsx)(
|
|
12608
12715
|
Icon,
|
|
12609
12716
|
{
|
|
12610
12717
|
size: "sm",
|
|
12611
12718
|
type: "close"
|
|
12612
12719
|
}
|
|
12613
12720
|
),
|
|
12614
|
-
/* @__PURE__ */ (0,
|
|
12721
|
+
/* @__PURE__ */ (0, import_jsx_runtime270.jsx)(ScreenReaderOnly, { children: onClickRemoveLabel })
|
|
12615
12722
|
]
|
|
12616
12723
|
}
|
|
12617
12724
|
)
|
|
12618
12725
|
] });
|
|
12619
12726
|
};
|
|
12620
|
-
var Tag = (0,
|
|
12727
|
+
var Tag = (0, import_react71.forwardRef)(
|
|
12621
12728
|
({ onClickRemove, colorScheme = "inherit", href, icon, label, onClickRemoveLabel, ...props }, ref) => {
|
|
12622
12729
|
const hasIcon = (0, import_type_guards52.isNotNil)(icon);
|
|
12623
12730
|
const labelProps = (0, import_type_guards52.isNotNil)(href) && (0, import_type_guards52.isNonEmptyString)(href) ? { href, as: "a" } : { as: "span" };
|
|
12624
|
-
return /* @__PURE__ */ (0,
|
|
12731
|
+
return /* @__PURE__ */ (0, import_jsx_runtime270.jsxs)(
|
|
12625
12732
|
StyledTag,
|
|
12626
12733
|
{
|
|
12627
12734
|
ref,
|
|
12628
12735
|
$colorScheme: colorScheme,
|
|
12629
12736
|
...props,
|
|
12630
12737
|
children: [
|
|
12631
|
-
/* @__PURE__ */ (0,
|
|
12738
|
+
/* @__PURE__ */ (0, import_jsx_runtime270.jsxs)(
|
|
12632
12739
|
TagLabel,
|
|
12633
12740
|
{
|
|
12634
12741
|
...labelProps,
|
|
@@ -12639,7 +12746,7 @@ var Tag = (0, import_react70.forwardRef)(
|
|
|
12639
12746
|
]
|
|
12640
12747
|
}
|
|
12641
12748
|
),
|
|
12642
|
-
/* @__PURE__ */ (0,
|
|
12749
|
+
/* @__PURE__ */ (0, import_jsx_runtime270.jsx)(
|
|
12643
12750
|
RemoveButton,
|
|
12644
12751
|
{
|
|
12645
12752
|
colorScheme,
|
|
@@ -12655,10 +12762,10 @@ var Tag = (0, import_react70.forwardRef)(
|
|
|
12655
12762
|
Tag.displayName = "Tag";
|
|
12656
12763
|
|
|
12657
12764
|
// src/components/Thumbnail/ThumbnailBadge.tsx
|
|
12658
|
-
var
|
|
12765
|
+
var import_styled_components90 = __toESM(require("styled-components"));
|
|
12659
12766
|
var import_type_guards53 = require("@wistia/type-guards");
|
|
12660
|
-
var
|
|
12661
|
-
var StyledThumbnailBadge =
|
|
12767
|
+
var import_jsx_runtime271 = require("react/jsx-runtime");
|
|
12768
|
+
var StyledThumbnailBadge = import_styled_components90.default.div`
|
|
12662
12769
|
align-items: center;
|
|
12663
12770
|
background-color: rgb(0 0 0 / 50%);
|
|
12664
12771
|
border-radius: var(--wui-border-radius-01);
|
|
@@ -12683,23 +12790,23 @@ var StyledThumbnailBadge = import_styled_components89.default.div`
|
|
|
12683
12790
|
}
|
|
12684
12791
|
`;
|
|
12685
12792
|
var ThumbnailBadge = ({ icon, label, ...props }) => {
|
|
12686
|
-
return /* @__PURE__ */ (0,
|
|
12793
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsxs)(StyledThumbnailBadge, { ...props, children: [
|
|
12687
12794
|
(0, import_type_guards53.isNotNil)(icon) && icon,
|
|
12688
|
-
/* @__PURE__ */ (0,
|
|
12795
|
+
/* @__PURE__ */ (0, import_jsx_runtime271.jsx)("span", { children: label })
|
|
12689
12796
|
] });
|
|
12690
12797
|
};
|
|
12691
12798
|
ThumbnailBadge.displayName = "ThumbnailBadge";
|
|
12692
12799
|
|
|
12693
12800
|
// src/components/Thumbnail/Thumbnail.tsx
|
|
12694
|
-
var
|
|
12695
|
-
var
|
|
12801
|
+
var import_react72 = require("react");
|
|
12802
|
+
var import_styled_components92 = __toESM(require("styled-components"));
|
|
12696
12803
|
var import_type_guards55 = require("@wistia/type-guards");
|
|
12697
12804
|
|
|
12698
12805
|
// src/private/helpers/getBackgroundGradient/getBackgroundGradient.ts
|
|
12699
12806
|
var import_type_guards54 = require("@wistia/type-guards");
|
|
12700
|
-
var
|
|
12807
|
+
var import_styled_components91 = require("styled-components");
|
|
12701
12808
|
var gradients = {
|
|
12702
|
-
defaultDarkOne:
|
|
12809
|
+
defaultDarkOne: import_styled_components91.css`
|
|
12703
12810
|
background-color: #222d66;
|
|
12704
12811
|
background-image:
|
|
12705
12812
|
radial-gradient(farthest-corner at top right, #222d66, transparent 70%),
|
|
@@ -12707,7 +12814,7 @@ var gradients = {
|
|
|
12707
12814
|
radial-gradient(farthest-corner at bottom left, #6b84ff, transparent 57%),
|
|
12708
12815
|
radial-gradient(farthest-corner at top left, #2949e5, transparent 68%);
|
|
12709
12816
|
`,
|
|
12710
|
-
defaultDarkTwo:
|
|
12817
|
+
defaultDarkTwo: import_styled_components91.css`
|
|
12711
12818
|
background-color: #222d66;
|
|
12712
12819
|
background-image:
|
|
12713
12820
|
radial-gradient(farthest-corner at top left, #6b84ff, transparent 100%),
|
|
@@ -12715,7 +12822,7 @@ var gradients = {
|
|
|
12715
12822
|
radial-gradient(farthest-corner at bottom right, #2949e5, transparent 50%),
|
|
12716
12823
|
radial-gradient(farthest-corner at top right, #2949e5, transparent 70%);
|
|
12717
12824
|
`,
|
|
12718
|
-
defaultLightOne:
|
|
12825
|
+
defaultLightOne: import_styled_components91.css`
|
|
12719
12826
|
background-color: #ccd5ff;
|
|
12720
12827
|
background-image:
|
|
12721
12828
|
radial-gradient(farthest-corner at bottom right, #ccd5ff, transparent 55%),
|
|
@@ -12723,13 +12830,13 @@ var gradients = {
|
|
|
12723
12830
|
radial-gradient(farthest-corner at top right, #6b84ff, transparent 50%),
|
|
12724
12831
|
radial-gradient(farthest-corner at bottom left, #f7f8ff, transparent 50%);
|
|
12725
12832
|
`,
|
|
12726
|
-
defaultLightTwo:
|
|
12833
|
+
defaultLightTwo: import_styled_components91.css`
|
|
12727
12834
|
background-color: #ccd5ff;
|
|
12728
12835
|
background-image:
|
|
12729
12836
|
radial-gradient(ellipse at top, #ccd5ff, transparent),
|
|
12730
12837
|
radial-gradient(ellipse at bottom, #6b84ff, transparent);
|
|
12731
12838
|
`,
|
|
12732
|
-
defaultMidOne:
|
|
12839
|
+
defaultMidOne: import_styled_components91.css`
|
|
12733
12840
|
background-color: #6b84ff;
|
|
12734
12841
|
background-image:
|
|
12735
12842
|
radial-gradient(farthest-corner at top right, #2949e5, transparent 70%),
|
|
@@ -12737,13 +12844,13 @@ var gradients = {
|
|
|
12737
12844
|
radial-gradient(farthest-corner at top left, #6b84ff, transparent 80%),
|
|
12738
12845
|
radial-gradient(farthest-corner at bottom left, #222d66, transparent 57%);
|
|
12739
12846
|
`,
|
|
12740
|
-
defaultMidTwo:
|
|
12847
|
+
defaultMidTwo: import_styled_components91.css`
|
|
12741
12848
|
background-color: #6b84ff;
|
|
12742
12849
|
background-image:
|
|
12743
12850
|
radial-gradient(ellipse at top, #2949e5, transparent),
|
|
12744
12851
|
radial-gradient(ellipse at bottom, #ccd5ff, transparent);
|
|
12745
12852
|
`,
|
|
12746
|
-
green:
|
|
12853
|
+
green: import_styled_components91.css`
|
|
12747
12854
|
background-color: #fafffa;
|
|
12748
12855
|
background-image:
|
|
12749
12856
|
radial-gradient(farthest-corner at bottom left, #b0e5a5, transparent 50%),
|
|
@@ -12751,7 +12858,7 @@ var gradients = {
|
|
|
12751
12858
|
radial-gradient(farthest-corner at top left, #44b62d, transparent 65%),
|
|
12752
12859
|
radial-gradient(farthest-corner at bottom right, #44b62d, transparent 55%);
|
|
12753
12860
|
`,
|
|
12754
|
-
greenWithPop:
|
|
12861
|
+
greenWithPop: import_styled_components91.css`
|
|
12755
12862
|
background-color: #fafffa;
|
|
12756
12863
|
background-image:
|
|
12757
12864
|
radial-gradient(farthest-corner at bottom left, #b0e5a5, transparent 50%),
|
|
@@ -12759,7 +12866,7 @@ var gradients = {
|
|
|
12759
12866
|
radial-gradient(farthest-corner at top left, #44b62d, transparent 65%),
|
|
12760
12867
|
radial-gradient(farthest-corner at bottom right, #44b62d, transparent 55%);
|
|
12761
12868
|
`,
|
|
12762
|
-
pink:
|
|
12869
|
+
pink: import_styled_components91.css`
|
|
12763
12870
|
background-color: #fffff0;
|
|
12764
12871
|
background-image:
|
|
12765
12872
|
radial-gradient(farthest-corner at bottom left, #ffc7e8, transparent 50%),
|
|
@@ -12767,7 +12874,7 @@ var gradients = {
|
|
|
12767
12874
|
radial-gradient(farthest-corner at top left, #ff40b3, transparent 65%),
|
|
12768
12875
|
radial-gradient(farthest-corner at bottom right, #ff40b3, transparent 55%);
|
|
12769
12876
|
`,
|
|
12770
|
-
pinkWithPop:
|
|
12877
|
+
pinkWithPop: import_styled_components91.css`
|
|
12771
12878
|
background-color: #fffff0;
|
|
12772
12879
|
background-image:
|
|
12773
12880
|
radial-gradient(farthest-corner at top right, #e0128e, transparent 70%),
|
|
@@ -12775,7 +12882,7 @@ var gradients = {
|
|
|
12775
12882
|
radial-gradient(farthest-corner at bottom right, #ff40b3, transparent 55%),
|
|
12776
12883
|
radial-gradient(farthest-corner at bottom left, #2949e5, transparent 50%);
|
|
12777
12884
|
`,
|
|
12778
|
-
playfulGradientOne:
|
|
12885
|
+
playfulGradientOne: import_styled_components91.css`
|
|
12779
12886
|
background-color: #f7f8ff;
|
|
12780
12887
|
background-image:
|
|
12781
12888
|
radial-gradient(farthest-corner at top left, #d65cff, transparent 68%),
|
|
@@ -12783,7 +12890,7 @@ var gradients = {
|
|
|
12783
12890
|
radial-gradient(farthest-corner at bottom left, #ffc7e8, transparent 57%),
|
|
12784
12891
|
radial-gradient(farthest-corner at top right, #ffcaba, transparent 70%);
|
|
12785
12892
|
`,
|
|
12786
|
-
playfulGradientTwo:
|
|
12893
|
+
playfulGradientTwo: import_styled_components91.css`
|
|
12787
12894
|
background-color: #f7f8ff;
|
|
12788
12895
|
background-image:
|
|
12789
12896
|
radial-gradient(farthest-corner at top left, #44b62d, transparent 68%),
|
|
@@ -12791,13 +12898,13 @@ var gradients = {
|
|
|
12791
12898
|
radial-gradient(farthest-corner at bottom left, #ccd5ff, transparent 57%),
|
|
12792
12899
|
radial-gradient(farthest-corner at top right, #2949e5, transparent 70%);
|
|
12793
12900
|
`,
|
|
12794
|
-
purple:
|
|
12901
|
+
purple: import_styled_components91.css`
|
|
12795
12902
|
background-color: #f2caff;
|
|
12796
12903
|
background-image:
|
|
12797
12904
|
radial-gradient(ellipse at 0% 100%, #f9e5ff, transparent 50%),
|
|
12798
12905
|
radial-gradient(ellipse at 100% 0%, #e093fa, transparent 70%);
|
|
12799
12906
|
`,
|
|
12800
|
-
purpleWithPop:
|
|
12907
|
+
purpleWithPop: import_styled_components91.css`
|
|
12801
12908
|
background-color: #f2caff;
|
|
12802
12909
|
background-image:
|
|
12803
12910
|
radial-gradient(farthest-corner at bottom left, #f2caff, transparent 50%),
|
|
@@ -12805,7 +12912,7 @@ var gradients = {
|
|
|
12805
12912
|
radial-gradient(farthest-corner at bottom right, #d65cff, transparent 55%),
|
|
12806
12913
|
radial-gradient(farthest-corner at top right, #2949e5, transparent 70%);
|
|
12807
12914
|
`,
|
|
12808
|
-
yellow:
|
|
12915
|
+
yellow: import_styled_components91.css`
|
|
12809
12916
|
background-color: #fffff0;
|
|
12810
12917
|
background-image:
|
|
12811
12918
|
radial-gradient(farthest-corner at bottom left, #eff18d, transparent 50%),
|
|
@@ -12813,7 +12920,7 @@ var gradients = {
|
|
|
12813
12920
|
radial-gradient(farthest-corner at top left, #e8ec1e, transparent 65%),
|
|
12814
12921
|
radial-gradient(farthest-corner at bottom right, #e8ec1e, transparent 55%);
|
|
12815
12922
|
`,
|
|
12816
|
-
yellowWithPop:
|
|
12923
|
+
yellowWithPop: import_styled_components91.css`
|
|
12817
12924
|
background-color: #fffff0;
|
|
12818
12925
|
background-image:
|
|
12819
12926
|
radial-gradient(farthest-corner at bottom left, #eff18d, transparent 50%),
|
|
@@ -12828,20 +12935,20 @@ var getBackgroundGradient = (gradientName = void 0) => {
|
|
|
12828
12935
|
};
|
|
12829
12936
|
|
|
12830
12937
|
// src/components/Thumbnail/Thumbnail.tsx
|
|
12831
|
-
var
|
|
12832
|
-
var WideThumbnailImage =
|
|
12938
|
+
var import_jsx_runtime272 = require("react/jsx-runtime");
|
|
12939
|
+
var WideThumbnailImage = import_styled_components92.default.img`
|
|
12833
12940
|
height: 100%;
|
|
12834
12941
|
object-fit: cover;
|
|
12835
12942
|
width: 100%;
|
|
12836
12943
|
`;
|
|
12837
|
-
var SquareThumbnailImage =
|
|
12944
|
+
var SquareThumbnailImage = import_styled_components92.default.img`
|
|
12838
12945
|
backdrop-filter: blur(8px);
|
|
12839
12946
|
object-fit: contain;
|
|
12840
12947
|
width: 100%;
|
|
12841
12948
|
`;
|
|
12842
12949
|
var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
|
|
12843
12950
|
if (thumbnailImageType === "wide") {
|
|
12844
|
-
return /* @__PURE__ */ (0,
|
|
12951
|
+
return /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(
|
|
12845
12952
|
WideThumbnailImage,
|
|
12846
12953
|
{
|
|
12847
12954
|
alt: "",
|
|
@@ -12850,7 +12957,7 @@ var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
|
|
|
12850
12957
|
}
|
|
12851
12958
|
);
|
|
12852
12959
|
}
|
|
12853
|
-
return /* @__PURE__ */ (0,
|
|
12960
|
+
return /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(
|
|
12854
12961
|
SquareThumbnailImage,
|
|
12855
12962
|
{
|
|
12856
12963
|
alt: "",
|
|
@@ -12859,7 +12966,7 @@ var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
|
|
|
12859
12966
|
}
|
|
12860
12967
|
);
|
|
12861
12968
|
};
|
|
12862
|
-
var StyledThumbnail =
|
|
12969
|
+
var StyledThumbnail = import_styled_components92.default.div`
|
|
12863
12970
|
background-image: ${({ $backgroundUrl }) => (0, import_type_guards55.isNotNil)($backgroundUrl) ? `url('${$backgroundUrl}')` : void 0};
|
|
12864
12971
|
${({ $backgroundUrl, $gradientBackground }) => (
|
|
12865
12972
|
// if we don't have $backgroundUrl show a gradient
|
|
@@ -12878,7 +12985,7 @@ var StyledThumbnail = import_styled_components91.default.div`
|
|
|
12878
12985
|
border-radius: calc(8% * (9 / 16)) / 8%;
|
|
12879
12986
|
}
|
|
12880
12987
|
`;
|
|
12881
|
-
var Thumbnail = (0,
|
|
12988
|
+
var Thumbnail = (0, import_react72.forwardRef)(
|
|
12882
12989
|
({
|
|
12883
12990
|
gradientBackground = "defaultMidOne",
|
|
12884
12991
|
thumbnailImageType = "square",
|
|
@@ -12888,7 +12995,7 @@ var Thumbnail = (0, import_react71.forwardRef)(
|
|
|
12888
12995
|
...props
|
|
12889
12996
|
}, ref) => {
|
|
12890
12997
|
const backgroundUrl = thumbnailImageType === "square" && (0, import_type_guards55.isNotNil)(thumbnailUrl) ? thumbnailUrl : void 0;
|
|
12891
|
-
return /* @__PURE__ */ (0,
|
|
12998
|
+
return /* @__PURE__ */ (0, import_jsx_runtime272.jsxs)(
|
|
12892
12999
|
StyledThumbnail,
|
|
12893
13000
|
{
|
|
12894
13001
|
ref,
|
|
@@ -12899,7 +13006,7 @@ var Thumbnail = (0, import_react71.forwardRef)(
|
|
|
12899
13006
|
role: "presentation",
|
|
12900
13007
|
children: [
|
|
12901
13008
|
(0, import_type_guards55.isNotNil)(children) ? children : null,
|
|
12902
|
-
(0, import_type_guards55.isNotNil)(thumbnailUrl) ? /* @__PURE__ */ (0,
|
|
13009
|
+
(0, import_type_guards55.isNotNil)(thumbnailUrl) ? /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(
|
|
12903
13010
|
ThumbnailImage,
|
|
12904
13011
|
{
|
|
12905
13012
|
thumbnailImageType,
|
|
@@ -12914,14 +13021,14 @@ var Thumbnail = (0, import_react71.forwardRef)(
|
|
|
12914
13021
|
Thumbnail.displayName = "Thumbnail";
|
|
12915
13022
|
|
|
12916
13023
|
// src/components/ThumbnailCollage/ThumbnailCollage.tsx
|
|
12917
|
-
var
|
|
12918
|
-
var
|
|
13024
|
+
var import_react73 = __toESM(require("react"));
|
|
13025
|
+
var import_styled_components93 = __toESM(require("styled-components"));
|
|
12919
13026
|
var import_type_guards56 = require("@wistia/type-guards");
|
|
12920
|
-
var
|
|
13027
|
+
var import_jsx_runtime273 = (
|
|
12921
13028
|
// ThumbnailCollage will fallback to a Thumbnail with a gradient background if no children are provided
|
|
12922
13029
|
require("react/jsx-runtime")
|
|
12923
13030
|
);
|
|
12924
|
-
var StyledThumbnailCollage =
|
|
13031
|
+
var StyledThumbnailCollage = import_styled_components93.default.div`
|
|
12925
13032
|
display: grid;
|
|
12926
13033
|
gap: var(--wui-space-01);
|
|
12927
13034
|
width: 100%;
|
|
@@ -12994,15 +13101,15 @@ var ThumbnailCollage = ({
|
|
|
12994
13101
|
gradientBackground = "defaultMidOne",
|
|
12995
13102
|
...props
|
|
12996
13103
|
}) => {
|
|
12997
|
-
const thumbnailArray =
|
|
13104
|
+
const thumbnailArray = import_react73.default.Children.toArray(children);
|
|
12998
13105
|
const truncatedThumbnails = thumbnailArray.slice(0, 3);
|
|
12999
13106
|
const thumbnails = (0, import_type_guards56.isNonEmptyArray)(thumbnailArray) ? truncatedThumbnails.map((child) => {
|
|
13000
|
-
return
|
|
13107
|
+
return import_react73.default.cloneElement(child, {
|
|
13001
13108
|
...child.props,
|
|
13002
13109
|
children: void 0
|
|
13003
13110
|
});
|
|
13004
13111
|
}) : [
|
|
13005
|
-
/* @__PURE__ */ (0,
|
|
13112
|
+
/* @__PURE__ */ (0, import_jsx_runtime273.jsx)(
|
|
13006
13113
|
Thumbnail,
|
|
13007
13114
|
{
|
|
13008
13115
|
gradientBackground,
|
|
@@ -13011,7 +13118,7 @@ var ThumbnailCollage = ({
|
|
|
13011
13118
|
"fallback"
|
|
13012
13119
|
)
|
|
13013
13120
|
];
|
|
13014
|
-
return /* @__PURE__ */ (0,
|
|
13121
|
+
return /* @__PURE__ */ (0, import_jsx_runtime273.jsx)(
|
|
13015
13122
|
StyledThumbnailCollage,
|
|
13016
13123
|
{
|
|
13017
13124
|
$gradientBackground: gradientBackground,
|
|
@@ -13023,26 +13130,26 @@ var ThumbnailCollage = ({
|
|
|
13023
13130
|
};
|
|
13024
13131
|
|
|
13025
13132
|
// src/components/WistiaLogo/WistiaLogo.tsx
|
|
13026
|
-
var
|
|
13133
|
+
var import_styled_components94 = __toESM(require("styled-components"));
|
|
13027
13134
|
var import_type_guards57 = require("@wistia/type-guards");
|
|
13028
|
-
var
|
|
13135
|
+
var import_jsx_runtime274 = require("react/jsx-runtime");
|
|
13029
13136
|
var renderBrandmark = (brandmarkColor, iconOnly) => {
|
|
13030
13137
|
if (iconOnly) {
|
|
13031
|
-
return /* @__PURE__ */ (0,
|
|
13138
|
+
return /* @__PURE__ */ (0, import_jsx_runtime274.jsx)(
|
|
13032
13139
|
"g",
|
|
13033
13140
|
{
|
|
13034
13141
|
"data-testid": "ui-wistia-logo-brandmark",
|
|
13035
13142
|
fill: brandmarkColor,
|
|
13036
|
-
children: /* @__PURE__ */ (0,
|
|
13143
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime274.jsx)("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" })
|
|
13037
13144
|
}
|
|
13038
13145
|
);
|
|
13039
13146
|
}
|
|
13040
|
-
return /* @__PURE__ */ (0,
|
|
13147
|
+
return /* @__PURE__ */ (0, import_jsx_runtime274.jsx)(
|
|
13041
13148
|
"g",
|
|
13042
13149
|
{
|
|
13043
13150
|
"data-testid": "ui-wistia-logo-brandmark",
|
|
13044
13151
|
fill: brandmarkColor,
|
|
13045
|
-
children: /* @__PURE__ */ (0,
|
|
13152
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime274.jsx)("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" })
|
|
13046
13153
|
}
|
|
13047
13154
|
);
|
|
13048
13155
|
};
|
|
@@ -13050,12 +13157,12 @@ var renderLogotype = (logotypeColor, iconOnly) => {
|
|
|
13050
13157
|
if (iconOnly) {
|
|
13051
13158
|
return null;
|
|
13052
13159
|
}
|
|
13053
|
-
return /* @__PURE__ */ (0,
|
|
13160
|
+
return /* @__PURE__ */ (0, import_jsx_runtime274.jsx)(
|
|
13054
13161
|
"g",
|
|
13055
13162
|
{
|
|
13056
13163
|
"data-testid": "ui-wistia-logo-logotype",
|
|
13057
13164
|
fill: logotypeColor,
|
|
13058
|
-
children: /* @__PURE__ */ (0,
|
|
13165
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime274.jsx)("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" })
|
|
13059
13166
|
}
|
|
13060
13167
|
);
|
|
13061
13168
|
};
|
|
@@ -13065,7 +13172,7 @@ var computedViewBox = (iconOnly) => {
|
|
|
13065
13172
|
}
|
|
13066
13173
|
return "0 0 144 31.47";
|
|
13067
13174
|
};
|
|
13068
|
-
var WistiaLogoComponent =
|
|
13175
|
+
var WistiaLogoComponent = import_styled_components94.default.svg`
|
|
13069
13176
|
height: ${({ height }) => `${height}px`};
|
|
13070
13177
|
|
|
13071
13178
|
/* ensure it will always fit on mobile */
|
|
@@ -13081,12 +13188,12 @@ var WistiaLogoComponent = import_styled_components93.default.svg`
|
|
|
13081
13188
|
${({ $opticallyCentered, $iconOnly }) => {
|
|
13082
13189
|
if ($opticallyCentered) {
|
|
13083
13190
|
if ($iconOnly) {
|
|
13084
|
-
return
|
|
13191
|
+
return import_styled_components94.css`
|
|
13085
13192
|
aspect-ratio: 1;
|
|
13086
13193
|
padding: 11.85% 3.12% 13.91%;
|
|
13087
13194
|
`;
|
|
13088
13195
|
}
|
|
13089
|
-
return
|
|
13196
|
+
return import_styled_components94.css`
|
|
13090
13197
|
aspect-ratio: 127 / 32;
|
|
13091
13198
|
`;
|
|
13092
13199
|
}
|
|
@@ -13123,7 +13230,7 @@ var WistiaLogo = ({
|
|
|
13123
13230
|
};
|
|
13124
13231
|
const brandmarkColor = VARIANT_COLORS[variant].brandmark;
|
|
13125
13232
|
const logotypeColor = VARIANT_COLORS[variant].logotype;
|
|
13126
|
-
const Logo = /* @__PURE__ */ (0,
|
|
13233
|
+
const Logo = /* @__PURE__ */ (0, import_jsx_runtime274.jsxs)(
|
|
13127
13234
|
WistiaLogoComponent,
|
|
13128
13235
|
{
|
|
13129
13236
|
$hoverColor: hoverColor,
|
|
@@ -13136,14 +13243,14 @@ var WistiaLogo = ({
|
|
|
13136
13243
|
xmlns: "http://www.w3.org/2000/svg",
|
|
13137
13244
|
...props,
|
|
13138
13245
|
children: [
|
|
13139
|
-
/* @__PURE__ */ (0,
|
|
13140
|
-
(0, import_type_guards57.isNotNil)(description) ? /* @__PURE__ */ (0,
|
|
13246
|
+
/* @__PURE__ */ (0, import_jsx_runtime274.jsx)("title", { children: title }),
|
|
13247
|
+
(0, import_type_guards57.isNotNil)(description) ? /* @__PURE__ */ (0, import_jsx_runtime274.jsx)("desc", { children: description }) : null,
|
|
13141
13248
|
renderBrandmark(brandmarkColor, iconOnly),
|
|
13142
13249
|
renderLogotype(logotypeColor, iconOnly)
|
|
13143
13250
|
]
|
|
13144
13251
|
}
|
|
13145
13252
|
);
|
|
13146
|
-
return href !== void 0 ? /* @__PURE__ */ (0,
|
|
13253
|
+
return href !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime274.jsx)("a", { href, children: Logo }) : Logo;
|
|
13147
13254
|
};
|
|
13148
13255
|
WistiaLogo.displayName = "WistiaLogo";
|
|
13149
13256
|
// Annotate the CommonJS export names for ESM import in node:
|