@aglyn/plugins-commerce 1.31.0 → 1.32.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 (118) hide show
  1. package/README.md +4 -0
  2. package/package.json +13 -13
  3. package/src/lib/components/cart.js +35 -15
  4. package/src/lib/components/cart.js.map +1 -1
  5. package/src/lib/components/commerce-console-page.js +6 -0
  6. package/src/lib/components/commerce-console-page.js.map +1 -1
  7. package/src/lib/components/console/currencies-card.component.d.ts +21 -0
  8. package/src/lib/components/console/currencies-card.component.js +408 -0
  9. package/src/lib/components/console/currencies-card.component.js.map +1 -0
  10. package/src/lib/components/console/product-add-ons-fields.component.d.ts +13 -0
  11. package/src/lib/components/console/product-add-ons-fields.component.js +74 -2
  12. package/src/lib/components/console/product-add-ons-fields.component.js.map +1 -1
  13. package/src/lib/components/console/product-editor-dialog.component.js +42 -1
  14. package/src/lib/components/console/product-editor-dialog.component.js.map +1 -1
  15. package/src/lib/components/console/product-fixed-prices-fields.component.d.ts +25 -0
  16. package/src/lib/components/console/product-fixed-prices-fields.component.js +112 -0
  17. package/src/lib/components/console/product-fixed-prices-fields.component.js.map +1 -0
  18. package/src/lib/components/console/reservations-card.component.js +32 -15
  19. package/src/lib/components/console/reservations-card.component.js.map +1 -1
  20. package/src/lib/components/console/shipping-settings-card.component.js +100 -1
  21. package/src/lib/components/console/shipping-settings-card.component.js.map +1 -1
  22. package/src/lib/components/console/store-settings-card.component.js +1 -1
  23. package/src/lib/components/console/store-settings-card.component.js.map +1 -1
  24. package/src/lib/components/console/use-currency-setup.d.ts +20 -0
  25. package/src/lib/components/console/use-currency-setup.js +61 -0
  26. package/src/lib/components/console/use-currency-setup.js.map +1 -0
  27. package/src/lib/components/currency-selector.d.ts +36 -0
  28. package/src/lib/components/currency-selector.js +157 -0
  29. package/src/lib/components/currency-selector.js.map +1 -0
  30. package/src/lib/components/product-add-ons.d.ts +9 -1
  31. package/src/lib/components/product-add-ons.js +8 -4
  32. package/src/lib/components/product-add-ons.js.map +1 -1
  33. package/src/lib/components/product-choice-cards.d.ts +13 -1
  34. package/src/lib/components/product-choice-cards.js +5 -4
  35. package/src/lib/components/product-choice-cards.js.map +1 -1
  36. package/src/lib/components/product-detail.d.ts +8 -0
  37. package/src/lib/components/product-detail.js +38 -11
  38. package/src/lib/components/product-detail.js.map +1 -1
  39. package/src/lib/components/product-grid.d.ts +2 -0
  40. package/src/lib/components/product-grid.js +22 -9
  41. package/src/lib/components/product-grid.js.map +1 -1
  42. package/src/lib/components/related-products.js +6 -2
  43. package/src/lib/components/related-products.js.map +1 -1
  44. package/src/lib/components/shopper-currency.d.ts +108 -0
  45. package/src/lib/components/shopper-currency.js +262 -0
  46. package/src/lib/components/shopper-currency.js.map +1 -0
  47. package/src/lib/components/wishlist.js +7 -1
  48. package/src/lib/components/wishlist.js.map +1 -1
  49. package/src/lib/declarations.server.js +39 -0
  50. package/src/lib/declarations.server.js.map +1 -1
  51. package/src/lib/model/commerce-currency-setup.d.ts +79 -0
  52. package/src/lib/model/commerce-currency-setup.js +124 -0
  53. package/src/lib/model/commerce-currency-setup.js.map +1 -0
  54. package/src/lib/model/commerce-currency.d.ts +215 -0
  55. package/src/lib/model/commerce-currency.js +511 -0
  56. package/src/lib/model/commerce-currency.js.map +1 -0
  57. package/src/lib/model/commerce-orders.d.ts +17 -0
  58. package/src/lib/model/commerce-orders.js +10 -5
  59. package/src/lib/model/commerce-orders.js.map +1 -1
  60. package/src/lib/model/commerce-record-routes.js +26 -1
  61. package/src/lib/model/commerce-record-routes.js.map +1 -1
  62. package/src/lib/model/commerce-reservations.d.ts +6 -0
  63. package/src/lib/model/commerce-reservations.js.map +1 -1
  64. package/src/lib/model/commerce-shipping.d.ts +22 -1
  65. package/src/lib/model/commerce-shipping.js +31 -2
  66. package/src/lib/model/commerce-shipping.js.map +1 -1
  67. package/src/lib/model/commerce.d.ts +6 -0
  68. package/src/lib/model/commerce.js.map +1 -1
  69. package/src/lib/model/index.d.ts +2 -0
  70. package/src/lib/model/index.js +2 -0
  71. package/src/lib/model/index.js.map +1 -1
  72. package/src/lib/model/order-figures.js +9 -2
  73. package/src/lib/model/order-figures.js.map +1 -1
  74. package/src/lib/model/product-modifiers.d.ts +5 -0
  75. package/src/lib/model/product-modifiers.js.map +1 -1
  76. package/src/lib/server/billing-webhook.js +37 -24
  77. package/src/lib/server/billing-webhook.js.map +1 -1
  78. package/src/lib/server/cart-checkout.js +67 -11
  79. package/src/lib/server/cart-checkout.js.map +1 -1
  80. package/src/lib/server/cart.d.ts +12 -0
  81. package/src/lib/server/cart.js +50 -4
  82. package/src/lib/server/cart.js.map +1 -1
  83. package/src/lib/server/catalog.d.ts +5 -0
  84. package/src/lib/server/catalog.js +7 -0
  85. package/src/lib/server/catalog.js.map +1 -1
  86. package/src/lib/server/checkout.js +48 -12
  87. package/src/lib/server/checkout.js.map +1 -1
  88. package/src/lib/server/currency.d.ts +93 -0
  89. package/src/lib/server/currency.js +182 -0
  90. package/src/lib/server/currency.js.map +1 -0
  91. package/src/lib/server/order-notifications.js +4 -2
  92. package/src/lib/server/order-notifications.js.map +1 -1
  93. package/src/lib/server/product.d.ts +9 -0
  94. package/src/lib/server/product.js +12 -0
  95. package/src/lib/server/product.js.map +1 -1
  96. package/src/lib/server/refund.js +3 -3
  97. package/src/lib/server/refund.js.map +1 -1
  98. package/src/lib/server/site-chat-tools.d.ts +22 -0
  99. package/src/lib/server/site-chat-tools.js +369 -0
  100. package/src/lib/server/site-chat-tools.js.map +1 -0
  101. package/src/lib/server/site-chat-visitor.d.ts +24 -0
  102. package/src/lib/server/site-chat-visitor.js +39 -0
  103. package/src/lib/server/site-chat-visitor.js.map +1 -0
  104. package/src/lib/server/site-offers.d.ts +31 -0
  105. package/src/lib/server/site-offers.js +91 -0
  106. package/src/lib/server/site-offers.js.map +1 -0
  107. package/src/lib/server/stays-site-search.d.ts +20 -0
  108. package/src/lib/server/stays-site-search.js +78 -0
  109. package/src/lib/server/stays-site-search.js.map +1 -0
  110. package/src/lib/server.js +20 -0
  111. package/src/lib/server.js.map +1 -1
  112. package/src/lib/site-chat-tool-definitions.d.ts +26 -0
  113. package/src/lib/site-chat-tool-definitions.js +141 -0
  114. package/src/lib/site-chat-tool-definitions.js.map +1 -0
  115. package/src/lib/site.js +8 -0
  116. package/src/lib/site.js.map +1 -1
  117. package/src/lib/subprocessors.js +7 -0
  118. package/src/lib/subprocessors.js.map +1 -1
