@angular-wave/angular.ts 0.0.53 → 0.0.54

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.
@@ -9,7 +9,6 @@ describe("binding", () => {
9
9
  $rootScope,
10
10
  $compile,
11
11
  $exceptionHandler,
12
- $document,
13
12
  errors = [];
14
13
 
15
14
  function childNode(element, index) {
@@ -27,7 +26,6 @@ describe("binding", () => {
27
26
  $rootScope = $injector.get("$rootScope");
28
27
  $compile = $injector.get("$compile");
29
28
  $exceptionHandler = $injector.get("$exceptionHandler");
30
- $document = $injector.get("$document");
31
29
  this.compileToHtml = function (content) {
32
30
  let html;
33
31
  content = JQLite(content);
@@ -55,8 +55,7 @@ describe("$compile", () => {
55
55
  $compile,
56
56
  $templateCache,
57
57
  log,
58
- $sce,
59
- $document;
58
+ $sce;
60
59
 
61
60
  beforeEach(() => {
62
61
  log = [];
@@ -68,7 +67,6 @@ describe("$compile", () => {
68
67
  $rootScope = injector.get("$rootScope");
69
68
  $compile = injector.get("$compile");
70
69
  $templateCache = injector.get("$templateCache");
71
- $document = injector.get("$document");
72
70
  $sce = injector.get("$sce");
73
71
  });
74
72
 
@@ -187,7 +185,6 @@ describe("$compile", () => {
187
185
  $rootScope = injector.get("$rootScope");
188
186
  $compile = injector.get("$compile");
189
187
  $templateCache = injector.get("$templateCache");
190
- $document = injector.get("$document");
191
188
  $sce = injector.get("$sce");
192
189
  }
193
190
 
@@ -4971,7 +4968,8 @@ describe("$compile", () => {
4971
4968
  describe("compile phase", () => {
4972
4969
  // NO ELEMENT ATTACHMENTS
4973
4970
  // it("should attach scope to the document node when it is compiled explicitly", () => {
4974
- // $compile($document)($rootScope);
4971
+ // let $document = JQLite(document);
4972
+ // $document = $compile($document)($rootScope);
4975
4973
  // expect($document.scope()).toBe($rootScope);
4976
4974
  // });
4977
4975
 
@@ -2361,7 +2361,7 @@ describe("$location", () => {
2361
2361
  // $compile,
2362
2362
  // $browser,
2363
2363
  // $rootElement,
2364
- // $document,
2364
+ //
2365
2365
  // $location,
2366
2366
  // ) => {
2367
2367
  // // we need to do this otherwise we can't simulate events
@@ -2402,7 +2402,7 @@ describe("$location", () => {
2402
2402
  // $compile,
2403
2403
  // $browser,
2404
2404
  // $rootElement,
2405
- // $document,
2405
+ //
2406
2406
  // $location,
2407
2407
  // ) => {
2408
2408
  // // we need to do this otherwise we can't simulate events
@@ -2477,7 +2477,7 @@ describe("$location", () => {
2477
2477
  // $compile,
2478
2478
  // $browser,
2479
2479
  // $rootElement,
2480
- // $document,
2480
+ //
2481
2481
  // $location,
2482
2482
  // ) => {
2483
2483
  // // make IE happy
@@ -2499,7 +2499,7 @@ describe("$location", () => {
2499
2499
 
2500
2500
  // // regression https://github.com/angular/angular.js/issues/1058
2501
2501
  // it("should not throw if element was removed", inject((
2502
- // $document,
2502
+ //
2503
2503
  // $rootElement,
2504
2504
  // $location,
2505
2505
  // ) => {
@@ -2532,7 +2532,7 @@ describe("$location", () => {
2532
2532
  // $compile,
2533
2533
  // $browser,
2534
2534
  // $rootElement,
2535
- // $document,
2535
+ //
2536
2536
  // $location,
2537
2537
  // ) => {
2538
2538
  // // we need to do this otherwise we can't simulate events
@@ -3440,7 +3440,7 @@ describe("$location", () => {
3440
3440
  // return win;
3441
3441
  // };
3442
3442
  // $browserProvider.$get = function (
3443
- // $document,
3443
+ //
3444
3444
  // $window,
3445
3445
  // $log,
3446
3446
  // $sniffer,
@@ -3449,7 +3449,7 @@ describe("$location", () => {
3449
3449
  // /* global Browser: false */
3450
3450
  // browser = new Browser(
3451
3451
  // $window,
3452
- // $document,
3452
+ //
3453
3453
  // $log,
3454
3454
  // $sniffer,
3455
3455
  // $$taskTrackerFactory,
@@ -5,8 +5,6 @@ import {
5
5
  urlIsAllowedOriginFactory,
6
6
  } from "./url-utils";
7
7
 
8
- let $document = window.document;
9
-
10
8
  describe("urlUtils", () => {
11
9
  describe("urlResolve", () => {
12
10
  it("should returned already parsed URLs unchanged", () => {
@@ -67,7 +65,7 @@ describe("urlUtils", () => {
67
65
 
68
66
  expectIsSameOrigin("path", true);
69
67
 
70
- const origin = urlResolve($document.location.href);
68
+ const origin = urlResolve(window.document.location.href);
71
69
  expectIsSameOrigin(`//${origin.host}/path`, true);
72
70
 
73
71
  // Different domain.
@@ -180,9 +180,8 @@ const NG_OPTIONS_REGEXP =
180
180
 
181
181
  export const ngOptionsDirective = [
182
182
  "$compile",
183
- "$document",
184
183
  "$parse",
185
- function ($compile, $document, $parse) {
184
+ function ($compile, $parse) {
186
185
  function parseOptionsExpression(optionsExp, selectElement, scope) {
187
186
  const match = optionsExp.match(NG_OPTIONS_REGEXP);
188
187
  if (!match) {
@@ -404,7 +403,7 @@ export const ngOptionsDirective = [
404
403
  // This stores the newly created options before they are appended to the select.
405
404
  // Since the contents are removed from the fragment when it is appended,
406
405
  // we only need to create it once.
407
- const listFragment = $document[0].createDocumentFragment();
406
+ const listFragment = document.createDocumentFragment();
408
407
 
409
408
  // Overwrite the implementation. ngOptions doesn't use hashes
410
409
  selectCtrl.generateUnknownOptionValue = () => "?";
@@ -1552,7 +1552,7 @@ describe("ngRepeat", () => {
1552
1552
  // $compile,
1553
1553
  // scope,
1554
1554
  // $animate,
1555
- // $document,
1555
+ //
1556
1556
  // $sniffer,
1557
1557
  // $timeout,
1558
1558
  // ) => {
@@ -223,9 +223,8 @@ export function initMessageModule() {
223
223
 
224
224
  .directive("ngMessagesInclude", [
225
225
  "$templateRequest",
226
- "$document",
227
226
  "$compile",
228
- function ($templateRequest, $document, $compile) {
227
+ function ($templateRequest, $compile) {
229
228
  return {
230
229
  restrict: "AE",
231
230
  require: "^^ngMessages", // we only require this for validation sake
package/src/public.js CHANGED
@@ -55,7 +55,6 @@ import { ngEventDirectives } from "./directive/events/events";
55
55
  import { AnchorScrollProvider } from "./services/anchor-scroll";
56
56
  import {
57
57
  AnimateProvider,
58
- CoreAnimateJsProvider,
59
58
  CoreAnimateQueueProvider,
60
59
  } from "./core/animate/animate";
61
60
  import { BrowserProvider } from "./services/browser";
@@ -70,10 +69,6 @@ import {
70
69
  TemplateCacheProvider,
71
70
  } from "./services/cache-factory";
72
71
  import { $ControllerProvider } from "./core/controller/controller";
73
- import {
74
- $DocumentProvider,
75
- $$IsDocumentHiddenProvider,
76
- } from "./services/document";
77
72
  import { $ExceptionHandlerProvider } from "./core/exception-handler";
78
73
  import { $FilterProvider } from "./core/filter/filter";
79
74
  import { $IntervalProvider } from "./core/interval/interval";
@@ -177,14 +172,12 @@ export function publishExternalAPI() {
177
172
  $anchorScroll: AnchorScrollProvider,
178
173
  $animate: AnimateProvider,
179
174
  $animateCss: CoreAnimateCssProvider,
180
- $$animateJs: CoreAnimateJsProvider,
181
175
  $$animateQueue: CoreAnimateQueueProvider,
182
176
  $$AnimateRunner: AnimateRunnerFactoryProvider,
183
177
  $$animateAsyncRun: AnimateAsyncRunFactoryProvider,
184
178
  $browser: BrowserProvider,
185
179
  $cacheFactory: CacheFactoryProvider,
186
180
  $controller: $ControllerProvider,
187
- $document: $DocumentProvider,
188
181
  $exceptionHandler: $ExceptionHandlerProvider,
189
182
  $filter: $FilterProvider,
190
183
  $interpolate: $InterpolateProvider,
@@ -1,16 +1,14 @@
1
1
  import { isUndefined } from "../shared/utils";
2
2
 
3
3
  /**
4
- * @name $$cookieReader
5
- * @requires $document
6
4
  *
7
5
  * @description
8
6
  * This is a private service for reading cookies used by $http and ngCookies
9
7
  *
10
8
  * @return {Object} a key/value map of the current cookies
11
9
  */
12
- export function $$CookieReader($document) {
13
- const rawDocument = $document[0] || {};
10
+ export function $$CookieReader() {
11
+ const rawDocument = window.document;
14
12
  let lastCookies = {};
15
13
  let lastCookieString = "";
16
14
 
@@ -64,8 +62,6 @@ export function $$CookieReader($document) {
64
62
  };
65
63
  }
66
64
 
67
- $$CookieReader.$inject = ["$document"];
68
-
69
65
  export function CookieReaderProvider() {
70
66
  this.$get = $$CookieReader;
71
67
  }
@@ -39,7 +39,6 @@ export function $xhrFactoryProvider() {
39
39
  /**
40
40
  * @ngdoc service
41
41
  * @name $httpBackend
42
- * @requires $document
43
42
  * @requires $xhrFactory
44
43
  *
45
44
  *
@@ -4,7 +4,7 @@ export class $$AnimateCssDriverProvider {
4
4
  /**
5
5
  * @returns {Function}
6
6
  */
7
- $get: (string | (($animateCss: any, $$AnimateRunner: any, $rootElement: any, $document: any) => (animationDetails: any) => any))[];
7
+ $get: (string | (($animateCss: any, $$AnimateRunner: any, $rootElement: any) => (animationDetails: any) => any))[];
8
8
  }
9
9
  export namespace $$AnimateCssDriverProvider {
10
10
  let $inject: string[];
@@ -6,7 +6,7 @@ export class $$AnimateQueueProvider {
6
6
  cancel: any[];
7
7
  join: any[];
8
8
  };
9
- $get: (string | (($rootScope: any, $rootElement: any, $document: any, $$animation: any, $$AnimateRunner: any, $templateRequest: any) => {
9
+ $get: (string | (($rootScope: any, $rootElement: any, $$animation: any, $$AnimateRunner: any, $templateRequest: any) => {
10
10
  on(event: any, container: any, callback: any): void;
11
11
  off(event: any, container: any, callback: any, ...args: any[]): void;
12
12
  pin(element: any, parentElement: any): void;