Skip to content

Commit afe832f

Browse files
committed
Type and doc updates
1 parent 197fe08 commit afe832f

File tree

9 files changed

+132
-160
lines changed

9 files changed

+132
-160
lines changed

@types/core/scope/scope.d.ts

Lines changed: 12 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -45,22 +45,14 @@ export class Scope {
4545
context: Scope;
4646
/** @type {Map<string, Array<import('./interface.ts').Listener>>} Watch listeners */
4747
watchers: Map<string, Array<import("./interface.ts").Listener>>;
48-
/** @type {Map<String, Function[]>} Event listeners */
49-
$$listeners: Map<string, Function[]>;
50-
/** @type {Map<string, Array<import('./interface.ts').Listener>>} Watch listeners from other proxies */
51-
foreignListeners: Map<string, Array<import("./interface.ts").Listener>>;
52-
/** @type {Set<Proxy<ng.Scope>>} */
53-
foreignProxies: Set<ProxyConstructor>;
54-
/** @type {WeakMap<Object, Array<string>>} */
55-
objectListeners: WeakMap<any, Array<string>>;
56-
/** @type {Map<Function, {oldValue: any, fn: Function}>} */
57-
functionListeners: Map<
58-
Function,
59-
{
60-
oldValue: any;
61-
fn: Function;
62-
}
63-
>;
48+
/** @private @type {Map<String, Function[]>} Event listeners */
49+
private _listeners;
50+
/** @private @type {Map<string, Array<import('./interface.ts').Listener>>} Watch listeners from other proxies */
51+
private _foreignListeners;
52+
/** @private @type {Set<Proxy<ng.Scope>>} */
53+
private _foreignProxies;
54+
/** @private @type {WeakMap<Object, Array<string>>} */
55+
private _objectListeners;
6456
/** @type {Proxy<Scope>} Current proxy being operated on */
6557
$proxy: ProxyConstructor;
6658
/** @type {Scope} The actual proxy */
@@ -82,10 +74,10 @@ export class Scope {
8274
*/
8375
$root: Scope;
8476
$parent: Scope;
85-
filters: any[];
86-
/** @type {boolean} */
87-
$$destroyed: boolean;
88-
scheduled: any[];
77+
/** @ignore @type {boolean} */
78+
_destroyed: boolean;
79+
/** @private @type {import("./interface.ts").Listener[]} A list of scheduled Event listeners */
80+
private _scheduled;
8981
$scopename: any;
9082
/** @private */
9183
private propertyMap;

docs/static/typedoc/assets/search.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/static/typedoc/classes/Scope.html

Lines changed: 3 additions & 11 deletions
Large diffs are not rendered by default.

src/core/compile/compile.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2537,7 +2537,7 @@ export class CompileProvider {
25372537

25382538
let linkNode = $compileNode._getAny();
25392539

2540-
if (scope.$$destroyed) {
2540+
if (scope._destroyed) {
25412541
continue;
25422542
}
25432543

@@ -2604,7 +2604,7 @@ export class CompileProvider {
26042604
) {
26052605
let childBoundTranscludeFn = boundTranscludeFn;
26062606

2607-
if (scope.$$destroyed) {
2607+
if (scope._destroyed) {
26082608
return;
26092609
}
26102610

src/core/compile/compile.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12993,7 +12993,7 @@ describe("$compile", () => {
1299312993
$rootScope.$apply("t = false");
1299412994
await wait();
1299512995
for (let i = 0; i < childScopes.length; ++i) {
12996-
expect(childScopes[i].$$destroyed).toBe(true);
12996+
expect(childScopes[i]._destroyed).toBe(true);
1299712997
}
1299812998
});
1299912999
});

0 commit comments

Comments
 (0)