@almadar/ui 4.45.0 → 4.46.0

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.
@@ -6011,12 +6011,15 @@ function ControlButton({
6011
6011
  sizeMap3[size] ?? sizeMap3.md,
6012
6012
  shapeMap[shape] ?? shapeMap.circle,
6013
6013
  variantMap[variant] ?? variantMap.secondary,
6014
- actualPressed && "scale-95 brightness-110 border-white",
6014
+ actualPressed && "scale-95 brightness-110 border-foreground",
6015
6015
  disabled && "opacity-50 cursor-not-allowed",
6016
6016
  className
6017
6017
  ),
6018
6018
  children: [
6019
- icon && /* @__PURE__ */ jsx("span", { className: "text-2xl", children: icon }),
6019
+ icon && /* @__PURE__ */ jsx("span", { className: "text-2xl", children: typeof icon === "string" ? (() => {
6020
+ const I = resolveIcon(icon);
6021
+ return I ? /* @__PURE__ */ jsx(I, { className: "w-6 h-6" }) : null;
6022
+ })() : icon }),
6020
6023
  label && !icon && /* @__PURE__ */ jsx("span", { children: label })
6021
6024
  ]
6022
6025
  }
@@ -6028,6 +6031,7 @@ var init_ControlButton = __esm({
6028
6031
  "use client";
6029
6032
  init_cn();
6030
6033
  init_useEventBus();
6034
+ init_Icon();
6031
6035
  sizeMap3 = {
6032
6036
  sm: "w-10 h-10 text-sm",
6033
6037
  md: "w-14 h-14 text-base",
@@ -6040,9 +6044,9 @@ var init_ControlButton = __esm({
6040
6044
  square: "rounded-md"
6041
6045
  };
6042
6046
  variantMap = {
6043
- primary: "bg-blue-600 text-[var(--color-foreground)] border-blue-400 hover:bg-blue-500",
6044
- secondary: "bg-[var(--color-surface,#374151)] text-[var(--color-foreground)] border-gray-500 hover:bg-gray-600",
6045
- ghost: "bg-transparent text-[var(--color-foreground)] border-white/30 hover:bg-white/10"
6047
+ primary: "bg-primary text-primary-foreground border-primary hover:bg-primary-hover",
6048
+ secondary: "bg-secondary text-secondary-foreground border-border hover:bg-secondary-hover",
6049
+ ghost: "bg-transparent text-foreground border-border hover:bg-muted"
6046
6050
  };
6047
6051
  ControlButton.displayName = "ControlButton";
6048
6052
  }
@@ -6770,8 +6774,8 @@ function ChoiceButton({
6770
6774
  className: cn(
6771
6775
  "w-full text-left px-4 py-2.5 rounded-md border transition-all duration-150",
6772
6776
  "flex items-center gap-2",
6773
- selected ? "bg-yellow-500/20 border-yellow-400 text-yellow-300" : "bg-white/5 border-white/10 text-[var(--color-foreground)] hover:bg-white/10 hover:border-white/30",
6774
- disabled && "opacity-40 cursor-not-allowed hover:bg-white/5 hover:border-white/10",
6777
+ selected ? "bg-accent/15 border-accent text-foreground" : "bg-muted/40 border-border text-foreground hover:bg-muted hover:border-border",
6778
+ disabled && "opacity-40 cursor-not-allowed hover:bg-muted/40 hover:border-border",
6775
6779
  className
6776
6780
  ),
6777
6781
  children: [
@@ -6780,7 +6784,7 @@ function ChoiceButton({
6780
6784
  {
6781
6785
  className: cn(
6782
6786
  "flex-shrink-0 font-mono font-bold text-sm",
6783
- selected ? "text-yellow-400" : "text-gray-500"
6787
+ selected ? "text-accent" : "text-muted-foreground"
6784
6788
  ),
6785
6789
  children: [
6786
6790
  index,
@@ -6821,7 +6825,7 @@ function ActionButton({
6821
6825
  disabled: isDisabled,
6822
6826
  onClick,
6823
6827
  className: cn(
6824
- "relative inline-flex items-center gap-1.5 rounded-md border font-medium text-[var(--color-foreground)] overflow-hidden transition-colors duration-150",
6828
+ "relative inline-flex items-center gap-1.5 rounded-md border font-medium overflow-hidden transition-colors duration-150",
6825
6829
  sizes.button,
6826
6830
  variantStyles8[variant],
6827
6831
  isDisabled && "opacity-60 cursor-not-allowed",
@@ -6831,7 +6835,7 @@ function ActionButton({
6831
6835
  onCooldown && /* @__PURE__ */ jsx(
6832
6836
  "div",
6833
6837
  {
6834
- className: "absolute inset-0 bg-black/60 pointer-events-none",
6838
+ className: "absolute inset-0 bg-foreground/40 pointer-events-none",
6835
6839
  style: {
6836
6840
  clipPath: `conic-gradient(from 0deg, transparent ${360 - cooldownDeg}deg, black ${360 - cooldownDeg}deg)`,
6837
6841
  WebkitClipPath: `conic-gradient(from 0deg, transparent ${360 - cooldownDeg}deg, black ${360 - cooldownDeg}deg)`,
@@ -6839,13 +6843,16 @@ function ActionButton({
6839
6843
  }
6840
6844
  }
6841
6845
  ),
6842
- icon && /* @__PURE__ */ jsx("span", { className: cn("flex-shrink-0", sizes.icon), children: icon }),
6846
+ icon && /* @__PURE__ */ jsx("span", { className: cn("flex-shrink-0", sizes.icon), children: typeof icon === "string" ? (() => {
6847
+ const I = resolveIcon(icon);
6848
+ return I ? /* @__PURE__ */ jsx(I, { className: "w-4 h-4" }) : null;
6849
+ })() : icon }),
6843
6850
  /* @__PURE__ */ jsx("span", { className: "relative z-10", children: label }),
6844
6851
  hotkey && /* @__PURE__ */ jsx(
6845
6852
  "span",
6846
6853
  {
6847
6854
  className: cn(
6848
- "absolute top-0.5 right-0.5 bg-black/50 text-gray-300 rounded font-mono leading-tight",
6855
+ "absolute top-0.5 right-0.5 bg-foreground/30 text-primary-foreground rounded font-mono leading-tight",
6849
6856
  sizes.hotkey
6850
6857
  ),
6851
6858
  children: hotkey
@@ -6859,15 +6866,16 @@ var sizeMap13, variantStyles8;
6859
6866
  var init_ActionButton = __esm({
6860
6867
  "components/atoms/game/ActionButton.tsx"() {
6861
6868
  init_cn();
6869
+ init_Icon();
6862
6870
  sizeMap13 = {
6863
6871
  sm: { button: "px-3 py-1.5 text-xs", hotkey: "text-[9px] px-1", icon: "text-xs" },
6864
6872
  md: { button: "px-4 py-2 text-sm", hotkey: "text-[10px] px-1.5", icon: "text-sm" },
6865
6873
  lg: { button: "px-5 py-2.5 text-base", hotkey: "text-xs px-2", icon: "text-base" }
6866
6874
  };
6867
6875
  variantStyles8 = {
6868
- primary: "bg-blue-600 hover:bg-blue-500 border-blue-400/40",
6869
- secondary: "bg-gray-700 hover:bg-gray-600 border-gray-500/40",
6870
- danger: "bg-red-700 hover:bg-red-600 border-red-400/40"
6876
+ primary: "bg-primary text-primary-foreground hover:bg-primary-hover border-primary",
6877
+ secondary: "bg-secondary text-secondary-foreground hover:bg-secondary-hover border-border",
6878
+ danger: "bg-error text-error-foreground hover:bg-error/90 border-error"
6871
6879
  };
6872
6880
  ActionButton.displayName = "ActionButton";
6873
6881
  }
@@ -21519,7 +21527,7 @@ function DataGrid({
21519
21527
  onClick: handleActionClick(action, itemData),
21520
21528
  "data-testid": `action-${action.event}`,
21521
21529
  "data-row-id": String(itemData.id),
21522
- className: "text-error hover:bg-error/10 px-2",
21530
+ className: "text-error hover:text-error hover:bg-error/10 px-2",
21523
21531
  children: [
21524
21532
  action.icon && /* @__PURE__ */ jsx(Icon, { name: action.icon, size: "xs" }),
21525
21533
  action.label
@@ -24112,7 +24120,7 @@ function StatBadge({
24112
24120
  const I = resolveIcon(icon);
24113
24121
  return I ? /* @__PURE__ */ jsx(I, { className: "w-4 h-4" }) : icon;
24114
24122
  })() : icon }),
24115
- /* @__PURE__ */ jsx("span", { className: "text-gray-400 font-medium", children: label }),
24123
+ /* @__PURE__ */ jsx("span", { className: "text-muted-foreground font-medium", children: label }),
24116
24124
  format === "hearts" && max && /* @__PURE__ */ jsx(
24117
24125
  HealthBar,
24118
24126
  {
@@ -24139,7 +24147,7 @@ function StatBadge({
24139
24147
  animated: true
24140
24148
  }
24141
24149
  ),
24142
- format === "text" && /* @__PURE__ */ jsx("span", { className: "font-bold text-[var(--color-foreground)]", children: value })
24150
+ format === "text" && /* @__PURE__ */ jsx("span", { className: "font-bold text-foreground", children: value })
24143
24151
  ]
24144
24152
  }
24145
24153
  );
@@ -24157,11 +24165,11 @@ var init_StatBadge = __esm({
24157
24165
  lg: "text-base px-4 py-2"
24158
24166
  };
24159
24167
  variantMap2 = {
24160
- default: "bg-[var(--color-card)]/80 border-gray-700",
24161
- primary: "bg-blue-900/80 border-blue-700",
24162
- success: "bg-green-900/80 border-green-700",
24163
- warning: "bg-yellow-900/80 border-yellow-700",
24164
- danger: "bg-red-900/80 border-red-700"
24168
+ default: "bg-card/80 border-border text-foreground",
24169
+ primary: "bg-primary/15 border-primary/40 text-foreground",
24170
+ success: "bg-success/15 border-success/40 text-foreground",
24171
+ warning: "bg-warning/15 border-warning/40 text-foreground",
24172
+ danger: "bg-error/15 border-error/40 text-foreground"
24165
24173
  };
24166
24174
  StatBadge.displayName = "StatBadge";
24167
24175
  }
@@ -36734,9 +36742,45 @@ var init_List = __esm({
36734
36742
  List3.displayName = "List";
36735
36743
  }
36736
36744
  });
36737
- var DefaultEmptyDetail, MasterDetail;
36745
+ function MasterDetail({
36746
+ entity,
36747
+ masterFields,
36748
+ detailFields: _detailFields,
36749
+ // Captured but not used here - detail handled separately
36750
+ loading: externalLoading,
36751
+ isLoading: externalIsLoading,
36752
+ error: externalError,
36753
+ className,
36754
+ ...rest
36755
+ }) {
36756
+ const loading = externalLoading ?? false;
36757
+ const isLoading = externalIsLoading ?? false;
36758
+ const error = externalError ?? null;
36759
+ return /* @__PURE__ */ jsx(
36760
+ DataTable,
36761
+ {
36762
+ fields: masterFields,
36763
+ columns: masterFields,
36764
+ entity,
36765
+ isLoading: loading || isLoading,
36766
+ error,
36767
+ className,
36768
+ emptyTitle: "No items found",
36769
+ emptyDescription: "Create your first item to get started.",
36770
+ ...rest
36771
+ }
36772
+ );
36773
+ }
36738
36774
  var init_MasterDetail = __esm({
36739
- "components/organisms/layout/MasterDetail.tsx"() {
36775
+ "components/organisms/MasterDetail.tsx"() {
36776
+ "use client";
36777
+ init_DataTable();
36778
+ MasterDetail.displayName = "MasterDetail";
36779
+ }
36780
+ });
36781
+ var DefaultEmptyDetail, MasterDetailLayout;
36782
+ var init_MasterDetailLayout = __esm({
36783
+ "components/organisms/layout/MasterDetailLayout.tsx"() {
36740
36784
  init_cn();
36741
36785
  init_Typography();
36742
36786
  DefaultEmptyDetail = () => /* @__PURE__ */ jsx("div", { className: "flex items-center justify-center h-full border-2 border-dashed border-border", children: /* @__PURE__ */ jsx(
@@ -36747,7 +36791,7 @@ var init_MasterDetail = __esm({
36747
36791
  children: "Select an item to view details"
36748
36792
  }
36749
36793
  ) });
36750
- MasterDetail = ({
36794
+ MasterDetailLayout = ({
36751
36795
  master,
36752
36796
  detail,
36753
36797
  emptyDetail,
@@ -36782,7 +36826,7 @@ var init_MasterDetail = __esm({
36782
36826
  }
36783
36827
  );
36784
36828
  };
36785
- MasterDetail.displayName = "MasterDetail";
36829
+ MasterDetailLayout.displayName = "MasterDetailLayout";
36786
36830
  }
36787
36831
  });
36788
36832
  var COLUMN_CLASSES, ASPECT_CLASSES, MediaGallery;
@@ -43518,6 +43562,7 @@ var init_component_registry_generated = __esm({
43518
43562
  init_LoadingState();
43519
43563
  init_MarkdownContent();
43520
43564
  init_MasterDetail();
43565
+ init_MasterDetailLayout();
43521
43566
  init_MatrixQuestion();
43522
43567
  init_MediaGallery();
43523
43568
  init_Meter();
@@ -43812,6 +43857,7 @@ var init_component_registry_generated = __esm({
43812
43857
  "MapViewPattern": MapViewPattern,
43813
43858
  "MarkdownContent": MarkdownContent,
43814
43859
  "MasterDetail": MasterDetail,
43860
+ "MasterDetailLayout": MasterDetailLayout,
43815
43861
  "MatrixQuestion": MatrixQuestion,
43816
43862
  "MediaGallery": MediaGallery,
43817
43863
  "Menu": MenuPattern,
@@ -6432,12 +6432,15 @@ function ControlButton({
6432
6432
  sizeMap3[size] ?? sizeMap3.md,
6433
6433
  shapeMap[shape] ?? shapeMap.circle,
6434
6434
  variantMap[variant] ?? variantMap.secondary,
6435
- actualPressed && "scale-95 brightness-110 border-white",
6435
+ actualPressed && "scale-95 brightness-110 border-foreground",
6436
6436
  disabled && "opacity-50 cursor-not-allowed",
6437
6437
  className
6438
6438
  ),
6439
6439
  children: [
6440
- icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-2xl", children: icon }),
6440
+ icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-2xl", children: typeof icon === "string" ? (() => {
6441
+ const I = resolveIcon(icon);
6442
+ return I ? /* @__PURE__ */ jsxRuntime.jsx(I, { className: "w-6 h-6" }) : null;
6443
+ })() : icon }),
6441
6444
  label && !icon && /* @__PURE__ */ jsxRuntime.jsx("span", { children: label })
6442
6445
  ]
6443
6446
  }
@@ -6449,6 +6452,7 @@ var init_ControlButton = __esm({
6449
6452
  "use client";
6450
6453
  init_cn();
6451
6454
  init_useEventBus();
6455
+ init_Icon();
6452
6456
  sizeMap3 = {
6453
6457
  sm: "w-10 h-10 text-sm",
6454
6458
  md: "w-14 h-14 text-base",
@@ -6461,9 +6465,9 @@ var init_ControlButton = __esm({
6461
6465
  square: "rounded-md"
6462
6466
  };
6463
6467
  variantMap = {
6464
- primary: "bg-blue-600 text-[var(--color-foreground)] border-blue-400 hover:bg-blue-500",
6465
- secondary: "bg-[var(--color-surface,#374151)] text-[var(--color-foreground)] border-gray-500 hover:bg-gray-600",
6466
- ghost: "bg-transparent text-[var(--color-foreground)] border-white/30 hover:bg-white/10"
6468
+ primary: "bg-primary text-primary-foreground border-primary hover:bg-primary-hover",
6469
+ secondary: "bg-secondary text-secondary-foreground border-border hover:bg-secondary-hover",
6470
+ ghost: "bg-transparent text-foreground border-border hover:bg-muted"
6467
6471
  };
6468
6472
  ControlButton.displayName = "ControlButton";
6469
6473
  }
@@ -7191,8 +7195,8 @@ function ChoiceButton({
7191
7195
  className: cn(
7192
7196
  "w-full text-left px-4 py-2.5 rounded-md border transition-all duration-150",
7193
7197
  "flex items-center gap-2",
7194
- selected ? "bg-yellow-500/20 border-yellow-400 text-yellow-300" : "bg-white/5 border-white/10 text-[var(--color-foreground)] hover:bg-white/10 hover:border-white/30",
7195
- disabled && "opacity-40 cursor-not-allowed hover:bg-white/5 hover:border-white/10",
7198
+ selected ? "bg-accent/15 border-accent text-foreground" : "bg-muted/40 border-border text-foreground hover:bg-muted hover:border-border",
7199
+ disabled && "opacity-40 cursor-not-allowed hover:bg-muted/40 hover:border-border",
7196
7200
  className
7197
7201
  ),
7198
7202
  children: [
@@ -7201,7 +7205,7 @@ function ChoiceButton({
7201
7205
  {
7202
7206
  className: cn(
7203
7207
  "flex-shrink-0 font-mono font-bold text-sm",
7204
- selected ? "text-yellow-400" : "text-gray-500"
7208
+ selected ? "text-accent" : "text-muted-foreground"
7205
7209
  ),
7206
7210
  children: [
7207
7211
  index,
@@ -7242,7 +7246,7 @@ function ActionButton({
7242
7246
  disabled: isDisabled,
7243
7247
  onClick,
7244
7248
  className: cn(
7245
- "relative inline-flex items-center gap-1.5 rounded-md border font-medium text-[var(--color-foreground)] overflow-hidden transition-colors duration-150",
7249
+ "relative inline-flex items-center gap-1.5 rounded-md border font-medium overflow-hidden transition-colors duration-150",
7246
7250
  sizes.button,
7247
7251
  variantStyles8[variant],
7248
7252
  isDisabled && "opacity-60 cursor-not-allowed",
@@ -7252,7 +7256,7 @@ function ActionButton({
7252
7256
  onCooldown && /* @__PURE__ */ jsxRuntime.jsx(
7253
7257
  "div",
7254
7258
  {
7255
- className: "absolute inset-0 bg-black/60 pointer-events-none",
7259
+ className: "absolute inset-0 bg-foreground/40 pointer-events-none",
7256
7260
  style: {
7257
7261
  clipPath: `conic-gradient(from 0deg, transparent ${360 - cooldownDeg}deg, black ${360 - cooldownDeg}deg)`,
7258
7262
  WebkitClipPath: `conic-gradient(from 0deg, transparent ${360 - cooldownDeg}deg, black ${360 - cooldownDeg}deg)`,
@@ -7260,13 +7264,16 @@ function ActionButton({
7260
7264
  }
7261
7265
  }
7262
7266
  ),
7263
- icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("flex-shrink-0", sizes.icon), children: icon }),
7267
+ icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("flex-shrink-0", sizes.icon), children: typeof icon === "string" ? (() => {
7268
+ const I = resolveIcon(icon);
7269
+ return I ? /* @__PURE__ */ jsxRuntime.jsx(I, { className: "w-4 h-4" }) : null;
7270
+ })() : icon }),
7264
7271
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "relative z-10", children: label }),
7265
7272
  hotkey && /* @__PURE__ */ jsxRuntime.jsx(
7266
7273
  "span",
7267
7274
  {
7268
7275
  className: cn(
7269
- "absolute top-0.5 right-0.5 bg-black/50 text-gray-300 rounded font-mono leading-tight",
7276
+ "absolute top-0.5 right-0.5 bg-foreground/30 text-primary-foreground rounded font-mono leading-tight",
7270
7277
  sizes.hotkey
7271
7278
  ),
7272
7279
  children: hotkey
@@ -7280,15 +7287,16 @@ var sizeMap13, variantStyles8;
7280
7287
  var init_ActionButton = __esm({
7281
7288
  "components/atoms/game/ActionButton.tsx"() {
7282
7289
  init_cn();
7290
+ init_Icon();
7283
7291
  sizeMap13 = {
7284
7292
  sm: { button: "px-3 py-1.5 text-xs", hotkey: "text-[9px] px-1", icon: "text-xs" },
7285
7293
  md: { button: "px-4 py-2 text-sm", hotkey: "text-[10px] px-1.5", icon: "text-sm" },
7286
7294
  lg: { button: "px-5 py-2.5 text-base", hotkey: "text-xs px-2", icon: "text-base" }
7287
7295
  };
7288
7296
  variantStyles8 = {
7289
- primary: "bg-blue-600 hover:bg-blue-500 border-blue-400/40",
7290
- secondary: "bg-gray-700 hover:bg-gray-600 border-gray-500/40",
7291
- danger: "bg-red-700 hover:bg-red-600 border-red-400/40"
7297
+ primary: "bg-primary text-primary-foreground hover:bg-primary-hover border-primary",
7298
+ secondary: "bg-secondary text-secondary-foreground hover:bg-secondary-hover border-border",
7299
+ danger: "bg-error text-error-foreground hover:bg-error/90 border-error"
7292
7300
  };
7293
7301
  ActionButton.displayName = "ActionButton";
7294
7302
  }
@@ -21334,7 +21342,7 @@ function DataGrid({
21334
21342
  onClick: handleActionClick(action, itemData),
21335
21343
  "data-testid": `action-${action.event}`,
21336
21344
  "data-row-id": String(itemData.id),
21337
- className: "text-error hover:bg-error/10 px-2",
21345
+ className: "text-error hover:text-error hover:bg-error/10 px-2",
21338
21346
  children: [
21339
21347
  action.icon && /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: action.icon, size: "xs" }),
21340
21348
  action.label
@@ -23863,7 +23871,7 @@ function StatBadge({
23863
23871
  const I = resolveIcon(icon);
23864
23872
  return I ? /* @__PURE__ */ jsxRuntime.jsx(I, { className: "w-4 h-4" }) : icon;
23865
23873
  })() : icon }),
23866
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-gray-400 font-medium", children: label }),
23874
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground font-medium", children: label }),
23867
23875
  format === "hearts" && max && /* @__PURE__ */ jsxRuntime.jsx(
23868
23876
  HealthBar,
23869
23877
  {
@@ -23890,7 +23898,7 @@ function StatBadge({
23890
23898
  animated: true
23891
23899
  }
23892
23900
  ),
23893
- format === "text" && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-bold text-[var(--color-foreground)]", children: value })
23901
+ format === "text" && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-bold text-foreground", children: value })
23894
23902
  ]
23895
23903
  }
23896
23904
  );
@@ -23908,11 +23916,11 @@ var init_StatBadge = __esm({
23908
23916
  lg: "text-base px-4 py-2"
23909
23917
  };
23910
23918
  variantMap2 = {
23911
- default: "bg-[var(--color-card)]/80 border-gray-700",
23912
- primary: "bg-blue-900/80 border-blue-700",
23913
- success: "bg-green-900/80 border-green-700",
23914
- warning: "bg-yellow-900/80 border-yellow-700",
23915
- danger: "bg-red-900/80 border-red-700"
23919
+ default: "bg-card/80 border-border text-foreground",
23920
+ primary: "bg-primary/15 border-primary/40 text-foreground",
23921
+ success: "bg-success/15 border-success/40 text-foreground",
23922
+ warning: "bg-warning/15 border-warning/40 text-foreground",
23923
+ danger: "bg-error/15 border-error/40 text-foreground"
23916
23924
  };
23917
23925
  StatBadge.displayName = "StatBadge";
23918
23926
  }
@@ -36347,9 +36355,45 @@ var init_List = __esm({
36347
36355
  List3.displayName = "List";
36348
36356
  }
36349
36357
  });
36350
- var DefaultEmptyDetail, MasterDetail;
36358
+ function MasterDetail({
36359
+ entity,
36360
+ masterFields,
36361
+ detailFields: _detailFields,
36362
+ // Captured but not used here - detail handled separately
36363
+ loading: externalLoading,
36364
+ isLoading: externalIsLoading,
36365
+ error: externalError,
36366
+ className,
36367
+ ...rest
36368
+ }) {
36369
+ const loading = externalLoading ?? false;
36370
+ const isLoading = externalIsLoading ?? false;
36371
+ const error = externalError ?? null;
36372
+ return /* @__PURE__ */ jsxRuntime.jsx(
36373
+ DataTable,
36374
+ {
36375
+ fields: masterFields,
36376
+ columns: masterFields,
36377
+ entity,
36378
+ isLoading: loading || isLoading,
36379
+ error,
36380
+ className,
36381
+ emptyTitle: "No items found",
36382
+ emptyDescription: "Create your first item to get started.",
36383
+ ...rest
36384
+ }
36385
+ );
36386
+ }
36351
36387
  var init_MasterDetail = __esm({
36352
- "components/organisms/layout/MasterDetail.tsx"() {
36388
+ "components/organisms/MasterDetail.tsx"() {
36389
+ "use client";
36390
+ init_DataTable();
36391
+ MasterDetail.displayName = "MasterDetail";
36392
+ }
36393
+ });
36394
+ var DefaultEmptyDetail, MasterDetailLayout;
36395
+ var init_MasterDetailLayout = __esm({
36396
+ "components/organisms/layout/MasterDetailLayout.tsx"() {
36353
36397
  init_cn();
36354
36398
  init_Typography();
36355
36399
  DefaultEmptyDetail = () => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center justify-center h-full border-2 border-dashed border-border", children: /* @__PURE__ */ jsxRuntime.jsx(
@@ -36360,7 +36404,7 @@ var init_MasterDetail = __esm({
36360
36404
  children: "Select an item to view details"
36361
36405
  }
36362
36406
  ) });
36363
- MasterDetail = ({
36407
+ MasterDetailLayout = ({
36364
36408
  master,
36365
36409
  detail,
36366
36410
  emptyDetail,
@@ -36395,7 +36439,7 @@ var init_MasterDetail = __esm({
36395
36439
  }
36396
36440
  );
36397
36441
  };
36398
- MasterDetail.displayName = "MasterDetail";
36442
+ MasterDetailLayout.displayName = "MasterDetailLayout";
36399
36443
  }
36400
36444
  });
36401
36445
  var COLUMN_CLASSES, ASPECT_CLASSES, MediaGallery;
@@ -43150,6 +43194,7 @@ var init_component_registry_generated = __esm({
43150
43194
  init_LoadingState();
43151
43195
  init_MarkdownContent();
43152
43196
  init_MasterDetail();
43197
+ init_MasterDetailLayout();
43153
43198
  init_MatrixQuestion();
43154
43199
  init_MediaGallery();
43155
43200
  init_Meter();
@@ -43444,6 +43489,7 @@ var init_component_registry_generated = __esm({
43444
43489
  "MapViewPattern": MapViewPattern,
43445
43490
  "MarkdownContent": MarkdownContent,
43446
43491
  "MasterDetail": MasterDetail,
43492
+ "MasterDetailLayout": MasterDetailLayout,
43447
43493
  "MatrixQuestion": MatrixQuestion,
43448
43494
  "MediaGallery": MediaGallery,
43449
43495
  "Menu": MenuPattern,