@camstack/ui-library 1.2.286 → 1.2.288

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,4 +1,4 @@
1
- import { TEXT_HINT, WidgetPanel, isAbsentProvider, s as Grid2x2, useDeviceProxy, usePlayerOverlayLayer, useSystem } from "./index.js";
1
+ import { TEXT_HINT, WidgetPanel, _n as Grid2x2, isAbsentProvider, useDeviceProxy, usePlayerOverlayLayer, useSystem } from "./index.js";
2
2
  import { MaskShapeCanvas } from "./MaskShapeCanvas-DI4BY7W2.js";
3
3
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
4
4
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
@@ -1,18 +1,8 @@
1
- import { TEXT_HINT, WidgetPanel, a as MicOff, c as EyeOff, i as Mic, isAbsentProvider, n as Square, t as Trash2, u as createLucideIcon, useDeviceProxy, usePlayerOverlayLayer, useSystem } from "./index.js";
1
+ import { n as Hexagon, t as MicOff } from "./mic-off-C2VTYr91.js";
2
+ import { Ht as Mic, TEXT_HINT, V as Square, WidgetPanel, isAbsentProvider, jn as EyeOff, k as Trash2, useDeviceProxy, usePlayerOverlayLayer, useSystem } from "./index.js";
2
3
  import { MaskShapeCanvas } from "./MaskShapeCanvas-DI4BY7W2.js";
3
4
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
4
5
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
5
- /**
6
- * @license lucide-react v0.576.0 - ISC
7
- *
8
- * This source code is licensed under the ISC license.
9
- * See the LICENSE file in the root directory of this source tree.
10
- */
11
- var Hexagon = createLucideIcon("hexagon", [["path", {
12
- d: "M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z",
13
- key: "yt0hxn"
14
- }]]);
15
- //#endregion
16
6
  //#region src/composites/cap-settings/privacy-mask-audio.ts
17
7
  var CAMERA_MICROPHONE_LABEL = "Microphone";
18
8
  var COST_WHEN_OFF = "The camera encodes no audio at all — live view, recordings, exports and the audio analyzer are all silent.";
@@ -1,18 +1,8 @@
1
+ const require_mic_off = require("./mic-off-4nCMfrMI.cjs");
1
2
  const require_index = require("./index.cjs");
2
3
  const require_MaskShapeCanvas = require("./MaskShapeCanvas-BByN3jvt.cjs");
3
4
  let react = require("react");
4
5
  let react_jsx_runtime = require("react/jsx-runtime");
5
- /**
6
- * @license lucide-react v0.576.0 - ISC
7
- *
8
- * This source code is licensed under the ISC license.
9
- * See the LICENSE file in the root directory of this source tree.
10
- */
11
- var Hexagon = require_index.createLucideIcon("hexagon", [["path", {
12
- d: "M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z",
13
- key: "yt0hxn"
14
- }]]);
15
- //#endregion
16
6
  //#region src/composites/cap-settings/privacy-mask-audio.ts
17
7
  var CAMERA_MICROPHONE_LABEL = "Microphone";
18
8
  var COST_WHEN_OFF = "The camera encodes no audio at all — live view, recordings, exports and the audio analyzer are all silent.";
@@ -397,7 +387,7 @@ function PrivacyMaskSettings({ deviceId }) {
397
387
  className: "flex flex-col gap-1",
398
388
  children: draft.regions.map((r) => {
399
389
  const selected = selectedId === r.id;
400
- const ShapeIcon = r.shape.kind === "polygon" ? Hexagon : require_index.Square;
390
+ const ShapeIcon = r.shape.kind === "polygon" ? require_mic_off.Hexagon : require_index.Square;
401
391
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
402
392
  className: `flex items-center gap-2 rounded-md border px-2 py-1 transition-colors ${selected ? "border-primary/50 bg-primary/10" : "border-border bg-surface"}`,
403
393
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
@@ -438,7 +428,7 @@ function PrivacyMaskSettings({ deviceId }) {
438
428
  className: microphone.on === false || microphone.on === null ? BTN_NEUTRAL : BTN_PRIMARY,
439
429
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
440
430
  className: "inline-flex items-center gap-1.5",
441
- children: [microphone.on === false ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_index.MicOff, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_index.Mic, { className: "h-3.5 w-3.5" }), microphone.on === null ? "Microphone unknown" : microphone.on ? "Microphone on" : "Microphone off"]
431
+ children: [microphone.on === false ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_mic_off.MicOff, { className: "h-3.5 w-3.5" }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_index.Mic, { className: "h-3.5 w-3.5" }), microphone.on === null ? "Microphone unknown" : microphone.on ? "Microphone on" : "Microphone off"]
442
432
  })
