@endora-commerce/mod-invoices 0.105.0 → 0.107.0

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 (144) hide show
  1. package/README.md +7 -8
  2. package/dist/admin/components/InvoiceSectionTabs.d.ts +8 -0
  3. package/dist/admin/components/InvoiceSectionTabs.d.ts.map +1 -1
  4. package/dist/admin/components/InvoiceSectionTabs.js +13 -2
  5. package/dist/admin/components/InvoiceSectionTabs.js.map +1 -1
  6. package/dist/admin/document-blocks/InvoiceDivider.d.ts +5 -0
  7. package/dist/admin/document-blocks/InvoiceDivider.d.ts.map +1 -0
  8. package/dist/admin/document-blocks/InvoiceDivider.js +5 -0
  9. package/dist/admin/document-blocks/InvoiceDivider.js.map +1 -0
  10. package/dist/admin/document-blocks/InvoiceFooter.d.ts +5 -0
  11. package/dist/admin/document-blocks/InvoiceFooter.d.ts.map +1 -0
  12. package/dist/admin/document-blocks/InvoiceFooter.js +5 -0
  13. package/dist/admin/document-blocks/InvoiceFooter.js.map +1 -0
  14. package/dist/admin/document-blocks/InvoiceHeader.d.ts +5 -0
  15. package/dist/admin/document-blocks/InvoiceHeader.d.ts.map +1 -0
  16. package/dist/admin/document-blocks/InvoiceHeader.js +5 -0
  17. package/dist/admin/document-blocks/InvoiceHeader.js.map +1 -0
  18. package/dist/admin/document-blocks/InvoiceLineItems.d.ts +5 -0
  19. package/dist/admin/document-blocks/InvoiceLineItems.d.ts.map +1 -0
  20. package/dist/admin/document-blocks/InvoiceLineItems.js +5 -0
  21. package/dist/admin/document-blocks/InvoiceLineItems.js.map +1 -0
  22. package/dist/admin/document-blocks/InvoiceLogo.d.ts +5 -0
  23. package/dist/admin/document-blocks/InvoiceLogo.d.ts.map +1 -0
  24. package/dist/admin/document-blocks/InvoiceLogo.js +5 -0
  25. package/dist/admin/document-blocks/InvoiceLogo.js.map +1 -0
  26. package/dist/admin/document-blocks/InvoiceNotes.d.ts +5 -0
  27. package/dist/admin/document-blocks/InvoiceNotes.d.ts.map +1 -0
  28. package/dist/admin/document-blocks/InvoiceNotes.js +5 -0
  29. package/dist/admin/document-blocks/InvoiceNotes.js.map +1 -0
  30. package/dist/admin/document-blocks/InvoiceParties.d.ts +5 -0
  31. package/dist/admin/document-blocks/InvoiceParties.d.ts.map +1 -0
  32. package/dist/admin/document-blocks/InvoiceParties.js +5 -0
  33. package/dist/admin/document-blocks/InvoiceParties.js.map +1 -0
  34. package/dist/admin/document-blocks/InvoiceSpacer.d.ts +5 -0
  35. package/dist/admin/document-blocks/InvoiceSpacer.d.ts.map +1 -0
  36. package/dist/admin/document-blocks/InvoiceSpacer.js +5 -0
  37. package/dist/admin/document-blocks/InvoiceSpacer.js.map +1 -0
  38. package/dist/admin/document-blocks/InvoiceTotals.d.ts +5 -0
  39. package/dist/admin/document-blocks/InvoiceTotals.d.ts.map +1 -0
  40. package/dist/admin/document-blocks/InvoiceTotals.js +5 -0
  41. package/dist/admin/document-blocks/InvoiceTotals.js.map +1 -0
  42. package/dist/admin/document-blocks/InvoiceVatSummary.d.ts +5 -0
  43. package/dist/admin/document-blocks/InvoiceVatSummary.d.ts.map +1 -0
  44. package/dist/admin/document-blocks/InvoiceVatSummary.js +5 -0
  45. package/dist/admin/document-blocks/InvoiceVatSummary.js.map +1 -0
  46. package/dist/admin/index.d.ts +3 -1
  47. package/dist/admin/index.d.ts.map +1 -1
  48. package/dist/admin/index.js +62 -2
  49. package/dist/admin/index.js.map +1 -1
  50. package/dist/admin/pages/InvoiceTemplatesRedirect.d.ts +10 -0
  51. package/dist/admin/pages/InvoiceTemplatesRedirect.d.ts.map +1 -0
  52. package/dist/admin/pages/InvoiceTemplatesRedirect.js +14 -0
  53. package/dist/admin/pages/InvoiceTemplatesRedirect.js.map +1 -0
  54. package/dist/admin/templates/invoice-puck-config.d.ts +7 -21
  55. package/dist/admin/templates/invoice-puck-config.d.ts.map +1 -1
  56. package/dist/admin/templates/invoice-puck-config.js +7 -26
  57. package/dist/admin/templates/invoice-puck-config.js.map +1 -1
  58. package/dist/backend/document/block-descriptions.d.ts +22 -0
  59. package/dist/backend/document/block-descriptions.d.ts.map +1 -0
  60. package/dist/backend/{pdf-components/descriptor.js → document/block-descriptions.js} +8 -24
  61. package/dist/backend/document/block-descriptions.js.map +1 -0
  62. package/dist/backend/document/document-templates-grant.d.ts +29 -0
  63. package/dist/backend/document/document-templates-grant.d.ts.map +1 -0
  64. package/dist/backend/document/document-templates-grant.js +45 -0
  65. package/dist/backend/document/document-templates-grant.js.map +1 -0
  66. package/dist/backend/document/invoice-document-type.d.ts +38 -0
  67. package/dist/backend/document/invoice-document-type.d.ts.map +1 -0
  68. package/dist/backend/document/invoice-document-type.js +108 -0
  69. package/dist/backend/document/invoice-document-type.js.map +1 -0
  70. package/dist/backend/document/render-invoice.d.ts +14 -0
  71. package/dist/backend/document/render-invoice.d.ts.map +1 -0
  72. package/dist/backend/document/render-invoice.js +24 -0
  73. package/dist/backend/document/render-invoice.js.map +1 -0
  74. package/dist/backend/index.d.ts +1 -3
  75. package/dist/backend/index.d.ts.map +1 -1
  76. package/dist/backend/index.js +48 -6
  77. package/dist/backend/index.js.map +1 -1
  78. package/dist/backend/pdf-components/tree-mapper.d.ts +5 -21
  79. package/dist/backend/pdf-components/tree-mapper.d.ts.map +1 -1
  80. package/dist/backend/pdf-components/tree-mapper.js +8 -44
  81. package/dist/backend/pdf-components/tree-mapper.js.map +1 -1
  82. package/dist/backend/plugin.d.ts +9 -12
  83. package/dist/backend/plugin.d.ts.map +1 -1
  84. package/dist/backend/plugin.js +3 -16
  85. package/dist/backend/plugin.js.map +1 -1
  86. package/dist/backend/routes.admin.d.ts +3 -5
  87. package/dist/backend/routes.admin.d.ts.map +1 -1
  88. package/dist/backend/routes.admin.js +8 -53
  89. package/dist/backend/routes.admin.js.map +1 -1
  90. package/dist/backend/routes.customer.d.ts +3 -5
  91. package/dist/backend/routes.customer.d.ts.map +1 -1
  92. package/dist/backend/routes.customer.js +3 -3
  93. package/dist/backend/routes.customer.js.map +1 -1
  94. package/dist/backend/services/invoice-email-dispatch.d.ts +7 -3
  95. package/dist/backend/services/invoice-email-dispatch.d.ts.map +1 -1
  96. package/dist/backend/services/invoice-email-dispatch.js +2 -1
  97. package/dist/backend/services/invoice-email-dispatch.js.map +1 -1
  98. package/dist/manifest.d.ts +9 -3
  99. package/dist/manifest.d.ts.map +1 -1
  100. package/dist/manifest.js +25 -14
  101. package/dist/manifest.js.map +1 -1
  102. package/dist/migrations/20261017T075839_invoices_drop_invoice_templates.d.ts +20 -0
  103. package/dist/migrations/20261017T075839_invoices_drop_invoice_templates.d.ts.map +1 -0
  104. package/dist/migrations/20261017T075839_invoices_drop_invoice_templates.js +43 -0
  105. package/dist/migrations/20261017T075839_invoices_drop_invoice_templates.js.map +1 -0
  106. package/dist/migrations/index.d.ts +2 -1
  107. package/dist/migrations/index.d.ts.map +1 -1
  108. package/dist/migrations/index.js +3 -1
  109. package/dist/migrations/index.js.map +1 -1
  110. package/docs/invoices.md +21 -14
  111. package/i18n/en.json +3 -3
  112. package/i18n/pl.json +3 -3
  113. package/package.json +13 -13
  114. package/dist/admin/pages/InvoiceTemplateEditor.d.ts +0 -11
  115. package/dist/admin/pages/InvoiceTemplateEditor.d.ts.map +0 -1
  116. package/dist/admin/pages/InvoiceTemplateEditor.js +0 -189
  117. package/dist/admin/pages/InvoiceTemplateEditor.js.map +0 -1
  118. package/dist/admin/pages/InvoiceTemplatesPage.d.ts +0 -10
  119. package/dist/admin/pages/InvoiceTemplatesPage.d.ts.map +0 -1
  120. package/dist/admin/pages/InvoiceTemplatesPage.js +0 -60
  121. package/dist/admin/pages/InvoiceTemplatesPage.js.map +0 -1
  122. package/dist/admin/templates/described-blocks.d.ts +0 -67
  123. package/dist/admin/templates/described-blocks.d.ts.map +0 -1
  124. package/dist/admin/templates/described-blocks.js +0 -83
  125. package/dist/admin/templates/described-blocks.js.map +0 -1
  126. package/dist/admin/templates/invoice-builder-plugin.d.ts +0 -4
  127. package/dist/admin/templates/invoice-builder-plugin.d.ts.map +0 -1
  128. package/dist/admin/templates/invoice-builder-plugin.js +0 -12
  129. package/dist/admin/templates/invoice-builder-plugin.js.map +0 -1
  130. package/dist/backend/entities/invoice-template.entity.d.ts +0 -22
  131. package/dist/backend/entities/invoice-template.entity.d.ts.map +0 -1
  132. package/dist/backend/entities/invoice-template.entity.js +0 -84
  133. package/dist/backend/entities/invoice-template.entity.js.map +0 -1
  134. package/dist/backend/pdf-components/descriptor.d.ts +0 -29
  135. package/dist/backend/pdf-components/descriptor.d.ts.map +0 -1
  136. package/dist/backend/pdf-components/descriptor.js.map +0 -1
  137. package/dist/backend/services/invoice-pdf-renderer.d.ts +0 -57
  138. package/dist/backend/services/invoice-pdf-renderer.d.ts.map +0 -1
  139. package/dist/backend/services/invoice-pdf-renderer.js +0 -158
  140. package/dist/backend/services/invoice-pdf-renderer.js.map +0 -1
  141. package/dist/backend/services/invoice-template-service.d.ts +0 -43
  142. package/dist/backend/services/invoice-template-service.d.ts.map +0 -1
  143. package/dist/backend/services/invoice-template-service.js +0 -147
  144. package/dist/backend/services/invoice-template-service.js.map +0 -1
