@burdenoff/microfe-healthybowl 2026.624.4 → 2026.624.6
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/healthybowl/components/EmptyState.js +9 -24
- package/dist/healthybowl/components/EmptyState.js.map +1 -1
- package/dist/healthybowl/components/ErrorState.js +16 -24
- package/dist/healthybowl/components/ErrorState.js.map +1 -1
- package/dist/healthybowl/components/LoadingSkeleton.js +2 -1
- package/dist/healthybowl/components/LoadingSkeleton.js.map +1 -1
- package/dist/healthybowl/components/Modal.js +22 -55
- package/dist/healthybowl/components/Modal.js.map +1 -1
- package/dist/healthybowl/components/PageLayout.js +10 -16
- package/dist/healthybowl/components/PageLayout.js.map +1 -1
- package/dist/healthybowl/components/PageLoader.js +4 -6
- package/dist/healthybowl/components/PageLoader.js.map +1 -1
- package/dist/healthybowl/components/StatusBadge.js +20 -18
- package/dist/healthybowl/components/StatusBadge.js.map +1 -1
- package/dist/healthybowl/pages/crops/CropsPage.js +607 -594
- package/dist/healthybowl/pages/crops/CropsPage.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,29 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { EmptyState as t } from "@burdenoff/fe-libs/ui";
|
|
4
3
|
//#region src/healthybowl/components/EmptyState.tsx
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}),
|
|
12
|
-
/* @__PURE__ */ n("h3", {
|
|
13
|
-
className: "text-lg font-medium text-text-primary",
|
|
14
|
-
children: a
|
|
15
|
-
}),
|
|
16
|
-
o && /* @__PURE__ */ n("p", {
|
|
17
|
-
className: "mt-1 text-sm text-text-secondary max-w-md",
|
|
18
|
-
children: o
|
|
19
|
-
}),
|
|
20
|
-
s && /* @__PURE__ */ n("div", {
|
|
21
|
-
className: "mt-4",
|
|
22
|
-
children: s
|
|
23
|
-
})
|
|
24
|
-
]
|
|
4
|
+
var n = ({ icon: n, title: r, description: i, action: a, className: o }) => /* @__PURE__ */ e(t, {
|
|
5
|
+
icon: n,
|
|
6
|
+
title: r,
|
|
7
|
+
description: i,
|
|
8
|
+
action: a,
|
|
9
|
+
className: o
|
|
25
10
|
});
|
|
26
11
|
//#endregion
|
|
27
|
-
export {
|
|
12
|
+
export { n as EmptyState };
|
|
28
13
|
|
|
29
14
|
//# sourceMappingURL=EmptyState.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EmptyState.js","names":[],"sources":["../../../src/healthybowl/components/EmptyState.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport {
|
|
1
|
+
{"version":3,"file":"EmptyState.js","names":[],"sources":["../../../src/healthybowl/components/EmptyState.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport { EmptyState as BoffEmptyState } from '@burdenoff/fe-libs/ui';\n\ninterface EmptyStateProps {\n icon?: ReactNode;\n title: string;\n description?: string;\n action?: ReactNode;\n className?: string;\n}\n\n/**\n * Thin wrapper over the Boff `EmptyState` primitive. Keeps the local prop API\n * (`icon`/`title`/`description`/`action`/`className`) so existing call sites are\n * untouched; the primitive owns the canonical icon→title→description→action\n * layout. When `icon` is omitted, the primitive supplies its default inbox icon.\n */\nexport const EmptyState: FC<EmptyStateProps> = ({ icon, title, description, action, className }) => {\n return <BoffEmptyState icon={icon} title={title} description={description} action={action} className={className} />;\n};\n"],"mappings":";;;AAiBA,IAAa,KAAmC,EAAE,SAAM,UAAO,gBAAa,WAAQ,mBAC3E,kBAAC,GAAD;CAAsB;CAAa;CAAoB;CAAqB;CAAmB;CAAa,CAAA"}
|
|
@@ -1,28 +1,20 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { AlertTriangle as e } from "lucide-react";
|
|
2
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
3
|
+
import { Button as n, EmptyState as r } from "@burdenoff/fe-libs/ui";
|
|
4
4
|
//#region src/healthybowl/components/ErrorState.tsx
|
|
5
|
-
var i = ({ title: i = "Couldn't load this data", description: a = "Something went wrong while loading. Please try again.", onRetry: o, icon: s, className: c }) => /* @__PURE__ */ r
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
children: a
|
|
19
|
-
}),
|
|
20
|
-
o && /* @__PURE__ */ n("button", {
|
|
21
|
-
onClick: o,
|
|
22
|
-
className: "mt-4 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
|
|
23
|
-
children: "Try again"
|
|
24
|
-
})
|
|
25
|
-
]
|
|
5
|
+
var i = ({ title: i = "Couldn't load this data", description: a = "Something went wrong while loading. Please try again.", onRetry: o, icon: s, className: c }) => /* @__PURE__ */ t(r, {
|
|
6
|
+
icon: s ?? /* @__PURE__ */ t(e, {
|
|
7
|
+
className: "size-8 text-status-error-text",
|
|
8
|
+
"aria-hidden": "true"
|
|
9
|
+
}),
|
|
10
|
+
title: i,
|
|
11
|
+
description: a,
|
|
12
|
+
action: o ? /* @__PURE__ */ t(n, {
|
|
13
|
+
variant: "outline",
|
|
14
|
+
onClick: o,
|
|
15
|
+
children: "Retry"
|
|
16
|
+
}) : void 0,
|
|
17
|
+
className: c
|
|
26
18
|
});
|
|
27
19
|
//#endregion
|
|
28
20
|
export { i as ErrorState };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ErrorState.js","names":[],"sources":["../../../src/healthybowl/components/ErrorState.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport {
|
|
1
|
+
{"version":3,"file":"ErrorState.js","names":[],"sources":["../../../src/healthybowl/components/ErrorState.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport { AlertTriangle } from 'lucide-react';\nimport { Button, EmptyState } from '@burdenoff/fe-libs/ui';\n\ninterface ErrorStateProps {\n /** Honest title — defaults to a generic load-failure message. */\n title?: string;\n description?: string;\n /** Optional retry handler (e.g. the hook's `refetch`). */\n onRetry?: () => void;\n icon?: ReactNode;\n className?: string;\n}\n\n/**\n * Shown when a query FAILED (vs. EmptyState, which means it succeeded with no data). Pages render\n * this instead of an empty state when the relevant query errored, so a load failure is never\n * silently disguised as \"no data yet\". Built on the Boff `EmptyState` primitive with an error icon\n * and a retry action.\n */\nexport const ErrorState: FC<ErrorStateProps> = ({\n title = \"Couldn't load this data\",\n description = 'Something went wrong while loading. Please try again.',\n onRetry,\n icon,\n className,\n}) => {\n return (\n <EmptyState\n icon={icon ?? <AlertTriangle className=\"size-8 text-status-error-text\" aria-hidden=\"true\" />}\n title={title}\n description={description}\n action={\n onRetry ? (\n <Button variant=\"outline\" onClick={onRetry}>\n Retry\n </Button>\n ) : undefined\n }\n className={className}\n />\n );\n};\n"],"mappings":";;;;AAoBA,IAAa,KAAmC,EAC9C,WAAQ,2BACR,iBAAc,yDACd,YACA,SACA,mBAGE,kBAAC,GAAD;CACE,MAAM,KAAQ,kBAAC,GAAD;EAAe,WAAU;EAAgC,eAAY;EAAS,CAAA;CACrF;CACM;CACb,QACE,IACE,kBAAC,GAAD;EAAQ,SAAQ;EAAU,SAAS;YAAS;EAEnC,CAAA,GACP,KAAA;CAEK;CACX,CAAA"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { cn as e } from "../utils/helpers.js";
|
|
2
2
|
import { jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
3
|
+
import { Skeleton as r } from "@burdenoff/fe-libs/ui";
|
|
3
4
|
//#region src/healthybowl/components/LoadingSkeleton.tsx
|
|
4
|
-
var
|
|
5
|
+
var i = ({ variant: i = "card", count: a = 3, className: o }) => i === "table" ? /* @__PURE__ */ t("div", {
|
|
5
6
|
className: e("space-y-3", o),
|
|
6
7
|
children: /* @__PURE__ */ n("div", {
|
|
7
8
|
className: "overflow-hidden rounded-lg border border-border-subtle",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LoadingSkeleton.js","names":[],"sources":["../../../src/healthybowl/components/LoadingSkeleton.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport {
|
|
1
|
+
{"version":3,"file":"LoadingSkeleton.js","names":[],"sources":["../../../src/healthybowl/components/LoadingSkeleton.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { Skeleton } from '@burdenoff/fe-libs/ui';\nimport { cn } from '../utils/helpers';\n\ninterface LoadingSkeletonProps {\n variant?: 'card' | 'table' | 'list' | 'detail';\n count?: number;\n className?: string;\n}\n\n/**\n * Composed loading placeholder. The layout shells (card grid, table, list,\n * detail) are local; every shimmering leaf is the Boff `Skeleton` primitive so\n * the pulse/tone stays theme-consistent.\n */\nexport const LoadingSkeleton: FC<LoadingSkeletonProps> = ({ variant = 'card', count = 3, className }) => {\n if (variant === 'table') {\n return (\n <div className={cn('space-y-3', className)}>\n <div className=\"overflow-hidden rounded-lg border border-border-subtle\">\n <div className=\"border-b border-border-subtle bg-bg-sunken/50 px-4 py-3\">\n <div className=\"flex gap-4\">\n {Array.from({ length: 5 }).map((_, i) => (\n <Skeleton key={i} className=\"h-4 w-20\" />\n ))}\n </div>\n </div>\n {Array.from({ length: count }).map((_, i) => (\n <div key={i} className=\"flex gap-4 border-b border-border-subtle px-4 py-3 last:border-b-0\">\n {Array.from({ length: 5 }).map((_, j) => (\n <Skeleton key={j} className=\"h-4 w-20\" />\n ))}\n </div>\n ))}\n </div>\n </div>\n );\n }\n\n if (variant === 'list') {\n return (\n <div className={cn('space-y-2', className)}>\n {Array.from({ length: count }).map((_, i) => (\n <div key={i} className=\"flex items-center gap-3 rounded-lg border border-border-subtle p-4\">\n <Skeleton className=\"h-10 w-10 rounded-full\" />\n <div className=\"flex-1 space-y-2\">\n <Skeleton className=\"h-4 w-1/3\" />\n <Skeleton className=\"h-3 w-2/3\" />\n </div>\n <Skeleton className=\"h-6 w-16 rounded-full\" />\n </div>\n ))}\n </div>\n );\n }\n\n if (variant === 'detail') {\n return (\n <div className={cn('space-y-6', className)}>\n <div className=\"space-y-2\">\n <Skeleton className=\"h-8 w-1/3\" />\n <Skeleton className=\"h-4 w-1/2\" />\n </div>\n <div className=\"grid gap-4 sm:grid-cols-3\">\n {Array.from({ length: 3 }).map((_, i) => (\n <div key={i} className=\"rounded-lg border border-border-subtle p-4\">\n <Skeleton className=\"h-3 w-20\" />\n <Skeleton className=\"mt-2 h-7 w-16\" />\n </div>\n ))}\n </div>\n <div className=\"rounded-lg border border-border-subtle p-6\">\n <Skeleton className=\"h-5 w-1/4\" />\n <div className=\"mt-4 space-y-3\">\n <Skeleton className=\"h-4 w-full\" />\n <Skeleton className=\"h-4 w-5/6\" />\n <Skeleton className=\"h-4 w-4/6\" />\n </div>\n </div>\n </div>\n );\n }\n\n // Default: card grid\n return (\n <div className={cn('grid gap-4 sm:grid-cols-2 lg:grid-cols-3', className)}>\n {Array.from({ length: count }).map((_, i) => (\n <div key={i} className=\"rounded-lg border border-border-subtle p-4\">\n <Skeleton className=\"h-4 w-2/3\" />\n <Skeleton className=\"mt-2 h-3 w-1/2\" />\n <Skeleton className=\"mt-4 h-8 w-24\" />\n <div className=\"mt-3 flex justify-between\">\n <Skeleton className=\"h-5 w-16 rounded-full\" />\n <Skeleton className=\"h-7 w-14 rounded-md\" />\n </div>\n </div>\n ))}\n </div>\n );\n};\n"],"mappings":";;;;AAeA,IAAa,KAA6C,EAAE,aAAU,QAAQ,WAAQ,GAAG,mBACnF,MAAY,UAEZ,kBAAC,OAAD;CAAK,WAAW,EAAG,aAAa,EAAU;WACxC,kBAAC,OAAD;EAAK,WAAU;YAAf,CACE,kBAAC,OAAD;GAAK,WAAU;aACb,kBAAC,OAAD;IAAK,WAAU;cACZ,MAAM,KAAK,EAAE,QAAQ,GAAG,CAAC,CAAC,KAAK,GAAG,MACjC,kBAAC,GAAD,EAAkB,WAAU,YAAa,EAA1B,EAA0B,CACzC;IACE,CAAA;GACF,CAAA,EACL,MAAM,KAAK,EAAE,QAAQ,GAAO,CAAC,CAAC,KAAK,GAAG,MACrC,kBAAC,OAAD;GAAa,WAAU;aACpB,MAAM,KAAK,EAAE,QAAQ,GAAG,CAAC,CAAC,KAAK,GAAG,MACjC,kBAAC,GAAD,EAAkB,WAAU,YAAa,EAA1B,EAA0B,CACzC;GACE,EAJI,EAIJ,CACN,CACE;;CACF,CAAA,GAIN,MAAY,SAEZ,kBAAC,OAAD;CAAK,WAAW,EAAG,aAAa,EAAU;WACvC,MAAM,KAAK,EAAE,QAAQ,GAAO,CAAC,CAAC,KAAK,GAAG,MACrC,kBAAC,OAAD;EAAa,WAAU;YAAvB;GACE,kBAAC,GAAD,EAAU,WAAU,0BAA2B,CAAA;GAC/C,kBAAC,OAAD;IAAK,WAAU;cAAf,CACE,kBAAC,GAAD,EAAU,WAAU,aAAc,CAAA,EAClC,kBAAC,GAAD,EAAU,WAAU,aAAc,CAAA,CAC9B;;GACN,kBAAC,GAAD,EAAU,WAAU,yBAA0B,CAAA;GAC1C;IAPI,EAOJ,CACN;CACE,CAAA,GAIN,MAAY,WAEZ,kBAAC,OAAD;CAAK,WAAW,EAAG,aAAa,EAAU;WAA1C;EACE,kBAAC,OAAD;GAAK,WAAU;aAAf,CACE,kBAAC,GAAD,EAAU,WAAU,aAAc,CAAA,EAClC,kBAAC,GAAD,EAAU,WAAU,aAAc,CAAA,CAC9B;;EACN,kBAAC,OAAD;GAAK,WAAU;aACZ,MAAM,KAAK,EAAE,QAAQ,GAAG,CAAC,CAAC,KAAK,GAAG,MACjC,kBAAC,OAAD;IAAa,WAAU;cAAvB,CACE,kBAAC,GAAD,EAAU,WAAU,YAAa,CAAA,EACjC,kBAAC,GAAD,EAAU,WAAU,iBAAkB,CAAA,CAClC;MAHI,EAGJ,CACN;GACE,CAAA;EACN,kBAAC,OAAD;GAAK,WAAU;aAAf,CACE,kBAAC,GAAD,EAAU,WAAU,aAAc,CAAA,EAClC,kBAAC,OAAD;IAAK,WAAU;cAAf;KACE,kBAAC,GAAD,EAAU,WAAU,cAAe,CAAA;KACnC,kBAAC,GAAD,EAAU,WAAU,aAAc,CAAA;KAClC,kBAAC,GAAD,EAAU,WAAU,aAAc,CAAA;KAC9B;MACF;;EACF;KAMR,kBAAC,OAAD;CAAK,WAAW,EAAG,4CAA4C,EAAU;WACtE,MAAM,KAAK,EAAE,QAAQ,GAAO,CAAC,CAAC,KAAK,GAAG,MACrC,kBAAC,OAAD;EAAa,WAAU;YAAvB;GACE,kBAAC,GAAD,EAAU,WAAU,aAAc,CAAA;GAClC,kBAAC,GAAD,EAAU,WAAU,kBAAmB,CAAA;GACvC,kBAAC,GAAD,EAAU,WAAU,iBAAkB,CAAA;GACtC,kBAAC,OAAD;IAAK,WAAU;cAAf,CACE,kBAAC,GAAD,EAAU,WAAU,yBAA0B,CAAA,EAC9C,kBAAC,GAAD,EAAU,WAAU,uBAAwB,CAAA,CACxC;;GACF;IARI,EAQJ,CACN;CACE,CAAA"}
|
|
@@ -1,59 +1,26 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { X as r } from "lucide-react";
|
|
4
|
-
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
1
|
+
import { jsx as e, jsxs as t } from "react/jsx-runtime";
|
|
2
|
+
import { ResponsiveDialog as n, ResponsiveDialogContent as r, ResponsiveDialogDescription as i, ResponsiveDialogFooter as a, ResponsiveDialogHeader as o, ResponsiveDialogTitle as s } from "@burdenoff/fe-libs/ui";
|
|
5
3
|
//#region src/healthybowl/components/Modal.tsx
|
|
6
|
-
var
|
|
7
|
-
sm: "max-w-sm",
|
|
8
|
-
md: "max-w-
|
|
9
|
-
lg: "max-w-
|
|
10
|
-
xl: "max-w-
|
|
11
|
-
},
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
e.target === m.current && c();
|
|
26
|
-
},
|
|
27
|
-
children: /* @__PURE__ */ a("div", {
|
|
28
|
-
className: e("w-full rounded-lg border border-border-subtle bg-bg-surface shadow-xl", o[f]),
|
|
29
|
-
children: [
|
|
30
|
-
/* @__PURE__ */ a("div", {
|
|
31
|
-
className: "flex items-start justify-between border-b border-border-subtle px-6 py-4",
|
|
32
|
-
children: [/* @__PURE__ */ a("div", { children: [/* @__PURE__ */ i("h2", {
|
|
33
|
-
className: "text-lg font-semibold text-text-primary",
|
|
34
|
-
children: l
|
|
35
|
-
}), u && /* @__PURE__ */ i("p", {
|
|
36
|
-
className: "mt-0.5 text-sm text-text-secondary",
|
|
37
|
-
children: u
|
|
38
|
-
})] }), /* @__PURE__ */ i("button", {
|
|
39
|
-
onClick: c,
|
|
40
|
-
className: "rounded-md p-1 text-text-secondary hover:bg-bg-sunken hover:text-text-primary",
|
|
41
|
-
children: /* @__PURE__ */ i(r, { className: "h-5 w-5" })
|
|
42
|
-
})]
|
|
43
|
-
}),
|
|
44
|
-
/* @__PURE__ */ i("div", {
|
|
45
|
-
className: "max-h-[60vh] overflow-y-auto px-6 py-4",
|
|
46
|
-
children: d
|
|
47
|
-
}),
|
|
48
|
-
p && /* @__PURE__ */ i("div", {
|
|
49
|
-
className: "flex items-center justify-end gap-2 border-t border-border-subtle px-6 py-4",
|
|
50
|
-
children: p
|
|
51
|
-
})
|
|
52
|
-
]
|
|
53
|
-
})
|
|
54
|
-
}) : null;
|
|
55
|
-
};
|
|
4
|
+
var c = {
|
|
5
|
+
sm: "sm:max-w-sm",
|
|
6
|
+
md: "sm:max-w-lg",
|
|
7
|
+
lg: "sm:max-w-2xl",
|
|
8
|
+
xl: "sm:max-w-3xl"
|
|
9
|
+
}, l = ({ open: l, onClose: u, title: d, description: f, children: p, size: m = "md", footer: h }) => /* @__PURE__ */ e(n, {
|
|
10
|
+
open: l,
|
|
11
|
+
onOpenChange: (e) => {
|
|
12
|
+
e || u();
|
|
13
|
+
},
|
|
14
|
+
children: /* @__PURE__ */ t(r, {
|
|
15
|
+
className: c[m],
|
|
16
|
+
children: [
|
|
17
|
+
/* @__PURE__ */ t(o, { children: [d && /* @__PURE__ */ e(s, { children: d }), f && /* @__PURE__ */ e(i, { children: f })] }),
|
|
18
|
+
p,
|
|
19
|
+
h && /* @__PURE__ */ e(a, { children: h })
|
|
20
|
+
]
|
|
21
|
+
})
|
|
22
|
+
});
|
|
56
23
|
//#endregion
|
|
57
|
-
export {
|
|
24
|
+
export { l as Modal };
|
|
58
25
|
|
|
59
26
|
//# sourceMappingURL=Modal.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Modal.js","names":[],"sources":["../../../src/healthybowl/components/Modal.tsx"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"Modal.js","names":[],"sources":["../../../src/healthybowl/components/Modal.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport {\n ResponsiveDialog,\n ResponsiveDialogContent,\n ResponsiveDialogDescription,\n ResponsiveDialogFooter,\n ResponsiveDialogHeader,\n ResponsiveDialogTitle,\n} from '@burdenoff/fe-libs/ui';\n\ninterface ModalProps {\n open: boolean;\n onClose: () => void;\n title: string;\n description?: string;\n children: ReactNode;\n size?: 'sm' | 'md' | 'lg' | 'xl';\n footer?: ReactNode;\n}\n\nconst sizeClasses: Record<NonNullable<ModalProps['size']>, string> = {\n sm: 'sm:max-w-sm',\n md: 'sm:max-w-lg',\n lg: 'sm:max-w-2xl',\n xl: 'sm:max-w-3xl',\n};\n\n/**\n * Modal scaffold wrapping the Boff `ResponsiveDialog` (centred dialog on\n * desktop, bottom-sheet on mobile). The primitive provides the scrim, Escape\n * handling, scroll-lock and close affordance, so those are no longer hand-rolled\n * here. `onClose` fires whenever the dialog is dismissed.\n */\nexport const Modal: FC<ModalProps> = ({ open, onClose, title, description, children, size = 'md', footer }) => {\n return (\n <ResponsiveDialog\n open={open}\n onOpenChange={(next) => {\n if (!next) {\n onClose();\n }\n }}\n >\n <ResponsiveDialogContent className={sizeClasses[size]}>\n <ResponsiveDialogHeader>\n {title && <ResponsiveDialogTitle>{title}</ResponsiveDialogTitle>}\n {description && <ResponsiveDialogDescription>{description}</ResponsiveDialogDescription>}\n </ResponsiveDialogHeader>\n {children}\n {footer && <ResponsiveDialogFooter>{footer}</ResponsiveDialogFooter>}\n </ResponsiveDialogContent>\n </ResponsiveDialog>\n );\n};\n"],"mappings":";;;AAoBA,IAAM,IAA+D;CACnE,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACL,EAQY,KAAyB,EAAE,SAAM,YAAS,UAAO,gBAAa,aAAU,UAAO,MAAM,gBAE9F,kBAAC,GAAD;CACQ;CACN,eAAe,MAAS;AACtB,EAAK,KACH,GAAS;;WAIb,kBAAC,GAAD;EAAyB,WAAW,EAAY;YAAhD;GACE,kBAAC,GAAD,EAAA,UAAA,CACG,KAAS,kBAAC,GAAD,EAAA,UAAwB,GAA8B,CAAA,EAC/D,KAAe,kBAAC,GAAD,EAAA,UAA8B,GAA0C,CAAA,CACjE,EAAA,CAAA;GACxB;GACA,KAAU,kBAAC,GAAD,EAAA,UAAyB,GAAgC,CAAA;GAC5C;;CACT,CAAA"}
|
|
@@ -1,23 +1,17 @@
|
|
|
1
1
|
import { cn as e } from "../utils/helpers.js";
|
|
2
2
|
import { jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
3
|
+
import { PageContainer as r } from "@burdenoff/fe-libs/ui";
|
|
4
|
+
import { PageHeader as i } from "@burdenoff/fe-libs/chrome";
|
|
3
5
|
//#region src/healthybowl/components/PageLayout.tsx
|
|
4
|
-
var
|
|
5
|
-
className: e("
|
|
6
|
-
children: [/* @__PURE__ */
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}), i && /* @__PURE__ */ t("p", {
|
|
12
|
-
className: "mt-1 text-sm text-text-secondary",
|
|
13
|
-
children: i
|
|
14
|
-
})] }), a && /* @__PURE__ */ t("div", {
|
|
15
|
-
className: "flex items-center gap-2 shrink-0",
|
|
16
|
-
children: a
|
|
17
|
-
})]
|
|
18
|
-
}), o]
|
|
6
|
+
var a = ({ title: a, description: o, actions: s, children: c, className: l }) => /* @__PURE__ */ n(r, {
|
|
7
|
+
className: e("space-y-6", l),
|
|
8
|
+
children: [/* @__PURE__ */ t(i, {
|
|
9
|
+
title: a,
|
|
10
|
+
description: o,
|
|
11
|
+
actions: s
|
|
12
|
+
}), c]
|
|
19
13
|
});
|
|
20
14
|
//#endregion
|
|
21
|
-
export {
|
|
15
|
+
export { a as PageLayout };
|
|
22
16
|
|
|
23
17
|
//# sourceMappingURL=PageLayout.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PageLayout.js","names":[],"sources":["../../../src/healthybowl/components/PageLayout.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport { cn } from '../utils/helpers';\n\ninterface PageLayoutProps {\n title: string;\n description?: string;\n actions?: ReactNode;\n children: ReactNode;\n className?: string;\n}\n\nexport const PageLayout: FC<PageLayoutProps> = ({ title, description, actions, children, className }) => {\n return (\n <
|
|
1
|
+
{"version":3,"file":"PageLayout.js","names":[],"sources":["../../../src/healthybowl/components/PageLayout.tsx"],"sourcesContent":["import type { FC, ReactNode } from 'react';\nimport { PageContainer } from '@burdenoff/fe-libs/ui';\nimport { PageHeader } from '@burdenoff/fe-libs/chrome';\nimport { cn } from '../utils/helpers';\n\ninterface PageLayoutProps {\n title: string;\n description?: string;\n actions?: ReactNode;\n children: ReactNode;\n className?: string;\n}\n\n/**\n * Standard page scaffold. Wraps the Boff `PageContainer` (background + padding)\n * and `PageHeader` (title/description/actions) so every page is theme-compliant.\n * `PageContainer` supplies the default page padding (`p-4 sm:p-6`); we re-add the\n * inter-section vertical gap here so the header→content spacing is preserved.\n */\nexport const PageLayout: FC<PageLayoutProps> = ({ title, description, actions, children, className }) => {\n return (\n <PageContainer className={cn('space-y-6', className)}>\n <PageHeader title={title} description={description} actions={actions} />\n {children}\n </PageContainer>\n );\n};\n"],"mappings":";;;;;AAmBA,IAAa,KAAmC,EAAE,UAAO,gBAAa,YAAS,aAAU,mBAErF,kBAAC,GAAD;CAAe,WAAW,EAAG,aAAa,EAAU;WAApD,CACE,kBAAC,GAAD;EAAmB;EAAoB;EAAsB;EAAW,CAAA,EACvE,EACa"}
|
|
@@ -1,20 +1,18 @@
|
|
|
1
1
|
import { jsx as e, jsxs as t } from "react/jsx-runtime";
|
|
2
|
+
import { Spinner as n } from "@burdenoff/fe-libs/ui";
|
|
2
3
|
//#region src/healthybowl/components/PageLoader.tsx
|
|
3
|
-
function
|
|
4
|
+
function r() {
|
|
4
5
|
return /* @__PURE__ */ t("div", {
|
|
5
6
|
role: "status",
|
|
6
7
|
"aria-live": "polite",
|
|
7
8
|
className: "flex min-h-[40vh] flex-col items-center justify-center gap-3 p-12",
|
|
8
|
-
children: [/* @__PURE__ */ e("
|
|
9
|
-
"aria-hidden": "true",
|
|
10
|
-
className: "h-6 w-6 animate-spin rounded-full border-2 border-muted border-t-primary"
|
|
11
|
-
}), /* @__PURE__ */ e("p", {
|
|
9
|
+
children: [/* @__PURE__ */ e(n, {}), /* @__PURE__ */ e("p", {
|
|
12
10
|
className: "text-sm text-text-secondary",
|
|
13
11
|
children: "Loading…"
|
|
14
12
|
})]
|
|
15
13
|
});
|
|
16
14
|
}
|
|
17
15
|
//#endregion
|
|
18
|
-
export {
|
|
16
|
+
export { r as PageLoader };
|
|
19
17
|
|
|
20
18
|
//# sourceMappingURL=PageLoader.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PageLoader.js","names":[],"sources":["../../../src/healthybowl/components/PageLoader.tsx"],"sourcesContent":["/**\n * Centered loading indicator for in-page data fetches and route Suspense\n * fallbacks. Shown while a page's workspace-scoped data is still loading, so an\n * empty/error state never flashes before the data arrives.\n */\nexport function PageLoader() {\n return (\n <div role=\"status\" aria-live=\"polite\" className=\"flex min-h-[40vh] flex-col items-center justify-center gap-3 p-12\">\n <
|
|
1
|
+
{"version":3,"file":"PageLoader.js","names":[],"sources":["../../../src/healthybowl/components/PageLoader.tsx"],"sourcesContent":["import { Spinner } from '@burdenoff/fe-libs/ui';\n\n/**\n * Centered loading indicator for in-page data fetches and route Suspense\n * fallbacks. Shown while a page's workspace-scoped data is still loading, so an\n * empty/error state never flashes before the data arrives. Renders the Boff\n * `Spinner` primitive.\n */\nexport function PageLoader() {\n return (\n <div role=\"status\" aria-live=\"polite\" className=\"flex min-h-[40vh] flex-col items-center justify-center gap-3 p-12\">\n <Spinner />\n <p className=\"text-sm text-text-secondary\">Loading…</p>\n </div>\n );\n}\n"],"mappings":";;;AAQA,SAAgB,IAAa;AAC3B,QACE,kBAAC,OAAD;EAAK,MAAK;EAAS,aAAU;EAAS,WAAU;YAAhD,CACE,kBAAC,GAAD,EAAW,CAAA,EACX,kBAAC,KAAD;GAAG,WAAU;aAA8B;GAAY,CAAA,CACnD"}
|
|
@@ -1,25 +1,27 @@
|
|
|
1
1
|
import { cn as e } from "../utils/helpers.js";
|
|
2
2
|
import { jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
3
|
+
import { Badge as r } from "@burdenoff/fe-libs/ui";
|
|
3
4
|
//#region src/healthybowl/components/StatusBadge.tsx
|
|
4
|
-
var
|
|
5
|
-
success: "
|
|
6
|
-
warning: "
|
|
7
|
-
error: "
|
|
8
|
-
info: "
|
|
9
|
-
default: "
|
|
10
|
-
muted: "
|
|
11
|
-
},
|
|
12
|
-
success: "bg-success",
|
|
13
|
-
warning: "bg-warning",
|
|
14
|
-
error: "bg-
|
|
15
|
-
info: "bg-info",
|
|
16
|
-
default: "bg-
|
|
17
|
-
muted: "bg-
|
|
18
|
-
},
|
|
19
|
-
|
|
20
|
-
|
|
5
|
+
var i = {
|
|
6
|
+
success: "success",
|
|
7
|
+
warning: "warning",
|
|
8
|
+
error: "destructive",
|
|
9
|
+
info: "info",
|
|
10
|
+
default: "default",
|
|
11
|
+
muted: "secondary"
|
|
12
|
+
}, a = {
|
|
13
|
+
success: "bg-status-success-text",
|
|
14
|
+
warning: "bg-status-warning-text",
|
|
15
|
+
error: "bg-destructive",
|
|
16
|
+
info: "bg-status-info-text",
|
|
17
|
+
default: "bg-primary-foreground",
|
|
18
|
+
muted: "bg-text-secondary"
|
|
19
|
+
}, o = ({ label: o, variant: s = "default", dot: c = !1, className: l }) => /* @__PURE__ */ n(r, {
|
|
20
|
+
variant: i[s],
|
|
21
|
+
className: e("gap-1.5", l),
|
|
22
|
+
children: [c && /* @__PURE__ */ t("span", { className: e("h-1.5 w-1.5 rounded-full", a[s]) }), o]
|
|
21
23
|
});
|
|
22
24
|
//#endregion
|
|
23
|
-
export {
|
|
25
|
+
export { o as StatusBadge };
|
|
24
26
|
|
|
25
27
|
//# sourceMappingURL=StatusBadge.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusBadge.js","names":[],"sources":["../../../src/healthybowl/components/StatusBadge.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { cn } from '../utils/helpers';\n\ntype BadgeVariant = 'success' | 'warning' | 'error' | 'info' | 'default' | 'muted';\n\ninterface StatusBadgeProps {\n label: string;\n variant?: BadgeVariant;\n dot?: boolean;\n className?: string;\n}\n\nconst
|
|
1
|
+
{"version":3,"file":"StatusBadge.js","names":[],"sources":["../../../src/healthybowl/components/StatusBadge.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { Badge, type BadgeProps } from '@burdenoff/fe-libs/ui';\nimport { cn } from '../utils/helpers';\n\ntype BadgeVariant = 'success' | 'warning' | 'error' | 'info' | 'default' | 'muted';\n\ninterface StatusBadgeProps {\n label: string;\n variant?: BadgeVariant;\n dot?: boolean;\n className?: string;\n}\n\n/**\n * Maps the local status vocabulary onto Boff `Badge` variants. `Badge` has no\n * `muted`/`error` variants, so they map to the nearest equivalents:\n * - `muted` → `secondary`\n * - `error` → `destructive`\n * `success | warning | info | default` pass through unchanged.\n */\nconst variantMap: Record<BadgeVariant, NonNullable<BadgeProps['variant']>> = {\n success: 'success',\n warning: 'warning',\n error: 'destructive',\n info: 'info',\n default: 'default',\n muted: 'secondary',\n};\n\nconst dotStyles: Record<BadgeVariant, string> = {\n success: 'bg-status-success-text',\n warning: 'bg-status-warning-text',\n error: 'bg-destructive',\n info: 'bg-status-info-text',\n default: 'bg-primary-foreground',\n muted: 'bg-text-secondary',\n};\n\nexport const StatusBadge: FC<StatusBadgeProps> = ({ label, variant = 'default', dot = false, className }) => {\n return (\n <Badge variant={variantMap[variant]} className={cn('gap-1.5', className)}>\n {dot && <span className={cn('h-1.5 w-1.5 rounded-full', dotStyles[variant])} />}\n {label}\n </Badge>\n );\n};\n"],"mappings":";;;;AAoBA,IAAM,IAAuE;CAC3E,SAAS;CACT,SAAS;CACT,OAAO;CACP,MAAM;CACN,SAAS;CACT,OAAO;CACR,EAEK,IAA0C;CAC9C,SAAS;CACT,SAAS;CACT,OAAO;CACP,MAAM;CACN,SAAS;CACT,OAAO;CACR,EAEY,KAAqC,EAAE,UAAO,aAAU,WAAW,SAAM,IAAO,mBAEzF,kBAAC,GAAD;CAAO,SAAS,EAAW;CAAU,WAAW,EAAG,WAAW,EAAU;WAAxE,CACG,KAAO,kBAAC,QAAD,EAAM,WAAW,EAAG,4BAA4B,EAAU,GAAS,EAAI,CAAA,EAC9E,EACK"}
|