@wealthx/shadcn 1.2.2 → 1.3.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/.turbo/turbo-build.log +193 -149
- package/CHANGELOG.md +28 -0
- package/dist/{chunk-4Y6R4WEC.mjs → chunk-2A5RRQGG.mjs} +9 -22
- package/dist/{chunk-TS2ZX2VS.mjs → chunk-2UM72RJ7.mjs} +11 -15
- package/dist/{chunk-A56YQQHG.mjs → chunk-3NCUZIFP.mjs} +2 -2
- package/dist/chunk-3OYFOX3X.mjs +79 -0
- package/dist/{chunk-RP3SQYA3.mjs → chunk-3TTACBDP.mjs} +9 -4
- package/dist/chunk-4GAWMKMI.mjs +710 -0
- package/dist/{chunk-VGSESELX.mjs → chunk-5FQIKDKP.mjs} +5 -5
- package/dist/{chunk-K3JYD4IU.mjs → chunk-5IS7G74I.mjs} +11 -4
- package/dist/chunk-6AW4KJHE.mjs +235 -0
- package/dist/chunk-6CR5N2JW.mjs +302 -0
- package/dist/{chunk-XIRTEFKH.mjs → chunk-6DZEXFNB.mjs} +36 -8
- package/dist/chunk-6O6KD7CE.mjs +271 -0
- package/dist/chunk-7PV3IWCN.mjs +33 -0
- package/dist/{chunk-SPJ5KXW7.mjs → chunk-7S5AESZO.mjs} +5 -5
- package/dist/{chunk-RYCLWMZ7.mjs → chunk-ABFDMHOR.mjs} +9 -7
- package/dist/{chunk-SWGT756Z.mjs → chunk-AMQZRHEZ.mjs} +10 -4
- package/dist/{chunk-WAZD7NFU.mjs → chunk-BKNFWEH2.mjs} +6 -6
- package/dist/{chunk-CLIN5525.mjs → chunk-C7CQJNMR.mjs} +1 -1
- package/dist/{chunk-D4ILTPOG.mjs → chunk-CFMQP5QS.mjs} +5 -4
- package/dist/{chunk-VPBN3WOO.mjs → chunk-DGHAXJBN.mjs} +9 -7
- package/dist/chunk-DOEO3CDL.mjs +27 -0
- package/dist/{chunk-5MEWU56Z.mjs → chunk-DUJTAXMH.mjs} +11 -6
- package/dist/{chunk-GGM2UYGG.mjs → chunk-EBXQWIYG.mjs} +10 -4
- package/dist/chunk-EWRB4PAD.mjs +468 -0
- package/dist/{chunk-ZSHYDDRB.mjs → chunk-FAKPBKLT.mjs} +6 -2
- package/dist/{chunk-A6AAWBPF.mjs → chunk-GHC7LLUX.mjs} +13 -4
- package/dist/chunk-HBZLGDIN.mjs +507 -0
- package/dist/{chunk-SIZMLSRU.mjs → chunk-HISNT2MG.mjs} +8 -6
- package/dist/{chunk-CGH4DRNG.mjs → chunk-HVY6KCCF.mjs} +10 -7
- package/dist/chunk-I3RZS7V2.mjs +136 -0
- package/dist/chunk-IAE3F7DR.mjs +1962 -0
- package/dist/{chunk-UT4KJR7V.mjs → chunk-IHMFS7NZ.mjs} +35 -74
- package/dist/{chunk-PCPLO5HT.mjs → chunk-IOJRDS6V.mjs} +96 -14
- package/dist/{chunk-LHYCMLVA.mjs → chunk-JKGDCQTZ.mjs} +11 -4
- package/dist/{chunk-H45TKD34.mjs → chunk-JMHR3YGZ.mjs} +1 -1
- package/dist/{chunk-4MN6UQHG.mjs → chunk-K5A5L6T2.mjs} +17 -39
- package/dist/chunk-LV35NGVG.mjs +272 -0
- package/dist/{chunk-FZIXGLMV.mjs → chunk-M3FV7LOK.mjs} +5 -12
- package/dist/{chunk-FMAXJ2SI.mjs → chunk-MBON7YRJ.mjs} +1 -1
- package/dist/chunk-MIZQHHUO.mjs +441 -0
- package/dist/chunk-MLNEWRWV.mjs +449 -0
- package/dist/chunk-MN5NYQCL.mjs +29 -0
- package/dist/chunk-NL3ZO62D.mjs +31 -0
- package/dist/{chunk-Q76O3RIQ.mjs → chunk-NMOI6CQD.mjs} +1 -1
- package/dist/{chunk-P6AM5V7O.mjs → chunk-OODBHKG7.mjs} +1 -1
- package/dist/chunk-PBL4OQV2.mjs +283 -0
- package/dist/{chunk-Y4QFWRNR.mjs → chunk-PU4YZQXV.mjs} +17 -18
- package/dist/chunk-Q2BGOAMG.mjs +202 -0
- package/dist/chunk-QMY3AZJH.mjs +80 -0
- package/dist/{chunk-BL3DXM2X.mjs → chunk-QZ4RE6NA.mjs} +11 -4
- package/dist/{chunk-VACKZOMY.mjs → chunk-R3VSPKNP.mjs} +3 -3
- package/dist/{chunk-OPNQAVVH.mjs → chunk-RJI6GKVF.mjs} +8 -6
- package/dist/{chunk-WG6JGJXB.mjs → chunk-T4BJLT57.mjs} +1 -1
- package/dist/chunk-UMTOX62O.mjs +415 -0
- package/dist/{chunk-7MMXNK3C.mjs → chunk-VLARHE5V.mjs} +8 -6
- package/dist/{chunk-2I5S2AMY.mjs → chunk-XREGSKX3.mjs} +2 -2
- package/dist/{chunk-JNQORUPP.mjs → chunk-YJG55G2H.mjs} +14 -11
- package/dist/components/ui/add-column-modal.js +42 -14
- package/dist/components/ui/add-column-modal.mjs +5 -5
- package/dist/components/ui/add-lead-modal.js +42 -11
- package/dist/components/ui/add-lead-modal.mjs +3 -3
- package/dist/components/ui/advisor-card.js +530 -0
- package/dist/components/ui/advisor-card.mjs +15 -0
- package/dist/components/ui/ai-assistant-drawer.js +11 -10
- package/dist/components/ui/ai-assistant-drawer.mjs +3 -3
- package/dist/components/ui/alert-dialog.js +2 -2
- package/dist/components/ui/alert-dialog.mjs +2 -2
- package/dist/components/ui/appointment-action-dialogs.js +1160 -0
- package/dist/components/ui/appointment-action-dialogs.mjs +23 -0
- package/dist/components/ui/appointment-availability-settings.js +1590 -0
- package/dist/components/ui/appointment-availability-settings.mjs +23 -0
- package/dist/components/ui/appointment-book-dialog.js +1744 -0
- package/dist/components/ui/appointment-book-dialog.mjs +27 -0
- package/dist/components/ui/appointment-calendar-view.js +833 -0
- package/dist/components/ui/appointment-calendar-view.mjs +14 -0
- package/dist/components/ui/appointment-detail-sheet.js +1517 -0
- package/dist/components/ui/appointment-detail-sheet.mjs +24 -0
- package/dist/components/ui/appointment-gmail-connect.js +467 -0
- package/dist/components/ui/appointment-gmail-connect.mjs +14 -0
- package/dist/components/ui/appointment-mini-card.js +345 -0
- package/dist/components/ui/appointment-mini-card.mjs +11 -0
- package/dist/components/ui/appointment-time-slot-picker.js +311 -0
- package/dist/components/ui/appointment-time-slot-picker.mjs +13 -0
- package/dist/components/ui/appointment-upcoming-card.js +1268 -0
- package/dist/components/ui/appointment-upcoming-card.mjs +21 -0
- package/dist/components/ui/backoffice-alert-history-chart.js +11 -5
- package/dist/components/ui/backoffice-alert-history-chart.mjs +5 -4
- package/dist/components/ui/backoffice-alerts-chart.js +786 -0
- package/dist/components/ui/backoffice-alerts-chart.mjs +19 -0
- package/dist/components/ui/backoffice-connections-chart.js +817 -0
- package/dist/components/ui/backoffice-connections-chart.mjs +19 -0
- package/dist/components/ui/backoffice-contact-history-chart.js +11 -5
- package/dist/components/ui/backoffice-contact-history-chart.mjs +5 -4
- package/dist/components/ui/badge.js +6 -6
- package/dist/components/ui/badge.mjs +1 -1
- package/dist/components/ui/borrowing-capacity-line-chart.js +30 -21
- package/dist/components/ui/borrowing-capacity-line-chart.mjs +5 -4
- package/dist/components/ui/button.js +2 -2
- package/dist/components/ui/button.mjs +1 -1
- package/dist/components/ui/calendar.js +2 -2
- package/dist/components/ui/calendar.mjs +2 -2
- package/dist/components/ui/card.js +1 -1
- package/dist/components/ui/card.mjs +1 -1
- package/dist/components/ui/cash-balance-line-chart.js +31 -23
- package/dist/components/ui/cash-balance-line-chart.mjs +5 -4
- package/dist/components/ui/cashflow-bar-chart.js +12 -5
- package/dist/components/ui/cashflow-bar-chart.mjs +5 -4
- package/dist/components/ui/chip.js +97 -18
- package/dist/components/ui/chip.mjs +3 -2
- package/dist/components/ui/color-picker.js +158 -28
- package/dist/components/ui/color-picker.mjs +3 -1
- package/dist/components/ui/data-table.js +140 -119
- package/dist/components/ui/data-table.mjs +3 -2
- package/dist/components/ui/date-picker.js +48 -27
- package/dist/components/ui/date-picker.mjs +4 -3
- package/dist/components/ui/dialog.js +37 -9
- package/dist/components/ui/dialog.mjs +2 -2
- package/dist/components/ui/expense-bar-chart.js +12 -5
- package/dist/components/ui/expense-bar-chart.mjs +5 -4
- package/dist/components/ui/field.mjs +2 -2
- package/dist/components/ui/financial-cards.js +322 -155
- package/dist/components/ui/financial-cards.mjs +5 -3
- package/dist/components/ui/financial-drawers.js +2 -2
- package/dist/components/ui/financial-drawers.mjs +3 -3
- package/dist/components/ui/financial-sections.js +14 -10
- package/dist/components/ui/financial-sections.mjs +6 -5
- package/dist/components/ui/income-bar-chart.js +12 -5
- package/dist/components/ui/income-bar-chart.mjs +5 -4
- package/dist/components/ui/input-group.js +2 -2
- package/dist/components/ui/input-group.mjs +2 -2
- package/dist/components/ui/kanban-column.js +52 -44
- package/dist/components/ui/kanban-column.mjs +7 -5
- package/dist/components/ui/opportunity-card.js +52 -44
- package/dist/components/ui/opportunity-card.mjs +6 -4
- package/dist/components/ui/opportunity-edit-modals.js +1367 -1263
- package/dist/components/ui/opportunity-edit-modals.mjs +8 -8
- package/dist/components/ui/opportunity-summary-tab.js +2744 -2157
- package/dist/components/ui/opportunity-summary-tab.mjs +14 -14
- package/dist/components/ui/page-header.js +92 -0
- package/dist/components/ui/page-header.mjs +8 -0
- package/dist/components/ui/page-top-bar.js +88 -0
- package/dist/components/ui/page-top-bar.mjs +8 -0
- package/dist/components/ui/pagination.js +303 -19
- package/dist/components/ui/pagination.mjs +11 -4
- package/dist/components/ui/pipeline-board.js +205 -191
- package/dist/components/ui/pipeline-board.mjs +9 -7
- package/dist/components/ui/pipeline-dialogs.js +114 -65
- package/dist/components/ui/pipeline-dialogs.mjs +7 -6
- package/dist/components/ui/pipeline-primitives.js +6 -6
- package/dist/components/ui/pipeline-primitives.mjs +2 -2
- package/dist/components/ui/property-cashflow-doughnut-chart.js +14 -12
- package/dist/components/ui/property-cashflow-doughnut-chart.mjs +5 -4
- package/dist/components/ui/property-debt-equity-doughnut-chart.js +14 -12
- package/dist/components/ui/property-debt-equity-doughnut-chart.mjs +5 -4
- package/dist/components/ui/property-mobile-estimate-line-chart.js +16 -14
- package/dist/components/ui/property-mobile-estimate-line-chart.mjs +5 -4
- package/dist/components/ui/sidebar-nav.js +426 -191
- package/dist/components/ui/sidebar-nav.mjs +5 -1
- package/dist/components/ui/stage-timeline.js +6 -6
- package/dist/components/ui/stage-timeline.mjs +3 -3
- package/dist/components/ui/transactions-expense-categories-doughnut-chart.js +18 -16
- package/dist/components/ui/transactions-expense-categories-doughnut-chart.mjs +5 -4
- package/dist/components/ui/transactions-income-expense-bar-chart.js +28 -12
- package/dist/components/ui/transactions-income-expense-bar-chart.mjs +5 -4
- package/dist/components/ui/transactions-liabilities-breakdown-doughnut-chart.js +18 -16
- package/dist/components/ui/transactions-liabilities-breakdown-doughnut-chart.mjs +5 -4
- package/dist/index.js +12258 -8611
- package/dist/index.mjs +258 -190
- package/dist/styles.css +1 -1
- package/package.json +71 -1
- package/src/components/index.tsx +115 -9
- package/src/components/ui/add-column-modal.tsx +7 -7
- package/src/components/ui/add-lead-modal.tsx +6 -3
- package/src/components/ui/advisor-card.tsx +284 -0
- package/src/components/ui/ai-assistant-drawer.tsx +4 -3
- package/src/components/ui/appointment-action-dialogs.tsx +297 -0
- package/src/components/ui/appointment-availability-settings.tsx +645 -0
- package/src/components/ui/appointment-book-dialog.tsx +618 -0
- package/src/components/ui/appointment-calendar-view.tsx +510 -0
- package/src/components/ui/appointment-detail-sheet.tsx +415 -0
- package/src/components/ui/appointment-gmail-connect.tsx +188 -0
- package/src/components/ui/appointment-mini-card.tsx +104 -0
- package/src/components/ui/appointment-time-slot-picker.tsx +123 -0
- package/src/components/ui/appointment-upcoming-card.tsx +635 -0
- package/src/components/ui/backoffice-alert-history-chart.tsx +10 -2
- package/src/components/ui/backoffice-alerts-chart.tsx +312 -0
- package/src/components/ui/backoffice-connections-chart.tsx +339 -0
- package/src/components/ui/backoffice-contact-history-chart.tsx +10 -2
- package/src/components/ui/badge.tsx +12 -6
- package/src/components/ui/borrowing-capacity-line-chart.tsx +4 -11
- package/src/components/ui/button.tsx +2 -2
- package/src/components/ui/card.tsx +1 -1
- package/src/components/ui/cash-balance-line-chart.tsx +4 -23
- package/src/components/ui/cashflow-bar-chart.tsx +9 -2
- package/src/components/ui/chart-shared.tsx +4 -11
- package/src/components/ui/chip.tsx +23 -19
- package/src/components/ui/color-picker.tsx +4 -2
- package/src/components/ui/data-table.tsx +28 -74
- package/src/components/ui/date-picker.tsx +42 -37
- package/src/components/ui/dialog.tsx +72 -6
- package/src/components/ui/expense-bar-chart.tsx +11 -2
- package/src/components/ui/financial-cards.tsx +99 -10
- package/src/components/ui/income-bar-chart.tsx +11 -2
- package/src/components/ui/opportunity-card.tsx +10 -39
- package/src/components/ui/opportunity-edit-modals.tsx +98 -36
- package/src/components/ui/opportunity-summary-tab.tsx +548 -232
- package/src/components/ui/page-header.tsx +57 -0
- package/src/components/ui/page-top-bar.tsx +48 -0
- package/src/components/ui/pagination.tsx +171 -22
- package/src/components/ui/pipeline-board.tsx +12 -5
- package/src/components/ui/property-cashflow-doughnut-chart.tsx +3 -1
- package/src/components/ui/property-debt-equity-doughnut-chart.tsx +3 -1
- package/src/components/ui/property-mobile-estimate-line-chart.tsx +3 -1
- package/src/components/ui/sidebar-nav.tsx +213 -157
- package/src/components/ui/transactions-expense-categories-doughnut-chart.tsx +3 -1
- package/src/components/ui/transactions-income-expense-bar-chart.tsx +12 -9
- package/src/components/ui/transactions-liabilities-breakdown-doughnut-chart.tsx +3 -1
- package/src/lib/format-currency.ts +44 -0
- package/src/lib/format-date.ts +50 -0
- package/src/lib/opportunity-constants.ts +12 -0
- package/src/styles/globals.css +17 -15
- package/src/styles/styles-css.ts +1 -1
- package/tsup.config.ts +14 -0
- package/dist/chunk-S4QRUQNW.mjs +0 -475
- package/dist/chunk-URGMJAE3.mjs +0 -1885
- package/dist/chunk-WNGWBVLV.mjs +0 -148
- package/dist/chunk-ZRSDX6OW.mjs +0 -385
- package/dist/{chunk-LLVQKSU3.mjs → chunk-GD4BJDJR.mjs} +3 -3
|
@@ -6,10 +6,12 @@ import {
|
|
|
6
6
|
IncomeCard,
|
|
7
7
|
OtherLiabilityCard,
|
|
8
8
|
PropertyCard
|
|
9
|
-
} from "../../chunk-
|
|
10
|
-
import "../../chunk-7XJHLGUV.mjs";
|
|
9
|
+
} from "../../chunk-IOJRDS6V.mjs";
|
|
11
10
|
import "../../chunk-OGOYQ7BG.mjs";
|
|
12
|
-
import "../../chunk-
|
|
11
|
+
import "../../chunk-7PV3IWCN.mjs";
|
|
12
|
+
import "../../chunk-7XJHLGUV.mjs";
|
|
13
|
+
import "../../chunk-BKNFWEH2.mjs";
|
|
14
|
+
import "../../chunk-XREGSKX3.mjs";
|
|
13
15
|
import "../../chunk-DBHJ5KC3.mjs";
|
|
14
16
|
import "../../chunk-VLQZANBF.mjs";
|
|
15
17
|
import "../../chunk-FWCSY2DS.mjs";
|
|
@@ -258,10 +258,10 @@ var buttonVariants = (0, import_class_variance_authority.cva)(
|
|
|
258
258
|
default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
|
|
259
259
|
secondary: "bg-brand-secondary text-brand-secondary-foreground shadow-xs hover:bg-brand-secondary/80 focus-visible:ring-brand-secondary/30",
|
|
260
260
|
destructive: "bg-destructive text-destructive-foreground shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
|
|
261
|
-
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
261
|
+
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground focus-visible:ring-border/50 dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
262
262
|
"outline-primary": "border border-primary text-foreground bg-transparent shadow-xs hover:bg-primary/5 focus-visible:ring-primary/50",
|
|
263
263
|
"outline-secondary": "border border-brand-secondary text-brand-secondary bg-transparent shadow-xs hover:bg-brand-secondary/10 focus-visible:ring-brand-secondary/30",
|
|
264
|
-
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs dark:hover:bg-accent/50",
|
|
264
|
+
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs focus-visible:ring-border/50 dark:hover:bg-accent/50",
|
|
265
265
|
link: "text-primary underline-offset-4 hover:underline"
|
|
266
266
|
},
|
|
267
267
|
size: {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
OpportunityDetailsDrawer,
|
|
3
3
|
SummaryReportDrawer
|
|
4
|
-
} from "../../chunk-
|
|
5
|
-
import "../../chunk-JHJHG4GO.mjs";
|
|
4
|
+
} from "../../chunk-7S5AESZO.mjs";
|
|
6
5
|
import "../../chunk-462HMNO4.mjs";
|
|
6
|
+
import "../../chunk-JHJHG4GO.mjs";
|
|
7
7
|
import "../../chunk-7YAU5CY6.mjs";
|
|
8
|
-
import "../../chunk-
|
|
8
|
+
import "../../chunk-XREGSKX3.mjs";
|
|
9
9
|
import "../../chunk-DBHJ5KC3.mjs";
|
|
10
10
|
import "../../chunk-FEZKMUCF.mjs";
|
|
11
11
|
import "../../chunk-QOJ2DQD6.mjs";
|
|
@@ -172,10 +172,10 @@ var buttonVariants = (0, import_class_variance_authority.cva)(
|
|
|
172
172
|
default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
|
|
173
173
|
secondary: "bg-brand-secondary text-brand-secondary-foreground shadow-xs hover:bg-brand-secondary/80 focus-visible:ring-brand-secondary/30",
|
|
174
174
|
destructive: "bg-destructive text-destructive-foreground shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
|
|
175
|
-
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
175
|
+
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground focus-visible:ring-border/50 dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
176
176
|
"outline-primary": "border border-primary text-foreground bg-transparent shadow-xs hover:bg-primary/5 focus-visible:ring-primary/50",
|
|
177
177
|
"outline-secondary": "border border-brand-secondary text-brand-secondary bg-transparent shadow-xs hover:bg-brand-secondary/10 focus-visible:ring-brand-secondary/30",
|
|
178
|
-
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs dark:hover:bg-accent/50",
|
|
178
|
+
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs focus-visible:ring-border/50 dark:hover:bg-accent/50",
|
|
179
179
|
link: "text-primary underline-offset-4 hover:underline"
|
|
180
180
|
},
|
|
181
181
|
size: {
|
|
@@ -339,6 +339,9 @@ function AccordionContent(_a) {
|
|
|
339
339
|
var React2 = __toESM(require("react"));
|
|
340
340
|
var import_lucide_react4 = require("lucide-react");
|
|
341
341
|
|
|
342
|
+
// src/lib/format-date.ts
|
|
343
|
+
var import_date_fns = require("date-fns");
|
|
344
|
+
|
|
342
345
|
// src/components/ui/badge.tsx
|
|
343
346
|
var import_class_variance_authority2 = require("class-variance-authority");
|
|
344
347
|
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
@@ -347,12 +350,12 @@ var badgeVariants = (0, import_class_variance_authority2.cva)(
|
|
|
347
350
|
{
|
|
348
351
|
variants: {
|
|
349
352
|
variant: {
|
|
350
|
-
default: "bg-primary text-
|
|
351
|
-
secondary: "bg-muted text-muted-foreground [a&]:hover:bg-muted/80",
|
|
352
|
-
destructive: "bg-destructive text-destructive-
|
|
353
|
-
success: "bg-success text-success-
|
|
354
|
-
warning: "bg-warning text-warning-
|
|
355
|
-
info: "bg-info text-info-
|
|
353
|
+
default: "border-primary/40 bg-primary/10 text-foreground [a&]:hover:bg-primary/15",
|
|
354
|
+
secondary: "border-border bg-muted text-muted-foreground [a&]:hover:bg-muted/80",
|
|
355
|
+
destructive: "border-destructive/40 bg-destructive/10 text-destructive-text focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/15",
|
|
356
|
+
success: "border-success/40 bg-success/10 text-success-text [a&]:hover:bg-success/15",
|
|
357
|
+
warning: "border-warning/40 bg-warning/10 text-warning-text [a&]:hover:bg-warning/15",
|
|
358
|
+
info: "border-info/40 bg-info/10 text-info-text [a&]:hover:bg-info/15",
|
|
356
359
|
outline: "border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
|
|
357
360
|
ghost: "[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
|
|
358
361
|
link: "text-primary underline-offset-4 [a&]:hover:underline"
|
|
@@ -608,12 +611,13 @@ function PropertyCard({
|
|
|
608
611
|
),
|
|
609
612
|
children: [
|
|
610
613
|
isLinkedToBank ? /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
|
|
611
|
-
|
|
614
|
+
Button,
|
|
612
615
|
{
|
|
613
616
|
type: "button",
|
|
617
|
+
variant: "ghost",
|
|
614
618
|
"aria-expanded": expanded,
|
|
615
619
|
onClick: () => setExpanded((prev) => !prev),
|
|
616
|
-
className: "
|
|
620
|
+
className: "h-auto w-full justify-start gap-1.5 px-5 py-3 text-left",
|
|
617
621
|
children: [
|
|
618
622
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "text-label-medium text-foreground", children: address }),
|
|
619
623
|
type && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Badge, { variant: "outline", children: type }),
|
|
@@ -7,14 +7,15 @@ import {
|
|
|
7
7
|
LoanScenarioSection,
|
|
8
8
|
OtherLiabilitiesSection,
|
|
9
9
|
PropertyHoldingsSection
|
|
10
|
-
} from "../../chunk-
|
|
11
|
-
import "../../chunk-
|
|
12
|
-
import "../../chunk-7XJHLGUV.mjs";
|
|
10
|
+
} from "../../chunk-3NCUZIFP.mjs";
|
|
11
|
+
import "../../chunk-IOJRDS6V.mjs";
|
|
13
12
|
import "../../chunk-OGOYQ7BG.mjs";
|
|
14
|
-
import "../../chunk-
|
|
13
|
+
import "../../chunk-7PV3IWCN.mjs";
|
|
14
|
+
import "../../chunk-7XJHLGUV.mjs";
|
|
15
|
+
import "../../chunk-BKNFWEH2.mjs";
|
|
15
16
|
import "../../chunk-MARPPFOJ.mjs";
|
|
16
17
|
import "../../chunk-FH6QVUVZ.mjs";
|
|
17
|
-
import "../../chunk-
|
|
18
|
+
import "../../chunk-XREGSKX3.mjs";
|
|
18
19
|
import "../../chunk-DBHJ5KC3.mjs";
|
|
19
20
|
import "../../chunk-VLQZANBF.mjs";
|
|
20
21
|
import "../../chunk-FWCSY2DS.mjs";
|
|
@@ -134,7 +134,7 @@ function CardHeader(_a) {
|
|
|
134
134
|
"div",
|
|
135
135
|
__spreadValues({
|
|
136
136
|
className: cn(
|
|
137
|
-
"@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-
|
|
137
|
+
"@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-center gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",
|
|
138
138
|
className
|
|
139
139
|
),
|
|
140
140
|
"data-slot": "card-header"
|
|
@@ -298,10 +298,10 @@ var buttonVariants = (0, import_class_variance_authority2.cva)(
|
|
|
298
298
|
default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
|
|
299
299
|
secondary: "bg-brand-secondary text-brand-secondary-foreground shadow-xs hover:bg-brand-secondary/80 focus-visible:ring-brand-secondary/30",
|
|
300
300
|
destructive: "bg-destructive text-destructive-foreground shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
|
|
301
|
-
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
301
|
+
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground focus-visible:ring-border/50 dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
302
302
|
"outline-primary": "border border-primary text-foreground bg-transparent shadow-xs hover:bg-primary/5 focus-visible:ring-primary/50",
|
|
303
303
|
"outline-secondary": "border border-brand-secondary text-brand-secondary bg-transparent shadow-xs hover:bg-brand-secondary/10 focus-visible:ring-brand-secondary/30",
|
|
304
|
-
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs dark:hover:bg-accent/50",
|
|
304
|
+
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs focus-visible:ring-border/50 dark:hover:bg-accent/50",
|
|
305
305
|
link: "text-primary underline-offset-4 hover:underline"
|
|
306
306
|
},
|
|
307
307
|
size: {
|
|
@@ -454,7 +454,14 @@ function ChartPeriodButton({
|
|
|
454
454
|
|
|
455
455
|
// src/components/ui/income-bar-chart.tsx
|
|
456
456
|
var import_jsx_runtime7 = require("react/jsx-runtime");
|
|
457
|
-
import_chart.Chart.register(
|
|
457
|
+
import_chart.Chart.register(
|
|
458
|
+
import_chart.CategoryScale,
|
|
459
|
+
import_chart.LinearScale,
|
|
460
|
+
import_chart.BarController,
|
|
461
|
+
import_chart.BarElement,
|
|
462
|
+
import_chart.Tooltip,
|
|
463
|
+
import_chart.Legend
|
|
464
|
+
);
|
|
458
465
|
function IncomeBarChart({
|
|
459
466
|
incomeData,
|
|
460
467
|
title = "Income",
|
|
@@ -592,7 +599,7 @@ function IncomeBarChart({
|
|
|
592
599
|
style: { maxWidth: width, fontFamily },
|
|
593
600
|
children: [
|
|
594
601
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(CardHeader, { className: "px-3 sm:px-6", children: [
|
|
595
|
-
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(CardTitle, { className: "text-
|
|
602
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(CardTitle, { className: "text-xs font-semibold uppercase tracking-wide", children: title }),
|
|
596
603
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(CardAction, { children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { className: "flex gap-0.5 sm:gap-1", children: periods.map((p) => /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
597
604
|
ChartPeriodButton,
|
|
598
605
|
{
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
IncomeBarChart
|
|
3
|
-
} from "../../chunk-
|
|
3
|
+
} from "../../chunk-QZ4RE6NA.mjs";
|
|
4
4
|
import "../../chunk-D6ID6M4V.mjs";
|
|
5
|
-
import "../../chunk-
|
|
5
|
+
import "../../chunk-M3FV7LOK.mjs";
|
|
6
|
+
import "../../chunk-MN5NYQCL.mjs";
|
|
6
7
|
import "../../chunk-NQPOYKAQ.mjs";
|
|
7
|
-
import "../../chunk-
|
|
8
|
-
import "../../chunk-
|
|
8
|
+
import "../../chunk-C7CQJNMR.mjs";
|
|
9
|
+
import "../../chunk-XREGSKX3.mjs";
|
|
9
10
|
import "../../chunk-DBHJ5KC3.mjs";
|
|
10
11
|
import "../../chunk-FEZKMUCF.mjs";
|
|
11
12
|
import "../../chunk-QOJ2DQD6.mjs";
|
|
@@ -170,10 +170,10 @@ var buttonVariants = (0, import_class_variance_authority.cva)(
|
|
|
170
170
|
default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
|
|
171
171
|
secondary: "bg-brand-secondary text-brand-secondary-foreground shadow-xs hover:bg-brand-secondary/80 focus-visible:ring-brand-secondary/30",
|
|
172
172
|
destructive: "bg-destructive text-destructive-foreground shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
|
|
173
|
-
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
173
|
+
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground focus-visible:ring-border/50 dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
174
174
|
"outline-primary": "border border-primary text-foreground bg-transparent shadow-xs hover:bg-primary/5 focus-visible:ring-primary/50",
|
|
175
175
|
"outline-secondary": "border border-brand-secondary text-brand-secondary bg-transparent shadow-xs hover:bg-brand-secondary/10 focus-visible:ring-brand-secondary/30",
|
|
176
|
-
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs dark:hover:bg-accent/50",
|
|
176
|
+
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs focus-visible:ring-border/50 dark:hover:bg-accent/50",
|
|
177
177
|
link: "text-primary underline-offset-4 hover:underline"
|
|
178
178
|
},
|
|
179
179
|
size: {
|
|
@@ -5,10 +5,10 @@ import {
|
|
|
5
5
|
InputGroupInput,
|
|
6
6
|
InputGroupText,
|
|
7
7
|
InputGroupTextarea
|
|
8
|
-
} from "../../chunk-
|
|
8
|
+
} from "../../chunk-NMOI6CQD.mjs";
|
|
9
9
|
import "../../chunk-34NWQURD.mjs";
|
|
10
10
|
import "../../chunk-GYMYRIZP.mjs";
|
|
11
|
-
import "../../chunk-
|
|
11
|
+
import "../../chunk-XREGSKX3.mjs";
|
|
12
12
|
import "../../chunk-DBHJ5KC3.mjs";
|
|
13
13
|
import "../../chunk-VLQZANBF.mjs";
|
|
14
14
|
import "../../chunk-FWCSY2DS.mjs";
|
|
@@ -168,12 +168,12 @@ var badgeVariants = (0, import_class_variance_authority.cva)(
|
|
|
168
168
|
{
|
|
169
169
|
variants: {
|
|
170
170
|
variant: {
|
|
171
|
-
default: "bg-primary text-
|
|
172
|
-
secondary: "bg-muted text-muted-foreground [a&]:hover:bg-muted/80",
|
|
173
|
-
destructive: "bg-destructive text-destructive-
|
|
174
|
-
success: "bg-success text-success-
|
|
175
|
-
warning: "bg-warning text-warning-
|
|
176
|
-
info: "bg-info text-info-
|
|
171
|
+
default: "border-primary/40 bg-primary/10 text-foreground [a&]:hover:bg-primary/15",
|
|
172
|
+
secondary: "border-border bg-muted text-muted-foreground [a&]:hover:bg-muted/80",
|
|
173
|
+
destructive: "border-destructive/40 bg-destructive/10 text-destructive-text focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/15",
|
|
174
|
+
success: "border-success/40 bg-success/10 text-success-text [a&]:hover:bg-success/15",
|
|
175
|
+
warning: "border-warning/40 bg-warning/10 text-warning-text [a&]:hover:bg-warning/15",
|
|
176
|
+
info: "border-info/40 bg-info/10 text-info-text [a&]:hover:bg-info/15",
|
|
177
177
|
outline: "border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
|
|
178
178
|
ghost: "[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
|
|
179
179
|
link: "text-primary underline-offset-4 [a&]:hover:underline"
|
|
@@ -218,10 +218,10 @@ var buttonVariants = (0, import_class_variance_authority2.cva)(
|
|
|
218
218
|
default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
|
|
219
219
|
secondary: "bg-brand-secondary text-brand-secondary-foreground shadow-xs hover:bg-brand-secondary/80 focus-visible:ring-brand-secondary/30",
|
|
220
220
|
destructive: "bg-destructive text-destructive-foreground shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
|
|
221
|
-
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
221
|
+
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground focus-visible:ring-border/50 dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
222
222
|
"outline-primary": "border border-primary text-foreground bg-transparent shadow-xs hover:bg-primary/5 focus-visible:ring-primary/50",
|
|
223
223
|
"outline-secondary": "border border-brand-secondary text-brand-secondary bg-transparent shadow-xs hover:bg-brand-secondary/10 focus-visible:ring-brand-secondary/30",
|
|
224
|
-
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs dark:hover:bg-accent/50",
|
|
224
|
+
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs focus-visible:ring-border/50 dark:hover:bg-accent/50",
|
|
225
225
|
link: "text-primary underline-offset-4 hover:underline"
|
|
226
226
|
},
|
|
227
227
|
size: {
|
|
@@ -387,6 +387,43 @@ function DropdownMenuSeparator(_a) {
|
|
|
387
387
|
// src/components/ui/opportunity-card.tsx
|
|
388
388
|
var import_lucide_react6 = require("lucide-react");
|
|
389
389
|
|
|
390
|
+
// src/lib/format-currency.ts
|
|
391
|
+
function formatCurrency(value, options) {
|
|
392
|
+
const { decimals = 0, showSign = false } = options != null ? options : {};
|
|
393
|
+
const abs = Math.abs(value);
|
|
394
|
+
const formatted = new Intl.NumberFormat("en-AU", {
|
|
395
|
+
style: "currency",
|
|
396
|
+
currency: "AUD",
|
|
397
|
+
minimumFractionDigits: decimals,
|
|
398
|
+
maximumFractionDigits: decimals
|
|
399
|
+
}).format(abs);
|
|
400
|
+
if (!showSign) return value < 0 ? `-${formatted}` : formatted;
|
|
401
|
+
if (value > 0) return `+${formatted}`;
|
|
402
|
+
if (value < 0) return `-${formatted}`;
|
|
403
|
+
return formatted;
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
// src/lib/format-date.ts
|
|
407
|
+
var import_date_fns = require("date-fns");
|
|
408
|
+
function safeParse(iso) {
|
|
409
|
+
return (0, import_date_fns.parseISO)(iso);
|
|
410
|
+
}
|
|
411
|
+
function formatDateShort(iso) {
|
|
412
|
+
if (!iso) return "\u2014";
|
|
413
|
+
try {
|
|
414
|
+
return (0, import_date_fns.format)(safeParse(iso), "dd MMM yyyy");
|
|
415
|
+
} catch (e) {
|
|
416
|
+
return iso;
|
|
417
|
+
}
|
|
418
|
+
}
|
|
419
|
+
function formatDateDayMonth(iso) {
|
|
420
|
+
try {
|
|
421
|
+
return (0, import_date_fns.format)(safeParse(iso), "dd MMM");
|
|
422
|
+
} catch (e) {
|
|
423
|
+
return iso;
|
|
424
|
+
}
|
|
425
|
+
}
|
|
426
|
+
|
|
390
427
|
// src/components/ui/separator.tsx
|
|
391
428
|
var import_separator = require("@base-ui/react/separator");
|
|
392
429
|
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
@@ -606,34 +643,6 @@ function resolvePriority(days, warningDays, priorityDays, priority) {
|
|
|
606
643
|
if (warningDays !== void 0 || priorityDays !== void 0) return "LOW";
|
|
607
644
|
return priority;
|
|
608
645
|
}
|
|
609
|
-
function formatAmount(amount) {
|
|
610
|
-
return new Intl.NumberFormat("en-AU", {
|
|
611
|
-
style: "currency",
|
|
612
|
-
currency: "AUD",
|
|
613
|
-
maximumFractionDigits: 0
|
|
614
|
-
}).format(amount);
|
|
615
|
-
}
|
|
616
|
-
function formatDate(iso) {
|
|
617
|
-
try {
|
|
618
|
-
return new Date(iso).toLocaleDateString("en-AU", {
|
|
619
|
-
day: "2-digit",
|
|
620
|
-
month: "short",
|
|
621
|
-
year: "numeric"
|
|
622
|
-
});
|
|
623
|
-
} catch (e) {
|
|
624
|
-
return iso;
|
|
625
|
-
}
|
|
626
|
-
}
|
|
627
|
-
function formatHoldDate(iso) {
|
|
628
|
-
try {
|
|
629
|
-
return new Date(iso).toLocaleDateString("en-AU", {
|
|
630
|
-
day: "2-digit",
|
|
631
|
-
month: "short"
|
|
632
|
-
});
|
|
633
|
-
} catch (e) {
|
|
634
|
-
return iso;
|
|
635
|
-
}
|
|
636
|
-
}
|
|
637
646
|
function formatLoanType(type) {
|
|
638
647
|
return type.split("-").map((w) => w.charAt(0).toUpperCase() + w.slice(1)).join(" ");
|
|
639
648
|
}
|
|
@@ -695,7 +704,7 @@ function OpportunityCard({
|
|
|
695
704
|
children: [
|
|
696
705
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_lucide_react6.Clock, { className: "size-3 shrink-0" }),
|
|
697
706
|
"On hold until ",
|
|
698
|
-
|
|
707
|
+
formatDateDayMonth(onHoldTo)
|
|
699
708
|
]
|
|
700
709
|
}
|
|
701
710
|
),
|
|
@@ -710,17 +719,16 @@ function OpportunityCard({
|
|
|
710
719
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex items-start justify-between gap-2", children: [
|
|
711
720
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex min-w-0 flex-1 flex-col gap-1", children: [
|
|
712
721
|
(loanPurposeLabel || loanType) && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Badge, { variant: "outline", className: "self-start", children: loanPurposeLabel != null ? loanPurposeLabel : formatLoanType(loanType) }),
|
|
713
|
-
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "text-base font-bold tabular-nums text-foreground", children:
|
|
722
|
+
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "text-base font-bold tabular-nums text-foreground", children: formatCurrency(amount) })
|
|
714
723
|
] }),
|
|
715
724
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex items-center gap-1 -mr-1 -mt-1", children: [
|
|
716
725
|
onLaunchAssistant && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
717
|
-
|
|
726
|
+
Button,
|
|
718
727
|
{
|
|
719
728
|
type: "button",
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
),
|
|
729
|
+
variant: "ghost",
|
|
730
|
+
size: "icon",
|
|
731
|
+
className: "size-7 shrink-0",
|
|
724
732
|
onClick: onLaunchAssistant,
|
|
725
733
|
"aria-label": "Launch AI Assistant",
|
|
726
734
|
title: "Launch AI Assistant",
|
|
@@ -776,7 +784,7 @@ function OpportunityCard({
|
|
|
776
784
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex items-center justify-between", children: [
|
|
777
785
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("span", { className: "flex items-center gap-1.5 text-xs text-muted-foreground", children: [
|
|
778
786
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_lucide_react6.Calendar, { className: "size-3 shrink-0", "aria-hidden": "true" }),
|
|
779
|
-
|
|
787
|
+
formatDateShort(date)
|
|
780
788
|
] }),
|
|
781
789
|
/* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("span", { className: "flex items-center gap-1.5", children: [
|
|
782
790
|
daysSinceColumnChanged !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
KanbanColumn
|
|
3
|
-
} from "../../chunk-
|
|
4
|
-
import "../../chunk-
|
|
5
|
-
import "../../chunk-
|
|
3
|
+
} from "../../chunk-R3VSPKNP.mjs";
|
|
4
|
+
import "../../chunk-K5A5L6T2.mjs";
|
|
5
|
+
import "../../chunk-MBON7YRJ.mjs";
|
|
6
6
|
import "../../chunk-EFRENWEJ.mjs";
|
|
7
|
-
import "../../chunk-
|
|
7
|
+
import "../../chunk-MN5NYQCL.mjs";
|
|
8
|
+
import "../../chunk-7PV3IWCN.mjs";
|
|
9
|
+
import "../../chunk-BKNFWEH2.mjs";
|
|
8
10
|
import "../../chunk-MARPPFOJ.mjs";
|
|
9
11
|
import "../../chunk-FH6QVUVZ.mjs";
|
|
10
12
|
import "../../chunk-RGVKLTLH.mjs";
|
|
11
13
|
import "../../chunk-7YAU5CY6.mjs";
|
|
12
|
-
import "../../chunk-
|
|
14
|
+
import "../../chunk-XREGSKX3.mjs";
|
|
13
15
|
import "../../chunk-DBHJ5KC3.mjs";
|
|
14
16
|
import "../../chunk-FEZKMUCF.mjs";
|
|
15
17
|
import "../../chunk-QOJ2DQD6.mjs";
|
|
@@ -104,6 +104,43 @@ function cn(...inputs) {
|
|
|
104
104
|
return twMerge((0, import_clsx.clsx)(inputs));
|
|
105
105
|
}
|
|
106
106
|
|
|
107
|
+
// src/lib/format-currency.ts
|
|
108
|
+
function formatCurrency(value, options) {
|
|
109
|
+
const { decimals = 0, showSign = false } = options != null ? options : {};
|
|
110
|
+
const abs = Math.abs(value);
|
|
111
|
+
const formatted = new Intl.NumberFormat("en-AU", {
|
|
112
|
+
style: "currency",
|
|
113
|
+
currency: "AUD",
|
|
114
|
+
minimumFractionDigits: decimals,
|
|
115
|
+
maximumFractionDigits: decimals
|
|
116
|
+
}).format(abs);
|
|
117
|
+
if (!showSign) return value < 0 ? `-${formatted}` : formatted;
|
|
118
|
+
if (value > 0) return `+${formatted}`;
|
|
119
|
+
if (value < 0) return `-${formatted}`;
|
|
120
|
+
return formatted;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
// src/lib/format-date.ts
|
|
124
|
+
var import_date_fns = require("date-fns");
|
|
125
|
+
function safeParse(iso) {
|
|
126
|
+
return (0, import_date_fns.parseISO)(iso);
|
|
127
|
+
}
|
|
128
|
+
function formatDateShort(iso) {
|
|
129
|
+
if (!iso) return "\u2014";
|
|
130
|
+
try {
|
|
131
|
+
return (0, import_date_fns.format)(safeParse(iso), "dd MMM yyyy");
|
|
132
|
+
} catch (e) {
|
|
133
|
+
return iso;
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
function formatDateDayMonth(iso) {
|
|
137
|
+
try {
|
|
138
|
+
return (0, import_date_fns.format)(safeParse(iso), "dd MMM");
|
|
139
|
+
} catch (e) {
|
|
140
|
+
return iso;
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
|
|
107
144
|
// src/components/ui/badge.tsx
|
|
108
145
|
var import_class_variance_authority = require("class-variance-authority");
|
|
109
146
|
|
|
@@ -161,12 +198,12 @@ var badgeVariants = (0, import_class_variance_authority.cva)(
|
|
|
161
198
|
{
|
|
162
199
|
variants: {
|
|
163
200
|
variant: {
|
|
164
|
-
default: "bg-primary text-
|
|
165
|
-
secondary: "bg-muted text-muted-foreground [a&]:hover:bg-muted/80",
|
|
166
|
-
destructive: "bg-destructive text-destructive-
|
|
167
|
-
success: "bg-success text-success-
|
|
168
|
-
warning: "bg-warning text-warning-
|
|
169
|
-
info: "bg-info text-info-
|
|
201
|
+
default: "border-primary/40 bg-primary/10 text-foreground [a&]:hover:bg-primary/15",
|
|
202
|
+
secondary: "border-border bg-muted text-muted-foreground [a&]:hover:bg-muted/80",
|
|
203
|
+
destructive: "border-destructive/40 bg-destructive/10 text-destructive-text focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/15",
|
|
204
|
+
success: "border-success/40 bg-success/10 text-success-text [a&]:hover:bg-success/15",
|
|
205
|
+
warning: "border-warning/40 bg-warning/10 text-warning-text [a&]:hover:bg-warning/15",
|
|
206
|
+
info: "border-info/40 bg-info/10 text-info-text [a&]:hover:bg-info/15",
|
|
170
207
|
outline: "border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
|
|
171
208
|
ghost: "[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",
|
|
172
209
|
link: "text-primary underline-offset-4 [a&]:hover:underline"
|
|
@@ -211,10 +248,10 @@ var buttonVariants = (0, import_class_variance_authority2.cva)(
|
|
|
211
248
|
default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
|
|
212
249
|
secondary: "bg-brand-secondary text-brand-secondary-foreground shadow-xs hover:bg-brand-secondary/80 focus-visible:ring-brand-secondary/30",
|
|
213
250
|
destructive: "bg-destructive text-destructive-foreground shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
|
|
214
|
-
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
251
|
+
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground focus-visible:ring-border/50 dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
215
252
|
"outline-primary": "border border-primary text-foreground bg-transparent shadow-xs hover:bg-primary/5 focus-visible:ring-primary/50",
|
|
216
253
|
"outline-secondary": "border border-brand-secondary text-brand-secondary bg-transparent shadow-xs hover:bg-brand-secondary/10 focus-visible:ring-brand-secondary/30",
|
|
217
|
-
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs dark:hover:bg-accent/50",
|
|
254
|
+
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs focus-visible:ring-border/50 dark:hover:bg-accent/50",
|
|
218
255
|
link: "text-primary underline-offset-4 hover:underline"
|
|
219
256
|
},
|
|
220
257
|
size: {
|
|
@@ -577,34 +614,6 @@ function resolvePriority(days, warningDays, priorityDays, priority) {
|
|
|
577
614
|
if (warningDays !== void 0 || priorityDays !== void 0) return "LOW";
|
|
578
615
|
return priority;
|
|
579
616
|
}
|
|
580
|
-
function formatAmount(amount) {
|
|
581
|
-
return new Intl.NumberFormat("en-AU", {
|
|
582
|
-
style: "currency",
|
|
583
|
-
currency: "AUD",
|
|
584
|
-
maximumFractionDigits: 0
|
|
585
|
-
}).format(amount);
|
|
586
|
-
}
|
|
587
|
-
function formatDate(iso) {
|
|
588
|
-
try {
|
|
589
|
-
return new Date(iso).toLocaleDateString("en-AU", {
|
|
590
|
-
day: "2-digit",
|
|
591
|
-
month: "short",
|
|
592
|
-
year: "numeric"
|
|
593
|
-
});
|
|
594
|
-
} catch (e) {
|
|
595
|
-
return iso;
|
|
596
|
-
}
|
|
597
|
-
}
|
|
598
|
-
function formatHoldDate(iso) {
|
|
599
|
-
try {
|
|
600
|
-
return new Date(iso).toLocaleDateString("en-AU", {
|
|
601
|
-
day: "2-digit",
|
|
602
|
-
month: "short"
|
|
603
|
-
});
|
|
604
|
-
} catch (e) {
|
|
605
|
-
return iso;
|
|
606
|
-
}
|
|
607
|
-
}
|
|
608
617
|
function formatLoanType(type) {
|
|
609
618
|
return type.split("-").map((w) => w.charAt(0).toUpperCase() + w.slice(1)).join(" ");
|
|
610
619
|
}
|
|
@@ -666,7 +675,7 @@ function OpportunityCard({
|
|
|
666
675
|
children: [
|
|
667
676
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_lucide_react5.Clock, { className: "size-3 shrink-0" }),
|
|
668
677
|
"On hold until ",
|
|
669
|
-
|
|
678
|
+
formatDateDayMonth(onHoldTo)
|
|
670
679
|
]
|
|
671
680
|
}
|
|
672
681
|
),
|
|
@@ -681,17 +690,16 @@ function OpportunityCard({
|
|
|
681
690
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "flex items-start justify-between gap-2", children: [
|
|
682
691
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "flex min-w-0 flex-1 flex-col gap-1", children: [
|
|
683
692
|
(loanPurposeLabel || loanType) && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Badge, { variant: "outline", className: "self-start", children: loanPurposeLabel != null ? loanPurposeLabel : formatLoanType(loanType) }),
|
|
684
|
-
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("span", { className: "text-base font-bold tabular-nums text-foreground", children:
|
|
693
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)("span", { className: "text-base font-bold tabular-nums text-foreground", children: formatCurrency(amount) })
|
|
685
694
|
] }),
|
|
686
695
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "flex items-center gap-1 -mr-1 -mt-1", children: [
|
|
687
696
|
onLaunchAssistant && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
688
|
-
|
|
697
|
+
Button,
|
|
689
698
|
{
|
|
690
699
|
type: "button",
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
),
|
|
700
|
+
variant: "ghost",
|
|
701
|
+
size: "icon",
|
|
702
|
+
className: "size-7 shrink-0",
|
|
695
703
|
onClick: onLaunchAssistant,
|
|
696
704
|
"aria-label": "Launch AI Assistant",
|
|
697
705
|
title: "Launch AI Assistant",
|
|
@@ -747,7 +755,7 @@ function OpportunityCard({
|
|
|
747
755
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "flex items-center justify-between", children: [
|
|
748
756
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("span", { className: "flex items-center gap-1.5 text-xs text-muted-foreground", children: [
|
|
749
757
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_lucide_react5.Calendar, { className: "size-3 shrink-0", "aria-hidden": "true" }),
|
|
750
|
-
|
|
758
|
+
formatDateShort(date)
|
|
751
759
|
] }),
|
|
752
760
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("span", { className: "flex items-center gap-1.5", children: [
|
|
753
761
|
daysSinceColumnChanged !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_jsx_runtime9.Fragment, { children: [
|
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
LeadCard,
|
|
3
3
|
OpportunityCard
|
|
4
|
-
} from "../../chunk-
|
|
5
|
-
import "../../chunk-
|
|
4
|
+
} from "../../chunk-K5A5L6T2.mjs";
|
|
5
|
+
import "../../chunk-MBON7YRJ.mjs";
|
|
6
6
|
import "../../chunk-EFRENWEJ.mjs";
|
|
7
|
-
import "../../chunk-
|
|
7
|
+
import "../../chunk-MN5NYQCL.mjs";
|
|
8
|
+
import "../../chunk-7PV3IWCN.mjs";
|
|
9
|
+
import "../../chunk-BKNFWEH2.mjs";
|
|
8
10
|
import "../../chunk-MARPPFOJ.mjs";
|
|
9
11
|
import "../../chunk-FH6QVUVZ.mjs";
|
|
10
12
|
import "../../chunk-RGVKLTLH.mjs";
|
|
11
|
-
import "../../chunk-
|
|
13
|
+
import "../../chunk-XREGSKX3.mjs";
|
|
12
14
|
import "../../chunk-DBHJ5KC3.mjs";
|
|
13
15
|
import "../../chunk-FEZKMUCF.mjs";
|
|
14
16
|
import "../../chunk-QOJ2DQD6.mjs";
|