@mieweb/ui 0.1.1 → 0.2.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.
package/dist/index.cjs CHANGED
@@ -1,24 +1,25 @@
1
1
  'use strict';
2
2
 
3
+ var chunkB7YGVKTE_cjs = require('./chunk-B7YGVKTE.cjs');
3
4
  var chunkVDMQCSXT_cjs = require('./chunk-VDMQCSXT.cjs');
4
5
  var chunkBXK5TNJE_cjs = require('./chunk-BXK5TNJE.cjs');
5
6
  var chunkZJCPW6MS_cjs = require('./chunk-ZJCPW6MS.cjs');
6
- var chunk6DP6RKUA_cjs = require('./chunk-6DP6RKUA.cjs');
7
+ var chunkCLJZHS7Y_cjs = require('./chunk-CLJZHS7Y.cjs');
8
+ var chunkP52GA3GJ_cjs = require('./chunk-P52GA3GJ.cjs');
7
9
  var chunkS6UNPMAS_cjs = require('./chunk-S6UNPMAS.cjs');
8
10
  var chunkSWV5E75F_cjs = require('./chunk-SWV5E75F.cjs');
9
11
  var chunkZ3TFPXVN_cjs = require('./chunk-Z3TFPXVN.cjs');
10
12
  var chunkFFJVCQ5R_cjs = require('./chunk-FFJVCQ5R.cjs');
11
13
  var chunk4LNS5QDP_cjs = require('./chunk-4LNS5QDP.cjs');
12
14
  var chunkO5HS7ZND_cjs = require('./chunk-O5HS7ZND.cjs');
13
- var chunkP52GA3GJ_cjs = require('./chunk-P52GA3GJ.cjs');
14
- var chunkNL3CZNBH_cjs = require('./chunk-NL3CZNBH.cjs');
15
+ var chunk5UUL5EEO_cjs = require('./chunk-5UUL5EEO.cjs');
15
16
  var chunkN3QTYHRZ_cjs = require('./chunk-N3QTYHRZ.cjs');
17
+ var chunkBV75DAKO_cjs = require('./chunk-BV75DAKO.cjs');
16
18
  var chunkJYMQJ32S_cjs = require('./chunk-JYMQJ32S.cjs');
17
19
  var chunkRRQGH7C5_cjs = require('./chunk-RRQGH7C5.cjs');
18
20
  var chunkLZEY55QZ_cjs = require('./chunk-LZEY55QZ.cjs');
19
21
  var chunkORUPC5TV_cjs = require('./chunk-ORUPC5TV.cjs');
20
22
  var chunkQDGZBDBI_cjs = require('./chunk-QDGZBDBI.cjs');
21
- var chunkB7YGVKTE_cjs = require('./chunk-B7YGVKTE.cjs');
22
23
  var chunkI7L6CQXR_cjs = require('./chunk-I7L6CQXR.cjs');
23
24
  var chunkPF3XWKE5_cjs = require('./chunk-PF3XWKE5.cjs');
24
25
  var chunkCQCYXHCU_cjs = require('./chunk-CQCYXHCU.cjs');
@@ -242,7 +243,7 @@ function AddContactModal({
242
243
  }
243
244
  ),
244
245
  /* @__PURE__ */ jsxRuntime.jsx(
245
- chunkNL3CZNBH_cjs.Select,
246
+ chunk5UUL5EEO_cjs.Select,
246
247
  {
247
248
  id: "contact-sex",
248
249
  options: SEX_OPTIONS,
@@ -2283,6 +2284,35 @@ var TOOL_ICONS = {
2283
2284
  )
2284
2285
  }
2285
2286
  ),
2287
+ // Provider tools
2288
+ search_providers: /* @__PURE__ */ jsxRuntime.jsxs(
2289
+ "svg",
2290
+ {
2291
+ className: "h-4 w-4",
2292
+ fill: "none",
2293
+ viewBox: "0 0 24 24",
2294
+ stroke: "currentColor",
2295
+ strokeWidth: "1.5",
2296
+ children: [
2297
+ /* @__PURE__ */ jsxRuntime.jsx(
2298
+ "path",
2299
+ {
2300
+ strokeLinecap: "round",
2301
+ strokeLinejoin: "round",
2302
+ d: "M15 10.5a3 3 0 11-6 0 3 3 0 016 0z"
2303
+ }
2304
+ ),
2305
+ /* @__PURE__ */ jsxRuntime.jsx(
2306
+ "path",
2307
+ {
2308
+ strokeLinecap: "round",
2309
+ strokeLinejoin: "round",
2310
+ d: "M19.5 10.5c0 7.142-7.5 11.25-7.5 11.25S4.5 17.642 4.5 10.5a7.5 7.5 0 1115 0z"
2311
+ }
2312
+ )
2313
+ ]
2314
+ }
2315
+ ),
2286
2316
  // Default tool icon
2287
2317
  default: /* @__PURE__ */ jsxRuntime.jsx(
2288
2318
  "svg",
@@ -2386,6 +2416,34 @@ function ResourceLink({ link, onClick, className }) {
2386
2416
  )
2387
2417
  }
2388
2418
  ),
2419
+ provider: /* @__PURE__ */ jsxRuntime.jsxs(
2420
+ "svg",
2421
+ {
2422
+ className: "h-4 w-4",
2423
+ fill: "none",
2424
+ viewBox: "0 0 24 24",
2425
+ stroke: "currentColor",
2426
+ strokeWidth: "1.5",
2427
+ children: [
2428
+ /* @__PURE__ */ jsxRuntime.jsx(
2429
+ "path",
2430
+ {
2431
+ strokeLinecap: "round",
2432
+ strokeLinejoin: "round",
2433
+ d: "M15 10.5a3 3 0 11-6 0 3 3 0 016 0z"
2434
+ }
2435
+ ),
2436
+ /* @__PURE__ */ jsxRuntime.jsx(
2437
+ "path",
2438
+ {
2439
+ strokeLinecap: "round",
2440
+ strokeLinejoin: "round",
2441
+ d: "M19.5 10.5c0 7.142-7.5 11.25-7.5 11.25S4.5 17.642 4.5 10.5a7.5 7.5 0 1115 0z"
2442
+ }
2443
+ )
2444
+ ]
2445
+ }
2446
+ ),
2389
2447
  external: /* @__PURE__ */ jsxRuntime.jsx(
2390
2448
  "svg",
2391
2449
  {
@@ -2572,7 +2630,8 @@ var TOOL_FRIENDLY_NAMES = {
2572
2630
  search_documents: "Searching documents",
2573
2631
  create_order: "Creating order",
2574
2632
  send_message: "Sending message",
2575
- search: "Searching"
2633
+ search: "Searching",
2634
+ search_providers: "Searching for providers"
2576
2635
  };
2577
2636
  function getToolFriendlyName(toolName, status) {
2578
2637
  const baseName = TOOL_FRIENDLY_NAMES[toolName] || toolName.replace(/_/g, " ");
@@ -2581,8 +2640,10 @@ function getToolFriendlyName(toolName, status) {
2581
2640
  return baseName.replace("Creating", "Created");
2582
2641
  if (baseName.startsWith("Scheduling"))
2583
2642
  return baseName.replace("Scheduling", "Scheduled");
2643
+ if (baseName.startsWith("Searching for"))
2644
+ return baseName.replace("Searching for", "Found");
2584
2645
  if (baseName.startsWith("Searching"))
2585
- return baseName.replace("Searching", "Searched");
2646
+ return baseName.replace("Searching", "Found");
2586
2647
  if (baseName.startsWith("Looking"))
2587
2648
  return baseName.replace("Looking", "Found");
2588
2649
  if (baseName.startsWith("Updating"))
@@ -2612,6 +2673,10 @@ function getParameterSummary(toolName, params) {
2612
2673
  const date = paramMap.preferredDate || paramMap.date;
2613
2674
  return date ? `${paramMap.patientName} on ${date}` : String(paramMap.patientName);
2614
2675
  }
2676
+ if (toolName === "search_providers" && paramMap.zipcode) {
2677
+ const service = paramMap.service;
2678
+ return service ? `${service} near ${paramMap.zipcode}` : `near ${paramMap.zipcode}`;
2679
+ }
2615
2680
  return null;
2616
2681
  }
2617
2682
  function MCPToolCallDisplay({
@@ -8314,7 +8379,7 @@ function CheckrIntegration({
8314
8379
  }
8315
8380
  ),
8316
8381
  /* @__PURE__ */ jsxRuntime.jsx(
8317
- chunkNL3CZNBH_cjs.Select,
8382
+ chunk5UUL5EEO_cjs.Select,
8318
8383
  {
8319
8384
  label: packageLabel,
8320
8385
  options: packageOptions,
@@ -9614,7 +9679,7 @@ function CSVColumnCard({
9614
9679
  hasError && !column.ignored && "ring-warning/50 ring-2"
9615
9680
  ),
9616
9681
  children: /* @__PURE__ */ jsxRuntime.jsx(
9617
- chunkNL3CZNBH_cjs.Select,
9682
+ chunk5UUL5EEO_cjs.Select,
9618
9683
  {
9619
9684
  id: formatHtmlId(column.name),
9620
9685
  options: selectOptions,
@@ -9635,7 +9700,7 @@ function CSVColumnCard({
9635
9700
  childSelectOptions && childSelectOptions.length > 0 && column.mappedTo && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
9636
9701
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground mb-1 block text-xs font-semibold tracking-wider uppercase", children: "Sub-field" }),
9637
9702
  /* @__PURE__ */ jsxRuntime.jsx(
9638
- chunkNL3CZNBH_cjs.Select,
9703
+ chunk5UUL5EEO_cjs.Select,
9639
9704
  {
9640
9705
  id: formatHtmlId(column.name, column.mappedTo),
9641
9706
  options: childSelectOptions,
@@ -11860,7 +11925,7 @@ function ClaimProviderForm({
11860
11925
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4 border-t border-gray-200 pt-4 dark:border-gray-700", children: [
11861
11926
  /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium text-gray-700 dark:text-gray-300", children: "Your Role" }),
11862
11927
  /* @__PURE__ */ jsxRuntime.jsx(
11863
- chunkNL3CZNBH_cjs.Select,
11928
+ chunk5UUL5EEO_cjs.Select,
11864
11929
  {
11865
11930
  label: "Role at this Organization",
11866
11931
  value: formData.role,
@@ -11883,7 +11948,7 @@ function ClaimProviderForm({
11883
11948
  )
11884
11949
  ] }),
11885
11950
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-4 border-t border-gray-200 pt-4 dark:border-gray-700", children: /* @__PURE__ */ jsxRuntime.jsx(
11886
- chunkNL3CZNBH_cjs.Select,
11951
+ chunk5UUL5EEO_cjs.Select,
11887
11952
  {
11888
11953
  label: "Preferred Language",
11889
11954
  value: formData.preferredLanguage || "en",
@@ -12072,7 +12137,7 @@ function CreateInvoiceModal({
12072
12137
  step === 1 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4", children: [
12073
12138
  /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-gray-600 dark:text-gray-400", children: "Select the employer you want to create an invoice for." }),
12074
12139
  /* @__PURE__ */ jsxRuntime.jsx(
12075
- chunkNL3CZNBH_cjs.Select,
12140
+ chunk5UUL5EEO_cjs.Select,
12076
12141
  {
12077
12142
  label: "Employer",
12078
12143
  options: employerOptions,
@@ -12567,7 +12632,7 @@ function EditUserRoleModal({
12567
12632
  /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-destructive text-sm", children: errorMessage })
12568
12633
  ] }) }),
12569
12634
  /* @__PURE__ */ jsxRuntime.jsx(
12570
- chunkNL3CZNBH_cjs.Select,
12635
+ chunk5UUL5EEO_cjs.Select,
12571
12636
  {
12572
12637
  label: "Role",
12573
12638
  value: selectedRoleId,
@@ -12799,7 +12864,7 @@ function EmployeeForm({
12799
12864
  departments.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
12800
12865
  /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-4 text-lg font-semibold", children: departmentLabel }),
12801
12866
  /* @__PURE__ */ jsxRuntime.jsx(
12802
- chunkNL3CZNBH_cjs.Select,
12867
+ chunk5UUL5EEO_cjs.Select,
12803
12868
  {
12804
12869
  label: selectDepartments,
12805
12870
  value: selectedDepartments[0] ?? "",
@@ -12888,7 +12953,7 @@ function EmployeeForm({
12888
12953
  }
12889
12954
  ) }),
12890
12955
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-32", children: /* @__PURE__ */ jsxRuntime.jsx(
12891
- chunkNL3CZNBH_cjs.Select,
12956
+ chunk5UUL5EEO_cjs.Select,
12892
12957
  {
12893
12958
  label: index === 0 ? "Type" : void 0,
12894
12959
  value: phone.type,
@@ -16070,7 +16135,7 @@ function InviteUserModal({
16070
16135
  )
16071
16136
  ] }),
16072
16137
  /* @__PURE__ */ jsxRuntime.jsx(
16073
- chunkNL3CZNBH_cjs.Select,
16138
+ chunk5UUL5EEO_cjs.Select,
16074
16139
  {
16075
16140
  label: "Role",
16076
16141
  value: roleId,
@@ -25093,9 +25158,13 @@ function RecurringServiceCard({
25093
25158
  onDelete,
25094
25159
  onEdit,
25095
25160
  showProvider = true,
25161
+ state,
25096
25162
  className,
25097
25163
  labels = {}
25098
25164
  }) {
25165
+ if (!service) {
25166
+ return null;
25167
+ }
25099
25168
  const {
25100
25169
  provider = "Provider",
25101
25170
  occurrence = "Occurrence",
@@ -25122,56 +25191,188 @@ function RecurringServiceCard({
25122
25191
  const getOccurrenceLabel = (occ) => {
25123
25192
  return occurrenceLabels[occ] || occ;
25124
25193
  };
25194
+ const effectiveState = state ?? "default";
25195
+ const stateStyles = {
25196
+ default: {
25197
+ border: "border-border",
25198
+ icon: null,
25199
+ showNote: !service?.overrideConsent
25200
+ // Still show consent note if needed
25201
+ },
25202
+ success: {
25203
+ border: "border-success/30",
25204
+ icon: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "bg-success text-success-foreground flex h-5 w-5 shrink-0 items-center justify-center rounded-full", children: /* @__PURE__ */ jsxRuntime.jsx(
25205
+ "svg",
25206
+ {
25207
+ className: "h-3 w-3",
25208
+ fill: "none",
25209
+ viewBox: "0 0 24 24",
25210
+ stroke: "currentColor",
25211
+ strokeWidth: 3,
25212
+ children: /* @__PURE__ */ jsxRuntime.jsx(
25213
+ "path",
25214
+ {
25215
+ strokeLinecap: "round",
25216
+ strokeLinejoin: "round",
25217
+ d: "M5 13l4 4L19 7"
25218
+ }
25219
+ )
25220
+ }
25221
+ ) }),
25222
+ showNote: false
25223
+ },
25224
+ primary: {
25225
+ border: "border-primary/30",
25226
+ icon: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "bg-primary text-primary-foreground flex h-5 w-5 shrink-0 items-center justify-center rounded-full", children: /* @__PURE__ */ jsxRuntime.jsx(
25227
+ "svg",
25228
+ {
25229
+ className: "h-3 w-3",
25230
+ fill: "none",
25231
+ viewBox: "0 0 24 24",
25232
+ stroke: "currentColor",
25233
+ strokeWidth: 2,
25234
+ children: /* @__PURE__ */ jsxRuntime.jsx(
25235
+ "path",
25236
+ {
25237
+ strokeLinecap: "round",
25238
+ strokeLinejoin: "round",
25239
+ d: "M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
25240
+ }
25241
+ )
25242
+ }
25243
+ ) }),
25244
+ showNote: false
25245
+ },
25246
+ warning: {
25247
+ border: "border-warning/30",
25248
+ icon: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "bg-warning text-warning-foreground flex h-5 w-5 shrink-0 items-center justify-center rounded-full", children: /* @__PURE__ */ jsxRuntime.jsxs("svg", { className: "h-3 w-3", fill: "currentColor", viewBox: "0 0 24 24", children: [
25249
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "12", cy: "12", r: "10", fill: "currentColor" }),
25250
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "12", cy: "12", r: "4", className: "fill-warning" })
25251
+ ] }) }),
25252
+ showNote: true
25253
+ },
25254
+ error: {
25255
+ border: "border-destructive/30",
25256
+ icon: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "bg-destructive text-destructive-foreground flex h-5 w-5 shrink-0 items-center justify-center rounded-full", children: /* @__PURE__ */ jsxRuntime.jsx(
25257
+ "svg",
25258
+ {
25259
+ className: "h-3 w-3",
25260
+ fill: "none",
25261
+ viewBox: "0 0 24 24",
25262
+ stroke: "currentColor",
25263
+ strokeWidth: 3,
25264
+ children: /* @__PURE__ */ jsxRuntime.jsx(
25265
+ "path",
25266
+ {
25267
+ strokeLinecap: "round",
25268
+ strokeLinejoin: "round",
25269
+ d: "M6 18L18 6M6 6l12 12"
25270
+ }
25271
+ )
25272
+ }
25273
+ ) }),
25274
+ showNote: true
25275
+ },
25276
+ disabled: {
25277
+ border: "border-border",
25278
+ icon: null,
25279
+ showNote: false
25280
+ }
25281
+ };
25282
+ const currentStyle = stateStyles[effectiveState];
25283
+ const isDisabled = effectiveState === "disabled";
25125
25284
  return /* @__PURE__ */ jsxRuntime.jsxs(
25126
25285
  "div",
25127
25286
  {
25128
25287
  className: chunkOR5DRJCW_cjs.cn(
25129
- "rounded-lg border bg-white shadow-sm",
25130
- onEdit && "cursor-pointer transition-shadow hover:shadow-md",
25288
+ "bg-card text-card-foreground rounded-xl border-2 shadow-sm",
25289
+ currentStyle.border,
25290
+ isDisabled && "opacity-50",
25291
+ onEdit && !isDisabled && "cursor-pointer transition-shadow hover:shadow-md",
25131
25292
  className
25132
25293
  ),
25133
- onClick: () => onEdit?.(service),
25134
- role: onEdit ? "button" : void 0,
25135
- tabIndex: onEdit ? 0 : void 0,
25294
+ onClick: () => !isDisabled && onEdit?.(service),
25295
+ role: onEdit && !isDisabled ? "button" : void 0,
25296
+ tabIndex: onEdit && !isDisabled ? 0 : void 0,
25136
25297
  onKeyDown: (e) => {
25137
- if (onEdit && (e.key === "Enter" || e.key === " ")) {
25298
+ if (onEdit && !isDisabled && (e.key === "Enter" || e.key === " ")) {
25138
25299
  e.preventDefault();
25139
25300
  onEdit(service);
25140
25301
  }
25141
25302
  },
25142
25303
  children: [
25143
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-b bg-gray-50 px-4 py-3", children: /* @__PURE__ */ jsxRuntime.jsx("h6", { className: "font-medium", children: service.serviceName }) }),
25144
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-4", children: [
25145
- showProvider && service.providerName && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-2 flex items-center justify-between text-sm", children: [
25146
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: provider }),
25147
- /* @__PURE__ */ jsxRuntime.jsx("span", { children: service.providerName })
25304
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 px-4 py-3", children: [
25305
+ currentStyle.icon,
25306
+ /* @__PURE__ */ jsxRuntime.jsx(
25307
+ "h6",
25308
+ {
25309
+ className: "truncate text-sm font-semibold",
25310
+ title: service.serviceName,
25311
+ children: service.serviceName
25312
+ }
25313
+ )
25314
+ ] }),
25315
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4 px-4 pb-4", children: [
25316
+ showProvider && service.providerName && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
25317
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground mb-1 block text-xs font-semibold tracking-wider uppercase", children: provider }),
25318
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted truncate rounded-md px-3 py-2 text-sm", children: service.providerName })
25148
25319
  ] }),
25149
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-2 flex items-center justify-between text-sm", children: [
25150
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: occurrence }),
25151
- /* @__PURE__ */ jsxRuntime.jsx("span", { children: getOccurrenceLabel(service.occurrence) })
25320
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
25321
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground mb-1 block text-xs font-semibold tracking-wider uppercase", children: occurrence }),
25322
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted rounded-md px-3 py-2 text-sm", children: getOccurrenceLabel(service.occurrence) })
25152
25323
  ] }),
25153
- /* @__PURE__ */ jsxRuntime.jsx("hr", { className: "my-3" }),
25154
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-2 flex items-center justify-between text-sm", children: [
25155
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: nextOrder }),
25156
- /* @__PURE__ */ jsxRuntime.jsx("span", { title: service.nextOrder?.toString(), children: formatDate4(service.nextOrder) })
25324
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
25325
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground mb-1 block text-xs font-semibold tracking-wider uppercase", children: nextOrder }),
25326
+ /* @__PURE__ */ jsxRuntime.jsx(
25327
+ "div",
25328
+ {
25329
+ className: "bg-muted rounded-md px-3 py-2 text-sm",
25330
+ title: service.nextOrder?.toString(),
25331
+ children: formatDate4(service.nextOrder)
25332
+ }
25333
+ )
25157
25334
  ] }),
25158
- !service.overrideConsent && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-2 text-right text-xs text-red-600", children: consentNote })
25159
- ] }),
25160
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-t bg-gray-50 px-4 py-3 text-right", children: /* @__PURE__ */ jsxRuntime.jsxs(
25161
- "button",
25162
- {
25163
- type: "button",
25164
- onClick: (e) => {
25165
- e.stopPropagation();
25166
- onDelete?.(service);
25167
- },
25168
- className: "rounded-lg border border-red-300 px-3 py-1.5 text-sm text-red-600 hover:bg-red-50",
25169
- children: [
25170
- /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-trash mr-1" }),
25171
- deleteLabel
25172
- ]
25173
- }
25174
- ) })
25335
+ effectiveState === "warning" && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-warning/10 text-warning-800 dark:text-warning-200 rounded-md px-3 py-2 text-xs", children: [
25336
+ /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-exclamation-triangle mr-1" }),
25337
+ consentNote
25338
+ ] }),
25339
+ effectiveState === "error" && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-destructive/10 text-destructive rounded-md px-3 py-2 text-xs", children: [
25340
+ /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-times-circle mr-1" }),
25341
+ consentNote
25342
+ ] }),
25343
+ !isDisabled && /* @__PURE__ */ jsxRuntime.jsxs(
25344
+ "button",
25345
+ {
25346
+ type: "button",
25347
+ onClick: (e) => {
25348
+ e.stopPropagation();
25349
+ onDelete?.(service);
25350
+ },
25351
+ className: "text-muted-foreground hover:text-destructive mx-auto flex items-center gap-1 text-xs transition-colors",
25352
+ children: [
25353
+ /* @__PURE__ */ jsxRuntime.jsx(
25354
+ "svg",
25355
+ {
25356
+ className: "h-3 w-3",
25357
+ fill: "none",
25358
+ viewBox: "0 0 24 24",
25359
+ stroke: "currentColor",
25360
+ strokeWidth: 2,
25361
+ children: /* @__PURE__ */ jsxRuntime.jsx(
25362
+ "path",
25363
+ {
25364
+ strokeLinecap: "round",
25365
+ strokeLinejoin: "round",
25366
+ d: "M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"
25367
+ }
25368
+ )
25369
+ }
25370
+ ),
25371
+ deleteLabel
25372
+ ]
25373
+ }
25374
+ )
25375
+ ] })
25175
25376
  ]
