@burdenoff/microfe-healthybowl 2026.1125.4 → 2026.1126.1
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/HealthyBowlRoot.js +59 -55
- package/dist/healthybowl/components/FarmArt.d.ts +8 -0
- package/dist/healthybowl/components/FarmArt.js +47 -0
- package/dist/healthybowl/components/PageLayout.d.ts +5 -16
- package/dist/healthybowl/components/PageLayout.js +51 -24
- package/dist/healthybowl/components/sidebarTitle.d.ts +5 -0
- package/dist/healthybowl/components/sidebarTitle.js +20 -0
- package/dist/healthybowl/pages/field-capture/CaptureObservationForm.js +86 -153
- package/dist/healthybowl/pages/field-capture/FieldCapturePage.d.ts +6 -0
- package/dist/healthybowl/pages/field-capture/FieldCapturePage.js +54 -27
- package/dist/healthybowl/pages/field-capture/ObservationLogPage.js +120 -87
- package/dist/healthybowl/pages/field-capture/OfflineSettingsPage.js +2 -1
- package/dist/healthybowl/pages/field-capture/SyncHistoryPage.js +2 -1
- package/dist/healthybowl/pages/field-capture/useCaptureObservation.d.ts +47 -0
- package/dist/healthybowl/pages/field-capture/useCaptureObservation.js +106 -0
- package/dist/healthybowl/pages/field-capture/v2/CaptureComposer.d.ts +2 -0
- package/dist/healthybowl/pages/field-capture/v2/CaptureComposer.js +271 -0
- package/dist/healthybowl/pages/field-capture/v2/CaptureSide.d.ts +13 -0
- package/dist/healthybowl/pages/field-capture/v2/CaptureSide.js +263 -0
- package/dist/healthybowl/pages/field-capture/v2/FieldCaptureLayout.d.ts +12 -0
- package/dist/healthybowl/pages/field-capture/v2/FieldCaptureLayout.js +83 -0
- package/dist/healthybowl/pages/field-capture/v2/ObservationLogList.d.ts +21 -0
- package/dist/healthybowl/pages/field-capture/v2/ObservationLogList.js +163 -0
- package/dist/healthybowl/pages/field-capture/v2/kinds.d.ts +13 -0
- package/dist/healthybowl/pages/field-capture/v2/kinds.js +53 -0
- package/dist/healthybowl/types/index.d.ts +7 -0
- package/package.json +1 -1
|
@@ -5,12 +5,13 @@ import { ErrorBoundary as i } from "./components/ErrorBoundary.js";
|
|
|
5
5
|
import { ConfirmProvider as a } from "./components/ConfirmDialog.js";
|
|
6
6
|
import { OfflineSyncProvider as o } from "./offline/OfflineSyncProvider.js";
|
|
7
7
|
import { HeaderOfflinePill as s } from "./offline/HeaderOfflinePill.js";
|
|
8
|
-
import { normalizeBasePath as
|
|
9
|
-
import { useCallback as
|
|
10
|
-
import { useI18n as
|
|
11
|
-
import { Award as
|
|
12
|
-
import { jsx as
|
|
13
|
-
import { FeatureFlagProvider as
|
|
8
|
+
import { normalizeBasePath as te, setHbFormatLocale as ne } from "./utils/helpers.js";
|
|
9
|
+
import { useCallback as re, useEffect as c } from "react";
|
|
10
|
+
import { useI18n as ie } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
11
|
+
import { Award as ae, Banknote as oe, BarChart3 as se, Bug as ce, Cloud as le, CloudUpload as l, DollarSign as u, Factory as d, Fence as f, FlaskConical as p, Globe as m, HardHat as h, Home as g, Landmark as _, Leaf as v, LineChart as y, ListChecks as b, Map as x, Package as S, PawPrint as C, Radio as w, RefreshCw as T, ScanLine as E, ScanSearch as D, ShieldAlert as O, ShieldCheck as k, ShoppingCart as A, Sprout as j, Stethoscope as M, Tractor as ue, UserCheck as N, Users as P, Users2 as F, Wheat as I } from "lucide-react";
|
|
12
|
+
import { jsx as L, jsxs as R } from "react/jsx-runtime";
|
|
13
|
+
import { FeatureFlagProvider as z, useFeatureFlags as B } from "@burdenoff/fe-libs/shared/feature-flags";
|
|
14
|
+
import { WorkspacePagesV2Provider as V } from "@burdenoff/fe-libs/ui";
|
|
14
15
|
// src/healthybowl/HealthyBowlRoot.tsx
|
|
15
16
|
var H = /* @__PURE__ */ new Set([]), U = [
|
|
16
17
|
".lucide-arrow-right",
|
|
@@ -32,27 +33,27 @@ function G(e, t) {
|
|
|
32
33
|
return t ? e : e.filter((e) => !W.has(e.id));
|
|
33
34
|
}
|
|
34
35
|
var K = (n) => {
|
|
35
|
-
let { registerNavItems:
|
|
36
|
-
|
|
36
|
+
let { registerNavItems: z, registerFooterItems: W, basePath: K = "/" } = n, { error: q, getEvaluation: de, isLoading: fe } = B(), J = ee(de(t), fe || q !== null), { t: Y, locale: X } = ie();
|
|
37
|
+
ne(X);
|
|
37
38
|
let Z = H.has(X) ? "rtl" : "ltr";
|
|
38
|
-
|
|
39
|
+
c(() => {
|
|
39
40
|
let e = document.documentElement, t = e.getAttribute("dir");
|
|
40
41
|
return e.setAttribute("dir", Z), () => {
|
|
41
42
|
t === null ? e.removeAttribute("dir") : e.setAttribute("dir", t);
|
|
42
43
|
};
|
|
43
44
|
}, [Z]);
|
|
44
|
-
let Q =
|
|
45
|
+
let Q = re((e, t) => {
|
|
45
46
|
let n = Y(e);
|
|
46
47
|
return n === e ? t : n;
|
|
47
48
|
}, [Y]), $ = (e, t) => (e.endsWith("/") ? e.slice(0, -1) : e) + (t.startsWith("/") ? t : `/${t}`);
|
|
48
|
-
return
|
|
49
|
-
if (!
|
|
49
|
+
return c(() => {
|
|
50
|
+
if (!z) return;
|
|
50
51
|
let e = G([
|
|
51
52
|
{
|
|
52
53
|
id: "healthybowl-dashboard",
|
|
53
54
|
label: Q("healthybowl.nav.dashboard", "Dashboard"),
|
|
54
|
-
path:
|
|
55
|
-
icon: /* @__PURE__ */
|
|
55
|
+
path: te(K),
|
|
56
|
+
icon: /* @__PURE__ */ L(g, { size: 20 }),
|
|
56
57
|
order: 1,
|
|
57
58
|
group: "main"
|
|
58
59
|
},
|
|
@@ -60,7 +61,7 @@ var K = (n) => {
|
|
|
60
61
|
id: "healthybowl-farm",
|
|
61
62
|
label: Q("healthybowl.nav.farm", "My Farm"),
|
|
62
63
|
path: $(K, "farm"),
|
|
63
|
-
icon: /* @__PURE__ */
|
|
64
|
+
icon: /* @__PURE__ */ L(ue, { size: 20 }),
|
|
64
65
|
order: 2,
|
|
65
66
|
group: "main"
|
|
66
67
|
},
|
|
@@ -68,7 +69,7 @@ var K = (n) => {
|
|
|
68
69
|
id: "healthybowl-tasks",
|
|
69
70
|
label: Q("healthybowl.nav.tasks", "Tasks"),
|
|
70
71
|
path: $(K, "tasks"),
|
|
71
|
-
icon: /* @__PURE__ */
|
|
72
|
+
icon: /* @__PURE__ */ L(b, { size: 20 }),
|
|
72
73
|
order: 3,
|
|
73
74
|
group: "main"
|
|
74
75
|
},
|
|
@@ -76,7 +77,7 @@ var K = (n) => {
|
|
|
76
77
|
id: "healthybowl-crops",
|
|
77
78
|
label: Q("healthybowl.nav.crops", "Crops"),
|
|
78
79
|
path: $(K, "crops"),
|
|
79
|
-
icon: /* @__PURE__ */
|
|
80
|
+
icon: /* @__PURE__ */ L(I, { size: 20 }),
|
|
80
81
|
order: 10,
|
|
81
82
|
group: "farming"
|
|
82
83
|
},
|
|
@@ -84,7 +85,7 @@ var K = (n) => {
|
|
|
84
85
|
id: "healthybowl-livestock",
|
|
85
86
|
label: Q("healthybowl.nav.livestock", "Livestock"),
|
|
86
87
|
path: $(K, "livestock"),
|
|
87
|
-
icon: /* @__PURE__ */
|
|
88
|
+
icon: /* @__PURE__ */ L(C, { size: 20 }),
|
|
88
89
|
order: 11,
|
|
89
90
|
group: "farming"
|
|
90
91
|
},
|
|
@@ -92,7 +93,7 @@ var K = (n) => {
|
|
|
92
93
|
id: "healthybowl-livestock-analytics",
|
|
93
94
|
label: Q("healthybowl.nav.livestockAnalytics", "Livestock Analytics"),
|
|
94
95
|
path: $(K, "livestock/analytics"),
|
|
95
|
-
icon: /* @__PURE__ */
|
|
96
|
+
icon: /* @__PURE__ */ L(y, { size: 20 }),
|
|
96
97
|
order: 11.3,
|
|
97
98
|
group: "farming"
|
|
98
99
|
},
|
|
@@ -100,7 +101,7 @@ var K = (n) => {
|
|
|
100
101
|
id: "healthybowl-grazing",
|
|
101
102
|
label: Q("healthybowl.nav.grazing", "Grazing"),
|
|
102
103
|
path: $(K, "livestock/grazing"),
|
|
103
|
-
icon: /* @__PURE__ */
|
|
104
|
+
icon: /* @__PURE__ */ L(f, { size: 20 }),
|
|
104
105
|
order: 11.4,
|
|
105
106
|
group: "farming"
|
|
106
107
|
},
|
|
@@ -108,7 +109,7 @@ var K = (n) => {
|
|
|
108
109
|
id: "healthybowl-withdrawal-alerts",
|
|
109
110
|
label: Q("healthybowl.nav.withdrawalAlerts", "Withdrawal Alerts"),
|
|
110
111
|
path: $(K, "livestock/withdrawal-alerts"),
|
|
111
|
-
icon: /* @__PURE__ */
|
|
112
|
+
icon: /* @__PURE__ */ L(O, { size: 20 }),
|
|
112
113
|
order: 11.5,
|
|
113
114
|
group: "farming"
|
|
114
115
|
},
|
|
@@ -116,7 +117,7 @@ var K = (n) => {
|
|
|
116
117
|
id: "healthybowl-weather",
|
|
117
118
|
label: Q("healthybowl.nav.weather", "Weather"),
|
|
118
119
|
path: $(K, "weather"),
|
|
119
|
-
icon: /* @__PURE__ */
|
|
120
|
+
icon: /* @__PURE__ */ L(le, { size: 20 }),
|
|
120
121
|
order: 12,
|
|
121
122
|
group: "farming"
|
|
122
123
|
},
|
|
@@ -124,7 +125,7 @@ var K = (n) => {
|
|
|
124
125
|
id: "healthybowl-field-map",
|
|
125
126
|
label: Q("healthybowl.nav.fieldMap", "Field Map"),
|
|
126
127
|
path: $(K, "field-map"),
|
|
127
|
-
icon: /* @__PURE__ */
|
|
128
|
+
icon: /* @__PURE__ */ L(x, { size: 20 }),
|
|
128
129
|
order: 12.5,
|
|
129
130
|
group: "farming"
|
|
130
131
|
},
|
|
@@ -132,7 +133,7 @@ var K = (n) => {
|
|
|
132
133
|
id: "healthybowl-field-capture",
|
|
133
134
|
label: Q("healthybowl.nav.fieldCapture", "Field Capture"),
|
|
134
135
|
path: $(K, "field-capture"),
|
|
135
|
-
icon: /* @__PURE__ */
|
|
136
|
+
icon: /* @__PURE__ */ L(l, { size: 20 }),
|
|
136
137
|
order: 12.6,
|
|
137
138
|
group: "farming"
|
|
138
139
|
},
|
|
@@ -140,7 +141,7 @@ var K = (n) => {
|
|
|
140
141
|
id: "healthybowl-pending-sync",
|
|
141
142
|
label: Q("healthybowl.nav.pendingSync", "Pending Sync"),
|
|
142
143
|
path: $(K, "field-capture/pending"),
|
|
143
|
-
icon: /* @__PURE__ */
|
|
144
|
+
icon: /* @__PURE__ */ L(T, { size: 20 }),
|
|
144
145
|
order: 12.7,
|
|
145
146
|
group: "farming"
|
|
146
147
|
},
|
|
@@ -148,7 +149,7 @@ var K = (n) => {
|
|
|
148
149
|
id: "healthybowl-field-sensors",
|
|
149
150
|
label: Q("healthybowl.nav.fieldSensors", "Field Sensors"),
|
|
150
151
|
path: $(K, "field-sensors"),
|
|
151
|
-
icon: /* @__PURE__ */
|
|
152
|
+
icon: /* @__PURE__ */ L(w, { size: 20 }),
|
|
152
153
|
order: 12.75,
|
|
153
154
|
group: "farming"
|
|
154
155
|
},
|
|
@@ -156,7 +157,7 @@ var K = (n) => {
|
|
|
156
157
|
id: "healthybowl-soil",
|
|
157
158
|
label: Q("healthybowl.nav.soilHealth", "Soil Health"),
|
|
158
159
|
path: $(K, "soil"),
|
|
159
|
-
icon: /* @__PURE__ */
|
|
160
|
+
icon: /* @__PURE__ */ L(p, { size: 20 }),
|
|
160
161
|
order: 13,
|
|
161
162
|
group: "farming"
|
|
162
163
|
},
|
|
@@ -164,7 +165,7 @@ var K = (n) => {
|
|
|
164
165
|
id: "healthybowl-pest",
|
|
165
166
|
label: Q("healthybowl.nav.pestManagement", "Pest Management"),
|
|
166
167
|
path: $(K, "pest-management"),
|
|
167
|
-
icon: /* @__PURE__ */
|
|
168
|
+
icon: /* @__PURE__ */ L(ce, { size: 20 }),
|
|
168
169
|
order: 14,
|
|
169
170
|
group: "farming"
|
|
170
171
|
},
|
|
@@ -172,7 +173,7 @@ var K = (n) => {
|
|
|
172
173
|
id: "healthybowl-pest-ai",
|
|
173
174
|
label: Q("healthybowl.nav.aiPestDetection", "AI Pest Detection"),
|
|
174
175
|
path: $(K, "pest-management/ai-detection"),
|
|
175
|
-
icon: /* @__PURE__ */
|
|
176
|
+
icon: /* @__PURE__ */ L(D, { size: 20 }),
|
|
176
177
|
order: 14.5,
|
|
177
178
|
group: "farming"
|
|
178
179
|
},
|
|
@@ -180,7 +181,7 @@ var K = (n) => {
|
|
|
180
181
|
id: "healthybowl-production",
|
|
181
182
|
label: Q("healthybowl.nav.production", "Production"),
|
|
182
183
|
path: $(K, "production"),
|
|
183
|
-
icon: /* @__PURE__ */
|
|
184
|
+
icon: /* @__PURE__ */ L(d, { size: 20 }),
|
|
184
185
|
order: 20,
|
|
185
186
|
group: "business"
|
|
186
187
|
},
|
|
@@ -188,7 +189,7 @@ var K = (n) => {
|
|
|
188
189
|
id: "healthybowl-products",
|
|
189
190
|
label: Q("healthybowl.nav.products", "Products"),
|
|
190
191
|
path: $(K, "products"),
|
|
191
|
-
icon: /* @__PURE__ */
|
|
192
|
+
icon: /* @__PURE__ */ L(S, { size: 20 }),
|
|
192
193
|
order: 21,
|
|
193
194
|
group: "business"
|
|
194
195
|
},
|
|
@@ -196,7 +197,7 @@ var K = (n) => {
|
|
|
196
197
|
id: "healthybowl-marketplace",
|
|
197
198
|
label: Q("healthybowl.nav.marketplace", "Marketplace"),
|
|
198
199
|
path: $(K, "marketplace"),
|
|
199
|
-
icon: /* @__PURE__ */
|
|
200
|
+
icon: /* @__PURE__ */ L(A, { size: 20 }),
|
|
200
201
|
order: 22,
|
|
201
202
|
group: "business"
|
|
202
203
|
},
|
|
@@ -204,7 +205,7 @@ var K = (n) => {
|
|
|
204
205
|
id: "healthybowl-labour",
|
|
205
206
|
label: Q("healthybowl.nav.labour", "Labour"),
|
|
206
207
|
path: $(K, "labour"),
|
|
207
|
-
icon: /* @__PURE__ */
|
|
208
|
+
icon: /* @__PURE__ */ L(h, { size: 20 }),
|
|
208
209
|
order: 22.5,
|
|
209
210
|
group: "business"
|
|
210
211
|
},
|
|
@@ -212,7 +213,7 @@ var K = (n) => {
|
|
|
212
213
|
id: "healthybowl-coop",
|
|
213
214
|
label: Q("healthybowl.nav.coop", "Co-operative"),
|
|
214
215
|
path: $(K, "coop"),
|
|
215
|
-
icon: /* @__PURE__ */
|
|
216
|
+
icon: /* @__PURE__ */ L(F, { size: 20 }),
|
|
216
217
|
order: 22.5,
|
|
217
218
|
group: "business"
|
|
218
219
|
},
|
|
@@ -220,7 +221,7 @@ var K = (n) => {
|
|
|
220
221
|
id: "healthybowl-financial",
|
|
221
222
|
label: Q("healthybowl.nav.financial", "Financial"),
|
|
222
223
|
path: $(K, "financial"),
|
|
223
|
-
icon: /* @__PURE__ */
|
|
224
|
+
icon: /* @__PURE__ */ L(u, { size: 20 }),
|
|
224
225
|
order: 23,
|
|
225
226
|
group: "business"
|
|
226
227
|
},
|
|
@@ -228,7 +229,7 @@ var K = (n) => {
|
|
|
228
229
|
id: "healthybowl-financier",
|
|
229
230
|
label: Q("healthybowl.nav.financier", "Financier"),
|
|
230
231
|
path: $(K, "financier"),
|
|
231
|
-
icon: /* @__PURE__ */
|
|
232
|
+
icon: /* @__PURE__ */ L(oe, { size: 20 }),
|
|
232
233
|
order: 24,
|
|
233
234
|
group: "business"
|
|
234
235
|
},
|
|
@@ -236,7 +237,7 @@ var K = (n) => {
|
|
|
236
237
|
id: "healthybowl-compliance",
|
|
237
238
|
label: Q("healthybowl.nav.compliance", "Compliance"),
|
|
238
239
|
path: $(K, "compliance"),
|
|
239
|
-
icon: /* @__PURE__ */
|
|
240
|
+
icon: /* @__PURE__ */ L(k, { size: 20 }),
|
|
240
241
|
order: 30,
|
|
241
242
|
group: "compliance"
|
|
242
243
|
},
|
|
@@ -244,7 +245,7 @@ var K = (n) => {
|
|
|
244
245
|
id: "healthybowl-traceability",
|
|
245
246
|
label: Q("healthybowl.nav.traceability", "Traceability"),
|
|
246
247
|
path: $(K, "traceability"),
|
|
247
|
-
icon: /* @__PURE__ */
|
|
248
|
+
icon: /* @__PURE__ */ L(E, { size: 20 }),
|
|
248
249
|
order: 31,
|
|
249
250
|
group: "compliance"
|
|
250
251
|
},
|
|
@@ -252,7 +253,7 @@ var K = (n) => {
|
|
|
252
253
|
id: "healthybowl-sustainability",
|
|
253
254
|
label: Q("healthybowl.nav.sustainability", "Sustainability"),
|
|
254
255
|
path: $(K, "sustainability"),
|
|
255
|
-
icon: /* @__PURE__ */
|
|
256
|
+
icon: /* @__PURE__ */ L(v, { size: 20 }),
|
|
256
257
|
order: 32,
|
|
257
258
|
group: "compliance"
|
|
258
259
|
},
|
|
@@ -260,7 +261,7 @@ var K = (n) => {
|
|
|
260
261
|
id: "healthybowl-sustainability-carbon",
|
|
261
262
|
label: Q("healthybowl.nav.sustainabilityCarbon", "Carbon & GHG"),
|
|
262
263
|
path: $(K, "sustainability/carbon"),
|
|
263
|
-
icon: /* @__PURE__ */
|
|
264
|
+
icon: /* @__PURE__ */ L(d, { size: 20 }),
|
|
264
265
|
order: 32.1,
|
|
265
266
|
group: "compliance"
|
|
266
267
|
},
|
|
@@ -268,7 +269,7 @@ var K = (n) => {
|
|
|
268
269
|
id: "healthybowl-sustainability-soil",
|
|
269
270
|
label: Q("healthybowl.nav.sustainabilitySoil", "Soil Carbon"),
|
|
270
271
|
path: $(K, "sustainability/soil-carbon"),
|
|
271
|
-
icon: /* @__PURE__ */
|
|
272
|
+
icon: /* @__PURE__ */ L(j, { size: 20 }),
|
|
272
273
|
order: 32.2,
|
|
273
274
|
group: "compliance"
|
|
274
275
|
},
|
|
@@ -276,7 +277,7 @@ var K = (n) => {
|
|
|
276
277
|
id: "healthybowl-sustainability-credits",
|
|
277
278
|
label: Q("healthybowl.nav.sustainabilityCredits", "Carbon Credits"),
|
|
278
279
|
path: $(K, "sustainability/credits"),
|
|
279
|
-
icon: /* @__PURE__ */
|
|
280
|
+
icon: /* @__PURE__ */ L(ae, { size: 20 }),
|
|
280
281
|
order: 32.3,
|
|
281
282
|
group: "compliance"
|
|
282
283
|
},
|
|
@@ -284,7 +285,7 @@ var K = (n) => {
|
|
|
284
285
|
id: "healthybowl-sustainability-eudr",
|
|
285
286
|
label: Q("healthybowl.nav.sustainabilityEudr", "EUDR Due-Diligence"),
|
|
286
287
|
path: $(K, "sustainability/eudr"),
|
|
287
|
-
icon: /* @__PURE__ */
|
|
288
|
+
icon: /* @__PURE__ */ L(m, { size: 20 }),
|
|
288
289
|
order: 32.4,
|
|
289
290
|
group: "compliance"
|
|
290
291
|
},
|
|
@@ -292,7 +293,7 @@ var K = (n) => {
|
|
|
292
293
|
id: "healthybowl-schemes",
|
|
293
294
|
label: Q("healthybowl.nav.governmentSchemes", "Gov. Schemes"),
|
|
294
295
|
path: $(K, "government-schemes"),
|
|
295
|
-
icon: /* @__PURE__ */
|
|
296
|
+
icon: /* @__PURE__ */ L(_, { size: 20 }),
|
|
296
297
|
order: 40,
|
|
297
298
|
group: "support"
|
|
298
299
|
},
|
|
@@ -300,7 +301,7 @@ var K = (n) => {
|
|
|
300
301
|
id: "healthybowl-network",
|
|
301
302
|
label: Q("healthybowl.nav.network", "Network"),
|
|
302
303
|
path: $(K, "network"),
|
|
303
|
-
icon: /* @__PURE__ */
|
|
304
|
+
icon: /* @__PURE__ */ L(P, { size: 20 }),
|
|
304
305
|
order: 41,
|
|
305
306
|
group: "support"
|
|
306
307
|
},
|
|
@@ -308,7 +309,7 @@ var K = (n) => {
|
|
|
308
309
|
id: "healthybowl-analytics",
|
|
309
310
|
label: Q("healthybowl.nav.analytics", "Analytics"),
|
|
310
311
|
path: $(K, "analytics"),
|
|
311
|
-
icon: /* @__PURE__ */
|
|
312
|
+
icon: /* @__PURE__ */ L(se, { size: 20 }),
|
|
312
313
|
order: 42,
|
|
313
314
|
group: "support"
|
|
314
315
|
},
|
|
@@ -316,7 +317,7 @@ var K = (n) => {
|
|
|
316
317
|
id: "healthybowl-advisors",
|
|
317
318
|
label: Q("healthybowl.nav.advisors", "My Advisors"),
|
|
318
319
|
path: $(K, "advisors"),
|
|
319
|
-
icon: /* @__PURE__ */
|
|
320
|
+
icon: /* @__PURE__ */ L(N, { size: 20 }),
|
|
320
321
|
order: 43,
|
|
321
322
|
group: "support"
|
|
322
323
|
},
|
|
@@ -324,18 +325,18 @@ var K = (n) => {
|
|
|
324
325
|
id: "healthybowl-consultant",
|
|
325
326
|
label: Q("healthybowl.nav.consultant", "Consultant"),
|
|
326
327
|
path: $(K, "consultant"),
|
|
327
|
-
icon: /* @__PURE__ */
|
|
328
|
+
icon: /* @__PURE__ */ L(M, { size: 20 }),
|
|
328
329
|
order: 44,
|
|
329
330
|
group: "support"
|
|
330
331
|
}
|
|
331
332
|
], J);
|
|
332
|
-
return
|
|
333
|
+
return z(e);
|
|
333
334
|
}, [
|
|
334
|
-
|
|
335
|
+
z,
|
|
335
336
|
K,
|
|
336
337
|
J,
|
|
337
338
|
Q
|
|
338
|
-
]),
|
|
339
|
+
]), c(() => {
|
|
339
340
|
if (!W) return;
|
|
340
341
|
let e = [{
|
|
341
342
|
id: "healthybowl-status",
|
|
@@ -345,15 +346,18 @@ var K = (n) => {
|
|
|
345
346
|
section: "left"
|
|
346
347
|
}];
|
|
347
348
|
return W(e);
|
|
348
|
-
}, [W, Q]), /* @__PURE__ */
|
|
349
|
+
}, [W, Q]), /* @__PURE__ */ R(e, {
|
|
349
350
|
...n,
|
|
350
|
-
children: [/* @__PURE__ */
|
|
351
|
+
children: [/* @__PURE__ */ L("style", { children: U }), /* @__PURE__ */ L(i, { children: /* @__PURE__ */ L(a, { children: /* @__PURE__ */ R(o, { children: [/* @__PURE__ */ L(s, {}), /* @__PURE__ */ L(V, {
|
|
352
|
+
enabled: n.pagesV2 === !0,
|
|
353
|
+
children: /* @__PURE__ */ L(r, {})
|
|
354
|
+
})] }) }) })]
|
|
351
355
|
});
|
|
352
|
-
}, q = (e) => /* @__PURE__ */
|
|
356
|
+
}, q = (e) => /* @__PURE__ */ L(z, {
|
|
353
357
|
workspaceId: e.workspaceId ?? null,
|
|
354
358
|
gateway: "global",
|
|
355
359
|
flagKeys: n,
|
|
356
360
|
defaultEnabled: !0,
|
|
357
|
-
children: /* @__PURE__ */
|
|
361
|
+
children: /* @__PURE__ */ L(K, { ...e })
|
|
358
362
|
}, e.workspaceId ?? "no-workspace");
|
|
359
363
|
export { q as HealthyBowlRoot, G as filterHealthyBowlNavItemsForCarbon };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { EmptyStateSubject } from '@burdenoff/fe-libs/ui';
|
|
2
|
+
export interface FarmArtProps {
|
|
3
|
+
subject: EmptyStateSubject;
|
|
4
|
+
/** The box's side in px (the drawing fills it). */
|
|
5
|
+
size: number;
|
|
6
|
+
className?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare function FarmArt({ subject, size, className }: FarmArtProps): import('react').JSX.Element;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { cn as e } from "../utils/helpers.js";
|
|
2
|
+
import { useId as t } from "react";
|
|
3
|
+
import { jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
4
|
+
import { useEmptyStateSubjects as i } from "@burdenoff/fe-libs/ui";
|
|
5
|
+
import { useEmptyStateArt as a } from "@burdenoff/fe-libs/ui/empty-state-art-loader";
|
|
6
|
+
import { useEmptyStateProductArt as o } from "@burdenoff/fe-libs/ui/empty-state-product-art";
|
|
7
|
+
// src/healthybowl/components/FarmArt.tsx
|
|
8
|
+
function s({ subject: s, size: c, className: l }) {
|
|
9
|
+
let u = `fa${t().replace(/[^\w-]/g, "")}`, d = i(), f = d && Object.hasOwn(d, s) ? d[s] : void 0, p = o(f ? {
|
|
10
|
+
name: s,
|
|
11
|
+
load: f.load
|
|
12
|
+
} : null), m = a(!0), h = null;
|
|
13
|
+
m && f && p && p.shapes.length > 0 ? h = /* @__PURE__ */ n(m.EmptyStateDrawing, {
|
|
14
|
+
art: "plants",
|
|
15
|
+
uid: u,
|
|
16
|
+
shapes: p.shapes
|
|
17
|
+
}) : m && !f && m.isEmptyStateArtDrawn(s) && (h = /* @__PURE__ */ n(m.EmptyStateDrawing, {
|
|
18
|
+
art: s,
|
|
19
|
+
uid: u
|
|
20
|
+
}));
|
|
21
|
+
let g = {
|
|
22
|
+
"--es-art-size": `${c}px`,
|
|
23
|
+
width: c,
|
|
24
|
+
height: c
|
|
25
|
+
};
|
|
26
|
+
return /* @__PURE__ */ n("span", {
|
|
27
|
+
"data-empty-state": "glass",
|
|
28
|
+
"data-size": c <= 44 ? "inline" : "table",
|
|
29
|
+
"data-slot": "farm-art",
|
|
30
|
+
"aria-hidden": "true",
|
|
31
|
+
className: e("block shrink-0", l),
|
|
32
|
+
style: g,
|
|
33
|
+
children: /* @__PURE__ */ r("span", {
|
|
34
|
+
className: "es-art",
|
|
35
|
+
"data-state": h ? "art" : "icon",
|
|
36
|
+
"data-art": s,
|
|
37
|
+
children: [
|
|
38
|
+
/* @__PURE__ */ n("span", { className: "es-orb es-o1" }),
|
|
39
|
+
/* @__PURE__ */ n("span", { className: "es-orb es-o2" }),
|
|
40
|
+
/* @__PURE__ */ n("span", { className: "es-orb es-o3" }),
|
|
41
|
+
/* @__PURE__ */ n("span", { className: "es-tile" }),
|
|
42
|
+
h
|
|
43
|
+
]
|
|
44
|
+
})
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
export { s as FarmArt };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FC, ReactNode } from 'react';
|
|
2
|
-
import { NextStep } from '@burdenoff/fe-libs/ui';
|
|
2
|
+
import { ActionMenuItem, NextStep } from '@burdenoff/fe-libs/ui';
|
|
3
3
|
interface PageLayoutProps {
|
|
4
4
|
title: string;
|
|
5
5
|
description?: string;
|
|
@@ -54,21 +54,10 @@ interface PageLayoutProps {
|
|
|
54
54
|
/** Optional title for the NextSteps card. */
|
|
55
55
|
nextStepsTitle?: string;
|
|
56
56
|
className?: string;
|
|
57
|
+
/** Page kit only (BOFF-16667): beside the title, e.g. a status chip. Ignored without the opt-in. */
|
|
58
|
+
badge?: ReactNode;
|
|
59
|
+
/** Page kit only (BOFF-16667): the page's own ⋯ items, before Get help. Ignored without the opt-in. */
|
|
60
|
+
more?: ActionMenuItem[];
|
|
57
61
|
}
|
|
58
|
-
/**
|
|
59
|
-
* Standard page scaffold. Wraps the Boff `PageContainer` (background + padding)
|
|
60
|
-
* and `PageHeader` (title/description/actions) so every page is theme-compliant.
|
|
61
|
-
* With `hero`, the header is wrapped in a glassy mesh card with a living aurora
|
|
62
|
-
* backdrop (Boff UI 2.0) for the MFE's primary page; `titleAccent` clips the key
|
|
63
|
-
* noun into a brand gradient. `PageContainer` supplies the default page padding;
|
|
64
|
-
* we re-add the inter-section vertical gap so header→content spacing is preserved.
|
|
65
|
-
*
|
|
66
|
-
* ★ The page sits on the CANVAS (`variant="canvas"`), as FluidGrids' pages do
|
|
67
|
-
* (BOFF-15552): the shell paints the canvas and, in the Navigation v2 shell, the
|
|
68
|
-
* depth layer's two-accent glow over the top of the page. The default `surface`
|
|
69
|
-
* variant painted a lighter panel over both, so every page read as a box inside the
|
|
70
|
-
* page, and the glow was hidden behind it. The page's own padding stays: the shell
|
|
71
|
-
* adds no gutters (FluidGrids' rule), so this padding IS the page's edge.
|
|
72
|
-
*/
|
|
73
62
|
export declare const PageLayout: FC<PageLayoutProps>;
|
|
74
63
|
export {};
|
|
@@ -1,46 +1,73 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import { useOpenAssistantHelp as e } from "../../hooks/useOpenAssistantHelp.js";
|
|
2
|
+
import { useTr as t } from "../../shared/hooks/useTr.js";
|
|
3
|
+
import { cn as n } from "../utils/helpers.js";
|
|
4
|
+
import { GetHelpButton as r } from "./GetHelpButton.js";
|
|
5
|
+
import { useSidebarTitle as i } from "./sidebarTitle.js";
|
|
6
|
+
import { HelpCircle as a } from "lucide-react";
|
|
7
|
+
import { Fragment as o, jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
8
|
+
import { AuroraBackground as l, GradientText as u, NextSteps as d, PageContainer as f, PagePurpose as p, WorkspacePage as m, useWorkspacePagesV2 as h } from "@burdenoff/fe-libs/ui";
|
|
9
|
+
import { PageHeader as g } from "@burdenoff/fe-libs/chrome";
|
|
6
10
|
// src/healthybowl/components/PageLayout.tsx
|
|
7
|
-
var
|
|
11
|
+
var _ = (e, t) => {
|
|
8
12
|
if (!t) return e;
|
|
9
|
-
let
|
|
10
|
-
return
|
|
11
|
-
e.slice(0,
|
|
12
|
-
/* @__PURE__ */
|
|
13
|
-
e.slice(
|
|
13
|
+
let n = e.indexOf(t);
|
|
14
|
+
return n === -1 ? e : /* @__PURE__ */ c(o, { children: [
|
|
15
|
+
e.slice(0, n),
|
|
16
|
+
/* @__PURE__ */ s(u, { children: t }),
|
|
17
|
+
e.slice(n + t.length)
|
|
14
18
|
] });
|
|
15
|
-
},
|
|
16
|
-
let
|
|
17
|
-
|
|
18
|
-
|
|
19
|
+
}, v = ({ title: n, description: r, actions: o, children: l, helpPrompt: u, hideHelp: d = !1, testId: f, className: p, badge: h, more: _ = [] }) => {
|
|
20
|
+
let v = t(), y = e(), b = i(n), x = d ? _ : [..._, {
|
|
21
|
+
id: "help",
|
|
22
|
+
label: v("healthybowl.shared.getHelpButton.label", "Get Help"),
|
|
23
|
+
icon: a,
|
|
24
|
+
onSelect: () => y(u ?? `What is the ${b} page for, and how do I use it?`),
|
|
25
|
+
separatorBefore: _.length > 0
|
|
26
|
+
}];
|
|
27
|
+
return /* @__PURE__ */ s("div", {
|
|
28
|
+
className: "contents",
|
|
29
|
+
"data-testid": f,
|
|
30
|
+
children: /* @__PURE__ */ c(m, {
|
|
31
|
+
className: p,
|
|
32
|
+
children: [/* @__PURE__ */ s(g, {
|
|
33
|
+
variant: "compact",
|
|
34
|
+
title: b,
|
|
35
|
+
description: r,
|
|
36
|
+
actions: o,
|
|
37
|
+
more: x,
|
|
38
|
+
badge: h
|
|
39
|
+
}), l]
|
|
40
|
+
})
|
|
41
|
+
});
|
|
42
|
+
}, y = (e) => h() ? /* @__PURE__ */ s(v, { ...e }) : /* @__PURE__ */ s(b, { ...e }), b = ({ title: e, description: t, actions: i, children: a, hero: u = !1, titleAccent: m, purpose: h, purposeIcon: v, testId: y, nextSteps: b, nextStepsKey: x, nextStepsTitle: S, helpPrompt: C, hideHelp: w = !1, className: T }) => {
|
|
43
|
+
let E = w ? null : /* @__PURE__ */ s(r, { prompt: C ?? `What is the ${e} page for, and how do I use it?` }), D = E || i ? /* @__PURE__ */ c(o, { children: [E, i] }) : void 0, O = /* @__PURE__ */ s(g, {
|
|
44
|
+
title: _(e, m),
|
|
45
|
+
description: t,
|
|
19
46
|
actions: D
|
|
20
47
|
});
|
|
21
|
-
return /* @__PURE__ */
|
|
48
|
+
return /* @__PURE__ */ c(f, {
|
|
22
49
|
variant: "canvas",
|
|
23
|
-
className:
|
|
50
|
+
className: n("space-y-6", T),
|
|
24
51
|
"data-testid": y,
|
|
25
52
|
children: [
|
|
26
|
-
|
|
53
|
+
u ? /* @__PURE__ */ c("div", {
|
|
27
54
|
className: "relative overflow-hidden rounded-2xl border border-border-seam bg-hero-mesh px-6 py-5 shadow-pop",
|
|
28
|
-
children: [/* @__PURE__ */
|
|
55
|
+
children: [/* @__PURE__ */ s(l, { intensity: "subtle" }), /* @__PURE__ */ s("div", {
|
|
29
56
|
className: "relative z-10",
|
|
30
57
|
children: O
|
|
31
58
|
})]
|
|
32
59
|
}) : O,
|
|
33
|
-
|
|
60
|
+
h && /* @__PURE__ */ s(p, {
|
|
34
61
|
icon: v,
|
|
35
|
-
children:
|
|
62
|
+
children: h
|
|
36
63
|
}),
|
|
37
|
-
b && b.length > 0 && x && /* @__PURE__ */
|
|
64
|
+
b && b.length > 0 && x && /* @__PURE__ */ s(d, {
|
|
38
65
|
steps: b,
|
|
39
66
|
storageKey: x,
|
|
40
67
|
title: S
|
|
41
68
|
}),
|
|
42
|
-
|
|
69
|
+
a
|
|
43
70
|
]
|
|
44
71
|
});
|
|
45
72
|
};
|
|
46
|
-
export {
|
|
73
|
+
export { y as PageLayout };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { NavItem } from '@burdenoff/fe-libs/shared/hooks/shell/useNavRegistry';
|
|
2
|
+
/** The label of the registry row whose address is exactly `pathname`, depth-first. */
|
|
3
|
+
export declare function sidebarLabelFor(items: readonly NavItem[], pathname: string): string | undefined;
|
|
4
|
+
/** The page's title: its sidebar row's name when the page is a row, else `fallback`. */
|
|
5
|
+
export declare function useSidebarTitle(fallback: string): string;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { useLocation as e } from "react-router";
|
|
2
|
+
import { useNavRegistryStore as t } from "@burdenoff/fe-libs/shared/hooks/shell/useNavRegistry";
|
|
3
|
+
// src/healthybowl/components/sidebarTitle.ts
|
|
4
|
+
var n = (e) => {
|
|
5
|
+
let t = e.split(/[?#]/)[0] ?? "";
|
|
6
|
+
return t.length > 1 ? t.replace(/\/+$/, "") : t;
|
|
7
|
+
};
|
|
8
|
+
function r(e, t) {
|
|
9
|
+
let i = n(t);
|
|
10
|
+
for (let a of e) {
|
|
11
|
+
if (a.label && n(a.path) === i) return a.label;
|
|
12
|
+
let e = a.children ? r(a.children, t) : void 0;
|
|
13
|
+
if (e) return e;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
function i(n) {
|
|
17
|
+
let { pathname: i } = e();
|
|
18
|
+
return r(t((e) => e.items), i) ?? n;
|
|
19
|
+
}
|
|
20
|
+
export { r as sidebarLabelFor, i as useSidebarTitle };
|