verstak 0.96.26018 → 0.96.26020
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.
|
@@ -16,9 +16,8 @@ export declare function declareSplitter<T>(index: number, splitViewNode: Reactiv
|
|
|
16
16
|
export declare function cursor(place: ElPlace): void;
|
|
17
17
|
export declare function Group<M = unknown>(body?: Script<El<HTMLElement, M>>, bodyTask?: ScriptAsync<El<HTMLElement, M>>, key?: string, mode?: Mode, unmounted?: boolean, preparation?: Script<El<HTMLElement, M>>, preparationTask?: ScriptAsync<El<HTMLElement, M>>, mounting?: Script<El<HTMLElement>>, finalization?: Script<El<HTMLElement, M>>, signalArgs?: unknown, basis?: ReactiveTreeNodeDecl<El<HTMLElement, M>>): ReactiveTreeNode<El<HTMLElement, M>>;
|
|
18
18
|
export declare function Group<M = unknown>(declaration?: ReactiveTreeNodeDecl<El<HTMLElement, M>>): ReactiveTreeNode<El<HTMLElement, M>>;
|
|
19
|
-
export declare function Fragment<M = unknown>(body
|
|
20
|
-
export declare function
|
|
21
|
-
export declare function PseudoElement<M = unknown>(declaration?: ReactiveTreeNodeDecl<El<void, M>>): ReactiveTreeNode<El<void, M>>;
|
|
19
|
+
export declare function Fragment<M = unknown>(body?: Script<El<void, M>>, bodyTask?: ScriptAsync<El<void, M>>, key?: string, mode?: Mode, unmounted?: boolean, preparation?: Script<El<void, M>>, preparationTask?: ScriptAsync<El<void, M>>, mounting?: Script<El<void>>, finalization?: Script<El<void, M>>, signalArgs?: unknown, basis?: ReactiveTreeNodeDecl<El<void, M>>): ReactiveTreeNode<El<void, M>>;
|
|
20
|
+
export declare function Fragment<M = unknown>(declaration?: ReactiveTreeNodeDecl<El<void, M>>): ReactiveTreeNode<El<void, M>>;
|
|
22
21
|
export declare class BlockDriver<T extends HTMLElement> extends HtmlDriver<T> {
|
|
23
22
|
rebuildBody(node: ReactiveTreeNode<El<T>>): void | Promise<void>;
|
|
24
23
|
declareChild(ownerNode: ReactiveTreeNode<El<T, any>>, childDriver: ReactiveTreeNodeDriver<any>, childDeclaration?: ReactiveTreeNodeDecl<any> | undefined, childBasis?: ReactiveTreeNodeDecl<any> | undefined): LinkedItem<ReactiveTreeNode> | undefined;
|
|
@@ -36,5 +35,5 @@ export declare const Drivers: {
|
|
|
36
35
|
wrapper: HtmlDriver<HTMLElement, any>;
|
|
37
36
|
splitter: HtmlDriver<HTMLElement, any>;
|
|
38
37
|
cursor: CursorCommandDriver;
|
|
39
|
-
|
|
38
|
+
fragment: ReactiveTreeNodeDriver<El<void, any>>;
|
|
40
39
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ReactiveTreeNode, declare, runNonReactive } from "reactronic";
|
|
1
|
+
import { ReactiveTreeNode, Mode, declare, runNonReactive } from "reactronic";
|
|
2
2
|
import { ElKind, Direction } from "./El.js";
|
|
3
3
|
import { clamp } from "./ElUtils.js";
|
|
4
4
|
import { Constants, CursorCommandDriver, ElDriver, ElLayoutInfo, InitialElLayoutInfo } from "./ElDriver.js";
|
|
@@ -88,11 +88,9 @@ export function cursor(place) {
|
|
|
88
88
|
export function Group(bodyOrDeclaration, bodyTask, key, mode, unmounted, preparation, preparationTask, mounting, finalization, signalArgs, basis) {
|
|
89
89
|
return declare(Drivers.group, bodyOrDeclaration, bodyTask, key, mode, unmounted, preparation, preparationTask, mounting, finalization, signalArgs, basis);
|
|
90
90
|
}
|
|
91
|
-
export function Fragment(
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
export function PseudoElement(bodyOrDeclaration, bodyTask, key, mode, unmounted, preparation, preparationTask, mounting, finalization, signalArgs, basis) {
|
|
95
|
-
return declare(Drivers.pseudo, bodyOrDeclaration, bodyTask, key, mode, unmounted, preparation, preparationTask, mounting, finalization, signalArgs, basis);
|
|
91
|
+
export function Fragment(bodyOrDeclaration, bodyTask, key, mode, unmounted, preparation, preparationTask, mounting, finalization, signalArgs, basis) {
|
|
92
|
+
mode = mode !== undefined ? mode | Mode.fragment : Mode.fragment;
|
|
93
|
+
return declare(Drivers.fragment, bodyOrDeclaration, bodyTask, key, mode, unmounted, preparation, preparationTask, mounting, finalization, signalArgs, basis);
|
|
96
94
|
}
|
|
97
95
|
export class BlockDriver extends HtmlDriver {
|
|
98
96
|
rebuildBody(node) {
|
|
@@ -116,7 +114,7 @@ export class BlockDriver extends HtmlDriver {
|
|
|
116
114
|
layoutInfo.contentSizeYpx = contentBoxPx.blockSize;
|
|
117
115
|
}
|
|
118
116
|
});
|
|
119
|
-
const relayoutEl =
|
|
117
|
+
const relayoutEl = Fragment({
|
|
120
118
|
body() {
|
|
121
119
|
const native = el.native;
|
|
122
120
|
const isHorizontal = el.splitView === Direction.horizontal;
|
|
@@ -205,7 +203,7 @@ export class BlockDriver extends HtmlDriver {
|
|
|
205
203
|
}
|
|
206
204
|
}
|
|
207
205
|
export function isSplitViewPartition(childDriver) {
|
|
208
|
-
return !childDriver.isPartition && childDriver !== Drivers.splitter && childDriver !== Drivers.
|
|
206
|
+
return !childDriver.isPartition && childDriver !== Drivers.splitter && childDriver !== Drivers.fragment;
|
|
209
207
|
}
|
|
210
208
|
function overrideMethod(declaration, method, func) {
|
|
211
209
|
const baseScript = declaration[method];
|
|
@@ -263,5 +261,5 @@ export const Drivers = {
|
|
|
263
261
|
wrapper: new HtmlDriver(Constants.wrapper, false, el => el.kind = ElKind.native),
|
|
264
262
|
splitter: new HtmlDriver(Constants.splitter, false, el => el.kind = ElKind.splitter),
|
|
265
263
|
cursor: new CursorCommandDriver(),
|
|
266
|
-
|
|
264
|
+
fragment: new ElDriver("fragment", false, el => el.kind = ElKind.group),
|
|
267
265
|
};
|
|
@@ -8,10 +8,10 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
import { ToggleRef, runNonReactive } from "reactronic";
|
|
11
|
-
import {
|
|
11
|
+
import { Fragment } from "../Elements.js";
|
|
12
12
|
export function OnClick(target, action, key) {
|
|
13
13
|
if (action !== undefined) {
|
|
14
|
-
|
|
14
|
+
Fragment({
|
|
15
15
|
key,
|
|
16
16
|
signalArgs: { target },
|
|
17
17
|
body() {
|
|
@@ -30,7 +30,7 @@ export function OnClick(target, action, key) {
|
|
|
30
30
|
}
|
|
31
31
|
export function OnClickAsync(target, action, key) {
|
|
32
32
|
if (action !== undefined) {
|
|
33
|
-
|
|
33
|
+
Fragment({
|
|
34
34
|
key,
|
|
35
35
|
signalArgs: { target },
|
|
36
36
|
bodyTask() {
|
|
@@ -51,7 +51,7 @@ export function OnClickAsync(target, action, key) {
|
|
|
51
51
|
}
|
|
52
52
|
export function OnResize(target, action, key) {
|
|
53
53
|
if (action) {
|
|
54
|
-
|
|
54
|
+
Fragment({
|
|
55
55
|
key,
|
|
56
56
|
signalArgs: { target },
|
|
57
57
|
body() {
|
|
@@ -64,7 +64,7 @@ export function OnResize(target, action, key) {
|
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
66
|
export function OnFocus(target, model, switchEditMode = undefined, key) {
|
|
67
|
-
|
|
67
|
+
Fragment({
|
|
68
68
|
key,
|
|
69
69
|
signalArgs: { target, model },
|
|
70
70
|
preparation() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "verstak",
|
|
3
|
-
"version": "0.96.
|
|
3
|
+
"version": "0.96.26020",
|
|
4
4
|
"description": "Verstak - Front-End Library",
|
|
5
5
|
"publisher": "Nezaboodka Software",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"markdown-it": "^14.1.0",
|
|
43
43
|
"markdown-it-prism": "^2.3.0",
|
|
44
44
|
"prismjs": "^1.30.0",
|
|
45
|
-
"reactronic": "^0.96.
|
|
45
|
+
"reactronic": "^0.96.26020"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"@types/markdown-it": "14.1.2",
|