x-runtime-lib 0.9.51 → 0.9.52
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/dist/index.d.ts
CHANGED
|
@@ -678,7 +678,7 @@ export declare interface Transients {
|
|
|
678
678
|
|
|
679
679
|
export declare type TriggerKind = 'propertyTrigger' | 'stateTrigger';
|
|
680
680
|
|
|
681
|
-
export declare const typesKeys: readonly ["borderRadiusV1", "borderWidthV1", "colorV1", "elevationV1", "leftRightV1", "marginV1", "paddingV1", "progressChunkWayV1", "sizeV1", "tableColumnAlignV1", "topBottomV1"];
|
|
681
|
+
export declare const typesKeys: readonly ["borderRadiusV1", "borderWidthV1", "colorV1", "elevationV1", "heightV1", "leftRightV1", "marginV1", "paddingV1", "progressChunkWayV1", "sizeV1", "tableColumnAlignV1", "topBottomV1", "widthV1"];
|
|
682
682
|
|
|
683
683
|
export declare function unwrapEventId(id: string): {
|
|
684
684
|
kind: EventKind;
|
package/dist/index.js
CHANGED
|
@@ -51,13 +51,15 @@ var rt = [
|
|
|
51
51
|
"borderWidthV1",
|
|
52
52
|
"colorV1",
|
|
53
53
|
"elevationV1",
|
|
54
|
+
"heightV1",
|
|
54
55
|
"leftRightV1",
|
|
55
56
|
"marginV1",
|
|
56
57
|
"paddingV1",
|
|
57
58
|
"progressChunkWayV1",
|
|
58
59
|
"sizeV1",
|
|
59
60
|
"tableColumnAlignV1",
|
|
60
|
-
"topBottomV1"
|
|
61
|
+
"topBottomV1",
|
|
62
|
+
"widthV1"
|
|
61
63
|
], at = {};
|
|
62
64
|
function ot(e, t) {
|
|
63
65
|
at[e] = t;
|
|
@@ -1715,42 +1717,42 @@ var bn = {
|
|
|
1715
1717
|
key: "width",
|
|
1716
1718
|
name: "x-runtime-lib.width",
|
|
1717
1719
|
ui: "multiTypes",
|
|
1718
|
-
types: "
|
|
1720
|
+
types: "widthV1",
|
|
1719
1721
|
default: null
|
|
1720
1722
|
},
|
|
1721
1723
|
{
|
|
1722
1724
|
key: "minWidth",
|
|
1723
1725
|
name: "x-runtime-lib.minWidth",
|
|
1724
1726
|
ui: "multiTypes",
|
|
1725
|
-
types: "
|
|
1727
|
+
types: "widthV1",
|
|
1726
1728
|
default: null
|
|
1727
1729
|
},
|
|
1728
1730
|
{
|
|
1729
1731
|
key: "maxWidth",
|
|
1730
1732
|
name: "x-runtime-lib.maxWidth",
|
|
1731
1733
|
ui: "multiTypes",
|
|
1732
|
-
types: "
|
|
1734
|
+
types: "widthV1",
|
|
1733
1735
|
default: null
|
|
1734
1736
|
},
|
|
1735
1737
|
{
|
|
1736
1738
|
key: "height",
|
|
1737
1739
|
name: "x-runtime-lib.height",
|
|
1738
1740
|
ui: "multiTypes",
|
|
1739
|
-
types: "
|
|
1741
|
+
types: "heightV1",
|
|
1740
1742
|
default: null
|
|
1741
1743
|
},
|
|
1742
1744
|
{
|
|
1743
1745
|
key: "minHeight",
|
|
1744
1746
|
name: "x-runtime-lib.minHeight",
|
|
1745
1747
|
ui: "multiTypes",
|
|
1746
|
-
types: "
|
|
1748
|
+
types: "heightV1",
|
|
1747
1749
|
default: null
|
|
1748
1750
|
},
|
|
1749
1751
|
{
|
|
1750
1752
|
key: "maxHeight",
|
|
1751
1753
|
name: "x-runtime-lib.maxHeight",
|
|
1752
1754
|
ui: "multiTypes",
|
|
1753
|
-
types: "
|
|
1755
|
+
types: "heightV1",
|
|
1754
1756
|
default: null
|
|
1755
1757
|
}
|
|
1756
1758
|
]
|
|
@@ -1871,21 +1873,21 @@ var bn = {
|
|
|
1871
1873
|
key: "width",
|
|
1872
1874
|
name: "x-runtime-lib.width",
|
|
1873
1875
|
ui: "multiTypes",
|
|
1874
|
-
types: "
|
|
1876
|
+
types: "widthV1",
|
|
1875
1877
|
default: null
|
|
1876
1878
|
},
|
|
1877
1879
|
{
|
|
1878
1880
|
key: "minWidth",
|
|
1879
1881
|
name: "x-runtime-lib.minWidth",
|
|
1880
1882
|
ui: "multiTypes",
|
|
1881
|
-
types: "
|
|
1883
|
+
types: "widthV1",
|
|
1882
1884
|
default: null
|
|
1883
1885
|
},
|
|
1884
1886
|
{
|
|
1885
1887
|
key: "maxWidth",
|
|
1886
1888
|
name: "x-runtime-lib.maxWidth",
|
|
1887
1889
|
ui: "multiTypes",
|
|
1888
|
-
types: "
|
|
1890
|
+
types: "widthV1",
|
|
1889
1891
|
default: null
|
|
1890
1892
|
}
|
|
1891
1893
|
]
|
|
@@ -1957,7 +1959,7 @@ var bn = {
|
|
|
1957
1959
|
]
|
|
1958
1960
|
};
|
|
1959
1961
|
//#endregion
|
|
1960
|
-
//#region src/element/_common/types/
|
|
1962
|
+
//#region src/element/_common/types/width/v1/index.ts
|
|
1961
1963
|
ot("borderRadiusV1", [
|
|
1962
1964
|
{
|
|
1963
1965
|
value: "notSet",
|
|
@@ -2118,7 +2120,51 @@ ot("borderRadiusV1", [
|
|
|
2118
2120
|
max: 5,
|
|
2119
2121
|
step: 1,
|
|
2120
2122
|
default: 0
|
|
2121
|
-
}]), ot("
|
|
2123
|
+
}]), ot("heightV1", [
|
|
2124
|
+
{
|
|
2125
|
+
value: "notSet",
|
|
2126
|
+
title: "x-runtime-lib.notSet",
|
|
2127
|
+
validator: xt,
|
|
2128
|
+
trait: "null",
|
|
2129
|
+
default: null
|
|
2130
|
+
},
|
|
2131
|
+
{
|
|
2132
|
+
value: "pixel",
|
|
2133
|
+
title: "x-runtime-lib.pixel",
|
|
2134
|
+
validator: (e) => Ct(e, "px"),
|
|
2135
|
+
trait: "numberUnit",
|
|
2136
|
+
unit: "px",
|
|
2137
|
+
precision: 0,
|
|
2138
|
+
min: 0,
|
|
2139
|
+
max: Infinity,
|
|
2140
|
+
step: 1,
|
|
2141
|
+
default: "0px"
|
|
2142
|
+
},
|
|
2143
|
+
{
|
|
2144
|
+
value: "percent",
|
|
2145
|
+
title: "x-runtime-lib.percent",
|
|
2146
|
+
validator: (e) => Ct(e, "%"),
|
|
2147
|
+
trait: "numberUnit",
|
|
2148
|
+
unit: "%",
|
|
2149
|
+
precision: 6,
|
|
2150
|
+
min: 0,
|
|
2151
|
+
max: Infinity,
|
|
2152
|
+
step: 1,
|
|
2153
|
+
default: "0%"
|
|
2154
|
+
},
|
|
2155
|
+
{
|
|
2156
|
+
value: "viewportPercent",
|
|
2157
|
+
title: "x-runtime-lib.viewportPercent",
|
|
2158
|
+
validator: (e) => Ct(e, "vh"),
|
|
2159
|
+
trait: "numberUnit",
|
|
2160
|
+
unit: "vh",
|
|
2161
|
+
precision: 6,
|
|
2162
|
+
min: 0,
|
|
2163
|
+
max: Infinity,
|
|
2164
|
+
step: 1,
|
|
2165
|
+
default: "0vh"
|
|
2166
|
+
}
|
|
2167
|
+
]), ot("leftRightV1", [
|
|
2122
2168
|
{
|
|
2123
2169
|
value: "notSet",
|
|
2124
2170
|
title: "x-runtime-lib.notSet",
|
|
@@ -2326,6 +2372,57 @@ ot("borderRadiusV1", [
|
|
|
2326
2372
|
trait: "word",
|
|
2327
2373
|
default: "bottom"
|
|
2328
2374
|
}
|
|
2375
|
+
]), ot("widthV1", [
|
|
2376
|
+
{
|
|
2377
|
+
value: "notSet",
|
|
2378
|
+
title: "x-runtime-lib.notSet",
|
|
2379
|
+
validator: xt,
|
|
2380
|
+
trait: "null",
|
|
2381
|
+
default: null
|
|
2382
|
+
},
|
|
2383
|
+
{
|
|
2384
|
+
value: "pixel",
|
|
2385
|
+
title: "x-runtime-lib.pixel",
|
|
2386
|
+
validator: (e) => Ct(e, "px"),
|
|
2387
|
+
trait: "numberUnit",
|
|
2388
|
+
unit: "px",
|
|
2389
|
+
precision: 0,
|
|
2390
|
+
min: 0,
|
|
2391
|
+
max: Infinity,
|
|
2392
|
+
step: 1,
|
|
2393
|
+
default: "0px"
|
|
2394
|
+
},
|
|
2395
|
+
{
|
|
2396
|
+
value: "percent",
|
|
2397
|
+
title: "x-runtime-lib.percent",
|
|
2398
|
+
validator: (e) => Ct(e, "%"),
|
|
2399
|
+
trait: "numberUnit",
|
|
2400
|
+
unit: "%",
|
|
2401
|
+
precision: 6,
|
|
2402
|
+
min: 0,
|
|
2403
|
+
max: Infinity,
|
|
2404
|
+
step: 1,
|
|
2405
|
+
default: "0%"
|
|
2406
|
+
},
|
|
2407
|
+
{
|
|
2408
|
+
value: "viewportPercent",
|
|
2409
|
+
title: "x-runtime-lib.viewportPercent",
|
|
2410
|
+
validator: (e) => Ct(e, "vw"),
|
|
2411
|
+
trait: "numberUnit",
|
|
2412
|
+
unit: "vw",
|
|
2413
|
+
precision: 6,
|
|
2414
|
+
min: 0,
|
|
2415
|
+
max: Infinity,
|
|
2416
|
+
step: 1,
|
|
2417
|
+
default: "0vw"
|
|
2418
|
+
},
|
|
2419
|
+
{
|
|
2420
|
+
value: "spaced",
|
|
2421
|
+
title: "x-runtime-lib.spaced",
|
|
2422
|
+
validator: (e) => e === "spaced",
|
|
2423
|
+
trait: "word",
|
|
2424
|
+
default: "spaced"
|
|
2425
|
+
}
|
|
2329
2426
|
]);
|
|
2330
2427
|
//#endregion
|
|
2331
2428
|
//#region src/element/_pkgs/index.ts
|
|
@@ -2339,13 +2436,15 @@ var kn = { v1: {
|
|
|
2339
2436
|
"borderWidthV1",
|
|
2340
2437
|
"colorV1",
|
|
2341
2438
|
"elevationV1",
|
|
2439
|
+
"heightV1",
|
|
2342
2440
|
"leftRightV1",
|
|
2343
2441
|
"marginV1",
|
|
2344
2442
|
"paddingV1",
|
|
2345
2443
|
"progressChunkWayV1",
|
|
2346
2444
|
"sizeV1",
|
|
2347
2445
|
"tableColumnAlignV1",
|
|
2348
|
-
"topBottomV1"
|
|
2446
|
+
"topBottomV1",
|
|
2447
|
+
"widthV1"
|
|
2349
2448
|
]),
|
|
2350
2449
|
groups: {
|
|
2351
2450
|
pageUi: [
|
|
@@ -3845,24 +3944,19 @@ function sr(e) {
|
|
|
3845
3944
|
//#endregion
|
|
3846
3945
|
//#region src/composables/element/piece/ui/height/v1/index.ts
|
|
3847
3946
|
function cr(e, t) {
|
|
3848
|
-
let n = $(), r = gl()
|
|
3849
|
-
|
|
3850
|
-
return n === "editor" && t && Dt(
|
|
3851
|
-
}
|
|
3852
|
-
|
|
3853
|
-
|
|
3854
|
-
|
|
3855
|
-
let i = e.value.size?.maxHeight;
|
|
3856
|
-
return n === "editor" && t && Dt(i) ? Ot(i) / 100 * r.value.height + "px" : i;
|
|
3857
|
-
});
|
|
3858
|
-
function s(e) {
|
|
3859
|
-
i.value && (e.height = i.value), a.value && (e.minHeight = a.value), o.value && (e.maxHeight = o.value);
|
|
3947
|
+
let n = $(), r = gl();
|
|
3948
|
+
function i(e) {
|
|
3949
|
+
if (typeof e == "string") return n === "editor" && t && Dt(e) ? Ot(e) / 100 * r.value.height + "px" : Ct(e, "vh") ? wt(e, "vh") / 100 * r.value.height + "px" : e;
|
|
3950
|
+
}
|
|
3951
|
+
let a = w(() => i(e.value.size?.height)), o = w(() => i(e.value.size?.minHeight)), s = w(() => i(e.value.size?.maxHeight));
|
|
3952
|
+
function c(e) {
|
|
3953
|
+
a.value && (e.height = a.value), o.value && (e.minHeight = o.value), s.value && (e.maxHeight = s.value);
|
|
3860
3954
|
}
|
|
3861
3955
|
return {
|
|
3862
|
-
height:
|
|
3863
|
-
minHeight:
|
|
3864
|
-
maxHeight:
|
|
3865
|
-
applyHeight:
|
|
3956
|
+
height: a,
|
|
3957
|
+
minHeight: o,
|
|
3958
|
+
maxHeight: s,
|
|
3959
|
+
applyHeight: c
|
|
3866
3960
|
};
|
|
3867
3961
|
}
|
|
3868
3962
|
//#endregion
|
|
@@ -3898,15 +3992,25 @@ function ur(e) {
|
|
|
3898
3992
|
//#endregion
|
|
3899
3993
|
//#region src/composables/element/piece/ui/width/v1/index.ts
|
|
3900
3994
|
function Q(e) {
|
|
3901
|
-
let t =
|
|
3902
|
-
function
|
|
3903
|
-
|
|
3995
|
+
let t = gl();
|
|
3996
|
+
function n(e) {
|
|
3997
|
+
if (typeof e == "string") {
|
|
3998
|
+
if (Ct(e, "vw")) return wt(e, "vw") / 100 * t.value.width + "px";
|
|
3999
|
+
if (e === "spaced") {
|
|
4000
|
+
let e = t.value.width;
|
|
4001
|
+
return e <= 1280 ? e + "px" : e <= 1920 ? "768px" : "1024px";
|
|
4002
|
+
} else return e;
|
|
4003
|
+
}
|
|
4004
|
+
}
|
|
4005
|
+
let r = w(() => n(e.value.size?.width)), i = w(() => n(e.value.size?.minWidth)), a = w(() => n(e.value.size?.maxWidth));
|
|
4006
|
+
function o(e) {
|
|
4007
|
+
r.value && (e.width = r.value), i.value && (e.minWidth = i.value), a.value && (e.maxWidth = a.value);
|
|
3904
4008
|
}
|
|
3905
4009
|
return {
|
|
3906
|
-
width:
|
|
3907
|
-
minWidth:
|
|
3908
|
-
maxWidth:
|
|
3909
|
-
applyWidth:
|
|
4010
|
+
width: r,
|
|
4011
|
+
minWidth: i,
|
|
4012
|
+
maxWidth: a,
|
|
4013
|
+
applyWidth: o
|
|
3910
4014
|
};
|
|
3911
4015
|
}
|
|
3912
4016
|
//#endregion
|
|
@@ -14207,7 +14311,7 @@ function gs(e, t) {
|
|
|
14207
14311
|
let { n, nodeIds: r } = U(e, t);
|
|
14208
14312
|
return {
|
|
14209
14313
|
nodePairs: [n("ui_dialog_v1", [n("inline_slot_v1", [n("ui_activator_v1", [n("ui_btn_v1", void 0, { "settings.text": "dialog" })])], { "settings.value": "activator" }), n("inline_slot_v1", [n("ui_container_v1", [n("ui_container_v1", [n("ui_container_v1", [], { "size.height": "48px" })], {
|
|
14210
|
-
"size.width": "
|
|
14314
|
+
"size.width": "spaced",
|
|
14211
14315
|
"size.height": "100%",
|
|
14212
14316
|
"margin.left": "auto",
|
|
14213
14317
|
"margin.right": "auto",
|
|
@@ -21587,8 +21691,8 @@ var Cu = (e, t, n) => {
|
|
|
21587
21691
|
//#region src/i18n/index.ts
|
|
21588
21692
|
async function wu(e) {
|
|
21589
21693
|
return (await Cu(/* @__PURE__ */ Object.assign({
|
|
21590
|
-
"./locales/en/index.ts": () => import("./i18n-en.
|
|
21591
|
-
"./locales/zhHans/index.ts": () => import("./i18n-zhHans.
|
|
21694
|
+
"./locales/en/index.ts": () => import("./i18n-en.ot9smdcm.js").then((e) => e.t),
|
|
21695
|
+
"./locales/zhHans/index.ts": () => import("./i18n-zhHans.jgc17e4x.js").then((e) => e.t)
|
|
21592
21696
|
}), `./locales/${e}/index.ts`, 4)).default;
|
|
21593
21697
|
}
|
|
21594
21698
|
//#endregion
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "x-runtime-lib",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.9.
|
|
4
|
+
"version": "0.9.52",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "dist/index.js",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
},
|
|
38
38
|
"peerDependencies": {
|
|
39
39
|
"x-error-lib": "^0.5.18",
|
|
40
|
-
"x-essential-lib": "^0.9.
|
|
40
|
+
"x-essential-lib": "^0.9.35"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"@eslint/js": "^10.0.1",
|