25176
25377
  }
25177
25378
  );
@@ -25187,7 +25388,7 @@ function RecurringServiceAddCard({
25187
25388
  type: "button",
25188
25389
  onClick,
25189
25390
  className: chunkOR5DRJCW_cjs.cn(
25190
- "text-muted-foreground hover:border-primary hover:bg-primary/5 hover:text-primary flex min-h-[200px] w-full flex-col items-center justify-center rounded-lg border-2 border-dashed border-gray-300 bg-gray-50 p-4 transition-colors",
25391
+ "text-muted-foreground hover:border-primary hover:bg-primary/5 hover:text-primary border-border bg-muted/50 flex min-h-[200px] w-full flex-col items-center justify-center rounded-xl border-2 border-dashed p-4 transition-colors",
25191
25392
  className
25192
25393
  ),
25193
25394
  children: [
@@ -25244,15 +25445,15 @@ function RecurringServiceSetupModal({
25244
25445
  onSave(formData);
25245
25446
  };
25246
25447
  if (!open) return null;
25247
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "fixed inset-0 z-50 flex items-center justify-center bg-black/50", children: /* @__PURE__ */ jsxRuntime.jsxs(
25448
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-foreground/50 fixed inset-0 z-50 flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsxs(
25248
25449
  "div",
25249
25450
  {
25250
25451
  className: chunkOR5DRJCW_cjs.cn(
25251
- "w-full max-w-lg rounded-lg bg-white shadow-xl",
25452
+ "bg-card text-card-foreground w-full max-w-lg rounded-lg shadow-xl",
25252
25453
  className
25253
25454
  ),
25254
25455
  children: [
25255
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-primary flex items-center justify-between border-b p-4 text-white", children: [
25456
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-primary text-primary-foreground flex items-center justify-between p-4", children: [
25256
25457
  /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "text-lg font-semibold", children: title }),
25257
25458
  /* @__PURE__ */ jsxRuntime.jsx(
25258
25459
  "button",
@@ -25266,13 +25467,13 @@ function RecurringServiceSetupModal({
25266
25467
  ] }),
25267
25468
  /* @__PURE__ */ jsxRuntime.jsxs("form", { onSubmit: handleSubmit, className: "p-6", children: [
25268
25469
  showProviderSelector && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-4", children: [
25269
- /* @__PURE__ */ jsxRuntime.jsx("label", { className: "mb-1 block text-sm font-medium", children: provider }),
25470
+ /* @__PURE__ */ jsxRuntime.jsx("label", { className: "text-muted-foreground mb-1 block text-xs font-semibold tracking-wider uppercase", children: provider }),
25270
25471
  /* @__PURE__ */ jsxRuntime.jsxs(
25271
25472
  "select",
25272
25473
  {
25273
25474
  value: formData.providerId,
25274
25475
  onChange: (e) => setFormData({ ...formData, providerId: e.target.value }),
25275
- className: "w-full rounded-lg border border-gray-300 p-2",
25476
+ className: "bg-card border-input focus:ring-primary w-full rounded-lg border p-2 focus:ring-2 focus:outline-none",
25276
25477
  required: showProviderSelector,
25277
25478
  children: [
25278
25479
  /* @__PURE__ */ jsxRuntime.jsx("option", { value: "", children: "Select provider..." }),
@@ -25282,13 +25483,13 @@ function RecurringServiceSetupModal({
25282
25483
  )
25283
25484
  ] }),
25284
25485
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-4", children: [
25285
- /* @__PURE__ */ jsxRuntime.jsx("label", { className: "mb-1 block text-sm font-medium", children: service }),
25486
+ /* @__PURE__ */ jsxRuntime.jsx("label", { className: "text-muted-foreground mb-1 block text-xs font-semibold tracking-wider uppercase", children: service }),
25286
25487
  /* @__PURE__ */ jsxRuntime.jsxs(
25287
25488
  "select",
25288
25489
  {
25289
25490
  value: formData.serviceId,
25290
25491
  onChange: (e) => setFormData({ ...formData, serviceId: e.target.value }),
25291
- className: "w-full rounded-lg border border-gray-300 p-2",
25492
+ className: "bg-card border-input focus:ring-primary w-full rounded-lg border p-2 focus:ring-2 focus:outline-none",
25292
25493
  required: true,
25293
25494
  children: [
25294
25495
  /* @__PURE__ */ jsxRuntime.jsx("option", { value: "", children: "Select service..." }),
@@ -25298,13 +25499,13 @@ function RecurringServiceSetupModal({
25298
25499
  )
25299
25500
  ] }),
25300
25501
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-4", children: [
25301
- /* @__PURE__ */ jsxRuntime.jsx("label", { className: "mb-1 block text-sm font-medium", children: occurrence }),
25502
+ /* @__PURE__ */ jsxRuntime.jsx("label", { className: "text-muted-foreground mb-1 block text-xs font-semibold tracking-wider uppercase", children: occurrence }),
25302
25503
  /* @__PURE__ */ jsxRuntime.jsxs(
25303
25504
  "select",
25304
25505
  {
25305
25506
  value: formData.occurrence,
25306
25507
  onChange: (e) => setFormData({ ...formData, occurrence: e.target.value }),
25307
- className: "w-full rounded-lg border border-gray-300 p-2",
25508
+ className: "bg-card border-input focus:ring-primary w-full rounded-lg border p-2 focus:ring-2 focus:outline-none",
25308
25509
  required: true,
25309
25510
  children: [
25310
25511
  /* @__PURE__ */ jsxRuntime.jsx("option", { value: "monthly", children: "Monthly" }),
@@ -25326,7 +25527,7 @@ function RecurringServiceSetupModal({
25326
25527
  ...formData,
25327
25528
  overrideConsent: e.target.checked
25328
25529
  }),
25329
- className: "h-4 w-4 rounded border-gray-300"
25530
+ className: "border-input accent-primary h-4 w-4 rounded"
25330
25531
  }
25331
25532
  ),
25332
25533
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: overrideConsent })
@@ -25339,7 +25540,7 @@ function RecurringServiceSetupModal({
25339
25540
  {
25340
25541
  type: "button",
25341
25542
  onClick: onClose,
25342
- className: "rounded-lg border border-gray-300 px-4 py-2 text-gray-700 hover:bg-gray-50",
25543
+ className: "border-border text-muted-foreground hover:bg-muted rounded-lg border px-4 py-2 transition-colors",
25343
25544
  children: cancel
25344
25545
  }
25345
25546
  ),
@@ -25348,7 +25549,7 @@ function RecurringServiceSetupModal({
25348
25549
  {
25349
25550
  type: "submit",
25350
25551
  disabled: saving,
25351
- className: "bg-primary hover:bg-primary/90 rounded-lg px-4 py-2 text-white disabled:bg-gray-300",
25552
+ className: "bg-primary text-primary-foreground hover:bg-primary/90 disabled:bg-muted disabled:text-muted-foreground rounded-lg px-4 py-2 transition-colors",
25352
25553
  children: saving ? /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "flex items-center gap-2", children: [
25353
25554
  /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-spinner fa-spin" }),
25354
25555
  "Saving..."
@@ -25428,16 +25629,16 @@ function RejectionModal({
25428
25629
  };
25429
25630
  return /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.Modal, { open, onOpenChange, size: "md", children: /* @__PURE__ */ jsxRuntime.jsxs("form", { onSubmit: handleSubmit, children: [
25430
25631
  /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalTitle, { children: title }) }),
25431
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4", children: [
25432
- (description || itemDescription) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rounded-lg bg-gray-50 p-3 dark:bg-gray-800", children: [
25433
- description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-gray-600 dark:text-gray-400", children: description }),
25434
- itemDescription && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-1 text-sm font-medium text-gray-900 dark:text-white", children: itemDescription })
25632
+ /* @__PURE__ */ jsxRuntime.jsxs(chunkI7L6CQXR_cjs.ModalBody, { className: "space-y-4", children: [
25633
+ (description || itemDescription) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-muted rounded-lg p-3", children: [
25634
+ description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-sm", children: description }),
25635
+ itemDescription && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-foreground mt-1 text-sm font-medium", children: itemDescription })
25435
25636
  ] }),
25436
- variant === "danger" && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-3 rounded-lg border border-red-200 bg-red-50 p-3 dark:border-red-800 dark:bg-red-900/20", children: [
25637
+ variant === "danger" && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "border-destructive/30 bg-destructive/10 flex items-start gap-3 rounded-lg border p-3", children: [
25437
25638
  /* @__PURE__ */ jsxRuntime.jsx(
25438
25639
  "svg",
25439
25640
  {
25440
- className: "mt-0.5 h-5 w-5 flex-shrink-0 text-red-500",
25641
+ className: "text-destructive mt-0.5 h-5 w-5 flex-shrink-0",
25441
25642
  fill: "none",
25442
25643
  viewBox: "0 0 24 24",
25443
25644
  stroke: "currentColor",
@@ -25452,14 +25653,17 @@ function RejectionModal({
25452
25653
  )
25453
25654
  }
25454
25655
  ),
25455
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-red-600 dark:text-red-400", children: "This action cannot be undone. The affected party will be notified of this rejection." })
25656
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-destructive text-sm", children: "This action cannot be undone. The affected party will be notified of this rejection." })
25456
25657
  ] }),
25457
25658
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
25458
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "mb-2 block text-sm font-medium text-gray-700 dark:text-gray-300", children: "Reason for rejection" }),
25659
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground mb-2 block text-sm font-medium", children: "Reason for rejection" }),
25459
25660
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-2", children: reasons.map((reason) => /* @__PURE__ */ jsxRuntime.jsxs(
25460
25661
  "label",
25461
25662
  {
25462
- className: `flex cursor-pointer items-center gap-3 rounded-lg border p-3 transition-colors ${selectedReasonId === reason.id ? "border-blue-500 bg-blue-50 dark:border-blue-400 dark:bg-blue-900/20" : "border-gray-200 hover:border-gray-300 dark:border-gray-700 dark:hover:border-gray-600"} `,
25663
+ className: chunkOR5DRJCW_cjs.cn(
25664
+ "flex cursor-pointer items-center gap-3 rounded-lg border p-3 transition-colors",
25665
+ selectedReasonId === reason.id ? "border-primary bg-primary/10" : "border-border hover:border-muted-foreground/50"
25666
+ ),
25463
25667
  children: [
25464
25668
  /* @__PURE__ */ jsxRuntime.jsx(
25465
25669
  "input",
@@ -25469,25 +25673,25 @@ function RejectionModal({
25469
25673
  value: reason.id,
25470
25674
  checked: selectedReasonId === reason.id,
25471
25675
  onChange: (e) => setSelectedReasonId(e.target.value),
25472
- className: "h-4 w-4 border-gray-300 text-blue-600 focus:ring-blue-500 dark:border-gray-600"
25676
+ className: "text-primary focus:ring-primary border-border h-4 w-4"
25473
25677
  }
25474
25678
  ),
25475
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-gray-900 dark:text-white", children: reason.label }),
25476
- reason.requiresDetails && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs text-gray-500 dark:text-gray-400", children: "(requires details)" })
25679
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground text-sm", children: reason.label }),
25680
+ reason.requiresDetails && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground text-xs", children: "(requires details)" })
25477
25681
  ]
25478
25682
  },
25479
25683
  reason.id
25480
25684
  )) })
25481
25685
  ] }),
25482
25686
  showDetails && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
25483
- /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "mb-1 block text-sm font-medium text-gray-700 dark:text-gray-300", children: [
25687
+ /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "text-foreground mb-1 block text-sm font-medium", children: [
25484
25688
  detailsLabel,
25485
- needsDetails && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "ml-1 text-red-500", children: "*" })
25689
+ needsDetails && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-destructive ml-1", children: "*" })
25486
25690
  ] }),
25487
25691
  /* @__PURE__ */ jsxRuntime.jsx(
25488
25692
  "textarea",
25489
25693
  {
25490
- className: "w-full rounded-md border border-gray-300 px-3 py-2 shadow-sm focus:ring-2 focus:ring-blue-500 focus:outline-none dark:border-gray-600 dark:bg-gray-800 dark:text-white",
25694
+ className: "bg-background text-foreground border-input focus:ring-ring w-full rounded-md border px-3 py-2 shadow-sm focus:ring-2 focus:outline-none",
25491
25695
  rows: 3,
25492
25696
  value: details,
25493
25697
  onChange: (e) => setDetails(e.target.value),
@@ -25495,7 +25699,7 @@ function RejectionModal({
25495
25699
  required: needsDetails
25496
25700
  }
25497
25701
  ),
25498
- needsDetails && !details.trim() && selectedReasonId && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-1 text-xs text-red-500", children: "Please provide additional details for this rejection reason." })
25702
+ needsDetails && !details.trim() && selectedReasonId && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-destructive mt-1 text-xs", children: "Please provide additional details for this rejection reason." })
25499
25703
  ] })
25500
25704
  ] }),
25501
25705
  /* @__PURE__ */ jsxRuntime.jsxs(chunkI7L6CQXR_cjs.ModalFooter, { children: [
@@ -25661,7 +25865,7 @@ function ReportDashboard({
25661
25865
  ] }),
25662
25866
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3", children: [
25663
25867
  /* @__PURE__ */ jsxRuntime.jsx(
25664
- chunkNL3CZNBH_cjs.Select,
25868
+ chunk5UUL5EEO_cjs.Select,
25665
25869
  {
25666
25870
  options: dateRangeOptions,
25667
25871
  value: selectedDateRange,
@@ -25798,7 +26002,7 @@ function ReportDashboard({
25798
26002
  ] })
25799
26003
  ] });
25800
26004
  }
