@angular-wave/angular.ts 0.0.38 → 0.0.40

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 (263) hide show
  1. package/Makefile +8 -5
  2. package/README.md +1 -1
  3. package/dist/angular-ts.esm.js +2 -1
  4. package/dist/angular-ts.umd.js +2 -1
  5. package/package.json +2 -4
  6. package/rollup.config.js +11 -2
  7. package/src/angular.spec.js +25 -26
  8. package/src/animations/animate-css-driver.js +3 -3
  9. package/src/animations/animate-queue.js +7 -7
  10. package/src/animations/animation.js +2 -2
  11. package/src/animations/shared.js +6 -6
  12. package/src/binding.spec.js +7 -7
  13. package/src/core/animate/animate.js +5 -5
  14. package/src/core/animate/animate.spec.js +31 -31
  15. package/src/core/cache/cache-factory.html +18 -0
  16. package/src/core/cache/{cache-factor.test.js → cache-factory.test.js} +1 -1
  17. package/src/core/compile/compile.js +31 -25
  18. package/src/core/compile/compile.md +2 -2
  19. package/src/core/cookie-reader.spec.js +2 -2
  20. package/src/core/core.html +22 -0
  21. package/src/core/core.test.js +12 -0
  22. package/src/core/document.spec.js +4 -4
  23. package/src/core/exception-handler.js +30 -23
  24. package/src/core/interpolate/interpolate.js +7 -0
  25. package/src/core/{cache/cache-factor.html → location/location.html} +1 -1
  26. package/src/core/location/location.js +2 -2
  27. package/src/core/location/location.spec.js +17 -17
  28. package/src/core/location/location.test.js +12 -0
  29. package/src/core/on.spec.js +3 -3
  30. package/src/core/parser/parse.html +18 -0
  31. package/src/core/parser/parse.spec.js +1 -1
  32. package/src/core/parser/parse.test.js +12 -0
  33. package/src/core/prop.spec.js +3 -4
  34. package/src/core/pubsub/pubsub.html +18 -0
  35. package/src/core/pubsub/pubsub.spec.js +1 -1
  36. package/src/core/pubsub/pubsub.test.js +12 -0
  37. package/src/core/q/q.html +18 -0
  38. package/src/core/q/q.js +33 -0
  39. package/src/core/q/q.test.js +0 -0
  40. package/src/core/root-element.spec.js +4 -4
  41. package/src/core/sanitize/sanitize-uri.spec.js +1 -1
  42. package/src/core/sanitize/sanitize-uri.test.js +12 -0
  43. package/src/core/sanitize/sanitize.html +21 -0
  44. package/src/core/sce/sce.html +18 -0
  45. package/src/core/sce/sce.spec.js +2 -1
  46. package/src/core/sce/sce.test.js +12 -0
  47. package/src/core/scope/scope.html +18 -0
  48. package/src/core/scope/scope.js +5 -8
  49. package/src/core/scope/scope.spec.js +1 -1
  50. package/src/core/scope/scope.test.js +12 -0
  51. package/src/core/task-tracker-factory.js +9 -11
  52. package/src/core/timeout/timeout.html +18 -0
  53. package/src/core/timeout/timeout.js +9 -0
  54. package/src/core/timeout/timeout.spec.js +2 -2
  55. package/src/core/timeout/timout.test.js +12 -0
  56. package/src/core/url-utils/url-utils.html +18 -0
  57. package/src/core/url-utils/url-utils.spec.js +4 -2
  58. package/src/core/url-utils/url-utils.test.js +12 -0
  59. package/src/directive/attrs/attrs.spec.js +1 -2
  60. package/src/directive/attrs/boolean.spec.js +1 -2
  61. package/src/directive/attrs/element-style.spec.js +6 -7
  62. package/src/directive/attrs/src.spec.js +1 -2
  63. package/src/directive/bind/bind.spec.js +1 -2
  64. package/src/directive/class/class.spec.js +15 -16
  65. package/src/directive/cloak/cloak.spec.js +3 -4
  66. package/src/directive/controller/controller.spec.js +4 -5
  67. package/src/directive/events/click.spec.js +1 -2
  68. package/src/directive/events/event.spec.js +1 -1
  69. package/src/directive/events/events.js +7 -0
  70. package/src/directive/form/form.spec.js +17 -17
  71. package/src/directive/if/if.spec.js +2 -2
  72. package/src/directive/include/include.js +2 -2
  73. package/src/directive/include/include.spec.js +32 -32
  74. package/src/directive/init/init.spec.js +2 -3
  75. package/src/directive/input/input.spec.js +3 -3
  76. package/src/directive/list/list.spec.js +1 -2
  77. package/src/directive/model/model.js +13 -0
  78. package/src/directive/model/model.spec.js +4 -5
  79. package/src/directive/model-options/model-options.spec.js +3 -3
  80. package/src/directive/non-bindable/non-bindable.spec.js +1 -2
  81. package/src/directive/options/options.js +5 -5
  82. package/src/directive/options/options.spec.js +13 -13
  83. package/src/directive/ref/href.spec.js +1 -2
  84. package/src/directive/repeat/repeat.spec.js +12 -12
  85. package/src/directive/script/script.spec.js +2 -3
  86. package/src/directive/select/select.js +6 -6
  87. package/src/directive/select/select.spec.js +5 -5
  88. package/src/directive/show-hide/show-hide.spec.js +12 -13
  89. package/src/directive/style/style.spec.js +3 -4
  90. package/src/directive/switch/switch.spec.js +2 -3
  91. package/src/directive/validators/validators.spec.js +1 -1
  92. package/src/exts/aria/aria.spec.js +1 -2
  93. package/src/exts/messages/messages.spec.js +5 -5
  94. package/src/filters/filter.spec.js +5 -5
  95. package/src/filters/filters.html +21 -0
  96. package/src/filters/filters.spec.js +3 -3
  97. package/src/filters/filters.test.js +12 -0
  98. package/src/filters/limit-to.md +1 -1
  99. package/src/filters/limit-to.spec.js +4 -4
  100. package/src/filters/order-by.spec.js +2 -2
  101. package/src/index.js +462 -1
  102. package/src/loader.js +62 -17
  103. package/src/public.js +6 -2
  104. package/src/router/directives/state-directives.spec.js +90 -90
  105. package/src/router/directives/view-directive.js +2 -2
  106. package/src/router/directives/view-directive.spec.js +9 -9
  107. package/src/router/state/state.spec.js +2 -4
  108. package/src/router/template-factory.spec.js +2 -2
  109. package/src/router/transition/hook-registry.js +2 -2
  110. package/src/router/view/view.spec.js +1 -1
  111. package/src/services/browser.js +56 -39
  112. package/src/services/document.js +16 -13
  113. package/src/services/log.js +39 -43
  114. package/src/services/template-request.js +9 -0
  115. package/src/shared/common.js +0 -3
  116. package/src/shared/jqlite/jqlite.js +83 -89
  117. package/src/shared/jqlite/jqlite.spec.js +218 -222
  118. package/src/shared/strings.js +2 -2
  119. package/src/shared/test-utils.js +2 -2
  120. package/src/shared/utils.js +8 -11
  121. package/src/src.test.js +10 -0
  122. package/tsconfig.json +1 -1
  123. package/tsconfig.types.json +11 -0
  124. package/types/animations/animate-cache.d.ts +7 -7
  125. package/types/animations/animate-children-directive.d.ts +3 -6
  126. package/types/animations/animate-swap.d.ts +7 -16
  127. package/types/animations/animation.d.ts +2 -11
  128. package/types/animations/raf-scheduler.d.ts +3 -3
  129. package/types/animations/shared.d.ts +9 -24
  130. package/types/core/{animate-css.d.ts → animate/animate-css.d.ts} +2 -8
  131. package/types/core/{cache.d.ts → cache/cache.d.ts} +5 -5
  132. package/types/core/compile/compile.d.ts +173 -0
  133. package/types/core/controller/controller.d.ts +32 -0
  134. package/types/core/exception-handler.d.ts +9 -42
  135. package/types/core/filter/filter.d.ts +9 -0
  136. package/types/core/{interpolate.d.ts → interpolate/interpolate.d.ts} +23 -39
  137. package/types/core/interval/interval-factory.d.ts +4 -0
  138. package/types/core/{interval.d.ts → interval/interval.d.ts} +1 -1
  139. package/types/core/location/location.d.ts +209 -0
  140. package/types/core/pubsub/pubsub.d.ts +156 -0
  141. package/types/core/q/q.d.ts +65 -0
  142. package/types/core/sanitize/sanitize-uri.d.ts +53 -0
  143. package/types/core/{sce.d.ts → sce/sce.d.ts} +80 -86
  144. package/types/core/scope/scope.d.ts +727 -0
  145. package/types/core/task-tracker-factory.d.ts +45 -38
  146. package/types/core/timeout/timeout.d.ts +29 -0
  147. package/types/core/{urlUtils.d.ts → url-utils/url-utils.d.ts} +2 -7
  148. package/types/directive/{bind.d.ts → bind/bind.d.ts} +4 -10
  149. package/types/directive/{class.d.ts → class/class.d.ts} +12 -21
  150. package/types/directive/controller/controller.d.ts +6 -0
  151. package/types/directive/events/events.d.ts +5 -0
  152. package/types/directive/form/form.d.ts +200 -0
  153. package/types/directive/if/if.d.ts +8 -0
  154. package/types/directive/include/include.d.ts +14 -0
  155. package/types/directive/{input.d.ts → input/input.d.ts} +20 -69
  156. package/types/directive/{model.d.ts → model/model.d.ts} +281 -280
  157. package/types/directive/options/options.d.ts +9 -0
  158. package/types/directive/ref/ref.d.ts +5 -0
  159. package/types/directive/repeat/repeat.d.ts +8 -0
  160. package/types/directive/{script.d.ts → script/script.d.ts} +5 -8
  161. package/types/directive/{show-hide.d.ts → show-hide/show-hide.d.ts} +10 -16
  162. package/types/directive/switch/switch.d.ts +17 -0
  163. package/types/directive/transclude/transclude.d.ts +4 -0
  164. package/types/directive/{validators.d.ts → validators/validators.d.ts} +20 -35
  165. package/types/filters/filters.d.ts +10 -16
  166. package/types/filters/order-by.d.ts +2 -4
  167. package/types/index.d.ts +702 -0
  168. package/types/injector.d.ts +12 -0
  169. package/types/public.d.ts +5 -0
  170. package/types/router/common/coreservices.d.ts +2 -2
  171. package/types/router/common/glob.d.ts +9 -9
  172. package/types/router/common/queue.d.ts +13 -13
  173. package/types/router/common/trace.d.ts +43 -43
  174. package/types/router/directives/view-directive.d.ts +13 -32
  175. package/types/router/globals.d.ts +20 -20
  176. package/types/router/hooks/lazy-load.d.ts +2 -11
  177. package/types/router/hooks/redirect-to.d.ts +1 -4
  178. package/types/router/hooks/url.d.ts +1 -5
  179. package/types/router/hooks/views.d.ts +1 -4
  180. package/types/router/params/param-factory.d.ts +5 -5
  181. package/types/router/params/param-type.d.ts +35 -35
  182. package/types/router/params/param-types.d.ts +11 -11
  183. package/types/router/params/param.d.ts +38 -38
  184. package/types/router/params/state-params.d.ts +10 -10
  185. package/types/router/path/path-node.d.ts +34 -34
  186. package/types/router/path/path-utils.d.ts +73 -77
  187. package/types/router/resolve/resolvable.d.ts +32 -32
  188. package/types/router/resolve/resolve-context.d.ts +84 -84
  189. package/types/router/services.d.ts +4 -9
  190. package/types/router/state/state-builder.d.ts +27 -27
  191. package/types/router/state/state-matcher.d.ts +5 -5
  192. package/types/router/state/state-object.d.ts +58 -58
  193. package/types/router/state/state-queue-manager.d.ts +10 -16
  194. package/types/router/state/state-registry.d.ts +100 -107
  195. package/types/router/state/state-service.d.ts +411 -411
  196. package/types/router/state/target-state.d.ts +64 -69
  197. package/types/router/state/views.d.ts +31 -37
  198. package/types/router/state-filters.d.ts +7 -7
  199. package/types/router/state-provider.d.ts +105 -105
  200. package/types/router/template-factory.d.ts +83 -112
  201. package/types/router/transition/hook-builder.d.ts +25 -25
  202. package/types/router/transition/hook-registry.d.ts +68 -83
  203. package/types/router/transition/interface.d.ts +7 -7
  204. package/types/router/transition/reject-factory.d.ts +34 -34
  205. package/types/router/transition/transition-event-type.d.ts +9 -18
  206. package/types/router/transition/transition-hook.d.ts +77 -82
  207. package/types/router/transition/transition-service.d.ts +82 -99
  208. package/types/router/transition/transition.d.ts +369 -377
  209. package/types/router/url/url-config.d.ts +84 -84
  210. package/types/router/url/url-matcher.d.ts +115 -119
  211. package/types/router/url/url-rule.d.ts +114 -124
  212. package/types/router/url/url-rules.d.ts +217 -217
  213. package/types/router/url/url-service.d.ts +264 -269
  214. package/types/router/view/view.d.ts +114 -117
  215. package/types/router/view-scroll.d.ts +2 -2
  216. package/types/services/anchor-scroll.d.ts +2 -8
  217. package/types/services/browser.d.ts +157 -135
  218. package/types/services/cache-factory.d.ts +25 -25
  219. package/types/services/cookie-reader.d.ts +2 -2
  220. package/types/services/document.d.ts +13 -9
  221. package/types/services/http/http.d.ts +145 -0
  222. package/types/services/{http-backend.d.ts → http-backend/http-backend.d.ts} +3 -35
  223. package/types/services/log.d.ts +55 -52
  224. package/types/services/template-request.d.ts +44 -53
  225. package/types/shared/common.d.ts +4 -20
  226. package/types/{constants.d.ts → shared/constants.d.ts} +6 -6
  227. package/types/shared/hof.d.ts +1 -1
  228. package/types/{jqLite.d.ts → shared/jqlite/jqlite.d.ts} +16 -17
  229. package/types/shared/test-utils.d.ts +11 -0
  230. package/types/shared/utils.d.ts +29 -46
  231. package/types-back/global.d.ts +3 -1
  232. package/types-back/index.d.ts +3 -296
  233. package/types/core/compile.d.ts +0 -206
  234. package/types/core/controller.d.ts +0 -42
  235. package/types/core/filter.d.ts +0 -9
  236. package/types/core/interval-factory.d.ts +0 -21
  237. package/types/core/location.d.ts +0 -234
  238. package/types/core/pubsub.d.ts +0 -164
  239. package/types/core/q.d.ts +0 -33
  240. package/types/core/root-scope.d.ts +0 -754
  241. package/types/core/sanitize-uri.d.ts +0 -57
  242. package/types/core/timeout.d.ts +0 -31
  243. package/types/directive/controller.d.ts +0 -6
  244. package/types/directive/events.d.ts +0 -12
  245. package/types/directive/form.d.ts +0 -230
  246. package/types/directive/if.d.ts +0 -17
  247. package/types/directive/include.d.ts +0 -33
  248. package/types/directive/options.d.ts +0 -16
  249. package/types/directive/ref.d.ts +0 -11
  250. package/types/directive/repeat.d.ts +0 -23
  251. package/types/directive/switch.d.ts +0 -23
  252. package/types/directive/transclude.d.ts +0 -15
  253. package/types/services/http.d.ts +0 -157
  254. /package/src/core/cache/{cache-factor.spec.js → cache-factory.spec.js} +0 -0
  255. /package/types/directive/{attrs.d.ts → attrs/attrs.d.ts} +0 -0
  256. /package/types/directive/{change.d.ts → change/change.d.ts} +0 -0
  257. /package/types/directive/{cloak.d.ts → cloak/cloak.d.ts} +0 -0
  258. /package/types/directive/{init.d.ts → init/init.d.ts} +0 -0
  259. /package/types/directive/{list.d.ts → list/list.d.ts} +0 -0
  260. /package/types/directive/{non-bindable.d.ts → non-bindable/non-bindable.d.ts} +0 -0
  261. /package/types/directive/{style.d.ts → style/style.d.ts} +0 -0
  262. /package/types/exts/{aria.d.ts → aria/aria.d.ts} +0 -0
  263. /package/types/exts/{messages.d.ts → messages/messages.d.ts} +0 -0
