verstak 0.24.301 → 0.24.305
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.
- package/build/dist/source/archive/RxDomV1.js +2 -2
- package/build/dist/source/html/El.js +8 -3
- package/build/dist/source/html/Elements.d.ts +6 -6
- package/build/dist/source/html/Elements.js +11 -11
- package/build/dist/source/html/HtmlDriver.d.ts +1 -1
- package/build/dist/source/html/HtmlDriver.js +14 -10
- package/build/dist/source/html/HtmlElements.d.ts +174 -174
- package/build/dist/source/html/HtmlElements.js +175 -175
- package/build/dist/source/html/sensors/ButtonSensor.js +20 -15
- package/build/dist/source/html/sensors/FocusSensor.js +17 -12
- package/build/dist/source/html/sensors/HoverSensor.js +19 -14
- package/build/dist/source/html/sensors/HtmlDragSensor.js +24 -19
- package/build/dist/source/html/sensors/KeyboardSensor.js +17 -12
- package/build/dist/source/html/sensors/PointerSensor.js +15 -10
- package/build/dist/source/html/sensors/ScrollSensor.js +13 -8
- package/build/dist/source/html/sensors/WheelSensor.js +13 -8
- package/package.json +3 -3
|
@@ -345,8 +345,8 @@ export class RxDom {
|
|
|
345
345
|
}
|
|
346
346
|
}
|
|
347
347
|
}
|
|
348
|
-
static renderIncrementally(
|
|
349
|
-
return __awaiter(this,
|
|
348
|
+
static renderIncrementally(parent_1, p1_1, p2_1) {
|
|
349
|
+
return __awaiter(this, arguments, void 0, function* (parent, p1, p2, checkEveryN = 30, timeLimit = 12) {
|
|
350
350
|
if (Transaction.isFrameOver(checkEveryN, timeLimit))
|
|
351
351
|
yield Transaction.requestNextFrame();
|
|
352
352
|
if (!Transaction.isCanceled) {
|
|
@@ -65,8 +65,8 @@ export class ElImpl {
|
|
|
65
65
|
this._kind = ElKind.part;
|
|
66
66
|
this._place = undefined;
|
|
67
67
|
this._coords = UndefinedElCoords;
|
|
68
|
-
this._width =
|
|
69
|
-
this._height =
|
|
68
|
+
this._width = new Size();
|
|
69
|
+
this._height = new Size();
|
|
70
70
|
this._horizontal = undefined;
|
|
71
71
|
this._vertical = undefined;
|
|
72
72
|
this._contentHorizontal = undefined;
|
|
@@ -557,7 +557,12 @@ export class ElImpl {
|
|
|
557
557
|
const e = element.native;
|
|
558
558
|
if (e instanceof HTMLElement) {
|
|
559
559
|
element.sealed = value;
|
|
560
|
-
|
|
560
|
+
const t = Transaction.current;
|
|
561
|
+
Transaction.outside(() => {
|
|
562
|
+
t.whenFinished(true).then(() => {
|
|
563
|
+
e.sensors.resize.observeResizing(element, value !== undefined);
|
|
564
|
+
}, e => { });
|
|
565
|
+
});
|
|
561
566
|
}
|
|
562
567
|
}
|
|
563
568
|
static applyStylingPreset(element, secondary, styleName, enabled) {
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { RxNodeDecl, RxNodeDriver, RxNode, Script, MergedItem } from "reactronic";
|
|
2
2
|
import { CursorCommandDriver, El, ElPlace } from "./El.js";
|
|
3
3
|
import { HtmlDriver } from "./HtmlDriver.js";
|
|
4
|
-
export declare function Panel<M = unknown>(declaration?: RxNodeDecl<El<HTMLElement, M>>,
|
|
5
|
-
export declare function Table<M = unknown, R = void>(declaration?: RxNodeDecl<El<HTMLElement, M>>,
|
|
4
|
+
export declare function Panel<M = unknown>(declaration?: RxNodeDecl<El<HTMLElement, M>>, basis?: RxNodeDecl<El<HTMLElement, M>>): RxNode<El<HTMLElement, M>>;
|
|
5
|
+
export declare function Table<M = unknown, R = void>(declaration?: RxNodeDecl<El<HTMLElement, M>>, basis?: RxNodeDecl<El<HTMLElement, M>>): RxNode<El<HTMLElement, M>>;
|
|
6
6
|
export declare function row<T = void>(builder?: (element: void) => T, shiftCursorDown?: number): void;
|
|
7
|
-
export declare function Splitter<M = unknown, R = void>(declaration?: RxNodeDecl<El<HTMLElement, M>>,
|
|
7
|
+
export declare function Splitter<M = unknown, R = void>(declaration?: RxNodeDecl<El<HTMLElement, M>>, basis?: RxNodeDecl<El<HTMLElement, M>>): RxNode<El<HTMLElement, M>>;
|
|
8
8
|
export declare function rowBreak(shiftCursorDown?: number): void;
|
|
9
9
|
export declare function declareSplitter<T>(index: number, splitViewNode: RxNode<El<T>>): RxNode<El<HTMLElement>>;
|
|
10
10
|
export declare function cursor(areaParams: ElPlace): void;
|
|
11
11
|
export declare function Note(content: string, formatted?: boolean, declaration?: RxNodeDecl<El<HTMLElement, void>>): RxNode<El<HTMLElement, void>>;
|
|
12
|
-
export declare function Group<M = unknown, R = void>(declaration?: RxNodeDecl<El<HTMLElement, M>>,
|
|
12
|
+
export declare function Group<M = unknown, R = void>(declaration?: RxNodeDecl<El<HTMLElement, M>>, basis?: RxNodeDecl<El<HTMLElement, M>>): RxNode<El<HTMLElement, M>>;
|
|
13
13
|
export declare function Handling<M = unknown>(script: Script<El<void, M>>): RxNode<El<void, M>>;
|
|
14
|
-
export declare function SyntheticElement<M = unknown>(declaration?: RxNodeDecl<El<void, M>>,
|
|
14
|
+
export declare function SyntheticElement<M = unknown>(declaration?: RxNodeDecl<El<void, M>>, basis?: RxNodeDecl<El<void, M>>): RxNode<El<void, M>>;
|
|
15
15
|
export declare class PanelDriver<T extends HTMLElement> extends HtmlDriver<T> {
|
|
16
16
|
update(node: RxNode<El<T>>): void | Promise<void>;
|
|
17
|
-
child(ownerNode: RxNode<El<T, any>>, childDriver: RxNodeDriver<any>, childDeclaration?: RxNodeDecl<any> | undefined,
|
|
17
|
+
child(ownerNode: RxNode<El<T, any>>, childDriver: RxNodeDriver<any>, childDeclaration?: RxNodeDecl<any> | undefined, childBasis?: RxNodeDecl<any> | undefined): MergedItem<RxNode> | undefined;
|
|
18
18
|
}
|
|
19
19
|
export declare function isSplitViewPartition(childDriver: RxNodeDriver): boolean;
|
|
20
20
|
export declare class PartitionDriver<T extends HTMLElement> extends HtmlDriver<T> {
|
|
@@ -4,18 +4,18 @@ import { getPrioritiesForEmptySpaceDistribution, getPrioritiesForSizeChanging, r
|
|
|
4
4
|
import { Axis, BodyFontSize, Dimension, toPx } from "./Sizes.js";
|
|
5
5
|
import { HtmlDriver } from "./HtmlDriver.js";
|
|
6
6
|
import { clamp } from "./ElUtils.js";
|
|
7
|
-
export function Panel(declaration,
|
|
8
|
-
return RxNode.declare(Drivers.panel, declaration,
|
|
7
|
+
export function Panel(declaration, basis) {
|
|
8
|
+
return RxNode.declare(Drivers.panel, declaration, basis);
|
|
9
9
|
}
|
|
10
|
-
export function Table(declaration,
|
|
11
|
-
return RxNode.declare(Drivers.table, declaration,
|
|
10
|
+
export function Table(declaration, basis) {
|
|
11
|
+
return RxNode.declare(Drivers.table, declaration, basis);
|
|
12
12
|
}
|
|
13
13
|
export function row(builder, shiftCursorDown) {
|
|
14
14
|
rowBreak(shiftCursorDown);
|
|
15
15
|
builder === null || builder === void 0 ? void 0 : builder();
|
|
16
16
|
}
|
|
17
|
-
export function Splitter(declaration,
|
|
18
|
-
return RxNode.declare(Drivers.splitter, declaration,
|
|
17
|
+
export function Splitter(declaration, basis) {
|
|
18
|
+
return RxNode.declare(Drivers.splitter, declaration, basis);
|
|
19
19
|
}
|
|
20
20
|
export function rowBreak(shiftCursorDown) {
|
|
21
21
|
RxNode.declare(Drivers.partition);
|
|
@@ -90,14 +90,14 @@ export function Note(content, formatted, declaration) {
|
|
|
90
90
|
},
|
|
91
91
|
});
|
|
92
92
|
}
|
|
93
|
-
export function Group(declaration,
|
|
94
|
-
return RxNode.declare(Drivers.group, declaration,
|
|
93
|
+
export function Group(declaration, basis) {
|
|
94
|
+
return RxNode.declare(Drivers.group, declaration, basis);
|
|
95
95
|
}
|
|
96
96
|
export function Handling(script) {
|
|
97
97
|
return SyntheticElement({ mode: Mode.independentUpdate, script });
|
|
98
98
|
}
|
|
99
|
-
export function SyntheticElement(declaration,
|
|
100
|
-
return RxNode.declare(Drivers.synthetic, declaration,
|
|
99
|
+
export function SyntheticElement(declaration, basis) {
|
|
100
|
+
return RxNode.declare(Drivers.synthetic, declaration, basis);
|
|
101
101
|
}
|
|
102
102
|
export class PanelDriver extends HtmlDriver {
|
|
103
103
|
update(node) {
|
|
@@ -173,7 +173,7 @@ export class PanelDriver extends HtmlDriver {
|
|
|
173
173
|
}
|
|
174
174
|
return result;
|
|
175
175
|
}
|
|
176
|
-
child(ownerNode, childDriver, childDeclaration,
|
|
176
|
+
child(ownerNode, childDriver, childDeclaration, childBasis) {
|
|
177
177
|
var _a;
|
|
178
178
|
let result = undefined;
|
|
179
179
|
const el = ownerNode.element;
|
|
@@ -2,7 +2,7 @@ import { RxNode, Handler } from "reactronic";
|
|
|
2
2
|
import { El, ElDriver } from "./El.js";
|
|
3
3
|
export declare class WebDriver<T extends Element, M = unknown> extends ElDriver<T, M> {
|
|
4
4
|
setNativeElement(node: RxNode<El<T, M>>): void;
|
|
5
|
-
create(node: RxNode<El<T, M>>): void
|
|
5
|
+
create(node: RxNode<El<T, M>>): void | Promise<void>;
|
|
6
6
|
destroy(node: RxNode<El<T, M>>, isLeader: boolean): boolean;
|
|
7
7
|
mount(node: RxNode<El<T, M>>): void;
|
|
8
8
|
update(node: RxNode<El<T, M>>): void | Promise<void>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RxSystem, RxNode } from "reactronic";
|
|
1
|
+
import { RxSystem, RxNode, proceedSyncOrAsync } from "reactronic";
|
|
2
2
|
import { Constants, ElDriver, ElImpl } from "./El.js";
|
|
3
3
|
export class WebDriver extends ElDriver {
|
|
4
4
|
setNativeElement(node) {
|
|
@@ -8,9 +8,10 @@ export class WebDriver extends ElDriver {
|
|
|
8
8
|
const e = node.element.native;
|
|
9
9
|
if (RxSystem.isLogging && e !== undefined && !node.driver.isPartition)
|
|
10
10
|
e.setAttribute(Constants.keyAttrName, node.key);
|
|
11
|
-
super.create(node);
|
|
11
|
+
const result = super.create(node);
|
|
12
12
|
if (e == undefined && RxSystem.isLogging && !node.driver.isPartition)
|
|
13
13
|
node.element.native.setAttribute(Constants.keyAttrName, node.key);
|
|
14
|
+
return result;
|
|
14
15
|
}
|
|
15
16
|
destroy(node, isLeader) {
|
|
16
17
|
var _a;
|
|
@@ -58,14 +59,17 @@ export class WebDriver extends ElDriver {
|
|
|
58
59
|
const element = node.element;
|
|
59
60
|
if (element instanceof ElImpl)
|
|
60
61
|
element.prepareForUpdate();
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
62
|
+
let result = super.update(node);
|
|
63
|
+
result = proceedSyncOrAsync(result, v => {
|
|
64
|
+
if (element.place === undefined) {
|
|
65
|
+
const oel = node.owner.element;
|
|
66
|
+
if (oel instanceof ElImpl && oel.isTable)
|
|
67
|
+
element.place = undefined;
|
|
68
|
+
}
|
|
69
|
+
if (gBlinkingEffectMarker)
|
|
70
|
+
blink(element.native, RxNode.currentUpdatePriority, node.stamp);
|
|
71
|
+
}, e => {
|
|
72
|
+
});
|
|
69
73
|
return result;
|
|
70
74
|
}
|
|
71
75
|
static findBrotherlyHost(node) {
|