25801
- function ResultsEntryForm({
26005
+ var ResultsEntryForm = React46__namespace.forwardRef(function ResultsEntryForm2({
25802
26006
  employeeFirstName,
25803
26007
  employeeLastName,
25804
26008
  initialData = {},
@@ -25808,7 +26012,7 @@ function ResultsEntryForm({
25808
26012
  onSubmit,
25809
26013
  labels = {},
25810
26014
  className
25811
- }) {
26015
+ }, ref) {
25812
26016
  const {
25813
26017
  testResults = "Test Results",
25814
26018
  passed = "Passed",
@@ -25865,39 +26069,60 @@ function ResultsEntryForm({
25865
26069
  (prev) => prev.includes(contactId) ? prev.filter((id) => id !== contactId) : [...prev, contactId]
25866
26070
  );
25867
26071
  };
26072
+ const validateAndSubmit = React46__namespace.useCallback(() => {
26073
+ if (!result) {
26074
+ setShowError(true);
26075
+ return;
26076
+ }
26077
+ setShowError(false);
26078
+ onSubmit({
26079
+ result,
26080
+ alternateText: alternateText || void 0,
26081
+ dateDrawn: dateDrawnValue || void 0,
26082
+ dateCompleted: dateCompletedValue || void 0,
26083
+ recommendations: recommendations || void 0,
26084
+ files: files.length > 0 ? files : void 0,
26085
+ providerContacts: selectedContacts.length > 0 ? selectedContacts : void 0,
26086
+ applyToAllServices: applyToAll
26087
+ });
26088
+ }, [
26089
+ result,
26090
+ alternateText,
26091
+ dateDrawnValue,
26092
+ dateCompletedValue,
26093
+ recommendations,
26094
+ files,
26095
+ selectedContacts,
26096
+ applyToAll,
26097
+ onSubmit
26098
+ ]);
26099
+ React46__namespace.useImperativeHandle(
26100
+ ref,
26101
+ () => ({
26102
+ submit: validateAndSubmit
26103
+ }),
26104
+ [validateAndSubmit]
26105
+ );
25868
26106
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: chunkOR5DRJCW_cjs.cn("space-y-6", className), children: [
25869
26107
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-4 sm:flex-row sm:items-center", children: [
25870
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "sm:w-1/2", children: [
25871
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "mr-2 font-semibold", children: testResults }),
25872
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mt-2 flex gap-4 sm:mt-0 sm:inline-flex", children: [
25873
- /* @__PURE__ */ jsxRuntime.jsx(
25874
- chunkXHJGYBYG_cjs.Radio,
25875
- {
25876
- name: "result",
25877
- value: "passed",
25878
- label: passed,
25879
- checked: result === "passed",
25880
- onChange: () => {
25881
- setResult("passed");
25882
- setShowError(false);
25883
- }
25884
- }
25885
- ),
25886
- /* @__PURE__ */ jsxRuntime.jsx(
25887
- chunkXHJGYBYG_cjs.Radio,
25888
- {
25889
- name: "result",
25890
- value: "failed",
25891
- label: failed,
25892
- checked: result === "failed",
25893
- onChange: () => {
25894
- setResult("failed");
25895
- setShowError(false);
25896
- }
25897
- }
25898
- )
25899
- ] })
25900
- ] }),
26108
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "sm:w-1/2", children: /* @__PURE__ */ jsxRuntime.jsxs(
26109
+ chunkXHJGYBYG_cjs.RadioGroup,
26110
+ {
26111
+ name: "result",
26112
+ label: testResults,
26113
+ value: result ?? "",
26114
+ onValueChange: (value) => {
26115
+ setResult(value);
26116
+ setShowError(false);
26117
+ },
26118
+ orientation: "horizontal",
26119
+ error: showError ? pleaseSelectResult : void 0,
26120
+ children: [
26121
+ /* @__PURE__ */ jsxRuntime.jsx(chunkXHJGYBYG_cjs.Radio, { value: "passed", label: passed }),
26122
+ /* @__PURE__ */ jsxRuntime.jsx(chunkXHJGYBYG_cjs.Radio, { value: "failed", label: failed })
26123
+ ]
26124
+ }
26125
+ ) }),
25901
26126
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "sm:w-1/2", children: /* @__PURE__ */ jsxRuntime.jsx(
25902
26127
  chunkVV4N4WY6_cjs.Input,
25903
26128
  {
@@ -26073,57 +26298,122 @@ function ResultsEntryForm({
26073
26298
  ] }),
26074
26299
  showError && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-destructive text-sm font-medium", children: pleaseSelectResult })
26075
26300
  ] });
26076
- }
26077
- function ResultsEntryCard({
26301
+ });
26302
+ function ResultsEntryModal({
26078
26303
  serviceName,
26079
26304
  employeeFirstName,
26080
26305
  employeeLastName,
26081
- isOpen = true,
26082
- onClose,
26306
+ open,
26307
+ onOpenChange,
26083
26308
  onSubmit,
26309
+ isSubmitting = false,
26084
26310
  labels = {},
26085
26311
  ...props
26086
26312
  }) {
26087
26313
  const { submit = "Submit", close = "Close" } = labels;
26314
+ const formRef = React46__namespace.useRef(null);
26088
26315
  const employeeName = employeeFirstName || employeeLastName ? `${employeeFirstName ?? ""} ${employeeLastName ?? ""}`.trim() : void 0;
26089
- if (!isOpen) return null;
26090
- const handleSubmit = (data) => {
26091
- onSubmit(data);
26092
- onClose();
26093
- };
26094
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-background w-full max-w-2xl rounded-lg border shadow-lg", children: [
26095
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-primary text-primary-foreground rounded-t-lg p-4", children: [
26096
- /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "text-lg font-semibold", children: serviceName }),
26097
- employeeName && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm opacity-90", children: employeeName })
26316
+ const handleSubmitClick = () => {
26317
+ formRef.current?.submit();
26318
+ };
26319
+ return /* @__PURE__ */ jsxRuntime.jsxs(chunkI7L6CQXR_cjs.Modal, { open, onOpenChange, size: "2xl", children: [
26320
+ /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalTitle, { children: serviceName }) }),
26321
+ /* @__PURE__ */ jsxRuntime.jsxs(chunkI7L6CQXR_cjs.ModalBody, { children: [
26322
+ employeeName && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted mb-4 rounded-lg p-3", children: /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-muted-foreground text-sm", children: [
26323
+ "Employee:",
26324
+ " ",
26325
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground font-medium", children: employeeName })
26326
+ ] }) }),
26327
+ /* @__PURE__ */ jsxRuntime.jsx(
26328
+ ResultsEntryForm,
26329
+ {
26330
+ ref: formRef,
26331
+ employeeFirstName,
26332
+ employeeLastName,
26333
+ onSubmit,
26334
+ labels,
26335
+ ...props
26336
+ }
26337
+ )
26098
26338
  ] }),
26099
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "p-6", children: /* @__PURE__ */ jsxRuntime.jsx(
26100
- ResultsEntryForm,
26101
- {
26102
- serviceName,
26103
- employeeFirstName,
26104
- employeeLastName,
26105
- onSubmit: handleSubmit,
26106
- labels,
26107
- ...props
26108
- }
26109
- ) }),
26110
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-end gap-3 border-t p-4", children: [
26111
- /* @__PURE__ */ jsxRuntime.jsx(chunkMKJDBXX4_cjs.Button, { variant: "outline", onClick: onClose, children: close }),
26339
+ /* @__PURE__ */ jsxRuntime.jsxs(chunkI7L6CQXR_cjs.ModalFooter, { children: [
26112
26340
  /* @__PURE__ */ jsxRuntime.jsx(
26113
26341
  chunkMKJDBXX4_cjs.Button,
26114
26342
  {
26115
- onClick: () => {
26116
- const form = document.querySelector("[data-results-form]");
26117
- if (form) {
26118
- form.dispatchEvent(new Event("submit", { bubbles: true }));
26119
- }
26120
- },
26121
- children: submit
26343
+ type: "button",
26344
+ variant: "outline",
26345
+ onClick: () => onOpenChange(false),
26346
+ disabled: isSubmitting,
26347
+ children: close
26348
+ }
26349
+ ),
26350
+ /* @__PURE__ */ jsxRuntime.jsx(
26351
+ chunkMKJDBXX4_cjs.Button,
26352
+ {
26353
+ type: "button",
26354
+ onClick: handleSubmitClick,
26355
+ disabled: isSubmitting,
26356
+ children: isSubmitting ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
26357
+ /* @__PURE__ */ jsxRuntime.jsxs(
26358
+ "svg",
26359
+ {
26360
+ className: "mr-2 -ml-1 h-4 w-4 animate-spin",
26361
+ fill: "none",
26362
+ viewBox: "0 0 24 24",
26363
+ children: [
26364
+ /* @__PURE__ */ jsxRuntime.jsx(
26365
+ "circle",
26366
+ {
26367
+ className: "opacity-25",
26368
+ cx: "12",
26369
+ cy: "12",
26370
+ r: "10",
26371
+ stroke: "currentColor",
26372
+ strokeWidth: "4"
26373
+ }
26374
+ ),
26375
+ /* @__PURE__ */ jsxRuntime.jsx(
26376
+ "path",
26377
+ {
26378
+ className: "opacity-75",
26379
+ fill: "currentColor",
26380
+ d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
26381
+ }
26382
+ )
26383
+ ]
26384
+ }
26385
+ ),
26386
+ "Processing..."
26387
+ ] }) : submit
26122
26388
  }
26123
26389
  )
26124
26390
  ] })
26125
26391
  ] });
26126
26392
  }
26393
+ function ResultsEntryCard({
26394
+ isOpen,
26395
+ onClose,
26396
+ onSubmit,
26397
+ ...restProps
26398
+ }) {
26399
+ const handleSubmit = (data) => {
26400
+ onSubmit(data);
26401
+ onClose();
26402
+ };
26403
+ return /* @__PURE__ */ jsxRuntime.jsx(
26404
+ ResultsEntryModal,
26405
+ {
26406
+ open: isOpen,
26407
+ onOpenChange: (nextOpen) => {
26408
+ if (!nextOpen) {
26409
+ onClose();
26410
+ }
26411
+ },
26412
+ onSubmit: handleSubmit,
26413
+ ...restProps
26414
+ }
26415
+ );
26416
+ }
26127
26417
  function ScheduleCalendar({
26128
26418
  appointments,
26129
26419
  selectedDate = /* @__PURE__ */ new Date(),
@@ -27321,42 +27611,42 @@ function ServiceCard({
27321
27611
  return /* @__PURE__ */ jsxRuntime.jsx(
27322
27612
  chunkHRA4FUO6_cjs.Card,
27323
27613
  {
27324
- className: `h-full transition-all duration-200 ${onClick ? "cursor-pointer hover:shadow-md" : ""} ${selected ? "ring-2 ring-blue-500 dark:ring-blue-400" : ""} ${!currentlyOffered ? "opacity-60" : ""} ${className} `.trim(),
27614
+ className: `h-full transition-all duration-200 ${onClick ? "cursor-pointer hover:shadow-md" : ""} ${selected ? "ring-primary ring-2" : ""} ${!currentlyOffered ? "opacity-60" : ""} ${className} `.trim(),
27325
27615
  onClick: onClick ? handleCardClick : void 0,
27326
27616
  children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex h-full flex-col p-4", children: [
27327
27617
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-2 flex items-start justify-between gap-2", children: [
27328
27618
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
27329
- /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "truncate font-semibold text-gray-900 dark:text-white", children: name }),
27330
- category && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-0.5 text-xs text-gray-500 dark:text-gray-400", children: category })
27619
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-foreground truncate font-semibold", children: name }),
27620
+ category && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground mt-0.5 text-xs", children: category })
27331
27621
  ] }),
27332
27622
  !currentlyOffered && /* @__PURE__ */ jsxRuntime.jsx(chunkEKIQE524_cjs.Badge, { variant: "warning", size: "sm", children: "Not Offered" })
27333
27623
  ] }),
27334
- description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mb-3 line-clamp-2 text-sm text-gray-600 dark:text-gray-400", children: description }),
27624
+ description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground mb-3 line-clamp-2 text-sm", children: description }),
27335
27625
  tags.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-3 flex flex-wrap gap-1", children: [
27336
27626
  tags.slice(0, 3).map((tag) => /* @__PURE__ */ jsxRuntime.jsx(
27337
27627
  "span",
27338
27628
  {
27339
- className: "inline-flex items-center rounded bg-gray-100 px-2 py-0.5 text-xs font-medium text-gray-600 dark:bg-gray-800 dark:text-gray-400",
27629
+ className: "bg-muted text-muted-foreground inline-flex items-center rounded px-2 py-0.5 text-xs font-medium",
27340
27630
  children: tag
27341
27631
  },
27342
27632
  tag
27343
27633
  )),
27344
- tags.length > 3 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-xs text-gray-500 dark:text-gray-400", children: [
27634
+ tags.length > 3 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-muted-foreground text-xs", children: [
27345
27635
  "+",
27346
27636
  tags.length - 3
27347
27637
  ] })
27348
27638
  ] }),
27349
27639
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mt-auto", children: [
27350
27640
  price !== void 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-2 flex items-baseline justify-between", children: [
27351
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs font-medium text-gray-500 uppercase dark:text-gray-400", children: "Base Price" }),
27352
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-lg font-bold text-gray-900 dark:text-white", children: formatCurrency2(price, currency) })
27641
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground text-xs font-medium uppercase", children: "Base Price" }),
27642
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground text-lg font-bold", children: formatCurrency2(price, currency) })
27353
27643
  ] }),
27354
27644
  showInventory && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-2 flex items-center justify-between text-sm", children: [
27355
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-gray-500 dark:text-gray-400", children: "Inventory" }),
27645
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: "Inventory" }),
27356
27646
  /* @__PURE__ */ jsxRuntime.jsxs(
27357
27647
  "span",
27358
27648
  {
27359
- className: `font-medium ${isLowInventory ? "text-red-600 dark:text-red-400" : "text-gray-900 dark:text-white"}`,
27649
+ className: `font-medium ${isLowInventory ? "text-destructive" : "text-foreground"}`,
27360
27650
  children: [
27361
27651
  inventoryCount,
27362
27652
  inventoryTotal && ` / ${inventoryTotal}`
@@ -27364,53 +27654,19 @@ function ServiceCard({
27364
27654
  }
27365
27655
  )
27366
27656
  ] }),
