@underverse-ui/underverse 2.0.6 → 2.0.7

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.
@@ -53,7 +53,7 @@ import {
53
53
  sanitizeUEditorUrl,
54
54
  useEditorColors,
55
55
  useSharedEditorUiRenderState
56
- } from "./chunk-JXE7JBQV.js";
56
+ } from "./chunk-TETMVVUP.js";
57
57
  import {
58
58
  Tooltip,
59
59
  cn,
@@ -14303,7 +14303,7 @@ function useUEditorOutput({
14303
14303
  // src/components/UEditor/UEditor.tsx
14304
14304
  import { jsx as jsx20, jsxs as jsxs17 } from "react/jsx-runtime";
14305
14305
  var LazyMenuBar = React15.lazy(async () => {
14306
- const { MenuBar } = await import("./menu-bar-6HZDCX44.js");
14306
+ const { MenuBar } = await import("./menu-bar-NFEW4FOJ.js");
14307
14307
  return { default: MenuBar };
14308
14308
  });
14309
14309
  var UEditor = React15.forwardRef(({
@@ -14753,4 +14753,4 @@ export {
14753
14753
  prepareUEditorContentForSave,
14754
14754
  UEditor_default
14755
14755
  };
14756
- //# sourceMappingURL=chunk-2UQ7H5GR.js.map
14756
+ //# sourceMappingURL=chunk-XE3RJHVX.js.map
package/dist/index.cjs CHANGED
@@ -31,7 +31,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
31
31
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
32
32
 
33
33
  // src/constants/form-control-size.ts
34
- var formControlSizeStyles, formControlFixedClass, formControlValueClass;
34
+ var formControlSizeStyles, formControlLabelClass, formControlFixedClass, formControlValueClass;
35
35
  var init_form_control_size = __esm({
36
36
  "src/constants/form-control-size.ts"() {
37
37
  "use strict";
@@ -82,6 +82,7 @@ var init_form_control_size = __esm({
82
82
  tag: "h-8 max-w-36 px-3 text-sm leading-none"
83
83
  }
84
84
  };
85
+ formControlLabelClass = "font-medium";
85
86
  formControlFixedClass = "min-h-0 overflow-hidden";
86
87
  formControlValueClass = "max-h-full min-w-0 flex-1 truncate whitespace-nowrap";
87
88
  }
@@ -10039,6 +10040,7 @@ var Card_default = Card;
10039
10040
  var React5 = __toESM(require("react"), 1);
10040
10041
  init_cn();
10041
10042
  var import_lucide_react2 = require("lucide-react");
10043
+ init_form_control_size();
10042
10044
  var import_jsx_runtime6 = require("react/jsx-runtime");
10043
10045
  var Checkbox = React5.forwardRef(
10044
10046
  ({ className, label, labelClassName, containerClassName, checked, defaultChecked, onChange, ...props }, ref) => {
@@ -10064,7 +10066,7 @@ var Checkbox = React5.forwardRef(
10064
10066
  children: isChecked && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_lucide_react2.Check, { className: "w-4 h-4" })
10065
10067
  }
10066
10068
  ),
10067
- label && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: cn("text-sm text-foreground", labelClassName), children: label })
10069
+ label && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: cn("text-sm text-foreground", formControlLabelClass, labelClassName), children: label })
10068
10070
  ] });
10069
10071
  }
10070
10072
  );
