@lokascript/compilation-service 2.6.0 → 2.7.1
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/{chunk-TDQUREQ3.js → chunk-7GECANUT.js} +2 -2
- package/dist/{chunk-OQFAWHZA.js → chunk-T7GHV2SS.js} +2 -2
- package/dist/{core-parser-adapter-VCJB52SO-TJOEWRMN.js → core-parser-adapter-VCJB52SO-KTZQFHF5.js} +2 -2
- package/dist/{dist-HIJ3NH2I.js → dist-HSJGJ5HF.js} +648 -421
- package/dist/dist-HSJGJ5HF.js.map +1 -0
- package/dist/{dist-4M6PD74Q.js → dist-NDTEGHXO.js} +3 -3
- package/dist/http.cjs +648 -421
- package/dist/http.cjs.map +1 -1
- package/dist/http.js +1 -1
- package/dist/index.cjs +648 -421
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1 -1
- package/package.json +5 -5
- package/dist/dist-HIJ3NH2I.js.map +0 -1
- /package/dist/{chunk-TDQUREQ3.js.map → chunk-7GECANUT.js.map} +0 -0
- /package/dist/{chunk-OQFAWHZA.js.map → chunk-T7GHV2SS.js.map} +0 -0
- /package/dist/{core-parser-adapter-VCJB52SO-TJOEWRMN.js.map → core-parser-adapter-VCJB52SO-KTZQFHF5.js.map} +0 -0
- /package/dist/{dist-4M6PD74Q.js.map → dist-NDTEGHXO.js.map} +0 -0
package/dist/index.cjs
CHANGED
|
@@ -80,6 +80,8 @@ __export(dist_exports, {
|
|
|
80
80
|
formatIssuesAsStrings: () => formatIssuesAsStrings,
|
|
81
81
|
formatResultSummary: () => formatResultSummary,
|
|
82
82
|
fromCoreAST: () => fromCoreAST,
|
|
83
|
+
getElementScopeMap: () => getElementScopeMap,
|
|
84
|
+
getElementVar: () => getElementVar,
|
|
83
85
|
getParserExtensionRegistry: () => getParserExtensionRegistry,
|
|
84
86
|
getPartialValidationConfig: () => getPartialValidationConfig,
|
|
85
87
|
hyperscript: () => hyperscript,
|
|
@@ -87,6 +89,8 @@ __export(dist_exports, {
|
|
|
87
89
|
lokascript: () => lokascript,
|
|
88
90
|
parse: () => parse$1,
|
|
89
91
|
resetPartialValidationConfig: () => resetPartialValidationConfig,
|
|
92
|
+
resolveScopeOwner: () => resolveScopeOwner,
|
|
93
|
+
setElementVar: () => setElementVar,
|
|
90
94
|
setGlobal: () => setGlobal,
|
|
91
95
|
toCoreAST: () => toCoreAST,
|
|
92
96
|
validatePartialContent: () => validatePartialContent
|
|
@@ -2423,7 +2427,7 @@ function parseColonVariable(ctx) {
|
|
|
2423
2427
|
return {
|
|
2424
2428
|
type: "identifier",
|
|
2425
2429
|
name: varToken.value,
|
|
2426
|
-
scope: "
|
|
2430
|
+
scope: "element",
|
|
2427
2431
|
start: varToken.start - 1,
|
|
2428
2432
|
end: varToken.end
|
|
2429
2433
|
};
|
|
@@ -2475,7 +2479,7 @@ function parseTargetFallback(ctx) {
|
|
|
2475
2479
|
expression: {
|
|
2476
2480
|
type: "identifier",
|
|
2477
2481
|
name: varToken.value,
|
|
2478
|
-
scope: "
|
|
2482
|
+
scope: "element",
|
|
2479
2483
|
start: varToken.start,
|
|
2480
2484
|
end: varToken.end
|
|
2481
2485
|
},
|
|
@@ -2546,6 +2550,11 @@ function parseSetCommand(ctx, identifierNode) {
|
|
|
2546
2550
|
}
|
|
2547
2551
|
ctx.advance();
|
|
2548
2552
|
const value = ctx.parseExpression() ?? ctx.parsePrimary();
|
|
2553
|
+
let scopeTarget;
|
|
2554
|
+
if (ctx.check(KEYWORDS$1.ON) && tokenLooksLikeElementTarget(ctx.peekAt(1))) {
|
|
2555
|
+
ctx.advance();
|
|
2556
|
+
scopeTarget = parseOneArgument(ctx);
|
|
2557
|
+
}
|
|
2549
2558
|
const finalArgs = [];
|
|
2550
2559
|
if (targetExpression) {
|
|
2551
2560
|
finalArgs.push(targetExpression);
|
|
@@ -2556,7 +2565,20 @@ function parseSetCommand(ctx, identifierNode) {
|
|
|
2556
2565
|
if (value) {
|
|
2557
2566
|
finalArgs.push(value);
|
|
2558
2567
|
}
|
|
2559
|
-
|
|
2568
|
+
const builder = CommandNodeBuilder.fromIdentifier(identifierNode).withArgs(...finalArgs);
|
|
2569
|
+
if (scopeTarget) {
|
|
2570
|
+
builder.withModifier("on", scopeTarget);
|
|
2571
|
+
}
|
|
2572
|
+
return builder.endingAt(ctx.getPosition()).build();
|
|
2573
|
+
}
|
|
2574
|
+
function tokenLooksLikeElementTarget(token) {
|
|
2575
|
+
if (!token)
|
|
2576
|
+
return false;
|
|
2577
|
+
if (token.kind === "selector")
|
|
2578
|
+
return true;
|
|
2579
|
+
if (token.value.startsWith("<"))
|
|
2580
|
+
return true;
|
|
2581
|
+
return ELEMENT_PRONOUNS.has(token.value);
|
|
2560
2582
|
}
|
|
2561
2583
|
function parseIncrementDecrementCommand(ctx, commandToken) {
|
|
2562
2584
|
const commandName = commandToken.value;
|
|
@@ -2602,6 +2624,7 @@ function parseIncrementDecrementCommand(ctx, commandToken) {
|
|
|
2602
2624
|
column: commandToken.column
|
|
2603
2625
|
};
|
|
2604
2626
|
const binaryExpr = createBinaryExpression(operator, target, amount, pos2);
|
|
2627
|
+
binaryExpr.coerceNumeric = true;
|
|
2605
2628
|
const toIdentifier = createIdentifier(KEYWORDS$1.TO, pos2);
|
|
2606
2629
|
const args = [targetWithScope, toIdentifier, binaryExpr];
|
|
2607
2630
|
return CommandNodeBuilder.from(commandToken).withName("set").withArgs(...args).withOriginalCommand(commandName).endingAt({ end: ctx.previous().end }).build();
|
|
@@ -3076,6 +3099,301 @@ function err(error) {
|
|
|
3076
3099
|
function isOk(result) {
|
|
3077
3100
|
return result.ok === true;
|
|
3078
3101
|
}
|
|
3102
|
+
function getElementScopeMap(element) {
|
|
3103
|
+
let map = elementScopes.get(element);
|
|
3104
|
+
if (!map) {
|
|
3105
|
+
map = /* @__PURE__ */ new Map();
|
|
3106
|
+
elementScopes.set(element, map);
|
|
3107
|
+
}
|
|
3108
|
+
return map;
|
|
3109
|
+
}
|
|
3110
|
+
function resolveScopeOwner(context) {
|
|
3111
|
+
const owner = context.owner;
|
|
3112
|
+
if (owner)
|
|
3113
|
+
return owner;
|
|
3114
|
+
return context.me instanceof Element ? context.me : null;
|
|
3115
|
+
}
|
|
3116
|
+
function getElementVar(context, name) {
|
|
3117
|
+
const owner = resolveScopeOwner(context);
|
|
3118
|
+
if (!owner)
|
|
3119
|
+
return void 0;
|
|
3120
|
+
notifyLocalRead(name, context);
|
|
3121
|
+
return getElementScopeMap(owner).get(name);
|
|
3122
|
+
}
|
|
3123
|
+
function setElementVar(context, name, value) {
|
|
3124
|
+
const owner = resolveScopeOwner(context);
|
|
3125
|
+
if (!owner)
|
|
3126
|
+
return;
|
|
3127
|
+
getElementScopeMap(owner).set(name, value);
|
|
3128
|
+
notifyLocalWrite(name, value, context);
|
|
3129
|
+
}
|
|
3130
|
+
function createContext(element, globals) {
|
|
3131
|
+
return {
|
|
3132
|
+
me: element ?? null,
|
|
3133
|
+
owner: element ?? null,
|
|
3134
|
+
it: null,
|
|
3135
|
+
you: null,
|
|
3136
|
+
result: null,
|
|
3137
|
+
locals: /* @__PURE__ */ new Map(),
|
|
3138
|
+
globals: globals || sharedGlobals,
|
|
3139
|
+
flags: {
|
|
3140
|
+
halted: false,
|
|
3141
|
+
breaking: false,
|
|
3142
|
+
continuing: false,
|
|
3143
|
+
returning: false,
|
|
3144
|
+
async: false
|
|
3145
|
+
}
|
|
3146
|
+
};
|
|
3147
|
+
}
|
|
3148
|
+
function getSharedGlobals() {
|
|
3149
|
+
return sharedGlobals;
|
|
3150
|
+
}
|
|
3151
|
+
function createChildContext(parent, element) {
|
|
3152
|
+
return {
|
|
3153
|
+
me: element ?? parent.me,
|
|
3154
|
+
owner: parent.owner ?? parent.me ?? element ?? null,
|
|
3155
|
+
it: null,
|
|
3156
|
+
you: null,
|
|
3157
|
+
result: null,
|
|
3158
|
+
locals: /* @__PURE__ */ new Map(),
|
|
3159
|
+
globals: parent.globals,
|
|
3160
|
+
parent,
|
|
3161
|
+
flags: {
|
|
3162
|
+
halted: false,
|
|
3163
|
+
breaking: false,
|
|
3164
|
+
continuing: false,
|
|
3165
|
+
returning: false,
|
|
3166
|
+
async: false
|
|
3167
|
+
}
|
|
3168
|
+
};
|
|
3169
|
+
}
|
|
3170
|
+
function isHTMLElement$2(value) {
|
|
3171
|
+
return value !== null && typeof value === "object" && "nodeType" in value && value.nodeType === 1 && "tagName" in value && typeof value.tagName === "string" && "classList" in value;
|
|
3172
|
+
}
|
|
3173
|
+
function isNodeList(value) {
|
|
3174
|
+
return value !== null && typeof value === "object" && "length" in value && typeof value.length === "number" && (Symbol.iterator in value || typeof value.item === "function");
|
|
3175
|
+
}
|
|
3176
|
+
function isDocumentFragment(value) {
|
|
3177
|
+
return value !== null && typeof value === "object" && "nodeType" in value && value.nodeType === 11 && "childNodes" in value;
|
|
3178
|
+
}
|
|
3179
|
+
function convertToNumber(value) {
|
|
3180
|
+
if (value === null || value === void 0) {
|
|
3181
|
+
return 0;
|
|
3182
|
+
}
|
|
3183
|
+
if (typeof value === "number") {
|
|
3184
|
+
return isFinite(value) ? value : 0;
|
|
3185
|
+
}
|
|
3186
|
+
if (typeof value === "string") {
|
|
3187
|
+
const parsed = parseFloat(value);
|
|
3188
|
+
return parsed;
|
|
3189
|
+
}
|
|
3190
|
+
if (typeof value === "boolean") {
|
|
3191
|
+
return value ? 1 : 0;
|
|
3192
|
+
}
|
|
3193
|
+
if (Array.isArray(value)) {
|
|
3194
|
+
return value.length;
|
|
3195
|
+
}
|
|
3196
|
+
if (typeof value === "object") {
|
|
3197
|
+
if ("length" in value && typeof value.length === "number") {
|
|
3198
|
+
return value.length;
|
|
3199
|
+
}
|
|
3200
|
+
if (typeof value.valueOf === "function") {
|
|
3201
|
+
const result = value.valueOf();
|
|
3202
|
+
if (typeof result === "number") {
|
|
3203
|
+
return result;
|
|
3204
|
+
}
|
|
3205
|
+
}
|
|
3206
|
+
return NaN;
|
|
3207
|
+
}
|
|
3208
|
+
return 0;
|
|
3209
|
+
}
|
|
3210
|
+
function getVariableValue(name, context, preferredScope) {
|
|
3211
|
+
if (preferredScope === "element") {
|
|
3212
|
+
return getElementVar(context, name);
|
|
3213
|
+
}
|
|
3214
|
+
if (preferredScope === "global" && context.globals && context.globals.has(name)) {
|
|
3215
|
+
return context.globals.get(name);
|
|
3216
|
+
}
|
|
3217
|
+
if (preferredScope !== "global" && context.locals && context.locals.has(name)) {
|
|
3218
|
+
notifyLocalRead(name, context);
|
|
3219
|
+
return context.locals.get(name);
|
|
3220
|
+
}
|
|
3221
|
+
if (context.globals && context.globals.has(name)) {
|
|
3222
|
+
return context.globals.get(name);
|
|
3223
|
+
}
|
|
3224
|
+
if (context.variables && context.variables.has(name)) {
|
|
3225
|
+
return context.variables.get(name);
|
|
3226
|
+
}
|
|
3227
|
+
if (preferredScope === "global" && context.locals && context.locals.has(name)) {
|
|
3228
|
+
notifyLocalRead(name, context);
|
|
3229
|
+
return context.locals.get(name);
|
|
3230
|
+
}
|
|
3231
|
+
if (typeof window !== "undefined" && name in window) {
|
|
3232
|
+
return window[name];
|
|
3233
|
+
}
|
|
3234
|
+
if (typeof globalThis !== "undefined" && name in globalThis) {
|
|
3235
|
+
return globalThis[name];
|
|
3236
|
+
}
|
|
3237
|
+
return void 0;
|
|
3238
|
+
}
|
|
3239
|
+
function setVariableValue(name, value, context, preferredScope) {
|
|
3240
|
+
if (preferredScope === "element") {
|
|
3241
|
+
setElementVar(context, name, value);
|
|
3242
|
+
return;
|
|
3243
|
+
}
|
|
3244
|
+
if (preferredScope === "global") {
|
|
3245
|
+
setGlobal(context, name, value);
|
|
3246
|
+
if (typeof window !== "undefined") {
|
|
3247
|
+
window[name] = value;
|
|
3248
|
+
}
|
|
3249
|
+
return;
|
|
3250
|
+
}
|
|
3251
|
+
if (name.startsWith("$")) {
|
|
3252
|
+
const bare = name.slice(1);
|
|
3253
|
+
setGlobal(context, bare, value);
|
|
3254
|
+
return;
|
|
3255
|
+
}
|
|
3256
|
+
if (context.locals && context.locals.has(name)) {
|
|
3257
|
+
context.locals.set(name, value);
|
|
3258
|
+
notifyLocalWrite(name, value, context);
|
|
3259
|
+
return;
|
|
3260
|
+
}
|
|
3261
|
+
if (context.globals && context.globals.has(name)) {
|
|
3262
|
+
setGlobal(context, name, value);
|
|
3263
|
+
if (typeof window !== "undefined" && name in window) {
|
|
3264
|
+
window[name] = value;
|
|
3265
|
+
}
|
|
3266
|
+
return;
|
|
3267
|
+
}
|
|
3268
|
+
if (context.variables && context.variables.has(name)) {
|
|
3269
|
+
context.variables.set(name, value);
|
|
3270
|
+
return;
|
|
3271
|
+
}
|
|
3272
|
+
if (typeof window !== "undefined" && name in window) {
|
|
3273
|
+
window[name] = value;
|
|
3274
|
+
setGlobal(context, name, value);
|
|
3275
|
+
return;
|
|
3276
|
+
}
|
|
3277
|
+
context.locals.set(name, value);
|
|
3278
|
+
notifyLocalWrite(name, value, context);
|
|
3279
|
+
}
|
|
3280
|
+
function resolveElementRef(elementRef, context) {
|
|
3281
|
+
if (elementRef === "me") {
|
|
3282
|
+
return context.me;
|
|
3283
|
+
} else if (elementRef === "it") {
|
|
3284
|
+
return context.it;
|
|
3285
|
+
} else if (elementRef === "you") {
|
|
3286
|
+
return context.you;
|
|
3287
|
+
} else {
|
|
3288
|
+
return getVariableValue(elementRef, context);
|
|
3289
|
+
}
|
|
3290
|
+
}
|
|
3291
|
+
function getElementPropertyValue(propertyPath, context) {
|
|
3292
|
+
const parts = propertyPath.split(".");
|
|
3293
|
+
const elementRef = parts[0];
|
|
3294
|
+
const property = parts[1];
|
|
3295
|
+
const element = resolveElementRef(elementRef, context);
|
|
3296
|
+
if (!element) {
|
|
3297
|
+
return 0;
|
|
3298
|
+
}
|
|
3299
|
+
const value = element[property];
|
|
3300
|
+
return convertToNumber(value);
|
|
3301
|
+
}
|
|
3302
|
+
function setElementPropertyValue(propertyPath, value, context) {
|
|
3303
|
+
const parts = propertyPath.split(".");
|
|
3304
|
+
const elementRef = parts[0];
|
|
3305
|
+
const property = parts[1];
|
|
3306
|
+
const element = resolveElementRef(elementRef, context);
|
|
3307
|
+
if (element) {
|
|
3308
|
+
element[property] = value;
|
|
3309
|
+
}
|
|
3310
|
+
}
|
|
3311
|
+
function getCurrentNumericValue(target, property, scope, context) {
|
|
3312
|
+
if (typeof target === "number") {
|
|
3313
|
+
return target;
|
|
3314
|
+
}
|
|
3315
|
+
if (isHTMLElement$2(target)) {
|
|
3316
|
+
const element = target;
|
|
3317
|
+
if (property) {
|
|
3318
|
+
if (property.startsWith("data-") || ["id", "class", "title", "alt", "src", "href"].includes(property)) {
|
|
3319
|
+
const value = element.getAttribute(property);
|
|
3320
|
+
return convertToNumber(value);
|
|
3321
|
+
} else {
|
|
3322
|
+
const value = element[property];
|
|
3323
|
+
return convertToNumber(value);
|
|
3324
|
+
}
|
|
3325
|
+
} else {
|
|
3326
|
+
const value = element.value || element.textContent;
|
|
3327
|
+
return convertToNumber(value);
|
|
3328
|
+
}
|
|
3329
|
+
}
|
|
3330
|
+
if (typeof target === "string") {
|
|
3331
|
+
if (scope === "element") {
|
|
3332
|
+
return convertToNumber(getVariableValue(target, context, "element"));
|
|
3333
|
+
}
|
|
3334
|
+
if (scope === "global") {
|
|
3335
|
+
const value2 = getVariableValue(target, context, "global");
|
|
3336
|
+
return convertToNumber(value2);
|
|
3337
|
+
}
|
|
3338
|
+
if (target.includes(".")) {
|
|
3339
|
+
return getElementPropertyValue(target, context);
|
|
3340
|
+
}
|
|
3341
|
+
if (target === "me" && context.me) {
|
|
3342
|
+
return convertToNumber(context.me.value || 0);
|
|
3343
|
+
} else if (target === "it") {
|
|
3344
|
+
return convertToNumber(context.it || 0);
|
|
3345
|
+
} else if (target === "you" && context.you) {
|
|
3346
|
+
return convertToNumber(context.you.value || 0);
|
|
3347
|
+
}
|
|
3348
|
+
const value = getVariableValue(target, context);
|
|
3349
|
+
return convertToNumber(value);
|
|
3350
|
+
}
|
|
3351
|
+
return convertToNumber(target);
|
|
3352
|
+
}
|
|
3353
|
+
function setTargetValue(target, property, scope, newValue, context) {
|
|
3354
|
+
if (isHTMLElement$2(target)) {
|
|
3355
|
+
const element = target;
|
|
3356
|
+
if (property) {
|
|
3357
|
+
if (property.startsWith("data-") || ["id", "class", "title", "alt", "src", "href"].includes(property)) {
|
|
3358
|
+
element.setAttribute(property, String(newValue));
|
|
3359
|
+
} else {
|
|
3360
|
+
element[property] = newValue;
|
|
3361
|
+
}
|
|
3362
|
+
} else {
|
|
3363
|
+
if ("value" in element && element.value !== void 0) {
|
|
3364
|
+
element.value = String(newValue);
|
|
3365
|
+
} else {
|
|
3366
|
+
element.textContent = String(newValue);
|
|
3367
|
+
}
|
|
3368
|
+
}
|
|
3369
|
+
return;
|
|
3370
|
+
}
|
|
3371
|
+
if (typeof target === "string") {
|
|
3372
|
+
if (scope === "element") {
|
|
3373
|
+
setVariableValue(target, newValue, context, "element");
|
|
3374
|
+
return;
|
|
3375
|
+
}
|
|
3376
|
+
if (scope === "global") {
|
|
3377
|
+
setVariableValue(target, newValue, context, "global");
|
|
3378
|
+
return;
|
|
3379
|
+
}
|
|
3380
|
+
if (target.includes(".")) {
|
|
3381
|
+
setElementPropertyValue(target, newValue, context);
|
|
3382
|
+
return;
|
|
3383
|
+
}
|
|
3384
|
+
if (target === "me" && context.me) {
|
|
3385
|
+
context.me.value = newValue;
|
|
3386
|
+
return;
|
|
3387
|
+
} else if (target === "it") {
|
|
3388
|
+
Object.assign(context, { it: newValue });
|
|
3389
|
+
return;
|
|
3390
|
+
} else if (target === "you" && context.you) {
|
|
3391
|
+
context.you.value = newValue;
|
|
3392
|
+
return;
|
|
3393
|
+
}
|
|
3394
|
+
setVariableValue(target, newValue, context);
|
|
3395
|
+
}
|
|
3396
|
+
}
|
|
3079
3397
|
function isString(value) {
|
|
3080
3398
|
const stringType = expressionTypeRegistry.get("String");
|
|
3081
3399
|
return stringType ? stringType.isType(value) : typeof value === "string";
|
|
@@ -3106,7 +3424,7 @@ function isFormElement$1(el) {
|
|
|
3106
3424
|
const tag = el.tagName;
|
|
3107
3425
|
return tag === "INPUT" || tag === "SELECT" || tag === "TEXTAREA";
|
|
3108
3426
|
}
|
|
3109
|
-
function isHTMLElement$
|
|
3427
|
+
function isHTMLElement$1(el) {
|
|
3110
3428
|
return el !== null && typeof el === "object" && "nodeType" in el && el.nodeType === 1 && "style" in el;
|
|
3111
3429
|
}
|
|
3112
3430
|
function isOptionElement$1(el) {
|
|
@@ -3115,7 +3433,7 @@ function isOptionElement$1(el) {
|
|
|
3115
3433
|
function isElement(value) {
|
|
3116
3434
|
return value instanceof Element;
|
|
3117
3435
|
}
|
|
3118
|
-
function isHTMLElement
|
|
3436
|
+
function isHTMLElement(value) {
|
|
3119
3437
|
return value instanceof HTMLElement;
|
|
3120
3438
|
}
|
|
3121
3439
|
function accessAttribute(element, attrName) {
|
|
@@ -3139,7 +3457,7 @@ function collectFormValues(el) {
|
|
|
3139
3457
|
return fd;
|
|
3140
3458
|
}
|
|
3141
3459
|
function getElementStyleValue(element, styleProp) {
|
|
3142
|
-
if (!isHTMLElement
|
|
3460
|
+
if (!isHTMLElement(element))
|
|
3143
3461
|
return void 0;
|
|
3144
3462
|
if (styleProp.startsWith("computed-")) {
|
|
3145
3463
|
return getComputedStyle(element).getPropertyValue(styleProp.slice("computed-".length)) || "";
|
|
@@ -3153,7 +3471,7 @@ function getElementProperty$1(element, property) {
|
|
|
3153
3471
|
}
|
|
3154
3472
|
if (property.startsWith("computed-")) {
|
|
3155
3473
|
const cssProperty = property.slice("computed-".length);
|
|
3156
|
-
if (isHTMLElement
|
|
3474
|
+
if (isHTMLElement(element)) {
|
|
3157
3475
|
const computedStyle = getComputedStyle(element);
|
|
3158
3476
|
return computedStyle.getPropertyValue(cssProperty);
|
|
3159
3477
|
}
|
|
@@ -3880,7 +4198,7 @@ function evaluateExpressionSync(node, context) {
|
|
|
3880
4198
|
case "selector":
|
|
3881
4199
|
return evaluateSelectorSync(n, context);
|
|
3882
4200
|
case "identifier":
|
|
3883
|
-
return resolveIdentifierSync(n.name, context);
|
|
4201
|
+
return resolveIdentifierSync(n.name, context, n.scope);
|
|
3884
4202
|
case "contextReference":
|
|
3885
4203
|
return resolveContextReferenceSync(n.contextType, context);
|
|
3886
4204
|
case "arrayLiteral":
|
|
@@ -3910,7 +4228,7 @@ function evaluateExpressionSync(node, context) {
|
|
|
3910
4228
|
throw new NotSyncEvaluable(n?.type ?? "unknown");
|
|
3911
4229
|
}
|
|
3912
4230
|
}
|
|
3913
|
-
function resolveIdentifierSync(name, context) {
|
|
4231
|
+
function resolveIdentifierSync(name, context, scope) {
|
|
3914
4232
|
if (name === "me" || name === "my" || name === "I")
|
|
3915
4233
|
return context.me;
|
|
3916
4234
|
if (name === "you" || name === "your" || name === "yourself")
|
|
@@ -3921,6 +4239,8 @@ function resolveIdentifierSync(name, context) {
|
|
|
3921
4239
|
return typeof window !== "undefined" ? window : globalThis;
|
|
3922
4240
|
if (name === "document")
|
|
3923
4241
|
return typeof document !== "undefined" ? document : void 0;
|
|
4242
|
+
if (scope === "element")
|
|
4243
|
+
return getElementVar(context, name);
|
|
3924
4244
|
if (context.locals?.has(name))
|
|
3925
4245
|
return context.locals.get(name);
|
|
3926
4246
|
if (context.globals?.has(name))
|
|
@@ -4046,6 +4366,9 @@ async function evaluateIdentifier(node, context) {
|
|
|
4046
4366
|
notifyGlobalRead(name, context);
|
|
4047
4367
|
return context.globals.get(name);
|
|
4048
4368
|
}
|
|
4369
|
+
if (node.scope === "element") {
|
|
4370
|
+
return getElementVar(context, name);
|
|
4371
|
+
}
|
|
4049
4372
|
if (context.locals && context.locals.has(name)) {
|
|
4050
4373
|
notifyLocalRead(name, context);
|
|
4051
4374
|
return context.locals.get(name);
|
|
@@ -4079,6 +4402,8 @@ async function evaluateBinaryExpression(node, context) {
|
|
|
4079
4402
|
setGlobal(context, name.slice(1), value);
|
|
4080
4403
|
} else if (leftNode.scope === "global") {
|
|
4081
4404
|
setGlobal(context, name, value);
|
|
4405
|
+
} else if (leftNode.scope === "element") {
|
|
4406
|
+
setElementVar(context, name, value);
|
|
4082
4407
|
} else {
|
|
4083
4408
|
if (!context.locals)
|
|
4084
4409
|
context.locals = /* @__PURE__ */ new Map();
|
|
@@ -4152,14 +4477,26 @@ async function evaluateBinaryExpression(node, context) {
|
|
|
4152
4477
|
const L = node.ignoringCase ? applyCI(left) : left;
|
|
4153
4478
|
const R = node.ignoringCase ? applyCI(right) : right;
|
|
4154
4479
|
switch (operator) {
|
|
4155
|
-
case "+":
|
|
4156
|
-
|
|
4157
|
-
|
|
4158
|
-
|
|
4159
|
-
|
|
4160
|
-
|
|
4161
|
-
|
|
4162
|
-
|
|
4480
|
+
case "+": {
|
|
4481
|
+
let addLeft = left;
|
|
4482
|
+
let addRight = right;
|
|
4483
|
+
if (node.coerceNumeric) {
|
|
4484
|
+
if (typeof addLeft === "string")
|
|
4485
|
+
addLeft = convertToNumber(addLeft);
|
|
4486
|
+
if (typeof addRight === "string")
|
|
4487
|
+
addRight = convertToNumber(addRight);
|
|
4488
|
+
}
|
|
4489
|
+
if (typeof addLeft === "string" || typeof addRight === "string") {
|
|
4490
|
+
return String(addLeft ?? "") + String(addRight ?? "");
|
|
4491
|
+
}
|
|
4492
|
+
if (Array.isArray(addLeft)) {
|
|
4493
|
+
return Array.isArray(addRight) ? [...addLeft, ...addRight] : [...addLeft, addRight];
|
|
4494
|
+
}
|
|
4495
|
+
return unwrapTypedResult(await getExpr(context, "addition").evaluate(context, {
|
|
4496
|
+
left: addLeft,
|
|
4497
|
+
right: addRight
|
|
4498
|
+
}));
|
|
4499
|
+
}
|
|
4163
4500
|
case "-":
|
|
4164
4501
|
return unwrapTypedResult(await getExpr(context, "subtraction").evaluate(context, { left, right }));
|
|
4165
4502
|
case "*":
|
|
@@ -4798,44 +5135,6 @@ async function evaluateConditionalExpression(node, context) {
|
|
|
4798
5135
|
}
|
|
4799
5136
|
return void 0;
|
|
4800
5137
|
}
|
|
4801
|
-
function createContext(element, globals) {
|
|
4802
|
-
return {
|
|
4803
|
-
me: element ?? null,
|
|
4804
|
-
it: null,
|
|
4805
|
-
you: null,
|
|
4806
|
-
result: null,
|
|
4807
|
-
locals: /* @__PURE__ */ new Map(),
|
|
4808
|
-
globals: globals || sharedGlobals,
|
|
4809
|
-
flags: {
|
|
4810
|
-
halted: false,
|
|
4811
|
-
breaking: false,
|
|
4812
|
-
continuing: false,
|
|
4813
|
-
returning: false,
|
|
4814
|
-
async: false
|
|
4815
|
-
}
|
|
4816
|
-
};
|
|
4817
|
-
}
|
|
4818
|
-
function getSharedGlobals() {
|
|
4819
|
-
return sharedGlobals;
|
|
4820
|
-
}
|
|
4821
|
-
function createChildContext(parent, element) {
|
|
4822
|
-
return {
|
|
4823
|
-
me: element ?? parent.me,
|
|
4824
|
-
it: null,
|
|
4825
|
-
you: null,
|
|
4826
|
-
result: null,
|
|
4827
|
-
locals: /* @__PURE__ */ new Map(),
|
|
4828
|
-
globals: parent.globals,
|
|
4829
|
-
parent,
|
|
4830
|
-
flags: {
|
|
4831
|
-
halted: false,
|
|
4832
|
-
breaking: false,
|
|
4833
|
-
continuing: false,
|
|
4834
|
-
returning: false,
|
|
4835
|
-
async: false
|
|
4836
|
-
}
|
|
4837
|
-
};
|
|
4838
|
-
}
|
|
4839
5138
|
function createEventSourceRegistry() {
|
|
4840
5139
|
return new EventSourceRegistry();
|
|
4841
5140
|
}
|
|
@@ -5531,20 +5830,11 @@ function meta(config2) {
|
|
|
5531
5830
|
function createFactory(CommandClass) {
|
|
5532
5831
|
return () => new CommandClass();
|
|
5533
5832
|
}
|
|
5534
|
-
function isHTMLElement(value) {
|
|
5535
|
-
return value !== null && typeof value === "object" && "nodeType" in value && value.nodeType === 1 && "tagName" in value && typeof value.tagName === "string" && "classList" in value;
|
|
5536
|
-
}
|
|
5537
|
-
function isNodeList(value) {
|
|
5538
|
-
return value !== null && typeof value === "object" && "length" in value && typeof value.length === "number" && (Symbol.iterator in value || typeof value.item === "function");
|
|
5539
|
-
}
|
|
5540
|
-
function isDocumentFragment(value) {
|
|
5541
|
-
return value !== null && typeof value === "object" && "nodeType" in value && value.nodeType === 11 && "childNodes" in value;
|
|
5542
|
-
}
|
|
5543
5833
|
function withCmd(commandName, message) {
|
|
5544
5834
|
return commandName ? `[${commandName}] ${message}` : message;
|
|
5545
5835
|
}
|
|
5546
5836
|
function resolveElement(target, context, commandName) {
|
|
5547
|
-
if (isHTMLElement(target)) {
|
|
5837
|
+
if (isHTMLElement$2(target)) {
|
|
5548
5838
|
return target;
|
|
5549
5839
|
}
|
|
5550
5840
|
if (!target) {
|
|
@@ -5563,7 +5853,7 @@ function resolveElement(target, context, commandName) {
|
|
|
5563
5853
|
return asHTMLElement(context.me);
|
|
5564
5854
|
}
|
|
5565
5855
|
if (trimmed === "it") {
|
|
5566
|
-
if (!isHTMLElement(context.it)) {
|
|
5856
|
+
if (!isHTMLElement$2(context.it)) {
|
|
5567
5857
|
throw new Error(withCmd(commandName, 'Context reference "it" is not an HTMLElement'));
|
|
5568
5858
|
}
|
|
5569
5859
|
return context.it;
|
|
@@ -5582,7 +5872,7 @@ function resolveElement(target, context, commandName) {
|
|
|
5582
5872
|
if (!element) {
|
|
5583
5873
|
throw new Error(withCmd(commandName, `Element not found with selector: ${trimmed}`));
|
|
5584
5874
|
}
|
|
5585
|
-
if (!isHTMLElement(element)) {
|
|
5875
|
+
if (!isHTMLElement$2(element)) {
|
|
5586
5876
|
throw new Error(withCmd(commandName, `Element found but is not an HTMLElement: ${trimmed}`));
|
|
5587
5877
|
}
|
|
5588
5878
|
return element;
|
|
@@ -5591,12 +5881,12 @@ function resolveElement(target, context, commandName) {
|
|
|
5591
5881
|
}
|
|
5592
5882
|
function resolveElements(target, context) {
|
|
5593
5883
|
if (Array.isArray(target)) {
|
|
5594
|
-
return target.filter(isHTMLElement);
|
|
5884
|
+
return target.filter(isHTMLElement$2);
|
|
5595
5885
|
}
|
|
5596
5886
|
if (isNodeList(target)) {
|
|
5597
|
-
return Array.from(target).filter(isHTMLElement);
|
|
5887
|
+
return Array.from(target).filter(isHTMLElement$2);
|
|
5598
5888
|
}
|
|
5599
|
-
if (isHTMLElement(target)) {
|
|
5889
|
+
if (isHTMLElement$2(target)) {
|
|
5600
5890
|
return [target];
|
|
5601
5891
|
}
|
|
5602
5892
|
if (!target) {
|
|
@@ -5604,18 +5894,18 @@ function resolveElements(target, context) {
|
|
|
5604
5894
|
if (!me) {
|
|
5605
5895
|
return [];
|
|
5606
5896
|
}
|
|
5607
|
-
return isHTMLElement(me) ? [me] : [];
|
|
5897
|
+
return isHTMLElement$2(me) ? [me] : [];
|
|
5608
5898
|
}
|
|
5609
5899
|
if (typeof target === "string") {
|
|
5610
5900
|
const trimmed = target.trim();
|
|
5611
5901
|
if (trimmed === "me") {
|
|
5612
|
-
return context.me && isHTMLElement(context.me) ? [context.me] : [];
|
|
5902
|
+
return context.me && isHTMLElement$2(context.me) ? [context.me] : [];
|
|
5613
5903
|
}
|
|
5614
5904
|
if (trimmed === "it") {
|
|
5615
|
-
return isHTMLElement(context.it) ? [context.it] : [];
|
|
5905
|
+
return isHTMLElement$2(context.it) ? [context.it] : [];
|
|
5616
5906
|
}
|
|
5617
5907
|
if (trimmed === "you") {
|
|
5618
|
-
return context.you && isHTMLElement(context.you) ? [context.you] : [];
|
|
5908
|
+
return context.you && isHTMLElement$2(context.you) ? [context.you] : [];
|
|
5619
5909
|
}
|
|
5620
5910
|
const doc = context.me?.ownerDocument ?? (typeof document !== "undefined" ? document : null);
|
|
5621
5911
|
if (doc) {
|
|
@@ -5624,13 +5914,13 @@ function resolveElements(target, context) {
|
|
|
5624
5914
|
selector = selector.slice(1, -2).trim();
|
|
5625
5915
|
}
|
|
5626
5916
|
const elements = doc.querySelectorAll(selector);
|
|
5627
|
-
return Array.from(elements).filter(isHTMLElement);
|
|
5917
|
+
return Array.from(elements).filter(isHTMLElement$2);
|
|
5628
5918
|
}
|
|
5629
5919
|
}
|
|
5630
5920
|
return [];
|
|
5631
5921
|
}
|
|
5632
5922
|
function asHTMLElement(value) {
|
|
5633
|
-
if (isHTMLElement(value)) {
|
|
5923
|
+
if (isHTMLElement$2(value)) {
|
|
5634
5924
|
return value;
|
|
5635
5925
|
}
|
|
5636
5926
|
throw new Error("Value is not an HTMLElement");
|
|
@@ -5641,21 +5931,21 @@ function resolvePossessive(possessive, context, commandName) {
|
|
|
5641
5931
|
case "me":
|
|
5642
5932
|
if (!context.me)
|
|
5643
5933
|
throw new Error(withCmd(commandName, 'No "me" element in context'));
|
|
5644
|
-
if (!isHTMLElement(context.me))
|
|
5934
|
+
if (!isHTMLElement$2(context.me))
|
|
5645
5935
|
throw new Error(withCmd(commandName, "context.me is not an HTMLElement"));
|
|
5646
5936
|
return context.me;
|
|
5647
5937
|
case "its":
|
|
5648
5938
|
case "it":
|
|
5649
5939
|
if (!context.it)
|
|
5650
5940
|
throw new Error(withCmd(commandName, 'No "it" value in context'));
|
|
5651
|
-
if (!isHTMLElement(context.it))
|
|
5941
|
+
if (!isHTMLElement$2(context.it))
|
|
5652
5942
|
throw new Error(withCmd(commandName, "context.it is not an HTMLElement"));
|
|
5653
5943
|
return context.it;
|
|
5654
5944
|
case "your":
|
|
5655
5945
|
case "you":
|
|
5656
5946
|
if (!context.you)
|
|
5657
5947
|
throw new Error(withCmd(commandName, 'No "you" element in context'));
|
|
5658
|
-
if (!isHTMLElement(context.you))
|
|
5948
|
+
if (!isHTMLElement$2(context.you))
|
|
5659
5949
|
throw new Error(withCmd(commandName, "context.you is not an HTMLElement"));
|
|
5660
5950
|
return context.you;
|
|
5661
5951
|
default:
|
|
@@ -5683,7 +5973,7 @@ async function resolveTargetsFromArgs(args, evaluator, context, commandName, opt
|
|
|
5683
5973
|
if (!context.me) {
|
|
5684
5974
|
throw new Error(`${commandName} command: no target specified and context.me is null`);
|
|
5685
5975
|
}
|
|
5686
|
-
if (!isHTMLElement(context.me)) {
|
|
5976
|
+
if (!isHTMLElement$2(context.me)) {
|
|
5687
5977
|
throw new Error(`${commandName} command: context.me must be an HTMLElement`);
|
|
5688
5978
|
}
|
|
5689
5979
|
return [context.me];
|
|
@@ -5694,13 +5984,13 @@ async function resolveTargetsFromArgs(args, evaluator, context, commandName, opt
|
|
|
5694
5984
|
if (evaluated === "" || typeof evaluated === "string" && evaluated.trim() === "") {
|
|
5695
5985
|
continue;
|
|
5696
5986
|
}
|
|
5697
|
-
if (isHTMLElement(evaluated)) {
|
|
5987
|
+
if (isHTMLElement$2(evaluated)) {
|
|
5698
5988
|
targets.push(evaluated);
|
|
5699
5989
|
} else if (isNodeList(evaluated)) {
|
|
5700
|
-
const elements = Array.from(evaluated).filter(isHTMLElement);
|
|
5990
|
+
const elements = Array.from(evaluated).filter(isHTMLElement$2);
|
|
5701
5991
|
targets.push(...elements);
|
|
5702
5992
|
} else if (Array.isArray(evaluated)) {
|
|
5703
|
-
const elements = evaluated.filter(isHTMLElement);
|
|
5993
|
+
const elements = evaluated.filter(isHTMLElement$2);
|
|
5704
5994
|
targets.push(...elements);
|
|
5705
5995
|
} else if (typeof evaluated === "string") {
|
|
5706
5996
|
try {
|
|
@@ -5713,7 +6003,7 @@ async function resolveTargetsFromArgs(args, evaluator, context, commandName, opt
|
|
|
5713
6003
|
throw new Error("DOM not available - cannot resolve element selector");
|
|
5714
6004
|
}
|
|
5715
6005
|
const selected = doc.querySelectorAll(selector);
|
|
5716
|
-
const elements = Array.from(selected).filter(isHTMLElement);
|
|
6006
|
+
const elements = Array.from(selected).filter(isHTMLElement$2);
|
|
5717
6007
|
targets.push(...elements);
|
|
5718
6008
|
} catch (error) {
|
|
5719
6009
|
throw new Error(`Invalid CSS selector: "${evaluated}" - ${error instanceof Error ? error.message : String(error)}`);
|
|
@@ -5728,7 +6018,7 @@ async function resolveTargetsFromArgs(args, evaluator, context, commandName, opt
|
|
|
5728
6018
|
if (!context.me) {
|
|
5729
6019
|
throw new Error(`${commandName} command: no target specified and context.me is null`);
|
|
5730
6020
|
}
|
|
5731
|
-
if (!isHTMLElement(context.me)) {
|
|
6021
|
+
if (!isHTMLElement$2(context.me)) {
|
|
5732
6022
|
throw new Error(`${commandName} command: context.me must be an HTMLElement`);
|
|
5733
6023
|
}
|
|
5734
6024
|
return [context.me];
|
|
@@ -6064,7 +6354,7 @@ async function evaluateFirstArg(firstArg, evaluator, context) {
|
|
|
6064
6354
|
};
|
|
6065
6355
|
}
|
|
6066
6356
|
function isValidTargetArray(targets) {
|
|
6067
|
-
return Array.isArray(targets) && targets.length > 0 && targets.every((t) => isHTMLElement(t));
|
|
6357
|
+
return Array.isArray(targets) && targets.length > 0 && targets.every((t) => isHTMLElement$2(t));
|
|
6068
6358
|
}
|
|
6069
6359
|
function isValidStringArray(arr, minLength = 1) {
|
|
6070
6360
|
return Array.isArray(arr) && arr.length >= minLength && arr.every((item) => typeof item === "string" && item.length > 0);
|
|
@@ -6356,7 +6646,7 @@ function isEmpty(value) {
|
|
|
6356
6646
|
function isPlainObject(value) {
|
|
6357
6647
|
if (typeof value !== "object" || value === null || Array.isArray(value))
|
|
6358
6648
|
return false;
|
|
6359
|
-
if (isHTMLElement(value) || value instanceof Node)
|
|
6649
|
+
if (isHTMLElement$2(value) || value instanceof Node)
|
|
6360
6650
|
return false;
|
|
6361
6651
|
const proto = Object.getPrototypeOf(value);
|
|
6362
6652
|
return proto === Object.prototype || proto === null;
|
|
@@ -6385,7 +6675,7 @@ async function resolvePropertyTargetFromNode(node, evaluator, context) {
|
|
|
6385
6675
|
let element = await evaluator.evaluate(node.target, context);
|
|
6386
6676
|
if (Array.isArray(element))
|
|
6387
6677
|
element = element[0];
|
|
6388
|
-
if (!isHTMLElement(element))
|
|
6678
|
+
if (!isHTMLElement$2(element))
|
|
6389
6679
|
return null;
|
|
6390
6680
|
return { element, property };
|
|
6391
6681
|
}
|
|
@@ -6396,7 +6686,7 @@ async function resolvePropertyTargetFromAccessNode(node, evaluator, context) {
|
|
|
6396
6686
|
let element = await evaluator.evaluate(node.object, context);
|
|
6397
6687
|
if (Array.isArray(element))
|
|
6398
6688
|
element = element[0];
|
|
6399
|
-
if (!isHTMLElement(element))
|
|
6689
|
+
if (!isHTMLElement$2(element))
|
|
6400
6690
|
return null;
|
|
6401
6691
|
return { element, property };
|
|
6402
6692
|
}
|
|
@@ -6425,7 +6715,7 @@ async function resolveAnyPropertyTarget(node, evaluator, context) {
|
|
|
6425
6715
|
let element = await evaluator.evaluate(objectNode, context);
|
|
6426
6716
|
if (Array.isArray(element))
|
|
6427
6717
|
element = element[0];
|
|
6428
|
-
if (!isHTMLElement(element))
|
|
6718
|
+
if (!isHTMLElement$2(element))
|
|
6429
6719
|
return null;
|
|
6430
6720
|
const propertyName = propertyNode?.name || propertyNode?.value;
|
|
6431
6721
|
if (!propertyName)
|
|
@@ -6525,7 +6815,7 @@ async function parseTemporalModifiers(modifiers, evaluator, context) {
|
|
|
6525
6815
|
function detectExpressionType(firstValue, firstArg) {
|
|
6526
6816
|
const firstArgName = firstArg?.name;
|
|
6527
6817
|
const isBareTag = isBareSmartElementNode(firstArg);
|
|
6528
|
-
if (isHTMLElement(firstValue) || Array.isArray(firstValue) && firstValue.every((el) => isHTMLElement(el))) {
|
|
6818
|
+
if (isHTMLElement$2(firstValue) || Array.isArray(firstValue) && firstValue.every((el) => isHTMLElement$2(el))) {
|
|
6529
6819
|
return { type: "element", expression: "" };
|
|
6530
6820
|
}
|
|
6531
6821
|
if (isBareTag && firstArgName) {
|
|
@@ -6545,210 +6835,6 @@ function detectExpressionType(firstValue, firstArg) {
|
|
|
6545
6835
|
}
|
|
6546
6836
|
return { type: "class", expression: "" };
|
|
6547
6837
|
}
|
|
6548
|
-
function convertToNumber(value) {
|
|
6549
|
-
if (value === null || value === void 0) {
|
|
6550
|
-
return 0;
|
|
6551
|
-
}
|
|
6552
|
-
if (typeof value === "number") {
|
|
6553
|
-
return isFinite(value) ? value : 0;
|
|
6554
|
-
}
|
|
6555
|
-
if (typeof value === "string") {
|
|
6556
|
-
const parsed = parseFloat(value);
|
|
6557
|
-
return parsed;
|
|
6558
|
-
}
|
|
6559
|
-
if (typeof value === "boolean") {
|
|
6560
|
-
return value ? 1 : 0;
|
|
6561
|
-
}
|
|
6562
|
-
if (Array.isArray(value)) {
|
|
6563
|
-
return value.length;
|
|
6564
|
-
}
|
|
6565
|
-
if (typeof value === "object") {
|
|
6566
|
-
if ("length" in value && typeof value.length === "number") {
|
|
6567
|
-
return value.length;
|
|
6568
|
-
}
|
|
6569
|
-
if (typeof value.valueOf === "function") {
|
|
6570
|
-
const result = value.valueOf();
|
|
6571
|
-
if (typeof result === "number") {
|
|
6572
|
-
return result;
|
|
6573
|
-
}
|
|
6574
|
-
}
|
|
6575
|
-
return NaN;
|
|
6576
|
-
}
|
|
6577
|
-
return 0;
|
|
6578
|
-
}
|
|
6579
|
-
function getVariableValue(name, context, preferredScope) {
|
|
6580
|
-
if (preferredScope === "global" && context.globals && context.globals.has(name)) {
|
|
6581
|
-
return context.globals.get(name);
|
|
6582
|
-
}
|
|
6583
|
-
if (preferredScope !== "global" && context.locals && context.locals.has(name)) {
|
|
6584
|
-
notifyLocalRead(name, context);
|
|
6585
|
-
return context.locals.get(name);
|
|
6586
|
-
}
|
|
6587
|
-
if (context.globals && context.globals.has(name)) {
|
|
6588
|
-
return context.globals.get(name);
|
|
6589
|
-
}
|
|
6590
|
-
if (context.variables && context.variables.has(name)) {
|
|
6591
|
-
return context.variables.get(name);
|
|
6592
|
-
}
|
|
6593
|
-
if (preferredScope === "global" && context.locals && context.locals.has(name)) {
|
|
6594
|
-
notifyLocalRead(name, context);
|
|
6595
|
-
return context.locals.get(name);
|
|
6596
|
-
}
|
|
6597
|
-
if (typeof window !== "undefined" && name in window) {
|
|
6598
|
-
return window[name];
|
|
6599
|
-
}
|
|
6600
|
-
if (typeof globalThis !== "undefined" && name in globalThis) {
|
|
6601
|
-
return globalThis[name];
|
|
6602
|
-
}
|
|
6603
|
-
return void 0;
|
|
6604
|
-
}
|
|
6605
|
-
function setVariableValue(name, value, context, preferredScope) {
|
|
6606
|
-
if (preferredScope === "global") {
|
|
6607
|
-
setGlobal(context, name, value);
|
|
6608
|
-
if (typeof window !== "undefined") {
|
|
6609
|
-
window[name] = value;
|
|
6610
|
-
}
|
|
6611
|
-
return;
|
|
6612
|
-
}
|
|
6613
|
-
if (name.startsWith("$")) {
|
|
6614
|
-
const bare = name.slice(1);
|
|
6615
|
-
setGlobal(context, bare, value);
|
|
6616
|
-
return;
|
|
6617
|
-
}
|
|
6618
|
-
if (context.locals && context.locals.has(name)) {
|
|
6619
|
-
context.locals.set(name, value);
|
|
6620
|
-
notifyLocalWrite(name, value, context);
|
|
6621
|
-
return;
|
|
6622
|
-
}
|
|
6623
|
-
if (context.globals && context.globals.has(name)) {
|
|
6624
|
-
setGlobal(context, name, value);
|
|
6625
|
-
if (typeof window !== "undefined" && name in window) {
|
|
6626
|
-
window[name] = value;
|
|
6627
|
-
}
|
|
6628
|
-
return;
|
|
6629
|
-
}
|
|
6630
|
-
if (context.variables && context.variables.has(name)) {
|
|
6631
|
-
context.variables.set(name, value);
|
|
6632
|
-
return;
|
|
6633
|
-
}
|
|
6634
|
-
if (typeof window !== "undefined" && name in window) {
|
|
6635
|
-
window[name] = value;
|
|
6636
|
-
setGlobal(context, name, value);
|
|
6637
|
-
return;
|
|
6638
|
-
}
|
|
6639
|
-
context.locals.set(name, value);
|
|
6640
|
-
notifyLocalWrite(name, value, context);
|
|
6641
|
-
}
|
|
6642
|
-
function resolveElementRef(elementRef, context) {
|
|
6643
|
-
if (elementRef === "me") {
|
|
6644
|
-
return context.me;
|
|
6645
|
-
} else if (elementRef === "it") {
|
|
6646
|
-
return context.it;
|
|
6647
|
-
} else if (elementRef === "you") {
|
|
6648
|
-
return context.you;
|
|
6649
|
-
} else {
|
|
6650
|
-
return getVariableValue(elementRef, context);
|
|
6651
|
-
}
|
|
6652
|
-
}
|
|
6653
|
-
function getElementPropertyValue(propertyPath, context) {
|
|
6654
|
-
const parts = propertyPath.split(".");
|
|
6655
|
-
const elementRef = parts[0];
|
|
6656
|
-
const property = parts[1];
|
|
6657
|
-
const element = resolveElementRef(elementRef, context);
|
|
6658
|
-
if (!element) {
|
|
6659
|
-
return 0;
|
|
6660
|
-
}
|
|
6661
|
-
const value = element[property];
|
|
6662
|
-
return convertToNumber(value);
|
|
6663
|
-
}
|
|
6664
|
-
function setElementPropertyValue(propertyPath, value, context) {
|
|
6665
|
-
const parts = propertyPath.split(".");
|
|
6666
|
-
const elementRef = parts[0];
|
|
6667
|
-
const property = parts[1];
|
|
6668
|
-
const element = resolveElementRef(elementRef, context);
|
|
6669
|
-
if (element) {
|
|
6670
|
-
element[property] = value;
|
|
6671
|
-
}
|
|
6672
|
-
}
|
|
6673
|
-
function getCurrentNumericValue(target, property, scope, context) {
|
|
6674
|
-
if (typeof target === "number") {
|
|
6675
|
-
return target;
|
|
6676
|
-
}
|
|
6677
|
-
if (isHTMLElement(target)) {
|
|
6678
|
-
const element = target;
|
|
6679
|
-
if (property) {
|
|
6680
|
-
if (property.startsWith("data-") || ["id", "class", "title", "alt", "src", "href"].includes(property)) {
|
|
6681
|
-
const value = element.getAttribute(property);
|
|
6682
|
-
return convertToNumber(value);
|
|
6683
|
-
} else {
|
|
6684
|
-
const value = element[property];
|
|
6685
|
-
return convertToNumber(value);
|
|
6686
|
-
}
|
|
6687
|
-
} else {
|
|
6688
|
-
const value = element.value || element.textContent;
|
|
6689
|
-
return convertToNumber(value);
|
|
6690
|
-
}
|
|
6691
|
-
}
|
|
6692
|
-
if (typeof target === "string") {
|
|
6693
|
-
if (scope === "global") {
|
|
6694
|
-
const value2 = getVariableValue(target, context, "global");
|
|
6695
|
-
return convertToNumber(value2);
|
|
6696
|
-
}
|
|
6697
|
-
if (target.includes(".")) {
|
|
6698
|
-
return getElementPropertyValue(target, context);
|
|
6699
|
-
}
|
|
6700
|
-
if (target === "me" && context.me) {
|
|
6701
|
-
return convertToNumber(context.me.value || 0);
|
|
6702
|
-
} else if (target === "it") {
|
|
6703
|
-
return convertToNumber(context.it || 0);
|
|
6704
|
-
} else if (target === "you" && context.you) {
|
|
6705
|
-
return convertToNumber(context.you.value || 0);
|
|
6706
|
-
}
|
|
6707
|
-
const value = getVariableValue(target, context);
|
|
6708
|
-
return convertToNumber(value);
|
|
6709
|
-
}
|
|
6710
|
-
return convertToNumber(target);
|
|
6711
|
-
}
|
|
6712
|
-
function setTargetValue(target, property, scope, newValue, context) {
|
|
6713
|
-
if (isHTMLElement(target)) {
|
|
6714
|
-
const element = target;
|
|
6715
|
-
if (property) {
|
|
6716
|
-
if (property.startsWith("data-") || ["id", "class", "title", "alt", "src", "href"].includes(property)) {
|
|
6717
|
-
element.setAttribute(property, String(newValue));
|
|
6718
|
-
} else {
|
|
6719
|
-
element[property] = newValue;
|
|
6720
|
-
}
|
|
6721
|
-
} else {
|
|
6722
|
-
if ("value" in element && element.value !== void 0) {
|
|
6723
|
-
element.value = String(newValue);
|
|
6724
|
-
} else {
|
|
6725
|
-
element.textContent = String(newValue);
|
|
6726
|
-
}
|
|
6727
|
-
}
|
|
6728
|
-
return;
|
|
6729
|
-
}
|
|
6730
|
-
if (typeof target === "string") {
|
|
6731
|
-
if (scope === "global") {
|
|
6732
|
-
setVariableValue(target, newValue, context, "global");
|
|
6733
|
-
return;
|
|
6734
|
-
}
|
|
6735
|
-
if (target.includes(".")) {
|
|
6736
|
-
setElementPropertyValue(target, newValue, context);
|
|
6737
|
-
return;
|
|
6738
|
-
}
|
|
6739
|
-
if (target === "me" && context.me) {
|
|
6740
|
-
context.me.value = newValue;
|
|
6741
|
-
return;
|
|
6742
|
-
} else if (target === "it") {
|
|
6743
|
-
Object.assign(context, { it: newValue });
|
|
6744
|
-
return;
|
|
6745
|
-
} else if (target === "you" && context.you) {
|
|
6746
|
-
context.you.value = newValue;
|
|
6747
|
-
return;
|
|
6748
|
-
}
|
|
6749
|
-
setVariableValue(target, newValue, context);
|
|
6750
|
-
}
|
|
6751
|
-
}
|
|
6752
6838
|
function escapeHtml(value) {
|
|
6753
6839
|
return value.replace(/[&<>"']/g, (c) => HTML_ESCAPE[c]);
|
|
6754
6840
|
}
|
|
@@ -6803,15 +6889,15 @@ function createElementFromHTML(html) {
|
|
|
6803
6889
|
const template = document.createElement("template");
|
|
6804
6890
|
template.innerHTML = html.trim();
|
|
6805
6891
|
const fromTemplate = template.content.firstElementChild;
|
|
6806
|
-
if (fromTemplate && isHTMLElement(fromTemplate))
|
|
6892
|
+
if (fromTemplate && isHTMLElement$2(fromTemplate))
|
|
6807
6893
|
return fromTemplate;
|
|
6808
6894
|
const wrapper = document.createElement("div");
|
|
6809
6895
|
wrapper.innerHTML = html.trim();
|
|
6810
6896
|
const child = wrapper.firstElementChild;
|
|
6811
|
-
return child && isHTMLElement(child) ? child : wrapper;
|
|
6897
|
+
return child && isHTMLElement$2(child) ? child : wrapper;
|
|
6812
6898
|
}
|
|
6813
6899
|
function createClassInstance(className, args, context) {
|
|
6814
|
-
if (isHTMLElement(className))
|
|
6900
|
+
if (isHTMLElement$2(className))
|
|
6815
6901
|
return className;
|
|
6816
6902
|
const name = String(className);
|
|
6817
6903
|
let Constructor;
|
|
@@ -7054,8 +7140,8 @@ function withViewTransition(callback, options) {
|
|
|
7054
7140
|
});
|
|
7055
7141
|
}
|
|
7056
7142
|
function executeSwap(target, content, strategy, morphOptions) {
|
|
7057
|
-
const contentStr = content !== null && !isHTMLElement(content) ? content : "";
|
|
7058
|
-
const contentEl = isHTMLElement(content) ? content : null;
|
|
7143
|
+
const contentStr = content !== null && !isHTMLElement$2(content) ? content : "";
|
|
7144
|
+
const contentEl = isHTMLElement$2(content) ? content : null;
|
|
7059
7145
|
switch (strategy) {
|
|
7060
7146
|
case "morph":
|
|
7061
7147
|
if (content !== null) {
|
|
@@ -7155,7 +7241,7 @@ function extractContent(value) {
|
|
|
7155
7241
|
if (value === null || value === void 0) {
|
|
7156
7242
|
return null;
|
|
7157
7243
|
}
|
|
7158
|
-
if (isHTMLElement(value)) {
|
|
7244
|
+
if (isHTMLElement$2(value)) {
|
|
7159
7245
|
return value;
|
|
7160
7246
|
}
|
|
7161
7247
|
if (isDocumentFragment(value)) {
|
|
@@ -7586,7 +7672,7 @@ function extractPartials(html) {
|
|
|
7586
7672
|
function executePartialSwap(partial, morphOptions) {
|
|
7587
7673
|
const { target, strategy, content } = partial;
|
|
7588
7674
|
const targetElement = document.querySelector(target);
|
|
7589
|
-
if (!targetElement || !isHTMLElement(targetElement)) {
|
|
7675
|
+
if (!targetElement || !isHTMLElement$2(targetElement)) {
|
|
7590
7676
|
return { success: false, error: `Target "${target}" not found` };
|
|
7591
7677
|
}
|
|
7592
7678
|
try {
|
|
@@ -11748,20 +11834,6 @@ function withDefaultExtractors(tokenizer) {
|
|
|
11748
11834
|
tokenizer.registerExtractors(getDefaultExtractors$1());
|
|
11749
11835
|
return tokenizer;
|
|
11750
11836
|
}
|
|
11751
|
-
function createUnicodeRangeClassifier(ranges) {
|
|
11752
|
-
return (char) => {
|
|
11753
|
-
const code = char.charCodeAt(0);
|
|
11754
|
-
return ranges.some(([start, end]) => code >= start && code <= end);
|
|
11755
|
-
};
|
|
11756
|
-
}
|
|
11757
|
-
function combineClassifiers(...classifiers) {
|
|
11758
|
-
return (char) => classifiers.some((fn) => fn(char));
|
|
11759
|
-
}
|
|
11760
|
-
function createLatinCharClassifiers(letterPattern) {
|
|
11761
|
-
const isLetter = (char) => letterPattern.test(char);
|
|
11762
|
-
const isIdentifierChar = (char) => isLetter(char) || /[0-9_-]/.test(char);
|
|
11763
|
-
return { isLetter, isIdentifierChar };
|
|
11764
|
-
}
|
|
11765
11837
|
function createSimpleTokenizer(config2) {
|
|
11766
11838
|
const {
|
|
11767
11839
|
language,
|
|
@@ -11799,6 +11871,115 @@ function createSimpleTokenizer(config2) {
|
|
|
11799
11871
|
}
|
|
11800
11872
|
return new SimpleTokenizer();
|
|
11801
11873
|
}
|
|
11874
|
+
function mergeRoleMarkers(slice, vocab) {
|
|
11875
|
+
const merged = {};
|
|
11876
|
+
const add = (role, marker) => {
|
|
11877
|
+
if (!marker?.primary) {
|
|
11878
|
+
delete merged[role];
|
|
11879
|
+
return;
|
|
11880
|
+
}
|
|
11881
|
+
merged[role] = {
|
|
11882
|
+
primary: marker.primary,
|
|
11883
|
+
...marker.alternatives?.length && { alternatives: [...marker.alternatives] },
|
|
11884
|
+
...marker.position && { position: marker.position }
|
|
11885
|
+
};
|
|
11886
|
+
};
|
|
11887
|
+
for (const [role, marker] of Object.entries(slice.roleMarkers ?? {})) add(role, marker);
|
|
11888
|
+
for (const [role, marker] of Object.entries(vocab.roleMarkerOverrides ?? {})) add(role, marker);
|
|
11889
|
+
return merged;
|
|
11890
|
+
}
|
|
11891
|
+
function buildPatternProfile(slice, vocab) {
|
|
11892
|
+
const keywords = {};
|
|
11893
|
+
for (const [action, translation] of Object.entries(vocab.keywords)) {
|
|
11894
|
+
keywords[action] = {
|
|
11895
|
+
primary: translation.primary,
|
|
11896
|
+
...translation.alternatives?.length && { alternatives: [...translation.alternatives] }
|
|
11897
|
+
};
|
|
11898
|
+
}
|
|
11899
|
+
const roleMarkers = mergeRoleMarkers(slice, vocab);
|
|
11900
|
+
return {
|
|
11901
|
+
code: slice.code,
|
|
11902
|
+
wordOrder: slice.wordOrder,
|
|
11903
|
+
keywords,
|
|
11904
|
+
...Object.keys(roleMarkers).length > 0 && { roleMarkers }
|
|
11905
|
+
};
|
|
11906
|
+
}
|
|
11907
|
+
function defaultCaseInsensitive(script) {
|
|
11908
|
+
return script === void 0 || script === "latin" || script === "cyrillic";
|
|
11909
|
+
}
|
|
11910
|
+
function buildDomainTokenizer(slice, vocab, options = {}) {
|
|
11911
|
+
const roleMarkers = mergeRoleMarkers(slice, vocab);
|
|
11912
|
+
const keywords = /* @__PURE__ */ new Set();
|
|
11913
|
+
for (const translation of Object.values(vocab.keywords)) {
|
|
11914
|
+
keywords.add(translation.primary);
|
|
11915
|
+
for (const alt of translation.alternatives ?? []) keywords.add(alt);
|
|
11916
|
+
}
|
|
11917
|
+
for (const marker of Object.values(roleMarkers)) {
|
|
11918
|
+
keywords.add(marker.primary);
|
|
11919
|
+
for (const alt of marker.alternatives ?? []) keywords.add(alt);
|
|
11920
|
+
}
|
|
11921
|
+
for (const particle of slice.tokenization?.particles ?? []) keywords.add(particle);
|
|
11922
|
+
for (const extra of vocab.tokenizerKeywords ?? []) keywords.add(extra);
|
|
11923
|
+
const profileKeywords = {};
|
|
11924
|
+
for (const [action, translation] of Object.entries(vocab.keywords)) {
|
|
11925
|
+
profileKeywords[action] = {
|
|
11926
|
+
primary: translation.primary,
|
|
11927
|
+
...translation.alternatives?.length && { alternatives: [...translation.alternatives] },
|
|
11928
|
+
normalized: translation.normalized ?? action
|
|
11929
|
+
};
|
|
11930
|
+
}
|
|
11931
|
+
const keywordProfile = {
|
|
11932
|
+
keywords: profileKeywords,
|
|
11933
|
+
...Object.keys(roleMarkers).length > 0 && { roleMarkers }
|
|
11934
|
+
};
|
|
11935
|
+
const customExtractors = [
|
|
11936
|
+
...options.customExtractors ?? [],
|
|
11937
|
+
...slice.script === "latin" ? [new LatinExtendedIdentifierExtractor()] : []
|
|
11938
|
+
];
|
|
11939
|
+
return createSimpleTokenizer({
|
|
11940
|
+
language: slice.code,
|
|
11941
|
+
direction: slice.direction ?? "ltr",
|
|
11942
|
+
keywords: [...keywords],
|
|
11943
|
+
...vocab.keywordExtras?.length && { keywordExtras: vocab.keywordExtras.map((e) => ({ ...e })) },
|
|
11944
|
+
keywordProfile,
|
|
11945
|
+
includeOperators: options.includeOperators ?? false,
|
|
11946
|
+
caseInsensitive: options.caseInsensitive ?? defaultCaseInsensitive(slice.script),
|
|
11947
|
+
...customExtractors.length > 0 && { customExtractors }
|
|
11948
|
+
});
|
|
11949
|
+
}
|
|
11950
|
+
function buildLanguageConfig(slice, vocab, meta2 = {}) {
|
|
11951
|
+
const name = meta2.name ?? slice.name ?? slice.code;
|
|
11952
|
+
return {
|
|
11953
|
+
code: slice.code,
|
|
11954
|
+
name,
|
|
11955
|
+
nativeName: meta2.nativeName ?? slice.nativeName ?? name,
|
|
11956
|
+
tokenizer: meta2.tokenizer ?? buildDomainTokenizer(slice, vocab, meta2.tokenizerOptions),
|
|
11957
|
+
patternProfile: buildPatternProfile(slice, vocab),
|
|
11958
|
+
...meta2.grammarProfile && { grammarProfile: meta2.grammarProfile }
|
|
11959
|
+
};
|
|
11960
|
+
}
|
|
11961
|
+
function deriveRoleMarkers(slice, roleMapping) {
|
|
11962
|
+
const derived = {};
|
|
11963
|
+
for (const [domainRole, semanticRole] of Object.entries(roleMapping)) {
|
|
11964
|
+
const marker = slice.roleMarkers?.[semanticRole];
|
|
11965
|
+
if (marker?.primary) derived[domainRole] = marker.primary;
|
|
11966
|
+
}
|
|
11967
|
+
return derived;
|
|
11968
|
+
}
|
|
11969
|
+
function createUnicodeRangeClassifier(ranges) {
|
|
11970
|
+
return (char) => {
|
|
11971
|
+
const code = char.charCodeAt(0);
|
|
11972
|
+
return ranges.some(([start, end]) => code >= start && code <= end);
|
|
11973
|
+
};
|
|
11974
|
+
}
|
|
11975
|
+
function combineClassifiers(...classifiers) {
|
|
11976
|
+
return (char) => classifiers.some((fn) => fn(char));
|
|
11977
|
+
}
|
|
11978
|
+
function createLatinCharClassifiers(letterPattern) {
|
|
11979
|
+
const isLetter = (char) => letterPattern.test(char);
|
|
11980
|
+
const isIdentifierChar = (char) => isLetter(char) || /[0-9_-]/.test(char);
|
|
11981
|
+
return { isLetter, isIdentifierChar };
|
|
11982
|
+
}
|
|
11802
11983
|
function noChange(word) {
|
|
11803
11984
|
return { stem: word, confidence: 1 };
|
|
11804
11985
|
}
|
|
@@ -24795,6 +24976,19 @@ function getPatternStats() {
|
|
|
24795
24976
|
function patternGeneratorForProfile(profile) {
|
|
24796
24977
|
return buildPatternsForLanguage(profile.code);
|
|
24797
24978
|
}
|
|
24979
|
+
function getKeywordTranslations(keyword, languages) {
|
|
24980
|
+
const codes = languages ?? Object.keys(KNOWN_PROFILES);
|
|
24981
|
+
const translations = {};
|
|
24982
|
+
for (const code of codes) {
|
|
24983
|
+
const translation = KNOWN_PROFILES[code]?.keywords[keyword];
|
|
24984
|
+
if (translation) translations[code] = translation;
|
|
24985
|
+
}
|
|
24986
|
+
return translations;
|
|
24987
|
+
}
|
|
24988
|
+
function getRoleMarkers(language, role) {
|
|
24989
|
+
const markers = KNOWN_PROFILES[language]?.roleMarkers ?? {};
|
|
24990
|
+
return role ? markers[role] : markers;
|
|
24991
|
+
}
|
|
24798
24992
|
function getSchema2(action) {
|
|
24799
24993
|
return schemaRegistry.get(action);
|
|
24800
24994
|
}
|
|
@@ -25540,9 +25734,9 @@ function createHistorySwap(config2) {
|
|
|
25540
25734
|
const resolveTarget3 = () => {
|
|
25541
25735
|
if (typeof target === "string") {
|
|
25542
25736
|
const element = document.querySelector(target);
|
|
25543
|
-
return isHTMLElement(element) ? element : null;
|
|
25737
|
+
return isHTMLElement$2(element) ? element : null;
|
|
25544
25738
|
}
|
|
25545
|
-
return isHTMLElement(target) ? target : null;
|
|
25739
|
+
return isHTMLElement$2(target) ? target : null;
|
|
25546
25740
|
};
|
|
25547
25741
|
const handlePopstate = async (_event) => {
|
|
25548
25742
|
const targetElement = resolveTarget3();
|
|
@@ -25639,9 +25833,9 @@ function createBoosted(config2) {
|
|
|
25639
25833
|
}
|
|
25640
25834
|
if (typeof target === "string") {
|
|
25641
25835
|
const element = document.querySelector(target);
|
|
25642
|
-
return isHTMLElement(element) ? element : null;
|
|
25836
|
+
return isHTMLElement$2(element) ? element : null;
|
|
25643
25837
|
}
|
|
25644
|
-
return isHTMLElement(target) ? target : null;
|
|
25838
|
+
return isHTMLElement$2(target) ? target : null;
|
|
25645
25839
|
};
|
|
25646
25840
|
const boost = async (url, method = "GET", body = null) => {
|
|
25647
25841
|
const targetElement = resolveTarget3();
|
|
@@ -27237,7 +27431,7 @@ async function semanticNodeToRuntimeAST(node) {
|
|
|
27237
27431
|
const fw = await getFramework();
|
|
27238
27432
|
return fw.semanticNodeToRuntimeAST(node);
|
|
27239
27433
|
}
|
|
27240
|
-
var KEYWORDS$1, COMMAND_TERMINATORS, COMMANDS, COMPOUND_COMMANDS, CONTROL_FLOW_COMMANDS, PUT_OPERATIONS, PUT_OPERATION_KEYWORDS, HYPERSCRIPT_KEYWORDS, CommandClassification, CSS_FUNCTIONS, CONTEXT_VARS$1, LOGICAL_OPERATORS$1, COMPARISON_OPERATORS, DOM_EVENTS, TOKENIZER_KEYWORDS, TokenKind, MATHEMATICAL_OPERATORS, TIME_UNITS$1, isDebugEnabled$1, DEBUG, debug, debugEnabled, debugEventTarget, stats, DEFAULT_CONFIDENCE_THRESHOLD$1, SemanticIntegrationAdapter, STOP_TOKENS, STOP_DELIMITERS, CORE_FRAGMENT, PARSER_COMPARISON_FRAGMENT, ASSIGNMENT_FRAGMENT, PARSER_TABLE, FEATURE_REGISTRY, NODE_EVALUATORS, NODE_WRITERS, GLOBAL_WRITE_HOOKS, GLOBAL_READ_HOOKS, LOCAL_WRITE_HOOKS, LOCAL_READ_HOOKS, ParserExtensionRegistry, SINGLETON, WINDOW_KEY, MULTI_WORD_PATTERNS, DEFAULT_BOUNDARY_KEYWORDS, CommandNodeBuilder, SWAP_STRATEGY_KEYWORDS, STRING_POSTFIX_UNITS, STRING_POSTFIX_BP, Parser, HookRegistry, ExpressionTypeRegistry, expressionTypeRegistry, BOOLEAN_ATTRIBUTES, SPECIAL_DOM_PROPERTIES, NUMBER_WORDS, isProduction, skipValidation, addDescribeToValidator, v, z, BaseExpressionImpl, enhancedConverters, AsExpressionInputSchema, AsExpression, IsExpressionInputSchema, IsExpression, conversionConfig, defaultConversions, TYPE_ALIASES, asExpression, isExpression, asyncExpression, conversionExpressions, UNSAFE_PROPS, possessiveExpression, myExpression, itsExpression$1, yourExpression, ofExpression, attributeExpression, attributeWithValueExpression, classReferenceExpression, idReferenceExpression, propertiesExpressions, NotSyncEvaluable, cachedFullRegistry, RAW_ARG_BUILTINS, CSS_PSEUDO_CLASSES, PSEUDO_CLASS_COLON_RE, BARE_REF_ESCAPE_RE, QUERY_REF_INTERP_RE, CleanupRegistry, sharedGlobals, EventSourceRegistry, ContextProviderRegistry, canonicalEvaluator, ContextBridge, CommandAdapterV2, CommandRegistryV2, defaultRegistry, RegistryIntegration, eventRecursionDepth, RuntimeBase, MeExpression, YouExpression, ItExpression, CSSelectorInputSchema, CSSSelectorExpression, meExpression, youExpression, itExpression, itsExpression, resultExpression, querySelectorExpression, querySelectorAllExpression, idExpression, classExpression, closestExpression, parentExpression, windowExpression, documentExpression, elementWithSelectorExpression, styleRefExpression, possessiveStyleRefExpression, ofStyleRefExpression, referencesExpressions, LRUCache, HyperscriptCache, globalCache, PerformanceTracker, performanceTracker, cleanupInterval, BinaryLogicalInputSchema, UnaryLogicalInputSchema, AndExpression, OrExpression, NotExpression, ComparisonInputSchema, PatternMatchingInputSchema, equalsExpression, strictEqualsExpression, notEqualsExpression, strictNotEqualsExpression, lessThanExpression, lessThanOrEqualExpression, greaterThanExpression, greaterThanOrEqualExpression, andExpression, orExpression, notExpression, isEmptyExpression, noExpression, isNotEmptyExpression, existsExpression, doesNotExistExpression, containsExpression, doesNotContainExpression, startsWithExpression, endsWithExpression, betweenExpression, matchesExpression, hasExpression, doesNotHaveExpression, logicalExpressions, StringLiteralInputSchema, NumberLiteralInputSchema, BooleanLiteralInputSchema, BinaryOperationInputSchema, StringLiteralExpression, NumberLiteralExpression, BooleanLiteralExpression, AdditionExpression$1, StringConcatenationExpression, MultiplicationExpression$1, specialExpressions, evaluationToHyperScriptType, CollectionInputSchema, IndexInputSchema, RandomInputSchema, FirstExpression, LastExpression, AtExpression, RandomExpression, firstExpression, lastExpression, atExpression, nextExpression, previousExpression, DOCUMENT_POSITION_PRECEDING, DOCUMENT_POSITION_FOLLOWING, nextWithinExpression, previousWithinExpression, positionalExpressions, AdditionExpression2, SubtractionExpression, MultiplicationExpression2, DivisionExpression, ModuloExpression, PowerExpression, mathematicalExpressions, index$3, COMMAND_NAME, COMMAND_CATEGORY, COMMAND_METADATA, KEYWORD_PREPOSITIONS, VisibilityCommandBase, HideCommand, createHideCommand, ShowCommand, createShowCommand, SMART_ELEMENT_TAGS, DOMModificationBase, AddCommand, createAddCommand, RemoveCommand, createRemoveCommand, PATTERN, BOOL_PROPS, ToggleCommand, createToggleCommand, PutCommand, createPutCommand, HTML_ESCAPE, MakeCommand, createMakeCommand, EmptyCommand, createEmptyCommand, OpenCommand, createOpenCommand, CloseCommand, createCloseCommand, SelectCommand, createSelectCommand, ResetCommand, createResetCommand, SUPPORTS_MOVE_BEFORE, ELEMENT_NODE_TYPE, TEXT_NODE_TYPE, IS_PARENT_NODE_TYPE, Operation, candidateNodes, candidateElements, candidateElementsWithIds, unmatchedNodes, unmatchedElements, whitespaceNodes, _idArrayMap, _idSetMap, _options, _Morph_instances, morphOneToMany_fn, morphOneToOne_fn, morphMatchingElements_fn, morphNonMatchingElements_fn, morphOtherNode_fn, visitAttributes_fn, visitTextArea_fn, replaceNode_fn, removeNode_fn, mapIdArraysForEach_fn, mapIdArrays_fn, mapIdSets_fn, Morph, morphAdapter, queue, processing, STRATEGY_KEYWORDS, SwapCommand, MorphCommand, createSwapCommand, createMorphCommand, CRITICAL_LAYOUT_ELEMENTS, STRUCTURAL_SEMANTIC_ELEMENTS, WARNING_ELEMENTS, DEFAULT_VALIDATION_CONFIG, globalConfig, STYLES, SEVERITY_ICONS, SEVERITY_LABELS, STRATEGY_MAP, ProcessPartialsCommand, createProcessPartialsCommand, WaitCommand, createWaitCommand, customResponseTypes, DEFAULT_FETCH_THROWS_ON, fetchThrowsOnPatterns, FetchCommand, createFetchCommand, SetCommand, createSetCommand, GetCommand, createGetCommand, NumericModifyCommand, createIncrementCommand, createDecrementCommand, ClearCommand, createClearCommand, LogCommand, createLogCommand, EventDispatchCommand, createTriggerCommand, createSendCommand, GoCommand, createGoCommand, KEYWORDS, HistoryCommand, createPushUrlCommand, createReplaceUrlCommand, ScrollCommand, createScrollCommand, ConditionalCommand, createConditionalCommand, createIfCommand, createUnlessCommand, RepeatCommand, createRepeatCommand, ControlFlowSignalBase, BreakCommand, createBreakCommand, ContinueCommand, createContinueCommand, HaltCommand, createHaltCommand, ReturnCommand, createReturnCommand, ExitCommand, createExitCommand, CallCommand, createCallCommand, FocusCommand, createFocusCommand, BlurCommand, createBlurCommand, AppendCommand, createAppendCommand, TransitionCommand, createTransitionCommand, MeasureCommand, createMeasureCommand, SettleCommand, createSettleCommand, StartViewTransitionCommand, createStartViewTransitionCommand, JsCommand, createJsCommand, AsyncCommand, createAsyncCommand, DefaultCommand, createDefaultCommand, PseudoCommand, TellCommand, createTellCommand, CopyCommand, createCopyCommand, PickCommand, createPickCommand, ThrowCommand, createThrowCommand, BeepCommand, createBeepCommand, BreakpointCommand, createBreakpointCommand, InstallCommand, TakeCommand, createTakeCommand, RenderCommand, Runtime, DEFAULT_REFERENCES, STRUCTURAL_ROLES, CHAIN_KEYWORDS, VERSION_HEADER_RE, VALID_KINDS, VALID_VALUE_TYPES$1, VALID_CHAIN_TYPES, VALID_ASYNC_VARIANTS, VALID_DIAGNOSTIC_LEVELS, DebugLogger, _PatternMatcher$1, PatternMatcher$1, patternMatcher$1, defaultConfig$1, GrammarTransformer, InMemoryDictionary, NullDictionary, InMemoryProfileProvider, NullProfileProvider, StringLiteralExtractor, NumberExtractor, IdentifierExtractor, UnicodeIdentifierExtractor, LatinExtendedIdentifierExtractor, WhitespaceExtractor, VALID_VALUE_TYPES, SCROLL_MARKERS, URL_MARKERS, PARTIALS_IN_MARKERS, DSLRegistry, MultilingualDSLImpl, DomainRegistry, COMMENT_PATTERN, CrossDomainDispatcher, DomainAwareScanner, AOTOrchestrator, TokenStreamImpl, DEFAULT_OPERATORS$1, OperatorExtractor$1, DEFAULT_PUNCTUATION$1, PunctuationExtractor$1, SIMPLE_TOKENIZER_OPERATOR_SET, MARKER_CONCEPT_NORMALIZEDS, ENGLISH_DOM_EVENT_NAMES, _BaseTokenizer, BaseTokenizer, BaseMorphologicalNormalizer, PatternTracker, MultiStatementParserImpl, index$2, __defProp2, __getOwnPropNames2, __esm2, __export2, tokenizers, profiles, patternCache, patternGenerator, registeredPatterns, init_registry, arabic_exports, arabicProfile, init_arabic, bengali_exports, bengaliProfile, init_bengali, german_exports, germanProfile, init_german, english_exports, englishProfile, init_english, spanish_exports, spanishProfile, init_spanish, french_exports, frenchProfile, init_french, he_exports, hebrewProfile, init_he, hindi_exports, hindiProfile, init_hindi, indonesian_exports, indonesianProfile, init_indonesian, italian_exports, italianProfile, init_italian, japanese_exports, japaneseProfile, init_japanese, korean_exports, koreanProfile, init_korean, ms_exports, malayProfile, init_ms, polish_exports, polishProfile, init_polish, portuguese_exports, portugueseProfile, init_portuguese, quechua_exports, quechuaProfile, init_quechua, russian_exports, russianProfile, init_russian, swahili_exports, swahiliProfile, init_swahili, thai_exports, thaiProfile, init_thai, tl_exports, tagalogProfile, init_tl, turkish_exports, turkishProfile, init_turkish, ukrainian_exports, ukrainianProfile, init_ukrainian, vietnamese_exports, vietnameseProfile, init_vietnamese, chinese_exports, chineseProfile, init_chinese, SchemaErrorCodes, SchemaErrorMessages, SchemaErrorSuggestions, init_schema_error_codes, schema_validator_exports, MULTI_TYPE_PATIENT_COMMANDS, NO_REQUIRED_ROLES_COMMANDS, init_schema_validator, toggleSchema, addSchema, removeSchema, putSchema, setSchema, bindSchema, liveSchema, eventsourceSchema, socketSchema, workerSchema, interceptSchema, showSchema, hideSchema, onSchema, triggerSchema, waitSchema, fetchSchema, incrementSchema, decrementSchema, appendSchema, prependSchema, logSchema, getCommandSchema, takeSchema, makeSchema, haltSchema, settleSchema, throwSchema, sendSchema, ifSchema, unlessSchema, elseSchema, repeatSchema, forSchema, whileSchema, continueSchema, goSchema, transitionSchema, cloneSchema, focusSchema, blurSchema, emptySchema, openSchema, closeSchema, selectSchema, clearSchema, resetSchema, breakpointSchema, callSchema, returnSchema, jsSchema, asyncSchema, tellSchema, defaultSchema, initSchema, behaviorSchema, installSchema, measureSchema, swapSchema, morphSchema, beepSchema, breakSchema, copySchema, exitSchema, pickSchema, scrollSchema, URL_MARKER_ALL_LANGS, PARTIALS_IN_MARKER_ALL_LANGS, pushSchema, replaceSchema, processSchema, renderSchema, commandSchemas, init_command_schemas, PUT_POSITIONAL, PUT_AT_END, init_put, init_token_utils, init_char_classifiers, init_base_tokenizer, init_base, DEFAULT_OPERATORS, OperatorExtractor2, DEFAULT_PUNCTUATION, PunctuationExtractor2, init_generic_extractors, CssSelectorExtractor, init_css_selector, EventModifierExtractor, init_event_modifier, UrlExtractor, init_url, VariableRefExtractor, init_variable_ref, JapaneseKeywordExtractor, init_japanese_keyword, SINGLE_CHAR_PARTICLES, MULTI_CHAR_PARTICLES, JapaneseParticleExtractor, init_japanese_particle, TEMPORAL_EVENT_SUFFIXES, KoreanKeywordExtractor, init_korean_keyword, SINGLE_CHAR_PARTICLES2, MULTI_CHAR_PARTICLES2, KoreanParticleExtractor, init_korean_particle, ChineseKeywordExtractor, init_chinese_keyword, SINGLE_CHAR_PARTICLES3, MULTI_CHAR_PARTICLES3, ChineseParticleExtractor, init_chinese_particle, isVietnameseLetter, isVietnameseIdentifierChar, PREPOSITIONS, VietnameseKeywordExtractor, init_vietnamese_keyword, isArabic, PREPOSITIONS2, ArabicKeywordExtractor, init_arabic_keyword, isArabic2, PROCLITICS, NON_PROCLITIC_WORDS, ArabicProcliticExtractor, init_arabic_proclitic, isArabic3, TEMPORAL_MARKERS, ArabicTemporalExtractor, init_arabic_temporal, CyrillicKeywordExtractor, RUSSIAN_PREPOSITIONS, UKRAINIAN_PREPOSITIONS, init_cyrillic_keyword, HindiKeywordExtractor, init_hindi_keyword, SINGLE_POSTPOSITIONS, COMPOUND_POSTPOSITIONS, HindiParticleExtractor, init_hindi_particle, BengaliKeywordExtractor, init_bengali_keyword, SINGLE_POSTPOSITIONS2, BengaliParticleExtractor, init_bengali_particle, ThaiKeywordExtractor, init_thai_keyword, MalayKeywordExtractor, init_malay_keyword, PREPOSITIONS3, TagalogKeywordExtractor, init_tagalog_keyword, PREPOSITIONS4, isPolishLetter, isPolishIdentifierChar, PolishKeywordExtractor, init_polish_keyword, PREPOSITIONS5, isIndonesianLetter, isIndonesianIdentifierChar, IndonesianKeywordExtractor, init_indonesian_keyword, PREPOSITIONS6, isSwahiliLetter, isSwahiliIdentifierChar, SwahiliKeywordExtractor, init_swahili_keyword, POSTPOSITIONS, CASE_SUFFIXES, TurkishKeywordExtractor, init_turkish_keyword, SUFFIXES, POSTPOSITIONS2, AGGLUTINATIVE_MARKERS, QuechuaKeywordExtractor, init_quechua_keyword, isHebrew, PREPOSITIONS7, CONJUNCTIONS, HebrewKeywordExtractor, init_hebrew_keyword, isHebrew2, PROCLITIC_PREFIXES, EVENT_MARKER_PREFIXES, EVENT_NAMES, HebrewProcliticExtractor, init_hebrew_proclitic, AsciiIdentifierExtractor, init_ascii_identifier, init_extractors, init_extractor_helpers, EnglishKeywordExtractor, init_english_keyword, english_exports2, ENGLISH_EXTRAS, EnglishTokenizer, englishTokenizer, init_english2, init_types, JAPANESE_SUFFIX_RULES, SURU_PATTERNS, JapaneseMorphologicalNormalizer, init_japanese_normalizer, japanese_exports2, PARTICLES, JAPANESE_EXTRAS, JapaneseTokenizer, japaneseTokenizer, init_japanese2, KOREAN_SUFFIX_RULES, HADA_PATTERNS, KoreanMorphologicalNormalizer, init_korean_normalizer, korean_exports2, PARTICLES2, KOREAN_EXTRAS, KoreanTokenizer, koreanTokenizer, init_korean2, COMBINED_PREFIXES, SINGLE_PREFIXES, VERB_PREFIXES, SUFFIXES2, ArabicMorphologicalNormalizer, init_arabic_normalizer, arabic_exports2, CONJUNCTIONS2, PREPOSITIONS8, ARABIC_EXTRAS, ArabicTokenizer, arabicTokenizer, init_arabic2, AR_ENDINGS, ER_ENDINGS, IR_ENDINGS, ALL_ENDINGS, SpanishMorphologicalNormalizer, init_spanish_normalizer, isSpanishLetter, isSpanishIdentifierChar, PREPOSITIONS9, SpanishKeywordExtractor, init_spanish_keyword, spanish_exports2, PREPOSITIONS10, SPANISH_EXTRAS, SpanishTokenizer, spanishTokenizer, init_spanish2, TURKISH_SUFFIX_RULES, TurkishMorphologicalNormalizer, init_turkish_normalizer, turkish_exports2, POSTPOSITIONS3, CASE_SUFFIXES2, TURKISH_EXTRAS, TurkishTokenizer, turkishTokenizer, init_turkish2, chinese_exports2, PARTICLES3, CHINESE_EXTRAS, ChineseTokenizer, chineseTokenizer, init_chinese2, REFLEXIVE_SUFFIXES, AR_ENDINGS2, ER_ENDINGS2, IR_ENDINGS2, ALL_ENDINGS2, PortugueseMorphologicalNormalizer, init_portuguese_normalizer, isPortugueseLetter, isPortugueseIdentifierChar, PREPOSITIONS11, PortugueseKeywordExtractor, init_portuguese_keyword, portuguese_exports2, PREPOSITIONS12, PORTUGUESE_EXTRAS, PortugueseTokenizer, portugueseTokenizer, init_portuguese2, REFLEXIVE_SUFFIXES2, ER_ENDINGS3, IR_ENDINGS3, RE_ENDINGS, ALL_ENDINGS3, FrenchMorphologicalNormalizer, init_french_normalizer, isFrenchLetter, isFrenchIdentifierChar, PREPOSITIONS13, FrenchKeywordExtractor, init_french_keyword, french_exports2, FRENCH_EXTRAS, FrenchTokenizer, frenchTokenizer, init_french2, SEPARABLE_PREFIXES, VERB_ENDINGS, ELN_ERN_ENDINGS, ALL_ENDINGS4, GermanMorphologicalNormalizer, init_german_normalizer, isGermanLetter, isGermanIdentifierChar, PREPOSITIONS14, GermanKeywordExtractor, init_german_keyword, german_exports2, GERMAN_EXTRAS, GermanTokenizer, germanTokenizer, init_german2, indonesian_exports2, PREPOSITIONS15, INDONESIAN_EXTRAS, IndonesianTokenizer, indonesianTokenizer, init_indonesian2, QUECHUA_SUFFIX_RULES, QuechuaMorphologicalNormalizer, quechuaMorphologicalNormalizer, init_quechua_normalizer, quechua_exports2, QuechuaStringLiteralExtractor, SUFFIXES3, QUECHUA_EXTRAS, QuechuaTokenizer, quechuaTokenizer, init_quechua2, swahili_exports2, PREPOSITIONS16, SWAHILI_EXTRAS, SwahiliTokenizer, swahiliTokenizer, init_swahili2, REFLEXIVE_SUFFIXES3, ARE_ENDINGS, ERE_ENDINGS, IRE_ENDINGS, ALL_ENDINGS5, ItalianMorphologicalNormalizer, init_italian_normalizer, RomanceKeywordExtractor, ITALIAN_PREPOSITIONS, init_romance_language_keyword, italian_exports2, PREPOSITIONS17, ITALIAN_EXTRAS, ItalianTokenizer, italianTokenizer, init_italian2, vietnamese_exports2, VIETNAMESE_EXTRAS, VietnameseTokenizer, vietnameseTokenizer, init_vietnamese2, IMPERATIVE_TO_INFINITIVE, PolishMorphologicalNormalizer, init_polish_normalizer, polish_exports2, PREPOSITIONS18, POLISH_EXTRAS, PolishTokenizer, polishTokenizer, init_polish2, IMPERATIVE_TO_INFINITIVE2, RussianMorphologicalNormalizer, init_russian_normalizer, russian_exports2, PREPOSITIONS19, RUSSIAN_EXTRAS, RussianTokenizer, russianTokenizer, init_russian2, IMPERATIVE_TO_INFINITIVE3, UkrainianMorphologicalNormalizer, init_ukrainian_normalizer, ukrainian_exports2, PREPOSITIONS20, UKRAINIAN_EXTRAS, UkrainianTokenizer, ukrainianTokenizer, init_ukrainian2, he_exports2, PREPOSITIONS21, HEBREW_EXTRAS, HebrewTokenizer, hebrewTokenizer, init_he2, SUFFIX_RULES, HindiMorphologicalNormalizer, init_hindi_normalizer, hindi_exports2, SINGLE_POSTPOSITIONS3, HINDI_EXTRAS, HindiTokenizer, hindiTokenizer, init_hindi2, SUFFIX_RULES2, BengaliMorphologicalNormalizer, bengaliMorphologicalNormalizer, init_bengali_normalizer, bengali_exports2, SINGLE_POSTPOSITIONS4, BENGALI_EXTRAS, BengaliTokenizer, bengaliTokenizer, init_bengali2, thai_exports2, THAI_EXTRAS, ThaiTokenizer, thaiTokenizer, init_thai2, ms_exports2, MALAY_EXTRAS, MalayTokenizer, malayTokenizer, init_ms2, COMBINED_PREFIXES2, SINGLE_PREFIXES2, INFIXES, SUFFIXES4, TagalogMorphologicalNormalizer, tagalogMorphologicalNormalizer, init_tagalog_normalizer, tl_exports2, TAGALOG_EXTRAS, TagalogTokenizer, tagalogTokenizer, init_tl2, eventNameTranslations, eventNameLocalizations, eventLocalizationDenylist, init_event_handler, init_role_positioning, init_marker_resolution, init_event_handlers_sov, init_event_handlers_vso, defaultConfig, init_pattern_generator, init_toggle, VERB_FIRST_REPEAT_TIMES, SOV_REPEAT_TIMES, FOR_IN_HEADS, WHILE_HEADS, VERB_FIRST_UNTIL_HEADS, repeatUntilHeadQuMidClause, SOV_UNTIL_HEADS, repeatUntilHeadQu, BY_LANG, addPattern, init_repeat, init_wait, en_exports, fetchWithResponseTypeEnglish, fetchSimpleEnglish, swapSimpleEnglish, swapElementEnglish, repeatUntilEventFromEnglish, repeatUntilEventEnglish, repeatTimesEnglish, repeatForeverEnglish, setPossessiveEnglish, forEnglish, ifEnglish, unlessEnglish, temporalInEnglish, temporalAfterEnglish, init_en, DEFAULT_CONFIDENCE_THRESHOLD, HIGH_CONFIDENCE_THRESHOLD, CONTEXT_VARS, LOGICAL_OPERATORS, BOOLEAN_LITERALS, COMPARISON_KEYWORDS, POSITIONAL_KEYWORDS, TIME_UNITS, POSSESSIVE_CONTEXT_TYPES, POSTFIX_STOP_WORDS, POSITIONAL_CALL_KEYWORDS, ExpressionParser, toggleMapper, addMapper, removeMapper, setMapper, showMapper, hideMapper, incrementMapper, decrementMapper, waitMapper, logMapper, putMapper, fetchMapper, appendMapper, prependMapper, triggerMapper, sendMapper, goMapper, transitionMapper, focusMapper, blurMapper, getMapper, takeMapper, callMapper, returnMapper, haltMapper, throwMapper, settleMapper, swapMapper, morphMapper, cloneMapper, makeMapper, measureMapper, tellMapper, jsMapper, asyncMapper, ifMapper, unlessMapper, repeatMapper, forMapper, whileMapper, continueMapper, defaultMapper, initMapper, behaviorMapper, installMapper, onMapper, mappers, ASTBuilder, KNOWN_PROFILES, OPTIONAL_ROLE_WEIGHT, DEFAULT_PARTIAL_CREDIT, MAX_STEM_PENALTY, STEM_PENALTY_FLOOR, VSO_VERB_BOOST, MAX_PREPOSITION_ADJUSTMENT, ARABIC_VERBS, PREFERRED_PREPOSITIONS, DefaultConfidenceModel, defaultConfidenceModel, BAREKEYWORD_BLOCK_ACTIONS, _PatternMatcher2, PatternMatcher, patternMatcher, OPENER_ACTIONS, OPENER_NORMS, TARGET_REFERENCES, ROLE_CONCEPTS, TRIGGER_SIGNATURE_LANGS, SemanticRendererImpl, semanticRenderer, hyperscriptSchemaLookup, BLOCK_BODY_ACTIONS, NON_VALUE_KEYWORDS, POSITIONAL_VALUE_KEYWORDS, WAITABLE_EVENT_WORDS, SemanticParseError, NORMALIZE_CHILD_FIELDS, _SemanticParserImpl, SemanticParserImpl, semanticParser, SemanticCache2, semanticCache, LANGUAGE_IMPORTERS, SUPPORTED_LANGUAGES, fetchWithResponseTypeEnglish2, fetchSimpleEnglish2, fetchPatternsEn, swapSimpleEnglish2, swapElementEnglish2, swapPatternsEn, repeatUntilEventFromEnglish2, repeatUntilEventEnglish2, repeatPatternsEn, setPossessiveEnglish2, setPatternsEn, forEnglish2, ifEnglish2, unlessEnglish2, controlFlowPatternsEn, temporalInEnglish2, temporalAfterEnglish2, temporalPatternsEn, allEnglishOnlyPatterns, PATTERN_LOADERS, _generatedPatternsPerLanguage, handcraftedLanguages, patternCache2, _allPatterns, schemaRegistry, DEFAULT_CONFIG, HIGH_FREQUENCY_TRIGGERS, THROTTLE_RECOMMENDED_TRIGGERS, _devModeEnabled, _devModeConfig, VERSION, index$1, HistorySwapBehavior, BoostedBehavior, DEFAULT_EVENT_TYPE, DEFAULT_LANGUAGE$1, compileSyncFn, compileAsyncFn, getRuntimeFn, configRef, RingBuffer, HISTORY_CAPACITY, DebugController, DEFAULT_LANGUAGE, ASTCache, astCache, semanticAnalyzerInstance, bridgeInstance, config, _defaultRuntime, _debugController, hyperscript, lokascript, OP_TABLE, Lexer, Tokens, MAX_HISTORY_SIZE$5, DefInputSchema, TypedDefFeatureImplementation, enhancedDefImplementation, MAX_HISTORY_SIZE$4, EnhancedOnInputSchema, TypedOnFeatureImplementation, enhancedOnImplementation, MAX_HISTORY_SIZE$3, BehaviorsInputSchema, TypedBehaviorsFeatureImplementation, enhancedBehaviorsImplementation, MAX_HISTORY_SIZE$2, SocketsInputSchema, TypedSocketsFeatureImplementation, enhancedSocketsImplementation, MAX_HISTORY_SIZE$1, WebWorkerInputSchema, TypedWebWorkerFeatureImplementation, enhancedWebWorkerImplementation, MAX_HISTORY_SIZE, EventSourceInputSchema, TypedEventSourceFeatureImplementation, enhancedEventSourceImplementation, INTERCHANGE_ADAPTER, POS, DiagnosticSeverity, SymbolKind, CompletionItemKind, _semanticModule, SemanticGrammarBridge, bridge, _fw, index;
|
|
27434
|
+
var KEYWORDS$1, COMMAND_TERMINATORS, COMMANDS, COMPOUND_COMMANDS, CONTROL_FLOW_COMMANDS, PUT_OPERATIONS, PUT_OPERATION_KEYWORDS, HYPERSCRIPT_KEYWORDS, CommandClassification, CSS_FUNCTIONS, CONTEXT_VARS$1, LOGICAL_OPERATORS$1, COMPARISON_OPERATORS, DOM_EVENTS, TOKENIZER_KEYWORDS, TokenKind, MATHEMATICAL_OPERATORS, TIME_UNITS$1, isDebugEnabled$1, DEBUG, debug, debugEnabled, debugEventTarget, stats, DEFAULT_CONFIDENCE_THRESHOLD$1, SemanticIntegrationAdapter, STOP_TOKENS, STOP_DELIMITERS, CORE_FRAGMENT, PARSER_COMPARISON_FRAGMENT, ASSIGNMENT_FRAGMENT, PARSER_TABLE, FEATURE_REGISTRY, NODE_EVALUATORS, NODE_WRITERS, GLOBAL_WRITE_HOOKS, GLOBAL_READ_HOOKS, LOCAL_WRITE_HOOKS, LOCAL_READ_HOOKS, ParserExtensionRegistry, SINGLETON, WINDOW_KEY, MULTI_WORD_PATTERNS, DEFAULT_BOUNDARY_KEYWORDS, CommandNodeBuilder, SWAP_STRATEGY_KEYWORDS, ELEMENT_PRONOUNS, STRING_POSTFIX_UNITS, STRING_POSTFIX_BP, Parser, HookRegistry, sharedGlobals, elementScopes, ExpressionTypeRegistry, expressionTypeRegistry, BOOLEAN_ATTRIBUTES, SPECIAL_DOM_PROPERTIES, NUMBER_WORDS, isProduction, skipValidation, addDescribeToValidator, v, z, BaseExpressionImpl, enhancedConverters, AsExpressionInputSchema, AsExpression, IsExpressionInputSchema, IsExpression, conversionConfig, defaultConversions, TYPE_ALIASES, asExpression, isExpression, asyncExpression, conversionExpressions, UNSAFE_PROPS, possessiveExpression, myExpression, itsExpression$1, yourExpression, ofExpression, attributeExpression, attributeWithValueExpression, classReferenceExpression, idReferenceExpression, propertiesExpressions, NotSyncEvaluable, cachedFullRegistry, RAW_ARG_BUILTINS, CSS_PSEUDO_CLASSES, PSEUDO_CLASS_COLON_RE, BARE_REF_ESCAPE_RE, QUERY_REF_INTERP_RE, CleanupRegistry, EventSourceRegistry, ContextProviderRegistry, canonicalEvaluator, ContextBridge, CommandAdapterV2, CommandRegistryV2, defaultRegistry, RegistryIntegration, eventRecursionDepth, RuntimeBase, MeExpression, YouExpression, ItExpression, CSSelectorInputSchema, CSSSelectorExpression, meExpression, youExpression, itExpression, itsExpression, resultExpression, querySelectorExpression, querySelectorAllExpression, idExpression, classExpression, closestExpression, parentExpression, windowExpression, documentExpression, elementWithSelectorExpression, styleRefExpression, possessiveStyleRefExpression, ofStyleRefExpression, referencesExpressions, LRUCache, HyperscriptCache, globalCache, PerformanceTracker, performanceTracker, cleanupInterval, BinaryLogicalInputSchema, UnaryLogicalInputSchema, AndExpression, OrExpression, NotExpression, ComparisonInputSchema, PatternMatchingInputSchema, equalsExpression, strictEqualsExpression, notEqualsExpression, strictNotEqualsExpression, lessThanExpression, lessThanOrEqualExpression, greaterThanExpression, greaterThanOrEqualExpression, andExpression, orExpression, notExpression, isEmptyExpression, noExpression, isNotEmptyExpression, existsExpression, doesNotExistExpression, containsExpression, doesNotContainExpression, startsWithExpression, endsWithExpression, betweenExpression, matchesExpression, hasExpression, doesNotHaveExpression, logicalExpressions, StringLiteralInputSchema, NumberLiteralInputSchema, BooleanLiteralInputSchema, BinaryOperationInputSchema, StringLiteralExpression, NumberLiteralExpression, BooleanLiteralExpression, AdditionExpression$1, StringConcatenationExpression, MultiplicationExpression$1, specialExpressions, evaluationToHyperScriptType, CollectionInputSchema, IndexInputSchema, RandomInputSchema, FirstExpression, LastExpression, AtExpression, RandomExpression, firstExpression, lastExpression, atExpression, nextExpression, previousExpression, DOCUMENT_POSITION_PRECEDING, DOCUMENT_POSITION_FOLLOWING, nextWithinExpression, previousWithinExpression, positionalExpressions, AdditionExpression2, SubtractionExpression, MultiplicationExpression2, DivisionExpression, ModuloExpression, PowerExpression, mathematicalExpressions, index$3, COMMAND_NAME, COMMAND_CATEGORY, COMMAND_METADATA, KEYWORD_PREPOSITIONS, VisibilityCommandBase, HideCommand, createHideCommand, ShowCommand, createShowCommand, SMART_ELEMENT_TAGS, DOMModificationBase, AddCommand, createAddCommand, RemoveCommand, createRemoveCommand, PATTERN, BOOL_PROPS, ToggleCommand, createToggleCommand, PutCommand, createPutCommand, HTML_ESCAPE, MakeCommand, createMakeCommand, EmptyCommand, createEmptyCommand, OpenCommand, createOpenCommand, CloseCommand, createCloseCommand, SelectCommand, createSelectCommand, ResetCommand, createResetCommand, SUPPORTS_MOVE_BEFORE, ELEMENT_NODE_TYPE, TEXT_NODE_TYPE, IS_PARENT_NODE_TYPE, Operation, candidateNodes, candidateElements, candidateElementsWithIds, unmatchedNodes, unmatchedElements, whitespaceNodes, _idArrayMap, _idSetMap, _options, _Morph_instances, morphOneToMany_fn, morphOneToOne_fn, morphMatchingElements_fn, morphNonMatchingElements_fn, morphOtherNode_fn, visitAttributes_fn, visitTextArea_fn, replaceNode_fn, removeNode_fn, mapIdArraysForEach_fn, mapIdArrays_fn, mapIdSets_fn, Morph, morphAdapter, queue, processing, STRATEGY_KEYWORDS, SwapCommand, MorphCommand, createSwapCommand, createMorphCommand, CRITICAL_LAYOUT_ELEMENTS, STRUCTURAL_SEMANTIC_ELEMENTS, WARNING_ELEMENTS, DEFAULT_VALIDATION_CONFIG, globalConfig, STYLES, SEVERITY_ICONS, SEVERITY_LABELS, STRATEGY_MAP, ProcessPartialsCommand, createProcessPartialsCommand, WaitCommand, createWaitCommand, customResponseTypes, DEFAULT_FETCH_THROWS_ON, fetchThrowsOnPatterns, FetchCommand, createFetchCommand, SetCommand, createSetCommand, GetCommand, createGetCommand, NumericModifyCommand, createIncrementCommand, createDecrementCommand, ClearCommand, createClearCommand, LogCommand, createLogCommand, EventDispatchCommand, createTriggerCommand, createSendCommand, GoCommand, createGoCommand, KEYWORDS, HistoryCommand, createPushUrlCommand, createReplaceUrlCommand, ScrollCommand, createScrollCommand, ConditionalCommand, createConditionalCommand, createIfCommand, createUnlessCommand, RepeatCommand, createRepeatCommand, ControlFlowSignalBase, BreakCommand, createBreakCommand, ContinueCommand, createContinueCommand, HaltCommand, createHaltCommand, ReturnCommand, createReturnCommand, ExitCommand, createExitCommand, CallCommand, createCallCommand, FocusCommand, createFocusCommand, BlurCommand, createBlurCommand, AppendCommand, createAppendCommand, TransitionCommand, createTransitionCommand, MeasureCommand, createMeasureCommand, SettleCommand, createSettleCommand, StartViewTransitionCommand, createStartViewTransitionCommand, JsCommand, createJsCommand, AsyncCommand, createAsyncCommand, DefaultCommand, createDefaultCommand, PseudoCommand, TellCommand, createTellCommand, CopyCommand, createCopyCommand, PickCommand, createPickCommand, ThrowCommand, createThrowCommand, BeepCommand, createBeepCommand, BreakpointCommand, createBreakpointCommand, InstallCommand, TakeCommand, createTakeCommand, RenderCommand, Runtime, DEFAULT_REFERENCES, STRUCTURAL_ROLES, CHAIN_KEYWORDS, VERSION_HEADER_RE, VALID_KINDS, VALID_VALUE_TYPES$1, VALID_CHAIN_TYPES, VALID_ASYNC_VARIANTS, VALID_DIAGNOSTIC_LEVELS, DebugLogger, _PatternMatcher$1, PatternMatcher$1, patternMatcher$1, defaultConfig$1, GrammarTransformer, InMemoryDictionary, NullDictionary, InMemoryProfileProvider, NullProfileProvider, StringLiteralExtractor, NumberExtractor, IdentifierExtractor, UnicodeIdentifierExtractor, LatinExtendedIdentifierExtractor, WhitespaceExtractor, VALID_VALUE_TYPES, SCROLL_MARKERS, URL_MARKERS, PARTIALS_IN_MARKERS, DSLRegistry, MultilingualDSLImpl, DomainRegistry, COMMENT_PATTERN, CrossDomainDispatcher, DomainAwareScanner, AOTOrchestrator, TokenStreamImpl, DEFAULT_OPERATORS$1, OperatorExtractor$1, DEFAULT_PUNCTUATION$1, PunctuationExtractor$1, SIMPLE_TOKENIZER_OPERATOR_SET, MARKER_CONCEPT_NORMALIZEDS, ENGLISH_DOM_EVENT_NAMES, _BaseTokenizer, BaseTokenizer, BaseMorphologicalNormalizer, PatternTracker, MultiStatementParserImpl, index$2, __defProp2, __getOwnPropNames2, __esm2, __export2, tokenizers, profiles, patternCache, patternGenerator, registeredPatterns, init_registry, arabic_exports, arabicProfile, init_arabic, bengali_exports, bengaliProfile, init_bengali, german_exports, germanProfile, init_german, english_exports, englishProfile, init_english, spanish_exports, spanishProfile, init_spanish, french_exports, frenchProfile, init_french, he_exports, hebrewProfile, init_he, hindi_exports, hindiProfile, init_hindi, indonesian_exports, indonesianProfile, init_indonesian, italian_exports, italianProfile, init_italian, japanese_exports, japaneseProfile, init_japanese, korean_exports, koreanProfile, init_korean, ms_exports, malayProfile, init_ms, polish_exports, polishProfile, init_polish, portuguese_exports, portugueseProfile, init_portuguese, quechua_exports, quechuaProfile, init_quechua, russian_exports, russianProfile, init_russian, swahili_exports, swahiliProfile, init_swahili, thai_exports, thaiProfile, init_thai, tl_exports, tagalogProfile, init_tl, turkish_exports, turkishProfile, init_turkish, ukrainian_exports, ukrainianProfile, init_ukrainian, vietnamese_exports, vietnameseProfile, init_vietnamese, chinese_exports, chineseProfile, init_chinese, SchemaErrorCodes, SchemaErrorMessages, SchemaErrorSuggestions, init_schema_error_codes, schema_validator_exports, MULTI_TYPE_PATIENT_COMMANDS, NO_REQUIRED_ROLES_COMMANDS, init_schema_validator, toggleSchema, addSchema, removeSchema, putSchema, setSchema, bindSchema, liveSchema, eventsourceSchema, socketSchema, workerSchema, interceptSchema, showSchema, hideSchema, onSchema, triggerSchema, waitSchema, fetchSchema, incrementSchema, decrementSchema, appendSchema, prependSchema, logSchema, getCommandSchema, takeSchema, makeSchema, haltSchema, settleSchema, throwSchema, sendSchema, ifSchema, unlessSchema, elseSchema, repeatSchema, forSchema, whileSchema, continueSchema, goSchema, transitionSchema, cloneSchema, focusSchema, blurSchema, emptySchema, openSchema, closeSchema, selectSchema, clearSchema, resetSchema, breakpointSchema, callSchema, returnSchema, jsSchema, asyncSchema, tellSchema, defaultSchema, initSchema, behaviorSchema, installSchema, measureSchema, swapSchema, morphSchema, beepSchema, breakSchema, copySchema, exitSchema, pickSchema, scrollSchema, URL_MARKER_ALL_LANGS, PARTIALS_IN_MARKER_ALL_LANGS, pushSchema, replaceSchema, processSchema, renderSchema, commandSchemas, init_command_schemas, PUT_POSITIONAL, PUT_AT_END, init_put, init_token_utils, init_char_classifiers, init_base_tokenizer, init_base, DEFAULT_OPERATORS, OperatorExtractor2, DEFAULT_PUNCTUATION, PunctuationExtractor2, init_generic_extractors, CssSelectorExtractor, init_css_selector, EventModifierExtractor, init_event_modifier, UrlExtractor, init_url, VariableRefExtractor, init_variable_ref, JapaneseKeywordExtractor, init_japanese_keyword, SINGLE_CHAR_PARTICLES, MULTI_CHAR_PARTICLES, JapaneseParticleExtractor, init_japanese_particle, TEMPORAL_EVENT_SUFFIXES, KoreanKeywordExtractor, init_korean_keyword, SINGLE_CHAR_PARTICLES2, MULTI_CHAR_PARTICLES2, KoreanParticleExtractor, init_korean_particle, ChineseKeywordExtractor, init_chinese_keyword, SINGLE_CHAR_PARTICLES3, MULTI_CHAR_PARTICLES3, ChineseParticleExtractor, init_chinese_particle, isVietnameseLetter, isVietnameseIdentifierChar, PREPOSITIONS, VietnameseKeywordExtractor, init_vietnamese_keyword, isArabic, PREPOSITIONS2, ArabicKeywordExtractor, init_arabic_keyword, isArabic2, PROCLITICS, NON_PROCLITIC_WORDS, ArabicProcliticExtractor, init_arabic_proclitic, isArabic3, TEMPORAL_MARKERS, ArabicTemporalExtractor, init_arabic_temporal, CyrillicKeywordExtractor, RUSSIAN_PREPOSITIONS, UKRAINIAN_PREPOSITIONS, init_cyrillic_keyword, HindiKeywordExtractor, init_hindi_keyword, SINGLE_POSTPOSITIONS, COMPOUND_POSTPOSITIONS, HindiParticleExtractor, init_hindi_particle, BengaliKeywordExtractor, init_bengali_keyword, SINGLE_POSTPOSITIONS2, BengaliParticleExtractor, init_bengali_particle, ThaiKeywordExtractor, init_thai_keyword, MalayKeywordExtractor, init_malay_keyword, PREPOSITIONS3, TagalogKeywordExtractor, init_tagalog_keyword, PREPOSITIONS4, isPolishLetter, isPolishIdentifierChar, PolishKeywordExtractor, init_polish_keyword, PREPOSITIONS5, isIndonesianLetter, isIndonesianIdentifierChar, IndonesianKeywordExtractor, init_indonesian_keyword, PREPOSITIONS6, isSwahiliLetter, isSwahiliIdentifierChar, SwahiliKeywordExtractor, init_swahili_keyword, POSTPOSITIONS, CASE_SUFFIXES, TurkishKeywordExtractor, init_turkish_keyword, SUFFIXES, POSTPOSITIONS2, AGGLUTINATIVE_MARKERS, QuechuaKeywordExtractor, init_quechua_keyword, isHebrew, PREPOSITIONS7, CONJUNCTIONS, HebrewKeywordExtractor, init_hebrew_keyword, isHebrew2, PROCLITIC_PREFIXES, EVENT_MARKER_PREFIXES, EVENT_NAMES, HebrewProcliticExtractor, init_hebrew_proclitic, AsciiIdentifierExtractor, init_ascii_identifier, init_extractors, init_extractor_helpers, EnglishKeywordExtractor, init_english_keyword, english_exports2, ENGLISH_EXTRAS, EnglishTokenizer, englishTokenizer, init_english2, init_types, JAPANESE_SUFFIX_RULES, SURU_PATTERNS, JapaneseMorphologicalNormalizer, init_japanese_normalizer, japanese_exports2, PARTICLES, JAPANESE_EXTRAS, JapaneseTokenizer, japaneseTokenizer, init_japanese2, KOREAN_SUFFIX_RULES, HADA_PATTERNS, KoreanMorphologicalNormalizer, init_korean_normalizer, korean_exports2, PARTICLES2, KOREAN_EXTRAS, KoreanTokenizer, koreanTokenizer, init_korean2, COMBINED_PREFIXES, SINGLE_PREFIXES, VERB_PREFIXES, SUFFIXES2, ArabicMorphologicalNormalizer, init_arabic_normalizer, arabic_exports2, CONJUNCTIONS2, PREPOSITIONS8, ARABIC_EXTRAS, ArabicTokenizer, arabicTokenizer, init_arabic2, AR_ENDINGS, ER_ENDINGS, IR_ENDINGS, ALL_ENDINGS, SpanishMorphologicalNormalizer, init_spanish_normalizer, isSpanishLetter, isSpanishIdentifierChar, PREPOSITIONS9, SpanishKeywordExtractor, init_spanish_keyword, spanish_exports2, PREPOSITIONS10, SPANISH_EXTRAS, SpanishTokenizer, spanishTokenizer, init_spanish2, TURKISH_SUFFIX_RULES, TurkishMorphologicalNormalizer, init_turkish_normalizer, turkish_exports2, POSTPOSITIONS3, CASE_SUFFIXES2, TURKISH_EXTRAS, TurkishTokenizer, turkishTokenizer, init_turkish2, chinese_exports2, PARTICLES3, CHINESE_EXTRAS, ChineseTokenizer, chineseTokenizer, init_chinese2, REFLEXIVE_SUFFIXES, AR_ENDINGS2, ER_ENDINGS2, IR_ENDINGS2, ALL_ENDINGS2, PortugueseMorphologicalNormalizer, init_portuguese_normalizer, isPortugueseLetter, isPortugueseIdentifierChar, PREPOSITIONS11, PortugueseKeywordExtractor, init_portuguese_keyword, portuguese_exports2, PREPOSITIONS12, PORTUGUESE_EXTRAS, PortugueseTokenizer, portugueseTokenizer, init_portuguese2, REFLEXIVE_SUFFIXES2, ER_ENDINGS3, IR_ENDINGS3, RE_ENDINGS, ALL_ENDINGS3, FrenchMorphologicalNormalizer, init_french_normalizer, isFrenchLetter, isFrenchIdentifierChar, PREPOSITIONS13, FrenchKeywordExtractor, init_french_keyword, french_exports2, FRENCH_EXTRAS, FrenchTokenizer, frenchTokenizer, init_french2, SEPARABLE_PREFIXES, VERB_ENDINGS, ELN_ERN_ENDINGS, ALL_ENDINGS4, GermanMorphologicalNormalizer, init_german_normalizer, isGermanLetter, isGermanIdentifierChar, PREPOSITIONS14, GermanKeywordExtractor, init_german_keyword, german_exports2, GERMAN_EXTRAS, GermanTokenizer, germanTokenizer, init_german2, indonesian_exports2, PREPOSITIONS15, INDONESIAN_EXTRAS, IndonesianTokenizer, indonesianTokenizer, init_indonesian2, QUECHUA_SUFFIX_RULES, QuechuaMorphologicalNormalizer, quechuaMorphologicalNormalizer, init_quechua_normalizer, quechua_exports2, QuechuaStringLiteralExtractor, SUFFIXES3, QUECHUA_EXTRAS, QuechuaTokenizer, quechuaTokenizer, init_quechua2, swahili_exports2, PREPOSITIONS16, SWAHILI_EXTRAS, SwahiliTokenizer, swahiliTokenizer, init_swahili2, REFLEXIVE_SUFFIXES3, ARE_ENDINGS, ERE_ENDINGS, IRE_ENDINGS, ALL_ENDINGS5, ItalianMorphologicalNormalizer, init_italian_normalizer, RomanceKeywordExtractor, ITALIAN_PREPOSITIONS, init_romance_language_keyword, italian_exports2, PREPOSITIONS17, ITALIAN_EXTRAS, ItalianTokenizer, italianTokenizer, init_italian2, vietnamese_exports2, VIETNAMESE_EXTRAS, VietnameseTokenizer, vietnameseTokenizer, init_vietnamese2, IMPERATIVE_TO_INFINITIVE, PolishMorphologicalNormalizer, init_polish_normalizer, polish_exports2, PREPOSITIONS18, POLISH_EXTRAS, PolishTokenizer, polishTokenizer, init_polish2, IMPERATIVE_TO_INFINITIVE2, RussianMorphologicalNormalizer, init_russian_normalizer, russian_exports2, PREPOSITIONS19, RUSSIAN_EXTRAS, RussianTokenizer, russianTokenizer, init_russian2, IMPERATIVE_TO_INFINITIVE3, UkrainianMorphologicalNormalizer, init_ukrainian_normalizer, ukrainian_exports2, PREPOSITIONS20, UKRAINIAN_EXTRAS, UkrainianTokenizer, ukrainianTokenizer, init_ukrainian2, he_exports2, PREPOSITIONS21, HEBREW_EXTRAS, HebrewTokenizer, hebrewTokenizer, init_he2, SUFFIX_RULES, HindiMorphologicalNormalizer, init_hindi_normalizer, hindi_exports2, SINGLE_POSTPOSITIONS3, HINDI_EXTRAS, HindiTokenizer, hindiTokenizer, init_hindi2, SUFFIX_RULES2, BengaliMorphologicalNormalizer, bengaliMorphologicalNormalizer, init_bengali_normalizer, bengali_exports2, SINGLE_POSTPOSITIONS4, BENGALI_EXTRAS, BengaliTokenizer, bengaliTokenizer, init_bengali2, thai_exports2, THAI_EXTRAS, ThaiTokenizer, thaiTokenizer, init_thai2, ms_exports2, MALAY_EXTRAS, MalayTokenizer, malayTokenizer, init_ms2, COMBINED_PREFIXES2, SINGLE_PREFIXES2, INFIXES, SUFFIXES4, TagalogMorphologicalNormalizer, tagalogMorphologicalNormalizer, init_tagalog_normalizer, tl_exports2, TAGALOG_EXTRAS, TagalogTokenizer, tagalogTokenizer, init_tl2, eventNameTranslations, eventNameLocalizations, eventLocalizationDenylist, init_event_handler, init_role_positioning, init_marker_resolution, init_event_handlers_sov, init_event_handlers_vso, defaultConfig, init_pattern_generator, init_toggle, VERB_FIRST_REPEAT_TIMES, SOV_REPEAT_TIMES, FOR_IN_HEADS, WHILE_HEADS, VERB_FIRST_UNTIL_HEADS, repeatUntilHeadQuMidClause, SOV_UNTIL_HEADS, repeatUntilHeadQu, BY_LANG, addPattern, init_repeat, init_wait, en_exports, fetchWithResponseTypeEnglish, fetchSimpleEnglish, swapSimpleEnglish, swapElementEnglish, repeatUntilEventFromEnglish, repeatUntilEventEnglish, repeatTimesEnglish, repeatForeverEnglish, setPossessiveEnglish, forEnglish, ifEnglish, unlessEnglish, temporalInEnglish, temporalAfterEnglish, init_en, DEFAULT_CONFIDENCE_THRESHOLD, HIGH_CONFIDENCE_THRESHOLD, CONTEXT_VARS, LOGICAL_OPERATORS, BOOLEAN_LITERALS, COMPARISON_KEYWORDS, POSITIONAL_KEYWORDS, TIME_UNITS, POSSESSIVE_CONTEXT_TYPES, POSTFIX_STOP_WORDS, POSITIONAL_CALL_KEYWORDS, ExpressionParser, toggleMapper, addMapper, removeMapper, setMapper, showMapper, hideMapper, incrementMapper, decrementMapper, waitMapper, logMapper, putMapper, fetchMapper, appendMapper, prependMapper, triggerMapper, sendMapper, goMapper, transitionMapper, focusMapper, blurMapper, getMapper, takeMapper, callMapper, returnMapper, haltMapper, throwMapper, settleMapper, swapMapper, morphMapper, cloneMapper, makeMapper, measureMapper, tellMapper, jsMapper, asyncMapper, ifMapper, unlessMapper, repeatMapper, forMapper, whileMapper, continueMapper, defaultMapper, initMapper, behaviorMapper, installMapper, onMapper, mappers, ASTBuilder, KNOWN_PROFILES, OPTIONAL_ROLE_WEIGHT, DEFAULT_PARTIAL_CREDIT, MAX_STEM_PENALTY, STEM_PENALTY_FLOOR, VSO_VERB_BOOST, MAX_PREPOSITION_ADJUSTMENT, ARABIC_VERBS, PREFERRED_PREPOSITIONS, DefaultConfidenceModel, defaultConfidenceModel, BAREKEYWORD_BLOCK_ACTIONS, _PatternMatcher2, PatternMatcher, patternMatcher, OPENER_ACTIONS, OPENER_NORMS, TARGET_REFERENCES, ROLE_CONCEPTS, TRIGGER_SIGNATURE_LANGS, SemanticRendererImpl, semanticRenderer, hyperscriptSchemaLookup, BLOCK_BODY_ACTIONS, NON_VALUE_KEYWORDS, POSITIONAL_VALUE_KEYWORDS, WAITABLE_EVENT_WORDS, SemanticParseError, NORMALIZE_CHILD_FIELDS, _SemanticParserImpl, SemanticParserImpl, semanticParser, SemanticCache2, semanticCache, LANGUAGE_IMPORTERS, SUPPORTED_LANGUAGES, fetchWithResponseTypeEnglish2, fetchSimpleEnglish2, fetchPatternsEn, swapSimpleEnglish2, swapElementEnglish2, swapPatternsEn, repeatUntilEventFromEnglish2, repeatUntilEventEnglish2, repeatPatternsEn, setPossessiveEnglish2, setPatternsEn, forEnglish2, ifEnglish2, unlessEnglish2, controlFlowPatternsEn, temporalInEnglish2, temporalAfterEnglish2, temporalPatternsEn, allEnglishOnlyPatterns, PATTERN_LOADERS, _generatedPatternsPerLanguage, handcraftedLanguages, patternCache2, _allPatterns, schemaRegistry, DEFAULT_CONFIG, HIGH_FREQUENCY_TRIGGERS, THROTTLE_RECOMMENDED_TRIGGERS, _devModeEnabled, _devModeConfig, VERSION, index$1, HistorySwapBehavior, BoostedBehavior, DEFAULT_EVENT_TYPE, DEFAULT_LANGUAGE$1, compileSyncFn, compileAsyncFn, getRuntimeFn, configRef, RingBuffer, HISTORY_CAPACITY, DebugController, DEFAULT_LANGUAGE, ASTCache, astCache, semanticAnalyzerInstance, bridgeInstance, config, _defaultRuntime, _debugController, hyperscript, lokascript, OP_TABLE, Lexer, Tokens, MAX_HISTORY_SIZE$5, DefInputSchema, TypedDefFeatureImplementation, enhancedDefImplementation, MAX_HISTORY_SIZE$4, EnhancedOnInputSchema, TypedOnFeatureImplementation, enhancedOnImplementation, MAX_HISTORY_SIZE$3, BehaviorsInputSchema, TypedBehaviorsFeatureImplementation, enhancedBehaviorsImplementation, MAX_HISTORY_SIZE$2, SocketsInputSchema, TypedSocketsFeatureImplementation, enhancedSocketsImplementation, MAX_HISTORY_SIZE$1, WebWorkerInputSchema, TypedWebWorkerFeatureImplementation, enhancedWebWorkerImplementation, MAX_HISTORY_SIZE, EventSourceInputSchema, TypedEventSourceFeatureImplementation, enhancedEventSourceImplementation, INTERCHANGE_ADAPTER, POS, DiagnosticSeverity, SymbolKind, CompletionItemKind, _semanticModule, SemanticGrammarBridge, bridge, _fw, index;
|
|
27241
27435
|
var init_dist = __esm({
|
|
27242
27436
|
"../core/dist/index.mjs"() {
|
|
27243
27437
|
"use strict";
|
|
@@ -28857,6 +29051,7 @@ var init_dist = __esm({
|
|
|
28857
29051
|
"morph",
|
|
28858
29052
|
"morphouter"
|
|
28859
29053
|
];
|
|
29054
|
+
ELEMENT_PRONOUNS = /* @__PURE__ */ new Set(["me", "my", "it", "its", "you", "your", "yourself"]);
|
|
28860
29055
|
STRING_POSTFIX_UNITS = /* @__PURE__ */ new Set([
|
|
28861
29056
|
"em",
|
|
28862
29057
|
"ex",
|
|
@@ -28964,6 +29159,14 @@ var init_dist = __esm({
|
|
|
28964
29159
|
this.advance();
|
|
28965
29160
|
continue;
|
|
28966
29161
|
}
|
|
29162
|
+
if (this.check("then")) {
|
|
29163
|
+
const next = this.peekAt(1);
|
|
29164
|
+
const startsFeature = next !== null && (next.value === "init" || next.value === "on" || next.value === "def" || getRegisteredFeature(next.value) !== void 0);
|
|
29165
|
+
if (startsFeature) {
|
|
29166
|
+
this.advance();
|
|
29167
|
+
continue;
|
|
29168
|
+
}
|
|
29169
|
+
}
|
|
28967
29170
|
if (this.check("init")) {
|
|
28968
29171
|
this.advance();
|
|
28969
29172
|
const initBlock = this.parseTopLevelInitBlock();
|
|
@@ -29676,7 +29879,7 @@ var init_dist = __esm({
|
|
|
29676
29879
|
return {
|
|
29677
29880
|
type: "identifier",
|
|
29678
29881
|
name: varToken.value,
|
|
29679
|
-
scope: "
|
|
29882
|
+
scope: "element",
|
|
29680
29883
|
start: varToken.start - 1,
|
|
29681
29884
|
end: varToken.end,
|
|
29682
29885
|
line: varToken.line,
|
|
@@ -30259,6 +30462,30 @@ var init_dist = __esm({
|
|
|
30259
30462
|
return null;
|
|
30260
30463
|
}
|
|
30261
30464
|
}
|
|
30465
|
+
parseTemporalKeywordModifiers(modifiers) {
|
|
30466
|
+
if (!this.check("debounced") && !this.check("throttled")) {
|
|
30467
|
+
return;
|
|
30468
|
+
}
|
|
30469
|
+
const modToken = this.advance();
|
|
30470
|
+
const modName = modToken.value.toLowerCase();
|
|
30471
|
+
const modifierKey = modName === "debounced" ? "debounce" : "throttle";
|
|
30472
|
+
if (this.match("at")) {
|
|
30473
|
+
if (this.checkTimeExpression()) {
|
|
30474
|
+
const timeToken = this.advance();
|
|
30475
|
+
const delayMs = parseTimeToMs(timeToken.value);
|
|
30476
|
+
modifiers[modifierKey] = delayMs;
|
|
30477
|
+
debug.parse(`\u{1F527} parseEventHandler: Parsed '${modName} at ${timeToken.value}' (${delayMs}ms)`);
|
|
30478
|
+
} else if (this.matchNumber()) {
|
|
30479
|
+
const delayMs = parseInt(this.previous().value, 10);
|
|
30480
|
+
modifiers[modifierKey] = delayMs;
|
|
30481
|
+
debug.parse(`\u{1F527} parseEventHandler: Parsed '${modName} at ${delayMs}'`);
|
|
30482
|
+
} else {
|
|
30483
|
+
this.addError(`Expected time expression after '${modName} at', got: ${this.peek().value}`);
|
|
30484
|
+
}
|
|
30485
|
+
} else {
|
|
30486
|
+
this.addError(`Expected 'at' after '${modName}'`);
|
|
30487
|
+
}
|
|
30488
|
+
}
|
|
30262
30489
|
parseEventHandler() {
|
|
30263
30490
|
debug.parse(`\u{1F527} parseEventHandler: ENTRY - parsing event handler`);
|
|
30264
30491
|
const eventNames = [];
|
|
@@ -30340,27 +30567,7 @@ var init_dist = __esm({
|
|
|
30340
30567
|
debug.parse(`\u{1F527} parseEventHandler: Warning - unknown modifier '.${modName}'`);
|
|
30341
30568
|
}
|
|
30342
30569
|
}
|
|
30343
|
-
|
|
30344
|
-
const modToken = this.advance();
|
|
30345
|
-
const modName = modToken.value.toLowerCase();
|
|
30346
|
-
const modifierKey = modName === "debounced" ? "debounce" : "throttle";
|
|
30347
|
-
if (this.match("at")) {
|
|
30348
|
-
if (this.checkTimeExpression()) {
|
|
30349
|
-
const timeToken = this.advance();
|
|
30350
|
-
const delayMs = parseTimeToMs(timeToken.value);
|
|
30351
|
-
modifiers[modifierKey] = delayMs;
|
|
30352
|
-
debug.parse(`\u{1F527} parseEventHandler: Parsed '${modName} at ${timeToken.value}' (${delayMs}ms)`);
|
|
30353
|
-
} else if (this.matchNumber()) {
|
|
30354
|
-
const delayMs = parseInt(this.previous().value, 10);
|
|
30355
|
-
modifiers[modifierKey] = delayMs;
|
|
30356
|
-
debug.parse(`\u{1F527} parseEventHandler: Parsed '${modName} at ${delayMs}'`);
|
|
30357
|
-
} else {
|
|
30358
|
-
this.addError(`Expected time expression after '${modName} at', got: ${this.peek().value}`);
|
|
30359
|
-
}
|
|
30360
|
-
} else {
|
|
30361
|
-
this.addError(`Expected 'at' after '${modName}'`);
|
|
30362
|
-
}
|
|
30363
|
-
}
|
|
30570
|
+
this.parseTemporalKeywordModifiers(modifiers);
|
|
30364
30571
|
if (firstOnceAlias) {
|
|
30365
30572
|
modifiers.once = true;
|
|
30366
30573
|
}
|
|
@@ -30377,6 +30584,7 @@ var init_dist = __esm({
|
|
|
30377
30584
|
const targetToken = this.advance();
|
|
30378
30585
|
target = targetToken.value;
|
|
30379
30586
|
debug.parse(`\u{1F527} parseEventHandler: Parsed 'from' target: ${target} (kind: ${targetToken.kind})`);
|
|
30587
|
+
this.parseTemporalKeywordModifiers(modifiers);
|
|
30380
30588
|
}
|
|
30381
30589
|
let attributeName;
|
|
30382
30590
|
if (this.match("of")) {
|
|
@@ -31285,6 +31493,10 @@ var init_dist = __esm({
|
|
|
31285
31493
|
}
|
|
31286
31494
|
return this.tokens[this.current];
|
|
31287
31495
|
}
|
|
31496
|
+
peekAt(offset) {
|
|
31497
|
+
const index2 = this.current + offset;
|
|
31498
|
+
return index2 >= 0 && index2 < this.tokens.length ? this.tokens[index2] : null;
|
|
31499
|
+
}
|
|
31288
31500
|
previous() {
|
|
31289
31501
|
return this.tokens[this.current - 1];
|
|
31290
31502
|
}
|
|
@@ -31482,10 +31694,7 @@ var init_dist = __esm({
|
|
|
31482
31694
|
restorePosition: (pos2) => {
|
|
31483
31695
|
parser.current = pos2;
|
|
31484
31696
|
},
|
|
31485
|
-
peekAt: (offset) =>
|
|
31486
|
-
const index2 = parser.current + offset;
|
|
31487
|
-
return index2 >= 0 && index2 < parser.tokens.length ? parser.tokens[index2] : null;
|
|
31488
|
-
},
|
|
31697
|
+
peekAt: (offset) => parser.peekAt(offset),
|
|
31489
31698
|
getInputSlice: (start, end) => {
|
|
31490
31699
|
if (!this.originalInput)
|
|
31491
31700
|
return "";
|
|
@@ -31606,6 +31815,8 @@ var init_dist = __esm({
|
|
|
31606
31815
|
this.interceptCommandHooks = [];
|
|
31607
31816
|
}
|
|
31608
31817
|
};
|
|
31818
|
+
sharedGlobals = /* @__PURE__ */ new Map();
|
|
31819
|
+
elementScopes = /* @__PURE__ */ new WeakMap();
|
|
31609
31820
|
ExpressionTypeRegistry = class {
|
|
31610
31821
|
constructor(config2 = {}) {
|
|
31611
31822
|
this.types = /* @__PURE__ */ new Map();
|
|
@@ -31965,8 +32176,8 @@ var init_dist = __esm({
|
|
|
31965
32176
|
checked: (el) => isInputElement$1(el) ? el.checked : void 0,
|
|
31966
32177
|
disabled: (el) => "disabled" in el ? el.disabled : void 0,
|
|
31967
32178
|
selected: (el) => isOptionElement$1(el) ? el.selected : void 0,
|
|
31968
|
-
tabindex: (el) => isHTMLElement$
|
|
31969
|
-
hidden: (el) => isHTMLElement$
|
|
32179
|
+
tabindex: (el) => isHTMLElement$1(el) ? el.tabIndex : void 0,
|
|
32180
|
+
hidden: (el) => isHTMLElement$1(el) ? el.hidden : void 0,
|
|
31970
32181
|
style: (el) => getComputedStyle(el),
|
|
31971
32182
|
children: (el) => Array.from(el.children),
|
|
31972
32183
|
parent: (el) => el.parentElement,
|
|
@@ -33675,7 +33886,6 @@ var init_dist = __esm({
|
|
|
33675
33886
|
this.debugMode = enabled;
|
|
33676
33887
|
}
|
|
33677
33888
|
};
|
|
33678
|
-
sharedGlobals = /* @__PURE__ */ new Map();
|
|
33679
33889
|
EventSourceRegistry = class {
|
|
33680
33890
|
constructor() {
|
|
33681
33891
|
this.sources = /* @__PURE__ */ new Map();
|
|
@@ -33892,6 +34102,7 @@ var init_dist = __esm({
|
|
|
33892
34102
|
static toTyped(context) {
|
|
33893
34103
|
return {
|
|
33894
34104
|
me: context.me,
|
|
34105
|
+
...context.owner !== void 0 && { owner: context.owner },
|
|
33895
34106
|
it: context.it,
|
|
33896
34107
|
you: context.you,
|
|
33897
34108
|
result: context.result,
|
|
@@ -34721,6 +34932,7 @@ var init_dist = __esm({
|
|
|
34721
34932
|
debug.runtime(`BEHAVIOR: Found behavior, eventHandlers count: ${behavior.eventHandlers?.length || 0}`);
|
|
34722
34933
|
const baseBehaviorContext = {
|
|
34723
34934
|
me: element,
|
|
34935
|
+
owner: element,
|
|
34724
34936
|
you: null,
|
|
34725
34937
|
it: null,
|
|
34726
34938
|
result: null,
|
|
@@ -38094,7 +38306,7 @@ var init_dist = __esm({
|
|
|
38094
38306
|
const typed = input;
|
|
38095
38307
|
if (!Array.isArray(typed.targets))
|
|
38096
38308
|
return false;
|
|
38097
|
-
if (!typed.targets.every((t) => isHTMLElement(t)))
|
|
38309
|
+
if (!typed.targets.every((t) => isHTMLElement$2(t)))
|
|
38098
38310
|
return false;
|
|
38099
38311
|
if (typed.mode !== "show" && typed.mode !== "hide")
|
|
38100
38312
|
return false;
|
|
@@ -38148,7 +38360,7 @@ var init_dist = __esm({
|
|
|
38148
38360
|
const typed = input;
|
|
38149
38361
|
if (!Array.isArray(typed.targets))
|
|
38150
38362
|
return false;
|
|
38151
|
-
if (!typed.targets.every((t) => isHTMLElement(t)))
|
|
38363
|
+
if (!typed.targets.every((t) => isHTMLElement$2(t)))
|
|
38152
38364
|
return false;
|
|
38153
38365
|
return true;
|
|
38154
38366
|
}
|
|
@@ -38192,7 +38404,7 @@ var init_dist = __esm({
|
|
|
38192
38404
|
const typed = input;
|
|
38193
38405
|
if (!Array.isArray(typed.targets))
|
|
38194
38406
|
return false;
|
|
38195
|
-
if (!typed.targets.every((t) => isHTMLElement(t)))
|
|
38407
|
+
if (!typed.targets.every((t) => isHTMLElement$2(t)))
|
|
38196
38408
|
return false;
|
|
38197
38409
|
if (typeof typed.defaultDisplay !== "string")
|
|
38198
38410
|
return false;
|
|
@@ -38388,13 +38600,13 @@ var init_dist = __esm({
|
|
|
38388
38600
|
throw new Error("remove command requires an argument");
|
|
38389
38601
|
}
|
|
38390
38602
|
const { value: firstValue } = await this.evaluateFirst(raw.args[0], evaluator, context);
|
|
38391
|
-
if (isHTMLElement(firstValue)) {
|
|
38603
|
+
if (isHTMLElement$2(firstValue)) {
|
|
38392
38604
|
return { type: "element", targets: [firstValue] };
|
|
38393
38605
|
}
|
|
38394
|
-
if (Array.isArray(firstValue) && firstValue.length > 0 && isHTMLElement(firstValue[0])) {
|
|
38606
|
+
if (Array.isArray(firstValue) && firstValue.length > 0 && isHTMLElement$2(firstValue[0])) {
|
|
38395
38607
|
return {
|
|
38396
38608
|
type: "element",
|
|
38397
|
-
targets: firstValue.filter((el) => isHTMLElement(el))
|
|
38609
|
+
targets: firstValue.filter((el) => isHTMLElement$2(el))
|
|
38398
38610
|
};
|
|
38399
38611
|
}
|
|
38400
38612
|
if (typeof firstValue === "string") {
|
|
@@ -38625,13 +38837,13 @@ var init_dist = __esm({
|
|
|
38625
38837
|
}
|
|
38626
38838
|
case "element": {
|
|
38627
38839
|
let elements;
|
|
38628
|
-
if (isHTMLElement(firstValue)) {
|
|
38840
|
+
if (isHTMLElement$2(firstValue)) {
|
|
38629
38841
|
elements = [firstValue];
|
|
38630
|
-
} else if (Array.isArray(firstValue) && firstValue.every((el) => isHTMLElement(el))) {
|
|
38842
|
+
} else if (Array.isArray(firstValue) && firstValue.every((el) => isHTMLElement$2(el))) {
|
|
38631
38843
|
elements = firstValue;
|
|
38632
38844
|
} else if (expression) {
|
|
38633
38845
|
const selected = document.querySelectorAll(expression);
|
|
38634
|
-
elements = Array.from(selected).filter((el) => isHTMLElement(el));
|
|
38846
|
+
elements = Array.from(selected).filter((el) => isHTMLElement$2(el));
|
|
38635
38847
|
} else {
|
|
38636
38848
|
elements = await resolveTargetsFromArgs([firstArg], evaluator, context, "toggle", resolveOpts, raw.modifiers);
|
|
38637
38849
|
}
|
|
@@ -38933,23 +39145,23 @@ var init_dist = __esm({
|
|
|
38933
39145
|
}
|
|
38934
39146
|
async resolveTargets(sel, ctx) {
|
|
38935
39147
|
if (!sel || sel === "me") {
|
|
38936
|
-
if (!ctx.me || !isHTMLElement(ctx.me))
|
|
39148
|
+
if (!ctx.me || !isHTMLElement$2(ctx.me))
|
|
38937
39149
|
throw new Error("put: no target and context.me is null");
|
|
38938
39150
|
return [ctx.me];
|
|
38939
39151
|
}
|
|
38940
|
-
const els = Array.from(document.querySelectorAll(sel)).filter((e) => isHTMLElement(e));
|
|
39152
|
+
const els = Array.from(document.querySelectorAll(sel)).filter((e) => isHTMLElement$2(e));
|
|
38941
39153
|
if (!els.length)
|
|
38942
39154
|
throw new Error(`No elements: "${sel}"`);
|
|
38943
39155
|
return els;
|
|
38944
39156
|
}
|
|
38945
39157
|
parseValue(v2) {
|
|
38946
|
-
if (isHTMLElement(v2))
|
|
39158
|
+
if (isHTMLElement$2(v2))
|
|
38947
39159
|
return v2;
|
|
38948
39160
|
return v2 == null ? "" : String(v2);
|
|
38949
39161
|
}
|
|
38950
39162
|
insertContent(target, content, pos2) {
|
|
38951
39163
|
if (pos2 === "replace") {
|
|
38952
|
-
if (isHTMLElement(content)) {
|
|
39164
|
+
if (isHTMLElement$2(content)) {
|
|
38953
39165
|
target.innerHTML = "";
|
|
38954
39166
|
target.appendChild(content);
|
|
38955
39167
|
} else {
|
|
@@ -38961,7 +39173,7 @@ var init_dist = __esm({
|
|
|
38961
39173
|
}
|
|
38962
39174
|
return;
|
|
38963
39175
|
}
|
|
38964
|
-
if (isHTMLElement(content)) {
|
|
39176
|
+
if (isHTMLElement$2(content)) {
|
|
38965
39177
|
const el = content;
|
|
38966
39178
|
switch (pos2) {
|
|
38967
39179
|
case "beforebegin":
|
|
@@ -38986,14 +39198,14 @@ var init_dist = __esm({
|
|
|
38986
39198
|
}
|
|
38987
39199
|
}
|
|
38988
39200
|
resolveEvaluatedAsElements(ev) {
|
|
38989
|
-
if (isHTMLElement(ev))
|
|
39201
|
+
if (isHTMLElement$2(ev))
|
|
38990
39202
|
return [ev];
|
|
38991
39203
|
if (Array.isArray(ev)) {
|
|
38992
|
-
const elements = ev.filter(isHTMLElement);
|
|
39204
|
+
const elements = ev.filter(isHTMLElement$2);
|
|
38993
39205
|
return elements.length > 0 ? elements : null;
|
|
38994
39206
|
}
|
|
38995
39207
|
if (typeof NodeList !== "undefined" && ev instanceof NodeList) {
|
|
38996
|
-
const elements = Array.from(ev).filter(isHTMLElement);
|
|
39208
|
+
const elements = Array.from(ev).filter(isHTMLElement$2);
|
|
38997
39209
|
return elements.length > 0 ? elements : null;
|
|
38998
39210
|
}
|
|
38999
39211
|
return null;
|
|
@@ -39150,7 +39362,7 @@ var init_dist = __esm({
|
|
|
39150
39362
|
const typed = input;
|
|
39151
39363
|
if (!Array.isArray(typed.targets))
|
|
39152
39364
|
return false;
|
|
39153
|
-
return typed.targets.every((t) => isHTMLElement(t));
|
|
39365
|
+
return typed.targets.every((t) => isHTMLElement$2(t));
|
|
39154
39366
|
}
|
|
39155
39367
|
};
|
|
39156
39368
|
__setFunctionName(_classThis, "EmptyCommand");
|
|
@@ -39217,7 +39429,7 @@ var init_dist = __esm({
|
|
|
39217
39429
|
const typed = input;
|
|
39218
39430
|
if (!Array.isArray(typed.targets))
|
|
39219
39431
|
return false;
|
|
39220
|
-
if (!typed.targets.every((t) => isHTMLElement(t)))
|
|
39432
|
+
if (!typed.targets.every((t) => isHTMLElement$2(t)))
|
|
39221
39433
|
return false;
|
|
39222
39434
|
return typed.dialogMode === "modal" || typed.dialogMode === "non-modal";
|
|
39223
39435
|
}
|
|
@@ -39274,7 +39486,7 @@ var init_dist = __esm({
|
|
|
39274
39486
|
const typed = input;
|
|
39275
39487
|
if (!Array.isArray(typed.targets))
|
|
39276
39488
|
return false;
|
|
39277
|
-
return typed.targets.every((t) => isHTMLElement(t));
|
|
39489
|
+
return typed.targets.every((t) => isHTMLElement$2(t));
|
|
39278
39490
|
}
|
|
39279
39491
|
};
|
|
39280
39492
|
__setFunctionName(_classThis, "CloseCommand");
|
|
@@ -39333,7 +39545,7 @@ var init_dist = __esm({
|
|
|
39333
39545
|
const typed = input;
|
|
39334
39546
|
if (!Array.isArray(typed.targets))
|
|
39335
39547
|
return false;
|
|
39336
|
-
return typed.targets.every((t) => isHTMLElement(t));
|
|
39548
|
+
return typed.targets.every((t) => isHTMLElement$2(t));
|
|
39337
39549
|
}
|
|
39338
39550
|
};
|
|
39339
39551
|
__setFunctionName(_classThis, "SelectCommand");
|
|
@@ -39375,7 +39587,7 @@ var init_dist = __esm({
|
|
|
39375
39587
|
const typed = input;
|
|
39376
39588
|
if (!Array.isArray(typed.targets))
|
|
39377
39589
|
return false;
|
|
39378
|
-
return typed.targets.every((t) => isHTMLElement(t));
|
|
39590
|
+
return typed.targets.every((t) => isHTMLElement$2(t));
|
|
39379
39591
|
}
|
|
39380
39592
|
};
|
|
39381
39593
|
__setFunctionName(_classThis, "ResetCommand");
|
|
@@ -40010,7 +40222,7 @@ var init_dist = __esm({
|
|
|
40010
40222
|
let targetSelector = null;
|
|
40011
40223
|
if (typeof targetArg === "string") {
|
|
40012
40224
|
targetSelector = targetArg;
|
|
40013
|
-
} else if (isHTMLElement(targetArg)) {
|
|
40225
|
+
} else if (isHTMLElement$2(targetArg)) {
|
|
40014
40226
|
return {
|
|
40015
40227
|
targets: [targetArg],
|
|
40016
40228
|
content: extractContent(contentArg),
|
|
@@ -40145,7 +40357,7 @@ var init_dist = __esm({
|
|
|
40145
40357
|
let targets;
|
|
40146
40358
|
if (typeof targetArg === "string") {
|
|
40147
40359
|
targets = await resolveTargets(targetArg, context);
|
|
40148
|
-
} else if (isHTMLElement(targetArg)) {
|
|
40360
|
+
} else if (isHTMLElement$2(targetArg)) {
|
|
40149
40361
|
targets = [targetArg];
|
|
40150
40362
|
} else {
|
|
40151
40363
|
throw new Error("[HyperFixi] morph: target must be a selector or element");
|
|
@@ -40334,7 +40546,7 @@ var init_dist = __esm({
|
|
|
40334
40546
|
let html;
|
|
40335
40547
|
if (typeof contentArg === "string") {
|
|
40336
40548
|
html = contentArg;
|
|
40337
|
-
} else if (isHTMLElement(contentArg)) {
|
|
40549
|
+
} else if (isHTMLElement$2(contentArg)) {
|
|
40338
40550
|
html = contentArg.outerHTML;
|
|
40339
40551
|
} else if (contentArg && typeof contentArg.text === "function") {
|
|
40340
40552
|
html = await contentArg.text();
|
|
@@ -40771,7 +40983,7 @@ var init_dist = __esm({
|
|
|
40771
40983
|
const doc = new DOMParser().parseFromString(html, "text/html");
|
|
40772
40984
|
const fragment = document.createDocumentFragment();
|
|
40773
40985
|
Array.from(doc.body.childNodes).forEach((n) => fragment.appendChild(n.cloneNode(true)));
|
|
40774
|
-
if (fragment.childNodes.length === 1 && isHTMLElement(fragment.firstChild))
|
|
40986
|
+
if (fragment.childNodes.length === 1 && isHTMLElement$2(fragment.firstChild))
|
|
40775
40987
|
return fragment.firstChild;
|
|
40776
40988
|
return fragment;
|
|
40777
40989
|
}
|
|
@@ -40807,6 +41019,7 @@ var init_dist = __esm({
|
|
|
40807
41019
|
}
|
|
40808
41020
|
const firstArg = raw.args[0];
|
|
40809
41021
|
const argName = firstArg?.name || firstArg?.value;
|
|
41022
|
+
const argScope = firstArg?.scope;
|
|
40810
41023
|
const firstArgType = firstArg?.type;
|
|
40811
41024
|
if (firstArgType) {
|
|
40812
41025
|
const writer = getRegisteredNodeWriter(firstArgType);
|
|
@@ -40882,11 +41095,11 @@ var init_dist = __esm({
|
|
|
40882
41095
|
return { type: "property", element, property: match[2], value: value2 };
|
|
40883
41096
|
}
|
|
40884
41097
|
}
|
|
40885
|
-
if (isHTMLElement(firstValue)) {
|
|
41098
|
+
if (isHTMLElement$2(firstValue)) {
|
|
40886
41099
|
const value2 = await this.extractValue(raw, evaluator, context);
|
|
40887
41100
|
return { type: "property", element: firstValue, property: "textContent", value: value2 };
|
|
40888
41101
|
}
|
|
40889
|
-
if (Array.isArray(firstValue) && firstValue.length > 0 && isHTMLElement(firstValue[0])) {
|
|
41102
|
+
if (Array.isArray(firstValue) && firstValue.length > 0 && isHTMLElement$2(firstValue[0])) {
|
|
40890
41103
|
const value2 = await this.extractValue(raw, evaluator, context);
|
|
40891
41104
|
return { type: "property", element: firstValue[0], property: "textContent", value: value2 };
|
|
40892
41105
|
}
|
|
@@ -40896,12 +41109,19 @@ var init_dist = __esm({
|
|
|
40896
41109
|
throw new Error(`set command target must be a string or object literal${hint}`);
|
|
40897
41110
|
}
|
|
40898
41111
|
const value = await this.extractValue(raw, evaluator, context);
|
|
40899
|
-
|
|
41112
|
+
const scope = argScope === "element" || argScope === "global" ? argScope : void 0;
|
|
41113
|
+
return { type: "variable", name: firstValue, value, scope };
|
|
40900
41114
|
}
|
|
40901
41115
|
async execute(input, context) {
|
|
40902
41116
|
switch (input.type) {
|
|
40903
41117
|
case "variable":
|
|
40904
|
-
|
|
41118
|
+
if (input.scope === "element") {
|
|
41119
|
+
setElementVar(context, input.name, input.value);
|
|
41120
|
+
} else if (input.scope === "global") {
|
|
41121
|
+
setVariableValue(input.name, input.value, context, "global");
|
|
41122
|
+
} else {
|
|
41123
|
+
setVariableValue(input.name, input.value, context);
|
|
41124
|
+
}
|
|
40905
41125
|
if (input.name === "result" || input.name === "it") {
|
|
40906
41126
|
Object.assign(context, { [input.name]: input.value });
|
|
40907
41127
|
}
|
|
@@ -40970,7 +41190,7 @@ var init_dist = __esm({
|
|
|
40970
41190
|
async evaluateToElement(node, evaluator, context) {
|
|
40971
41191
|
const value = await evaluator.evaluate(node, context);
|
|
40972
41192
|
const el = Array.isArray(value) ? value[0] : value;
|
|
40973
|
-
return isHTMLElement(el) ? el : null;
|
|
41193
|
+
return isHTMLElement$2(el) ? el : null;
|
|
40974
41194
|
}
|
|
40975
41195
|
async tryParseMemberExpression(firstArg, raw, evaluator, context) {
|
|
40976
41196
|
const objectNode = firstArg.object;
|
|
@@ -41057,11 +41277,11 @@ var init_dist = __esm({
|
|
|
41057
41277
|
case "variable":
|
|
41058
41278
|
return typeof obj.name === "string" && "value" in obj;
|
|
41059
41279
|
case "attribute":
|
|
41060
|
-
return typeof obj.name === "string" && Array.isArray(obj.elements) && obj.elements.every(isHTMLElement) && "value" in obj;
|
|
41280
|
+
return typeof obj.name === "string" && Array.isArray(obj.elements) && obj.elements.every(isHTMLElement$2) && "value" in obj;
|
|
41061
41281
|
case "property":
|
|
41062
|
-
return typeof obj.property === "string" && isHTMLElement(obj.element) && "value" in obj;
|
|
41282
|
+
return typeof obj.property === "string" && isHTMLElement$2(obj.element) && "value" in obj;
|
|
41063
41283
|
case "style":
|
|
41064
|
-
return typeof obj.property === "string" && obj.property !== "" && isHTMLElement(obj.element) && typeof obj.value === "string";
|
|
41284
|
+
return typeof obj.property === "string" && obj.property !== "" && isHTMLElement$2(obj.element) && typeof obj.value === "string";
|
|
41065
41285
|
case "object-literal":
|
|
41066
41286
|
return obj.properties !== null && typeof obj.properties === "object" && Array.isArray(obj.targets) && obj.targets.length > 0;
|
|
41067
41287
|
default:
|
|
@@ -41201,7 +41421,7 @@ var init_dist = __esm({
|
|
|
41201
41421
|
if (firstArg && (firstArgType === "variable" || firstArgType === "identifier" && typeof firstArgName === "string")) {
|
|
41202
41422
|
try {
|
|
41203
41423
|
const evaluated = await evaluator.evaluate(firstArg, context);
|
|
41204
|
-
if (isHTMLElement(evaluated) || Array.isArray(evaluated)) {
|
|
41424
|
+
if (isHTMLElement$2(evaluated) || Array.isArray(evaluated)) {
|
|
41205
41425
|
} else {
|
|
41206
41426
|
return { type: "variable", name: firstArgName };
|
|
41207
41427
|
}
|
|
@@ -41236,7 +41456,7 @@ var init_dist = __esm({
|
|
|
41236
41456
|
return typeof typed.name === "string";
|
|
41237
41457
|
if (typed.type === "form-fields") {
|
|
41238
41458
|
const targets = typed.targets;
|
|
41239
|
-
return Array.isArray(targets) && targets.every((t) => isHTMLElement(t));
|
|
41459
|
+
return Array.isArray(targets) && targets.every((t) => isHTMLElement$2(t));
|
|
41240
41460
|
}
|
|
41241
41461
|
return false;
|
|
41242
41462
|
}
|
|
@@ -41395,23 +41615,23 @@ var init_dist = __esm({
|
|
|
41395
41615
|
targets.push(context.it);
|
|
41396
41616
|
continue;
|
|
41397
41617
|
}
|
|
41398
|
-
if (isHTMLElement(val)) {
|
|
41618
|
+
if (isHTMLElement$2(val)) {
|
|
41399
41619
|
targets.push(val);
|
|
41400
41620
|
continue;
|
|
41401
41621
|
}
|
|
41402
41622
|
if (val instanceof NodeList) {
|
|
41403
|
-
targets.push(...Array.from(val).filter(isHTMLElement));
|
|
41623
|
+
targets.push(...Array.from(val).filter(isHTMLElement$2));
|
|
41404
41624
|
continue;
|
|
41405
41625
|
}
|
|
41406
41626
|
if (Array.isArray(val)) {
|
|
41407
|
-
targets.push(...val.filter(isHTMLElement));
|
|
41627
|
+
targets.push(...val.filter(isHTMLElement$2));
|
|
41408
41628
|
continue;
|
|
41409
41629
|
}
|
|
41410
41630
|
if (typeof val === "string") {
|
|
41411
41631
|
const els = document.querySelectorAll(val);
|
|
41412
41632
|
if (els.length === 0)
|
|
41413
41633
|
throw new Error(`No elements found: "${val}"`);
|
|
41414
|
-
targets.push(...Array.from(els).filter(isHTMLElement));
|
|
41634
|
+
targets.push(...Array.from(els).filter(isHTMLElement$2));
|
|
41415
41635
|
continue;
|
|
41416
41636
|
}
|
|
41417
41637
|
if (val && typeof val === "object" && "addEventListener" in val) {
|
|
@@ -41716,14 +41936,14 @@ var init_dist = __esm({
|
|
|
41716
41936
|
return document.body;
|
|
41717
41937
|
if (str === "html" && typeof document !== "undefined")
|
|
41718
41938
|
return document.documentElement;
|
|
41719
|
-
if (str === "me" && isHTMLElement(context.me))
|
|
41939
|
+
if (str === "me" && isHTMLElement$2(context.me))
|
|
41720
41940
|
return context.me;
|
|
41721
|
-
if (str === "it" && isHTMLElement(context.it))
|
|
41941
|
+
if (str === "it" && isHTMLElement$2(context.it))
|
|
41722
41942
|
return context.it;
|
|
41723
|
-
if (str === "you" && isHTMLElement(context.you))
|
|
41943
|
+
if (str === "you" && isHTMLElement$2(context.you))
|
|
41724
41944
|
return context.you;
|
|
41725
41945
|
const variable = getVariableValue(str, context);
|
|
41726
|
-
if (isHTMLElement(variable))
|
|
41946
|
+
if (isHTMLElement$2(variable))
|
|
41727
41947
|
return variable;
|
|
41728
41948
|
if (typeof document !== "undefined") {
|
|
41729
41949
|
try {
|
|
@@ -41909,18 +42129,18 @@ var init_dist = __esm({
|
|
|
41909
42129
|
}
|
|
41910
42130
|
if (typeof a !== "string" || skip.has(a))
|
|
41911
42131
|
continue;
|
|
41912
|
-
if (a === "me" && isHTMLElement(context.me))
|
|
42132
|
+
if (a === "me" && isHTMLElement$2(context.me))
|
|
41913
42133
|
return context.me;
|
|
41914
|
-
if (a === "it" && isHTMLElement(context.it))
|
|
42134
|
+
if (a === "it" && isHTMLElement$2(context.it))
|
|
41915
42135
|
return context.it;
|
|
41916
|
-
if (a === "you" && isHTMLElement(context.you))
|
|
42136
|
+
if (a === "you" && isHTMLElement$2(context.you))
|
|
41917
42137
|
return context.you;
|
|
41918
42138
|
if (a === "body" && typeof document !== "undefined")
|
|
41919
42139
|
return document.body;
|
|
41920
42140
|
if (a === "html" && typeof document !== "undefined")
|
|
41921
42141
|
return document.documentElement;
|
|
41922
42142
|
const variable = getVariableValue(a, context);
|
|
41923
|
-
if (isHTMLElement(variable))
|
|
42143
|
+
if (isHTMLElement$2(variable))
|
|
41924
42144
|
return variable;
|
|
41925
42145
|
if (typeof document !== "undefined") {
|
|
41926
42146
|
try {
|
|
@@ -42585,7 +42805,7 @@ var init_dist = __esm({
|
|
|
42585
42805
|
const typed = input;
|
|
42586
42806
|
if (!Array.isArray(typed.targets))
|
|
42587
42807
|
return false;
|
|
42588
|
-
return typed.targets.every((t) => isHTMLElement(t));
|
|
42808
|
+
return typed.targets.every((t) => isHTMLElement$2(t));
|
|
42589
42809
|
}
|
|
42590
42810
|
};
|
|
42591
42811
|
__setFunctionName(_classThis, "FocusCommand");
|
|
@@ -42625,7 +42845,7 @@ var init_dist = __esm({
|
|
|
42625
42845
|
const typed = input;
|
|
42626
42846
|
if (!Array.isArray(typed.targets))
|
|
42627
42847
|
return false;
|
|
42628
|
-
return typed.targets.every((t) => isHTMLElement(t));
|
|
42848
|
+
return typed.targets.every((t) => isHTMLElement$2(t));
|
|
42629
42849
|
}
|
|
42630
42850
|
};
|
|
42631
42851
|
__setFunctionName(_classThis, "BlurCommand");
|
|
@@ -42690,14 +42910,14 @@ var init_dist = __esm({
|
|
|
42690
42910
|
}
|
|
42691
42911
|
if (target === "me" || target === "it" || target === "you") {
|
|
42692
42912
|
const ctxTarget = this.resolveContextRef(target, context);
|
|
42693
|
-
if (isHTMLElement(ctxTarget)) {
|
|
42913
|
+
if (isHTMLElement$2(ctxTarget)) {
|
|
42694
42914
|
ctxTarget.innerHTML += contentStr;
|
|
42695
42915
|
return { result: ctxTarget, targetType: "element", target: ctxTarget };
|
|
42696
42916
|
}
|
|
42697
42917
|
}
|
|
42698
42918
|
const current = getVariableValue(target, context);
|
|
42699
42919
|
if (current !== void 0) {
|
|
42700
|
-
if (isHTMLElement(current)) {
|
|
42920
|
+
if (isHTMLElement$2(current)) {
|
|
42701
42921
|
current.innerHTML += contentStr;
|
|
42702
42922
|
return { result: current, targetType: "element", target: current };
|
|
42703
42923
|
}
|
|
@@ -42715,7 +42935,7 @@ var init_dist = __esm({
|
|
|
42715
42935
|
} else if (Array.isArray(target)) {
|
|
42716
42936
|
target.push(content);
|
|
42717
42937
|
return { result: target, targetType: "array" };
|
|
42718
|
-
} else if (isHTMLElement(target)) {
|
|
42938
|
+
} else if (isHTMLElement$2(target)) {
|
|
42719
42939
|
target.innerHTML += contentStr;
|
|
42720
42940
|
return { result: target, targetType: "element", target };
|
|
42721
42941
|
} else {
|
|
@@ -42777,7 +42997,7 @@ var init_dist = __esm({
|
|
|
42777
42997
|
let property;
|
|
42778
42998
|
let target;
|
|
42779
42999
|
const firstArg = await evaluator.evaluate(raw.args[0], context);
|
|
42780
|
-
if (isHTMLElement(firstArg) || typeof firstArg === "string" && /^[#.]|^(?:me|it|you)$/.test(firstArg)) {
|
|
43000
|
+
if (isHTMLElement$2(firstArg) || typeof firstArg === "string" && /^[#.]|^(?:me|it|you)$/.test(firstArg)) {
|
|
42781
43001
|
target = firstArg;
|
|
42782
43002
|
property = String(await evaluator.evaluate(raw.args[1], context));
|
|
42783
43003
|
} else {
|
|
@@ -42872,7 +43092,7 @@ var init_dist = __esm({
|
|
|
42872
43092
|
const name = first.name.toLowerCase();
|
|
42873
43093
|
if (name === "me" || name === "it" || name === "you") {
|
|
42874
43094
|
const ev = await evaluator.evaluate(first, context);
|
|
42875
|
-
if (isHTMLElement(ev)) {
|
|
43095
|
+
if (isHTMLElement$2(ev)) {
|
|
42876
43096
|
target = ev;
|
|
42877
43097
|
if (raw.args.length > 1) {
|
|
42878
43098
|
const s = raw.args[1];
|
|
@@ -42884,7 +43104,7 @@ var init_dist = __esm({
|
|
|
42884
43104
|
}
|
|
42885
43105
|
} else {
|
|
42886
43106
|
const ev = await evaluator.evaluate(first, context);
|
|
42887
|
-
if (isHTMLElement(ev) || typeof ev === "string" && /^[#.]/.test(ev)) {
|
|
43107
|
+
if (isHTMLElement$2(ev) || typeof ev === "string" && /^[#.]/.test(ev)) {
|
|
42888
43108
|
target = ev;
|
|
42889
43109
|
if (raw.args.length > 1) {
|
|
42890
43110
|
const s = raw.args[1];
|
|
@@ -43004,7 +43224,7 @@ var init_dist = __esm({
|
|
|
43004
43224
|
let timeout;
|
|
43005
43225
|
if (raw.args && raw.args.length > 0) {
|
|
43006
43226
|
const firstArg = await evaluator.evaluate(raw.args[0], context);
|
|
43007
|
-
if (isHTMLElement(firstArg) || typeof firstArg === "string" && (firstArg.startsWith("#") || firstArg.startsWith(".") || firstArg === "me" || firstArg === "it" || firstArg === "you")) {
|
|
43227
|
+
if (isHTMLElement$2(firstArg) || typeof firstArg === "string" && (firstArg.startsWith("#") || firstArg.startsWith(".") || firstArg === "me" || firstArg === "it" || firstArg === "you")) {
|
|
43008
43228
|
target = firstArg;
|
|
43009
43229
|
}
|
|
43010
43230
|
}
|
|
@@ -43342,7 +43562,7 @@ var init_dist = __esm({
|
|
|
43342
43562
|
}
|
|
43343
43563
|
return this.defaultVariable(context, target, value);
|
|
43344
43564
|
}
|
|
43345
|
-
if (isHTMLElement(target)) {
|
|
43565
|
+
if (isHTMLElement$2(target)) {
|
|
43346
43566
|
return this.defaultElementValue(context, target, value);
|
|
43347
43567
|
}
|
|
43348
43568
|
throw new Error(`Invalid target type: ${typeof target}`);
|
|
@@ -43734,10 +43954,10 @@ var init_dist = __esm({
|
|
|
43734
43954
|
extractText(source, format, context) {
|
|
43735
43955
|
if (typeof source === "string")
|
|
43736
43956
|
return source;
|
|
43737
|
-
if (isHTMLElement(source)) {
|
|
43957
|
+
if (isHTMLElement$2(source)) {
|
|
43738
43958
|
return format === "html" ? source.outerHTML : source.textContent || "";
|
|
43739
43959
|
}
|
|
43740
|
-
if (source === context.me && isHTMLElement(context.me)) {
|
|
43960
|
+
if (source === context.me && isHTMLElement$2(context.me)) {
|
|
43741
43961
|
const el = context.me;
|
|
43742
43962
|
return format === "html" ? el.outerHTML : el.textContent || "";
|
|
43743
43963
|
}
|
|
@@ -43763,7 +43983,7 @@ var init_dist = __esm({
|
|
|
43763
43983
|
}
|
|
43764
43984
|
}
|
|
43765
43985
|
dispatchCopyEvent(context, eventName, detail) {
|
|
43766
|
-
if (isHTMLElement(context.me)) {
|
|
43986
|
+
if (isHTMLElement$2(context.me)) {
|
|
43767
43987
|
const event = new CustomEvent(eventName, { detail, bubbles: true, cancelable: false });
|
|
43768
43988
|
context.me.dispatchEvent(event);
|
|
43769
43989
|
}
|
|
@@ -44103,7 +44323,7 @@ var init_dist = __esm({
|
|
|
44103
44323
|
return "undefined";
|
|
44104
44324
|
if (Array.isArray(value))
|
|
44105
44325
|
return "array";
|
|
44106
|
-
if (isHTMLElement(value))
|
|
44326
|
+
if (isHTMLElement$2(value))
|
|
44107
44327
|
return "HTMLElement";
|
|
44108
44328
|
if (value instanceof Element)
|
|
44109
44329
|
return "Element";
|
|
@@ -44125,7 +44345,7 @@ var init_dist = __esm({
|
|
|
44125
44345
|
if (Array.isArray(value)) {
|
|
44126
44346
|
return `Array(${value.length}) [${value.slice(0, 3).map((v2) => this.getRepresentation(v2)).join(", ")}${value.length > 3 ? "..." : ""}]`;
|
|
44127
44347
|
}
|
|
44128
|
-
if (isHTMLElement(value)) {
|
|
44348
|
+
if (isHTMLElement$2(value)) {
|
|
44129
44349
|
const el = value;
|
|
44130
44350
|
const tag = el.tagName.toLowerCase();
|
|
44131
44351
|
const id = el.id ? `#${el.id}` : "";
|
|
@@ -44262,16 +44482,16 @@ var init_dist = __esm({
|
|
|
44262
44482
|
resolveTarget(target, context) {
|
|
44263
44483
|
if (target === void 0 || target === null) {
|
|
44264
44484
|
const me = context.me || context.locals.get("me");
|
|
44265
|
-
if (isHTMLElement(me)) {
|
|
44485
|
+
if (isHTMLElement$2(me)) {
|
|
44266
44486
|
return [me];
|
|
44267
44487
|
}
|
|
44268
44488
|
throw new Error('No target specified and "me" is not available in context');
|
|
44269
44489
|
}
|
|
44270
|
-
if (isHTMLElement(target)) {
|
|
44490
|
+
if (isHTMLElement$2(target)) {
|
|
44271
44491
|
return [target];
|
|
44272
44492
|
}
|
|
44273
44493
|
if (Array.isArray(target)) {
|
|
44274
|
-
const elements = target.filter((t) => isHTMLElement(t));
|
|
44494
|
+
const elements = target.filter((t) => isHTMLElement$2(t));
|
|
44275
44495
|
if (elements.length === 0) {
|
|
44276
44496
|
throw new Error("Target array contains no valid HTMLElements");
|
|
44277
44497
|
}
|
|
@@ -44280,14 +44500,14 @@ var init_dist = __esm({
|
|
|
44280
44500
|
if (typeof target === "string") {
|
|
44281
44501
|
if (target === "me") {
|
|
44282
44502
|
const me = context.me || context.locals.get("me");
|
|
44283
|
-
if (isHTMLElement(me)) {
|
|
44503
|
+
if (isHTMLElement$2(me)) {
|
|
44284
44504
|
return [me];
|
|
44285
44505
|
}
|
|
44286
44506
|
throw new Error('"me" is not available in context');
|
|
44287
44507
|
}
|
|
44288
44508
|
if (typeof document !== "undefined") {
|
|
44289
44509
|
const elements = document.querySelectorAll(target);
|
|
44290
|
-
const htmlElements = Array.from(elements).filter((el) => isHTMLElement(el));
|
|
44510
|
+
const htmlElements = Array.from(elements).filter((el) => isHTMLElement$2(el));
|
|
44291
44511
|
if (htmlElements.length === 0) {
|
|
44292
44512
|
throw new Error(`No elements found matching selector: "${target}"`);
|
|
44293
44513
|
}
|
|
@@ -44296,7 +44516,7 @@ var init_dist = __esm({
|
|
|
44296
44516
|
throw new Error("document is not available (not in browser environment)");
|
|
44297
44517
|
}
|
|
44298
44518
|
if (target && typeof target === "object" && "length" in target) {
|
|
44299
|
-
const elements = Array.from(target).filter((t) => isHTMLElement(t));
|
|
44519
|
+
const elements = Array.from(target).filter((t) => isHTMLElement$2(t));
|
|
44300
44520
|
if (elements.length === 0) {
|
|
44301
44521
|
throw new Error("Target collection contains no valid HTMLElements");
|
|
44302
44522
|
}
|
|
@@ -44304,7 +44524,7 @@ var init_dist = __esm({
|
|
|
44304
44524
|
}
|
|
44305
44525
|
if (typeof target === "object" && "element" in target) {
|
|
44306
44526
|
const element = target.element;
|
|
44307
|
-
if (isHTMLElement(element)) {
|
|
44527
|
+
if (isHTMLElement$2(element)) {
|
|
44308
44528
|
return [element];
|
|
44309
44529
|
}
|
|
44310
44530
|
}
|
|
@@ -48496,7 +48716,10 @@ ${body}
|
|
|
48496
48716
|
WhitespaceExtractor,
|
|
48497
48717
|
accumulateBlocks,
|
|
48498
48718
|
buildDisambiguation,
|
|
48719
|
+
buildDomainTokenizer,
|
|
48499
48720
|
buildFeedback,
|
|
48721
|
+
buildLanguageConfig,
|
|
48722
|
+
buildPatternProfile,
|
|
48500
48723
|
buildPhrase,
|
|
48501
48724
|
buildTablesFromProfiles,
|
|
48502
48725
|
combineClassifiers,
|
|
@@ -48527,6 +48750,7 @@ ${body}
|
|
|
48527
48750
|
createUnicodeRangeClassifier,
|
|
48528
48751
|
defineCommand,
|
|
48529
48752
|
defineRole,
|
|
48753
|
+
deriveRoleMarkers,
|
|
48530
48754
|
detectWordOrders,
|
|
48531
48755
|
extractCssSelector: extractCssSelector$1,
|
|
48532
48756
|
extractNumber,
|
|
@@ -74612,6 +74836,7 @@ ${body}
|
|
|
74612
74836
|
getEventHandlerPatternsForLanguage,
|
|
74613
74837
|
getGeneratorSummary,
|
|
74614
74838
|
getHyperscriptExtractors,
|
|
74839
|
+
getKeywordTranslations,
|
|
74615
74840
|
getLoadedLanguages,
|
|
74616
74841
|
getPatternById,
|
|
74617
74842
|
getPatternStats,
|
|
@@ -74620,6 +74845,7 @@ ${body}
|
|
|
74620
74845
|
getPutPatternsForLanguage,
|
|
74621
74846
|
getRegisteredLanguages,
|
|
74622
74847
|
getRegisteredMappers,
|
|
74848
|
+
getRoleMarkers,
|
|
74623
74849
|
getSchema,
|
|
74624
74850
|
getSchemasByCategory,
|
|
74625
74851
|
getSupportedCommands,
|
|
@@ -75139,7 +75365,8 @@ ${body}
|
|
|
75139
75365
|
language: "en",
|
|
75140
75366
|
confidenceThreshold: DEFAULT_CONFIDENCE_THRESHOLD,
|
|
75141
75367
|
logAll: false,
|
|
75142
|
-
conversions: conversionConfig.conversions
|
|
75368
|
+
conversions: conversionConfig.conversions,
|
|
75369
|
+
onCompileError: null
|
|
75143
75370
|
};
|
|
75144
75371
|
_defaultRuntime = null;
|
|
75145
75372
|
_debugController = null;
|