@stripe/connect-js 3.3.18-preview-1 → 3.3.20-preview-1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -28,10 +28,12 @@ const ConnectElementCustomMethodConfig = {
28
28
  "issuing-card": {
29
29
  setDefaultCard: _defaultCard => {},
30
30
  setCardSwitching: _cardSwitching => {},
31
- setFetchEphemeralKey: _fetchEphemeralKey => {}
31
+ setFetchEphemeralKey: _fetchEphemeralKey => {},
32
+ setShowSpendControls: _showSpendControls => {}
32
33
  },
33
34
  "issuing-cards-list": {
34
- setFetchEphemeralKey: _fetchEphemeralKey => {}
35
+ setFetchEphemeralKey: _fetchEphemeralKey => {},
36
+ setShowSpendControls: _showSpendControls => {}
35
37
  },
36
38
  "financial-account": {
37
39
  setFinancialAccount: _financialAccount => {}
@@ -59,12 +61,23 @@ const ConnectElementCustomMethodConfig = {
59
61
  setOnFinancingsLoaded: _listener => {}
60
62
  },
61
63
  "capital-financing-application": {
62
- setOnApplicationSubmitted: _listener => {}
64
+ setOnApplicationSubmitted: _listener => {},
65
+ setPrivacyPolicyUrl: _privacyPolicyUrl => {},
66
+ setHowCapitalWorksUrl: _howCapitalWorksUrl => {}
63
67
  },
64
68
  "capital-financing-promotion": {
65
69
  setLayout: _layout => {},
66
70
  setOnApplicationSubmitted: _listener => {},
67
- setOnEligibleFinancingOfferLoaded: _listener => {}
71
+ setOnEligibleFinancingOfferLoaded: _listener => {},
72
+ setPrivacyPolicyUrl: _privacyPolicyUrl => {},
73
+ setHowCapitalWorksUrl: _howCapitalWorksUrl => {},
74
+ setEligibilityCriteriaUrl: _eligibilityCriteriaUrl => {}
75
+ },
76
+ "reporting-chart": {
77
+ setReportName: _reportName => {},
78
+ setIntervalStart: _intervalStart => {},
79
+ setIntervalEnd: _intervalEnd => {},
80
+ setIntervalType: _intervalType => {}
68
81
  }
69
82
  };
70
83
 
@@ -91,7 +104,8 @@ const componentNameMapping = {
91
104
  balances: "stripe-connect-balances",
92
105
  "payouts-list": "stripe-connect-payouts-list",
93
106
  "app-install": "stripe-connect-app-install",
94
- "app-viewport": "stripe-connect-app-viewport"
107
+ "app-viewport": "stripe-connect-app-viewport",
108
+ "reporting-chart": "stripe-connect-reporting-chart"
95
109
  };
96
110
  const EXISTING_SCRIPT_MESSAGE = "loadConnect was called but an existing Connect.js script already exists in the document; existing script parameters will be used";
97
111
  const V0_URL = "https://connect-js.stripe.com/v0.1/connect.js";
@@ -234,7 +248,7 @@ const createWrapper = stripeConnect => {
234
248
  sdk: true,
235
249
  sdkOptions: {
236
250
  // This will be replaced by the npm package version when bundling
237
- sdkVersion: "3.3.18-preview-1"
251
+ sdkVersion: "3.3.20-preview-1"
238
252
  }
239
253
  })
240
254
  }));