27367
- (hasCustomAvailability || customPricingCount > 0) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-3 flex items-center gap-2 text-xs text-gray-500 dark:text-gray-400", children: [
27368
- /* @__PURE__ */ jsxRuntime.jsx(
27369
- "svg",
27370
- {
27371
- className: "h-3.5 w-3.5",
27372
- fill: "none",
27373
- viewBox: "0 0 24 24",
27374
- stroke: "currentColor",
27375
- children: /* @__PURE__ */ jsxRuntime.jsx(
27376
- "path",
27377
- {
27378
- strokeLinecap: "round",
27379
- strokeLinejoin: "round",
27380
- strokeWidth: 2,
27381
- d: "M12 6V4m0 2a2 2 0 100 4m0-4a2 2 0 110 4m-6 8a2 2 0 100-4m0 4a2 2 0 110-4m0 4v2m0-6V4m6 6v10m6-2a2 2 0 100-4m0 4a2 2 0 110-4m0 4v2m0-6V4"
27382
- }
27383
- )
27384
- }
27385
- ),
27657
+ (hasCustomAvailability || customPricingCount > 0) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-muted-foreground mb-3 flex items-center gap-2 text-xs", children: [
27658
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.SlidersHorizontal, { className: "h-3.5 w-3.5" }),
27386
27659
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: customPricingCount > 0 ? `${customPricingCount} custom pricing tier${customPricingCount > 1 ? "s" : ""}` : "Custom availability" })
27387
27660
  ] }),
27388
- (onEdit || onManage || onDelete) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-end gap-2 border-t border-gray-100 pt-2 dark:border-gray-800", children: [
27661
+ (onEdit || onManage || onDelete) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "border-border flex items-center gap-2 border-t pt-2", children: [
27389
27662
  onDelete && /* @__PURE__ */ jsxRuntime.jsx(
27390
27663
  "button",
27391
27664
  {
27392
27665
  type: "button",
27393
27666
  onClick: handleDeleteClick,
27394
- className: "p-1.5 text-gray-400 transition-colors hover:text-red-500 dark:hover:text-red-400",
27667
+ className: "text-muted-foreground hover:text-destructive p-1.5 transition-colors",
27395
27668
  title: "Delete service",
27396
- children: /* @__PURE__ */ jsxRuntime.jsx(
27397
- "svg",
27398
- {
27399
- className: "h-4 w-4",
27400
- fill: "none",
27401
- viewBox: "0 0 24 24",
27402
- stroke: "currentColor",
27403
- children: /* @__PURE__ */ jsxRuntime.jsx(
27404
- "path",
27405
- {
27406
- strokeLinecap: "round",
27407
- strokeLinejoin: "round",
27408
- strokeWidth: 2,
27409
- d: "M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"
27410
- }
27411
- )
27412
- }
27413
- )
27669
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Trash2, { className: "h-4 w-4" })
27414
27670
  }
27415
27671
  ),
27416
27672
  onEdit && /* @__PURE__ */ jsxRuntime.jsx(
@@ -27418,26 +27674,9 @@ function ServiceCard({
27418
27674
  {
27419
27675
  type: "button",
27420
27676
  onClick: handleEditClick,
27421
- className: "p-1.5 text-gray-400 transition-colors hover:text-blue-500 dark:hover:text-blue-400",
27677
+ className: "text-muted-foreground hover:text-primary p-1.5 transition-colors",
27422
27678
  title: "Edit service",
27423
- children: /* @__PURE__ */ jsxRuntime.jsx(
27424
- "svg",
27425
- {
27426
- className: "h-4 w-4",
27427
- fill: "none",
27428
- viewBox: "0 0 24 24",
27429
- stroke: "currentColor",
27430
- children: /* @__PURE__ */ jsxRuntime.jsx(
27431
- "path",
27432
- {
27433
- strokeLinecap: "round",
27434
- strokeLinejoin: "round",
27435
- strokeWidth: 2,
27436
- d: "M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z"
27437
- }
27438
- )
27439
- }
27440
- )
27679
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Pencil, { className: "h-4 w-4" })
27441
27680
  }
27442
27681
  ),
27443
27682
  onManage && /* @__PURE__ */ jsxRuntime.jsx(
@@ -27445,7 +27684,7 @@ function ServiceCard({
27445
27684
  {
27446
27685
  type: "button",
27447
27686
  onClick: handleManageClick,
27448
- className: "rounded px-3 py-1 text-sm font-medium text-blue-600 transition-colors hover:bg-blue-50 dark:text-blue-400 dark:hover:bg-blue-900/20",
27687
+ className: "text-primary hover:bg-primary/10 ml-auto rounded px-3 py-1 text-sm font-medium transition-colors",
27449
27688
  children: "Manage"
27450
27689
  }
27451
27690
  )
@@ -27462,28 +27701,11 @@ function AddServiceCard({
27462
27701
  return /* @__PURE__ */ jsxRuntime.jsx(
27463
27702
  chunkHRA4FUO6_cjs.Card,
27464
27703
  {
27465
- className: `h-full cursor-pointer border-2 border-dashed border-gray-300 bg-gray-50 transition-all duration-200 hover:border-blue-400 hover:bg-gray-100 dark:border-gray-600 dark:bg-gray-800/50 dark:hover:border-blue-500 dark:hover:bg-gray-800 ${className} `.trim(),
27704
+ className: `border-border bg-muted/50 hover:border-primary hover:bg-muted h-full cursor-pointer border-2 border-dashed transition-all duration-200 ${className} `.trim(),
27466
27705
  onClick,
27467
27706
  children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex h-full min-h-[160px] flex-col items-center justify-center p-4", children: [
27468
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mb-3 flex h-12 w-12 items-center justify-center rounded-full bg-gray-200 dark:bg-gray-700", children: /* @__PURE__ */ jsxRuntime.jsx(
27469
- "svg",
27470
- {
27471
- className: "h-6 w-6 text-gray-500 dark:text-gray-400",
27472
- fill: "none",
27473
- viewBox: "0 0 24 24",
27474
- stroke: "currentColor",
27475
- children: /* @__PURE__ */ jsxRuntime.jsx(
27476
- "path",
27477
- {
27478
- strokeLinecap: "round",
27479
- strokeLinejoin: "round",
27480
- strokeWidth: 2,
27481
- d: "M12 4v16m8-8H4"
27482
- }
27483
- )
27484
- }
27485
- ) }),
27486
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium text-gray-600 dark:text-gray-400", children: "Add New Service" })
27707
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted mb-3 flex h-12 w-12 items-center justify-center rounded-full", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "text-muted-foreground h-6 w-6" }) }),
27708
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-sm font-medium", children: "Add New Service" })
27487
27709
  ] })
27488
27710
  }
27489
27711
  );
@@ -27579,7 +27801,7 @@ function ServiceGeneralSettings({
27579
27801
  }
27580
27802
  ),
27581
27803
  categories.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
27582
- chunkNL3CZNBH_cjs.Select,
27804
+ chunk5UUL5EEO_cjs.Select,
27583
27805
  {
27584
27806
  label: "Category",
27585
27807
  value: categoryId || "",
@@ -27666,18 +27888,18 @@ function ServiceGeneralSettings({
27666
27888
  ] });
27667
27889
  }
27668
27890
  function ServiceSkeleton() {
27669
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "animate-pulse rounded-lg border border-gray-200 p-4 dark:border-gray-700", children: [
27891
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "border-border animate-pulse rounded-lg border p-4", children: [
27670
27892
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-3 flex items-start justify-between", children: [
27671
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-5 w-32 rounded bg-gray-200 dark:bg-gray-700" }),
27672
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-5 w-16 rounded bg-gray-200 dark:bg-gray-700" })
27893
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted h-5 w-32 rounded" }),
27894
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted h-5 w-16 rounded" })
27673
27895
  ] }),
27674
27896
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-4 space-y-2", children: [
27675
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-4 w-full rounded bg-gray-200 dark:bg-gray-700" }),
27676
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-4 w-3/4 rounded bg-gray-200 dark:bg-gray-700" })
27897
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted h-4 w-full rounded" }),
27898
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted h-4 w-3/4 rounded" })
27677
27899
  ] }),
27678
27900
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-2", children: [
27679
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-6 w-20 rounded-full bg-gray-200 dark:bg-gray-700" }),
27680
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-6 w-20 rounded-full bg-gray-200 dark:bg-gray-700" })
27901
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted h-6 w-20 rounded-full" }),
27902
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted h-6 w-20 rounded-full" })
27681
27903
  ] })
27682
27904
  ] });
27683
27905
  }
@@ -27725,7 +27947,7 @@ function ServiceGrid({
27725
27947
  /* @__PURE__ */ jsxRuntime.jsx(
27726
27948
  "svg",
27727
27949
  {
27728
- className: "mb-4 h-12 w-12 text-gray-400",
27950
+ className: "text-muted-foreground mb-4 h-12 w-12",
27729
27951
  fill: "none",
27730
27952
  viewBox: "0 0 24 24",
27731
27953
  stroke: "currentColor",
@@ -27740,7 +27962,7 @@ function ServiceGrid({
27740
27962
  )
27741
27963
  }
27742
27964
  ),
27743
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-gray-500 dark:text-gray-400", children: emptyMessage })
27965
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground", children: emptyMessage })
27744
27966
  ] });
27745
27967
  }
27746
27968
  return /* @__PURE__ */ jsxRuntime.jsxs(
@@ -27854,12 +28076,16 @@ function ServicePicker({
27854
28076
  return /* @__PURE__ */ jsxRuntime.jsxs(
27855
28077
  "div",
27856
28078
  {
27857
- className: chunkOR5DRJCW_cjs.cn("flex flex-col", !fullWidth && "lg:max-w-md", className),
28079
+ className: chunkOR5DRJCW_cjs.cn(
28080
+ "bg-card text-card-foreground border-border shadow-card flex flex-col rounded-xl border",
28081
+ !fullWidth && "lg:max-w-md",
28082
+ className
28083
+ ),
27858
28084
  children: [
27859
28085
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "p-3", children: [
27860
- !hideHeading && /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "mb-3 text-xl font-bold text-gray-900 dark:text-gray-100", children: heading }),
28086
+ !hideHeading && /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-foreground mb-3 text-xl font-bold", children: heading }),
27861
28087
  showSearch && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
27862
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "pointer-events-none absolute inset-y-0 left-0 flex items-center pl-3", children: /* @__PURE__ */ jsxRuntime.jsx(SearchIcon5, { className: "h-5 w-5 text-gray-400" }) }),
28088
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "pointer-events-none absolute inset-y-0 left-0 flex items-center pl-3", children: /* @__PURE__ */ jsxRuntime.jsx(SearchIcon5, { className: "text-muted-foreground h-5 w-5" }) }),
27863
28089
  /* @__PURE__ */ jsxRuntime.jsx(
27864
28090
  chunkVV4N4WY6_cjs.Input,
27865
28091
  {
@@ -27874,8 +28100,8 @@ function ServicePicker({
27874
28100
  ] })
27875
28101
  ] }),
27876
28102
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 overflow-y-auto p-3", children: [
27877
- error && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mb-4 rounded-lg bg-red-50 p-4 text-red-700 dark:bg-red-900/20 dark:text-red-400", children: /* @__PURE__ */ jsxRuntime.jsx("strong", { children: error }) }),
27878
- loading ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 text-gray-500", children: [
28103
+ error && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-destructive/10 text-destructive mb-4 rounded-lg p-4", children: /* @__PURE__ */ jsxRuntime.jsx("strong", { children: error }) }),
28104
+ loading ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-muted-foreground flex items-center gap-2", children: [
27879
28105
  /* @__PURE__ */ jsxRuntime.jsx(SpinnerIcon5, { className: "h-5 w-5 animate-spin" }),
27880
28106
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Loading available services..." })
27881
28107
  ] }) : isSearching ? (
@@ -27889,7 +28115,7 @@ function ServicePicker({
27889
28115
  multiple
27890
28116
  },
27891
28117
  service.id
27892
- )) : /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-lg bg-yellow-50 p-4 text-yellow-700 dark:bg-yellow-900/20 dark:text-yellow-400", children: /* @__PURE__ */ jsxRuntime.jsx("strong", { children: emptyMessage }) }) }) })
28118
+ )) : /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted text-muted-foreground rounded-lg p-4", children: /* @__PURE__ */ jsxRuntime.jsx("strong", { children: emptyMessage }) }) }) })
27893
28119
  ) : (
27894
28120
  // Grouped list - accordion style
27895
28121
  /* @__PURE__ */ jsxRuntime.jsx("ul", { className: "space-y-1", children: filteredGroups.length > 0 ? filteredGroups.map((group) => /* @__PURE__ */ jsxRuntime.jsx(
@@ -27904,7 +28130,7 @@ function ServicePicker({
27904
28130
  multiple
27905
28131
  },
27906
28132
  group.id
27907
- )) : /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-lg bg-yellow-50 p-4 text-yellow-700 dark:bg-yellow-900/20 dark:text-yellow-400", children: /* @__PURE__ */ jsxRuntime.jsx("strong", { children: emptyMessage }) }) }) })
28133
+ )) : /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-muted text-muted-foreground rounded-lg p-4", children: /* @__PURE__ */ jsxRuntime.jsx("strong", { children: emptyMessage }) }) }) })
27908
28134
  )
27909
28135
  ] })
27910
28136
  ]
@@ -27932,10 +28158,10 @@ function ServiceGroupItem({
27932
28158
  onClick: () => onToggleGroup(group.id),
27933
28159
  className: chunkOR5DRJCW_cjs.cn(
27934
28160
  "flex w-full items-center justify-between rounded-lg px-3 py-2",
27935
- "text-left text-sm font-medium",
27936
- "hover:bg-gray-100 dark:hover:bg-gray-800",
28161
+ "text-muted-foreground text-left text-sm font-medium",
28162
+ "hover:bg-muted",
27937
28163
  "transition-colors",
27938
- depth > 0 && "ml-4 text-gray-600 dark:text-gray-400"
28164
+ depth > 0 && "ml-4"
27939
28165
  ),
27940
28166
  "aria-expanded": isExpanded,
27941
28167
  children: [
@@ -27944,7 +28170,7 @@ function ServiceGroupItem({
27944
28170
  hasSelection && /* @__PURE__ */ jsxRuntime.jsx(
27945
28171
  "span",
27946
28172
  {
27947
- className: "bg-brand-500 h-2 w-2 rounded-full",
28173
+ className: "bg-primary h-2 w-2 rounded-full",
27948
28174
  "aria-label": "Has selected items"
27949
28175
  }
27950
28176
  )
@@ -27953,7 +28179,7 @@ function ServiceGroupItem({
27953
28179
  ChevronIcon2,
27954
28180
  {
27955
28181
  className: chunkOR5DRJCW_cjs.cn(
27956
- "h-5 w-5 transition-transform",
28182
+ "text-muted-foreground h-5 w-5 transition-transform",
27957
28183
  isExpanded && "rotate-180"
27958
28184
  )
27959
28185
  }
@@ -28000,42 +28226,62 @@ function ServiceItem({
28000
28226
  {
28001
28227
  className: chunkOR5DRJCW_cjs.cn(
28002
28228
  "flex cursor-pointer items-center gap-3 rounded-lg px-3 py-2",
28003
- "hover:bg-gray-100 dark:hover:bg-gray-800",
28229
+ "hover:bg-muted",
28004
28230
  "transition-colors",
28005
28231
  service.disabled && "cursor-not-allowed opacity-50"
28006
28232
  ),
28007
28233
  children: [
28008
- multiple ? /* @__PURE__ */ jsxRuntime.jsx(
28009
- "input",
28010
- {
28011
- type: "checkbox",
28012
- checked: selected,
28013
- onChange: onToggle,
28014
- disabled: service.disabled,
28015
- className: "text-brand-600 focus:ring-brand-500 h-4 w-4 rounded border-gray-300"
28016
- }
28017
- ) : /* @__PURE__ */ jsxRuntime.jsx(
28018
- "input",
28019
- {
28020
- type: "radio",
28021
- checked: selected,
28022
- onChange: onToggle,
28023
- disabled: service.disabled,
28024
- className: "text-brand-600 focus:ring-brand-500 h-4 w-4 border-gray-300"
28025
- }
28026
- ),
28234
+ multiple ? /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "relative inline-flex shrink-0 items-center justify-center", children: [
28235
+ /* @__PURE__ */ jsxRuntime.jsx(
28236
+ "input",
28237
+ {
28238
+ type: "checkbox",
28239
+ checked: selected,
28240
+ onChange: onToggle,
28241
+ disabled: service.disabled,
28242
+ className: chunkOR5DRJCW_cjs.cn(
28243
+ "peer h-4 w-4 shrink-0 appearance-none rounded",
28244
+ "border-input bg-background border-2",
28245
+ "cursor-pointer transition-all duration-150",
28246
+ "focus-visible:ring-ring focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none",
28247
+ "disabled:cursor-not-allowed disabled:opacity-50",
28248
+ "checked:bg-primary-500 checked:border-primary-500"
28249
+ )
28250
+ }
28251
+ ),
28252
+ /* @__PURE__ */ jsxRuntime.jsx(CheckIcon4, { className: "pointer-events-none absolute h-3 w-3 text-white opacity-0 transition-opacity peer-checked:opacity-100" })
28253
+ ] }) : /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "relative inline-flex shrink-0 items-center justify-center", children: [
28254
+ /* @__PURE__ */ jsxRuntime.jsx(
28255
+ "input",
28256
+ {
28257
+ type: "radio",
28258
+ checked: selected,
28259
+ onChange: onToggle,
28260
+ disabled: service.disabled,
28261
+ className: chunkOR5DRJCW_cjs.cn(
28262
+ "peer h-4 w-4 shrink-0 appearance-none rounded-full",
28263
+ "border-input bg-background border-2",
28264
+ "cursor-pointer transition-all duration-150",
28265
+ "focus-visible:ring-ring focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none",
28266
+ "disabled:cursor-not-allowed disabled:opacity-50",
28267
+ "checked:border-primary-500"
28268
+ )
28269
+ }
28270
+ ),
28271
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "bg-primary-500 pointer-events-none absolute h-2 w-2 scale-0 rounded-full transition-transform peer-checked:scale-100" })
28272
+ ] }),
28027
28273
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
28028
28274
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
28029
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-medium text-gray-900 dark:text-gray-100", children: service.name }),
28030
- service.code && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-xs text-gray-500 dark:text-gray-400", children: [
28275
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground text-sm font-medium", children: service.name }),
28276
+ service.code && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-muted-foreground text-xs", children: [
28031
28277
  "(",
28032
28278
  service.code,
28033
28279
  ")"
28034
28280
  ] })
28035
28281
  ] }),
