@foxy.io/elements 1.24.1-beta.2 → 1.25.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (196) hide show
  1. package/dist/cdn/foxy-access-recovery-form.js +1 -1
  2. package/dist/cdn/foxy-address-card.js +1 -1
  3. package/dist/cdn/foxy-address-form.js +1 -1
  4. package/dist/cdn/foxy-admin-subscription-card.js +1 -1
  5. package/dist/cdn/foxy-api-browser.js +1 -1
  6. package/dist/cdn/foxy-applied-coupon-code-card.js +1 -1
  7. package/dist/cdn/foxy-applied-coupon-code-form.js +1 -1
  8. package/dist/cdn/foxy-applied-tax-card.js +1 -1
  9. package/dist/cdn/foxy-attribute-card.js +1 -1
  10. package/dist/cdn/foxy-attribute-form.js +1 -1
  11. package/dist/cdn/foxy-cancellation-form.js +1 -1
  12. package/dist/cdn/foxy-cart-card.js +1 -1
  13. package/dist/cdn/foxy-cart-form.js +1 -1
  14. package/dist/cdn/foxy-client-card.js +1 -1
  15. package/dist/cdn/foxy-client-form.js +1 -1
  16. package/dist/cdn/foxy-collection-page.js +1 -1
  17. package/dist/cdn/foxy-collection-pages.js +1 -1
  18. package/dist/cdn/foxy-copy-to-clipboard.js +1 -1
  19. package/dist/cdn/foxy-coupon-card.js +1 -1
  20. package/dist/cdn/foxy-coupon-code-form.js +1 -1
  21. package/dist/cdn/foxy-coupon-codes-form.js +1 -1
  22. package/dist/cdn/foxy-coupon-detail-card.js +1 -1
  23. package/dist/cdn/foxy-coupon-form.js +1 -1
  24. package/dist/cdn/foxy-custom-field-card.js +1 -1
  25. package/dist/cdn/foxy-custom-field-form.js +1 -1
  26. package/dist/cdn/foxy-customer-card.js +1 -1
  27. package/dist/cdn/foxy-customer-form.js +1 -1
  28. package/dist/cdn/foxy-customer-portal-settings.js +1 -1
  29. package/dist/cdn/foxy-customer-portal.js +1 -1
  30. package/dist/cdn/foxy-customer.js +3 -3
  31. package/dist/cdn/foxy-customers-table.js +1 -1
  32. package/dist/cdn/foxy-discount-builder.js +1 -1
  33. package/dist/cdn/foxy-discount-card.js +1 -1
  34. package/dist/cdn/foxy-discount-detail-card.js +1 -1
  35. package/dist/cdn/foxy-donation.js +1 -1
  36. package/dist/cdn/foxy-downloadable-card.js +1 -1
  37. package/dist/cdn/foxy-downloadable-form.js +1 -1
  38. package/dist/cdn/foxy-email-template-card.js +1 -1
  39. package/dist/cdn/foxy-email-template-form.js +1 -1
  40. package/dist/cdn/foxy-error-entry-card.js +1 -1
  41. package/dist/cdn/foxy-filter-attribute-card.js +1 -1
  42. package/dist/cdn/foxy-filter-attribute-form.js +1 -1
  43. package/dist/cdn/foxy-form-dialog.js +1 -1
  44. package/dist/cdn/foxy-generate-codes-form.js +1 -1
  45. package/dist/cdn/foxy-gift-card-card.js +1 -1
  46. package/dist/cdn/foxy-gift-card-code-form.js +1 -1
  47. package/dist/cdn/foxy-gift-card-code-log-card.js +1 -1
  48. package/dist/cdn/foxy-gift-card-codes-form.js +1 -1
  49. package/dist/cdn/foxy-gift-card-form.js +1 -1
  50. package/dist/cdn/foxy-i18n-editor.js +2 -2
  51. package/dist/cdn/foxy-i18n.js +1 -1
  52. package/dist/cdn/foxy-integration-card.js +1 -1
  53. package/dist/cdn/foxy-integration-form.js +1 -1
  54. package/dist/cdn/foxy-item-card.js +1 -1
  55. package/dist/cdn/foxy-item-category-card.js +1 -1
  56. package/dist/cdn/foxy-item-category-form.js +1 -1
  57. package/dist/cdn/foxy-item-form.js +1 -1
  58. package/dist/cdn/foxy-item-option-card.js +1 -1
  59. package/dist/cdn/foxy-item-option-form.js +1 -1
  60. package/dist/cdn/foxy-items-form.js +1 -1
  61. package/dist/cdn/foxy-native-integration-card.js +1 -0
  62. package/dist/cdn/foxy-native-integration-form.js +1 -0
  63. package/dist/cdn/foxy-pagination.js +1 -1
  64. package/dist/cdn/foxy-passkey-card.js +1 -1
  65. package/dist/cdn/foxy-passkey-form.js +1 -1
  66. package/dist/cdn/foxy-payment-card.js +1 -1
  67. package/dist/cdn/foxy-payment-method-card.js +1 -1
  68. package/dist/cdn/foxy-payments-api-fraud-protection-card.js +1 -1
  69. package/dist/cdn/foxy-payments-api-fraud-protection-form.js +1 -1
  70. package/dist/cdn/foxy-payments-api-payment-method-card.js +1 -1
  71. package/dist/cdn/foxy-payments-api-payment-method-form.js +1 -1
  72. package/dist/cdn/foxy-payments-api-payment-preset-card.js +1 -1
  73. package/dist/cdn/foxy-payments-api-payment-preset-form.js +1 -1
  74. package/dist/cdn/foxy-query-builder.js +1 -1
  75. package/dist/cdn/foxy-report-form.js +1 -1
  76. package/dist/cdn/foxy-reports-table.js +5 -5
  77. package/dist/cdn/foxy-shipment-card.js +2 -2
  78. package/dist/cdn/foxy-shipping-method-card.js +1 -1
  79. package/dist/cdn/foxy-sign-in-form.js +1 -1
  80. package/dist/cdn/foxy-spinner.js +2 -2
  81. package/dist/cdn/foxy-store-card.js +1 -1
  82. package/dist/cdn/foxy-store-form.js +1 -1
  83. package/dist/cdn/foxy-store-shipping-method-form.js +1 -1
  84. package/dist/cdn/foxy-subscription-card.js +1 -1
  85. package/dist/cdn/foxy-subscription-form.js +3 -3
  86. package/dist/cdn/foxy-subscription-settings-form.js +1 -1
  87. package/dist/cdn/foxy-subscriptions-table.js +1 -1
  88. package/dist/cdn/foxy-table.js +1 -1
  89. package/dist/cdn/foxy-tax-card.js +1 -1
  90. package/dist/cdn/foxy-tax-form.js +1 -1
  91. package/dist/cdn/foxy-template-config-form.js +1 -1
  92. package/dist/cdn/foxy-template-form.js +1 -1
  93. package/dist/cdn/foxy-template-set-card.js +1 -1
  94. package/dist/cdn/foxy-template-set-form.js +1 -1
  95. package/dist/cdn/foxy-transaction-card.js +1 -1
  96. package/dist/cdn/foxy-transaction.js +1 -1
  97. package/dist/cdn/foxy-transactions-table.js +4 -4
  98. package/dist/cdn/foxy-user-card.js +1 -1
  99. package/dist/cdn/foxy-user-form.js +1 -1
  100. package/dist/cdn/foxy-users-table.js +1 -1
  101. package/dist/cdn/foxy-webhook-card.js +1 -1
  102. package/dist/cdn/foxy-webhook-form.js +1 -1
  103. package/dist/cdn/foxy-webhook-log-card.js +1 -1
  104. package/dist/cdn/foxy-webhook-status-card.js +1 -1
  105. package/dist/cdn/{shared-9aa72495.js → shared-074a74c3.js} +1 -1
  106. package/dist/cdn/{shared-fd40a40c.js → shared-093b64b4.js} +1 -1
  107. package/dist/cdn/{shared-5db85492.js → shared-1105e4b9.js} +1 -1
  108. package/dist/cdn/{shared-31d8e3b8.js → shared-112dbca7.js} +1 -1
  109. package/dist/cdn/{shared-d1f5de89.js → shared-1313f293.js} +1 -1
  110. package/dist/cdn/{shared-7a455b15.js → shared-131988fc.js} +1 -1
  111. package/dist/cdn/{shared-ddac7722.js → shared-18672d26.js} +2 -2
  112. package/dist/cdn/{shared-0c0ee663.js → shared-1a65fd20.js} +1 -1
  113. package/dist/cdn/{shared-bee111d6.js → shared-1dbad347.js} +1 -1
  114. package/dist/cdn/{shared-ff7fd5fa.js → shared-21293163.js} +1 -1
  115. package/dist/cdn/shared-26dea180.js +1 -0
  116. package/dist/cdn/{shared-406ce9ad.js → shared-2f082f50.js} +1 -1
  117. package/dist/cdn/{shared-b446c140.js → shared-417ab233.js} +1 -1
  118. package/dist/cdn/{shared-f0a9f3c2.js → shared-468de081.js} +1 -1
  119. package/dist/cdn/{shared-de3dae6c.js → shared-4c3cb511.js} +1 -1
  120. package/dist/cdn/{shared-9954ee26.js → shared-4d555419.js} +1 -1
  121. package/dist/cdn/{shared-799dc083.js → shared-4e05dfb4.js} +1 -1
  122. package/dist/cdn/{shared-2edcd981.js → shared-51a5af7e.js} +1 -1
  123. package/dist/cdn/{shared-6daeb197.js → shared-53d66db2.js} +3 -3
  124. package/dist/cdn/{shared-601f27b1.js → shared-5742a841.js} +1 -1
  125. package/dist/cdn/{shared-773e7177.js → shared-5d718eaf.js} +1 -1
  126. package/dist/cdn/{shared-7723f756.js → shared-5d795aaf.js} +1 -1
  127. package/dist/cdn/shared-5e932eb5.js +1 -0
  128. package/dist/cdn/{shared-3b709ddc.js → shared-662c576b.js} +1 -1
  129. package/dist/cdn/{shared-099c1f57.js → shared-6e704d83.js} +1 -1
  130. package/dist/cdn/{shared-ba93be6b.js → shared-702eae16.js} +1 -1
  131. package/dist/cdn/{shared-fff03a45.js → shared-71b3559f.js} +3 -3
  132. package/dist/cdn/{shared-9048eeb2.js → shared-732bee4b.js} +1 -1
  133. package/dist/cdn/{shared-f29acc38.js → shared-76e71481.js} +1 -1
  134. package/dist/cdn/{shared-1196b6a7.js → shared-783f5705.js} +1 -1
  135. package/dist/cdn/{shared-f5bbb1e0.js → shared-7b771301.js} +1 -1
  136. package/dist/cdn/{shared-7abbc95c.js → shared-7d933f9d.js} +1 -1
  137. package/dist/cdn/{shared-5280c80a.js → shared-870074ff.js} +1 -1
  138. package/dist/cdn/{shared-27d21f4a.js → shared-8771fb61.js} +1 -1
  139. package/dist/cdn/{shared-621b3283.js → shared-8c681381.js} +1 -1
  140. package/dist/cdn/{shared-9b486845.js → shared-92de4f37.js} +1 -1
  141. package/dist/cdn/{shared-ef7f2d07.js → shared-96215749.js} +1 -1
  142. package/dist/cdn/{shared-ad80244a.js → shared-9771ef0f.js} +1 -1
  143. package/dist/cdn/{shared-8f922de8.js → shared-a52c3d8c.js} +1 -1
  144. package/dist/cdn/{shared-94798eb5.js → shared-b8963ec6.js} +1 -1
  145. package/dist/cdn/{shared-13fbea95.js → shared-c00049b2.js} +1 -1
  146. package/dist/cdn/{shared-fa7539af.js → shared-c320cfef.js} +1 -1
  147. package/dist/cdn/{shared-fcfbfbdb.js → shared-ca428891.js} +1 -1
  148. package/dist/cdn/{shared-b87d1af0.js → shared-cb9cdc88.js} +1 -1
  149. package/dist/cdn/{shared-c76ef8d8.js → shared-d01f42d0.js} +7 -7
  150. package/dist/cdn/{shared-59fc6288.js → shared-d123bea6.js} +1 -1
  151. package/dist/cdn/{shared-c839e147.js → shared-da5e32c1.js} +1 -1
  152. package/dist/cdn/{shared-f21e5761.js → shared-e2db3ab5.js} +1 -1
  153. package/dist/cdn/{shared-eb8a0fdf.js → shared-e3096241.js} +1 -1
  154. package/dist/cdn/{shared-5103c1b4.js → shared-e312da08.js} +1 -1
  155. package/dist/cdn/{shared-3f04e4cc.js → shared-e60dc924.js} +1 -1
  156. package/dist/cdn/{shared-efaf8d49.js → shared-e79b5765.js} +1 -1
  157. package/dist/cdn/{shared-d90dbae7.js → shared-f1b36324.js} +1 -1
  158. package/dist/cdn/{shared-e5239bec.js → shared-f3b8de28.js} +1 -1
  159. package/dist/cdn/{shared-3c2414d4.js → shared-fc99076a.js} +1 -1
  160. package/dist/cdn/{shared-5784c088.js → shared-fe927c53.js} +1 -1
  161. package/dist/cdn/{shared-4205699e.js → shared-fed6cd4d.js} +1 -1
  162. package/dist/cdn/{shared-5a889c45.js → shared-fff7db77.js} +1 -1
  163. package/dist/cdn/translations/native-integration-card/en.json +20 -0
  164. package/dist/cdn/translations/native-integration-form/en.json +262 -0
  165. package/dist/elements/public/NativeIntegrationCard/NativeIntegrationCard.d.ts +19 -0
  166. package/dist/elements/public/NativeIntegrationCard/NativeIntegrationCard.js +87 -0
  167. package/dist/elements/public/NativeIntegrationCard/NativeIntegrationCard.js.map +1 -0
  168. package/dist/elements/public/NativeIntegrationCard/index.d.ts +4 -0
  169. package/dist/elements/public/NativeIntegrationCard/index.js +6 -0
  170. package/dist/elements/public/NativeIntegrationCard/index.js.map +1 -0
  171. package/dist/elements/public/NativeIntegrationCard/types.d.ts +3 -0
  172. package/dist/elements/public/NativeIntegrationCard/types.js +2 -0
  173. package/dist/elements/public/NativeIntegrationCard/types.js.map +1 -0
  174. package/dist/elements/public/NativeIntegrationForm/NativeIntegrationForm.d.ts +133 -0
  175. package/dist/elements/public/NativeIntegrationForm/NativeIntegrationForm.js +759 -0
  176. package/dist/elements/public/NativeIntegrationForm/NativeIntegrationForm.js.map +1 -0
  177. package/dist/elements/public/NativeIntegrationForm/defaults.d.ts +62 -0
  178. package/dist/elements/public/NativeIntegrationForm/defaults.js +63 -0
  179. package/dist/elements/public/NativeIntegrationForm/defaults.js.map +1 -0
  180. package/dist/elements/public/NativeIntegrationForm/index.d.ts +9 -0
  181. package/dist/elements/public/NativeIntegrationForm/index.js +11 -0
  182. package/dist/elements/public/NativeIntegrationForm/index.js.map +1 -0
  183. package/dist/elements/public/NativeIntegrationForm/types.d.ts +89 -0
  184. package/dist/elements/public/NativeIntegrationForm/types.js +2 -0
  185. package/dist/elements/public/NativeIntegrationForm/types.js.map +1 -0
  186. package/dist/elements/public/index.d.ts +2 -0
  187. package/dist/elements/public/index.defined.d.ts +2 -0
  188. package/dist/elements/public/index.defined.js +2 -0
  189. package/dist/elements/public/index.defined.js.map +1 -1
  190. package/dist/elements/public/index.js +2 -0
  191. package/dist/elements/public/index.js.map +1 -1
  192. package/dist/mixins/themeable.js +4 -0
  193. package/dist/mixins/themeable.js.map +1 -1
  194. package/package.json +1 -1
  195. package/dist/cdn/shared-584174ff.js +0 -1
  196. package/dist/cdn/shared-630a0ff2.js +0 -1