package/dist/connect.js CHANGED
@@ -32,10 +32,12 @@ const ConnectElementCustomMethodConfig = {
32
32
  "issuing-card": {
33
33
  setDefaultCard: _defaultCard => {},
34
34
  setCardSwitching: _cardSwitching => {},
35
- setFetchEphemeralKey: _fetchEphemeralKey => {}
35
+ setFetchEphemeralKey: _fetchEphemeralKey => {},
36
+ setShowSpendControls: _showSpendControls => {}
36
37
  },
37
38
  "issuing-cards-list": {
38
- setFetchEphemeralKey: _fetchEphemeralKey => {}
39
+ setFetchEphemeralKey: _fetchEphemeralKey => {},
40
+ setShowSpendControls: _showSpendControls => {}
39
41
  },
40
42
  "financial-account": {
41
43
  setFinancialAccount: _financialAccount => {}
@@ -63,12 +65,23 @@ const ConnectElementCustomMethodConfig = {
63
65
  setOnFinancingsLoaded: _listener => {}
64
66
  },
65
67
  "capital-financing-application": {
66
- setOnApplicationSubmitted: _listener => {}
68
+ setOnApplicationSubmitted: _listener => {},
69
+ setPrivacyPolicyUrl: _privacyPolicyUrl => {},
70
+ setHowCapitalWorksUrl: _howCapitalWorksUrl => {}
67
71
  },
68
72
  "capital-financing-promotion": {
69
73
  setLayout: _layout => {},
70
74
  setOnApplicationSubmitted: _listener => {},
71
- setOnEligibleFinancingOfferLoaded: _listener => {}
75
+ setOnEligibleFinancingOfferLoaded: _listener => {},
76
+ setPrivacyPolicyUrl: _privacyPolicyUrl => {},
77
+ setHowCapitalWorksUrl: _howCapitalWorksUrl => {},
78
+ setEligibilityCriteriaUrl: _eligibilityCriteriaUrl => {}
79
+ },
80
+ "reporting-chart": {
81
+ setReportName: _reportName => {},
82
+ setIntervalStart: _intervalStart => {},
83
+ setIntervalEnd: _intervalEnd => {},
84
+ setIntervalType: _intervalType => {}
72
85
  }
73
86
  };
74
87
 
@@ -95,7 +108,8 @@ const componentNameMapping = {
95
108
  balances: "stripe-connect-balances",
96
109
  "payouts-list": "stripe-connect-payouts-list",
97
110
  "app-install": "stripe-connect-app-install",
98
- "app-viewport": "stripe-connect-app-viewport"
111
+ "app-viewport": "stripe-connect-app-viewport",
112
+ "reporting-chart": "stripe-connect-reporting-chart"
99
113
  };
100
114
  const EXISTING_SCRIPT_MESSAGE = "loadConnect was called but an existing Connect.js script already exists in the document; existing script parameters will be used";
101
115
  const V0_URL = "https://connect-js.stripe.com/v0.1/connect.js";
@@ -238,7 +252,7 @@ const createWrapper = stripeConnect => {
238
252
  sdk: true,
239
253
  sdkOptions: {
240
254
  // This will be replaced by the npm package version when bundling
241
- sdkVersion: "3.3.18-preview-1"
255
+ sdkVersion: "3.3.20-preview-1"
242
256
  }
243
257
  })
244
258
  }));
