@wistia/ui 0.12.1 → 0.13.0-beta.14ba576c.39303c6

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 CHANGED
@@ -1,6 +1,6 @@
1
1
 
2
2
  /*
3
- * @license @wistia/ui v0.12.1
3
+ * @license @wistia/ui v0.13.0-beta.14ba576c.39303c6
4
4
  *
5
5
  * Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
6
6
  *
@@ -61,6 +61,7 @@ __export(index_exports, {
61
61
  ColorSchemeWrapper: () => ColorSchemeWrapper,
62
62
  Combobox: () => Combobox2,
63
63
  ComboboxOption: () => ComboboxOption,
64
+ ContextMenu: () => ContextMenu,
64
65
  DataCard: () => DataCard,
65
66
  DataCardTrend: () => DataCardTrend,
66
67
  DataCards: () => DataCards,
@@ -100,6 +101,8 @@ __export(index_exports, {
100
101
  Popover: () => Popover2,
101
102
  ProgressBar: () => ProgressBar,
102
103
  Radio: () => Radio,
104
+ RadioCard: () => RadioCard,
105
+ RadioCardImage: () => RadioCardImage,
103
106
  RadioGroup: () => RadioGroup,
104
107
  RadioMenuItem: () => RadioMenuItem,
105
108
  ScreenReaderOnly: () => ScreenReaderOnly,
@@ -9102,7 +9105,7 @@ var StyledFieldset = import_styled_components41.default.fieldset`
9102
9105
  border: 0;
9103
9106
  `;
9104
9107
  var StyledLegend = import_styled_components41.default.legend`
9105
- margin-bottom: var(--space-01);
9108
+ margin-bottom: var(--wui-space-02);
9106
9109
  `;
9107
9110
  var FormGroup = ({ children, label, ...props }) => {
9108
9111
  const ref = (0, import_react35.useRef)(null);
@@ -11138,7 +11141,7 @@ var StyledGrid = import_styled_components59.default.div`
11138
11141
  }}
11139
11142
  `;
11140
11143
  var GridComponent = (0, import_react50.forwardRef)(
11141
- ({ children, columns = "auto", minChildWidth = "auto", gap = "space-04", renderAs, ...props }, ref) => {
11144
+ ({ children, columns = "auto", minChildWidth = "auto", gap = "space-02", renderAs, ...props }, ref) => {
11142
11145
  const responsiveGap = useResponsiveProp(gap);
11143
11146
  const { column, row } = (0, import_type_guards38.isRecord)(responsiveGap) ? responsiveGap : { column: responsiveGap, row: responsiveGap };
11144
11147
  const responsiveColumns = useResponsiveProp(columns);
@@ -11642,10 +11645,11 @@ var Menu = (0, import_react53.forwardRef)(
11642
11645
  $compact: compact,
11643
11646
  align,
11644
11647
  collisionPadding: 8,
11645
- sideOffset: 6,
11646
11648
  onFocusOutside: (event) => {
11647
11649
  event.preventDefault();
11648
11650
  },
11651
+ side: "bottom",
11652
+ sideOffset: 6,
11649
11653
  children
11650
11654
  }
11651
11655
  ) })
@@ -12892,21 +12896,339 @@ var Radio = (0, import_react61.forwardRef)(
12892
12896
  );
12893
12897
  Radio.displayName = "Radio";
12894
12898
 
12895
- // src/components/SegmentedControl/SegmentedControl.tsx
12896
- var import_react64 = require("react");
12899
+ // src/components/RadioCard/RadioCard.tsx
12900
+ var import_react63 = require("react");
12901
+
12902
+ // src/components/RadioCard/RadioCardRoot.tsx
12903
+ var import_react62 = require("react");
12904
+ var import_styled_components78 = __toESM(require("styled-components"));
12905
+ var import_type_guards52 = require("@wistia/type-guards");
12906
+ var import_jsx_runtime261 = require("react/jsx-runtime");
12907
+ var checkedStyles = import_styled_components78.css`
12908
+ --wui-radio-card-border-color: var(--wui-color-focus-ring);
12909
+ --wui-color-icon: var(--wui-color-icon-selected);
12910
+ --wui-radio-card-background-color: var(--wui-color-bg-surface-info);
12911
+ --wui-color-text: var(--wui-color-text-info);
12912
+ --wui-color-text-secondary: var(--wui-color-text-info);
12913
+ `;
12914
+ var disabledStyles = import_styled_components78.css`
12915
+ --wui-radio-card-border-color: var(--wui-color-border-disabled);
12916
+ --wui-radio-card-background-color: var(--wui-color-bg-surface-disabled);
12917
+ --wui-radio-card-cursor: not-allowed;
12918
+ --wui-color-icon: var(--wui-color-icon-disabled);
12919
+ --wui-color-text: var(--wui-color-text-disabled);
12920
+ --wui-color-text-secondary: var(--wui-color-text-disabled);
12921
+ `;
12922
+ var focusStyles = import_styled_components78.css`
12923
+ outline: 2px solid var(--wui-color-focus-ring);
12924
+ `;
12925
+ var imageCoverStyles = import_styled_components78.css`
12926
+ --wui-radio-card-image-inset: 0px;
12927
+ --wui-radio-card-border-width: 0px;
12928
+ --wui-inset-shadow-width: 1px;
12929
+ --wui-radio-card-border-color: rgb(0 0 0 / 25%);
12930
+
12931
+ overflow: hidden;
12932
+
12933
+ &:has(input:checked) {
12934
+ --wui-radio-card-border-color: var(--wui-color-focus-ring);
12935
+ --wui-radio-card-image-inset: 2px;
12936
+ --wui-inset-shadow-width: 2px;
12937
+ }
12938
+
12939
+ &:hover:not(:has(input:disabled, input:checked)) {
12940
+ --wui-radio-card-border-color: rgb(0 0 0 / 50%);
12941
+ }
12942
+
12943
+ &::after {
12944
+ content: '';
12945
+ position: absolute;
12946
+ top: 0;
12947
+ width: 100%;
12948
+ height: 100%;
12949
+ border-radius: var(--wui-radio-card-border-radius);
12950
+ box-shadow:
12951
+ inset 0 0 0 var(--wui-inset-shadow-width) var(--wui-radio-card-border-color),
12952
+ inset 0 0 0 calc(var(--wui-radio-card-image-inset) * 2) var(--wui-radio-card-background-color);
12953
+ transition: all var(--wui-motion-duration-02) var(--wui-motion-ease);
12954
+ }
12955
+ `;
12956
+ var StyledCard2 = import_styled_components78.default.label`
12957
+ --wui-radio-card-border-color: var(--wui-color-border-secondary);
12958
+ --wui-radio-card-background-color: var(--wui-color-bg-surface);
12959
+ --wui-radio-card-cursor: pointer;
12960
+ --wui-radio-card-border-width: 1px;
12961
+ --wui-radio-card-border-radius: var(--wui-border-radius-02);
12962
+
12963
+ position: relative;
12964
+ display: flex;
12965
+ padding: ${({ $padding }) => `var(--wui-${$padding})`};
12966
+ aspect-ratio: ${({ $aspectRatio }) => $aspectRatio};
12967
+ border: var(--wui-radio-card-border-width) solid var(--wui-radio-card-border-color);
12968
+ border-radius: var(--wui-radio-card-border-radius);
12969
+ background-color: var(--wui-radio-card-background-color);
12970
+ cursor: var(--wui-radio-card-cursor);
12971
+ transition: all var(--wui-motion-duration-03) var(--wui-motion-ease);
12972
+
12973
+ svg {
12974
+ transition: all var(--wui-motion-duration-03) var(--wui-motion-ease);
12975
+ }
12976
+
12977
+ &:hover {
12978
+ --wui-radio-card-border-color: var(--wui-color-border-secondary-hover);
12979
+ }
12980
+
12981
+ &:active {
12982
+ --wui-radio-card-border-color: var(--wui-color-border-secondary-active);
12983
+ }
12984
+
12985
+ &:has(input:checked) {
12986
+ ${checkedStyles}
12987
+ }
12988
+
12989
+ &:has(input:disabled) {
12990
+ ${disabledStyles}
12991
+ }
12992
+
12993
+ &:has(input:focus-visible) {
12994
+ ${focusStyles}
12995
+ }
12996
+
12997
+ &:has([data-wui-radio-card-image]) {
12998
+ &:has(input:disabled) {
12999
+ [data-wui-radio-card-image] {
13000
+ filter: grayscale(100%);
13001
+ }
13002
+ }
13003
+
13004
+ &:has([data-wui-radio-card-image='cover']) {
13005
+ ${imageCoverStyles}
13006
+ }
13007
+ }
13008
+ `;
13009
+ var StyledHiddenInput = import_styled_components78.default.input`
13010
+ ${visuallyHiddenStyle}
13011
+ `;
13012
+ var RadioCardRoot = (0, import_react62.forwardRef)(
13013
+ ({
13014
+ children,
13015
+ disabled = false,
13016
+ id,
13017
+ name,
13018
+ onChange,
13019
+ value,
13020
+ aspectRatio = "initial",
13021
+ padding = "space-04",
13022
+ checked,
13023
+ ...props
13024
+ }, ref) => {
13025
+ const generatedId = (0, import_react62.useId)();
13026
+ const computedId = (0, import_type_guards52.isNonEmptyString)(id) ? id : `wistia-ui-radio-${generatedId}`;
13027
+ const radioGroupContext = useRadioGroup();
13028
+ const contextName = radioGroupContext?.name;
13029
+ const contextOnChange = radioGroupContext?.onChange;
13030
+ const contextValue = radioGroupContext?.value;
13031
+ const radioName = name ?? contextName;
13032
+ const handleOnChange = onChange ?? contextOnChange;
13033
+ const defaultChecked = (0, import_type_guards52.isNotUndefined)(value) && (0, import_type_guards52.isNotUndefined)(contextValue) ? contextValue.includes(value) : void 0;
13034
+ return /* @__PURE__ */ (0, import_jsx_runtime261.jsxs)(
13035
+ StyledCard2,
13036
+ {
13037
+ $aspectRatio: aspectRatio,
13038
+ $padding: padding,
13039
+ htmlFor: computedId,
13040
+ children: [
13041
+ /* @__PURE__ */ (0, import_jsx_runtime261.jsx)(
13042
+ StyledHiddenInput,
13043
+ {
13044
+ ...props,
13045
+ ref,
13046
+ disabled,
13047
+ id: computedId,
13048
+ name: radioName,
13049
+ onChange: handleOnChange,
13050
+ type: "radio",
13051
+ value,
13052
+ ...(0, import_type_guards52.isNotUndefined)(defaultChecked) ? { defaultChecked } : { checked }
13053
+ }
13054
+ ),
13055
+ children
13056
+ ]
13057
+ }
13058
+ );
13059
+ }
13060
+ );
13061
+ RadioCardRoot.displayName = "RadioCardRoot";
13062
+
13063
+ // src/components/RadioCard/RadioCardDefaultLayout.tsx
13064
+ var import_styled_components80 = __toESM(require("styled-components"));
13065
+ var import_type_guards53 = require("@wistia/type-guards");
13066
+
13067
+ // src/components/RadioCard/RadioCardIndicator.tsx
12897
13068
  var import_styled_components79 = __toESM(require("styled-components"));