package/README.md CHANGED
@@ -24,14 +24,13 @@ Generates, numbers, renders, corrects, and emails invoices for orders.
24
24
  (`link` mode). Idempotent, best-effort.
25
25
  - **Customer access** — `GET /api/v1/orders/:id/invoices` and `.../:invoiceId/pdf`
26
26
  (ownership-guarded); surfaced on the storefront order page.
27
- - **WYSIWYG templates (US6)** — a seeded global generic template + optional
28
- per-channel templates, authored in a dedicated Puck editor in the admin
29
- (`/invoices/templates`). The PDF renderer maps the template's Puck tree to
30
- pdfmake sections (`InvoiceHeader`, `InvoiceParties`, `InvoiceLineItems`,
31
- `InvoiceVatSummary`, `InvoiceTotals`, `InvoiceNotes`, `InvoiceKsef`), falling
32
- back to the built-in layout when no valid template applies (FR-016). Endpoints
33
- under `/api/v1/admin/invoice-templates` (list/get/create, `PUT content/:lang`,
34
- `GET .../preview`, page-builder config).
27
+ - **PDF layouts** — designed in *Document templates* (`document_templates`):
28
+ this module registers the `invoices.invoice` document type — its ten blocks
29
+ over the pdfmake section builders, the blocks other modules contribute through
30
+ `invoicePdfBlockRegistry`, and the generic layout as its built-in layout — and
31
+ produces every invoice PDF (downloads, regenerate, e-mail attachment) through
32
+ `documentRenderPort`. The former `/api/v1/admin/invoice-templates` API and the
33
+ `invoice_templates` table are gone (`specs/152-compare-pdf-template/`).
35
34
  - **Settings** — seller VAT/NIP + company data (JSON), numbering patterns,