28036
- service.description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "truncate text-xs text-gray-500 dark:text-gray-400", children: service.description })
28282
+ service.description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground truncate text-xs", children: service.description })
28037
28283
  ] }),
28038
- service.price !== void 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm font-medium text-gray-700 dark:text-gray-300", children: [
28284
+ service.price !== void 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-foreground text-sm font-medium", children: [
28039
28285
  "$",
28040
28286
  service.price.toFixed(2)
28041
28287
  ] })
@@ -28043,6 +28289,19 @@ function ServiceItem({
28043
28289
  }
28044
28290
  ) });
28045
28291
  }
28292
+ function CheckIcon4({ className }) {
28293
+ return /* @__PURE__ */ jsxRuntime.jsx(
28294
+ "svg",
28295
+ {
28296
+ className,
28297
+ fill: "none",
28298
+ viewBox: "0 0 24 24",
28299
+ stroke: "currentColor",
28300
+ strokeWidth: 3,
28301
+ children: /* @__PURE__ */ jsxRuntime.jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M5 13l4 4L19 7" })
28302
+ }
28303
+ );
28304
+ }
28046
28305
  function SearchIcon5({ className }) {
28047
28306
  return /* @__PURE__ */ jsxRuntime.jsx(
28048
28307
  "svg",
@@ -28512,7 +28771,7 @@ function ServiceShippingSettings({
28512
28771
  ] }),
28513
28772
  shippingEnabled && /* @__PURE__ */ jsxRuntime.jsxs(chunkHRA4FUO6_cjs.CardContent, { className: "space-y-6", children: [
28514
28773
  shippingMethods.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
28515
- chunkNL3CZNBH_cjs.Select,
28774
+ chunk5UUL5EEO_cjs.Select,
28516
28775
  {
28517
28776
  label: "Shipping Method",
28518
28777
  value: selectedMethodId || "",
@@ -28579,7 +28838,7 @@ function ServiceShippingSettings({
28579
28838
  }
28580
28839
  ) }),
28581
28840
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "col-span-1", children: /* @__PURE__ */ jsxRuntime.jsx(
28582
- chunkNL3CZNBH_cjs.Select,
28841
+ chunk5UUL5EEO_cjs.Select,
28583
28842
  {
28584
28843
  label: "State",
28585
28844
  value: address.state,
@@ -28688,10 +28947,10 @@ function SetupServiceModal({
28688
28947
  const isValid = formData.name.trim() && formData.price >= 0;
28689
28948
  return /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.Modal, { open, onOpenChange, size: "lg", children: /* @__PURE__ */ jsxRuntime.jsxs("form", { onSubmit: handleSubmit, children: [
28690
28949
  /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalTitle, { children: title }) }),
28691
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4", children: [
28950
+ /* @__PURE__ */ jsxRuntime.jsxs(chunkI7L6CQXR_cjs.ModalBody, { className: "min-w-[320px] space-y-4", children: [
28692
28951
  errorMessage && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-lg border border-red-200 bg-red-50 p-3 dark:border-red-800 dark:bg-red-900/20", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-red-600 dark:text-red-400", children: errorMessage }) }),
28693
28952
  showServicePicker && availableServices.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
28694
- chunkNL3CZNBH_cjs.Select,
28953
+ chunk5UUL5EEO_cjs.Select,
28695
28954
  {
28696
28955
  label: "Select Service",
28697
28956
  value: formData.serviceId || "",
@@ -28719,7 +28978,7 @@ function SetupServiceModal({
28719
28978
  "label",
28720
28979
  {
28721
28980
  htmlFor: "setup-service-description",
28722
- className: "mb-1 block text-sm font-medium text-gray-700 dark:text-gray-300",
28981
+ className: "text-foreground mb-1 block text-sm font-medium",
28723
28982
  children: "Description"
28724
28983
  }
28725
28984
  ),
@@ -28727,7 +28986,7 @@ function SetupServiceModal({
28727
28986
  "textarea",
28728
28987
  {
28729
28988
  id: "setup-service-description",
28730
- className: "w-full rounded-md border border-gray-300 px-3 py-2 shadow-sm focus:ring-2 focus:ring-blue-500 focus:outline-none dark:border-gray-600 dark:bg-gray-800 dark:text-white",
28989
+ className: "bg-background text-foreground border-input focus:ring-ring w-full rounded-md border px-3 py-2 shadow-sm focus:ring-2 focus:outline-none",
28731
28990
  rows: 3,
28732
28991
  value: formData.description,
28733
28992
  onChange: (e) => setFormData((prev) => ({
@@ -28739,7 +28998,7 @@ function SetupServiceModal({
28739
28998
  )
28740
28999
  ] }),
28741
29000
  categories.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
28742
- chunkNL3CZNBH_cjs.Select,
29001
+ chunk5UUL5EEO_cjs.Select,
28743
29002
  {
28744
29003
  label: "Category",
28745
29004
  value: formData.categoryId || "",
@@ -28756,12 +29015,12 @@ function SetupServiceModal({
28756
29015
  "label",
28757
29016
  {
28758
29017
  htmlFor: "setup-service-price",
28759
- className: "mb-1 block text-sm font-medium text-gray-700 dark:text-gray-300",
29018
+ className: "text-foreground mb-1 block text-sm font-medium",
28760
29019
  children: "Base Price"
28761
29020
  }
28762
29021
  ),
28763
29022
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
28764
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute top-1/2 left-3 -translate-y-1/2 text-gray-500", children: "$" }),
29023
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground absolute top-1/2 left-3 -translate-y-1/2", children: "$" }),
28765
29024
  /* @__PURE__ */ jsxRuntime.jsx(
28766
29025
  "input",
28767
29026
  {
@@ -28769,7 +29028,7 @@ function SetupServiceModal({
28769
29028
  type: "number",
28770
29029
  min: "0",
28771
29030
  step: "0.01",
28772
- className: "w-full rounded-md border border-gray-300 py-2 pr-4 pl-7 shadow-sm focus:ring-2 focus:ring-blue-500 focus:outline-none dark:border-gray-600 dark:bg-gray-800 dark:text-white",
29031
+ className: "bg-background text-foreground border-input focus:ring-ring w-full rounded-md border py-2 pr-4 pl-7 shadow-sm focus:ring-2 focus:outline-none",
28773
29032
  value: formData.price,
28774
29033
  onChange: (e) => setFormData((prev) => ({
28775
29034
  ...prev,
@@ -28782,14 +29041,15 @@ function SetupServiceModal({
28782
29041
  ] })
28783
29042
  ] }),
28784
29043
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3 pt-2", children: [
28785
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
28786
- /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
28787
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium text-gray-900 dark:text-white", children: "Currently Offered" }),
28788
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-gray-500 dark:text-gray-400", children: "Service is available for orders" })
29044
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-4", children: [
29045
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0", children: [
29046
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-foreground text-sm font-medium", children: "Currently Offered" }),
29047
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-xs", children: "Service is available for orders" })
28789
29048
  ] }),
28790
29049
  /* @__PURE__ */ jsxRuntime.jsx(
28791
29050
  chunkRRQGH7C5_cjs.Switch,
28792
29051
  {
29052
+ className: "flex-shrink-0",
28793
29053
  checked: formData.currentlyOffered,
28794
29054
  onCheckedChange: (checked) => setFormData((prev) => ({
28795
29055
  ...prev,
@@ -28798,14 +29058,15 @@ function SetupServiceModal({
28798
29058
  }
28799
29059
  )
28800
29060
  ] }),
28801
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
28802
- /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
28803
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium text-gray-900 dark:text-white", children: "Limited Inventory" }),
28804
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-gray-500 dark:text-gray-400", children: "Track inventory for this service" })
29061
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-4", children: [
29062
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0", children: [
29063
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-foreground text-sm font-medium", children: "Limited Inventory" }),
29064
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-xs", children: "Track inventory for this service" })
28805
29065
  ] }),
28806
29066
  /* @__PURE__ */ jsxRuntime.jsx(
28807
29067
  chunkRRQGH7C5_cjs.Switch,
28808
29068
  {
29069
+ className: "flex-shrink-0",
28809
29070
  checked: formData.limitedInventory,
28810
29071
  onCheckedChange: (checked) => setFormData((prev) => ({
28811
29072
  ...prev,
@@ -28814,7 +29075,7 @@ function SetupServiceModal({
28814
29075
  }
28815
29076
  )
28816
29077
  ] }),
28817
- formData.limitedInventory && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "ml-4 border-l-2 border-gray-200 pl-4 dark:border-gray-700", children: /* @__PURE__ */ jsxRuntime.jsx(
29078
+ formData.limitedInventory && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-border ml-4 border-l-2 pl-4", children: /* @__PURE__ */ jsxRuntime.jsx(
28818
29079
  chunkVV4N4WY6_cjs.Input,
28819
29080
  {
28820
29081
  label: "Initial Inventory",
@@ -28828,14 +29089,15 @@ function SetupServiceModal({
28828
29089
  placeholder: "Enter quantity"
28829
29090
  }
28830
29091
  ) }),
28831
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
28832
- /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
28833
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium text-gray-900 dark:text-white", children: "Auto-Accept Referrals" }),
28834
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-gray-500 dark:text-gray-400", children: "Automatically accept incoming referrals" })
29092
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-4", children: [
29093
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0", children: [
29094
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-foreground text-sm font-medium", children: "Auto-Accept Referrals" }),
29095
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground text-xs", children: "Automatically accept incoming referrals" })
28835
29096
  ] }),
28836
29097
  /* @__PURE__ */ jsxRuntime.jsx(
28837
29098
  chunkRRQGH7C5_cjs.Switch,
28838
29099
  {
29100
+ className: "flex-shrink-0",
28839
29101
  checked: formData.autoAcceptReferrals,
28840
29102
  onCheckedChange: (checked) => setFormData((prev) => ({
28841
29103
  ...prev,
@@ -30903,7 +31165,7 @@ function SSOConfigForm({
30903
31165
  ] })
30904
31166
  ] });
30905
31167
  }
30906
- function CheckIcon4({ className }) {
31168
+ function CheckIcon5({ className }) {
30907
31169
  return /* @__PURE__ */ jsxRuntime.jsx(
30908
31170
  "svg",
30909
31171
  {
@@ -30988,66 +31250,89 @@ function StepIndicator({
30988
31250
  if (allowCompletedStepsOnly) return index <= currentStep;
30989
31251
  return true;
30990
31252
  };
31253
+ const circleButton = (step, index, status, clickable) => /* @__PURE__ */ jsxRuntime.jsx(
31254
+ "button",
31255
+ {
31256
+ type: "button",
31257
+ onClick: () => handleStepClick(index),
31258
+ disabled: !clickable,
31259
+ className: `${sizes.circle} flex shrink-0 items-center justify-center rounded-full font-medium transition-all duration-200 focus:ring-2 focus:ring-offset-2 focus:outline-none dark:focus:ring-offset-neutral-900 ${clickable ? "cursor-pointer" : "cursor-default"} ${step.hasError ? "bg-red-100 text-red-600 focus:ring-red-500 dark:bg-red-900/30 dark:text-red-400" : status === "completed" ? "bg-primary-600 focus:ring-primary-500 dark:bg-primary-500 text-white" : status === "current" ? "bg-primary-600 ring-primary-600 focus:ring-primary-500 dark:bg-primary-500 dark:ring-primary-500 text-white ring-2 ring-offset-2 dark:ring-offset-neutral-900" : "bg-neutral-200 text-neutral-500 focus:ring-neutral-400 dark:bg-neutral-700 dark:text-neutral-300"}`.trim(),
31260
+ "aria-current": status === "current" ? "step" : void 0,
31261
+ children: step.hasError ? /* @__PURE__ */ jsxRuntime.jsx(ErrorIcon, { className: "h-4 w-4" }) : status === "completed" ? step.icon || /* @__PURE__ */ jsxRuntime.jsx(CheckIcon5, { className: "h-4 w-4" }) : step.icon || /* @__PURE__ */ jsxRuntime.jsx(
31262
+ "span",
31263
+ {
31264
+ className: status === "current" ? "text-white" : "text-neutral-500 dark:text-neutral-300",
31265
+ children: index + 1
31266
+ }
31267
+ )
31268
+ }
31269
+ );
31270
+ const stepLabel = (step, status, horizontal) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: `${horizontal ? "text-center" : "flex-1"} ${sizes.text}`, children: [
31271
+ /* @__PURE__ */ jsxRuntime.jsxs(
31272
+ "p",
31273
+ {
31274
+ className: `font-medium ${step.hasError ? "text-red-600 dark:text-red-400" : status === "completed" || status === "current" ? "text-neutral-900 dark:text-white" : "text-neutral-500 dark:text-neutral-400"}`.trim(),
31275
+ children: [
31276
+ step.label,
31277
+ step.optional && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "font-normal text-neutral-500 dark:text-neutral-400", children: [
31278
+ " ",
31279
+ "(optional)"
31280
+ ] })
31281
+ ]
31282
+ }
31283
+ ),
31284
+ step.description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-0.5 text-neutral-500 dark:text-neutral-400", children: step.description })
31285
+ ] });
31286
+ if (orientation === "horizontal") {
31287
+ return /* @__PURE__ */ jsxRuntime.jsx("nav", { className: `flex ${className}`.trim(), "aria-label": "Progress", children: steps.map((step, index) => {
31288
+ const status = getStepStatus(index);
31289
+ const isLast = index === steps.length - 1;
31290
+ const clickable = isClickable(index);
31291
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-1 flex-col items-center", children: [
31292
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex w-full items-center", children: [
31293
+ index > 0 ? /* @__PURE__ */ jsxRuntime.jsx(
31294
+ "div",
31295
+ {
31296
+ className: `flex-1 ${sizes.line} ${index <= currentStep ? "bg-primary-600 dark:bg-primary-500" : "bg-neutral-200 dark:bg-neutral-700"}`,
31297
+ "aria-hidden": "true"
31298
+ }
31299
+ ) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1" }),
31300
+ circleButton(step, index, status, clickable),
31301
+ !isLast ? /* @__PURE__ */ jsxRuntime.jsx(
31302
+ "div",
31303
+ {
31304
+ className: `flex-1 ${sizes.line} ${index < currentStep ? "bg-primary-600 dark:bg-primary-500" : "bg-neutral-200 dark:bg-neutral-700"}`,
31305
+ "aria-hidden": "true"
31306
+ }
31307
+ ) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1" })
31308
+ ] }),
31309
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-2", children: stepLabel(step, status, true) })
31310
+ ] }, step.id);
31311
+ }) });
31312
+ }
30991
31313
  return /* @__PURE__ */ jsxRuntime.jsx(
30992
31314
  "nav",
30993
31315
  {
30994
- className: ` ${orientation === "horizontal" ? "flex items-center" : "flex flex-col"} ${sizes.gap} ${className} `.trim(),
31316
+ className: `flex flex-col ${sizes.gap} ${className}`.trim(),
30995
31317
  "aria-label": "Progress",
30996
31318
  children: steps.map((step, index) => {
30997
31319
  const status = getStepStatus(index);
30998
31320
  const isLast = index === steps.length - 1;
30999
31321
  const clickable = isClickable(index);
31000
31322
  return /* @__PURE__ */ jsxRuntime.jsxs(React46__namespace.Fragment, { children: [
31001
- /* @__PURE__ */ jsxRuntime.jsxs(
31002
- "div",
31003
- {
31004
- className: `flex items-center ${orientation === "vertical" ? "flex-row" : "flex-col"} ${sizes.gap} `.trim(),
31005
- children: [
31006
- /* @__PURE__ */ jsxRuntime.jsx(
31007
- "button",
31008
- {
31009
- type: "button",
31010
- onClick: () => handleStepClick(index),
31011
- disabled: !clickable,
31012
- className: ` ${sizes.circle} flex items-center justify-center rounded-full font-medium transition-all duration-200 focus:ring-2 focus:ring-offset-2 focus:outline-none ${clickable ? "cursor-pointer" : "cursor-default"} ${step.hasError ? "bg-red-100 text-red-600 focus:ring-red-500 dark:bg-red-900/30 dark:text-red-400" : status === "completed" ? "bg-blue-600 text-white focus:ring-blue-500 dark:bg-blue-500" : status === "current" ? "bg-blue-600 text-white ring-2 ring-blue-600 ring-offset-2 focus:ring-blue-500 dark:bg-blue-500 dark:ring-blue-500" : "bg-gray-200 text-gray-500 focus:ring-gray-400 dark:bg-gray-700 dark:text-gray-400"} `.trim(),
31013
- "aria-current": status === "current" ? "step" : void 0,
31014
- children: step.hasError ? /* @__PURE__ */ jsxRuntime.jsx(ErrorIcon, { className: "h-4 w-4" }) : status === "completed" ? step.icon || /* @__PURE__ */ jsxRuntime.jsx(CheckIcon4, { className: "h-4 w-4" }) : step.icon || /* @__PURE__ */ jsxRuntime.jsx("span", { children: index + 1 })
31015
- }
31016
- ),
31017
- /* @__PURE__ */ jsxRuntime.jsxs(
31018
- "div",
31019
- {
31020
- className: ` ${orientation === "horizontal" ? "text-center" : "flex-1"} ${sizes.text} `.trim(),
31021
- children: [
31022
- /* @__PURE__ */ jsxRuntime.jsxs(
31023
- "p",
31024
- {
31025
- className: `font-medium ${step.hasError ? "text-red-600 dark:text-red-400" : status === "completed" || status === "current" ? "text-gray-900 dark:text-white" : "text-gray-500 dark:text-gray-400"} `.trim(),
31026
- children: [
31027
- step.label,
31028
- step.optional && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "font-normal text-gray-500 dark:text-gray-400", children: [
31029
- " ",
31030
- "(optional)"
31031
- ] })
31032
- ]
31033
- }
31034
- ),
31035
- step.description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-0.5 text-gray-500 dark:text-gray-400", children: step.description })
31036
- ]
31037
- }
31038
- )
31039
- ]
31040
- }
31041
- ),
31323
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: `flex flex-row items-center ${sizes.gap}`, children: [
31324
+ circleButton(step, index, status, clickable),
31325
+ stepLabel(step, status, false)
31326
+ ] }),
31042
31327
  !isLast && /* @__PURE__ */ jsxRuntime.jsx(
31043
31328
  "div",
31044
31329
  {
31045
- className: ` ${orientation === "horizontal" ? "min-w-8 flex-1" : "ml-4 min-h-4"} flex items-center justify-center`.trim(),
31330
+ className: `flex min-h-4 justify-center ${size === "sm" ? "w-6" : size === "lg" ? "w-10" : "w-8"}`,
31046
31331
  "aria-hidden": "true",
31047
31332
  children: /* @__PURE__ */ jsxRuntime.jsx(
31048
31333
  "div",
31049
31334
  {
31050
- className: ` ${orientation === "horizontal" ? "w-full" : "h-full min-h-4"} ${sizes.line} ${index < currentStep ? "bg-blue-600 dark:bg-blue-500" : "bg-gray-200 dark:bg-gray-700"} `.trim()
31335
+ className: `h-full min-h-4 ${sizes.line} ${index < currentStep ? "bg-primary-600 dark:bg-primary-500" : "bg-neutral-200 dark:bg-neutral-700"}`
31051
31336
  }
31052
31337
  )
31053
31338
  }
@@ -31191,11 +31476,68 @@ function TimelineProgress({
31191
31476
  steps,
31192
31477
  currentStep,
31193
31478
  showTimestamps = true,
31479
+ size = "md",
31480
+ pulse = true,
31194
31481
  className
31195
31482
  }) {
31196
31483
  const visibleSteps = steps.filter((step) => !step.hidden);
31197
31484
  const currentIndex = visibleSteps.findIndex((s) => s.key === currentStep);
31198
- const getStepState = (index) => {
31485
+ const sizeConfig = {
31486
+ sm: {
31487
+ wrapper: "h-6 w-6",
31488
+ completed: "h-5 w-5",
31489
+ current: "h-6 w-6",
31490
+ pending: "h-5 w-5",
31491
+ error: "h-6 w-6",
31492
+ checkIcon: "h-3 w-3",
31493
+ xIcon: "h-3.5 w-3.5",
31494
+ currentDot: "h-1.5 w-1.5",
31495
+ pendingDot: "h-1.5 w-1.5",
31496
+ connector: "h-px",
31497
+ timestamp: "text-[10px]",
31498
+ label: "text-[10px]",
31499
+ padding: "py-2",
31500
+ labelMargin: "mt-1.5",
31501
+ timestampMargin: "mb-1"
31502
+ },
31503
+ md: {
31504
+ wrapper: "h-10 w-10",
31505
+ completed: "h-8 w-8",
31506
+ current: "h-10 w-10",
31507
+ pending: "h-8 w-8",
31508
+ error: "h-10 w-10",
31509
+ checkIcon: "h-4 w-4",
31510
+ xIcon: "h-5 w-5",
31511
+ currentDot: "h-2.5 w-2.5",
31512
+ pendingDot: "h-2 w-2",
31513
+ connector: "h-0.5",
31514
+ timestamp: "text-xs",
31515
+ label: "text-xs",
31516
+ padding: "py-4",
31517
+ labelMargin: "mt-2.5",
31518
+ timestampMargin: "mb-2"
31519
+ },
31520
+ lg: {
31521
+ wrapper: "h-14 w-14",
31522
+ completed: "h-11 w-11",
31523
+ current: "h-14 w-14",
31524
+ pending: "h-11 w-11",
31525
+ error: "h-14 w-14",
31526
+ checkIcon: "h-5 w-5",
31527
+ xIcon: "h-6 w-6",
31528
+ currentDot: "h-3.5 w-3.5",
31529
+ pendingDot: "h-2.5 w-2.5",
31530
+ connector: "h-1",
31531
+ timestamp: "text-sm",
31532
+ label: "text-sm",
31533
+ padding: "py-6",
31534
+ labelMargin: "mt-3",
31535
+ timestampMargin: "mb-3"
31536
+ }
31537
+ };
31538
+ const sizes = sizeConfig[size];
31539
+ const getStepState = (index, step) => {
31540
+ if (step.error) return "error";
31199
31541
  if (index < currentIndex) return "completed";
31200
31542
  if (index === currentIndex) return "current";
31201
31543
  return "pending";
@@ -31207,77 +31549,123 @@ function TimelineProgress({
31207
31549
  return /* @__PURE__ */ jsxRuntime.jsx(
31208
31550
  "div",
31209
31551
  {
31210
- className: chunkOR5DRJCW_cjs.cn("flex items-start overflow-x-auto py-4", className),
31552
+ className: chunkOR5DRJCW_cjs.cn(sizes.padding, "overflow-x-auto", className),
31211
31553
  role: "progressbar",
31212
31554
  "aria-valuenow": currentIndex + 1,
31213
31555
  "aria-valuemin": 1,
31214
31556
  "aria-valuemax": visibleSteps.length,
31215
- children: visibleSteps.map((step, index) => {
31216
- const state = getStepState(index);
31557
+ children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative flex items-start", children: visibleSteps.map((step, index) => {
31558
+ const state = getStepState(index, step);
31217
31559
  const isLast = index === visibleSteps.length - 1;
31218
- return /* @__PURE__ */ jsxRuntime.jsxs(
31219
- "div",
31220
- {
31221
- className: chunkOR5DRJCW_cjs.cn(
31222
- "flex flex-1 flex-col items-center",
31223
- !isLast && "mr-2"
31560
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-1 flex-col items-center", children: [
31561
+ showTimestamps && /* @__PURE__ */ jsxRuntime.jsx(
31562
+ "div",
31563
+ {
31564
+ className: chunkOR5DRJCW_cjs.cn(
31565
+ "h-4 text-center text-neutral-500 dark:text-neutral-400",
31566
+ sizes.timestamp,
31567
+ sizes.timestampMargin
31568
+ ),
31569
+ children: step.completedAt ? formatTimestamp(step.completedAt) : "\xA0"
31570
+ }
31571
+ ),
31572
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative flex w-full items-center", children: [
31573
+ index > 0 && /* @__PURE__ */ jsxRuntime.jsx(
31574
+ "div",
31575
+ {
31576
+ className: chunkOR5DRJCW_cjs.cn(
31577
+ "flex-1",
31578
+ sizes.connector,
31579
+ state === "completed" || state === "current" || state === "error" ? "bg-primary-600 dark:bg-primary-500" : "bg-neutral-200 dark:bg-neutral-700"
31580
+ )
31581
+ }
31224
31582
  ),
31225
- children: [
31226
- showTimestamps && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mb-1 h-5 text-center text-xs text-gray-500", children: step.completedAt ? formatTimestamp(step.completedAt) : "\xA0" }),
31227
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex w-full items-center", children: [
31228
- /* @__PURE__ */ jsxRuntime.jsx(
31229
- "div",
31230
- {
31231
- className: chunkOR5DRJCW_cjs.cn(
31232
- "h-1 flex-1",
31233
- index === 0 ? "bg-transparent" : "",
31234
- state === "completed" || state === "current" && index > 0 ? "bg-brand-500" : "bg-gray-200 dark:bg-gray-700"
31235
- )
31236
- }
31583
+ index === 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1" }),
31584
+ /* @__PURE__ */ jsxRuntime.jsx(
31585
+ "div",
31586
+ {
31587
+ className: chunkOR5DRJCW_cjs.cn(
31588
+ "flex shrink-0 items-center justify-center",
31589
+ sizes.wrapper
31237
31590
  ),
31238
- /* @__PURE__ */ jsxRuntime.jsxs(
31591
+ children: /* @__PURE__ */ jsxRuntime.jsxs(
31239
31592
  "div",
31240
31593
  {
31241
31594
  className: chunkOR5DRJCW_cjs.cn(
31242
- "relative z-10 flex h-6 w-6 shrink-0 items-center justify-center rounded-full border-2",
31243
- state === "completed" && "border-brand-500 bg-brand-500 text-white",
31244
- state === "current" && "border-brand-500 bg-white dark:bg-gray-900",
31245
- state === "pending" && "border-gray-300 bg-white dark:border-gray-600 dark:bg-gray-900"
31595
+ "relative z-10 flex items-center justify-center rounded-full transition-all duration-200",
31596
+ state === "completed" && chunkOR5DRJCW_cjs.cn(
31597
+ "bg-primary-100 text-primary-600 ring-primary-200 dark:bg-primary-900/40 dark:text-primary-400 dark:ring-primary-800 ring-2",
31598
+ sizes.completed
31599
+ ),
31600
+ state === "current" && chunkOR5DRJCW_cjs.cn(
31601
+ "bg-primary-500 shadow-primary-500/30 ring-primary-100 dark:bg-primary-500 dark:ring-primary-900/50 text-white shadow-md ring-4",
31602
+ sizes.current,
31603
+ pulse && "animate-pulse"
31604
+ ),
31605
+ state === "pending" && chunkOR5DRJCW_cjs.cn(
31606
+ "bg-neutral-100 text-neutral-400 ring-2 ring-neutral-200 dark:bg-neutral-800 dark:text-neutral-500 dark:ring-neutral-700",
31607
+ sizes.pending
31608
+ ),
31609
+ state === "error" && chunkOR5DRJCW_cjs.cn(
31610
+ "bg-red-500 text-white shadow-md ring-4 shadow-red-500/30 ring-red-100 dark:bg-red-500 dark:ring-red-900/50",
31611
+ sizes.error
31612
+ )
31246
31613
  ),
31247
31614
  children: [
31248
- state === "completed" && /* @__PURE__ */ jsxRuntime.jsx(CheckIcon5, { className: "h-3 w-3" }),
31249
- state === "current" && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "bg-brand-500 h-2 w-2 rounded-full" })
31615
+ state === "completed" && /* @__PURE__ */ jsxRuntime.jsx(CheckIcon6, { className: sizes.checkIcon }),
31616
+ state === "current" && /* @__PURE__ */ jsxRuntime.jsx(
31617
+ "div",
31618
+ {
31619
+ className: chunkOR5DRJCW_cjs.cn(
31620
+ "rounded-full bg-white",
31621
+ sizes.currentDot
31622
+ )
31623
+ }
31624
+ ),
31625
+ state === "pending" && /* @__PURE__ */ jsxRuntime.jsx(
31626
+ "div",
31627
+ {
31628
+ className: chunkOR5DRJCW_cjs.cn(
31629
+ "rounded-full bg-neutral-300 dark:bg-neutral-600",
31630
+ sizes.pendingDot
31631
+ )
31632
+ }
31633
+ ),
31634
+ state === "error" && /* @__PURE__ */ jsxRuntime.jsx(XIcon4, { className: sizes.xIcon })
31250
31635
  ]
31251
31636
  }
31252
- ),
31253
- /* @__PURE__ */ jsxRuntime.jsx(
31254
- "div",
31255
- {
31256
- className: chunkOR5DRJCW_cjs.cn(
31257
- "h-1 flex-1",
31258
- isLast ? "bg-transparent" : "",
31259
- state === "completed" ? "bg-brand-500" : "bg-gray-200 dark:bg-gray-700"
31260
- )
31261
- }
31262
31637
  )
31263
- ] }),
31264
- /* @__PURE__ */ jsxRuntime.jsx(
31265
- "div",
31266
- {
31267
- className: chunkOR5DRJCW_cjs.cn(
31268
- "mt-2 text-center text-xs font-medium capitalize",
31269
- state === "completed" && "text-brand-600 dark:text-brand-400",
31270
- state === "current" && "text-gray-900 dark:text-gray-100",
31271
- state === "pending" && "text-gray-400 dark:text-gray-500"
31272
- ),
31273
- children: step.label
31274
- }
31275
- )
31276
- ]
31277
- },
31278
- step.key
31279
- );
31280
- })
31638
+ }
31639
+ ),
31640
+ !isLast && /* @__PURE__ */ jsxRuntime.jsx(
31641
+ "div",
31642
+ {
31643
+ className: chunkOR5DRJCW_cjs.cn(
31644
+ "flex-1",
31645
+ sizes.connector,
31646
+ state === "completed" ? "bg-primary-600 dark:bg-primary-500" : "bg-neutral-200 dark:bg-neutral-700"
31647
+ )
31648
+ }
31649
+ ),
31650
+ isLast && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1" })
31651
+ ] }),
31652
+ /* @__PURE__ */ jsxRuntime.jsx(
31653
+ "div",
31654
+ {
31655
+ className: chunkOR5DRJCW_cjs.cn(
31656
+ "text-center font-medium capitalize",
31657
+ sizes.label,
31658
+ sizes.labelMargin,
31659
+ state === "completed" && "text-primary-700 dark:text-primary-300",
31660
+ state === "current" && "font-semibold text-neutral-900 dark:text-white",
31661
+ state === "pending" && "text-neutral-400 dark:text-neutral-500",
31662
+ state === "error" && "font-semibold text-red-600 dark:text-red-400"
31663
+ ),
31664
+ children: step.label
31665
+ }
31666
+ )
31667
+ ] }, step.key);
31668
+ }) })
31281
31669
  }
31282
31670
  );
31283
31671
  }
@@ -31326,48 +31714,56 @@ function TimelineEventList({
31326
31714
  const getEventColor = (type) => {
31327
31715
  switch (type) {
31328
31716
  case "message":
31329
- return "bg-blue-100 text-blue-600 dark:bg-blue-900/30 dark:text-blue-400";
31717
+ return "bg-blue-50 text-blue-500 ring-blue-100 dark:bg-blue-900/20 dark:text-blue-400 dark:ring-blue-800/40";
31330
31718
  case "status":
31331
- return "bg-green-100 text-green-600 dark:bg-green-900/30 dark:text-green-400";
31719
+ return "bg-green-50 text-green-500 ring-green-100 dark:bg-green-900/20 dark:text-green-400 dark:ring-green-800/40";
31332
31720
  case "attachment":
31333
- return "bg-purple-100 text-purple-600 dark:bg-purple-900/30 dark:text-purple-400";
31721
+ return "bg-purple-50 text-purple-500 ring-purple-100 dark:bg-purple-900/20 dark:text-purple-400 dark:ring-purple-800/40";
31334
31722
  case "assignment":
31335
- return "bg-orange-100 text-orange-600 dark:bg-orange-900/30 dark:text-orange-400";
31723
+ return "bg-orange-50 text-orange-500 ring-orange-100 dark:bg-orange-900/20 dark:text-orange-400 dark:ring-orange-800/40";
31336
31724
  case "note":
31337
- return "bg-gray-100 text-gray-600 dark:bg-gray-800 dark:text-gray-400";
31725
+ return "bg-neutral-50 text-neutral-500 ring-neutral-100 dark:bg-neutral-800/50 dark:text-neutral-400 dark:ring-neutral-700/40";
31338
31726
  default:
31339
- return "bg-gray-100 text-gray-600 dark:bg-gray-800 dark:text-gray-400";
31727
+ return "bg-neutral-50 text-neutral-500 ring-neutral-100 dark:bg-neutral-800/50 dark:text-neutral-400 dark:ring-neutral-700/40";
31340
31728
  }
31341
31729
  };
31342
31730
  if (events.length === 0) {
31343
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: chunkOR5DRJCW_cjs.cn("py-8 text-center text-gray-500", className), children: "No activity yet." });
31731
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: chunkOR5DRJCW_cjs.cn("py-8 text-center text-neutral-500", className), children: "No activity yet." });
31344
31732
  }
31345
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: chunkOR5DRJCW_cjs.cn("space-y-4", className), children: events.map((event, index) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative flex gap-4", children: [
31346
- index < events.length - 1 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute top-10 left-5 h-full w-px bg-gray-200 dark:bg-gray-700" }),
31347
- /* @__PURE__ */ jsxRuntime.jsx(
31733
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: chunkOR5DRJCW_cjs.cn("relative", className), children: [
31734
+ events.length > 1 && /* @__PURE__ */ jsxRuntime.jsx(
31348
31735
  "div",
31349
31736
  {
31350
- className: chunkOR5DRJCW_cjs.cn(
31351
- "relative z-10 flex h-10 w-10 shrink-0 items-center justify-center rounded-full",
31352
- getEventColor(event.type)
31353
- ),
31354
- children: getEventIcon(event.type)
31737
+ className: "absolute top-0 bottom-0 left-5 w-px bg-neutral-200 dark:bg-neutral-700",
31738
+ "aria-hidden": "true"
31355
31739
  }
31356
31740
  ),
31357
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 pt-1", children: [
31358
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-2", children: [
31359
- /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
31360
- /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-medium text-gray-900 dark:text-gray-100", children: event.title }),
31361
- event.author && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-sm text-gray-500 dark:text-gray-400", children: [
31362
- "by ",
31363
- event.author
31364
- ] })
31741
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-6", children: events.map((event) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative flex gap-4", children: [
31742
+ /* @__PURE__ */ jsxRuntime.jsx(
31743
+ "div",
31744
+ {
31745
+ className: chunkOR5DRJCW_cjs.cn(
31746
+ "relative z-10 flex h-10 w-10 shrink-0 items-center justify-center rounded-full ring-2",
31747
+ getEventColor(event.type)
31748
+ ),
31749
+ children: getEventIcon(event.type)
31750
+ }
31751
+ ),
31752
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 pt-0.5", children: [
31753
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-2", children: [
31754
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
31755
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-neutral-900 dark:text-neutral-100", children: event.title }),
31756
+ event.author && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-sm text-neutral-500 dark:text-neutral-400", children: [
31757
+ "by ",
31758
+ event.author
31759
+ ] })
31760
+ ] }),
31761
+ /* @__PURE__ */ jsxRuntime.jsx("time", { className: "shrink-0 pt-0.5 text-xs text-neutral-400 dark:text-neutral-500", children: formatTime4(event.timestamp) })
31365
31762
  ] }),
