@baack-software/baack-ts-crm 0.0.2 → 0.0.3

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.
Files changed (112) hide show
  1. package/dist/backend.d.ts +29 -1
  2. package/dist/backend.d.ts.map +1 -1
  3. package/dist/backend.js +95 -0
  4. package/dist/backend.js.map +1 -1
  5. package/dist/crm-client.d.ts +55 -13
  6. package/dist/crm-client.d.ts.map +1 -1
  7. package/dist/crm-client.js +99 -15
  8. package/dist/crm-client.js.map +1 -1
  9. package/dist/deal-order.d.ts +42 -0
  10. package/dist/deal-order.d.ts.map +1 -0
  11. package/dist/deal-order.js +80 -0
  12. package/dist/deal-order.js.map +1 -0
  13. package/dist/index.d.ts +1 -0
  14. package/dist/index.d.ts.map +1 -1
  15. package/dist/index.js +1 -0
  16. package/dist/index.js.map +1 -1
  17. package/dist/invoices.d.ts +7 -0
  18. package/dist/invoices.d.ts.map +1 -1
  19. package/dist/invoices.js +20 -2
  20. package/dist/invoices.js.map +1 -1
  21. package/dist/period.d.ts +15 -2
  22. package/dist/period.d.ts.map +1 -1
  23. package/dist/period.js +27 -1
  24. package/dist/period.js.map +1 -1
  25. package/dist/pipeline.d.ts +6 -0
  26. package/dist/pipeline.d.ts.map +1 -1
  27. package/dist/pipeline.js +18 -0
  28. package/dist/pipeline.js.map +1 -1
  29. package/dist/react/ChoiceCombobox.d.ts +36 -0
  30. package/dist/react/ChoiceCombobox.d.ts.map +1 -0
  31. package/dist/react/ChoiceCombobox.js +105 -0
  32. package/dist/react/ChoiceCombobox.js.map +1 -0
  33. package/dist/react/DealsBoard.d.ts +22 -3
  34. package/dist/react/DealsBoard.d.ts.map +1 -1
  35. package/dist/react/DealsBoard.js +53 -4
  36. package/dist/react/DealsBoard.js.map +1 -1
  37. package/dist/react/Details.d.ts +40 -7
  38. package/dist/react/Details.d.ts.map +1 -1
  39. package/dist/react/Details.js +180 -23
  40. package/dist/react/Details.js.map +1 -1
  41. package/dist/react/Forms.d.ts +148 -17
  42. package/dist/react/Forms.d.ts.map +1 -1
  43. package/dist/react/Forms.js +365 -75
  44. package/dist/react/Forms.js.map +1 -1
  45. package/dist/react/Sales.d.ts +25 -6
  46. package/dist/react/Sales.d.ts.map +1 -1
  47. package/dist/react/Sales.js +114 -30
  48. package/dist/react/Sales.js.map +1 -1
  49. package/dist/react/SidePanel.d.ts +10 -0
  50. package/dist/react/SidePanel.d.ts.map +1 -1
  51. package/dist/react/SidePanel.js +14 -2
  52. package/dist/react/SidePanel.js.map +1 -1
  53. package/dist/react/index.d.ts +1 -0
  54. package/dist/react/index.d.ts.map +1 -1
  55. package/dist/react/index.js +1 -0
  56. package/dist/react/index.js.map +1 -1
  57. package/dist/react/parts.d.ts +12 -2
  58. package/dist/react/parts.d.ts.map +1 -1
  59. package/dist/react/parts.js +25 -2
  60. package/dist/react/parts.js.map +1 -1
  61. package/dist/react/pipeline-choice.d.ts +19 -0
  62. package/dist/react/pipeline-choice.d.ts.map +1 -0
  63. package/dist/react/pipeline-choice.js +39 -0
  64. package/dist/react/pipeline-choice.js.map +1 -0
  65. package/dist/react/text.d.ts +89 -2
  66. package/dist/react/text.d.ts.map +1 -1
  67. package/dist/react/text.js +89 -2
  68. package/dist/react/text.js.map +1 -1
  69. package/dist/react/ui/badge.d.ts +1 -1
  70. package/dist/react/ui/button.d.ts +2 -2
  71. package/dist/react/views.d.ts +33 -11
  72. package/dist/react/views.d.ts.map +1 -1
  73. package/dist/react/views.js +96 -27
  74. package/dist/react/views.js.map +1 -1
  75. package/dist/sales.d.ts +28 -3
  76. package/dist/sales.d.ts.map +1 -1
  77. package/dist/sales.js +33 -10
  78. package/dist/sales.js.map +1 -1
  79. package/dist/store.d.ts +31 -12
  80. package/dist/store.d.ts.map +1 -1
  81. package/dist/store.js +82 -21
  82. package/dist/store.js.map +1 -1
  83. package/dist/target.d.ts +2 -1
  84. package/dist/target.d.ts.map +1 -1
  85. package/dist/target.js +6 -2
  86. package/dist/target.js.map +1 -1
  87. package/dist/types.d.ts +24 -0
  88. package/dist/types.d.ts.map +1 -1
  89. package/dist/types.js.map +1 -1
  90. package/package.json +1 -1
  91. package/src/backend.ts +131 -1
  92. package/src/crm-client.ts +162 -19
  93. package/src/deal-order.ts +116 -0
  94. package/src/index.ts +1 -0
  95. package/src/invoices.ts +22 -2
  96. package/src/period.ts +41 -2
  97. package/src/pipeline.ts +21 -0
  98. package/src/react/ChoiceCombobox.tsx +227 -0
  99. package/src/react/DealsBoard.tsx +171 -4
  100. package/src/react/Details.tsx +608 -31
  101. package/src/react/Forms.tsx +1006 -139
  102. package/src/react/Sales.tsx +332 -44
  103. package/src/react/SidePanel.tsx +19 -10
  104. package/src/react/index.ts +1 -0
  105. package/src/react/parts.tsx +56 -4
  106. package/src/react/pipeline-choice.ts +54 -0
  107. package/src/react/text.ts +90 -2
  108. package/src/react/views.tsx +222 -32
  109. package/src/sales.ts +57 -10
  110. package/src/store.ts +136 -27
  111. package/src/target.ts +5 -2
  112. package/src/types.ts +28 -0
