@nar-bus/lena-ui-shared 1.3.12 → 1.3.14

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.d.ts CHANGED
@@ -147,8 +147,8 @@ export declare interface AppHeaderLogo {
147
147
 
148
148
  export declare interface AppHeaderProps {
149
149
  breadcrumbs: BreadcrumbItem[];
150
- theme: 'light' | 'dark' | 'system';
151
- onThemeChange: (theme: 'light' | 'dark' | 'system') => void;
150
+ theme: 'light' | 'dark';
151
+ onThemeChange: (theme: 'light' | 'dark') => void;
152
152
  locale?: string;
153
153
  onLocaleChange?: (locale: string) => void;
154
154
  user?: AppHeaderUser | null;
@@ -239,6 +239,8 @@ declare interface AsyncSelectFieldProps<TFieldValues extends FieldValues> {
239
239
  cols?: 1 | 2 | 3 | 4 | 6 | 12;
240
240
  }
241
241
 
242
+ export declare function autoStatusColor(value: string): string;
243
+
242
244
  export declare function Avatar({ className, size, ...props }: React_2.ComponentProps<typeof AvatarPrimitive.Root> & {
243
245
  size?: "default" | "sm" | "lg";
244
246
  }): JSX.Element;
@@ -278,6 +280,10 @@ declare interface BadgeCellProps {
278
280
  className?: string;
279
281
  }
280
282
 
283
+ declare type BadgeSize = keyof typeof SIZE_STYLES;
284
+
285
+ declare type BadgeVariant = keyof typeof VARIANT_STYLES;
286
+
281
287
  export declare const badgeVariants: (props?: ({
282
288
  variant?: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
283
289
  } & ClassProp) | undefined) => string;
@@ -347,6 +353,22 @@ export declare function BreadcrumbSeparator({ children, className, ...props }: R
347
353
 
348
354
  export declare function BreadcrumbUIItem({ className, ...props }: React_2.ComponentProps<"li">): JSX.Element;
349
355
 
356
+ /**
357
+ * Manifest groups + current pathname'den breadcrumb zinciri türetir.
358
+ *
359
+ * Children in manifest items are treated as tab-level navigation and are NOT
360
+ * included in the breadcrumb trail. The breadcrumb stops at the parent item.
361
+ *
362
+ * @example
363
+ * buildBreadcrumbsFromManifest(manifest.groups, '/device-management/meters', 'tr')
364
+ * // → [{ label: 'Envanter', href: '/brand-model' }, { label: 'Cihaz Yönetimi' }]
365
+ * // Note: 'Sayaçlar' (tab) is NOT included — breadcrumb stops at parent
366
+ *
367
+ * buildBreadcrumbsFromManifest(manifest.groups, '/simcard', 'tr')
368
+ * // → [{ label: 'Envanter', href: '/brand-model' }, { label: 'SIM Kartlar' }]
369
+ */
370
+ export declare function buildBreadcrumbsFromManifest(groups: ManifestGroup[], pathname: string, locale: string): BreadcrumbItem[];
371
+
350
372
  export declare interface BulkAction<TData> {
351
373
  id: string;
352
374
  label: string;
@@ -1226,11 +1248,11 @@ declare interface DetailPageMetadataFooterProps {
1226
1248
  export declare const deviceStatusColors: {
1227
1249
  readonly ACTIVE: "bg-status-success/10 text-status-success-foreground border-status-success/30 ring-status-success/30";
1228
1250
  readonly INACTIVE: "bg-status-neutral/10 text-status-neutral-foreground border-status-neutral/30 ring-status-neutral/30";
1229
- readonly MAINTENANCE: "bg-status-warning/10 text-status-warning border-status-warning/30 ring-status-warning/30";
1230
- readonly FAULTY: "bg-status-error/10 text-status-error border-status-error/30 ring-status-error/30";
1251
+ readonly MAINTENANCE: "bg-status-warning/10 text-status-warning-foreground border-status-warning/30 ring-status-warning/30";
1252
+ readonly FAULTY: "bg-status-error/10 text-status-error-foreground border-status-error/30 ring-status-error/30";
1231
1253
  readonly ONLINE: "bg-status-success/10 text-status-success-foreground border-status-success/30 ring-status-success/30";
1232
1254
  readonly OFFLINE: "bg-status-neutral/10 text-status-neutral-foreground border-status-neutral/30 ring-status-neutral/30";
1233
- readonly PENDING: "bg-status-warning/10 text-status-warning border-status-warning/30 ring-status-warning/30";
1255
+ readonly PENDING: "bg-status-warning/10 text-status-warning-foreground border-status-warning/30 ring-status-warning/30";
1234
1256
  readonly CONNECTED: "bg-status-success/10 text-status-success-foreground border-status-success/30 ring-status-success/30";
1235
1257
  readonly DISCONNECTED: "bg-status-neutral/10 text-status-neutral-foreground border-status-neutral/30 ring-status-neutral/30";
1236
1258
  };
@@ -1346,6 +1368,49 @@ export declare interface EnumPrefetcherProps {
1346
1368
  fetcher: EnumFetcher;
1347
1369
  }
1348
1370
 
1371
+ export declare function EnumSelectField<TFieldValues extends FieldValues>({ enumKey, fallback, ...rest }: EnumSelectFieldProps<TFieldValues>): JSX.Element;
1372
+
1373
+ declare interface EnumSelectFieldProps<TFieldValues extends FieldValues> {
1374
+ name: FieldPath<TFieldValues>;
1375
+ control: Control<TFieldValues>;
1376
+ /** Enum cache key — backend'den tanımlanan enum code'u */
1377
+ enumKey: string;
1378
+ /** Cache yüklenmeden önce gösterilecek fallback options */
1379
+ fallback?: SelectOption[];
1380
+ label?: string;
1381
+ description?: string;
1382
+ required?: boolean;
1383
+ placeholder?: string;
1384
+ searchPlaceholder?: string;
1385
+ emptyText?: string;
1386
+ disabled?: boolean;
1387
+ className?: string;
1388
+ cols?: 1 | 2 | 3 | 4 | 6 | 12;
1389
+ errorHint?: string;
1390
+ }
1391
+
1392
+ export declare function EnumText({ enumKey, value, fallback, className }: EnumTextProps): JSX.Element;
1393
+
1394
+ /**
1395
+ * EnumText — Enum cache'den label resolve eden display component.
1396
+ *
1397
+ * Static label map'lerin drop-in replacement'ı:
1398
+ * ```tsx
1399
+ * // ÖNCE: {protocolTypeLabels[protocol.protocolType]}
1400
+ * // SONRA: <EnumText enumKey="PROTOCOL_TYPE" value={protocol.protocolType} />
1401
+ * ```
1402
+ */
1403
+ export declare interface EnumTextProps {
1404
+ /** Enum cache key (e.g., 'PROTOCOL_TYPE') */
1405
+ enumKey: string;
1406
+ /** Backend'den gelen raw enum value (e.g., 'DLMS') */
1407
+ value: string | undefined | null;
1408
+ /** Fallback text when value is empty */
1409
+ fallback?: string;
1410
+ /** Optional className */
1411
+ className?: string;
1412
+ }
1413
+
1349
1414
  /**
1350
1415
  * Error Boundary Component
1351
1416
  * Catches JavaScript errors in child component tree and displays fallback UI
@@ -1422,6 +1487,12 @@ export declare interface FieldConfig {
1422
1487
  type: FieldType;
1423
1488
  /** Options for enum fields */
1424
1489
  options?: SelectOption[];
1490
+ /**
1491
+ * Enum cache key — otomatik olarak cache'den resolve edilir.
1492
+ * `type: 'enum'` ile birlikte kullanılır. `options` yerine tercih edilmeli.
1493
+ * @example { field: 'status', type: 'enum', enumKey: 'METER_STATUS' }
1494
+ */
1495
+ enumKey?: string;
1425
1496
  /** Async function to load options */
1426
1497
  loadOptions?: () => Promise<SelectOption[]>;
1427
1498
  /** Placeholder text for input */
@@ -1688,6 +1759,17 @@ export declare interface GaugeFooterStat {
1688
1759
  colorClass?: string;
1689
1760
  }
1690
1761
 
1762
+ /**
1763
+ * Get a tone color class string from a base color family.
1764
+ * Each unique value gets a deterministic tone level within the family.
1765
+ * All class strings are pre-defined for Tailwind JIT compatibility.
1766
+ *
1767
+ * @example
1768
+ * generateToneColor('G_2', 'accent') // lighter cyan
1769
+ * generateToneColor('G_5', 'accent') // darker cyan
1770
+ */
1771
+ export declare function generateToneColor(value: string, baseColor: StatusColor): string;
1772
+
1691
1773
  /**
1692
1774
  * Get error path for highlighting in tree view
1693
1775
  */
@@ -1715,16 +1797,23 @@ export declare type GradientPair = [topColor: string, bottomColor: string];
1715
1797
 
1716
1798
  declare function Header({ children, icon: Icon, iconClassName, subtitle, actions, gradient, className, }: LenaPanelHeaderProps): JSX.Element;
1717
1799
 
1718
- export declare function HeaderCreateButton({ label, icon, children, contentClassName, className, }: HeaderCreateButtonProps): JSX.Element;
1800
+ export declare function HeaderCreateButton({ label, icon, searchPlaceholder, emptyText, children, contentClassName, className, }: HeaderCreateButtonProps): JSX.Element;
1719
1801
 
1720
1802
  export declare interface HeaderCreateButtonProps {
1721
1803
  /** Button label text */
1722
1804
  label: string;
1723
1805
  /** Custom icon — defaults to Plus */
1724
1806
  icon?: ReactNode;
1725
- /** DropdownMenu items rendered inside the dropdown content */
1807
+ /** Placeholder for search input */
1808
+ searchPlaceholder?: string;
1809
+ /** Empty state text when no results match */
1810
+ emptyText?: string;
1811
+ /**
1812
+ * Command palette content — use CommandGroup + CommandItem from lena-ui-shared.
1813
+ * Each CommandItem's onSelect should call the provided `onClose` or manage its own state.
1814
+ */
1726
1815
  children: ReactNode;
1727
- /** Additional class for DropdownMenuContent */
1816
+ /** Additional class for PopoverContent */
1728
1817
  contentClassName?: string;
1729
1818
  /** Additional class for the trigger button */
1730
1819
  className?: string;
@@ -1732,7 +1821,7 @@ export declare interface HeaderCreateButtonProps {
1732
1821
 
1733
1822
  export declare type HeaderGradient = 'teal' | 'navy' | 'cherry' | 'emerald' | 'amber' | 'violet' | 'rose' | 'indigo' | 'orange';
1734
1823
 
1735
- export declare function HeaderQuickSearch({ placeholder, value, onValueChange, open, onOpenChange, loading, shortcutKey, shouldFilter, className, children, }: HeaderQuickSearchProps): JSX.Element;
1824
+ export declare function HeaderQuickSearch({ placeholder, value, onValueChange, open, onOpenChange, loading, shortcutKey, shouldFilter, filter, className, children, }: HeaderQuickSearchProps): JSX.Element;
1736
1825
 
1737
1826
  export declare interface HeaderQuickSearchProps {
1738
1827
  placeholder?: string;
@@ -1743,6 +1832,8 @@ export declare interface HeaderQuickSearchProps {
1743
1832
  loading?: boolean;
1744
1833
  shortcutKey?: string;
1745
1834
  shouldFilter?: boolean;
1835
+ /** Custom filter function for cmdk (default: starts-with) */
1836
+ filter?: (value: string, search: string) => number;
1746
1837
  className?: string;
1747
1838
  children?: ReactNode;
1748
1839
  }
@@ -2192,6 +2283,22 @@ export declare interface LocationMapProps {
2192
2283
  className?: string;
2193
2284
  }
2194
2285
 
2286
+ export declare interface ManifestGroup {
2287
+ label?: string | ManifestTitle | null;
2288
+ href?: string;
2289
+ items: ManifestNavItem[];
2290
+ }
2291
+
2292
+ export declare interface ManifestNavItem {
2293
+ title: string | ManifestTitle;
2294
+ href: string;
2295
+ children?: ManifestNavItem[];
2296
+ }
2297
+
2298
+ declare interface ManifestTitle {
2299
+ [key: string]: string;
2300
+ }
2301
+
2195
2302
  export declare const MAP_TOOLTIP_OPTIONS: Partial<TooltipOptions>;
2196
2303
 
2197
2304
  /** Fixes Leaflet map sizing when rendered inside hidden tabs or collapsible panels */
@@ -2339,7 +2446,7 @@ export declare function PageErrorBoundary({ children }: {
2339
2446
  children: ReactNode;
2340
2447
  }): JSX.Element;
2341
2448
 
2342
- export declare function PageHeader({ title, description, icon: Icon, breadcrumbs, actions, className, onBreadcrumbsChange, }: PageHeaderProps): JSX.Element;
2449
+ export declare function PageHeader({ title, description, icon: Icon, actions, className, }: PageHeaderProps): JSX.Element;
2343
2450
 
2344
2451
  export declare interface PageHeaderProps {
2345
2452
  title: string;
@@ -2347,11 +2454,8 @@ export declare interface PageHeaderProps {
2347
2454
  icon: React.ComponentType<{
2348
2455
  className?: string;
2349
2456
  }>;
2350
- breadcrumbs: BreadcrumbItem[];
2351
2457
  actions?: React.ReactNode;
2352
2458
  className?: string;
2353
- /** Callback to sync breadcrumbs with external store (e.g. uiStore) */
2354
- onBreadcrumbsChange?: (breadcrumbs: BreadcrumbItem[]) => void;
2355
2459
  }
2356
2460
 
2357
2461
  export declare function Pagination({ className, ...props }: React_2.ComponentProps<"nav">): JSX.Element;
@@ -2458,10 +2562,10 @@ export declare interface PreviewSheetProps {
2458
2562
  }
2459
2563
 
2460
2564
  export declare const priorityColors: {
2461
- readonly HIGH: "bg-status-error/10 text-status-error border-status-error/30 ring-status-error/30";
2462
- readonly MEDIUM: "bg-status-warning/10 text-status-warning border-status-warning/30 ring-status-warning/30";
2565
+ readonly HIGH: "bg-status-error/10 text-status-error-foreground border-status-error/30 ring-status-error/30";
2566
+ readonly MEDIUM: "bg-status-warning/10 text-status-warning-foreground border-status-warning/30 ring-status-warning/30";
2463
2567
  readonly LOW: "bg-status-info/10 text-status-info-foreground border-status-info/30 ring-status-info/30";
2464
- readonly CRITICAL: "bg-status-error/10 text-status-error border-status-error/30 ring-status-error/30";
2568
+ readonly CRITICAL: "bg-status-error/10 text-status-error-foreground border-status-error/30 ring-status-error/30";
2465
2569
  readonly NORMAL: "bg-status-neutral/10 text-status-neutral-foreground border-status-neutral/30 ring-status-neutral/30";
2466
2570
  };
2467
2571
 
@@ -2486,8 +2590,8 @@ declare interface PropertyRowProps {
2486
2590
  export declare const protocolTypeColors: {
2487
2591
  readonly DLMS: "bg-status-info/10 text-status-info-foreground border-status-info/30 ring-status-info/30";
2488
2592
  readonly MODBUS: "bg-status-purple/10 text-status-purple-foreground border-status-purple/30 ring-status-purple/30";
2489
- readonly IEC_62056_21: "bg-accent-cyan/10 text-accent-cyan border-accent-cyan/30 ring-accent-cyan/30";
2490
- readonly ANSI_C12_18: "bg-status-warning/10 text-status-warning border-status-warning/30 ring-status-warning/30";
2593
+ readonly IEC_62056_21: "bg-accent-cyan/10 text-accent-cyan-foreground border-accent-cyan/30 ring-accent-cyan/30";
2594
+ readonly ANSI_C12_18: "bg-status-warning/10 text-status-warning-foreground border-status-warning/30 ring-status-warning/30";
2491
2595
  };
2492
2596
 
2493
2597
  export declare function QuickActionTile({ title, description, icon, href, onClick, variant, badge, className, animationDelay, }: QuickActionTileProps): JSX.Element;
@@ -2876,6 +2980,12 @@ declare interface SimpleDataTableProps<TData> {
2876
2980
  headerTextColor?: string;
2877
2981
  }
2878
2982
 
2983
+ declare const SIZE_STYLES: {
2984
+ readonly xs: "px-1.5 py-0 text-2xs-plus";
2985
+ readonly sm: "px-2 py-0.5 text-2xs-plus";
2986
+ readonly md: "px-2.5 py-1 text-2xs-plus";
2987
+ };
2988
+
2879
2989
  export declare function Skeleton({ className, ...props }: React.ComponentProps<"div">): JSX.Element;
2880
2990
 
2881
2991
  export declare function Slider({ className, defaultValue, value, min, max, ...props }: React_2.ComponentProps<typeof SliderPrimitive.Root>): JSX.Element;
@@ -2912,41 +3022,72 @@ export declare interface StatCardProps {
2912
3022
  }
2913
3023
 
2914
3024
  /**
2915
- * Status badge for displaying enum/status values.
2916
- * Provides consistent styling across all tables.
3025
+ * Unified badge component for the entire platform.
3026
+ * Single source of truth for all badge styling — status, tags, counters, labels.
2917
3027
  *
2918
- * @example
3028
+ * @example Status badge with color mapping
3029
+ * ```tsx
3030
+ * <StatusBadge value="ACTIVE" colorMap={colors} labelMap={labels} showDot />
3031
+ * ```
3032
+ *
3033
+ * @example Auto-colored enum (no colorMap needed)
3034
+ * ```tsx
3035
+ * <StatusBadge value={row.protocolName} autoColor />
3036
+ * ```
3037
+ *
3038
+ * @example Simple tag/label
2919
3039
  * ```tsx
2920
- * <StatusBadge
2921
- * value={row.status}
2922
- * colorMap={{
2923
- * ACTIVE: statusColors.success,
2924
- * INACTIVE: statusColors.neutral,
2925
- * }}
2926
- * labelMap={{
2927
- * ACTIVE: 'Active',
2928
- * INACTIVE: 'Inactive',
2929
- * }}
2930
- * showDot
2931
- * icon={<Wifi className="h-3 w-3" />}
2932
- * />
3040
+ * <StatusBadge variant="outline">DLMS</StatusBadge>
3041
+ * ```
3042
+ *
3043
+ * @example Counter badge (xs size)
3044
+ * ```tsx
3045
+ * <StatusBadge variant="destructive" size="xs">{count}</StatusBadge>
3046
+ * ```
3047
+ *
3048
+ * @example Compact badge (sm size)
3049
+ * ```tsx
3050
+ * <StatusBadge variant="outline" size="sm">{label}</StatusBadge>
2933
3051
  * ```
2934
3052
  */
2935
- export declare function StatusBadge<T extends string>({ value, colorMap, labelMap, icon, showDot, dotColorMap, pulse, size, showLabel, className, }: StatusBadgeProps<T>): JSX.Element;
2936
-
2937
- declare interface StatusBadgeProps<T extends string> {
2938
- value: T | null | undefined;
2939
- colorMap: Record<T, string>;
3053
+ export declare function StatusBadge<T extends string>({ value, colorMap, autoColor, toneColor, labelMap, icon, iconMap, showDot, dotColorMap, pulse, size, showLabel, variant, accentColorMap, minWidth, children, showNullState, className, ...htmlProps }: StatusBadgeProps<T>): JSX.Element;
3054
+
3055
+ declare interface StatusBadgeBaseProps<T extends string> {
3056
+ /** Enum/status value used with colorMap for semantic coloring */
3057
+ value?: T | null | undefined;
3058
+ /** Map enum values to Tailwind color classes */
3059
+ colorMap?: Record<T, string>;
3060
+ /** Auto-assign color from value string hash (no colorMap needed) */
3061
+ autoColor?: boolean;
3062
+ /** Base color family for graduated tone coloring — each value gets a unique tone within the family */
3063
+ toneColor?: StatusColor;
3064
+ /** Map enum values to display labels */
2940
3065
  labelMap?: Record<T, string>;
3066
+ /** Global icon — same icon for all values */
2941
3067
  icon?: React.ReactNode;
3068
+ /** Per-value icon — different icon per enum value (takes priority over `icon`) */
3069
+ iconMap?: Partial<Record<T, React.ReactNode>>;
2942
3070
  showDot?: boolean;
2943
3071
  dotColorMap?: Record<T, string>;
2944
3072
  pulse?: boolean | Record<T, boolean>;
2945
- size?: 'sm' | 'md';
3073
+ /** xs: counter/mini | sm: compact | md: default */
3074
+ size?: BadgeSize;
2946
3075
  showLabel?: boolean;
3076
+ /** Visual variant */
3077
+ variant?: BadgeVariant;
3078
+ /** Accent bar color map for variant="mono" */
3079
+ accentColorMap?: Partial<Record<T, string>>;
3080
+ /** Optional min-width Tailwind class for table column alignment */
3081
+ minWidth?: string;
3082
+ /** Direct children — for simple tag/label/counter usage without value+colorMap */
3083
+ children?: React.ReactNode;
3084
+ /** Show null state when value is null/undefined. Default: true for value mode, false for children mode */
3085
+ showNullState?: boolean;
2947
3086
  className?: string;
2948
3087
  }
2949
3088
 
3089
+ declare type StatusBadgeProps<T extends string> = StatusBadgeBaseProps<T> & Omit<React.HTMLAttributes<HTMLSpanElement>, keyof StatusBadgeBaseProps<T>>;
3090
+
2950
3091
  export declare type StatusColor = keyof typeof statusColors;
2951
3092
 
2952
3093
  /**
@@ -2955,11 +3096,11 @@ export declare type StatusColor = keyof typeof statusColors;
2955
3096
  */
2956
3097
  export declare const statusColors: {
2957
3098
  readonly success: "bg-status-success/10 text-status-success-foreground border-status-success/30 ring-status-success/30";
2958
- readonly warning: "bg-status-warning/10 text-status-warning border-status-warning/30 ring-status-warning/30";
2959
- readonly error: "bg-status-error/10 text-status-error border-status-error/30 ring-status-error/30";
3099
+ readonly warning: "bg-status-warning/10 text-status-warning-foreground border-status-warning/30 ring-status-warning/30";
3100
+ readonly error: "bg-status-error/10 text-status-error-foreground border-status-error/30 ring-status-error/30";
2960
3101
  readonly info: "bg-status-info/10 text-status-info-foreground border-status-info/30 ring-status-info/30";
2961
3102
  readonly neutral: "bg-status-neutral/10 text-status-neutral-foreground border-status-neutral/30 ring-status-neutral/30";
2962
- readonly accent: "bg-accent-cyan/10 text-accent-cyan border-accent-cyan/30 ring-accent-cyan/30";
3103
+ readonly accent: "bg-accent-cyan/10 text-accent-cyan-foreground border-accent-cyan/30 ring-accent-cyan/30";
2963
3104
  readonly purple: "bg-status-purple/10 text-status-purple-foreground border-status-purple/30 ring-status-purple/30";
2964
3105
  };
2965
3106
 
@@ -3384,6 +3525,51 @@ export declare interface UrlState {
3384
3525
  f?: FilterState[];
3385
3526
  }
3386
3527
 
3528
+ /**
3529
+ * Enterprise breadcrumb hook — derives breadcrumbs from manifest groups + current route.
3530
+ *
3531
+ * @example
3532
+ * // Header.tsx
3533
+ * const breadcrumbs = useAutoBreadcrumbs({
3534
+ * groups: manifest.groups,
3535
+ * pathname,
3536
+ * locale,
3537
+ * tail, // from useBreadcrumbs() store
3538
+ * });
3539
+ */
3540
+ export declare function useAutoBreadcrumbs({ groups, pathname, locale, tail, }: UseAutoBreadcrumbsOptions): BreadcrumbItem[];
3541
+
3542
+ export declare interface UseAutoBreadcrumbsOptions {
3543
+ /** Manifest navigation groups (source of truth for breadcrumb hierarchy) */
3544
+ groups: ManifestGroup[];
3545
+ /** Current route pathname */
3546
+ pathname: string;
3547
+ /** Active locale for resolving multilingual titles */
3548
+ locale: string;
3549
+ /** Optional tail items from detail pages (appended to auto-breadcrumbs) */
3550
+ tail?: BreadcrumbItem[];
3551
+ }
3552
+
3553
+ /**
3554
+ * Declarative breadcrumb tail hook for detail pages.
3555
+ * Sets tail items on mount and auto-clears on unmount.
3556
+ * Uses deep comparison to avoid unnecessary updates.
3557
+ *
3558
+ * @param items - Breadcrumb items to append (undefined = skip, e.g. while loading)
3559
+ * @param setBreadcrumbs - Setter from store (e.g. useSetBreadcrumbs from lena-ui-core)
3560
+ *
3561
+ * @example
3562
+ * const setBreadcrumbs = useSetBreadcrumbs();
3563
+ * useBreadcrumbTail(
3564
+ * meter ? [
3565
+ * { label: 'Sayaçlar', href: '/device-management/meters' },
3566
+ * { label: meter.serialNumber },
3567
+ * ] : undefined,
3568
+ * setBreadcrumbs,
3569
+ * );
3570
+ */
3571
+ export declare function useBreadcrumbTail(items: BreadcrumbItem[] | undefined, setBreadcrumbs: (items: BreadcrumbItem[]) => void): void;
3572
+
3387
3573
  export declare function useDataTable<TData>(options: UseDataTableOptions<TData>): UseDataTableReturn<TData>;
3388
3574
 
3389
3575
  declare interface UseDataTableOptions<TData> extends CreateDataTableStoreOptions {
@@ -3470,6 +3656,30 @@ export declare interface UseDoubleClickHandlerOptions<T> {
3470
3656
  */
3471
3657
  export declare function useEnumDefinitions(): CachedEnumDefinition[];
3472
3658
 
3659
+ /**
3660
+ * Tek bir enum value'nun label'ını döner.
3661
+ * Cache'de bulunamazsa raw value döner (graceful fallback).
3662
+ *
3663
+ * @example
3664
+ * ```tsx
3665
+ * const label = useEnumLabel('PROTOCOL_TYPE', protocol.protocolType);
3666
+ * <span>{label}</span>
3667
+ * ```
3668
+ */
3669
+ export declare function useEnumLabel(key: string, value: string | undefined | null): string;
3670
+
3671
+ /**
3672
+ * Tüm enum'un key→label map'ini Record<string, string> olarak döner.
3673
+ * Mevcut static label map'lerin drop-in replacement'ı.
3674
+ *
3675
+ * @example
3676
+ * ```tsx
3677
+ * const protocolTypeLabels = useEnumLabelMap('PROTOCOL_TYPE');
3678
+ * <span>{protocolTypeLabels[protocol.protocolType]}</span>
3679
+ * ```
3680
+ */
3681
+ export declare function useEnumLabelMap(key: string): Record<string, string>;
3682
+
3473
3683
  /**
3474
3684
  * Belirli bir enum code'unun SelectOption[] listesini döner.
3475
3685
  *
@@ -3777,6 +3987,15 @@ export declare interface ValidationStatusProps {
3777
3987
  showDetails?: boolean;
3778
3988
  }
3779
3989
 
3990
+ declare const VARIANT_STYLES: {
3991
+ readonly default: "";
3992
+ readonly mono: "font-mono tracking-tight";
3993
+ readonly outline: "border-border text-foreground ring-0 border";
3994
+ readonly secondary: "bg-secondary text-secondary-foreground ring-0";
3995
+ readonly destructive: "bg-destructive text-white ring-0";
3996
+ readonly ghost: "ring-0 text-foreground";
3997
+ };
3998
+
3780
3999
  /**
3781
4000
  * Adds monthly average fields to chart data.
3782
4001
  * Date format: "dd/MM" — groups by month part, calculates average per key.