443
433
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
444
434
  className: `text-[10px] text-foreground-subtle flex-1 leading-relaxed`,
@@ -1,36 +1,8 @@
1
+ const require_settings_2 = require("./settings-2-CR4WtEw4.cjs");
1
2
  const require_index = require("./index.cjs");
2
3
  const require_MaskShapeCanvas = require("./MaskShapeCanvas-BByN3jvt.cjs");
3
4
  let react = require("react");
4
5
  let react_jsx_runtime = require("react/jsx-runtime");
5
- /**
6
- * @license lucide-react v0.576.0 - ISC
7
- *
8
- * This source code is licensed under the ISC license.
9
- * See the LICENSE file in the root directory of this source tree.
10
- */
11
- var Settings2 = require_index.createLucideIcon("settings-2", [
12
- ["path", {
13
- d: "M14 17H5",
14
- key: "gfn3mx"
15
- }],
16
- ["path", {
17
- d: "M19 7h-9",
18
- key: "6i9tg"
19
- }],
20
- ["circle", {
21
- cx: "17",
22
- cy: "17",
23
- r: "3",
24
- key: "18b49y"
25
- }],
26
- ["circle", {
27
- cx: "7",
28
- cy: "7",
29
- r: "3",
30
- key: "dfmy0x"
31
- }]
32
- ]);
33
- //#endregion
34
6
  //#region src/composites/cap-settings/SceneReferenceGallery.tsx
35
7
  /** The hub-proxied prefix for the pipeline-analytics event-media data plane. */
36
8
  var SCENE_MEDIA_BASE = require_index.hubPath$1("/addon/pipeline-analytics/event-media");
@@ -900,7 +872,7 @@ function SceneMonitorEditor({ deviceId }) {
900
872
  "aria-label": `Settings for ${m.label}`,
901
873
  disabled: busy !== null,
902
874
  onClick: () => setTuningId((id) => id === m.id ? null : m.id),
903
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Settings2, { className: "mr-1 inline h-3 w-3" }), "Settings"]
875
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_settings_2.Settings2, { className: "mr-1 inline h-3 w-3" }), "Settings"]
904
876
  }),
905
877
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
906
878
  type: "button",
@@ -1,36 +1,8 @@
1
- import { SCENE_CAPTURE_VARIANTS, TEXT_HINT, badgeFor, coverageLine, hubPath, isAbsentProvider, l as Camera, o as ImageOff, r as RotateCcw, roiTooLarge, statusLine, t as Trash2, u as createLucideIcon, useDeviceProxy, useDeviceSnapshotImage, useDeviceStateSlice, useSystem, variantLabel } from "./index.js";
1
+ import { t as Settings2 } from "./settings-2-jT1iBqHD.js";
2
+ import { SCENE_CAPTURE_VARIANTS, TEXT_HINT, badgeFor, coverageLine, dt as RotateCcw, hubPath, isAbsentProvider, k as Trash2, roiTooLarge, statusLine, un as ImageOff, useDeviceProxy, useDeviceSnapshotImage, useDeviceStateSlice, useSystem, variantLabel, vr as Camera } from "./index.js";
2
3
  import { MaskShapeCanvas } from "./MaskShapeCanvas-DI4BY7W2.js";
3
4
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
4
5
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
5
- /**
6
- * @license lucide-react v0.576.0 - ISC
7
- *
8
- * This source code is licensed under the ISC license.
9
- * See the LICENSE file in the root directory of this source tree.
10
- */
11
- var Settings2 = createLucideIcon("settings-2", [
12
- ["path", {
13
- d: "M14 17H5",
14
- key: "gfn3mx"
15
- }],
16
- ["path", {
17
- d: "M19 7h-9",
18
- key: "6i9tg"
19
- }],
20
- ["circle", {
21
- cx: "17",
22
- cy: "17",
23
- r: "3",
24
- key: "18b49y"
25
- }],
26
- ["circle", {
27
- cx: "7",
28
- cy: "7",
29
- r: "3",
30
- key: "dfmy0x"
31
- }]
32
- ]);
33
- //#endregion
34
6
  //#region src/composites/cap-settings/SceneReferenceGallery.tsx
