@primer-io/primer-js 0.3.1 → 0.3.3

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.
@@ -331,6 +331,19 @@ export type PaymentMethodComponentProps = {
331
331
  paymentMethods?: PaymentMethodsContextType;
332
332
  };
333
333
 
334
+ export type PaymentMethodContainerComponentProps = {
335
+ /** */
336
+ include?: string | undefined;
337
+ /** */
338
+ exclude?: string | undefined;
339
+ /** */
340
+ disabled?: boolean;
341
+ /** */
342
+ paymentMethods?: PaymentMethodsContextType;
343
+ /** */
344
+ clientOptions?: ClientOptionsContextType;
345
+ };
346
+
334
347
  export type PrimerCheckoutCompleteComponentProps = {};
335
348
 
336
349
  export type PrimerCheckoutErrorComponentProps = {
@@ -829,6 +842,13 @@ export type CustomElements = {
829
842
  */
830
843
  "primer-payment-method": Partial<PaymentMethodComponentProps & BaseProps & BaseEvents>;
831
844
 
845
+ /**
846
+ *
847
+ * ---
848
+ *
849
+ */
850
+ "primer-payment-method-container": Partial<PaymentMethodContainerComponentProps & BaseProps & BaseEvents>;
851
+
832
852
  /**
833
853
  *
834
854
  * ---
@@ -1221,13 +1221,14 @@ declare class VaultManagerController extends CompositeStateController<PrimerChec
1221
1221
  private itemController;
1222
1222
  private _vaultManager;
1223
1223
  private _options;
1224
+ private createVaultManagerFn;
1224
1225
  constructor(host: PrimerCheckoutType);
1225
1226
  /**
1226
- * Initialize the vault manager with additional options
1227
- * @param vaultManager - The HeadlessVaultManager instance
1228
- * @param options - Additional initialization options
1227
+ * Initialize the vault manager with a factory function and options
1228
+ * @param createVaultManagerFn - Bound function to create vault manager when needed
1229
+ * @param options - Vault configuration options
1229
1230
  */
1230
- initializeVaultManager(vaultManager: HeadlessVaultManager, options?: VaultManagerInitOptions): void;
1231
+ initializeVaultManager(createVaultManagerFn: PrimerHeadlessCheckout["createVaultManager"] | null, options?: VaultManagerInitOptions): void;
1231
1232
  get vaultManager(): HeadlessVaultManager | null;
1232
1233
  set vaultManager(vaultManager: HeadlessVaultManager | null);
1233
1234
  get options(): VaultManagerInitOptions | null;
@@ -2103,6 +2104,21 @@ declare global {
2103
2104
  }
2104
2105
  }
2105
2106
  export type ClientOptionsContextType = PrimerCheckoutOptions | null;
2107
+ declare class PaymentMethodContainerComponent extends LitElement {
2108
+ static styles: import("lit").CSSResult[];
2109
+ include?: string;
2110
+ exclude?: string;
2111
+ disabled: boolean;
2112
+ paymentMethods: PaymentMethodsContextType;
2113
+ clientOptions: ClientOptionsContextType;
2114
+ private getFilteredMethods;
2115
+ render(): typeof nothing | import("lit-html").TemplateResult<1>;
2116
+ }
2117
+ declare global {
2118
+ interface HTMLElementTagNameMap {
2119
+ "primer-payment-method-container": PaymentMethodContainerComponent;
2120
+ }
2121
+ }
2106
2122
  export type AchField = "firstName" | "lastName" | "emailAddress";
2107
2123
  export interface AchFormState {
2108
2124
  value: string;
@@ -3230,6 +3246,7 @@ export {
3230
3246
  InputWrapperComponent as InputWrapper,
3231
3247
  NativePaymentComponent as NativePayment,
3232
3248
  PaymentMethodComponent as PaymentMethod,
3249
+ PaymentMethodContainerComponent as PaymentMethodContainer,
3233
3250
  PortalComponent as Portal,
3234
3251
  PrimerCheckoutCompleteComponent as PrimerCheckoutComplete,
3235
3252
  PrimerCheckoutErrorComponent as PrimerCheckoutFailure,