package/dist/pure.esm.js CHANGED
@@ -28,10 +28,12 @@ const ConnectElementCustomMethodConfig = {
28
28
  "issuing-card": {
29
29
  setDefaultCard: _defaultCard => {},
30
30
  setCardSwitching: _cardSwitching => {},
31
- setFetchEphemeralKey: _fetchEphemeralKey => {}
31
+ setFetchEphemeralKey: _fetchEphemeralKey => {},
32
+ setShowSpendControls: _showSpendControls => {}
32
33
  },
33
34
  "issuing-cards-list": {
34
- setFetchEphemeralKey: _fetchEphemeralKey => {}
35
+ setFetchEphemeralKey: _fetchEphemeralKey => {},
36
+ setShowSpendControls: _showSpendControls => {}
35
37
  },
36
38
  "financial-account": {
37
39
  setFinancialAccount: _financialAccount => {}
@@ -59,12 +61,23 @@ const ConnectElementCustomMethodConfig = {
59
61
  setOnFinancingsLoaded: _listener => {}
60
62
  },
61
63
  "capital-financing-application": {
62
- setOnApplicationSubmitted: _listener => {}
64
+ setOnApplicationSubmitted: _listener => {},
65
+ setPrivacyPolicyUrl: _privacyPolicyUrl => {},
66
+ setHowCapitalWorksUrl: _howCapitalWorksUrl => {}
63
67
  },
64
68
  "capital-financing-promotion": {
65
69
  setLayout: _layout => {},
66
70
  setOnApplicationSubmitted: _listener => {},
67
- setOnEligibleFinancingOfferLoaded: _listener => {}
71
+ setOnEligibleFinancingOfferLoaded: _listener => {},
72
+ setPrivacyPolicyUrl: _privacyPolicyUrl => {},
73
+ setHowCapitalWorksUrl: _howCapitalWorksUrl => {},
74
+ setEligibilityCriteriaUrl: _eligibilityCriteriaUrl => {}
75
+ },
76
+ "reporting-chart": {
77
+ setReportName: _reportName => {},
78
+ setIntervalStart: _intervalStart => {},
79
+ setIntervalEnd: _intervalEnd => {},
80
+ setIntervalType: _intervalType => {}
68
81
  }
69
82
  };
70
83
 
@@ -91,7 +104,8 @@ const componentNameMapping = {
91
104
  balances: "stripe-connect-balances",
92
105
  "payouts-list": "stripe-connect-payouts-list",
93
106
  "app-install": "stripe-connect-app-install",
94
- "app-viewport": "stripe-connect-app-viewport"
107
+ "app-viewport": "stripe-connect-app-viewport",
108
+ "reporting-chart": "stripe-connect-reporting-chart"
95
109
  };
96
110
  const EXISTING_SCRIPT_MESSAGE = "loadConnect was called but an existing Connect.js script already exists in the document; existing script parameters will be used";
97
111
  const V0_URL = "https://connect-js.stripe.com/v0.1/connect.js";
@@ -234,7 +248,7 @@ const createWrapper = stripeConnect => {
234
248
  sdk: true,
235
249
  sdkOptions: {
236
250
  // This will be replaced by the npm package version when bundling
237
- sdkVersion: "3.3.18-preview-1"
251
+ sdkVersion: "3.3.20-preview-1"
238
252
  }
239
253
  })
240
254
  }));
package/dist/pure.js CHANGED
@@ -32,10 +32,12 @@ const ConnectElementCustomMethodConfig = {
32
32
  "issuing-card": {
33
33
  setDefaultCard: _defaultCard => {},
34
34
  setCardSwitching: _cardSwitching => {},
35
- setFetchEphemeralKey: _fetchEphemeralKey => {}
35
+ setFetchEphemeralKey: _fetchEphemeralKey => {},
36
+ setShowSpendControls: _showSpendControls => {}
36
37
  },
37
38
  "issuing-cards-list": {
38
- setFetchEphemeralKey: _fetchEphemeralKey => {}
39
+ setFetchEphemeralKey: _fetchEphemeralKey => {},
40
+ setShowSpendControls: _showSpendControls => {}
39
41
  },
40
42
  "financial-account": {
41
43
  setFinancialAccount: _financialAccount => {}
@@ -63,12 +65,23 @@ const ConnectElementCustomMethodConfig = {
63
65
  setOnFinancingsLoaded: _listener => {}
64
66
  },
65
67
  "capital-financing-application": {
66
- setOnApplicationSubmitted: _listener => {}
68
+ setOnApplicationSubmitted: _listener => {},
69
+ setPrivacyPolicyUrl: _privacyPolicyUrl => {},
70
+ setHowCapitalWorksUrl: _howCapitalWorksUrl => {}
67
71
  },
68
72
  "capital-financing-promotion": {
69
73
  setLayout: _layout => {},
70
74
  setOnApplicationSubmitted: _listener => {},
71
- setOnEligibleFinancingOfferLoaded: _listener => {}
75
+ setOnEligibleFinancingOfferLoaded: _listener => {},
76
+ setPrivacyPolicyUrl: _privacyPolicyUrl => {},
77
+ setHowCapitalWorksUrl: _howCapitalWorksUrl => {},
78
+ setEligibilityCriteriaUrl: _eligibilityCriteriaUrl => {}
79
+ },
80
+ "reporting-chart": {
81
+ setReportName: _reportName => {},
82
+ setIntervalStart: _intervalStart => {},
83
+ setIntervalEnd: _intervalEnd => {},
84
+ setIntervalType: _intervalType => {}
72
85
  }
73
86
  };
74
87
 
@@ -95,7 +108,8 @@ const componentNameMapping = {
95
108
  balances: "stripe-connect-balances",
96
109
  "payouts-list": "stripe-connect-payouts-list",
97
110
  "app-install": "stripe-connect-app-install",
98
- "app-viewport": "stripe-connect-app-viewport"
111
+ "app-viewport": "stripe-connect-app-viewport",
112
+ "reporting-chart": "stripe-connect-reporting-chart"
99
113
  };
100
114
  const EXISTING_SCRIPT_MESSAGE = "loadConnect was called but an existing Connect.js script already exists in the document; existing script parameters will be used";
101
115
  const V0_URL = "https://connect-js.stripe.com/v0.1/connect.js";
@@ -238,7 +252,7 @@ const createWrapper = stripeConnect => {
238
252
  sdk: true,
239
253
  sdkOptions: {
240
254
  // This will be replaced by the npm package version when bundling
241
- sdkVersion: "3.3.18-preview-1"
255
+ sdkVersion: "3.3.20-preview-1"
242
256
  }
243
257
  })
