@angular-wave/angular.ts 0.0.69 → 0.0.71

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 (45) hide show
  1. package/dist/angular-ts.esm.js +2 -2
  2. package/dist/angular-ts.umd.js +2 -2
  3. package/package.json +1 -1
  4. package/src/animations/shared.js +14 -5
  5. package/src/core/compile/attributes.js +326 -0
  6. package/src/core/compile/compile.js +76 -434
  7. package/src/core/compile/compile.spec.js +2 -2
  8. package/src/core/interpolate/interpolate.js +1 -12
  9. package/src/core/location/location.js +26 -4
  10. package/src/core/parser/parse.js +50 -47
  11. package/src/core/scope/scope.js +4 -8
  12. package/src/{exts → directive}/aria/aria.html +1 -1
  13. package/src/directive/aria/aria.js +382 -0
  14. package/src/{exts → directive}/aria/aria.spec.js +12 -12
  15. package/src/{exts → directive}/aria/aria.test.js +1 -1
  16. package/src/directive/form/form.js +3 -1
  17. package/src/directive/messages/messages.js +268 -274
  18. package/src/filters/filter.js +0 -3
  19. package/src/filters/limit-to.js +0 -1
  20. package/src/public.js +27 -3
  21. package/src/router/state/state-object.js +4 -9
  22. package/src/router/url/url-matcher.js +1 -1
  23. package/src/router/url/url-rule.js +5 -1
  24. package/src/router/url/url-service.js +1 -1
  25. package/src/shared/jqlite/jqlite.js +13 -1
  26. package/src/shared/utils.js +0 -2
  27. package/src/types.js +1 -1
  28. package/types/animations/shared.d.ts +11 -6
  29. package/types/core/compile/attributes.d.ts +101 -0
  30. package/types/core/compile/compile.d.ts +10 -67
  31. package/types/core/interpolate/interpolate.d.ts +1 -12
  32. package/types/core/location/location.d.ts +12 -2
  33. package/types/core/parser/parse.d.ts +10 -10
  34. package/types/core/scope/scope.d.ts +21 -22
  35. package/types/directive/aria/aria.d.ts +94 -0
  36. package/types/directive/form/form.d.ts +2 -11
  37. package/types/router/state/state-object.d.ts +0 -2
  38. package/types/router/url/url-matcher.d.ts +2 -2
  39. package/types/router/url/url-rule.d.ts +2 -1
  40. package/types/shared/jqlite/jqlite.d.ts +8 -4
  41. package/types/shared/utils.d.ts +0 -2
  42. package/types/types.d.ts +1 -1
  43. package/src/exts/aria/aria.js +0 -415
  44. package/types/exts/aria/aria.d.ts +0 -1
  45. /package/src/{exts → directive}/aria/aria.md +0 -0
package/src/public.js CHANGED
@@ -97,8 +97,21 @@ import {
97
97
  ngMessagesDirective,
98
98
  ngMessagesIncludeDirective,
99
99
  } from "./directive/messages/messages";
100
- import { initAriaModule } from "./exts/aria/aria";
101
100
  import { initRouter } from "./router/index";
101
+ import {
102
+ AriaProvider,
103
+ ngCheckedAriaDirective,
104
+ ngClickAriaDirective,
105
+ ngDblclickAriaDirective,
106
+ ngDisabledAriaDirective,
107
+ ngHideAriaDirective,
108
+ ngMessagesAriaDirective,
109
+ ngModelAriaDirective,
110
+ ngReadonlyAriaDirective,
111
+ ngRequiredAriaDirective,
112
+ ngShowAriaDirective,
113
+ ngValueAriaDirective,
114
+ } from "./directive/aria/aria";
102
115
 