@@ -0,0 +1,141 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2026 Aglyn LLC
4
+ *
5
+ * Licensed under the Apache License, Version 2.0 (the "License");
6
+ * you may not use this file except in compliance with the License.
7
+ * You may obtain a copy of the License at
8
+ *
9
+ * http://www.apache.org/licenses/LICENSE-2.0
10
+ *
11
+ * Unless required by applicable law or agreed to in writing, software
12
+ * distributed under the License is distributed on an "AS IS" BASIS,
13
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ * See the License for the specific language governing permissions and
15
+ * limitations under the License.
16
+ */ export const COMMERCE_SITE_CHAT_TOOLS = [
17
+ {
18
+ name: 'commerce_product_details',
19
+ kind: 'lookup',
20
+ capability: 'answer',
21
+ description: "A product's options, prices (and sale prices), whether it asks for the day it will be used, and whether it has add-ons to choose. Use it before offering to add a product, or when a visitor asks about a product's options or price.",
22
+ inputSchema: {
23
+ type: 'object',
24
+ properties: {
25
+ product: {
26
+ type: 'string',
27
+ description: "The product's name, as the visitor or the site calls it."
28
+ }
29
+ },
30
+ required: [
31
+ 'product'
32
+ ],
33
+ additionalProperties: false
34
+ }
35
+ },
36
+ {
37
+ name: 'commerce_propose_add_to_cart',
38
+ kind: 'proposal',
39
+ capability: 'cart',
40
+ endpoints: [
41
+ 'commerce/cart'
42
+ ],
43
+ description: 'Offer the visitor a card to add one product to their cart. Only once you know the product, its option where it has several, and the day where it asks for one. The visitor presses the card to add it; nothing is added before.',
44
+ inputSchema: {
45
+ type: 'object',
46
+ properties: {
47
+ product: {
48
+ type: 'string',
49
+ description: "The product's name."
50
+ },
51
+ option: {
52
+ type: 'string',
53
+ description: 'The option the visitor chose, such as "Adult" or "Large"; empty when the product has one.'
54
+ },
55
+ quantity: {
56
+ type: 'integer',
57
+ description: 'How many, 1 or more.'
58
+ },
59
+ day: {
60
+ type: 'string',
61
+ description: 'The day it will be used, YYYY-MM-DD, for a product that asks; otherwise empty.'
62
+ }
63
+ },
64
+ required: [
65
+ 'product',
66
+ 'option',
67
+ 'quantity',
68
+ 'day'
69
+ ],
70
+ additionalProperties: false
71
+ }
72
+ },
73
+ {
74
+ name: 'commerce_stay_availability',
75
+ kind: 'lookup',
76
+ capability: 'answer',
77
+ description: 'Whether a stay (a cabin, a room, a campsite) is free for the nights from a check-in day to a check-out day, and its nightly price. Use it whenever a visitor asks if dates are free.',
78
+ inputSchema: {
79
+ type: 'object',
80
+ properties: {
81
+ stay: {
82
+ type: 'string',
83
+ description: "The stay's name."
84
+ },
85
+ checkIn: {
86
+ type: 'string',
87
+ description: 'Check-in day, YYYY-MM-DD.'
88
+ },
89
+ checkOut: {
90
+ type: 'string',
91
+ description: 'Check-out day, YYYY-MM-DD.'
92
+ }
93
+ },
94
+ required: [
95
+ 'stay',
96
+ 'checkIn',
97
+ 'checkOut'
98
+ ],
99
+ additionalProperties: false
100
+ }
101
+ },
102
+ {
103
+ name: 'commerce_propose_reservation',
104
+ kind: 'proposal',
105
+ capability: 'book',
106
+ endpoints: [
107
+ 'commerce/reserve'
108
+ ],
109
+ description: 'Offer the visitor a card to reserve a stay for free dates, after commerce_stay_availability showed them free. The visitor enters their name and email on the card and pays at the normal checkout.',
110
+ inputSchema: {
111
+ type: 'object',
112
+ properties: {
113
+ stay: {
114
+ type: 'string',
115
+ description: "The stay's name."
116
+ },
117
+ checkIn: {
118
+ type: 'string',
119
+ description: 'Check-in day, YYYY-MM-DD.'
120
+ },
121
+ checkOut: {
122
+ type: 'string',
123
+ description: 'Check-out day, YYYY-MM-DD.'
124
+ },
125
+ guests: {
126
+ type: 'integer',
127
+ description: 'How many guests; 0 when the visitor did not say.'
128
+ }
129
+ },
130
+ required: [
131
+ 'stay',
132
+ 'checkIn',
133
+ 'checkOut',
134
+ 'guests'
135
+ ],
136
+ additionalProperties: false
137
+ }
138
+ }
139
+ ];
140
+
141
+ //# sourceMappingURL=site-chat-tool-definitions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../../libs/plugins/commerce/src/lib/site-chat-tool-definitions.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { SiteChatTool } from '@aglyn/aglyn/plugin-manager/plugin-site-chat-tools'\n\n/**\n * The store's tools for the AI chat on its site (AGL-4250), as the chat\n * offers them to the model: names, descriptions and argument schemas only.\n * What each one does is `server/site-chat-tools.ts`, loaded on its first\n * call, so the boot that registers them reads nothing.\n */\n\ntype Definition = Omit<SiteChatTool, 'run'>\n\nexport const COMMERCE_SITE_CHAT_TOOLS: readonly Definition[] = [\n {\n name: 'commerce_product_details',\n kind: 'lookup',\n capability: 'answer',\n description:\n \"A product's options, prices (and sale prices), whether it asks for the day it will be used, and whether it has add-ons to choose. Use it before offering to add a product, or when a visitor asks about a product's options or price.\",\n inputSchema: {\n type: 'object',\n properties: {\n product: { type: 'string', description: \"The product's name, as the visitor or the site calls it.\" },\n },\n required: ['product'],\n additionalProperties: false,\n },\n },\n {\n name: 'commerce_propose_add_to_cart',\n kind: 'proposal',\n capability: 'cart',\n endpoints: ['commerce/cart'],\n description:\n 'Offer the visitor a card to add one product to their cart. Only once you know the product, its option where it has several, and the day where it asks for one. The visitor presses the card to add it; nothing is added before.',\n inputSchema: {\n type: 'object',\n properties: {\n product: { type: 'string', description: \"The product's name.\" },\n option: { type: 'string', description: 'The option the visitor chose, such as \"Adult\" or \"Large\"; empty when the product has one.' },\n quantity: { type: 'integer', description: 'How many, 1 or more.' },\n day: { type: 'string', description: 'The day it will be used, YYYY-MM-DD, for a product that asks; otherwise empty.' },\n },\n required: ['product', 'option', 'quantity', 'day'],\n additionalProperties: false,\n },\n },\n {\n name: 'commerce_stay_availability',\n kind: 'lookup',\n capability: 'answer',\n description:\n 'Whether a stay (a cabin, a room, a campsite) is free for the nights from a check-in day to a check-out day, and its nightly price. Use it whenever a visitor asks if dates are free.',\n inputSchema: {\n type: 'object',\n properties: {\n stay: { type: 'string', description: \"The stay's name.\" },\n checkIn: { type: 'string', description: 'Check-in day, YYYY-MM-DD.' },\n checkOut: { type: 'string', description: 'Check-out day, YYYY-MM-DD.' },\n },\n required: ['stay', 'checkIn', 'checkOut'],\n additionalProperties: false,\n },\n },\n {\n name: 'commerce_propose_reservation',\n kind: 'proposal',\n capability: 'book',\n endpoints: ['commerce/reserve'],\n description:\n 'Offer the visitor a card to reserve a stay for free dates, after commerce_stay_availability showed them free. The visitor enters their name and email on the card and pays at the normal checkout.',\n inputSchema: {\n type: 'object',\n properties: {\n stay: { type: 'string', description: \"The stay's name.\" },\n checkIn: { type: 'string', description: 'Check-in day, YYYY-MM-DD.' },\n checkOut: { type: 'string', description: 'Check-out day, YYYY-MM-DD.' },\n guests: { type: 'integer', description: 'How many guests; 0 when the visitor did not say.' },\n },\n required: ['stay', 'checkIn', 'checkOut', 'guests'],\n additionalProperties: false,\n },\n },\n]\n"],"names":["COMMERCE_SITE_CHAT_TOOLS","name","kind","capability","description","inputSchema","type","properties","product","required","additionalProperties","endpoints","option","quantity","day","stay","checkIn","checkOut","guests"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAaD,OAAO,MAAMA,2BAAkD;IAC7D;QACEC,MAAM;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,UAAU;gBAAC;gBAAQ;gBAAW;gBAAY;aAAS;YACnDC,sBAAsB;QACxB;IACF;CACD,CAAA"}
package/src/lib/site.js CHANGED
@@ -17,6 +17,7 @@
17
17
  import { mdiStorefrontOutline } from "@aglyn/shared-data-mdi";