@@ -0,0 +1,759 @@
1
+ import { TranslatableMixin } from "../../../mixins/translatable.js";
2
+ import { BooleanSelector } from '@foxy.io/sdk/core';
3
+ import { InternalForm } from "../../internal/InternalForm/InternalForm.js";
4
+ import { html } from 'lit-html';
5
+ import * as defaults from "./defaults.js";
6
+ import memoize from 'lodash-es/memoize';
7
+ const NS = 'native-integration-form';
8
+ const Base = TranslatableMixin(InternalForm, NS);
9
+ /**
10
+ * Form element for configuring native integrations (`fx:native_integration`).
11
+ *
12
+ * @slot timestamps:before
13
+ * @slot timestamps:after
14
+ * @slot delete:before
15
+ * @slot delete:after
16
+ * @slot create:before
17
+ * @slot create:after
18
+ * @slot provider:before
19
+ * @slot provider:after
20
+ * @slot avalara-service-url:before
21
+ * @slot avalara-service-url:after
22
+ * @slot avalara-id:before
23
+ * @slot avalara-id:after
24
+ * @slot avalara-key:before
25
+ * @slot avalara-key:after
26
+ * @slot avalara-company-code:before
27
+ * @slot avalara-company-code:after
28
+ * @slot avalara-options:before
29
+ * @slot avalara-options:after
30
+ * @slot avalara-address-validation-countries:before
31
+ * @slot avalara-address-validation-countries:after
32
+ * @slot avalara-category-to-product-tax-code-mappings:before
33
+ * @slot avalara-category-to-product-tax-code-mappings:after
34
+ * @slot taxjar-api-token:before
35
+ * @slot taxjar-api-token:after
36
+ * @slot taxjar-category-to-product-tax-code-mappings:before
37
+ * @slot taxjar-category-to-product-tax-code-mappings:after
38
+ * @slot taxjar-options:before
39
+ * @slot taxjar-options:after
40
+ * @slot onesource-service-url:before
41
+ * @slot onesource-service-url:after
42
+ * @slot onesource-external-company-id:before
43
+ * @slot onesource-external-company-id:after
44
+ * @slot onesource-calling-system-number:before
45
+ * @slot onesource-calling-system-number:after
46
+ * @slot onesource-from-city:before
47
+ * @slot onesource-from-city:after
48
+ * @slot onesource-host-system:before
49
+ * @slot onesource-host-system:after
50
+ * @slot onesource-company-role:before
51
+ * @slot onesource-company-role:after
52
+ * @slot onesource-part-number-product-option:before
53
+ * @slot onesource-part-number-product-option:after
54
+ * @slot onesource-product-order-priority:before
55
+ * @slot onesource-product-order-priority:after
56
+ * @slot onesource-audit-settings:before
57
+ * @slot onesource-audit-settings:after
58
+ * @slot webhook-service:before
59
+ * @slot webhook-service:after
60
+ * @slot webhook-json-title:before
61
+ * @slot webhook-json-title:after
62
+ * @slot webhook-json-encryption-key:before
63
+ * @slot webhook-json-encryption-key:after
64
+ * @slot webhook-json-url:before
65
+ * @slot webhook-json-url:after
66
+ * @slot webhook-json-events:before
67
+ * @slot webhook-json-events:after
68
+ * @slot webhook-legacy-xml-title:before
69
+ * @slot webhook-legacy-xml-title:after
70
+ * @slot webhook-legacy-xml-url:before
71
+ * @slot webhook-legacy-xml-url:after
72
+ * @slot webhook-webflow-site-id:before
73
+ * @slot webhook-webflow-site-id:after
74
+ * @slot webhook-webflow-site-name:before
75
+ * @slot webhook-webflow-site-name:after
76
+ * @slot webhook-webflow-collection-id:before
77
+ * @slot webhook-webflow-collection-id:after
78
+ * @slot webhook-webflow-collection-name:before
79
+ * @slot webhook-webflow-collection-name:after
80
+ * @slot webhook-webflow-sku-field-id:before
81
+ * @slot webhook-webflow-sku-field-id:after
82
+ * @slot webhook-webflow-sku-field-name:before
83
+ * @slot webhook-webflow-sku-field-name:after
84
+ * @slot webhook-webflow-inventory-field-id:before
85
+ * @slot webhook-webflow-inventory-field-id:after
86
+ * @slot webhook-webflow-inventory-field-name:before
87
+ * @slot webhook-webflow-inventory-field-name:after
88
+ * @slot webhook-webflow-auth:before
89
+ * @slot webhook-webflow-auth:after
90
+ * @slot webhook-zapier-event:before
91
+ * @slot webhook-zapier-event:after
92
+ * @slot webhook-zapier-url:before
93
+ * @slot webhook-zapier-url:after
94
+ *
95
+ * @element foxy-native-integration-form
96
+ * @since 1.25.0
97
+ */
98
+ export class NativeIntegrationForm extends Base {
99
+ constructor() {
100
+ super(...arguments);
101
+ this.templates = {};
102
+ this.__createConfigGetterFor = memoize((key) => {
103
+ return () => { var _a; return (_a = this.__config) === null || _a === void 0 ? void 0 : _a[key]; };
104
+ });
105
+ this.__createConfigSetterFor = memoize((key) => {
106
+ return (value) => (this.__config = { [key]: value });
107
+ });
108
+ this.__providerGetValue = () => {
109
+ var _a;
110
+ return (_a = this.form.provider) !== null && _a !== void 0 ? _a : 'avalara';
111
+ };
112
+ this.__providerSetValue = (value) => {
113
+ this.edit({ provider: value, config: '{}' });
114
+ this.__config = {};
115
+ };
116
+ this.__templateProviderOptions = [
117
+ { value: 'avalara', label: 'option_avalara' },
118
+ { value: 'onesource', label: 'option_onesource' },
119
+ { value: 'taxjar', label: 'option_taxjar' },
120
+ { value: 'webflow', label: 'option_webflow' },
121
+ ];
122
+ this.__avalaraConfigOptions = [
123
+ {
124
+ value: 'use_ava_tax',
125
+ label: 'option_use_ava_tax',
126
+ },
127
+ {
128
+ value: 'enable_colorado_delivery_fee',
129
+ label: 'option_enable_colorado_delivery_fee',
130
+ },
131
+ {
132
+ value: 'create_invoice',
133
+ label: 'option_create_invoice',
134
+ },
135
+ {
136
+ value: 'use_address_validation',
137
+ label: 'option_use_address_validation',
138
+ },
139
+ ];
140
+ this.__taxjarConfigOptions = [
141
+ {
142
+ value: 'create_invoice',
143
+ label: 'option_create_invoice',
144
+ },
145
+ ];
146
+ this.__configOptionsGetValue = () => {
147
+ const config = this.__config;
148
+ const value = [];
149
+ if (config === null || config === void 0 ? void 0 : config.enable_colorado_delivery_fee)
150
+ value.push('enable_colorado_delivery_fee');
151
+ if (config === null || config === void 0 ? void 0 : config.use_address_validation)
152
+ value.push('use_address_validation');
153
+ if (config === null || config === void 0 ? void 0 : config.create_invoice)
154
+ value.push('create_invoice');
155
+ if (config === null || config === void 0 ? void 0 : config.use_ava_tax)
156
+ value.push('use_ava_tax');
157
+ return value;
158
+ };
159
+ this.__configOptionsSetValue = (value) => {
160
+ this.__config = {
161
+ enable_colorado_delivery_fee: value.includes('enable_colorado_delivery_fee'),
162
+ use_address_validation: value.includes('use_address_validation'),
163
+ create_invoice: value.includes('create_invoice'),
164
+ use_ava_tax: value.includes('use_ava_tax'),
165
+ };
166
+ };
167
+ this.__avalaraAddressValidationCountriesOptions = [
168
+ { value: 'US', label: 'option_US' },
169
+ { value: 'CA', label: 'option_CA' },
170
+ ];
171
+ this.__codeMappingsGetValue = () => {
172
+ var _a, _b;
173
+ const mappings = (_b = (_a = this.__config) === null || _a === void 0 ? void 0 : _a.category_to_product_tax_code_mappings) !== null && _b !== void 0 ? _b : {};
174
+ return Object.entries(mappings).map(([foxyCategory, vndTaxCode]) => {
175
+ return { value: `${foxyCategory}:${vndTaxCode}` };
176
+ });
177
+ };
178
+ this.__codeMappingsSetValue = (value) => {
179
+ const mappings = {};
180
+ for (const { value: mapping } of value) {
181
+ const [foxyCategory, vndTaxCode] = mapping.split(':');
182
+ if (foxyCategory && vndTaxCode)
183
+ mappings[foxyCategory] = vndTaxCode;
184
+ }
185
+ this.__config = { category_to_product_tax_code_mappings: mappings };
186
+ };
187
+ this.__onesourceCompanyRoleOptions = [
188
+ { value: 'B', label: 'option_buyer' },
189
+ { value: 'M', label: 'option_middleman' },
190
+ { value: 'S', label: 'option_seller' },
191
+ ];
192
+ this.__onesourceProductOrderPriorityGetValue = () => {
193
+ var _a, _b;
194
+ const value = (_b = (_a = this.__config) === null || _a === void 0 ? void 0 : _a.product_order_priority.split(',')) !== null && _b !== void 0 ? _b : [];
195
+ return value.map((code) => ({ value: code }));
196
+ };
197
+ this.__onesourceProductOrderPrioritySetValue = (value) => {
198
+ this.__config = { product_order_priority: value.map(i => i.value).join(',') };
199
+ };
200
+ this.__onesourceAuditSettingsOptions = [
201
+ { value: 'capture_only', label: 'option_capture_only' },
202
+ { value: 'auth_and_capture', label: 'option_auth_and_capture' },
203
+ { value: 'never', label: 'option_never' },
204
+ ];
205
+ this.__webhookServiceOptions = [
206
+ { value: 'json', label: 'option_json' },
207
+ { value: 'legacy_xml', label: 'option_legacy_xml' },
208
+ ];
209
+ this.__webhookJsonEventsOptions = [
210
+ { value: 'transaction/created', label: 'option_transaction_created' },
211
+ { value: 'subscription/cancelled', label: 'option_subscription_cancelled' },
212
+ ];
213
+ }
214
+ static get v8n() {
215
+ const parse = memoize(JSON.parse);
216
+ const isURL = memoize((value) => {
217
+ try {
218
+ return Boolean(new URL(value));
219
+ }
220
+ catch (_a) {
221
+ return false;
222
+ }
223
+ });
224
+ return [
225
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
226
+ const url = parse(c).service_url;
227
+ const err = url ? (isURL(url) ? null : 'v8n_invalid') : 'v8n_required';
228
+ return p === 'avalara' && err ? `avalara-service-url:${err}` : true;
229
+ },
230
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
231
+ return p !== 'avalara' || !!parse(c).id || 'avalara-id:v8n_required';
232
+ },
233
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
234
+ return p !== 'avalara' || !!parse(c).key || 'avalara-key:v8n_required';
235
+ },
236
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
237
+ return p !== 'avalara' || !!parse(c).company_code || 'avalara-company-code:v8n_required';
238
+ },
239
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
240
+ return p !== 'taxjar' || !!parse(c).api_token || 'taxjar-api-token:v8n_required';
241
+ },
242
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
243
+ const url = parse(c).service_url;
244
+ const err = url ? (isURL(url) ? null : 'v8n_invalid') : 'v8n_required';
245
+ return p === 'onesource' && err ? `onesource-service-url:${err}` : true;
246
+ },
247
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
248
+ const prefix = 'onesource-external-company-id';
249
+ return p !== 'onesource' || !!parse(c).external_company_id || `${prefix}:v8n_required`;
250
+ },
251
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
252
+ const prefix = 'onesource-calling-system-number';
253
+ return p !== 'onesource' || !!parse(c).calling_system_number || `${prefix}:v8n_required`;
254
+ },
255
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
256
+ const prefix = 'onesource-from-city';
257
+ return p !== 'onesource' || !!parse(c).from_city || `${prefix}:v8n_required`;
258
+ },
259
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
260
+ const prefix = 'onesource-host-system';
261
+ return p !== 'onesource' || !!parse(c).host_system || `${prefix}:v8n_required`;
262
+ },
263
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
264
+ const { service: s, title: t } = parse(c);
265
+ return p !== 'webhook' || s !== 'json' || !!t || 'webhook-json-title:v8n_required';
266
+ },
267
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
268
+ const { service: s, encryption_key: e } = parse(c);
269
+ return p !== 'webhook' || s !== 'json' || !!e || 'webhook-json-encryption-key:v8n_required';
270
+ },
271
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
272
+ const { service: s, url: u } = parse(c);
273
+ const err = u ? (isURL(u) ? null : 'v8n_invalid') : 'v8n_required';
274
+ return p === 'webhook' && s === 'json' && err ? `webhook-json-url:${err}` : true;
275
+ },
276
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
277
+ const { service: s, title: t } = parse(c);
278
+ const err = 'webhook-legacy-xml-title:v8n_required';
279
+ return p !== 'webhook' || s !== 'legacy_xml' || !!t || err;
280
+ },
281
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
282
+ const { service: s, url: u } = parse(c);
283
+ const err = u ? (isURL(u) ? null : 'v8n_invalid') : 'v8n_required';
284
+ const prefix = 'webhook-legacy-xml-url';
285
+ return p === 'webhook' && s === 'legacy_xml' && err ? `${prefix}:${err}` : true;
286
+ },
287
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
288
+ const { service: s, site_id: v } = parse(c);
289
+ const err = 'webhook-webflow-site-id:v8n_required';
290
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
291
+ },
292
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
293
+ const { service: s, site_name: v } = parse(c);
294
+ const err = 'webhook-webflow-site-name:v8n_required';
295
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
296
+ },
297
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
298
+ const { service: s, collection_id: v } = parse(c);
299
+ const err = 'webhook-webflow-collection-id:v8n_required';
300
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
301
+ },
302
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
303
+ const { service: s, collection_name: v } = parse(c);
304
+ const err = 'webhook-webflow-collection-name:v8n_required';
305
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
306
+ },
307
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
308
+ const { service: s, sku_field_id: v } = parse(c);
309
+ const err = 'webhook-webflow-sku-field-id:v8n_required';
310
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
311
+ },
312
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
313
+ const { service: s, sku_field_name: v } = parse(c);
314
+ const err = 'webhook-webflow-sku-field-name:v8n_required';
315
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
316
+ },
317
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
318
+ const { service: s, inventory_field_id: v } = parse(c);
319
+ const err = 'webhook-webflow-inventory-field-id:v8n_required';
320
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
321
+ },
322
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
323
+ const { service: s, inventory_field_name: v } = parse(c);
324
+ const err = 'webhook-webflow-inventory-field-name:v8n_required';
325
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
326
+ },
327
+ ({ provider: p = 'avalara', config: c = '{}' }) => {
328
+ const { service: s, auth: v } = parse(c);
329
+ const err = 'webhook-webflow-auth:v8n_required';
330
+ return p !== 'webhook' || s !== 'webflow' || !!v || err;
331
+ },
332
+ ];
333
+ }
334
+ get readonlySelector() {
335
+ const match = [super.readonlySelector.toString()];
336
+ if (this.href)
337
+ match.push('provider', 'webhook-zapier-event', 'webhook-zapier-url');
338
+ return new BooleanSelector(match.join(' ').trim());
339
+ }
340
+ renderBody() {
341
+ const provider = this.__providerGetValue();
342
+ return html `
343
+ ${this.href
344
+ ? provider === 'webhook'
345
+ ? ''
346
+ : html `<foxy-internal-text-control infer="provider"></foxy-internal-text-control>`
347
+ : html `
348
+ <foxy-internal-radio-group-control
349
+ infer="provider"
350
+ theme="vertical"
351
+ .getValue=${this.__providerGetValue}
352
+ .setValue=${this.__providerSetValue}
353
+ .options=${this.__templateProviderOptions}
354
+ >
355
+ </foxy-internal-radio-group-control>
356
+ `}
357
+ ${provider === 'avalara'
358
+ ? this.__renderAvalaraConfig()
359
+ : provider === 'taxjar'
360
+ ? this.__renderTaxJarConfig()
361
+ : provider === 'onesource'
362
+ ? this.__renderOneSourceConfig()
363
+ : provider === 'webhook'
364
+ ? this.__renderWebhookConfig()
365
+ : ''}
366
+ ${super.renderBody()}
367
+ `;
368
+ }
369
+ async _fetch(...args) {
370
+ try {
371
+ return await super._fetch(...args);
372
+ }
373
+ catch (err) {
374
+ let message;
375
+ try {
376
+ message = (await err.json())._embedded['fx:errors'][0].message;
377
+ }
378
+ catch (_a) {
379
+ throw err;
380
+ }
381
+ if (message.includes('has already been configured')) {
382
+ throw ['error:already_configured'];
383
+ }
384
+ else {
385
+ throw err;
386
+ }
387
+ }
388
+ }
389
+ get __config() {
390
+ try {
391
+ return JSON.parse(this.form.config);
392
+ }
393
+ catch (_a) {
394
+ return null;
395
+ }
396
+ }
397
+ set __config(value) {
398
+ const config = this.__config;
399
+ const provider = this.form.provider;
400
+ const defaultConfig = (() => {
401
+ if (provider === 'taxjar')
402
+ return defaults.taxjar;
403
+ if (provider === 'onesource')
404
+ return defaults.onesource;
405
+ if (provider === 'webhook') {
406
+ if ((config === null || config === void 0 ? void 0 : config.service) === 'legacy_xml')
407
+ return defaults.webhookLegacyXml;
408
+ if ((config === null || config === void 0 ? void 0 : config.service) === 'webflow')
409
+ return defaults.webhookWebflow;
410
+ if ((config === null || config === void 0 ? void 0 : config.service) === 'zapier')
411
+ return defaults.webhookZapier;
412
+ return defaults.webhookJson;
413
+ }
414
+ return defaults.avalara;
415
+ })();
416
+ this.edit({ config: JSON.stringify({ ...defaultConfig, ...config, ...value }) });
417
+ }
418
+ __renderAvalaraConfig() {
419
+ var _a;
420
+ return html `
421
+ <foxy-internal-text-control
422
+ infer="avalara-service-url"
423
+ .getValue=${this.__createConfigGetterFor('service_url')}
424
+ .setValue=${this.__createConfigSetterFor('service_url')}
425
+ >
426
+ </foxy-internal-text-control>
427
+
428
+ <foxy-internal-text-control
429
+ infer="avalara-id"
430
+ .getValue=${this.__createConfigGetterFor('id')}
431
+ .setValue=${this.__createConfigSetterFor('id')}
432
+ >
433
+ </foxy-internal-text-control>
434
+
435
+ <foxy-internal-password-control
436
+ infer="avalara-key"
437
+ .getValue=${this.__createConfigGetterFor('key')}
438
+ .setValue=${this.__createConfigSetterFor('key')}
439
+ >
440
+ </foxy-internal-password-control>
441
+
442
+ <foxy-internal-text-control
443
+ infer="avalara-company-code"
444
+ .getValue=${this.__createConfigGetterFor('company_code')}
445
+ .setValue=${this.__createConfigSetterFor('company_code')}
446
+ >
447
+ </foxy-internal-text-control>
448
+
449
+ <foxy-internal-editable-list-control
450
+ infer="avalara-category-to-product-tax-code-mappings"
451
+ .getValue=${this.__codeMappingsGetValue}
452
+ .setValue=${this.__codeMappingsSetValue}
453
+ >
454
+ </foxy-internal-editable-list-control>
455
+
456
+ <foxy-internal-checkbox-group-control
457
+ infer="avalara-options"
458
+ .getValue=${this.__configOptionsGetValue}
459
+ .setValue=${this.__configOptionsSetValue}
460
+ .options=${this.__avalaraConfigOptions}
461
+ >
462
+ </foxy-internal-checkbox-group-control>
463
+
464
+ ${((_a = this.__config) === null || _a === void 0 ? void 0 : _a.use_address_validation) ? html `
465
+ <foxy-internal-checkbox-group-control
466
+ infer="avalara-address-validation-countries"
467
+ .getValue=${this.__createConfigGetterFor('address_validation_countries')}
468
+ .setValue=${this.__createConfigSetterFor('address_validation_countries')}
469
+ .options=${this.__avalaraAddressValidationCountriesOptions}
470
+ >
471
+ </foxy-internal-checkbox-group-control>
472
+ `
473
+ : ''}
474
+ `;
475
+ }
476
+ __renderTaxJarConfig() {
477
+ return html `
478
+ <foxy-internal-password-control
479
+ infer="taxjar-api-token"
480
+ .getValue=${this.__createConfigGetterFor('api_token')}
481
+ .setValue=${this.__createConfigSetterFor('api_token')}
482
+ >
483
+ </foxy-internal-password-control>
484
+
485
+ <foxy-internal-editable-list-control
486
+ infer="taxjar-category-to-product-tax-code-mappings"
487
+ .getValue=${this.__codeMappingsGetValue}
488
+ .setValue=${this.__codeMappingsSetValue}
489
+ >
490
+ </foxy-internal-editable-list-control>
491
+
492
+ <foxy-internal-checkbox-group-control
493
+ infer="taxjar-options"
494
+ .getValue=${this.__configOptionsGetValue}
495
+ .setValue=${this.__configOptionsSetValue}
496
+ .options=${this.__taxjarConfigOptions}
497
+ >
498
+ </foxy-internal-checkbox-group-control>
499
+ `;
500
+ }
501
+ __renderOneSourceConfig() {
502
+ return html `
503
+ <foxy-internal-text-control
504
+ infer="onesource-service-url"
505
+ .getValue=${this.__createConfigGetterFor('service_url')}
506
+ .setValue=${this.__createConfigSetterFor('service_url')}
507
+ >
508
+ </foxy-internal-text-control>
509
+
510
+ <foxy-internal-text-control
511
+ infer="onesource-external-company-id"
512
+ .getValue=${this.__createConfigGetterFor('external_company_id')}
513
+ .setValue=${this.__createConfigSetterFor('external_company_id')}
514
+ >
515
+ </foxy-internal-text-control>
516
+
517
+ <foxy-internal-text-control
518
+ infer="onesource-calling-system-number"
519
+ .getValue=${this.__createConfigGetterFor('calling_system_number')}
520
+ .setValue=${this.__createConfigSetterFor('calling_system_number')}
521
+ >
522
+ </foxy-internal-text-control>
523
+
524
+ <foxy-internal-text-control
525
+ infer="onesource-from-city"
526
+ .getValue=${this.__createConfigGetterFor('from_city')}
527
+ .setValue=${this.__createConfigSetterFor('from_city')}
528
+ >
529
+ </foxy-internal-text-control>
530
+
531
+ <foxy-internal-text-control
532
+ infer="onesource-host-system"
533
+ .getValue=${this.__createConfigGetterFor('host_system')}
534
+ .setValue=${this.__createConfigSetterFor('host_system')}
535
+ >
536
+ </foxy-internal-text-control>
537
+
538
+ <foxy-internal-radio-group-control
539
+ infer="onesource-company-role"
540
+ .getValue=${this.__createConfigGetterFor('company_role')}
541
+ .setValue=${this.__createConfigSetterFor('company_role')}
542
+ .options=${this.__onesourceCompanyRoleOptions}
543
+ >
544
+ </foxy-internal-radio-group-control>
545
+
546
+ <foxy-internal-text-control
547
+ infer="onesource-part-number-product-option"
548
+ .getValue=${this.__createConfigGetterFor('part_number_product_option')}
549
+ .setValue=${this.__createConfigSetterFor('part_number_product_option')}
550
+ >
551
+ </foxy-internal-text-control>
552
+
553
+ <foxy-internal-editable-list-control
554
+ infer="onesource-product-order-priority"
555
+ .getValue=${this.__onesourceProductOrderPriorityGetValue}
556
+ .setValue=${this.__onesourceProductOrderPrioritySetValue}
557
+ >
558
+ </foxy-internal-editable-list-control>
559
+
560
+ <foxy-internal-radio-group-control
561
+ infer="onesource-audit-settings"
562
+ .getValue=${this.__createConfigGetterFor('audit_settings')}
563
+ .setValue=${this.__createConfigSetterFor('audit_settings')}
564
+ .options=${this.__onesourceAuditSettingsOptions}
565
+ >
566
+ </foxy-internal-radio-group-control>
567
+ `;
568
+ }
569
+ __renderWebhookConfig() {
570
+ var _a, _b, _c, _d, _e, _f;
571
+ return html `
572
+ ${((_a = this.__config) === null || _a === void 0 ? void 0 : _a.service) === 'json' || ((_b = this.__config) === null || _b === void 0 ? void 0 : _b.service) === 'legacy_xml'
573
+ ? html `
574
+ <p
575
+ style="padding: calc(0.625em + (var(--lumo-border-radius) / 4) - 1px)"
576
+ class="rounded bg-error-10 text-error font-medium"
577
+ >
578
+ <foxy-i18n infer="webhook-warning" key="warning_text"></foxy-i18n>
579
+ <br />
580
+ <br />
581
+ <a
582
+ target="_blank"
583
+ class="text-body rounded hover-underline hover-cursor-pointer focus-outline-none focus-ring-2 focus-ring-error-50"
584
+ lang="en"
585
+ rel="noopener"
586
+ href="https://www.foxy.io/blog/new-feature-json-webhook/"
587
+ >
588
+ <foxy-i18n infer="webhook-warning" key="link_text"></foxy-i18n>
589
+ </a>
590
+ </p>
591
+ `
592
+ : ''}
593
+ ${((_c = this.__config) === null || _c === void 0 ? void 0 : _c.service) === 'json'
594
+ ? this.__renderWebhookJsonConfig()
595
+ : ((_d = this.__config) === null || _d === void 0 ? void 0 : _d.service) === 'legacy_xml'
596
+ ? this.__renderWebhookLegacyXmlConfig()
597
+ : ((_e = this.__config) === null || _e === void 0 ? void 0 : _e.service) === 'webflow'
598
+ ? this.__renderWebhookWebflowConfig()
599
+ : ((_f = this.__config) === null || _f === void 0 ? void 0 : _f.service) === 'zapier'
600
+ ? this.__renderWebhookZapierConfig()
601
+ : ''}
602
+ `;
603
+ }
604
+ __renderWebhookJsonConfig() {
605
+ return html `
606
+ <foxy-internal-text-control
607
+ infer="webhook-json-title"
608
+ .getValue=${this.__createConfigGetterFor('title')}
609
+ .setValue=${this.__createConfigSetterFor('title')}
610
+ >
611
+ </foxy-internal-text-control>
612
+
613
+ <foxy-internal-text-area-control
614
+ infer="webhook-json-url"
615
+ .getValue=${this.__createConfigGetterFor('url')}
616
+ .setValue=${this.__createConfigSetterFor('url')}
617
+ >
618
+ </foxy-internal-text-area-control>
619
+
620
+ <foxy-internal-radio-group-control
621
+ infer="webhook-service"
622
+ .getValue=${this.__createConfigGetterFor('service')}
623
+ .setValue=${this.__createConfigSetterFor('service')}
624
+ .options=${this.__webhookServiceOptions}
625
+ >
626
+ </foxy-internal-radio-group-control>
627
+
628
+ <foxy-internal-checkbox-group-control
629
+ infer="webhook-json-events"
630
+ .getValue=${this.__createConfigGetterFor('events')}
631
+ .setValue=${this.__createConfigSetterFor('events')}
632
+ .options=${this.__webhookJsonEventsOptions}
633
+ >
634
+ </foxy-internal-checkbox-group-control>
635
+
636
+ <foxy-internal-password-control
637
+ infer="webhook-json-encryption-key"
638
+ .getValue=${this.__createConfigGetterFor('encryption_key')}
639
+ .setValue=${this.__createConfigSetterFor('encryption_key')}
640
+ >
641
+ </foxy-internal-password-control>
642
+ `;
643
+ }
644
+ __renderWebhookLegacyXmlConfig() {
645
+ return html `
646
+ <foxy-internal-text-control
647
+ infer="webhook-legacy-xml-title"
648
+ .getValue=${this.__createConfigGetterFor('title')}
649
+ .setValue=${this.__createConfigSetterFor('title')}
650
+ >
651
+ </foxy-internal-text-control>
652
+
653
+ <foxy-internal-text-area-control
654
+ infer="webhook-legacy-xml-url"
655
+ .getValue=${this.__createConfigGetterFor('url')}
656
+ .setValue=${this.__createConfigSetterFor('url')}
657
+ >
658
+ </foxy-internal-text-area-control>
659
+
660
+ <foxy-internal-radio-group-control
661
+ infer="webhook-service"
662
+ .getValue=${this.__createConfigGetterFor('service')}
663
+ .setValue=${this.__createConfigSetterFor('service')}
664
+ .options=${this.__webhookServiceOptions}
665
+ >
666
+ </foxy-internal-radio-group-control>
667
+ `;
668
+ }
669
+ __renderWebhookWebflowConfig() {
670
+ return html `
671
+ <div class="grid grid-cols-2 gap-m">
672
+ <foxy-internal-text-control
673
+ infer="webhook-webflow-site-id"
674
+ .getValue=${this.__createConfigGetterFor('site_id')}
675
+ .setValue=${this.__createConfigSetterFor('site_id')}
676
+ >
677
+ </foxy-internal-text-control>
678
+
679
+ <foxy-internal-text-control
680
+ infer="webhook-webflow-site-name"
681
+ .getValue=${this.__createConfigGetterFor('site_name')}
682
+ .setValue=${this.__createConfigSetterFor('site_name')}
683
+ >
684
+ </foxy-internal-text-control>
685
+
686
+ <foxy-internal-text-control
687
+ infer="webhook-webflow-collection-id"
688
+ .getValue=${this.__createConfigGetterFor('collection_id')}
689
+ .setValue=${this.__createConfigSetterFor('collection_id')}
690
+ >
691
+ </foxy-internal-text-control>
692
+
693
+ <foxy-internal-text-control
694
+ infer="webhook-webflow-collection-name"
695
+ .getValue=${this.__createConfigGetterFor('collection_name')}
696
+ .setValue=${this.__createConfigSetterFor('collection_name')}
697
+ >
698
+ </foxy-internal-text-control>
699
+
700
+ <foxy-internal-text-control
701
+ infer="webhook-webflow-sku-field-id"
702
+ .getValue=${this.__createConfigGetterFor('sku_field_id')}
703
+ .setValue=${this.__createConfigSetterFor('sku_field_id')}
704
+ >
705
+ </foxy-internal-text-control>
706
+
707
+ <foxy-internal-text-control
708
+ infer="webhook-webflow-sku-field-name"
709
+ .getValue=${this.__createConfigGetterFor('sku_field_name')}
710
+ .setValue=${this.__createConfigSetterFor('sku_field_name')}
711
+ >
712
+ </foxy-internal-text-control>
713
+
714
+ <foxy-internal-text-control
715
+ infer="webhook-webflow-inventory-field-id"
716
+ .getValue=${this.__createConfigGetterFor('inventory_field_id')}
717
+ .setValue=${this.__createConfigSetterFor('inventory_field_id')}
718
+ >
719
+ </foxy-internal-text-control>
720
+
721
+ <foxy-internal-text-control
722
+ infer="webhook-webflow-inventory-field-name"
723
+ .getValue=${this.__createConfigGetterFor('inventory_field_name')}
724
+ .setValue=${this.__createConfigSetterFor('inventory_field_name')}
725
+ >
726
+ </foxy-internal-text-control>
727
+ </div>
728
+
729
+ <foxy-internal-password-control
730
+ infer="webhook-webflow-auth"
731
+ .getValue=${this.__createConfigGetterFor('auth')}
732
+ .setValue=${this.__createConfigSetterFor('auth')}
733
+ >
734
+ </foxy-internal-password-control>
735
+ `;
736
+ }
737
+ __renderWebhookZapierConfig() {
738
+ return html `
739
+ <foxy-internal-text-control
740
+ infer="webhook-zapier-event"
741
+ .getValue=${this.__createConfigGetterFor('event')}
742
+ .setValue=${this.__createConfigSetterFor('event')}
743
+ >
744
+ </foxy-internal-text-control>
745
+
746
+ <foxy-internal-text-area-control
747
+ infer="webhook-zapier-url"
748
+ .getValue=${this.__createConfigGetterFor('url')}
749
+ .setValue=${this.__createConfigSetterFor('url')}
750
+ >
751
+ </foxy-internal-text-area-control>
752
+
753
+ <p class="text-xs text-secondary leading-xs">
754
+ <foxy-i18n infer="webhook-zapier-warning" key="warning_text"></foxy-i18n>
755
+ </p>
756
+ `;
757
+ }
758
+ }
759
+ //# sourceMappingURL=NativeIntegrationForm.js.map