@wistia/ui 0.10.4-beta.f468ee4b.d928e02 → 0.10.4

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.10.4-beta.f468ee4b.d928e02
3
+ * @license @wistia/ui v0.10.4
4
4
  *
5
5
  * Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
6
6
  *
@@ -7828,7 +7828,6 @@ var StyledBadge = import_styled_components26.default.div`
7828
7828
  ${({ $colorScheme }) => getColorScheme($colorScheme)};
7829
7829
  align-items: center;
7830
7830
  background-color: var(--wui-color-bg-surface-secondary);
7831
- box-shadow: ${({ $variant }) => $variant === "outline" ? "inset 0 0 0 1px var(--wui-color-border)" : "none"};
7832
7831
  border-radius: var(--wui-border-radius-rounded);
7833
7832
  color: var(--wui-color-text);
7834
7833
  display: inline-flex;
@@ -7836,21 +7835,17 @@ var StyledBadge = import_styled_components26.default.div`
7836
7835
  font-weight: var(--wui-typography-label-4-weight);
7837
7836
  gap: var(--wui-space-01);
7838
7837
  justify-content: center;
7839
- line-height: var(--wui-typography-label-3-line-height);
7840
7838
  padding: var(--wui-space-01) var(--wui-space-02);
7841
7839
  width: fit-content;
7842
7840
 
7843
- /* Icon component size and color */
7844
- && {
7845
- svg {
7846
- color: var(--wui-color-icon);
7847
- height: 12px;
7848
- width: 12px;
7849
- }
7841
+ /* Icon component size */
7842
+ svg {
7843
+ height: 12px;
7844
+ width: 12px;
7850
7845
  }
7851
7846
  `;
7852
7847
  var Badge = (0, import_react26.forwardRef)(
7853
- ({ colorScheme = "inherit", label, icon, variant = "default", ...props }, ref) => {
7848
+ ({ colorScheme = "inherit", label, icon, ...props }, ref) => {
7854
7849
  const hasIcon = (0, import_type_guards19.isNotNil)(icon);
7855
7850
  return /* @__PURE__ */ (0, import_jsx_runtime200.jsxs)(
7856
7851
  StyledBadge,
@@ -7859,7 +7854,6 @@ var Badge = (0, import_react26.forwardRef)(
7859
7854
  ...props,
7860
7855
  $colorScheme: colorScheme,
7861
7856
  $hasIcon: hasIcon,
7862
- $variant: variant,
7863
7857
  children: [
7864
7858
  hasIcon ? icon : null,
7865
7859
  /* @__PURE__ */ (0, import_jsx_runtime200.jsx)("span", { children: label })
@@ -9905,23 +9899,6 @@ var EditableHeading = ({
9905
9899
  var import_react41 = require("react");
9906
9900
  var import_styled_components51 = __toESM(require("styled-components"));
9907
9901
  var import_type_guards32 = require("@wistia/type-guards");
9908
-
9909
- // src/components/Form/serializeFormData.tsx
9910
- var ARRAY_SUFFIX = "[]";
9911
- var serializeFormData = (formData) => {
9912
- const data = {};
9913
- formData.forEach((value, key) => {
9914
- if (key.endsWith(ARRAY_SUFFIX)) {
9915
- const newKey = key.slice(0, -ARRAY_SUFFIX.length);
9916
- data[newKey] = formData.getAll(key);
9917
- } else {
9918
- data[key] = value;
9919
- }
9920
- });
9921
- return data;
9922
- };
9923
-
9924
- // src/components/Form/Form.tsx
9925
9902
  var import_jsx_runtime226 = require("react/jsx-runtime");
9926
9903
  var StyledForm = import_styled_components51.default.form`
9927
9904
  --form-default-width: 690px;
@@ -9952,7 +9929,7 @@ var FormComponent = ({
9952
9929
  const autoId = (0, import_react41.useId)();
9953
9930
  const id = props.id ?? autoId;
9954
9931
  const handleValidate = (nextFormData) => {
9955
- const nextData = serializeFormData(nextFormData);
9932
+ const nextData = Object.fromEntries(nextFormData.entries());
9956
9933
  if ((0, import_type_guards32.isUndefined)(validate)) {
9957
9934
  return {};
9958
9935
  }
@@ -10035,7 +10012,7 @@ var useFormState = (action, initialData = {}) => {
10035
10012
  setError(null);
10036
10013
  return;
10037
10014
  }
10038
- const nextData = serializeFormData(nextFormData);
10015
+ const nextData = Object.fromEntries(nextFormData.entries());
10039
10016
  setIsPending(true);
10040
10017
  try {
10041
10018
  const result = await action(data, nextData);