@justifi/webcomponents 4.19.3-rc-1 → 4.19.3-rc-2

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 (164) hide show
  1. package/dist/cjs/{Analytics-84cccd4a.js → Analytics-adc90fc6.js} +1 -1
  2. package/dist/cjs/justifi-bank-account-form.cjs.entry.js +2 -2
  3. package/dist/cjs/justifi-business-details.cjs.entry.js +2 -2
  4. package/dist/cjs/justifi-business-form.cjs.entry.js +2 -2
  5. package/dist/cjs/justifi-card-form.cjs.entry.js +2 -2
  6. package/dist/cjs/justifi-checkout-core.cjs.entry.js +2 -1
  7. package/dist/cjs/justifi-checkout.cjs.entry.js +2 -2
  8. package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +2 -2
  9. package/dist/cjs/justifi-new-payment-method_4.cjs.entry.js +4 -1
  10. package/dist/cjs/justifi-payment-details.cjs.entry.js +2 -2
  11. package/dist/cjs/justifi-payment-form.cjs.entry.js +2 -2
  12. package/dist/cjs/justifi-payment-method-form.cjs.entry.js +1 -1
  13. package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +2 -2
  14. package/dist/cjs/justifi-payments-list.cjs.entry.js +2 -2
  15. package/dist/cjs/justifi-payout-details.cjs.entry.js +2 -2
  16. package/dist/cjs/justifi-payouts-list.cjs.entry.js +2 -2
  17. package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +2 -2
  18. package/dist/cjs/{package-d2e04416.js → package-22d30c5d.js} +1 -1
  19. package/dist/collection/components/checkout/checkout-core.js +2 -1
  20. package/dist/collection/components/checkout/new-payment-method.js +4 -1
  21. package/dist/docs.json +1 -1
  22. package/dist/esm/{Analytics-a742f6d2.js → Analytics-a8eb7344.js} +1 -1
  23. package/dist/esm/justifi-bank-account-form.entry.js +2 -2
  24. package/dist/esm/justifi-business-details.entry.js +2 -2
  25. package/dist/esm/justifi-business-form.entry.js +2 -2
  26. package/dist/esm/justifi-card-form.entry.js +2 -2
  27. package/dist/esm/justifi-checkout-core.entry.js +2 -1
  28. package/dist/esm/justifi-checkout.entry.js +2 -2
  29. package/dist/esm/justifi-gross-payment-chart.entry.js +2 -2
  30. package/dist/esm/justifi-new-payment-method_4.entry.js +4 -1
  31. package/dist/esm/justifi-payment-details.entry.js +2 -2
  32. package/dist/esm/justifi-payment-form.entry.js +2 -2
  33. package/dist/esm/justifi-payment-method-form.entry.js +1 -1
  34. package/dist/esm/justifi-payment-provisioning.entry.js +2 -2
  35. package/dist/esm/justifi-payments-list.entry.js +2 -2
  36. package/dist/esm/justifi-payout-details.entry.js +2 -2
  37. package/dist/esm/justifi-payouts-list.entry.js +2 -2
  38. package/dist/esm/justifi-season-interruption-insurance.entry.js +2 -2
  39. package/dist/esm/{package-a70c900f.js → package-ccb774a9.js} +1 -1
  40. package/dist/module/checkout-core.js +2 -1
  41. package/dist/module/new-payment-method.js +4 -1
  42. package/dist/module/package.js +1 -1
  43. package/dist/types/components/checkout/new-payment-method.d.ts +1 -0
  44. package/dist/webcomponents/index.esm.js +1 -0
  45. package/dist/webcomponents/p-01a404ca.entry.js +44 -0
  46. package/dist/webcomponents/p-03d35880.entry.js +130 -0
  47. package/dist/webcomponents/p-06ff0429.entry.js +65 -0
  48. package/dist/webcomponents/p-08b0fb31.js +41 -1
  49. package/dist/webcomponents/p-0e1bc91e.js +28 -1
  50. package/dist/webcomponents/p-10875f3d.entry.js +97 -0
  51. package/dist/webcomponents/p-14c91ffd.js +20 -1
  52. package/dist/webcomponents/p-157acba8.entry.js +98 -0
  53. package/dist/webcomponents/p-15eafa87.js +77 -0
  54. package/dist/webcomponents/p-18fa0479.entry.js +131 -0
  55. package/dist/webcomponents/p-1a5120f4.entry.js +145 -0
  56. package/dist/webcomponents/p-1ad5995e.js +3599 -1
  57. package/dist/webcomponents/p-1ff8810b.js +29 -1
  58. package/dist/webcomponents/p-2338affa.js +213 -1
  59. package/dist/webcomponents/p-24dc023a.entry.js +791 -0
  60. package/dist/webcomponents/p-25d8cd65.entry.js +102 -0
  61. package/dist/webcomponents/p-27d87fe2.entry.js +133 -0
  62. package/dist/webcomponents/p-29c0b182.js +114 -1
  63. package/dist/webcomponents/p-2b6c9c4f.js +7 -1
  64. package/dist/webcomponents/p-2e8f4937.js +79 -0
  65. package/dist/webcomponents/p-2eab3c90.js +3052 -1
  66. package/dist/webcomponents/p-3395e896.entry.js +74 -0
  67. package/dist/webcomponents/p-3fd13ca3.js +52 -1
  68. package/dist/webcomponents/p-47d79529.js +18 -1
  69. package/dist/webcomponents/p-525db3e8.js +22 -1
  70. package/dist/webcomponents/p-53ecc8b9.entry.js +261 -0
  71. package/dist/webcomponents/p-5482d030.entry.js +21 -0
  72. package/dist/webcomponents/p-56f6ce4c.js +10 -1
  73. package/dist/webcomponents/p-576826b1.entry.js +43 -0
  74. package/dist/webcomponents/p-5968ff8a.js +178 -1
  75. package/dist/webcomponents/p-5f835b89.entry.js +606 -0
  76. package/dist/webcomponents/p-6078a370.js +244 -1
  77. package/dist/webcomponents/p-6124b1b3.entry.js +80 -0
  78. package/dist/webcomponents/p-70a2aa74.entry.js +76 -0
  79. package/dist/webcomponents/p-7582b554.entry.js +18 -0
  80. package/dist/webcomponents/p-75fd6367.entry.js +149 -0
  81. package/dist/webcomponents/p-79646550.entry.js +61 -0
  82. package/dist/webcomponents/p-7d85af5c.js +16 -1
  83. package/dist/webcomponents/p-800d31fe.entry.js +162 -0
  84. package/dist/webcomponents/p-8115b2f4.js +28 -1
  85. package/dist/webcomponents/p-83125497.js +4027 -1
  86. package/dist/webcomponents/p-85fc69e5.js +90 -1
  87. package/dist/webcomponents/p-89887332.js +301 -1
  88. package/dist/webcomponents/p-8df7bde8.js +27 -1
  89. package/dist/webcomponents/p-8eb774df.entry.js +54 -0
  90. package/dist/webcomponents/p-9c9c7dac.js +24 -1
  91. package/dist/webcomponents/p-9e17630d.entry.js +1684 -0
  92. package/dist/webcomponents/p-9f94bbb6.entry.js +118 -0
  93. package/dist/webcomponents/p-a4e8573e.entry.js +94 -0
  94. package/dist/webcomponents/p-a5a225d9.entry.js +125 -0
  95. package/dist/webcomponents/p-a5fb51dc.entry.js +131 -0
  96. package/dist/webcomponents/p-ab4816e1.entry.js +117 -0
  97. package/dist/webcomponents/p-ac086069.entry.js +58 -0
  98. package/dist/webcomponents/p-af244664.js +126 -1
  99. package/dist/webcomponents/p-b4b8b531.js +44 -1
  100. package/dist/webcomponents/p-b82c146f.entry.js +111 -0
  101. package/dist/webcomponents/p-ba4bae6f.js +12 -1
  102. package/dist/webcomponents/p-ba5fae28.js +90 -1
  103. package/dist/webcomponents/p-bd66f9d2.entry.js +101 -0
  104. package/dist/webcomponents/p-cc39384f.entry.js +99 -0
  105. package/dist/webcomponents/p-d17aee2b.entry.js +26 -0
  106. package/dist/webcomponents/p-d89bad72.js +39 -1
  107. package/dist/webcomponents/p-dad3e069.entry.js +298 -0
  108. package/dist/webcomponents/p-dce846bf.js +27 -1
  109. package/dist/webcomponents/p-df21aaad.js +120 -1
  110. package/dist/webcomponents/p-e1255160.js +3 -1
  111. package/dist/webcomponents/p-e1e7525b.entry.js +73 -0
  112. package/dist/webcomponents/p-e333620e.js +34 -1
  113. package/dist/webcomponents/p-e356f280.entry.js +29 -0
  114. package/dist/webcomponents/p-e3fab0e2.js +43 -1
  115. package/dist/webcomponents/p-e9a5cb95.entry.js +94 -0
  116. package/dist/webcomponents/p-ec854a3e.entry.js +11053 -0
  117. package/dist/webcomponents/p-edc37d1f.entry.js +75 -0
  118. package/dist/webcomponents/p-f02b75dc.entry.js +96 -0
  119. package/dist/webcomponents/p-fad19d75.js +1638 -2
  120. package/dist/webcomponents/webcomponents.css +362 -4
  121. package/dist/webcomponents/webcomponents.esm.js +20 -1
  122. package/package.json +1 -1
  123. package/dist/webcomponents/p-07109641.entry.js +0 -1
  124. package/dist/webcomponents/p-080fedb5.entry.js +0 -1
  125. package/dist/webcomponents/p-0e3e3544.entry.js +0 -1
  126. package/dist/webcomponents/p-0f7b9555.entry.js +0 -1
  127. package/dist/webcomponents/p-1295970b.entry.js +0 -1
  128. package/dist/webcomponents/p-15b9b267.entry.js +0 -1
  129. package/dist/webcomponents/p-17e4246f.entry.js +0 -1
  130. package/dist/webcomponents/p-1a43e355.entry.js +0 -19
  131. package/dist/webcomponents/p-232278e0.entry.js +0 -1
  132. package/dist/webcomponents/p-30a493cd.entry.js +0 -1
  133. package/dist/webcomponents/p-32211b2f.entry.js +0 -1
  134. package/dist/webcomponents/p-3352353a.entry.js +0 -1
  135. package/dist/webcomponents/p-462dc522.entry.js +0 -1
  136. package/dist/webcomponents/p-487b72a8.entry.js +0 -1
  137. package/dist/webcomponents/p-4abc17f0.entry.js +0 -1
  138. package/dist/webcomponents/p-52021fa1.entry.js +0 -1
  139. package/dist/webcomponents/p-53e64f15.entry.js +0 -1
  140. package/dist/webcomponents/p-62b32c4c.entry.js +0 -1
  141. package/dist/webcomponents/p-701e03a8.entry.js +0 -1
  142. package/dist/webcomponents/p-79cfbcfa.entry.js +0 -1
  143. package/dist/webcomponents/p-8e263202.js +0 -1
  144. package/dist/webcomponents/p-8e541a32.entry.js +0 -1
  145. package/dist/webcomponents/p-99899e7e.entry.js +0 -1
  146. package/dist/webcomponents/p-9993e959.entry.js +0 -1
  147. package/dist/webcomponents/p-b29f5084.entry.js +0 -1
  148. package/dist/webcomponents/p-bbed6107.entry.js +0 -1
  149. package/dist/webcomponents/p-be39c802.entry.js +0 -1
  150. package/dist/webcomponents/p-c9f8f7ec.entry.js +0 -1
  151. package/dist/webcomponents/p-cc97f21b.entry.js +0 -1
  152. package/dist/webcomponents/p-cd37a87e.entry.js +0 -1
  153. package/dist/webcomponents/p-d4c94340.entry.js +0 -1
  154. package/dist/webcomponents/p-d5c9e036.entry.js +0 -1
  155. package/dist/webcomponents/p-d6a998e4.js +0 -1
  156. package/dist/webcomponents/p-d8355f91.entry.js +0 -1
  157. package/dist/webcomponents/p-e2c88817.entry.js +0 -1
  158. package/dist/webcomponents/p-e31f0f3e.entry.js +0 -1
  159. package/dist/webcomponents/p-ea3598f3.entry.js +0 -1
  160. package/dist/webcomponents/p-eca70b1d.entry.js +0 -1
  161. package/dist/webcomponents/p-f0866375.entry.js +0 -1
  162. package/dist/webcomponents/p-f117d1d1.entry.js +0 -1
  163. package/dist/webcomponents/p-fb58feb5.entry.js +0 -1
  164. package/dist/webcomponents/p-fe33151d.entry.js +0 -1
