@mieweb/ui 0.2.2 → 0.2.4
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/ag-grid.cjs +5 -5
- package/dist/ag-grid.js +1 -1
- package/dist/{chunk-I7L6CQXR.cjs → chunk-377KAB4C.cjs} +52 -31
- package/dist/chunk-377KAB4C.cjs.map +1 -0
- package/dist/chunk-3K7QCDSV.js +3 -0
- package/dist/{chunk-Y22SOAJM.js.map → chunk-3K7QCDSV.js.map} +1 -1
- package/dist/{chunk-QUA7WVHK.cjs → chunk-QIOM5ZV2.cjs} +2 -14
- package/dist/{chunk-QUA7WVHK.cjs.map → chunk-QIOM5ZV2.cjs.map} +1 -1
- package/dist/{chunk-SD44QJIP.js → chunk-TCQ27C5M.js} +52 -31
- package/dist/chunk-TCQ27C5M.js.map +1 -0
- package/dist/components/Modal/index.cjs +9 -9
- package/dist/components/Modal/index.js +1 -1
- package/dist/index.cjs +334 -363
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +8 -6
- package/dist/index.d.ts +8 -6
- package/dist/index.js +177 -206
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
- package/dist/chunk-I7L6CQXR.cjs.map +0 -1
- package/dist/chunk-SD44QJIP.js.map +0 -1
- package/dist/chunk-Y22SOAJM.js +0 -3
package/dist/index.js
CHANGED
|
@@ -29,8 +29,8 @@ import { Table, TableHeader, TableRow, TableHead, TableBody, TableCell } from '.
|
|
|
29
29
|
export { Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow } from './chunk-AWIULTJW.js';
|
|
30
30
|
import { Tabs, TabsList, TabsTrigger, TabsContent } from './chunk-JFAXLE2J.js';
|
|
31
31
|
export { Tabs, TabsContent, TabsList, TabsTrigger, tabsListVariants, tabsTriggerVariants } from './chunk-JFAXLE2J.js';
|
|
32
|
-
import { Modal, ModalHeader, ModalTitle, ModalClose, ModalBody, ModalFooter } from './chunk-
|
|
33
|
-
export { Modal, ModalBody, ModalClose, ModalFooter, ModalHeader, ModalTitle, modalContentVariants, modalOverlayVariants } from './chunk-
|
|
32
|
+
import { Modal, ModalHeader, ModalTitle, ModalClose, ModalBody, ModalFooter } from './chunk-TCQ27C5M.js';
|
|
33
|
+
export { Modal, ModalBody, ModalClose, ModalFooter, ModalHeader, ModalTitle, modalContentVariants, modalOverlayVariants } from './chunk-TCQ27C5M.js';
|
|
34
34
|
export { Pagination, SimplePagination, paginationButtonVariants } from './chunk-ONWOB76P.js';
|
|
35
35
|
export { PhoneInput, PhoneInputGroup } from './chunk-4YRAEFYW.js';
|
|
36
36
|
import { Progress } from './chunk-4MHTSFPX.js';
|
|
@@ -55,7 +55,7 @@ import { Input } from './chunk-NXRLGHEC.js';
|
|
|
55
55
|
export { Input, inputVariants } from './chunk-NXRLGHEC.js';
|
|
56
56
|
import { Dropdown, DropdownItem } from './chunk-265CFCCX.js';
|
|
57
57
|
export { Dropdown, DropdownContent, DropdownHeader, DropdownItem, DropdownLabel, DropdownSeparator } from './chunk-265CFCCX.js';
|
|
58
|
-
import { Clock, FileText, ArrowLeft,
|
|
58
|
+
import { Clock, FileText, ArrowLeft, Stethoscope, Users, Mail, Phone, Share, ChevronDown, User, Download, ExternalLink, MoreVertical, Pencil, Send, Calendar, Printer, ClipboardPlus, ClipboardCheck, FilePlus, FileCheck, Wheat, Pill, Bell, FileHeart, HeartPulse, AlertCircle as AlertCircle$1, Paperclip, ClipboardList, MoreHorizontal, Trash2, Plus, CheckCircle, Upload as Upload$1, Scan, Camera, ScanLine, RefreshCw as RefreshCw$1, Image, X as X$1, Check as Check$1 } from './chunk-3K7QCDSV.js';
|
|
59
59
|
import { useCommandK, useIsMobile, useMediaQuery } from './chunk-CP7NPDQW.js';
|
|
60
60
|
export { useCommandK, useIsDesktop, useIsLargeDesktop, useIsMobile, useIsMobileOrTablet, useIsSmallTablet, useIsTablet, useKeyboardShortcut, useMediaQuery } from './chunk-CP7NPDQW.js';
|
|
61
61
|
export { useTheme } from './chunk-KJZNEVYM.js';
|
|
@@ -83,7 +83,7 @@ import React48__default, { createContext, useState, useEffect, useCallback, useM
|
|
|
83
83
|
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
84
84
|
import { cva } from 'class-variance-authority';
|
|
85
85
|
import * as ReactDOM from 'react-dom';
|
|
86
|
-
import { FileUp, X, AlertCircle, Calendar as Calendar$1, ChevronLeft, ChevronRight, ChevronDown as ChevronDown$1, FolderUp, Upload, Edit2, Check, ChevronUp
|
|
86
|
+
import { FileUp, X, AlertCircle, Calendar as Calendar$1, ChevronLeft, ChevronRight, ChevronDown as ChevronDown$1, FolderUp, Upload, Edit2, Check, ChevronUp, Phone as Phone$1, Mail as Mail$1, Clock as Clock$1, MapPin, Shield, Building2, SlidersHorizontal, Trash2 as Trash2$1, Pencil as Pencil$1, Plus as Plus$1, Link, AlertTriangle, RefreshCw } from 'lucide-react';
|
|
87
87
|
|
|
88
88
|
var SEX_OPTIONS = [
|
|
89
89
|
{ value: "F", label: "Female" },
|
|
@@ -8628,7 +8628,7 @@ var countChipVariants = cva(
|
|
|
8628
8628
|
variant: {
|
|
8629
8629
|
default: "bg-muted text-foreground/70 dark:bg-muted dark:text-foreground/70",
|
|
8630
8630
|
info: "bg-primary-100 text-primary-800 dark:bg-primary-900 dark:text-primary-200",
|
|
8631
|
-
informative: "bg-blue-
|
|
8631
|
+
informative: "bg-blue-50 text-blue-600 dark:bg-blue-950/50 dark:text-blue-300",
|
|
8632
8632
|
success: "bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200",
|
|
8633
8633
|
warning: "bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-200",
|
|
8634
8634
|
alert: "bg-red-100 text-red-800 dark:bg-red-900 dark:text-red-200"
|
|
@@ -9006,6 +9006,7 @@ var CountBadge = React48.forwardRef(
|
|
|
9006
9006
|
onEdit,
|
|
9007
9007
|
onDelete,
|
|
9008
9008
|
deleteLabel,
|
|
9009
|
+
countVariant,
|
|
9009
9010
|
...props
|
|
9010
9011
|
}, ref) => {
|
|
9011
9012
|
const [open, setOpen] = React48.useState(false);
|
|
@@ -9067,6 +9068,7 @@ var CountBadge = React48.forwardRef(
|
|
|
9067
9068
|
{
|
|
9068
9069
|
ref,
|
|
9069
9070
|
type: "button",
|
|
9071
|
+
"data-count-badge": true,
|
|
9070
9072
|
className: cn(countBadgeVariants({ variant }), className),
|
|
9071
9073
|
onClick: (e) => {
|
|
9072
9074
|
if (showMenu) {
|
|
@@ -9079,7 +9081,15 @@ var CountBadge = React48.forwardRef(
|
|
|
9079
9081
|
children: [
|
|
9080
9082
|
icon && /* @__PURE__ */ jsx("span", { className: "shrink-0", children: icon }),
|
|
9081
9083
|
/* @__PURE__ */ jsx("span", { children: label }),
|
|
9082
|
-
/* @__PURE__ */ jsx(
|
|
9084
|
+
/* @__PURE__ */ jsx(
|
|
9085
|
+
"span",
|
|
9086
|
+
{
|
|
9087
|
+
className: cn(
|
|
9088
|
+
countChipVariants({ variant: countVariant ?? variant })
|
|
9089
|
+
),
|
|
9090
|
+
children: count
|
|
9091
|
+
}
|
|
9092
|
+
)
|
|
9083
9093
|
]
|
|
9084
9094
|
}
|
|
9085
9095
|
),
|
|
@@ -13945,7 +13955,7 @@ function EmployeeProfileCard({
|
|
|
13945
13955
|
"aria-controls": "employee-details",
|
|
13946
13956
|
children: isExpanded ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
13947
13957
|
lessDetails,
|
|
13948
|
-
/* @__PURE__ */ jsx(ChevronUp
|
|
13958
|
+
/* @__PURE__ */ jsx(ChevronUp, { className: "h-4 w-4" })
|
|
13949
13959
|
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
13950
13960
|
moreDetails,
|
|
13951
13961
|
/* @__PURE__ */ jsx(ChevronDown$1, { className: "h-4 w-4" })
|
|
@@ -14327,7 +14337,7 @@ function EmployerList({
|
|
|
14327
14337
|
const d = typeof date === "string" ? new Date(date) : date;
|
|
14328
14338
|
return d.toLocaleDateString();
|
|
14329
14339
|
};
|
|
14330
|
-
const
|
|
14340
|
+
const getStatusVariant = (status) => {
|
|
14331
14341
|
switch (status) {
|
|
14332
14342
|
case "active":
|
|
14333
14343
|
return "success";
|
|
@@ -14444,7 +14454,7 @@ function EmployerList({
|
|
|
14444
14454
|
/* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1", children: [
|
|
14445
14455
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
14446
14456
|
/* @__PURE__ */ jsx("h3", { className: "truncate font-medium text-gray-900 dark:text-white", children: employer.name }),
|
|
14447
|
-
/* @__PURE__ */ jsx(Badge, { variant:
|
|
14457
|
+
/* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(employer.status), children: employer.status })
|
|
14448
14458
|
] }),
|
|
14449
14459
|
/* @__PURE__ */ jsxs("div", { className: "mt-0.5 flex items-center gap-4", children: [
|
|
14450
14460
|
employer.email && /* @__PURE__ */ jsx("span", { className: "truncate text-sm text-gray-500 dark:text-gray-400", children: employer.email }),
|
|
@@ -14626,7 +14636,7 @@ function EmployerView({
|
|
|
14626
14636
|
currency: "USD"
|
|
14627
14637
|
}).format(amount);
|
|
14628
14638
|
};
|
|
14629
|
-
const
|
|
14639
|
+
const getStatusVariant = (status) => {
|
|
14630
14640
|
switch (status) {
|
|
14631
14641
|
case "active":
|
|
14632
14642
|
case "completed":
|
|
@@ -14666,7 +14676,7 @@ function EmployerView({
|
|
|
14666
14676
|
/* @__PURE__ */ jsxs("div", { children: [
|
|
14667
14677
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
14668
14678
|
/* @__PURE__ */ jsx("h1", { className: "text-2xl font-bold text-gray-900 dark:text-white", children: employer.name }),
|
|
14669
|
-
/* @__PURE__ */ jsx(Badge, { variant:
|
|
14679
|
+
/* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(employer.status), children: employer.status })
|
|
14670
14680
|
] }),
|
|
14671
14681
|
/* @__PURE__ */ jsxs("p", { className: "text-sm text-gray-500 dark:text-gray-400", children: [
|
|
14672
14682
|
"Linked since ",
|
|
@@ -14768,7 +14778,7 @@ function EmployerView({
|
|
|
14768
14778
|
/* @__PURE__ */ jsx("p", { className: "text-xs text-gray-500 dark:text-gray-400", children: order.services.join(", ") })
|
|
14769
14779
|
] }),
|
|
14770
14780
|
/* @__PURE__ */ jsxs("div", { className: "text-right", children: [
|
|
14771
|
-
/* @__PURE__ */ jsx(Badge, { variant:
|
|
14781
|
+
/* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(order.status), children: order.status }),
|
|
14772
14782
|
/* @__PURE__ */ jsx("p", { className: "mt-1 text-xs text-gray-500 dark:text-gray-400", children: formatDate4(order.createdDate) })
|
|
14773
14783
|
] }),
|
|
14774
14784
|
onViewOrder && /* @__PURE__ */ jsx(
|
|
@@ -14804,7 +14814,7 @@ function EmployerView({
|
|
|
14804
14814
|
] }),
|
|
14805
14815
|
/* @__PURE__ */ jsxs("div", { className: "text-right", children: [
|
|
14806
14816
|
/* @__PURE__ */ jsx("p", { className: "font-semibold text-gray-900 dark:text-white", children: formatCurrency3(invoice.amount) }),
|
|
14807
|
-
/* @__PURE__ */ jsx(Badge, { variant:
|
|
14817
|
+
/* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(invoice.status), children: invoice.status })
|
|
14808
14818
|
] }),
|
|
14809
14819
|
onViewInvoice && /* @__PURE__ */ jsx(
|
|
14810
14820
|
Button,
|
|
@@ -17009,7 +17019,7 @@ function InvoiceList({
|
|
|
17009
17019
|
const formatCurrency3 = (amount) => {
|
|
17010
17020
|
return `${currency}${amount.toLocaleString(void 0, { minimumFractionDigits: 2, maximumFractionDigits: 2 })}`;
|
|
17011
17021
|
};
|
|
17012
|
-
const
|
|
17022
|
+
const getStatusVariant = (status) => {
|
|
17013
17023
|
switch (status) {
|
|
17014
17024
|
case "paid":
|
|
17015
17025
|
return "success";
|
|
@@ -17197,7 +17207,7 @@ function InvoiceList({
|
|
|
17197
17207
|
}
|
|
17198
17208
|
) }),
|
|
17199
17209
|
/* @__PURE__ */ jsx("td", { className: "px-4 py-3 text-right", children: /* @__PURE__ */ jsx("p", { className: "font-medium text-gray-900 dark:text-white", children: formatCurrency3(invoice.amount) }) }),
|
|
17200
|
-
/* @__PURE__ */ jsx("td", { className: "px-4 py-3 text-center", children: /* @__PURE__ */ jsx(Badge, { variant:
|
|
17210
|
+
/* @__PURE__ */ jsx("td", { className: "px-4 py-3 text-center", children: /* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(invoice.status), children: invoice.status }) })
|
|
17201
17211
|
]
|
|
17202
17212
|
},
|
|
17203
17213
|
invoice.id
|
|
@@ -17234,7 +17244,7 @@ function InvoicePaymentPage({
|
|
|
17234
17244
|
const d = typeof date === "string" ? new Date(date) : date;
|
|
17235
17245
|
return d.toLocaleDateString();
|
|
17236
17246
|
};
|
|
17237
|
-
const
|
|
17247
|
+
const getStatusVariant = (status) => {
|
|
17238
17248
|
switch (status) {
|
|
17239
17249
|
case "paid":
|
|
17240
17250
|
return "success";
|
|
@@ -17356,7 +17366,7 @@ function InvoicePaymentPage({
|
|
|
17356
17366
|
"Invoice ",
|
|
17357
17367
|
invoice.invoiceNumber
|
|
17358
17368
|
] }),
|
|
17359
|
-
/* @__PURE__ */ jsx(Badge, { variant:
|
|
17369
|
+
/* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(invoice.status), children: invoice.status })
|
|
17360
17370
|
] }) }),
|
|
17361
17371
|
/* @__PURE__ */ jsxs(CardContent, { className: "space-y-4", children: [
|
|
17362
17372
|
/* @__PURE__ */ jsxs("div", { className: "space-y-1 text-sm text-gray-600 dark:text-gray-400", children: [
|
|
@@ -17573,7 +17583,7 @@ function InvoiceView({
|
|
|
17573
17583
|
const formatCurrency3 = (amount) => {
|
|
17574
17584
|
return `${currency}${amount.toLocaleString(void 0, { minimumFractionDigits: 2, maximumFractionDigits: 2 })}`;
|
|
17575
17585
|
};
|
|
17576
|
-
const
|
|
17586
|
+
const getStatusVariant = (status) => {
|
|
17577
17587
|
switch (status) {
|
|
17578
17588
|
case "paid":
|
|
17579
17589
|
return "success";
|
|
@@ -17619,7 +17629,7 @@ function InvoiceView({
|
|
|
17619
17629
|
/* @__PURE__ */ jsxs("div", { children: [
|
|
17620
17630
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
17621
17631
|
/* @__PURE__ */ jsx("h1", { className: "text-2xl font-bold text-gray-900 dark:text-white", children: invoice.invoiceNumber }),
|
|
17622
|
-
/* @__PURE__ */ jsx(Badge, { variant:
|
|
17632
|
+
/* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(invoice.status), children: invoice.status })
|
|
17623
17633
|
] }),
|
|
17624
17634
|
/* @__PURE__ */ jsxs("p", { className: "text-sm text-gray-500 dark:text-gray-400", children: [
|
|
17625
17635
|
"Issued ",
|
|
@@ -20725,7 +20735,7 @@ function OrderSidebar({
|
|
|
20725
20735
|
year: "numeric"
|
|
20726
20736
|
});
|
|
20727
20737
|
};
|
|
20728
|
-
const
|
|
20738
|
+
const getStatusVariant = (s) => {
|
|
20729
20739
|
switch (s?.toLowerCase()) {
|
|
20730
20740
|
case "completed":
|
|
20731
20741
|
return "success";
|
|
@@ -20804,7 +20814,7 @@ function OrderSidebar({
|
|
|
20804
20814
|
] }),
|
|
20805
20815
|
/* @__PURE__ */ jsxs("div", { className: "h-[calc(100%-8rem)] overflow-y-auto p-4", children: [
|
|
20806
20816
|
/* @__PURE__ */ jsxs("div", { className: "mb-4 flex items-center gap-2", children: [
|
|
20807
|
-
status && /* @__PURE__ */ jsx(Badge, { variant:
|
|
20817
|
+
status && /* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(status), children: status }),
|
|
20808
20818
|
priority !== "normal" && /* @__PURE__ */ jsx(
|
|
20809
20819
|
"span",
|
|
20810
20820
|
{
|
|
@@ -20951,24 +20961,6 @@ function formatFullName(name) {
|
|
|
20951
20961
|
if (name.suffix) parts.push(name.suffix);
|
|
20952
20962
|
return parts.filter(Boolean).join(" ");
|
|
20953
20963
|
}
|
|
20954
|
-
function getStatusVariant(status) {
|
|
20955
|
-
switch (status) {
|
|
20956
|
-
case "active":
|
|
20957
|
-
return "success";
|
|
20958
|
-
case "deceased":
|
|
20959
|
-
return "danger";
|
|
20960
|
-
case "inactive":
|
|
20961
|
-
return "secondary";
|
|
20962
|
-
default:
|
|
20963
|
-
return "secondary";
|
|
20964
|
-
}
|
|
20965
|
-
}
|
|
20966
|
-
function getFlagVariant(flag) {
|
|
20967
|
-
const lower = flag.toLowerCase();
|
|
20968
|
-
if (lower === "duplicate") return "warning";
|
|
20969
|
-
if (lower === "deceased" || lower === "restricted") return "danger";
|
|
20970
|
-
return "secondary";
|
|
20971
|
-
}
|
|
20972
20964
|
function DetailItem({
|
|
20973
20965
|
icon,
|
|
20974
20966
|
label,
|
|
@@ -21082,12 +21074,12 @@ function PatientOverflowMenu({
|
|
|
21082
21074
|
"aria-label": "Patient actions",
|
|
21083
21075
|
className: cn(
|
|
21084
21076
|
"absolute top-full right-0 z-50 mt-1",
|
|
21077
|
+
"w-[calc(100vw_-_2rem)] md:w-auto",
|
|
21085
21078
|
"border-border bg-card rounded-xl border py-1 shadow-lg",
|
|
21086
|
-
"max-h-[calc(
|
|
21087
|
-
"motion-safe:animate-fade-in"
|
|
21088
|
-
"w-56 sm:w-auto"
|
|
21079
|
+
"max-h-[calc(100vh_-_3rem)] overflow-y-auto md:max-h-[calc(100vh_-_4rem)]",
|
|
21080
|
+
"motion-safe:animate-fade-in"
|
|
21089
21081
|
),
|
|
21090
|
-
children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col
|
|
21082
|
+
children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col md:flex-row", children: [
|
|
21091
21083
|
/* @__PURE__ */ jsxs("div", { className: "min-w-[13rem]", children: [
|
|
21092
21084
|
/* @__PURE__ */ jsx("div", { className: "px-3 py-1.5", children: /* @__PURE__ */ jsx("span", { className: "text-muted-foreground text-[11px] font-semibold tracking-wide uppercase", children: "Quick Actions" }) }),
|
|
21093
21085
|
/* @__PURE__ */ jsx(
|
|
@@ -21098,6 +21090,14 @@ function PatientOverflowMenu({
|
|
|
21098
21090
|
onClick: () => handleAction("edit-patient")
|
|
21099
21091
|
}
|
|
21100
21092
|
),
|
|
21093
|
+
/* @__PURE__ */ jsx(
|
|
21094
|
+
OverflowMenuItem,
|
|
21095
|
+
{
|
|
21096
|
+
icon: /* @__PURE__ */ jsx(Phone, { size: 15 }),
|
|
21097
|
+
label: "Contact",
|
|
21098
|
+
onClick: () => handleAction("contact")
|
|
21099
|
+
}
|
|
21100
|
+
),
|
|
21101
21101
|
/* @__PURE__ */ jsx(
|
|
21102
21102
|
OverflowMenuItem,
|
|
21103
21103
|
{
|
|
@@ -21131,10 +21131,10 @@ function PatientOverflowMenu({
|
|
|
21131
21131
|
}
|
|
21132
21132
|
)
|
|
21133
21133
|
] }),
|
|
21134
|
-
/* @__PURE__ */ jsx("div", { className: "border-border my-1 border-t
|
|
21135
|
-
/* @__PURE__ */ jsxs("div", { className: "min-w-[26rem]", children: [
|
|
21134
|
+
/* @__PURE__ */ jsx("div", { className: "border-border my-1 border-t md:my-0 md:border-t-0 md:border-l" }),
|
|
21135
|
+
/* @__PURE__ */ jsxs("div", { className: "md:min-w-[26rem]", children: [
|
|
21136
21136
|
/* @__PURE__ */ jsx("div", { className: "px-3 py-1.5", children: /* @__PURE__ */ jsx("span", { className: "text-muted-foreground text-[11px] font-semibold tracking-wide uppercase", children: "Add" }) }),
|
|
21137
|
-
/* @__PURE__ */ jsxs("div", { className: "grid grid-cols-2 gap-2", children: [
|
|
21137
|
+
/* @__PURE__ */ jsxs("div", { className: "grid grid-cols-1 gap-1 md:grid-cols-2 md:gap-2", children: [
|
|
21138
21138
|
/* @__PURE__ */ jsx(
|
|
21139
21139
|
OverflowMenuItem,
|
|
21140
21140
|
{
|
|
@@ -21244,8 +21244,8 @@ var PatientHeader = React48.forwardRef(
|
|
|
21244
21244
|
showAllergyBanner = false,
|
|
21245
21245
|
showMedicationBanner = false,
|
|
21246
21246
|
showCommentsBanner = false,
|
|
21247
|
-
|
|
21248
|
-
|
|
21247
|
+
showProviderBanner = false,
|
|
21248
|
+
showFlagBanner = false,
|
|
21249
21249
|
showOverflowMenu = false,
|
|
21250
21250
|
onOverflowAction,
|
|
21251
21251
|
onAddItem,
|
|
@@ -21258,33 +21258,19 @@ var PatientHeader = React48.forwardRef(
|
|
|
21258
21258
|
const hasAllergies = showAllergyBanner && allergies.length > 0;
|
|
21259
21259
|
const hasMedications = showMedicationBanner && medications.length > 0;
|
|
21260
21260
|
const hasComments = showCommentsBanner && comments.length > 0;
|
|
21261
|
-
const
|
|
21262
|
-
const
|
|
21263
|
-
detailsExpandedProp ?? true
|
|
21264
|
-
);
|
|
21265
|
-
const [actionsMenuOpen, setActionsMenuOpen] = React48.useState(false);
|
|
21266
|
-
const actionsMenuRef = React48.useRef(null);
|
|
21267
|
-
useClickOutside(
|
|
21268
|
-
actionsMenuRef,
|
|
21269
|
-
React48.useCallback(() => setActionsMenuOpen(false), [])
|
|
21270
|
-
);
|
|
21271
|
-
useEscapeKey(
|
|
21272
|
-
React48.useCallback(() => setActionsMenuOpen(false), []),
|
|
21273
|
-
actionsMenuOpen
|
|
21274
|
-
);
|
|
21275
|
-
React48.useEffect(() => {
|
|
21276
|
-
if (detailsExpandedProp !== void 0) {
|
|
21277
|
-
setDetailsExpanded(detailsExpandedProp);
|
|
21278
|
-
}
|
|
21279
|
-
}, [detailsExpandedProp]);
|
|
21261
|
+
const hasProviders = showProviderBanner && !!(patient.attendingProvider || patient.familyProvider);
|
|
21262
|
+
const hasInfoRows = hasAllergies || hasMedications || hasComments || hasProviders;
|
|
21280
21263
|
const [addModalType, setAddModalType] = React48.useState(null);
|
|
21281
21264
|
const [addForm, setAddForm] = React48.useState({});
|
|
21282
21265
|
const addEntityLabel = addModalType ? ADD_ENTITY_LABELS[addModalType] ?? "" : "";
|
|
21266
|
+
const [contactModalOpen, setContactModalOpen] = React48.useState(false);
|
|
21283
21267
|
const [editPatientOpen, setEditPatientOpen] = React48.useState(false);
|
|
21284
21268
|
const [editPatientForm, setEditPatientForm] = React48.useState({});
|
|
21285
21269
|
const handleOverflowAction = React48.useCallback(
|
|
21286
21270
|
(action) => {
|
|
21287
|
-
if (action === "
|
|
21271
|
+
if (action === "contact") {
|
|
21272
|
+
setContactModalOpen(true);
|
|
21273
|
+
} else if (action === "edit-patient") {
|
|
21288
21274
|
setEditPatientOpen(true);
|
|
21289
21275
|
setEditPatientForm({
|
|
21290
21276
|
firstName: patient.name.first,
|
|
@@ -21349,71 +21335,63 @@ var PatientHeader = React48.forwardRef(
|
|
|
21349
21335
|
{
|
|
21350
21336
|
name: formatFullName(patient.name),
|
|
21351
21337
|
src: patient.photo,
|
|
21352
|
-
size: "
|
|
21353
|
-
className: "
|
|
21338
|
+
size: "md",
|
|
21339
|
+
className: "hidden shrink-0 md:inline-flex"
|
|
21354
21340
|
}
|
|
21355
21341
|
),
|
|
21356
|
-
/* @__PURE__ */
|
|
21357
|
-
/* @__PURE__ */
|
|
21358
|
-
|
|
21359
|
-
|
|
21342
|
+
/* @__PURE__ */ jsx("div", { className: "min-w-0 flex-1", children: /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-x-2 gap-y-1", children: [
|
|
21343
|
+
/* @__PURE__ */ jsx("h2", { className: "text-foreground order-1 min-w-0 flex-1 truncate text-xl font-bold", children: displayName }),
|
|
21344
|
+
showOverflowMenu && /* @__PURE__ */ jsx("div", { className: "order-2 shrink-0 md:order-3", children: /* @__PURE__ */ jsx(PatientOverflowMenu, { onAction: handleOverflowAction }) }),
|
|
21345
|
+
actions && /* @__PURE__ */ jsx(
|
|
21346
|
+
"div",
|
|
21347
|
+
{
|
|
21348
|
+
className: cn(
|
|
21349
|
+
"order-4 w-full md:order-2 md:w-auto md:shrink-0",
|
|
21350
|
+
"mt-1 md:mt-0",
|
|
21351
|
+
"[&_button[data-count-badge]]:gap-1.5 [&_button[data-count-badge]]:px-2 [&_button[data-count-badge]]:py-0.5 [&_button[data-count-badge]]:text-xs",
|
|
21352
|
+
"md:[&_button[data-count-badge]]:gap-2 md:[&_button[data-count-badge]]:px-3 md:[&_button[data-count-badge]]:py-1 md:[&_button[data-count-badge]]:text-sm"
|
|
21353
|
+
),
|
|
21354
|
+
children: actions
|
|
21355
|
+
}
|
|
21356
|
+
),
|
|
21357
|
+
/* @__PURE__ */ jsxs("div", { className: "order-3 mt-1 flex w-full flex-wrap items-center gap-x-3 gap-y-1 text-sm md:order-4", children: [
|
|
21358
|
+
patient.status && (() => {
|
|
21359
|
+
const normalizedStatus = patient.status.toLowerCase();
|
|
21360
|
+
const statusColorMap = {
|
|
21361
|
+
active: "bg-green-500",
|
|
21362
|
+
inactive: "bg-gray-400",
|
|
21363
|
+
deceased: "bg-red-500"
|
|
21364
|
+
};
|
|
21365
|
+
const statusColorClass = statusColorMap[normalizedStatus] ?? "bg-yellow-500";
|
|
21366
|
+
return /* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-1 whitespace-nowrap", children: [
|
|
21367
|
+
/* @__PURE__ */ jsx(
|
|
21368
|
+
"span",
|
|
21369
|
+
{
|
|
21370
|
+
"aria-hidden": "true",
|
|
21371
|
+
className: `inline-block h-2 w-2 rounded-full ${statusColorClass}`
|
|
21372
|
+
}
|
|
21373
|
+
),
|
|
21374
|
+
/* @__PURE__ */ jsx("span", { className: "text-muted-foreground capitalize", children: normalizedStatus })
|
|
21375
|
+
] });
|
|
21376
|
+
})(),
|
|
21377
|
+
/* @__PURE__ */ jsxs("span", { className: "text-muted-foreground whitespace-nowrap", children: [
|
|
21378
|
+
"MRN: ",
|
|
21379
|
+
patient.mrn
|
|
21380
|
+
] }),
|
|
21381
|
+
/* @__PURE__ */ jsxs("span", { className: "text-muted-foreground whitespace-nowrap", children: [
|
|
21360
21382
|
patient.age,
|
|
21361
21383
|
" y/o ",
|
|
21362
21384
|
patient.sex
|
|
21363
21385
|
] }),
|
|
21364
|
-
/* @__PURE__ */ jsxs("span", { className: "text-muted-foreground
|
|
21365
|
-
"
|
|
21366
|
-
patient.
|
|
21367
|
-
] })
|
|
21368
|
-
|
|
21369
|
-
(patient.status || patient.flags && patient.flags.length > 0) && /* @__PURE__ */ jsxs("div", { className: "mt-1.5 flex flex-wrap items-center gap-1.5", children: [
|
|
21370
|
-
patient.status && /* @__PURE__ */ jsx(
|
|
21371
|
-
Badge,
|
|
21372
|
-
{
|
|
21373
|
-
variant: getStatusVariant(patient.status),
|
|
21374
|
-
size: "sm",
|
|
21375
|
-
className: "uppercase",
|
|
21376
|
-
children: patient.status
|
|
21377
|
-
}
|
|
21378
|
-
),
|
|
21379
|
-
patient.flags?.map((flag) => /* @__PURE__ */ jsx(Badge, { variant: getFlagVariant(flag), size: "sm", children: flag.toUpperCase() }, flag))
|
|
21386
|
+
/* @__PURE__ */ jsxs("span", { className: "text-muted-foreground whitespace-nowrap", children: [
|
|
21387
|
+
"DOB: ",
|
|
21388
|
+
patient.dob
|
|
21389
|
+
] }),
|
|
21390
|
+
patient.employer && /* @__PURE__ */ jsx("span", { className: "text-muted-foreground whitespace-nowrap", children: patient.employer })
|
|
21380
21391
|
] })
|
|
21381
|
-
] })
|
|
21382
|
-
(actions || showOverflowMenu) && /* @__PURE__ */ jsxs("div", { className: "mt-1 flex shrink-0 items-start gap-1", children: [
|
|
21383
|
-
actions && /* @__PURE__ */ jsxs("div", { className: "relative", ref: actionsMenuRef, children: [
|
|
21384
|
-
/* @__PURE__ */ jsx(
|
|
21385
|
-
Button,
|
|
21386
|
-
{
|
|
21387
|
-
variant: "ghost",
|
|
21388
|
-
size: "icon",
|
|
21389
|
-
onClick: () => setActionsMenuOpen(!actionsMenuOpen),
|
|
21390
|
-
"aria-label": "Open actions menu",
|
|
21391
|
-
"aria-haspopup": "true",
|
|
21392
|
-
"aria-expanded": actionsMenuOpen,
|
|
21393
|
-
"aria-controls": "patient-actions-menu",
|
|
21394
|
-
className: "h-8 w-8 md:hidden",
|
|
21395
|
-
children: /* @__PURE__ */ jsx(Menu, { size: 18 })
|
|
21396
|
-
}
|
|
21397
|
-
),
|
|
21398
|
-
/* @__PURE__ */ jsx(
|
|
21399
|
-
"div",
|
|
21400
|
-
{
|
|
21401
|
-
id: "patient-actions-menu",
|
|
21402
|
-
role: "group",
|
|
21403
|
-
"aria-label": "Patient actions",
|
|
21404
|
-
className: cn(
|
|
21405
|
-
"hidden items-center gap-2 md:flex",
|
|
21406
|
-
actionsMenuOpen && "border-border bg-card motion-safe:animate-fade-in absolute top-full right-0 z-50 mt-1 !flex min-w-[12rem] flex-col gap-1.5 rounded-xl border p-2 shadow-lg",
|
|
21407
|
-
"md:static md:z-auto md:mt-0 md:min-w-0 md:flex-row md:gap-2 md:rounded-none md:border-0 md:bg-transparent md:p-0 md:shadow-none"
|
|
21408
|
-
),
|
|
21409
|
-
children: actions
|
|
21410
|
-
}
|
|
21411
|
-
)
|
|
21412
|
-
] }),
|
|
21413
|
-
showOverflowMenu && /* @__PURE__ */ jsx(PatientOverflowMenu, { onAction: handleOverflowAction })
|
|
21414
|
-
] })
|
|
21392
|
+
] }) })
|
|
21415
21393
|
] }),
|
|
21416
|
-
|
|
21394
|
+
hasInfoRows && /* @__PURE__ */ jsxs("div", { className: "border-border bg-muted/30 mx-5 mb-3 space-y-2.5 rounded-lg border px-4 py-3", children: [
|
|
21417
21395
|
hasAllergies && /* @__PURE__ */ jsx(AllergyRow, { allergies }),
|
|
21418
21396
|
hasMedications && /* @__PURE__ */ jsx(
|
|
21419
21397
|
MedicationRow,
|
|
@@ -21422,89 +21400,82 @@ var PatientHeader = React48.forwardRef(
|
|
|
21422
21400
|
maxVisible: maxVisibleMeds
|
|
21423
21401
|
}
|
|
21424
21402
|
),
|
|
21425
|
-
hasComments && /* @__PURE__ */ jsx(AlertRow, { comments })
|
|
21403
|
+
hasComments && /* @__PURE__ */ jsx(AlertRow, { comments }),
|
|
21404
|
+
hasProviders && /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap gap-x-8 gap-y-2", children: [
|
|
21405
|
+
patient.attendingProvider && /* @__PURE__ */ jsx(
|
|
21406
|
+
DetailItem,
|
|
21407
|
+
{
|
|
21408
|
+
icon: /* @__PURE__ */ jsx(Stethoscope, { size: 14 }),
|
|
21409
|
+
label: "Attending",
|
|
21410
|
+
value: patient.attendingProvider
|
|
21411
|
+
}
|
|
21412
|
+
),
|
|
21413
|
+
patient.familyProvider && /* @__PURE__ */ jsx(
|
|
21414
|
+
DetailItem,
|
|
21415
|
+
{
|
|
21416
|
+
icon: /* @__PURE__ */ jsx(Users, { size: 14 }),
|
|
21417
|
+
label: "Family MD",
|
|
21418
|
+
value: patient.familyProvider
|
|
21419
|
+
}
|
|
21420
|
+
)
|
|
21421
|
+
] })
|
|
21426
21422
|
] }),
|
|
21427
|
-
|
|
21428
|
-
|
|
21429
|
-
|
|
21430
|
-
|
|
21431
|
-
|
|
21432
|
-
|
|
21433
|
-
|
|
21434
|
-
|
|
21435
|
-
|
|
21436
|
-
|
|
21437
|
-
|
|
21438
|
-
|
|
21439
|
-
|
|
21440
|
-
|
|
21441
|
-
/* @__PURE__ */ jsx(
|
|
21442
|
-
|
|
21443
|
-
|
|
21444
|
-
|
|
21445
|
-
) }),
|
|
21446
|
-
detailsExpanded && /* @__PURE__ */ jsxs(
|
|
21447
|
-
"div",
|
|
21448
|
-
{
|
|
21449
|
-
id: "patient-details-content",
|
|
21450
|
-
className: "border-border motion-safe:animate-fade-in space-y-3 border-t px-5 py-4",
|
|
21451
|
-
children: [
|
|
21452
|
-
/* @__PURE__ */ jsxs("div", { className: "flex flex-wrap gap-x-10 gap-y-3", children: [
|
|
21423
|
+
showFlagBanner && patient.flags && patient.flags.length > 0 && /* @__PURE__ */ jsx("div", { className: "border-t border-amber-200 bg-amber-50 px-5 py-1.5 text-left text-xs font-medium tracking-wide text-amber-800 dark:border-amber-800/40 dark:bg-amber-950/40 dark:text-amber-300", children: patient.flags.map(
|
|
21424
|
+
(flag) => flag.charAt(0).toUpperCase() + flag.slice(1).toLowerCase()
|
|
21425
|
+
).join(" \xB7 ") }),
|
|
21426
|
+
/* @__PURE__ */ jsxs(
|
|
21427
|
+
Modal,
|
|
21428
|
+
{
|
|
21429
|
+
open: contactModalOpen,
|
|
21430
|
+
onOpenChange: (isOpen) => {
|
|
21431
|
+
if (!isOpen) setContactModalOpen(false);
|
|
21432
|
+
},
|
|
21433
|
+
size: "sm",
|
|
21434
|
+
children: [
|
|
21435
|
+
/* @__PURE__ */ jsxs(ModalHeader, { children: [
|
|
21436
|
+
/* @__PURE__ */ jsx(ModalTitle, { children: "Contact Information" }),
|
|
21437
|
+
/* @__PURE__ */ jsx(ModalClose, {})
|
|
21438
|
+
] }),
|
|
21439
|
+
/* @__PURE__ */ jsx(ModalBody, { children: /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
|
|
21440
|
+
patient.email && /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
21453
21441
|
/* @__PURE__ */ jsx(
|
|
21454
|
-
|
|
21442
|
+
Mail,
|
|
21455
21443
|
{
|
|
21456
|
-
|
|
21457
|
-
|
|
21458
|
-
value: patient.dob
|
|
21444
|
+
size: 18,
|
|
21445
|
+
className: "text-muted-foreground shrink-0"
|
|
21459
21446
|
}
|
|
21460
21447
|
),
|
|
21461
|
-
|
|
21462
|
-
|
|
21463
|
-
{
|
|
21464
|
-
|
|
21465
|
-
label: "Email",
|
|
21466
|
-
value: patient.email
|
|
21467
|
-
}
|
|
21468
|
-
),
|
|
21469
|
-
patient.phone && /* @__PURE__ */ jsx(
|
|
21470
|
-
DetailItem,
|
|
21471
|
-
{
|
|
21472
|
-
icon: /* @__PURE__ */ jsx(Phone, { size: 14 }),
|
|
21473
|
-
label: "Phone",
|
|
21474
|
-
value: patient.phone
|
|
21475
|
-
}
|
|
21476
|
-
),
|
|
21477
|
-
patient.employer && /* @__PURE__ */ jsx(
|
|
21478
|
-
DetailItem,
|
|
21479
|
-
{
|
|
21480
|
-
icon: /* @__PURE__ */ jsx(Building, { size: 14 }),
|
|
21481
|
-
label: "Employer",
|
|
21482
|
-
value: patient.employer
|
|
21483
|
-
}
|
|
21484
|
-
)
|
|
21448
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
21449
|
+
/* @__PURE__ */ jsx("span", { className: "text-muted-foreground text-xs font-semibold tracking-wide uppercase", children: "Email" }),
|
|
21450
|
+
/* @__PURE__ */ jsx("p", { className: "text-foreground text-sm", children: patient.email })
|
|
21451
|
+
] })
|
|
21485
21452
|
] }),
|
|
21486
|
-
|
|
21487
|
-
|
|
21488
|
-
|
|
21453
|
+
patient.phone && /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
21454
|
+
/* @__PURE__ */ jsx(
|
|
21455
|
+
Phone,
|
|
21489
21456
|
{
|
|
21490
|
-
|
|
21491
|
-
|
|
21492
|
-
value: patient.attendingProvider
|
|
21457
|
+
size: 18,
|
|
21458
|
+
className: "text-muted-foreground shrink-0"
|
|
21493
21459
|
}
|
|
21494
21460
|
),
|
|
21495
|
-
|
|
21496
|
-
|
|
21497
|
-
{
|
|
21498
|
-
|
|
21499
|
-
|
|
21500
|
-
|
|
21501
|
-
|
|
21502
|
-
|
|
21503
|
-
|
|
21504
|
-
|
|
21505
|
-
|
|
21506
|
-
|
|
21507
|
-
|
|
21461
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
21462
|
+
/* @__PURE__ */ jsx("span", { className: "text-muted-foreground text-xs font-semibold tracking-wide uppercase", children: "Phone" }),
|
|
21463
|
+
/* @__PURE__ */ jsx("p", { className: "text-foreground text-sm", children: patient.phone })
|
|
21464
|
+
] })
|
|
21465
|
+
] }),
|
|
21466
|
+
!patient.email && !patient.phone && /* @__PURE__ */ jsx("p", { className: "text-muted-foreground text-sm", children: "No contact information available." })
|
|
21467
|
+
] }) }),
|
|
21468
|
+
/* @__PURE__ */ jsx(ModalFooter, { children: /* @__PURE__ */ jsx(
|
|
21469
|
+
Button,
|
|
21470
|
+
{
|
|
21471
|
+
variant: "secondary",
|
|
21472
|
+
onClick: () => setContactModalOpen(false),
|
|
21473
|
+
children: "Close"
|
|
21474
|
+
}
|
|
21475
|
+
) })
|
|
21476
|
+
]
|
|
21477
|
+
}
|
|
21478
|
+
),
|
|
21508
21479
|
/* @__PURE__ */ jsxs(
|
|
21509
21480
|
Modal,
|
|
21510
21481
|
{
|
|
@@ -21916,7 +21887,7 @@ function PaymentHistoryTable({
|
|
|
21916
21887
|
const formatCurrency3 = (amount) => {
|
|
21917
21888
|
return `${currency}${amount.toLocaleString(void 0, { minimumFractionDigits: 2, maximumFractionDigits: 2 })}`;
|
|
21918
21889
|
};
|
|
21919
|
-
const
|
|
21890
|
+
const getStatusVariant = (status) => {
|
|
21920
21891
|
switch (status) {
|
|
21921
21892
|
case "completed":
|
|
21922
21893
|
return "success";
|
|
@@ -22110,7 +22081,7 @@ function PaymentHistoryTable({
|
|
|
22110
22081
|
children: formatCurrency3(payment.amount)
|
|
22111
22082
|
}
|
|
22112
22083
|
) }),
|
|
22113
|
-
/* @__PURE__ */ jsx("td", { className: "px-4 py-3 text-center", children: /* @__PURE__ */ jsx(Badge, { variant:
|
|
22084
|
+
/* @__PURE__ */ jsx("td", { className: "px-4 py-3 text-center", children: /* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(payment.status), children: payment.status }) }),
|
|
22114
22085
|
onRefund && /* @__PURE__ */ jsx("td", { className: "px-4 py-3 text-right", children: payment.status === "completed" && /* @__PURE__ */ jsx(
|
|
22115
22086
|
Button,
|
|
22116
22087
|
{
|
|
@@ -22482,7 +22453,7 @@ function PendingClaimsTable({
|
|
|
22482
22453
|
const d = typeof date === "string" ? new Date(date) : date;
|
|
22483
22454
|
return d.toLocaleDateString();
|
|
22484
22455
|
};
|
|
22485
|
-
const
|
|
22456
|
+
const getStatusVariant = (status) => {
|
|
22486
22457
|
switch (status) {
|
|
22487
22458
|
case "approved":
|
|
22488
22459
|
return "success";
|
|
@@ -22553,7 +22524,7 @@ function PendingClaimsTable({
|
|
|
22553
22524
|
] }) }),
|
|
22554
22525
|
/* @__PURE__ */ jsx("td", { className: "px-4 py-4", children: /* @__PURE__ */ jsx("p", { className: "text-sm text-gray-700 dark:text-gray-300", children: claim.claimantRole || "Not specified" }) }),
|
|
22555
22526
|
/* @__PURE__ */ jsx("td", { className: "px-4 py-4", children: /* @__PURE__ */ jsx("p", { className: "text-sm text-gray-500 dark:text-gray-400", children: formatDate4(claim.submittedDate) }) }),
|
|
22556
|
-
/* @__PURE__ */ jsx("td", { className: "px-4 py-4 text-center", children: /* @__PURE__ */ jsx(Badge, { variant:
|
|
22527
|
+
/* @__PURE__ */ jsx("td", { className: "px-4 py-4 text-center", children: /* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(claim.status), children: claim.status }) }),
|
|
22557
22528
|
/* @__PURE__ */ jsx("td", { className: "px-4 py-4 text-right", children: /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-end gap-2", children: [
|
|
22558
22529
|
onViewDetails && /* @__PURE__ */ jsx(
|
|
22559
22530
|
Button,
|
|
@@ -22597,7 +22568,7 @@ function PendingClaimsTable({
|
|
|
22597
22568
|
/* @__PURE__ */ jsx("p", { className: "text-xs text-gray-500 dark:text-gray-400", children: claim.claimantEmail })
|
|
22598
22569
|
] })
|
|
22599
22570
|
] }),
|
|
22600
|
-
/* @__PURE__ */ jsx(Badge, { variant:
|
|
22571
|
+
/* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(claim.status), children: claim.status })
|
|
22601
22572
|
] }),
|
|
22602
22573
|
/* @__PURE__ */ jsx("div", { className: "mt-3 flex items-center justify-between", children: /* @__PURE__ */ jsxs("div", { className: "text-sm text-gray-500 dark:text-gray-400", children: [
|
|
22603
22574
|
/* @__PURE__ */ jsx("span", { children: claim.claimantRole || "No role" }),
|
|
@@ -26658,7 +26629,7 @@ function ProviderUsersTable({
|
|
|
26658
26629
|
year: "numeric"
|
|
26659
26630
|
});
|
|
26660
26631
|
};
|
|
26661
|
-
const
|
|
26632
|
+
const getStatusVariant = (status) => {
|
|
26662
26633
|
switch (status) {
|
|
26663
26634
|
case "active":
|
|
26664
26635
|
return "success";
|
|
@@ -26731,7 +26702,7 @@ function ProviderUsersTable({
|
|
|
26731
26702
|
] })
|
|
26732
26703
|
] }) }),
|
|
26733
26704
|
/* @__PURE__ */ jsx(TableCell, { children: /* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 dark:text-gray-300", children: user.role }) }),
|
|
26734
|
-
/* @__PURE__ */ jsx(TableCell, { children: /* @__PURE__ */ jsx(Badge, { variant:
|
|
26705
|
+
/* @__PURE__ */ jsx(TableCell, { children: /* @__PURE__ */ jsx(Badge, { variant: getStatusVariant(user.status), children: user.status || "active" }) }),
|
|
26735
26706
|
/* @__PURE__ */ jsx(TableCell, { children: /* @__PURE__ */ jsx("span", { className: "text-sm text-gray-500 dark:text-gray-400", children: isPending ? `Invited ${formatDate4(user.invitedAt)}` : formatDate4(user.lastActive) }) }),
|
|
26736
26707
|
showActions && /* @__PURE__ */ jsx(TableCell, { className: "text-right", children: /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-end gap-1", children: [
|
|
26737
26708
|
isPending && onResendInvite && /* @__PURE__ */ jsx(
|