@huyooo/ui 0.12.2 → 0.13.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.
- package/dist/CustomTable-BBcd4nNL.js +278 -0
- package/dist/PaySubscriptions-Dxg7GZJx.js +1194 -0
- package/dist/PricingPlans-CAKsTY8G.js +405 -0
- package/dist/{ReferrerReferees-DhS91Ulf.js → ReferrerReferees-Hh88qOrp.js} +1 -1
- package/dist/UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-24U6PK1y.js +521 -0
- package/dist/{WidthContainer-ektCstwj.js → WidthContainer-B2cjwKvY.js} +2 -2
- package/dist/common/paymentReturn.d.ts +9 -0
- package/dist/common.js +2 -2
- package/dist/components/Pay/PaymentReturnPage.vue.d.ts +7 -0
- package/dist/components/UserMenu/parts/UserSubscriptionBaseInformation.vue.d.ts +2 -0
- package/dist/composables/Billing/useBillingPlans.d.ts +39 -0
- package/dist/composables/Billing/useBillingSubscriptionSummary.d.ts +52 -0
- package/dist/composables/Billing/usePaymentReturn.d.ts +33 -0
- package/dist/composables/UserMenu/useUserMenu.d.ts +1 -1
- package/dist/main.js +154 -147
- package/dist/pay.d.ts +3 -0
- package/dist/pay.js +15 -8
- package/dist/referrer.js +1 -1
- package/dist/style.css +1 -1
- package/dist/user.js +1 -1
- package/dist/utils/billingFetch.d.ts +1 -0
- package/package.json +1 -1
- package/dist/CustomTable-BUkwlbzN.js +0 -272
- package/dist/PaySubscriptions-DS4kJNb_.js +0 -531
- package/dist/PricingPlans-CfW_mv5_.js +0 -279
- package/dist/UserMenuInvitationsItem.vue_vue_type_script_setup_true_lang-9cF5hBYc.js +0 -508
|
@@ -14,6 +14,19 @@ export interface BillingSubscriptionSummaryCurrent {
|
|
|
14
14
|
currentPeriodStart?: string | null;
|
|
15
15
|
currentPeriodEnd?: string | null;
|
|
16
16
|
cancelAtPeriodEnd?: boolean;
|
|
17
|
+
pendingChange?: {
|
|
18
|
+
type: string;
|
|
19
|
+
productId: string;
|
|
20
|
+
productName?: string;
|
|
21
|
+
priceId: string;
|
|
22
|
+
priceNickname?: string;
|
|
23
|
+
interval?: string;
|
|
24
|
+
intervalCount?: number;
|
|
25
|
+
unitAmount?: number;
|
|
26
|
+
currency?: string;
|
|
27
|
+
requestedAt?: string | null;
|
|
28
|
+
effectiveAt?: string | null;
|
|
29
|
+
} | null;
|
|
17
30
|
canceledAt?: string | null;
|
|
18
31
|
endedAt?: string | null;
|
|
19
32
|
createAt?: string;
|
|
@@ -91,6 +104,19 @@ export declare function useBillingSubscriptionSummary(): {
|
|
|
91
104
|
currentPeriodStart?: string | null | undefined;
|
|
92
105
|
currentPeriodEnd?: string | null | undefined;
|
|
93
106
|
cancelAtPeriodEnd?: boolean | undefined;
|
|
107
|
+
pendingChange?: {
|
|
108
|
+
type: string;
|
|
109
|
+
productId: string;
|
|
110
|
+
productName?: string | undefined;
|
|
111
|
+
priceId: string;
|
|
112
|
+
priceNickname?: string | undefined;
|
|
113
|
+
interval?: string | undefined;
|
|
114
|
+
intervalCount?: number | undefined;
|
|
115
|
+
unitAmount?: number | undefined;
|
|
116
|
+
currency?: string | undefined;
|
|
117
|
+
requestedAt?: string | null | undefined;
|
|
118
|
+
effectiveAt?: string | null | undefined;
|
|
119
|
+
} | null | undefined;
|
|
94
120
|
canceledAt?: string | null | undefined;
|
|
95
121
|
endedAt?: string | null | undefined;
|
|
96
122
|
createAt?: string | undefined;
|
|
@@ -158,6 +184,19 @@ export declare function useBillingSubscriptionSummary(): {
|
|
|
158
184
|
currentPeriodStart?: string | null | undefined;
|
|
159
185
|
currentPeriodEnd?: string | null | undefined;
|
|
160
186
|
cancelAtPeriodEnd?: boolean | undefined;
|
|
187
|
+
pendingChange?: {
|
|
188
|
+
type: string;
|
|
189
|
+
productId: string;
|
|
190
|
+
productName?: string | undefined;
|
|
191
|
+
priceId: string;
|
|
192
|
+
priceNickname?: string | undefined;
|
|
193
|
+
interval?: string | undefined;
|
|
194
|
+
intervalCount?: number | undefined;
|
|
195
|
+
unitAmount?: number | undefined;
|
|
196
|
+
currency?: string | undefined;
|
|
197
|
+
requestedAt?: string | null | undefined;
|
|
198
|
+
effectiveAt?: string | null | undefined;
|
|
199
|
+
} | null | undefined;
|
|
161
200
|
canceledAt?: string | null | undefined;
|
|
162
201
|
endedAt?: string | null | undefined;
|
|
163
202
|
createAt?: string | undefined;
|
|
@@ -225,6 +264,19 @@ export declare function useBillingSubscriptionSummary(): {
|
|
|
225
264
|
currentPeriodStart?: string | null | undefined;
|
|
226
265
|
currentPeriodEnd?: string | null | undefined;
|
|
227
266
|
cancelAtPeriodEnd?: boolean | undefined;
|
|
267
|
+
pendingChange?: {
|
|
268
|
+
type: string;
|
|
269
|
+
productId: string;
|
|
270
|
+
productName?: string | undefined;
|
|
271
|
+
priceId: string;
|
|
272
|
+
priceNickname?: string | undefined;
|
|
273
|
+
interval?: string | undefined;
|
|
274
|
+
intervalCount?: number | undefined;
|
|
275
|
+
unitAmount?: number | undefined;
|
|
276
|
+
currency?: string | undefined;
|
|
277
|
+
requestedAt?: string | null | undefined;
|
|
278
|
+
effectiveAt?: string | null | undefined;
|
|
279
|
+
} | null | undefined;
|
|
228
280
|
canceledAt?: string | null | undefined;
|
|
229
281
|
endedAt?: string | null | undefined;
|
|
230
282
|
createAt?: string | undefined;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { PaymentReturnScene } from '../../common/paymentReturn';
|
|
2
|
+
export interface PaymentVerifyResult {
|
|
3
|
+
success: boolean;
|
|
4
|
+
status: string;
|
|
5
|
+
message?: string;
|
|
6
|
+
pointsAdded?: number;
|
|
7
|
+
}
|
|
8
|
+
/** 按支付场景查询订单/账单是否已支付完成 */
|
|
9
|
+
export declare function verifyPaymentStatus(scene: PaymentReturnScene, orderId: string): Promise<PaymentVerifyResult>;
|
|
10
|
+
/** 轮询支付结果,供结果页与等待弹窗复用 */
|
|
11
|
+
export declare function usePaymentPolling(): {
|
|
12
|
+
checking: import('vue').Ref<boolean, boolean>;
|
|
13
|
+
statusText: import('vue').Ref<string, string>;
|
|
14
|
+
startPolling: (input: {
|
|
15
|
+
scene: PaymentReturnScene;
|
|
16
|
+
orderId: string;
|
|
17
|
+
onSuccess: (result: PaymentVerifyResult) => void;
|
|
18
|
+
onWaiting?: (result: PaymentVerifyResult) => void;
|
|
19
|
+
onError?: (error: unknown) => void;
|
|
20
|
+
}) => void;
|
|
21
|
+
stopPolling: () => void;
|
|
22
|
+
verifyNow: (scene: PaymentReturnScene, orderId: string) => Promise<PaymentVerifyResult>;
|
|
23
|
+
};
|
|
24
|
+
/** 支付结果页:解析 query、轮询并在成功后跳转 */
|
|
25
|
+
export declare function usePaymentReturnPage(getReturnTo: () => string): {
|
|
26
|
+
phase: import('vue').Ref<"success" | "failed" | "loading", "success" | "failed" | "loading">;
|
|
27
|
+
message: import('vue').Ref<string, string>;
|
|
28
|
+
checking: import('vue').Ref<boolean, boolean>;
|
|
29
|
+
statusText: import('vue').Ref<string, string>;
|
|
30
|
+
confirmPayment: (scene: PaymentReturnScene, orderId: string) => Promise<void>;
|
|
31
|
+
stopPolling: () => void;
|
|
32
|
+
verifyNow: (scene: PaymentReturnScene, orderId: string) => Promise<PaymentVerifyResult>;
|
|
33
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ComputedRef, Ref } from 'vue';
|
|
2
2
|
export interface OpenSubscriptionsOptions {
|
|
3
|
-
target?: "overview" | "
|
|
3
|
+
target?: "overview" | "subscriptions" | "points" | "usage" | "invoices" | "quotas";
|
|
4
4
|
}
|
|
5
5
|
export interface UseUserMenuReturn {
|
|
6
6
|
isOpen: ComputedRef<boolean>;
|