the-omelet-ui 1.0.0 → 1.0.2

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
@@ -77,7 +77,7 @@ var buttonStyles = classVarianceAuthority.cva(
77
77
  // ใส่สีตาม variant ผ่าน compoundVariants
78
78
  compoundVariants: [
79
79
  // SOLID
80
- { variant: "solid", color: "neutral", class: "bg-neutral-900 text-white hover:bg-neutral-800" },
80
+ { variant: "solid", color: "neutral", class: "bg-neutral-900 text-white hover:dark:bg-neutral-800" },
81
81
  { variant: "solid", color: "primary", class: "bg-black text-white hover:bg-black/85" },
82
82
  { variant: "solid", color: "red", class: "bg-red-600 text-white hover:bg-red-700" },
83
83
  { variant: "solid", color: "green", class: "bg-green-600 text-white hover:bg-green-700" },
@@ -123,7 +123,7 @@ var Button = React29__namespace.forwardRef(
123
123
  );
124
124
  Button.displayName = "Button";
125
125
  var LabelInput = React29__namespace.default.forwardRef(({ required, label, id }, ref) => {
126
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center", ref, children: /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "block text-sm text-[#444] font-bold", htmlFor: id, children: [
126
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center ", ref, children: /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "block text-sm text-[#444] font-bold", htmlFor: id, children: [
127
127
  required && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-red-500", children: "*" }),
128
128
  label
129
129
  ] }) });
@@ -27167,6 +27167,7 @@ function SearchSelect({
27167
27167
  }, [selectedItems, isMulti, triggerPlaceholder]);
27168
27168
  return /* @__PURE__ */ jsxRuntime.jsxs(Root22, { open, onOpenChange: setOpen, children: [
27169
27169
  label && /* @__PURE__ */ jsxRuntime.jsx(LabelInput, { label, required }),
27170
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mb-2" }),
27170
27171
  /* @__PURE__ */ jsxRuntime.jsx(Trigger, { asChild: true, children: trigger ?? // Trigger แบบ "ฟิลด์มีกรอบ + ลูกศร"
27171
27172
  /* @__PURE__ */ jsxRuntime.jsxs(
27172
27173
  "button",
@@ -27178,7 +27179,10 @@ function SearchSelect({
27178
27179
  "outline-none focus-visible:ring-2 ring-black/20"
27179
27180
  ),
27180
27181
  children: [
27181
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate text-base text-black", children: renderTriggerValue ? renderTriggerValue(selectedIds, selectedItems) : defaultTriggerValue }),
27182
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("flex-1 ", {
27183
+ "text-gray-400": isMulti ? current?.length === 0 : !current,
27184
+ "text-black": isMulti ? current?.length > 0 : !!current
27185
+ }), children: renderTriggerValue ? renderTriggerValue(selectedIds, selectedItems) : defaultTriggerValue }),
27182
27186
  /* @__PURE__ */ jsxRuntime.jsx(
27183
27187
  "svg",
27184
27188
  {
@@ -27232,7 +27236,7 @@ function SearchSelect({
27232
27236
  color: searchButtonColor ?? buttonColor,
27233
27237
  type: "submit",
27234
27238
  disabled: loading || q.trim() === appliedQ.trim(),
27235
- size: "sm",
27239
+ size: "md",
27236
27240
  className: searchButtonClassName,
27237
27241
  children: searchButtonLabel
27238
27242
  }
package/dist/index.js CHANGED
@@ -56,7 +56,7 @@ var buttonStyles = cva(
56
56
  // ใส่สีตาม variant ผ่าน compoundVariants
57
57
  compoundVariants: [
58
58
  // SOLID
59
- { variant: "solid", color: "neutral", class: "bg-neutral-900 text-white hover:bg-neutral-800" },
59
+ { variant: "solid", color: "neutral", class: "bg-neutral-900 text-white hover:dark:bg-neutral-800" },
60
60
  { variant: "solid", color: "primary", class: "bg-black text-white hover:bg-black/85" },
61
61
  { variant: "solid", color: "red", class: "bg-red-600 text-white hover:bg-red-700" },
62
62
  { variant: "solid", color: "green", class: "bg-green-600 text-white hover:bg-green-700" },
@@ -102,7 +102,7 @@ var Button = React29.forwardRef(
102
102
  );
103
103
  Button.displayName = "Button";
104
104
  var LabelInput = React29__default.forwardRef(({ required, label, id }, ref) => {
105
- return /* @__PURE__ */ jsx("div", { className: "flex items-center", ref, children: /* @__PURE__ */ jsxs("label", { className: "block text-sm text-[#444] font-bold", htmlFor: id, children: [
105
+ return /* @__PURE__ */ jsx("div", { className: "flex items-center ", ref, children: /* @__PURE__ */ jsxs("label", { className: "block text-sm text-[#444] font-bold", htmlFor: id, children: [
106
106
  required && /* @__PURE__ */ jsx("span", { className: "text-red-500", children: "*" }),
107
107
  label
108
108
  ] }) });
@@ -27146,6 +27146,7 @@ function SearchSelect({
27146
27146
  }, [selectedItems, isMulti, triggerPlaceholder]);
27147
27147
  return /* @__PURE__ */ jsxs(Root22, { open, onOpenChange: setOpen, children: [
27148
27148
  label && /* @__PURE__ */ jsx(LabelInput, { label, required }),
27149
+ /* @__PURE__ */ jsx("div", { className: "mb-2" }),
27149
27150
  /* @__PURE__ */ jsx(Trigger, { asChild: true, children: trigger ?? // Trigger แบบ "ฟิลด์มีกรอบ + ลูกศร"
27150
27151
  /* @__PURE__ */ jsxs(
27151
27152
  "button",
@@ -27157,7 +27158,10 @@ function SearchSelect({
27157
27158
  "outline-none focus-visible:ring-2 ring-black/20"
27158
27159
  ),
27159
27160
  children: [
27160
- /* @__PURE__ */ jsx("span", { className: "truncate text-base text-black", children: renderTriggerValue ? renderTriggerValue(selectedIds, selectedItems) : defaultTriggerValue }),
27161
+ /* @__PURE__ */ jsx("span", { className: cn("flex-1 ", {
27162
+ "text-gray-400": isMulti ? current?.length === 0 : !current,
27163
+ "text-black": isMulti ? current?.length > 0 : !!current
27164
+ }), children: renderTriggerValue ? renderTriggerValue(selectedIds, selectedItems) : defaultTriggerValue }),
27161
27165
  /* @__PURE__ */ jsx(
27162
27166
  "svg",
27163
27167
  {
@@ -27211,7 +27215,7 @@ function SearchSelect({
27211
27215
  color: searchButtonColor ?? buttonColor,
27212
27216
  type: "submit",
27213
27217
  disabled: loading || q.trim() === appliedQ.trim(),
27214
- size: "sm",
27218
+ size: "md",
27215
27219
  className: searchButtonClassName,
27216
27220
  children: searchButtonLabel
27217
27221
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "the-omelet-ui",
3
- "version": "1.0.0",
3
+ "version": "1.0.2",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs",