@primer-io/primer-js 0.1.5 → 0.1.6
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.
- package/dist/custom-elements.json +1789 -335
- package/dist/jsx/index.d.ts +3 -1
- package/dist/primer-loader.d.ts +14 -0
- package/dist/primer-loader.js +75 -66
- package/dist/primer-react-wrappers.js +2370 -0
- package/dist/vscode.html-custom-data.json +4 -1
- package/dist/web-types.json +14 -6
- package/package.json +23 -1
|
@@ -2,6 +2,21 @@
|
|
|
2
2
|
"schemaVersion": "1.0.0",
|
|
3
3
|
"readme": "",
|
|
4
4
|
"modules": [
|
|
5
|
+
{
|
|
6
|
+
"kind": "javascript-module",
|
|
7
|
+
"path": "react-wrappers.ts",
|
|
8
|
+
"declarations": [],
|
|
9
|
+
"exports": [
|
|
10
|
+
{
|
|
11
|
+
"kind": "js",
|
|
12
|
+
"name": "*",
|
|
13
|
+
"declaration": {
|
|
14
|
+
"name": "*",
|
|
15
|
+
"package": "./src/react-components"
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
]
|
|
19
|
+
},
|
|
5
20
|
{
|
|
6
21
|
"kind": "javascript-module",
|
|
7
22
|
"path": "cdn/primer-components.js",
|
|
@@ -16,13 +31,13 @@
|
|
|
16
31
|
},
|
|
17
32
|
{
|
|
18
33
|
"kind": "variable",
|
|
19
|
-
"name": "
|
|
34
|
+
"name": "Hr",
|
|
20
35
|
"default": "class{constructor(e){this._methods=e}get(e){return this._methods.get(e)}toArray(){return Array.from(this._methods.values())}size(){return this._methods.size}}"
|
|
21
36
|
},
|
|
22
37
|
{
|
|
23
38
|
"kind": "variable",
|
|
24
39
|
"name": "le",
|
|
25
|
-
"default": "class extends v{constructor(){super();this.customStyles=\"\";this.clientToken=\"\";this.options={};this._jsInitialized=!1;this.previousLoadingState=!0;this.hasAssignedContent=!1;this._loadingTimeoutId=null;this.locale=\"en-GB\";this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0,this.requestUpdate()};this.sdkContextController=new
|
|
40
|
+
"default": "class extends v{constructor(){super();this.customStyles=\"\";this.clientToken=\"\";this.options={};this._jsInitialized=!1;this.previousLoadingState=!0;this.hasAssignedContent=!1;this._loadingTimeoutId=null;this.locale=\"en-GB\";this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0,this.requestUpdate()};this.sdkContextController=new Ar(this),this.sdkStateController=new Cr(this),this.primerEventsController=new gt(this),this.styleProcessingController=new _r(this),this.vaultManagerController=new Yt(this),this.cardNetworkController=new fr(this),this.achPaymentEventsController=new zr(this),new Yr(this)}set jsInitialized(t){this.requestUpdate(),this._jsInitialized=t}get jsInitialized(){return this._jsInitialized}attributeChangedCallback(t,r,o){t===Fr.CUSTOM_STYLES?this.styleProcessingController.processCustomStyles(o):super.attributeChangedCallback(t,r,o)}disconnectedCallback(){this._loadingTimeoutId&&(window.clearTimeout(this._loadingTimeoutId),this._loadingTimeoutId=null),this.sdkStateController?.currentState.isLoading&&this.sdkStateController.forceCompleteLoading(),super.disconnectedCallback()}willUpdate(t){t.has(\"options\")&&(this.options?.locale&&(Oi(this.options?.locale)?this.locale=Di(this.options?.locale):R.warn(\"\\u{1F30E}\\u2757 Unsupported locale provided:\",this.options?.locale,\"- Falling back to default locale `en-GB`\")),Ri(this.locale||\"en-GB\"))}updated(){let t=getComputedStyle(this);this.sdkContextController.setComputedStyles(t),this.checkLoadingStateChange()}checkLoadingStateChange(){let t=this.sdkStateController?.currentState.isLoading||!1;this.previousLoadingState&&!t&&(this.jsInitialized=!0),this.previousLoadingState=t,t&&!this._loadingTimeoutId?this._loadingTimeoutId=window.setTimeout(()=>{this.sdkStateController?.currentState.isLoading&&(R.warn(\"Loading timeout in component, forcing completion\"),this.sdkStateController.forceCompleteLoading(),this.jsInitialized=!0),this._loadingTimeoutId=null},1e4):!t&&this._loadingTimeoutId&&(window.clearTimeout(this._loadingTimeoutId),this._loadingTimeoutId=null)}render(){let t=this.sdkStateController.currentState,r=t.isLoading,o=t.error,n=!r&&!o;return c` ${V(r,()=>h)} ${V(o,()=>c`<primer-checkout-error></primer-checkout-error>`)} ${V(n,()=>c` <slot name=\"main\" @slotchange=${this.onSlotChange}></slot> ${V(this.hasAssignedContent,()=>h,()=>c`<primer-main></primer-main>`)} `,()=>h)} `}addEventListener(t,r,o){super.addEventListener(t,r,o)}removeEventListener(t,r,o){super.removeEventListener(t,r,o)}}"
|
|
26
41
|
},
|
|
27
42
|
{
|
|
28
43
|
"kind": "function",
|
|
@@ -42,7 +57,7 @@
|
|
|
42
57
|
},
|
|
43
58
|
{
|
|
44
59
|
"kind": "variable",
|
|
45
|
-
"name": "
|
|
60
|
+
"name": "Pe",
|
|
46
61
|
"default": "class extends v{constructor(){super(...arguments);this.color=\"var(--primer-color-loader)\";this.size=\"medium\";this.compact=!1}getSize(){if(this.size in Ki)return Ki[this.size];let t=parseInt(this.size,10);return isNaN(t)?Ki.medium:t}render(){let t=this.getSize(),r=20,o=`0 0 ${r} ${r}`;return this.style.setProperty(\"--spinner-color\",this.color),this.style.setProperty(\"--spinner-size\",`${t}px`),c` <div class=\"spinner-container ${this.compact?\"compact\":\"\"}\"> <svg class=\"spinner\" width=\"${t}\" height=\"${t}\" viewBox=\"${o}\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" role=\"status\" aria-label=\"Loading\" > <path d=\"M4.27827 10.002C4.27827 6.84166 6.84019 4.27973 10.0005 4.27973C10.7676 4.27973 11.3894 3.6579 11.3894 2.89084C11.3894 2.12378 10.7676 1.50195 10.0005 1.50195C5.30607 1.50195 1.50049 5.30753 1.50049 10.002C1.50049 14.6964 5.30607 18.502 10.0005 18.502C14.6949 18.502 18.5005 14.6964 18.5005 10.002C18.5005 9.23489 17.8787 8.61306 17.1116 8.61306C16.3445 8.61306 15.7227 9.23489 15.7227 10.002C15.7227 13.1622 13.1608 15.7242 10.0005 15.7242C6.84019 15.7242 4.27827 13.1622 4.27827 10.002Z\" fill=\"currentColor\" class=\"path\" /> </svg> </div> `}}"
|
|
47
62
|
},
|
|
48
63
|
{
|
|
@@ -67,7 +82,7 @@
|
|
|
67
82
|
},
|
|
68
83
|
{
|
|
69
84
|
"kind": "variable",
|
|
70
|
-
"name": "
|
|
85
|
+
"name": "we",
|
|
71
86
|
"default": "class extends v{constructor(){super(...arguments);this.color=\"var(--primer-color-icon-primary)\";this.size=\"lg\"}render(){let t=this.name?wa[this.name]:null;return c` <div style=\"--internal-icon-color: ${this.color}\"> ${t||c`<slot></slot>`} </div> `}}"
|
|
72
87
|
},
|
|
73
88
|
{
|
|
@@ -113,7 +128,7 @@
|
|
|
113
128
|
{
|
|
114
129
|
"kind": "variable",
|
|
115
130
|
"name": "pe",
|
|
116
|
-
"default": "class extends v{constructor(){super(...arguments);this.formController=new
|
|
131
|
+
"default": "class extends v{constructor(){super(...arguments);this.formController=new Kr(this,t=>this._paymentMethodManagerTask.value.setAndValidate(t));this.paymentManagers=new Map;this.sdkState=void 0;this.clientOptions=void 0;this.screen=\"form\";this.isSubmitting=!1;this._paymentMethodManagerTask=new D(this,{task:async([t])=>t!==\"STRIPE_ACH\"?L:this.paymentManagers.get(t)?.manager,args:()=>[this.paymentMethod?.type]})}_handleInput(t,r){let o=t.target;this.formController.setFieldValue(r,o.value)}_handleBlur(t){this.formController.setFieldTouched(t)}_handleError(t){this.dispatchEvent(new CustomEvent(\"primer-ach-error\",{bubbles:!0,composed:!0,detail:{error:t instanceof Error?t:new Error(typeof t==\"string\"?t:\"Unknown error occurred\")}}))}async _handleSubmitButtonClick(t){if(!this.isSubmitting){this.isSubmitting=!0;try{let r=await t.start(this.formController.formData);if(!r||r.valid)return await this._handleCollectBankAccountDetails(t);r&&this.formController.setValidation(r,!0)}catch(r){this._handleError(r)}finally{this.isSubmitting=!1}}}async _handleCollectBankAccountDetails(t){try{await t.collectBankAccountDetails(),this.screen=\"mandate\",this.dispatchEvent(new CustomEvent(\"primer-ach-bank-details-collected\",{bubbles:!0,composed:!0}))}catch(r){this._handleError(r)}}async _handleConfirmMandate(){if(this._paymentMethodManagerTask.value){this.isSubmitting=!0;try{await this._paymentMethodManagerTask.value.confirmMandate(),this.dispatchEvent(new CustomEvent(\"primer-ach-mandate-confirmed\",{bubbles:!0,composed:!0}))}catch(t){this._handleError(t)}finally{this.isSubmitting=!1}}}async _handleDeclineMandate(){if(this._paymentMethodManagerTask.value){this.isSubmitting=!0;try{await this._paymentMethodManagerTask.value.declineMandate(),this.dispatchEvent(new CustomEvent(\"primer-ach-mandate-declined\",{bubbles:!0,composed:!0}))}catch(t){this._handleError(t)}finally{this.isSubmitting=!1}}}renderForm(t){return c` <h2> ${A(\"payWithAch\",{id:\"payWithAch\"})} </h2> <p> ${A(\"stripe_ach_user_details_collection_subtitle_label\",{id:\"stripe_ach_user_details_collection_subtitle_label\"})} </p> <form @submit=${r=>r.preventDefault()}> <div class=\"form-row\"> <primer-input-wrapper .hasError=${this.formController.hasError.firstName} > <primer-input-label slot=\"label\"> ${A(\"stripe_ach_user_details_collection_first_name_label\",{id:\"stripe_ach_user_details_collection_first_name_label\"})} </primer-input-label> <primer-input slot=\"input\" .value=${this.formController.formState.firstName.value} @input=${r=>this._handleInput(r,\"firstName\")} @blur=${()=>this._handleBlur(\"firstName\")} ?disabled=${this.isSubmitting} ></primer-input> <primer-input-error slot=\"error\"> ${this.formController.hasError.firstName?this.formController.formState.firstName.error:h} </primer-input-error> </primer-input-wrapper> <primer-input-wrapper .hasError=${this.formController.hasError.lastName} > <primer-input-label slot=\"label\"> ${A(\"stripe_ach_user_details_collection_last_name_label\",{id:\"stripe_ach_user_details_collection_last_name_label\"})} </primer-input-label> <primer-input slot=\"input\" .value=${this.formController.formState.lastName.value} @input=${r=>this._handleInput(r,\"lastName\")} @blur=${()=>this._handleBlur(\"lastName\")} ?disabled=${this.isSubmitting} > </primer-input> <primer-input-error slot=\"error\"> ${this.formController.hasError.lastName?this.formController.formState.lastName.error:h} </primer-input-error> </primer-input-wrapper> </div> <primer-input-wrapper .hasError=${this.formController.hasError.emailAddress} > <primer-input-label slot=\"label\"> ${A(\"stripe_ach_user_details_collection_email_address_label\",{id:\"stripe_ach_user_details_collection_email_address_label\"})} </primer-input-label> <primer-input slot=\"input\" type=\"email\" .value=${this.formController.formState.emailAddress.value} @input=${r=>this._handleInput(r,\"emailAddress\")} @blur=${()=>this._handleBlur(\"emailAddress\")} ?disabled=${this.isSubmitting} ></primer-input> <primer-input-error slot=\"error\"> ${this.formController.hasError.emailAddress?this.formController.formState.emailAddress.error:h} </primer-input-error> </primer-input-wrapper> <p> ${A(\"stripe_ach_user_details_collection_data_usage_label\",{id:\"stripe_ach_user_details_collection_data_usage_label\"})} </p> <primer-button buttonType=\"submit\" variant=\"primary\" @click=${()=>this._handleSubmitButtonClick(t)} ?disabled=${this.isSubmitting} ?loading=${this.isSubmitting} > ${A(\"stripe_ach_user_details_collection_continue_button\",{id:\"stripe_ach_user_details_collection_continue_button\"})} </primer-button> </form> `}renderMandate(){return c` <h2> ${A(\"payWithAch\",{id:\"payWithAch\"})} </h2> <p> ${this.clientOptions?.stripe?.mandateData.fullMandateText??A(\"stripe_ach_mandate_template_web\",{id:\"stripe_ach_mandate_template_web\"}).replace(/\\{merchantName\\}/g,this.clientOptions?.stripe?.mandateData.merchantName??\"Merchant\")} </p> <div class=\"button-group\"> <primer-button variant=\"primary\" @click=${this._handleConfirmMandate.bind(this)} ?disabled=${this.isSubmitting} ?loading=${this.isSubmitting} > ${A(\"stripe_ach_mandate_accept_button\",{id:\"stripe_ach_mandate_accept_button\"})} </primer-button> <primer-button variant=\"tertiary\" @click=${this._handleDeclineMandate.bind(this)} ?disabled=${this.isSubmitting} > ${A(\"stripe_ach_mandate_cancel_payment_button\",{id:\"stripe_ach_mandate_cancel_payment_button\"})} </primer-button> </div> `}render(){return this._paymentMethodManagerTask.render({complete:t=>t?this.screen===\"form\"?this.renderForm(t):this.renderMandate():h})}}"
|
|
117
132
|
},
|
|
118
133
|
{
|
|
119
134
|
"kind": "variable",
|
|
@@ -128,22 +143,22 @@
|
|
|
128
143
|
{
|
|
129
144
|
"kind": "variable",
|
|
130
145
|
"name": "Fe",
|
|
131
|
-
"default": "class extends v{constructor(){super(...arguments);this.hasAssignedContent=!1;this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0,this.requestUpdate()};this.paymentMethods=null;this.sdkState=null}render(){return this.sdkState?.isSuccessful?c` <slot name=\"checkout-complete\"> <primer-checkout-complete></primer-checkout-complete> </slot> `:c` <slot name=\"payments\" @slotchange=${this.onSlotChange}></slot> ${
|
|
146
|
+
"default": "class extends v{constructor(){super(...arguments);this.hasAssignedContent=!1;this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0,this.requestUpdate()};this.paymentMethods=null;this.sdkState=null}render(){return this.sdkState?.isSuccessful?c` <slot name=\"checkout-complete\"> <primer-checkout-complete></primer-checkout-complete> </slot> `:c` <slot name=\"payments\" @slotchange=${this.onSlotChange}></slot> ${V(this.hasAssignedContent,()=>h,()=>c` <div class=${Z({\"primer-is-processing\":!!this.sdkState?.isProcessing})} > <primer-vault-manager></primer-vault-manager> <primer-show-other-payments> <div slot=\"other-payments\" class=\"primer-main-list\"> ${this.paymentMethods?.toArray().map(t=>c` <primer-payment-method type=${t.type} ></primer-payment-method> `)} </div> </primer-show-other-payments> <primer-error-message-container></primer-error-message-container> </div> `)} `}}"
|
|
132
147
|
},
|
|
133
148
|
{
|
|
134
149
|
"kind": "variable",
|
|
135
|
-
"name": "
|
|
150
|
+
"name": "ke",
|
|
136
151
|
"default": "class extends v{constructor(){super();this.paymentManagers=new Map;this.computedStyles=null;this._buttonId=\"button-container\";this.loadManagerTask=new D(this,{args:()=>[this.paymentMethod?.type],task:async([t])=>{if(!t)return L;let r=this.paymentManagers.get(t)?.manager;if(!r)throw new Error(`No manager found for payment method type ${t}`);return r}}),new D(this,{args:()=>[this.loadManagerTask.value],task:async([t])=>{if(!t)return L;await this.updateComplete;let r=this.shadowRoot?.getElementById(this._buttonId);if(!r)return;let o=this.calculateButtonHeight(),n=t.createButton(),l=this.createRenderOptions(o);return await n.render(this.paymentMethod?.type===\"GOOGLE_PAY\"?this.shadowRoot?.getRootNode():r,l),t}})}calculateButtonHeight(){if(typeof window>\"u\"||!this.isConnected||!this.computedStyles)return 0;let t=parseFloat(this.computedStyles.getPropertyValue(\"--primer-typography-title-large-line-height\")),r=parseFloat(this.computedStyles.getPropertyValue(\"--primer-space-medium\"));return t+2*r}createRenderOptions(t){let r=this.paymentMethod?.type;return r===\"GOOGLE_PAY\"?{style:{shadowRoot:!0}}:r===\"APPLE_PAY\"?{style:{buttonHeight:t}}:r===\"PAYPAL\"?{style:{buttonHeight:t}}:{style:{buttonHeight:t}}}updated(t){t.has(\"paymentMethod\")&&this.paymentMethod&&(this._buttonId=`button-container-${this.paymentMethod.type}`)}render(){return this.loadManagerTask.render({error:()=>h,complete:()=>c` <!-- The native button container is rendered first --> <div class=\"native-button-container\" id=\"${this._buttonId}\"></div> `,pending:()=>h})}}"
|
|
137
152
|
},
|
|
138
153
|
{
|
|
139
154
|
"kind": "variable",
|
|
140
|
-
"name": "
|
|
141
|
-
"default": "class extends v{constructor(){super(...arguments);this.hasAssignedContent=!1;this.selectedCardNetwork=null;this.paymentManagers=new Map;this.cardFormProvider=new q(this,{context:
|
|
155
|
+
"name": "Ee",
|
|
156
|
+
"default": "class extends v{constructor(){super(...arguments);this.hideLabels=!1;this.hasAssignedContent=!1;this.selectedCardNetwork=null;this.paymentManagers=new Map;this.cardFormProvider=new q(this,{context:jr,initialValue:null});this.eventsController=new gt(this);this.setupCardFormTask=new D(this,{task:async([t])=>{if(!t?.manager)return L;let{manager:r}=t,{cardNumberInput:o,expiryInput:n,cvvInput:l}=r.createHostedInputs();return this.cardFormProvider.setValue({cardNumberInput:o,expiryInput:n,cvvInput:l,setCardholderName:g=>r.setCardholderName(g),setCardNetwork:g=>{this.selectedCardNetwork=g},validate:()=>r.validate(),submit:g=>r.submit(g),hideLabels:this.hideLabels}),!0},args:()=>[this.paymentManagers.get(\"PAYMENT_CARD\")]});this.handleSlotButtonClick=t=>{let o=t.target.closest(\"button, primer-button\");if(!o)return;this.isSubmitButton(o)&&(t.preventDefault(),this.submitCardPayment())};this.handleDirectSubmit=t=>{t.stopPropagation(),this.submitCardPayment()};this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0};this.handleFormSubmit=t=>{t.preventDefault(),t.stopPropagation(),this.submitCardPayment()}}updated(t){super.updated(t),t.has(\"hideLabels\")&&this.cardFormProvider.value&&this.cardFormProvider.setValue({...this.cardFormProvider.value,hideLabels:this.hideLabels})}connectedCallback(){super.connectedCallback(),this.addEventListener(\"click\",this.handleSlotButtonClick),this.addEventListener(\"primer-form-submit\",this.handleDirectSubmit)}disconnectedCallback(){this.removeEventListener(\"click\",this.handleSlotButtonClick),this.removeEventListener(\"primer-form-submit\",this.handleDirectSubmit),super.disconnectedCallback()}isSubmitButton(t){let r=t.tagName.toLowerCase(),o=r===\"button\",n=r===\"primer-button\";return o&&(t.getAttribute(\"type\")===\"submit\"||t.hasAttribute(\"data-submit\"))||n&&(t.getAttribute(\"type\")===\"submit\"||t.hasAttribute(\"data-submit\"))}async submitCardPayment(){let t=this.cardFormProvider.value;if(!t)return;let r=await t.validate?.();if(r?.valid){let o=await t.submit?.(this.selectedCardNetwork?{cardNetwork:this.selectedCardNetwork}:void 0);this.eventsController.dispatchFormSubmitSuccess(o)}else{let o=r?.validationErrors;this.cardFormProvider.setValue({...t,errors:o}),this.eventsController.dispatchFormSubmitErrors(o)}}render(){return this.setupCardFormTask.status===De.ERROR||this.setupCardFormTask.status===De.INITIAL?h:c` <form @submit=${this.handleFormSubmit}> <slot name=\"card-form-content\" @slotchange=${this.onSlotChange}></slot> ${this.setupCardFormTask.render({complete:()=>V(this.hasAssignedContent,()=>h,()=>c` <div class=\"card-form\"> <primer-input-card-number></primer-input-card-number> <div class=\"card-form-row\"> <primer-input-card-expiry></primer-input-card-expiry> <primer-input-cvv></primer-input-cvv> </div> <primer-input-card-holder-name></primer-input-card-holder-name> </div> <primer-card-form-submit></primer-card-form-submit> `)})} </form> `}}"
|
|
142
157
|
},
|
|
143
158
|
{
|
|
144
159
|
"kind": "variable",
|
|
145
160
|
"name": "xt",
|
|
146
|
-
"default": "class extends X{constructor(){super();this.config={inputType:\"cardNumber\",containerSelector:\"#cardNumber\",errorName:\"cardNumber-card\",translations:{label:{id:\"cardNumber\",defaultMessage:\"Card Number\"},placeholder:\"4111 1111 1111 1111\",ariaLabel:{id:\"cardNumber\",defaultMessage:\"Card Number\"}}};this.childUpdated()}handleNetworkSelected(t){let{network:r}=t.detail;this.cardFormContext&&this.cardFormContext.setCardNetwork(r)}renderInput(){if(this.hostedInputController.setupTask.status===De.ERROR)return h;let t=this.getError();return c` <primer-input-wrapper .focusWithin=\"${this.hostedInputController.isFocused}\" .hasError=${!!t} >
|
|
161
|
+
"default": "class extends X{constructor(){super();this.config={inputType:\"cardNumber\",containerSelector:\"#cardNumber\",errorName:\"cardNumber-card\",translations:{label:{id:\"cardNumber\",defaultMessage:\"Card Number\"},placeholder:\"4111 1111 1111 1111\",ariaLabel:{id:\"cardNumber\",defaultMessage:\"Card Number\"}}};this.childUpdated()}handleNetworkSelected(t){let{network:r}=t.detail;this.cardFormContext&&this.cardFormContext.setCardNetwork(r)}renderInput(){if(this.hostedInputController.setupTask.status===De.ERROR)return h;let t=this.getError();return c` <primer-input-wrapper .focusWithin=\"${this.hostedInputController.isFocused}\" .hasError=${!!t} > ${V(!this.cardFormContext?.hideLabels,()=>c`<primer-input-label slot=\"label\" >${this.label}</primer-input-label >`,()=>h)} <div slot=\"input\" class=\"card-number-container\" aria-label=\"${this.ariaLabel}\" > <div id=\"${this.config.containerSelector.substring(1)}\"></div> <div class=\"network-selector-container\"> <primer-card-network-selector @network-selected=${this.handleNetworkSelected} ></primer-card-network-selector> </div> </div> ${V(t,r=>c` <primer-input-error slot=\"error\"> ${A(r,{id:r})} </primer-input-error> `,()=>h)} </primer-input-wrapper> `}render(){return this.renderInput()}}"
|
|
147
162
|
},
|
|
148
163
|
{
|
|
149
164
|
"kind": "variable",
|
|
@@ -163,22 +178,22 @@
|
|
|
163
178
|
{
|
|
164
179
|
"kind": "variable",
|
|
165
180
|
"name": "ce",
|
|
166
|
-
"default": "class extends v{constructor(){super(...arguments);this._userAssignedProps=new Set;this._internalButtonText=\"\";this.headlessInstance=null;this.clientOptions=null;this.sdkState=null;this.variant=\"primary\";this.disabled=!1;this.handleClick=t=>{if(t.preventDefault(),this.disabled)return;let r=new CustomEvent(\"primer-form-submit\",{bubbles:!0,composed:!0,detail:{source:\"primer-card-form-submit\"}});this.dispatchEvent(r)}}get buttonText(){return this._userAssignedProps.has(\"buttonText\")?this._internalButtonText:A(\"pay\",{id:\"pay\"})}set buttonText(t){let r=this.buttonText;t!==\"\"?(this._userAssignedProps.add(\"buttonText\"),this._internalButtonText=t):(this._userAssignedProps.delete(\"buttonText\"),this._internalButtonText=\"\"),this.requestUpdate(\"buttonText\",r)}render(){let t=this.clientOptions?.submitButton?.amountVisible?this.headlessInstance?.getUIOrderAmount():null,r=t?` ${t}`:h;return c` <primer-button
|
|
181
|
+
"default": "class extends v{constructor(){super(...arguments);this._userAssignedProps=new Set;this._internalButtonText=\"\";this.headlessInstance=null;this.clientOptions=null;this.sdkState=null;this.variant=\"primary\";this.disabled=!1;this.handleClick=t=>{if(t.preventDefault(),this.disabled)return;let r=new CustomEvent(\"primer-form-submit\",{bubbles:!0,composed:!0,detail:{source:\"primer-card-form-submit\"}});this.dispatchEvent(r)}}get buttonText(){return this._userAssignedProps.has(\"buttonText\")?this._internalButtonText:A(\"pay\",{id:\"pay\"})}set buttonText(t){let r=this.buttonText;t!==\"\"?(this._userAssignedProps.add(\"buttonText\"),this._internalButtonText=t):(this._userAssignedProps.delete(\"buttonText\"),this._internalButtonText=\"\"),this.requestUpdate(\"buttonText\",r)}render(){let t=this.clientOptions?.submitButton?.amountVisible?this.headlessInstance?.getUIOrderAmount():null,r=t?` ${t}`:h;return c` <primer-button type=\"submit\" variant=${this.variant} ?disabled=${this.disabled} @click=${this.handleClick} .loading=${!!this.sdkState?.isProcessing} data-submit > ${this.buttonText}${r} </primer-button> `}}"
|
|
167
182
|
},
|
|
168
183
|
{
|
|
169
184
|
"kind": "variable",
|
|
170
185
|
"name": "me",
|
|
171
|
-
"default": "class extends v{constructor(){super(...arguments);this.cardNetworks=null;this.headlessUtils=null;this.selectedCardNetwork=null;this.isDropdownOpen=!1;this.focusedNetworkIndex=0;this.isKeyboardNavigation=!1;this.buttonRef=qi();this.dropdownRef=qi();this.networkOptionRefs=[];this.handleClickOutside=t=>{this.isDropdownOpen&&(this.contains(t.target)||(this.isDropdownOpen=!1,this.isKeyboardNavigation=!1))};this.handleMouseMove=()=>{this.isKeyboardNavigation&&(this.isKeyboardNavigation=!1)};this.handleKeyDown=t=>{if(!(!(this.getSelectableNetworks().length>1)||!(this.contains(t.target)||this===t.target||this.isDropdownOpen&&t.target===document.body)))switch(this.isKeyboardNavigation=!0,t.key){case\"ArrowDown\":t.preventDefault(),this.isDropdownOpen?(this.focusedNetworkIndex=(this.focusedNetworkIndex+1)%this.getSelectableNetworks().length,this.focusNetworkOption()):(this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"ArrowUp\":t.preventDefault(),this.isDropdownOpen?(this.focusedNetworkIndex=(this.focusedNetworkIndex-1+this.getSelectableNetworks().length)%this.getSelectableNetworks().length,this.focusNetworkOption()):(this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"Enter\":case\" \":this.isDropdownOpen&&this.focusedNetworkIndex>=0?(t.preventDefault(),this.selectNetwork(t,this.getSelectableNetworks()[this.focusedNetworkIndex])):!this.isDropdownOpen&&this.buttonRef.value===document.activeElement&&(t.preventDefault(),this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"Escape\":this.isDropdownOpen&&(t.preventDefault(),this.isDropdownOpen=!1,this.buttonRef.value?.focus());break;case\"Tab\":this.isDropdownOpen&&(this.isDropdownOpen=!1);break}};this.handleDocumentKeyDown=t=>{this.isDropdownOpen&&this.handleKeyDown(t)}}toggleDropdown(t){this.isKeyboardNavigation=!1,t.stopPropagation(),this.getSelectableNetworks().length>1&&(this.isDropdownOpen=!this.isDropdownOpen,this.isDropdownOpen&&(this.focusedNetworkIndex=this.getSelectedNetworkIndex()))}getNetworkIconUrl(t){return this.headlessUtils?.getCardNetworkAsset(t.network)?.cardUrl}getSelectableNetworks(){return this.cardNetworks?.selectableCardNetworks||[]}getDetectedNetwork(){return this.selectedCardNetwork??(this.cardNetworks?.detectedCardNetwork||null)}getSelectedNetworkIndex(){let t=this.getDetectedNetwork();if(!t)return 0;let r=this.getSelectableNetworks().findIndex(o=>o.network===t.network);return r>=0?r:0}selectNetwork(t,r){t.stopPropagation(),this.selectedCardNetwork=r,this.isDropdownOpen=!1,this.buttonRef.value?.focus(),this.cardNetworks&&this.dispatchEvent(new CustomEvent(\"network-selected\",{detail:{network:r.network},bubbles:!0,composed:!0}))}focusNetworkOption(){requestAnimationFrame(()=>{this.networkOptionRefs[this.focusedNetworkIndex]&&this.networkOptionRefs[this.focusedNetworkIndex].focus()})}setNetworkOptionRef(t,r){this.networkOptionRefs[r]=t}connectedCallback(){super.connectedCallback(),setTimeout(()=>{document.addEventListener(\"click\",this.handleClickOutside),document.addEventListener(\"mousemove\",this.handleMouseMove),this.addEventListener(\"keydown\",this.handleKeyDown),document.addEventListener(\"keydown\",this.handleDocumentKeyDown)},0)}disconnectedCallback(){document.removeEventListener(\"click\",this.handleClickOutside),document.removeEventListener(\"keydown\",this.handleDocumentKeyDown),document.removeEventListener(\"mousemove\",this.handleMouseMove),this.removeEventListener(\"keydown\",this.handleKeyDown),super.disconnectedCallback()}render(){if(this.cardNetworks?.isLoading)return c`<primer-spinner size=\"small\" compact></primer-spinner>`;let t=this.getSelectableNetworks();if(!this.getDetectedNetwork()&&t.length===0)return c`<primer-icon name=\"payment-card\"></primer-icon>`;let r=this.getDetectedNetwork()||(t.length>0?t[0]:null);if(!r)return c`<primer-icon name=\"payment-card\" size=\"sm\"></primer-icon>`;let o=t.length>1;return c` <button ${
|
|
186
|
+
"default": "class extends v{constructor(){super(...arguments);this.cardNetworks=null;this.headlessUtils=null;this.selectedCardNetwork=null;this.isDropdownOpen=!1;this.focusedNetworkIndex=0;this.isKeyboardNavigation=!1;this.buttonRef=qi();this.dropdownRef=qi();this.networkOptionRefs=[];this.handleClickOutside=t=>{this.isDropdownOpen&&(this.contains(t.target)||(this.isDropdownOpen=!1,this.isKeyboardNavigation=!1))};this.handleMouseMove=()=>{this.isKeyboardNavigation&&(this.isKeyboardNavigation=!1)};this.handleKeyDown=t=>{if(!(!(this.getSelectableNetworks().length>1)||!(this.contains(t.target)||this===t.target||this.isDropdownOpen&&t.target===document.body)))switch(this.isKeyboardNavigation=!0,t.key){case\"ArrowDown\":t.preventDefault(),this.isDropdownOpen?(this.focusedNetworkIndex=(this.focusedNetworkIndex+1)%this.getSelectableNetworks().length,this.focusNetworkOption()):(this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"ArrowUp\":t.preventDefault(),this.isDropdownOpen?(this.focusedNetworkIndex=(this.focusedNetworkIndex-1+this.getSelectableNetworks().length)%this.getSelectableNetworks().length,this.focusNetworkOption()):(this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"Enter\":case\" \":this.isDropdownOpen&&this.focusedNetworkIndex>=0?(t.preventDefault(),this.selectNetwork(t,this.getSelectableNetworks()[this.focusedNetworkIndex])):!this.isDropdownOpen&&this.buttonRef.value===document.activeElement&&(t.preventDefault(),this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"Escape\":this.isDropdownOpen&&(t.preventDefault(),this.isDropdownOpen=!1,this.buttonRef.value?.focus());break;case\"Tab\":this.isDropdownOpen&&(this.isDropdownOpen=!1);break}};this.handleDocumentKeyDown=t=>{this.isDropdownOpen&&this.handleKeyDown(t)}}toggleDropdown(t){this.isKeyboardNavigation=!1,t.stopPropagation(),this.getSelectableNetworks().length>1&&(this.isDropdownOpen=!this.isDropdownOpen,this.isDropdownOpen&&(this.focusedNetworkIndex=this.getSelectedNetworkIndex()))}getNetworkIconUrl(t){return this.headlessUtils?.getCardNetworkAsset(t.network)?.cardUrl}getSelectableNetworks(){return this.cardNetworks?.selectableCardNetworks||[]}getDetectedNetwork(){return this.selectedCardNetwork??(this.cardNetworks?.detectedCardNetwork||null)}getSelectedNetworkIndex(){let t=this.getDetectedNetwork();if(!t)return 0;let r=this.getSelectableNetworks().findIndex(o=>o.network===t.network);return r>=0?r:0}selectNetwork(t,r){t.stopPropagation(),this.selectedCardNetwork=r,this.isDropdownOpen=!1,this.buttonRef.value?.focus(),this.cardNetworks&&this.dispatchEvent(new CustomEvent(\"network-selected\",{detail:{network:r.network},bubbles:!0,composed:!0}))}focusNetworkOption(){requestAnimationFrame(()=>{this.networkOptionRefs[this.focusedNetworkIndex]&&this.networkOptionRefs[this.focusedNetworkIndex].focus()})}setNetworkOptionRef(t,r){this.networkOptionRefs[r]=t}connectedCallback(){super.connectedCallback(),setTimeout(()=>{document.addEventListener(\"click\",this.handleClickOutside),document.addEventListener(\"mousemove\",this.handleMouseMove),this.addEventListener(\"keydown\",this.handleKeyDown),document.addEventListener(\"keydown\",this.handleDocumentKeyDown)},0)}disconnectedCallback(){document.removeEventListener(\"click\",this.handleClickOutside),document.removeEventListener(\"keydown\",this.handleDocumentKeyDown),document.removeEventListener(\"mousemove\",this.handleMouseMove),this.removeEventListener(\"keydown\",this.handleKeyDown),super.disconnectedCallback()}render(){if(this.cardNetworks?.isLoading)return c`<primer-spinner size=\"small\" compact></primer-spinner>`;let t=this.getSelectableNetworks();if(!this.getDetectedNetwork()&&t.length===0)return c`<primer-icon name=\"payment-card\"></primer-icon>`;let r=this.getDetectedNetwork()||(t.length>0?t[0]:null);if(!r)return c`<primer-icon name=\"payment-card\" size=\"sm\"></primer-icon>`;let o=t.length>1;return c` <button ${Xr(this.buttonRef)} class=\"network-selector\" @click=${this.toggleDropdown} @keydown=${n=>{(n.key===\" \"||n.key===\"Enter\")&&o&&(n.preventDefault(),this.isDropdownOpen=!this.isDropdownOpen,this.isDropdownOpen&&(this.focusedNetworkIndex=this.getSelectedNetworkIndex()))}} aria-label=${o?`Selected card network: ${r.displayName}. Click to change.`:`Card network: ${r.displayName}`} aria-expanded=${o?this.isDropdownOpen:h} aria-haspopup=${o?\"true\":h} aria-controls=${o?\"network-dropdown\":h} > <img class=\"network-icon\" src=${this.getNetworkIconUrl(r)} alt=${r.displayName} /> ${V(o,()=>c` <primer-icon class=\"caret ${this.isDropdownOpen?\"open\":\"\"}\" name=\"chevron-down\" ></primer-icon> `,()=>h)} </button> ${V(this.isDropdownOpen,()=>c` <div ${Xr(this.dropdownRef)} id=\"network-dropdown\" class=\"dropdown open\" role=\"listbox\" aria-label=\"Select card network\" > ${t.map((n,l)=>c` <div ${Xr(g=>this.setNetworkOptionRef(g,l))} class=\"network-option ${this.isKeyboardNavigation&&l===this.focusedNetworkIndex?\"focused\":\"\"}\" @click=${g=>this.selectNetwork(g,n)} @keydown=${g=>{(g.key===\"Enter\"||g.key===\" \")&&this.selectNetwork(g,n)}} role=\"option\" aria-selected=${n.network===r.network} tabindex=\"${l===this.focusedNetworkIndex?\"0\":\"-1\"}\" > <img class=\"network-option-icon\" src=${this.getNetworkIconUrl(n)} alt=${n.displayName} /> <span class=\"network-name\">${n.displayName}</span> ${V(n.network===r.network,()=>c` <primer-icon class=\"checkmark\" name=\"checkmark\" ></primer-icon> `,()=>h)} </div> `)} </div> `,()=>h)} `}}"
|
|
172
187
|
},
|
|
173
188
|
{
|
|
174
189
|
"kind": "variable",
|
|
175
190
|
"name": "ue",
|
|
176
|
-
"default": "class extends v{constructor(){super();this.vaultManagerContext=null;this.isEditMode=!1;this.deletePaymentMethodId=null;this.isDeleting=!1;this.errorMessage=\"\";this.animationDuration=300;new
|
|
191
|
+
"default": "class extends v{constructor(){super();this.vaultManagerContext=null;this.isEditMode=!1;this.deletePaymentMethodId=null;this.isDeleting=!1;this.errorMessage=\"\";this.animationDuration=300;new Tt(this,{defaultOptions:{keyframeOptions:{duration:Number(getComputedStyle(document.documentElement).getPropertyValue(\"--primer-animation-duration\").trim().replace(\"ms\",\"\")),easing:getComputedStyle(document.documentElement).getPropertyValue(\"--primer-animation-easing\").trim()}}})}getAnimationConfig(){return{keyframeOptions:{duration:this.animationDuration,easing:getComputedStyle(document.documentElement).getPropertyValue(\"--primer-animation-easing\").trim(),fill:\"both\"}}}handleToggleEditMode(t){this.isEditMode=t.detail,this.deletePaymentMethodId=null}handleDeletePaymentMethod(t){this.deletePaymentMethodId=t.detail}handleCancelDelete(){this.deletePaymentMethodId=null}async handleConfirmDelete(){if(!this.vaultManagerContext?.deleteVaultedPaymentMethod||!this.deletePaymentMethodId){this.errorMessage=A(\"something_went_wrong_error\",{id:\"something_went_wrong_error\"});return}try{this.isDeleting=!0,await this.vaultManagerContext.deleteVaultedPaymentMethod(this.deletePaymentMethodId),this.deletePaymentMethodId=null}catch(t){this.errorMessage=t instanceof Error?t.message:A(\"something_went_wrong_error\",{id:\"something_went_wrong_error\"})}finally{this.isDeleting=!1}}handlePaymentError(t){let r=t.detail?.error;this.errorMessage=r instanceof Error?r.message:A(\"payment_processing_error\",{id:\"payment_processing_error\"})}handleCloseError(){this.errorMessage=\"\"}getPaymentMethodName(t){if(!this.vaultManagerContext)return\"\";let r=this.vaultManagerContext.vaultedPaymentMethods.find(o=>o.id===t);if(!r)return\"\";try{return Jr(r).description||\"\"}catch{return\"\"}}renderLoadingOverlay(){return c` <div class=\"loading-overlay\" ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} > <primer-spinner size=\"medium\" color=\"var(--primer-color-loader)\" ></primer-spinner> </div> `}renderDeleteConfirmation(){if(!this.deletePaymentMethodId)return h;let t=this.getPaymentMethodName(this.deletePaymentMethodId);return c` <div class=\"delete-confirmation-container\"> <primer-vault-delete-confirmation .isDeleting=${this.isDeleting} .paymentMethodId=${this.deletePaymentMethodId} .paymentMethodName=${t} @confirm-delete=${this.handleConfirmDelete} @cancel-delete=${this.handleCancelDelete} ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-delete-confirmation> </div> `}renderPaymentMethodItem(t){return this.deletePaymentMethodId===t.id?h:c` <primer-vault-payment-method-item .paymentMethod=${t} .isEditMode=${this.isEditMode} @delete-payment-method=${this.handleDeletePaymentMethod} ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-payment-method-item> `}renderPaymentMethodList(){let t=this.vaultManagerContext?.vaultedPaymentMethods||[],r=!this.isEditMode&&t.length>0&&!this.deletePaymentMethodId;return c` <div class=\"payment-methods-list\"> ${t.map(o=>this.renderPaymentMethodItem(o))} ${V(r,()=>c` <div class=\"submit-button-container\"> <primer-vault-payment-submit class=\"submit-button\" @primer-vault-payment-error=${this.handlePaymentError} ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-payment-submit> </div> `,()=>h)} </div> `}render(){if(!this.vaultManagerContext?.enabled)return h;let t=this.vaultManagerContext.vaultedPaymentMethods.length>0,r=this.vaultManagerContext.isLoading,o=this.vaultManagerContext.isUpdating;return c` <div class=\"vault-manager ${o?\"is-updating\":\"\"}\"> <primer-vault-manager-header .isEditMode=${this.isEditMode} .hasPaymentMethods=${t} @toggle-edit-mode=${this.handleToggleEditMode} ></primer-vault-manager-header> ${V(this.errorMessage,()=>c` <primer-vault-error-message .errorMessage=${this.errorMessage} @close-error=${this.handleCloseError} ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-error-message> `,()=>h)} <div class=\"vault-manager-content\"> ${V(!r&&!t,()=>c` <div class=\"content-container\"> <primer-vault-empty-state ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-empty-state> </div> `,()=>h)} ${V(!r&&t,()=>c` <div class=\"content-container\"> ${V(this.deletePaymentMethodId,()=>this.renderDeleteConfirmation(),()=>this.renderPaymentMethodList())} </div> `,()=>h)} </div> ${V(o,()=>this.renderLoadingOverlay(),()=>h)} </div> `}}"
|
|
177
192
|
},
|
|
178
193
|
{
|
|
179
194
|
"kind": "variable",
|
|
180
195
|
"name": "ve",
|
|
181
|
-
"default": "class extends v{constructor(){super(...arguments);this.vaultManagerContext=null;this.vaultItemContext=null;this.headlessUtils=null;this.paymentMethod=null;this.isEditMode=!1;this._getAssetsTask=new D(this,{task:async([t,r,o])=>{if(!t||!r||!o)return L;let n=\"\";if(Mn(t))n=r.getCardNetworkAsset(t.paymentInstrumentData.network).cardUrl;else{let u=await r.getCDNAssets(t.paymentMethodType);u&&(n=u.assets?.icon?`${u.goatCdnUrl}/${u.assets.icon}`:\"\")}let l=o.cvvRecapture,g=
|
|
196
|
+
"default": "class extends v{constructor(){super(...arguments);this.vaultManagerContext=null;this.vaultItemContext=null;this.headlessUtils=null;this.paymentMethod=null;this.isEditMode=!1;this._getAssetsTask=new D(this,{task:async([t,r,o])=>{if(!t||!r||!o)return L;let n=\"\";if(Mn(t))n=r.getCardNetworkAsset(t.paymentInstrumentData.network).cardUrl;else{let u=await r.getCDNAssets(t.paymentMethodType);u&&(n=u.assets?.icon?`${u.goatCdnUrl}/${u.assets.icon}`:\"\")}let l=o.cvvRecapture,g=Jr(t);return{icon:n,shouldShowCVV:l,...g}},args:()=>[this.paymentMethod,this.headlessUtils,this.vaultManagerContext]})}isSelected(){if(!this.vaultManagerContext||!this.paymentMethod)return!1;let t=this.vaultItemContext?.selectedVaultedPaymentMethod;return!!t&&t.id===this.paymentMethod.id}handleClick(){this.isEditMode||!this.vaultManagerContext||!this.paymentMethod||(this.isSelected()?this.vaultItemContext?.setSelectedVaultedPaymentMethod(null):this.vaultItemContext?.setSelectedVaultedPaymentMethod(this.paymentMethod))}handleDeleteClick(t){t.stopPropagation(),this.dispatchEvent(new CustomEvent(\"delete-payment-method\",{detail:this.paymentMethod?.id,bubbles:!0,composed:!0}))}renderPaymentMethodContent(t){let r=t.icon?c`<img class=\"payment-method-icon\" src=${t.icon} alt=${t.description} />`:c` <div class=\"payment-method-icon payment-method-icon-generic\"> <primer-icon name=\"payment-card\" size=\"sm\"></primer-icon> </div> `;return c` ${r} <div class=\"payment-method-details\"> <div class=\"payment-method-description\">${t.description}</div> ${t.secondaryDescription?c`<div class=\"payment-method-secondary-description\"> ${t.secondaryDescription} </div>`:h} </div> `}render(){return this._getAssetsTask.render({error:()=>h,complete:t=>{let r=this.isSelected()?\"checked\":\"default\";return c` <div class=\"payment-method-wrapper\"> <div class=\"payment-method-container\"> <primer-button variant=\"secondary\" class=\"payment-method-button\" selectable ?disabled=${this.isEditMode} selectionState=${r} @click=${this.handleClick} > ${this.renderPaymentMethodContent(t)} </primer-button> ${this.isEditMode?c` <button class=\"delete-button\" @click=${this.handleDeleteClick} aria-label=${`${A(\"delete\",{id:\"delete\"})} ${t.description}`} > <primer-icon name=\"trash\" size=\"sm\"></primer-icon> </button> `:h} </div> ${V(t.shouldShowCVV&&this.isSelected()&&!this.isEditMode,()=>c`<primer-vault-cvv-input .paymentMethod=\"${this.paymentMethod}\" ></primer-vault-cvv-input>`,()=>h)} </div> `}})}}"
|
|
182
197
|
},
|
|
183
198
|
{
|
|
184
199
|
"kind": "variable",
|
|
@@ -187,7 +202,7 @@
|
|
|
187
202
|
},
|
|
188
203
|
{
|
|
189
204
|
"kind": "variable",
|
|
190
|
-
"name": "
|
|
205
|
+
"name": "Ce",
|
|
191
206
|
"default": "class extends v{constructor(){super(...arguments);this.isDeleting=!1;this.paymentMethodId=\"\";this.paymentMethodName=\"\";this.vaultManager=null}handleConfirmClick(){this.dispatchEvent(new CustomEvent(\"confirm-delete\",{bubbles:!0,composed:!0}))}handleCancelClick(){this.dispatchEvent(new CustomEvent(\"cancel-delete\",{bubbles:!0,composed:!0}))}render(){let t=this.paymentMethodName;return c` <div class=\"delete-confirmation\"> <div class=\"delete-message\"> <p class=\"delete-text\">${t}</p> </div> <div class=\"delete-actions\"> <button class=\"delete-confirm\" @click=${this.handleConfirmClick} ?disabled=${this.isDeleting} > ${this.isDeleting?A(\"deleting\",{id:\"deleting\"}):A(\"confirmVaultedPaymentMethodDeletion\",{id:\"confirmVaultedPaymentMethodDeletion\"})} </button> <button class=\"delete-cancel\" @click=${this.handleCancelClick} ?disabled=${this.isDeleting} > ${A(\"cancel\",{id:\"cancel\"})} </button> </div> </div> `}}"
|
|
192
207
|
},
|
|
193
208
|
{
|
|
@@ -208,7 +223,7 @@
|
|
|
208
223
|
{
|
|
209
224
|
"kind": "variable",
|
|
210
225
|
"name": "re",
|
|
211
|
-
"default": "class extends v{constructor(){super();this.vaultManagerFormContext=null;this.vaultManagerCvvContext=null;this.computedStyles=null;this.paymentMethod=null;this.cvvError=null;this.cvvInputIsDirty=!1;this.cvvInputIsBlurred=!1;this.cvvInput=null;this._setupCVVIframe=new D(this,{task:async([t,r])=>!t||!r||t.paymentMethodType!==\"PAYMENT_CARD\"||!t.paymentInstrumentData?.network||r.createCvvInput===null?L:{network:t.paymentInstrumentData.network,createCvvInput:r.createCvvInput},args:()=>[this.paymentMethod,this.vaultManagerFormContext]});this.cvvContainerId=`cvv-container-${Math.random().toString(36).substring(2,9)}`,new D(this,{task:async([t])=>{if(!t)return L;await this.updateComplete;let r=this.renderRoot.querySelector(`#${this.cvvContainerId}`);if(!r)return;let o=
|
|
226
|
+
"default": "class extends v{constructor(){super();this.vaultManagerFormContext=null;this.vaultManagerCvvContext=null;this.computedStyles=null;this.paymentMethod=null;this.cvvError=null;this.cvvInputIsDirty=!1;this.cvvInputIsBlurred=!1;this.cvvInput=null;this._setupCVVIframe=new D(this,{task:async([t,r])=>!t||!r||t.paymentMethodType!==\"PAYMENT_CARD\"||!t.paymentInstrumentData?.network||r.createCvvInput===null?L:{network:t.paymentInstrumentData.network,createCvvInput:r.createCvvInput},args:()=>[this.paymentMethod,this.vaultManagerFormContext]});this.cvvContainerId=`cvv-container-${Math.random().toString(36).substring(2,9)}`,new D(this,{task:async([t])=>{if(!t)return L;await this.updateComplete;let r=this.renderRoot.querySelector(`#${this.cvvContainerId}`);if(!r)return;let o=Gr(this.computedStyles),n=o?{input:{base:o}}:void 0,l={cardNetwork:t.network,container:r,name:\"cvv\",placeholder:\"123\",style:n};this.cvvInput=await t.createCvvInput?.(l)??null,this.cvvInput&&(this.cvvInput.focus(),this.cvvError=this.cvvInput.metadata.error||null,this.vaultManagerCvvContext?.setCvvInput(this.cvvInput),this.cvvInput.addListener(\"change\",()=>{this.onCvvInputChange()}),this.cvvInput.addListener(\"blur\",()=>{this.onBlur()}))},args:()=>[this._setupCVVIframe.value]})}disconnectedCallback(){super.disconnectedCallback(),this.cvvInput&&(this.cvvInput.remove(),this.cvvInput=null,this.cvvError=null,this.vaultManagerCvvContext?.setCvvInput(null))}onCvvInputChange(){!this.cvvInput||!this.vaultManagerCvvContext||(this.cvvInputIsDirty=!0,this.cvvError=this.cvvInput.metadata.error||null)}onBlur(){this.cvvInput&&(this.cvvInputIsBlurred=!0,this.cvvError=this.cvvInput.metadata.error||null)}render(){return this._setupCVVIframe.render({error:()=>h,complete:()=>c` <div class=\"cvv-input-container\"> <primer-input-wrapper .hasError=${!!this.cvvError&&(this.vaultManagerCvvContext?.formIsDirty||this.cvvInputIsDirty&&this.cvvInputIsBlurred)} > <primer-input-label slot=\"label\">CVV</primer-input-label> <div slot=\"input\" id=\"${this.cvvContainerId}\"></div> ${V(this.cvvError&&(this.vaultManagerCvvContext?.formIsDirty||this.cvvInputIsDirty&&this.cvvInputIsBlurred),()=>c` <primer-input-error slot=\"error\"> ${this.cvvError} </primer-input-error> `)} </primer-input-wrapper> </div> `})}}"
|
|
212
227
|
},
|
|
213
228
|
{
|
|
214
229
|
"kind": "variable",
|
|
@@ -268,7 +283,7 @@
|
|
|
268
283
|
"kind": "js",
|
|
269
284
|
"name": "CardForm",
|
|
270
285
|
"declaration": {
|
|
271
|
-
"name": "
|
|
286
|
+
"name": "Ee",
|
|
272
287
|
"module": "cdn/primer-components.js"
|
|
273
288
|
}
|
|
274
289
|
},
|
|
@@ -372,7 +387,7 @@
|
|
|
372
387
|
"kind": "js",
|
|
373
388
|
"name": "InitializedPayments",
|
|
374
389
|
"declaration": {
|
|
375
|
-
"name": "
|
|
390
|
+
"name": "Hr",
|
|
376
391
|
"module": "cdn/primer-components.js"
|
|
377
392
|
}
|
|
378
393
|
},
|
|
@@ -404,7 +419,7 @@
|
|
|
404
419
|
"kind": "js",
|
|
405
420
|
"name": "NativePayment",
|
|
406
421
|
"declaration": {
|
|
407
|
-
"name": "
|
|
422
|
+
"name": "ke",
|
|
408
423
|
"module": "cdn/primer-components.js"
|
|
409
424
|
}
|
|
410
425
|
},
|
|
@@ -460,7 +475,7 @@
|
|
|
460
475
|
"kind": "js",
|
|
461
476
|
"name": "PrimerIcon",
|
|
462
477
|
"declaration": {
|
|
463
|
-
"name": "
|
|
478
|
+
"name": "we",
|
|
464
479
|
"module": "cdn/primer-components.js"
|
|
465
480
|
}
|
|
466
481
|
},
|
|
@@ -500,7 +515,7 @@
|
|
|
500
515
|
"kind": "js",
|
|
501
516
|
"name": "Spinner",
|
|
502
517
|
"declaration": {
|
|
503
|
-
"name": "
|
|
518
|
+
"name": "Pe",
|
|
504
519
|
"module": "cdn/primer-components.js"
|
|
505
520
|
}
|
|
506
521
|
},
|
|
@@ -516,7 +531,7 @@
|
|
|
516
531
|
"kind": "js",
|
|
517
532
|
"name": "VaultDeleteConfirmation",
|
|
518
533
|
"declaration": {
|
|
519
|
-
"name": "
|
|
534
|
+
"name": "Ce",
|
|
520
535
|
"module": "cdn/primer-components.js"
|
|
521
536
|
}
|
|
522
537
|
},
|
|
@@ -616,13 +631,13 @@
|
|
|
616
631
|
},
|
|
617
632
|
{
|
|
618
633
|
"kind": "variable",
|
|
619
|
-
"name": "
|
|
634
|
+
"name": "Hr",
|
|
620
635
|
"default": "class{constructor(e){this._methods=e}get(e){return this._methods.get(e)}toArray(){return Array.from(this._methods.values())}size(){return this._methods.size}}"
|
|
621
636
|
},
|
|
622
637
|
{
|
|
623
638
|
"kind": "variable",
|
|
624
639
|
"name": "le",
|
|
625
|
-
"default": "class extends v{constructor(){super();this.customStyles=\"\";this.clientToken=\"\";this.options={};this._jsInitialized=!1;this.previousLoadingState=!0;this.hasAssignedContent=!1;this._loadingTimeoutId=null;this.locale=\"en-GB\";this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0,this.requestUpdate()};this.sdkContextController=new
|
|
640
|
+
"default": "class extends v{constructor(){super();this.customStyles=\"\";this.clientToken=\"\";this.options={};this._jsInitialized=!1;this.previousLoadingState=!0;this.hasAssignedContent=!1;this._loadingTimeoutId=null;this.locale=\"en-GB\";this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0,this.requestUpdate()};this.sdkContextController=new Ar(this),this.sdkStateController=new Cr(this),this.primerEventsController=new gt(this),this.styleProcessingController=new _r(this),this.vaultManagerController=new Yt(this),this.cardNetworkController=new fr(this),this.achPaymentEventsController=new zr(this),new Yr(this)}set jsInitialized(t){this.requestUpdate(),this._jsInitialized=t}get jsInitialized(){return this._jsInitialized}attributeChangedCallback(t,r,o){t===Fr.CUSTOM_STYLES?this.styleProcessingController.processCustomStyles(o):super.attributeChangedCallback(t,r,o)}disconnectedCallback(){this._loadingTimeoutId&&(window.clearTimeout(this._loadingTimeoutId),this._loadingTimeoutId=null),this.sdkStateController?.currentState.isLoading&&this.sdkStateController.forceCompleteLoading(),super.disconnectedCallback()}willUpdate(t){t.has(\"options\")&&(this.options?.locale&&(Oi(this.options?.locale)?this.locale=Di(this.options?.locale):R.warn(\"\\u{1F30E}\\u2757 Unsupported locale provided:\",this.options?.locale,\"- Falling back to default locale `en-GB`\")),Ri(this.locale||\"en-GB\"))}updated(){let t=getComputedStyle(this);this.sdkContextController.setComputedStyles(t),this.checkLoadingStateChange()}checkLoadingStateChange(){let t=this.sdkStateController?.currentState.isLoading||!1;this.previousLoadingState&&!t&&(this.jsInitialized=!0),this.previousLoadingState=t,t&&!this._loadingTimeoutId?this._loadingTimeoutId=window.setTimeout(()=>{this.sdkStateController?.currentState.isLoading&&(R.warn(\"Loading timeout in component, forcing completion\"),this.sdkStateController.forceCompleteLoading(),this.jsInitialized=!0),this._loadingTimeoutId=null},1e4):!t&&this._loadingTimeoutId&&(window.clearTimeout(this._loadingTimeoutId),this._loadingTimeoutId=null)}render(){let t=this.sdkStateController.currentState,r=t.isLoading,o=t.error,n=!r&&!o;return c` ${V(r,()=>h)} ${V(o,()=>c`<primer-checkout-error></primer-checkout-error>`)} ${V(n,()=>c` <slot name=\"main\" @slotchange=${this.onSlotChange}></slot> ${V(this.hasAssignedContent,()=>h,()=>c`<primer-main></primer-main>`)} `,()=>h)} `}addEventListener(t,r,o){super.addEventListener(t,r,o)}removeEventListener(t,r,o){super.removeEventListener(t,r,o)}}"
|
|
626
641
|
},
|
|
627
642
|
{
|
|
628
643
|
"kind": "function",
|
|
@@ -642,7 +657,7 @@
|
|
|
642
657
|
},
|
|
643
658
|
{
|
|
644
659
|
"kind": "variable",
|
|
645
|
-
"name": "
|
|
660
|
+
"name": "Pe",
|
|
646
661
|
"default": "class extends v{constructor(){super(...arguments);this.color=\"var(--primer-color-loader)\";this.size=\"medium\";this.compact=!1}getSize(){if(this.size in Ki)return Ki[this.size];let t=parseInt(this.size,10);return isNaN(t)?Ki.medium:t}render(){let t=this.getSize(),r=20,o=`0 0 ${r} ${r}`;return this.style.setProperty(\"--spinner-color\",this.color),this.style.setProperty(\"--spinner-size\",`${t}px`),c` <div class=\"spinner-container ${this.compact?\"compact\":\"\"}\"> <svg class=\"spinner\" width=\"${t}\" height=\"${t}\" viewBox=\"${o}\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" role=\"status\" aria-label=\"Loading\" > <path d=\"M4.27827 10.002C4.27827 6.84166 6.84019 4.27973 10.0005 4.27973C10.7676 4.27973 11.3894 3.6579 11.3894 2.89084C11.3894 2.12378 10.7676 1.50195 10.0005 1.50195C5.30607 1.50195 1.50049 5.30753 1.50049 10.002C1.50049 14.6964 5.30607 18.502 10.0005 18.502C14.6949 18.502 18.5005 14.6964 18.5005 10.002C18.5005 9.23489 17.8787 8.61306 17.1116 8.61306C16.3445 8.61306 15.7227 9.23489 15.7227 10.002C15.7227 13.1622 13.1608 15.7242 10.0005 15.7242C6.84019 15.7242 4.27827 13.1622 4.27827 10.002Z\" fill=\"currentColor\" class=\"path\" /> </svg> </div> `}}"
|
|
647
662
|
},
|
|
648
663
|
{
|
|
@@ -667,7 +682,7 @@
|
|
|
667
682
|
},
|
|
668
683
|
{
|
|
669
684
|
"kind": "variable",
|
|
670
|
-
"name": "
|
|
685
|
+
"name": "we",
|
|
671
686
|
"default": "class extends v{constructor(){super(...arguments);this.color=\"var(--primer-color-icon-primary)\";this.size=\"lg\"}render(){let t=this.name?wa[this.name]:null;return c` <div style=\"--internal-icon-color: ${this.color}\"> ${t||c`<slot></slot>`} </div> `}}"
|
|
672
687
|
},
|
|
673
688
|
{
|
|
@@ -713,7 +728,7 @@
|
|
|
713
728
|
{
|
|
714
729
|
"kind": "variable",
|
|
715
730
|
"name": "pe",
|
|
716
|
-
"default": "class extends v{constructor(){super(...arguments);this.formController=new
|
|
731
|
+
"default": "class extends v{constructor(){super(...arguments);this.formController=new Kr(this,t=>this._paymentMethodManagerTask.value.setAndValidate(t));this.paymentManagers=new Map;this.sdkState=void 0;this.clientOptions=void 0;this.screen=\"form\";this.isSubmitting=!1;this._paymentMethodManagerTask=new D(this,{task:async([t])=>t!==\"STRIPE_ACH\"?L:this.paymentManagers.get(t)?.manager,args:()=>[this.paymentMethod?.type]})}_handleInput(t,r){let o=t.target;this.formController.setFieldValue(r,o.value)}_handleBlur(t){this.formController.setFieldTouched(t)}_handleError(t){this.dispatchEvent(new CustomEvent(\"primer-ach-error\",{bubbles:!0,composed:!0,detail:{error:t instanceof Error?t:new Error(typeof t==\"string\"?t:\"Unknown error occurred\")}}))}async _handleSubmitButtonClick(t){if(!this.isSubmitting){this.isSubmitting=!0;try{let r=await t.start(this.formController.formData);if(!r||r.valid)return await this._handleCollectBankAccountDetails(t);r&&this.formController.setValidation(r,!0)}catch(r){this._handleError(r)}finally{this.isSubmitting=!1}}}async _handleCollectBankAccountDetails(t){try{await t.collectBankAccountDetails(),this.screen=\"mandate\",this.dispatchEvent(new CustomEvent(\"primer-ach-bank-details-collected\",{bubbles:!0,composed:!0}))}catch(r){this._handleError(r)}}async _handleConfirmMandate(){if(this._paymentMethodManagerTask.value){this.isSubmitting=!0;try{await this._paymentMethodManagerTask.value.confirmMandate(),this.dispatchEvent(new CustomEvent(\"primer-ach-mandate-confirmed\",{bubbles:!0,composed:!0}))}catch(t){this._handleError(t)}finally{this.isSubmitting=!1}}}async _handleDeclineMandate(){if(this._paymentMethodManagerTask.value){this.isSubmitting=!0;try{await this._paymentMethodManagerTask.value.declineMandate(),this.dispatchEvent(new CustomEvent(\"primer-ach-mandate-declined\",{bubbles:!0,composed:!0}))}catch(t){this._handleError(t)}finally{this.isSubmitting=!1}}}renderForm(t){return c` <h2> ${A(\"payWithAch\",{id:\"payWithAch\"})} </h2> <p> ${A(\"stripe_ach_user_details_collection_subtitle_label\",{id:\"stripe_ach_user_details_collection_subtitle_label\"})} </p> <form @submit=${r=>r.preventDefault()}> <div class=\"form-row\"> <primer-input-wrapper .hasError=${this.formController.hasError.firstName} > <primer-input-label slot=\"label\"> ${A(\"stripe_ach_user_details_collection_first_name_label\",{id:\"stripe_ach_user_details_collection_first_name_label\"})} </primer-input-label> <primer-input slot=\"input\" .value=${this.formController.formState.firstName.value} @input=${r=>this._handleInput(r,\"firstName\")} @blur=${()=>this._handleBlur(\"firstName\")} ?disabled=${this.isSubmitting} ></primer-input> <primer-input-error slot=\"error\"> ${this.formController.hasError.firstName?this.formController.formState.firstName.error:h} </primer-input-error> </primer-input-wrapper> <primer-input-wrapper .hasError=${this.formController.hasError.lastName} > <primer-input-label slot=\"label\"> ${A(\"stripe_ach_user_details_collection_last_name_label\",{id:\"stripe_ach_user_details_collection_last_name_label\"})} </primer-input-label> <primer-input slot=\"input\" .value=${this.formController.formState.lastName.value} @input=${r=>this._handleInput(r,\"lastName\")} @blur=${()=>this._handleBlur(\"lastName\")} ?disabled=${this.isSubmitting} > </primer-input> <primer-input-error slot=\"error\"> ${this.formController.hasError.lastName?this.formController.formState.lastName.error:h} </primer-input-error> </primer-input-wrapper> </div> <primer-input-wrapper .hasError=${this.formController.hasError.emailAddress} > <primer-input-label slot=\"label\"> ${A(\"stripe_ach_user_details_collection_email_address_label\",{id:\"stripe_ach_user_details_collection_email_address_label\"})} </primer-input-label> <primer-input slot=\"input\" type=\"email\" .value=${this.formController.formState.emailAddress.value} @input=${r=>this._handleInput(r,\"emailAddress\")} @blur=${()=>this._handleBlur(\"emailAddress\")} ?disabled=${this.isSubmitting} ></primer-input> <primer-input-error slot=\"error\"> ${this.formController.hasError.emailAddress?this.formController.formState.emailAddress.error:h} </primer-input-error> </primer-input-wrapper> <p> ${A(\"stripe_ach_user_details_collection_data_usage_label\",{id:\"stripe_ach_user_details_collection_data_usage_label\"})} </p> <primer-button buttonType=\"submit\" variant=\"primary\" @click=${()=>this._handleSubmitButtonClick(t)} ?disabled=${this.isSubmitting} ?loading=${this.isSubmitting} > ${A(\"stripe_ach_user_details_collection_continue_button\",{id:\"stripe_ach_user_details_collection_continue_button\"})} </primer-button> </form> `}renderMandate(){return c` <h2> ${A(\"payWithAch\",{id:\"payWithAch\"})} </h2> <p> ${this.clientOptions?.stripe?.mandateData.fullMandateText??A(\"stripe_ach_mandate_template_web\",{id:\"stripe_ach_mandate_template_web\"}).replace(/\\{merchantName\\}/g,this.clientOptions?.stripe?.mandateData.merchantName??\"Merchant\")} </p> <div class=\"button-group\"> <primer-button variant=\"primary\" @click=${this._handleConfirmMandate.bind(this)} ?disabled=${this.isSubmitting} ?loading=${this.isSubmitting} > ${A(\"stripe_ach_mandate_accept_button\",{id:\"stripe_ach_mandate_accept_button\"})} </primer-button> <primer-button variant=\"tertiary\" @click=${this._handleDeclineMandate.bind(this)} ?disabled=${this.isSubmitting} > ${A(\"stripe_ach_mandate_cancel_payment_button\",{id:\"stripe_ach_mandate_cancel_payment_button\"})} </primer-button> </div> `}render(){return this._paymentMethodManagerTask.render({complete:t=>t?this.screen===\"form\"?this.renderForm(t):this.renderMandate():h})}}"
|
|
717
732
|
},
|
|
718
733
|
{
|
|
719
734
|
"kind": "variable",
|
|
@@ -728,22 +743,22 @@
|
|
|
728
743
|
{
|
|
729
744
|
"kind": "variable",
|
|
730
745
|
"name": "Fe",
|
|
731
|
-
"default": "class extends v{constructor(){super(...arguments);this.hasAssignedContent=!1;this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0,this.requestUpdate()};this.paymentMethods=null;this.sdkState=null}render(){return this.sdkState?.isSuccessful?c` <slot name=\"checkout-complete\"> <primer-checkout-complete></primer-checkout-complete> </slot> `:c` <slot name=\"payments\" @slotchange=${this.onSlotChange}></slot> ${
|
|
746
|
+
"default": "class extends v{constructor(){super(...arguments);this.hasAssignedContent=!1;this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0,this.requestUpdate()};this.paymentMethods=null;this.sdkState=null}render(){return this.sdkState?.isSuccessful?c` <slot name=\"checkout-complete\"> <primer-checkout-complete></primer-checkout-complete> </slot> `:c` <slot name=\"payments\" @slotchange=${this.onSlotChange}></slot> ${V(this.hasAssignedContent,()=>h,()=>c` <div class=${Z({\"primer-is-processing\":!!this.sdkState?.isProcessing})} > <primer-vault-manager></primer-vault-manager> <primer-show-other-payments> <div slot=\"other-payments\" class=\"primer-main-list\"> ${this.paymentMethods?.toArray().map(t=>c` <primer-payment-method type=${t.type} ></primer-payment-method> `)} </div> </primer-show-other-payments> <primer-error-message-container></primer-error-message-container> </div> `)} `}}"
|
|
732
747
|
},
|
|
733
748
|
{
|
|
734
749
|
"kind": "variable",
|
|
735
|
-
"name": "
|
|
750
|
+
"name": "ke",
|
|
736
751
|
"default": "class extends v{constructor(){super();this.paymentManagers=new Map;this.computedStyles=null;this._buttonId=\"button-container\";this.loadManagerTask=new D(this,{args:()=>[this.paymentMethod?.type],task:async([t])=>{if(!t)return L;let r=this.paymentManagers.get(t)?.manager;if(!r)throw new Error(`No manager found for payment method type ${t}`);return r}}),new D(this,{args:()=>[this.loadManagerTask.value],task:async([t])=>{if(!t)return L;await this.updateComplete;let r=this.shadowRoot?.getElementById(this._buttonId);if(!r)return;let o=this.calculateButtonHeight(),n=t.createButton(),l=this.createRenderOptions(o);return await n.render(this.paymentMethod?.type===\"GOOGLE_PAY\"?this.shadowRoot?.getRootNode():r,l),t}})}calculateButtonHeight(){if(typeof window>\"u\"||!this.isConnected||!this.computedStyles)return 0;let t=parseFloat(this.computedStyles.getPropertyValue(\"--primer-typography-title-large-line-height\")),r=parseFloat(this.computedStyles.getPropertyValue(\"--primer-space-medium\"));return t+2*r}createRenderOptions(t){let r=this.paymentMethod?.type;return r===\"GOOGLE_PAY\"?{style:{shadowRoot:!0}}:r===\"APPLE_PAY\"?{style:{buttonHeight:t}}:r===\"PAYPAL\"?{style:{buttonHeight:t}}:{style:{buttonHeight:t}}}updated(t){t.has(\"paymentMethod\")&&this.paymentMethod&&(this._buttonId=`button-container-${this.paymentMethod.type}`)}render(){return this.loadManagerTask.render({error:()=>h,complete:()=>c` <!-- The native button container is rendered first --> <div class=\"native-button-container\" id=\"${this._buttonId}\"></div> `,pending:()=>h})}}"
|
|
737
752
|
},
|
|
738
753
|
{
|
|
739
754
|
"kind": "variable",
|
|
740
|
-
"name": "
|
|
741
|
-
"default": "class extends v{constructor(){super(...arguments);this.hasAssignedContent=!1;this.selectedCardNetwork=null;this.paymentManagers=new Map;this.cardFormProvider=new q(this,{context:
|
|
755
|
+
"name": "Ee",
|
|
756
|
+
"default": "class extends v{constructor(){super(...arguments);this.hideLabels=!1;this.hasAssignedContent=!1;this.selectedCardNetwork=null;this.paymentManagers=new Map;this.cardFormProvider=new q(this,{context:jr,initialValue:null});this.eventsController=new gt(this);this.setupCardFormTask=new D(this,{task:async([t])=>{if(!t?.manager)return L;let{manager:r}=t,{cardNumberInput:o,expiryInput:n,cvvInput:l}=r.createHostedInputs();return this.cardFormProvider.setValue({cardNumberInput:o,expiryInput:n,cvvInput:l,setCardholderName:g=>r.setCardholderName(g),setCardNetwork:g=>{this.selectedCardNetwork=g},validate:()=>r.validate(),submit:g=>r.submit(g),hideLabels:this.hideLabels}),!0},args:()=>[this.paymentManagers.get(\"PAYMENT_CARD\")]});this.handleSlotButtonClick=t=>{let o=t.target.closest(\"button, primer-button\");if(!o)return;this.isSubmitButton(o)&&(t.preventDefault(),this.submitCardPayment())};this.handleDirectSubmit=t=>{t.stopPropagation(),this.submitCardPayment()};this.onSlotChange=t=>{let o=t.target.assignedNodes({flatten:!0});this.hasAssignedContent=o.length>0};this.handleFormSubmit=t=>{t.preventDefault(),t.stopPropagation(),this.submitCardPayment()}}updated(t){super.updated(t),t.has(\"hideLabels\")&&this.cardFormProvider.value&&this.cardFormProvider.setValue({...this.cardFormProvider.value,hideLabels:this.hideLabels})}connectedCallback(){super.connectedCallback(),this.addEventListener(\"click\",this.handleSlotButtonClick),this.addEventListener(\"primer-form-submit\",this.handleDirectSubmit)}disconnectedCallback(){this.removeEventListener(\"click\",this.handleSlotButtonClick),this.removeEventListener(\"primer-form-submit\",this.handleDirectSubmit),super.disconnectedCallback()}isSubmitButton(t){let r=t.tagName.toLowerCase(),o=r===\"button\",n=r===\"primer-button\";return o&&(t.getAttribute(\"type\")===\"submit\"||t.hasAttribute(\"data-submit\"))||n&&(t.getAttribute(\"type\")===\"submit\"||t.hasAttribute(\"data-submit\"))}async submitCardPayment(){let t=this.cardFormProvider.value;if(!t)return;let r=await t.validate?.();if(r?.valid){let o=await t.submit?.(this.selectedCardNetwork?{cardNetwork:this.selectedCardNetwork}:void 0);this.eventsController.dispatchFormSubmitSuccess(o)}else{let o=r?.validationErrors;this.cardFormProvider.setValue({...t,errors:o}),this.eventsController.dispatchFormSubmitErrors(o)}}render(){return this.setupCardFormTask.status===De.ERROR||this.setupCardFormTask.status===De.INITIAL?h:c` <form @submit=${this.handleFormSubmit}> <slot name=\"card-form-content\" @slotchange=${this.onSlotChange}></slot> ${this.setupCardFormTask.render({complete:()=>V(this.hasAssignedContent,()=>h,()=>c` <div class=\"card-form\"> <primer-input-card-number></primer-input-card-number> <div class=\"card-form-row\"> <primer-input-card-expiry></primer-input-card-expiry> <primer-input-cvv></primer-input-cvv> </div> <primer-input-card-holder-name></primer-input-card-holder-name> </div> <primer-card-form-submit></primer-card-form-submit> `)})} </form> `}}"
|
|
742
757
|
},
|
|
743
758
|
{
|
|
744
759
|
"kind": "variable",
|
|
745
760
|
"name": "xt",
|
|
746
|
-
"default": "class extends X{constructor(){super();this.config={inputType:\"cardNumber\",containerSelector:\"#cardNumber\",errorName:\"cardNumber-card\",translations:{label:{id:\"cardNumber\",defaultMessage:\"Card Number\"},placeholder:\"4111 1111 1111 1111\",ariaLabel:{id:\"cardNumber\",defaultMessage:\"Card Number\"}}};this.childUpdated()}handleNetworkSelected(t){let{network:r}=t.detail;this.cardFormContext&&this.cardFormContext.setCardNetwork(r)}renderInput(){if(this.hostedInputController.setupTask.status===De.ERROR)return h;let t=this.getError();return c` <primer-input-wrapper .focusWithin=\"${this.hostedInputController.isFocused}\" .hasError=${!!t} >
|
|
761
|
+
"default": "class extends X{constructor(){super();this.config={inputType:\"cardNumber\",containerSelector:\"#cardNumber\",errorName:\"cardNumber-card\",translations:{label:{id:\"cardNumber\",defaultMessage:\"Card Number\"},placeholder:\"4111 1111 1111 1111\",ariaLabel:{id:\"cardNumber\",defaultMessage:\"Card Number\"}}};this.childUpdated()}handleNetworkSelected(t){let{network:r}=t.detail;this.cardFormContext&&this.cardFormContext.setCardNetwork(r)}renderInput(){if(this.hostedInputController.setupTask.status===De.ERROR)return h;let t=this.getError();return c` <primer-input-wrapper .focusWithin=\"${this.hostedInputController.isFocused}\" .hasError=${!!t} > ${V(!this.cardFormContext?.hideLabels,()=>c`<primer-input-label slot=\"label\" >${this.label}</primer-input-label >`,()=>h)} <div slot=\"input\" class=\"card-number-container\" aria-label=\"${this.ariaLabel}\" > <div id=\"${this.config.containerSelector.substring(1)}\"></div> <div class=\"network-selector-container\"> <primer-card-network-selector @network-selected=${this.handleNetworkSelected} ></primer-card-network-selector> </div> </div> ${V(t,r=>c` <primer-input-error slot=\"error\"> ${A(r,{id:r})} </primer-input-error> `,()=>h)} </primer-input-wrapper> `}render(){return this.renderInput()}}"
|
|
747
762
|
},
|
|
748
763
|
{
|
|
749
764
|
"kind": "variable",
|
|
@@ -763,22 +778,22 @@
|
|
|
763
778
|
{
|
|
764
779
|
"kind": "variable",
|
|
765
780
|
"name": "ce",
|
|
766
|
-
"default": "class extends v{constructor(){super(...arguments);this._userAssignedProps=new Set;this._internalButtonText=\"\";this.headlessInstance=null;this.clientOptions=null;this.sdkState=null;this.variant=\"primary\";this.disabled=!1;this.handleClick=t=>{if(t.preventDefault(),this.disabled)return;let r=new CustomEvent(\"primer-form-submit\",{bubbles:!0,composed:!0,detail:{source:\"primer-card-form-submit\"}});this.dispatchEvent(r)}}get buttonText(){return this._userAssignedProps.has(\"buttonText\")?this._internalButtonText:A(\"pay\",{id:\"pay\"})}set buttonText(t){let r=this.buttonText;t!==\"\"?(this._userAssignedProps.add(\"buttonText\"),this._internalButtonText=t):(this._userAssignedProps.delete(\"buttonText\"),this._internalButtonText=\"\"),this.requestUpdate(\"buttonText\",r)}render(){let t=this.clientOptions?.submitButton?.amountVisible?this.headlessInstance?.getUIOrderAmount():null,r=t?` ${t}`:h;return c` <primer-button
|
|
781
|
+
"default": "class extends v{constructor(){super(...arguments);this._userAssignedProps=new Set;this._internalButtonText=\"\";this.headlessInstance=null;this.clientOptions=null;this.sdkState=null;this.variant=\"primary\";this.disabled=!1;this.handleClick=t=>{if(t.preventDefault(),this.disabled)return;let r=new CustomEvent(\"primer-form-submit\",{bubbles:!0,composed:!0,detail:{source:\"primer-card-form-submit\"}});this.dispatchEvent(r)}}get buttonText(){return this._userAssignedProps.has(\"buttonText\")?this._internalButtonText:A(\"pay\",{id:\"pay\"})}set buttonText(t){let r=this.buttonText;t!==\"\"?(this._userAssignedProps.add(\"buttonText\"),this._internalButtonText=t):(this._userAssignedProps.delete(\"buttonText\"),this._internalButtonText=\"\"),this.requestUpdate(\"buttonText\",r)}render(){let t=this.clientOptions?.submitButton?.amountVisible?this.headlessInstance?.getUIOrderAmount():null,r=t?` ${t}`:h;return c` <primer-button type=\"submit\" variant=${this.variant} ?disabled=${this.disabled} @click=${this.handleClick} .loading=${!!this.sdkState?.isProcessing} data-submit > ${this.buttonText}${r} </primer-button> `}}"
|
|
767
782
|
},
|
|
768
783
|
{
|
|
769
784
|
"kind": "variable",
|
|
770
785
|
"name": "me",
|
|
771
|
-
"default": "class extends v{constructor(){super(...arguments);this.cardNetworks=null;this.headlessUtils=null;this.selectedCardNetwork=null;this.isDropdownOpen=!1;this.focusedNetworkIndex=0;this.isKeyboardNavigation=!1;this.buttonRef=qi();this.dropdownRef=qi();this.networkOptionRefs=[];this.handleClickOutside=t=>{this.isDropdownOpen&&(this.contains(t.target)||(this.isDropdownOpen=!1,this.isKeyboardNavigation=!1))};this.handleMouseMove=()=>{this.isKeyboardNavigation&&(this.isKeyboardNavigation=!1)};this.handleKeyDown=t=>{if(!(!(this.getSelectableNetworks().length>1)||!(this.contains(t.target)||this===t.target||this.isDropdownOpen&&t.target===document.body)))switch(this.isKeyboardNavigation=!0,t.key){case\"ArrowDown\":t.preventDefault(),this.isDropdownOpen?(this.focusedNetworkIndex=(this.focusedNetworkIndex+1)%this.getSelectableNetworks().length,this.focusNetworkOption()):(this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"ArrowUp\":t.preventDefault(),this.isDropdownOpen?(this.focusedNetworkIndex=(this.focusedNetworkIndex-1+this.getSelectableNetworks().length)%this.getSelectableNetworks().length,this.focusNetworkOption()):(this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"Enter\":case\" \":this.isDropdownOpen&&this.focusedNetworkIndex>=0?(t.preventDefault(),this.selectNetwork(t,this.getSelectableNetworks()[this.focusedNetworkIndex])):!this.isDropdownOpen&&this.buttonRef.value===document.activeElement&&(t.preventDefault(),this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"Escape\":this.isDropdownOpen&&(t.preventDefault(),this.isDropdownOpen=!1,this.buttonRef.value?.focus());break;case\"Tab\":this.isDropdownOpen&&(this.isDropdownOpen=!1);break}};this.handleDocumentKeyDown=t=>{this.isDropdownOpen&&this.handleKeyDown(t)}}toggleDropdown(t){this.isKeyboardNavigation=!1,t.stopPropagation(),this.getSelectableNetworks().length>1&&(this.isDropdownOpen=!this.isDropdownOpen,this.isDropdownOpen&&(this.focusedNetworkIndex=this.getSelectedNetworkIndex()))}getNetworkIconUrl(t){return this.headlessUtils?.getCardNetworkAsset(t.network)?.cardUrl}getSelectableNetworks(){return this.cardNetworks?.selectableCardNetworks||[]}getDetectedNetwork(){return this.selectedCardNetwork??(this.cardNetworks?.detectedCardNetwork||null)}getSelectedNetworkIndex(){let t=this.getDetectedNetwork();if(!t)return 0;let r=this.getSelectableNetworks().findIndex(o=>o.network===t.network);return r>=0?r:0}selectNetwork(t,r){t.stopPropagation(),this.selectedCardNetwork=r,this.isDropdownOpen=!1,this.buttonRef.value?.focus(),this.cardNetworks&&this.dispatchEvent(new CustomEvent(\"network-selected\",{detail:{network:r.network},bubbles:!0,composed:!0}))}focusNetworkOption(){requestAnimationFrame(()=>{this.networkOptionRefs[this.focusedNetworkIndex]&&this.networkOptionRefs[this.focusedNetworkIndex].focus()})}setNetworkOptionRef(t,r){this.networkOptionRefs[r]=t}connectedCallback(){super.connectedCallback(),setTimeout(()=>{document.addEventListener(\"click\",this.handleClickOutside),document.addEventListener(\"mousemove\",this.handleMouseMove),this.addEventListener(\"keydown\",this.handleKeyDown),document.addEventListener(\"keydown\",this.handleDocumentKeyDown)},0)}disconnectedCallback(){document.removeEventListener(\"click\",this.handleClickOutside),document.removeEventListener(\"keydown\",this.handleDocumentKeyDown),document.removeEventListener(\"mousemove\",this.handleMouseMove),this.removeEventListener(\"keydown\",this.handleKeyDown),super.disconnectedCallback()}render(){if(this.cardNetworks?.isLoading)return c`<primer-spinner size=\"small\" compact></primer-spinner>`;let t=this.getSelectableNetworks();if(!this.getDetectedNetwork()&&t.length===0)return c`<primer-icon name=\"payment-card\"></primer-icon>`;let r=this.getDetectedNetwork()||(t.length>0?t[0]:null);if(!r)return c`<primer-icon name=\"payment-card\" size=\"sm\"></primer-icon>`;let o=t.length>1;return c` <button ${
|
|
786
|
+
"default": "class extends v{constructor(){super(...arguments);this.cardNetworks=null;this.headlessUtils=null;this.selectedCardNetwork=null;this.isDropdownOpen=!1;this.focusedNetworkIndex=0;this.isKeyboardNavigation=!1;this.buttonRef=qi();this.dropdownRef=qi();this.networkOptionRefs=[];this.handleClickOutside=t=>{this.isDropdownOpen&&(this.contains(t.target)||(this.isDropdownOpen=!1,this.isKeyboardNavigation=!1))};this.handleMouseMove=()=>{this.isKeyboardNavigation&&(this.isKeyboardNavigation=!1)};this.handleKeyDown=t=>{if(!(!(this.getSelectableNetworks().length>1)||!(this.contains(t.target)||this===t.target||this.isDropdownOpen&&t.target===document.body)))switch(this.isKeyboardNavigation=!0,t.key){case\"ArrowDown\":t.preventDefault(),this.isDropdownOpen?(this.focusedNetworkIndex=(this.focusedNetworkIndex+1)%this.getSelectableNetworks().length,this.focusNetworkOption()):(this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"ArrowUp\":t.preventDefault(),this.isDropdownOpen?(this.focusedNetworkIndex=(this.focusedNetworkIndex-1+this.getSelectableNetworks().length)%this.getSelectableNetworks().length,this.focusNetworkOption()):(this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"Enter\":case\" \":this.isDropdownOpen&&this.focusedNetworkIndex>=0?(t.preventDefault(),this.selectNetwork(t,this.getSelectableNetworks()[this.focusedNetworkIndex])):!this.isDropdownOpen&&this.buttonRef.value===document.activeElement&&(t.preventDefault(),this.isDropdownOpen=!0,this.focusedNetworkIndex=this.getSelectedNetworkIndex());break;case\"Escape\":this.isDropdownOpen&&(t.preventDefault(),this.isDropdownOpen=!1,this.buttonRef.value?.focus());break;case\"Tab\":this.isDropdownOpen&&(this.isDropdownOpen=!1);break}};this.handleDocumentKeyDown=t=>{this.isDropdownOpen&&this.handleKeyDown(t)}}toggleDropdown(t){this.isKeyboardNavigation=!1,t.stopPropagation(),this.getSelectableNetworks().length>1&&(this.isDropdownOpen=!this.isDropdownOpen,this.isDropdownOpen&&(this.focusedNetworkIndex=this.getSelectedNetworkIndex()))}getNetworkIconUrl(t){return this.headlessUtils?.getCardNetworkAsset(t.network)?.cardUrl}getSelectableNetworks(){return this.cardNetworks?.selectableCardNetworks||[]}getDetectedNetwork(){return this.selectedCardNetwork??(this.cardNetworks?.detectedCardNetwork||null)}getSelectedNetworkIndex(){let t=this.getDetectedNetwork();if(!t)return 0;let r=this.getSelectableNetworks().findIndex(o=>o.network===t.network);return r>=0?r:0}selectNetwork(t,r){t.stopPropagation(),this.selectedCardNetwork=r,this.isDropdownOpen=!1,this.buttonRef.value?.focus(),this.cardNetworks&&this.dispatchEvent(new CustomEvent(\"network-selected\",{detail:{network:r.network},bubbles:!0,composed:!0}))}focusNetworkOption(){requestAnimationFrame(()=>{this.networkOptionRefs[this.focusedNetworkIndex]&&this.networkOptionRefs[this.focusedNetworkIndex].focus()})}setNetworkOptionRef(t,r){this.networkOptionRefs[r]=t}connectedCallback(){super.connectedCallback(),setTimeout(()=>{document.addEventListener(\"click\",this.handleClickOutside),document.addEventListener(\"mousemove\",this.handleMouseMove),this.addEventListener(\"keydown\",this.handleKeyDown),document.addEventListener(\"keydown\",this.handleDocumentKeyDown)},0)}disconnectedCallback(){document.removeEventListener(\"click\",this.handleClickOutside),document.removeEventListener(\"keydown\",this.handleDocumentKeyDown),document.removeEventListener(\"mousemove\",this.handleMouseMove),this.removeEventListener(\"keydown\",this.handleKeyDown),super.disconnectedCallback()}render(){if(this.cardNetworks?.isLoading)return c`<primer-spinner size=\"small\" compact></primer-spinner>`;let t=this.getSelectableNetworks();if(!this.getDetectedNetwork()&&t.length===0)return c`<primer-icon name=\"payment-card\"></primer-icon>`;let r=this.getDetectedNetwork()||(t.length>0?t[0]:null);if(!r)return c`<primer-icon name=\"payment-card\" size=\"sm\"></primer-icon>`;let o=t.length>1;return c` <button ${Xr(this.buttonRef)} class=\"network-selector\" @click=${this.toggleDropdown} @keydown=${n=>{(n.key===\" \"||n.key===\"Enter\")&&o&&(n.preventDefault(),this.isDropdownOpen=!this.isDropdownOpen,this.isDropdownOpen&&(this.focusedNetworkIndex=this.getSelectedNetworkIndex()))}} aria-label=${o?`Selected card network: ${r.displayName}. Click to change.`:`Card network: ${r.displayName}`} aria-expanded=${o?this.isDropdownOpen:h} aria-haspopup=${o?\"true\":h} aria-controls=${o?\"network-dropdown\":h} > <img class=\"network-icon\" src=${this.getNetworkIconUrl(r)} alt=${r.displayName} /> ${V(o,()=>c` <primer-icon class=\"caret ${this.isDropdownOpen?\"open\":\"\"}\" name=\"chevron-down\" ></primer-icon> `,()=>h)} </button> ${V(this.isDropdownOpen,()=>c` <div ${Xr(this.dropdownRef)} id=\"network-dropdown\" class=\"dropdown open\" role=\"listbox\" aria-label=\"Select card network\" > ${t.map((n,l)=>c` <div ${Xr(g=>this.setNetworkOptionRef(g,l))} class=\"network-option ${this.isKeyboardNavigation&&l===this.focusedNetworkIndex?\"focused\":\"\"}\" @click=${g=>this.selectNetwork(g,n)} @keydown=${g=>{(g.key===\"Enter\"||g.key===\" \")&&this.selectNetwork(g,n)}} role=\"option\" aria-selected=${n.network===r.network} tabindex=\"${l===this.focusedNetworkIndex?\"0\":\"-1\"}\" > <img class=\"network-option-icon\" src=${this.getNetworkIconUrl(n)} alt=${n.displayName} /> <span class=\"network-name\">${n.displayName}</span> ${V(n.network===r.network,()=>c` <primer-icon class=\"checkmark\" name=\"checkmark\" ></primer-icon> `,()=>h)} </div> `)} </div> `,()=>h)} `}}"
|
|
772
787
|
},
|
|
773
788
|
{
|
|
774
789
|
"kind": "variable",
|
|
775
790
|
"name": "ue",
|
|
776
|
-
"default": "class extends v{constructor(){super();this.vaultManagerContext=null;this.isEditMode=!1;this.deletePaymentMethodId=null;this.isDeleting=!1;this.errorMessage=\"\";this.animationDuration=300;new
|
|
791
|
+
"default": "class extends v{constructor(){super();this.vaultManagerContext=null;this.isEditMode=!1;this.deletePaymentMethodId=null;this.isDeleting=!1;this.errorMessage=\"\";this.animationDuration=300;new Tt(this,{defaultOptions:{keyframeOptions:{duration:Number(getComputedStyle(document.documentElement).getPropertyValue(\"--primer-animation-duration\").trim().replace(\"ms\",\"\")),easing:getComputedStyle(document.documentElement).getPropertyValue(\"--primer-animation-easing\").trim()}}})}getAnimationConfig(){return{keyframeOptions:{duration:this.animationDuration,easing:getComputedStyle(document.documentElement).getPropertyValue(\"--primer-animation-easing\").trim(),fill:\"both\"}}}handleToggleEditMode(t){this.isEditMode=t.detail,this.deletePaymentMethodId=null}handleDeletePaymentMethod(t){this.deletePaymentMethodId=t.detail}handleCancelDelete(){this.deletePaymentMethodId=null}async handleConfirmDelete(){if(!this.vaultManagerContext?.deleteVaultedPaymentMethod||!this.deletePaymentMethodId){this.errorMessage=A(\"something_went_wrong_error\",{id:\"something_went_wrong_error\"});return}try{this.isDeleting=!0,await this.vaultManagerContext.deleteVaultedPaymentMethod(this.deletePaymentMethodId),this.deletePaymentMethodId=null}catch(t){this.errorMessage=t instanceof Error?t.message:A(\"something_went_wrong_error\",{id:\"something_went_wrong_error\"})}finally{this.isDeleting=!1}}handlePaymentError(t){let r=t.detail?.error;this.errorMessage=r instanceof Error?r.message:A(\"payment_processing_error\",{id:\"payment_processing_error\"})}handleCloseError(){this.errorMessage=\"\"}getPaymentMethodName(t){if(!this.vaultManagerContext)return\"\";let r=this.vaultManagerContext.vaultedPaymentMethods.find(o=>o.id===t);if(!r)return\"\";try{return Jr(r).description||\"\"}catch{return\"\"}}renderLoadingOverlay(){return c` <div class=\"loading-overlay\" ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} > <primer-spinner size=\"medium\" color=\"var(--primer-color-loader)\" ></primer-spinner> </div> `}renderDeleteConfirmation(){if(!this.deletePaymentMethodId)return h;let t=this.getPaymentMethodName(this.deletePaymentMethodId);return c` <div class=\"delete-confirmation-container\"> <primer-vault-delete-confirmation .isDeleting=${this.isDeleting} .paymentMethodId=${this.deletePaymentMethodId} .paymentMethodName=${t} @confirm-delete=${this.handleConfirmDelete} @cancel-delete=${this.handleCancelDelete} ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-delete-confirmation> </div> `}renderPaymentMethodItem(t){return this.deletePaymentMethodId===t.id?h:c` <primer-vault-payment-method-item .paymentMethod=${t} .isEditMode=${this.isEditMode} @delete-payment-method=${this.handleDeletePaymentMethod} ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-payment-method-item> `}renderPaymentMethodList(){let t=this.vaultManagerContext?.vaultedPaymentMethods||[],r=!this.isEditMode&&t.length>0&&!this.deletePaymentMethodId;return c` <div class=\"payment-methods-list\"> ${t.map(o=>this.renderPaymentMethodItem(o))} ${V(r,()=>c` <div class=\"submit-button-container\"> <primer-vault-payment-submit class=\"submit-button\" @primer-vault-payment-error=${this.handlePaymentError} ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-payment-submit> </div> `,()=>h)} </div> `}render(){if(!this.vaultManagerContext?.enabled)return h;let t=this.vaultManagerContext.vaultedPaymentMethods.length>0,r=this.vaultManagerContext.isLoading,o=this.vaultManagerContext.isUpdating;return c` <div class=\"vault-manager ${o?\"is-updating\":\"\"}\"> <primer-vault-manager-header .isEditMode=${this.isEditMode} .hasPaymentMethods=${t} @toggle-edit-mode=${this.handleToggleEditMode} ></primer-vault-manager-header> ${V(this.errorMessage,()=>c` <primer-vault-error-message .errorMessage=${this.errorMessage} @close-error=${this.handleCloseError} ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-error-message> `,()=>h)} <div class=\"vault-manager-content\"> ${V(!r&&!t,()=>c` <div class=\"content-container\"> <primer-vault-empty-state ${je({...this.getAnimationConfig(),properties:[\"opacity\"],in:[{opacity:0},{opacity:1}],out:[{opacity:1},{opacity:0}]})} ></primer-vault-empty-state> </div> `,()=>h)} ${V(!r&&t,()=>c` <div class=\"content-container\"> ${V(this.deletePaymentMethodId,()=>this.renderDeleteConfirmation(),()=>this.renderPaymentMethodList())} </div> `,()=>h)} </div> ${V(o,()=>this.renderLoadingOverlay(),()=>h)} </div> `}}"
|
|
777
792
|
},
|
|
778
793
|
{
|
|
779
794
|
"kind": "variable",
|
|
780
795
|
"name": "ve",
|
|
781
|
-
"default": "class extends v{constructor(){super(...arguments);this.vaultManagerContext=null;this.vaultItemContext=null;this.headlessUtils=null;this.paymentMethod=null;this.isEditMode=!1;this._getAssetsTask=new D(this,{task:async([t,r,o])=>{if(!t||!r||!o)return L;let n=\"\";if(Mn(t))n=r.getCardNetworkAsset(t.paymentInstrumentData.network).cardUrl;else{let u=await r.getCDNAssets(t.paymentMethodType);u&&(n=u.assets?.icon?`${u.goatCdnUrl}/${u.assets.icon}`:\"\")}let l=o.cvvRecapture,g=
|
|
796
|
+
"default": "class extends v{constructor(){super(...arguments);this.vaultManagerContext=null;this.vaultItemContext=null;this.headlessUtils=null;this.paymentMethod=null;this.isEditMode=!1;this._getAssetsTask=new D(this,{task:async([t,r,o])=>{if(!t||!r||!o)return L;let n=\"\";if(Mn(t))n=r.getCardNetworkAsset(t.paymentInstrumentData.network).cardUrl;else{let u=await r.getCDNAssets(t.paymentMethodType);u&&(n=u.assets?.icon?`${u.goatCdnUrl}/${u.assets.icon}`:\"\")}let l=o.cvvRecapture,g=Jr(t);return{icon:n,shouldShowCVV:l,...g}},args:()=>[this.paymentMethod,this.headlessUtils,this.vaultManagerContext]})}isSelected(){if(!this.vaultManagerContext||!this.paymentMethod)return!1;let t=this.vaultItemContext?.selectedVaultedPaymentMethod;return!!t&&t.id===this.paymentMethod.id}handleClick(){this.isEditMode||!this.vaultManagerContext||!this.paymentMethod||(this.isSelected()?this.vaultItemContext?.setSelectedVaultedPaymentMethod(null):this.vaultItemContext?.setSelectedVaultedPaymentMethod(this.paymentMethod))}handleDeleteClick(t){t.stopPropagation(),this.dispatchEvent(new CustomEvent(\"delete-payment-method\",{detail:this.paymentMethod?.id,bubbles:!0,composed:!0}))}renderPaymentMethodContent(t){let r=t.icon?c`<img class=\"payment-method-icon\" src=${t.icon} alt=${t.description} />`:c` <div class=\"payment-method-icon payment-method-icon-generic\"> <primer-icon name=\"payment-card\" size=\"sm\"></primer-icon> </div> `;return c` ${r} <div class=\"payment-method-details\"> <div class=\"payment-method-description\">${t.description}</div> ${t.secondaryDescription?c`<div class=\"payment-method-secondary-description\"> ${t.secondaryDescription} </div>`:h} </div> `}render(){return this._getAssetsTask.render({error:()=>h,complete:t=>{let r=this.isSelected()?\"checked\":\"default\";return c` <div class=\"payment-method-wrapper\"> <div class=\"payment-method-container\"> <primer-button variant=\"secondary\" class=\"payment-method-button\" selectable ?disabled=${this.isEditMode} selectionState=${r} @click=${this.handleClick} > ${this.renderPaymentMethodContent(t)} </primer-button> ${this.isEditMode?c` <button class=\"delete-button\" @click=${this.handleDeleteClick} aria-label=${`${A(\"delete\",{id:\"delete\"})} ${t.description}`} > <primer-icon name=\"trash\" size=\"sm\"></primer-icon> </button> `:h} </div> ${V(t.shouldShowCVV&&this.isSelected()&&!this.isEditMode,()=>c`<primer-vault-cvv-input .paymentMethod=\"${this.paymentMethod}\" ></primer-vault-cvv-input>`,()=>h)} </div> `}})}}"
|
|
782
797
|
},
|
|
783
798
|
{
|
|
784
799
|
"kind": "variable",
|
|
@@ -787,7 +802,7 @@
|
|
|
787
802
|
},
|
|
788
803
|
{
|
|
789
804
|
"kind": "variable",
|
|
790
|
-
"name": "
|
|
805
|
+
"name": "Ce",
|
|
791
806
|
"default": "class extends v{constructor(){super(...arguments);this.isDeleting=!1;this.paymentMethodId=\"\";this.paymentMethodName=\"\";this.vaultManager=null}handleConfirmClick(){this.dispatchEvent(new CustomEvent(\"confirm-delete\",{bubbles:!0,composed:!0}))}handleCancelClick(){this.dispatchEvent(new CustomEvent(\"cancel-delete\",{bubbles:!0,composed:!0}))}render(){let t=this.paymentMethodName;return c` <div class=\"delete-confirmation\"> <div class=\"delete-message\"> <p class=\"delete-text\">${t}</p> </div> <div class=\"delete-actions\"> <button class=\"delete-confirm\" @click=${this.handleConfirmClick} ?disabled=${this.isDeleting} > ${this.isDeleting?A(\"deleting\",{id:\"deleting\"}):A(\"confirmVaultedPaymentMethodDeletion\",{id:\"confirmVaultedPaymentMethodDeletion\"})} </button> <button class=\"delete-cancel\" @click=${this.handleCancelClick} ?disabled=${this.isDeleting} > ${A(\"cancel\",{id:\"cancel\"})} </button> </div> </div> `}}"
|
|
792
807
|
},
|
|
793
808
|
{
|
|
@@ -808,7 +823,7 @@
|
|
|
808
823
|
{
|
|
809
824
|
"kind": "variable",
|
|
810
825
|
"name": "re",
|
|
811
|
-
"default": "class extends v{constructor(){super();this.vaultManagerFormContext=null;this.vaultManagerCvvContext=null;this.computedStyles=null;this.paymentMethod=null;this.cvvError=null;this.cvvInputIsDirty=!1;this.cvvInputIsBlurred=!1;this.cvvInput=null;this._setupCVVIframe=new D(this,{task:async([t,r])=>!t||!r||t.paymentMethodType!==\"PAYMENT_CARD\"||!t.paymentInstrumentData?.network||r.createCvvInput===null?L:{network:t.paymentInstrumentData.network,createCvvInput:r.createCvvInput},args:()=>[this.paymentMethod,this.vaultManagerFormContext]});this.cvvContainerId=`cvv-container-${Math.random().toString(36).substring(2,9)}`,new D(this,{task:async([t])=>{if(!t)return L;await this.updateComplete;let r=this.renderRoot.querySelector(`#${this.cvvContainerId}`);if(!r)return;let o=
|
|
826
|
+
"default": "class extends v{constructor(){super();this.vaultManagerFormContext=null;this.vaultManagerCvvContext=null;this.computedStyles=null;this.paymentMethod=null;this.cvvError=null;this.cvvInputIsDirty=!1;this.cvvInputIsBlurred=!1;this.cvvInput=null;this._setupCVVIframe=new D(this,{task:async([t,r])=>!t||!r||t.paymentMethodType!==\"PAYMENT_CARD\"||!t.paymentInstrumentData?.network||r.createCvvInput===null?L:{network:t.paymentInstrumentData.network,createCvvInput:r.createCvvInput},args:()=>[this.paymentMethod,this.vaultManagerFormContext]});this.cvvContainerId=`cvv-container-${Math.random().toString(36).substring(2,9)}`,new D(this,{task:async([t])=>{if(!t)return L;await this.updateComplete;let r=this.renderRoot.querySelector(`#${this.cvvContainerId}`);if(!r)return;let o=Gr(this.computedStyles),n=o?{input:{base:o}}:void 0,l={cardNetwork:t.network,container:r,name:\"cvv\",placeholder:\"123\",style:n};this.cvvInput=await t.createCvvInput?.(l)??null,this.cvvInput&&(this.cvvInput.focus(),this.cvvError=this.cvvInput.metadata.error||null,this.vaultManagerCvvContext?.setCvvInput(this.cvvInput),this.cvvInput.addListener(\"change\",()=>{this.onCvvInputChange()}),this.cvvInput.addListener(\"blur\",()=>{this.onBlur()}))},args:()=>[this._setupCVVIframe.value]})}disconnectedCallback(){super.disconnectedCallback(),this.cvvInput&&(this.cvvInput.remove(),this.cvvInput=null,this.cvvError=null,this.vaultManagerCvvContext?.setCvvInput(null))}onCvvInputChange(){!this.cvvInput||!this.vaultManagerCvvContext||(this.cvvInputIsDirty=!0,this.cvvError=this.cvvInput.metadata.error||null)}onBlur(){this.cvvInput&&(this.cvvInputIsBlurred=!0,this.cvvError=this.cvvInput.metadata.error||null)}render(){return this._setupCVVIframe.render({error:()=>h,complete:()=>c` <div class=\"cvv-input-container\"> <primer-input-wrapper .hasError=${!!this.cvvError&&(this.vaultManagerCvvContext?.formIsDirty||this.cvvInputIsDirty&&this.cvvInputIsBlurred)} > <primer-input-label slot=\"label\">CVV</primer-input-label> <div slot=\"input\" id=\"${this.cvvContainerId}\"></div> ${V(this.cvvError&&(this.vaultManagerCvvContext?.formIsDirty||this.cvvInputIsDirty&&this.cvvInputIsBlurred),()=>c` <primer-input-error slot=\"error\"> ${this.cvvError} </primer-input-error> `)} </primer-input-wrapper> </div> `})}}"
|
|
812
827
|
},
|
|
813
828
|
{
|
|
814
829
|
"kind": "variable",
|
|
@@ -872,7 +887,7 @@
|
|
|
872
887
|
"kind": "js",
|
|
873
888
|
"name": "CardForm",
|
|
874
889
|
"declaration": {
|
|
875
|
-
"name": "
|
|
890
|
+
"name": "Ee",
|
|
876
891
|
"module": "dist/primer-loader.js"
|
|
877
892
|
}
|
|
878
893
|
},
|
|
@@ -976,7 +991,7 @@
|
|
|
976
991
|
"kind": "js",
|
|
977
992
|
"name": "InitializedPayments",
|
|
978
993
|
"declaration": {
|
|
979
|
-
"name": "
|
|
994
|
+
"name": "Hr",
|
|
980
995
|
"module": "dist/primer-loader.js"
|
|
981
996
|
}
|
|
982
997
|
},
|
|
@@ -1008,7 +1023,7 @@
|
|
|
1008
1023
|
"kind": "js",
|
|
1009
1024
|
"name": "NativePayment",
|
|
1010
1025
|
"declaration": {
|
|
1011
|
-
"name": "
|
|
1026
|
+
"name": "ke",
|
|
1012
1027
|
"module": "dist/primer-loader.js"
|
|
1013
1028
|
}
|
|
1014
1029
|
},
|
|
@@ -1064,7 +1079,7 @@
|
|
|
1064
1079
|
"kind": "js",
|
|
1065
1080
|
"name": "PrimerIcon",
|
|
1066
1081
|
"declaration": {
|
|
1067
|
-
"name": "
|
|
1082
|
+
"name": "we",
|
|
1068
1083
|
"module": "dist/primer-loader.js"
|
|
1069
1084
|
}
|
|
1070
1085
|
},
|
|
@@ -1104,7 +1119,7 @@
|
|
|
1104
1119
|
"kind": "js",
|
|
1105
1120
|
"name": "Spinner",
|
|
1106
1121
|
"declaration": {
|
|
1107
|
-
"name": "
|
|
1122
|
+
"name": "Pe",
|
|
1108
1123
|
"module": "dist/primer-loader.js"
|
|
1109
1124
|
}
|
|
1110
1125
|
},
|
|
@@ -1120,7 +1135,7 @@
|
|
|
1120
1135
|
"kind": "js",
|
|
1121
1136
|
"name": "VaultDeleteConfirmation",
|
|
1122
1137
|
"declaration": {
|
|
1123
|
-
"name": "
|
|
1138
|
+
"name": "Ce",
|
|
1124
1139
|
"module": "dist/primer-loader.js"
|
|
1125
1140
|
}
|
|
1126
1141
|
},
|
|
@@ -1216,182 +1231,458 @@
|
|
|
1216
1231
|
},
|
|
1217
1232
|
{
|
|
1218
1233
|
"kind": "javascript-module",
|
|
1219
|
-
"path": "
|
|
1234
|
+
"path": "dist/primer-react-wrappers.js",
|
|
1220
1235
|
"declarations": [
|
|
1221
1236
|
{
|
|
1222
1237
|
"kind": "variable",
|
|
1223
|
-
"name": "
|
|
1224
|
-
"default": "css` * { box-sizing: border-box; } `"
|
|
1238
|
+
"name": "i"
|
|
1225
1239
|
},
|
|
1226
1240
|
{
|
|
1227
1241
|
"kind": "variable",
|
|
1228
|
-
"name": "
|
|
1229
|
-
|
|
1242
|
+
"name": "t"
|
|
1243
|
+
},
|
|
1244
|
+
{
|
|
1245
|
+
"kind": "variable",
|
|
1246
|
+
"name": "Eh"
|
|
1247
|
+
},
|
|
1248
|
+
{
|
|
1249
|
+
"kind": "variable",
|
|
1250
|
+
"name": "Ih"
|
|
1251
|
+
},
|
|
1252
|
+
{
|
|
1253
|
+
"kind": "variable",
|
|
1254
|
+
"name": "eu"
|
|
1255
|
+
},
|
|
1256
|
+
{
|
|
1257
|
+
"kind": "variable",
|
|
1258
|
+
"name": "Cu"
|
|
1259
|
+
},
|
|
1260
|
+
{
|
|
1261
|
+
"kind": "variable",
|
|
1262
|
+
"name": "Wu"
|
|
1263
|
+
},
|
|
1264
|
+
{
|
|
1265
|
+
"kind": "variable",
|
|
1266
|
+
"name": "tf"
|
|
1267
|
+
},
|
|
1268
|
+
{
|
|
1269
|
+
"kind": "variable",
|
|
1270
|
+
"name": "uf"
|
|
1271
|
+
},
|
|
1272
|
+
{
|
|
1273
|
+
"kind": "variable",
|
|
1274
|
+
"name": "Mf"
|
|
1275
|
+
},
|
|
1276
|
+
{
|
|
1277
|
+
"kind": "variable",
|
|
1278
|
+
"name": "Vf"
|
|
1279
|
+
},
|
|
1280
|
+
{
|
|
1281
|
+
"kind": "variable",
|
|
1282
|
+
"name": "Xf"
|
|
1283
|
+
},
|
|
1284
|
+
{
|
|
1285
|
+
"kind": "variable",
|
|
1286
|
+
"name": "dg"
|
|
1287
|
+
},
|
|
1288
|
+
{
|
|
1289
|
+
"kind": "variable",
|
|
1290
|
+
"name": "Cg"
|
|
1291
|
+
},
|
|
1292
|
+
{
|
|
1293
|
+
"kind": "variable",
|
|
1294
|
+
"name": "Gg"
|
|
1295
|
+
},
|
|
1296
|
+
{
|
|
1297
|
+
"kind": "variable",
|
|
1298
|
+
"name": "uy"
|
|
1299
|
+
},
|
|
1300
|
+
{
|
|
1301
|
+
"kind": "variable",
|
|
1302
|
+
"name": "$y"
|
|
1303
|
+
},
|
|
1304
|
+
{
|
|
1305
|
+
"kind": "variable",
|
|
1306
|
+
"name": "gv"
|
|
1307
|
+
},
|
|
1308
|
+
{
|
|
1309
|
+
"kind": "variable",
|
|
1310
|
+
"name": "eb"
|
|
1311
|
+
},
|
|
1312
|
+
{
|
|
1313
|
+
"kind": "variable",
|
|
1314
|
+
"name": "yb"
|
|
1315
|
+
},
|
|
1316
|
+
{
|
|
1317
|
+
"kind": "variable",
|
|
1318
|
+
"name": "Lb"
|
|
1319
|
+
},
|
|
1320
|
+
{
|
|
1321
|
+
"kind": "variable",
|
|
1322
|
+
"name": "Jb"
|
|
1323
|
+
},
|
|
1324
|
+
{
|
|
1325
|
+
"kind": "variable",
|
|
1326
|
+
"name": "AE"
|
|
1327
|
+
},
|
|
1328
|
+
{
|
|
1329
|
+
"kind": "variable",
|
|
1330
|
+
"name": "YE"
|
|
1331
|
+
},
|
|
1332
|
+
{
|
|
1333
|
+
"kind": "variable",
|
|
1334
|
+
"name": "mC"
|
|
1335
|
+
},
|
|
1336
|
+
{
|
|
1337
|
+
"kind": "variable",
|
|
1338
|
+
"name": "kC"
|
|
1339
|
+
},
|
|
1340
|
+
{
|
|
1341
|
+
"kind": "variable",
|
|
1342
|
+
"name": "KC"
|
|
1343
|
+
},
|
|
1344
|
+
{
|
|
1345
|
+
"kind": "variable",
|
|
1346
|
+
"name": "tA"
|
|
1347
|
+
},
|
|
1348
|
+
{
|
|
1349
|
+
"kind": "variable",
|
|
1350
|
+
"name": "mA"
|
|
1351
|
+
},
|
|
1352
|
+
{
|
|
1353
|
+
"kind": "variable",
|
|
1354
|
+
"name": "IA"
|
|
1355
|
+
},
|
|
1356
|
+
{
|
|
1357
|
+
"kind": "variable",
|
|
1358
|
+
"name": "e_"
|
|
1359
|
+
},
|
|
1360
|
+
{
|
|
1361
|
+
"kind": "variable",
|
|
1362
|
+
"name": "A_"
|
|
1363
|
+
},
|
|
1364
|
+
{
|
|
1365
|
+
"kind": "variable",
|
|
1366
|
+
"name": "P_"
|
|
1367
|
+
},
|
|
1368
|
+
{
|
|
1369
|
+
"kind": "variable",
|
|
1370
|
+
"name": "Kx"
|
|
1230
1371
|
}
|
|
1231
1372
|
],
|
|
1232
1373
|
"exports": [
|
|
1233
1374
|
{
|
|
1234
|
-
"kind": "
|
|
1235
|
-
"name": "
|
|
1375
|
+
"kind": "custom-element-definition",
|
|
1376
|
+
"name": "i",
|
|
1236
1377
|
"declaration": {
|
|
1237
|
-
"name": "
|
|
1238
|
-
"module": "
|
|
1378
|
+
"name": "t",
|
|
1379
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1380
|
+
}
|
|
1381
|
+
},
|
|
1382
|
+
{
|
|
1383
|
+
"kind": "custom-element-definition",
|
|
1384
|
+
"name": "i",
|
|
1385
|
+
"declaration": {
|
|
1386
|
+
"name": "t",
|
|
1387
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1239
1388
|
}
|
|
1240
1389
|
},
|
|
1241
1390
|
{
|
|
1242
1391
|
"kind": "js",
|
|
1243
|
-
"name": "
|
|
1392
|
+
"name": "AchPayment",
|
|
1244
1393
|
"declaration": {
|
|
1245
|
-
"name": "
|
|
1246
|
-
"module": "
|
|
1394
|
+
"name": "Gg",
|
|
1395
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1247
1396
|
}
|
|
1248
|
-
}
|
|
1249
|
-
]
|
|
1250
|
-
},
|
|
1251
|
-
{
|
|
1252
|
-
"kind": "javascript-module",
|
|
1253
|
-
"path": "src/components.ts",
|
|
1254
|
-
"declarations": [],
|
|
1255
|
-
"exports": [
|
|
1397
|
+
},
|
|
1256
1398
|
{
|
|
1257
1399
|
"kind": "js",
|
|
1258
|
-
"name": "
|
|
1400
|
+
"name": "Button",
|
|
1259
1401
|
"declaration": {
|
|
1260
|
-
"name": "
|
|
1261
|
-
"
|
|
1402
|
+
"name": "P_",
|
|
1403
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1262
1404
|
}
|
|
1263
1405
|
},
|
|
1264
1406
|
{
|
|
1265
1407
|
"kind": "js",
|
|
1266
|
-
"name": "
|
|
1408
|
+
"name": "CardForm",
|
|
1267
1409
|
"declaration": {
|
|
1268
|
-
"name": "
|
|
1269
|
-
"
|
|
1410
|
+
"name": "uy",
|
|
1411
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1270
1412
|
}
|
|
1271
1413
|
},
|
|
1272
1414
|
{
|
|
1273
1415
|
"kind": "js",
|
|
1274
|
-
"name": "
|
|
1416
|
+
"name": "CardFormSubmit",
|
|
1275
1417
|
"declaration": {
|
|
1276
|
-
"name": "
|
|
1277
|
-
"
|
|
1418
|
+
"name": "$y",
|
|
1419
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1278
1420
|
}
|
|
1279
1421
|
},
|
|
1280
1422
|
{
|
|
1281
1423
|
"kind": "js",
|
|
1282
|
-
"name": "
|
|
1424
|
+
"name": "CardNetworkSelector",
|
|
1283
1425
|
"declaration": {
|
|
1284
|
-
"name": "
|
|
1285
|
-
"
|
|
1426
|
+
"name": "gv",
|
|
1427
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1286
1428
|
}
|
|
1287
1429
|
},
|
|
1288
1430
|
{
|
|
1289
1431
|
"kind": "js",
|
|
1290
|
-
"name": "
|
|
1432
|
+
"name": "CheckoutState",
|
|
1291
1433
|
"declaration": {
|
|
1292
|
-
"name": "
|
|
1293
|
-
"module": "
|
|
1434
|
+
"name": "Ih",
|
|
1435
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1294
1436
|
}
|
|
1295
1437
|
},
|
|
1296
1438
|
{
|
|
1297
1439
|
"kind": "js",
|
|
1298
|
-
"name": "
|
|
1440
|
+
"name": "Collapsable",
|
|
1299
1441
|
"declaration": {
|
|
1300
|
-
"name": "
|
|
1301
|
-
"module": "
|
|
1442
|
+
"name": "eu",
|
|
1443
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1302
1444
|
}
|
|
1303
1445
|
},
|
|
1304
1446
|
{
|
|
1305
1447
|
"kind": "js",
|
|
1306
|
-
"name": "
|
|
1448
|
+
"name": "Dialog",
|
|
1307
1449
|
"declaration": {
|
|
1308
|
-
"name": "
|
|
1309
|
-
"module": "
|
|
1450
|
+
"name": "Cu",
|
|
1451
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1310
1452
|
}
|
|
1311
1453
|
},
|
|
1312
1454
|
{
|
|
1313
1455
|
"kind": "js",
|
|
1314
|
-
"name": "
|
|
1456
|
+
"name": "DynamicPayment",
|
|
1315
1457
|
"declaration": {
|
|
1316
|
-
"name": "
|
|
1317
|
-
"module": "
|
|
1458
|
+
"name": "AE",
|
|
1459
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1318
1460
|
}
|
|
1319
1461
|
},
|
|
1320
1462
|
{
|
|
1321
1463
|
"kind": "js",
|
|
1322
|
-
"name": "
|
|
1464
|
+
"name": "ErrorMessage",
|
|
1323
1465
|
"declaration": {
|
|
1324
|
-
"name": "
|
|
1325
|
-
"module": "
|
|
1466
|
+
"name": "Wu",
|
|
1467
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1326
1468
|
}
|
|
1327
1469
|
},
|
|
1328
1470
|
{
|
|
1329
1471
|
"kind": "js",
|
|
1330
|
-
"name": "
|
|
1472
|
+
"name": "ErrorMessageContainer",
|
|
1331
1473
|
"declaration": {
|
|
1332
|
-
"name": "
|
|
1333
|
-
"module": "
|
|
1474
|
+
"name": "YE",
|
|
1475
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1334
1476
|
}
|
|
1335
|
-
}
|
|
1336
|
-
]
|
|
1337
|
-
},
|
|
1338
|
-
{
|
|
1339
|
-
"kind": "javascript-module",
|
|
1340
|
-
"path": "src/consts.ts",
|
|
1341
|
-
"declarations": [
|
|
1477
|
+
},
|
|
1342
1478
|
{
|
|
1343
|
-
"kind": "
|
|
1344
|
-
"name": "
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1479
|
+
"kind": "js",
|
|
1480
|
+
"name": "Icon",
|
|
1481
|
+
"declaration": {
|
|
1482
|
+
"name": "tf",
|
|
1483
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1484
|
+
}
|
|
1485
|
+
},
|
|
1348
1486
|
{
|
|
1349
1487
|
"kind": "js",
|
|
1350
|
-
"name": "
|
|
1488
|
+
"name": "Input",
|
|
1351
1489
|
"declaration": {
|
|
1352
|
-
"name": "
|
|
1353
|
-
"module": "
|
|
1490
|
+
"name": "uf",
|
|
1491
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1354
1492
|
}
|
|
1355
|
-
}
|
|
1356
|
-
]
|
|
1357
|
-
},
|
|
1358
|
-
{
|
|
1359
|
-
"kind": "javascript-module",
|
|
1360
|
-
"path": "src/css-loader-inline.ts",
|
|
1361
|
-
"declarations": [
|
|
1493
|
+
},
|
|
1362
1494
|
{
|
|
1363
|
-
"kind": "
|
|
1364
|
-
"name": "
|
|
1365
|
-
"
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1495
|
+
"kind": "js",
|
|
1496
|
+
"name": "InputCardExpiry",
|
|
1497
|
+
"declaration": {
|
|
1498
|
+
"name": "yb",
|
|
1499
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1500
|
+
}
|
|
1501
|
+
},
|
|
1370
1502
|
{
|
|
1371
1503
|
"kind": "js",
|
|
1372
|
-
"name": "
|
|
1504
|
+
"name": "InputCardHolderName",
|
|
1373
1505
|
"declaration": {
|
|
1374
|
-
"name": "
|
|
1375
|
-
"module": "
|
|
1506
|
+
"name": "eb",
|
|
1507
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1376
1508
|
}
|
|
1377
|
-
}
|
|
1509
|
+
},
|
|
1510
|
+
{
|
|
1511
|
+
"kind": "js",
|
|
1512
|
+
"name": "InputCardNumber",
|
|
1513
|
+
"declaration": {
|
|
1514
|
+
"name": "Jb",
|
|
1515
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1516
|
+
}
|
|
1517
|
+
},
|
|
1518
|
+
{
|
|
1519
|
+
"kind": "js",
|
|
1520
|
+
"name": "InputCvv",
|
|
1521
|
+
"declaration": {
|
|
1522
|
+
"name": "Lb",
|
|
1523
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1524
|
+
}
|
|
1525
|
+
},
|
|
1526
|
+
{
|
|
1527
|
+
"kind": "js",
|
|
1528
|
+
"name": "InputError",
|
|
1529
|
+
"declaration": {
|
|
1530
|
+
"name": "Mf",
|
|
1531
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1532
|
+
}
|
|
1533
|
+
},
|
|
1534
|
+
{
|
|
1535
|
+
"kind": "js",
|
|
1536
|
+
"name": "InputLabel",
|
|
1537
|
+
"declaration": {
|
|
1538
|
+
"name": "Vf",
|
|
1539
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1540
|
+
}
|
|
1541
|
+
},
|
|
1542
|
+
{
|
|
1543
|
+
"kind": "js",
|
|
1544
|
+
"name": "InputWrapper",
|
|
1545
|
+
"declaration": {
|
|
1546
|
+
"name": "Xf",
|
|
1547
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1548
|
+
}
|
|
1549
|
+
},
|
|
1550
|
+
{
|
|
1551
|
+
"kind": "js",
|
|
1552
|
+
"name": "Klarna",
|
|
1553
|
+
"declaration": {
|
|
1554
|
+
"name": "mC",
|
|
1555
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1556
|
+
}
|
|
1557
|
+
},
|
|
1558
|
+
{
|
|
1559
|
+
"kind": "js",
|
|
1560
|
+
"name": "NativePayment",
|
|
1561
|
+
"declaration": {
|
|
1562
|
+
"name": "kC",
|
|
1563
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1564
|
+
}
|
|
1565
|
+
},
|
|
1566
|
+
{
|
|
1567
|
+
"kind": "js",
|
|
1568
|
+
"name": "PaymentMethod",
|
|
1569
|
+
"declaration": {
|
|
1570
|
+
"name": "KC",
|
|
1571
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1572
|
+
}
|
|
1573
|
+
},
|
|
1574
|
+
{
|
|
1575
|
+
"kind": "js",
|
|
1576
|
+
"name": "Portal",
|
|
1577
|
+
"declaration": {
|
|
1578
|
+
"name": "dg",
|
|
1579
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1580
|
+
}
|
|
1581
|
+
},
|
|
1582
|
+
{
|
|
1583
|
+
"kind": "js",
|
|
1584
|
+
"name": "PrimerCheckout",
|
|
1585
|
+
"declaration": {
|
|
1586
|
+
"name": "Eh",
|
|
1587
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1588
|
+
}
|
|
1589
|
+
},
|
|
1590
|
+
{
|
|
1591
|
+
"kind": "js",
|
|
1592
|
+
"name": "PrimerCheckoutComplete",
|
|
1593
|
+
"declaration": {
|
|
1594
|
+
"name": "tA",
|
|
1595
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1596
|
+
}
|
|
1597
|
+
},
|
|
1598
|
+
{
|
|
1599
|
+
"kind": "js",
|
|
1600
|
+
"name": "PrimerCheckoutError",
|
|
1601
|
+
"declaration": {
|
|
1602
|
+
"name": "mA",
|
|
1603
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1604
|
+
}
|
|
1605
|
+
},
|
|
1606
|
+
{
|
|
1607
|
+
"kind": "js",
|
|
1608
|
+
"name": "PrimerMain",
|
|
1609
|
+
"declaration": {
|
|
1610
|
+
"name": "IA",
|
|
1611
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1612
|
+
}
|
|
1613
|
+
},
|
|
1614
|
+
{
|
|
1615
|
+
"kind": "js",
|
|
1616
|
+
"name": "RedirectPayment",
|
|
1617
|
+
"declaration": {
|
|
1618
|
+
"name": "e_",
|
|
1619
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1620
|
+
}
|
|
1621
|
+
},
|
|
1622
|
+
{
|
|
1623
|
+
"kind": "js",
|
|
1624
|
+
"name": "ShowOtherPayments",
|
|
1625
|
+
"declaration": {
|
|
1626
|
+
"name": "A_",
|
|
1627
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1628
|
+
}
|
|
1629
|
+
},
|
|
1630
|
+
{
|
|
1631
|
+
"kind": "js",
|
|
1632
|
+
"name": "Spinner",
|
|
1633
|
+
"declaration": {
|
|
1634
|
+
"name": "Cg",
|
|
1635
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1636
|
+
}
|
|
1637
|
+
},
|
|
1638
|
+
{
|
|
1639
|
+
"kind": "js",
|
|
1640
|
+
"name": "VaultManager",
|
|
1641
|
+
"declaration": {
|
|
1642
|
+
"name": "Kx",
|
|
1643
|
+
"module": "dist/primer-react-wrappers.js"
|
|
1644
|
+
}
|
|
1645
|
+
}
|
|
1378
1646
|
]
|
|
1379
1647
|
},
|
|
1380
1648
|
{
|
|
1381
1649
|
"kind": "javascript-module",
|
|
1382
|
-
"path": "src/
|
|
1650
|
+
"path": "src/base.styles.ts",
|
|
1383
1651
|
"declarations": [
|
|
1384
1652
|
{
|
|
1385
|
-
"kind": "
|
|
1386
|
-
"name": "
|
|
1387
|
-
"
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
"
|
|
1653
|
+
"kind": "variable",
|
|
1654
|
+
"name": "base",
|
|
1655
|
+
"default": "css` * { box-sizing: border-box; } `"
|
|
1656
|
+
},
|
|
1657
|
+
{
|
|
1658
|
+
"kind": "variable",
|
|
1659
|
+
"name": "primerCheckout",
|
|
1660
|
+
"default": "css` :host { display: block; isolation: isolate; position: relative; width: 100%; //Keep the CSS loader in the same position - check css-loader-inline.ts min-height: 64px; } `"
|
|
1393
1661
|
}
|
|
1394
1662
|
],
|
|
1663
|
+
"exports": [
|
|
1664
|
+
{
|
|
1665
|
+
"kind": "js",
|
|
1666
|
+
"name": "base",
|
|
1667
|
+
"declaration": {
|
|
1668
|
+
"name": "base",
|
|
1669
|
+
"module": "src/base.styles.ts"
|
|
1670
|
+
}
|
|
1671
|
+
},
|
|
1672
|
+
{
|
|
1673
|
+
"kind": "js",
|
|
1674
|
+
"name": "primerCheckout",
|
|
1675
|
+
"declaration": {
|
|
1676
|
+
"name": "primerCheckout",
|
|
1677
|
+
"module": "src/base.styles.ts"
|
|
1678
|
+
}
|
|
1679
|
+
}
|
|
1680
|
+
]
|
|
1681
|
+
},
|
|
1682
|
+
{
|
|
1683
|
+
"kind": "javascript-module",
|
|
1684
|
+
"path": "src/components.ts",
|
|
1685
|
+
"declarations": [],
|
|
1395
1686
|
"exports": [
|
|
1396
1687
|
{
|
|
1397
1688
|
"kind": "js",
|
|
@@ -1438,7 +1729,7 @@
|
|
|
1438
1729
|
"name": "PrimerCheckoutComponent",
|
|
1439
1730
|
"declaration": {
|
|
1440
1731
|
"name": "PrimerCheckoutComponent",
|
|
1441
|
-
"module": "src/
|
|
1732
|
+
"module": "src/components.ts"
|
|
1442
1733
|
}
|
|
1443
1734
|
},
|
|
1444
1735
|
{
|
|
@@ -1446,7 +1737,7 @@
|
|
|
1446
1737
|
"name": "injectLoaderStyles",
|
|
1447
1738
|
"declaration": {
|
|
1448
1739
|
"name": "injectLoaderStyles",
|
|
1449
|
-
"module": "src/
|
|
1740
|
+
"module": "src/components.ts"
|
|
1450
1741
|
}
|
|
1451
1742
|
},
|
|
1452
1743
|
{
|
|
@@ -1454,7 +1745,7 @@
|
|
|
1454
1745
|
"name": "injectThemeStyles",
|
|
1455
1746
|
"declaration": {
|
|
1456
1747
|
"name": "injectThemeStyles",
|
|
1457
|
-
"module": "src/
|
|
1748
|
+
"module": "src/components.ts"
|
|
1458
1749
|
}
|
|
1459
1750
|
},
|
|
1460
1751
|
{
|
|
@@ -1462,7 +1753,7 @@
|
|
|
1462
1753
|
"name": "injectLightTheme",
|
|
1463
1754
|
"declaration": {
|
|
1464
1755
|
"name": "injectLightTheme",
|
|
1465
|
-
"module": "src/
|
|
1756
|
+
"module": "src/components.ts"
|
|
1466
1757
|
}
|
|
1467
1758
|
},
|
|
1468
1759
|
{
|
|
@@ -1470,35 +1761,175 @@
|
|
|
1470
1761
|
"name": "injectDarkTheme",
|
|
1471
1762
|
"declaration": {
|
|
1472
1763
|
"name": "injectDarkTheme",
|
|
1473
|
-
"module": "src/
|
|
1764
|
+
"module": "src/components.ts"
|
|
1474
1765
|
}
|
|
1475
|
-
}
|
|
1766
|
+
}
|
|
1767
|
+
]
|
|
1768
|
+
},
|
|
1769
|
+
{
|
|
1770
|
+
"kind": "javascript-module",
|
|
1771
|
+
"path": "src/consts.ts",
|
|
1772
|
+
"declarations": [
|
|
1773
|
+
{
|
|
1774
|
+
"kind": "variable",
|
|
1775
|
+
"name": "legacySdkCdnUrl"
|
|
1776
|
+
}
|
|
1777
|
+
],
|
|
1778
|
+
"exports": [
|
|
1476
1779
|
{
|
|
1477
1780
|
"kind": "js",
|
|
1478
|
-
"name": "
|
|
1781
|
+
"name": "legacySdkCdnUrl",
|
|
1479
1782
|
"declaration": {
|
|
1480
|
-
"name": "
|
|
1481
|
-
"module": "src/
|
|
1783
|
+
"name": "legacySdkCdnUrl",
|
|
1784
|
+
"module": "src/consts.ts"
|
|
1482
1785
|
}
|
|
1483
1786
|
}
|
|
1484
1787
|
]
|
|
1485
1788
|
},
|
|
1486
1789
|
{
|
|
1487
1790
|
"kind": "javascript-module",
|
|
1488
|
-
"path": "src/
|
|
1791
|
+
"path": "src/css-loader-inline.ts",
|
|
1489
1792
|
"declarations": [
|
|
1490
1793
|
{
|
|
1491
|
-
"kind": "
|
|
1492
|
-
"
|
|
1794
|
+
"kind": "variable",
|
|
1795
|
+
"name": "cssLoaderStyles",
|
|
1796
|
+
"default": "` @keyframes primer-css-spinner-rotate { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } } primer-checkout:has(:not(:defined)) > * { visibility: hidden; } primer-checkout:not([js-initialized]) { display: block; position: relative; width: 100%; min-height: 64px; } primer-checkout:not([js-initialized]):not([loader-disabled])::after { content: \"\"; display: block; box-sizing: border-box; position: absolute; inset: 0; margin: auto; width: var(--primer-size-xlarge); height: var(--primer-size-xlarge); border-radius: 50%; border: 3px solid #f5f5f5; border-top-color: var(--primer-color-loader); animation: primer-css-spinner-rotate 1.2s linear infinite; z-index: 9999; } `",
|
|
1797
|
+
"description": "This module exports the CSS loader styles as a string for inline injection.\nThese styles are injected into the page before any JavaScript loads,\nensuring the loading indicator appears immediately."
|
|
1798
|
+
}
|
|
1799
|
+
],
|
|
1800
|
+
"exports": [
|
|
1801
|
+
{
|
|
1802
|
+
"kind": "js",
|
|
1803
|
+
"name": "cssLoaderStyles",
|
|
1804
|
+
"declaration": {
|
|
1805
|
+
"name": "cssLoaderStyles",
|
|
1806
|
+
"module": "src/css-loader-inline.ts"
|
|
1807
|
+
}
|
|
1808
|
+
}
|
|
1809
|
+
]
|
|
1810
|
+
},
|
|
1811
|
+
{
|
|
1812
|
+
"kind": "javascript-module",
|
|
1813
|
+
"path": "src/loader.ts",
|
|
1814
|
+
"declarations": [
|
|
1815
|
+
{
|
|
1816
|
+
"kind": "function",
|
|
1817
|
+
"name": "loadPrimer",
|
|
1818
|
+
"return": {
|
|
1819
|
+
"type": {
|
|
1820
|
+
"text": "Promise<void>"
|
|
1821
|
+
}
|
|
1822
|
+
},
|
|
1823
|
+
"description": "Main function to load the Primer SDK with all required dependencies and styles"
|
|
1824
|
+
}
|
|
1825
|
+
],
|
|
1826
|
+
"exports": [
|
|
1827
|
+
{
|
|
1828
|
+
"kind": "js",
|
|
1829
|
+
"name": "*",
|
|
1830
|
+
"declaration": {
|
|
1831
|
+
"name": "*",
|
|
1832
|
+
"package": "./contexts/types"
|
|
1833
|
+
}
|
|
1834
|
+
},
|
|
1835
|
+
{
|
|
1836
|
+
"kind": "js",
|
|
1837
|
+
"name": "*",
|
|
1838
|
+
"declaration": {
|
|
1839
|
+
"name": "*",
|
|
1840
|
+
"package": "./contexts/payments-objects"
|
|
1841
|
+
}
|
|
1842
|
+
},
|
|
1843
|
+
{
|
|
1844
|
+
"kind": "js",
|
|
1845
|
+
"name": "*",
|
|
1846
|
+
"declaration": {
|
|
1847
|
+
"name": "*",
|
|
1848
|
+
"package": "./atoms"
|
|
1849
|
+
}
|
|
1850
|
+
},
|
|
1851
|
+
{
|
|
1852
|
+
"kind": "js",
|
|
1853
|
+
"name": "*",
|
|
1854
|
+
"declaration": {
|
|
1855
|
+
"name": "*",
|
|
1856
|
+
"package": "./containers"
|
|
1857
|
+
}
|
|
1858
|
+
},
|
|
1859
|
+
{
|
|
1860
|
+
"kind": "js",
|
|
1861
|
+
"name": "PrimerCheckoutOptions",
|
|
1862
|
+
"declaration": {
|
|
1863
|
+
"name": "PrimerCheckoutOptions",
|
|
1864
|
+
"module": "./types/sdk"
|
|
1865
|
+
}
|
|
1866
|
+
},
|
|
1867
|
+
{
|
|
1868
|
+
"kind": "js",
|
|
1493
1869
|
"name": "PrimerCheckoutComponent",
|
|
1494
|
-
"
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1870
|
+
"declaration": {
|
|
1871
|
+
"name": "PrimerCheckoutComponent",
|
|
1872
|
+
"module": "src/loader.ts"
|
|
1873
|
+
}
|
|
1874
|
+
},
|
|
1875
|
+
{
|
|
1876
|
+
"kind": "js",
|
|
1877
|
+
"name": "injectLoaderStyles",
|
|
1878
|
+
"declaration": {
|
|
1879
|
+
"name": "injectLoaderStyles",
|
|
1880
|
+
"module": "src/loader.ts"
|
|
1881
|
+
}
|
|
1882
|
+
},
|
|
1883
|
+
{
|
|
1884
|
+
"kind": "js",
|
|
1885
|
+
"name": "injectThemeStyles",
|
|
1886
|
+
"declaration": {
|
|
1887
|
+
"name": "injectThemeStyles",
|
|
1888
|
+
"module": "src/loader.ts"
|
|
1889
|
+
}
|
|
1890
|
+
},
|
|
1891
|
+
{
|
|
1892
|
+
"kind": "js",
|
|
1893
|
+
"name": "injectLightTheme",
|
|
1894
|
+
"declaration": {
|
|
1895
|
+
"name": "injectLightTheme",
|
|
1896
|
+
"module": "src/loader.ts"
|
|
1897
|
+
}
|
|
1898
|
+
},
|
|
1899
|
+
{
|
|
1900
|
+
"kind": "js",
|
|
1901
|
+
"name": "injectDarkTheme",
|
|
1902
|
+
"declaration": {
|
|
1903
|
+
"name": "injectDarkTheme",
|
|
1904
|
+
"module": "src/loader.ts"
|
|
1905
|
+
}
|
|
1906
|
+
},
|
|
1907
|
+
{
|
|
1908
|
+
"kind": "js",
|
|
1909
|
+
"name": "loadPrimer",
|
|
1910
|
+
"declaration": {
|
|
1911
|
+
"name": "loadPrimer",
|
|
1912
|
+
"module": "src/loader.ts"
|
|
1913
|
+
}
|
|
1914
|
+
}
|
|
1915
|
+
]
|
|
1916
|
+
},
|
|
1917
|
+
{
|
|
1918
|
+
"kind": "javascript-module",
|
|
1919
|
+
"path": "src/primer-checkout.ts",
|
|
1920
|
+
"declarations": [
|
|
1921
|
+
{
|
|
1922
|
+
"kind": "class",
|
|
1923
|
+
"description": "PrimerCheckoutComponent implements the main checkout experience.\nThis component includes a CSS-only loader that displays before the JavaScript\nis fully loaded, ensuring users see a loading indicator immediately.\n\nThe loader can be disabled by:\n1. Adding the 'loader-disabled' attribute to the component\n2. Setting the CSS custom property --primer-loader-disabled: 1",
|
|
1924
|
+
"name": "PrimerCheckoutComponent",
|
|
1925
|
+
"members": [
|
|
1926
|
+
{
|
|
1927
|
+
"kind": "field",
|
|
1928
|
+
"name": "jsInitialized",
|
|
1929
|
+
"type": {
|
|
1930
|
+
"text": "boolean"
|
|
1931
|
+
}
|
|
1932
|
+
},
|
|
1502
1933
|
{
|
|
1503
1934
|
"kind": "field",
|
|
1504
1935
|
"name": "customStyles",
|
|
@@ -5216,6 +5647,47 @@
|
|
|
5216
5647
|
}
|
|
5217
5648
|
]
|
|
5218
5649
|
},
|
|
5650
|
+
{
|
|
5651
|
+
"kind": "method",
|
|
5652
|
+
"name": "dispatchOnCheckoutComplete",
|
|
5653
|
+
"return": {
|
|
5654
|
+
"type": {
|
|
5655
|
+
"text": "void"
|
|
5656
|
+
}
|
|
5657
|
+
},
|
|
5658
|
+
"parameters": [
|
|
5659
|
+
{
|
|
5660
|
+
"name": "payment",
|
|
5661
|
+
"type": {
|
|
5662
|
+
"text": "Payment | null"
|
|
5663
|
+
}
|
|
5664
|
+
}
|
|
5665
|
+
]
|
|
5666
|
+
},
|
|
5667
|
+
{
|
|
5668
|
+
"kind": "method",
|
|
5669
|
+
"name": "dispatchOnCheckoutFailure",
|
|
5670
|
+
"return": {
|
|
5671
|
+
"type": {
|
|
5672
|
+
"text": "void"
|
|
5673
|
+
}
|
|
5674
|
+
},
|
|
5675
|
+
"parameters": [
|
|
5676
|
+
{
|
|
5677
|
+
"name": "error",
|
|
5678
|
+
"type": {
|
|
5679
|
+
"text": "PrimerClientError"
|
|
5680
|
+
}
|
|
5681
|
+
},
|
|
5682
|
+
{
|
|
5683
|
+
"name": "payment",
|
|
5684
|
+
"optional": true,
|
|
5685
|
+
"type": {
|
|
5686
|
+
"text": "Payment"
|
|
5687
|
+
}
|
|
5688
|
+
}
|
|
5689
|
+
]
|
|
5690
|
+
},
|
|
5219
5691
|
{
|
|
5220
5692
|
"kind": "method",
|
|
5221
5693
|
"name": "dispatchFormSubmitSuccess",
|
|
@@ -5755,193 +6227,1136 @@
|
|
|
5755
6227
|
"exports": [
|
|
5756
6228
|
{
|
|
5757
6229
|
"kind": "js",
|
|
5758
|
-
"name": "initialSDKState",
|
|
6230
|
+
"name": "initialSDKState",
|
|
6231
|
+
"declaration": {
|
|
6232
|
+
"name": "initialSDKState",
|
|
6233
|
+
"module": "src/controllers/sdk-state-controller.ts"
|
|
6234
|
+
}
|
|
6235
|
+
},
|
|
6236
|
+
{
|
|
6237
|
+
"kind": "js",
|
|
6238
|
+
"name": "SdkStateController",
|
|
6239
|
+
"declaration": {
|
|
6240
|
+
"name": "SdkStateController",
|
|
6241
|
+
"module": "src/controllers/sdk-state-controller.ts"
|
|
6242
|
+
}
|
|
6243
|
+
}
|
|
6244
|
+
]
|
|
6245
|
+
},
|
|
6246
|
+
{
|
|
6247
|
+
"kind": "javascript-module",
|
|
6248
|
+
"path": "src/controllers/style-processing-controller.ts",
|
|
6249
|
+
"declarations": [
|
|
6250
|
+
{
|
|
6251
|
+
"kind": "class",
|
|
6252
|
+
"description": "Controller that handles processing and application of custom styles to Lit components.\nSafely converts JSON style objects to CSS variables applied to the host element.",
|
|
6253
|
+
"name": "StyleProcessingController",
|
|
6254
|
+
"members": [
|
|
6255
|
+
{
|
|
6256
|
+
"kind": "field",
|
|
6257
|
+
"name": "host",
|
|
6258
|
+
"type": {
|
|
6259
|
+
"text": "ReactiveControllerHost & LitElement"
|
|
6260
|
+
}
|
|
6261
|
+
},
|
|
6262
|
+
{
|
|
6263
|
+
"kind": "field",
|
|
6264
|
+
"name": "cssVarCache",
|
|
6265
|
+
"privacy": "private",
|
|
6266
|
+
"static": true,
|
|
6267
|
+
"default": "new Map<string, string>()"
|
|
6268
|
+
},
|
|
6269
|
+
{
|
|
6270
|
+
"kind": "method",
|
|
6271
|
+
"name": "processCustomStyles",
|
|
6272
|
+
"return": {
|
|
6273
|
+
"type": {
|
|
6274
|
+
"text": "void"
|
|
6275
|
+
}
|
|
6276
|
+
},
|
|
6277
|
+
"parameters": [
|
|
6278
|
+
{
|
|
6279
|
+
"name": "jsonString",
|
|
6280
|
+
"type": {
|
|
6281
|
+
"text": "string"
|
|
6282
|
+
},
|
|
6283
|
+
"description": "The JSON string representing custom styles."
|
|
6284
|
+
}
|
|
6285
|
+
],
|
|
6286
|
+
"description": "Processes the customStyles JSON string.\nExpected JSON contains only CSS variable properties in camelCase."
|
|
6287
|
+
},
|
|
6288
|
+
{
|
|
6289
|
+
"kind": "method",
|
|
6290
|
+
"name": "isValidCssProperty",
|
|
6291
|
+
"privacy": "private",
|
|
6292
|
+
"return": {
|
|
6293
|
+
"type": {
|
|
6294
|
+
"text": ""
|
|
6295
|
+
}
|
|
6296
|
+
},
|
|
6297
|
+
"parameters": [
|
|
6298
|
+
{
|
|
6299
|
+
"name": "property",
|
|
6300
|
+
"type": {
|
|
6301
|
+
"text": "string"
|
|
6302
|
+
},
|
|
6303
|
+
"description": "The CSS property name to validate."
|
|
6304
|
+
}
|
|
6305
|
+
],
|
|
6306
|
+
"description": "Validates a CSS property name to ensure it follows expected patterns."
|
|
6307
|
+
},
|
|
6308
|
+
{
|
|
6309
|
+
"kind": "method",
|
|
6310
|
+
"name": "isValidCssValue",
|
|
6311
|
+
"privacy": "private",
|
|
6312
|
+
"return": {
|
|
6313
|
+
"type": {
|
|
6314
|
+
"text": ""
|
|
6315
|
+
}
|
|
6316
|
+
},
|
|
6317
|
+
"parameters": [
|
|
6318
|
+
{
|
|
6319
|
+
"name": "value",
|
|
6320
|
+
"type": {
|
|
6321
|
+
"text": "string"
|
|
6322
|
+
},
|
|
6323
|
+
"description": "The CSS value to validate."
|
|
6324
|
+
}
|
|
6325
|
+
],
|
|
6326
|
+
"description": "Validates a CSS value to ensure it only contains safe, expected characters.\nAllowed characters include alphanumerics, whitespace, and common CSS punctuation.\nThis helps prevent CSS injection attacks."
|
|
6327
|
+
},
|
|
6328
|
+
{
|
|
6329
|
+
"kind": "method",
|
|
6330
|
+
"name": "getCssVarName",
|
|
6331
|
+
"privacy": "private",
|
|
6332
|
+
"return": {
|
|
6333
|
+
"type": {
|
|
6334
|
+
"text": ""
|
|
6335
|
+
}
|
|
6336
|
+
},
|
|
6337
|
+
"parameters": [
|
|
6338
|
+
{
|
|
6339
|
+
"name": "key",
|
|
6340
|
+
"type": {
|
|
6341
|
+
"text": "string"
|
|
6342
|
+
},
|
|
6343
|
+
"description": "The camelCase property key"
|
|
6344
|
+
}
|
|
6345
|
+
],
|
|
6346
|
+
"description": "Gets the CSS variable name for a camelCase property key.\nUses caching for performance."
|
|
6347
|
+
},
|
|
6348
|
+
{
|
|
6349
|
+
"kind": "method",
|
|
6350
|
+
"name": "applyStyles",
|
|
6351
|
+
"privacy": "private",
|
|
6352
|
+
"return": {
|
|
6353
|
+
"type": {
|
|
6354
|
+
"text": "void"
|
|
6355
|
+
}
|
|
6356
|
+
},
|
|
6357
|
+
"parameters": [
|
|
6358
|
+
{
|
|
6359
|
+
"name": "styles",
|
|
6360
|
+
"type": {
|
|
6361
|
+
"text": "StylesObject"
|
|
6362
|
+
},
|
|
6363
|
+
"description": "An object with style keys and corresponding CSS values."
|
|
6364
|
+
}
|
|
6365
|
+
],
|
|
6366
|
+
"description": "Transforms a styles object into CSS variables and applies them to the host element.\nEach key (in camelCase) is converted into a kebab-case CSS variable prefixed with '--'.\nOnly valid CSS properties and values are applied."
|
|
6367
|
+
},
|
|
6368
|
+
{
|
|
6369
|
+
"kind": "method",
|
|
6370
|
+
"name": "removeStyle",
|
|
6371
|
+
"return": {
|
|
6372
|
+
"type": {
|
|
6373
|
+
"text": "void"
|
|
6374
|
+
}
|
|
6375
|
+
},
|
|
6376
|
+
"parameters": [
|
|
6377
|
+
{
|
|
6378
|
+
"name": "key",
|
|
6379
|
+
"type": {
|
|
6380
|
+
"text": "string"
|
|
6381
|
+
},
|
|
6382
|
+
"description": "The camelCase property key to remove"
|
|
6383
|
+
}
|
|
6384
|
+
],
|
|
6385
|
+
"description": "Removes a specific CSS variable from the host element"
|
|
6386
|
+
},
|
|
6387
|
+
{
|
|
6388
|
+
"kind": "method",
|
|
6389
|
+
"name": "clearAllStyles",
|
|
6390
|
+
"return": {
|
|
6391
|
+
"type": {
|
|
6392
|
+
"text": "void"
|
|
6393
|
+
}
|
|
6394
|
+
},
|
|
6395
|
+
"description": "Removes all custom styles from the host element"
|
|
6396
|
+
},
|
|
6397
|
+
{
|
|
6398
|
+
"kind": "method",
|
|
6399
|
+
"name": "hostDisconnected",
|
|
6400
|
+
"return": {
|
|
6401
|
+
"type": {
|
|
6402
|
+
"text": "void"
|
|
6403
|
+
}
|
|
6404
|
+
},
|
|
6405
|
+
"description": "Optional cleanup when the host is disconnected"
|
|
6406
|
+
}
|
|
6407
|
+
]
|
|
6408
|
+
}
|
|
6409
|
+
],
|
|
6410
|
+
"exports": [
|
|
6411
|
+
{
|
|
6412
|
+
"kind": "js",
|
|
6413
|
+
"name": "StyleProcessingController",
|
|
6414
|
+
"declaration": {
|
|
6415
|
+
"name": "StyleProcessingController",
|
|
6416
|
+
"module": "src/controllers/style-processing-controller.ts"
|
|
6417
|
+
}
|
|
6418
|
+
}
|
|
6419
|
+
]
|
|
6420
|
+
},
|
|
6421
|
+
{
|
|
6422
|
+
"kind": "javascript-module",
|
|
6423
|
+
"path": "src/react-components/ach-payment.ts",
|
|
6424
|
+
"declarations": [
|
|
6425
|
+
{
|
|
6426
|
+
"kind": "variable",
|
|
6427
|
+
"name": "AchPayment"
|
|
6428
|
+
}
|
|
6429
|
+
],
|
|
6430
|
+
"exports": [
|
|
6431
|
+
{
|
|
6432
|
+
"kind": "js",
|
|
6433
|
+
"name": "AchPayment",
|
|
6434
|
+
"declaration": {
|
|
6435
|
+
"name": "AchPayment",
|
|
6436
|
+
"module": "src/react-components/ach-payment.ts"
|
|
6437
|
+
}
|
|
6438
|
+
}
|
|
6439
|
+
]
|
|
6440
|
+
},
|
|
6441
|
+
{
|
|
6442
|
+
"kind": "javascript-module",
|
|
6443
|
+
"path": "src/react-components/button.ts",
|
|
6444
|
+
"declarations": [
|
|
6445
|
+
{
|
|
6446
|
+
"kind": "variable",
|
|
6447
|
+
"name": "Button"
|
|
6448
|
+
}
|
|
6449
|
+
],
|
|
6450
|
+
"exports": [
|
|
6451
|
+
{
|
|
6452
|
+
"kind": "js",
|
|
6453
|
+
"name": "Button",
|
|
6454
|
+
"declaration": {
|
|
6455
|
+
"name": "Button",
|
|
6456
|
+
"module": "src/react-components/button.ts"
|
|
6457
|
+
}
|
|
6458
|
+
},
|
|
6459
|
+
{
|
|
6460
|
+
"kind": "js",
|
|
6461
|
+
"name": "ButtonSelectionState",
|
|
6462
|
+
"declaration": {
|
|
6463
|
+
"name": "ButtonSelectionState",
|
|
6464
|
+
"module": "../atoms/button/button.component"
|
|
6465
|
+
}
|
|
6466
|
+
}
|
|
6467
|
+
]
|
|
6468
|
+
},
|
|
6469
|
+
{
|
|
6470
|
+
"kind": "javascript-module",
|
|
6471
|
+
"path": "src/react-components/card-form-submit.ts",
|
|
6472
|
+
"declarations": [
|
|
6473
|
+
{
|
|
6474
|
+
"kind": "variable",
|
|
6475
|
+
"name": "CardFormSubmit"
|
|
6476
|
+
}
|
|
6477
|
+
],
|
|
6478
|
+
"exports": [
|
|
6479
|
+
{
|
|
6480
|
+
"kind": "js",
|
|
6481
|
+
"name": "CardFormSubmit",
|
|
6482
|
+
"declaration": {
|
|
6483
|
+
"name": "CardFormSubmit",
|
|
6484
|
+
"module": "src/react-components/card-form-submit.ts"
|
|
6485
|
+
}
|
|
6486
|
+
}
|
|
6487
|
+
]
|
|
6488
|
+
},
|
|
6489
|
+
{
|
|
6490
|
+
"kind": "javascript-module",
|
|
6491
|
+
"path": "src/react-components/card-form.ts",
|
|
6492
|
+
"declarations": [
|
|
6493
|
+
{
|
|
6494
|
+
"kind": "variable",
|
|
6495
|
+
"name": "CardForm"
|
|
6496
|
+
}
|
|
6497
|
+
],
|
|
6498
|
+
"exports": [
|
|
6499
|
+
{
|
|
6500
|
+
"kind": "js",
|
|
6501
|
+
"name": "CardForm",
|
|
6502
|
+
"declaration": {
|
|
6503
|
+
"name": "CardForm",
|
|
6504
|
+
"module": "src/react-components/card-form.ts"
|
|
6505
|
+
}
|
|
6506
|
+
}
|
|
6507
|
+
]
|
|
6508
|
+
},
|
|
6509
|
+
{
|
|
6510
|
+
"kind": "javascript-module",
|
|
6511
|
+
"path": "src/react-components/card-network-selector.ts",
|
|
6512
|
+
"declarations": [
|
|
6513
|
+
{
|
|
6514
|
+
"kind": "variable",
|
|
6515
|
+
"name": "CardNetworkSelector"
|
|
6516
|
+
}
|
|
6517
|
+
],
|
|
6518
|
+
"exports": [
|
|
6519
|
+
{
|
|
6520
|
+
"kind": "js",
|
|
6521
|
+
"name": "CardNetworkSelector",
|
|
6522
|
+
"declaration": {
|
|
6523
|
+
"name": "CardNetworkSelector",
|
|
6524
|
+
"module": "src/react-components/card-network-selector.ts"
|
|
6525
|
+
}
|
|
6526
|
+
}
|
|
6527
|
+
]
|
|
6528
|
+
},
|
|
6529
|
+
{
|
|
6530
|
+
"kind": "javascript-module",
|
|
6531
|
+
"path": "src/react-components/checkout-state.ts",
|
|
6532
|
+
"declarations": [
|
|
6533
|
+
{
|
|
6534
|
+
"kind": "variable",
|
|
6535
|
+
"name": "CheckoutState"
|
|
6536
|
+
}
|
|
6537
|
+
],
|
|
6538
|
+
"exports": [
|
|
6539
|
+
{
|
|
6540
|
+
"kind": "js",
|
|
6541
|
+
"name": "CheckoutState",
|
|
6542
|
+
"declaration": {
|
|
6543
|
+
"name": "CheckoutState",
|
|
6544
|
+
"module": "src/react-components/checkout-state.ts"
|
|
6545
|
+
}
|
|
6546
|
+
}
|
|
6547
|
+
]
|
|
6548
|
+
},
|
|
6549
|
+
{
|
|
6550
|
+
"kind": "javascript-module",
|
|
6551
|
+
"path": "src/react-components/checkout.ts",
|
|
6552
|
+
"declarations": [
|
|
6553
|
+
{
|
|
6554
|
+
"kind": "variable",
|
|
6555
|
+
"name": "PrimerCheckout"
|
|
6556
|
+
}
|
|
6557
|
+
],
|
|
6558
|
+
"exports": [
|
|
6559
|
+
{
|
|
6560
|
+
"kind": "js",
|
|
6561
|
+
"name": "PrimerCheckout",
|
|
6562
|
+
"declaration": {
|
|
6563
|
+
"name": "PrimerCheckout",
|
|
6564
|
+
"module": "src/react-components/checkout.ts"
|
|
6565
|
+
}
|
|
6566
|
+
}
|
|
6567
|
+
]
|
|
6568
|
+
},
|
|
6569
|
+
{
|
|
6570
|
+
"kind": "javascript-module",
|
|
6571
|
+
"path": "src/react-components/collapsable.ts",
|
|
6572
|
+
"declarations": [
|
|
6573
|
+
{
|
|
6574
|
+
"kind": "variable",
|
|
6575
|
+
"name": "Collapsable"
|
|
6576
|
+
}
|
|
6577
|
+
],
|
|
6578
|
+
"exports": [
|
|
6579
|
+
{
|
|
6580
|
+
"kind": "js",
|
|
6581
|
+
"name": "Collapsable",
|
|
6582
|
+
"declaration": {
|
|
6583
|
+
"name": "Collapsable",
|
|
6584
|
+
"module": "src/react-components/collapsable.ts"
|
|
6585
|
+
}
|
|
6586
|
+
},
|
|
6587
|
+
{
|
|
6588
|
+
"kind": "js",
|
|
6589
|
+
"name": "ButtonVariant",
|
|
6590
|
+
"declaration": {
|
|
6591
|
+
"name": "ButtonVariant",
|
|
6592
|
+
"module": "../atoms/collapsable/collapsable.component"
|
|
6593
|
+
}
|
|
6594
|
+
}
|
|
6595
|
+
]
|
|
6596
|
+
},
|
|
6597
|
+
{
|
|
6598
|
+
"kind": "javascript-module",
|
|
6599
|
+
"path": "src/react-components/dialog.ts",
|
|
6600
|
+
"declarations": [
|
|
6601
|
+
{
|
|
6602
|
+
"kind": "variable",
|
|
6603
|
+
"name": "Dialog"
|
|
6604
|
+
}
|
|
6605
|
+
],
|
|
6606
|
+
"exports": [
|
|
6607
|
+
{
|
|
6608
|
+
"kind": "js",
|
|
6609
|
+
"name": "Dialog",
|
|
6610
|
+
"declaration": {
|
|
6611
|
+
"name": "Dialog",
|
|
6612
|
+
"module": "src/react-components/dialog.ts"
|
|
6613
|
+
}
|
|
6614
|
+
}
|
|
6615
|
+
]
|
|
6616
|
+
},
|
|
6617
|
+
{
|
|
6618
|
+
"kind": "javascript-module",
|
|
6619
|
+
"path": "src/react-components/dynamic-payment.ts",
|
|
6620
|
+
"declarations": [
|
|
6621
|
+
{
|
|
6622
|
+
"kind": "variable",
|
|
6623
|
+
"name": "DynamicPayment"
|
|
6624
|
+
}
|
|
6625
|
+
],
|
|
6626
|
+
"exports": [
|
|
6627
|
+
{
|
|
6628
|
+
"kind": "js",
|
|
6629
|
+
"name": "DynamicPayment",
|
|
6630
|
+
"declaration": {
|
|
6631
|
+
"name": "DynamicPayment",
|
|
6632
|
+
"module": "src/react-components/dynamic-payment.ts"
|
|
6633
|
+
}
|
|
6634
|
+
}
|
|
6635
|
+
]
|
|
6636
|
+
},
|
|
6637
|
+
{
|
|
6638
|
+
"kind": "javascript-module",
|
|
6639
|
+
"path": "src/react-components/error-message-container.ts",
|
|
6640
|
+
"declarations": [
|
|
6641
|
+
{
|
|
6642
|
+
"kind": "variable",
|
|
6643
|
+
"name": "ErrorMessageContainer"
|
|
6644
|
+
}
|
|
6645
|
+
],
|
|
6646
|
+
"exports": [
|
|
6647
|
+
{
|
|
6648
|
+
"kind": "js",
|
|
6649
|
+
"name": "ErrorMessageContainer",
|
|
6650
|
+
"declaration": {
|
|
6651
|
+
"name": "ErrorMessageContainer",
|
|
6652
|
+
"module": "src/react-components/error-message-container.ts"
|
|
6653
|
+
}
|
|
6654
|
+
}
|
|
6655
|
+
]
|
|
6656
|
+
},
|
|
6657
|
+
{
|
|
6658
|
+
"kind": "javascript-module",
|
|
6659
|
+
"path": "src/react-components/error-message.ts",
|
|
6660
|
+
"declarations": [
|
|
6661
|
+
{
|
|
6662
|
+
"kind": "variable",
|
|
6663
|
+
"name": "ErrorMessage"
|
|
6664
|
+
}
|
|
6665
|
+
],
|
|
6666
|
+
"exports": [
|
|
6667
|
+
{
|
|
6668
|
+
"kind": "js",
|
|
6669
|
+
"name": "ErrorMessage",
|
|
6670
|
+
"declaration": {
|
|
6671
|
+
"name": "ErrorMessage",
|
|
6672
|
+
"module": "src/react-components/error-message.ts"
|
|
6673
|
+
}
|
|
6674
|
+
}
|
|
6675
|
+
]
|
|
6676
|
+
},
|
|
6677
|
+
{
|
|
6678
|
+
"kind": "javascript-module",
|
|
6679
|
+
"path": "src/react-components/icon.ts",
|
|
6680
|
+
"declarations": [
|
|
6681
|
+
{
|
|
6682
|
+
"kind": "variable",
|
|
6683
|
+
"name": "Icon"
|
|
6684
|
+
}
|
|
6685
|
+
],
|
|
6686
|
+
"exports": [
|
|
6687
|
+
{
|
|
6688
|
+
"kind": "js",
|
|
6689
|
+
"name": "Icon",
|
|
6690
|
+
"declaration": {
|
|
6691
|
+
"name": "Icon",
|
|
6692
|
+
"module": "src/react-components/icon.ts"
|
|
6693
|
+
}
|
|
6694
|
+
}
|
|
6695
|
+
]
|
|
6696
|
+
},
|
|
6697
|
+
{
|
|
6698
|
+
"kind": "javascript-module",
|
|
6699
|
+
"path": "src/react-components/index.ts",
|
|
6700
|
+
"declarations": [],
|
|
6701
|
+
"exports": [
|
|
6702
|
+
{
|
|
6703
|
+
"kind": "js",
|
|
6704
|
+
"name": "*",
|
|
6705
|
+
"declaration": {
|
|
6706
|
+
"name": "*",
|
|
6707
|
+
"package": "./checkout"
|
|
6708
|
+
}
|
|
6709
|
+
},
|
|
6710
|
+
{
|
|
6711
|
+
"kind": "js",
|
|
6712
|
+
"name": "*",
|
|
6713
|
+
"declaration": {
|
|
6714
|
+
"name": "*",
|
|
6715
|
+
"package": "./checkout-state"
|
|
6716
|
+
}
|
|
6717
|
+
},
|
|
6718
|
+
{
|
|
6719
|
+
"kind": "js",
|
|
6720
|
+
"name": "*",
|
|
6721
|
+
"declaration": {
|
|
6722
|
+
"name": "*",
|
|
6723
|
+
"package": "./collapsable"
|
|
6724
|
+
}
|
|
6725
|
+
},
|
|
6726
|
+
{
|
|
6727
|
+
"kind": "js",
|
|
6728
|
+
"name": "*",
|
|
6729
|
+
"declaration": {
|
|
6730
|
+
"name": "*",
|
|
6731
|
+
"package": "./dialog"
|
|
6732
|
+
}
|
|
6733
|
+
},
|
|
6734
|
+
{
|
|
6735
|
+
"kind": "js",
|
|
6736
|
+
"name": "*",
|
|
6737
|
+
"declaration": {
|
|
6738
|
+
"name": "*",
|
|
6739
|
+
"package": "./error-message"
|
|
6740
|
+
}
|
|
6741
|
+
},
|
|
6742
|
+
{
|
|
6743
|
+
"kind": "js",
|
|
6744
|
+
"name": "*",
|
|
6745
|
+
"declaration": {
|
|
6746
|
+
"name": "*",
|
|
6747
|
+
"package": "./icon"
|
|
6748
|
+
}
|
|
6749
|
+
},
|
|
6750
|
+
{
|
|
6751
|
+
"kind": "js",
|
|
6752
|
+
"name": "*",
|
|
6753
|
+
"declaration": {
|
|
6754
|
+
"name": "*",
|
|
6755
|
+
"package": "./input"
|
|
6756
|
+
}
|
|
6757
|
+
},
|
|
6758
|
+
{
|
|
6759
|
+
"kind": "js",
|
|
6760
|
+
"name": "*",
|
|
6761
|
+
"declaration": {
|
|
6762
|
+
"name": "*",
|
|
6763
|
+
"package": "./input-error"
|
|
6764
|
+
}
|
|
6765
|
+
},
|
|
6766
|
+
{
|
|
6767
|
+
"kind": "js",
|
|
6768
|
+
"name": "*",
|
|
6769
|
+
"declaration": {
|
|
6770
|
+
"name": "*",
|
|
6771
|
+
"package": "./input-label"
|
|
6772
|
+
}
|
|
6773
|
+
},
|
|
6774
|
+
{
|
|
6775
|
+
"kind": "js",
|
|
6776
|
+
"name": "*",
|
|
6777
|
+
"declaration": {
|
|
6778
|
+
"name": "*",
|
|
6779
|
+
"package": "./input-wrapper"
|
|
6780
|
+
}
|
|
6781
|
+
},
|
|
6782
|
+
{
|
|
6783
|
+
"kind": "js",
|
|
6784
|
+
"name": "*",
|
|
6785
|
+
"declaration": {
|
|
6786
|
+
"name": "*",
|
|
6787
|
+
"package": "./portal"
|
|
6788
|
+
}
|
|
6789
|
+
},
|
|
6790
|
+
{
|
|
6791
|
+
"kind": "js",
|
|
6792
|
+
"name": "*",
|
|
6793
|
+
"declaration": {
|
|
6794
|
+
"name": "*",
|
|
6795
|
+
"package": "./spinner"
|
|
6796
|
+
}
|
|
6797
|
+
},
|
|
6798
|
+
{
|
|
6799
|
+
"kind": "js",
|
|
6800
|
+
"name": "*",
|
|
6801
|
+
"declaration": {
|
|
6802
|
+
"name": "*",
|
|
6803
|
+
"package": "./ach-payment"
|
|
6804
|
+
}
|
|
6805
|
+
},
|
|
6806
|
+
{
|
|
6807
|
+
"kind": "js",
|
|
6808
|
+
"name": "*",
|
|
6809
|
+
"declaration": {
|
|
6810
|
+
"name": "*",
|
|
6811
|
+
"package": "./card-form"
|
|
6812
|
+
}
|
|
6813
|
+
},
|
|
6814
|
+
{
|
|
6815
|
+
"kind": "js",
|
|
6816
|
+
"name": "*",
|
|
6817
|
+
"declaration": {
|
|
6818
|
+
"name": "*",
|
|
6819
|
+
"package": "./card-form-submit"
|
|
6820
|
+
}
|
|
6821
|
+
},
|
|
6822
|
+
{
|
|
6823
|
+
"kind": "js",
|
|
6824
|
+
"name": "*",
|
|
6825
|
+
"declaration": {
|
|
6826
|
+
"name": "*",
|
|
6827
|
+
"package": "./card-network-selector"
|
|
6828
|
+
}
|
|
6829
|
+
},
|
|
6830
|
+
{
|
|
6831
|
+
"kind": "js",
|
|
6832
|
+
"name": "*",
|
|
6833
|
+
"declaration": {
|
|
6834
|
+
"name": "*",
|
|
6835
|
+
"package": "./input-card-holder-name"
|
|
6836
|
+
}
|
|
6837
|
+
},
|
|
6838
|
+
{
|
|
6839
|
+
"kind": "js",
|
|
6840
|
+
"name": "*",
|
|
6841
|
+
"declaration": {
|
|
6842
|
+
"name": "*",
|
|
6843
|
+
"package": "./input-card-expiry"
|
|
6844
|
+
}
|
|
6845
|
+
},
|
|
6846
|
+
{
|
|
6847
|
+
"kind": "js",
|
|
6848
|
+
"name": "*",
|
|
6849
|
+
"declaration": {
|
|
6850
|
+
"name": "*",
|
|
6851
|
+
"package": "./input-cvv"
|
|
6852
|
+
}
|
|
6853
|
+
},
|
|
6854
|
+
{
|
|
6855
|
+
"kind": "js",
|
|
6856
|
+
"name": "*",
|
|
6857
|
+
"declaration": {
|
|
6858
|
+
"name": "*",
|
|
6859
|
+
"package": "./input-card-number"
|
|
6860
|
+
}
|
|
6861
|
+
},
|
|
6862
|
+
{
|
|
6863
|
+
"kind": "js",
|
|
6864
|
+
"name": "*",
|
|
6865
|
+
"declaration": {
|
|
6866
|
+
"name": "*",
|
|
6867
|
+
"package": "./dynamic-payment"
|
|
6868
|
+
}
|
|
6869
|
+
},
|
|
6870
|
+
{
|
|
6871
|
+
"kind": "js",
|
|
6872
|
+
"name": "*",
|
|
6873
|
+
"declaration": {
|
|
6874
|
+
"name": "*",
|
|
6875
|
+
"package": "./error-message-container"
|
|
6876
|
+
}
|
|
6877
|
+
},
|
|
6878
|
+
{
|
|
6879
|
+
"kind": "js",
|
|
6880
|
+
"name": "*",
|
|
6881
|
+
"declaration": {
|
|
6882
|
+
"name": "*",
|
|
6883
|
+
"package": "./klarna"
|
|
6884
|
+
}
|
|
6885
|
+
},
|
|
6886
|
+
{
|
|
6887
|
+
"kind": "js",
|
|
6888
|
+
"name": "*",
|
|
6889
|
+
"declaration": {
|
|
6890
|
+
"name": "*",
|
|
6891
|
+
"package": "./native-payment"
|
|
6892
|
+
}
|
|
6893
|
+
},
|
|
6894
|
+
{
|
|
6895
|
+
"kind": "js",
|
|
6896
|
+
"name": "*",
|
|
6897
|
+
"declaration": {
|
|
6898
|
+
"name": "*",
|
|
6899
|
+
"package": "./payment-method"
|
|
6900
|
+
}
|
|
6901
|
+
},
|
|
6902
|
+
{
|
|
6903
|
+
"kind": "js",
|
|
6904
|
+
"name": "*",
|
|
6905
|
+
"declaration": {
|
|
6906
|
+
"name": "*",
|
|
6907
|
+
"package": "./primer-checkout-complete"
|
|
6908
|
+
}
|
|
6909
|
+
},
|
|
6910
|
+
{
|
|
6911
|
+
"kind": "js",
|
|
6912
|
+
"name": "*",
|
|
6913
|
+
"declaration": {
|
|
6914
|
+
"name": "*",
|
|
6915
|
+
"package": "./primer-checkout-error"
|
|
6916
|
+
}
|
|
6917
|
+
},
|
|
6918
|
+
{
|
|
6919
|
+
"kind": "js",
|
|
6920
|
+
"name": "*",
|
|
6921
|
+
"declaration": {
|
|
6922
|
+
"name": "*",
|
|
6923
|
+
"package": "./primer-main"
|
|
6924
|
+
}
|
|
6925
|
+
},
|
|
6926
|
+
{
|
|
6927
|
+
"kind": "js",
|
|
6928
|
+
"name": "*",
|
|
6929
|
+
"declaration": {
|
|
6930
|
+
"name": "*",
|
|
6931
|
+
"package": "./redirect-payment"
|
|
6932
|
+
}
|
|
6933
|
+
},
|
|
6934
|
+
{
|
|
6935
|
+
"kind": "js",
|
|
6936
|
+
"name": "*",
|
|
6937
|
+
"declaration": {
|
|
6938
|
+
"name": "*",
|
|
6939
|
+
"package": "./show-other-payments"
|
|
6940
|
+
}
|
|
6941
|
+
},
|
|
6942
|
+
{
|
|
6943
|
+
"kind": "js",
|
|
6944
|
+
"name": "*",
|
|
6945
|
+
"declaration": {
|
|
6946
|
+
"name": "*",
|
|
6947
|
+
"package": "./button"
|
|
6948
|
+
}
|
|
6949
|
+
},
|
|
6950
|
+
{
|
|
6951
|
+
"kind": "js",
|
|
6952
|
+
"name": "*",
|
|
6953
|
+
"declaration": {
|
|
6954
|
+
"name": "*",
|
|
6955
|
+
"package": "./vault-manager"
|
|
6956
|
+
}
|
|
6957
|
+
}
|
|
6958
|
+
]
|
|
6959
|
+
},
|
|
6960
|
+
{
|
|
6961
|
+
"kind": "javascript-module",
|
|
6962
|
+
"path": "src/react-components/input-card-expiry.ts",
|
|
6963
|
+
"declarations": [
|
|
6964
|
+
{
|
|
6965
|
+
"kind": "variable",
|
|
6966
|
+
"name": "InputCardExpiry"
|
|
6967
|
+
}
|
|
6968
|
+
],
|
|
6969
|
+
"exports": [
|
|
6970
|
+
{
|
|
6971
|
+
"kind": "js",
|
|
6972
|
+
"name": "InputCardExpiry",
|
|
6973
|
+
"declaration": {
|
|
6974
|
+
"name": "InputCardExpiry",
|
|
6975
|
+
"module": "src/react-components/input-card-expiry.ts"
|
|
6976
|
+
}
|
|
6977
|
+
}
|
|
6978
|
+
]
|
|
6979
|
+
},
|
|
6980
|
+
{
|
|
6981
|
+
"kind": "javascript-module",
|
|
6982
|
+
"path": "src/react-components/input-card-holder-name.ts",
|
|
6983
|
+
"declarations": [
|
|
6984
|
+
{
|
|
6985
|
+
"kind": "variable",
|
|
6986
|
+
"name": "InputCardHolderName"
|
|
6987
|
+
}
|
|
6988
|
+
],
|
|
6989
|
+
"exports": [
|
|
6990
|
+
{
|
|
6991
|
+
"kind": "js",
|
|
6992
|
+
"name": "InputCardHolderName",
|
|
6993
|
+
"declaration": {
|
|
6994
|
+
"name": "InputCardHolderName",
|
|
6995
|
+
"module": "src/react-components/input-card-holder-name.ts"
|
|
6996
|
+
}
|
|
6997
|
+
}
|
|
6998
|
+
]
|
|
6999
|
+
},
|
|
7000
|
+
{
|
|
7001
|
+
"kind": "javascript-module",
|
|
7002
|
+
"path": "src/react-components/input-card-number.ts",
|
|
7003
|
+
"declarations": [
|
|
7004
|
+
{
|
|
7005
|
+
"kind": "variable",
|
|
7006
|
+
"name": "InputCardNumber"
|
|
7007
|
+
}
|
|
7008
|
+
],
|
|
7009
|
+
"exports": [
|
|
7010
|
+
{
|
|
7011
|
+
"kind": "js",
|
|
7012
|
+
"name": "InputCardNumber",
|
|
7013
|
+
"declaration": {
|
|
7014
|
+
"name": "InputCardNumber",
|
|
7015
|
+
"module": "src/react-components/input-card-number.ts"
|
|
7016
|
+
}
|
|
7017
|
+
}
|
|
7018
|
+
]
|
|
7019
|
+
},
|
|
7020
|
+
{
|
|
7021
|
+
"kind": "javascript-module",
|
|
7022
|
+
"path": "src/react-components/input-cvv.ts",
|
|
7023
|
+
"declarations": [
|
|
7024
|
+
{
|
|
7025
|
+
"kind": "variable",
|
|
7026
|
+
"name": "InputCvv"
|
|
7027
|
+
}
|
|
7028
|
+
],
|
|
7029
|
+
"exports": [
|
|
7030
|
+
{
|
|
7031
|
+
"kind": "js",
|
|
7032
|
+
"name": "InputCvv",
|
|
7033
|
+
"declaration": {
|
|
7034
|
+
"name": "InputCvv",
|
|
7035
|
+
"module": "src/react-components/input-cvv.ts"
|
|
7036
|
+
}
|
|
7037
|
+
}
|
|
7038
|
+
]
|
|
7039
|
+
},
|
|
7040
|
+
{
|
|
7041
|
+
"kind": "javascript-module",
|
|
7042
|
+
"path": "src/react-components/input-error.ts",
|
|
7043
|
+
"declarations": [
|
|
7044
|
+
{
|
|
7045
|
+
"kind": "variable",
|
|
7046
|
+
"name": "InputError"
|
|
7047
|
+
}
|
|
7048
|
+
],
|
|
7049
|
+
"exports": [
|
|
7050
|
+
{
|
|
7051
|
+
"kind": "js",
|
|
7052
|
+
"name": "InputError",
|
|
7053
|
+
"declaration": {
|
|
7054
|
+
"name": "InputError",
|
|
7055
|
+
"module": "src/react-components/input-error.ts"
|
|
7056
|
+
}
|
|
7057
|
+
}
|
|
7058
|
+
]
|
|
7059
|
+
},
|
|
7060
|
+
{
|
|
7061
|
+
"kind": "javascript-module",
|
|
7062
|
+
"path": "src/react-components/input-label.ts",
|
|
7063
|
+
"declarations": [
|
|
7064
|
+
{
|
|
7065
|
+
"kind": "variable",
|
|
7066
|
+
"name": "InputLabel"
|
|
7067
|
+
}
|
|
7068
|
+
],
|
|
7069
|
+
"exports": [
|
|
7070
|
+
{
|
|
7071
|
+
"kind": "js",
|
|
7072
|
+
"name": "InputLabel",
|
|
7073
|
+
"declaration": {
|
|
7074
|
+
"name": "InputLabel",
|
|
7075
|
+
"module": "src/react-components/input-label.ts"
|
|
7076
|
+
}
|
|
7077
|
+
}
|
|
7078
|
+
]
|
|
7079
|
+
},
|
|
7080
|
+
{
|
|
7081
|
+
"kind": "javascript-module",
|
|
7082
|
+
"path": "src/react-components/input-wrapper.ts",
|
|
7083
|
+
"declarations": [
|
|
7084
|
+
{
|
|
7085
|
+
"kind": "variable",
|
|
7086
|
+
"name": "InputWrapper"
|
|
7087
|
+
}
|
|
7088
|
+
],
|
|
7089
|
+
"exports": [
|
|
7090
|
+
{
|
|
7091
|
+
"kind": "js",
|
|
7092
|
+
"name": "InputWrapper",
|
|
7093
|
+
"declaration": {
|
|
7094
|
+
"name": "InputWrapper",
|
|
7095
|
+
"module": "src/react-components/input-wrapper.ts"
|
|
7096
|
+
}
|
|
7097
|
+
}
|
|
7098
|
+
]
|
|
7099
|
+
},
|
|
7100
|
+
{
|
|
7101
|
+
"kind": "javascript-module",
|
|
7102
|
+
"path": "src/react-components/input.ts",
|
|
7103
|
+
"declarations": [
|
|
7104
|
+
{
|
|
7105
|
+
"kind": "variable",
|
|
7106
|
+
"name": "Input"
|
|
7107
|
+
}
|
|
7108
|
+
],
|
|
7109
|
+
"exports": [
|
|
7110
|
+
{
|
|
7111
|
+
"kind": "js",
|
|
7112
|
+
"name": "Input",
|
|
7113
|
+
"declaration": {
|
|
7114
|
+
"name": "Input",
|
|
7115
|
+
"module": "src/react-components/input.ts"
|
|
7116
|
+
}
|
|
7117
|
+
},
|
|
7118
|
+
{
|
|
7119
|
+
"kind": "js",
|
|
7120
|
+
"name": "InputType",
|
|
7121
|
+
"declaration": {
|
|
7122
|
+
"name": "InputType",
|
|
7123
|
+
"module": "../atoms/input/input.component"
|
|
7124
|
+
}
|
|
7125
|
+
},
|
|
7126
|
+
{
|
|
7127
|
+
"kind": "js",
|
|
7128
|
+
"name": "InputEventMap",
|
|
7129
|
+
"declaration": {
|
|
7130
|
+
"name": "InputEventMap",
|
|
7131
|
+
"module": "../atoms/input/input.component"
|
|
7132
|
+
}
|
|
7133
|
+
}
|
|
7134
|
+
]
|
|
7135
|
+
},
|
|
7136
|
+
{
|
|
7137
|
+
"kind": "javascript-module",
|
|
7138
|
+
"path": "src/react-components/klarna.ts",
|
|
7139
|
+
"declarations": [
|
|
7140
|
+
{
|
|
7141
|
+
"kind": "variable",
|
|
7142
|
+
"name": "Klarna"
|
|
7143
|
+
}
|
|
7144
|
+
],
|
|
7145
|
+
"exports": [
|
|
7146
|
+
{
|
|
7147
|
+
"kind": "js",
|
|
7148
|
+
"name": "Klarna",
|
|
7149
|
+
"declaration": {
|
|
7150
|
+
"name": "Klarna",
|
|
7151
|
+
"module": "src/react-components/klarna.ts"
|
|
7152
|
+
}
|
|
7153
|
+
}
|
|
7154
|
+
]
|
|
7155
|
+
},
|
|
7156
|
+
{
|
|
7157
|
+
"kind": "javascript-module",
|
|
7158
|
+
"path": "src/react-components/native-payment.ts",
|
|
7159
|
+
"declarations": [
|
|
7160
|
+
{
|
|
7161
|
+
"kind": "variable",
|
|
7162
|
+
"name": "NativePayment"
|
|
7163
|
+
}
|
|
7164
|
+
],
|
|
7165
|
+
"exports": [
|
|
7166
|
+
{
|
|
7167
|
+
"kind": "js",
|
|
7168
|
+
"name": "NativePayment",
|
|
7169
|
+
"declaration": {
|
|
7170
|
+
"name": "NativePayment",
|
|
7171
|
+
"module": "src/react-components/native-payment.ts"
|
|
7172
|
+
}
|
|
7173
|
+
}
|
|
7174
|
+
]
|
|
7175
|
+
},
|
|
7176
|
+
{
|
|
7177
|
+
"kind": "javascript-module",
|
|
7178
|
+
"path": "src/react-components/payment-method.ts",
|
|
7179
|
+
"declarations": [
|
|
7180
|
+
{
|
|
7181
|
+
"kind": "variable",
|
|
7182
|
+
"name": "PaymentMethod"
|
|
7183
|
+
}
|
|
7184
|
+
],
|
|
7185
|
+
"exports": [
|
|
7186
|
+
{
|
|
7187
|
+
"kind": "js",
|
|
7188
|
+
"name": "PaymentMethod",
|
|
7189
|
+
"declaration": {
|
|
7190
|
+
"name": "PaymentMethod",
|
|
7191
|
+
"module": "src/react-components/payment-method.ts"
|
|
7192
|
+
}
|
|
7193
|
+
}
|
|
7194
|
+
]
|
|
7195
|
+
},
|
|
7196
|
+
{
|
|
7197
|
+
"kind": "javascript-module",
|
|
7198
|
+
"path": "src/react-components/portal.ts",
|
|
7199
|
+
"declarations": [
|
|
7200
|
+
{
|
|
7201
|
+
"kind": "variable",
|
|
7202
|
+
"name": "Portal"
|
|
7203
|
+
}
|
|
7204
|
+
],
|
|
7205
|
+
"exports": [
|
|
7206
|
+
{
|
|
7207
|
+
"kind": "js",
|
|
7208
|
+
"name": "Portal",
|
|
7209
|
+
"declaration": {
|
|
7210
|
+
"name": "Portal",
|
|
7211
|
+
"module": "src/react-components/portal.ts"
|
|
7212
|
+
}
|
|
7213
|
+
}
|
|
7214
|
+
]
|
|
7215
|
+
},
|
|
7216
|
+
{
|
|
7217
|
+
"kind": "javascript-module",
|
|
7218
|
+
"path": "src/react-components/primer-checkout-complete.ts",
|
|
7219
|
+
"declarations": [
|
|
7220
|
+
{
|
|
7221
|
+
"kind": "variable",
|
|
7222
|
+
"name": "PrimerCheckoutComplete"
|
|
7223
|
+
}
|
|
7224
|
+
],
|
|
7225
|
+
"exports": [
|
|
7226
|
+
{
|
|
7227
|
+
"kind": "js",
|
|
7228
|
+
"name": "PrimerCheckoutComplete",
|
|
7229
|
+
"declaration": {
|
|
7230
|
+
"name": "PrimerCheckoutComplete",
|
|
7231
|
+
"module": "src/react-components/primer-checkout-complete.ts"
|
|
7232
|
+
}
|
|
7233
|
+
}
|
|
7234
|
+
]
|
|
7235
|
+
},
|
|
7236
|
+
{
|
|
7237
|
+
"kind": "javascript-module",
|
|
7238
|
+
"path": "src/react-components/primer-checkout-error.ts",
|
|
7239
|
+
"declarations": [
|
|
7240
|
+
{
|
|
7241
|
+
"kind": "variable",
|
|
7242
|
+
"name": "PrimerCheckoutError"
|
|
7243
|
+
}
|
|
7244
|
+
],
|
|
7245
|
+
"exports": [
|
|
7246
|
+
{
|
|
7247
|
+
"kind": "js",
|
|
7248
|
+
"name": "PrimerCheckoutError",
|
|
7249
|
+
"declaration": {
|
|
7250
|
+
"name": "PrimerCheckoutError",
|
|
7251
|
+
"module": "src/react-components/primer-checkout-error.ts"
|
|
7252
|
+
}
|
|
7253
|
+
}
|
|
7254
|
+
]
|
|
7255
|
+
},
|
|
7256
|
+
{
|
|
7257
|
+
"kind": "javascript-module",
|
|
7258
|
+
"path": "src/react-components/primer-main.ts",
|
|
7259
|
+
"declarations": [
|
|
7260
|
+
{
|
|
7261
|
+
"kind": "variable",
|
|
7262
|
+
"name": "PrimerMain"
|
|
7263
|
+
}
|
|
7264
|
+
],
|
|
7265
|
+
"exports": [
|
|
7266
|
+
{
|
|
7267
|
+
"kind": "js",
|
|
7268
|
+
"name": "PrimerMain",
|
|
7269
|
+
"declaration": {
|
|
7270
|
+
"name": "PrimerMain",
|
|
7271
|
+
"module": "src/react-components/primer-main.ts"
|
|
7272
|
+
}
|
|
7273
|
+
}
|
|
7274
|
+
]
|
|
7275
|
+
},
|
|
7276
|
+
{
|
|
7277
|
+
"kind": "javascript-module",
|
|
7278
|
+
"path": "src/react-components/redirect-payment.ts",
|
|
7279
|
+
"declarations": [
|
|
7280
|
+
{
|
|
7281
|
+
"kind": "variable",
|
|
7282
|
+
"name": "RedirectPayment"
|
|
7283
|
+
}
|
|
7284
|
+
],
|
|
7285
|
+
"exports": [
|
|
7286
|
+
{
|
|
7287
|
+
"kind": "js",
|
|
7288
|
+
"name": "RedirectPayment",
|
|
5759
7289
|
"declaration": {
|
|
5760
|
-
"name": "
|
|
5761
|
-
"module": "src/
|
|
7290
|
+
"name": "RedirectPayment",
|
|
7291
|
+
"module": "src/react-components/redirect-payment.ts"
|
|
7292
|
+
}
|
|
7293
|
+
}
|
|
7294
|
+
]
|
|
7295
|
+
},
|
|
7296
|
+
{
|
|
7297
|
+
"kind": "javascript-module",
|
|
7298
|
+
"path": "src/react-components/show-other-payments.ts",
|
|
7299
|
+
"declarations": [
|
|
7300
|
+
{
|
|
7301
|
+
"kind": "variable",
|
|
7302
|
+
"name": "ShowOtherPayments"
|
|
7303
|
+
}
|
|
7304
|
+
],
|
|
7305
|
+
"exports": [
|
|
7306
|
+
{
|
|
7307
|
+
"kind": "js",
|
|
7308
|
+
"name": "ShowOtherPayments",
|
|
7309
|
+
"declaration": {
|
|
7310
|
+
"name": "ShowOtherPayments",
|
|
7311
|
+
"module": "src/react-components/show-other-payments.ts"
|
|
7312
|
+
}
|
|
7313
|
+
}
|
|
7314
|
+
]
|
|
7315
|
+
},
|
|
7316
|
+
{
|
|
7317
|
+
"kind": "javascript-module",
|
|
7318
|
+
"path": "src/react-components/spinner.ts",
|
|
7319
|
+
"declarations": [
|
|
7320
|
+
{
|
|
7321
|
+
"kind": "variable",
|
|
7322
|
+
"name": "Spinner"
|
|
7323
|
+
}
|
|
7324
|
+
],
|
|
7325
|
+
"exports": [
|
|
7326
|
+
{
|
|
7327
|
+
"kind": "js",
|
|
7328
|
+
"name": "Spinner",
|
|
7329
|
+
"declaration": {
|
|
7330
|
+
"name": "Spinner",
|
|
7331
|
+
"module": "src/react-components/spinner.ts"
|
|
5762
7332
|
}
|
|
5763
7333
|
},
|
|
5764
7334
|
{
|
|
5765
7335
|
"kind": "js",
|
|
5766
|
-
"name": "
|
|
7336
|
+
"name": "SpinnerSize",
|
|
5767
7337
|
"declaration": {
|
|
5768
|
-
"name": "
|
|
5769
|
-
"module": "
|
|
7338
|
+
"name": "SpinnerSize",
|
|
7339
|
+
"module": "../atoms/spinner/spinner.component"
|
|
5770
7340
|
}
|
|
5771
7341
|
}
|
|
5772
7342
|
]
|
|
5773
7343
|
},
|
|
5774
7344
|
{
|
|
5775
7345
|
"kind": "javascript-module",
|
|
5776
|
-
"path": "src/
|
|
7346
|
+
"path": "src/react-components/vault-manager.ts",
|
|
5777
7347
|
"declarations": [
|
|
5778
7348
|
{
|
|
5779
|
-
"kind": "
|
|
5780
|
-
"
|
|
5781
|
-
"name": "StyleProcessingController",
|
|
5782
|
-
"members": [
|
|
5783
|
-
{
|
|
5784
|
-
"kind": "field",
|
|
5785
|
-
"name": "host",
|
|
5786
|
-
"type": {
|
|
5787
|
-
"text": "ReactiveControllerHost & LitElement"
|
|
5788
|
-
}
|
|
5789
|
-
},
|
|
5790
|
-
{
|
|
5791
|
-
"kind": "field",
|
|
5792
|
-
"name": "cssVarCache",
|
|
5793
|
-
"privacy": "private",
|
|
5794
|
-
"static": true,
|
|
5795
|
-
"default": "new Map<string, string>()"
|
|
5796
|
-
},
|
|
5797
|
-
{
|
|
5798
|
-
"kind": "method",
|
|
5799
|
-
"name": "processCustomStyles",
|
|
5800
|
-
"return": {
|
|
5801
|
-
"type": {
|
|
5802
|
-
"text": "void"
|
|
5803
|
-
}
|
|
5804
|
-
},
|
|
5805
|
-
"parameters": [
|
|
5806
|
-
{
|
|
5807
|
-
"name": "jsonString",
|
|
5808
|
-
"type": {
|
|
5809
|
-
"text": "string"
|
|
5810
|
-
},
|
|
5811
|
-
"description": "The JSON string representing custom styles."
|
|
5812
|
-
}
|
|
5813
|
-
],
|
|
5814
|
-
"description": "Processes the customStyles JSON string.\nExpected JSON contains only CSS variable properties in camelCase."
|
|
5815
|
-
},
|
|
5816
|
-
{
|
|
5817
|
-
"kind": "method",
|
|
5818
|
-
"name": "isValidCssProperty",
|
|
5819
|
-
"privacy": "private",
|
|
5820
|
-
"return": {
|
|
5821
|
-
"type": {
|
|
5822
|
-
"text": ""
|
|
5823
|
-
}
|
|
5824
|
-
},
|
|
5825
|
-
"parameters": [
|
|
5826
|
-
{
|
|
5827
|
-
"name": "property",
|
|
5828
|
-
"type": {
|
|
5829
|
-
"text": "string"
|
|
5830
|
-
},
|
|
5831
|
-
"description": "The CSS property name to validate."
|
|
5832
|
-
}
|
|
5833
|
-
],
|
|
5834
|
-
"description": "Validates a CSS property name to ensure it follows expected patterns."
|
|
5835
|
-
},
|
|
5836
|
-
{
|
|
5837
|
-
"kind": "method",
|
|
5838
|
-
"name": "isValidCssValue",
|
|
5839
|
-
"privacy": "private",
|
|
5840
|
-
"return": {
|
|
5841
|
-
"type": {
|
|
5842
|
-
"text": ""
|
|
5843
|
-
}
|
|
5844
|
-
},
|
|
5845
|
-
"parameters": [
|
|
5846
|
-
{
|
|
5847
|
-
"name": "value",
|
|
5848
|
-
"type": {
|
|
5849
|
-
"text": "string"
|
|
5850
|
-
},
|
|
5851
|
-
"description": "The CSS value to validate."
|
|
5852
|
-
}
|
|
5853
|
-
],
|
|
5854
|
-
"description": "Validates a CSS value to ensure it only contains safe, expected characters.\nAllowed characters include alphanumerics, whitespace, and common CSS punctuation.\nThis helps prevent CSS injection attacks."
|
|
5855
|
-
},
|
|
5856
|
-
{
|
|
5857
|
-
"kind": "method",
|
|
5858
|
-
"name": "getCssVarName",
|
|
5859
|
-
"privacy": "private",
|
|
5860
|
-
"return": {
|
|
5861
|
-
"type": {
|
|
5862
|
-
"text": ""
|
|
5863
|
-
}
|
|
5864
|
-
},
|
|
5865
|
-
"parameters": [
|
|
5866
|
-
{
|
|
5867
|
-
"name": "key",
|
|
5868
|
-
"type": {
|
|
5869
|
-
"text": "string"
|
|
5870
|
-
},
|
|
5871
|
-
"description": "The camelCase property key"
|
|
5872
|
-
}
|
|
5873
|
-
],
|
|
5874
|
-
"description": "Gets the CSS variable name for a camelCase property key.\nUses caching for performance."
|
|
5875
|
-
},
|
|
5876
|
-
{
|
|
5877
|
-
"kind": "method",
|
|
5878
|
-
"name": "applyStyles",
|
|
5879
|
-
"privacy": "private",
|
|
5880
|
-
"return": {
|
|
5881
|
-
"type": {
|
|
5882
|
-
"text": "void"
|
|
5883
|
-
}
|
|
5884
|
-
},
|
|
5885
|
-
"parameters": [
|
|
5886
|
-
{
|
|
5887
|
-
"name": "styles",
|
|
5888
|
-
"type": {
|
|
5889
|
-
"text": "StylesObject"
|
|
5890
|
-
},
|
|
5891
|
-
"description": "An object with style keys and corresponding CSS values."
|
|
5892
|
-
}
|
|
5893
|
-
],
|
|
5894
|
-
"description": "Transforms a styles object into CSS variables and applies them to the host element.\nEach key (in camelCase) is converted into a kebab-case CSS variable prefixed with '--'.\nOnly valid CSS properties and values are applied."
|
|
5895
|
-
},
|
|
5896
|
-
{
|
|
5897
|
-
"kind": "method",
|
|
5898
|
-
"name": "removeStyle",
|
|
5899
|
-
"return": {
|
|
5900
|
-
"type": {
|
|
5901
|
-
"text": "void"
|
|
5902
|
-
}
|
|
5903
|
-
},
|
|
5904
|
-
"parameters": [
|
|
5905
|
-
{
|
|
5906
|
-
"name": "key",
|
|
5907
|
-
"type": {
|
|
5908
|
-
"text": "string"
|
|
5909
|
-
},
|
|
5910
|
-
"description": "The camelCase property key to remove"
|
|
5911
|
-
}
|
|
5912
|
-
],
|
|
5913
|
-
"description": "Removes a specific CSS variable from the host element"
|
|
5914
|
-
},
|
|
5915
|
-
{
|
|
5916
|
-
"kind": "method",
|
|
5917
|
-
"name": "clearAllStyles",
|
|
5918
|
-
"return": {
|
|
5919
|
-
"type": {
|
|
5920
|
-
"text": "void"
|
|
5921
|
-
}
|
|
5922
|
-
},
|
|
5923
|
-
"description": "Removes all custom styles from the host element"
|
|
5924
|
-
},
|
|
5925
|
-
{
|
|
5926
|
-
"kind": "method",
|
|
5927
|
-
"name": "hostDisconnected",
|
|
5928
|
-
"return": {
|
|
5929
|
-
"type": {
|
|
5930
|
-
"text": "void"
|
|
5931
|
-
}
|
|
5932
|
-
},
|
|
5933
|
-
"description": "Optional cleanup when the host is disconnected"
|
|
5934
|
-
}
|
|
5935
|
-
]
|
|
7349
|
+
"kind": "variable",
|
|
7350
|
+
"name": "VaultManager"
|
|
5936
7351
|
}
|
|
5937
7352
|
],
|
|
5938
7353
|
"exports": [
|
|
5939
7354
|
{
|
|
5940
7355
|
"kind": "js",
|
|
5941
|
-
"name": "
|
|
7356
|
+
"name": "VaultManager",
|
|
5942
7357
|
"declaration": {
|
|
5943
|
-
"name": "
|
|
5944
|
-
"module": "src/
|
|
7358
|
+
"name": "VaultManager",
|
|
7359
|
+
"module": "src/react-components/vault-manager.ts"
|
|
5945
7360
|
}
|
|
5946
7361
|
}
|
|
5947
7362
|
]
|
|
@@ -6337,6 +7752,14 @@
|
|
|
6337
7752
|
"module": "src/types/sdk.ts"
|
|
6338
7753
|
}
|
|
6339
7754
|
},
|
|
7755
|
+
{
|
|
7756
|
+
"kind": "js",
|
|
7757
|
+
"name": "Payment",
|
|
7758
|
+
"declaration": {
|
|
7759
|
+
"name": "Payment",
|
|
7760
|
+
"module": "src/types/sdk.ts"
|
|
7761
|
+
}
|
|
7762
|
+
},
|
|
6340
7763
|
{
|
|
6341
7764
|
"kind": "js",
|
|
6342
7765
|
"name": "PaymentCardVaultedMethod",
|
|
@@ -6385,6 +7808,14 @@
|
|
|
6385
7808
|
"module": "src/types/sdk.ts"
|
|
6386
7809
|
}
|
|
6387
7810
|
},
|
|
7811
|
+
{
|
|
7812
|
+
"kind": "js",
|
|
7813
|
+
"name": "PrimerClientError",
|
|
7814
|
+
"declaration": {
|
|
7815
|
+
"name": "PrimerClientError",
|
|
7816
|
+
"module": "src/types/sdk.ts"
|
|
7817
|
+
}
|
|
7818
|
+
},
|
|
6388
7819
|
{
|
|
6389
7820
|
"kind": "js",
|
|
6390
7821
|
"name": "StripeAchCustomerDetails",
|
|
@@ -6948,10 +8379,11 @@
|
|
|
6948
8379
|
"kind": "field",
|
|
6949
8380
|
"name": "variant",
|
|
6950
8381
|
"type": {
|
|
6951
|
-
"text": "'primary'
|
|
8382
|
+
"text": "| 'primary'\n | 'secondary'\n | 'tertiary'"
|
|
6952
8383
|
},
|
|
6953
8384
|
"default": "'primary'",
|
|
6954
|
-
"attribute": "variant"
|
|
8385
|
+
"attribute": "variant",
|
|
8386
|
+
"reflects": true
|
|
6955
8387
|
},
|
|
6956
8388
|
{
|
|
6957
8389
|
"kind": "field",
|
|
@@ -6978,10 +8410,10 @@
|
|
|
6978
8410
|
"kind": "field",
|
|
6979
8411
|
"name": "buttonType",
|
|
6980
8412
|
"type": {
|
|
6981
|
-
"text": "'button'
|
|
8413
|
+
"text": "| 'button'\n | 'submit'\n | 'reset'"
|
|
6982
8414
|
},
|
|
6983
8415
|
"default": "'button'",
|
|
6984
|
-
"attribute": "
|
|
8416
|
+
"attribute": "type"
|
|
6985
8417
|
},
|
|
6986
8418
|
{
|
|
6987
8419
|
"kind": "field",
|
|
@@ -7041,7 +8473,7 @@
|
|
|
7041
8473
|
{
|
|
7042
8474
|
"name": "variant",
|
|
7043
8475
|
"type": {
|
|
7044
|
-
"text": "'primary'
|
|
8476
|
+
"text": "| 'primary'\n | 'secondary'\n | 'tertiary'"
|
|
7045
8477
|
},
|
|
7046
8478
|
"default": "'primary'",
|
|
7047
8479
|
"fieldName": "variant"
|
|
@@ -7064,9 +8496,9 @@
|
|
|
7064
8496
|
"fieldName": "loading"
|
|
7065
8497
|
},
|
|
7066
8498
|
{
|
|
7067
|
-
"name": "
|
|
8499
|
+
"name": "type",
|
|
7068
8500
|
"type": {
|
|
7069
|
-
"text": "'button'
|
|
8501
|
+
"text": "| 'button'\n | 'submit'\n | 'reset'"
|
|
7070
8502
|
},
|
|
7071
8503
|
"default": "'button'",
|
|
7072
8504
|
"fieldName": "buttonType"
|
|
@@ -7162,7 +8594,8 @@
|
|
|
7162
8594
|
"text": "'complete' | 'failure'"
|
|
7163
8595
|
},
|
|
7164
8596
|
"default": "'complete'",
|
|
7165
|
-
"attribute": "type"
|
|
8597
|
+
"attribute": "type",
|
|
8598
|
+
"reflects": true
|
|
7166
8599
|
},
|
|
7167
8600
|
{
|
|
7168
8601
|
"kind": "field",
|
|
@@ -7170,7 +8603,8 @@
|
|
|
7170
8603
|
"type": {
|
|
7171
8604
|
"text": "string | undefined"
|
|
7172
8605
|
},
|
|
7173
|
-
"attribute": "description"
|
|
8606
|
+
"attribute": "description",
|
|
8607
|
+
"reflects": true
|
|
7174
8608
|
}
|
|
7175
8609
|
],
|
|
7176
8610
|
"attributes": [
|
|
@@ -7771,7 +9205,8 @@
|
|
|
7771
9205
|
"text": "string"
|
|
7772
9206
|
},
|
|
7773
9207
|
"default": "'var(--primer-color-icon-primary)'",
|
|
7774
|
-
"attribute": "color"
|
|
9208
|
+
"attribute": "color",
|
|
9209
|
+
"reflects": true
|
|
7775
9210
|
},
|
|
7776
9211
|
{
|
|
7777
9212
|
"kind": "field",
|
|
@@ -7780,7 +9215,8 @@
|
|
|
7780
9215
|
"text": "'lg' | 'md' | 'sm'"
|
|
7781
9216
|
},
|
|
7782
9217
|
"default": "'lg'",
|
|
7783
|
-
"attribute": "size"
|
|
9218
|
+
"attribute": "size",
|
|
9219
|
+
"reflects": true
|
|
7784
9220
|
},
|
|
7785
9221
|
{
|
|
7786
9222
|
"kind": "field",
|
|
@@ -9685,6 +11121,16 @@
|
|
|
9685
11121
|
"description": "CardFormComponent serves as a container for card input components.\nIt handles form submission, validation, and provides context to child components.",
|
|
9686
11122
|
"name": "CardFormComponent",
|
|
9687
11123
|
"members": [
|
|
11124
|
+
{
|
|
11125
|
+
"kind": "field",
|
|
11126
|
+
"name": "hideLabels",
|
|
11127
|
+
"type": {
|
|
11128
|
+
"text": "boolean"
|
|
11129
|
+
},
|
|
11130
|
+
"default": "false",
|
|
11131
|
+
"attribute": "hide-labels",
|
|
11132
|
+
"reflects": true
|
|
11133
|
+
},
|
|
9688
11134
|
{
|
|
9689
11135
|
"kind": "field",
|
|
9690
11136
|
"name": "hasAssignedContent",
|
|
@@ -9735,7 +11181,7 @@
|
|
|
9735
11181
|
"name": "setupCardFormTask",
|
|
9736
11182
|
"privacy": "private",
|
|
9737
11183
|
"readonly": true,
|
|
9738
|
-
"default": "new Task(this, { task: async ([cardManager]) => { if (!cardManager?.manager) return initialState; const { manager } = cardManager; const { cardNumberInput, expiryInput, cvvInput } = manager.createHostedInputs(); this.cardFormProvider.setValue({ cardNumberInput, expiryInput, cvvInput, setCardholderName: (val: string) => manager.setCardholderName(val), setCardNetwork: (val: string) => { this.selectedCardNetwork = val; }, validate: () => manager.validate(), submit: (args) => manager.submit(args), }); return true; }, args: () => [this.paymentManagers.get('PAYMENT_CARD')], })",
|
|
11184
|
+
"default": "new Task(this, { task: async ([cardManager]) => { if (!cardManager?.manager) return initialState; const { manager } = cardManager; const { cardNumberInput, expiryInput, cvvInput } = manager.createHostedInputs(); this.cardFormProvider.setValue({ cardNumberInput, expiryInput, cvvInput, setCardholderName: (val: string) => manager.setCardholderName(val), setCardNetwork: (val: string) => { this.selectedCardNetwork = val; }, validate: () => manager.validate(), submit: (args) => manager.submit(args), hideLabels: this.hideLabels, }); return true; }, args: () => [this.paymentManagers.get('PAYMENT_CARD')], })",
|
|
9739
11185
|
"description": "Task to set up the card form with hosted inputs"
|
|
9740
11186
|
},
|
|
9741
11187
|
{
|
|
@@ -9794,6 +11240,14 @@
|
|
|
9794
11240
|
}
|
|
9795
11241
|
],
|
|
9796
11242
|
"attributes": [
|
|
11243
|
+
{
|
|
11244
|
+
"name": "hide-labels",
|
|
11245
|
+
"type": {
|
|
11246
|
+
"text": "boolean"
|
|
11247
|
+
},
|
|
11248
|
+
"default": "false",
|
|
11249
|
+
"fieldName": "hideLabels"
|
|
11250
|
+
},
|
|
9797
11251
|
{
|
|
9798
11252
|
"name": "paymentManagers",
|
|
9799
11253
|
"type": {
|