35
7
  /** The hub-proxied prefix for the pipeline-analytics event-media data plane. */
36
8
  var SCENE_MEDIA_BASE = hubPath("/addon/pipeline-analytics/event-media");
@@ -1,5 +1,5 @@
1
1
  import type { LucideIcon } from "lucide-react";
2
- import { DeviceType, DeviceRole } from "@camstack/types";
2
+ import { DeviceType, DeviceRole, type IconKey } from "@camstack/types";
3
3
  import type { MultiSelectOption } from "./device-list/multi-select";
4
4
  /**
5
5
  * Single source of truth for rendering a device TYPE or ROLE: its icon + label.
@@ -40,24 +40,15 @@ export declare function deviceTypeMetaOf(type: string): DeviceTypeMeta;
40
40
  /** Runtime-string-safe role lookup; unknown roles fall back to `GenericSensor`. */
41
41
  export declare function deviceRoleMetaOf(role: string): DeviceRoleMeta;
42
42
  /**
43
- * Icons an operator may pick for a per-device `display.icon` override (and for
44
- * a per-role default), keyed by a stable kebab-case name. Named imports only —
45
- * no dynamic indexing into lucide, so the bundle carries exactly this set.
46
- * Unknown keys resolve to `undefined` (caller falls through to the next level).
43
+ * The glyphs the admin draws on FIRST PAINT, synchronously — the ones the
44
+ * device-type and role meta tables above already import. Everything else in
45
+ * the icon catalog is drawn from the lazily loaded full table
46
+ * (`icon-glyphs.ts`), so the initial chunk carries ~60 lucide icons instead of
47
+ * one static import per catalog key (D854).
47
48
  *
48
- * The vocabulary is the one the VIEWER draws from too (its own icon module,
49
- * keyed by these same strings): a key added here that the phone cannot draw
50
- * falls through to the next resolution level there, which reads as "my change
51
- * did nothing". So the KEY is the contract — a stable kebab-case string, never
52
- * a glyph identity — and `device-meta.test.ts` pins that every key resolves
53
- * and that the set never loses a key an operator may already have persisted.
54
- *
55
- * Grouped by what an operator is naming: a device, a light or appliance, a
56
- * sensor or the weather it reads, a room, or what moves through it. `gauge2`
57
- * is a legacy alias kept for rows that persisted it.
49
+ * Typed `Partial<Record<IconKey, ...>>`: a key that is not in the catalog is a
50
+ * compile error, so this table can never become a second vocabulary — it is a
51
+ * cache of glyphs, not a list of choices.
58
52
  */
59
- export declare const DISPLAY_ICON_REGISTRY: Readonly<Record<string, LucideIcon>>;
60
- /** Resolve a `display.icon` name to a lucide component, or `undefined` when the
61
- * name is not in the curated `DISPLAY_ICON_REGISTRY`. */
62
- export declare function resolveDisplayIcon(name: string): LucideIcon | undefined;
53
+ export declare const FAST_ICON_GLYPHS: Readonly<Partial<Record<IconKey, LucideIcon>>>;
63
54
  export declare function allDeviceTypeFilterOptions(): readonly MultiSelectOption[];