18
18
  import * as Account from "./components/account.js";
19
19
  import * as Cart from "./components/cart.js";
20
+ import * as CurrencySelector from "./components/currency-selector.js";
20
21
  import * as Gate from "./components/gate.js";
21
22
  import * as GatedVideo from "./components/gated-video.js";
22
23
  import * as MemberFeed from "./components/member-feed.js";
@@ -139,6 +140,13 @@ import { BUNDLE_ID } from "./constants/bundle-common.js";
139
140
  component: ProductOptionsField.default,
140
141
  schema: ProductOptionsField.schema,
141
142
  presets: ProductOptionsField.presets
143
+ },
144
+ {
145
+ // Shoppers pick the currency prices show in (AGL-4248); hidden on a
146
+ // store that sells in one currency.
147
+ component: CurrencySelector.default,
148
+ schema: CurrencySelector.schema,
149
+ presets: CurrencySelector.presets
142
150
  }
143
151
  ];
144
152
  export function registerCommercePlugin() {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../../libs/plugins/commerce/src/lib/site.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Aglyn from '@aglyn/aglyn'\nimport { mdiStorefrontOutline } from '@aglyn/shared-data-mdi'\nimport * as Account from './components/account'\nimport * as Cart from './components/cart'\nimport * as Gate from './components/gate'\nimport * as GatedVideo from './components/gated-video'\nimport * as MemberFeed from './components/member-feed'\nimport * as MemberRecovery from './components/member-recovery'\nimport * as MemberSignin from './components/member-signin'\nimport * as MemberSignup from './components/member-signup'\nimport * as NewsletterSignup from './components/newsletter-signup'\nimport * as OrderStatus from './components/order-status'\nimport * as ProductDetail from './components/product-detail'\nimport * as ReservationWidget from './components/reservation-widget'\nimport * as ProductGrid from './components/product-grid'\nimport * as ProductReviews from './components/product-reviews'\nimport * as QuotePage from './components/quote-page'\nimport * as ProductOptionsField from './components/product-options-field'\nimport * as RelatedProducts from './components/related-products'\nimport * as ReturnRequest from './components/return-request'\nimport * as Wishlist from './components/wishlist'\nimport { BUNDLE_ID } from './constants/bundle-common'\n\n/**\n * Commerce UI feature plugin (AGL-290): the storefront component set,\n * built on the feature-plugin pattern (AGL-277) — depends on the mui\n * bundle for primitives/theming and registers alongside it in the\n * besigner and the tenant renderer. Components join `COMMERCE_BUNDLE`\n * as they land (PLP AGL-291, PDP AGL-292, cart AGL-293, …); ids are\n * persisted in screen docs and never renamed.\n */\nexport const COMMERCE_BUNDLE: Aglyn.FeatureBundleEntry[] = [\n {\n component: ProductGrid.default,\n schema: ProductGrid.schema,\n presets: ProductGrid.presets,\n },\n {\n component: ProductDetail.default,\n schema: ProductDetail.schema,\n presets: ProductDetail.presets,\n },\n {\n component: Cart.default,\n schema: Cart.schema,\n presets: Cart.presets,\n },\n {\n component: Account.default,\n schema: Account.schema,\n presets: Account.presets,\n },\n {\n component: Wishlist.default,\n schema: Wishlist.schema,\n presets: Wishlist.presets,\n },\n {\n component: NewsletterSignup.default,\n schema: NewsletterSignup.schema,\n presets: NewsletterSignup.presets,\n },\n {\n component: Gate.default,\n schema: Gate.schema,\n presets: Gate.presets,\n },\n {\n component: GatedVideo.default,\n schema: GatedVideo.schema,\n presets: GatedVideo.presets,\n },\n {\n component: MemberFeed.default,\n schema: MemberFeed.schema,\n presets: MemberFeed.presets,\n },\n {\n component: MemberRecovery.default,\n schema: MemberRecovery.schema,\n presets: MemberRecovery.presets,\n },\n {\n component: MemberSignin.default,\n schema: MemberSignin.schema,\n presets: MemberSignin.presets,\n },\n {\n component: MemberSignup.default,\n schema: MemberSignup.schema,\n presets: MemberSignup.presets,\n },\n {\n component: ReservationWidget.default,\n schema: ReservationWidget.schema,\n presets: ReservationWidget.presets,\n },\n {\n component: ProductReviews.default,\n schema: ProductReviews.schema,\n presets: ProductReviews.presets,\n },\n {\n component: RelatedProducts.default,\n schema: RelatedProducts.schema,\n presets: RelatedProducts.presets,\n },\n {\n component: OrderStatus.default,\n schema: OrderStatus.schema,\n presets: OrderStatus.presets,\n },\n {\n component: ReturnRequest.default,\n schema: ReturnRequest.schema,\n presets: ReturnRequest.presets,\n },\n {\n component: QuotePage.default,\n schema: QuotePage.schema,\n presets: QuotePage.presets,\n },\n {\n // A form field (AGL-4098): a product and its options, for a quote\n // request. Its picker is a chunk of its own.\n component: ProductOptionsField.default,\n schema: ProductOptionsField.schema,\n presets: ProductOptionsField.presets,\n },\n]\n\nexport function registerCommercePlugin(): void {\n // The canvas half only. The console registers the console half through its\n // own `console` surface, and a published page must never load console code\n // (AGL-3116): this runs on every page that places one of these elements.\n if (Aglyn.plugins.getDependency(BUNDLE_ID)) return\n Aglyn.plugins.addDependency(\n Aglyn.defineUiFeatureBundle(\n {\n bundleId: BUNDLE_ID,\n displayName: 'Commerce',\n description: 'Storefront blocks: product grids, detail, cart',\n icon: { path: mdiStorefrontOutline.path },\n components: COMMERCE_BUNDLE,\n },\n Aglyn.components,\n ),\n )\n}\n"],"names":["Aglyn","mdiStorefrontOutline","Account","Cart","Gate","GatedVideo","MemberFeed","MemberRecovery","MemberSignin","MemberSignup","NewsletterSignup","OrderStatus","ProductDetail","ReservationWidget","ProductGrid","ProductReviews","QuotePage","ProductOptionsField","RelatedProducts","ReturnRequest","Wishlist","BUNDLE_ID","COMMERCE_BUNDLE","component","default","schema","presets","registerCommercePlugin","plugins","getDependency","addDependency","defineUiFeatureBundle","bundleId","displayName","description","icon","path","components"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAED,YAAYA,WAAW,eAAc;AACrC,SAASC,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CH,WAAWN,oBAAoBO,OAAO;QACtCC,QAAQR,oBAAoBQ,MAAM;QAClCC,SAAST,oBAAoBS,OAAO;IACtC;CACD,CAAA;AAED,OAAO,SAASC;IACd,2EAA2E;IAC3E,2EAA2E;IAC3E,yEAAyE;IACzE,IAAI3B,MAAM4B,OAAO,CAACC,aAAa,CAACR,YAAY;IAC5CrB,MAAM4B,OAAO,CAACE,aAAa,CACzB9B,MAAM+B,qBAAqB,CACzB;QACEC,UAAUX;QACVY,aAAa;QACbC,aAAa;QACbC,MAAM;YAAEC,MAAMnC,qBAAqBmC,IAAI;QAAC;QACxCC,YAAYf;IACd,GACAtB,MAAMqC,UAAU;AAGtB"}
1
+ {"version":3,"sources":["../../../../../../libs/plugins/commerce/src/lib/site.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as Aglyn from '@aglyn/aglyn'\nimport { mdiStorefrontOutline } from '@aglyn/shared-data-mdi'\nimport * as Account from './components/account'\nimport * as Cart from './components/cart'\nimport * as CurrencySelector from './components/currency-selector'\nimport * as Gate from './components/gate'\nimport * as GatedVideo from './components/gated-video'\nimport * as MemberFeed from './components/member-feed'\nimport * as MemberRecovery from './components/member-recovery'\nimport * as MemberSignin from './components/member-signin'\nimport * as MemberSignup from './components/member-signup'\nimport * as NewsletterSignup from './components/newsletter-signup'\nimport * as OrderStatus from './components/order-status'\nimport * as ProductDetail from './components/product-detail'\nimport * as ReservationWidget from './components/reservation-widget'\nimport * as ProductGrid from './components/product-grid'\nimport * as ProductReviews from './components/product-reviews'\nimport * as QuotePage from './components/quote-page'\nimport * as ProductOptionsField from './components/product-options-field'\nimport * as RelatedProducts from './components/related-products'\nimport * as ReturnRequest from './components/return-request'\nimport * as Wishlist from './components/wishlist'\nimport { BUNDLE_ID } from './constants/bundle-common'\n\n/**\n * Commerce UI feature plugin (AGL-290): the storefront component set,\n * built on the feature-plugin pattern (AGL-277) — depends on the mui\n * bundle for primitives/theming and registers alongside it in the\n * besigner and the tenant renderer. Components join `COMMERCE_BUNDLE`\n * as they land (PLP AGL-291, PDP AGL-292, cart AGL-293, …); ids are\n * persisted in screen docs and never renamed.\n */\nexport const COMMERCE_BUNDLE: Aglyn.FeatureBundleEntry[] = [\n {\n component: ProductGrid.default,\n schema: ProductGrid.schema,\n presets: ProductGrid.presets,\n },\n {\n component: ProductDetail.default,\n schema: ProductDetail.schema,\n presets: ProductDetail.presets,\n },\n {\n component: Cart.default,\n schema: Cart.schema,\n presets: Cart.presets,\n },\n {\n component: Account.default,\n schema: Account.schema,\n presets: Account.presets,\n },\n {\n component: Wishlist.default,\n schema: Wishlist.schema,\n presets: Wishlist.presets,\n },\n {\n component: NewsletterSignup.default,\n schema: NewsletterSignup.schema,\n presets: NewsletterSignup.presets,\n },\n {\n component: Gate.default,\n schema: Gate.schema,\n presets: Gate.presets,\n },\n {\n component: GatedVideo.default,\n schema: GatedVideo.schema,\n presets: GatedVideo.presets,\n },\n {\n component: MemberFeed.default,\n schema: MemberFeed.schema,\n presets: MemberFeed.presets,\n },\n {\n component: MemberRecovery.default,\n schema: MemberRecovery.schema,\n presets: MemberRecovery.presets,\n },\n {\n component: MemberSignin.default,\n schema: MemberSignin.schema,\n presets: MemberSignin.presets,\n },\n {\n component: MemberSignup.default,\n schema: MemberSignup.schema,\n presets: MemberSignup.presets,\n },\n {\n component: ReservationWidget.default,\n schema: ReservationWidget.schema,\n presets: ReservationWidget.presets,\n },\n {\n component: ProductReviews.default,\n schema: ProductReviews.schema,\n presets: ProductReviews.presets,\n },\n {\n component: RelatedProducts.default,\n schema: RelatedProducts.schema,\n presets: RelatedProducts.presets,\n },\n {\n component: OrderStatus.default,\n schema: OrderStatus.schema,\n presets: OrderStatus.presets,\n },\n {\n component: ReturnRequest.default,\n schema: ReturnRequest.schema,\n presets: ReturnRequest.presets,\n },\n {\n component: QuotePage.default,\n schema: QuotePage.schema,\n presets: QuotePage.presets,\n },\n {\n // A form field (AGL-4098): a product and its options, for a quote\n // request. Its picker is a chunk of its own.\n component: ProductOptionsField.default,\n schema: ProductOptionsField.schema,\n presets: ProductOptionsField.presets,\n },\n {\n // Shoppers pick the currency prices show in (AGL-4248); hidden on a\n // store that sells in one currency.\n component: CurrencySelector.default,\n schema: CurrencySelector.schema,\n presets: CurrencySelector.presets,\n },\n]\n\nexport function registerCommercePlugin(): void {\n // The canvas half only. The console registers the console half through its\n // own `console` surface, and a published page must never load console code\n // (AGL-3116): this runs on every page that places one of these elements.\n if (Aglyn.plugins.getDependency(BUNDLE_ID)) return\n Aglyn.plugins.addDependency(\n Aglyn.defineUiFeatureBundle(\n {\n bundleId: BUNDLE_ID,\n displayName: 'Commerce',\n description: 'Storefront blocks: product grids, detail, cart',\n icon: { path: mdiStorefrontOutline.path },\n components: COMMERCE_BUNDLE,\n },\n Aglyn.components,\n ),\n )\n}\n"],"names":["Aglyn","mdiStorefrontOutline","Account","Cart","CurrencySelector","Gate","GatedVideo","MemberFeed","MemberRecovery","MemberSignin","MemberSignup","NewsletterSignup","OrderStatus","ProductDetail","ReservationWidget","ProductGrid","ProductReviews","QuotePage","ProductOptionsField","RelatedProducts","ReturnRequest","Wishlist","BUNDLE_ID","COMMERCE_BUNDLE","component","default","schema","presets","registerCommercePlugin","plugins","getDependency","addDependency","defineUiFeatureBundle","bundleId","displayName","description","icon","path","components"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAED,YAAYA,WAAW,eAAc;AACrC,SAASC,oBAAoB,QAAQ,yBAAwB;AAC7D,YAAYC,aAAa,0BAAsB;AAC/C,YAAYC,UAAU,uBAAmB;A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AAM;QAClCC,SAAST,oBAAoBS,OAAO;IACtC;IACA;QACE,oEAAoE;QACpE,oCAAoC;QACpCH,WAAWpB,iBAAiBqB,OAAO;QACnCC,QAAQtB,iBAAiBsB,MAAM;QAC/BC,SAASvB,iBAAiBuB,OAAO;IACnC;CACD,CAAA;AAED,OAAO,SAASC;IACd,2EAA2E;IAC3E,2EAA2E;IAC3E,yEAAyE;IACzE,IAAI5B,MAAM6B,OAAO,CAACC,aAAa,CAACR,YAAY;IAC5CtB,MAAM6B,OAAO,CAACE,aAAa,CACzB/B,MAAMgC,qBAAqB,CACzB;QACEC,UAAUX;QACVY,aAAa;QACbC,aAAa;QACbC,MAAM;YAAEC,MAAMpC,qBAAqBoC,IAAI;QAAC;QACxCC,YAAYf;IACd,GACAvB,MAAMsC,UAAU;AAGtB"}
@@ -16,6 +16,7 @@
16
16
  */ import { SHIPPINGEASY_DEFAULT_BASE_URL } from "./model/shippingeasy.js";
17
17
  import { TRACKING_CARRIERS } from "./model/tracking-url.js";
18
18
  import { EPOS_PRINT_NAMESPACE } from "./printing/render-epson.js";
19
+ import { ECB_DAILY_URL } from "./model/commerce-currency.js";
19
20
  /**
20
21
  * Hosts commerce's code names that are no recipient of anything (AGL-3610):
21
22
  * the carriers' public tracking pages, which `model/tracking-url.ts` turns a
@@ -42,6 +43,12 @@ import { EPOS_PRINT_NAMESPACE } from "./printing/render-epson.js";
42
43
  reason: 'ShippingEasy’s order API (`libs/plugins/commerce/src/lib/server/shippingeasy.ts`, AGL-3633). A site admin ' + 'connects their OWN ShippingEasy account with its API key, secret and store key, and commerce sends that ' + 'site’s paid orders into it and cancels canceled ones there. The customer chose and contracts with ' + 'ShippingEasy; the platform sends nothing to it for a site that has not connected it.',
43
44
  dataReceived: 'For a connected site only: each shippable order’s number, date, totals, ship-to and billing name, ' + 'address, email and phone, and its items (name, SKU, quantity, price, weight, options), signed with the ' + 'merchant’s own API key. Nothing from any other site or account.'
44
45
  });
46
+ hosts.push({
47
+ host: new URL(ECB_DAILY_URL).host,
48
+ disposition: 'not-a-subprocessor',
49
+ reason: 'The European Central Bank’s public daily reference rates file (`libs/plugins/commerce/src/lib/server/currency.ts`, ' + 'AGL-4248), fetched by the `fx-rates-refresh` job every six hours so stores selling in other currencies can price in them. ' + 'No personal data of a customer or their visitors reaches it: the request carries no parameter and no credential.',
50
+ dataReceived: 'Nothing from the platform beyond the request itself from a platform server. No customer, visitor, order or store data.'
51
+ });
45
52
  return {
46
53
  hosts
47
54
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../../libs/plugins/commerce/src/lib/subprocessors.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type {\n PluginEgressHostDeclaration,\n PluginSubprocessorsAnswer,\n} from '@aglyn/aglyn/plugin-manager/plugin-subprocessors'\nimport { SHIPPINGEASY_DEFAULT_BASE_URL } from './model/shippingeasy'\nimport { TRACKING_CARRIERS } from './model/tracking-url'\nimport { EPOS_PRINT_NAMESPACE } from './printing/render-epson'\n\n/**\n * Hosts commerce's code names that are no recipient of anything (AGL-3610):\n * the carriers' public tracking pages, which `model/tracking-url.ts` turns a\n * tracking number into a link to. No server here requests them — the link is\n * printed in a buyer email and on the order status page, and only the buyer's\n * own browser opens it, when they click. The Epson ePOS-Print namespace is\n * the same: an identifier inside the XML a receipt printer is handed.\n */\nexport function commerceSubprocessors(): PluginSubprocessorsAnswer {\n const hosts: PluginEgressHostDeclaration[] = TRACKING_CARRIERS.map(\n (carrier) => ({\n host: new URL(carrier.url('TRACKING')).host,\n disposition: 'no-request',\n reason:\n `${carrier.label}'s public tracking page. Commerce builds a link to it from a ` +\n 'shipment’s carrier and tracking number (`libs/plugins/commerce/src/lib/model/tracking-url.ts`) ' +\n 'and prints it in the buyer’s shipping email and order status page; no platform server ever requests it.',\n dataReceived:\n 'Nothing from the platform. When the buyer clicks the link, their own browser sends the carrier the tracking number in the URL; no customer record, email or order detail goes with it.',\n }),\n )\n hosts.push({\n host: new URL(EPOS_PRINT_NAMESPACE).host,\n disposition: 'no-request',\n reason:\n 'The ePOS-Print XML namespace (`libs/plugins/commerce/src/lib/printing/render-epson.ts`) on the print job an Epson receipt printer receives when it polls. A namespace is an identifier that happens to look like a URL; neither the platform nor the printer requests it.',\n dataReceived: 'Nothing. No request is made.',\n })\n hosts.push({\n host: new URL(SHIPPINGEASY_DEFAULT_BASE_URL).host,\n disposition: 'not-a-subprocessor',\n reason:\n 'ShippingEasy’s order API (`libs/plugins/commerce/src/lib/server/shippingeasy.ts`, AGL-3633). A site admin ' +\n 'connects their OWN ShippingEasy account with its API key, secret and store key, and commerce sends that ' +\n 'site’s paid orders into it and cancels canceled ones there. The customer chose and contracts with ' +\n 'ShippingEasy; the platform sends nothing to it for a site that has not connected it.',\n dataReceived:\n 'For a connected site only: each shippable order’s number, date, totals, ship-to and billing name, ' +\n 'address, email and phone, and its items (name, SKU, quantity, price, weight, options), signed with the ' +\n 'merchant’s own API key. Nothing from any other site or account.',\n })\n return { hosts }\n}\n"],"names":["SHIPPINGEASY_DEFAULT_BASE_URL","TRACKING_CARRIERS","EPOS_PRINT_NAMESPACE","commerceSubprocessors","hosts","map","carrier","host","URL","url","disposition","reason","label","dataReceived","push"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAMD,SAASA,6BAA6B,QAAQ,0BAAsB;AACpE,SAASC,iBAAiB,QAAQ,0BAAsB;AACxD,SAASC,oBAAoB,QAAQ,6BAAyB;AAE9D;;;;;;;CAOC,GACD,OAAO,SAASC;IACd,MAAMC,QAAuCH,kBAAkBI,GAAG,CAChE,CAACC,UAAa,CAAA;YACZC,MAAM,IAAIC,IAAIF,QAAQG,GAAG,CAAC,aAAaF,IAAI;YAC3CG,aAAa;YACbC,QACE,GAAGL,QAAQM,KAAK,CAAC,6DAA6D,CAAC,GAC/E,oGACA;YACFC,cACE;QACJ,CAAA;IAEFT,MAAMU,IAAI,CAAC;QACTP,MAAM,IAAIC,IAAIN,sBAAsBK,IAAI;QACxCG,aAAa;QACbC,QACE;QACFE,cAAc;IAChB;IACAT,MAAMU,IAAI,CAAC;QACTP,MAAM,IAAIC,IAAIR,+BAA+BO,IAAI;QACjDG,aAAa;QACbC,QACE,+GACA,6GACA,uGACA;QACFE,cACE,uGACA,4GACA;IACJ;IACA,OAAO;QAAET;IAAM;AACjB"}
1
+ {"version":3,"sources":["../../../../../../libs/plugins/commerce/src/lib/subprocessors.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type {\n PluginEgressHostDeclaration,\n PluginSubprocessorsAnswer,\n} from '@aglyn/aglyn/plugin-manager/plugin-subprocessors'\nimport { SHIPPINGEASY_DEFAULT_BASE_URL } from './model/shippingeasy'\nimport { TRACKING_CARRIERS } from './model/tracking-url'\nimport { EPOS_PRINT_NAMESPACE } from './printing/render-epson'\nimport { ECB_DAILY_URL } from './model/commerce-currency'\n\n/**\n * Hosts commerce's code names that are no recipient of anything (AGL-3610):\n * the carriers' public tracking pages, which `model/tracking-url.ts` turns a\n * tracking number into a link to. No server here requests them — the link is\n * printed in a buyer email and on the order status page, and only the buyer's\n * own browser opens it, when they click. The Epson ePOS-Print namespace is\n * the same: an identifier inside the XML a receipt printer is handed.\n */\nexport function commerceSubprocessors(): PluginSubprocessorsAnswer {\n const hosts: PluginEgressHostDeclaration[] = TRACKING_CARRIERS.map(\n (carrier) => ({\n host: new URL(carrier.url('TRACKING')).host,\n disposition: 'no-request',\n reason:\n `${carrier.label}'s public tracking page. Commerce builds a link to it from a ` +\n 'shipment’s carrier and tracking number (`libs/plugins/commerce/src/lib/model/tracking-url.ts`) ' +\n 'and prints it in the buyer’s shipping email and order status page; no platform server ever requests it.',\n dataReceived:\n 'Nothing from the platform. When the buyer clicks the link, their own browser sends the carrier the tracking number in the URL; no customer record, email or order detail goes with it.',\n }),\n )\n hosts.push({\n host: new URL(EPOS_PRINT_NAMESPACE).host,\n disposition: 'no-request',\n reason:\n 'The ePOS-Print XML namespace (`libs/plugins/commerce/src/lib/printing/render-epson.ts`) on the print job an Epson receipt printer receives when it polls. A namespace is an identifier that happens to look like a URL; neither the platform nor the printer requests it.',\n dataReceived: 'Nothing. No request is made.',\n })\n hosts.push({\n host: new URL(SHIPPINGEASY_DEFAULT_BASE_URL).host,\n disposition: 'not-a-subprocessor',\n reason:\n 'ShippingEasy’s order API (`libs/plugins/commerce/src/lib/server/shippingeasy.ts`, AGL-3633). A site admin ' +\n 'connects their OWN ShippingEasy account with its API key, secret and store key, and commerce sends that ' +\n 'site’s paid orders into it and cancels canceled ones there. The customer chose and contracts with ' +\n 'ShippingEasy; the platform sends nothing to it for a site that has not connected it.',\n dataReceived:\n 'For a connected site only: each shippable order’s number, date, totals, ship-to and billing name, ' +\n 'address, email and phone, and its items (name, SKU, quantity, price, weight, options), signed with the ' +\n 'merchant’s own API key. Nothing from any other site or account.',\n })\n hosts.push({\n host: new URL(ECB_DAILY_URL).host,\n disposition: 'not-a-subprocessor',\n reason:\n 'The European Central Bank’s public daily reference rates file (`libs/plugins/commerce/src/lib/server/currency.ts`, ' +\n 'AGL-4248), fetched by the `fx-rates-refresh` job every six hours so stores selling in other currencies can price in them. ' +\n 'No personal data of a customer or their visitors reaches it: the request carries no parameter and no credential.',\n dataReceived:\n 'Nothing from the platform beyond the request itself from a platform server. No customer, visitor, order or store data.',\n })\n return { hosts }\n}\n"],"names":["SHIPPINGEASY_DEFAULT_BASE_URL","TRACKING_CARRIERS","EPOS_PRINT_NAMESPACE","ECB_DAILY_URL","commerceSubprocessors","hosts","map","carrier","host","URL","url","disposition","reason","label","dataReceived","push"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAMD,SAASA,6BAA6B,QAAQ,0BAAsB;AACpE,SAASC,iBAAiB,QAAQ,0BAAsB;AACxD,SAASC,oBAAoB,QAAQ,6BAAyB;AAC9D,SAASC,aAAa,QAAQ,+BAA2B;AAEzD;;;;;;;CAOC,GACD,OAAO,SAASC;IACd,MAAMC,QAAuCJ,kBAAkBK,GAAG,CAChE,CAACC,UAAa,CAAA;YACZC,MAAM,IAAIC,IAAIF,QAAQG,GAAG,CAAC,aAAaF,IAAI;YAC3CG,aAAa;YACbC,QACE,GAAGL,QAAQM,KAAK,CAAC,6DAA6D,CAAC,GAC/E,oGACA;YACFC,cACE;QACJ,CAAA;IAEFT,MAAMU,IAAI,CAAC;QACTP,MAAM,IAAIC,IAAIP,sBAAsBM,IAAI;QACxCG,aAAa;QACbC,QACE;QACFE,cAAc;IAChB;IACAT,MAAMU,IAAI,CAAC;QACTP,MAAM,IAAIC,IAAIT,+BAA+BQ,IAAI;QACjDG,aAAa;QACbC,QACE,+GACA,6GACA,uGACA;QACFE,cACE,uGACA,4GACA;IACJ;IACAT,MAAMU,IAAI,CAAC;QACTP,MAAM,IAAIC,IAAIN,eAAeK,IAAI;QACjCG,aAAa;QACbC,QACE,wHACA,+HACA;QACFE,cACE;IACJ;IACA,OAAO;QAAET;IAAM;AACjB"}