31366
- /* @__PURE__ */ jsxRuntime.jsx("time", { className: "shrink-0 text-xs text-gray-400 dark:text-gray-500", children: formatTime4(event.timestamp) })
31367
- ] }),
31368
- event.content && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-2 text-sm text-gray-600 dark:text-gray-300", children: event.content })
31369
- ] })
31370
- ] }, event.id)) });
31763
+ event.content && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-1.5 text-sm text-neutral-600 dark:text-neutral-300", children: event.content })
31764
+ ] })
31765
+ ] }, event.id)) })
31766
+ ] });
31371
31767
  }
31372
31768
  TimelineEventList.displayName = "TimelineEventList";
31373
31769
  function OrderConfirmation({
@@ -31388,21 +31784,21 @@ function OrderConfirmation({
31388
31784
  role: "dialog",
31389
31785
  "aria-modal": "true",
31390
31786
  "aria-labelledby": "order-confirmation-title",
31391
- children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full max-w-md rounded-xl bg-white p-6 shadow-xl dark:bg-gray-800", children: [
31787
+ children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full max-w-md rounded-xl bg-white p-6 shadow-xl dark:bg-neutral-800", children: [
31392
31788
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mb-6 flex justify-center", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex h-20 w-20 items-center justify-center rounded-full bg-green-100 dark:bg-green-900/30", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "animate-bounce", children: /* @__PURE__ */ jsxRuntime.jsx(PlaneIcon, { className: "h-10 w-10 text-green-600 dark:text-green-400" }) }) }) }),
31393
31789
  /* @__PURE__ */ jsxRuntime.jsx(
31394
31790
  "h2",
31395
31791
  {
31396
31792
  id: "order-confirmation-title",
31397
- className: "mb-2 text-center text-2xl font-bold text-gray-900 dark:text-gray-100",
31793
+ className: "mb-2 text-center text-2xl font-bold text-neutral-900 dark:text-neutral-100",
31398
31794
  children: "Order Submitted!"
31399
31795
  }
31400
31796
  ),