@@ -0,0 +1,30 @@
1
+ import type { LucideIcon } from "lucide-react";
2
+ /** `house` → `House`, `arrow-down-0-1` → `ArrowDown01`: lucide's export naming. */
3
+ export declare function lucideExportName(key: string): string;
4
+ /**
5
+ * Load the full glyph table once. Resolves when it is available; rejects (once)
6
+ * if the chunk could not be fetched. Safe to call repeatedly.
7
+ */
8
+ export declare function loadIconGlyphs(): Promise<void>;
9
+ /** Has the lazy glyph chunk failed to load? (Then only the fast table answers.) */
10
+ export declare function iconGlyphsFailed(): boolean;
11
+ /** Is the full table loaded? */
12
+ export declare function iconGlyphsLoaded(): boolean;
13
+ /**
14
+ * The glyph for a stored icon value (a catalog key, or a spelling that
15
+ * resolves to one), or `undefined` when it names no catalog icon — or when its
16
+ * glyph is not loaded YET, in which case the load is started.
17
+ */
18
+ export declare function resolveDisplayIcon(name: string): LucideIcon | undefined;
19
+ /**
20
+ * Subscribe a component to the lazy glyph table. Call it in any component that
21
+ * draws the result of `resolveDisplayIcon` (directly or through a helper such
22
+ * as `deviceLeadIcon`): it re-renders once when the table arrives, so a glyph
23
+ * that was `undefined` a moment ago is drawn.
24
+ */
25
+ export declare function useIconGlyphsVersion(): number;
26
+ /**
27
+ * `resolveDisplayIcon` for a component: the returned function changes identity
28
+ * when the full table arrives, so anything memoised on it recomputes.
29
+ */
30
+ export declare function useDisplayIconResolver(): (name: string) => LucideIcon | undefined;
@@ -1,39 +1,40 @@
1
1
  /**
2
2
  * icon-picker — the ONE control for choosing an icon, wherever admin-ui asks.
3
3
  *
4
- * There were two: a device one over `DISPLAY_ICON_REGISTRY` and a room one
5
- * over `LOCATION_ICON_IDS`, identical apart from the vocabulary they walked.
6
- * That was tolerable while the device set was 56 glyphs in a flat grid. It is
7
- * not at 157: a picker that only lets the operator HUNT is a picker they stop
8
- * using, and the two copies were already drifting — only one of them had an
9
- * i18n'd label.
4
+ * One view over the ONE icon catalog (`@camstack/types`' `icon-catalog`, D854):
5
+ * every lucide icon both surfaces can draw, filed under its primary lucide
6
+ * category, searched over the key, the Italian/English overlay and lucide's own
7
+ * English tags. There is no curated section and no per-caller subset — a device
8
+ * override, a room and a settings field all choose from the same ~1,700 icons.
10
9
  *
11
- * So the vocabulary, the grouping and the search all come from
12
- * `@camstack/types`' `display-icon-vocabulary`, which is the same module the
13
- * viewer's sheet searches. What is left here is the web half: a popover, a
14
- * grid, and a text field.
10
+ * ## It is virtualised
11
+ *
12
+ * ~1,700 tiles is too many to mount at once (and each is an SVG component whose
13
+ * glyph may still be loading). The list is flattened into fixed-height rows —
14
+ * a category header or a row of seven tiles — and only the rows in (or just
15
+ * past) the scrolled window are rendered; two spacers stand in for the rest.
16
+ * Opening the popover mounts ~20 rows, and typing re-filters the same window.
15
17
  *
16
18
  * ## What it does NOT own
17
19
  *
18
- * - **The glyphs.** `resolveGlyph` is a prop, because this package's table is
19
- * `lucide-react` and the viewer's is `lucide-react-native`. A key this build
20
- * cannot draw is SKIPPED rather than rendered as a hole — an empty tile
21
- * reads as a rendering bug, not as a missing choice.
22
20
  * - **The words.** Every string is a prop. This package has no i18n (one file
23
- * in it imports react-i18next, and that is the exception), and a control
24
- * that reached for a translation would force it on every consumer.
21
+ * in it imports react-i18next, and that is the exception). Section titles are
22
+ * derived from the lucide category id unless the caller supplies
23
+ * `categoryLabel`.
25
24
  * - **The write.** `onPick` is called and that is all; whether it is a form
26
- * value or an immediate mutation is the caller's business, as it already was
27
- * in both pickers this replaces.
25
+ * value or an immediate mutation is the caller's business.
26
+ *
27
+ * The glyphs come from `icon-glyphs.ts`: a synchronous fast table, then one
28
+ * lazily loaded table for the rest, which opening the picker starts loading.
28
29
  *
29
30
  * ## The clear tile is never filtered away
30
31
  *
31
- * The "inherit" / "no icon" choice sits above the sections and ignores the
32
- * search. A query that hid it would strand the operator on a glyph they picked
33
- * by accident with no way back to the default — the one action a picker must
32
+ * The "inherit" / "no icon" choice sits above the list and ignores the search.
33
+ * A query that hid it would strand the operator on a glyph they picked by
34
+ * accident with no way back to the default — the one action a picker must
34
35
  * always offer.
35
36
  */
