@polyv/lottery-ui-launch 2.6.0-rc-20260625.4 → 2.7.0

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.
Files changed (4) hide show
  1. package/index.es.d.ts +77 -7
  2. package/index.es.js +35140 -28675
  3. package/index.umd.js +570 -560
  4. package/package.json +1 -1
package/index.es.d.ts CHANGED
@@ -2,7 +2,13 @@ import { ComponentOptionsMixin } from 'vue';
2
2
  import { DefineComponent } from 'vue';
3
3
  import { ExtractPropTypes } from 'vue';
4
4
  import type { Lottery } from '@polyv/lottery-sdk';
5
+ import { LotteryCondition } from '@polyv/lottery-sdk';
6
+ import { LotteryInviteType } from '@polyv/lottery-sdk';
7
+ import { LotteryLaunchForm } from '@polyv/lottery-sdk';
5
8
  import type { Questionnaire } from '@polyv/questionnaire-sdk';
9
+ import { ValidatorFunction } from 'vue-types/dist/types';
10
+ import { VueTypeDef } from 'vue-types';
11
+ import { VueTypeValidableDef } from 'vue-types';
6
12
 
7
13
  export declare const ChoiceLotteryActivity: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, Readonly<ExtractPropTypes< {}>>, {}>;
8
14
 
@@ -10,7 +16,75 @@ export declare const LotteryDialog: DefineComponent< {}, {
10
16
  openDialog: typeof openDialog;
11
17
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, Readonly<ExtractPropTypes< {}>>, {}>;
12
18
 
13
- export declare const LotteryForm: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, Readonly<ExtractPropTypes< {}>>, {}>;
19
+ export declare const LotteryForm: DefineComponent< {
20
+ mode: VueTypeDef<LotteryFormMode> & {
21
+ default: LotteryFormMode;
22
+ };
23
+ initialFormData: VueTypeValidableDef<LotteryLaunchForm, ValidatorFunction<LotteryLaunchForm>>;
24
+ submitting: VueTypeValidableDef<boolean, ValidatorFunction<boolean>> & {
25
+ default: boolean;
26
+ } & {
27
+ default: boolean;
28
+ };
29
+ }, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
30
+ cancel: (arg?: void | undefined) => void;
31
+ submit: (arg: Required<LotteryLaunchForm>) => void;
32
+ }, string, Readonly<ExtractPropTypes< {
33
+ mode: VueTypeDef<LotteryFormMode> & {
34
+ default: LotteryFormMode;
35
+ };
36
+ initialFormData: VueTypeValidableDef<LotteryLaunchForm, ValidatorFunction<LotteryLaunchForm>>;
37
+ submitting: VueTypeValidableDef<boolean, ValidatorFunction<boolean>> & {
38
+ default: boolean;
39
+ } & {
40
+ default: boolean;
41
+ };
42
+ }>>, {
43
+ mode: LotteryFormMode;
44
+ submitting: boolean;
45
+ }>;
46
+
47
+ export declare interface LotteryFormEmits {
48
+ submit: (formData: Required<LotteryLaunchForm>) => void;
49
+ cancel: () => void;
50
+ }
51
+
52
+ export declare type LotteryFormMode = 'launch' | 'preset';
53
+
54
+ export declare interface LotteryFormProps {
55
+ /**
56
+ * 表单模式
57
+ * @default launch
58
+ */
59
+ mode?: LotteryFormMode;
60
+ /** 初始化表单数据 */
61
+ initialFormData?: LotteryLaunchForm;
62
+ /** 宿主是否正在提交 */
63
+ submitting?: boolean;
64
+ }
65
+
66
+ export declare interface LotteryLaunchConfig {
67
+ /**
68
+ * 支持的邀请方式
69
+ * @default 'poster'
70
+ */
71
+ supportInviteType?: LotteryInviteType | LotteryInviteType[];
72
+ /**
73
+ * 邀请海报开关
74
+ * @default false
75
+ */
76
+ invitePosterEnabled?: boolean;
77
+ /** 不支持的参与条件 */
78
+ excludedConditions?: LotteryCondition[];
79
+ /** 打开分组管理 */
80
+ onManageGroup?: () => void;
81
+ /** 打开邀请海报配置 */
82
+ onConfigureInvitePoster?: () => void;
83
+ }
84
+
85
+ export declare interface LotteryLaunchProvideData extends LotteryProvideData {
86
+ getLaunchConfig?: () => LotteryLaunchConfig;
87
+ }
14
88
 
15
89
  export declare const LotteryList: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, Readonly<ExtractPropTypes< {}>>, {}>;
16
90
 
@@ -55,13 +129,9 @@ export declare const uiLotteryLaunchEvents: {
55
129
  readonly OpenLotteryWinners: "ui-lottery-launch.OpenLotteryWinners";
56
130
  };
57
131
 
58
- export declare const useLotteryGlobalProvide = (injectData: LotteryProvideData) => {
59
- provide(LOTTERY_GLOBAL_INJECT_KEY, injectData);
60
- };
132
+ export declare function useLotteryGlobalProvide(injectData: LotteryLaunchProvideData): void;
61
133
 
62
- export declare function useWebviewPopupProvide(options: WebviewPopupProvideOptions) {
63
- provide(WEBVIEW_POPUP_PROVIDE_KEY, options);
64
- }
134
+ export declare function useWebviewPopupProvide(options: WebviewPopupProvideOptions): void;
65
135
 
66
136
  export declare interface WebviewPopupProvideOptions {
67
137
  isClientWebview: boolean;