@nivaro/react 0.3.79 → 0.3.81

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.
@@ -1,13 +1,13 @@
1
1
  import { jsxs as t, jsx as e } from "react/jsx-runtime";
2
2
  import { ArrowRight as f, X as v } from "lucide-react";
3
3
  import { useState as g } from "react";
4
- import { Command as k, CommandInput as y, CommandList as C, CommandEmpty as N, CommandItem as w } from "../ui/command.js";
4
+ import { Command as k, CommandInput as y, CommandList as C, CommandEmpty as w, CommandItem as N } from "../ui/command.js";
5
5
  import { Popover as T, PopoverTrigger as O, PopoverContent as P } from "../ui/popover.js";
6
6
  function z({
7
7
  count: l,
8
- states: n,
8
+ states: o,
9
9
  busy: r,
10
- claimsEnabled: o = !0,
10
+ claimsEnabled: n = !0,
11
11
  showClaim: i = !0,
12
12
  showRelease: s = !0,
13
13
  showTransition: m = !0,
@@ -18,74 +18,78 @@ function z({
18
18
  children: h
19
19
  }) {
20
20
  const [b, d] = g(!1);
21
- return l === 0 ? null : /* @__PURE__ */ t("div", { className: "nvr-slide-up-centered fixed bottom-6 left-1/2 z-40 flex -translate-x-1/2 items-center gap-1 rounded-full border border-slate-200 bg-white px-4 py-2 shadow-lg dark:border-border dark:bg-card", children: [
22
- /* @__PURE__ */ t("span", { className: "mr-2 text-[12px] font-semibold text-slate-700 dark:text-slate-200", children: [
23
- l,
24
- " selected"
25
- ] }),
26
- o && i && /* @__PURE__ */ e(
27
- "button",
28
- {
29
- type: "button",
30
- disabled: r,
31
- onClick: p,
32
- className: "rounded-md px-2.5 py-1 text-[12px] font-medium text-nvr-navy hover:bg-nvr-cyan/10 disabled:opacity-50 dark:text-nvr-cyan",
33
- children: "Claim"
34
- }
35
- ),
36
- o && s && /* @__PURE__ */ e(
37
- "button",
38
- {
39
- type: "button",
40
- disabled: r,
41
- onClick: c,
42
- className: "rounded-md px-2.5 py-1 text-[12px] font-medium text-slate-600 hover:bg-slate-100 disabled:opacity-50 dark:text-slate-300 dark:hover:bg-muted",
43
- children: "Release"
44
- }
45
- ),
46
- h,
47
- m && /* @__PURE__ */ t(T, { open: b, onOpenChange: d, children: [
48
- /* @__PURE__ */ e(O, { asChild: !0, children: /* @__PURE__ */ t(
21
+ return l === 0 ? null : (
22
+ // Labels never wrap ("Push to / Fusion" on two lines, 2026-11-09): every button keeps one
23
+ // line (white-space inherits) and a bar wider than the window scrolls sideways instead.
24
+ /* @__PURE__ */ t("div", { className: "nvr-slide-up-centered fixed bottom-6 left-1/2 z-40 flex max-w-[calc(100vw-2rem)] -translate-x-1/2 items-center gap-1 overflow-x-auto whitespace-nowrap rounded-full border border-slate-200 bg-white px-4 py-2 shadow-lg dark:border-border dark:bg-card [&>*]:shrink-0", children: [
25
+ /* @__PURE__ */ t("span", { className: "mr-2 text-[12px] font-semibold text-slate-700 dark:text-slate-200", children: [
26
+ l,
27
+ " selected"
28
+ ] }),
29
+ n && i && /* @__PURE__ */ e(
49
30
  "button",
50
31
  {
51
32
  type: "button",
52
- disabled: r || n.length === 0,
53
- className: "flex items-center gap-1 rounded-md px-2.5 py-1 text-[12px] font-medium text-slate-600 hover:bg-slate-100 disabled:opacity-50 dark:text-slate-300 dark:hover:bg-muted",
54
- children: [
55
- "Transition ",
56
- /* @__PURE__ */ e(f, { className: "h-3 w-3" })
57
- ]
33
+ disabled: r,
34
+ onClick: p,
35
+ className: "rounded-md px-2.5 py-1 text-[12px] font-medium text-nvr-navy hover:bg-nvr-cyan/10 disabled:opacity-50 dark:text-nvr-cyan",
36
+ children: "Claim"
58
37
  }
59
- ) }),
60
- /* @__PURE__ */ e(P, { className: "w-[200px] p-0", align: "center", side: "top", children: /* @__PURE__ */ t(k, { children: [
61
- /* @__PURE__ */ e(y, { placeholder: "Target state…", className: "h-8 text-[12px]" }),
62
- /* @__PURE__ */ t(C, { children: [
63
- /* @__PURE__ */ e(N, { children: "No state found." }),
64
- n.map((a) => /* @__PURE__ */ e(
65
- w,
66
- {
67
- value: a.label,
68
- onSelect: () => {
69
- d(!1), u(a.value);
38
+ ),
39
+ n && s && /* @__PURE__ */ e(
40
+ "button",
41
+ {
42
+ type: "button",
43
+ disabled: r,
44
+ onClick: c,
45
+ className: "rounded-md px-2.5 py-1 text-[12px] font-medium text-slate-600 hover:bg-slate-100 disabled:opacity-50 dark:text-slate-300 dark:hover:bg-muted",
46
+ children: "Release"
47
+ }
48
+ ),
49
+ h,
50
+ m && /* @__PURE__ */ t(T, { open: b, onOpenChange: d, children: [
51
+ /* @__PURE__ */ e(O, { asChild: !0, children: /* @__PURE__ */ t(
52
+ "button",
53
+ {
54
+ type: "button",
55
+ disabled: r || o.length === 0,
56
+ className: "flex items-center gap-1 rounded-md px-2.5 py-1 text-[12px] font-medium text-slate-600 hover:bg-slate-100 disabled:opacity-50 dark:text-slate-300 dark:hover:bg-muted",
57
+ children: [
58
+ "Transition ",
59
+ /* @__PURE__ */ e(f, { className: "h-3 w-3" })
60
+ ]
61
+ }
62
+ ) }),
63
+ /* @__PURE__ */ e(P, { className: "w-[200px] p-0", align: "center", side: "top", children: /* @__PURE__ */ t(k, { children: [
64
+ /* @__PURE__ */ e(y, { placeholder: "Target state…", className: "h-8 text-[12px]" }),
65
+ /* @__PURE__ */ t(C, { children: [
66
+ /* @__PURE__ */ e(w, { children: "No state found." }),
67
+ o.map((a) => /* @__PURE__ */ e(
68
+ N,
69
+ {
70
+ value: a.label,
71
+ onSelect: () => {
72
+ d(!1), u(a.value);
73
+ },
74
+ children: a.label
70
75
  },
71
- children: a.label
72
- },
73
- a.value
74
- ))
75
- ] })
76
- ] }) })
77
- ] }),
78
- /* @__PURE__ */ e(
79
- "button",
80
- {
81
- type: "button",
82
- onClick: x,
83
- className: "ml-1 rounded-full p-1 text-slate-400 hover:text-slate-600 dark:hover:text-slate-200",
84
- "aria-label": "Clear selection",
85
- children: /* @__PURE__ */ e(v, { className: "h-3.5 w-3.5" })
86
- }
87
- )
88
- ] });
76
+ a.value
77
+ ))
78
+ ] })
79
+ ] }) })
80
+ ] }),
81
+ /* @__PURE__ */ e(
82
+ "button",
83
+ {
84
+ type: "button",
85
+ onClick: x,
86
+ className: "ml-1 rounded-full p-1 text-slate-400 hover:text-slate-600 dark:hover:text-slate-200",
87
+ "aria-label": "Clear selection",
88
+ children: /* @__PURE__ */ e(v, { className: "h-3.5 w-3.5" })
89
+ }
90
+ )
91
+ ] })
92
+ );
89
93
  }
90
94
  export {
91
95
  z as QueueBulkBar
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nivaro/react",
3
- "version": "0.3.79",
3
+ "version": "0.3.81",
4
4
  "description": "React hooks and components for Nivaro CMS forms",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",