@@ -1 +1 @@
1
- {"version":3,"file":"SidePanel.d.ts","sourceRoot":"","sources":["../../src/react/SidePanel.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAqC,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAC1E,OAAO,EAAY,KAAK,OAAO,EAAE,MAAM,WAAW,CAAC;AAInD,oHAAoH;AACpH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAYpD;AAED,uFAAuF;AACvF,eAAO,MAAM,YAAY,GAAI,KAAK,MAAM,WAAsB,CAAC;AAE/D;;;GAGG;AACH,wBAAgB,eAAe,CAAC,EAC9B,IAAI,EACJ,KAAK,EACL,OAAO,EACP,QAAQ,EACR,KAAK,EACL,IAAI,GACL,EAAE;IACD,0CAA0C;IAC1C,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IACzB,uEAAuE;IACvE,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,SAAS,CAAC;IACpB,KAAK,EAAE,SAAS,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,GAAG,SAAS,CAAC;CACrC,+BAiDA"}
1
+ {"version":3,"file":"SidePanel.d.ts","sourceRoot":"","sources":["../../src/react/SidePanel.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAgE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AACrG,OAAO,EAAY,KAAK,OAAO,EAAE,MAAM,WAAW,CAAC;AAInD,oHAAoH;AACpH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAYpD;AAED,uFAAuF;AACvF,eAAO,MAAM,YAAY,GAAI,KAAK,MAAM,WAAsB,CAAC;AAE/D,qGAAqG;AACrG,eAAO,MAAM,UAAU;WAA0B,MAAM,IAAI;WAAS,MAAM;cAA0B,CAAC;AAErG;;;GAGG;AACH,wBAAgB,gBAAgB,uCAQ/B;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,EAC9B,IAAI,EACJ,KAAK,EACL,OAAO,EACP,QAAQ,EACR,KAAK,EACL,IAAI,GACL,EAAE;IACD,0CAA0C;IAC1C,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IACzB,uEAAuE;IACvE,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,SAAS,CAAC;IACpB,KAAK,EAAE,SAAS,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,GAAG,SAAS,CAAC;CACrC,+BAyCA"}
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
2
  import { cn } from 'cn';
3
3
  import { X } from 'lucide-react';
4
- import { useCallback, useSyncExternalStore } from 'react';
4
+ import { createContext, useCallback, useContext, useSyncExternalStore } from 'react';
5
5
  import { withText } from "./text.js";
6
6
  import { Button } from "./ui/button.js";
7
7
  import { Sheet, SheetContent, SheetTitle } from "./ui/sheet.js";
@@ -19,6 +19,18 @@ export function useMediaQuery(query) {
19
19
  }
20
20
  /** The id of a record's card or row, so closing its panel can put focus back on it. */
21
21
  export const recordItemId = (urn) => `crm-item-${urn}`;
22
+ /** The open panel's close action, for the card or form heading it holds to show beside its title. */
23
+ export const PanelClose = createContext(undefined);
24
+ /**
25
+ * Closes the side panel this is in, beside a card's or form's title so it lines up with it. Nothing outside a panel.
26
+ * A card shows it once: it clears the context for what it holds (see `CrmCard`).
27
+ */
28
+ export function PanelCloseButton() {
29
+ const panel = useContext(PanelClose);
30
+ if (!panel)
31
+ return null;
32
+ return (_jsx(Button, { variant: "ghost", size: "icon-sm", onClick: panel.close, "aria-label": panel.label, children: _jsx(X, { "aria-hidden": "true" }) }));
33
+ }
22
34
  /**
23
35
  * A list or board with the open record beside it, as baack-ts-tasks' task view does: a sticky panel to the right on
24
36
  * wide screens, a sheet from the right on narrow ones. Closing puts focus back on the record's card or row.
@@ -31,7 +43,7 @@ export function SidePanelLayout({ open, title, onClose, children, panel, text, }
31
43
  if (open)
32
44
  requestAnimationFrame(() => document.getElementById(recordItemId(open))?.focus());
33
45
  };
34
- const content = (_jsxs("div", { className: "grid gap-2", children: [_jsx("div", { className: "flex justify-end", children: _jsxs(Button, { variant: "ghost", size: "sm", onClick: close, "aria-label": `${words.close}: ${title}`, children: [_jsx(X, { "aria-hidden": "true" }), words.close] }) }), panel] }));
46
+ const content = (_jsx(PanelClose.Provider, { value: { close, label: `${words.close}: ${title}` }, children: panel }));
35
47
  return (_jsxs(_Fragment, { children: [_jsxs("div", { className: cn('grid grid-cols-1 items-start gap-4', open && wide && 'grid-cols-[minmax(0,1fr)_minmax(22rem,28rem)]'), children: [_jsx("div", { className: "min-w-0", children: children }), open && wide && (_jsx("aside", { "aria-label": title, className: "sticky top-4 max-h-[calc(100vh-2rem)] overflow-y-auto p-px", children: content }))] }), !wide && (_jsx(Sheet, { open: open !== undefined, onOpenChange: (isOpen) => !isOpen && close(), children: _jsxs(SheetContent, { side: "right", showCloseButton: false, "aria-describedby": undefined, className: "w-full overflow-y-auto p-4 sm:max-w-md", onCloseAutoFocus: (event) => event.preventDefault(), children: [_jsx(SheetTitle, { className: "sr-only", children: title }), content] }) }))] }));
36
48
  }
37
49
  //# sourceMappingURL=SidePanel.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SidePanel.js","sourceRoot":"","sources":["../../src/react/SidePanel.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,IAAI,CAAC;AACxB,OAAO,EAAE,CAAC,EAAE,MAAM,cAAc,CAAC;AACjC,OAAO,EAAE,WAAW,EAAE,oBAAoB,EAAkB,MAAM,OAAO,CAAC;AAC1E,OAAO,EAAE,QAAQ,EAAgB,MAAM,WAAW,CAAC;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAiB,CAAC;AACzC,OAAO,EAAE,KAAK,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,eAAgB,CAAC;AAEjE,oHAAoH;AACpH,MAAM,UAAU,aAAa,CAAC,KAAa;IACzC,MAAM,SAAS,GAAG,WAAW,CAC3B,CAAC,QAAoB,EAAE,EAAE;QACvB,IAAI,OAAO,UAAU,KAAK,UAAU;YAAE,OAAO,GAAG,EAAE,CAAC,SAAS,CAAC;QAC7D,MAAM,IAAI,GAAG,UAAU,CAAC,KAAK,CAAC,CAAC;QAC/B,IAAI,CAAC,gBAAgB,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;QAC1C,OAAO,GAAG,EAAE,CAAC,IAAI,CAAC,mBAAmB,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;IAC5D,CAAC,EACD,CAAC,KAAK,CAAC,CACR,CAAC;IACF,MAAM,OAAO,GAAG,GAAG,EAAE,CAAC,OAAO,UAAU,KAAK,UAAU,IAAI,UAAU,CAAC,KAAK,CAAC,CAAC,OAA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C,YAAY,CAAC,IAAI,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC;IAC9F,CAAC,CAAC;IACF,MAAM,OAAO,GAAG,CACd,KAAC,UAAU,CAAC,QAAQ,IAAC,KAAK,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,KAAK,CAAC,KAAK,KAAK,KAAK,EAAE,EAAE,YAAG,KAAK,GAAuB,CACxG,CAAC;IACF,OAAO,CACL,8BACE,eACE,SAAS,EAAE,EAAE,CACX,oCAAoC,EACpC,IAAI,IAAI,IAAI,IAAI,+CAA+C,CAChE,aAED,cAAK,SAAS,EAAC,SAAS,YAAE,QAAQ,GAAO,EACxC,IAAI,IAAI,IAAI,IAAI,CACf,8BAAmB,KAAK,EAAE,SAAS,EAAC,4DAA4D,YAC7F,OAAO,GACF,CACT,IACG,EACL,CAAC,IAAI,IAAI,CACR,KAAC,KAAK,IAAC,IAAI,EAAE,IAAI,KAAK,SAAS,EAAE,YAAY,EAAE,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,MAAM,IAAI,KAAK,EAAE,YAC3E,MAAC,YAAY,IACX,IAAI,EAAC,OAAO,EACZ,eAAe,EAAE,KAAK,sBACJ,SAAS,EAC3B,SAAS,EAAC,wCAAwC,EAClD,gBAAgB,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,cAAc,EAAE,aAEnD,KAAC,UAAU,IAAC,SAAS,EAAC,SAAS,YAAE,KAAK,GAAc,EACnD,OAAO,IACK,GACT,CACT,IACA,CACJ,CAAC;AACJ,CAAC"}
@@ -9,6 +9,7 @@ export * from './Details.tsx';
9
9
  export * from './CompanyAccountView.tsx';
10
10
  export * from './Sales.tsx';
11
11
  export * from './Forms.tsx';
12
+ export * from './ChoiceCombobox.tsx';
12
13
  export * from './SidePanel.tsx';
13
14
  export * from './views.tsx';
14
15
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/react/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,cAAc,CAAC;AAC7B,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,0BAA0B,CAAC;AACzC,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/react/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,cAAc,CAAC;AAC7B,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,0BAA0B,CAAC;AACzC,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC"}
@@ -9,6 +9,7 @@ export * from "./Details.js";
9
9
  export * from "./CompanyAccountView.js";
10
10
  export * from "./Sales.js";
11
11
  export * from "./Forms.js";
12
+ export * from "./ChoiceCombobox.js";
12
13
  export * from "./SidePanel.js";
13
14
  export * from "./views.js";
14
15
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/react/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAa,CAAC;AAC5B,cAAc,qBAAsB,CAAC;AACrC,cAAc,aAAc,CAAC;AAC7B,cAAc,iBAAkB,CAAC;AACjC,cAAc,iBAAkB,CAAC;AACjC,cAAc,cAAe,CAAC;AAC9B,cAAc,yBAA0B,CAAC;AACzC,cAAc,YAAa,CAAC;AAC5B,cAAc,YAAa,CAAC;AAC5B,cAAc,gBAAiB,CAAC;AAChC,cAAc,YAAa,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/react/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAa,CAAC;AAC5B,cAAc,qBAAsB,CAAC;AACrC,cAAc,aAAc,CAAC;AAC7B,cAAc,iBAAkB,CAAC;AACjC,cAAc,iBAAkB,CAAC;AACjC,cAAc,cAAe,CAAC;AAC9B,cAAc,yBAA0B,CAAC;AACzC,cAAc,YAAa,CAAC;AAC5B,cAAc,YAAa,CAAC;AAC5B,cAAc,qBAAsB,CAAC;AACrC,cAAc,gBAAiB,CAAC;AAChC,cAAc,YAAa,CAAC"}
@@ -1,4 +1,5 @@
1
- import type { ReactNode } from 'react';
1
+ import { type ReactNode } from 'react';
2
+ import { type ReportingPeriod } from '../period.ts';
2
3
  import type { DealOutcome, InvoiceStatus, Lead } from '../types.ts';
3
4
  import { type CrmText } from './text.ts';
4
5
  /** Marks a view or card whose records come from sample data, so nobody takes them for real ones. */
@@ -13,7 +14,8 @@ export declare function SampleDataNotice({ concepts, text, }: {
13
14
  text?: Partial<CrmText> | undefined;
14
15
  }): import("react").JSX.Element | null;
15
16
  /**
16
- * A titled card for the CRM views. `sample` adds the sample data badge; `action` sits at the top right.
17
+ * A titled card for the CRM views. `sample` adds the sample data badge; `action` sits at the top right. In a side
18
+ * panel, the panel's close button sits there too, in line with the title; cards inside this one don't repeat it.
17
19
  */
18
20
  export declare function CrmCard({ title, description, sample, action, text, className, children, }: {
19
21
  title: string;
@@ -42,4 +44,12 @@ export declare function InvoiceStatusBadge({ status, overdue }: {
42
44
  status: InvoiceStatus;
43
45
  overdue?: boolean;
44
46
  }): import("react").JSX.Element;
47
+ /** The words for figures in `period`: what each change is against. */
48
+ export declare const periodText: (period: ReportingPeriod, text?: Partial<CrmText>) => Partial<CrmText>;
49
+ /** Picks the reporting period a view's figures are for. */
50
+ export declare function PeriodSelect({ value, onChange, text, }: {
51
+ value: ReportingPeriod;
52
+ onChange: (period: ReportingPeriod) => void;
53
+ text?: Partial<CrmText> | undefined;
54
+ }): import("react").JSX.Element;
45
55
  //# sourceMappingURL=parts.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"parts.d.ts","sourceRoot":"","sources":["../../src/react/parts.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAEpE,OAAO,EAAY,KAAK,OAAO,EAAE,MAAM,WAAW,CAAC;AAInD,oGAAoG;AACpG,wBAAgB,eAAe,CAAC,EAAE,IAAI,EAAE,EAAE;IAAE,IAAI,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,GAAG,SAAS,CAAA;CAAE,+BAQhF;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,QAAQ,EACR,IAAI,GACL,EAAE;IACD,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAC;IAC5B,IAAI,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,GAAG,SAAS,CAAC;CACrC,sCAiBA;AAED;;GAEG;AACH,wBAAgB,OAAO,CAAC,EACtB,KAAK,EACL,WAAW,EACX,MAAM,EACN,MAAM,EACN,IAAI,EACJ,SAAS,EACT,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC7B,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,IAAI,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,GAAG,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AO,CAAC,OAAO,CAAC,KAAG,OAAO,CAAC,OAAO,CAG3F,CAAC;AAEH,2DAA2D;AAC3D,wBAAgB,YAAY,CAAC,EAC3B,KAAK,EACL,QAAQ,EACR,IAAI,GACL,EAAE;IACD,KAAK,EAAE,eAAe,CAAC;IACvB,QAAQ,EAAE,CAAC,MAAM,EAAE,eAAe,KAAK,IAAI,CAAC;IAC5C,IAAI,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,GAAG,SAAS,CAAC;CACrC,+BAoBA"}
@@ -1,12 +1,17 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { FlaskConical, TrendingDown, TrendingUp } from 'lucide-react';
3
3
  import { cn } from 'cn';
4
+ import { useContext, useId } from 'react';
4
5
  import { INVOICE_STATUS_LABELS } from "../invoices.js";
5
6
  import { LEAD_STATE_LABELS, leadState } from "../leads.js";
7
+ import { REPORTING_PERIODS } from "../period.js";
6
8
  import { formatChange } from "./format.js";
9
+ import { PanelClose, PanelCloseButton } from "./SidePanel.js";
7
10
  import { withText } from "./text.js";
8
11
  import { Badge } from "./ui/badge.js";
9
12
  import { Card, CardAction, CardContent, CardDescription, CardHeader, CardTitle } from "./ui/card.js";
13
+ import { Label } from "./ui/label.js";
14
+ import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "./ui/select.js";
10
15
  /** Marks a view or card whose records come from sample data, so nobody takes them for real ones. */
11
16
  export function SampleDataBadge({ text }) {
12
17
  const words = withText(text);
@@ -22,10 +27,12 @@ export function SampleDataNotice({ concepts, text, }) {
22
27
  return (_jsxs("p", { className: cn('bg-muted/50 text-muted-foreground flex flex-wrap items-center gap-2', 'rounded-lg border border-dashed px-3 py-2 text-sm'), children: [_jsx(FlaskConical, { "aria-hidden": "true", className: "size-4 shrink-0" }), _jsxs("span", { children: [_jsxs("span", { className: "text-foreground font-medium", children: [words.sampleData, ":"] }), " ", concepts.join(', '), ".", ' ', words.sampleDataHint] })] }));
23
28
  }
24
29
  /**
25
- * A titled card for the CRM views. `sample` adds the sample data badge; `action` sits at the top right.
30
+ * A titled card for the CRM views. `sample` adds the sample data badge; `action` sits at the top right. In a side
31
+ * panel, the panel's close button sits there too, in line with the title; cards inside this one don't repeat it.
26
32
  */
27
33
  export function CrmCard({ title, description, sample, action, text, className, children, }) {
28
- return (_jsxs(Card, { className: className, children: [_jsxs(CardHeader, { children: [_jsx(CardTitle, { children: _jsx("h2", { className: "text-base font-semibold", children: title }) }), description && _jsx(CardDescription, { children: description }), (sample || action) && (_jsxs(CardAction, { className: "flex items-center gap-2", children: [sample && _jsx(SampleDataBadge, { text: text }), action] }))] }), _jsx(CardContent, { children: children })] }));
34
+ const inPanel = useContext(PanelClose) !== undefined;
35
+ return (_jsxs(Card, { className: className, children: [_jsxs(CardHeader, { children: [_jsx(CardTitle, { children: _jsx("h2", { className: "text-base font-semibold", children: title }) }), description && _jsx(CardDescription, { children: description }), (sample || action || inPanel) && (_jsxs(CardAction, { className: "flex items-center gap-2", children: [sample && _jsx(SampleDataBadge, { text: text }), action, _jsx(PanelCloseButton, {})] }))] }), _jsx(CardContent, { children: _jsx(PanelClose.Provider, { value: undefined, children: children }) })] }));
29
36
  }
30
37
  /** A rise or fall against the previous period, in words and an icon, not colour alone. */
31
38
  export function ChangeIndicator({ change, text }) {
@@ -56,4 +63,20 @@ export function InvoiceStatusBadge({ status, overdue }) {
56
63
  return _jsx(Badge, { variant: "destructive", children: "Overdue" });
57
64
  return (_jsx(Badge, { variant: status === 'PAID' ? 'default' : status === 'DRAFT' || status === 'VOIDED' ? 'outline' : 'secondary', children: INVOICE_STATUS_LABELS[status] }));
58
65
  }
66
+ const PERIOD_WORDS = {
67
+ last30: { label: 'periodLast30', versus: 'vsPrevious30' },
68
+ quarter: { label: 'periodQuarter', versus: 'vsLastQuarter' },
69
+ year: { label: 'periodYear', versus: 'vsLastYear' },
70
+ };
71
+ /** The words for figures in `period`: what each change is against. */
72
+ export const periodText = (period, text) => ({
73
+ ...text,
74
+ vsPrevious: withText(text)[PERIOD_WORDS[period].versus],
75
+ });
76
+ /** Picks the reporting period a view's figures are for. */
77
+ export function PeriodSelect({ value, onChange, text, }) {
78
+ const words = withText(text);
79
+ const id = useId();
80
+ return (_jsxs("div", { className: "flex items-center gap-2", children: [_jsx(Label, { htmlFor: id, children: words.period }), _jsxs(Select, { value: value, onValueChange: (next) => onChange(next), children: [_jsx(SelectTrigger, { id: id, className: "w-40", children: _jsx(SelectValue, {}) }), _jsx(SelectContent, { children: REPORTING_PERIODS.map((period) => (_jsx(SelectItem, { value: period, children: words[PERIOD_WORDS[period].label] }, period))) })] })] }));
81
+ }
59
82
  //# sourceMappingURL=parts.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"parts.js","sourceRoot":"","sources":["../../src/react/parts.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,EAAE,EAAE,EAAE,MAAM,IAAI,CAAC;AAExB,OAAO,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAkB,MAAM,aAAa,CAAC;AAE3E,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAgB,MAAM,WAAW,CAAC;AACnD,OAAO,EAAE,KAAK,EAAE,MAAM,eAAgB,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,WAAW,EAAE,eAAe,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,cAAe,CAAC;AAEtG,oGAAoG;AACpG,MAAM,UAAU,eAAe,CAAC,EAAE,IAAI,EAA2C;IAC/E,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC;IAC7B,OAAO,CACL,MAAC,KAAK,IAAC,OAAO,EAAC,SAAS,EAAC,KAAK,EAAE,KAAK,CAAC,cAAc,EAAE,SAAS,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ACtE,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,MAAuB,EAAE,IAAuB,EAAoB,EAAE,CAAC,CAAC;IACjG,GAAG,IAAI;IACP,UAAU,EAAE,QAAQ,CAAC,IAAI,CAAC,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC;CACxD,CAAC,CAAC;AAEH,2DAA2D;AAC3D,MAAM,UAAU,YAAY,CAAC,EAC3B,KAAK,EACL,QAAQ,EACR,IAAI,GAKL;IACC,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC;IAC7B,MAAM,EAAE,GAAG,KAAK,EAAE,CAAC;IACnB,OAAO,CACL,eAAK,SAAS,EAAC,yBAAyB,aACtC,KAAC,KAAK,IAAC,OAAO,EAAE,EAAE,YAAG,KAAK,CAAC,MAAM,GAAS,EAC1C,MAAC,MAAM,IAAC,KAAK,EAAE,KAAK,EAAE,aAAa,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAuB,CAAC,aAC9E,KAAC,aAAa,IAAC,EAAE,EAAE,EAAE,EAAE,SAAS,EAAC,MAAM,YACrC,KAAC,WAAW,KAAG,GACD,EAChB,KAAC,aAAa,cACX,iBAAiB,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CACjC,KAAC,UAAU,IAAc,KAAK,EAAE,MAAM,YACnC,KAAK,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,IADnB,MAAM,CAEV,CACd,CAAC,GACY,IACT,IACL,CACP,CAAC;AACJ,CAAC"}
@@ -0,0 +1,19 @@
1
+ import type { Deal, Pipeline } from '../types.ts';
2
+ /**
3
+ * What this user last chose in the deals, per company, kept in the browser: the workflow they work in (shared by the
4
+ * dashboard, converting leads and the deals board) and the board's order. One record, so each writer keeps the other's.
5
+ */
6
+ export interface DealsMemory {
7
+ pipeline?: string | undefined;
8
+ order?: string | undefined;
9
+ }
10
+ export declare function recallDeals(owner: string): DealsMemory;
11
+ /** Keeps `changes`, merged into what's stored, so a change to one field never puts back an old value of another. */
12
+ export declare function rememberDeals(owner: string, changes: DealsMemory): void;
13
+ /**
14
+ * The pipeline this user works in, for the company `owner`: the one they last chose (their team may work in a
15
+ * different workflow from other users'), else the default (`defaultPipeline`: the workflow with the most deals).
16
+ * Choosing one remembers it.
17
+ */
18
+ export declare function usePipeline(owner: string, pipelines: readonly Pipeline[], deals: readonly Deal[]): [Pipeline | undefined, (urn: string) => void];
19
+ //# sourceMappingURL=pipeline-choice.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pipeline-choice.d.ts","sourceRoot":"","sources":["../../src/react/pipeline-choice.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAElD;;;GAGG;AACH,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC9B,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAC5B;AAID,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,GAAG,WAAW,CAWtD;AAED,oHAAoH;AACpH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,WAAW,GAAG,IAAI,CAMvE;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CACzB,KAAK,EAAE,MAAM,EACb,SAAS,EAAE,SAAS,QAAQ,EAAE,EAC9B,KAAK,EAAE,SAAS,IAAI,EAAE,GACrB,CAAC,QAAQ,GAAG,SAAS,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC,CAO/C"}
@@ -0,0 +1,39 @@
1
+ import { useState } from 'react';
2
+ import { defaultPipeline } from "../pipeline.js";
3
+ const memoryKey = (owner) => `baack-crm:deals-board:${owner}`;
4
+ export function recallDeals(owner) {
5
+ try {
6
+ const saved = JSON.parse(localStorage.getItem(memoryKey(owner)) ?? '{}');
7
+ return {
8
+ pipeline: typeof saved.pipeline === 'string' ? saved.pipeline : undefined,
9
+ order: typeof saved.order === 'string' ? saved.order : undefined,
10
+ };
11
+ }
12
+ catch {
13
+ // No storage (private browsing, blocked, or no browser): start afresh.
14
+ return {};
15
+ }
16
+ }
17
+ /** Keeps `changes`, merged into what's stored, so a change to one field never puts back an old value of another. */
18
+ export function rememberDeals(owner, changes) {
19
+ try {
20
+ localStorage.setItem(memoryKey(owner), JSON.stringify({ ...recallDeals(owner), ...changes }));
21
+ }
22
+ catch {
23
+ // Not kept; the views still work.
24
+ }
25
+ }
26
+ /**
27
+ * The pipeline this user works in, for the company `owner`: the one they last chose (their team may work in a
28
+ * different workflow from other users'), else the default (`defaultPipeline`: the workflow with the most deals).
29
+ * Choosing one remembers it.
30
+ */
31
+ export function usePipeline(owner, pipelines, deals) {
32
+ const [chosen, setChosen] = useState(() => recallDeals(owner).pipeline);
33
+ const choose = (urn) => {
34
+ setChosen(urn);
35
+ rememberDeals(owner, { pipeline: urn });
36
+ };
37
+ return [defaultPipeline(pipelines, deals, chosen), choose];
38
+ }
39
+ //# sourceMappingURL=pipeline-choice.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pipeline-choice.js","sourceRoot":"","sources":["../../src/react/pipeline-choice.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjC,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAYjD,MAAM,SAAS,GAAG,CAAC,KAAa,EAAE,EAAE,CAAC,yBAAyB,KAAK,EAAE,CAAC;AAEtE,MAAM,UAAU,WAAW,CAAC,KAAa;IACvC,IAAI,CAAC;QACH,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,OAAO,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,IAAI,IAAI,CAA4C,CAAC;QACpH,OAAO;YACL,QAAQ,EAAE,OAAO,KAAK,CAAC,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS;YACzE,KAAK,EAAE,OAAO,KAAK,CAAC,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS;SACjE,CAAC;IACJ,CAAC;IAAC,MAAM,CAAC;QACP,uEAAuE;QACvE,OAAO,EAAE,CAAC;IACZ,CAAC;AACH,CAAC;AAED,oHAAoH;AACpH,MAAM,UAAU,aAAa,CAAC,KAAa,EAAE,OAAoB;IAC/D,IAAI,CAAC;QACH,YAAY,CAAC,OAAO,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,IAAI,CAAC,SAAS,CAAC,EAAE,GAAG,WAAW,CAAC,KAAK,CAAC,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC,CAAC;IAChG,CAAC;IAAC,MAAM,CAAC;QACP,kCAAkC;IACpC,CAAC;AACH,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,WAAW,CACzB,KAAa,EACb,SAA8B,EAC9B,KAAsB;IAEtB,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GAAG,QAAQ,CAAC,GAAG,EAAE,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,QAAQ,CAAC,CAAC;IACxE,MAAM,MAAM,GAAG,CAAC,GAAW,EAAE,EAAE;QAC7B,SAAS,CAAC,GAAG,CAAC,CAAC;QACf,aAAa,CAAC,KAAK,EAAE,EAAE,QAAQ,EAAE,GAAG,EAAE,CAAC,CAAC;IAC1C,CAAC,CAAC;IACF,OAAO,CAAC,eAAe,CAAC,SAAS,EAAE,KAAK,EAAE,MAAM,CAAC,EAAE,MAAM,CAAC,CAAC;AAC7D,CAAC"}
@@ -9,6 +9,9 @@ export declare const CRM_TEXT: {
9
9
  readonly loading: "Loading";
10
10
  readonly noChange: "No earlier figures";
11
11
  readonly vsPrevious: "vs previous period";
12
+ readonly vsPrevious30: "vs the 30 days before";
13
+ readonly vsLastQuarter: "vs the same time last quarter";
14
+ readonly vsLastYear: "vs the same time last year";
12
15
  readonly customers: "Customers";
13
16
  readonly customersHint: "Companies with a won deal";
14
17
  readonly openDeals: "Open deals";
@@ -22,6 +25,7 @@ export declare const CRM_TEXT: {
22
25
  readonly leadsBySource: "Leads by source";
23
26
  readonly pipeline: "Sales pipeline";
24
27
  readonly stage: "Stage";
28
+ readonly workflow: "Workflow";
25
29
  readonly deals: "Deals";
26
30
  readonly value: "Value";
27
31
  readonly weighted: "Weighted";
@@ -112,8 +116,30 @@ export declare const CRM_TEXT: {
112
116
  readonly title: "Title";
113
117
  readonly titleRequired: "Enter a title.";
114
118
  readonly noCompany: "No company";
115
- readonly newCompany: "Or a new company";
116
- readonly newCompanyHint: "Makes the company, owned by yours. Leave it empty to choose one above, or for a person.";
119
+ readonly newCompany: "New company";
120
+ readonly newCompanyHint: "Makes the client company, owned by yours, when the lead is saved.";
121
+ readonly addCompany: "Add a new company";
122
+ readonly companyNameRequired: "Enter the company name.";
123
+ readonly noContact: "No contact";
124
+ readonly newContact: "New contact";
125
+ readonly newContactHint: "Makes a person owned by your company when the lead is saved, linked to the lead's company when it has one.";
126
+ readonly addContact: "Add a new person";
127
+ readonly addPerson: "Add a person";
128
+ readonly givenName: "Given name";
129
+ readonly familyName: "Family name";
130
+ readonly email: "Email";
131
+ readonly givenNameRequired: "Enter a given name.";
132
+ readonly telephone: "Telephone";
133
+ readonly contactDetails: "Contact's details";
134
+ readonly contactEmail: "Contact's email";
135
+ readonly contactTelephone: "Contact's telephone";
136
+ readonly contactDetailsUnavailable: "The contact's email and telephone couldn't be read.";
137
+ readonly unassigned: "Unassigned";
138
+ readonly toBeCreated: "new";
139
+ readonly useThis: "Use this";
140
+ readonly saving: "Saving";
141
+ readonly back: "Back";
142
+ readonly saveFailed: "The change couldn't be saved.";
117
143
  readonly createLead: "Create lead";
118
144
  readonly createDeal: "Create deal";
119
145
  readonly createInvoice: "Create invoice";
@@ -133,9 +159,70 @@ export declare const CRM_TEXT: {
133
159
  readonly subTotal: "Subtotal";
134
160
  readonly tax: "Tax";
135
161
  readonly customerRequired: "Choose the customer.";
162
+ readonly amountAs: "Amount as";
163
+ readonly amountAsLines: "Line items";
164
+ readonly amountAsTotal: "A total";
165
+ readonly totalWithTax: "Total, including tax";
166
+ readonly totalHint: "The subtotal and tax are worked out from it at the tax rate.";
167
+ readonly totalRequired: "Enter the total, above zero, such as 1,200.00.";
136
168
  readonly linesRequired: "Give each line a description, a quantity and a unit price above zero.";
137
169
  readonly invalidRate: "Enter a tax rate from 0 to 100.";
138
170
  readonly invalidProbability: "Enter a probability from 0 to 100.";
171
+ readonly companies: "Companies";
172
+ readonly contacts: "Contacts";
173
+ readonly searchCompanies: "Search companies by name";
174
+ readonly searchContacts: "Search people by name, email or telephone";
175
+ readonly chosen: "Chosen";
176
+ readonly remove: "Remove";
177
+ readonly noMatches: "No matches.";
178
+ readonly filterDeals: "Filter deals";
179
+ readonly allOutcomes: "All outcomes";
180
+ readonly anyone: "Anyone";
181
+ readonly allCompanies: "All companies";
182
+ readonly clearFilters: "Clear filters";
183
+ readonly sortBy: "Sort by";
184
+ readonly orderWeighted: "Weighted";
185
+ readonly orderSize: "Deal size";
186
+ readonly orderUrgency: "Urgency";
187
+ readonly dealsShown: "deals shown";
188
+ readonly remitter: "Remitter: who pays";
189
+ readonly remitterCompany: "Company that pays";
190
+ readonly remitterPerson: "Person who pays";
191
+ readonly recipient: "Recipient: who is paid";
192
+ readonly recipientCompany: "Company paid";
193
+ readonly recipientPerson: "Person who is paid";
194
+ readonly recipientHint: "Usually your company, or one of its companies; another company for an invoice you pay.";
195
+ readonly remitterRequired: "Choose the company or person who pays.";
196
+ readonly recipientRequired: "Choose the company or person who is paid.";
197
+ readonly searchPeople: "Search people by name, email or telephone";
198
+ readonly noPerson: "No person";
199
+ readonly line: "Line";
200
+ readonly lineDetails: "All fields";
201
+ readonly itemCode: "Item code";
202
+ readonly discountRate: "Discount (%)";
203
+ readonly taxability: "Tax treatment";
204
+ readonly taxName: "Tax name";
205
+ readonly price: "Price";
206
+ readonly done: "Done";
207
+ readonly invalidDiscount: "Enter a discount from 0 to 100.";
208
+ readonly costs: "Costs";
209
+ readonly costsHint: "Invoices you pay, issued in the period";
210
+ readonly toPay: "To pay";
211
+ readonly party: "Customer or supplier";
212
+ readonly paidBy: "Paid by";
213
+ readonly paidTo: "Paid to";
214
+ readonly allKinds: "Sales and costs";
215
+ readonly salesOnly: "Sales";
216
+ readonly costsOnly: "Costs";
217
+ readonly cost: "Cost";
218
+ readonly drafts: "Drafts";
219
+ readonly draftsHint: "Not yet sent, so not counted above";
220
+ readonly draftInvoice: "draft invoice";
221
+ readonly draftInvoices: "draft invoices";
222
+ readonly period: "Period";
223
+ readonly periodLast30: "Last 30 days";
224
+ readonly periodQuarter: "This quarter";
225
+ readonly periodYear: "This year";
139
226
  };
140
227
  export type CrmText = {
141
228
  readonly [K in keyof typeof CRM_TEXT]: string;
@@ -1 +1 @@
1
- {"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../src/react/text.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsIX,CAAC;AAEX,MAAM,MAAM,OAAO,GAAG;IAAE,QAAQ,EAAE,CAAC,IAAI,MAAM,OAAO,QAAQ,GAAG,MAAM;CAAE,CAAC;AAExE,oDAAoD;AACpD,eAAO,MAAM,QAAQ,GAAI,OAAO,OAAO,CAAC,OAAO,CAAC,KAAG,OAAuD,CAAC"}
1
+ {"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../src/react/text.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8NX,CAAC;AAEX,MAAM,MAAM,OAAO,GAAG;IAAE,QAAQ,EAAE,CAAC,IAAI,MAAM,OAAO,QAAQ,GAAG,MAAM;CAAE,CAAC;AAExE,oDAAoD;AACpD,eAAO,MAAM,QAAQ,GAAI,OAAO,OAAO,CAAC,OAAO,CAAC,KAAG,OAAuD,CAAC"}
@@ -9,6 +9,9 @@ export const CRM_TEXT = {
9
9
  loading: 'Loading',
10
10
  noChange: 'No earlier figures',
11
11
  vsPrevious: 'vs previous period',
12
+ vsPrevious30: 'vs the 30 days before',
13
+ vsLastQuarter: 'vs the same time last quarter',
14
+ vsLastYear: 'vs the same time last year',
12
15
  customers: 'Customers',
13
16
  customersHint: 'Companies with a won deal',
14
17
  openDeals: 'Open deals',
@@ -22,6 +25,7 @@ export const CRM_TEXT = {
22
25
  leadsBySource: 'Leads by source',
23
26
  pipeline: 'Sales pipeline',
24
27
  stage: 'Stage',
28
+ workflow: 'Workflow',
25
29
  deals: 'Deals',
26
30
  value: 'Value',
27
31
  weighted: 'Weighted',
@@ -112,8 +116,30 @@ export const CRM_TEXT = {
112
116
  title: 'Title',
113
117
  titleRequired: 'Enter a title.',
114
118
  noCompany: 'No company',
115
- newCompany: 'Or a new company',
116
- newCompanyHint: 'Makes the company, owned by yours. Leave it empty to choose one above, or for a person.',
119
+ newCompany: 'New company',
120
+ newCompanyHint: 'Makes the client company, owned by yours, when the lead is saved.',
121
+ addCompany: 'Add a new company',
122
+ companyNameRequired: 'Enter the company name.',
123
+ noContact: 'No contact',
124
+ newContact: 'New contact',
125
+ newContactHint: "Makes a person owned by your company when the lead is saved, linked to the lead's company when it has one.",
126
+ addContact: 'Add a new person',
127
+ addPerson: 'Add a person',
128
+ givenName: 'Given name',
129
+ familyName: 'Family name',
130
+ email: 'Email',
131
+ givenNameRequired: 'Enter a given name.',
132
+ telephone: 'Telephone',
133
+ contactDetails: "Contact's details",
134
+ contactEmail: "Contact's email",
135
+ contactTelephone: "Contact's telephone",
136
+ contactDetailsUnavailable: "The contact's email and telephone couldn't be read.",
137
+ unassigned: 'Unassigned',
138
+ toBeCreated: 'new',
139
+ useThis: 'Use this',
140
+ saving: 'Saving',
141
+ back: 'Back',
142
+ saveFailed: "The change couldn't be saved.",
117
143
  createLead: 'Create lead',
118
144
  createDeal: 'Create deal',
119
145
  createInvoice: 'Create invoice',
@@ -133,9 +159,70 @@ export const CRM_TEXT = {
133
159
  subTotal: 'Subtotal',
134
160
  tax: 'Tax',
135
161
  customerRequired: 'Choose the customer.',
162
+ amountAs: 'Amount as',
163
+ amountAsLines: 'Line items',
164
+ amountAsTotal: 'A total',
165
+ totalWithTax: 'Total, including tax',
166
+ totalHint: 'The subtotal and tax are worked out from it at the tax rate.',
167
+ totalRequired: 'Enter the total, above zero, such as 1,200.00.',
136
168
  linesRequired: 'Give each line a description, a quantity and a unit price above zero.',
137
169
  invalidRate: 'Enter a tax rate from 0 to 100.',
138
170
  invalidProbability: 'Enter a probability from 0 to 100.',
171
+ companies: 'Companies',
172
+ contacts: 'Contacts',
173
+ searchCompanies: 'Search companies by name',
174
+ searchContacts: 'Search people by name, email or telephone',
175
+ chosen: 'Chosen',
176
+ remove: 'Remove',
177
+ noMatches: 'No matches.',
178
+ filterDeals: 'Filter deals',
179
+ allOutcomes: 'All outcomes',
180
+ anyone: 'Anyone',
181
+ allCompanies: 'All companies',
182
+ clearFilters: 'Clear filters',
183
+ sortBy: 'Sort by',
184
+ orderWeighted: 'Weighted',
185
+ orderSize: 'Deal size',
186
+ orderUrgency: 'Urgency',
187
+ dealsShown: 'deals shown',
188
+ remitter: 'Remitter: who pays',
189
+ remitterCompany: 'Company that pays',
190
+ remitterPerson: 'Person who pays',
191
+ recipient: 'Recipient: who is paid',
192
+ recipientCompany: 'Company paid',
193
+ recipientPerson: 'Person who is paid',
194
+ recipientHint: 'Usually your company, or one of its companies; another company for an invoice you pay.',
195
+ remitterRequired: 'Choose the company or person who pays.',
196
+ recipientRequired: 'Choose the company or person who is paid.',
197
+ searchPeople: 'Search people by name, email or telephone',
198
+ noPerson: 'No person',
199
+ line: 'Line',
200
+ lineDetails: 'All fields',
201
+ itemCode: 'Item code',
202
+ discountRate: 'Discount (%)',
203
+ taxability: 'Tax treatment',
204
+ taxName: 'Tax name',
205
+ price: 'Price',
206
+ done: 'Done',
207
+ invalidDiscount: 'Enter a discount from 0 to 100.',
208
+ costs: 'Costs',
209
+ costsHint: 'Invoices you pay, issued in the period',
210
+ toPay: 'To pay',
211
+ party: 'Customer or supplier',
212
+ paidBy: 'Paid by',
213
+ paidTo: 'Paid to',
214
+ allKinds: 'Sales and costs',
215
+ salesOnly: 'Sales',
216
+ costsOnly: 'Costs',
217
+ cost: 'Cost',
218
+ drafts: 'Drafts',
219
+ draftsHint: 'Not yet sent, so not counted above',
220
+ draftInvoice: 'draft invoice',
221
+ draftInvoices: 'draft invoices',
222
+ period: 'Period',
223
+ periodLast30: 'Last 30 days',
224
+ periodQuarter: 'This quarter',
225
+ periodYear: 'This year',
139
226
  };
140
227
  /** The default words with a host's replacements. */
141
228
  export const withText = (text) => (text ? { ...CRM_TEXT, ...text } : CRM_TEXT);
@@ -1 +1 @@
1
- {"version":3,"file":"text.js","sourceRoot":"","sources":["../../src/react/text.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,UAAU,EAAE,aAAa;IACzB,cAAc,EAAE,+EAA+E;IAC/F,WAAW,EAAE,mBAAmB;IAChC,OAAO,EAAE,SAAS;IAClB,QAAQ,EAAE,oBAAoB;IAC9B,UAAU,EAAE,oBAAoB;IAChC,SAAS,EAAE,WAAW;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AK,EAAE,OAAO;IACd,SAAS,EAAE,wCAAwC;IACnD,KAAK,EAAE,QAAQ;IACf,KAAK,EAAE,sBAAsB;IAC7B,MAAM,EAAE,SAAS;IACjB,MAAM,EAAE,SAAS;IACjB,QAAQ,EAAE,iBAAiB;IAC3B,SAAS,EAAE,OAAO;IAClB,SAAS,EAAE,OAAO;IAClB,IAAI,EAAE,MAAM;IACZ,MAAM,EAAE,QAAQ;IAChB,UAAU,EAAE,oCAAoC;IAChD,YAAY,EAAE,eAAe;IAC7B,aAAa,EAAE,gBAAgB;IAC/B,MAAM,EAAE,QAAQ;IAChB,YAAY,EAAE,cAAc;IAC5B,aAAa,EAAE,cAAc;IAC7B,UAAU,EAAE,WAAW;CACf,CAAC;AAIX,oDAAoD;AACpD,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,IAAuB,EAAW,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,GAAG,QAAQ,EAAE,GAAG,IAAI,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import * as React from "react";
2
2
  import { type VariantProps } from "class-variance-authority";
3
3
  declare const badgeVariants: (props?: ({
4
- variant?: "default" | "secondary" | "destructive" | "outline" | "ghost" | "link" | null | undefined;
4
+ variant?: "default" | "outline" | "secondary" | "ghost" | "destructive" | "link" | null | undefined;
5
5
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
6
6
  declare function Badge({ className, variant, asChild, ...props }: React.ComponentProps<"span"> & VariantProps<typeof badgeVariants> & {
7
7
  asChild?: boolean;
@@ -1,8 +1,8 @@
1
1
  import * as React from "react";
2
2
  import { type VariantProps } from "class-variance-authority";
3
3
  declare const buttonVariants: (props?: ({
4
- variant?: "default" | "secondary" | "destructive" | "outline" | "ghost" | "link" | null | undefined;
5
- size?: "default" | "sm" | "icon" | "xs" | "lg" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
4
+ variant?: "default" | "outline" | "secondary" | "ghost" | "destructive" | "link" | null | undefined;
5
+ size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
6
6
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
7
  declare function Button({ className, variant, size, asChild, ...props }: React.ComponentProps<"button"> & VariantProps<typeof buttonVariants> & {
8
8
  asChild?: boolean;