@@ -3,7 +3,7 @@ import {
3
3
  urlIsSameOrigin,
4
4
  urlIsSameOriginAsBaseUrl,
5
5
  urlIsAllowedOriginFactory,
6
- } from "../../core/urlUtils";
6
+ } from "./url-utils";
7
7
 
8
8
  let $document = window.document;
9
9
 
@@ -18,7 +18,9 @@ describe("urlUtils", () => {
18
18
  });
19
19
 
20
20
  it("should normalize a relative url", () => {
21
- expect(urlResolve("foo").href).toMatch(/^https?:\/\/[^/]+\/foo$/);
21
+ expect(urlResolve("/src/core/url-utils/foo").href).toEqual(
22
+ "http://localhost:4000/src/core/url-utils/foo",
23
+ );
22
24
  });
23
25
 
24
26
  it("should parse relative URL into component pieces", () => {
@@ -0,0 +1,12 @@
1
+ import { test, expect } from "@playwright/test";
2
+
3
+ const TEST_URL = "src/core/url-utils/url-utils.html";
4
+
5
+ test("unit tests contain no errors", async ({ page }) => {
6
+ await page.goto(TEST_URL);
7
+ await page.content();
8
+ await page.waitForTimeout(100);
9
+ await expect(page.locator(".jasmine-overall-result")).toHaveText(
10
+ /0 failures/,
11
+ );
12
+ });
@@ -1,6 +1,6 @@
1
1
  import { publishExternalAPI } from "../../public";
2
2
  import { createInjector } from "../../injector";
3
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
3
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
4
4
 
5
5
  describe("ngSrcset", () => {
6
6
  let $scope;
@@ -17,7 +17,6 @@ describe("ngSrcset", () => {
17
17
 
18
18
  afterEach(() => {
19
19
  dealoc(element);
20
- jqLite.CACHE.clear();
21
20
  });
22
21
 
23
22
  it("should not result empty string in img srcset", () => {
@@ -1,6 +1,6 @@
1
1
  import { publishExternalAPI } from "../../public";
2
2
  import { createInjector } from "../../injector";
3
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
3
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
4
4
 
5
5
  describe("boolean attr directives", () => {
6
6
  let element, $rootScope, $compile, $rootElement;
@@ -21,7 +21,6 @@ describe("boolean attr directives", () => {
21
21
 
22
22
  afterEach(() => {
23
23
  dealoc(element);
24
- jqLite.CACHE.clear();
25
24
  });
26
25
 
27
26
  it("should properly evaluate 0 as false", () => {
@@ -1,6 +1,6 @@
1
1
  import { publishExternalAPI } from "../../public";
2
2
  import { createInjector } from "../../injector";
3
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
3
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
4
4
 
5
5
  describe("style", () => {
6
6
  let $rootScope;
@@ -17,11 +17,10 @@ describe("style", () => {
17
17
 
18
18
  afterEach(() => {
19
19
  dealoc(element);
20
- jqLite.CACHE.clear();
21
20
  });
22
21
 
23
22
  it("should compile style element without binding", () => {
24
- element = jqLite(
23
+ element = JQLite(
25
24
  '<style type="text/css">.header{font-size:1.5em; h3{font-size:1.5em}}</style>',
26
25
  );
27
26
  $compile(element)($rootScope);
@@ -33,7 +32,7 @@ describe("style", () => {
33
32
  });
34
33
 
35
34
  it("should compile style element with one simple bind", () => {
36
- element = jqLite(
35
+ element = JQLite(
37
36
  '<style type="text/css">.some-container{ width: {{elementWidth}}px; }</style>',
38
37
  );
39
38
  $compile(element)($rootScope);
@@ -49,7 +48,7 @@ describe("style", () => {
49
48
  });
50
49
 
51
50
  it("should compile style element with one bind", () => {
52
- element = jqLite(
51
+ element = JQLite(
53
52
  '<style type="text/css">.header{ h3 { font-size: {{fontSize}}em }}</style>',
54
53
  );
55
54
  $compile(element)($rootScope);
@@ -65,7 +64,7 @@ describe("style", () => {
65
64
  });
66
65
 
67
66
  it("should compile style element with two binds", () => {
68
- element = jqLite(
67
+ element = JQLite(
69
68
  '<style type="text/css">.header{ h3 { font-size: {{fontSize}}{{unit}} }}</style>',
70
69
  );
71
70
  $compile(element)($rootScope);
@@ -82,7 +81,7 @@ describe("style", () => {
82
81
  });
83
82
 
84
83
  it("should compile content of element with style attr", () => {
85
- element = jqLite('<div style="some">{{bind}}</div>');
84
+ element = JQLite('<div style="some">{{bind}}</div>');
86
85
  $compile(element)($rootScope);
87
86
  $rootScope.$apply(() => {
88
87
  $rootScope.bind = "value";
@@ -1,6 +1,6 @@
1
1
  import { publishExternalAPI } from "../../public";
2
2
  import { createInjector } from "../../injector";
3
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
3
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
4
4
 
5
5
  describe("ngSrc", () => {
6
6
  let $scope;
@@ -17,7 +17,6 @@ describe("ngSrc", () => {
17
17
 
18
18
  afterEach(() => {
19
19
  dealoc(element);
20
- jqLite.CACHE.clear();
21
20
  });
22
21
 
23
22
  describe("img[ng-src]", () => {
@@ -1,6 +1,6 @@
1
1
  import { publishExternalAPI } from "../../public";
2
2
  import { createInjector } from "../../injector";
3
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
3
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
4
4
 
5
5
  describe("ng-bind", () => {
6
6
  let $rootScope;
@@ -24,7 +24,6 @@ describe("ng-bind", () => {
24
24
 
25
25
  afterEach(() => {
26
26
  dealoc(element);
27
- jqLite.CACHE.clear();
28
27
  });
29
28
 
30
29
  describe("ngBind", () => {
@@ -1,4 +1,4 @@
1
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
1
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
2
2
  import { publishExternalAPI } from "../../public";
3
3
  import { createInjector } from "../../injector";
4
4
  import { valueFn } from "../../shared/utils";
@@ -18,7 +18,6 @@ describe("ngClass", () => {
18
18
 
19
19
  afterEach(() => {
20
20
  dealoc(element);
21
- jqLite.CACHE.clear();
22
21
  });
23
22
 
24
23
  it("should add new and remove old classes dynamically", () => {
@@ -246,8 +245,8 @@ describe("ngClass", () => {
246
245
  '<ul><li ng-repeat="i in [0,1]" class="existing" ng-class-odd="\'odd\'" ng-class-even="\'even\'"></li><ul>',
247
246
  )($rootScope);
248
247
  $rootScope.$digest();
249
- const e1 = jqLite(element[0].childNodes[1]);
250
- const e2 = jqLite(element[0].childNodes[3]);
248
+ const e1 = JQLite(element[0].childNodes[1]);
249
+ const e2 = JQLite(element[0].childNodes[3]);
251
250
  expect(e1[0].classList.contains("existing")).toBeTruthy();
252
251
  expect(e1[0].classList.contains("odd")).toBeTruthy();
253
252
  expect(e2[0].classList.contains("existing")).toBeTruthy();
@@ -262,8 +261,8 @@ describe("ngClass", () => {
262
261
  "<ul>",
263
262
  )($rootScope);
264
263
  $rootScope.$apply();
265
- const e1 = jqLite(element[0].childNodes[1]);
266
- const e2 = jqLite(element[0].childNodes[3]);
264
+ const e1 = JQLite(element[0].childNodes[1]);
265
+ const e2 = JQLite(element[0].childNodes[3]);
267
266
 
268
267
  expect(e1[0].classList.contains("plainClass")).toBeTruthy();
269
268
  expect(e1[0].classList.contains("odd")).toBeTruthy();
@@ -324,8 +323,8 @@ describe("ngClass", () => {
324
323
  "<ul>",
325
324
  )($rootScope);
326
325
  $rootScope.$apply();
327
- const e1 = jqLite(element[0].childNodes[1]);
328
- const e2 = jqLite(element[0].childNodes[3]);
326
+ const e1 = JQLite(element[0].childNodes[1]);
327
+ const e2 = JQLite(element[0].childNodes[3]);
329
328
 
330
329
  expect(e1[0].classList.contains("A")).toBeTruthy();
331
330
  expect(e1[0].classList.contains("B")).toBeTruthy();
@@ -438,8 +437,8 @@ describe("ngClass", () => {
438
437
  $rootScope.items.unshift("a");
439
438
  $rootScope.$digest();
440
439
 
441
- const e1 = jqLite(element[0].childNodes[1]);
442
- const e4 = jqLite(element[0].childNodes[3]);
440
+ const e1 = JQLite(element[0].childNodes[1]);
441
+ const e4 = JQLite(element[0].childNodes[3]);
443
442
 
444
443
  expect(e1[0].classList.contains("odd")).toBeTruthy();
445
444
  expect(e1[0].classList.contains("even")).toBeFalsy();
@@ -461,8 +460,8 @@ describe("ngClass", () => {
461
460
  $rootScope.items = ["a", "a"];
462
461
  $rootScope.$digest();
463
462
 
464
- const e1 = jqLite(element[0].childNodes[1]);
465
- const e2 = jqLite(element[0].childNodes[3]);
463
+ const e1 = JQLite(element[0].childNodes[1]);
464
+ const e2 = JQLite(element[0].childNodes[3]);
466
465
 
467
466
  expect(e1[0].classList.contains("odd")).toBeTruthy();
468
467
  expect(e1[0].classList.contains("even")).toBeFalsy();
@@ -484,8 +483,8 @@ describe("ngClass", () => {
484
483
  $rootScope.items = ["b", "a"];
485
484
  $rootScope.$digest();
486
485
 
487
- const e1 = jqLite(element[0].childNodes[1]);
488
- const e2 = jqLite(element[0].childNodes[3]);
486
+ const e1 = JQLite(element[0].childNodes[1]);
487
+ const e2 = JQLite(element[0].childNodes[3]);
489
488
 
490
489
  expect(e1[0].classList.contains("odd")).toBeTruthy();
491
490
  expect(e1[0].classList.contains("even")).toBeFalsy();
@@ -735,7 +734,7 @@ describe("ngClass", () => {
735
734
  // module("ngAnimateMock");
736
735
  // inject(($compile, $rootScope, $animate, $timeout) => {
737
736
  // element = angular.element('<div ng-class="val"></div>');
738
- // const body = jqLite(window.document.body);
737
+ // const body = JQLite(window.document.body);
739
738
  // body.append(element);
740
739
  // $compile(element)($rootScope);
741
740
 
@@ -784,7 +783,7 @@ describe("ngClass", () => {
784
783
 
785
784
  // $rootScope.val = "crazy";
786
785
  // element = angular.element('<div ng-class="val"></div>');
787
- // jqLite($document[0].body).append($rootElement);
786
+ // JQLite($document[0].body).append($rootElement);
788
787
 
789
788
  // $compile(element)($rootScope);
790
789
 
@@ -1,4 +1,4 @@
1
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
1
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
2
2
  import { publishExternalAPI } from "../../public";
3
3
  import { createInjector } from "../../injector";
4
4
 
@@ -17,18 +17,17 @@ describe("ngCloak", () => {
17
17
 
18
18
  afterEach(() => {
19
19
  dealoc(element);
20
- jqLite.CACHE.clear();
21
20
  });
22
21
 
23
22
  it("should get removed when an element is compiled", () => {
24
- element = jqLite("<div ng-cloak></div>");
23
+ element = JQLite("<div ng-cloak></div>");
25
24
  expect(element.attr("ng-cloak")).toBe("");
26
25
  $compile(element);
27
26
  expect(element.attr("ng-cloak")).toBeUndefined();
28
27
  });
29
28
 
30
29
  it("should remove ngCloak class from a compiled element with attribute", () => {
31
- element = jqLite('<div ng-cloak class="foo ng-cloak bar"></div>');
30
+ element = JQLite('<div ng-cloak class="foo ng-cloak bar"></div>');
32
31
 
33
32
  expect(element[0].classList.contains("foo")).toBe(true);
34
33
  expect(element[0].classList.contains("ng-cloak")).toBe(true);
@@ -1,6 +1,6 @@
1
1
  import { publishExternalAPI } from "../../public";
2
2
  import { createInjector } from "../../injector";
3
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
3
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
4
4
  import { bind } from "../../shared/utils";
5
5
  import { Angular } from "../../loader";
6
6
 
@@ -64,7 +64,6 @@ describe("ngController", () => {
64
64
 
65
65
  afterEach(() => {
66
66
  dealoc(element);
67
- jqLite.CACHE.clear();
68
67
  });
69
68
 
70
69
  it("should instantiate controller and bind methods", () => {
@@ -127,7 +126,7 @@ describe("ngController", () => {
127
126
  });
128
127
 
129
128
  it("should work with ngInclude on the same element", (done) => {
130
- element = jqLite(
129
+ element = JQLite(
131
130
  '<div><div ng-controller="Greeter" ng-include="\'/mock/interpolation\'"></div></div>',
132
131
  );
133
132
  window.angular
@@ -150,7 +149,7 @@ describe("ngController", () => {
150
149
  it("should only instantiate the controller once with ngInclude on the same element", () => {
151
150
  let count = 0;
152
151
 
153
- element = jqLite(
152
+ element = JQLite(
154
153
  '<div><div ng-controller="Count" ng-include="\'/mock/interpolation\'"></div></div>',
155
154
  );
156
155
  window.angular
@@ -175,7 +174,7 @@ describe("ngController", () => {
175
174
  it("when ngInclude is on the same element, the content included content should get a child scope of the controller", () => {
176
175
  let controllerScope;
177
176
 
178
- element = jqLite(
177
+ element = JQLite(
179
178
  '<div><div ng-controller="ExposeScope" ng-include="\'/mock/scopeinit\'"></div></div>',
180
179
  );
181
180
 
@@ -1,4 +1,4 @@
1
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
1
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
2
2
  import { publishExternalAPI } from "../../public";
3
3
  import { createInjector } from "../../injector";
4
4
 
@@ -17,7 +17,6 @@ describe("ngClick", () => {
17
17
 
18
18
  afterEach(() => {
19
19
  dealoc(element);
20
- jqLite.CACHE.clear();
21
20
  });
22
21
 
23
22
  it("should get called on a click", () => {
@@ -1,6 +1,6 @@
1
1
  import { publishExternalAPI } from "../../public";
2
2
  import { createInjector } from "../../injector";
3
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
3
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
4
4
  import { Angular } from "../../loader";
5
5
 
6
6
  describe("event directives", () => {
@@ -23,6 +23,13 @@ const forceAsyncEvents = {
23
23
  "$parse",
24
24
  "$rootScope",
25
25
  "$exceptionHandler",
26
+ /**
27
+ *
28
+ * @param {*} $parse
29
+ * @param {*} $rootScope
30
+ * @param {import('../../core/exception-handler').angular.ErrorHandler} $exceptionHandler
31
+ * @returns
32
+ */
26
33
  ($parse, $rootScope, $exceptionHandler) => {
27
34
  return createEventDirective(
28
35
  $parse,
@@ -1,6 +1,6 @@
1
1
  import { publishExternalAPI } from "../../public";
2
2
  import { createInjector } from "../../injector";
3
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
3
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
4
4
  import { FormController } from "../../directive/form/form";
5
5
  import { Angular } from "../../loader";
6
6
 
@@ -277,7 +277,7 @@ describe("form", () => {
277
277
  });
278
278
 
279
279
  it("should publish widgets", () => {
280
- doc = jqLite(
280
+ doc = JQLite(
281
281
  '<form name="form"><input type="text" name="w1" ng-model="some" /></form>',
282
282
  );
283
283
  $compile(doc)(scope);
@@ -291,7 +291,7 @@ describe("form", () => {
291
291
  });
292
292
 
293
293
  it('should throw an exception if an input has name="hasOwnProperty"', () => {
294
- doc = jqLite(
294
+ doc = JQLite(
295
295
  '<form name="form">' +
296
296
  '<input name="hasOwnProperty" ng-model="some" />' +
297
297
  '<input name="other" ng-model="someOther" />' +
@@ -411,7 +411,7 @@ describe("form", () => {
411
411
  let submitted = false;
412
412
  let reloadPrevented;
413
413
 
414
- doc = jqLite(
414
+ doc = JQLite(
415
415
  '<form ng-submit="submitMe()">' +
416
416
  '<input type="submit" value="submit">' +
417
417
  "</form>",
@@ -445,7 +445,7 @@ describe("form", () => {
445
445
  });
446
446
 
447
447
  it("should prevent the default when the form is destroyed by a submission via a click event", (done) => {
448
- doc = jqLite(
448
+ doc = JQLite(
449
449
  "<div>" +
450
450
  '<form ng-submit="submitMe()">' +
451
451
  '<button type="submit" ng-click="destroy()"></button>' +
@@ -522,7 +522,7 @@ describe("form", () => {
522
522
 
523
523
  describe("nested forms", () => {
524
524
  it("should chain nested forms", () => {
525
- doc = jqLite(
525
+ doc = JQLite(
526
526
  '<ng:form name="parent">' +
527
527
  '<ng:form name="child">' +
528
528
  '<input ng:model="modelA" name="inputA">' +
@@ -558,7 +558,7 @@ describe("form", () => {
558
558
  });
559
559
 
560
560
  it("should set $submitted to true on child forms when parent is submitted", () => {
561
- doc = jqLite(
561
+ doc = JQLite(
562
562
  '<ng-form name="parent">' +
563
563
  '<ng-form name="child">' +
564
564
  '<input ng:model="modelA" name="inputA">' +
@@ -577,7 +577,7 @@ describe("form", () => {
577
577
  });
578
578
 
579
579
  it("should not propagate $submitted state on removed child forms when parent is submitted", () => {
580
- doc = jqLite(
580
+ doc = JQLite(
581
581
  '<ng-form name="parent">' +
582
582
  '<ng-form name="child">' +
583
583
  '<ng-form name="grandchild">' +
@@ -643,7 +643,7 @@ describe("form", () => {
643
643
  });
644
644
 
645
645
  it("should set $submitted to true on child and parent forms when form is submitted", () => {
646
- doc = jqLite(
646
+ doc = JQLite(
647
647
  '<ng-form name="parent">' +
648
648
  '<ng-form name="child">' +
649
649
  '<ng-form name="grandchild">' +
@@ -667,7 +667,7 @@ describe("form", () => {
667
667
  });
668
668
 
669
669
  it("should deregister a child form when its DOM is removed", function () {
670
- doc = jqLite(
670
+ doc = JQLite(
671
671
  '<form name="parent">' +
672
672
  '<div ng-form name="child">' +
673
673
  '<input ng:model="modelA" name="inputA" required>' +
@@ -691,7 +691,7 @@ describe("form", () => {
691
691
  });
692
692
 
693
693
  it("should deregister a child form whose name is an expression when its DOM is removed", () => {
694
- doc = jqLite(
694
+ doc = JQLite(
695
695
  '<form name="parent">' +
696
696
  '<div ng-form name="child.form">' +
697
697
  '<input ng:model="modelA" name="inputA" required>' +
@@ -715,7 +715,7 @@ describe("form", () => {
715
715
  });
716
716
 
717
717
  it("should deregister a input when it is removed from DOM", () => {
718
- doc = jqLite(
718
+ doc = JQLite(
719
719
  '<form name="parent">' +
720
720
  '<div ng-form name="child">' +
721
721
  '<input ng-if="inputPresent" ng-model="modelA" name="inputA" required maxlength="10">' +
@@ -781,7 +781,7 @@ describe("form", () => {
781
781
  });
782
782
 
783
783
  it("should deregister a input that is $pending when it is removed from DOM", () => {
784
- doc = jqLite(
784
+ doc = JQLite(
785
785
  '<form name="parent">' +
786
786
  '<div ng-form name="child">' +
787
787
  '<input ng-if="inputPresent" ng-model="modelA" name="inputA">' +
@@ -817,7 +817,7 @@ describe("form", () => {
817
817
  });
818
818
 
819
819
  it("should leave the parent form invalid when deregister a removed input", () => {
820
- doc = jqLite(
820
+ doc = JQLite(
821
821
  '<form name="parent">' +
822
822
  '<div ng-form name="child">' +
823
823
  '<input ng-if="inputPresent" ng-model="modelA" name="inputA" required>' +
@@ -973,7 +973,7 @@ describe("form", () => {
973
973
  });
974
974
 
975
975
  it("should chain nested forms in repeater", () => {
976
- doc = jqLite(
976
+ doc = JQLite(
977
977
  "<ng:form name=parent>" +
978
978
  '<ng:form ng:repeat="f in forms" name=child>' +
979
979
  "<input type=text ng:model=text name=text>" +
@@ -1404,8 +1404,8 @@ describe("form", () => {
1404
1404
 
1405
1405
  beforeEach(() => {
1406
1406
  let dummy = window.document.getElementById("dummy");
1407
- doc = jqLite('<form name="myForm"></form>');
1408
- jqLite(dummy).append(doc);
1407
+ doc = JQLite('<form name="myForm"></form>');
1408
+ JQLite(dummy).append(doc);
1409
1409
  let angular = new Angular();
1410
1410
  publishExternalAPI();
1411
1411
  myModule = window.angular.module("myModule", ["ngAnimate"]);
@@ -1,4 +1,4 @@
1
- import { dealoc, jqLite } from "../../shared/jqlite/jqlite";
1
+ import { dealoc, JQLite } from "../../shared/jqlite/jqlite";
2
2
  import { forEach, valueFn } from "../../shared/utils";
3
3
  import { publishExternalAPI } from "../../public";
4
4
  import { createInjector } from "../../injector";
@@ -138,7 +138,7 @@ describe("ngIf", () => {
138
138
  });
139
139
 
140
140
  it("should play nice with ngInclude on the same element", (done) => {
141
- element = jqLite(
141
+ element = JQLite(
142
142
  `<div><div ng-if="value=='first'" ng-include="'/mock/hello'"></div></div>`,
143
143
  );
144
144
 
@@ -1,5 +1,5 @@
1
1
  import { isDefined } from "../../shared/utils";
2
- import { jqLiteBuildFragment } from "../../shared/jqlite/jqlite";
2
+ import { JQLiteBuildFragment } from "../../shared/jqlite/jqlite";
3
3
 
4
4
  export const ngIncludeDirective = [
5
5
  "$templateRequest",
@@ -117,7 +117,7 @@ export const ngIncludeFillContentDirective = [
117
117
  // specially.
118
118
  $element.empty();
119
119
  $compile(
120
- jqLiteBuildFragment(ctrl.template, window.document).childNodes,
120
+ JQLiteBuildFragment(ctrl.template, window.document).childNodes,
121
121
  )(
122
122
  scope,
123
123
  (clone) => {