@@ -10454,7 +10456,8 @@ var Input = (0, import_react4.forwardRef)(
10454
10456
  className: cn(
10455
10457
  // Label size follows input size
10456
10458
  sizeStyles8[size].label,
10457
- "font-medium transition-colors duration-200",
10459
+ formControlLabelClass,
10460
+ "transition-colors duration-200",
10458
10461
  // default color and highlight while any descendant focused
10459
10462
  disabled ? "text-muted-foreground" : cn("text-foreground group-focus-within:text-primary", success && "text-primary"),
10460
10463
  errMsg && "text-destructive",
@@ -10872,7 +10875,8 @@ var Textarea = (0, import_react4.forwardRef)(
10872
10875
  "label",
10873
10876
  {
10874
10877
  className: cn(
10875
- "text-sm font-medium transition-colors duration-200",
10878
+ "text-sm transition-colors duration-200",
10879
+ formControlLabelClass,
10876
10880
  isFocused ? "text-primary" : "text-foreground",
10877
10881
  error && "text-destructive",
10878
10882
  labelClassName
@@ -11837,7 +11841,8 @@ var TagInput = (0, import_react10.forwardRef)(
11837
11841
  {
11838
11842
  htmlFor: inputId,
11839
11843
  className: cn(
11840
- "block font-medium transition-colors duration-200",
11844
+ "block transition-colors duration-200",
11845
+ formControlLabelClass,
11841
11846
  formControlSizeStyles[size].label,
11842
11847
  disabled ? "text-muted-foreground" : isFocused ? "text-primary" : "text-foreground",
11843
11848
  labelClassName
@@ -12012,6 +12017,7 @@ var TagInput_default = TagInput;
12012
12017
  // src/components/Switch.tsx
12013
12018
  var React17 = __toESM(require("react"), 1);
12014
12019
  init_cn();
12020
+ init_form_control_size();
12015
12021
  var import_jsx_runtime18 = require("react/jsx-runtime");
12016
12022
  var Switch = ({
12017
12023
  checked,
@@ -12112,7 +12118,7 @@ var Switch = ({
12112
12118
  ]
12113
12119
  }
12114
12120
  ),
12115
- label && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { className: cn("text-sm font-medium text-foreground transition-colors", disabled && "text-muted-foreground", labelClassName), children: label })
12121
+ label && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { className: cn("text-sm text-foreground transition-colors", formControlLabelClass, disabled && "text-muted-foreground", labelClassName), children: label })
12116
12122
  ] });
12117
12123
  };
12118
12124
  Switch.displayName = "Switch";
@@ -12122,9 +12128,10 @@ var Switch_default = Switch;
12122
12128
  var React18 = __toESM(require("react"), 1);
12123
12129
  var import_class_variance_authority = require("class-variance-authority");
12124
12130
  init_cn();
12131
+ init_form_control_size();
12125
12132
  var import_jsx_runtime19 = require("react/jsx-runtime");
12126
12133
  var labelVariants = (0, import_class_variance_authority.cva)(
12127
- "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
12134
+ `text-sm ${formControlLabelClass} leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70`
12128
12135
  );
12129
12136
  var Label = React18.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
12130
12137
  "label",
@@ -14554,7 +14561,8 @@ var Combobox = ({
14554
14561
  onClick: () => triggerRef.current?.focus(),
14555
14562
  className: cn(
14556
14563
  labelSize,
14557
- "font-medium transition-colors duration-200",
14564
+ formControlLabelClass,
14565
+ "transition-colors duration-200",
14558
14566
  disabled ? "text-muted-foreground" : "text-foreground group-focus-within:text-primary",
14559
14567
  effectiveError && "text-destructive",
14560
14568
  labelClassName
@@ -15835,7 +15843,8 @@ var DatePicker = ({
15835
15843
  onClick: () => inputRef.current?.focus(),
15836
15844
  className: cn(
15837
15845
  labelSize,
15838
- "font-semibold transition-colors duration-300 cursor-pointer",
15846
+ formControlLabelClass,
15847
+ "transition-colors duration-300 cursor-pointer",
15839
15848
  disabled ? "text-muted-foreground" : "text-foreground group-focus-within:text-primary hover:text-primary",
15840
15849
  effectiveError && "text-destructive",
15841
15850
  labelClassName
@@ -16594,7 +16603,8 @@ var DateRangePicker = ({
16594
16603
  onClick: () => inputRef.current?.focus(),
16595
16604
  className: cn(
16596
16605
  size === "sm" ? "text-xs" : size === "lg" ? "text-base" : "text-sm",
16597
- "font-medium transition-colors duration-300",
16606
+ formControlLabelClass,
16607
+ "transition-colors duration-300",
16598
16608
  disabled ? "text-muted-foreground cursor-not-allowed" : "text-foreground group-focus-within:text-primary hover:text-primary cursor-pointer",
16599
16609
  effectiveError && "text-destructive",
16600
16610
  labelClassName
@@ -17539,7 +17549,8 @@ var LunarDatePicker = ({
17539
17549
  onClick: () => inputRef.current?.focus(),
17540
17550
  className: cn(
17541
17551
  labelSize,
17542
- "font-semibold transition-colors duration-300 cursor-pointer",
17552
+ formControlLabelClass,
17553
+ "transition-colors duration-300 cursor-pointer",
17543
17554
  disabled ? "text-muted-foreground" : "text-foreground group-focus-within:text-primary hover:text-primary",
17544
17555
  effectiveError && "text-destructive",
17545
17556
  labelClassName
@@ -18168,7 +18179,8 @@ var LunarDateRangePicker = ({
18168
18179
  onClick: () => setIsOpen(true),
18169
18180
  className: cn(
18170
18181
  size === "sm" ? "text-xs" : size === "lg" ? "text-base" : "text-sm",
18171
- "font-medium transition-colors duration-300",
18182
+ formControlLabelClass,
18183
+ "transition-colors duration-300",
18172
18184
  disabled ? "text-muted-foreground cursor-not-allowed" : "text-foreground group-focus-within:text-primary hover:text-primary cursor-pointer",
18173
18185
  effectiveError && "text-destructive",
18174
18186
  labelClassName
@@ -19086,7 +19098,7 @@ function MonthYearPicker({
19086
19098
  ] });
19087
19099
  if (variant === "inline") {
19088
19100
  return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: cn("w-full", className), ...rest, children: [
19089
- label && /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("label", { className: cn(sz.label, "block mb-1.5 font-medium text-foreground/80", effectiveError && "text-destructive", labelClassName), children: [
19101
+ label && /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("label", { className: cn(sz.label, "block mb-1.5 text-foreground/80", formControlLabelClass, effectiveError && "text-destructive", labelClassName), children: [
19090
19102
  label,
19091
19103
  required && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("span", { className: "text-destructive ml-0.5", children: "*" })
19092
19104
  ] }),
@@ -19123,7 +19135,7 @@ function MonthYearPicker({
19123
19135
  ] });
19124
19136
  }
19125
19137
  return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: cn("w-full", className), ...rest, children: [
19126
- label && /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("label", { className: cn(sz.label, "block mb-1.5 font-medium text-foreground/80", effectiveError && "text-destructive", labelClassName), children: [
19138
+ label && /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("label", { className: cn(sz.label, "block mb-1.5 text-foreground/80", formControlLabelClass, effectiveError && "text-destructive", labelClassName), children: [
19127
19139
  label,
19128
19140
  required && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("span", { className: "text-destructive ml-0.5", children: "*" })
19129
19141
  ] }),
@@ -21005,7 +21017,7 @@ function TimePicker({
21005
21017
  "label",
21006
21018
  {
21007
21019
  id: labelId,
21008
- className: cn(sz.label, "font-semibold", disabled ? "text-muted-foreground" : "text-foreground", effectiveError && "text-destructive"),
21020
+ className: cn(sz.label, formControlLabelClass, disabled ? "text-muted-foreground" : "text-foreground", effectiveError && "text-destructive"),
21009
21021
  children: [
21010
21022
  label,
21011
21023
  required && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "text-destructive ml-1", children: "*" })
@@ -21053,7 +21065,7 @@ function TimePicker({
21053
21065
  htmlFor: triggerId,
21054
21066
  className: cn(
21055
21067
  sz.label,
21056
- "font-semibold",
21068
+ formControlLabelClass,
21057
21069
  disabled ? "text-muted-foreground" : "text-foreground",
21058
21070
  effectiveError && "text-destructive",
21059
21071
  "cursor-pointer transition-colors hover:text-primary"
@@ -21298,7 +21310,13 @@ var DateTimePicker = ({
21298
21310
  {
21299
21311
  id: labelId,
21300
21312
  htmlFor: triggerId,
21301
- className: cn(sizeStyles8[size].label, "font-medium text-foreground flex items-center gap-1", effectiveError && "text-destructive", labelClassName),
21313
+ className: cn(
21314
+ sizeStyles8[size].label,
21315
+ formControlLabelClass,
21316
+ "text-foreground flex items-center gap-1",
21317
+ effectiveError && "text-destructive",
21318
+ labelClassName
21319
+ ),
21302
21320
  children: [
21303
21321
  label,
21304
21322
  " ",
@@ -24931,7 +24949,8 @@ var MultiCombobox = ({
24931
24949
  {
24932
24950
  className: cn(
24933
24951
  size === "sm" ? "text-xs" : size === "lg" ? "text-base" : "text-sm",
24934
- "font-medium transition-colors duration-200",
24952
+ formControlLabelClass,
24953
+ "transition-colors duration-200",
24935
24954
  disabled ? "text-muted-foreground" : "text-foreground group-focus-within:text-primary",
24936
24955
  effectiveError && "text-destructive",
24937
24956
  labelClassName
@@ -24949,7 +24968,8 @@ var MultiCombobox = ({
24949
24968
  onClick: () => triggerRef.current?.focus(),
24950
24969
  className: cn(
24951
24970
  labelSize,
24952
- "font-medium transition-colors duration-200",
24971
+ formControlLabelClass,
24972
+ "transition-colors duration-200",
24953
24973
  disabled ? "text-muted-foreground" : "text-foreground group-focus-within:text-primary",
24954
24974
  effectiveError && "text-destructive",
24955
24975
  labelClassName
@@ -25019,6 +25039,7 @@ var React47 = __toESM(require("react"), 1);
25019
25039
  init_cn();
25020
25040
  init_radius();
25021
25041
  init_UnderverseConfigContext();
25042
+ init_form_control_size();
25022
25043
  var import_jsx_runtime51 = require("react/jsx-runtime");
25023
25044
  var RadioGroupContext = React47.createContext(void 0);
25024
25045
  var useRadioGroup = () => {
@@ -25170,7 +25191,7 @@ var RadioGroupItem = React47.forwardRef(
25170
25191
  /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex-1 min-w-0", children: [
25171
25192
  /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "flex items-center gap-2", children: [
25172
25193
  Icon && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Icon, { className: "h-4 w-4 text-foreground" }),
25173
- /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("label", { htmlFor: radioId, className: cn("font-medium text-foreground cursor-pointer", sizeStyles7[size].text, labelClassName), children: label || children })
25194
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("label", { htmlFor: radioId, className: cn(formControlLabelClass, "text-foreground cursor-pointer", sizeStyles7[size].text, labelClassName), children: label || children })
25174
25195
  ] }),
25175
25196
  description && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("p", { className: "text-muted-foreground mt-1 text-xs", children: description })
25176
25197
  ] })
@@ -25205,7 +25226,8 @@ var RadioGroupItem = React47.forwardRef(
25205
25226
  id: radioId,
25206
25227
  disabled: isDisabled,
25207
25228
  className: cn(
25208
- "inline-flex items-center justify-center gap-2 border font-medium transition-all duration-200",
25229
+ "inline-flex items-center justify-center gap-2 border transition-all duration-200",
25230
+ formControlLabelClass,
25209
25231
  getBorderRadiusClass(borderMode ?? "lg"),
25210
25232
  "focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
25211
25233
  "disabled:cursor-not-allowed disabled:opacity-50",
@@ -25263,7 +25285,8 @@ var RadioGroupItem = React47.forwardRef(
25263
25285
  {
25264
25286
  htmlFor: radioId,
25265
25287
  className: cn(
25266
- "font-medium text-foreground cursor-pointer flex-1",
25288
+ formControlLabelClass,
25289
+ "text-foreground cursor-pointer flex-1",
25267
25290
  "disabled:cursor-not-allowed disabled:opacity-50",
25268
25291
  sizeStyles7[size].text,
25269
25292
  isDisabled && "cursor-not-allowed opacity-50",
@@ -25452,6 +25475,7 @@ var ToggleGroup = (props) => {
25452
25475
  var React48 = __toESM(require("react"), 1);
25453
25476
  init_cn();
25454
25477
  init_GlobalI18nContext();
25478
+ init_form_control_size();
25455
25479
  var import_jsx_runtime52 = require("react/jsx-runtime");
25456
25480
  var SIZE_STYLES = {
25457
25481
  sm: {
@@ -25670,7 +25694,7 @@ var Slider = React48.forwardRef(
25670
25694
  }
25671
25695
  return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: cn("w-full space-y-2", containerClassName), children: [
25672
25696
  (label || showValue) && /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "flex items-center justify-between", children: [
25673
- label && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("label", { className: cn("text-sm font-medium text-foreground", labelClassName), children: label }),
25697
+ label && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("label", { className: cn("text-sm text-foreground", formControlLabelClass, labelClassName), children: label }),
25674
25698
  showValue && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: cn("text-xs font-mono text-muted-foreground min-w-8 text-right", valueClassName), children: displayValue })
25675
25699
  ] }),
25676
25700
  /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(