@lumino/widgets
Advanced tools
Comparing version 2.0.0-alpha.5 to 2.0.0-alpha.6
{ | ||
"name": "@lumino/widgets", | ||
"version": "2.0.0-alpha.5", | ||
"version": "2.0.0-alpha.6", | ||
"description": "Lumino Widgets", | ||
@@ -56,13 +56,13 @@ "homepage": "https://github.com/jupyterlab/lumino", | ||
"dependencies": { | ||
"@lumino/algorithm": "^2.0.0-alpha.5", | ||
"@lumino/commands": "^2.0.0-alpha.5", | ||
"@lumino/coreutils": "^2.0.0-alpha.5", | ||
"@lumino/disposable": "^2.0.0-alpha.5", | ||
"@lumino/domutils": "^2.0.0-alpha.5", | ||
"@lumino/dragdrop": "^2.0.0-alpha.5", | ||
"@lumino/keyboard": "^2.0.0-alpha.5", | ||
"@lumino/messaging": "^2.0.0-alpha.5", | ||
"@lumino/properties": "^2.0.0-alpha.5", | ||
"@lumino/signaling": "^2.0.0-alpha.5", | ||
"@lumino/virtualdom": "^2.0.0-alpha.5" | ||
"@lumino/algorithm": "^2.0.0-alpha.6", | ||
"@lumino/commands": "^2.0.0-alpha.6", | ||
"@lumino/coreutils": "^2.0.0-alpha.6", | ||
"@lumino/disposable": "^2.0.0-alpha.6", | ||
"@lumino/domutils": "^2.0.0-alpha.6", | ||
"@lumino/dragdrop": "^2.0.0-alpha.6", | ||
"@lumino/keyboard": "^2.0.0-alpha.6", | ||
"@lumino/messaging": "^2.0.0-alpha.6", | ||
"@lumino/properties": "^2.0.0-alpha.6", | ||
"@lumino/signaling": "^2.0.0-alpha.6", | ||
"@lumino/virtualdom": "^2.0.0-alpha.6" | ||
}, | ||
@@ -69,0 +69,0 @@ "devDependencies": { |
@@ -375,2 +375,6 @@ // Copyright (c) Jupyter Development Team. | ||
export class Renderer extends SplitPanel.Renderer implements IRenderer { | ||
constructor() { | ||
super(); | ||
this._uuid = ++Renderer._nInstance; | ||
} | ||
/** | ||
@@ -405,3 +409,2 @@ * A selector which matches any title node in the accordion. | ||
handle.className = this.titleClassName; | ||
handle.title = data.caption; | ||
for (const aData in data.dataset) { | ||
@@ -417,2 +420,3 @@ handle.dataset[aData] = data.dataset[aData]; | ||
label.textContent = data.label; | ||
label.title = data.caption || data.label; | ||
@@ -436,3 +440,3 @@ return handle; | ||
if (key === undefined) { | ||
key = `title-key-${this._titleID++}`; | ||
key = `title-key-${this._uuid}-${this._titleID++}`; | ||
this._titleKeys.set(data, key); | ||
@@ -443,2 +447,4 @@ } | ||
private static _nInstance = 0; | ||
private readonly _uuid: number; | ||
private _titleID = 0; | ||
@@ -445,0 +451,0 @@ private _titleKeys = new WeakMap<Title<Widget>, string>(); |
@@ -148,6 +148,4 @@ // Copyright (c) Jupyter Development Team. | ||
*/ | ||
*[Symbol.iterator](): IterableIterator<Widget> { | ||
if (this._root) { | ||
yield* this._root.iterAllWidgets(); | ||
} | ||
[Symbol.iterator](): IterableIterator<Widget> { | ||
return this._root ? this._root.iterAllWidgets() : Private.empty; | ||
} | ||
@@ -163,6 +161,4 @@ | ||
*/ | ||
*widgets(): IterableIterator<Widget> { | ||
if (this._root) { | ||
yield* this._root.iterUserWidgets(); | ||
} | ||
widgets(): IterableIterator<Widget> { | ||
return this._root ? this._root.iterUserWidgets() : Private.empty; | ||
} | ||
@@ -179,6 +175,4 @@ | ||
*/ | ||
*selectedWidgets(): IterableIterator<Widget> { | ||
if (this._root) { | ||
yield* this._root.iterSelectedWidgets(); | ||
} | ||
selectedWidgets(): IterableIterator<Widget> { | ||
return this._root ? this._root.iterSelectedWidgets() : Private.empty; | ||
} | ||
@@ -194,6 +188,4 @@ | ||
*/ | ||
*tabBars(): IterableIterator<TabBar<Widget>> { | ||
if (this._root) { | ||
yield* this._root.iterTabBars(); | ||
} | ||
tabBars(): IterableIterator<TabBar<Widget>> { | ||
return this._root ? this._root.iterTabBars() : Private.empty; | ||
} | ||
@@ -206,6 +198,4 @@ | ||
*/ | ||
*handles(): IterableIterator<HTMLDivElement> { | ||
if (this._root) { | ||
yield* this._root.iterHandles(); | ||
} | ||
handles(): IterableIterator<HTMLDivElement> { | ||
return this._root ? this._root.iterHandles() : Private.empty; | ||
} | ||
@@ -1443,2 +1433,7 @@ | ||
/** | ||
* An empty iterator. | ||
*/ | ||
export const empty = [][Symbol.iterator](); | ||
/** | ||
* A fraction used for sizing root panels; ~= `1 / golden_ratio`. | ||
@@ -1849,2 +1844,3 @@ */ | ||
*iterHandles(): IterableIterator<HTMLDivElement> { | ||
yield* this.handles; | ||
for (const child of this.children) { | ||
@@ -1851,0 +1847,0 @@ yield* child.iterHandles(); |
@@ -449,9 +449,9 @@ // Copyright (c) Jupyter Development Team. | ||
case 'pointerdown': | ||
this._evtPointerDown(event as MouseEvent); | ||
this._evtPointerDown(event as PointerEvent); | ||
break; | ||
case 'pointermove': | ||
this._evtPointerMove(event as MouseEvent); | ||
this._evtPointerMove(event as PointerEvent); | ||
break; | ||
case 'pointerup': | ||
this._evtPointerUp(event as MouseEvent); | ||
this._evtPointerUp(event as PointerEvent); | ||
break; | ||
@@ -689,3 +689,3 @@ case 'keydown': | ||
*/ | ||
private _evtPointerDown(event: MouseEvent): void { | ||
private _evtPointerDown(event: PointerEvent): void { | ||
// Do nothing if the left mouse button is not pressed. | ||
@@ -728,3 +728,3 @@ if (event.button !== 0) { | ||
*/ | ||
private _evtPointerMove(event: MouseEvent): void { | ||
private _evtPointerMove(event: PointerEvent): void { | ||
// Bail early if no drag is in progress. | ||
@@ -752,3 +752,3 @@ if (!this._pressData) { | ||
*/ | ||
private _evtPointerUp(event: MouseEvent): void { | ||
private _evtPointerUp(event: PointerEvent): void { | ||
// Do nothing if the left mouse button is not released. | ||
@@ -755,0 +755,0 @@ if (event.button !== 0) { |
@@ -1522,2 +1522,5 @@ // Copyright (c) Jupyter Development Team. | ||
export class Renderer implements IRenderer<any> { | ||
constructor() { | ||
this._uuid = ++Renderer._nInstance; | ||
} | ||
/** | ||
@@ -1611,3 +1614,3 @@ * A selector which matches the close icon node in a tab. | ||
if (key === undefined) { | ||
key = `tab-key-${this._tabID++}`; | ||
key = `tab-key-${this._uuid}-${this._tabID++}`; | ||
this._tabKeys.set(data.title, key); | ||
@@ -1685,2 +1688,4 @@ } | ||
private static _nInstance = 0; | ||
private readonly _uuid: number; | ||
private _tabID = 0; | ||
@@ -1687,0 +1692,0 @@ private _tabKeys = new WeakMap<Title<any>, string>(); |
@@ -156,2 +156,3 @@ import { Message } from '@lumino/messaging'; | ||
class Renderer extends SplitPanel.Renderer implements IRenderer { | ||
constructor(); | ||
/** | ||
@@ -189,2 +190,4 @@ * A selector which matches any title node in the accordion. | ||
createTitleKey(data: Title<Widget>): string; | ||
private static _nInstance; | ||
private readonly _uuid; | ||
private _titleID; | ||
@@ -191,0 +194,0 @@ private _titleKeys; |
@@ -594,2 +594,3 @@ import { Message } from '@lumino/messaging'; | ||
class Renderer implements IRenderer<any> { | ||
constructor(); | ||
/** | ||
@@ -684,2 +685,4 @@ * A selector which matches the close icon node in a tab. | ||
createIconClass(data: IRenderData<any>): string; | ||
private static _nInstance; | ||
private readonly _uuid; | ||
private _tabID; | ||
@@ -686,0 +689,0 @@ private _tabKeys; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4480555
56047