103
116
  /**
104
117
  * @type {string} `version` from `package.json`, injected by Rollup plugin
@@ -140,6 +153,7 @@ export function publishExternalAPI(angular) {
140
153
  ngClassOdd: ngClassOddDirective,
141
154
  ngCloak: ngCloakDirective,
142
155
  ngController: ngControllerDirective,
156
+ ngDisabled: ngDisabledAriaDirective,
143
157
  ngForm: ngFormDirective,
144
158
  ngHide: ngHideDirective,
145
159
  ngIf: ngIfDirective,
@@ -175,12 +189,23 @@ export function publishExternalAPI(angular) {
175
189
  ngModelOptions: ngModelOptionsDirective,
176
190
  })
177
191
  .directive({
178
- ngInclude: ngIncludeFillContentDirective,
179
192
  input: hiddenInputBrowserCacheDirective,
193
+ ngChecked: ngCheckedAriaDirective,
194
+ ngClick: ngClickAriaDirective,
195
+ ngDblclick: ngDblclickAriaDirective,
196
+ ngInclude: ngIncludeFillContentDirective,
197
+ ngHide: ngHideAriaDirective,
198
+ ngShow: ngShowAriaDirective,
199
+ ngMessages: ngMessagesAriaDirective,
200
+ ngModel: ngModelAriaDirective,
201
+ ngReadonly: ngReadonlyAriaDirective,
202
+ ngRequired: ngRequiredAriaDirective,
203
+ ngValue: ngValueAriaDirective,
180
204
  })
181
205
  .directive(ngAttributeAliasDirectives)
182
206
  .directive(ngEventDirectives);
183
207
  $provide.provider({
208
+ $aria: AriaProvider,
184
209
  $anchorScroll: AnchorScrollProvider,
185
210
  $animate: AnimateProvider,
186
211
  $animateCss: CoreAnimateCssProvider,
@@ -218,7 +243,6 @@ export function publishExternalAPI(angular) {
218
243
  .info({ version: VERSION });
219
244
 
220
245
  initAnimateModule(angular);
221
- initAriaModule(angular);
222
246
  initRouter(angular);
223
247
  return ng;
224
248
  }
@@ -22,12 +22,10 @@ export class StateObject {
22
22
  * @returns {StateObject} an internal State object
23
23
  */