36
35
  auto-issue trigger, email toggle + delivery mode, storefront base URL — all
37
36
  global + per-channel.
@@ -17,6 +17,14 @@ import type { ReactNode } from 'react';
17
17
  * both tabs are `/invoices*`, the presence gate asks about `invoices`, and both
18
18
  * consumers are `invoices`' own screens. There was nothing here for a mechanism
19
19
  * to do; it was a file in the wrong directory.
20
+ *
21
+ * **The templates tab leads to *Document templates*** since
22
+ * `specs/152-compare-pdf-template/` (FR-088): invoice templates are that
23
+ * module's, opened on the Invoice card. It is shown to an administrator who may
24
+ * read document templates; the module itself is always present while invoices
25
+ * are, because invoices bind it (owner answer N2).
20
26
  */
27
+ /** The Invoice card of *Document templates*. */
28
+ export declare const INVOICE_TEMPLATES_TARGET = "/document-templates?type=invoices.invoice";
21
29
  export declare function InvoiceSectionTabs(): ReactNode;
22
30
  //# sourceMappingURL=InvoiceSectionTabs.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"InvoiceSectionTabs.d.ts","sourceRoot":"","sources":["../../../src/admin/components/InvoiceSectionTabs.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAKvC;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,kBAAkB,IAAI,SAAS,CAa9C"}