@@ -1 +1,244 @@
1
- const l=[{label:"Choose state",value:""},{label:"Alabama",value:"AL"},{label:"Alaska",value:"AK"},{label:"American Samoa",value:"AS"},{label:"Arizona",value:"AZ"},{label:"Arkansas",value:"AR"},{label:"California",value:"CA"},{label:"Colorado",value:"CO"},{label:"Connecticut",value:"CT"},{label:"Delaware",value:"DE"},{label:"District Of Columbia",value:"DC"},{label:"Federated States Of Micronesia",value:"FM"},{label:"Florida",value:"FL"},{label:"Georgia",value:"GA"},{label:"Guam",value:"GU"},{label:"Hawaii",value:"HI"},{label:"Idaho",value:"ID"},{label:"Illinois",value:"IL"},{label:"Indiana",value:"IN"},{label:"Iowa",value:"IA"},{label:"Kansas",value:"KS"},{label:"Kentucky",value:"KY"},{label:"Louisiana",value:"LA"},{label:"Maine",value:"ME"},{label:"Marshall Islands",value:"MH"},{label:"Maryland",value:"MD"},{label:"Massachusetts",value:"MA"},{label:"Michigan",value:"MI"},{label:"Minnesota",value:"MN"},{label:"Mississippi",value:"MS"},{label:"Missouri",value:"MO"},{label:"Montana",value:"MT"},{label:"Nebraska",value:"NE"},{label:"Nevada",value:"NV"},{label:"New Hampshire",value:"NH"},{label:"New Jersey",value:"NJ"},{label:"New Mexico",value:"NM"},{label:"New York",value:"NY"},{label:"North Carolina",value:"NC"},{label:"North Dakota",value:"ND"},{label:"Northern Mariana Islands",value:"MP"},{label:"Ohio",value:"OH"},{label:"Oklahoma",value:"OK"},{label:"Oregon",value:"OR"},{label:"Palau",value:"PW"},{label:"Pennsylvania",value:"PA"},{label:"Puerto Rico",value:"PR"},{label:"Rhode Island",value:"RI"},{label:"South Carolina",value:"SC"},{label:"South Dakota",value:"SD"},{label:"Tennessee",value:"TN"},{label:"Texas",value:"TX"},{label:"Utah",value:"UT"},{label:"Vermont",value:"VT"},{label:"Virgin Islands",value:"VI"},{label:"Virginia",value:"VA"},{label:"Washington",value:"WA"},{label:"West Virginia",value:"WV"},{label:"Wisconsin",value:"WI"},{label:"Wyoming",value:"WY"}];export{l as S}
1
+ const StateOptions = [
2
+ {
3
+ label: 'Choose state',
4
+ value: '',
5
+ },
6
+ {
7
+ label: 'Alabama',
8
+ value: 'AL',
9
+ },
10
+ {
11
+ label: 'Alaska',
12
+ value: 'AK',
13
+ },
14
+ {
15
+ label: 'American Samoa',
16
+ value: 'AS',
17
+ },
18
+ {
19
+ label: 'Arizona',
20
+ value: 'AZ',
21
+ },
22
+ {
23
+ label: 'Arkansas',
24
+ value: 'AR',
25
+ },
26
+ {
27
+ label: 'California',
28
+ value: 'CA',
29
+ },
30
+ {
31
+ label: 'Colorado',
32
+ value: 'CO',
33
+ },
34
+ {
35
+ label: 'Connecticut',
36
+ value: 'CT',
37
+ },
38
+ {
39
+ label: 'Delaware',
40
+ value: 'DE',
41
+ },
42
+ {
43
+ label: 'District Of Columbia',
44
+ value: 'DC',
45
+ },
46
+ {
47
+ label: 'Federated States Of Micronesia',
48
+ value: 'FM',
49
+ },
50
+ {
51
+ label: 'Florida',
52
+ value: 'FL',
53
+ },
54
+ {
55
+ label: 'Georgia',
56
+ value: 'GA',
57
+ },
58
+ {
59
+ label: 'Guam',
60
+ value: 'GU',
61
+ },
62
+ {
63
+ label: 'Hawaii',
64
+ value: 'HI',
65
+ },
66
+ {
67
+ label: 'Idaho',
68
+ value: 'ID',
69
+ },
70
+ {
71
+ label: 'Illinois',
72
+ value: 'IL',
73
+ },
74
+ {
75
+ label: 'Indiana',
76
+ value: 'IN',
77
+ },
78
+ {
79
+ label: 'Iowa',
80
+ value: 'IA',
81
+ },
82
+ {
83
+ label: 'Kansas',
84
+ value: 'KS',
85
+ },
86
+ {
87
+ label: 'Kentucky',
88
+ value: 'KY',
89
+ },
90
+ {
91
+ label: 'Louisiana',
92
+ value: 'LA',
93
+ },
94
+ {
95
+ label: 'Maine',
96
+ value: 'ME',
97
+ },
98
+ {
99
+ label: 'Marshall Islands',
100
+ value: 'MH',
101
+ },
102
+ {
103
+ label: 'Maryland',
104
+ value: 'MD',
105
+ },
106
+ {
107
+ label: 'Massachusetts',
108
+ value: 'MA',
109
+ },
110
+ {
111
+ label: 'Michigan',
112
+ value: 'MI',
113
+ },
114
+ {
115
+ label: 'Minnesota',
116
+ value: 'MN',
117
+ },
118
+ {
119
+ label: 'Mississippi',
120
+ value: 'MS',
121
+ },
122
+ {
123
+ label: 'Missouri',
124
+ value: 'MO',
125
+ },
126
+ {
127
+ label: 'Montana',
128
+ value: 'MT',
129
+ },
130
+ {
131
+ label: 'Nebraska',
132
+ value: 'NE',
133
+ },
134
+ {
135
+ label: 'Nevada',
136
+ value: 'NV',
137
+ },
138
+ {
139
+ label: 'New Hampshire',
140
+ value: 'NH',
141
+ },
142
+ {
143
+ label: 'New Jersey',
144
+ value: 'NJ',
145
+ },
146
+ {
147
+ label: 'New Mexico',
148
+ value: 'NM',
149
+ },
150
+ {
151
+ label: 'New York',
152
+ value: 'NY',
153
+ },
154
+ {
155
+ label: 'North Carolina',
156
+ value: 'NC',
157
+ },
158
+ {
159
+ label: 'North Dakota',
160
+ value: 'ND',
161
+ },
162
+ {
163
+ label: 'Northern Mariana Islands',
164
+ value: 'MP',
165
+ },
166
+ {
167
+ label: 'Ohio',
168
+ value: 'OH',
169
+ },
170
+ {
171
+ label: 'Oklahoma',
172
+ value: 'OK',
173
+ },
174
+ {
175
+ label: 'Oregon',
176
+ value: 'OR',
177
+ },
178
+ {
179
+ label: 'Palau',
180
+ value: 'PW',
181
+ },
182
+ {
183
+ label: 'Pennsylvania',
184
+ value: 'PA',
185
+ },
186
+ {
187
+ label: 'Puerto Rico',
188
+ value: 'PR',
189
+ },
190
+ {
191
+ label: 'Rhode Island',
192
+ value: 'RI',
193
+ },
194
+ {
195
+ label: 'South Carolina',
196
+ value: 'SC',
197
+ },
198
+ {
199
+ label: 'South Dakota',
200
+ value: 'SD',
201
+ },
202
+ {
203
+ label: 'Tennessee',
204
+ value: 'TN',
205
+ },
206
+ {
207
+ label: 'Texas',
208
+ value: 'TX',
209
+ },
210
+ {
211
+ label: 'Utah',
212
+ value: 'UT',
213
+ },
214
+ {
215
+ label: 'Vermont',
216
+ value: 'VT',
217
+ },
218
+ {
219
+ label: 'Virgin Islands',
220
+ value: 'VI',
221
+ },
222
+ {
223
+ label: 'Virginia',
224
+ value: 'VA',
225
+ },
226
+ {
227
+ label: 'Washington',
228
+ value: 'WA',
229
+ },
230
+ {
231
+ label: 'West Virginia',
232
+ value: 'WV',
233
+ },
234
+ {
235
+ label: 'Wisconsin',
236
+ value: 'WI',
237
+ },
238
+ {
239
+ label: 'Wyoming',
240
+ value: 'WY',
241
+ },
242
+ ];
243
+
244
+ export { StateOptions as S };
@@ -0,0 +1,80 @@
1
+ import { r as registerInstance, c as createEvent, h, H as Host } from './p-fad19d75.js';
2
+ import { E as ErrorState } from './p-dce846bf.js';
3
+ import { B as BusinessService } from './p-0e1bc91e.js';
4
+ import { B as Business } from './p-af244664.js';
5
+ import { C as ComponentErrorSeverity, a as ComponentErrorCodes } from './p-14c91ffd.js';
6
+ import { g as getErrorMessage, a as getErrorCode } from './p-8115b2f4.js';
7
+ import { J as JustifiAnalytics } from './p-15eafa87.js';
8
+ import './p-29c0b182.js';
9
+ import './p-1ff8810b.js';
10
+ import './p-6078a370.js';
11
+ import './p-2e8f4937.js';
12
+
13
+ const makeGetBusiness = ({ id, authToken, service }) => async ({ onSuccess, onError }) => {
14
+ var _a;
15
+ try {
16
+ const response = await service.fetchBusiness(id, authToken);
17
+ if (!response.error) {
18
+ onSuccess({ business: new Business(response.data) });
19
+ }
20
+ else {
21
+ const responseError = getErrorMessage(response.error);
22
+ const code = getErrorCode((_a = response.error) === null || _a === void 0 ? void 0 : _a.code);
23
+ return onError({
24
+ error: responseError,
25
+ code,
26
+ severity: ComponentErrorSeverity.ERROR,
27
+ });
28
+ }
29
+ }
30
+ catch (error) {
31
+ const code = getErrorCode(error === null || error === void 0 ? void 0 : error.code);
32
+ return onError({
33
+ error: error.message || error,
34
+ code,
35
+ severity: ComponentErrorSeverity.ERROR,
36
+ });
37
+ }
38
+ };
39
+
40
+ const BusinessDetails = class {
41
+ constructor(hostRef) {
42
+ registerInstance(this, hostRef);
43
+ this.errorEvent = createEvent(this, "error-event", 7);
44
+ this.businessId = undefined;
45
+ this.authToken = undefined;
46
+ this.errorMessage = undefined;
47
+ this.getBusiness = undefined;
48
+ }
49
+ componentWillLoad() {
50
+ this.analytics = new JustifiAnalytics(this);
51
+ this.initializeGetBusiness();
52
+ }
53
+ disconnectedCallback() {
54
+ this.analytics.cleanup();
55
+ }
56
+ initializeGetBusiness() {
57
+ if (!this.businessId || !this.authToken) {
58
+ this.errorMessage = 'Invalid business id or auth token';
59
+ this.errorEvent.emit({
60
+ errorCode: ComponentErrorCodes.MISSING_PROPS,
61
+ message: this.errorMessage,
62
+ severity: ComponentErrorSeverity.ERROR,
63
+ });
64
+ return;
65
+ }
66
+ this.getBusiness = makeGetBusiness({
67
+ id: this.businessId,
68
+ authToken: this.authToken,
69
+ service: new BusinessService(),
70
+ });
71
+ }
72
+ render() {
73
+ if (this.errorMessage) {
74
+ return h(Host, null, ErrorState(this.errorMessage));
75
+ }
76
+ return (h(Host, null, h("business-details-core", { getBusiness: this.getBusiness })));
77
+ }
78
+ };
79
+
80
+ export { BusinessDetails as justifi_business_details };
@@ -0,0 +1,76 @@
1
+ import { r as registerInstance, h, c as createEvent } from './p-fad19d75.js';
2
+ import { c as create$3, F as FormController } from './p-2eab3c90.js';
3
+ import { i as identityNameValidation, l as lineOneValidation, a as lineTwoValidation, c as cityValidation, s as stateValidation, p as postalValidation } from './p-89887332.js';
4
+ import { S as StateOptions } from './p-6078a370.js';
5
+ import { n as numberOnlyHandler } from './p-8df7bde8.js';
6
+ import { S as StyledHost } from './p-ba4bae6f.js';
7
+ import './p-ba5fae28.js';
8
+ import './p-af244664.js';
9
+ import './p-1ff8810b.js';
10
+
11
+ const BillingFormSchema = create$3({
12
+ name: identityNameValidation.required('Enter full name'),
13
+ address_line1: lineOneValidation.required('Enter street address'),
14
+ address_line2: lineTwoValidation.nullable(),
15
+ address_city: cityValidation.required('Enter city'),
16
+ address_state: stateValidation.required('Select state'),
17
+ address_postal_code: postalValidation.required('Enter postal code'),
18
+ });
19
+
20
+ const billingFormCss = ":host{display:block}justifi-billing-form{margin-left:calc(var(--jfi-layout-padding) * -1);margin-right:calc(var(--jfi-layout-padding) * -1)}*::part(label){color:var(--jfi-form-label-color);font-family:var(--jfi-form-label-font-family);font-weight:var(--jfi-form-label-font-weight);font-size:var(--jfi-form-label-font-size);margin:var(--jfi-form-label-margin)}*::part(input){background-color:var(--jfi-form-control-background-color);border-color:var(--jfi-form-control-border-color);border-width:var(--jfi-form-control-border-width);border-bottom-width:var(--jfi-form-control-border-bottom-width);border-left-width:var(--jfi-form-control-border-left-width);border-right-width:var(--jfi-form-control-border-right-width);border-top-width:var(--jfi-form-control-border-top-width);border-radius:var(--jfi-form-control-border-radius);border-style:var(--jfi-form-control-border-style);box-shadow:var(--jfi-form-control-box-shadow);color:var(--jfi-form-control-color);font-size:var(--jfi-form-control-font-size);font-weight:var(--jfi-form-control-font-weight);line-height:var(--jfi-form-control-line-height);margin:var(--jfi-form-control-margin);padding:var(--jfi-form-control-padding)}*::part(input):focus{color:var(--jfi-form-control-color-focus);border-color:var(--jfi-form-control-border-color-focus);box-shadow:var(--jfi-form-control-box-shadow-focus)}*::part(input-invalid){border-color:var(--jfi-form-control-border-color-error);box-shadow:var(--jfi-form-control-box-shadow-error)}*::part(input-invalid):focus{border-color:var(--jfi-form-control-border-color-error);box-shadow:var(--jfi-form-control-box-shadow-error-focus)}";
21
+ const JustifiBillingFormStyle0 = billingFormCss;
22
+
23
+ const BillingForm = class {
24
+ constructor(hostRef) {
25
+ registerInstance(this, hostRef);
26
+ this.inputHandler = (name, value) => {
27
+ this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { [name]: value }));
28
+ };
29
+ this.legend = undefined;
30
+ this.formController = undefined;
31
+ this.billingInfo = undefined;
32
+ this.errors = {};
33
+ }
34
+ componentWillLoad() {
35
+ this.formController = new FormController(BillingFormSchema);
36
+ }
37
+ componentDidLoad() {
38
+ this.formController.values.subscribe(values => this.billingInfo = Object.assign({}, values));
39
+ this.formController.errors.subscribe(errors => {
40
+ this.errors = Object.assign({}, errors);
41
+ });
42
+ }
43
+ async getValues() {
44
+ return this.formController.values.getValue();
45
+ }
46
+ async fill(fields) {
47
+ this.formController.setInitialValues(fields);
48
+ }
49
+ async validate() {
50
+ let isValid = await this.formController.validate();
51
+ return { isValid: isValid };
52
+ }
53
+ render() {
54
+ const billingFormDefaultValue = this.formController.getInitialValues();
55
+ return (h(StyledHost, { key: 'b08094d3c44d35cdb3c21b4bc360dbbee19d7d15', exportparts: "label,input,input-invalid" }, h("form", { key: '392538a781ffa2ac299cbc4203bab5efd10e77cc' }, h("fieldset", { key: 'f4b5a5ec9a91e9f50a3847c5eb16635c4f9d569a' }, this.legend && h("legend", { key: 'eb75e22f9df33c13e3851ece784d237b8973e2c5' }, this.legend), h("div", { key: 'd7ffdc1cfeda5568ad003a4d3bbe94765de04605', class: "row gy-3" }, h("div", { key: 'c22f9e7b2f33b5c298bb5f0a5c7bcaa709c231a0', class: "col-12" }, h("form-control-text", { key: 'd6eb4d2f4d1a2a709e0f29bf18b5d9700bd91a13', name: 'name', label: 'Full Name', defaultValue: billingFormDefaultValue.name, errorText: this.errors.name, inputHandler: this.inputHandler })), h("div", { key: '8494ee3c14f8923d18d8708077e030c2f141a251', class: "col-12" }, h("form-control-text", { key: '63266eb0e2b2b006a3c914a68703ee1cdf848f83', name: 'address_line1', label: 'Street Address', defaultValue: billingFormDefaultValue.address_line1, errorText: this.errors.address_line1, inputHandler: this.inputHandler })), h("div", { key: '0a19fcf5c172d2539f23e147f39461d84dfd9d37', class: "col-12" }, h("form-control-text", { key: '0e5fae5d65d5ea195de0227d1e4f79cee7c7a0fb', name: 'address_line2', label: "Apartment, Suite, etc. (optional)", defaultValue: billingFormDefaultValue.address_line2, errorText: this.errors.address_line2, inputHandler: this.inputHandler })), h("div", { key: '13104554e8247cb0534c3dc9e6a16b2f44397795', class: "col-12" }, h("form-control-text", { key: '430e59713ec66ff7a6f735ca24640c27b05cbeee', name: 'address_city', label: "City", defaultValue: billingFormDefaultValue.address_city, errorText: this.errors.address_city, inputHandler: this.inputHandler })), h("div", { key: '5b81499717f67d5f499f4ebfc585056ef5bd3d56', class: "col-12" }, h("form-control-select", { key: '726c724eda5f25a92bad7e549ff7845ece7b41e1', name: 'address_state', label: 'State', options: StateOptions, defaultValue: billingFormDefaultValue.address_state, errorText: this.errors.address_state, inputHandler: this.inputHandler })), h("div", { key: '5d5a6e0949c5ad93da5bc1837dadf88c2128212d', class: "col-12" }, h("form-control-text", { key: 'ebb4e77126d86011d9a1ed5d118461198b399092', name: 'address_postal_code', label: "ZIP", defaultValue: billingFormDefaultValue.address_postal_code, errorText: this.errors.address_postal_code, inputHandler: this.inputHandler, maxLength: 5, keyDownHandler: numberOnlyHandler })))))));
56
+ }
57
+ };
58
+ BillingForm.style = JustifiBillingFormStyle0;
59
+
60
+ const SaveNewPaymentMethod = class {
61
+ constructor(hostRef) {
62
+ registerInstance(this, hostRef);
63
+ this.checkboxChanged = createEvent(this, "checkboxChanged", 7);
64
+ this.isChecked = false;
65
+ }
66
+ handleCheckboxChange(event) {
67
+ const target = event.target;
68
+ this.isChecked = target.checked;
69
+ this.checkboxChanged.emit(this.isChecked);
70
+ }
71
+ render() {
72
+ return (h("div", { key: 'f22a132a518a98786c8486e08c9a65050f3c5ea0', class: "mt-4 form-check" }, h("input", { key: '6f1392f9dd29a9761f5942b0a40e05a899858ada', type: "checkbox", checked: this.isChecked, onChange: (event) => this.handleCheckboxChange(event), class: "form-check-input" }), h("label", { key: 'e6e5908ba70ece8ea19370a04104d88d17237fc7', class: "form-check-label" }, "Save new payment method")));
73
+ }
74
+ };
75
+
76
+ export { BillingForm as justifi_billing_form, SaveNewPaymentMethod as justifi_save_new_payment_method };
@@ -0,0 +1,18 @@
1
+ import { r as registerInstance, h } from './p-fad19d75.js';
2
+ import { E as ErrorState } from './p-dce846bf.js';
3
+ import { S as StyledHost } from './p-ba4bae6f.js';
4
+
5
+ const Details = class {
6
+ constructor(hostRef) {
7
+ registerInstance(this, hostRef);
8
+ this.errorMessage = undefined;
9
+ }
10
+ render() {
11
+ return (h(StyledHost, { key: '00b10fc4e459688ae06147ef1535f03609ec35e4', exportParts: 'detail-empty-state, detail-metadata-title, detail-metadata, detail-section, detail-section-title, \n detail-section-item-title, detail-section-item-data, detail-head, detail-title, detail-head-info' }, this.errorMessage ?
12
+ ErrorState(this.errorMessage)
13
+ :
14
+ h("main", { class: "p-2" }, h("slot", { name: "head-info" }), h("slot", { name: 'detail-sections' }))));
15
+ }
16
+ };
17
+
18
+ export { Details as justifi_details };
@@ -0,0 +1,149 @@
1
+ import { r as registerInstance, c as createEvent, h } from './p-fad19d75.js';
2
+ import { f as formatCurrency } from './p-83125497.js';
3
+ import { C as ComponentErrorSeverity } from './p-14c91ffd.js';
4
+ import { i as insuranceValuesOn, v as validateInsuranceValues, a as insuranceValues } from './p-2338affa.js';
5
+ import { B as Button } from './p-9c9c7dac.js';
6
+ import { S as StyledHost } from './p-ba4bae6f.js';
7
+ import { S as Skeleton } from './p-08b0fb31.js';
8
+
9
+ class Checkout {
10
+ constructor(data) {
11
+ Object.assign(this, data);
12
+ }
13
+ }
14
+
15
+ const checkoutCoreCss = ":host{display:block}justifi-payment-method-form{display:block;margin-left:calc(var(--jfi-layout-padding) * -1);margin-right:calc(var(--jfi-layout-padding) * -1)}.jfi-checkout-core{color:var(--jfi-body-color)}*::part(label){color:var(--jfi-form-label-color);font-family:var(--jfi-form-label-font-family);font-weight:var(--jfi-form-label-font-weight);font-size:var(--jfi-form-label-font-size);margin:var(--jfi-form-label-margin)}*::part(input){font-family:var(--jfi-layout-font-family);background-color:var(--jfi-form-control-background-color);border-color:var(--jfi-form-control-border-color);border-width:var(--jfi-form-control-border-width);border-bottom-width:var(--jfi-form-control-border-bottom-width);border-left-width:var(--jfi-form-control-border-left-width);border-right-width:var(--jfi-form-control-border-right-width);border-top-width:var(--jfi-form-control-border-top-width);border-radius:var(--jfi-form-control-border-radius);border-style:var(--jfi-form-control-border-style);box-shadow:var(--jfi-form-control-box-shadow);color:var(--jfi-form-control-color);font-size:var(--jfi-form-control-font-size);font-weight:var(--jfi-form-control-font-weight);line-height:var(--jfi-form-control-line-height);margin:var(--jfi-form-control-margin);padding:var(--jfi-form-control-padding)}*::part(input):focus{color:var(--jfi-form-control-color-focus);border-color:var(--jfi-form-control-border-color-focus);box-shadow:var(--jfi-form-control-box-shadow-focus)}*::part(input-invalid){border-color:var(--jfi-form-control-border-color-error);box-shadow:var(--jfi-form-control-box-shadow-error)}*::part(input-invalid):focus{border-color:var(--jfi-form-control-border-color-error);box-shadow:var(--jfi-form-control-box-shadow-error-focus)}*::part(invalid-feedback){color:var(--jfi-error-message-color);font-size:var(--jfi-error-message-font-size);margin:var(--jfi-error-message-margin);line-height:normal}.jfi-submit-button{font-family:var(--jfi-layout-font-family);color:var(--jfi-submit-button-color);background-color:var(--jfi-submit-button-background-color);border-color:var(--jfi-submit-button-border-color);padding:var(--jfi-submit-button-padding);font-size:var(--jfi-submit-button-font-size);border-radius:var(--jfi-submit-button-border-radius);width:var(--jfi-submit-button-width);box-shadow:var(--jfi-submit-button-box-shadow);line-height:var(--jfi-submit-button-line-height);text-transform:var(--jfi-submit-button-text-transform)}.jfi-submit-button:hover{color:var(--jfi-submit-button-color-hover);background-color:var(--jfi-submit-button-background-color-hover);border-color:var(--jfi-submit-button-border-color-hover)}.jfi-submit-button:focus{color:var(--jfi-submit-button-color-focus);background-color:var(--jfi-submit-button-background-color-focus);border-color:var(--jfi-submit-button-border-color-focus)}.btn.jfi-submit-button:active{color:var(--jfi-submit-button-color-active);background-color:var(--jfi-submit-button-background-color-active);border-color:var(--jfi-submit-button-border-color-active)}.btn.jfi-submit-button-loading{min-width:75px;color:var(--jfi-submit-button-color-loading);background-color:var(--jfi-submit-button-background-color-loading);border-color:var(--jfi-submit-button-border-color-loading)}.btn.jfi-submit-button-loading .spinner-border{border-top-color:var(--jfi-submit-button-color-loading);border-bottom-color:var(--jfi-submit-button-color-loading);border-left-color:var(--jfi-submit-button-color-loading)}";
16
+ const JustifiCheckoutCoreStyle0 = checkoutCoreCss;
17
+
18
+ const headerCss = ".jfi-header{color:var(--jfi-header-color);border-bottom:var(--jfi-header-border)}";
19
+ const JustifiCheckoutCoreStyle1 = headerCss;
20
+
21
+ const CheckoutCore = class {
22
+ constructor(hostRef) {
23
+ registerInstance(this, hostRef);
24
+ this.submitted = createEvent(this, "submitted", 7);
25
+ this.errorEvent = createEvent(this, "error-event", 7);
26
+ this.loaded = createEvent(this, "loaded", 7);
27
+ this.completeCheckout = async (payment) => {
28
+ this.complete({
29
+ payment,
30
+ onSuccess: this.onSubmitted,
31
+ onError: this.onError,
32
+ });
33
+ };
34
+ this.onSubmitted = (data) => {
35
+ this.submitted.emit(data);
36
+ this.renderState = 'success';
37
+ };
38
+ this.onError = ({ error, code, severity }) => {
39
+ this.serverError = error;
40
+ this.errorEvent.emit({
41
+ errorCode: code,
42
+ message: error,
43
+ severity,
44
+ });
45
+ this.renderState = 'error';
46
+ };
47
+ this.iframeOrigin = "";
48
+ this.authToken = undefined;
49
+ this.getCheckout = undefined;
50
+ this.complete = undefined;
51
+ this.checkoutId = undefined;
52
+ this.disableCreditCard = undefined;
53
+ this.disableBankAccount = undefined;
54
+ this.disableBnpl = undefined;
55
+ this.disablePaymentMethodGroup = undefined;
56
+ this.hasLoadedFonts = false;
57
+ this.checkout = undefined;
58
+ this.serverError = undefined;
59
+ this.renderState = 'loading';
60
+ this.creatingNewPaymentMethod = false;
61
+ this.insuranceToggled = false;
62
+ }
63
+ async fillBillingForm(fields) {
64
+ this.paymentMethodOptionsRef.fillBillingForm(fields);
65
+ }
66
+ componentWillLoad() {
67
+ console.log('CheckoutCore: componentWillLoad iframeOrigin', this, this.iframeOrigin);
68
+ if (this.getCheckout) {
69
+ this.fetchData();
70
+ // Refresh the checkout data when insurance is added or removed
71
+ insuranceValuesOn('set', (key) => {
72
+ const value = insuranceValues[key];
73
+ if (value !== undefined) {
74
+ this.insuranceToggled = value;
75
+ this.fetchData();
76
+ }
77
+ });
78
+ }
79
+ }
80
+ fetchData() {
81
+ this.renderState = 'loading';
82
+ this.getCheckout({
83
+ onSuccess: ({ checkout }) => {
84
+ this.checkout = new Checkout(checkout);
85
+ const { status } = this.checkout;
86
+ this.loaded.emit({ checkout_status: status });
87
+ this.renderState = 'success';
88
+ },
89
+ onError: ({ error, code, severity }) => {
90
+ this.serverError = error;
91
+ this.renderState = 'error';
92
+ this.errorEvent.emit({
93
+ errorCode: code,
94
+ message: error,
95
+ severity,
96
+ });
97
+ }
98
+ });
99
+ }
100
+ ;
101
+ async submit(event) {
102
+ var _a;
103
+ event.preventDefault();
104
+ this.renderState = 'loading';
105
+ const insuranceValidation = validateInsuranceValues();
106
+ const payload = await this.paymentMethodOptionsRef.resolvePaymentMethod(insuranceValidation);
107
+ if (payload.validationError) {
108
+ this.renderState = 'error';
109
+ }
110
+ else if (payload.error) {
111
+ this.renderState = 'error';
112
+ this.serverError = payload.error.message;
113
+ this.onError({
114
+ code: payload.error.code,
115
+ error: payload.error.message,
116
+ severity: ComponentErrorSeverity.ERROR,
117
+ });
118
+ }
119
+ else if (payload.token) {
120
+ this.completeCheckout({ payment_mode: 'ecom', payment_token: payload.token });
121
+ }
122
+ else if (((_a = payload.bnpl) === null || _a === void 0 ? void 0 : _a.status) === 'success') {
123
+ this.completeCheckout({ payment_mode: 'bnpl' });
124
+ }
125
+ else {
126
+ this.renderState = 'error';
127
+ }
128
+ }
129
+ get isLoading() {
130
+ return this.renderState === 'loading';
131
+ }
132
+ get isError() {
133
+ return this.renderState === 'error';
134
+ }
135
+ get paymentType() {
136
+ var _a, _b, _c, _d, _e;
137
+ return (h("section", null, h("div", { class: !this.isLoading && 'visually-hidden' }, h(Skeleton, { variant: "rounded", height: "300px" })), h("div", { class: this.isLoading && 'visually-hidden' }, h("justifi-payment-method-options", { ref: (el) => (this.paymentMethodOptionsRef = el), "show-card": !this.disableCreditCard, "show-ach": !this.disableBankAccount, "show-bnpl": !this.disableBnpl, paymentMethodGroupId: (_a = this.checkout) === null || _a === void 0 ? void 0 : _a.payment_method_group_id, "show-saved-payment-methods": !this.disablePaymentMethodGroup, bnpl: (_b = this.checkout) === null || _b === void 0 ? void 0 : _b.bnpl, authToken: this.authToken, "account-id": (_c = this.checkout) === null || _c === void 0 ? void 0 : _c.account_id, savedPaymentMethods: ((_d = this.checkout) === null || _d === void 0 ? void 0 : _d.payment_methods) || [], paymentAmount: (_e = this.checkout) === null || _e === void 0 ? void 0 : _e.payment_amount, insuranceToggled: this.insuranceToggled }))));
138
+ }
139
+ get summary() {
140
+ var _a, _b;
141
+ return (h("section", null, h("div", { class: !this.isLoading && 'visually-hidden' }, h(Skeleton, { height: "24px" })), h("div", { class: this.isLoading && 'visually-hidden' }, h("div", { class: "jfi-payment-description" }, (_a = this.checkout) === null || _a === void 0 ? void 0 : _a.payment_description), h("div", { class: "jfi-payment-total" }, h("span", { class: "jfi-payment-total-label" }, "Total"), "\u00A0", h("span", { class: "jfi-payment-total-amount" }, formatCurrency(+((_b = this.checkout) === null || _b === void 0 ? void 0 : _b.total_amount)))))));
142
+ }
143
+ render() {
144
+ return (h(StyledHost, { key: '991ae6970e426028ace0d1e8327119bc197639b0' }, h("div", { key: '1e57ee21429b494240e644235a2d5815ced99d43', class: "row gy-3 jfi-checkout-core" }, h("div", { key: '70023ce10dea6ff8d5bd8e30c7d474f774682c65', class: "col-12" }, h("h2", { key: '8b09b03c1998e4d60e174fefb3d196e48d50b84a', class: "fs-5 fw-bold pb-3 jfi-header" }, "Summary"), this.summary), h("div", { key: 'e3bbdaaaf010451a31fe9c60bdf81e89bdd142f2', class: "col-12" }, h("slot", { key: '442a01184960f42b5e1f6694798633d3e7219bf5', name: "insurance" })), h("div", { key: '716e26e3dc675e9d72a3a992b1cb212ce48ffb1a', class: "col-12 mt-4" }, h("h2", { key: '762cfc8549b20d16583d0fd8748bde8035042c00', class: "fs-5 fw-bold pb-3 jfi-header" }, "Payment"), h("h3", { key: 'f07d716a87f3e2bd44471f7e93f7af5f5d20440e', class: "fs-6 fw-bold lh-lg" }, "Select payment type"), h("div", { key: '1156291dd748b90d64a08916ffb98c3123132175', class: "d-flex flex-column" }, this.paymentType)), h("div", { key: 'a5bd142a1c72c5abb29338a2cf24c180119d4ea7', class: "col-12" }, h("div", { key: '5a94ed9d54fd3dd24cfe3e34c23ee3c4995eca6d', class: "d-flex justify-content-end" }, h(Button, { key: '7fce3940d8fe562aa7c23e38201b5d2924157288', type: "submit", variant: "primary", onClick: (e) => this.submit(e), disabled: this.isLoading, isLoading: this.isLoading, style: { width: '100%' } }, "Pay"))))));
145
+ }
146
+ };
147
+ CheckoutCore.style = JustifiCheckoutCoreStyle0 + JustifiCheckoutCoreStyle1;
148
+
149
+ export { CheckoutCore as justifi_checkout_core };
@@ -0,0 +1,61 @@
1
+ import { r as registerInstance, c as createEvent, h, H as Host } from './p-fad19d75.js';
2
+ import { I as IMask } from './p-1ad5995e.js';
3
+ import { C as CURRENCY_MASK } from './p-525db3e8.js';
4
+
5
+ const MonetaryInput = class {
6
+ constructor(hostRef) {
7
+ registerInstance(this, hostRef);
8
+ this.formControlInput = createEvent(this, "formControlInput", 7);
9
+ this.formControlBlur = createEvent(this, "formControlBlur", 7);
10
+ this.imask = null;
11
+ this.initializeIMask = () => {
12
+ if (!this.textInput)
13
+ return;
14
+ this.imask = IMask(this.textInput, this.maskOptions);
15
+ this.imask.on('accept', () => {
16
+ const rawValue = this.imask.unmaskedValue;
17
+ this.inputHandler(this.name, rawValue);
18
+ this.formControlInput.emit({ name: this.name, value: rawValue });
19
+ });
20
+ this.textInput.addEventListener('blur', () => this.formControlBlur.emit());
21
+ };
22
+ this.handleFormControlInput = (event) => {
23
+ const target = event.target;
24
+ const name = target.getAttribute('name');
25
+ const rawValue = this.imask.unmaskedValue;
26
+ this.formControlInput.emit({ name: name, value: rawValue });
27
+ };
28
+ this.updateInput = (newValue) => {
29
+ if (this.imask) {
30
+ this.imask.value = String(newValue);
31
+ }
32
+ };
33
+ this.label = undefined;
34
+ this.name = undefined;
35
+ this.helpText = undefined;
36
+ this.errorText = undefined;
37
+ this.defaultValue = undefined;
38
+ this.inputHandler = undefined;
39
+ this.maskOptions = CURRENCY_MASK.DECIMAL;
40
+ this.disabled = undefined;
41
+ }
42
+ handleDefaultValueChange(newValue) {
43
+ this.updateInput(newValue);
44
+ }
45
+ componentDidLoad() {
46
+ this.initializeIMask();
47
+ this.updateInput(this.defaultValue);
48
+ }
49
+ disconnectedCallback() {
50
+ var _a;
51
+ (_a = this.imask) === null || _a === void 0 ? void 0 : _a.destroy();
52
+ }
53
+ render() {
54
+ return (h(Host, { key: '8797b3aa5c6a30f472d51e2b9437b6158b0566fc', exportparts: "label,input,input-group-input,input-group-text,input-invalid" }, h("div", { key: '0d3e068cf104aec3f6250f5cd6c00a9342928fe8', class: "form-group d-flex flex-column" }, h("label", { key: '0e86db7c0d981bdae74c51dd75bf5579d07b4793', part: "label", class: "form-label", htmlFor: this.name }, this.label), h("div", { key: '8fc773de3995bb37e6fa00b34d8d9e2deaef4bbd', class: "input-group" }, h("span", { key: '83860eac764be9eeea31302d60525fb56af9dc1d', class: "input-group-text", part: "input-group-text" }, "$"), h("input", { key: 'b8c655c0b8eeb6ec328eeaed651773c293aa3100', ref: el => (this.textInput = el), id: this.name, name: this.name, onBlur: this.formControlBlur.emit, onInput: this.handleFormControlInput, part: `input input-group-input ${this.errorText && 'input-invalid'}`, class: this.errorText ? 'form-control monetary is-invalid' : 'form-control monetary', type: "text", disabled: this.disabled })), h("form-control-help-text", { key: 'b3f142b9c67a792a96b597bdaf91fd3abe1b7ce3', helpText: this.helpText, name: this.name }), h("form-control-error-text", { key: 'daefe97a15bde309c397a506de6cda9a0376323b', errorText: this.errorText, name: this.name }))));
55
+ }
56
+ static get watchers() { return {
57
+ "defaultValue": ["handleDefaultValueChange"]
58
+ }; }
59
+ };
60
+
61
+ export { MonetaryInput as form_control_monetary };
@@ -1 +1,16 @@
1
- import{d as b}from"./p-1ff8810b.js";const t=(b,t)=>{b.setValues(Object.assign(Object.assign({},b.values.getValue()),t))},e=(b,e)=>{t(b,{address:Object.assign(Object.assign({},b.values.getValue().address),e)})},o=(e,o)=>{const s=b(e.detail);t(o,Object.assign(Object.assign({},o.values.getValue()),{dob_day:s.dob_day,dob_month:s.dob_month,dob_year:s.dob_year}))};export{e as a,o as b,t as u}
1
+ import { d as deconstructDate } from './p-1ff8810b.js';
2
+
3
+ const updateFormValues = (formController, newValues) => {
4
+ formController.setValues(Object.assign(Object.assign({}, formController.values.getValue()), newValues));
5
+ };
6
+ const updateAddressFormValues = (formController, newValues) => {
7
+ updateFormValues(formController, {
8
+ address: Object.assign(Object.assign({}, formController.values.getValue().address), newValues),
9
+ });
10
+ };
11
+ const updateDateOfBirthFormValues = (event, formController) => {
12
+ const dob_values = deconstructDate(event.detail);
13
+ updateFormValues(formController, Object.assign(Object.assign({}, formController.values.getValue()), { dob_day: dob_values.dob_day, dob_month: dob_values.dob_month, dob_year: dob_values.dob_year }));
14
+ };
15
+
16
+ export { updateAddressFormValues as a, updateDateOfBirthFormValues as b, updateFormValues as u };