244
258
  }));
@@ -1,6 +1,6 @@
1
1
  import { IStripeConnectInitParams, StripeConnectInstance, ConnectElementTagName } from "../types";
2
2
  export type LoadConnectAndInitialize = (initParams: IStripeConnectInitParams) => StripeConnectInstance;
3
- export type ConnectElementHTMLName = "stripe-connect-payments" | "stripe-connect-payouts" | "stripe-connect-payment-details" | "stripe-connect-account-onboarding" | "stripe-connect-payment-method-settings" | "stripe-connect-account-management" | "stripe-connect-notification-banner" | "stripe-connect-instant-payouts" | "stripe-connect-issuing-card" | "stripe-connect-issuing-cards-list" | "stripe-connect-financial-account" | "stripe-connect-financial-account-transactions" | "stripe-connect-capital-financing" | "stripe-connect-capital-financing-application" | "stripe-connect-capital-financing-promotion" | "stripe-connect-capital-overview" | "stripe-connect-documents" | "stripe-connect-tax-registrations" | "stripe-connect-tax-settings" | "stripe-connect-balances" | "stripe-connect-payouts-list" | "stripe-connect-app-install" | "stripe-connect-app-viewport";
3
+ export type ConnectElementHTMLName = "stripe-connect-payments" | "stripe-connect-payouts" | "stripe-connect-payment-details" | "stripe-connect-account-onboarding" | "stripe-connect-payment-method-settings" | "stripe-connect-account-management" | "stripe-connect-notification-banner" | "stripe-connect-instant-payouts" | "stripe-connect-issuing-card" | "stripe-connect-issuing-cards-list" | "stripe-connect-financial-account" | "stripe-connect-financial-account-transactions" | "stripe-connect-capital-financing" | "stripe-connect-capital-financing-application" | "stripe-connect-capital-financing-promotion" | "stripe-connect-capital-overview" | "stripe-connect-documents" | "stripe-connect-tax-registrations" | "stripe-connect-tax-settings" | "stripe-connect-balances" | "stripe-connect-payouts-list" | "stripe-connect-app-install" | "stripe-connect-app-viewport" | "stripe-connect-reporting-chart";
4
4
  export declare const componentNameMapping: Record<ConnectElementTagName, ConnectElementHTMLName>;