1
+ {"version":3,"file":"InvoiceSectionTabs.d.ts","sourceRoot":"","sources":["../../../src/admin/components/InvoiceSectionTabs.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAKvC;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,gDAAgD;AAChD,eAAO,MAAM,wBAAwB,8CAA8C,CAAC;AAEpF,wBAAgB,kBAAkB,IAAI,SAAS,CAgB9C"}
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { RouteTabs } from '@endora-commerce/admin-kit/ui';
3
3
  import { useTranslation } from '@endora-commerce/admin-kit/i18n';
4
- import { useModulePresence } from '@endora-commerce/admin-kit/lib';
4
+ import { useAuth, useModulePresence } from '@endora-commerce/admin-kit/lib';
5
5
  /**
6
6
  * The switch between invoices and the templates they are rendered with.
7
7
  *
@@ -20,15 +20,26 @@ import { useModulePresence } from '@endora-commerce/admin-kit/lib';
20
20
  * both tabs are `/invoices*`, the presence gate asks about `invoices`, and both
21
21
  * consumers are `invoices`' own screens. There was nothing here for a mechanism
22
22
  * to do; it was a file in the wrong directory.
23
+ *
24
+ * **The templates tab leads to *Document templates*** since
25
+ * `specs/152-compare-pdf-template/` (FR-088): invoice templates are that
26
+ * module's, opened on the Invoice card. It is shown to an administrator who may
27
+ * read document templates; the module itself is always present while invoices
28
+ * are, because invoices bind it (owner answer N2).
23
29
  */
30
+ /** The Invoice card of *Document templates*. */
31
+ export const INVOICE_TEMPLATES_TARGET = '/document-templates?type=invoices.invoice';
24
32
  export function InvoiceSectionTabs() {
25
33
  const t = useTranslation('core');
26
34
  const { isPresent } = useModulePresence();
35
+ const { hasPermission } = useAuth();
27
36
  if (!isPresent('invoices'))
28
37
  return null;
29
38
  return (_jsx(RouteTabs, { className: "mb-4", tabs: [
30
39
  { to: '/invoices', label: t('invoiceTabs.invoices') },
31
- { to: '/invoices/templates', label: t('invoiceTabs.templates') },
40
+ ...(isPresent('document_templates') && hasPermission('document_templates:read')
41
+ ? [{ to: INVOICE_TEMPLATES_TARGET, label: t('invoiceTabs.templates') }]
42
+ : []),
32
43
  ] }));
33
44
  }
34
45
  //# sourceMappingURL=InvoiceSectionTabs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"InvoiceSectionTabs.js","sourceRoot":"","sources":["../../../src/admin/components/InvoiceSectionTabs.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAC;AAC1D,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAEnE;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,UAAU,kBAAkB;IAChC,MAAM,CAAC,GAAG,cAAc,CAAC,MAAM,CAAC,CAAC;IACjC,MAAM,EAAE,SAAS,EAAE,GAAG,iBAAiB,EAAE,CAAC;IAC1C,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC;QAAE,OAAO,IAAI,CAAC;IACxC,OAAO,CACL,KAAC,SAAS,IACR,SAAS,EAAC,MAAM,EAChB,IAAI,EAAE;YACJ,EAAE,EAAE,EAAE,WAAW,EAAE,KAAK,EAAE,CAAC,CAAC,sBAAsB,CAAC,EAAE;YACrD,EAAE,EAAE,EAAE,qBAAqB,EAAE,KAAK,EAAE,CAAC,CAAC,uBAAuB,CAAC,EAAE;SACjE,GACD,CACH,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"InvoiceSectionTabs.js","sourceRoot":"","sources":["../../../src/admin/components/InvoiceSectionTabs.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAC;AAC1D,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAE5E;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,gDAAgD;AAChD,MAAM,CAAC,MAAM,wBAAwB,GAAG,2CAA2C,CAAC;AAEpF,MAAM,UAAU,kBAAkB;IAChC,MAAM,CAAC,GAAG,cAAc,CAAC,MAAM,CAAC,CAAC;IACjC,MAAM,EAAE,SAAS,EAAE,GAAG,iBAAiB,EAAE,CAAC;IAC1C,MAAM,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,CAAC;IACpC,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC;QAAE,OAAO,IAAI,CAAC;IACxC,OAAO,CACL,KAAC,SAAS,IACR,SAAS,EAAC,MAAM,EAChB,IAAI,EAAE;YACJ,EAAE,EAAE,EAAE,WAAW,EAAE,KAAK,EAAE,CAAC,CAAC,sBAAsB,CAAC,EAAE;YACrD,GAAG,CAAC,SAAS,CAAC,oBAAoB,CAAC,IAAI,aAAa,CAAC,yBAAyB,CAAC;gBAC7E,CAAC,CAAC,CAAC,EAAE,EAAE,EAAE,wBAAwB,EAAE,KAAK,EAAE,CAAC,CAAC,uBAAuB,CAAC,EAAE,CAAC;gBACvE,CAAC,CAAC,EAAE,CAAC;SACR,GACD,CACH,CAAC;AACJ,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceDivider`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceDivider.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceDivider.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceDivider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,uHAAuH;AACvH,QAAA,MAAM,MAAM,EAA2E,yBAAyB,CAAC;AACjH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceDivider`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceDivider'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceDivider.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceDivider.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceDivider.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,uHAAuH;AACvH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,yBAAyB,CAAyC,CAAC;AACjH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceFooter`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceFooter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceFooter.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceFooter.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,sHAAsH;AACtH,QAAA,MAAM,MAAM,EAA0E,yBAAyB,CAAC;AAChH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceFooter`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceFooter'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceFooter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceFooter.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceFooter.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,sHAAsH;AACtH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,wBAAwB,CAAyC,CAAC;AAChH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceHeader`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceHeader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceHeader.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceHeader.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,sHAAsH;AACtH,QAAA,MAAM,MAAM,EAA0E,yBAAyB,CAAC;AAChH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceHeader`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceHeader'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceHeader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceHeader.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceHeader.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,sHAAsH;AACtH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,wBAAwB,CAAyC,CAAC;AAChH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceLineItems`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceLineItems.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceLineItems.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceLineItems.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,yHAAyH;AACzH,QAAA,MAAM,MAAM,EAA6E,yBAAyB,CAAC;AACnH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceLineItems`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceLineItems'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceLineItems.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceLineItems.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceLineItems.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,yHAAyH;AACzH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,2BAA2B,CAAyC,CAAC;AACnH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceLogo`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceLogo.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceLogo.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceLogo.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,oHAAoH;AACpH,QAAA,MAAM,MAAM,EAAwE,yBAAyB,CAAC;AAC9G,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceLogo`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceLogo'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceLogo.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceLogo.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceLogo.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,oHAAoH;AACpH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,sBAAsB,CAAyC,CAAC;AAC9G,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceNotes`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceNotes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceNotes.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceNotes.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,qHAAqH;AACrH,QAAA,MAAM,MAAM,EAAyE,yBAAyB,CAAC;AAC/G,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceNotes`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceNotes'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceNotes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceNotes.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceNotes.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,qHAAqH;AACrH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,uBAAuB,CAAyC,CAAC;AAC/G,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceParties`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceParties.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceParties.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceParties.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,uHAAuH;AACvH,QAAA,MAAM,MAAM,EAA2E,yBAAyB,CAAC;AACjH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceParties`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceParties'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceParties.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceParties.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceParties.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,uHAAuH;AACvH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,yBAAyB,CAAyC,CAAC;AACjH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceSpacer`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceSpacer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceSpacer.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceSpacer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,sHAAsH;AACtH,QAAA,MAAM,MAAM,EAA0E,yBAAyB,CAAC;AAChH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceSpacer`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceSpacer'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceSpacer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceSpacer.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceSpacer.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,sHAAsH;AACtH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,wBAAwB,CAAyC,CAAC;AAChH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceTotals`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceTotals.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceTotals.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceTotals.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,sHAAsH;AACtH,QAAA,MAAM,MAAM,EAA0E,yBAAyB,CAAC;AAChH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceTotals`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceTotals'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceTotals.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceTotals.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceTotals.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,sHAAsH;AACtH,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,wBAAwB,CAAyC,CAAC;AAChH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DocumentBlockEditorConfig } from '@endora-commerce/page-builder-core/contributions';
2
+ /** `invoices.InvoiceVatSummary`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ declare const config: DocumentBlockEditorConfig;
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceVatSummary.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceVatSummary.d.ts","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceVatSummary.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kDAAkD,CAAC;AAGlG,0HAA0H;AAC1H,QAAA,MAAM,MAAM,EAA8E,yBAAyB,CAAC;AACpH,eAAe,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { invoicePuckConfig } from '../templates/invoice-puck-config.js';
2
+ /** `invoices.InvoiceVatSummary`'s canvas renderer in the document-template editor (`specs/152-compare-pdf-template/`). */
3
+ const config = invoicePuckConfig.components?.['invoices.InvoiceVatSummary'];
4
+ export default config;
5
+ //# sourceMappingURL=InvoiceVatSummary.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceVatSummary.js","sourceRoot":"","sources":["../../../src/admin/document-blocks/InvoiceVatSummary.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AAExE,0HAA0H;AAC1H,MAAM,MAAM,GAAG,iBAAiB,CAAC,UAAU,EAAE,CAAC,4BAA4B,CAAyC,CAAC;AACpH,eAAe,MAAM,CAAC"}
@@ -24,7 +24,9 @@
24
24
  *
25
25
  * **Both palette actions were already declared** (`open-invoices`,
26
26
  * `invoice-templates`) and are untouched; this module had no hand-written
27
- * `PALETTE_ITEMS` row for the batch to delete.
27
+ * `PALETTE_ITEMS` row for the batch to delete. (`invoice-templates` left with
28
+ * `specs/152-compare-pdf-template/`: `document_templates`' own action finds
29
+ * invoice templates now.)
28
30
  *
29
31
  * **This entry exports data and nothing else** (R2); every component is a
30
32
  * dynamic-import factory (R6).
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/admin/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,0CAA0C,CAAC;AAqBnF,eAAO,MAAM,aAAa,EAAE,kBAmD3B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/admin/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AACH,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,0CAA0C,CAAC;AAqBnF,eAAO,MAAM,aAAa,EAAE,kBA+G3B,CAAC"}
@@ -22,14 +22,16 @@ export const contributions = {
22
22
  requiredPermission: READ_PERMISSION,
23
23
  index: true,
24
24
  },
25
+ // `specs/152-compare-pdf-template/` (FR-088): invoice templates live in
26
+ // *Document templates*; the two former addresses redirect there.
25
27
  {
26
28
  path: TEMPLATES_ROUTE,
27
- component: () => import('./pages/InvoiceTemplatesPage.js'),
29
+ component: () => import('./pages/InvoiceTemplatesRedirect.js'),
28
30
  requiredPermission: READ_PERMISSION,
29
31
  },
30
32
  {
31
33
  path: `${TEMPLATES_ROUTE}/:id`,
32
- component: () => import('./pages/InvoiceTemplateEditor.js'),
34
+ component: () => import('./pages/InvoiceTemplatesRedirect.js'),
33
35
  requiredPermission: READ_PERMISSION,
34
36
  },
35
37
  {
@@ -65,5 +67,63 @@ export const contributions = {
65
67
  requiredPermission: READ_PERMISSION,
66
68
  },
67
69
  ],
70
+ /**
71
+ * The ten invoice blocks' canvas renderers in the document-template editor
72
+ * (`specs/152-compare-pdf-template/` R-7). A block another module contributes
73
+ * to invoices (`ksef.InvoiceSection`) has none and is drawn as the editor's
74
+ * neutral stand-in.
75
+ */
76
+ blocks: [
77
+ {
78
+ name: 'invoices.InvoiceHeader',
79
+ context: 'document',
80
+ component: () => import('./document-blocks/InvoiceHeader.js'),
81
+ },
82
+ {
83
+ name: 'invoices.InvoiceParties',
84
+ context: 'document',
85
+ component: () => import('./document-blocks/InvoiceParties.js'),
86
+ },
87
+ {
88
+ name: 'invoices.InvoiceLineItems',
89
+ context: 'document',
90
+ component: () => import('./document-blocks/InvoiceLineItems.js'),
91
+ },
92
+ {
93
+ name: 'invoices.InvoiceVatSummary',
94
+ context: 'document',
95
+ component: () => import('./document-blocks/InvoiceVatSummary.js'),
96
+ },
97
+ {
98
+ name: 'invoices.InvoiceTotals',
99
+ context: 'document',
100
+ component: () => import('./document-blocks/InvoiceTotals.js'),
101
+ },
102
+ {
103
+ name: 'invoices.InvoiceNotes',
104
+ context: 'document',
105
+ component: () => import('./document-blocks/InvoiceNotes.js'),
106
+ },
107
+ {
108
+ name: 'invoices.InvoiceSpacer',
109
+ context: 'document',
110
+ component: () => import('./document-blocks/InvoiceSpacer.js'),
111
+ },
112
+ {
113
+ name: 'invoices.InvoiceDivider',
114
+ context: 'document',
115
+ component: () => import('./document-blocks/InvoiceDivider.js'),
116
+ },
117
+ {
118
+ name: 'invoices.InvoiceLogo',
119
+ context: 'document',
120
+ component: () => import('./document-blocks/InvoiceLogo.js'),
121
+ },
122
+ {
123
+ name: 'invoices.InvoiceFooter',
124
+ context: 'document',
125
+ component: () => import('./document-blocks/InvoiceFooter.js'),
126
+ },
127
+ ],
68
128
  };
