@angular-wave/angular.ts 0.17.0 → 0.19.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/@types/angular.d.ts +18 -6
- package/@types/animations/animate-css-driver.d.ts +2 -2
- package/@types/animations/animate-js-driver.d.ts +21 -3
- package/@types/animations/animate-js.d.ts +10 -2
- package/@types/animations/animate-swap.d.ts +4 -1
- package/@types/animations/animate.d.ts +11 -5
- package/@types/animations/animation.d.ts +8 -2
- package/@types/animations/css/animate-css.d.ts +16 -0
- package/@types/animations/interface.d.ts +315 -21
- package/@types/animations/queue/animate-queue.d.ts +17 -8
- package/@types/animations/queue/interface.d.ts +14 -7
- package/@types/animations/shared.d.ts +1 -1
- package/@types/core/compile/attributes.d.ts +5 -5
- package/@types/core/compile/compile.d.ts +28 -18
- package/@types/core/compile/interface.d.ts +209 -34
- package/@types/core/controller/controller.d.ts +30 -38
- package/@types/core/controller/interface.d.ts +12 -3
- package/@types/core/interpolate/interpolate.d.ts +1 -1
- package/@types/core/parse/interface.d.ts +2 -2
- package/@types/core/parse/interpreter.d.ts +110 -58
- package/@types/core/scope/interface.d.ts +6 -0
- package/@types/core/scope/scope.d.ts +2 -1
- package/@types/directive/aria/aria.d.ts +67 -27
- package/@types/directive/aria/interface.d.ts +9 -0
- package/@types/directive/class/class.d.ts +31 -0
- package/@types/directive/form/form.d.ts +54 -18
- package/@types/directive/input/input.d.ts +59 -18
- package/@types/directive/input/interface.d.ts +10 -0
- package/@types/directive/messages/messages.d.ts +73 -22
- package/@types/directive/model/interface.d.ts +19 -0
- package/@types/directive/model/model.d.ts +70 -33
- package/@types/directive/model-options/model-options.d.ts +1 -23
- package/@types/directive/repeat/repeat.d.ts +2 -3
- package/@types/directive/validators/validators.d.ts +1 -5
- package/@types/directive/worker/interface.d.ts +9 -0
- package/@types/docs.d.ts +24 -0
- package/@types/filters/json.d.ts +4 -0
- package/@types/interface.d.ts +22 -70
- package/@types/namespace.d.ts +73 -53
- package/@types/router/common/trace.d.ts +150 -42
- package/@types/router/directives/state-directives.d.ts +4 -4
- package/@types/router/directives/view-directive.d.ts +4 -7
- package/@types/router/hooks/core-resolvables.d.ts +11 -2
- package/@types/router/hooks/ignored-transition.d.ts +3 -1
- package/@types/router/hooks/invalid-transition.d.ts +3 -1
- package/@types/router/hooks/lazy-load.d.ts +17 -13
- package/@types/router/hooks/on-enter-exit-retain.d.ts +9 -3
- package/@types/router/hooks/redirect-to.d.ts +3 -3
- package/@types/router/hooks/resolve.d.ts +11 -3
- package/@types/router/hooks/views.d.ts +6 -4
- package/@types/router/params/interface.d.ts +3 -2
- package/@types/router/params/param-factory.d.ts +24 -3
- package/@types/router/params/param-type.d.ts +47 -11
- package/@types/router/params/param-types.d.ts +52 -0
- package/@types/router/params/param.d.ts +52 -28
- package/@types/router/params/state-params.d.ts +5 -3
- package/@types/router/path/interface.d.ts +3 -0
- package/@types/router/path/path-node.d.ts +34 -14
- package/@types/router/path/path-utils.d.ts +75 -25
- package/@types/router/resolve/resolvable.d.ts +34 -7
- package/@types/router/resolve/resolve-context.d.ts +52 -34
- package/@types/router/router.d.ts +10 -12
- package/@types/router/state/interface.d.ts +194 -31
- package/@types/router/state/state-builder.d.ts +29 -29
- package/@types/router/state/state-matcher.d.ts +29 -11
- package/@types/router/state/state-object.d.ts +68 -22
- package/@types/router/state/state-queue-manager.d.ts +19 -10
- package/@types/router/state/state-registry.d.ts +80 -28
- package/@types/router/state/state-service.d.ts +182 -123
- package/@types/router/state/target-state.d.ts +36 -27
- package/@types/router/state/views.d.ts +48 -19
- package/@types/router/template-factory.d.ts +8 -15
- package/@types/router/transition/hook-builder.d.ts +17 -6
- package/@types/router/transition/hook-registry.d.ts +80 -46
- package/@types/router/transition/interface.d.ts +138 -118
- package/@types/router/transition/reject-factory.d.ts +58 -22
- package/@types/router/transition/transition-event-type.d.ts +19 -8
- package/@types/router/transition/transition-hook.d.ts +50 -29
- package/@types/router/transition/transition-service.d.ts +186 -30
- package/@types/router/transition/transition.d.ts +201 -70
- package/@types/router/url/interface.d.ts +140 -0
- package/@types/router/url/url-config.d.ts +19 -16
- package/@types/router/url/url-matcher.d.ts +66 -46
- package/@types/router/url/url-rule.d.ts +58 -35
- package/@types/router/url/url-rules.d.ts +38 -28
- package/@types/router/url/url-service.d.ts +68 -41
- package/@types/router/view/interface.d.ts +10 -30
- package/@types/router/view/view.d.ts +35 -21
- package/@types/services/anchor-scroll/anchor-scroll.d.ts +1 -1
- package/@types/services/anchor-scroll/interface.d.ts +5 -8
- package/@types/services/http/http.d.ts +20 -23
- package/@types/services/http/interface.d.ts +11 -23
- package/@types/services/location/interface.d.ts +1 -4
- package/@types/services/location/location.d.ts +14 -14
- package/@types/services/sce/interface.d.ts +2 -2
- package/@types/services/sce/sce.d.ts +16 -10
- package/@types/services/template-request/template-request.d.ts +21 -4
- package/@types/shared/common.d.ts +5 -32
- package/@types/shared/dom.d.ts +10 -5
- package/@types/shared/interface.d.ts +4 -0
- package/@types/shared/utils.d.ts +17 -6
- package/dist/angular-ts.esm.js +6643 -3107
- package/dist/angular-ts.umd.js +6643 -3107
- package/dist/angular-ts.umd.min.js +1 -1
- package/dist/angular-ts.umd.min.js.gz +0 -0
- package/dist/angular-ts.umd.min.js.map +1 -1
- package/package.json +1 -2
- package/@types/animations/animate-css.d.ts +0 -11
- package/@types/filters/filters.d.ts +0 -38
- package/@types/router/hooks/update-globals.d.ts +0 -1
- package/@types/router/hooks/url.d.ts +0 -5
- package/@types/router/scroll/interface.d.ts +0 -3
- package/@types/router/scroll/view-scroll.d.ts +0 -8
|
@@ -4,33 +4,69 @@
|
|
|
4
4
|
* @returns {*}
|
|
5
5
|
*/
|
|
6
6
|
export function createStringDateInputType(type: string, regexp: RegExp): any;
|
|
7
|
+
/**
|
|
8
|
+
* @param {ng.Scope} scope
|
|
9
|
+
* @param {HTMLInputElement} element
|
|
10
|
+
* @param {ng.Attributes} attr
|
|
11
|
+
* @param {NgModelControllerProxied} ctrl
|
|
12
|
+
* @param {string} parserName
|
|
13
|
+
*/
|
|
7
14
|
export function badInputChecker(
|
|
8
|
-
scope:
|
|
9
|
-
element:
|
|
10
|
-
attr:
|
|
11
|
-
ctrl:
|
|
12
|
-
parserName:
|
|
15
|
+
scope: ng.Scope,
|
|
16
|
+
element: HTMLInputElement,
|
|
17
|
+
attr: ng.Attributes,
|
|
18
|
+
ctrl: NgModelControllerProxied,
|
|
19
|
+
parserName: string,
|
|
13
20
|
): void;
|
|
14
|
-
|
|
21
|
+
/**
|
|
22
|
+
* @param {NgModelController} ctrl
|
|
23
|
+
*/
|
|
24
|
+
export function numberFormatterParser(ctrl: NgModelController): void;
|
|
25
|
+
/**
|
|
26
|
+
* @param {any} num
|
|
27
|
+
* @return {boolean}
|
|
28
|
+
*/
|
|
15
29
|
export function isNumberInteger(num: any): boolean;
|
|
16
|
-
|
|
30
|
+
/**
|
|
31
|
+
* @param {number} num
|
|
32
|
+
* @return {number}
|
|
33
|
+
*/
|
|
34
|
+
export function countDecimals(num: number): number;
|
|
35
|
+
/**
|
|
36
|
+
* @param {any} viewValue
|
|
37
|
+
* @param {number} stepBase
|
|
38
|
+
* @param {number | undefined} step
|
|
39
|
+
*/
|
|
17
40
|
export function isValidForStep(
|
|
18
41
|
viewValue: any,
|
|
19
|
-
stepBase:
|
|
20
|
-
step:
|
|
42
|
+
stepBase: number,
|
|
43
|
+
step: number | undefined,
|
|
21
44
|
): boolean;
|
|
45
|
+
/**
|
|
46
|
+
* @param {ng.Scope} scope
|
|
47
|
+
* @param {HTMLInputElement} element
|
|
48
|
+
* @param {ng.Attributes} attr
|
|
49
|
+
* @param {NgModelControllerProxied} ctrl
|
|
50
|
+
* @param {ng.ParseService} $parse
|
|
51
|
+
*/
|
|
22
52
|
export function numberInputType(
|
|
23
|
-
scope:
|
|
24
|
-
element:
|
|
25
|
-
attr:
|
|
26
|
-
ctrl:
|
|
27
|
-
$parse:
|
|
53
|
+
scope: ng.Scope,
|
|
54
|
+
element: HTMLInputElement,
|
|
55
|
+
attr: ng.Attributes,
|
|
56
|
+
ctrl: NgModelControllerProxied,
|
|
57
|
+
$parse: ng.ParseService,
|
|
28
58
|
): void;
|
|
59
|
+
/**
|
|
60
|
+
* @param {ng.Scope} scope
|
|
61
|
+
* @param {HTMLInputElement} element
|
|
62
|
+
* @param {ng.Attributes} attr
|
|
63
|
+
* @param {NgModelControllerProxied} ctrl
|
|
64
|
+
*/
|
|
29
65
|
export function rangeInputType(
|
|
30
|
-
scope:
|
|
31
|
-
element:
|
|
32
|
-
attr:
|
|
33
|
-
ctrl:
|
|
66
|
+
scope: ng.Scope,
|
|
67
|
+
element: HTMLInputElement,
|
|
68
|
+
attr: ng.Attributes,
|
|
69
|
+
ctrl: NgModelControllerProxied,
|
|
34
70
|
): void;
|
|
35
71
|
/**
|
|
36
72
|
* @param {ng.ParseService} $parse
|
|
@@ -48,7 +84,12 @@ export function hiddenInputDirective(): ng.Directive;
|
|
|
48
84
|
* @returns {ng.Directive}
|
|
49
85
|
*/
|
|
50
86
|
export function ngValueDirective(): ng.Directive;
|
|
87
|
+
/** @typedef {import("../model/model.js").NgModelController} NgModelController */
|
|
88
|
+
/** @typedef {import("./interface.ts").NgModelControllerProxied} NgModelControllerProxied */
|
|
51
89
|
export const ISO_DATE_REGEXP: RegExp;
|
|
52
90
|
export const URL_REGEXP: RegExp;
|
|
53
91
|
export const EMAIL_REGEXP: RegExp;
|
|
54
92
|
export const VALIDITY_STATE_PROPERTY: "validity";
|
|
93
|
+
export type NgModelController = import("../model/model.js").NgModelController;
|
|
94
|
+
export type NgModelControllerProxied =
|
|
95
|
+
import("./interface.ts").NgModelControllerProxied;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ScopeProxied } from "../../core/scope/interface.js";
|
|
2
|
+
import { NgModelController } from "../model/model.js";
|
|
3
|
+
export type NgModelControllerProxied = ScopeProxied<NgModelController>;
|
|
4
|
+
export type InputTypeHandler = (
|
|
5
|
+
scope: ng.Scope,
|
|
6
|
+
element: HTMLInputElement,
|
|
7
|
+
attr: ng.Attributes,
|
|
8
|
+
ctrl: NgModelControllerProxied,
|
|
9
|
+
$parse: ng.ParseService,
|
|
10
|
+
) => void;
|
|
@@ -21,40 +21,91 @@ export namespace ngMessagesIncludeDirective {
|
|
|
21
21
|
let $inject_1: string[];
|
|
22
22
|
export { $inject_1 as $inject };
|
|
23
23
|
}
|
|
24
|
-
export const ngMessageDirective: (
|
|
25
|
-
export const ngMessageExpDirective: (
|
|
26
|
-
|
|
24
|
+
export const ngMessageDirective: ($animate: ng.AnimateService) => ng.Directive;
|
|
25
|
+
export const ngMessageExpDirective: (
|
|
26
|
+
$animate: ng.AnimateService,
|
|
27
|
+
) => ng.Directive;
|
|
28
|
+
export const ngMessageDefaultDirective: (
|
|
29
|
+
$animate: ng.AnimateService,
|
|
30
|
+
) => ng.Directive;
|
|
27
31
|
declare class NgMessageCtrl {
|
|
28
32
|
/**
|
|
29
|
-
* @param {
|
|
33
|
+
* @param {HTMLElement} $element
|
|
30
34
|
* @param {ng.Scope} $scope
|
|
31
35
|
* @param {ng.Attributes} $attrs
|
|
32
36
|
* @param {ng.AnimateService} $animate
|
|
33
37
|
*/
|
|
34
38
|
constructor(
|
|
35
|
-
$element:
|
|
39
|
+
$element: HTMLElement,
|
|
36
40
|
$scope: ng.Scope,
|
|
37
41
|
$attrs: ng.Attributes,
|
|
38
42
|
$animate: ng.AnimateService,
|
|
39
43
|
);
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
44
|
+
_element: HTMLElement;
|
|
45
|
+
_scope: ng.Scope;
|
|
46
|
+
_attrs: ng.Attributes;
|
|
47
|
+
_animate: import("../../docs.ts").AnimateService;
|
|
48
|
+
_latestKey: number;
|
|
49
|
+
_nextAttachId: number;
|
|
50
|
+
/** @type {Record<string, any>} */
|
|
51
|
+
_messages: Record<string, any>;
|
|
52
|
+
_renderLater: boolean;
|
|
53
|
+
_cachedCollection: {};
|
|
54
|
+
_head: any;
|
|
55
|
+
_default: any;
|
|
56
|
+
_getAttachId(): number;
|
|
57
|
+
_render(collection?: {}): void;
|
|
53
58
|
reRender(): void;
|
|
54
|
-
|
|
55
|
-
|
|
59
|
+
/**
|
|
60
|
+
* @param {{ _ngMessageNode: string; }} comment
|
|
61
|
+
* @param {any} messageCtrl
|
|
62
|
+
* @param {any} isDefault
|
|
63
|
+
*/
|
|
64
|
+
register(
|
|
65
|
+
comment: {
|
|
66
|
+
_ngMessageNode: string;
|
|
67
|
+
},
|
|
68
|
+
messageCtrl: any,
|
|
69
|
+
isDefault: any,
|
|
70
|
+
): void;
|
|
71
|
+
/**
|
|
72
|
+
* @param {{ _ngMessageNode: any; }} comment
|
|
73
|
+
* @param {any} isDefault
|
|
74
|
+
*/
|
|
75
|
+
deregister(
|
|
76
|
+
comment: {
|
|
77
|
+
_ngMessageNode: any;
|
|
78
|
+
},
|
|
79
|
+
isDefault: any,
|
|
80
|
+
): void;
|
|
81
|
+
/**
|
|
82
|
+
* @param {any} parent
|
|
83
|
+
* @param {any} comment
|
|
84
|
+
*/
|
|
56
85
|
findPreviousMessage(parent: any, comment: any): any;
|
|
57
|
-
|
|
58
|
-
|
|
86
|
+
/**
|
|
87
|
+
* @param {HTMLElement} parent
|
|
88
|
+
* @param {{ _ngMessageNode: string; }} comment
|
|
89
|
+
* @param {string} key
|
|
90
|
+
*/
|
|
91
|
+
insertMessageNode(
|
|
92
|
+
parent: HTMLElement,
|
|
93
|
+
comment: {
|
|
94
|
+
_ngMessageNode: string;
|
|
95
|
+
},
|
|
96
|
+
key: string,
|
|
97
|
+
): void;
|
|
98
|
+
/**
|
|
99
|
+
* @param {HTMLElement} parent
|
|
100
|
+
* @param {{ _ngMessageNode: any; }} comment
|
|
101
|
+
* @param {string | number} key
|
|
102
|
+
*/
|
|
103
|
+
removeMessageNode(
|
|
104
|
+
parent: HTMLElement,
|
|
105
|
+
comment: {
|
|
106
|
+
_ngMessageNode: any;
|
|
107
|
+
},
|
|
108
|
+
key: string | number,
|
|
109
|
+
): void;
|
|
59
110
|
}
|
|
60
111
|
export {};
|
|
@@ -16,3 +16,22 @@ export interface ModelFormatter {
|
|
|
16
16
|
export interface ModelViewChangeListener {
|
|
17
17
|
(): void;
|
|
18
18
|
}
|
|
19
|
+
/**
|
|
20
|
+
* Configuration for ngModel behavior.
|
|
21
|
+
*/
|
|
22
|
+
export interface NgModelOptions {
|
|
23
|
+
/** Space-separated event names that trigger updates */
|
|
24
|
+
updateOn?: string;
|
|
25
|
+
/** Delay in milliseconds or event-specific debounce times */
|
|
26
|
+
debounce?: number | Record<string, number>;
|
|
27
|
+
/** Whether to allow invalid values */
|
|
28
|
+
allowInvalid?: boolean;
|
|
29
|
+
/** Enables getter/setter style ngModel */
|
|
30
|
+
getterSetter?: boolean;
|
|
31
|
+
/** Timezone used for Date objects */
|
|
32
|
+
timezone?: string;
|
|
33
|
+
/** Time display format including seconds */
|
|
34
|
+
timeSecondsFormat?: string;
|
|
35
|
+
/** Whether to remove trailing :00 seconds */
|
|
36
|
+
timeStripZeroSeconds?: boolean;
|
|
37
|
+
}
|
|
@@ -1,13 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
priority: number;
|
|
6
|
-
compile: (element: Element) => {
|
|
7
|
-
pre: (scope: any, _element: any, attr: any, ctrls: any) => void;
|
|
8
|
-
post: (scope: any, elementPost: any, _attr: any, ctrls: any) => void;
|
|
9
|
-
};
|
|
10
|
-
};
|
|
1
|
+
/**
|
|
2
|
+
* @returns {ng.Directive}
|
|
3
|
+
*/
|
|
4
|
+
export function ngModelDirective(): ng.Directive;
|
|
11
5
|
export const ngModelMinErr: (arg0: string, ...arg1: any[]) => Error;
|
|
12
6
|
/**
|
|
13
7
|
*
|
|
@@ -92,13 +86,18 @@ export class NgModelController {
|
|
|
92
86
|
$pristine: boolean;
|
|
93
87
|
/** @type {boolean} */
|
|
94
88
|
$dirty: boolean;
|
|
95
|
-
/** @type {boolean} */
|
|
96
|
-
$valid: boolean;
|
|
97
|
-
/** @type {boolean} */
|
|
98
|
-
$invalid: boolean;
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
89
|
+
/** @type {boolean | undefined} */
|
|
90
|
+
$valid: boolean | undefined;
|
|
91
|
+
/** @type {boolean | undefined} */
|
|
92
|
+
$invalid: boolean | undefined;
|
|
93
|
+
/** @type {Record<string, boolean>} */
|
|
94
|
+
$error: Record<string, boolean>;
|
|
95
|
+
/** @type {Record<string, boolean>} */
|
|
96
|
+
_success: Record<string, boolean>;
|
|
97
|
+
/**
|
|
98
|
+
* @type {import("../../shared/interface.ts").Dict<any> | undefined}
|
|
99
|
+
*/
|
|
100
|
+
$pending: import("../../shared/interface.ts").Dict<any> | undefined;
|
|
102
101
|
$name: any;
|
|
103
102
|
_parentForm: {
|
|
104
103
|
$nonscope: boolean;
|
|
@@ -108,7 +107,7 @@ export class NgModelController {
|
|
|
108
107
|
$removeControl: Function;
|
|
109
108
|
$setValidity:
|
|
110
109
|
| Function
|
|
111
|
-
| ((key: any, isValid: boolean, control: any) => any);
|
|
110
|
+
| ((key: any, isValid: boolean | undefined | null, control: any) => any);
|
|
112
111
|
$setDirty: Function;
|
|
113
112
|
$setPristine: Function;
|
|
114
113
|
$setSubmitted: Function;
|
|
@@ -126,7 +125,10 @@ export class NgModelController {
|
|
|
126
125
|
createChild(options: ModelOptionsConfig): /*elided*/ any;
|
|
127
126
|
};
|
|
128
127
|
_updateEvents: string;
|
|
129
|
-
|
|
128
|
+
/**
|
|
129
|
+
* @param {Event} ev
|
|
130
|
+
*/
|
|
131
|
+
_updateEventHandler(ev: Event): void;
|
|
130
132
|
_parsedNgModel: import("../../core/parse/interface.ts").CompiledExpression;
|
|
131
133
|
_parsedNgModelAssign: (context: any, value: any) => any;
|
|
132
134
|
/**
|
|
@@ -147,15 +149,41 @@ export class NgModelController {
|
|
|
147
149
|
_scope: ng.Scope;
|
|
148
150
|
_attr: ng.Attributes;
|
|
149
151
|
_element: HTMLElement;
|
|
150
|
-
_animate: import("../../
|
|
152
|
+
_animate: import("../../docs.ts").AnimateService;
|
|
151
153
|
_parse: import("../../core/parse/interface.ts").ParseService;
|
|
152
|
-
_exceptionHandler: import("../../
|
|
154
|
+
_exceptionHandler: import("../../docs.ts").ExceptionHandler;
|
|
153
155
|
_hasNativeValidators: boolean;
|
|
154
|
-
|
|
156
|
+
/** @type {Record<string, boolean>} */
|
|
157
|
+
_classCache: Record<string, boolean>;
|
|
155
158
|
_eventRemovers: Set<any>;
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
+
/**
|
|
160
|
+
* @param {{ [x: string]: boolean; }} object
|
|
161
|
+
* @param {string | number} property
|
|
162
|
+
*/
|
|
163
|
+
set(
|
|
164
|
+
object: {
|
|
165
|
+
[x: string]: boolean;
|
|
166
|
+
},
|
|
167
|
+
property: string | number,
|
|
168
|
+
): void;
|
|
169
|
+
/**
|
|
170
|
+
* @param {{ [x: string]: any; }} object
|
|
171
|
+
* @param {string | number} property
|
|
172
|
+
*/
|
|
173
|
+
unset(
|
|
174
|
+
object: {
|
|
175
|
+
[x: string]: any;
|
|
176
|
+
},
|
|
177
|
+
property: string | number,
|
|
178
|
+
): void;
|
|
179
|
+
/**
|
|
180
|
+
* @param {string} validationErrorKey
|
|
181
|
+
* @param {boolean | undefined | null} state
|
|
182
|
+
*/
|
|
183
|
+
$setValidity(
|
|
184
|
+
validationErrorKey: string,
|
|
185
|
+
state: boolean | undefined | null,
|
|
186
|
+
): void;
|
|
159
187
|
_initGetterSetters(): void;
|
|
160
188
|
/**
|
|
161
189
|
* Called when the view needs to be updated. It is expected that the user of the ng-model
|
|
@@ -189,6 +217,9 @@ export class NgModelController {
|
|
|
189
217
|
* @returns {boolean} True if `value` is "empty".
|
|
190
218
|
*/
|
|
191
219
|
$isEmpty(value: any): boolean;
|
|
220
|
+
/**
|
|
221
|
+
* @param {any} value
|
|
222
|
+
*/
|
|
192
223
|
_updateEmptyClasses(value: any): void;
|
|
193
224
|
/**
|
|
194
225
|
* Sets the control to its pristine state.
|
|
@@ -318,7 +349,12 @@ export class NgModelController {
|
|
|
318
349
|
* `$modelValue`, i.e. either the last parsed value or the last value set from the scope.
|
|
319
350
|
*/
|
|
320
351
|
$validate(): void;
|
|
321
|
-
|
|
352
|
+
/**
|
|
353
|
+
* @param {any} modelValue
|
|
354
|
+
* @param {any} viewValue
|
|
355
|
+
* @param {Function} doneCallback
|
|
356
|
+
*/
|
|
357
|
+
_runValidators(modelValue: any, viewValue: any, doneCallback: Function): void;
|
|
322
358
|
/**
|
|
323
359
|
* Commit a pending update to the `$modelValue`.
|
|
324
360
|
*
|
|
@@ -378,7 +414,10 @@ export class NgModelController {
|
|
|
378
414
|
* @param {string} [trigger] Event that triggered the update.
|
|
379
415
|
*/
|
|
380
416
|
$setViewValue(value: any, trigger?: string): void;
|
|
381
|
-
|
|
417
|
+
/**
|
|
418
|
+
* @param {string | undefined} trigger
|
|
419
|
+
*/
|
|
420
|
+
_debounceViewValueCommit(trigger: string | undefined): void;
|
|
382
421
|
/**
|
|
383
422
|
*
|
|
384
423
|
* Override the current model options settings programmatically.
|
|
@@ -400,12 +439,10 @@ export class NgModelController {
|
|
|
400
439
|
* **Note:** it is not possible to override the `getterSetter` option.
|
|
401
440
|
* </div>
|
|
402
441
|
*
|
|
403
|
-
* @param {import("
|
|
442
|
+
* @param {import("./interface.ts").NgModelOptions} options a hash of settings to override the previous options
|
|
404
443
|
*
|
|
405
444
|
*/
|
|
406
|
-
$overrideModelOptions(
|
|
407
|
-
options: import("../../interface.ts").NgModelOptions,
|
|
408
|
-
): void;
|
|
445
|
+
$overrideModelOptions(options: import("./interface.ts").NgModelOptions): void;
|
|
409
446
|
/**
|
|
410
447
|
* Runs the model -> view pipeline on the current
|
|
411
448
|
* {@link ngModel.NgModelController#$modelValue $modelValue}.
|
|
@@ -517,8 +554,8 @@ export class NgModelController {
|
|
|
517
554
|
*/
|
|
518
555
|
_format(): any;
|
|
519
556
|
/**
|
|
520
|
-
* @ignore
|
|
521
|
-
*
|
|
557
|
+
* @ignore This method is called internally when the bound scope value changes.
|
|
558
|
+
* @param {any} modelValue
|
|
522
559
|
*/
|
|
523
560
|
_setModelValue(modelValue: any): void;
|
|
524
561
|
/**
|
|
@@ -3,29 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export function ngModelOptionsDirective(): ng.Directive;
|
|
5
5
|
export const defaultModelOptions: ModelOptions;
|
|
6
|
-
export type ModelOptionsConfig =
|
|
7
|
-
/**
|
|
8
|
-
* - A string specifying which events the input should be bound to. Multiple events can be set using a space-delimited list. The special event 'default' matches the default events belonging to the control.
|
|
9
|
-
*/
|
|
10
|
-
updateOn?: string;
|
|
11
|
-
/**
|
|
12
|
-
* - An integer specifying the debounce time in milliseconds. A value of 0 triggers an immediate update. If an object is supplied, custom debounce values can be set for each event.
|
|
13
|
-
*/
|
|
14
|
-
debounce?:
|
|
15
|
-
| number
|
|
16
|
-
| {
|
|
17
|
-
[x: string]: number;
|
|
18
|
-
};
|
|
19
|
-
/**
|
|
20
|
-
* - Indicates whether the model can be set with values that did not validate correctly. Defaults to false, which sets the model to undefined on validation failure.
|
|
21
|
-
*/
|
|
22
|
-
allowInvalid?: boolean;
|
|
23
|
-
/**
|
|
24
|
-
* - Determines whether to treat functions bound to `ngModel` as getters/setters. Defaults to false.
|
|
25
|
-
*/
|
|
26
|
-
getterSetter?: boolean;
|
|
27
|
-
updateOnDefault?: boolean;
|
|
28
|
-
};
|
|
6
|
+
export type ModelOptionsConfig = any & Record<string, any>;
|
|
29
7
|
/**
|
|
30
8
|
* A container for the options set by the {@link ngModelOptions} directive
|
|
31
9
|
*/
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* @param {*} $animate
|
|
2
|
+
* @param {ng.AnimateService} $animate
|
|
4
3
|
* @returns {ng.Directive}
|
|
5
4
|
*/
|
|
6
|
-
export function ngRepeatDirective($animate:
|
|
5
|
+
export function ngRepeatDirective($animate: ng.AnimateService): ng.Directive;
|
|
7
6
|
export namespace ngRepeatDirective {
|
|
8
7
|
let $inject: string[];
|
|
9
8
|
}
|
|
@@ -137,9 +137,5 @@ export const maxlengthDirective: (
|
|
|
137
137
|
*/
|
|
138
138
|
export const minlengthDirective: (
|
|
139
139
|
| string
|
|
140
|
-
| (($parse: ng.ParseService) =>
|
|
141
|
-
restrict: string;
|
|
142
|
-
require: string;
|
|
143
|
-
link(scope: any, elm: any, attr: any, ctrl: any): void;
|
|
144
|
-
})
|
|
140
|
+
| (($parse: ng.ParseService) => ng.Directive)
|
|
145
141
|
)[];
|
|
@@ -7,6 +7,15 @@ export interface WorkerConfig {
|
|
|
7
7
|
logger?: ng.LogService;
|
|
8
8
|
err?: ng.ExceptionHandlerService;
|
|
9
9
|
}
|
|
10
|
+
export interface DefultWorkerConfig {
|
|
11
|
+
onMessage: (data: any, event: MessageEvent) => void;
|
|
12
|
+
onError: (err: ErrorEvent) => void;
|
|
13
|
+
autoRestart: boolean;
|
|
14
|
+
autoTerminate: boolean;
|
|
15
|
+
transformMessage: (data: any) => any;
|
|
16
|
+
logger: ng.LogService;
|
|
17
|
+
err: ng.ExceptionHandlerService;
|
|
18
|
+
}
|
|
10
19
|
export interface WorkerConnection {
|
|
11
20
|
post(data: any): void;
|
|
12
21
|
terminate(): void;
|
package/@types/docs.d.ts
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export * from "./animations/interface.ts";
|
|
2
|
+
export { AnimateRunner } from "./animations/runner/animate-runner.js";
|
|
3
|
+
export { AnchorScrollService } from "./services/anchor-scroll/interface.ts";
|
|
4
|
+
export { AnchorScrollProvider } from "./services/anchor-scroll/anchor-scroll.js";
|
|
5
|
+
export * from "./services/http/interface.ts";
|
|
6
|
+
export * from "./services/log/interface.ts";
|
|
7
|
+
export * from "./services/log/log.js";
|
|
8
|
+
export * from "./services/location/interface.ts";
|
|
9
|
+
export * from "./services/location/location.js";
|
|
10
|
+
export * from "./services/pubsub/pubsub.js";
|
|
11
|
+
export * from "./services/template-cache/template-cache.js";
|
|
12
|
+
export { SceProvider, SceDelegateProvider } from "./services/sce/sce.js";
|
|
13
|
+
export { SceService, SceDelegateService } from "./services/sce/interface.ts";
|
|
14
|
+
export * from "./index.js";
|
|
15
|
+
export * from "./angular.js";
|
|
16
|
+
export * from "./core/di/internal-injector.js";
|
|
17
|
+
export * from "./core/scope/scope.js";
|
|
18
|
+
export * from "./services/cookie/cookie.js";
|
|
19
|
+
export * from "./services/cookie/interface.ts";
|
|
20
|
+
export * from "./services/exception/exception.ts";
|
|
21
|
+
export * from "./services/exception/interface.ts";
|
|
22
|
+
export * from "./core/parse/interface.ts";
|
|
23
|
+
export * from "./filters/interface.ts";
|
|
24
|
+
export * from "./core/filter/filter.js";
|
package/@types/interface.d.ts
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import { Attributes } from "./core/compile/attributes.js";
|
|
2
|
-
import {
|
|
2
|
+
import type {
|
|
3
|
+
BoundTranscludeFn,
|
|
4
|
+
CloneAttachFn,
|
|
5
|
+
PublicLinkFn,
|
|
6
|
+
TemplateLinkingFunctionOptions as CompileTemplateLinkingFunctionOptions,
|
|
7
|
+
} from "./core/compile/interface.js";
|
|
3
8
|
import { NgModelController } from "./directive/model/model.js";
|
|
4
9
|
export interface Constructor<T = any> {
|
|
5
10
|
new (...args: any[]): T;
|
|
@@ -25,7 +30,6 @@ export declare const PublicInjectionTokens: {
|
|
|
25
30
|
readonly $interpolate: "$interpolate";
|
|
26
31
|
readonly $location: "$location";
|
|
27
32
|
readonly $log: "$log";
|
|
28
|
-
readonly $viewScroll: "$viewScroll";
|
|
29
33
|
readonly $parse: "$parse";
|
|
30
34
|
readonly $rest: "$rest";
|
|
31
35
|
readonly $rootScope: "$rootScope";
|
|
@@ -384,7 +388,7 @@ export type DirectiveLinkFn<T> = (
|
|
|
384
388
|
element: HTMLElement,
|
|
385
389
|
attrs: ng.Attributes,
|
|
386
390
|
controller?: TController<T>,
|
|
387
|
-
transclude?:
|
|
391
|
+
transclude?: ng.TranscludeFn,
|
|
388
392
|
) => void;
|
|
389
393
|
/**
|
|
390
394
|
* A compile function used to prepare directives before linking.
|
|
@@ -423,13 +427,14 @@ export interface Directive<TController = any> {
|
|
|
423
427
|
/** Scope configuration (`true`, `false`, or object for isolate scope) */
|
|
424
428
|
scope?: boolean | Record<string, string>;
|
|
425
429
|
/** Inline template */
|
|
426
|
-
template?: string | ((element:
|
|
430
|
+
template?: string | ((element: HTMLElement, attrs: Attributes) => string);
|
|
427
431
|
/** Template namespace (e.g., SVG, HTML) */
|
|
428
432
|
templateNamespace?: string;
|
|
429
433
|
/** Template URL for loading from server */
|
|
430
|
-
templateUrl?: string | ((element:
|
|
434
|
+
templateUrl?: string | ((element: HTMLElement, attrs: Attributes) => string);
|
|
431
435
|
/** Enables transclusion or configures named slots */
|
|
432
436
|
transclude?: boolean | string | Record<string, string>;
|
|
437
|
+
/** Currently only used by view directive */
|
|
433
438
|
count?: number;
|
|
434
439
|
/** Internal hook for directive compilation state */
|
|
435
440
|
_addStateInfo?: (...args: any[]) => any;
|
|
@@ -442,72 +447,19 @@ export type DirectiveFactory = DirectiveFactoryFn | AnnotatedDirectiveFactory;
|
|
|
442
447
|
/**
|
|
443
448
|
* Represents advanced transclusion functions used in directives.
|
|
444
449
|
*/
|
|
445
|
-
export
|
|
446
|
-
/** Transcludes content with a new scope */
|
|
447
|
-
transcludeWithScope(
|
|
448
|
-
scope: Scope,
|
|
449
|
-
cloneAttachFn: CloneAttachFunction,
|
|
450
|
-
element?: Element,
|
|
451
|
-
slotName?: string,
|
|
452
|
-
): Element;
|
|
453
|
-
/** Transcludes content without creating a new scope */
|
|
454
|
-
transcludeWithoutScope(
|
|
455
|
-
cloneAttachFn?: CloneAttachFunction,
|
|
456
|
-
element?: Element,
|
|
457
|
-
slotName?: string,
|
|
458
|
-
): Element;
|
|
459
|
-
/** Checks if a named slot is filled */
|
|
460
|
-
isSlotFilled(slotName: string): boolean;
|
|
461
|
-
}
|
|
450
|
+
export type TranscludeFunctionObject = BoundTranscludeFn;
|
|
462
451
|
/**
|
|
463
452
|
* Callback used when transcluded content is cloned.
|
|
464
453
|
*/
|
|
465
|
-
export type CloneAttachFunction =
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
export interface
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
}
|
|
476
|
-
export interface TemplateLinkingFunctionOptions {
|
|
477
|
-
_parentBoundTranscludeFn?: TranscludeFunctionObject | undefined;
|
|
478
|
-
transcludeControllers?:
|
|
479
|
-
| {
|
|
480
|
-
[controller: string]: {
|
|
481
|
-
instance: Controller;
|
|
482
|
-
};
|
|
483
|
-
}
|
|
484
|
-
| undefined;
|
|
485
|
-
_futureParentElement?: Element | undefined;
|
|
486
|
-
}
|
|
487
|
-
/**
|
|
488
|
-
* Configuration for ngModel behavior.
|
|
489
|
-
*/
|
|
490
|
-
export interface NgModelOptions {
|
|
491
|
-
/** Space-separated event names that trigger updates */
|
|
492
|
-
updateOn?: string;
|
|
493
|
-
/** Delay in milliseconds or event-specific debounce times */
|
|
494
|
-
debounce?: number | Record<string, number>;
|
|
495
|
-
/** Whether to allow invalid values */
|
|
496
|
-
allowInvalid?: boolean;
|
|
497
|
-
/** Enables getter/setter style ngModel */
|
|
498
|
-
getterSetter?: boolean;
|
|
499
|
-
/** Timezone used for Date objects */
|
|
500
|
-
timezone?: string;
|
|
501
|
-
/** Time display format including seconds */
|
|
502
|
-
timeSecondsFormat?: string;
|
|
503
|
-
/** Whether to remove trailing :00 seconds */
|
|
504
|
-
timeStripZeroSeconds?: boolean;
|
|
505
|
-
}
|
|
506
|
-
export interface RootElementService extends Element {}
|
|
507
|
-
/**
|
|
508
|
-
* The minimal local definitions required by $controller(ctrl, locals) calls.
|
|
509
|
-
*/
|
|
510
|
-
export interface ControllerLocals {
|
|
511
|
-
$scope: Scope;
|
|
512
|
-
$element: Element;
|
|
454
|
+
export type CloneAttachFunction = CloneAttachFn;
|
|
455
|
+
export type TemplateLinkingFunction = PublicLinkFn;
|
|
456
|
+
export type TemplateLinkingFunctionOptions =
|
|
457
|
+
CompileTemplateLinkingFunctionOptions;
|
|
458
|
+
export interface RootElementService extends HTMLElement {}
|
|
459
|
+
export interface InvocationDetail {
|
|
460
|
+
expr: string;
|
|
461
|
+
_reply?: {
|
|
462
|
+
resolve: (value: any) => any;
|
|
463
|
+
reject: (reason: any) => PromiseLike<never>;
|
|
464
|
+
};
|
|
513
465
|
}
|