5
5
  type StripeConnectInstanceExtended = StripeConnectInstance & {
6
6
  debugInstance: () => Promise<StripeConnectInstance>;
@@ -36,6 +36,8 @@ export type FinancingProductType = {
36
36
  productType: "standard" | "refill" | "none";
37
37
  };
38
38
  export type FinancingPromotionLayoutType = "full" | "banner";
39
+ export type IntervalType = "day" | "week" | "month" | "quarter" | "year";
40
+ export type ReportName = "gross_volume" | "net_volume";
39
41
  export type EmbeddedErrorType =
40
42
  /**
41
43
  * Failure to connect to Stripe's API.
@@ -90,9 +92,11 @@ export declare const ConnectElementCustomMethodConfig: {
90
92
  setDefaultCard: (_defaultCard: string | undefined) => void;
91
93
  setCardSwitching: (_cardSwitching: boolean | undefined) => void;
92
94
  setFetchEphemeralKey: (_fetchEphemeralKey: FetchEphemeralKeyFunction | undefined) => void;
95
+ setShowSpendControls: (_showSpendControls: boolean | undefined) => void;
93
96
  };
94
97
  "issuing-cards-list": {
95
98
  setFetchEphemeralKey: (_fetchEphemeralKey: FetchEphemeralKeyFunction | undefined) => void;
99
+ setShowSpendControls: (_showSpendControls: boolean | undefined) => void;
96
100
  };
97
101
  "financial-account": {
98
102
  setFinancialAccount: (_financialAccount: string) => void;
@@ -123,10 +127,21 @@ export declare const ConnectElementCustomMethodConfig: {
123
127
  };
124
128
  "capital-financing-application": {
125
129
  setOnApplicationSubmitted: (_listener: (() => void) | undefined) => void;
130
+ setPrivacyPolicyUrl: (_privacyPolicyUrl: string | undefined) => void;
131
+ setHowCapitalWorksUrl: (_howCapitalWorksUrl: string | undefined) => void;
126
132
  };
127
133
  "capital-financing-promotion": {
128
134
  setLayout: (_layout: FinancingPromotionLayoutType | undefined) => void;
129
135
  setOnApplicationSubmitted: (_listener: (() => void) | undefined) => void;
130
136
  setOnEligibleFinancingOfferLoaded: (_listener: (({ productType }: FinancingProductType) => void) | undefined) => void;
137
+ setPrivacyPolicyUrl: (_privacyPolicyUrl: string | undefined) => void;
138
+ setHowCapitalWorksUrl: (_howCapitalWorksUrl: string | undefined) => void;
139
+ setEligibilityCriteriaUrl: (_eligibilityCriteriaUrl: string | undefined) => void;
140
+ };
141
+ "reporting-chart": {
142
+ setReportName: (_reportName: ReportName) => void;
143
+ setIntervalStart: (_intervalStart: Date | undefined) => void;
144
+ setIntervalEnd: (_intervalEnd: Date | undefined) => void;
145
+ setIntervalType: (_intervalType: IntervalType | undefined) => void;
131
146
  };
132
147
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stripe/connect-js",
3
- "version": "3.3.18-preview-1",
3
+ "version": "3.3.20-preview-1",
4
4
  "description": "Connect.js loading utility package",
5
5
  "main": "dist/connect.js",
6
6
  "module": "dist/connect.esm.js",
package/src/shared.ts CHANGED
@@ -36,7 +36,8 @@ export type ConnectElementHTMLName =
36
36
  | "stripe-connect-balances"
37
37
  | "stripe-connect-payouts-list"
38
38
  | "stripe-connect-app-install"
39
- | "stripe-connect-app-viewport";
39
+ | "stripe-connect-app-viewport"
40
+ | "stripe-connect-reporting-chart";
40
41
 
41
42
  export const componentNameMapping: Record<
42
43
  ConnectElementTagName,
@@ -66,7 +67,8 @@ export const componentNameMapping: Record<
66
67
  balances: "stripe-connect-balances",
67
68
  "payouts-list": "stripe-connect-payouts-list",
68
69
  "app-install": "stripe-connect-app-install",
69
- "app-viewport": "stripe-connect-app-viewport"
70
+ "app-viewport": "stripe-connect-app-viewport",
71
+ "reporting-chart": "stripe-connect-reporting-chart"
70
72
  };
71
73
 
72
74
  type StripeConnectInstanceExtended = StripeConnectInstance & {
package/types/config.ts CHANGED
@@ -49,6 +49,10 @@ export type FinancingProductType = {
49
49
 
50
50
  export type FinancingPromotionLayoutType = "full" | "banner";
51
51
 
52
+ export type IntervalType = "day" | "week" | "month" | "quarter" | "year";
53
+
54
+ export type ReportName = "gross_volume" | "net_volume";
55
+
52
56
  export type EmbeddedErrorType =
53
57
  /**
54
58
  * Failure to connect to Stripe's API.
@@ -128,12 +132,14 @@ export const ConnectElementCustomMethodConfig = {
128
132
  setCardSwitching: (_cardSwitching: boolean | undefined): void => {},
129
133
  setFetchEphemeralKey: (
130
134
  _fetchEphemeralKey: FetchEphemeralKeyFunction | undefined
131
- ): void => {}
135
+ ): void => {},
136
+ setShowSpendControls: (_showSpendControls: boolean | undefined): void => {}
132
137
  },
133
138
  "issuing-cards-list": {
134
139
  setFetchEphemeralKey: (
135
140
  _fetchEphemeralKey: FetchEphemeralKeyFunction | undefined
136
- ): void => {}
141
+ ): void => {},
142
+ setShowSpendControls: (_showSpendControls: boolean | undefined): void => {}
137
143
  },
138
144
  "financial-account": {
139
145
  setFinancialAccount: (_financialAccount: string): void => {}
@@ -173,7 +179,11 @@ export const ConnectElementCustomMethodConfig = {
173
179
  ): void => {}
174
180
  },
175
181
  "capital-financing-application": {
176
- setOnApplicationSubmitted: (_listener: (() => void) | undefined): void => {}
182
+ setOnApplicationSubmitted: (
183
+ _listener: (() => void) | undefined
184
+ ): void => {},
185
+ setPrivacyPolicyUrl: (_privacyPolicyUrl: string | undefined): void => {},
186
+ setHowCapitalWorksUrl: (_howCapitalWorksUrl: string | undefined): void => {}
177
187
  },
178
188
  "capital-financing-promotion": {
179
189
  setLayout: (_layout: FinancingPromotionLayoutType | undefined): void => {},
@@ -182,6 +192,19 @@ export const ConnectElementCustomMethodConfig = {
182
192
  ): void => {},
183
193
  setOnEligibleFinancingOfferLoaded: (
184
194
  _listener: (({ productType }: FinancingProductType) => void) | undefined
195
+ ): void => {},
196
+ setPrivacyPolicyUrl: (_privacyPolicyUrl: string | undefined): void => {},
197
+ setHowCapitalWorksUrl: (
198
+ _howCapitalWorksUrl: string | undefined
199
+ ): void => {},
200
+ setEligibilityCriteriaUrl: (
201
+ _eligibilityCriteriaUrl: string | undefined
185
202
  ): void => {}
203
+ },
204
+ "reporting-chart": {
205
+ setReportName: (_reportName: ReportName): void => {},
206
+ setIntervalStart: (_intervalStart: Date | undefined): void => {},
207
+ setIntervalEnd: (_intervalEnd: Date | undefined): void => {},
208
+ setIntervalType: (_intervalType: IntervalType | undefined): void => {}
186
209
  }
187
210
  };
package/types/shared.d.ts CHANGED
@@ -473,4 +473,5 @@ export type ConnectElementTagName =
473
473
  | "balances"
474
474
  | "payouts-list"
475
475
  | "app-install"
476
- | "app-viewport";
476
+ | "app-viewport"
477
+ | "reporting-chart";