31401
- orderNumber && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "mb-4 text-center text-sm text-gray-500 dark:text-gray-400", children: [
31797
+ orderNumber && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "mb-4 text-center text-sm text-neutral-500 dark:text-neutral-400", children: [
31402
31798
  "Order #",
31403
31799
  orderNumber
31404
31800
  ] }),
31405
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mb-6 text-center text-gray-600 dark:text-gray-300", children: message }),
31801
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mb-6 text-center text-neutral-600 dark:text-neutral-300", children: message }),
31406
31802
  /* @__PURE__ */ jsxRuntime.jsx(
31407
31803
  "button",
31408
31804
  {
@@ -31410,8 +31806,8 @@ function OrderConfirmation({
31410
31806
  onClick: onClose,
31411
31807
  className: chunkOR5DRJCW_cjs.cn(
31412
31808
  "w-full rounded-lg px-4 py-3 font-medium",
31413
- "bg-brand-600 hover:bg-brand-700 text-white",
31414
- "dark:bg-brand-500 dark:hover:bg-brand-600",
31809
+ "bg-primary-600 hover:bg-primary-700 text-white",
31810
+ "dark:bg-primary-500 dark:hover:bg-primary-600",
31415
31811
  "transition-colors"
31416
31812
  ),
31417
31813
  children: "Got It"
@@ -31422,7 +31818,7 @@ function OrderConfirmation({
31422
31818
  );
31423
31819
  }
31424
31820
  OrderConfirmation.displayName = "OrderConfirmation";
31425
- function CheckIcon5({ className }) {
31821
+ function CheckIcon6({ className }) {
31426
31822
  return /* @__PURE__ */ jsxRuntime.jsx(
31427
31823
  "svg",
31428
31824
  {
@@ -31442,6 +31838,26 @@ function CheckIcon5({ className }) {
31442
31838
  }
31443
31839
  );
31444
31840
  }
31841
+ function XIcon4({ className }) {
31842
+ return /* @__PURE__ */ jsxRuntime.jsx(
31843
+ "svg",
31844
+ {
31845
+ className,
31846
+ fill: "none",
31847
+ viewBox: "0 0 24 24",
31848
+ stroke: "currentColor",
31849
+ strokeWidth: 3,
31850
+ children: /* @__PURE__ */ jsxRuntime.jsx(
31851
+ "path",
31852
+ {
31853
+ strokeLinecap: "round",
31854
+ strokeLinejoin: "round",
31855
+ d: "M6 18L18 6M6 6l12 12"
31856
+ }
31857
+ )
31858
+ }
31859
+ );
31860
+ }
31445
31861
  function MessageIcon({ className }) {
31446
31862
  return /* @__PURE__ */ jsxRuntime.jsx(
31447
31863
  "svg",
@@ -31562,7 +31978,7 @@ function PlaneIcon({ className }) {
31562
31978
  }
31563
31979
  );
31564
31980
  }
31565
- var CheckIcon6 = () => /* @__PURE__ */ jsxRuntime.jsx(
31981
+ var CheckIcon7 = () => /* @__PURE__ */ jsxRuntime.jsx(
31566
31982
  "svg",
31567
31983
  {
31568
31984
  className: "h-5 w-5",
@@ -31627,7 +32043,7 @@ var InfoIcon = () => /* @__PURE__ */ jsxRuntime.jsx(
31627
32043
  )
31628
32044
  }
31629
32045
  );
31630
- var XIcon4 = () => /* @__PURE__ */ jsxRuntime.jsx(
32046
+ var XIcon5 = () => /* @__PURE__ */ jsxRuntime.jsx(
31631
32047
  "svg",
31632
32048
  {
31633
32049
  className: "h-4 w-4",
@@ -31664,7 +32080,7 @@ var variantStyles = {
31664
32080
  }
31665
32081
  };
31666
32082
  var defaultIcons = {
31667
- success: /* @__PURE__ */ jsxRuntime.jsx(CheckIcon6, {}),
32083
+ success: /* @__PURE__ */ jsxRuntime.jsx(CheckIcon7, {}),
31668
32084
  error: /* @__PURE__ */ jsxRuntime.jsx(XCircleIcon, {}),
31669
32085
  warning: /* @__PURE__ */ jsxRuntime.jsx(ExclamationIcon, {}),
31670
32086
  info: /* @__PURE__ */ jsxRuntime.jsx(InfoIcon, {})
@@ -31710,7 +32126,7 @@ function Toast({
31710
32126
  onClick: onClose,
31711
32127
  className: "flex-shrink-0 rounded p-1 transition-colors hover:bg-black/10 focus:ring-2 focus:ring-current focus:outline-none dark:hover:bg-white/10",
31712
32128
  "aria-label": "Dismiss notification",
31713
- children: /* @__PURE__ */ jsxRuntime.jsx(XIcon4, {})
32129
+ children: /* @__PURE__ */ jsxRuntime.jsx(XIcon5, {})
31714
32130
  }
31715
32131
  )
31716
32132
  ]
@@ -31864,6 +32280,7 @@ function WebChartReportViewer({
31864
32280
  onDateRangeChange,
31865
32281
  webchartBrand: webchartBrand2 = { name: "Enterprise Health" },
31866
32282
  onReconnect,
32283
+ columnRenderers,
31867
32284
  className,
31868
32285
  labels = {}
31869
32286
  }) {
@@ -31873,17 +32290,16 @@ function WebChartReportViewer({
31873
32290
  reconnect = "Reconnect",
31874
32291
  noReports = "No reports available",
31875
32292
  loadingData = "Fetching latest data from Enterprise Health...",
31876
- close = "Close",
31877
32293
  dateFrom = "From",
31878
32294
  dateTo = "To"
31879
32295
  } = labels;
31880
- const [offcanvasOpen, setOffcanvasOpen] = React46__namespace.useState(false);
32296
+ const [modalOpen, setModalOpen] = React46__namespace.useState(false);
31881
32297
  const handleReportClick = (report) => {
31882
32298
  onReportSelect?.(report);
31883
- setOffcanvasOpen(true);
32299
+ setModalOpen(true);
31884
32300
  };
31885
32301
  const handleClose = () => {
31886
- setOffcanvasOpen(false);
32302
+ setModalOpen(false);
31887
32303
  onClose?.();
31888
32304
  };
31889
32305
  const formatDate4 = (date) => {
@@ -31891,144 +32307,153 @@ function WebChartReportViewer({
31891
32307
  return d.toISOString().split("T")[0];
31892
32308
  };
31893
32309
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: chunkOR5DRJCW_cjs.cn("webchart-report-viewer", className), children: [
31894
- error && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mb-4 rounded-lg border border-yellow-300 bg-yellow-50 p-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-2", children: [
31895
- /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-exclamation-triangle mt-0.5 text-yellow-600" }),
31896
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1", children: [
31897
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-medium text-yellow-800", children: error }),
31898
- /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "mt-1 text-sm text-yellow-700", children: [
31899
- "If this error persists, you can try reconnecting",
31900
- " ",
31901
- webchartBrand2.name,
31902
- "."
31903
- ] }),
32310
+ error && /* @__PURE__ */ jsxRuntime.jsxs(chunkIY7UQPDO_cjs.Alert, { variant: "warning", icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.AlertTriangle, {}), className: "mb-4", children: [
32311
+ /* @__PURE__ */ jsxRuntime.jsx(chunkIY7UQPDO_cjs.AlertTitle, { children: error }),
32312
+ /* @__PURE__ */ jsxRuntime.jsxs(chunkIY7UQPDO_cjs.AlertDescription, { children: [
32313
+ "If this error persists, you can try reconnecting",
32314
+ " ",
32315
+ webchartBrand2.name,
32316
+ ".",
31904
32317
  onReconnect && /* @__PURE__ */ jsxRuntime.jsxs(
31905
- "button",
32318
+ chunkMKJDBXX4_cjs.Button,
31906
32319
  {
31907
- type: "button",
32320
+ variant: "secondary",
32321
+ size: "sm",
31908
32322
  onClick: onReconnect,
31909
- className: "mt-2 rounded-lg border border-gray-300 bg-white px-4 py-2 text-gray-700 hover:bg-gray-50",
32323
+ className: "mt-2",
31910
32324
  children: [
31911
- /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-link mr-2" }),
32325
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Link, { className: "mr-2 h-4 w-4" }),
31912
32326
  reconnect
31913
32327
  ]
31914
32328
  }
31915
32329
  )
31916
32330
  ] })
31917
- ] }) }),
31918
- !error && !loading && /* @__PURE__ */ jsxRuntime.jsxs(
31919
- "button",
31920
- {
31921
- type: "button",
31922
- onClick: onRefreshReports,
31923
- className: "bg-primary hover:bg-primary/90 mb-4 rounded-lg px-4 py-2 text-white",
31924
- title: refreshReports,
31925
- children: [
31926
- /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-sync-alt mr-2" }),
31927
- refreshReports
31928
- ]
31929
- }
31930
- ),
32331
+ ] }),
32332
+ !error && !loading && /* @__PURE__ */ jsxRuntime.jsxs(chunkMKJDBXX4_cjs.Button, { onClick: onRefreshReports, className: "mb-4", children: [
32333
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.RefreshCw, { className: "mr-2 h-4 w-4" }),
32334
+ refreshReports
32335
+ ] }),
31931
32336
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-4 grid grid-cols-1 gap-4 md:grid-cols-2 lg:grid-cols-3", children: loading ? (
31932
32337
  // Loading placeholders
31933
- /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: [1, 2, 3, 4, 5, 6].map((i) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "animate-pulse", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-12 rounded-lg bg-gray-200" }) }, i)) })
32338
+ /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: [1, 2, 3, 4, 5, 6].map((i) => /* @__PURE__ */ jsxRuntime.jsx(chunkN3QTYHRZ_cjs.Skeleton, { variant: "button", className: "h-12 w-full" }, i)) })
31934
32339
  ) : reports.length > 0 ? (
31935
32340
  // Report buttons
31936
32341
  reports.map((report) => /* @__PURE__ */ jsxRuntime.jsx(
31937
- "button",
32342
+ chunkHRA4FUO6_cjs.Card,
31938
32343
  {
31939
- type: "button",
32344
+ interactive: true,
32345
+ padding: "none",
32346
+ role: "button",
32347
+ tabIndex: 0,
32348
+ "aria-label": report.description ? `${report.name}: ${report.description}` : report.name,
31940
32349
  onClick: () => handleReportClick(report),
31941
- className: "border-primary text-primary hover:bg-primary w-full truncate rounded-lg border bg-white p-3 text-left hover:text-white",
31942
- title: report.description ? `${report.name}: ${report.description}` : report.name,
31943
- children: report.name
32350
+ onKeyDown: (e) => {
32351
+ if (e.key === "Enter" || e.key === " ") {
32352
+ e.preventDefault();
32353
+ handleReportClick(report);
32354
+ }
32355
+ },
32356
+ className: "cursor-pointer",
32357
+ children: /* @__PURE__ */ jsxRuntime.jsx(chunkHRA4FUO6_cjs.CardContent, { className: "p-3", children: /* @__PURE__ */ jsxRuntime.jsx(
32358
+ "span",
32359
+ {
32360
+ className: "block truncate text-sm font-medium",
32361
+ title: report.description ? `${report.name}: ${report.description}` : report.name,
32362
+ children: report.name
32363
+ }
32364
+ ) })
31944
32365
  },
31945
32366
  report.id
31946
32367
  ))
31947
32368
  ) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-muted-foreground col-span-full py-8 text-center", children: noReports }) }),
31948
- offcanvasOpen && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "fixed inset-0 z-50 flex", children: [
31949
- /* @__PURE__ */ jsxRuntime.jsx(
31950
- "div",
31951
- {
31952
- role: "button",
31953
- tabIndex: 0,
31954
- "aria-label": "Close panel",
31955
- className: "fixed inset-0 bg-black/50",
31956
- onClick: handleClose,
31957
- onKeyDown: (e) => e.key === "Enter" && handleClose()
31958
- }
31959
- ),
31960
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "fixed right-0 bottom-0 left-0 flex h-3/4 flex-col rounded-t-xl bg-white shadow-xl", children: [
31961
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between border-b p-4", children: [
31962
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3", children: [
31963
- /* @__PURE__ */ jsxRuntime.jsx("h5", { className: "text-lg font-semibold", children: currentReport?.name || "Report Results" }),
31964
- reportResult?.error ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-yellow-500", title: reportResult.error, children: /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-exclamation-triangle" }) }) : reportResult?.success ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-green-500", children: /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-check-circle" }) }) : null
31965
- ] }),
31966
- /* @__PURE__ */ jsxRuntime.jsx(
31967
- "button",
31968
- {
31969
- type: "button",
31970
- onClick: handleClose,
31971
- className: "text-2xl text-gray-400 hover:text-gray-600",
31972
- "aria-label": close,
31973
- children: "\xD7"
31974
- }
31975
- )
31976
- ] }),
31977
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-center gap-3 border-b bg-gray-50 p-4", children: [
31978
- onDateRangeChange && dateRange && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
31979
- /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "text-muted-foreground text-sm", children: [
31980
- dateFrom,
31981
- ":"
32369
+ /* @__PURE__ */ jsxRuntime.jsxs(
32370
+ chunkI7L6CQXR_cjs.Modal,
32371
+ {
32372
+ open: modalOpen,
32373
+ onOpenChange: (open) => {
32374
+ if (!open) {
32375
+ handleClose();
32376
+ }
32377
+ },
32378
+ size: "4xl",
32379
+ children: [
32380
+ /* @__PURE__ */ jsxRuntime.jsxs(chunkI7L6CQXR_cjs.ModalHeader, { children: [
32381
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3", children: [
32382
+ /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalTitle, { children: currentReport?.name || "Report Results" }),
32383
+ reportResult?.error ? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.AlertTriangle, { className: "h-5 w-5 text-yellow-500" }) : reportResult?.success ? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Check, { className: "h-5 w-5 text-green-500" }) : null
31982
32384
  ] }),
31983
- /* @__PURE__ */ jsxRuntime.jsx(
31984
- "input",
31985
- {
31986
- type: "date",
31987
- value: formatDate4(dateRange.start),
31988
- onChange: (e) => onDateRangeChange(e.target.value, dateRange.end),
31989
- className: "rounded-lg border border-gray-300 px-2 py-1 text-sm"
31990
- }
31991
- ),
31992
- /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "text-muted-foreground text-sm", children: [
31993
- dateTo,
31994
- ":"
32385
+ /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalClose, {})
32386
+ ] }),
32387
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-muted/50 flex flex-wrap items-center gap-3 border-b px-6 py-4", children: [
32388
+ onDateRangeChange && dateRange && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
32389
+ /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "text-muted-foreground text-sm", children: [
32390
+ dateFrom,
32391
+ ":"
32392
+ ] }),
32393
+ /* @__PURE__ */ jsxRuntime.jsx(
32394
+ chunkVV4N4WY6_cjs.Input,
32395
+ {
32396
+ type: "date",
32397
+ size: "sm",
32398
+ value: formatDate4(dateRange.start),
32399
+ onChange: (e) => onDateRangeChange(e.target.value, dateRange.end),
32400
+ className: "w-auto"
32401
+ }
32402
+ ),
32403
+ /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "text-muted-foreground text-sm", children: [
32404
+ dateTo,
32405
+ ":"
32406
+ ] }),
32407
+ /* @__PURE__ */ jsxRuntime.jsx(
32408
+ chunkVV4N4WY6_cjs.Input,
32409
+ {
32410
+ type: "date",
32411
+ size: "sm",
32412
+ value: formatDate4(dateRange.end),
32413
+ onChange: (e) => onDateRangeChange(dateRange.start, e.target.value),
32414
+ className: "w-auto"
32415
+ }
32416
+ )
31995
32417
  ] }),