36
- import { type DisplayIconGroup } from "@camstack/types";
37
+ import { type IconCategoryId, type IconKey } from "@camstack/types";
37
38
  import type { LucideIcon } from "lucide-react";
38
39
  import { type JSX } from "react";
39
40
  /** The strings this control shows. All of them, so nothing is hardcoded. */
@@ -42,26 +43,17 @@ export interface IconPickerLabels {
42
43
  readonly trigger: string;
43
44
  /** The popover's accessible name. */
44
45
  readonly panel: string;
45
- /** The backdrop button's accessible name. */
46
- readonly close: string;
47
46
  readonly searchPlaceholder: string;
48
47
  /** The tile that clears the pick — "No icon", "Inherit from the role", … */
49
48
  readonly clear: string;
50
- /** Shown in place of the grid when the query matches nothing. */
49
+ /** Shown in place of the list when the query matches nothing. */
51
50
  readonly noMatches: string;
52
- /** One per group, keyed by group id. */
53
- readonly groups: Readonly<Record<DisplayIconGroup, string>>;
54
51
  }
55
52
  export interface IconPickerProps {
56
- /** The chosen key, or `null` for "nothing chosen". */
53
+ /** The chosen key (or a spelling that resolves to one), or `null` for "nothing chosen". */
57
54
  readonly value: string | null;
58
- /** `null` clears the choice. */
59
- readonly onPick: (key: string | null) => void | Promise<void>;
60
- /**
61
- * The glyph for a key, or `undefined` when this build cannot draw it. The
62
- * caller's table, never a lookup this component makes.
63
- */
64
- readonly resolveGlyph: (key: string) => LucideIcon | undefined;
55
+ /** `null` clears the choice; otherwise a canonical catalog key. */
56
+ readonly onPick: (key: IconKey | null) => void | Promise<void>;
65
57
  /** What the trigger draws when `value` is null or undrawable. */
66
58
  readonly fallbackGlyph: LucideIcon;
67
59
  /**
@@ -74,18 +66,15 @@ export interface IconPickerProps {
74
66
  * A human name for a key, for the tile's title and accessible name. The key
75
67
  * itself when absent — which is honest, since the key IS what gets stored.
76
68
  */
77
- readonly labelFor?: (key: string) => string | undefined;
69
+ readonly labelFor?: (key: IconKey) => string | undefined;
70
+ /** Title of a category section. Derived from the lucide category id when absent. */
71
+ readonly categoryLabel?: (category: IconCategoryId) => string;
78
72
  readonly labels: IconPickerLabels;
79
73
  /**
80
- * Restrict the vocabulary to these keys — the room picker offers only
81
- * `LOCATION_ICON_IDS`. Absent means the whole vocabulary.
82
- */
83
- readonly only?: readonly string[];
84
- /**
85
74
  * Extra searchable words per key, for a caller that has translations this
86
75
  * package cannot see. Scored exactly like a synonym.
87
76
  */
88
77
  readonly extraWords?: ReadonlyMap<string, readonly string[]>;
89
78
  readonly disabled?: boolean;
90
79
  }
91
- export declare function IconPicker({ value, onPick, resolveGlyph, fallbackGlyph, labels, only, extraWords, clearGlyph, labelFor, disabled }: IconPickerProps): JSX.Element | null;
80
+ export declare function IconPicker({ value, onPick, fallbackGlyph, labels, extraWords, clearGlyph, labelFor, categoryLabel, disabled }: IconPickerProps): JSX.Element | null;
@@ -112,6 +112,7 @@ export * from "./device-list";
112
112
  export type { DeviceBatchToolbarProps } from "./device-list/batch-toolbar";
113
113
  export { DeviceBatchToolbar } from "./device-list/batch-toolbar";
114
114
  export * from "./device-meta";
115
+ export * from "./icon-glyphs";
115
116
  export * from "./icon-picker";
116
117
  export { DeviceMultiSelectField, DeviceSelectField } from "./device-select-field";
117
118
  export type { NotificationTargetOption, NotificationTargetSelectFieldProps, NotificationTargetsFieldProps } from "./notification-targets-field";