13069
+ var RadioCardIndicator = import_styled_components79.default.div`
13070
+ --wui-radio-card-indicator-size: 14px;
13071
+ --wui-radio-card-indicator-background-color: var(--wui-color-bg-surface);
13072
+ --wui-radio-card-indicator-fill-color: var(--wui-color-bg-fill);
13073
+
13074
+ /* TODO: figure out radio / checkbox / switch colors */
13075
+ --wui-radio-card-indicator-border-color: var(--wui-color-border-secondary-active);
13076
+
13077
+ width: var(--wui-radio-card-indicator-size);
13078
+ height: var(--wui-radio-card-indicator-size);
13079
+ min-width: var(--wui-radio-card-indicator-size);
13080
+ min-height: var(--wui-radio-card-indicator-size);
13081
+ background-color: var(--wui-radio-card-indicator-background-color);
13082
+ box-shadow: inset 0 0 0 1px var(--wui-radio-card-indicator-border-color);
13083
+ border-radius: 100%;
13084
+ position: relative;
13085
+ cursor: pointer;
13086
+ transition: border-color var(--wui-motion-duration-03) var(--wui-motion-ease);
13087
+
13088
+ &::after {
13089
+ content: '';
13090
+ position: absolute;
13091
+ top: 50%;
13092
+ left: 50%;
13093
+ width: 0;
13094
+ height: 0;
13095
+ background-color: var(--wui-radio-card-indicator-fill-color);
13096
+ border-radius: 100%;
13097
+ transform: translate(-50%, -50%);
13098
+ }
13099
+
13100
+ ${StyledCard2}:has(input:checked) & {
13101
+ --wui-radio-card-indicator-border-color: var(--wui-color-focus-ring);
13102
+ --wui-radio-card-indicator-fill-color: var(--wui-color-focus-ring);
13103
+
13104
+ &::after {
13105
+ width: calc(var(--wui-radio-card-indicator-size) / 2);
13106
+ height: calc(var(--wui-radio-card-indicator-size) / 2);
13107
+ }
13108
+ }
13109
+
13110
+ ${StyledCard2}:has(input:disabled) & {
13111
+ --wui-radio-card-indicator-border-color: var(--wui-color-border-secondary);
13112
+ --wui-radio-card-indicator-background-color: var(--wui-color-bg-surface-disabled);
13113
+ }
13114
+ `;
13115
+ RadioCardIndicator.displayName = "RadioCardIndicator";
13116
+
13117
+ // src/components/RadioCard/RadioCardDefaultLayout.tsx
13118
+ var import_jsx_runtime262 = require("react/jsx-runtime");
13119
+ var StyledCardContent = import_styled_components80.default.div`
13120
+ display: grid;
13121
+ grid-auto-flow: column;
13122
+ gap: var(--wui-space-02);
13123
+ `;
13124
+ var StyledCardIcon = import_styled_components80.default.div`
13125
+ display: contents;
13126
+ `;
13127
+ var StyledIndicatorContainer = import_styled_components80.default.div`
13128
+ height: ${({ $hasIcon }) => $hasIcon ? "24px" : "16px"};
13129
+ display: flex;
13130
+ align-items: center;
13131
+ `;
13132
+ var RadioCardDefaultLayout = ({
13133
+ icon,
13134
+ label,
13135
+ description,
13136
+ showIndicator = true
13137
+ }) => {
13138
+ return /* @__PURE__ */ (0, import_jsx_runtime262.jsxs)(StyledCardContent, { children: [
13139
+ showIndicator ? /* @__PURE__ */ (0, import_jsx_runtime262.jsx)(StyledIndicatorContainer, { $hasIcon: (0, import_type_guards53.isNotNil)(icon), children: /* @__PURE__ */ (0, import_jsx_runtime262.jsx)(RadioCardIndicator, { "data-testid": "wui-radio-card-indicator" }) }) : null,
13140
+ /* @__PURE__ */ (0, import_jsx_runtime262.jsxs)(Stack, { gap: "space-02", children: [
13141
+ (0, import_type_guards53.isNotNil)(icon) && /* @__PURE__ */ (0, import_jsx_runtime262.jsx)(StyledCardIcon, { "data-wui-radio-card-icon": true, children: icon }),
13142
+ /* @__PURE__ */ (0, import_jsx_runtime262.jsxs)(
13143
+ Stack,
13144
+ {
13145
+ gap: "space-01",
13146
+ style: (0, import_type_guards53.isNotNil)(icon) ? { paddingLeft: 2 } : void 0,
13147
+ children: [
13148
+ /* @__PURE__ */ (0, import_jsx_runtime262.jsx)(Text, { variant: "label3", children: /* @__PURE__ */ (0, import_jsx_runtime262.jsx)("strong", { children: label }) }),
13149
+ (0, import_type_guards53.isNotNil)(description) && /* @__PURE__ */ (0, import_jsx_runtime262.jsx)(
13150
+ Text,
13151
+ {
13152
+ prominence: "secondary",
13153
+ variant: "body3",
13154
+ children: description
13155
+ }
13156
+ )
13157
+ ]
13158
+ }
13159
+ )
13160
+ ] })
13161
+ ] });
13162
+ };
13163
+ RadioCardDefaultLayout.displayName = "RadioCardDefaultLayout";
13164
+
13165
+ // src/components/RadioCard/RadioCard.tsx
13166
+ var import_jsx_runtime263 = require("react/jsx-runtime");
13167
+ var RadioCard = (0, import_react63.forwardRef)(
13168
+ ({ icon, label, description, showIndicator, ...rootProps }, ref) => {
13169
+ return /* @__PURE__ */ (0, import_jsx_runtime263.jsx)(
13170
+ RadioCardRoot,
13171
+ {
13172
+ ref,
13173
+ ...rootProps,
13174
+ children: /* @__PURE__ */ (0, import_jsx_runtime263.jsx)(
13175
+ RadioCardDefaultLayout,
13176
+ {
13177
+ description,
13178
+ icon,
13179
+ label,
13180
+ showIndicator
13181
+ }
13182
+ )
13183
+ }
13184
+ );
13185
+ }
13186
+ );
13187
+ RadioCard.displayName = "RadioCard";
13188
+
13189
+ // src/components/RadioCard/RadioCardImage.tsx
13190
+ var import_react64 = require("react");
13191
+ var import_jsx_runtime264 = require("react/jsx-runtime");
13192
+ var RadioCardImage = (0, import_react64.forwardRef)(
13193
+ ({ label, imageSrc, aspectRatio, padding = "space-04", ...rootProps }, ref) => {
13194
+ return /* @__PURE__ */ (0, import_jsx_runtime264.jsx)(
13195
+ RadioCardRoot,
13196
+ {
13197
+ ref,
13198
+ ...rootProps,
13199
+ aspectRatio,
13200
+ padding,
13201
+ children: /* @__PURE__ */ (0, import_jsx_runtime264.jsx)(
13202
+ Image,
13203
+ {
13204
+ alt: label,
13205
+ "data-wui-radio-card-image": padding === "space-00" ? "cover" : "contain",
13206
+ fill: true,
13207
+ fit: padding === "space-00" ? "cover" : "contain",
13208
+ src: imageSrc
13209
+ }
13210
+ )
13211
+ }
13212
+ );
13213
+ }
13214
+ );
13215
+ RadioCardImage.displayName = "RadioCardImage";
13216
+
13217
+ // src/components/SegmentedControl/SegmentedControl.tsx
13218
+ var import_react67 = require("react");
13219
+ var import_styled_components82 = __toESM(require("styled-components"));
12898
13220
  var import_react_toggle_group = require("@radix-ui/react-toggle-group");
12899
- var import_type_guards53 = require("@wistia/type-guards");
13221
+ var import_type_guards55 = require("@wistia/type-guards");
12900
13222
 
12901
13223
  // src/components/SegmentedControl/useSelectedItemStyle.tsx