24
24
  static create(stateDecl) {
25
- const state = StateObject.isStateClass(stateDecl)
26
- ? new stateDecl()
27
- : Object.setPrototypeOf(
28
- Object.assign({}, stateDecl),
29
- StateObject.prototype,
30
- );
25
+ const state = Object.setPrototypeOf(
26
+ Object.assign({}, stateDecl),
27
+ StateObject.prototype,
28
+ );
31
29
  stateDecl.$$state = () => state;
32
30
  state.self = stateDecl;
33
31
  state.__stateObjectCache = {
@@ -110,9 +108,6 @@ export class StateObject {
110
108
  return this.fqn();
111
109
  }
112
110
  }
113
- /** Predicate which returns true if the object is an class with @State() decorator */
114
- StateObject.isStateClass = (stateDecl) =>
115
- isFunction(stateDecl) && stateDecl["__uiRouterState"] === true;
116
111
  /** Predicate which returns true if the object is a [[StateDeclaration]] object */
117
112
  StateObject.isStateDeclaration = (obj) => isFunction(obj["$$state"]);
118
113
  /** Predicate which returns true if the object is an internal [[StateObject]] object */
@@ -406,7 +406,7 @@ export class UrlMatcher {
406
406
  *
407
407
  * @param id
408
408
  * @param opts
409
- * @returns {T|Param|any|boolean|UrlMatcher|null}
409
+ * @returns {Param|any|boolean|UrlMatcher|null}
410
410
  */
411
411
  parameter(id, opts = {}) {
412
412
  const findParam = () => {
@@ -203,7 +203,11 @@ export class BaseUrlRule {
203
203
  this.match = match;
204
204
  this.type = "RAW";
205
205
  this.$id = -1;
206
- this.matchPriority = () => 0 - this.$id;
206
+ this._group = undefined;
207
207
  this.handler = handler || ((x) => x);
208
208
  }
209
+
210
+ matchPriority() {
211
+ return 0 - this.$id;
212
+ }
209
213
  }
@@ -356,7 +356,7 @@ export class UrlService {
356
356
  return;
357
357
  }
358
358
  if (this.url() === this.location) return;
359
- this.url(this.location, true);
359
+ this.url(/** @type {string} */ (this.location), true);
360
360
  }
361
361
 
362
362
  /**
@@ -62,7 +62,7 @@ const BOOLEAN_ELEMENTS = {};
62
62
  * JQLite both a function and an array-like data structure for manipulation of DOM, linking elements to expando cache,
63
63
  * and execution of chain functions.
64
64
  *
65
- * @param {string|Node|JQLite|ArrayLike<Element>|(() => void)|Window} element
65
+ * @param {string|Node|Node[]|NodeList|JQLite|ArrayLike<Element>|(() => void)|Window} element
66
66
  * @returns {JQLite}
67
67
  */
68
68
  export function JQLite(element) {
@@ -116,6 +116,18 @@ JQLite.prototype = {
116
116
  length: 0,
117
117
  };
118
118
 
119
+ /**
120
+ * @returns {Element[]}
121
+ */
122
+ JQLite.prototype.elements = function () {
123
+ /** @type {Element[]} */
124
+ let elements = [];
125
+ for (let index = 0; index < this.length; index++) {
126
+ elements.push(this[index]);
127
+ }
128
+ return elements;
129
+ };
130
+
119
131
  /**
120
132
  * Remove all child nodes of the set of matched elements from the DOM and clears CACHE data, associated with the node.
121
133
  * @returns {JQLite} The current instance of JQLite.
@@ -185,7 +185,6 @@ export function isFunction(value) {
185
185
  /**
186
186
  * Determines if a value is a regular expression object.
187
187
  *
188
- * @private
189
188
  * @param {*} value Reference to check.
190
189
  * @returns {boolean} True if `value` is a `RegExp`.
191
190
  */
@@ -196,7 +195,6 @@ export function isRegExp(value) {
196
195
  /**
197
196
  * Checks if `obj` is a window object.
198
197
  *
199
- * @private
200
198
  * @param {*} obj Object to check
201
199
  * @returns {boolean} True if `obj` is a window obj.
202
200
  */
package/src/types.js CHANGED
@@ -217,7 +217,7 @@
217
217
  /**
218
218
 
219
219
  *
220
- * @typedef {function(TScope, CloneAttachFunction, import('./shared/jqlite/jqlite').JQLite=, string=): import('./shared/jqlite/jqlite').JQLite} TranscludeFunction
220
+ * @typedef {function(TScope|Function, CloneAttachFunction=, import('./shared/jqlite/jqlite').JQLite=, string=): import('./shared/jqlite/jqlite').JQLite} TranscludeFunction
221
221
  */
222
222
 
223
223
  /**
@@ -6,12 +6,17 @@ export function packageStyles(options: any): {
6
6
  };
7
7
  export function pendClasses(classes: any, fix: any, isPrefix: any): string;
8
8
  export function removeFromArray(arr: any, val: any): void;
9
- export function stripCommentsFromElement(element: any): JQLite | {
10
- toString(): string;
11
- eq(index: any): JQLite;
12
- length: number;
13
- };
14
- export function extractElementNode(element: any): any;
9
+ /**
10
+ *
11
+ * @param {JQLite|Node} element
12
+ * @returns {JQLite}
13
+ */
14
+ export function stripCommentsFromElement(element: JQLite | Node): JQLite;
15
+ /**
16
+ * @param {JQLite|Node} element
17
+ * @returns {Node}
18
+ */
19
+ export function extractElementNode(element: JQLite | Node): Node;
15
20
  export function applyAnimationClassesFactory(): (element: any, options: any) => void;
16
21
  export function prepareAnimationOptions(options: any): any;
17
22
  export function applyAnimationStyles(element: any, options: any): void;
@@ -0,0 +1,101 @@
1
+ export class Attributes {
2
+ /**
3
+ *
4
+ * @param {import('../scope/scope').Scope} $rootScope
5
+ * @param {*} $animate
6
+ * @param {import("../exception-handler").ExceptionHandlerProvider} $exceptionHandler
7
+ * @param {*} $sce
8
+ * @param {import('../../shared/jqlite/jqlite').JQLite} [element]
9
+ * @param {*} [attributesToCopy]
10
+ */
11
+ constructor($rootScope: import("../scope/scope").Scope, $animate: any, $exceptionHandler: import("../exception-handler").ExceptionHandlerProvider, $sce: any, element?: import("../../shared/jqlite/jqlite").JQLite, attributesToCopy?: any);
12
+ $rootScope: import("../scope/scope").Scope;
13
+ $animate: any;
14
+ $exceptionHandler: any;
15
+ $sce: any;
16
+ $attr: {};
17
+ $$element: import("../../shared/jqlite/jqlite").JQLite;
18
+ /**
19
+ * @ngdoc method
20
+ * @name $compile.directive.Attributes#$normalize
21
+ * @kind function
22
+ *
23
+ * @description
24
+ * Converts an attribute name (e.g. dash/colon/underscore-delimited string, optionally prefixed with `x-` or
25
+ * `data-`) to its normalized, camelCase form.
26
+ *
27
+ * Also there is special case for Moz prefix starting with upper case letter.
28
+ *
29
+ * For further information check out the guide on {@link guide/directive#matching-directives Matching Directives}
30
+ *
31
+ * @param {string} name Name to normalize
32
+ */
33
+ $normalize: typeof directiveNormalize;
34
+ /**
35
+ * @ngdoc method
36
+ * @name $compile.directive.Attributes#$addClass
37
+ * @kind function
38
+ *
39
+ * @description
40
+ * Adds the CSS class value specified by the classVal parameter to the element. If animations
41
+ * are enabled then an animation will be triggered for the class addition.
42
+ *
43
+ * @param {string} classVal The className value that will be added to the element
44
+ */
45
+ $addClass(classVal: string): void;
46
+ /**
47
+ * @ngdoc method
48
+ * @name $compile.directive.Attributes#$removeClass
49
+ * @kind function
50
+ *
51
+ * @description
52
+ * Removes the CSS class value specified by the classVal parameter from the element. If
53
+ * animations are enabled then an animation will be triggered for the class removal.
54
+ *
55
+ * @param {string} classVal The className value that will be removed from the element
56
+ */
57
+ $removeClass(classVal: string): void;
58
+ /**
59
+ * @ngdoc method
60
+ * @name $compile.directive.Attributes#$updateClass
61
+ * @kind function
62
+ *
63
+ * @description
64
+ * Adds and removes the appropriate CSS class values to the element based on the difference
65
+ * between the new and old CSS class values (specified as newClasses and oldClasses).
66
+ *
67
+ * @param {string} newClasses The current CSS className value
68
+ * @param {string} oldClasses The former CSS className value
69
+ */
70
+ $updateClass(newClasses: string, oldClasses: string): void;
71
+ /**
72
+ * Set a normalized attribute on the element in a way such that all directives
73
+ * can share the attribute. This function properly handles boolean attributes.
74
+ * @param {string} key Normalized key. (ie ngAttribute)
75
+ * @param {string|boolean} value The value to set. If `null` attribute will be deleted.
76
+ * @param {boolean=} writeAttr If false, does not write the value to DOM element attribute.
77
+ * Defaults to true.
78
+ * @param {string=} attrName Optional none normalized name. Defaults to key.
79
+ */
80
+ $set(key: string, value: string | boolean, writeAttr?: boolean | undefined, attrName?: string | undefined): void;
81
+ /**
82
+ * Observes an interpolated attribute.
83
+ *
84
+ * The observer function will be invoked once during the next `$digest` following
85
+ * compilation. The observer is then invoked whenever the interpolated value
86
+ * changes.
87
+ *
88
+ * @param {string} key Normalized key. (ie ngAttribute) .
89
+ * @param {any} fn Function that will be called whenever
90
+ the interpolated value of the attribute changes.
91
+ * See the {@link guide/interpolation#how-text-and-attribute-bindings-work Interpolation
92
+ * guide} for more info.
93
+ * @returns {function()} Returns a deregistration function for this observer.
94
+ */
95
+ $observe(key: string, fn: any): () => any;
96
+ $$observers: any;
97
+ setSpecialAttr(element: any, attrName: any, value: any): void;
98
+ sanitizeSrcset(value: any, invokeType: any): any;
99
+ srcset: any;
100
+ }
101
+ import { directiveNormalize } from "../../shared/utils";
@@ -2,11 +2,6 @@ export function $CompileProvider($provide: any, $$sanitizeUriProvider: any): voi
2
2
  export class $CompileProvider {
3
3
  constructor($provide: any, $$sanitizeUriProvider: any);
4
4
  /**
5
- * @ngdoc method
6
- * @name $compileProvider#directive
7
- * @kind function
8
- *
9
- * @description
10
5
  * Register a new directive with the compiler.
11
6
  *
12
7
  * @param {string|Object} name Name of the directive in camel-case (i.e. `ngBind` which will match
@@ -18,18 +13,14 @@ export class $CompileProvider {
18
13
  */
19
14
  directive: (name: string | any, directiveFactory: Function | any[]) => $CompileProvider;
20
15
  /**
21
- * @ngdoc method
22
- * @name $compileProvider#component
23
- * @module ng
24
16
  * @param {string|Object} name Name of the component in camelCase (i.e. `myComp` which will match `<my-comp>`),
25
17
  * or an object map of components where the keys are the names and the values are the component definition objects.
26
18
  * @param {Object} options Component definition object (a simplified
27
- * {@link ng.$compile#directive-definition-object directive definition object}),
19
+ * {directive definition object}),
28
20
  * with the following properties (all optional):
29
21
  *
30
22
  * - `controller` – `{(string|function()=}` – controller constructor function that should be
31
- * associated with newly created scope or the name of a {@link ng.$compile#-controller-
32
- * registered controller} if passed as a string. An empty `noop` function by default.
23
+ * associated with newly created scope or the name of a {controller} if passed as a string. An empty `noop` function by default.
33
24
  * - `controllerAs` – `{string=}` – identifier name for to reference the controller in the component's scope.
34
25
  * If present, the controller will be published to scope under the `controllerAs` name.
35
26
  * If not present, this will default to be `$ctrl`.
@@ -37,7 +28,7 @@ export class $CompileProvider {
37
28
  * returns an html template as a string which should be used as the contents of this component.
38
29
  * Empty string by default.
39
30
  *
40
- * If `template` is a function, then it is {@link auto.$injector#invoke injected} with
31
+ * If `template` is a function, then it is {injected} with
41
32
  * the following locals:
42
33
  *
43
34
  * - `$element` - Current element
@@ -46,7 +37,7 @@ export class $CompileProvider {
46
37
  * - `templateUrl` – `{string=|function()=}` – path or function that returns a path to an html
47
38
  * template that should be used as the contents of this component.
48
39
  *
49
- * If `templateUrl` is a function, then it is {@link auto.$injector#invoke injected} with
40
+ * If `templateUrl` is a function, then it is {injected} with
50
41
  * the following locals:
51
42
  *
52
43
  * - `$element` - Current element
@@ -54,57 +45,18 @@ export class $CompileProvider {
54
45
  *
55
46
  * - `bindings` – `{object=}` – defines bindings between DOM attributes and component properties.
56
47
  * Component properties are always bound to the component controller and not to the scope.
57
- * See {@link ng.$compile#-bindtocontroller- `bindToController`}.
58
- * - `transclude` – `{boolean=}` – whether {@link $compile#transclusion content transclusion} is enabled.
48
+ * See {`bindToController`}.
49
+ * - `transclude` – `{boolean=}` – whether {content transclusion} is enabled.
59
50
  * Disabled by default.
60
51
  * - `require` - `{Object<string, string>=}` - requires the controllers of other directives and binds them to
61
52
  * this component's controller. The object keys specify the property names under which the required
62
- * controllers (object values) will be bound. See {@link ng.$compile#-require- `require`}.
53
+ * controllers (object values) will be bound. See {`require`}.
63
54
  * - `$...` – additional properties to attach to the directive factory function and the controller
64
55
  * constructor function. (This is used by the component router to annotate)
65
56
  *
66
- * @returns {ng.$compileProvider} the compile provider itself, for chaining of function calls.
67
- * @description
68
- * Register a **component definition** with the compiler. This is a shorthand for registering a special
69
- * type of directive, which represents a self-contained UI component in your application. Such components
70
- * are always isolated (i.e. `scope: {}`) and are always restricted to elements (i.e. `restrict: 'E'`).
71
- *
72
- * Component definitions are very simple and do not require as much configuration as defining general
73
- * directives. Component definitions usually consist only of a template and a controller backing it.
74
- *
75
- * In order to make the definition easier, components enforce best practices like use of `controllerAs`,
76
- * `bindToController`. They always have **isolate scope** and are restricted to elements.
77
- *
78
- * Here are a few examples of how you would usually define components:
79
- *
80
- * ```js
81
- * let myMod = angular.module(...);
82
- * myMod.component('myComp', {
83
- * template: '<div>My name is {{$ctrl.name}}</div>',
84
- * controller: function() {
85
- * this.name = 'shahar';
86
- * }
87
- * });
88
- *
89
- * myMod.component('myComp', {
90
- * template: '<div>My name is {{$ctrl.name}}</div>',
91
- * bindings: {name: '@'}
92
- * });
93
- *
94
- * myMod.component('myComp', {
95
- * templateUrl: 'views/my-comp.html',
96
- * controller: 'MyCtrl',
97
- * controllerAs: 'ctrl',
98
- * bindings: {name: '@'}
99
- * });
100
- *
101
- * ```
102
- * For more examples, and an in-depth guide, see the {@link guide/component component guide}.
103
- *
104
- * <br />
105
- * See also {@link ng.$compileProvider#directive $compileProvider.directive()}.
57
+ * @returns {$CompileProvider} the compile provider itself, for chaining of function calls.
106
58
  */
107
- component: (name: string | any, options: any) => ng.$compileProvider;
59
+ component: (name: string | any, options: any) => $CompileProvider;
108
60
  /**
109
61
  * @ngdoc method
110
62
  * @name $compileProvider#aHrefSanitizationTrustedUrlList
@@ -127,11 +79,6 @@ export class $CompileProvider {
127
79
  */
128
80
  aHrefSanitizationTrustedUrlList: (regexp?: RegExp | undefined) => RegExp | $CompileProvider;
129
81
  /**
130
- * @ngdoc method
131
- * @name $compileProvider#imgSrcSanitizationTrustedUrlList
132
- * @kind function
133
- *
134
- * @description
135
82
  * Retrieves or overrides the default regular expression that is used for determining trusted safe
136
83
  * urls during img[src] sanitization.
137
84
  *
@@ -149,10 +96,6 @@ export class $CompileProvider {
149
96
  imgSrcSanitizationTrustedUrlList: (regexp?: RegExp | undefined) => RegExp | $CompileProvider;
150
97
  strictComponentBindingsEnabled: (enabled: any) => boolean | this;
151
98
  /**
152
- * @ngdoc method
153
- * @name $compileProvider#addPropertySecurityContext
154
- * @description
155
- *
156
99
  * Defines the security context for DOM properties bound by ng-prop-*.
157
100
  *
158
101
  * @param {string} elementName The element name or '*' to match any element.
@@ -161,7 +104,7 @@ export class $CompileProvider {
161
104
  * @returns {object} `this` for chaining
162
105
  */
163
106
  addPropertySecurityContext: (elementName: string, propertyName: string, ctx: string) => object;
164
- $get: (string | (($injector: import("../../core/di/internal-injector").InjectorService, $interpolate: any, $exceptionHandler: any, $templateRequest: any, $parse: any, $controller: any, $rootScope: any, $sce: any, $animate: any) => ($compileNodes: string | NodeList, transcludeFn: any, maxPriority: any, ignoreDirective: any, previousCompileContext: any) => (scope: any, cloneConnectFn: any, options: any) => string | NodeList | JQLite))[];
107
+ $get: (string | (($injector: import("../../core/di/internal-injector").InjectorService, $interpolate: any, $exceptionHandler: import("../exception-handler").ExceptionHandlerProvider, $templateRequest: any, $parse: import("../parser/parse").ParseService, $controller: any, $rootScope: import("../scope/scope").Scope, $sce: any, $animate: any) => ($compileNodes: string | NodeList, transcludeFn: any, maxPriority: any, ignoreDirective: any, previousCompileContext: any) => (scope: any, cloneConnectFn: any, options: any) => JQLite))[];
165
108
  }
166
109
  export namespace $CompileProvider {
167
110
  let $inject: string[];
@@ -1,9 +1,4 @@
1
1
  /**
2
- * @ngdoc provider
3
- * @name $interpolateProvider
4
- *
5
- *
6
- * @description
7
2
  *
8
3
  * Used for configuring the interpolation markup. Defaults to `{{` and `}}`.
9
4
  *
@@ -18,9 +13,6 @@
18
13
  export function $InterpolateProvider(): void;
19
14
  export class $InterpolateProvider {
20
15
  /**
21
- * @ngdoc method
22
- * @name $interpolateProvider#startSymbol
23
- * @description
24
16
  * Symbol to denote start of expression in the interpolated string. Defaults to `{{`.
25
17
  *
26
18
  * @param {string=} value new value to set the starting symbol to.
@@ -28,16 +20,13 @@ export class $InterpolateProvider {
28
20
  */
29
21
  startSymbol: (value?: string | undefined) => string | (Window & typeof globalThis);
30
22
  /**
31
- * @ngdoc method
32
- * @name $interpolateProvider#endSymbol
33
- * @description
34
23
  * Symbol to denote the end of expression in the interpolated string. Defaults to `}}`.
35
24
  *
36
25
  * @param {string=} value new value to set the ending symbol to.
37
26
  * @returns {string|self} Returns the symbol when used as getter and self if used as setter.
38
27
  */
39
28
  endSymbol: (value?: string | undefined) => string | (Window & typeof globalThis);
40
- $get: (string | (($parse: any, $exceptionHandler: import("../exception-handler").ErrorHandler, $sce: any) => {
29
+ $get: (string | (($parse: import("../parser/parse").ParseService, $exceptionHandler: import("../exception-handler").ErrorHandler, $sce: any) => {
41
30
  (text: string, mustHaveExpression?: boolean | undefined, trustedContext?: string | undefined, allOrNothing?: boolean | undefined): (arg0: context) => any;
42
31
  /**
43
32
  * @ngdoc method
@@ -223,6 +223,13 @@ export class Location {
223
223
  */
224
224
  state(state: any, ...args: any[]): any;
225
225
  $$state: any;
226
+ /**
227
+ * @param {string} _url
228
+ * @param {string} _url2
229
+ * @returns {boolean}
230
+ */
231
+ $$parseLinkUrl(_url: string, _url2: string): boolean;
232
+ $$parse(_url: any): void;
226
233
  }
227
234
  /**
228
235
  * This object is exposed as $location service when HTML5 mode is enabled and supported
@@ -241,7 +248,6 @@ export class LocationHtml5Url extends Location {
241
248
  */
242
249
  $$parse(url: string): void;
243
250
  $$normalizeUrl(url: any): string;
244
- $$parseLinkUrl: (url: any, relHref: any) => boolean;
245
251
  }
246
252
  /**
247
253
  * LocationHashbangUrl represents URL
@@ -264,7 +270,11 @@ export class LocationHashbangUrl extends Location {
264
270
  */
265
271
  $$parse(url: string): void;
266
272
  $$normalizeUrl(url: any): any;
267
- $$parseLinkUrl(url: any): boolean;
273
+ /**
274
+ * @param {string} url
275
+ * @returns {boolean}
276
+ */
277
+ $$parseLinkUrl(url: string): boolean;
268
278
  }
269
279
  export type DefaultPorts = {
270
280
  http: number;
@@ -2,11 +2,11 @@
2
2
  * @typedef {Object} CompiledExpressionProps
3
3
  * @property {boolean} literal - Indicates if the expression is a literal.
4
4
  * @property {boolean} constant - Indicates if the expression is constant.
5
- * @property {boolean} isPure
5
+ * @property {boolean} [isPure]
6
6
  * @property {boolean} oneTime
7
- * @property {function(import('../scope/scope').Scope, import('../scope/scope').WatchListener, boolean, CompiledExpression, string | ((scope: import('../scope/scope').Scope) => any)): any} $$watchDelegate
8
- * @property {any[]} inputs
9
- * @property {function(any, any): any} assign - Assigns a value to a context. If value is not provided,
7
+ * @property {function(import('../scope/scope').Scope, import('../scope/scope').WatchListener, boolean, CompiledExpression, string | ((scope: import('../scope/scope').Scope) => any) | CompiledExpression): any} [$$watchDelegate]
8
+ * @property {any[]|Function} inputs
9
+ * @property {function(any, any): any} [assign] - Assigns a value to a context. If value is not provided,
10
10
  */
11
11
  /**
12
12
  * @typedef {Function} CompiledExpressionFunction
@@ -22,7 +22,7 @@
22
22
  * @typedef {CompiledExpressionFunction & CompiledExpressionProps} CompiledExpression
23
23
  */
24
24
  /**
25
- * @typedef {function(string|function(import('../scope/scope').Scope):any, function(any, import('../scope/scope').Scope, any):any=, boolean=): CompiledExpression} ParseService
25
+ * @typedef {function(CompiledExpression|string|function(import('../scope/scope').Scope):any, function(any, import('../scope/scope').Scope, any):any=, boolean=): CompiledExpression} ParseService
26
26
  */
27
27
  export function $ParseProvider(): void;
28
28
  export class $ParseProvider {
@@ -59,15 +59,15 @@ export type CompiledExpressionProps = {
59
59
  * - Indicates if the expression is constant.
60
60
  */
61
61
  constant: boolean;
62
- isPure: boolean;
62
+ isPure?: boolean;
63
63
  oneTime: boolean;
64
- $$watchDelegate: (arg0: import("../scope/scope").Scope, arg1: import("../scope/scope").WatchListener, arg2: boolean, arg3: CompiledExpression, arg4: string | ((scope: import("../scope/scope").Scope) => any)) => any;
65
- inputs: any[];
64
+ $$watchDelegate?: (arg0: import("../scope/scope").Scope, arg1: import("../scope/scope").WatchListener, arg2: boolean, arg3: CompiledExpression, arg4: string | ((scope: import("../scope/scope").Scope) => any) | CompiledExpression) => any;
65
+ inputs: any[] | Function;
66
66
  /**
67
67
  * - Assigns a value to a context. If value is not provided,
68
68
  */
69
- assign: (arg0: any, arg1: any) => any;
69
+ assign?: (arg0: any, arg1: any) => any;
70
70
  };
71
71
  export type CompiledExpressionFunction = Function;
72
72
  export type CompiledExpression = CompiledExpressionFunction & CompiledExpressionProps;
73
- export type ParseService = (arg0: string | ((arg0: import("../scope/scope").Scope) => any), arg1: ((arg0: any, arg1: import("../scope/scope").Scope, arg2: any) => any) | undefined, arg2: boolean | undefined) => CompiledExpression;
73
+ export type ParseService = (arg0: CompiledExpression | string | ((arg0: import("../scope/scope").Scope) => any), arg1: ((arg0: any, arg1: import("../scope/scope").Scope, arg2: any) => any) | undefined, arg2: boolean | undefined) => CompiledExpression;
@@ -278,7 +278,7 @@ export class Scope {
278
278
  *
279
279
  *
280
280
  *
281
- * @param {string | ((scope: Scope) => any)} watchExp Expression that is evaluated on each
281
+ * @param {string | ((scope: Scope) => any) | import("../parser/parse").CompiledExpression} watchExp Expression that is evaluated on each
282
282
  * {@link ng.$rootScope.Scope#$digest $digest} cycle. A change in the return value triggers
283
283
  * a call to the `listener`.
284
284
  *
@@ -289,7 +289,7 @@ export class Scope {
289
289
  * comparing for reference equality.
290
290
  * @returns {function()} Returns a deregistration function for this listener.
291
291
  */
292
- $watch(watchExp: string | ((scope: Scope) => any), listener?: WatchListener, objectEquality?: boolean | undefined): () => any;
292
+ $watch(watchExp: string | ((scope: Scope) => any) | import("../parser/parse").CompiledExpression, listener?: WatchListener, objectEquality?: boolean | undefined): () => any;
293
293
  /**
294
294
  * @ngdoc method
295
295
  * @name $rootScope.Scope#$watchGroup
@@ -404,10 +404,9 @@ export class Scope {
404
404
  */
405
405
  $digest(): void;
406
406
  /**
407
- * @private
408
407
  * @param {ScopePhase} phase
409
408
  */
410
- private beginPhase;
409
+ beginPhase(phase: ScopePhase): void;
411
410
  /**
412
411
  * @ngdoc method
413
412
  * @name $rootScope.Scope#$suspend
@@ -568,6 +567,24 @@ export class Scope {
568
567
  * @returns {*} The result of evaluating the expression.
569
568
  */
570
569
  $apply(expr?: string | ((arg0: Scope) => any)): any;
570
+ /**
571
+ * @ngdoc method
572
+ * @name $rootScope.Scope#$applyAsync
573
+ * @kind function
574
+ *
575
+ * @description
576
+ * Schedule the invocation of $apply to occur at a later time. The actual time difference
577
+ * varies across browsers, but is typically around ~10 milliseconds.
578
+ *
579
+ * This can be used to queue up multiple expressions which need to be evaluated in the same
580
+ * digest.
581
+ *
582
+ * @param {(string|function())=} expr An AngularTS expression to be executed.
583
+ *
584
+ * - `string`: execute using the rules as defined in {@link guide/expression expression}.
585
+ * - `function(scope)`: execute the function with current `scope` parameter.
586
+ */
587
+ $applyAsync(expr?: (string | (() => any)) | undefined): void;
571
588
  /**
572
589
  * @ngdoc method
573
590
  * @name $rootScope.Scope#$evalAsync
@@ -599,24 +616,6 @@ export class Scope {
599
616
  * @param {(object)=} locals Local variables object, useful for overriding values in scope.
600
617
  */
601
618
  $evalAsync(expr?: (string | ((arg0: any) => any)) | undefined, locals?: (object) | undefined): number;
602
- /**
603
- * @ngdoc method
604
- * @name $rootScope.Scope#$applyAsync
605
- * @kind function
606
- *
607
- * @description
608
- * Schedule the invocation of $apply to occur at a later time. The actual time difference
609
- * varies across browsers, but is typically around ~10 milliseconds.
610
- *
611
- * This can be used to queue up multiple expressions which need to be evaluated in the same
612
- * digest.
613
- *
614
- * @param {(string|function())=} expr An AngularTS expression to be executed.
615
- *
616
- * - `string`: execute using the rules as defined in {@link guide/expression expression}.
617
- * - `function(scope)`: execute the function with current `scope` parameter.
618
- */
619
- $applyAsync(expr?: (string | (() => any)) | undefined): void;
620
619
  /**
621
620
  * @description
622
621
  * Listens on events of a given type. See {@link ng.$rootScope.Scope#$emit $emit} for