69
129
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/admin/index.ts"],"names":[],"mappings":"AAiCA,2DAA2D;AAC3D,MAAM,UAAU,GAAG,WAAW,CAAC;AAE/B,MAAM,eAAe,GAAG,GAAG,UAAU,YAAY,CAAC;AAElD;;;;;;;;;;;GAWG;AACH,MAAM,eAAe,GAAG,eAAe,CAAC;AAExC,MAAM,CAAC,MAAM,aAAa,GAAuB;IAC/C,MAAM,EAAE;QACN;YACE,IAAI,EAAE,UAAU;YAChB,SAAS,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,yBAAyB,CAAC;YAClD,kBAAkB,EAAE,eAAe;YACnC,KAAK,EAAE,IAAI;SACZ;QACD;YACE,IAAI,EAAE,eAAe;YACrB,SAAS,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,iCAAiC,CAAC;YAC1D,kBAAkB,EAAE,eAAe;SACpC;QACD;YACE,IAAI,EAAE,GAAG,eAAe,MAAM;YAC9B,SAAS,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,kCAAkC,CAAC;YAC3D,kBAAkB,EAAE,eAAe;SACpC;QACD;YACE,qEAAqE;YACrE,yEAAyE;YACzE,wEAAwE;YACxE,wEAAwE;YACxE,sDAAsD;YACtD,IAAI,EAAE,GAAG,UAAU,MAAM;YACzB,SAAS,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,0BAA0B,CAAC;YACnD,kBAAkB,EAAE,eAAe;SACpC;KACF;IACD,GAAG,EAAE;QACH;YACE,EAAE,EAAE,UAAU;YACd,uEAAuE;YACvE,uEAAuE;YACvE,0EAA0E;YAC1E,eAAe;YACf,QAAQ,EAAE,oBAAoB;YAC9B,qEAAqE;YACrE,wEAAwE;YACxE,oDAAoD;YACpD,IAAI,EAAE,SAAS;YACf,OAAO,EAAE,OAAO;YAChB,uEAAuE;YACvE,qEAAqE;YACrE,sEAAsE;YACtE,oEAAoE;YACpE,qDAAqD;YACrD,MAAM,EAAE,GAAG;YACX,kBAAkB,EAAE,eAAe;SACpC;KACF;CACF,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/admin/index.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,10 @@
1
+ import type { ReactNode } from 'react';
2
+ /**
3
+ * `/invoices/templates` and `/invoices/templates/:id` — the addresses invoice
4
+ * templates had before they moved into *Document templates*
5
+ * (`specs/152-compare-pdf-template/` FR-088). A bookmark lands on the Invoice
6
+ * card, or — with a template id — on that template's editor.
7
+ */
8
+ export declare function InvoiceTemplatesRedirect(): ReactNode;
9
+ export default InvoiceTemplatesRedirect;
10
+ //# sourceMappingURL=InvoiceTemplatesRedirect.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceTemplatesRedirect.d.ts","sourceRoot":"","sources":["../../../src/admin/pages/InvoiceTemplatesRedirect.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC;;;;;GAKG;AACH,wBAAgB,wBAAwB,IAAI,SAAS,CAGpD;AAED,eAAe,wBAAwB,CAAC"}
@@ -0,0 +1,14 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { Navigate, useParams } from 'react-router-dom';
3
+ /**
4
+ * `/invoices/templates` and `/invoices/templates/:id` — the addresses invoice
5
+ * templates had before they moved into *Document templates*
6
+ * (`specs/152-compare-pdf-template/` FR-088). A bookmark lands on the Invoice
7
+ * card, or — with a template id — on that template's editor.
8
+ */
9
+ export function InvoiceTemplatesRedirect() {
10
+ const { id } = useParams();
11
+ return _jsx(Navigate, { replace: true, to: id ? `/document-templates/${id}` : '/document-templates?type=invoices.invoice' });
12
+ }
13
+ export default InvoiceTemplatesRedirect;
14
+ //# sourceMappingURL=InvoiceTemplatesRedirect.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InvoiceTemplatesRedirect.js","sourceRoot":"","sources":["../../../src/admin/pages/InvoiceTemplatesRedirect.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAEvD;;;;;GAKG;AACH,MAAM,UAAU,wBAAwB;IACtC,MAAM,EAAE,EAAE,EAAE,GAAG,SAAS,EAAE,CAAC;IAC3B,OAAO,KAAC,QAAQ,IAAC,OAAO,QAAC,EAAE,EAAE,EAAE,CAAC,CAAC,CAAC,uBAAuB,EAAE,EAAE,CAAC,CAAC,CAAC,2CAA2C,GAAI,CAAC;AAClH,CAAC;AAED,eAAe,wBAAwB,CAAC"}
@@ -11,27 +11,13 @@ import type { Config } from '@puckeditor/core';
11
11
  * file could not express.