@@ -0,0 +1,116 @@
1
+ let react = require("react");
2
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/mergeClasses.js
3
+ /**
4
+ * @license lucide-react v0.576.0 - ISC
5
+ *
6
+ * This source code is licensed under the ISC license.
7
+ * See the LICENSE file in the root directory of this source tree.
8
+ */
9
+ var mergeClasses = (...classes) => classes.filter((className, index, array) => {
10
+ return Boolean(className) && className.trim() !== "" && array.indexOf(className) === index;
11
+ }).join(" ").trim();
12
+ //#endregion
13
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/toKebabCase.js
14
+ /**
15
+ * @license lucide-react v0.576.0 - ISC
16
+ *
17
+ * This source code is licensed under the ISC license.
18
+ * See the LICENSE file in the root directory of this source tree.
19
+ */
20
+ var toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
21
+ //#endregion
22
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/toCamelCase.js
23
+ /**
24
+ * @license lucide-react v0.576.0 - ISC
25
+ *
26
+ * This source code is licensed under the ISC license.
27
+ * See the LICENSE file in the root directory of this source tree.
28
+ */
29
+ var toCamelCase = (string) => string.replace(/^([A-Z])|[\s-_]+(\w)/g, (match, p1, p2) => p2 ? p2.toUpperCase() : p1.toLowerCase());
30
+ //#endregion
31
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/toPascalCase.js
32
+ /**
33
+ * @license lucide-react v0.576.0 - ISC
34
+ *
35
+ * This source code is licensed under the ISC license.
36
+ * See the LICENSE file in the root directory of this source tree.
37
+ */
38
+ var toPascalCase = (string) => {
39
+ const camelCase = toCamelCase(string);
40
+ return camelCase.charAt(0).toUpperCase() + camelCase.slice(1);
41
+ };
42
+ //#endregion
43
+ //#region ../../node_modules/lucide-react/dist/esm/defaultAttributes.js
44
+ /**
45
+ * @license lucide-react v0.576.0 - ISC
46
+ *
47
+ * This source code is licensed under the ISC license.
48
+ * See the LICENSE file in the root directory of this source tree.
49
+ */
50
+ var defaultAttributes = {
51
+ xmlns: "http://www.w3.org/2000/svg",
52
+ width: 24,
53
+ height: 24,
54
+ viewBox: "0 0 24 24",
55
+ fill: "none",
56
+ stroke: "currentColor",
57
+ strokeWidth: 2,
58
+ strokeLinecap: "round",
59
+ strokeLinejoin: "round"
60
+ };
61
+ //#endregion
62
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/hasA11yProp.js
63
+ /**
64
+ * @license lucide-react v0.576.0 - ISC
65
+ *
66
+ * This source code is licensed under the ISC license.
67
+ * See the LICENSE file in the root directory of this source tree.
68
+ */
69
+ var hasA11yProp = (props) => {
70
+ for (const prop in props) if (prop.startsWith("aria-") || prop === "role" || prop === "title") return true;
71
+ return false;
72
+ };
73
+ //#endregion
74
+ //#region ../../node_modules/lucide-react/dist/esm/Icon.js
75
+ /**
76
+ * @license lucide-react v0.576.0 - ISC
77
+ *
78
+ * This source code is licensed under the ISC license.
79
+ * See the LICENSE file in the root directory of this source tree.
80
+ */
81
+ var Icon = (0, react.forwardRef)(({ color = "currentColor", size = 24, strokeWidth = 2, absoluteStrokeWidth, className = "", children, iconNode, ...rest }, ref) => (0, react.createElement)("svg", {
82
+ ref,
83
+ ...defaultAttributes,
84
+ width: size,
85
+ height: size,
86
+ stroke: color,
87
+ strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,
88
+ className: mergeClasses("lucide", className),
89
+ ...!children && !hasA11yProp(rest) && { "aria-hidden": "true" },
90
+ ...rest
91
+ }, [...iconNode.map(([tag, attrs]) => (0, react.createElement)(tag, attrs)), ...Array.isArray(children) ? children : [children]]));
92
+ //#endregion
93
+ //#region ../../node_modules/lucide-react/dist/esm/createLucideIcon.js
94
+ /**
95
+ * @license lucide-react v0.576.0 - ISC
96
+ *
97
+ * This source code is licensed under the ISC license.
98
+ * See the LICENSE file in the root directory of this source tree.
99
+ */
100
+ var createLucideIcon = (iconName, iconNode) => {
101
+ const Component = (0, react.forwardRef)(({ className, ...props }, ref) => (0, react.createElement)(Icon, {
102
+ ref,
103
+ iconNode,
104
+ className: mergeClasses(`lucide-${toKebabCase(toPascalCase(iconName))}`, `lucide-${iconName}`, className),
105
+ ...props
106
+ }));
107
+ Component.displayName = toPascalCase(iconName);
108
+ return Component;
109
+ };
110
+ //#endregion
111
+ Object.defineProperty(exports, "createLucideIcon", {
112
+ enumerable: true,
113
+ get: function() {
114
+ return createLucideIcon;
115
+ }
116
+ });
@@ -0,0 +1,111 @@
1
+ import { createElement, forwardRef } from "react";
2
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/mergeClasses.js
3
+ /**
4
+ * @license lucide-react v0.576.0 - ISC
5
+ *
6
+ * This source code is licensed under the ISC license.
7
+ * See the LICENSE file in the root directory of this source tree.
8
+ */
9
+ var mergeClasses = (...classes) => classes.filter((className, index, array) => {
10
+ return Boolean(className) && className.trim() !== "" && array.indexOf(className) === index;
11
+ }).join(" ").trim();
12
+ //#endregion
13
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/toKebabCase.js
14
+ /**
15
+ * @license lucide-react v0.576.0 - ISC
16
+ *
17
+ * This source code is licensed under the ISC license.
18
+ * See the LICENSE file in the root directory of this source tree.
19
+ */
20
+ var toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
21
+ //#endregion
22
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/toCamelCase.js
23
+ /**
24
+ * @license lucide-react v0.576.0 - ISC
25
+ *
26
+ * This source code is licensed under the ISC license.
27
+ * See the LICENSE file in the root directory of this source tree.
28
+ */
29
+ var toCamelCase = (string) => string.replace(/^([A-Z])|[\s-_]+(\w)/g, (match, p1, p2) => p2 ? p2.toUpperCase() : p1.toLowerCase());
30
+ //#endregion
31
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/toPascalCase.js
32
+ /**
33
+ * @license lucide-react v0.576.0 - ISC
34
+ *
35
+ * This source code is licensed under the ISC license.
36
+ * See the LICENSE file in the root directory of this source tree.
37
+ */
38
+ var toPascalCase = (string) => {
39
+ const camelCase = toCamelCase(string);
40
+ return camelCase.charAt(0).toUpperCase() + camelCase.slice(1);
41
+ };
42
+ //#endregion
43
+ //#region ../../node_modules/lucide-react/dist/esm/defaultAttributes.js
44
+ /**
45
+ * @license lucide-react v0.576.0 - ISC
46
+ *
47
+ * This source code is licensed under the ISC license.
48
+ * See the LICENSE file in the root directory of this source tree.
49
+ */
50
+ var defaultAttributes = {
51
+ xmlns: "http://www.w3.org/2000/svg",
52
+ width: 24,
53
+ height: 24,
54
+ viewBox: "0 0 24 24",
55
+ fill: "none",
56
+ stroke: "currentColor",
57
+ strokeWidth: 2,
58
+ strokeLinecap: "round",
59
+ strokeLinejoin: "round"
60
+ };
61
+ //#endregion
62
+ //#region ../../node_modules/lucide-react/dist/esm/shared/src/utils/hasA11yProp.js
63
+ /**
64
+ * @license lucide-react v0.576.0 - ISC
65
+ *
66
+ * This source code is licensed under the ISC license.
67
+ * See the LICENSE file in the root directory of this source tree.
68
+ */
69
+ var hasA11yProp = (props) => {
70
+ for (const prop in props) if (prop.startsWith("aria-") || prop === "role" || prop === "title") return true;
71
+ return false;
72
+ };
73
+ //#endregion
74
+ //#region ../../node_modules/lucide-react/dist/esm/Icon.js
75
+ /**
76
+ * @license lucide-react v0.576.0 - ISC
77
+ *
78
+ * This source code is licensed under the ISC license.
79
+ * See the LICENSE file in the root directory of this source tree.
80
+ */
81
+ var Icon = forwardRef(({ color = "currentColor", size = 24, strokeWidth = 2, absoluteStrokeWidth, className = "", children, iconNode, ...rest }, ref) => createElement("svg", {
82
+ ref,
83
+ ...defaultAttributes,
84
+ width: size,
85
+ height: size,
86
+ stroke: color,
87
+ strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,
88
+ className: mergeClasses("lucide", className),
89
+ ...!children && !hasA11yProp(rest) && { "aria-hidden": "true" },
90
+ ...rest
91
+ }, [...iconNode.map(([tag, attrs]) => createElement(tag, attrs)), ...Array.isArray(children) ? children : [children]]));
92
+ //#endregion
93
+ //#region ../../node_modules/lucide-react/dist/esm/createLucideIcon.js
94
+ /**
95
+ * @license lucide-react v0.576.0 - ISC
96
+ *
97
+ * This source code is licensed under the ISC license.
98
+ * See the LICENSE file in the root directory of this source tree.
99
+ */
100
+ var createLucideIcon = (iconName, iconNode) => {
101
+ const Component = forwardRef(({ className, ...props }, ref) => createElement(Icon, {
102
+ ref,
103
+ iconNode,
104
+ className: mergeClasses(`lucide-${toKebabCase(toPascalCase(iconName))}`, `lucide-${iconName}`, className),
105
+ ...props
106
+ }));
107
+ Component.displayName = toPascalCase(iconName);
108
+ return Component;
109
+ };
110
+ //#endregion
111
+ export { createLucideIcon as t };
@@ -427,6 +427,22 @@ export declare const useDeviceAdoptionRelease: typeof trpc.deviceAdoption.releas
427
427
  export declare const useDeviceAdoptionResync: typeof trpc.deviceAdoption.resync.useMutation;
