DefinitelyTyped/types/stripe-checkout/index.d.ts
Nathan Shively-Sanders f0ce987bc1 Update project urls to match NPM url
Note that this *trivially* updates project urls by adding the NPM url to
the end, even when the urls are almost identical or the DT one is
outdated. I'll clean up the urls in a later commit.

This PR is unfinished! Please do not merge it yet.
2019-02-11 17:10:55 -08:00

42 lines
1.1 KiB
TypeScript

// Type definitions for Stripe Checkout 1.0
// Project: https://stripe.com/checkout, https://github.com/matthewmueller/stripe-checkout
// Definitions by: Chris Wrench <https://github.com/cgwrench>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
/// <reference types="stripe-v3"/>
interface StripeCheckoutStatic {
configure(options: StripeCheckoutOptions): StripeCheckoutHandler;
}
interface StripeCheckoutHandler {
open(options?: StripeCheckoutOptions): void;
close(): void;
}
interface StripeCheckoutOptions {
key?: string;
token?(token: stripe.Token): void;
source?(source: stripe.Source): void;
image?: string;
name?: string;
description?: string;
amount?: number;
locale?: string;
currency?: string;
panelLabel?: string;
zipCode?: boolean;
billingAddress?: boolean;
email?: string;
shippingAddress?: boolean;
label?: string;
allowRememberMe?: boolean;
bitcoin?: boolean;
alipay?: boolean | 'auto';
alipayReusable?: boolean;
opened?(): void;
closed?(): void;
}
declare var StripeCheckout: StripeCheckoutStatic;