12
12
  *
13
13
  * **Every entry is this module's own.** A block another module declares is not
14
- * bound here: its binding lives with its declarant, and no page-builder
15
- * component contribution kind (α, F7's roadmap row) is built. The editor
16
- * reaches such a block through the served descriptor instead —
17
- * `withDescribedInvoiceBlocks` (`./described-blocks.tsx`,
18
- * `specs/134-paid-module-extraction/` T138) makes a present contributor's block
19
- * insertable and configurable with a neutral canvas stand-in, and keeps a stored
20
- * block nothing covers as FR-019's placeholder. The PDF — the legal document —
21
- * renders it through the contributor's registration on the backend.
14
+ * bound here: its binding lives with its declarant. Since
15
+ * `specs/152-compare-pdf-template/` invoice templates are edited in the
16
+ * document-template editor, which takes each entry below through this module's
17
+ * `document` block contributions (`../document-blocks/`) and draws a block
18
+ * another module contributes to invoices as its neutral stand-in. The PDF — the
19
+ * legal document — renders it through the contributor's registration on the
20
+ * backend.
22
21
  */
23
22
  export declare const invoicePuckConfig: Config;
24
- /**
25
- * The invoice palette's one section.
26
- *
27
- * **Derived from the renderer map rather than written out** (FR-008, SC-005):
28
- * this file no longer holds a mapping from a category to a list of block names,
29
- * which is what let a section list five of another module's blocks. The
30
- * *authoritative* declarations are `invoices`' and `ksef`'s `blockCategories`,
31
- * merged and presence-filtered by
32
- * `GET /api/v1/admin/cms/page-builder/config`; this local derivation is what
33
- * the editor renders until the invoice builder reads that descriptor, and it
34
- * carries no name of its own.
35
- */
36
- export declare const invoicePuckPalette: NonNullable<Config['categories']>;
37
23
  //# sourceMappingURL=invoice-puck-config.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"invoice-puck-config.d.ts","sourceRoot":"","sources":["../../../src/admin/templates/invoice-puck-config.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAmB,MAAM,kBAAkB,CAAC;AAujChE;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAa/B,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,kBAAkB,EAAE,WAAW,CAAC,MAAM,CAAC,YAAY,CAAC,CAKhE,CAAC"}
1
+ {"version":3,"file":"invoice-puck-config.d.ts","sourceRoot":"","sources":["../../../src/admin/templates/invoice-puck-config.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAmB,MAAM,kBAAkB,CAAC;AAujChE;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAa/B,CAAC"}
@@ -689,14 +689,13 @@ const InvoiceFooter = invoiceSection({
689
689
  * file could not express.
690
690
  *
691
691
  * **Every entry is this module's own.** A block another module declares is not
692
- * bound here: its binding lives with its declarant, and no page-builder
693
- * component contribution kind (α, F7's roadmap row) is built. The editor
694
- * reaches such a block through the served descriptor instead —
695
- * `withDescribedInvoiceBlocks` (`./described-blocks.tsx`,
696
- * `specs/134-paid-module-extraction/` T138) makes a present contributor's block
697
- * insertable and configurable with a neutral canvas stand-in, and keeps a stored
698
- * block nothing covers as FR-019's placeholder. The PDF — the legal document —
699
- * renders it through the contributor's registration on the backend.
692
+ * bound here: its binding lives with its declarant. Since
693
+ * `specs/152-compare-pdf-template/` invoice templates are edited in the
694
+ * document-template editor, which takes each entry below through this module's
695
+ * `document` block contributions (`../document-blocks/`) and draws a block
696
+ * another module contributes to invoices as its neutral stand-in. The PDF — the
697
+ * legal document — renders it through the contributor's registration on the
698
+ * backend.
700
699
  */
701
700
  export const invoicePuckConfig = {
702
701
  components: {
@@ -712,22 +711,4 @@ export const invoicePuckConfig = {
712
711
  'invoices.InvoiceFooter': InvoiceFooter,
713
712
  },
714
713
  };
715
- /**
716
- * The invoice palette's one section.
717
- *
718
- * **Derived from the renderer map rather than written out** (FR-008, SC-005):
719
- * this file no longer holds a mapping from a category to a list of block names,
720
- * which is what let a section list five of another module's blocks. The
721
- * *authoritative* declarations are `invoices`' and `ksef`'s `blockCategories`,
722
- * merged and presence-filtered by
723
- * `GET /api/v1/admin/cms/page-builder/config`; this local derivation is what
724
- * the editor renders until the invoice builder reads that descriptor, and it
725
- * carries no name of its own.
726
- */
727
- export const invoicePuckPalette = {
728
- invoice: {
729
- title: 'Invoice sections',
730
- components: Object.keys(invoicePuckConfig.components ?? {}),
731
- },
732
- };
733
714
  //# sourceMappingURL=invoice-puck-config.js.map