12902
- var import_react62 = require("react");
12903
- var import_jsx_runtime261 = require("react/jsx-runtime");
12904
- var SelectedItemStyleContext = (0, import_react62.createContext)(null);
13224
+ var import_react65 = require("react");
13225
+ var import_jsx_runtime265 = require("react/jsx-runtime");
13226
+ var SelectedItemStyleContext = (0, import_react65.createContext)(null);
12905
13227
  var SelectedItemStyleProvider = ({
12906
13228
  children
12907
13229
  }) => {
12908
- const [selectedItemMeasurements, setSelectedItemMeasurements] = (0, import_react62.useState)(null);
12909
- const selectedItemIndicatorStyle = (0, import_react62.useMemo)(
13230
+ const [selectedItemMeasurements, setSelectedItemMeasurements] = (0, import_react65.useState)(null);
13231
+ const selectedItemIndicatorStyle = (0, import_react65.useMemo)(
12910
13232
  () => selectedItemMeasurements != null ? {
12911
13233
  height: `${selectedItemMeasurements.offsetHeight}px`,
12912
13234
  transform: `translateX(${selectedItemMeasurements.offsetLeft}px) translateY(-50%)`,
@@ -12914,17 +13236,17 @@ var SelectedItemStyleProvider = ({
12914
13236
  } : void 0,
12915
13237
  [selectedItemMeasurements]
12916
13238
  );
12917
- const contextValue = (0, import_react62.useMemo)(
13239
+ const contextValue = (0, import_react65.useMemo)(
12918
13240
  () => ({
12919
13241
  setSelectedItemMeasurements,
12920
13242
  selectedItemIndicatorStyle
12921
13243
  }),
12922
13244
  [selectedItemIndicatorStyle]
12923
13245
  );
12924
- return /* @__PURE__ */ (0, import_jsx_runtime261.jsx)(SelectedItemStyleContext.Provider, { value: contextValue, children });
13246
+ return /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(SelectedItemStyleContext.Provider, { value: contextValue, children });
12925
13247
  };
12926
13248
  var useSelectedItemStyle = () => {
12927
- const context = (0, import_react62.useContext)(SelectedItemStyleContext);
13249
+ const context = (0, import_react65.useContext)(SelectedItemStyleContext);
12928
13250
  if (context === null) {
12929
13251
  throw new Error("useSelectedItemStyle must be used within a SelectedItemStyleProvider");
12930
13252
  }
@@ -12932,15 +13254,15 @@ var useSelectedItemStyle = () => {
12932
13254
  };
12933
13255
 
12934
13256
  // src/components/SegmentedControl/SelectedItemIndicator.tsx
12935
- var import_styled_components78 = __toESM(require("styled-components"));
12936
- var import_type_guards52 = require("@wistia/type-guards");
13257
+ var import_styled_components81 = __toESM(require("styled-components"));
13258
+ var import_type_guards54 = require("@wistia/type-guards");
12937
13259
 
12938
13260
  // src/components/SegmentedControl/useSegmentedControlValue.tsx
12939
- var import_react63 = require("react");
12940
- var SegmentedControlValueContext = (0, import_react63.createContext)(null);
13261
+ var import_react66 = require("react");
13262
+ var SegmentedControlValueContext = (0, import_react66.createContext)(null);
12941
13263
  var SegmentedControlValueProvider = SegmentedControlValueContext.Provider;
12942
13264
  var useSegmentedControlValue = () => {
12943
- const context = (0, import_react63.useContext)(SegmentedControlValueContext);
13265
+ const context = (0, import_react66.useContext)(SegmentedControlValueContext);
12944
13266
  if (context === null) {
12945
13267
  throw new Error("useSegmentedControlValue must be used within a SegmentedControlValueProvider");
12946
13268
  }
@@ -12948,13 +13270,13 @@ var useSegmentedControlValue = () => {
12948
13270
  };
12949
13271
 
12950
13272
  // src/components/SegmentedControl/SelectedItemIndicator.tsx
12951
- var import_jsx_runtime262 = require("react/jsx-runtime");
12952
- var selectedItemIndicatorStyles = import_styled_components78.css`
13273
+ var import_jsx_runtime266 = require("react/jsx-runtime");
13274
+ var selectedItemIndicatorStyles = import_styled_components81.css`
12953
13275
  background-color: var(--wui-color-bg-fill-white);
12954
13276
  border-radius: var(--wui-border-radius-rounded);
12955
13277
  box-shadow: var(--wui-elevation-01);
12956
13278
  `;
12957
- var SelectedItemIndicatorDiv = import_styled_components78.default.div`
13279
+ var SelectedItemIndicatorDiv = import_styled_components81.default.div`
12958
13280
  ${selectedItemIndicatorStyles}
12959
13281
  left: 0;
12960
13282
  position: absolute;
@@ -12967,10 +13289,10 @@ var SelectedItemIndicatorDiv = import_styled_components78.default.div`
12967
13289
  var SelectedItemIndicator = () => {
12968
13290
  const selectedValue = useSegmentedControlValue();
12969
13291
  const { selectedItemIndicatorStyle } = useSelectedItemStyle();
12970
- if (!selectedValue || (0, import_type_guards52.isUndefined)(selectedItemIndicatorStyle)) {
13292
+ if (!selectedValue || (0, import_type_guards54.isUndefined)(selectedItemIndicatorStyle)) {
12971
13293
  return null;
12972
13294
  }
12973
- return /* @__PURE__ */ (0, import_jsx_runtime262.jsx)(
13295
+ return /* @__PURE__ */ (0, import_jsx_runtime266.jsx)(
12974
13296
  SelectedItemIndicatorDiv,
12975
13297
  {
12976
13298
  "data-wui-selected-item-indicator": true,
@@ -12980,8 +13302,8 @@ var SelectedItemIndicator = () => {
12980
13302
  };
12981
13303
 
12982
13304
  // src/components/SegmentedControl/SegmentedControl.tsx
12983
- var import_jsx_runtime263 = require("react/jsx-runtime");
12984
- var segmentedControlStyles = import_styled_components79.css`
13305
+ var import_jsx_runtime267 = require("react/jsx-runtime");
13306
+ var segmentedControlStyles = import_styled_components82.css`
12985
13307
  display: inline-flex;
12986
13308
  background-color: var(--wui-color-bg-surface-secondary);
12987
13309
  border-radius: var(--wui-border-radius-rounded);
@@ -12992,10 +13314,10 @@ var segmentedControlStyles = import_styled_components79.css`
12992
13314
  position: relative;
12993
13315
  width: ${({ $fullWidth }) => $fullWidth ? "100%" : "auto"};
12994
13316
  `;
12995
- var StyledSegmentedControl = (0, import_styled_components79.default)(import_react_toggle_group.Root)`
13317
+ var StyledSegmentedControl = (0, import_styled_components82.default)(import_react_toggle_group.Root)`
12996
13318
  ${segmentedControlStyles}
12997
13319
  `;
12998
- var SegmentedControl = (0, import_react64.forwardRef)(
13320
+ var SegmentedControl = (0, import_react67.forwardRef)(
12999
13321
  ({
13000
13322
  children,
13001
13323
  disabled = false,
@@ -13004,10 +13326,10 @@ var SegmentedControl = (0, import_react64.forwardRef)(
13004
13326
  onSelectedValueChange,
13005
13327
  ...props
13006
13328
  }, ref) => {
13007
- if ((0, import_type_guards53.isNil)(children)) {
13329
+ if ((0, import_type_guards55.isNil)(children)) {
13008
13330
  return null;
13009
13331
  }
13010
- return /* @__PURE__ */ (0, import_jsx_runtime263.jsx)(
13332
+ return /* @__PURE__ */ (0, import_jsx_runtime267.jsx)(
13011
13333
  StyledSegmentedControl,
13012
13334
  {
13013
13335
  ref,
@@ -13019,9 +13341,9 @@ var SegmentedControl = (0, import_react64.forwardRef)(
13019
13341
  type: "single",
13020
13342
  value: selectedValue,
13021
13343
  ...props,
13022
- children: /* @__PURE__ */ (0, import_jsx_runtime263.jsx)(SegmentedControlValueProvider, { value: selectedValue, children: /* @__PURE__ */ (0, import_jsx_runtime263.jsxs)(SelectedItemStyleProvider, { children: [
13344
+ children: /* @__PURE__ */ (0, import_jsx_runtime267.jsx)(SegmentedControlValueProvider, { value: selectedValue, children: /* @__PURE__ */ (0, import_jsx_runtime267.jsxs)(SelectedItemStyleProvider, { children: [
13023
13345
  children,
13024
- /* @__PURE__ */ (0, import_jsx_runtime263.jsx)(SelectedItemIndicator, {})
13346
+ /* @__PURE__ */ (0, import_jsx_runtime267.jsx)(SelectedItemIndicator, {})
13025
13347
  ] }) })
13026
13348
  }
13027
13349
  );
@@ -13030,12 +13352,12 @@ var SegmentedControl = (0, import_react64.forwardRef)(
13030
13352
  SegmentedControl.displayName = "SegmentedControl";
13031
13353
 
13032
13354
  // src/components/SegmentedControl/SegmentedControlItem.tsx
13033
- var import_react65 = require("react");
13034
- var import_styled_components80 = __toESM(require("styled-components"));
13355
+ var import_react68 = require("react");
13356
+ var import_styled_components83 = __toESM(require("styled-components"));
13035
13357
  var import_react_toggle_group2 = require("@radix-ui/react-toggle-group");
13036
- var import_type_guards54 = require("@wistia/type-guards");
13037
- var import_jsx_runtime264 = require("react/jsx-runtime");
13038
- var segmentedControlItemStyles = import_styled_components80.css`
13358
+ var import_type_guards56 = require("@wistia/type-guards");
13359
+ var import_jsx_runtime268 = require("react/jsx-runtime");
13360
+ var segmentedControlItemStyles = import_styled_components83.css`
13039
13361
  all: unset; /* ToggleGroupItem is a button element */
13040
13362
  align-items: center;
13041
13363
  border-radius: var(--wui-border-radius-rounded);
@@ -13102,14 +13424,14 @@ var segmentedControlItemStyles = import_styled_components80.css`
13102
13424
  }
13103
13425
  }
13104
13426
  `;
13105
- var StyledSegmentedControlItem = (0, import_styled_components80.default)(import_react_toggle_group2.Item)`
13427
+ var StyledSegmentedControlItem = (0, import_styled_components83.default)(import_react_toggle_group2.Item)`
13106
13428
  ${segmentedControlItemStyles}
13107
13429
  `;
13108
- var SegmentedControlItem = (0, import_react65.forwardRef)(
13430
+ var SegmentedControlItem = (0, import_react68.forwardRef)(
13109
13431
  ({ disabled, icon, label, "aria-label": ariaLabel, value, ...otherProps }, forwardedRef) => {
13110
13432
  const selectedValue = useSegmentedControlValue();
13111
13433
  const { setSelectedItemMeasurements } = useSelectedItemStyle();
13112
- const buttonRef = (0, import_react65.useRef)(null);
13434
+ const buttonRef = (0, import_react68.useRef)(null);
13113
13435
  const combinedRef = mergeRefs([buttonRef, forwardedRef]);
13114
13436
  const handleClick = (event) => {
13115
13437
  const target = event.target;
@@ -13118,7 +13440,7 @@ var SegmentedControlItem = (0, import_react65.forwardRef)(
13118
13440
  event.preventDefault();
13119
13441
  }
13120
13442
  };
13121
- (0, import_react65.useEffect)(() => {
13443
+ (0, import_react68.useEffect)(() => {
13122
13444
  const buttonElem = buttonRef.current;
13123
13445
  if (!buttonElem) {
13124
13446
  return void 0;
@@ -13143,13 +13465,13 @@ var SegmentedControlItem = (0, import_react65.forwardRef)(
13143
13465
  resizeObserver.disconnect();
13144
13466
  };
13145
13467
  }, [selectedValue, setSelectedItemMeasurements, value]);
13146
- return /* @__PURE__ */ (0, import_jsx_runtime264.jsxs)(
13468
+ return /* @__PURE__ */ (0, import_jsx_runtime268.jsxs)(
13147
13469
  StyledSegmentedControlItem,
13148
13470
  {
13149
13471
  ref: combinedRef,
13150
13472
  ...otherProps,
13151
- $hasLabel: (0, import_type_guards54.isNotNil)(label),
13152
- "aria-label": (0, import_type_guards54.isNotNil)(label) ? void 0 : ariaLabel,
13473
+ $hasLabel: (0, import_type_guards56.isNotNil)(label),
13474
+ "aria-label": (0, import_type_guards56.isNotNil)(label) ? void 0 : ariaLabel,
13153
13475
  disabled,
13154
13476
  onClick: handleClick,
13155
13477
  value,
@@ -13165,10 +13487,10 @@ SegmentedControlItem.displayName = "SegmentedControlItem";
13165
13487
 
13166
13488
  // src/components/Select/Select.tsx
13167
13489
  var import_react_select = require("@radix-ui/react-select");
13168
- var import_react66 = require("react");
13169
- var import_styled_components81 = __toESM(require("styled-components"));
13170
- var import_jsx_runtime265 = require("react/jsx-runtime");
13171
- var StyledTrigger2 = (0, import_styled_components81.default)(import_react_select.Trigger)`
13490
+ var import_react69 = require("react");
13491
+ var import_styled_components84 = __toESM(require("styled-components"));
13492
+ var import_jsx_runtime269 = require("react/jsx-runtime");
13493
+ var StyledTrigger2 = (0, import_styled_components84.default)(import_react_select.Trigger)`
13172
13494
  ${({ $colorScheme }) => getColorScheme($colorScheme)};
13173
13495
  ${inputCss};
13174
13496
  padding: var(--wui-input-vertical-padding) var(--wui-input-horizontal-padding);
@@ -13212,7 +13534,7 @@ var StyledTrigger2 = (0, import_styled_components81.default)(import_react_select
13212
13534
  color: var(--wui-input-placeholder);
13213
13535
  }
13214
13536
  `;
13215
- var StyledContent3 = (0, import_styled_components81.default)(import_react_select.Content)`
13537
+ var StyledContent3 = (0, import_styled_components84.default)(import_react_select.Content)`
13216
13538
  --wui-select-content-border: var(--wui-color-border);
13217
13539
  --wui-select-content-bg: var(--wui-color-bg-surface);
13218
13540
  --wui-select-content-border-radius: var(--wui-border-radius-02);
@@ -13230,7 +13552,7 @@ var StyledContent3 = (0, import_styled_components81.default)(import_react_select
13230
13552
  max-height: var(--radix-select-content-available-height);
13231
13553
  z-index: var(--wui-zindex-select);
13232
13554
  `;
13233
- var Select = (0, import_react66.forwardRef)(
13555
+ var Select = (0, import_react69.forwardRef)(
13234
13556
  ({
13235
13557
  colorScheme = "inherit",
13236
13558
  children,
@@ -13240,13 +13562,13 @@ var Select = (0, import_react66.forwardRef)(
13240
13562
  ...props
13241
13563
  }, forwardedRef) => {
13242
13564
  const responsiveFullWidth = useResponsiveProp(fullWidth);
13243
- return /* @__PURE__ */ (0, import_jsx_runtime265.jsxs)(
13565
+ return /* @__PURE__ */ (0, import_jsx_runtime269.jsxs)(
13244
13566
  import_react_select.Root,
13245
13567
  {
13246
13568
  ...props,
13247
13569
  onValueChange: onChange,
13248
13570
  children: [
13249
- /* @__PURE__ */ (0, import_jsx_runtime265.jsxs)(
13571
+ /* @__PURE__ */ (0, import_jsx_runtime269.jsxs)(
13250
13572
  StyledTrigger2,
13251
13573
  {
13252
13574
  ref: forwardedRef,
@@ -13254,8 +13576,8 @@ var Select = (0, import_react66.forwardRef)(
13254
13576
  $fullWidth: responsiveFullWidth,
13255
13577
  ...props,
13256
13578
  children: [
13257
- /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(import_react_select.Value, { placeholder }),
13258
- /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(
13579
+ /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(import_react_select.Value, { placeholder }),
13580
+ /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(
13259
13581
  Icon,
13260
13582
  {
13261
13583
  size: "md",
@@ -13265,10 +13587,10 @@ var Select = (0, import_react66.forwardRef)(
13265
13587
  ]
13266
13588
  }
13267
13589
  ),
13268
- /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(import_react_select.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime265.jsxs)(StyledContent3, { position: "popper", children: [
13269
- /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(import_react_select.ScrollUpButton, { children: /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(Icon, { type: "caret-up" }) }),
13270
- /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(import_react_select.Viewport, { children }),
13271
- /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(import_react_select.ScrollDownButton, { children: /* @__PURE__ */ (0, import_jsx_runtime265.jsx)(Icon, { type: "caret-down" }) })
13590
+ /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(import_react_select.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime269.jsxs)(StyledContent3, { position: "popper", children: [
13591
+ /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(import_react_select.ScrollUpButton, { children: /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(Icon, { type: "caret-up" }) }),
13592
+ /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(import_react_select.Viewport, { children }),
13593
+ /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(import_react_select.ScrollDownButton, { children: /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(Icon, { type: "caret-down" }) })
13272
13594
  ] }) })
13273
13595
  ]
13274
13596
  }
@@ -13279,11 +13601,11 @@ Select.displayName = "Select";
13279
13601
 
13280
13602
  // src/components/Select/SelectOption.tsx
13281
13603
  var import_react_select2 = require("@radix-ui/react-select");
13282
- var import_react67 = require("react");
13283
- var import_styled_components82 = __toESM(require("styled-components"));
13284
- var import_type_guards55 = require("@wistia/type-guards");
13285
- var import_jsx_runtime266 = require("react/jsx-runtime");
13286
- var StyledItem = (0, import_styled_components82.default)(import_react_select2.Item)`
13604
+ var import_react70 = require("react");
13605
+ var import_styled_components85 = __toESM(require("styled-components"));
13606
+ var import_type_guards57 = require("@wistia/type-guards");
13607
+ var import_jsx_runtime270 = require("react/jsx-runtime");
13608
+ var StyledItem = (0, import_styled_components85.default)(import_react_select2.Item)`
13287
13609
  ${variantStyleMap2.body3};
13288
13610
  display: flex;
13289
13611
  padding: var(--wui-select-option-padding);
@@ -13307,28 +13629,28 @@ var StyledItem = (0, import_styled_components82.default)(import_react_select2.It
13307
13629
  background-color: transparent;
13308
13630
  }
13309
13631
  `;
13310
- var StyledIconContainer = import_styled_components82.default.span`
13632
+ var StyledIconContainer = import_styled_components85.default.span`
13311
13633
  width: 12px;
13312
13634
  `;
13313
- var SelectOption = (0, import_react67.forwardRef)(
13635
+ var SelectOption = (0, import_react70.forwardRef)(
13314
13636
  ({ children, selectedDisplayValue, ...props }, forwardedRef) => {
13315
- return /* @__PURE__ */ (0, import_jsx_runtime266.jsxs)(
13637
+ return /* @__PURE__ */ (0, import_jsx_runtime270.jsxs)(
13316
13638
  StyledItem,
13317
13639
  {
13318
13640
  ...props,
13319
13641
  ref: forwardedRef,
13320
13642
  children: [
13321
- /* @__PURE__ */ (0, import_jsx_runtime266.jsx)(StyledIconContainer, { "data-indicator": true, children: /* @__PURE__ */ (0, import_jsx_runtime266.jsx)(import_react_select2.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime266.jsx)(
13643
+ /* @__PURE__ */ (0, import_jsx_runtime270.jsx)(StyledIconContainer, { "data-indicator": true, children: /* @__PURE__ */ (0, import_jsx_runtime270.jsx)(import_react_select2.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime270.jsx)(
13322
13644
  Icon,
13323
13645
  {
13324
13646
  size: "sm",
13325
13647
  type: "checkmark"
13326
13648
  }
13327
13649
  ) }) }),
13328
- (0, import_type_guards55.isNotNil)(selectedDisplayValue) ? /* @__PURE__ */ (0, import_jsx_runtime266.jsxs)("div", { children: [
13650
+ (0, import_type_guards57.isNotNil)(selectedDisplayValue) ? /* @__PURE__ */ (0, import_jsx_runtime270.jsxs)("div", { children: [
13329
13651
  children,
13330
- /* @__PURE__ */ (0, import_jsx_runtime266.jsx)("div", { style: { display: "none" }, children: /* @__PURE__ */ (0, import_jsx_runtime266.jsx)(import_react_select2.ItemText, { children: selectedDisplayValue }) })
13331
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime266.jsx)(import_react_select2.ItemText, { children })
13652
+ /* @__PURE__ */ (0, import_jsx_runtime270.jsx)("div", { style: { display: "none" }, children: /* @__PURE__ */ (0, import_jsx_runtime270.jsx)(import_react_select2.ItemText, { children: selectedDisplayValue }) })
13653
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime270.jsx)(import_react_select2.ItemText, { children })
13332
13654
  ]
13333
13655
  }
13334
13656
  );
@@ -13338,14 +13660,14 @@ SelectOption.displayName = "SelectOption";
13338
13660
 
13339
13661
  // src/components/Select/SelectOptionGroup.tsx
13340
13662
  var import_react_select3 = require("@radix-ui/react-select");
13341
- var import_styled_components83 = __toESM(require("styled-components"));
13342
- var import_jsx_runtime267 = require("react/jsx-runtime");
13343
- var StyledLabel4 = (0, import_styled_components83.default)(import_react_select3.Label)`
13663
+ var import_styled_components86 = __toESM(require("styled-components"));
13664
+ var import_jsx_runtime271 = require("react/jsx-runtime");
13665
+ var StyledLabel4 = (0, import_styled_components86.default)(import_react_select3.Label)`
13344
13666
  padding: var(--wui-select-option-padding);
13345
13667
  `;
13346
13668
  var SelectOptionGroup = ({ children, label, ...props }) => {
13347
- return /* @__PURE__ */ (0, import_jsx_runtime267.jsxs)(import_react_select3.Group, { ...props, children: [
13348
- /* @__PURE__ */ (0, import_jsx_runtime267.jsx)(StyledLabel4, { children: /* @__PURE__ */ (0, import_jsx_runtime267.jsx)(
13669
+ return /* @__PURE__ */ (0, import_jsx_runtime271.jsxs)(import_react_select3.Group, { ...props, children: [
13670
+ /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(StyledLabel4, { children: /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(
13349
13671
  Text,
13350
13672
  {
13351
13673
  prominence: "secondary",
@@ -13359,10 +13681,10 @@ var SelectOptionGroup = ({ children, label, ...props }) => {
13359
13681
 
13360
13682
  // src/components/Slider/Slider.tsx
13361
13683
  var import_react_slider = require("@radix-ui/react-slider");
13362
- var import_styled_components84 = __toESM(require("styled-components"));
13363
- var import_type_guards56 = require("@wistia/type-guards");
13364
- var import_jsx_runtime268 = require("react/jsx-runtime");
13365
- var SliderContainer = import_styled_components84.default.div`
13684
+ var import_styled_components87 = __toESM(require("styled-components"));
13685
+ var import_type_guards58 = require("@wistia/type-guards");
13686
+ var import_jsx_runtime272 = require("react/jsx-runtime");
13687
+ var SliderContainer = import_styled_components87.default.div`
13366
13688
  --wui-slider-track-color: var(--wui-gray-6);
13367
13689
  --wui-slider-track-border-radius: var(--wui-border-radius-rounded);
13368
13690
  --wui-slider-range-color: var(--wui-color-bg-fill);
@@ -13378,7 +13700,7 @@ var SliderContainer = import_styled_components84.default.div`
13378
13700
  pointer-events: none;
13379
13701
  }
13380
13702
  `;
13381
- var StyledSliderRoot = (0, import_styled_components84.default)(import_react_slider.Root)`
13703
+ var StyledSliderRoot = (0, import_styled_components87.default)(import_react_slider.Root)`
13382
13704
  position: relative;
13383
13705
  display: flex;
13384
13706
  align-items: center;
@@ -13386,20 +13708,20 @@ var StyledSliderRoot = (0, import_styled_components84.default)(import_react_slid
13386
13708
  touch-action: none;
13387
13709
  width: 100%;
13388
13710
  `;
13389
- var StyledSliderTrack = (0, import_styled_components84.default)(import_react_slider.Track)`
13711
+ var StyledSliderTrack = (0, import_styled_components87.default)(import_react_slider.Track)`
13390
13712
  background-color: var(--wui-slider-track-color);
13391
13713
  border-radius: var(--wui-slider-track-border-radius);
13392
13714
  flex-grow: 1;
13393
13715
  height: 6px;
13394
13716
  position: relative;
13395
13717
  `;
13396
- var StyledSliderRange = (0, import_styled_components84.default)(import_react_slider.Range)`
13718
+ var StyledSliderRange = (0, import_styled_components87.default)(import_react_slider.Range)`
13397
13719
  background-color: var(--wui-slider-range-color);
13398
13720
  border-radius: var(--wui-slider-track-border-radius);
13399
13721
  height: 100%;
13400
13722
  position: absolute;
13401
13723
  `;
13402
- var StyledSliderThumb = (0, import_styled_components84.default)(import_react_slider.Thumb)`
13724
+ var StyledSliderThumb = (0, import_styled_components87.default)(import_react_slider.Thumb)`
13403
13725
  background-color: var(--wui-slider-thumb-color);
13404
13726
  border-radius: var(--wui-border-radius-rounded);
13405
13727
  cursor: grab;
@@ -13439,7 +13761,7 @@ var Slider = ({
13439
13761
  "data-testid": dataTestId = "ui-slider",
13440
13762
  ...otherProps
13441
13763
  }) => {
13442
- if (!((0, import_type_guards56.isNonEmptyString)(ariaLabel) || (0, import_type_guards56.isNonEmptyString)(ariaLabelledby))) {
13764
+ if (!((0, import_type_guards58.isNonEmptyString)(ariaLabel) || (0, import_type_guards58.isNonEmptyString)(ariaLabelledby))) {
13443
13765
  throw new Error(
13444
13766
  "UI Slider: Sliders should have an accessible name. Add a label using the aria-label or aria-labelledby prop."
13445
13767
  );
@@ -13450,12 +13772,12 @@ var Slider = ({
13450
13772
  onChange(newValue);
13451
13773
  }
13452
13774
  };
13453
- return /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(
13775
+ return /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(
13454
13776
  SliderContainer,
13455
13777
  {
13456
13778
  ...otherProps,
13457
13779
  "data-testid": dataTestId,
13458
- children: /* @__PURE__ */ (0, import_jsx_runtime268.jsxs)(
13780
+ children: /* @__PURE__ */ (0, import_jsx_runtime272.jsxs)(
13459
13781
  StyledSliderRoot,
13460
13782
  {
13461
13783
  "aria-label": ariaLabel,
@@ -13468,8 +13790,8 @@ var Slider = ({
13468
13790
  step,
13469
13791
  ...value ? { value } : {},
13470
13792
  children: [
13471
- /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(StyledSliderTrack, { "data-testid": `${dataTestId}-track`, children: /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(StyledSliderRange, { "data-testid": `${dataTestId}-range` }) }),
13472
- values.map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime268.jsx)(
13793
+ /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(StyledSliderTrack, { "data-testid": `${dataTestId}-track`, children: /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(StyledSliderRange, { "data-testid": `${dataTestId}-range` }) }),
13794
+ values.map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(
13473
13795
  StyledSliderThumb,
13474
13796
  {
13475
13797
  "data-testid": `${dataTestId}-thumb-${index}`
@@ -13485,11 +13807,11 @@ var Slider = ({
13485
13807
  Slider.displayName = "Slider";
13486
13808
 
13487
13809
  // src/components/Switch/Switch.tsx
13488
- var import_react68 = require("react");
13489
- var import_styled_components85 = __toESM(require("styled-components"));
13490
- var import_type_guards57 = require("@wistia/type-guards");
13491
- var import_jsx_runtime269 = require("react/jsx-runtime");
13492
- var sizeSmall3 = import_styled_components85.css`
13810
+ var import_react71 = require("react");
13811
+ var import_styled_components88 = __toESM(require("styled-components"));
13812
+ var import_type_guards59 = require("@wistia/type-guards");
13813
+ var import_jsx_runtime273 = require("react/jsx-runtime");
13814
+ var sizeSmall3 = import_styled_components88.css`
13493
13815
  --wui-size-small-width: 24px;
13494
13816
  --wui-size-small-height: 14px;
13495
13817
 
@@ -13504,7 +13826,7 @@ var sizeSmall3 = import_styled_components85.css`
13504
13826
  height: calc(var(--wui-size-small-width) / 2);
13505
13827
  }
13506
13828
  `;
13507
- var sizeMedium3 = import_styled_components85.css`
13829
+ var sizeMedium3 = import_styled_components88.css`
13508
13830
  --wui-size-medium-width: 32px;
13509
13831
  --wui-size-medium-height: 18px;
13510
13832
 
@@ -13519,7 +13841,7 @@ var sizeMedium3 = import_styled_components85.css`
13519
13841
  height: calc(var(--wui-size-medium-width) / 2);
13520
13842
  }
13521
13843
  `;
13522
- var sizeLarge3 = import_styled_components85.css`
13844
+ var sizeLarge3 = import_styled_components88.css`
13523
13845
  --wui-size-large-width: 40px;
13524
13846
  --wui-size-large-height: 22px;
13525
13847
 
@@ -13539,14 +13861,14 @@ var getSizeCss3 = (size) => {
13539
13861
  if (size === "lg") return sizeLarge3;
13540
13862
  return sizeMedium3;
13541
13863
  };
13542
- var StyledSwitchWrapper = import_styled_components85.default.div`
13864
+ var StyledSwitchWrapper = import_styled_components88.default.div`
13543
13865
  display: flex;
13544
13866
  margin: 0;
13545
13867
 
13546
13868
  /* TODO this solves a problem but potentially causes and a11y issue */
13547
13869
  user-select: none;
13548
13870
  `;
13549
- var StyledSwitchInput = import_styled_components85.default.div`
13871
+ var StyledSwitchInput = import_styled_components88.default.div`
13550
13872
  ${({ $size }) => getSizeCss3($size)}
13551
13873
  line-height: 0;
13552
13874
  margin: 0;
@@ -13574,7 +13896,7 @@ var StyledSwitchInput = import_styled_components85.default.div`
13574
13896
  transition: all 0.2s ease-in-out;
13575
13897
  }
13576
13898
  `;
13577
- var StyledHiddenSwitchInput = import_styled_components85.default.input`
13899
+ var StyledHiddenSwitchInput = import_styled_components88.default.input`
13578
13900
  ${visuallyHiddenStyle}
13579
13901
 
13580
13902
  /* toggles display of faux-input background-color and toggle position */
@@ -13590,7 +13912,7 @@ var StyledHiddenSwitchInput = import_styled_components85.default.input`
13590
13912
  }
13591
13913
  }
13592
13914
  `;
13593
- var Switch = (0, import_react68.forwardRef)(
13915
+ var Switch = (0, import_react71.forwardRef)(
13594
13916
  ({
13595
13917
  align = "left",
13596
13918
  checked,
@@ -13606,10 +13928,10 @@ var Switch = (0, import_react68.forwardRef)(
13606
13928
  hideLabel = false,
13607
13929
  ...props
13608
13930
  }, ref) => {
13609
- const generatedId = (0, import_react68.useId)();
13610
- const computedId = (0, import_type_guards57.isNonEmptyString)(id) ? id : `wistia-ui-switch-${generatedId}`;
13611
- return /* @__PURE__ */ (0, import_jsx_runtime269.jsxs)(StyledSwitchWrapper, { $disabled: disabled, children: [
13612
- /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(
13931
+ const generatedId = (0, import_react71.useId)();
13932
+ const computedId = (0, import_type_guards59.isNonEmptyString)(id) ? id : `wistia-ui-switch-${generatedId}`;
13933
+ return /* @__PURE__ */ (0, import_jsx_runtime273.jsxs)(StyledSwitchWrapper, { $disabled: disabled, children: [
13934
+ /* @__PURE__ */ (0, import_jsx_runtime273.jsx)(
13613
13935
  StyledHiddenSwitchInput,
13614
13936
  {
13615
13937
  ...props,
@@ -13624,11 +13946,11 @@ var Switch = (0, import_react68.forwardRef)(
13624
13946
  value
13625
13947
  }
13626
13948
  ),
13627
- /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(
13949
+ /* @__PURE__ */ (0, import_jsx_runtime273.jsx)(
13628
13950
  FormControlLabel,
13629
13951
  {
13630
13952
  align,
13631
- controlSlot: /* @__PURE__ */ (0, import_jsx_runtime269.jsx)(
13953
+ controlSlot: /* @__PURE__ */ (0, import_jsx_runtime273.jsx)(
13632
13954
  StyledSwitchInput,
13633
13955
  {
13634
13956
  $disabled: disabled,
@@ -13650,25 +13972,25 @@ var Switch = (0, import_react68.forwardRef)(
13650
13972
  Switch.displayName = "Switch";
13651
13973
 
13652
13974
  // src/components/Table/Table.tsx
13653
- var import_styled_components86 = __toESM(require("styled-components"));
13654
- var import_jsx_runtime270 = require("react/jsx-runtime");
13655
- var StyledTable = import_styled_components86.default.table`
13975
+ var import_styled_components89 = __toESM(require("styled-components"));
13976
+ var import_jsx_runtime274 = require("react/jsx-runtime");
13977
+ var StyledTable = import_styled_components89.default.table`
13656
13978
  width: 100%;
13657
13979
  border-collapse: collapse;
13658
13980
 
13659
- ${({ $divided }) => $divided && import_styled_components86.css`
13981
+ ${({ $divided }) => $divided && import_styled_components89.css`
13660
13982
  tr {
13661
13983
  border-bottom: 1px solid var(--wui-color-border);
13662
13984
  }
13663
13985
  `}
13664
13986
 
13665
- ${({ $striped }) => $striped && import_styled_components86.css`
13987
+ ${({ $striped }) => $striped && import_styled_components89.css`
13666
13988
  tbody tr:nth-child(even) {
13667
13989
  background-color: var(--wui-color-bg-surface-secondary);
13668
13990
  }
13669
13991
  `}
13670
13992
 
13671
- ${({ $visuallyHiddenHeader }) => $visuallyHiddenHeader && import_styled_components86.css`
13993
+ ${({ $visuallyHiddenHeader }) => $visuallyHiddenHeader && import_styled_components89.css`
13672
13994
  thead {
13673
13995
  ${visuallyHiddenStyle}
13674
13996
  }
@@ -13681,7 +14003,7 @@ var Table = ({
13681
14003
  visuallyHiddenHeader = false,
13682
14004
  ...props
13683
14005
  }) => {
13684
- return /* @__PURE__ */ (0, import_jsx_runtime270.jsx)(
14006
+ return /* @__PURE__ */ (0, import_jsx_runtime274.jsx)(
13685
14007
  StyledTable,
13686
14008
  {
13687
14009
  $divided: divided,
@@ -13694,83 +14016,83 @@ var Table = ({
13694
14016
  };
13695
14017
 
13696
14018
  // src/components/Table/TableBody.tsx
13697
- var import_styled_components87 = __toESM(require("styled-components"));
14019
+ var import_styled_components90 = __toESM(require("styled-components"));
13698
14020
 
13699
14021
  // src/components/Table/TableSectionContext.ts
13700
- var import_react69 = require("react");
13701
- var TableSectionContext = (0, import_react69.createContext)(null);
14022
+ var import_react72 = require("react");
14023
+ var TableSectionContext = (0, import_react72.createContext)(null);
13702
14024
 
13703
14025
  // src/components/Table/TableBody.tsx
13704
- var import_jsx_runtime271 = require("react/jsx-runtime");
13705
- var StyledTableBody = import_styled_components87.default.tbody``;
14026
+ var import_jsx_runtime275 = require("react/jsx-runtime");
14027
+ var StyledTableBody = import_styled_components90.default.tbody``;
13706
14028
  var TableBody = ({ children, ...props }) => {
13707
- return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(TableSectionContext.Provider, { value: "body", children: /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(StyledTableBody, { ...props, children }) });
14029
+ return /* @__PURE__ */ (0, import_jsx_runtime275.jsx)(TableSectionContext.Provider, { value: "body", children: /* @__PURE__ */ (0, import_jsx_runtime275.jsx)(StyledTableBody, { ...props, children }) });
13708
14030
  };
13709
14031
 
13710
14032
  // src/components/Table/TableCell.tsx
13711
- var import_react70 = require("react");
13712
- var import_styled_components88 = __toESM(require("styled-components"));
13713
- var import_jsx_runtime272 = require("react/jsx-runtime");
13714
- var sharedStyles = import_styled_components88.css`
14033
+ var import_react73 = require("react");
14034
+ var import_styled_components91 = __toESM(require("styled-components"));
14035
+ var import_jsx_runtime276 = require("react/jsx-runtime");
14036
+ var sharedStyles = import_styled_components91.css`
13715
14037
  color: var(--wui-color-text);
13716
14038
  padding: var(--wui-space-02);
13717
14039
  text-align: left;
13718
14040
  `;
13719
- var StyledTh = import_styled_components88.default.th`
14041
+ var StyledTh = import_styled_components91.default.th`
13720
14042
  ${sharedStyles}
13721
14043
  font-size: var(--wui-typography-body-4-size);
13722
14044
  font-weight: var(--wui-typography-weight-label-bold);
13723
14045
  line-height: var(--wui-typography-body-4-line-height);
13724
14046
  `;
13725
- var StyledTd = import_styled_components88.default.td`
14047
+ var StyledTd = import_styled_components91.default.td`
13726
14048
  ${sharedStyles}
13727
14049
  font-size: var(--wui-typography-body-2-size);
13728
14050
  font-weight: var(--wui-typography-body-2-weight);
13729
14051
  line-height: var(--wui-typography-body-2-line-height);
13730
14052
  `;
13731
14053
  var TableCell = ({ children, ...props }) => {
13732
- const section = (0, import_react70.useContext)(TableSectionContext);
14054
+ const section = (0, import_react73.useContext)(TableSectionContext);
13733
14055
  if (section === "head") {
13734
- return /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(StyledTh, { ...props, children });
14056
+ return /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(StyledTh, { ...props, children });
13735
14057
  }
13736
- return /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(StyledTd, { ...props, children });
14058
+ return /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(StyledTd, { ...props, children });
13737
14059
  };
13738
14060
 
13739
14061
  // src/components/Table/TableFoot.tsx
13740
- var import_styled_components89 = __toESM(require("styled-components"));
13741
- var import_jsx_runtime273 = require("react/jsx-runtime");
13742
- var StyledTableFoot = import_styled_components89.default.tfoot``;
14062
+ var import_styled_components92 = __toESM(require("styled-components"));
14063
+ var import_jsx_runtime277 = require("react/jsx-runtime");
14064
+ var StyledTableFoot = import_styled_components92.default.tfoot``;
13743
14065
  var TableFoot = ({ children, ...props }) => {
13744
- return /* @__PURE__ */ (0, import_jsx_runtime273.jsx)(TableSectionContext.Provider, { value: "footer", children: /* @__PURE__ */ (0, import_jsx_runtime273.jsx)(StyledTableFoot, { ...props, children }) });
14066
+ return /* @__PURE__ */ (0, import_jsx_runtime277.jsx)(TableSectionContext.Provider, { value: "footer", children: /* @__PURE__ */ (0, import_jsx_runtime277.jsx)(StyledTableFoot, { ...props, children }) });
13745
14067
  };
13746
14068
 
13747
14069
  // src/components/Table/TableHead.tsx
13748
- var import_styled_components90 = __toESM(require("styled-components"));
13749
- var import_jsx_runtime274 = require("react/jsx-runtime");
13750
- var StyledThead = import_styled_components90.default.thead``;
14070
+ var import_styled_components93 = __toESM(require("styled-components"));
14071
+ var import_jsx_runtime278 = require("react/jsx-runtime");
14072
+ var StyledThead = import_styled_components93.default.thead``;
13751
14073
  var TableHead = ({ children, ...props }) => {
13752
- return /* @__PURE__ */ (0, import_jsx_runtime274.jsx)(TableSectionContext.Provider, { value: "head", children: /* @__PURE__ */ (0, import_jsx_runtime274.jsx)(StyledThead, { ...props, children }) });
14074
+ return /* @__PURE__ */ (0, import_jsx_runtime278.jsx)(TableSectionContext.Provider, { value: "head", children: /* @__PURE__ */ (0, import_jsx_runtime278.jsx)(StyledThead, { ...props, children }) });
13753
14075
  };
13754
14076
 
13755
14077
  // src/components/Table/TableRow.tsx
13756
- var import_styled_components91 = __toESM(require("styled-components"));
13757
- var import_jsx_runtime275 = require("react/jsx-runtime");
13758
- var StyledTableRow = import_styled_components91.default.tr``;
14078
+ var import_styled_components94 = __toESM(require("styled-components"));
14079
+ var import_jsx_runtime279 = require("react/jsx-runtime");
14080
+ var StyledTableRow = import_styled_components94.default.tr``;
13759
14081
  var TableRow = ({ children, ...props }) => {
13760
- return /* @__PURE__ */ (0, import_jsx_runtime275.jsx)(StyledTableRow, { ...props, children });
14082
+ return /* @__PURE__ */ (0, import_jsx_runtime279.jsx)(StyledTableRow, { ...props, children });
13761
14083
  };
13762
14084
 
13763
14085
  // src/components/Tabs/Tabs.tsx
13764
14086
  var import_react_tabs = require("@radix-ui/react-tabs");
13765
- var import_react72 = require("react");
13766
- var import_type_guards58 = require("@wistia/type-guards");
14087
+ var import_react75 = require("react");
14088
+ var import_type_guards60 = require("@wistia/type-guards");
13767
14089
 
13768
14090
  // src/components/Tabs/useTabsValue.tsx
13769
- var import_react71 = require("react");
13770
- var TabsValueContext = (0, import_react71.createContext)(null);
14091
+ var import_react74 = require("react");
14092
+ var TabsValueContext = (0, import_react74.createContext)(null);
13771
14093
  var TabsValueProvider = TabsValueContext.Provider;
13772
14094
  var useTabsValue = () => {
13773
- const context = (0, import_react71.useContext)(TabsValueContext);
14095
+ const context = (0, import_react74.useContext)(TabsValueContext);
13774
14096
  if (context === null) {
13775
14097
  throw new Error("useTabsValue must be used within a TabsValueProvider");
13776
14098
  }
@@ -13778,7 +14100,7 @@ var useTabsValue = () => {
13778
14100
  };
13779
14101
 
13780
14102
  // src/components/Tabs/Tabs.tsx
13781
- var import_jsx_runtime276 = require("react/jsx-runtime");
14103
+ var import_jsx_runtime280 = require("react/jsx-runtime");
13782
14104
  var Tabs = ({
13783
14105
  children,
13784
14106
  value: valueProp,
@@ -13786,8 +14108,8 @@ var Tabs = ({
13786
14108
  defaultValue,
13787
14109
  ...props
13788
14110
  }) => {
13789
- const [value, setValue] = (0, import_react72.useState)(valueProp ?? defaultValue);
13790
- const onValueChange = (0, import_react72.useCallback)(
14111
+ const [value, setValue] = (0, import_react75.useState)(valueProp ?? defaultValue);
14112
+ const onValueChange = (0, import_react75.useCallback)(
13791
14113
  (newValue) => {
13792
14114
  setValue(newValue);
13793
14115
  if (onValueChangeProp) {
@@ -13800,48 +14122,48 @@ var Tabs = ({
13800
14122
  ...props,
13801
14123
  onValueChange
13802
14124
  };
13803
- if ((0, import_type_guards58.isNotNil)(value)) {
14125
+ if ((0, import_type_guards60.isNotNil)(value)) {
13804
14126
  rootProps.value = value;
13805
14127
  }
13806
- if ((0, import_type_guards58.isNotNil)(defaultValue)) {
14128
+ if ((0, import_type_guards60.isNotNil)(defaultValue)) {
13807
14129
  rootProps.defaultValue = defaultValue;
13808
14130
  }
13809
- return /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(import_react_tabs.Root, { ...rootProps, children: /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(TabsValueProvider, { value: value ?? defaultValue, children: /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(SelectedItemStyleProvider, { children }) }) });
14131
+ return /* @__PURE__ */ (0, import_jsx_runtime280.jsx)(import_react_tabs.Root, { ...rootProps, children: /* @__PURE__ */ (0, import_jsx_runtime280.jsx)(TabsValueProvider, { value: value ?? defaultValue, children: /* @__PURE__ */ (0, import_jsx_runtime280.jsx)(SelectedItemStyleProvider, { children }) }) });
13810
14132
  };
13811
14133
  Tabs.displayName = "Tabs";
13812
14134
 
13813
14135
  // src/components/Tabs/TabsContent.tsx
13814
14136
  var import_react_tabs2 = require("@radix-ui/react-tabs");
13815
- var import_jsx_runtime277 = require("react/jsx-runtime");
14137
+ var import_jsx_runtime281 = require("react/jsx-runtime");
13816
14138
  var TabsContent = ({ children, value }) => {
13817
- return /* @__PURE__ */ (0, import_jsx_runtime277.jsx)(import_react_tabs2.Content, { value, children });
14139
+ return /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(import_react_tabs2.Content, { value, children });
13818
14140
  };
13819
14141
  TabsContent.displayName = "TabsContent";
13820
14142
 
13821
14143
  // src/components/Tabs/TabsList.tsx
13822
14144
  var import_react_tabs3 = require("@radix-ui/react-tabs");
13823
- var import_styled_components93 = __toESM(require("styled-components"));
14145
+ var import_styled_components96 = __toESM(require("styled-components"));
13824
14146
 
13825
14147
  // src/components/Tabs/SelectedTabIndicator.tsx
13826
- var import_type_guards59 = require("@wistia/type-guards");
14148
+ var import_type_guards61 = require("@wistia/type-guards");
13827
14149
 
13828
14150
  // src/components/Tabs/TabsSelectedItemIndicatorDiv.tsx
13829
- var import_styled_components92 = __toESM(require("styled-components"));
13830
- var TabsSelectedItemIndicatorDiv = (0, import_styled_components92.default)(SelectedItemIndicatorDiv)`
14151
+ var import_styled_components95 = __toESM(require("styled-components"));
14152
+ var TabsSelectedItemIndicatorDiv = (0, import_styled_components95.default)(SelectedItemIndicatorDiv)`
13831
14153
  &:has(~ button[role='tab']:focus-visible) {
13832
14154
  outline: 2px solid var(--wui-color-focus-ring);
13833
14155
  }
13834
14156
  `;
13835
14157
 
13836
14158
  // src/components/Tabs/SelectedTabIndicator.tsx
13837
- var import_jsx_runtime278 = require("react/jsx-runtime");
14159
+ var import_jsx_runtime282 = require("react/jsx-runtime");
13838
14160
  var SelectedTabIndicator = () => {
13839
14161
  const { selectedItemIndicatorStyle } = useSelectedItemStyle();
13840
14162
  const selectedValue = useTabsValue();
13841
- if (selectedValue == null || (0, import_type_guards59.isUndefined)(selectedItemIndicatorStyle)) {
14163
+ if (selectedValue == null || (0, import_type_guards61.isUndefined)(selectedItemIndicatorStyle)) {
13842
14164
  return null;
13843
14165
  }
13844
- return /* @__PURE__ */ (0, import_jsx_runtime278.jsx)(
14166
+ return /* @__PURE__ */ (0, import_jsx_runtime282.jsx)(
13845
14167
  TabsSelectedItemIndicatorDiv,
13846
14168
  {
13847
14169
  "data-wui-selected-item-indicator": true,
@@ -13851,19 +14173,19 @@ var SelectedTabIndicator = () => {
13851
14173
  };
13852
14174
 
13853
14175
  // src/components/Tabs/TabsList.tsx
13854
- var import_jsx_runtime279 = require("react/jsx-runtime");
13855
- var StyledRadixTabsList = (0, import_styled_components93.default)(import_react_tabs3.List)`
14176
+ var import_jsx_runtime283 = require("react/jsx-runtime");
14177
+ var StyledRadixTabsList = (0, import_styled_components96.default)(import_react_tabs3.List)`
13856
14178
  ${segmentedControlStyles}
13857
14179
  `;
13858
14180
  var TabsList = ({ children, fullWidth = true, ...props }) => {
13859
- return /* @__PURE__ */ (0, import_jsx_runtime279.jsxs)(
14181
+ return /* @__PURE__ */ (0, import_jsx_runtime283.jsxs)(
13860
14182
  StyledRadixTabsList,
13861
14183
  {
13862
14184
  $fullWidth: fullWidth,
13863
14185
  "aria-label": props["aria-label"],
13864
14186
  children: [
13865
14187
  children,
13866
- /* @__PURE__ */ (0, import_jsx_runtime279.jsx)(SelectedTabIndicator, {})
14188
+ /* @__PURE__ */ (0, import_jsx_runtime283.jsx)(SelectedTabIndicator, {})
13867
14189
  ]
13868
14190
  }
13869
14191
  );
@@ -13871,13 +14193,13 @@ var TabsList = ({ children, fullWidth = true, ...props }) => {
13871
14193
  TabsList.displayName = "TabsList";
13872
14194
 
13873
14195
  // src/components/Tabs/TabsTrigger.tsx
13874
- var import_react73 = require("react");
13875
- var import_type_guards60 = require("@wistia/type-guards");
14196
+ var import_react76 = require("react");
14197
+ var import_type_guards62 = require("@wistia/type-guards");
13876
14198
 
13877
14199
  // src/components/Tabs/StyledRadixTabsTrigger.tsx
13878
- var import_styled_components94 = __toESM(require("styled-components"));
14200
+ var import_styled_components97 = __toESM(require("styled-components"));
13879
14201
  var import_react_tabs4 = require("@radix-ui/react-tabs");
13880
- var StyledRadixTabsTrigger = (0, import_styled_components94.default)(import_react_tabs4.Trigger)`
14202
+ var StyledRadixTabsTrigger = (0, import_styled_components97.default)(import_react_tabs4.Trigger)`
13881
14203
  ${segmentedControlItemStyles}
13882
14204
 
13883
14205
  &:focus-visible {
@@ -13886,14 +14208,14 @@ var StyledRadixTabsTrigger = (0, import_styled_components94.default)(import_reac
13886
14208
  `;
13887
14209
 
13888
14210
  // src/components/Tabs/TabsTrigger.tsx
13889
- var import_jsx_runtime280 = require("react/jsx-runtime");
13890
- var TabsTrigger = (0, import_react73.forwardRef)(
14211
+ var import_jsx_runtime284 = require("react/jsx-runtime");
14212
+ var TabsTrigger = (0, import_react76.forwardRef)(
13891
14213
  ({ disabled = false, icon, label, "aria-label": ariaLabel, value, ...otherProps }, forwardedRef) => {
13892
14214
  const selectedValue = useTabsValue();
13893
14215
  const { setSelectedItemMeasurements } = useSelectedItemStyle();
13894
- const buttonRef = (0, import_react73.useRef)(null);
14216
+ const buttonRef = (0, import_react76.useRef)(null);
13895
14217
  const combinedRef = mergeRefs([buttonRef, forwardedRef]);
13896
- (0, import_react73.useEffect)(() => {
14218
+ (0, import_react76.useEffect)(() => {
13897
14219
  const buttonElem = buttonRef.current;
13898
14220
  if (!buttonElem) {
13899
14221
  return void 0;
@@ -13918,13 +14240,13 @@ var TabsTrigger = (0, import_react73.forwardRef)(
13918
14240
  resizeObserver.disconnect();
13919
14241
  };
13920
14242
  }, [selectedValue, setSelectedItemMeasurements, value]);
13921
- return /* @__PURE__ */ (0, import_jsx_runtime280.jsxs)(
14243
+ return /* @__PURE__ */ (0, import_jsx_runtime284.jsxs)(
13922
14244
  StyledRadixTabsTrigger,
13923
14245
  {
13924
14246
  ...otherProps,
13925
14247
  ref: combinedRef,
13926
- $hasLabel: (0, import_type_guards60.isNotNil)(label),
13927
- "aria-label": (0, import_type_guards60.isNotNil)(label) ? void 0 : ariaLabel,
14248
+ $hasLabel: (0, import_type_guards62.isNotNil)(label),
14249
+ "aria-label": (0, import_type_guards62.isNotNil)(label) ? void 0 : ariaLabel,
13928
14250
  disabled,
13929
14251
  value,
13930
14252
  children: [
@@ -13938,10 +14260,10 @@ var TabsTrigger = (0, import_react73.forwardRef)(
13938
14260
  TabsTrigger.displayName = "TabsTrigger";
13939
14261
 
13940
14262
  // src/components/Thumbnail/ThumbnailBadge.tsx
13941
- var import_styled_components95 = __toESM(require("styled-components"));
13942
- var import_type_guards61 = require("@wistia/type-guards");
13943
- var import_jsx_runtime281 = require("react/jsx-runtime");
13944
- var StyledThumbnailBadge = import_styled_components95.default.div`
14263
+ var import_styled_components98 = __toESM(require("styled-components"));
14264
+ var import_type_guards63 = require("@wistia/type-guards");
14265
+ var import_jsx_runtime285 = require("react/jsx-runtime");
14266
+ var StyledThumbnailBadge = import_styled_components98.default.div`
13945
14267
  align-items: center;
13946
14268
  background-color: rgb(0 0 0 / 50%);
13947
14269
  border-radius: var(--wui-border-radius-01);
@@ -13966,23 +14288,23 @@ var StyledThumbnailBadge = import_styled_components95.default.div`
13966
14288
  }
13967
14289
  `;
13968
14290
  var ThumbnailBadge = ({ icon, label, ...props }) => {
13969
- return /* @__PURE__ */ (0, import_jsx_runtime281.jsxs)(StyledThumbnailBadge, { ...props, children: [
13970
- (0, import_type_guards61.isNotNil)(icon) && icon,
13971
- /* @__PURE__ */ (0, import_jsx_runtime281.jsx)("span", { children: label })
14291
+ return /* @__PURE__ */ (0, import_jsx_runtime285.jsxs)(StyledThumbnailBadge, { ...props, children: [
14292
+ (0, import_type_guards63.isNotNil)(icon) && icon,
14293
+ /* @__PURE__ */ (0, import_jsx_runtime285.jsx)("span", { children: label })
13972
14294
  ] });
13973
14295
  };
13974
14296
  ThumbnailBadge.displayName = "ThumbnailBadge";
13975
14297
 
13976
14298
  // src/components/Thumbnail/Thumbnail.tsx
13977
- var import_react74 = require("react");
13978
- var import_styled_components98 = __toESM(require("styled-components"));
13979
- var import_type_guards64 = require("@wistia/type-guards");
14299
+ var import_react77 = require("react");
14300
+ var import_styled_components101 = __toESM(require("styled-components"));
14301
+ var import_type_guards66 = require("@wistia/type-guards");
13980
14302
 
13981
14303
  // src/private/helpers/getBackgroundGradient/getBackgroundGradient.ts
13982
- var import_type_guards62 = require("@wistia/type-guards");
13983
- var import_styled_components96 = require("styled-components");
14304
+ var import_type_guards64 = require("@wistia/type-guards");
14305
+ var import_styled_components99 = require("styled-components");
13984
14306
  var gradients = {
13985
- defaultDarkOne: import_styled_components96.css`
14307
+ defaultDarkOne: import_styled_components99.css`
13986
14308
  background-color: #222d66;
13987
14309
  background-image:
13988
14310
  radial-gradient(farthest-corner at top right, #222d66, transparent 70%),
@@ -13990,7 +14312,7 @@ var gradients = {
13990
14312
  radial-gradient(farthest-corner at bottom left, #6b84ff, transparent 57%),
13991
14313
  radial-gradient(farthest-corner at top left, #2949e5, transparent 68%);
13992
14314
  `,
13993
- defaultDarkTwo: import_styled_components96.css`
14315
+ defaultDarkTwo: import_styled_components99.css`
13994
14316
  background-color: #222d66;
13995
14317
  background-image:
13996
14318
  radial-gradient(farthest-corner at top left, #6b84ff, transparent 100%),
@@ -13998,7 +14320,7 @@ var gradients = {
13998
14320
  radial-gradient(farthest-corner at bottom right, #2949e5, transparent 50%),
13999
14321
  radial-gradient(farthest-corner at top right, #2949e5, transparent 70%);
14000
14322
  `,
14001
- defaultLightOne: import_styled_components96.css`
14323
+ defaultLightOne: import_styled_components99.css`
14002
14324
  background-color: #ccd5ff;
14003
14325
  background-image:
14004
14326
  radial-gradient(farthest-corner at bottom right, #ccd5ff, transparent 55%),
@@ -14006,13 +14328,13 @@ var gradients = {
14006
14328
  radial-gradient(farthest-corner at top right, #6b84ff, transparent 50%),
14007
14329
  radial-gradient(farthest-corner at bottom left, #f7f8ff, transparent 50%);
14008
14330
  `,
14009
- defaultLightTwo: import_styled_components96.css`
14331
+ defaultLightTwo: import_styled_components99.css`
14010
14332
  background-color: #ccd5ff;
14011
14333
  background-image:
14012
14334
  radial-gradient(ellipse at top, #ccd5ff, transparent),
14013
14335
  radial-gradient(ellipse at bottom, #6b84ff, transparent);
14014
14336
  `,
14015
- defaultMidOne: import_styled_components96.css`
14337
+ defaultMidOne: import_styled_components99.css`
14016
14338
  background-color: #6b84ff;
14017
14339
  background-image:
14018
14340
  radial-gradient(farthest-corner at top right, #2949e5, transparent 70%),
@@ -14020,13 +14342,13 @@ var gradients = {
14020
14342
  radial-gradient(farthest-corner at top left, #6b84ff, transparent 80%),
14021
14343
  radial-gradient(farthest-corner at bottom left, #222d66, transparent 57%);
14022
14344
  `,
14023
- defaultMidTwo: import_styled_components96.css`
14345
+ defaultMidTwo: import_styled_components99.css`
14024
14346
  background-color: #6b84ff;
14025
14347
  background-image:
14026
14348
  radial-gradient(ellipse at top, #2949e5, transparent),
14027
14349
  radial-gradient(ellipse at bottom, #ccd5ff, transparent);
14028
14350
  `,
14029
- green: import_styled_components96.css`
14351
+ green: import_styled_components99.css`
14030
14352
  background-color: #fafffa;
14031
14353
  background-image:
14032
14354
  radial-gradient(farthest-corner at bottom left, #b0e5a5, transparent 50%),
@@ -14034,7 +14356,7 @@ var gradients = {
14034
14356
  radial-gradient(farthest-corner at top left, #44b62d, transparent 65%),
14035
14357
  radial-gradient(farthest-corner at bottom right, #44b62d, transparent 55%);
14036
14358
  `,
14037
- greenWithPop: import_styled_components96.css`
14359
+ greenWithPop: import_styled_components99.css`
14038
14360
  background-color: #fafffa;
14039
14361
  background-image:
14040
14362
  radial-gradient(farthest-corner at bottom left, #b0e5a5, transparent 50%),
@@ -14042,7 +14364,7 @@ var gradients = {
14042
14364
  radial-gradient(farthest-corner at top left, #44b62d, transparent 65%),
14043
14365
  radial-gradient(farthest-corner at bottom right, #44b62d, transparent 55%);
14044
14366
  `,
14045
- pink: import_styled_components96.css`
14367
+ pink: import_styled_components99.css`
14046
14368
  background-color: #fffff0;
14047
14369
  background-image:
14048
14370
  radial-gradient(farthest-corner at bottom left, #ffc7e8, transparent 50%),
@@ -14050,7 +14372,7 @@ var gradients = {
14050
14372
  radial-gradient(farthest-corner at top left, #ff40b3, transparent 65%),
14051
14373
  radial-gradient(farthest-corner at bottom right, #ff40b3, transparent 55%);
14052
14374
  `,
14053
- pinkWithPop: import_styled_components96.css`
14375
+ pinkWithPop: import_styled_components99.css`
14054
14376
  background-color: #fffff0;
14055
14377
  background-image:
14056
14378
  radial-gradient(farthest-corner at top right, #e0128e, transparent 70%),
@@ -14058,7 +14380,7 @@ var gradients = {
14058
14380
  radial-gradient(farthest-corner at bottom right, #ff40b3, transparent 55%),
14059
14381
  radial-gradient(farthest-corner at bottom left, #2949e5, transparent 50%);
14060
14382
  `,
14061
- playfulGradientOne: import_styled_components96.css`
14383
+ playfulGradientOne: import_styled_components99.css`
14062
14384
  background-color: #f7f8ff;
14063
14385
  background-image:
14064
14386
  radial-gradient(farthest-corner at top left, #d65cff, transparent 68%),
@@ -14066,7 +14388,7 @@ var gradients = {
14066
14388
  radial-gradient(farthest-corner at bottom left, #ffc7e8, transparent 57%),
14067
14389
  radial-gradient(farthest-corner at top right, #ffcaba, transparent 70%);
14068
14390
  `,
14069
- playfulGradientTwo: import_styled_components96.css`
14391
+ playfulGradientTwo: import_styled_components99.css`
14070
14392
  background-color: #f7f8ff;
14071
14393
  background-image:
14072
14394
  radial-gradient(farthest-corner at top left, #44b62d, transparent 68%),
@@ -14074,13 +14396,13 @@ var gradients = {
14074
14396
  radial-gradient(farthest-corner at bottom left, #ccd5ff, transparent 57%),
14075
14397
  radial-gradient(farthest-corner at top right, #2949e5, transparent 70%);
14076
14398
  `,
14077
- purple: import_styled_components96.css`
14399
+ purple: import_styled_components99.css`
14078
14400
  background-color: #f2caff;
14079
14401
  background-image:
14080
14402
  radial-gradient(ellipse at 0% 100%, #f9e5ff, transparent 50%),
14081
14403
  radial-gradient(ellipse at 100% 0%, #e093fa, transparent 70%);
14082
14404
  `,
14083
- purpleWithPop: import_styled_components96.css`
14405
+ purpleWithPop: import_styled_components99.css`
14084
14406
  background-color: #f2caff;
14085
14407
  background-image:
14086
14408
  radial-gradient(farthest-corner at bottom left, #f2caff, transparent 50%),
@@ -14088,7 +14410,7 @@ var gradients = {
14088
14410
  radial-gradient(farthest-corner at bottom right, #d65cff, transparent 55%),
14089
14411
  radial-gradient(farthest-corner at top right, #2949e5, transparent 70%);
14090
14412
  `,
14091
- yellow: import_styled_components96.css`
14413
+ yellow: import_styled_components99.css`
14092
14414
  background-color: #fffff0;
14093
14415
  background-image:
14094
14416
  radial-gradient(farthest-corner at bottom left, #eff18d, transparent 50%),
@@ -14096,7 +14418,7 @@ var gradients = {
14096
14418
  radial-gradient(farthest-corner at top left, #e8ec1e, transparent 65%),
14097
14419
  radial-gradient(farthest-corner at bottom right, #e8ec1e, transparent 55%);
14098
14420
  `,
14099
- yellowWithPop: import_styled_components96.css`
14421
+ yellowWithPop: import_styled_components99.css`
14100
14422
  background-color: #fffff0;
14101
14423
  background-image:
14102
14424
  radial-gradient(farthest-corner at bottom left, #eff18d, transparent 50%),
@@ -14107,14 +14429,14 @@ var gradients = {
14107
14429
  };
14108
14430
  var gradientMap = Object.keys(gradients);
14109
14431
  var getBackgroundGradient = (gradientName = void 0) => {
14110
- return (0, import_type_guards62.isNotNil)(gradientName) ? gradients[gradientName] : gradients.defaultDarkOne;
14432
+ return (0, import_type_guards64.isNotNil)(gradientName) ? gradients[gradientName] : gradients.defaultDarkOne;
14111
14433
  };
14112
14434
 
14113
14435
  // src/components/Thumbnail/ThumbnailStoryboardViewer.tsx
14114
- var import_styled_components97 = __toESM(require("styled-components"));
14115
- var import_type_guards63 = require("@wistia/type-guards");
14116
- var import_jsx_runtime282 = require("react/jsx-runtime");
14117
- var ScrubLine = import_styled_components97.default.div`
14436
+ var import_styled_components100 = __toESM(require("styled-components"));
14437
+ var import_type_guards65 = require("@wistia/type-guards");
14438
+ var import_jsx_runtime286 = require("react/jsx-runtime");
14439
+ var ScrubLine = import_styled_components100.default.div`
14118
14440
  position: absolute;
14119
14441
  top: 0;
14120
14442
  height: 100%;
@@ -14198,8 +14520,8 @@ var ThumbnailStoryboardViewer = ({
14198
14520
  );
14199
14521
  const backgroundSize = `${scaledStoryboardWidth}px ${scaledStoryboardHeight}px`;
14200
14522
  const backgroundImage = `url(${storyboardUrl})`;
14201
- const showScrubLine = (0, import_type_guards63.isNotNil)(cursorPosition);
14202
- const scrubLinePosition = (0, import_type_guards63.isNotNil)(cursorPosition) ? `${cursorPosition - 1}px` : "0";
14523
+ const showScrubLine = (0, import_type_guards65.isNotNil)(cursorPosition);
14524
+ const scrubLinePosition = (0, import_type_guards65.isNotNil)(cursorPosition) ? `${cursorPosition - 1}px` : "0";
14203
14525
  const viewerStyles = {
14204
14526
  position: "relative",
14205
14527
  overflow: "hidden",
@@ -14217,14 +14539,14 @@ var ThumbnailStoryboardViewer = ({
14217
14539
  backgroundPosition,
14218
14540
  backgroundSize
14219
14541
  };
14220
- return /* @__PURE__ */ (0, import_jsx_runtime282.jsxs)(
14542
+ return /* @__PURE__ */ (0, import_jsx_runtime286.jsxs)(
14221
14543
  "div",
14222
14544
  {
14223
14545
  ...props,
14224
14546
  style: viewerStyles,
14225
14547
  children: [
14226
- /* @__PURE__ */ (0, import_jsx_runtime282.jsx)("div", { style: storyboardStyles }),
14227
- showScrubLine ? /* @__PURE__ */ (0, import_jsx_runtime282.jsx)(
14548
+ /* @__PURE__ */ (0, import_jsx_runtime286.jsx)("div", { style: storyboardStyles }),
14549
+ showScrubLine ? /* @__PURE__ */ (0, import_jsx_runtime286.jsx)(
14228
14550
  ScrubLine,
14229
14551
  {
14230
14552
  style: {
@@ -14238,20 +14560,20 @@ var ThumbnailStoryboardViewer = ({
14238
14560
  };
14239
14561
 
14240
14562
  // src/components/Thumbnail/Thumbnail.tsx
14241
- var import_jsx_runtime283 = require("react/jsx-runtime");
14242
- var WideThumbnailImage = import_styled_components98.default.img`
14563
+ var import_jsx_runtime287 = require("react/jsx-runtime");
14564
+ var WideThumbnailImage = import_styled_components101.default.img`
14243
14565
  height: 100%;
14244
14566
  object-fit: cover;
14245
14567
  width: 100%;
14246
14568
  `;
14247
- var SquareThumbnailImage = import_styled_components98.default.img`
14569
+ var SquareThumbnailImage = import_styled_components101.default.img`
14248
14570
  backdrop-filter: blur(8px);
14249
14571
  object-fit: contain;
14250
14572
  width: 100%;
14251
14573
  `;
14252
14574
  var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
14253
14575
  if (thumbnailImageType === "wide") {
14254
- return /* @__PURE__ */ (0, import_jsx_runtime283.jsx)(
14576
+ return /* @__PURE__ */ (0, import_jsx_runtime287.jsx)(
14255
14577
  WideThumbnailImage,
14256
14578
  {
14257
14579
  alt: "",
@@ -14260,7 +14582,7 @@ var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
14260
14582
  }
14261
14583
  );
14262
14584
  }
14263
- return /* @__PURE__ */ (0, import_jsx_runtime283.jsx)(
14585
+ return /* @__PURE__ */ (0, import_jsx_runtime287.jsx)(
14264
14586
  SquareThumbnailImage,
14265
14587
  {
14266
14588
  alt: "",
@@ -14269,11 +14591,11 @@ var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
14269
14591
  }
14270
14592
  );
14271
14593
  };
14272
- var StyledThumbnail = import_styled_components98.default.div`
14273
- background-image: ${({ $backgroundUrl }) => (0, import_type_guards64.isNotNil)($backgroundUrl) ? `url('${$backgroundUrl}')` : void 0};
14594
+ var StyledThumbnail = import_styled_components101.default.div`
14595
+ background-image: ${({ $backgroundUrl }) => (0, import_type_guards66.isNotNil)($backgroundUrl) ? `url('${$backgroundUrl}')` : void 0};
14274
14596
  ${({ $backgroundUrl, $gradientBackground }) => (
14275
14597
  // if we don't have $backgroundUrl show a gradient
14276
- (0, import_type_guards64.isNil)($backgroundUrl) ? getBackgroundGradient($gradientBackground) : void 0
14598
+ (0, import_type_guards66.isNil)($backgroundUrl) ? getBackgroundGradient($gradientBackground) : void 0
14277
14599
  )};
14278
14600
  background-position: center center;
14279
14601
  background-size: cover;
@@ -14298,7 +14620,7 @@ var getRelativeMousePosition = (elem, mouseEvent) => {
14298
14620
  left: relativeLeft
14299
14621
  };
14300
14622
  };
14301
- var Thumbnail = (0, import_react74.forwardRef)(
14623
+ var Thumbnail = (0, import_react77.forwardRef)(
14302
14624
  ({
14303
14625
  gradientBackground = "defaultMidOne",
14304
14626
  thumbnailImageType = "wide",
@@ -14309,17 +14631,17 @@ var Thumbnail = (0, import_react74.forwardRef)(
14309
14631
  height,
14310
14632
  ...props
14311
14633
  }, ref) => {
14312
- const [percent, setPercent] = (0, import_react74.useState)(0);
14313
- const [isMouseOver, setIsMouseOver] = (0, import_react74.useState)(false);
14314
- const [isStoryboardReady, setIsStoryboardReady] = (0, import_react74.useState)(false);
14315
- const storyboardElementRef = (0, import_react74.useRef)(null);
14316
- const [cursorPosition, setCursorPosition] = (0, import_react74.useState)(null);
14317
- const backgroundUrl = (0, import_react74.useMemo)(
14318
- () => thumbnailImageType === "square" && (0, import_type_guards64.isNotNil)(thumbnailUrl) ? thumbnailUrl : void 0,
14634
+ const [percent, setPercent] = (0, import_react77.useState)(0);
14635
+ const [isMouseOver, setIsMouseOver] = (0, import_react77.useState)(false);
14636
+ const [isStoryboardReady, setIsStoryboardReady] = (0, import_react77.useState)(false);
14637
+ const storyboardElementRef = (0, import_react77.useRef)(null);
14638
+ const [cursorPosition, setCursorPosition] = (0, import_react77.useState)(null);
14639
+ const backgroundUrl = (0, import_react77.useMemo)(
14640
+ () => thumbnailImageType === "square" && (0, import_type_guards66.isNotNil)(thumbnailUrl) ? thumbnailUrl : void 0,
14319
14641
  [thumbnailImageType, thumbnailUrl]
14320
14642
  );
14321
- const isScrubbable = (0, import_type_guards64.isNotNil)(storyboard);
14322
- const trackStoryboardLoadStatus = (0, import_react74.useCallback)(() => {
14643
+ const isScrubbable = (0, import_type_guards66.isNotNil)(storyboard);
14644
+ const trackStoryboardLoadStatus = (0, import_react77.useCallback)(() => {
14323
14645
  if (storyboardElementRef.current || !storyboard) {
14324
14646
  return storyboardElementRef.current;
14325
14647
  }
@@ -14329,7 +14651,7 @@ var Thumbnail = (0, import_react74.forwardRef)(
14329
14651
  storyboardElementRef.current = asset;
14330
14652
  return storyboardElementRef.current;
14331
14653
  }, [storyboard]);
14332
- const handleMouseMove = (0, import_react74.useCallback)(
14654
+ const handleMouseMove = (0, import_react77.useCallback)(
14333
14655
  (mouseEvent) => {
14334
14656
  if (!isScrubbable) return;
14335
14657
  const elem = mouseEvent.currentTarget;
@@ -14342,16 +14664,16 @@ var Thumbnail = (0, import_react74.forwardRef)(
14342
14664
  },
14343
14665
  [isScrubbable, trackStoryboardLoadStatus]
14344
14666
  );
14345
- const handleMouseOut = (0, import_react74.useCallback)(() => {
14667
+ const handleMouseOut = (0, import_react77.useCallback)(() => {
14346
14668
  if (!isScrubbable) return;
14347
14669
  setIsMouseOver(false);
14348
14670
  setCursorPosition(null);
14349
14671
  }, [isScrubbable]);
14350
- const shouldRenderStoryboard = (0, import_react74.useMemo)(() => {
14672
+ const shouldRenderStoryboard = (0, import_react77.useMemo)(() => {
14351
14673
  return Boolean(isScrubbable && isMouseOver && isStoryboardReady);
14352
14674
  }, [isScrubbable, isMouseOver, isStoryboardReady]);
14353
- const renderStoryboard = (0, import_react74.useCallback)(() => {
14354
- if (!storyboard || (0, import_type_guards64.isUndefined)(height) || (0, import_type_guards64.isEmptyString)(height)) return null;
14675
+ const renderStoryboard = (0, import_react77.useCallback)(() => {
14676
+ if (!storyboard || (0, import_type_guards66.isUndefined)(height) || (0, import_type_guards66.isEmptyString)(height)) return null;
14355
14677
  const {
14356
14678
  url,
14357
14679
  width: sbWidth,
@@ -14361,9 +14683,9 @@ var Thumbnail = (0, import_react74.forwardRef)(
14361
14683
  frameCount,
14362
14684
  aspectRatio
14363
14685
  } = storyboard;
14364
- const targetWidth = (0, import_type_guards64.isString)(width) ? parseInt(width, 10) : Number(width);
14686
+ const targetWidth = (0, import_type_guards66.isString)(width) ? parseInt(width, 10) : Number(width);
14365
14687
  const effectiveCursorPosition = isStoryboardReady ? cursorPosition : null;
14366
- return /* @__PURE__ */ (0, import_jsx_runtime283.jsx)(
14688
+ return /* @__PURE__ */ (0, import_jsx_runtime287.jsx)(
14367
14689
  ThumbnailStoryboardViewer,
14368
14690
  {
14369
14691
  cursorPosition: effectiveCursorPosition,
@@ -14382,8 +14704,8 @@ var Thumbnail = (0, import_react74.forwardRef)(
14382
14704
  let thumbnailContent = null;
14383
14705
  if (shouldRenderStoryboard) {
14384
14706
  thumbnailContent = renderStoryboard();
14385
- } else if ((0, import_type_guards64.isNotNil)(thumbnailUrl)) {
14386
- thumbnailContent = /* @__PURE__ */ (0, import_jsx_runtime283.jsx)(
14707
+ } else if ((0, import_type_guards66.isNotNil)(thumbnailUrl)) {
14708
+ thumbnailContent = /* @__PURE__ */ (0, import_jsx_runtime287.jsx)(
14387
14709
  ThumbnailImage,
14388
14710
  {
14389
14711
  thumbnailImageType,
@@ -14393,7 +14715,7 @@ var Thumbnail = (0, import_react74.forwardRef)(
14393
14715
  } else {
14394
14716
  thumbnailContent = null;
14395
14717
  }
14396
- return /* @__PURE__ */ (0, import_jsx_runtime283.jsxs)(
14718
+ return /* @__PURE__ */ (0, import_jsx_runtime287.jsxs)(
14397
14719
  StyledThumbnail,
14398
14720
  {
14399
14721
  ref,
@@ -14407,7 +14729,7 @@ var Thumbnail = (0, import_react74.forwardRef)(
14407
14729
  onMouseOut: handleMouseOut,
14408
14730
  role: "presentation",
14409
14731
  children: [
14410
- (0, import_type_guards64.isNotNil)(children) ? children : null,
14732
+ (0, import_type_guards66.isNotNil)(children) ? children : null,
14411
14733
  thumbnailContent
14412
14734
  ]
14413
14735
  }
@@ -14417,14 +14739,14 @@ var Thumbnail = (0, import_react74.forwardRef)(
14417
14739
  Thumbnail.displayName = "Thumbnail";
14418
14740
 
14419
14741
  // src/components/ThumbnailCollage/ThumbnailCollage.tsx
14420
- var import_react75 = __toESM(require("react"));
14421
- var import_styled_components99 = __toESM(require("styled-components"));
14422
- var import_type_guards65 = require("@wistia/type-guards");
14423
- var import_jsx_runtime284 = (
14742
+ var import_react78 = __toESM(require("react"));
14743
+ var import_styled_components102 = __toESM(require("styled-components"));
14744
+ var import_type_guards67 = require("@wistia/type-guards");
14745
+ var import_jsx_runtime288 = (
14424
14746
  // ThumbnailCollage will fallback to a Thumbnail with a gradient background if no children are provided
14425
14747
  require("react/jsx-runtime")
14426
14748
  );
14427
- var StyledThumbnailCollage = import_styled_components99.default.div`
14749
+ var StyledThumbnailCollage = import_styled_components102.default.div`
14428
14750
  display: grid;
14429
14751
  gap: var(--wui-space-01);
14430
14752
  width: 100%;
@@ -14497,15 +14819,15 @@ var ThumbnailCollage = ({
14497
14819
  gradientBackground = "defaultMidOne",
14498
14820
  ...props
14499
14821
  }) => {
14500
- const thumbnailArray = import_react75.default.Children.toArray(children);
14822
+ const thumbnailArray = import_react78.default.Children.toArray(children);
14501
14823
  const truncatedThumbnails = thumbnailArray.slice(0, 3);
14502
- const thumbnails = (0, import_type_guards65.isNonEmptyArray)(thumbnailArray) ? truncatedThumbnails.map((child) => {
14503
- return import_react75.default.cloneElement(child, {
14824
+ const thumbnails = (0, import_type_guards67.isNonEmptyArray)(thumbnailArray) ? truncatedThumbnails.map((child) => {
14825
+ return import_react78.default.cloneElement(child, {
14504
14826
  ...child.props,
14505
14827
  children: void 0
14506
14828
  });
14507
14829
  }) : [
14508
- /* @__PURE__ */ (0, import_jsx_runtime284.jsx)(
14830
+ /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(
14509
14831
  Thumbnail,
14510
14832
  {
14511
14833
  gradientBackground,
@@ -14514,7 +14836,7 @@ var ThumbnailCollage = ({
14514
14836
  "fallback"
14515
14837
  )
14516
14838
  ];
14517
- return /* @__PURE__ */ (0, import_jsx_runtime284.jsx)(
14839
+ return /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(
14518
14840
  StyledThumbnailCollage,
14519
14841
  {
14520
14842
  $gradientBackground: gradientBackground,
@@ -14526,26 +14848,26 @@ var ThumbnailCollage = ({
14526
14848
  };
14527
14849
 
14528
14850
  // src/components/WistiaLogo/WistiaLogo.tsx
14529
- var import_styled_components100 = __toESM(require("styled-components"));
14530
- var import_type_guards66 = require("@wistia/type-guards");
14531
- var import_jsx_runtime285 = require("react/jsx-runtime");
14851
+ var import_styled_components103 = __toESM(require("styled-components"));
14852
+ var import_type_guards68 = require("@wistia/type-guards");
14853
+ var import_jsx_runtime289 = require("react/jsx-runtime");
14532
14854
  var renderBrandmark = (brandmarkColor, iconOnly) => {
14533
14855
  if (iconOnly) {
14534
- return /* @__PURE__ */ (0, import_jsx_runtime285.jsx)(
14856
+ return /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(
14535
14857
  "g",
14536
14858
  {
14537
14859
  "data-testid": "ui-wistia-logo-brandmark",
14538
14860
  fill: brandmarkColor,
14539
- children: /* @__PURE__ */ (0, import_jsx_runtime285.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" })
14861
+ children: /* @__PURE__ */ (0, import_jsx_runtime289.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" })
14540
14862
  }
14541
14863
  );
14542
14864
  }
14543
- return /* @__PURE__ */ (0, import_jsx_runtime285.jsx)(
14865
+ return /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(
14544
14866
  "g",
14545
14867
  {
14546
14868
  "data-testid": "ui-wistia-logo-brandmark",
14547
14869
  fill: brandmarkColor,
14548
- children: /* @__PURE__ */ (0, import_jsx_runtime285.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" })
14870
+ children: /* @__PURE__ */ (0, import_jsx_runtime289.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" })
14549
14871
  }
14550
14872
  );
14551
14873
  };
@@ -14553,12 +14875,12 @@ var renderLogotype = (logotypeColor, iconOnly) => {
14553
14875
  if (iconOnly) {
14554
14876
  return null;
14555
14877
  }
14556
- return /* @__PURE__ */ (0, import_jsx_runtime285.jsx)(
14878
+ return /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(
14557
14879
  "g",
14558
14880
  {
14559
14881
  "data-testid": "ui-wistia-logo-logotype",
14560
14882
  fill: logotypeColor,
14561
- children: /* @__PURE__ */ (0, import_jsx_runtime285.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" })
14883
+ children: /* @__PURE__ */ (0, import_jsx_runtime289.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" })
14562
14884
  }
14563
14885
  );
14564
14886
  };
@@ -14568,7 +14890,7 @@ var computedViewBox = (iconOnly) => {
14568
14890
  }
14569
14891
  return "0 0 144 31.47";
14570
14892
  };
14571
- var WistiaLogoComponent = import_styled_components100.default.svg`
14893
+ var WistiaLogoComponent = import_styled_components103.default.svg`
14572
14894
  height: ${({ height }) => `${height}px`};
14573
14895
 
14574
14896
  /* ensure it will always fit on mobile */
@@ -14584,12 +14906,12 @@ var WistiaLogoComponent = import_styled_components100.default.svg`
14584
14906
  ${({ $opticallyCentered, $iconOnly }) => {
14585
14907
  if ($opticallyCentered) {
14586
14908
  if ($iconOnly) {
14587
- return import_styled_components100.css`
14909
+ return import_styled_components103.css`
14588
14910
  aspect-ratio: 1;
14589
14911
  padding: 11.85% 3.12% 13.91%;
14590
14912
  `;
14591
14913
  }
14592
- return import_styled_components100.css`
14914
+ return import_styled_components103.css`
14593
14915
  aspect-ratio: 127 / 32;
14594
14916
  `;
14595
14917
  }
@@ -14626,7 +14948,7 @@ var WistiaLogo = ({
14626
14948
  };
14627
14949
  const brandmarkColor = VARIANT_COLORS[variant].brandmark;
14628
14950
  const logotypeColor = VARIANT_COLORS[variant].logotype;
14629
- const Logo = /* @__PURE__ */ (0, import_jsx_runtime285.jsxs)(
14951
+ const Logo = /* @__PURE__ */ (0, import_jsx_runtime289.jsxs)(
14630
14952
  WistiaLogoComponent,
14631
14953
  {
14632
14954
  $hoverColor: hoverColor,
@@ -14639,23 +14961,23 @@ var WistiaLogo = ({
14639
14961
  xmlns: "http://www.w3.org/2000/svg",
14640
14962
  ...props,
14641
14963
  children: [
14642
- /* @__PURE__ */ (0, import_jsx_runtime285.jsx)("title", { children: title }),
14643
- (0, import_type_guards66.isNotNil)(description) ? /* @__PURE__ */ (0, import_jsx_runtime285.jsx)("desc", { children: description }) : null,
14964
+ /* @__PURE__ */ (0, import_jsx_runtime289.jsx)("title", { children: title }),
14965
+ (0, import_type_guards68.isNotNil)(description) ? /* @__PURE__ */ (0, import_jsx_runtime289.jsx)("desc", { children: description }) : null,
14644
14966
  renderBrandmark(brandmarkColor, iconOnly),
14645
14967
  renderLogotype(logotypeColor, iconOnly)
14646
14968
  ]
14647
14969
  }
14648
14970
  );
14649
- return href !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime285.jsx)("a", { href, children: Logo }) : Logo;
14971
+ return href !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime289.jsx)("a", { href, children: Logo }) : Logo;
14650
14972
  };
14651
14973
  WistiaLogo.displayName = "WistiaLogo";
14652
14974
 
14653
14975
  // src/components/InputPassword/InputPassword.tsx
14654
- var import_styled_components101 = __toESM(require("styled-components"));
14655
- var import_react76 = require("react");
14656
- var import_type_guards67 = require("@wistia/type-guards");
14657
- var import_jsx_runtime286 = require("react/jsx-runtime");
14658
- var StyledIconButton = (0, import_styled_components101.default)(IconButton)`
14976
+ var import_styled_components104 = __toESM(require("styled-components"));
14977
+ var import_react79 = require("react");
14978
+ var import_type_guards69 = require("@wistia/type-guards");
14979
+ var import_jsx_runtime290 = require("react/jsx-runtime");
14980
+ var StyledIconButton = (0, import_styled_components104.default)(IconButton)`
14659
14981
  /* override size for icon button since prop gets changed by Input */
14660
14982
  height: var(--icon-button-size-sm);
14661
14983
  width: var(--icon-button-size-sm);
@@ -14663,23 +14985,23 @@ var StyledIconButton = (0, import_styled_components101.default)(IconButton)`
14663
14985
  /* override input padding variable since it is used for Input Icon positioning */
14664
14986
  --wui-input-horizontal-padding: 4px;
14665
14987
  `;
14666
- var InputPassword = (0, import_react76.forwardRef)(
14988
+ var InputPassword = (0, import_react79.forwardRef)(
14667
14989
  ({ onVisibilityToggle, disabled = false, ...props }, ref) => {
14668
- const [isVisible, setIsVisible] = (0, import_react76.useState)(false);
14990
+ const [isVisible, setIsVisible] = (0, import_react79.useState)(false);
14669
14991
  const handleClick = () => {
14670
14992
  const newVisibility = !isVisible;
14671
14993
  setIsVisible(newVisibility);
14672
- if ((0, import_type_guards67.isFunction)(onVisibilityToggle)) {
14994
+ if ((0, import_type_guards69.isFunction)(onVisibilityToggle)) {
14673
14995
  onVisibilityToggle(newVisibility);
14674
14996
  }
14675
14997
  };
14676
- return /* @__PURE__ */ (0, import_jsx_runtime286.jsx)(
14998
+ return /* @__PURE__ */ (0, import_jsx_runtime290.jsx)(
14677
14999
  Input,
14678
15000
  {
14679
15001
  ...props,
14680
15002
  ref,
14681
15003
  disabled,
14682
- rightIcon: /* @__PURE__ */ (0, import_jsx_runtime286.jsx)(
15004
+ rightIcon: /* @__PURE__ */ (0, import_jsx_runtime290.jsx)(
14683
15005
  StyledIconButton,
14684
15006
  {
14685
15007
  disabled,
@@ -14687,7 +15009,7 @@ var InputPassword = (0, import_react76.forwardRef)(
14687
15009
  onClick: handleClick,
14688
15010
  tabIndex: disabled ? -1 : 0,
14689
15011
  variant: "ghost",
14690
- children: /* @__PURE__ */ (0, import_jsx_runtime286.jsx)(Icon, { type: isVisible ? "preview" : "hide" })
15012
+ children: /* @__PURE__ */ (0, import_jsx_runtime290.jsx)(Icon, { type: isVisible ? "preview" : "hide" })
14691
15013
  }
14692
15014
  ),
14693
15015
  type: isVisible ? "text" : "password"
@@ -14696,6 +15018,65 @@ var InputPassword = (0, import_react76.forwardRef)(
14696
15018
  }
14697
15019
  );
14698
15020
  InputPassword.displayName = "InputPassword";
15021
+
15022
+ // src/components/ContextMenu/ContextMenu.tsx
15023
+ var import_react80 = require("react");
15024
+ var import_type_guards70 = require("@wistia/type-guards");
15025
+ var import_jsx_runtime291 = require("react/jsx-runtime");
15026
+ var ContextMenu = ({
15027
+ position,
15028
+ triggerRef,
15029
+ children,
15030
+ onRequestClose = () => null
15031
+ }) => {
15032
+ const [isRightClicked, setIsRightClicked] = (0, import_react80.useState)(false);
15033
+ const [menuPosition, setMenuPosition] = (0, import_react80.useState)(position ?? { x: 0, y: 0 });
15034
+ (0, import_react80.useEffect)(() => {
15035
+ if ((0, import_type_guards70.isNil)(position)) {
15036
+ const onContextMenu = (event) => {
15037
+ event.preventDefault();
15038
+ setMenuPosition({ x: event.clientX, y: event.clientY });
15039
+ setIsRightClicked(true);
15040
+ };
15041
+ const triggerEl = triggerRef?.current;
15042
+ triggerEl?.addEventListener("contextmenu", onContextMenu);
15043
+ return () => {
15044
+ triggerEl?.removeEventListener("contextmenu", onContextMenu);
15045
+ };
15046
+ }
15047
+ return () => null;
15048
+ }, [position, triggerRef]);
15049
+ const isOpen = (0, import_type_guards70.isNotNil)(position) || isRightClicked;
15050
+ return isOpen ? /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
15051
+ Menu,
15052
+ {
15053
+ avoidCollisions: false,
15054
+ isOpen,
15055
+ onOpenChange: (next) => {
15056
+ setIsRightClicked(next);
15057
+ if (!next) {
15058
+ onRequestClose();
15059
+ }
15060
+ },
15061
+ trigger: /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
15062
+ "button",
15063
+ {
15064
+ "aria-label": "context menu",
15065
+ style: {
15066
+ width: "1px",
15067
+ height: "1px",
15068
+ all: "unset",
15069
+ position: "fixed",
15070
+ top: menuPosition.y,
15071
+ left: menuPosition.x
15072
+ },
15073
+ type: "button"
15074
+ }
15075
+ ),
15076
+ children
15077
+ }
15078
+ ) : null;
15079
+ };
14699
15080
  // Annotate the CommonJS export names for ESM import in node:
14700
15081
  0 && (module.exports = {
14701
15082
  ActionButton,
@@ -14720,6 +15101,7 @@ InputPassword.displayName = "InputPassword";
14720
15101
  ColorSchemeWrapper,
14721
15102
  Combobox,
14722
15103
  ComboboxOption,
15104
+ ContextMenu,
14723
15105
  DataCard,
14724
15106
  DataCardTrend,
14725
15107
  DataCards,
@@ -14759,6 +15141,8 @@ InputPassword.displayName = "InputPassword";
14759
15141
  Popover,
14760
15142
  ProgressBar,
14761
15143
  Radio,
15144
+ RadioCard,
15145
+ RadioCardImage,
14762
15146
  RadioGroup,
14763
15147
  RadioMenuItem,
14764
15148
  ScreenReaderOnly,