@bunnyapp/components 1.0.68-beta.9 → 1.0.68
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/cjs/index.js +302 -444
- package/dist/cjs/src/components/Checkout/Checkout.d.ts +3 -1
- package/dist/cjs/src/components/Checkout/checkoutUtils.d.ts +1 -1
- package/dist/cjs/src/components/PaymentForm/PaymentForm.d.ts +1 -2
- package/dist/cjs/src/components/Quote/AcceptQuoteModal.d.ts +1 -1
- package/dist/cjs/src/components/Signup/PaymentForms.d.ts +0 -6
- package/dist/cjs/src/components/Signup/Signup.d.ts +3 -1
- package/dist/cjs/src/components/Subscriptions/PlanManager/PlanManager.d.ts +4 -0
- package/dist/cjs/src/components/Subscriptions/PlanManager/PlanPicker/checkoutBar/PlanPickerCheckoutBar.d.ts +1 -1
- package/dist/cjs/src/components/Subscriptions/PlanManager/PlanPicker/planPickerMobile/PriceListCardMobile.d.ts +1 -1
- package/dist/cjs/src/components/Subscriptions/PlanManager/PlanPicker/priceListCard/PriceListCardDescription.d.ts +1 -1
- package/dist/cjs/src/contexts/PaymentContext.d.ts +1 -1
- package/dist/cjs/src/graphql/mutations/accountSignup.d.ts +2 -1
- package/dist/cjs/src/graphql/mutations/quoteAccountSignup.d.ts +2 -3
- package/dist/cjs/src/graphql/mutations/quoteAddCoupon.d.ts +8 -0
- package/dist/cjs/src/hooks/quotes/useSendAcceptQuote.d.ts +2 -1
- package/dist/cjs/src/hooks/usePaymentPlugins.d.ts +3 -24
- package/dist/esm/index.js +287 -448
- package/dist/esm/src/components/Checkout/Checkout.d.ts +3 -1
- package/dist/esm/src/components/Checkout/checkoutUtils.d.ts +1 -1
- package/dist/esm/src/components/PaymentForm/PaymentForm.d.ts +1 -2
- package/dist/esm/src/components/Quote/AcceptQuoteModal.d.ts +1 -1
- package/dist/esm/src/components/Signup/PaymentForms.d.ts +0 -6
- package/dist/esm/src/components/Signup/Signup.d.ts +3 -1
- package/dist/esm/src/components/Subscriptions/PlanManager/PlanManager.d.ts +4 -0
- package/dist/esm/src/components/Subscriptions/PlanManager/PlanPicker/checkoutBar/PlanPickerCheckoutBar.d.ts +1 -1
- package/dist/esm/src/components/Subscriptions/PlanManager/PlanPicker/planPickerMobile/PriceListCardMobile.d.ts +1 -1
- package/dist/esm/src/components/Subscriptions/PlanManager/PlanPicker/priceListCard/PriceListCardDescription.d.ts +1 -1
- package/dist/esm/src/contexts/PaymentContext.d.ts +1 -1
- package/dist/esm/src/graphql/mutations/accountSignup.d.ts +2 -1
- package/dist/esm/src/graphql/mutations/quoteAccountSignup.d.ts +2 -3
- package/dist/esm/src/graphql/mutations/quoteAddCoupon.d.ts +8 -0
- package/dist/esm/src/hooks/quotes/useSendAcceptQuote.d.ts +2 -1
- package/dist/esm/src/hooks/usePaymentPlugins.d.ts +3 -24
- package/dist/index.d.ts +4 -3
- package/package.json +6 -4
- package/dist/cjs/src/components/Signup/CheckoutSummary.d.ts +0 -11
- package/dist/cjs/src/graphql/mutations/quoteChangeAddCoupon.d.ts +0 -8
- package/dist/cjs/src/graphql/mutations/quoteChangeRemoveCoupon.d.ts +0 -8
- package/dist/esm/src/components/Signup/CheckoutSummary.d.ts +0 -11
- package/dist/esm/src/graphql/mutations/quoteChangeAddCoupon.d.ts +0 -8
- package/dist/esm/src/graphql/mutations/quoteChangeRemoveCoupon.d.ts +0 -8
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { PaymentMethod } from '@bunnyapp/common';
|
|
2
2
|
import { CheckoutProps } from '../PaymentForm/PaymentFormTypes';
|
|
3
3
|
interface CheckoutComponentProps extends CheckoutProps {
|
|
4
|
+
isMobile: boolean;
|
|
5
|
+
token?: string;
|
|
4
6
|
storedPaymentMethod?: PaymentMethod;
|
|
5
7
|
}
|
|
6
|
-
declare const Checkout: ({ onCancel, onSuccess, onFail, invoice, open, quote, selectedPriceList, }: CheckoutComponentProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
8
|
+
declare const Checkout: ({ onCancel, onSuccess, onFail, invoice, open, quote, selectedPriceList, token, }: CheckoutComponentProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
7
9
|
export default Checkout;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Quote } from
|
|
1
|
+
import { Quote } from "@bunnyapp/common";
|
|
2
2
|
export declare const getQuoteAmountDue: (quote: Quote) => number;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FormattedInvoice, PluginData, Quote } from '@bunnyapp/common';
|
|
2
|
-
export declare const PaymentForm: ({ invoice, onFail, onPaymentSuccess, onPaymentHoldSuccess, quote, accountId, onSavePaymentMethod, onRemovePaymentMethod, onSetDefaultPaymentMethod,
|
|
2
|
+
export declare const PaymentForm: ({ invoice, onFail, onPaymentSuccess, onPaymentHoldSuccess, quote, accountId, onSavePaymentMethod, onRemovePaymentMethod, onSetDefaultPaymentMethod, overrideToken, customCheckoutFunction, currencyId: currencyIdFromProps, paymentHoldOptions, }: {
|
|
3
3
|
invoice?: FormattedInvoice | undefined;
|
|
4
4
|
quote?: Quote | undefined;
|
|
5
5
|
onFail: (error: any) => void;
|
|
@@ -9,7 +9,6 @@ export declare const PaymentForm: ({ invoice, onFail, onPaymentSuccess, onPaymen
|
|
|
9
9
|
onRemovePaymentMethod?: (() => void) | undefined;
|
|
10
10
|
onSetDefaultPaymentMethod?: (() => void) | undefined;
|
|
11
11
|
accountId?: string | undefined;
|
|
12
|
-
entityId?: string | undefined;
|
|
13
12
|
overrideToken?: string | undefined;
|
|
14
13
|
customCheckoutFunction?: ((plugin: PluginData | undefined) => Promise<any>) | undefined;
|
|
15
14
|
currencyId?: string | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { FormattedQuote } from
|
|
1
|
+
import { FormattedQuote } from "@bunnyapp/common";
|
|
2
2
|
declare const AcceptQuoteModal: ({ acceptBoxVisible, formattedQuote, sendAccept, setAcceptBoxVisible, setIsAccepting, isSendAcceptPending, }: {
|
|
3
3
|
acceptBoxVisible: boolean;
|
|
4
4
|
formattedQuote: FormattedQuote;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import '../../styles/index.less';
|
|
3
3
|
import { ShadowType } from '../../types/shadowType';
|
|
4
|
-
export default function Signup({ companyName, priceListCode, returnUrl, couponCode, className, shadow, style, }: {
|
|
4
|
+
export default function Signup({ companyName, priceListCode, returnUrl, couponCode, className, shadow, style, entityId, }: {
|
|
5
5
|
/** The company name to display on the signup page */
|
|
6
6
|
companyName: string;
|
|
7
7
|
/** The price list code to use for the signup */
|
|
@@ -16,4 +16,6 @@ export default function Signup({ companyName, priceListCode, returnUrl, couponCo
|
|
|
16
16
|
shadow?: ShadowType;
|
|
17
17
|
/** A custom style to apply to the component */
|
|
18
18
|
style?: React.CSSProperties;
|
|
19
|
+
/** The entity ID to use for the signup */
|
|
20
|
+
entityId: string;
|
|
19
21
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EditingQuoteDataType } from '
|
|
1
|
+
import { EditingQuoteDataType } from '../../PlanManager';
|
|
2
2
|
declare const PlanPickerCheckoutBarWrapper: ({ editingQuote, setEditingQuoteData, handlePortalErrors, onCheckoutSuccess, }: {
|
|
3
3
|
editingQuote?: EditingQuoteDataType | undefined;
|
|
4
4
|
setEditingQuoteData?: ((quoteId?: string, isTrial?: boolean) => void) | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Feature, PriceList, Subscription } from
|
|
1
|
+
import { Feature, PriceList, Subscription } from "@bunnyapp/common";
|
|
2
2
|
declare const PriceListCardMobile: ({ description, disableOnClick, feature, isPriceListCurrentSubscription, isSelected, onClick, priceList, subscriptionPlan, trialRemainingDays, }: {
|
|
3
3
|
description: string;
|
|
4
4
|
disableOnClick: boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const accountSignup: ({ token, apiHost, accountId, quoteId, paymentToken, paymentMethodId, pluginId, priceListCode, }: {
|
|
1
|
+
declare const accountSignup: ({ token, apiHost, accountId, quoteId, paymentToken, paymentMethodId, pluginId, priceListCode, entityId, }: {
|
|
2
2
|
token: string;
|
|
3
3
|
apiHost: string;
|
|
4
4
|
accountId: string;
|
|
@@ -7,5 +7,6 @@ declare const accountSignup: ({ token, apiHost, accountId, quoteId, paymentToken
|
|
|
7
7
|
paymentMethodId?: string | undefined;
|
|
8
8
|
pluginId: string;
|
|
9
9
|
priceListCode: string;
|
|
10
|
+
entityId: string;
|
|
10
11
|
}) => Promise<any>;
|
|
11
12
|
export default accountSignup;
|
|
@@ -1,15 +1,14 @@
|
|
|
1
|
-
import BillingDetails from '../../types/billingDetails';
|
|
2
1
|
type BillingContact = {
|
|
3
2
|
firstName: string;
|
|
4
3
|
lastName: string;
|
|
5
4
|
email: string;
|
|
6
5
|
};
|
|
7
|
-
declare const quoteAccountSignup: ({ token, apiHost, priceListCode, accountName, billingContact,
|
|
6
|
+
declare const quoteAccountSignup: ({ token, apiHost, priceListCode, accountName, billingContact, entityId, }: {
|
|
8
7
|
token?: string | undefined;
|
|
9
8
|
apiHost: string;
|
|
10
9
|
priceListCode: string;
|
|
11
10
|
accountName: string;
|
|
12
11
|
billingContact: BillingContact;
|
|
13
|
-
|
|
12
|
+
entityId: string;
|
|
14
13
|
}) => Promise<any>;
|
|
15
14
|
export default quoteAccountSignup;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Quote } from '@bunnyapp/common';
|
|
2
|
+
declare const quoteAddCoupon: ({ quoteId, couponCode, token, apiHost, }: {
|
|
3
|
+
quoteId?: string | undefined;
|
|
4
|
+
couponCode?: string | undefined;
|
|
5
|
+
token?: string | undefined;
|
|
6
|
+
apiHost: string;
|
|
7
|
+
}) => Promise<Quote>;
|
|
8
|
+
export default quoteAddCoupon;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
declare const useSendAcceptQuote: ({ quoteId, apiHost, token, }: {
|
|
2
|
+
declare const useSendAcceptQuote: ({ onTokenExpired, quoteId, apiHost, token, }: {
|
|
3
|
+
onTokenExpired?: (() => void) | undefined;
|
|
3
4
|
quoteId?: string | undefined;
|
|
4
5
|
apiHost: string;
|
|
5
6
|
token?: string | undefined;
|
|
@@ -1,30 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
entities: string[];
|
|
4
|
-
guid: string;
|
|
5
|
-
hidden: boolean;
|
|
6
|
-
id: string;
|
|
7
|
-
name: string;
|
|
8
|
-
status: string;
|
|
9
|
-
type: string;
|
|
10
|
-
webhookEnabled: boolean;
|
|
11
|
-
components: {
|
|
12
|
-
frontend: {
|
|
13
|
-
name: string;
|
|
14
|
-
scenarios: string[];
|
|
15
|
-
}[];
|
|
16
|
-
backend: {
|
|
17
|
-
name: string;
|
|
18
|
-
access: string[];
|
|
19
|
-
}[];
|
|
20
|
-
};
|
|
21
|
-
};
|
|
22
|
-
export declare const usePaymentPlugins: ({ apiHost, token, selectedEntityId, }: {
|
|
1
|
+
import { PluginData } from '@bunnyapp/common';
|
|
2
|
+
export declare const usePaymentPlugins: ({ apiHost, token }: {
|
|
23
3
|
apiHost: string;
|
|
24
4
|
token?: string | undefined;
|
|
25
|
-
selectedEntityId?: string | null | undefined;
|
|
26
5
|
}) => {
|
|
27
|
-
paymentPlugins:
|
|
6
|
+
paymentPlugins: PluginData[] | undefined;
|
|
28
7
|
isFetched: boolean;
|
|
29
8
|
};
|
|
30
9
|
export default usePaymentPlugins;
|