31996
32418
  /* @__PURE__ */ jsxRuntime.jsx(
31997
- "input",
32419
+ chunkMKJDBXX4_cjs.Button,
31998
32420
  {
31999
- type: "date",
32000
- value: formatDate4(dateRange.end),
32001
- onChange: (e) => onDateRangeChange(dateRange.start, e.target.value),
32002
- className: "rounded-lg border border-gray-300 px-2 py-1 text-sm"
32421
+ size: "sm",
32422
+ onClick: onRefreshReport,
32423
+ title: refreshReport,
32424
+ "aria-label": refreshReport,
32425
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.RefreshCw, { className: "h-4 w-4" })
32003
32426
  }
32004
32427
  )
32005
32428
  ] }),
32006
- /* @__PURE__ */ jsxRuntime.jsx(
32007
- "button",
32429
+ /* @__PURE__ */ jsxRuntime.jsx(chunkI7L6CQXR_cjs.ModalBody, { className: "max-h-[60vh] overflow-auto", children: loadingReport ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex h-64 flex-col items-center justify-center", children: [
32430
+ /* @__PURE__ */ jsxRuntime.jsx(chunkJYMQJ32S_cjs.Spinner, { size: "xl" }),
32431
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground mt-4", children: loadingData })
32432
+ ] }) : reportResult?.error ? /* @__PURE__ */ jsxRuntime.jsx(chunkIY7UQPDO_cjs.Alert, { variant: "danger", icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.AlertTriangle, {}), children: /* @__PURE__ */ jsxRuntime.jsx(chunkIY7UQPDO_cjs.AlertDescription, { children: reportResult.error }) }) : reportResult?.data ? typeof reportResult.data === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
32433
+ "div",
32008
32434
  {
32009
- type: "button",
32010
- onClick: onRefreshReport,
32011
- className: "bg-primary hover:bg-primary/90 rounded-lg px-3 py-1.5 text-white",
32012
- title: refreshReport,
32013
- children: /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-sync-alt" })
32435
+ className: "prose dark:prose-invert max-w-none",
32436
+ dangerouslySetInnerHTML: { __html: reportResult.data }
32014
32437
  }
32015
- )
32016
- ] }),
32017
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 overflow-auto p-4", children: loadingReport ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex h-full flex-col items-center justify-center", children: [
32018
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-primary h-12 w-12 animate-spin rounded-full border-4 border-t-transparent" }),
32019
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground mt-4", children: loadingData })
32020
- ] }) : reportResult?.error ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rounded-lg border border-red-200 bg-red-50 p-4 text-red-600", children: [
32021
- /* @__PURE__ */ jsxRuntime.jsx("i", { className: "fas fa-exclamation-circle mr-2" }),
32022
- reportResult.error
32023
- ] }) : reportResult?.data ? typeof reportResult.data === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
32024
- "div",
32025
- {
32026
- className: "prose max-w-none",
32027
- dangerouslySetInnerHTML: { __html: reportResult.data }
32028
- }
32029
- ) : /* @__PURE__ */ jsxRuntime.jsx("pre", { className: "overflow-auto rounded-lg bg-gray-100 p-4 text-sm", children: JSON.stringify(reportResult.data, null, 2) }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-muted-foreground py-8 text-center", children: "No data available" }) })
32030
- ] })
32031
- ] })
32438
+ ) : Array.isArray(reportResult.data) && reportResult.data.length > 0 ? (() => {
32439
+ const rows = reportResult.data;
32440
+ const columns = Object.keys(rows[0]);
32441
+ return /* @__PURE__ */ jsxRuntime.jsxs(chunkLZEY55QZ_cjs.Table, { children: [
32442
+ /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableRow, { children: columns.map((key) => /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableHead, { children: key }, key)) }) }),
32443
+ /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableBody, { children: rows.map((row) => {
32444
+ const rowKey = columns.map((key) => String(row[key])).join("|") || JSON.stringify(row);
32445
+ return /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableRow, { children: columns.map((key) => /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableCell, { children: columnRenderers?.[key] ? columnRenderers[key](row[key], row) : row[key] == null ? "" : String(row[key]) }, key)) }, rowKey);
32446
+ }) })
32447
+ ] });
32448
+ })() : /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.Table, { children: /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableBody, { children: Object.entries(
32449
+ reportResult.data
32450
+ ).map(([key, val]) => /* @__PURE__ */ jsxRuntime.jsxs(chunkLZEY55QZ_cjs.TableRow, { children: [
32451
+ /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableCell, { className: "text-muted-foreground font-medium", children: key }),
32452
+ /* @__PURE__ */ jsxRuntime.jsx(chunkLZEY55QZ_cjs.TableCell, { children: val == null ? "" : String(val) })
32453
+ ] }, key)) }) }) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-muted-foreground py-8 text-center", children: "No data available" }) })
32454
+ ]
32455
+ }
32456
+ )
32032
32457
  ] });
32033
32458
  }
32034
32459
  function ReportDatePicker({
@@ -32055,7 +32480,7 @@ function ReportDatePicker({
32055
32480
  setPreset(value);
32056
32481
  const now = /* @__PURE__ */ new Date();
32057
32482
  let start;
32058
- let end = now;
32483
+ const end = now;
32059
32484
  switch (value) {
32060
32485
  case "today":
32061
32486
  start = now;
@@ -32080,34 +32505,40 @@ function ReportDatePicker({
32080
32505
  }
32081
32506
  onChange?.(start, end);
32082
32507
  };
32508
+ const selectOptions = presets.map((p) => ({
32509
+ value: p.value,
32510
+ label: p.label
32511
+ }));
32083
32512
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: chunkOR5DRJCW_cjs.cn("flex flex-wrap items-center gap-3", className), children: [
32084
32513
  /* @__PURE__ */ jsxRuntime.jsx(
32085
- "select",
32514
+ chunk5UUL5EEO_cjs.Select,
32086
32515
  {
32087
32516
  value: preset,
32088
- onChange: (e) => handlePresetChange(e.target.value),
32089
- className: "rounded-lg border border-gray-300 px-3 py-2",
32090
- children: presets.map((p) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: p.value, children: p.label }, p.value))
32517
+ onValueChange: (value) => handlePresetChange(value),
32518
+ options: selectOptions,
32519
+ size: "sm"
32091
32520
  }
32092
32521
  ),
32093
32522
  preset === "custom" && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
32094
32523
  /* @__PURE__ */ jsxRuntime.jsx(
32095
- "input",
32524
+ chunkVV4N4WY6_cjs.Input,
32096
32525
  {
32097
32526
  type: "date",
32527
+ size: "sm",
32098
32528
  value: formatDate4(startDate),
32099
32529
  onChange: (e) => onChange?.(e.target.value, endDate || /* @__PURE__ */ new Date()),
32100
- className: "rounded-lg border border-gray-300 px-3 py-2"
32530
+ className: "w-auto"
32101
32531
  }
32102
32532
  ),
32103
32533
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: "to" }),
32104
32534
  /* @__PURE__ */ jsxRuntime.jsx(
32105
- "input",
32535
+ chunkVV4N4WY6_cjs.Input,
32106
32536
  {
32107
32537
  type: "date",
32538
+ size: "sm",
32108
32539
  value: formatDate4(endDate),
32109
32540
  onChange: (e) => onChange?.(startDate || /* @__PURE__ */ new Date(), e.target.value),
32110
- className: "rounded-lg border border-gray-300 px-3 py-2"
32541
+ className: "w-auto"
32111
32542
  }
32112
32543
  )
32113
32544
  ] })
@@ -32366,6 +32797,14 @@ function WebsiteInputGroup({
32366
32797
  }
32367
32798
  WebsiteInputGroup.displayName = "WebsiteInputGroup";
32368
32799
 
32800
+ Object.defineProperty(exports, "Textarea", {
32801
+ enumerable: true,
32802
+ get: function () { return chunkB7YGVKTE_cjs.Textarea; }
32803
+ });
32804
+ Object.defineProperty(exports, "textareaVariants", {
32805
+ enumerable: true,
32806
+ get: function () { return chunkB7YGVKTE_cjs.textareaVariants; }
32807
+ });
32369
32808
  Object.defineProperty(exports, "ThemeProvider", {
32370
32809
  enumerable: true,
32371
32810
  get: function () { return chunkVDMQCSXT_cjs.ThemeProvider; }
@@ -32400,7 +32839,11 @@ Object.defineProperty(exports, "VisuallyHidden", {
32400
32839
  });
32401
32840
  Object.defineProperty(exports, "brands", {
32402
32841
  enumerable: true,
32403
- get: function () { return chunk6DP6RKUA_cjs.brands; }
32842
+ get: function () { return chunkCLJZHS7Y_cjs.brands; }
32843
+ });
32844
+ Object.defineProperty(exports, "enterpriseHealthBrand", {
32845
+ enumerable: true,
32846
+ get: function () { return chunkP52GA3GJ_cjs.enterpriseHealthBrand; }
32404
32847
  });
32405
32848
  Object.defineProperty(exports, "miewebBrand", {
32406
32849
  enumerable: true,
@@ -32434,17 +32877,13 @@ Object.defineProperty(exports, "defaultBrand", {
32434
32877
  enumerable: true,
32435
32878
  get: function () { return chunkO5HS7ZND_cjs.defaultBrand; }
32436
32879
  });
32437
- Object.defineProperty(exports, "enterpriseHealthBrand", {
32438
- enumerable: true,
32439
- get: function () { return chunkP52GA3GJ_cjs.enterpriseHealthBrand; }
32440
- });
32441
32880
  Object.defineProperty(exports, "Select", {
32442
32881
  enumerable: true,
32443
- get: function () { return chunkNL3CZNBH_cjs.Select; }
32882
+ get: function () { return chunk5UUL5EEO_cjs.Select; }
32444
32883
  });
32445
32884
  Object.defineProperty(exports, "selectTriggerVariants", {
32446
32885
  enumerable: true,
32447
- get: function () { return chunkNL3CZNBH_cjs.selectTriggerVariants; }
32886
+ get: function () { return chunk5UUL5EEO_cjs.selectTriggerVariants; }
32448
32887
  });
32449
32888
  Object.defineProperty(exports, "Skeleton", {
32450
32889
  enumerable: true,
@@ -32466,6 +32905,22 @@ Object.defineProperty(exports, "skeletonVariants", {
32466
32905
  enumerable: true,
32467
32906
  get: function () { return chunkN3QTYHRZ_cjs.skeletonVariants; }
32468
32907
  });
32908
+ Object.defineProperty(exports, "Slider", {
32909
+ enumerable: true,
32910
+ get: function () { return chunkBV75DAKO_cjs.Slider; }
32911
+ });
32912
+ Object.defineProperty(exports, "sliderRangeVariants", {
32913
+ enumerable: true,
32914
+ get: function () { return chunkBV75DAKO_cjs.sliderRangeVariants; }
32915
+ });
32916
+ Object.defineProperty(exports, "sliderThumbVariants", {
32917
+ enumerable: true,
32918
+ get: function () { return chunkBV75DAKO_cjs.sliderThumbVariants; }
32919
+ });
32920
+ Object.defineProperty(exports, "sliderTrackVariants", {
32921
+ enumerable: true,
32922
+ get: function () { return chunkBV75DAKO_cjs.sliderTrackVariants; }
32923
+ });
32469
32924
  Object.defineProperty(exports, "FullPageSpinner", {
32470
32925
  enumerable: true,
32471
32926
  get: function () { return chunkJYMQJ32S_cjs.FullPageSpinner; }
@@ -32562,14 +33017,6 @@ Object.defineProperty(exports, "textVariants", {
32562
33017
  enumerable: true,
32563
33018
  get: function () { return chunkQDGZBDBI_cjs.textVariants; }
32564
33019
  });
32565
- Object.defineProperty(exports, "Textarea", {
32566
- enumerable: true,
32567
- get: function () { return chunkB7YGVKTE_cjs.Textarea; }
32568
- });
32569
- Object.defineProperty(exports, "textareaVariants", {
32570
- enumerable: true,
32571
- get: function () { return chunkB7YGVKTE_cjs.textareaVariants; }
32572
- });
32573
33020
  Object.defineProperty(exports, "Modal", {
32574
33021
  enumerable: true,
32575
33022
  get: function () { return chunkI7L6CQXR_cjs.Modal; }
@@ -33258,6 +33705,7 @@ exports.ReportLink = ReportLink;
33258
33705
  exports.ResourceLink = ResourceLink;
33259
33706
  exports.ResultsEntryCard = ResultsEntryCard;
33260
33707
  exports.ResultsEntryForm = ResultsEntryForm;
33708
+ exports.ResultsEntryModal = ResultsEntryModal;
33261
33709
  exports.SSOConfigForm = SSOConfigForm;
33262
33710
  exports.ScheduleCalendar = ScheduleCalendar;
33263
33711
  exports.SearchResultsMessage = SearchResultsMessage;