428
428
  /** Generated alias around `trpc.deviceAdoption.getStatus.useQuery`. */
429
429
  export declare const useDeviceAdoptionGetStatus: typeof trpc.deviceAdoption.getStatus.useQuery;
430
+ /** Generated alias around `trpc.deviceCredentials.listDeviceCredentials.useQuery`. */
431
+ export declare const useDeviceCredentialsListDeviceCredentials: typeof trpc.deviceCredentials.listDeviceCredentials.useQuery;
432
+ /** Generated alias around `trpc.deviceCredentials.startEnrollment.useMutation`. */
433
+ export declare const useDeviceCredentialsStartEnrollment: typeof trpc.deviceCredentials.startEnrollment.useMutation;
434
+ /** Generated alias around `trpc.deviceCredentials.revokeDeviceCredential.useMutation`. */
435
+ export declare const useDeviceCredentialsRevokeDeviceCredential: typeof trpc.deviceCredentials.revokeDeviceCredential.useMutation;
436
+ /** Generated alias around `trpc.deviceCredentials.getDeviceCertificateSettings.useQuery`. */
437
+ export declare const useDeviceCredentialsGetDeviceCertificateSettings: typeof trpc.deviceCredentials.getDeviceCertificateSettings.useQuery;
438
+ /** Generated alias around `trpc.deviceCredentials.setDeviceCertificateSettings.useMutation`. */
439
+ export declare const useDeviceCredentialsSetDeviceCertificateSettings: typeof trpc.deviceCredentials.setDeviceCertificateSettings.useMutation;
440
+ /** Generated alias around `trpc.deviceCredentials.deleteDeviceCredential.useMutation`. */
441
+ export declare const useDeviceCredentialsDeleteDeviceCredential: typeof trpc.deviceCredentials.deleteDeviceCredential.useMutation;
442
+ /** Generated alias around `trpc.deviceCredentials.getDeviceCaStatus.useQuery`. */
443
+ export declare const useDeviceCredentialsGetDeviceCaStatus: typeof trpc.deviceCredentials.getDeviceCaStatus.useQuery;
444
+ /** Generated alias around `trpc.deviceCredentials.renameDeviceCredential.useMutation`. */
445
+ export declare const useDeviceCredentialsRenameDeviceCredential: typeof trpc.deviceCredentials.renameDeviceCredential.useMutation;
430
446
  /** Generated alias around `trpc.deviceDiscovery.listDiscovered.useQuery`. */
431
447
  export declare const useDeviceDiscoveryListDiscovered: typeof trpc.deviceDiscovery.listDiscovered.useQuery;
432
448
  /** Generated alias around `trpc.deviceDiscovery.refreshDiscovery.useMutation`. */