@oinone/kunlun-event 6.4.3 → 7.2.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.
- package/dist/oinone-kunlun-event.esm.js +1 -15
- package/dist/types/index.d.ts +1 -1
- package/dist/types/src/bus/abstract/AbstractEventConsumer.d.ts +17 -17
- package/dist/types/src/bus/abstract/AbstractEventEngine.d.ts +21 -21
- package/dist/types/src/bus/abstract/AbstractEventProducer.d.ts +15 -15
- package/dist/types/src/bus/abstract/index.d.ts +2 -2
- package/dist/types/src/bus/bus/basic.d.ts +12 -12
- package/dist/types/src/bus/bus/html-event.d.ts +6 -6
- package/dist/types/src/bus/bus/html-keyboard-event.d.ts +6 -6
- package/dist/types/src/bus/bus/index.d.ts +18 -18
- package/dist/types/src/bus/hook/consumer.d.ts +1 -1
- package/dist/types/src/bus/hook/index.d.ts +2 -2
- package/dist/types/src/bus/hook/producer.d.ts +1 -1
- package/dist/types/src/bus/index.d.ts +5 -5
- package/dist/types/src/bus/operator/consumer.d.ts +11 -11
- package/dist/types/src/bus/operator/index.d.ts +2 -2
- package/dist/types/src/bus/operator/producer.d.ts +10 -10
- package/dist/types/src/bus/spi/consumer.d.ts +8 -8
- package/dist/types/src/bus/spi/index.d.ts +2 -2
- package/dist/types/src/bus/spi/producer.d.ts +8 -8
- package/dist/types/src/bus/typing/basic.d.ts +64 -64
- package/dist/types/src/bus/typing/category.d.ts +5 -5
- package/dist/types/src/bus/typing/index.d.ts +3 -3
- package/dist/types/src/bus/typing/keyboard.d.ts +16 -16
- package/dist/types/src/effects/effectbox.d.ts +3 -3
- package/dist/types/src/effects/fieldEffects.d.ts +61 -61
- package/dist/types/src/effects/index.d.ts +2 -2
- package/dist/types/src/effects/viewEffects.d.ts +69 -69
- package/dist/types/src/helper.d.ts +14 -14
- package/dist/types/src/html-event/basic/AbstractHTMLEventProducer.d.ts +7 -7
- package/dist/types/src/html-event/basic/HTMLEventConsumer.d.ts +4 -4
- package/dist/types/src/html-event/basic/HTMLEventProducer.d.ts +5 -5
- package/dist/types/src/html-event/basic/index.d.ts +3 -3
- package/dist/types/src/html-event/index.d.ts +2 -2
- package/dist/types/src/html-event/keyboard/HTMLKeyboardEventConsumer.d.ts +14 -14
- package/dist/types/src/html-event/keyboard/HTMLKeyboardEventProducer.d.ts +16 -16
- package/dist/types/src/html-event/keyboard/index.d.ts +2 -2
- package/dist/types/src/index.d.ts +6 -6
- package/dist/types/src/lifecycle/heart.d.ts +75 -75
- package/dist/types/src/lifecycle/index.d.ts +2 -2
- package/dist/types/src/lifecycle/lifecycle.d.ts +7 -7
- package/dist/types/src/typing/index.d.ts +1 -1
- package/dist/types/src/typing/lifecycle.d.ts +92 -92
- package/package.json +20 -9
- package/src/bus/abstract/AbstractEventConsumer.ts +1 -9
- package/src/bus/abstract/AbstractEventEngine.ts +1 -1
- package/src/bus/abstract/AbstractEventProducer.ts +1 -8
- package/src/bus/bus/basic.ts +1 -10
- package/src/bus/bus/html-event.ts +1 -9
- package/src/bus/bus/html-keyboard-event.ts +1 -9
- package/src/bus/operator/consumer.ts +1 -8
- package/src/bus/operator/producer.ts +1 -1
- package/src/bus/spi/consumer.ts +2 -2
- package/src/bus/spi/producer.ts +2 -2
- package/src/bus/typing/basic.ts +1 -1
- package/src/bus/typing/keyboard.ts +1 -1
- package/src/html-event/basic/AbstractHTMLEventProducer.ts +1 -1
- package/src/html-event/basic/HTMLEventConsumer.ts +1 -10
- package/src/html-event/basic/HTMLEventProducer.ts +1 -1
- package/src/html-event/keyboard/HTMLKeyboardEventConsumer.ts +1 -13
- package/src/html-event/keyboard/HTMLKeyboardEventProducer.ts +1 -10
- package/rollup.config.js +0 -4
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { EventConsumerConfig, EventMessage } from './basic';
|
|
2
|
-
export interface KeyboardEventMessage extends EventMessage<KeyboardEvent> {
|
|
3
|
-
code: string;
|
|
4
|
-
key: string;
|
|
5
|
-
ctrl: boolean;
|
|
6
|
-
alt: boolean;
|
|
7
|
-
shift: boolean;
|
|
8
|
-
}
|
|
9
|
-
export
|
|
10
|
-
export
|
|
11
|
-
export declare const KeyboardTypes: KeyboardType[];
|
|
12
|
-
export interface HTMLKeyboardEventConsumerConfig extends EventConsumerConfig {
|
|
13
|
-
ctrl?: boolean;
|
|
14
|
-
alt?: boolean;
|
|
15
|
-
shift?: boolean;
|
|
16
|
-
}
|
|
1
|
+
import type { EventConsumerConfig, EventMessage } from './basic';
|
|
2
|
+
export interface KeyboardEventMessage extends EventMessage<KeyboardEvent> {
|
|
3
|
+
code: string;
|
|
4
|
+
key: string;
|
|
5
|
+
ctrl: boolean;
|
|
6
|
+
alt: boolean;
|
|
7
|
+
shift: boolean;
|
|
8
|
+
}
|
|
9
|
+
export type KeyboardKeys = '*' | string | string[];
|
|
10
|
+
export type KeyboardType = 'keypress' | 'keyup' | 'keydown';
|
|
11
|
+
export declare const KeyboardTypes: KeyboardType[];
|
|
12
|
+
export interface HTMLKeyboardEventConsumerConfig extends EventConsumerConfig {
|
|
13
|
+
ctrl?: boolean;
|
|
14
|
+
alt?: boolean;
|
|
15
|
+
shift?: boolean;
|
|
16
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { RegistryType, LifeCycleTypes } from '../typing';
|
|
2
|
-
declare function creatEffectHook<V, C>(lifeType: LifeCycleTypes, registryType: RegistryType): (type: string, callback?: (
|
|
3
|
-
export { creatEffectHook };
|
|
1
|
+
import { RegistryType, LifeCycleTypes } from '../typing';
|
|
2
|
+
declare function creatEffectHook<V, C>(lifeType: LifeCycleTypes, registryType: RegistryType): (type: string, callback?: (ctx: C) => void) => void;
|
|
3
|
+
export { creatEffectHook };
|
|
@@ -1,61 +1,61 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* 字段生命周期 字段创建前
|
|
3
|
-
*/
|
|
4
|
-
declare const onFieldBeforeCreate: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
5
|
-
/**
|
|
6
|
-
* 字段生命周期 字段已被创建
|
|
7
|
-
*/
|
|
8
|
-
declare const onFieldCreated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
9
|
-
/**
|
|
10
|
-
* 字段生命周期 字段挂载前
|
|
11
|
-
*/
|
|
12
|
-
declare const onFieldBeforeMount: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
13
|
-
/**
|
|
14
|
-
* 字段生命周期 字段已经挂载在页面上
|
|
15
|
-
*/
|
|
16
|
-
declare const onFieldMounted: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
17
|
-
/**
|
|
18
|
-
* 字段生命周期 字段修改前
|
|
19
|
-
*/
|
|
20
|
-
declare const onFieldBeforeUpdate: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
21
|
-
/**
|
|
22
|
-
* 字段生命周期 字段已被修改
|
|
23
|
-
*/
|
|
24
|
-
declare const onFieldUpdated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
25
|
-
/**
|
|
26
|
-
* 字段生命周期 字段销毁前
|
|
27
|
-
*/
|
|
28
|
-
declare const onFieldBeforeUnmount: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
29
|
-
/**
|
|
30
|
-
* 字段生命周期 字段已被销毁
|
|
31
|
-
*/
|
|
32
|
-
declare const onFieldUnmounted: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
33
|
-
/**
|
|
34
|
-
* 字段生命周期 单字段校验 校验开始
|
|
35
|
-
*/
|
|
36
|
-
declare const onFieldValidateStart: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
37
|
-
/**
|
|
38
|
-
* 字段生命周期 单字段校验 校验成功
|
|
39
|
-
*/
|
|
40
|
-
declare const onFieldValidateSuccess: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
41
|
-
/**
|
|
42
|
-
* 字段生命周期 单字段校验 校验失败
|
|
43
|
-
*/
|
|
44
|
-
declare const onFieldValidateFailed: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
45
|
-
/**
|
|
46
|
-
* 字段生命周期 单字段校验 校验结束
|
|
47
|
-
*/
|
|
48
|
-
declare const onFieldValidateEnd: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
49
|
-
/**
|
|
50
|
-
* 字段生命周期 字段获得焦点
|
|
51
|
-
*/
|
|
52
|
-
declare const onFieldFocus: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
53
|
-
/**
|
|
54
|
-
* 字段生命周期 字段的值发生的修改(只有该字段发生了change方法才会触发,否则不触发)
|
|
55
|
-
*/
|
|
56
|
-
declare const onFieldValueChange: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
57
|
-
/**
|
|
58
|
-
* 字段生命周期 字段失去焦点
|
|
59
|
-
*/
|
|
60
|
-
declare const onFieldBlur: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
61
|
-
export { onFieldBeforeCreate, onFieldCreated, onFieldBeforeMount, onFieldMounted, onFieldBeforeUpdate, onFieldUpdated, onFieldBeforeUnmount, onFieldUnmounted, onFieldValidateStart, onFieldValidateSuccess, onFieldValidateFailed, onFieldValidateEnd, onFieldFocus, onFieldValueChange, onFieldBlur };
|
|
1
|
+
/**
|
|
2
|
+
* 字段生命周期 字段创建前
|
|
3
|
+
*/
|
|
4
|
+
declare const onFieldBeforeCreate: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
5
|
+
/**
|
|
6
|
+
* 字段生命周期 字段已被创建
|
|
7
|
+
*/
|
|
8
|
+
declare const onFieldCreated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
9
|
+
/**
|
|
10
|
+
* 字段生命周期 字段挂载前
|
|
11
|
+
*/
|
|
12
|
+
declare const onFieldBeforeMount: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
13
|
+
/**
|
|
14
|
+
* 字段生命周期 字段已经挂载在页面上
|
|
15
|
+
*/
|
|
16
|
+
declare const onFieldMounted: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
17
|
+
/**
|
|
18
|
+
* 字段生命周期 字段修改前
|
|
19
|
+
*/
|
|
20
|
+
declare const onFieldBeforeUpdate: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
21
|
+
/**
|
|
22
|
+
* 字段生命周期 字段已被修改
|
|
23
|
+
*/
|
|
24
|
+
declare const onFieldUpdated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
25
|
+
/**
|
|
26
|
+
* 字段生命周期 字段销毁前
|
|
27
|
+
*/
|
|
28
|
+
declare const onFieldBeforeUnmount: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
29
|
+
/**
|
|
30
|
+
* 字段生命周期 字段已被销毁
|
|
31
|
+
*/
|
|
32
|
+
declare const onFieldUnmounted: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
33
|
+
/**
|
|
34
|
+
* 字段生命周期 单字段校验 校验开始
|
|
35
|
+
*/
|
|
36
|
+
declare const onFieldValidateStart: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
37
|
+
/**
|
|
38
|
+
* 字段生命周期 单字段校验 校验成功
|
|
39
|
+
*/
|
|
40
|
+
declare const onFieldValidateSuccess: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
41
|
+
/**
|
|
42
|
+
* 字段生命周期 单字段校验 校验失败
|
|
43
|
+
*/
|
|
44
|
+
declare const onFieldValidateFailed: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
45
|
+
/**
|
|
46
|
+
* 字段生命周期 单字段校验 校验结束
|
|
47
|
+
*/
|
|
48
|
+
declare const onFieldValidateEnd: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
49
|
+
/**
|
|
50
|
+
* 字段生命周期 字段获得焦点
|
|
51
|
+
*/
|
|
52
|
+
declare const onFieldFocus: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
53
|
+
/**
|
|
54
|
+
* 字段生命周期 字段的值发生的修改(只有该字段发生了change方法才会触发,否则不触发)
|
|
55
|
+
*/
|
|
56
|
+
declare const onFieldValueChange: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
57
|
+
/**
|
|
58
|
+
* 字段生命周期 字段失去焦点
|
|
59
|
+
*/
|
|
60
|
+
declare const onFieldBlur: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
61
|
+
export { onFieldBeforeCreate, onFieldCreated, onFieldBeforeMount, onFieldMounted, onFieldBeforeUpdate, onFieldUpdated, onFieldBeforeUnmount, onFieldUnmounted, onFieldValidateStart, onFieldValidateSuccess, onFieldValidateFailed, onFieldValidateEnd, onFieldFocus, onFieldValueChange, onFieldBlur };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './fieldEffects';
|
|
2
|
-
export * from './viewEffects';
|
|
1
|
+
export * from './fieldEffects';
|
|
2
|
+
export * from './viewEffects';
|
|
@@ -1,69 +1,69 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* 视图生命周期 视图创建前
|
|
3
|
-
*/
|
|
4
|
-
declare const onViewBeforeCreated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
5
|
-
/**
|
|
6
|
-
* 视图生命周期 视图已被创建
|
|
7
|
-
*/
|
|
8
|
-
declare const onViewCreated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
9
|
-
/**
|
|
10
|
-
* 视图生命周期 视图挂载前
|
|
11
|
-
*/
|
|
12
|
-
declare const onViewBeforeMount: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
13
|
-
/**
|
|
14
|
-
* 视图生命周期 视图已经挂载在页面上
|
|
15
|
-
*/
|
|
16
|
-
declare const onViewMounted: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
17
|
-
/**
|
|
18
|
-
* 视图生命周期 视图修改前
|
|
19
|
-
*/
|
|
20
|
-
declare const onViewBeforeUpdate: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
21
|
-
/**
|
|
22
|
-
* 视图生命周期 视图已被修改
|
|
23
|
-
*/
|
|
24
|
-
declare const onViewUpdated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
25
|
-
/**
|
|
26
|
-
* 视图生命周期 视图销毁前
|
|
27
|
-
*/
|
|
28
|
-
declare const onViewBeforeUnmount: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
29
|
-
/**
|
|
30
|
-
* 视图生命周期 视图已被销毁
|
|
31
|
-
*/
|
|
32
|
-
declare const onViewUnmounted: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
33
|
-
/**
|
|
34
|
-
* 视图生命周期 视图数据提交
|
|
35
|
-
*/
|
|
36
|
-
declare const onViewSubmit: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
37
|
-
/**
|
|
38
|
-
* 视图生命周期 视图数据开始提交
|
|
39
|
-
*/
|
|
40
|
-
declare const onViewSubmitStart: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
41
|
-
/**
|
|
42
|
-
* 视图生命周期 视图数据提交成功
|
|
43
|
-
*/
|
|
44
|
-
declare const onViewSubmitSuccess: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
45
|
-
/**
|
|
46
|
-
* 视图生命周期 视图数据提交失败
|
|
47
|
-
*/
|
|
48
|
-
declare const onViewSubmitFailed: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
49
|
-
/**
|
|
50
|
-
* 视图生命周期 视图数据提交结束
|
|
51
|
-
*/
|
|
52
|
-
declare const onViewSubmitEnd: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
53
|
-
/**
|
|
54
|
-
* 视图生命周期 视图开始校验,只有表单页才会触发
|
|
55
|
-
*/
|
|
56
|
-
declare const onViewValidateStart: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
57
|
-
/**
|
|
58
|
-
* 视图生命周期 视图校验成功,只有表单页才会触发
|
|
59
|
-
*/
|
|
60
|
-
declare const onViewValidateSuccess: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
61
|
-
/**
|
|
62
|
-
* 视图生命周期 视图校验失败,只有表单页才会触发
|
|
63
|
-
*/
|
|
64
|
-
declare const onViewValidateFailed: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
65
|
-
/**
|
|
66
|
-
* 视图生命周期 视图校验结束,只有表单页才会触发
|
|
67
|
-
*/
|
|
68
|
-
declare const onViewValidateEnd: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
69
|
-
export { onViewBeforeCreated, onViewCreated, onViewBeforeMount, onViewMounted, onViewBeforeUpdate, onViewUpdated, onViewBeforeUnmount, onViewUnmounted, onViewSubmit, onViewSubmitStart, onViewSubmitSuccess, onViewSubmitFailed, onViewSubmitEnd, onViewValidateStart, onViewValidateSuccess, onViewValidateFailed, onViewValidateEnd };
|
|
1
|
+
/**
|
|
2
|
+
* 视图生命周期 视图创建前
|
|
3
|
+
*/
|
|
4
|
+
declare const onViewBeforeCreated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
5
|
+
/**
|
|
6
|
+
* 视图生命周期 视图已被创建
|
|
7
|
+
*/
|
|
8
|
+
declare const onViewCreated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
9
|
+
/**
|
|
10
|
+
* 视图生命周期 视图挂载前
|
|
11
|
+
*/
|
|
12
|
+
declare const onViewBeforeMount: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
13
|
+
/**
|
|
14
|
+
* 视图生命周期 视图已经挂载在页面上
|
|
15
|
+
*/
|
|
16
|
+
declare const onViewMounted: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
17
|
+
/**
|
|
18
|
+
* 视图生命周期 视图修改前
|
|
19
|
+
*/
|
|
20
|
+
declare const onViewBeforeUpdate: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
21
|
+
/**
|
|
22
|
+
* 视图生命周期 视图已被修改
|
|
23
|
+
*/
|
|
24
|
+
declare const onViewUpdated: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
25
|
+
/**
|
|
26
|
+
* 视图生命周期 视图销毁前
|
|
27
|
+
*/
|
|
28
|
+
declare const onViewBeforeUnmount: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
29
|
+
/**
|
|
30
|
+
* 视图生命周期 视图已被销毁
|
|
31
|
+
*/
|
|
32
|
+
declare const onViewUnmounted: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
33
|
+
/**
|
|
34
|
+
* 视图生命周期 视图数据提交
|
|
35
|
+
*/
|
|
36
|
+
declare const onViewSubmit: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
37
|
+
/**
|
|
38
|
+
* 视图生命周期 视图数据开始提交
|
|
39
|
+
*/
|
|
40
|
+
declare const onViewSubmitStart: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
41
|
+
/**
|
|
42
|
+
* 视图生命周期 视图数据提交成功
|
|
43
|
+
*/
|
|
44
|
+
declare const onViewSubmitSuccess: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
45
|
+
/**
|
|
46
|
+
* 视图生命周期 视图数据提交失败
|
|
47
|
+
*/
|
|
48
|
+
declare const onViewSubmitFailed: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
49
|
+
/**
|
|
50
|
+
* 视图生命周期 视图数据提交结束
|
|
51
|
+
*/
|
|
52
|
+
declare const onViewSubmitEnd: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
53
|
+
/**
|
|
54
|
+
* 视图生命周期 视图开始校验,只有表单页才会触发
|
|
55
|
+
*/
|
|
56
|
+
declare const onViewValidateStart: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
57
|
+
/**
|
|
58
|
+
* 视图生命周期 视图校验成功,只有表单页才会触发
|
|
59
|
+
*/
|
|
60
|
+
declare const onViewValidateSuccess: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
61
|
+
/**
|
|
62
|
+
* 视图生命周期 视图校验失败,只有表单页才会触发
|
|
63
|
+
*/
|
|
64
|
+
declare const onViewValidateFailed: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
65
|
+
/**
|
|
66
|
+
* 视图生命周期 视图校验结束,只有表单页才会触发
|
|
67
|
+
*/
|
|
68
|
+
declare const onViewValidateEnd: (type: string, callback?: ((ctx: any) => void) | undefined) => void;
|
|
69
|
+
export { onViewBeforeCreated, onViewCreated, onViewBeforeMount, onViewMounted, onViewBeforeUpdate, onViewUpdated, onViewBeforeUnmount, onViewUnmounted, onViewSubmit, onViewSubmitStart, onViewSubmitSuccess, onViewSubmitFailed, onViewSubmitEnd, onViewValidateStart, onViewValidateSuccess, onViewValidateFailed, onViewValidateEnd };
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
declare const isFn: (val: any) => val is Function;
|
|
2
|
-
declare const isArr: (arg: any) => arg is any[];
|
|
3
|
-
declare const isPlainObj: (obj: unknown) => obj is object;
|
|
4
|
-
declare const isStr: (obj: unknown) => obj is string;
|
|
5
|
-
declare const isBool: (obj: unknown) => obj is boolean;
|
|
6
|
-
declare const isNum: (obj: unknown) => obj is number;
|
|
7
|
-
declare const isMap: (val: any) => val is Map<any, any>;
|
|
8
|
-
declare const isSet: (val: any) => val is Set<any>;
|
|
9
|
-
declare const isWeakMap: (val: any) => val is WeakMap<any, any>;
|
|
10
|
-
declare const isWeakSet: (val: any) => val is WeakSet<any>;
|
|
11
|
-
declare const isNumberLike: (index: any) => index is number;
|
|
12
|
-
declare const isObj: (val: unknown) => val is object;
|
|
13
|
-
declare const isRegExp: (obj: unknown) => obj is RegExp;
|
|
14
|
-
export { isFn, isArr, isPlainObj, isStr, isBool, isNum, isMap, isSet, isWeakMap, isWeakSet, isNumberLike, isObj, isRegExp };
|
|
1
|
+
declare const isFn: (val: any) => val is Function;
|
|
2
|
+
declare const isArr: (arg: any) => arg is any[];
|
|
3
|
+
declare const isPlainObj: (obj: unknown) => obj is object;
|
|
4
|
+
declare const isStr: (obj: unknown) => obj is string;
|
|
5
|
+
declare const isBool: (obj: unknown) => obj is boolean;
|
|
6
|
+
declare const isNum: (obj: unknown) => obj is number;
|
|
7
|
+
declare const isMap: (val: any) => val is Map<any, any>;
|
|
8
|
+
declare const isSet: (val: any) => val is Set<any>;
|
|
9
|
+
declare const isWeakMap: (val: any) => val is WeakMap<any, any>;
|
|
10
|
+
declare const isWeakSet: (val: any) => val is WeakSet<any>;
|
|
11
|
+
declare const isNumberLike: (index: any) => index is number;
|
|
12
|
+
declare const isObj: (val: unknown) => val is object;
|
|
13
|
+
declare const isRegExp: (obj: unknown) => obj is RegExp;
|
|
14
|
+
export { isFn, isArr, isPlainObj, isStr, isBool, isNum, isMap, isSet, isWeakMap, isWeakSet, isNumberLike, isObj, isRegExp };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { AbstractEventProducer, EventCategoryType, EventMessage, EventProducer, EventProducerOptions } from '../../bus';
|
|
2
|
-
export declare abstract class AbstractHTMLEventProducer<K extends keyof HTMLElementEventMap, EV extends HTMLElementEventMap[K] = HTMLElementEventMap[K]> extends AbstractEventProducer<K, HTMLElementEventMap[K]> {
|
|
3
|
-
protected constructor(category: EventCategoryType, type: K, options?: EventProducerOptions<K, HTMLElementEventMap[K]>);
|
|
4
|
-
protected $$convert(self: EventProducer<K, EV>, ev: EV): EventMessage<EV> | undefined;
|
|
5
|
-
protected $$start(): void;
|
|
6
|
-
protected $$stop(): void;
|
|
7
|
-
}
|
|
1
|
+
import { AbstractEventProducer, type EventCategoryType, type EventMessage, type EventProducer, type EventProducerOptions } from '../../bus';
|
|
2
|
+
export declare abstract class AbstractHTMLEventProducer<K extends keyof HTMLElementEventMap, EV extends HTMLElementEventMap[K] = HTMLElementEventMap[K]> extends AbstractEventProducer<K, HTMLElementEventMap[K]> {
|
|
3
|
+
protected constructor(category: EventCategoryType, type: K, options?: EventProducerOptions<K, HTMLElementEventMap[K]>);
|
|
4
|
+
protected $$convert(self: EventProducer<K, EV>, ev: EV): EventMessage<EV> | undefined;
|
|
5
|
+
protected $$start(): void;
|
|
6
|
+
protected $$stop(): void;
|
|
7
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AbstractEventConsumer, EventConsumerConfig, EventConsumerFunction, EventConsumerOptions, EventMessage } from '../../bus';
|
|
2
|
-
export declare class HTMLEventConsumer<K extends keyof HTMLElementEventMap, M extends EventMessage<HTMLElementEventMap[K]> = EventMessage<HTMLElementEventMap[K]>, C extends EventConsumerConfig = EventConsumerConfig> extends AbstractEventConsumer<K, HTMLElementEventMap[K], HTMLElementEventMap[K], M, C> {
|
|
3
|
-
constructor(type: K, consumer: EventConsumerFunction<K, HTMLElementEventMap[K], HTMLElementEventMap[K], M, C>, options?: EventConsumerOptions<HTMLElementEventMap[K], HTMLElementEventMap[K], M, C>);
|
|
4
|
-
}
|
|
1
|
+
import { AbstractEventConsumer, type EventConsumerConfig, type EventConsumerFunction, type EventConsumerOptions, type EventMessage } from '../../bus';
|
|
2
|
+
export declare class HTMLEventConsumer<K extends keyof HTMLElementEventMap, M extends EventMessage<HTMLElementEventMap[K]> = EventMessage<HTMLElementEventMap[K]>, C extends EventConsumerConfig = EventConsumerConfig> extends AbstractEventConsumer<K, HTMLElementEventMap[K], HTMLElementEventMap[K], M, C> {
|
|
3
|
+
constructor(type: K, consumer: EventConsumerFunction<K, HTMLElementEventMap[K], HTMLElementEventMap[K], M, C>, options?: EventConsumerOptions<HTMLElementEventMap[K], HTMLElementEventMap[K], M, C>);
|
|
4
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { EventProducerOptions } from '../../bus';
|
|
2
|
-
import { AbstractHTMLEventProducer } from './AbstractHTMLEventProducer';
|
|
3
|
-
export declare class HTMLEventProducer<K extends keyof HTMLElementEventMap> extends AbstractHTMLEventProducer<K> {
|
|
4
|
-
constructor(type: K, options?: EventProducerOptions<K, HTMLElementEventMap[K]>);
|
|
5
|
-
}
|
|
1
|
+
import { type EventProducerOptions } from '../../bus';
|
|
2
|
+
import { AbstractHTMLEventProducer } from './AbstractHTMLEventProducer';
|
|
3
|
+
export declare class HTMLEventProducer<K extends keyof HTMLElementEventMap> extends AbstractHTMLEventProducer<K> {
|
|
4
|
+
constructor(type: K, options?: EventProducerOptions<K, HTMLElementEventMap[K]>);
|
|
5
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './AbstractHTMLEventProducer';
|
|
2
|
-
export * from './HTMLEventConsumer';
|
|
3
|
-
export * from './HTMLEventProducer';
|
|
1
|
+
export * from './AbstractHTMLEventProducer';
|
|
2
|
+
export * from './HTMLEventConsumer';
|
|
3
|
+
export * from './HTMLEventProducer';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './basic';
|
|
2
|
-
export * from './keyboard';
|
|
1
|
+
export * from './basic';
|
|
2
|
+
export * from './keyboard';
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { AbstractEventConsumer, EventCategoryType, EventConsumerFunction, EventConsumerOptions, HTMLKeyboardEventConsumerConfig, KeyboardEventMessage } from '../../bus';
|
|
2
|
-
|
|
3
|
-
declare class AbstractKeyboardEventConsumer extends AbstractEventConsumer<string, KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig> {
|
|
4
|
-
constructor(category: EventCategoryType, type: string, consumer: EventConsumerFunction<string, KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig>, options?: KeyboardEventConsumerOptions);
|
|
5
|
-
protected initConfig(): void;
|
|
6
|
-
protected $$filter(ev: KeyboardEvent, message: KeyboardEventMessage): boolean;
|
|
7
|
-
}
|
|
8
|
-
export declare class HTMLKeyboardEventConsumer extends AbstractKeyboardEventConsumer {
|
|
9
|
-
constructor(type: string, consumer: EventConsumerFunction<string, KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig>, options?: KeyboardEventConsumerOptions);
|
|
10
|
-
}
|
|
11
|
-
export declare class KeyboardEventConsumer extends AbstractKeyboardEventConsumer {
|
|
12
|
-
constructor(type: string, consumer: EventConsumerFunction<string, KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig>, options?: KeyboardEventConsumerOptions);
|
|
13
|
-
}
|
|
14
|
-
export {};
|
|
1
|
+
import { AbstractEventConsumer, type EventCategoryType, type EventConsumerFunction, type EventConsumerOptions, type HTMLKeyboardEventConsumerConfig, type KeyboardEventMessage } from '../../bus';
|
|
2
|
+
type KeyboardEventConsumerOptions = EventConsumerOptions<KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig>;
|
|
3
|
+
declare class AbstractKeyboardEventConsumer extends AbstractEventConsumer<string, KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig> {
|
|
4
|
+
constructor(category: EventCategoryType, type: string, consumer: EventConsumerFunction<string, KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig>, options?: KeyboardEventConsumerOptions);
|
|
5
|
+
protected initConfig(): void;
|
|
6
|
+
protected $$filter(ev: KeyboardEvent, message: KeyboardEventMessage): boolean;
|
|
7
|
+
}
|
|
8
|
+
export declare class HTMLKeyboardEventConsumer extends AbstractKeyboardEventConsumer {
|
|
9
|
+
constructor(type: string, consumer: EventConsumerFunction<string, KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig>, options?: KeyboardEventConsumerOptions);
|
|
10
|
+
}
|
|
11
|
+
export declare class KeyboardEventConsumer extends AbstractKeyboardEventConsumer {
|
|
12
|
+
constructor(type: string, consumer: EventConsumerFunction<string, KeyboardEvent, KeyboardEvent, KeyboardEventMessage, HTMLKeyboardEventConsumerConfig>, options?: KeyboardEventConsumerOptions);
|
|
13
|
+
}
|
|
14
|
+
export {};
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { EventProducer, EventProducerOptions, KeyboardEventMessage, KeyboardType } from '../../bus';
|
|
2
|
-
import { AbstractHTMLEventProducer } from '../basic';
|
|
3
|
-
declare abstract class AbstractHTMLKeyboardEventProducer<K extends KeyboardType> extends AbstractHTMLEventProducer<K, KeyboardEvent> {
|
|
4
|
-
protected $$convert(self: EventProducer<K, KeyboardEvent>, ev: KeyboardEvent): KeyboardEventMessage | undefined;
|
|
5
|
-
}
|
|
6
|
-
export declare class HTMLKeyboardEventProducer<K extends KeyboardType> extends AbstractHTMLKeyboardEventProducer<K> {
|
|
7
|
-
constructor(type: K, options?: EventProducerOptions<K, KeyboardEvent>);
|
|
8
|
-
}
|
|
9
|
-
export declare class KeyboardEventProducer<K extends KeyboardType> extends AbstractHTMLKeyboardEventProducer<K> {
|
|
10
|
-
constructor(type: K, options?: EventProducerOptions<K, KeyboardEvent>);
|
|
11
|
-
protected $$convert(self: EventProducer<K, KeyboardEvent>, ev: KeyboardEvent): KeyboardEventMessage | undefined;
|
|
12
|
-
protected onKeydown(ev: KeyboardEvent): void;
|
|
13
|
-
protected $$start(): void;
|
|
14
|
-
protected $$stop(): void;
|
|
15
|
-
}
|
|
16
|
-
export {};
|
|
1
|
+
import { type EventProducer, type EventProducerOptions, type KeyboardEventMessage, type KeyboardType } from '../../bus';
|
|
2
|
+
import { AbstractHTMLEventProducer } from '../basic';
|
|
3
|
+
declare abstract class AbstractHTMLKeyboardEventProducer<K extends KeyboardType> extends AbstractHTMLEventProducer<K, KeyboardEvent> {
|
|
4
|
+
protected $$convert(self: EventProducer<K, KeyboardEvent>, ev: KeyboardEvent): KeyboardEventMessage | undefined;
|
|
5
|
+
}
|
|
6
|
+
export declare class HTMLKeyboardEventProducer<K extends KeyboardType> extends AbstractHTMLKeyboardEventProducer<K> {
|
|
7
|
+
constructor(type: K, options?: EventProducerOptions<K, KeyboardEvent>);
|
|
8
|
+
}
|
|
9
|
+
export declare class KeyboardEventProducer<K extends KeyboardType> extends AbstractHTMLKeyboardEventProducer<K> {
|
|
10
|
+
constructor(type: K, options?: EventProducerOptions<K, KeyboardEvent>);
|
|
11
|
+
protected $$convert(self: EventProducer<K, KeyboardEvent>, ev: KeyboardEvent): KeyboardEventMessage | undefined;
|
|
12
|
+
protected onKeydown(ev: KeyboardEvent): void;
|
|
13
|
+
protected $$start(): void;
|
|
14
|
+
protected $$stop(): void;
|
|
15
|
+
}
|
|
16
|
+
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './HTMLKeyboardEventConsumer';
|
|
2
|
-
export * from './HTMLKeyboardEventProducer';
|
|
1
|
+
export * from './HTMLKeyboardEventConsumer';
|
|
2
|
+
export * from './HTMLKeyboardEventProducer';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export * from './bus';
|
|
2
|
-
export * from './html-event';
|
|
3
|
-
export * from './effects';
|
|
4
|
-
export * from './lifecycle';
|
|
5
|
-
export * from './helper';
|
|
6
|
-
export * from './typing';
|
|
1
|
+
export * from './bus';
|
|
2
|
+
export * from './html-event';
|
|
3
|
+
export * from './effects';
|
|
4
|
+
export * from './lifecycle';
|
|
5
|
+
export * from './helper';
|
|
6
|
+
export * from './typing';
|
|
@@ -1,75 +1,75 @@
|
|
|
1
|
-
import { LifeCycle } from './lifecycle';
|
|
2
|
-
import { LifeCycleTypes, RegistryType } from '../typing';
|
|
3
|
-
/**
|
|
4
|
-
* HeartLifeCycles = [{
|
|
5
|
-
* registryType: Field,
|
|
6
|
-
* type: onFieldChange,
|
|
7
|
-
* pattern: {
|
|
8
|
-
* identifier: displayName
|
|
9
|
-
* lifes: [LifeCycle]
|
|
10
|
-
* }
|
|
11
|
-
* }]
|
|
12
|
-
*/
|
|
13
|
-
|
|
14
|
-
type: LifeCycleTypes;
|
|
15
|
-
registryType: RegistryType;
|
|
16
|
-
pattern: {
|
|
17
|
-
identifier: string;
|
|
18
|
-
lifes: LifeCycle[];
|
|
19
|
-
}[];
|
|
20
|
-
}[];
|
|
21
|
-
/**
|
|
22
|
-
* 操作生命周期的api
|
|
23
|
-
*/
|
|
24
|
-
declare class LifeCycleHeart {
|
|
25
|
-
private static lifeCycles;
|
|
26
|
-
private static heartType;
|
|
27
|
-
static initialize(lifeCycles: HeartLifeCycles): void;
|
|
28
|
-
private static getLifeCycleIndex;
|
|
29
|
-
static getLifeCycle(): HeartLifeCycles;
|
|
30
|
-
static getLifeCycleByType(type: LifeCycleTypes): {
|
|
31
|
-
type: LifeCycleTypes;
|
|
32
|
-
registryType: RegistryType;
|
|
33
|
-
pattern: {
|
|
34
|
-
identifier: string;
|
|
35
|
-
lifes: LifeCycle
|
|
36
|
-
}[];
|
|
37
|
-
} | null;
|
|
38
|
-
/**
|
|
39
|
-
* 设置生命周期的注册类型,
|
|
40
|
-
*
|
|
41
|
-
* @param {registryType} RegistryType 类型
|
|
42
|
-
*/
|
|
43
|
-
static setType(registryType: RegistryType): void;
|
|
44
|
-
/**
|
|
45
|
-
* 设置生命周期
|
|
46
|
-
* 调用该函数之前要先调用 `setType` 设置注册类型
|
|
47
|
-
*
|
|
48
|
-
* @param {type} LifeCycleTypes 生命周期的类型
|
|
49
|
-
* @param {identifier} string 唯一标识符
|
|
50
|
-
* @param {lifeCycle} LifeCycle 生命周期的实例
|
|
51
|
-
*
|
|
52
|
-
*/
|
|
53
|
-
static setLifeCycle(type: LifeCycleTypes, identifier: string, lifeCycle: LifeCycle): false | undefined;
|
|
54
|
-
/**
|
|
55
|
-
* 触发生命周期的回调函数
|
|
56
|
-
*
|
|
57
|
-
* @param {type} LifeCycleTypes 生命周期的类型
|
|
58
|
-
* @param {identifier} string 唯一标识符
|
|
59
|
-
* @param {ctx} Context 当前「视图/字段/Action」的上下文
|
|
60
|
-
*/
|
|
61
|
-
static publish<C = any>(type: LifeCycleTypes, identifier: string, ctx: C): false | undefined;
|
|
62
|
-
/**
|
|
63
|
-
* @deprecated 销毁生命周期
|
|
64
|
-
*
|
|
65
|
-
* @param {identifier} string 唯一标识符
|
|
66
|
-
*/
|
|
67
|
-
static disposeLifeCycle(identifier: string): void;
|
|
68
|
-
/**
|
|
69
|
-
* 销毁生命周期
|
|
70
|
-
*
|
|
71
|
-
* @param {identifier} string 唯一标识符
|
|
72
|
-
*/
|
|
73
|
-
static dispose(identifier: string): void;
|
|
74
|
-
}
|
|
75
|
-
export { LifeCycleHeart };
|
|
1
|
+
import { LifeCycle } from './lifecycle';
|
|
2
|
+
import { LifeCycleTypes, RegistryType } from '../typing';
|
|
3
|
+
/**
|
|
4
|
+
* HeartLifeCycles = [{
|
|
5
|
+
* registryType: Field,
|
|
6
|
+
* type: onFieldChange,
|
|
7
|
+
* pattern: {
|
|
8
|
+
* identifier: displayName
|
|
9
|
+
* lifes: [LifeCycle]
|
|
10
|
+
* }
|
|
11
|
+
* }]
|
|
12
|
+
*/
|
|
13
|
+
type HeartLifeCycles = {
|
|
14
|
+
type: LifeCycleTypes;
|
|
15
|
+
registryType: RegistryType;
|
|
16
|
+
pattern: {
|
|
17
|
+
identifier: string;
|
|
18
|
+
lifes: LifeCycle[];
|
|
19
|
+
}[];
|
|
20
|
+
}[];
|
|
21
|
+
/**
|
|
22
|
+
* 操作生命周期的api
|
|
23
|
+
*/
|
|
24
|
+
declare class LifeCycleHeart {
|
|
25
|
+
private static lifeCycles;
|
|
26
|
+
private static heartType;
|
|
27
|
+
static initialize(lifeCycles: HeartLifeCycles): void;
|
|
28
|
+
private static getLifeCycleIndex;
|
|
29
|
+
static getLifeCycle(): HeartLifeCycles;
|
|
30
|
+
static getLifeCycleByType(type: LifeCycleTypes): {
|
|
31
|
+
type: LifeCycleTypes;
|
|
32
|
+
registryType: RegistryType;
|
|
33
|
+
pattern: {
|
|
34
|
+
identifier: string;
|
|
35
|
+
lifes: LifeCycle[];
|
|
36
|
+
}[];
|
|
37
|
+
} | null;
|
|
38
|
+
/**
|
|
39
|
+
* 设置生命周期的注册类型,
|
|
40
|
+
*
|
|
41
|
+
* @param {registryType} RegistryType 类型
|
|
42
|
+
*/
|
|
43
|
+
static setType(registryType: RegistryType): void;
|
|
44
|
+
/**
|
|
45
|
+
* 设置生命周期
|
|
46
|
+
* 调用该函数之前要先调用 `setType` 设置注册类型
|
|
47
|
+
*
|
|
48
|
+
* @param {type} LifeCycleTypes 生命周期的类型
|
|
49
|
+
* @param {identifier} string 唯一标识符
|
|
50
|
+
* @param {lifeCycle} LifeCycle 生命周期的实例
|
|
51
|
+
*
|
|
52
|
+
*/
|
|
53
|
+
static setLifeCycle(type: LifeCycleTypes, identifier: string, lifeCycle: LifeCycle): false | undefined;
|
|
54
|
+
/**
|
|
55
|
+
* 触发生命周期的回调函数
|
|
56
|
+
*
|
|
57
|
+
* @param {type} LifeCycleTypes 生命周期的类型
|
|
58
|
+
* @param {identifier} string 唯一标识符
|
|
59
|
+
* @param {ctx} Context 当前「视图/字段/Action」的上下文
|
|
60
|
+
*/
|
|
61
|
+
static publish<C = any>(type: LifeCycleTypes, identifier: string, ctx: C): false | undefined;
|
|
62
|
+
/**
|
|
63
|
+
* @deprecated 销毁生命周期
|
|
64
|
+
*
|
|
65
|
+
* @param {identifier} string 唯一标识符
|
|
66
|
+
*/
|
|
67
|
+
static disposeLifeCycle(identifier: string): void;
|
|
68
|
+
/**
|
|
69
|
+
* 销毁生命周期
|
|
70
|
+
*
|
|
71
|
+
* @param {identifier} string 唯一标识符
|
|
72
|
+
*/
|
|
73
|
+
static dispose(identifier: string): void;
|
|
74
|
+
}
|
|
75
|
+
export { LifeCycleHeart };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './lifecycle';
|
|
2
|
-
export * from './heart';
|
|
1
|
+
export * from './lifecycle';
|
|
2
|
+
export * from './heart';
|