unframer 2.22.0 → 2.22.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/framer.d.ts.map +1 -1
- package/dist/framer.js +215 -231
- package/dist/framer.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/esm/framer.d.ts.map +1 -1
- package/esm/framer.js +215 -231
- package/esm/framer.js.map +1 -1
- package/esm/version.d.ts +1 -1
- package/esm/version.js +1 -1
- package/package.json +2 -2
- package/src/framer.js +186 -207
- package/src/version.ts +1 -1
package/src/framer.js
CHANGED
|
@@ -10429,7 +10429,7 @@ function steps(numSteps, direction = 'end',) {
|
|
|
10429
10429
|
};
|
|
10430
10430
|
}
|
|
10431
10431
|
|
|
10432
|
-
// /:https://app.framerstatic.com/framer.
|
|
10432
|
+
// /:https://app.framerstatic.com/framer.VDKYGJXW.mjs
|
|
10433
10433
|
import React4 from 'react';
|
|
10434
10434
|
import { Suspense as Suspense3, } from 'react';
|
|
10435
10435
|
import { memo as memo2, startTransition as startTransition2, } from 'react';
|
|
@@ -13602,7 +13602,7 @@ var MarkSuspenseEffects = {
|
|
|
13602
13602
|
function renderPage(Page4, defaultPageStyle,) {
|
|
13603
13603
|
const props = {
|
|
13604
13604
|
style: defaultPageStyle,
|
|
13605
|
-
'data-framer-root':
|
|
13605
|
+
'data-framer-root': '',
|
|
13606
13606
|
};
|
|
13607
13607
|
return React4.isValidElement(Page4,) ? React4.cloneElement(Page4, props,) : React4.createElement(Page4, props,);
|
|
13608
13608
|
}
|
|
@@ -31364,26 +31364,36 @@ var CustomCursorContext = /* @__PURE__ */ createContext({
|
|
|
31364
31364
|
},);
|
|
31365
31365
|
var replaceCursorClassName = 'framer-cursor-none';
|
|
31366
31366
|
var cursorComponentClassName = 'framer-pointer-events-none';
|
|
31367
|
+
function getActiveDefinitions(map2, previousDefinitions, newDefinitions,) {
|
|
31368
|
+
const allCursors = {};
|
|
31369
|
+
for (const [, hashes,] of map2) {
|
|
31370
|
+
for (const hash2 of hashes) {
|
|
31371
|
+
const value = allCursors[hash2] ?? previousDefinitions[hash2] ?? newDefinitions[hash2];
|
|
31372
|
+
if (value) allCursors[hash2] = value;
|
|
31373
|
+
}
|
|
31374
|
+
}
|
|
31375
|
+
return allCursors;
|
|
31376
|
+
}
|
|
31367
31377
|
var CustomCursorContextProvider = /* @__PURE__ */ memo2(function CustomCursorList({
|
|
31368
31378
|
children,
|
|
31369
31379
|
},) {
|
|
31370
31380
|
const value = useConstant2(() => {
|
|
31371
31381
|
const events = /* @__PURE__ */ new Set();
|
|
31372
31382
|
let allCursors = {};
|
|
31383
|
+
const byCaller = /* @__PURE__ */ new Map();
|
|
31373
31384
|
return {
|
|
31374
31385
|
onRegisterCursors: (callback) => {
|
|
31375
31386
|
callback(allCursors,);
|
|
31376
31387
|
events.add(callback,);
|
|
31377
31388
|
return () => events.delete(callback,);
|
|
31378
31389
|
},
|
|
31379
|
-
registerCursors: (cursors) => {
|
|
31380
|
-
|
|
31381
|
-
|
|
31382
|
-
const cursor = allCursors[key7] ?? cursors[key7];
|
|
31383
|
-
if (cursor) nextCursors[key7] = cursor;
|
|
31384
|
-
}
|
|
31385
|
-
allCursors = nextCursors;
|
|
31390
|
+
registerCursors: (cursors, id3,) => {
|
|
31391
|
+
byCaller.set(id3, Object.keys(cursors,),);
|
|
31392
|
+
allCursors = getActiveDefinitions(byCaller, allCursors, cursors,);
|
|
31386
31393
|
for (const callback of events) callback(allCursors,);
|
|
31394
|
+
return () => {
|
|
31395
|
+
byCaller.delete(id3,);
|
|
31396
|
+
};
|
|
31387
31397
|
},
|
|
31388
31398
|
};
|
|
31389
31399
|
},);
|
|
@@ -31625,9 +31635,10 @@ function useCustomCursors(webPageCursors,) {
|
|
|
31625
31635
|
registerCursors,
|
|
31626
31636
|
} = useContext(CustomCursorContext,);
|
|
31627
31637
|
const cursors = useConstant2(() => webPageCursors);
|
|
31638
|
+
const id3 = useId();
|
|
31628
31639
|
useLayoutEffect(() => {
|
|
31629
|
-
registerCursors(cursors,);
|
|
31630
|
-
}, [registerCursors,],);
|
|
31640
|
+
return registerCursors(cursors, id3,);
|
|
31641
|
+
}, [registerCursors, id3,],);
|
|
31631
31642
|
}
|
|
31632
31643
|
var Polygon = {
|
|
31633
31644
|
/**
|
|
@@ -34845,6 +34856,19 @@ var CompatibilityDatabaseCollection = class {
|
|
|
34845
34856
|
return Number(left.pointer,) - Number(right.pointer,);
|
|
34846
34857
|
}
|
|
34847
34858
|
};
|
|
34859
|
+
function compareArray(left, right, collation11,) {
|
|
34860
|
+
const leftLength = left.value.length;
|
|
34861
|
+
const rightLength = right.value.length;
|
|
34862
|
+
if (leftLength < rightLength) return -1;
|
|
34863
|
+
if (leftLength > rightLength) return 1;
|
|
34864
|
+
for (let i = 0; i < leftLength; i++) {
|
|
34865
|
+
const leftItem = left.value[i];
|
|
34866
|
+
const rightItem = right.value[i];
|
|
34867
|
+
const result = compare(leftItem, rightItem, collation11,);
|
|
34868
|
+
if (result !== 0) return result;
|
|
34869
|
+
}
|
|
34870
|
+
return 0;
|
|
34871
|
+
}
|
|
34848
34872
|
function castArray(value, definition,) {
|
|
34849
34873
|
switch (value == null ? void 0 : value.type) {
|
|
34850
34874
|
case 'array': {
|
|
@@ -34859,6 +34883,11 @@ function castArray(value, definition,) {
|
|
|
34859
34883
|
}
|
|
34860
34884
|
return null;
|
|
34861
34885
|
}
|
|
34886
|
+
function compareBoolean(left, right,) {
|
|
34887
|
+
if (left.value < right.value) return -1;
|
|
34888
|
+
if (left.value > right.value) return 1;
|
|
34889
|
+
return 0;
|
|
34890
|
+
}
|
|
34862
34891
|
function castBoolean(value,) {
|
|
34863
34892
|
switch (value == null ? void 0 : value.type) {
|
|
34864
34893
|
case 'boolean': {
|
|
@@ -34874,10 +34903,15 @@ function castBoolean(value,) {
|
|
|
34874
34903
|
}
|
|
34875
34904
|
return null;
|
|
34876
34905
|
}
|
|
34877
|
-
function
|
|
34906
|
+
function valueToBoolean(value,) {
|
|
34878
34907
|
const cast = castBoolean(value,);
|
|
34879
34908
|
return (cast == null ? void 0 : cast.value) ?? false;
|
|
34880
34909
|
}
|
|
34910
|
+
function compareColor(left, right,) {
|
|
34911
|
+
if (left.value < right.value) return -1;
|
|
34912
|
+
if (left.value > right.value) return 1;
|
|
34913
|
+
return 0;
|
|
34914
|
+
}
|
|
34881
34915
|
function castColor(value,) {
|
|
34882
34916
|
switch (value == null ? void 0 : value.type) {
|
|
34883
34917
|
case 'color': {
|
|
@@ -34886,6 +34920,13 @@ function castColor(value,) {
|
|
|
34886
34920
|
}
|
|
34887
34921
|
return null;
|
|
34888
34922
|
}
|
|
34923
|
+
function compareDate(left, right,) {
|
|
34924
|
+
const leftDate = new Date(left.value,);
|
|
34925
|
+
const rightDate = new Date(right.value,);
|
|
34926
|
+
if (leftDate < rightDate) return -1;
|
|
34927
|
+
if (leftDate > rightDate) return 1;
|
|
34928
|
+
return 0;
|
|
34929
|
+
}
|
|
34889
34930
|
function castDate(value,) {
|
|
34890
34931
|
switch (value == null ? void 0 : value.type) {
|
|
34891
34932
|
case 'date': {
|
|
@@ -34905,6 +34946,11 @@ function castDate(value,) {
|
|
|
34905
34946
|
}
|
|
34906
34947
|
return null;
|
|
34907
34948
|
}
|
|
34949
|
+
function compareEnum(left, right,) {
|
|
34950
|
+
if (left.value < right.value) return -1;
|
|
34951
|
+
if (left.value > right.value) return 1;
|
|
34952
|
+
return 0;
|
|
34953
|
+
}
|
|
34908
34954
|
function castEnum(value,) {
|
|
34909
34955
|
switch (value == null ? void 0 : value.type) {
|
|
34910
34956
|
case 'enum': {
|
|
@@ -34919,6 +34965,11 @@ function castEnum(value,) {
|
|
|
34919
34965
|
}
|
|
34920
34966
|
return null;
|
|
34921
34967
|
}
|
|
34968
|
+
function compareFile(left, right,) {
|
|
34969
|
+
if (left.value < right.value) return -1;
|
|
34970
|
+
if (left.value > right.value) return 1;
|
|
34971
|
+
return 0;
|
|
34972
|
+
}
|
|
34922
34973
|
function castFile(value,) {
|
|
34923
34974
|
switch (value == null ? void 0 : value.type) {
|
|
34924
34975
|
case 'file': {
|
|
@@ -34927,6 +34978,13 @@ function castFile(value,) {
|
|
|
34927
34978
|
}
|
|
34928
34979
|
return null;
|
|
34929
34980
|
}
|
|
34981
|
+
function compareLink(left, right,) {
|
|
34982
|
+
const leftEncoded = JSON.stringify(left.value,);
|
|
34983
|
+
const rightEncoded = JSON.stringify(right.value,);
|
|
34984
|
+
if (leftEncoded < rightEncoded) return -1;
|
|
34985
|
+
if (leftEncoded > rightEncoded) return 1;
|
|
34986
|
+
return 0;
|
|
34987
|
+
}
|
|
34930
34988
|
function castLink(value,) {
|
|
34931
34989
|
switch (value == null ? void 0 : value.type) {
|
|
34932
34990
|
case 'link': {
|
|
@@ -34951,6 +35009,11 @@ function castLink(value,) {
|
|
|
34951
35009
|
}
|
|
34952
35010
|
return null;
|
|
34953
35011
|
}
|
|
35012
|
+
function compareNumber(left, right,) {
|
|
35013
|
+
if (left.value < right.value) return -1;
|
|
35014
|
+
if (left.value > right.value) return 1;
|
|
35015
|
+
return 0;
|
|
35016
|
+
}
|
|
34954
35017
|
function castNumber(value,) {
|
|
34955
35018
|
switch (value == null ? void 0 : value.type) {
|
|
34956
35019
|
case 'number':
|
|
@@ -34967,10 +35030,27 @@ function castNumber(value,) {
|
|
|
34967
35030
|
}
|
|
34968
35031
|
return null;
|
|
34969
35032
|
}
|
|
34970
|
-
function
|
|
35033
|
+
function valueToNumber(value,) {
|
|
34971
35034
|
const cast = castNumber(value,);
|
|
34972
35035
|
return (cast == null ? void 0 : cast.value) ?? null;
|
|
34973
35036
|
}
|
|
35037
|
+
function compareObject(left, right, collation11,) {
|
|
35038
|
+
const leftKeys = Object.keys(left.value,).sort();
|
|
35039
|
+
const rightKeys = Object.keys(right.value,).sort();
|
|
35040
|
+
if (leftKeys.length < rightKeys.length) return -1;
|
|
35041
|
+
if (leftKeys.length > rightKeys.length) return 1;
|
|
35042
|
+
for (let i = 0; i < leftKeys.length; i++) {
|
|
35043
|
+
const leftKey = leftKeys[i];
|
|
35044
|
+
const rightKey = rightKeys[i];
|
|
35045
|
+
if (leftKey < rightKey) return -1;
|
|
35046
|
+
if (leftKey > rightKey) return 1;
|
|
35047
|
+
const leftValue = left.value[leftKey] ?? null;
|
|
35048
|
+
const rightValue = right.value[rightKey] ?? null;
|
|
35049
|
+
const result = compare(leftValue, rightValue, collation11,);
|
|
35050
|
+
if (result !== 0) return result;
|
|
35051
|
+
}
|
|
35052
|
+
return 0;
|
|
35053
|
+
}
|
|
34974
35054
|
function castObject(value, definition,) {
|
|
34975
35055
|
switch (value == null ? void 0 : value.type) {
|
|
34976
35056
|
case 'object': {
|
|
@@ -34988,6 +35068,13 @@ function castObject(value, definition,) {
|
|
|
34988
35068
|
}
|
|
34989
35069
|
return null;
|
|
34990
35070
|
}
|
|
35071
|
+
function compareResponsiveImage(left, right,) {
|
|
35072
|
+
const leftEncoded = JSON.stringify(left.value,);
|
|
35073
|
+
const rightEncoded = JSON.stringify(right.value,);
|
|
35074
|
+
if (leftEncoded < rightEncoded) return -1;
|
|
35075
|
+
if (leftEncoded > rightEncoded) return 1;
|
|
35076
|
+
return 0;
|
|
35077
|
+
}
|
|
34991
35078
|
function castResponsiveImage(value,) {
|
|
34992
35079
|
switch (value == null ? void 0 : value.type) {
|
|
34993
35080
|
case 'responsiveimage': {
|
|
@@ -34996,6 +35083,13 @@ function castResponsiveImage(value,) {
|
|
|
34996
35083
|
}
|
|
34997
35084
|
return null;
|
|
34998
35085
|
}
|
|
35086
|
+
function compareRichText(left, right,) {
|
|
35087
|
+
const leftValue = left.value;
|
|
35088
|
+
const rightValue = right.value;
|
|
35089
|
+
if (leftValue < rightValue) return -1;
|
|
35090
|
+
if (leftValue > rightValue) return 1;
|
|
35091
|
+
return 0;
|
|
35092
|
+
}
|
|
34999
35093
|
function castRichText(value,) {
|
|
35000
35094
|
switch (value == null ? void 0 : value.type) {
|
|
35001
35095
|
case 'richtext': {
|
|
@@ -35004,6 +35098,17 @@ function castRichText(value,) {
|
|
|
35004
35098
|
}
|
|
35005
35099
|
return null;
|
|
35006
35100
|
}
|
|
35101
|
+
function compareString(left, right, collation11,) {
|
|
35102
|
+
let leftValue = left.value;
|
|
35103
|
+
let rightValue = right.value;
|
|
35104
|
+
if (collation11.type === 0) {
|
|
35105
|
+
leftValue = left.value.toLowerCase();
|
|
35106
|
+
rightValue = right.value.toLowerCase();
|
|
35107
|
+
}
|
|
35108
|
+
if (leftValue < rightValue) return -1;
|
|
35109
|
+
if (leftValue > rightValue) return 1;
|
|
35110
|
+
return 0;
|
|
35111
|
+
}
|
|
35007
35112
|
function castString(value,) {
|
|
35008
35113
|
switch (value == null ? void 0 : value.type) {
|
|
35009
35114
|
case 'string': {
|
|
@@ -35018,7 +35123,7 @@ function castString(value,) {
|
|
|
35018
35123
|
}
|
|
35019
35124
|
return null;
|
|
35020
35125
|
}
|
|
35021
|
-
function
|
|
35126
|
+
function valueToString(value,) {
|
|
35022
35127
|
const cast = castString(value,);
|
|
35023
35128
|
return (cast == null ? void 0 : cast.value) ?? null;
|
|
35024
35129
|
}
|
|
@@ -35166,8 +35271,8 @@ var DatabaseValue = {
|
|
|
35166
35271
|
},);
|
|
35167
35272
|
},
|
|
35168
35273
|
contains(source, target, collation11,) {
|
|
35169
|
-
let sourceValue =
|
|
35170
|
-
let targetValue =
|
|
35274
|
+
let sourceValue = valueToString(source,);
|
|
35275
|
+
let targetValue = valueToString(target,);
|
|
35171
35276
|
if (isNull(sourceValue,)) return false;
|
|
35172
35277
|
if (isNull(targetValue,)) return false;
|
|
35173
35278
|
if (collation11.type === 0) {
|
|
@@ -35177,8 +35282,8 @@ var DatabaseValue = {
|
|
|
35177
35282
|
return sourceValue.includes(targetValue,);
|
|
35178
35283
|
},
|
|
35179
35284
|
startsWith(source, target, collation11,) {
|
|
35180
|
-
let sourceValue =
|
|
35181
|
-
let targetValue =
|
|
35285
|
+
let sourceValue = valueToString(source,);
|
|
35286
|
+
let targetValue = valueToString(target,);
|
|
35182
35287
|
if (isNull(sourceValue,)) return false;
|
|
35183
35288
|
if (isNull(targetValue,)) return false;
|
|
35184
35289
|
if (collation11.type === 0) {
|
|
@@ -35188,8 +35293,8 @@ var DatabaseValue = {
|
|
|
35188
35293
|
return sourceValue.startsWith(targetValue,);
|
|
35189
35294
|
},
|
|
35190
35295
|
endsWith(source, target, collation11,) {
|
|
35191
|
-
let sourceValue =
|
|
35192
|
-
let targetValue =
|
|
35296
|
+
let sourceValue = valueToString(source,);
|
|
35297
|
+
let targetValue = valueToString(target,);
|
|
35193
35298
|
if (isNull(sourceValue,)) return false;
|
|
35194
35299
|
if (isNull(targetValue,)) return false;
|
|
35195
35300
|
if (collation11.type === 0) {
|
|
@@ -35246,115 +35351,51 @@ function compare(left, right, collation11,) {
|
|
|
35246
35351
|
switch (left.type) {
|
|
35247
35352
|
case 'array': {
|
|
35248
35353
|
assert(left.type === right.type,);
|
|
35249
|
-
|
|
35250
|
-
const rightLength = right.value.length;
|
|
35251
|
-
if (leftLength < rightLength) return -1;
|
|
35252
|
-
if (leftLength > rightLength) return 1;
|
|
35253
|
-
for (let i = 0; i < leftLength; i++) {
|
|
35254
|
-
const leftItem = left.value[i];
|
|
35255
|
-
const rightItem = right.value[i];
|
|
35256
|
-
assert(!isUndefined(leftItem,), 'Left item must exist',);
|
|
35257
|
-
assert(!isUndefined(rightItem,), 'Right item must exist',);
|
|
35258
|
-
const result = compare(leftItem, rightItem, collation11,);
|
|
35259
|
-
if (result !== 0) return result;
|
|
35260
|
-
}
|
|
35261
|
-
return 0;
|
|
35354
|
+
return compareArray(left, right, collation11,);
|
|
35262
35355
|
}
|
|
35263
35356
|
case 'boolean': {
|
|
35264
35357
|
assert(left.type === right.type,);
|
|
35265
|
-
|
|
35266
|
-
if (left.value > right.value) return 1;
|
|
35267
|
-
return 0;
|
|
35358
|
+
return compareBoolean(left, right,);
|
|
35268
35359
|
}
|
|
35269
35360
|
case 'color': {
|
|
35270
35361
|
assert(left.type === right.type,);
|
|
35271
|
-
|
|
35272
|
-
if (left.value > right.value) return 1;
|
|
35273
|
-
return 0;
|
|
35362
|
+
return compareColor(left, right,);
|
|
35274
35363
|
}
|
|
35275
35364
|
case 'date': {
|
|
35276
35365
|
assert(left.type === right.type,);
|
|
35277
|
-
|
|
35278
|
-
const rightDate = new Date(right.value,);
|
|
35279
|
-
if (leftDate < rightDate) return -1;
|
|
35280
|
-
if (leftDate > rightDate) return 1;
|
|
35281
|
-
return 0;
|
|
35366
|
+
return compareDate(left, right,);
|
|
35282
35367
|
}
|
|
35283
35368
|
case 'enum': {
|
|
35284
35369
|
assert(left.type === right.type,);
|
|
35285
|
-
|
|
35286
|
-
if (left.value > right.value) return 1;
|
|
35287
|
-
return 0;
|
|
35370
|
+
return compareEnum(left, right,);
|
|
35288
35371
|
}
|
|
35289
35372
|
case 'file': {
|
|
35290
35373
|
assert(left.type === right.type,);
|
|
35291
|
-
|
|
35292
|
-
if (left.value > right.value) return 1;
|
|
35293
|
-
return 0;
|
|
35374
|
+
return compareFile(left, right,);
|
|
35294
35375
|
}
|
|
35295
35376
|
case 'link': {
|
|
35296
35377
|
assert(left.type === right.type,);
|
|
35297
|
-
|
|
35298
|
-
const rightEncoded = JSON.stringify(right.value,);
|
|
35299
|
-
if (leftEncoded < rightEncoded) return -1;
|
|
35300
|
-
if (leftEncoded > rightEncoded) return 1;
|
|
35301
|
-
return 0;
|
|
35378
|
+
return compareLink(left, right,);
|
|
35302
35379
|
}
|
|
35303
35380
|
case 'number': {
|
|
35304
35381
|
assert(left.type === right.type,);
|
|
35305
|
-
|
|
35306
|
-
if (left.value > right.value) return 1;
|
|
35307
|
-
return 0;
|
|
35382
|
+
return compareNumber(left, right,);
|
|
35308
35383
|
}
|
|
35309
35384
|
case 'object': {
|
|
35310
35385
|
assert(left.type === right.type,);
|
|
35311
|
-
|
|
35312
|
-
const rightKeys = Object.keys(right.value,).sort();
|
|
35313
|
-
if (leftKeys.length < rightKeys.length) return -1;
|
|
35314
|
-
if (leftKeys.length > rightKeys.length) return 1;
|
|
35315
|
-
for (let i = 0; i < leftKeys.length; i++) {
|
|
35316
|
-
const leftKey = leftKeys[i];
|
|
35317
|
-
const rightKey = rightKeys[i];
|
|
35318
|
-
assert(!isUndefined(leftKey,), 'Left key must exist',);
|
|
35319
|
-
assert(!isUndefined(rightKey,), 'Left key must exist',);
|
|
35320
|
-
if (leftKey < rightKey) return -1;
|
|
35321
|
-
if (leftKey > rightKey) return 1;
|
|
35322
|
-
const leftValue = left.value[leftKey];
|
|
35323
|
-
const rightValue = right.value[rightKey];
|
|
35324
|
-
assert(!isUndefined(leftValue,), 'Left value must exist',);
|
|
35325
|
-
assert(!isUndefined(rightValue,), 'Right value must exist',);
|
|
35326
|
-
const result = compare(leftValue, rightValue, collation11,);
|
|
35327
|
-
if (result !== 0) return result;
|
|
35328
|
-
}
|
|
35329
|
-
return 0;
|
|
35386
|
+
return compareObject(left, right, collation11,);
|
|
35330
35387
|
}
|
|
35331
35388
|
case 'responsiveimage': {
|
|
35332
35389
|
assert(left.type === right.type,);
|
|
35333
|
-
|
|
35334
|
-
const rightEncoded = JSON.stringify(right.value,);
|
|
35335
|
-
if (leftEncoded < rightEncoded) return -1;
|
|
35336
|
-
if (leftEncoded > rightEncoded) return 1;
|
|
35337
|
-
return 0;
|
|
35390
|
+
return compareResponsiveImage(left, right,);
|
|
35338
35391
|
}
|
|
35339
35392
|
case 'richtext': {
|
|
35340
35393
|
assert(left.type === right.type,);
|
|
35341
|
-
|
|
35342
|
-
const rightValue = right.value;
|
|
35343
|
-
if (leftValue < rightValue) return -1;
|
|
35344
|
-
if (leftValue > rightValue) return 1;
|
|
35345
|
-
return 0;
|
|
35394
|
+
return compareRichText(left, right,);
|
|
35346
35395
|
}
|
|
35347
35396
|
case 'string': {
|
|
35348
35397
|
assert(left.type === right.type,);
|
|
35349
|
-
|
|
35350
|
-
let rightValue = right.value;
|
|
35351
|
-
if (collation11.type === 0) {
|
|
35352
|
-
leftValue = left.value.toLowerCase();
|
|
35353
|
-
rightValue = right.value.toLowerCase();
|
|
35354
|
-
}
|
|
35355
|
-
if (leftValue < rightValue) return -1;
|
|
35356
|
-
if (leftValue > rightValue) return 1;
|
|
35357
|
-
return 0;
|
|
35398
|
+
return compareString(left, right, collation11,);
|
|
35358
35399
|
}
|
|
35359
35400
|
default: {
|
|
35360
35401
|
assertNever(left,);
|
|
@@ -36059,7 +36100,8 @@ var RelationalProject = class extends RelationalNode {
|
|
|
36059
36100
|
this.input = input;
|
|
36060
36101
|
this.projections = projections;
|
|
36061
36102
|
this.passthrough = passthrough;
|
|
36062
|
-
__publicField(this, 'inputGroup',
|
|
36103
|
+
__publicField(this, 'inputGroup',);
|
|
36104
|
+
this.inputGroup = input.getGroup();
|
|
36063
36105
|
}
|
|
36064
36106
|
getHash() {
|
|
36065
36107
|
return calculateHash('RelationalProject', this.inputGroup.id, ...this.projections, this.passthrough,);
|
|
@@ -36232,24 +36274,6 @@ var ScalarCase = class extends ScalarNode {
|
|
|
36232
36274
|
getHash() {
|
|
36233
36275
|
return calculateHash('ScalarCase', this.input, ...this.conditions, this.otherwise,);
|
|
36234
36276
|
}
|
|
36235
|
-
toString() {
|
|
36236
|
-
let result = 'CASE';
|
|
36237
|
-
if (this.input) {
|
|
36238
|
-
result = `${result} ${this.input}`;
|
|
36239
|
-
}
|
|
36240
|
-
for (
|
|
36241
|
-
const {
|
|
36242
|
-
when,
|
|
36243
|
-
then,
|
|
36244
|
-
} of this.conditions
|
|
36245
|
-
) {
|
|
36246
|
-
result = `${result} WHEN ${when} THEN ${then}`;
|
|
36247
|
-
}
|
|
36248
|
-
if (this.otherwise) {
|
|
36249
|
-
result = `${result} ELSE ${this.otherwise}`;
|
|
36250
|
-
}
|
|
36251
|
-
return `${result} END`;
|
|
36252
|
-
}
|
|
36253
36277
|
optimize(optimizer,) {
|
|
36254
36278
|
var _a, _b;
|
|
36255
36279
|
(_a = this.input) == null ? void 0 : _a.optimize(optimizer,);
|
|
@@ -36282,6 +36306,7 @@ var ScalarCase = class extends ScalarNode {
|
|
|
36282
36306
|
conditions: evaluateArray(this.conditions.map((condition) =>
|
|
36283
36307
|
evaluateObject({
|
|
36284
36308
|
when: condition.when.evaluate(context, tuple,),
|
|
36309
|
+
// biome-ignore lint/suspicious/noThenProperty: Existing name.
|
|
36285
36310
|
then: condition.then.evaluate(context, tuple,),
|
|
36286
36311
|
},)
|
|
36287
36312
|
),),
|
|
@@ -36305,7 +36330,7 @@ var ScalarCase = class extends ScalarNode {
|
|
|
36305
36330
|
then,
|
|
36306
36331
|
} of conditions
|
|
36307
36332
|
) {
|
|
36308
|
-
if (
|
|
36333
|
+
if (valueToBoolean(when,)) {
|
|
36309
36334
|
return then;
|
|
36310
36335
|
}
|
|
36311
36336
|
}
|
|
@@ -36742,7 +36767,8 @@ var RelationalFilter = class extends RelationalNode {
|
|
|
36742
36767
|
super(input.isSynchronous && predicate.isSynchronous,);
|
|
36743
36768
|
this.input = input;
|
|
36744
36769
|
this.predicate = predicate;
|
|
36745
|
-
__publicField(this, 'inputGroup',
|
|
36770
|
+
__publicField(this, 'inputGroup',);
|
|
36771
|
+
this.inputGroup = input.getGroup();
|
|
36746
36772
|
}
|
|
36747
36773
|
getHash() {
|
|
36748
36774
|
return calculateHash('RelationalFilter', this.inputGroup.id, this.predicate,);
|
|
@@ -36780,7 +36806,7 @@ var RelationalFilter = class extends RelationalNode {
|
|
|
36780
36806
|
},),);
|
|
36781
36807
|
return input.filter((_, index,) => {
|
|
36782
36808
|
const predicate = predicates[index] ?? null;
|
|
36783
|
-
return
|
|
36809
|
+
return valueToBoolean(predicate,);
|
|
36784
36810
|
},);
|
|
36785
36811
|
}
|
|
36786
36812
|
};
|
|
@@ -36832,8 +36858,10 @@ var RelationalIntersection = class extends RelationalNode {
|
|
|
36832
36858
|
super(left.isSynchronous && right.isSynchronous,);
|
|
36833
36859
|
this.left = left;
|
|
36834
36860
|
this.right = right;
|
|
36835
|
-
__publicField(this, 'leftGroup',
|
|
36836
|
-
__publicField(this, 'rightGroup',
|
|
36861
|
+
__publicField(this, 'leftGroup',);
|
|
36862
|
+
__publicField(this, 'rightGroup',);
|
|
36863
|
+
this.leftGroup = left.getGroup();
|
|
36864
|
+
this.rightGroup = right.getGroup();
|
|
36837
36865
|
}
|
|
36838
36866
|
getHash() {
|
|
36839
36867
|
return calculateHash('RelationalIntersection', this.leftGroup.id, this.rightGroup.id,);
|
|
@@ -36904,9 +36932,6 @@ var ScalarEquals = class extends ScalarNode {
|
|
|
36904
36932
|
getHash() {
|
|
36905
36933
|
return calculateHash('ScalarEquals', this.left, this.right,);
|
|
36906
36934
|
}
|
|
36907
|
-
toString() {
|
|
36908
|
-
return `${this.left} == ${this.right}`;
|
|
36909
|
-
}
|
|
36910
36935
|
optimize(optimizer,) {
|
|
36911
36936
|
const leftCost = this.left.optimize(optimizer,);
|
|
36912
36937
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -36937,8 +36962,10 @@ var RelationalLeftJoin = class extends RelationalNode {
|
|
|
36937
36962
|
this.left = left;
|
|
36938
36963
|
this.right = right;
|
|
36939
36964
|
this.constraint = constraint;
|
|
36940
|
-
__publicField(this, 'leftGroup',
|
|
36941
|
-
__publicField(this, 'rightGroup',
|
|
36965
|
+
__publicField(this, 'leftGroup',);
|
|
36966
|
+
__publicField(this, 'rightGroup',);
|
|
36967
|
+
this.leftGroup = left.getGroup();
|
|
36968
|
+
this.rightGroup = right.getGroup();
|
|
36942
36969
|
}
|
|
36943
36970
|
getHash() {
|
|
36944
36971
|
return calculateHash('RelationalLeftJoin', this.leftGroup.id, this.rightGroup.id, this.constraint,);
|
|
@@ -37047,7 +37074,7 @@ var RelationalLeftJoin = class extends RelationalNode {
|
|
|
37047
37074
|
tuple.merge(leftTuple,);
|
|
37048
37075
|
tuple.merge(rightTuple,);
|
|
37049
37076
|
const value = yield* this.constraint.evaluate(context, tuple,);
|
|
37050
|
-
if (
|
|
37077
|
+
if (valueToBoolean(value,)) {
|
|
37051
37078
|
result.push(tuple,);
|
|
37052
37079
|
hasMatch = true;
|
|
37053
37080
|
}
|
|
@@ -37065,8 +37092,10 @@ var RelationalRightJoin = class extends RelationalNode {
|
|
|
37065
37092
|
this.left = left;
|
|
37066
37093
|
this.right = right;
|
|
37067
37094
|
this.constraint = constraint;
|
|
37068
|
-
__publicField(this, 'leftGroup',
|
|
37069
|
-
__publicField(this, 'rightGroup',
|
|
37095
|
+
__publicField(this, 'leftGroup',);
|
|
37096
|
+
__publicField(this, 'rightGroup',);
|
|
37097
|
+
this.leftGroup = left.getGroup();
|
|
37098
|
+
this.rightGroup = right.getGroup();
|
|
37070
37099
|
}
|
|
37071
37100
|
getHash() {
|
|
37072
37101
|
return calculateHash('RelationalRightJoin', this.leftGroup.id, this.rightGroup.id, this.constraint,);
|
|
@@ -37175,7 +37204,7 @@ var RelationalRightJoin = class extends RelationalNode {
|
|
|
37175
37204
|
tuple.merge(rightTuple,);
|
|
37176
37205
|
tuple.merge(leftTuple,);
|
|
37177
37206
|
const value = yield* this.constraint.evaluate(context, tuple,);
|
|
37178
|
-
if (
|
|
37207
|
+
if (valueToBoolean(value,)) {
|
|
37179
37208
|
result.push(tuple,);
|
|
37180
37209
|
hasMatch = true;
|
|
37181
37210
|
}
|
|
@@ -37231,8 +37260,10 @@ var RelationalUnion = class extends RelationalNode {
|
|
|
37231
37260
|
super(left.isSynchronous && right.isSynchronous,);
|
|
37232
37261
|
this.left = left;
|
|
37233
37262
|
this.right = right;
|
|
37234
|
-
__publicField(this, 'leftGroup',
|
|
37235
|
-
__publicField(this, 'rightGroup',
|
|
37263
|
+
__publicField(this, 'leftGroup',);
|
|
37264
|
+
__publicField(this, 'rightGroup',);
|
|
37265
|
+
this.leftGroup = left.getGroup();
|
|
37266
|
+
this.rightGroup = right.getGroup();
|
|
37236
37267
|
}
|
|
37237
37268
|
getHash() {
|
|
37238
37269
|
return calculateHash('RelationalUnion', this.leftGroup.id, this.rightGroup.id,);
|
|
@@ -37303,9 +37334,6 @@ var ScalarAnd = class extends ScalarNode {
|
|
|
37303
37334
|
getHash() {
|
|
37304
37335
|
return calculateHash('ScalarAnd', this.left, this.right,);
|
|
37305
37336
|
}
|
|
37306
|
-
toString() {
|
|
37307
|
-
return `${this.left} && ${this.right}`;
|
|
37308
|
-
}
|
|
37309
37337
|
optimize(optimizer,) {
|
|
37310
37338
|
const leftCost = this.left.optimize(optimizer,);
|
|
37311
37339
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -37326,7 +37354,7 @@ var ScalarAnd = class extends ScalarNode {
|
|
|
37326
37354
|
},);
|
|
37327
37355
|
return {
|
|
37328
37356
|
type: 'boolean',
|
|
37329
|
-
value:
|
|
37357
|
+
value: valueToBoolean(left,) && valueToBoolean(right,),
|
|
37330
37358
|
};
|
|
37331
37359
|
}
|
|
37332
37360
|
};
|
|
@@ -37341,16 +37369,13 @@ var ScalarConstant = class extends ScalarNode {
|
|
|
37341
37369
|
getHash() {
|
|
37342
37370
|
return calculateHash('ScalarConstant', this.definition, this.value,);
|
|
37343
37371
|
}
|
|
37344
|
-
toString() {
|
|
37345
|
-
return DatabaseValue.stringify(this.value,);
|
|
37346
|
-
}
|
|
37347
37372
|
optimize() {
|
|
37348
37373
|
return new Cost(0,);
|
|
37349
37374
|
}
|
|
37350
37375
|
getOptimized() {
|
|
37351
37376
|
return this;
|
|
37352
37377
|
}
|
|
37353
|
-
//
|
|
37378
|
+
// biome-ignore lint/correctness/useYield: Required by the super class.
|
|
37354
37379
|
*evaluate() {
|
|
37355
37380
|
return this.value;
|
|
37356
37381
|
}
|
|
@@ -37379,9 +37404,6 @@ var ScalarContains = class extends ScalarNode {
|
|
|
37379
37404
|
getHash() {
|
|
37380
37405
|
return calculateHash('ScalarContains', this.source, this.target,);
|
|
37381
37406
|
}
|
|
37382
|
-
toString() {
|
|
37383
|
-
return `CONTAINS(${this.source}, ${this.target})`;
|
|
37384
|
-
}
|
|
37385
37407
|
optimize(optimizer,) {
|
|
37386
37408
|
const sourceCost = this.source.optimize(optimizer,);
|
|
37387
37409
|
const targetCost = this.target.optimize(optimizer,);
|
|
@@ -37430,9 +37452,6 @@ var ScalarEndsWith = class extends ScalarNode {
|
|
|
37430
37452
|
getHash() {
|
|
37431
37453
|
return calculateHash('ScalarEndsWith', this.source, this.target,);
|
|
37432
37454
|
}
|
|
37433
|
-
toString() {
|
|
37434
|
-
return `ENDS_WITH(${this.source}, ${this.target})`;
|
|
37435
|
-
}
|
|
37436
37455
|
optimize(optimizer,) {
|
|
37437
37456
|
const sourceCost = this.source.optimize(optimizer,);
|
|
37438
37457
|
const targetCost = this.target.optimize(optimizer,);
|
|
@@ -37477,9 +37496,6 @@ var ScalarGreaterThan = class extends ScalarNode {
|
|
|
37477
37496
|
getHash() {
|
|
37478
37497
|
return calculateHash('ScalarGreaterThan', this.left, this.right,);
|
|
37479
37498
|
}
|
|
37480
|
-
toString() {
|
|
37481
|
-
return `${this.left} > ${this.right}`;
|
|
37482
|
-
}
|
|
37483
37499
|
optimize(optimizer,) {
|
|
37484
37500
|
const leftCost = this.left.optimize(optimizer,);
|
|
37485
37501
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -37524,9 +37540,6 @@ var ScalarGreaterThanOrEqual = class extends ScalarNode {
|
|
|
37524
37540
|
getHash() {
|
|
37525
37541
|
return calculateHash('ScalarGreaterThanOrEqual', this.left, this.right,);
|
|
37526
37542
|
}
|
|
37527
|
-
toString() {
|
|
37528
|
-
return `${this.left} >= ${this.right}`;
|
|
37529
|
-
}
|
|
37530
37543
|
optimize(optimizer,) {
|
|
37531
37544
|
const leftCost = this.left.optimize(optimizer,);
|
|
37532
37545
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -37571,9 +37584,6 @@ var ScalarLessThan = class extends ScalarNode {
|
|
|
37571
37584
|
getHash() {
|
|
37572
37585
|
return calculateHash('ScalarLessThan', this.left, this.right,);
|
|
37573
37586
|
}
|
|
37574
|
-
toString() {
|
|
37575
|
-
return `${this.left} < ${this.right}`;
|
|
37576
|
-
}
|
|
37577
37587
|
optimize(optimizer,) {
|
|
37578
37588
|
const leftCost = this.left.optimize(optimizer,);
|
|
37579
37589
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -37618,9 +37628,6 @@ var ScalarLessThanOrEqual = class extends ScalarNode {
|
|
|
37618
37628
|
getHash() {
|
|
37619
37629
|
return calculateHash('ScalarLessThanOrEqual', this.left, this.right,);
|
|
37620
37630
|
}
|
|
37621
|
-
toString() {
|
|
37622
|
-
return `${this.left} <= ${this.right}`;
|
|
37623
|
-
}
|
|
37624
37631
|
optimize(optimizer,) {
|
|
37625
37632
|
const leftCost = this.left.optimize(optimizer,);
|
|
37626
37633
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -37665,9 +37672,6 @@ var ScalarNotEquals = class extends ScalarNode {
|
|
|
37665
37672
|
getHash() {
|
|
37666
37673
|
return calculateHash('ScalarNotEquals', this.left, this.right,);
|
|
37667
37674
|
}
|
|
37668
|
-
toString() {
|
|
37669
|
-
return `${this.left} != ${this.right}`;
|
|
37670
|
-
}
|
|
37671
37675
|
optimize(optimizer,) {
|
|
37672
37676
|
const leftCost = this.left.optimize(optimizer,);
|
|
37673
37677
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -37712,9 +37716,6 @@ var ScalarOr = class extends ScalarNode {
|
|
|
37712
37716
|
getHash() {
|
|
37713
37717
|
return calculateHash('ScalarOr', this.left, this.right,);
|
|
37714
37718
|
}
|
|
37715
|
-
toString() {
|
|
37716
|
-
return `${this.left} || ${this.right}`;
|
|
37717
|
-
}
|
|
37718
37719
|
optimize(optimizer,) {
|
|
37719
37720
|
const leftCost = this.left.optimize(optimizer,);
|
|
37720
37721
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -37735,7 +37736,7 @@ var ScalarOr = class extends ScalarNode {
|
|
|
37735
37736
|
},);
|
|
37736
37737
|
return {
|
|
37737
37738
|
type: 'boolean',
|
|
37738
|
-
value:
|
|
37739
|
+
value: valueToBoolean(left,) || valueToBoolean(right,),
|
|
37739
37740
|
};
|
|
37740
37741
|
}
|
|
37741
37742
|
};
|
|
@@ -37763,9 +37764,6 @@ var ScalarStartsWith = class extends ScalarNode {
|
|
|
37763
37764
|
getHash() {
|
|
37764
37765
|
return calculateHash('ScalarStartsWith', this.source, this.target,);
|
|
37765
37766
|
}
|
|
37766
|
-
toString() {
|
|
37767
|
-
return `STARTS_WITH(${this.source}, ${this.target})`;
|
|
37768
|
-
}
|
|
37769
37767
|
optimize(optimizer,) {
|
|
37770
37768
|
const sourceCost = this.source.optimize(optimizer,);
|
|
37771
37769
|
const targetCost = this.target.optimize(optimizer,);
|
|
@@ -37793,7 +37791,8 @@ var ScalarStartsWith = class extends ScalarNode {
|
|
|
37793
37791
|
var Explorer = class {
|
|
37794
37792
|
constructor(normalizer,) {
|
|
37795
37793
|
this.normalizer = normalizer;
|
|
37796
|
-
__publicField(this, 'memo',
|
|
37794
|
+
__publicField(this, 'memo',);
|
|
37795
|
+
this.memo = normalizer.memo;
|
|
37797
37796
|
}
|
|
37798
37797
|
explore(before,) {
|
|
37799
37798
|
const group = before.getGroup();
|
|
@@ -38023,7 +38022,8 @@ var RelationalLimit = class extends RelationalNode {
|
|
|
38023
38022
|
this.input = input;
|
|
38024
38023
|
this.limit = limit;
|
|
38025
38024
|
this.ordering = ordering;
|
|
38026
|
-
__publicField(this, 'inputGroup',
|
|
38025
|
+
__publicField(this, 'inputGroup',);
|
|
38026
|
+
this.inputGroup = input.getGroup();
|
|
38027
38027
|
}
|
|
38028
38028
|
getHash() {
|
|
38029
38029
|
return calculateHash('RelationalLimit', this.inputGroup.id, this.limit,);
|
|
@@ -38062,7 +38062,7 @@ var RelationalLimit = class extends RelationalNode {
|
|
|
38062
38062
|
input: this.input.evaluate(context,),
|
|
38063
38063
|
limit: this.limit.evaluate(context, void 0,),
|
|
38064
38064
|
},);
|
|
38065
|
-
const value =
|
|
38065
|
+
const value = valueToNumber(limit,) ?? Infinity;
|
|
38066
38066
|
if (value === Infinity) return input;
|
|
38067
38067
|
return input.slice(0, value,);
|
|
38068
38068
|
}
|
|
@@ -38073,7 +38073,8 @@ var RelationalOffset = class extends RelationalNode {
|
|
|
38073
38073
|
this.input = input;
|
|
38074
38074
|
this.offset = offset;
|
|
38075
38075
|
this.ordering = ordering;
|
|
38076
|
-
__publicField(this, 'inputGroup',
|
|
38076
|
+
__publicField(this, 'inputGroup',);
|
|
38077
|
+
this.inputGroup = input.getGroup();
|
|
38077
38078
|
}
|
|
38078
38079
|
getHash() {
|
|
38079
38080
|
return calculateHash('RelationalOffset', this.inputGroup.id, this.offset,);
|
|
@@ -38112,7 +38113,7 @@ var RelationalOffset = class extends RelationalNode {
|
|
|
38112
38113
|
input: this.input.evaluate(context,),
|
|
38113
38114
|
offset: this.offset.evaluate(context, void 0,),
|
|
38114
38115
|
},);
|
|
38115
|
-
const value =
|
|
38116
|
+
const value = valueToNumber(offset,) ?? 0;
|
|
38116
38117
|
if (value === 0) return input;
|
|
38117
38118
|
return input.slice(value,);
|
|
38118
38119
|
}
|
|
@@ -38125,8 +38126,9 @@ var ScalarArray = class extends ScalarNode {
|
|
|
38125
38126
|
this.ordering = ordering;
|
|
38126
38127
|
this.referencedFields = referencedFields;
|
|
38127
38128
|
this.referencedOuterFields = referencedOuterFields;
|
|
38128
|
-
__publicField(this, 'inputGroup',
|
|
38129
|
+
__publicField(this, 'inputGroup',);
|
|
38129
38130
|
__publicField(this, 'definition',);
|
|
38131
|
+
this.inputGroup = input.getGroup();
|
|
38130
38132
|
const itemDefinitions = {};
|
|
38131
38133
|
const namedFieldEntries = Object.entries(namedFields,);
|
|
38132
38134
|
for (const [name, field,] of namedFieldEntries) {
|
|
@@ -38157,9 +38159,6 @@ var ScalarArray = class extends ScalarNode {
|
|
|
38157
38159
|
this.referencedOuterFields,
|
|
38158
38160
|
);
|
|
38159
38161
|
}
|
|
38160
|
-
toString() {
|
|
38161
|
-
return `ARRAY(${this.inputGroup.id})`;
|
|
38162
|
-
}
|
|
38163
38162
|
getInputRequiredProps() {
|
|
38164
38163
|
const resolvedFields = new Fields();
|
|
38165
38164
|
const fields = Object.values(this.namedFields,);
|
|
@@ -38210,9 +38209,6 @@ var ScalarCast = class extends ScalarNode {
|
|
|
38210
38209
|
getHash() {
|
|
38211
38210
|
return calculateHash('ScalarCast', this.input, this.definition,);
|
|
38212
38211
|
}
|
|
38213
|
-
toString() {
|
|
38214
|
-
return `CAST(${this.input} AS ${this.definition.type.toUpperCase()})`;
|
|
38215
|
-
}
|
|
38216
38212
|
optimize(optimizer,) {
|
|
38217
38213
|
return this.input.optimize(optimizer,);
|
|
38218
38214
|
}
|
|
@@ -38233,12 +38229,13 @@ var ScalarFlatArray = class extends ScalarNode {
|
|
|
38233
38229
|
this.ordering = ordering;
|
|
38234
38230
|
this.referencedFields = referencedFields;
|
|
38235
38231
|
this.referencedOuterFields = referencedOuterFields;
|
|
38236
|
-
__publicField(this, 'inputGroup',
|
|
38232
|
+
__publicField(this, 'inputGroup',);
|
|
38237
38233
|
__publicField(this, 'definition',);
|
|
38234
|
+
this.inputGroup = input.getGroup();
|
|
38238
38235
|
this.definition = {
|
|
38239
38236
|
type: 'array',
|
|
38240
38237
|
isNullable: false,
|
|
38241
|
-
definition:
|
|
38238
|
+
definition: field.definition,
|
|
38242
38239
|
};
|
|
38243
38240
|
}
|
|
38244
38241
|
getHash() {
|
|
@@ -38251,9 +38248,6 @@ var ScalarFlatArray = class extends ScalarNode {
|
|
|
38251
38248
|
this.referencedOuterFields,
|
|
38252
38249
|
);
|
|
38253
38250
|
}
|
|
38254
|
-
toString() {
|
|
38255
|
-
return `FLAT_ARRAY(${this.inputGroup.id})`;
|
|
38256
|
-
}
|
|
38257
38251
|
getInputRequiredProps() {
|
|
38258
38252
|
const resolvedFields = new Fields();
|
|
38259
38253
|
if (!isUndefined(this.field.collection,)) {
|
|
@@ -38308,9 +38302,6 @@ var ScalarIn = class extends ScalarNode {
|
|
|
38308
38302
|
getHash() {
|
|
38309
38303
|
return calculateHash('ScalarIn', this.left, this.right,);
|
|
38310
38304
|
}
|
|
38311
|
-
toString() {
|
|
38312
|
-
return `${this.left} IN ${this.right}`;
|
|
38313
|
-
}
|
|
38314
38305
|
optimize(optimizer,) {
|
|
38315
38306
|
const leftCost = this.left.optimize(optimizer,);
|
|
38316
38307
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -38359,9 +38350,6 @@ var ScalarIndexOf = class extends ScalarNode {
|
|
|
38359
38350
|
getHash() {
|
|
38360
38351
|
return calculateHash('ScalarIndexOf', this.source, this.target,);
|
|
38361
38352
|
}
|
|
38362
|
-
toString() {
|
|
38363
|
-
return `INDEX_OF(${this.source}, ${this.target})`;
|
|
38364
|
-
}
|
|
38365
38353
|
optimize(optimizer,) {
|
|
38366
38354
|
const sourceCost = this.source.optimize(optimizer,);
|
|
38367
38355
|
const targetCost = this.target.optimize(optimizer,);
|
|
@@ -38398,9 +38386,6 @@ var ScalarLength = class extends ScalarNode {
|
|
|
38398
38386
|
getHash() {
|
|
38399
38387
|
return calculateHash('ScalarLength', this.input,);
|
|
38400
38388
|
}
|
|
38401
|
-
toString() {
|
|
38402
|
-
return `LENGTH(${this.input})`;
|
|
38403
|
-
}
|
|
38404
38389
|
optimize(optimizer,) {
|
|
38405
38390
|
return this.input.optimize(optimizer,);
|
|
38406
38391
|
}
|
|
@@ -38428,9 +38413,6 @@ var ScalarNot = class extends ScalarNode {
|
|
|
38428
38413
|
getHash() {
|
|
38429
38414
|
return calculateHash('ScalarNot', this.input,);
|
|
38430
38415
|
}
|
|
38431
|
-
toString() {
|
|
38432
|
-
return `NOT ${this.input}`;
|
|
38433
|
-
}
|
|
38434
38416
|
optimize(optimizer,) {
|
|
38435
38417
|
return this.input.optimize(optimizer,);
|
|
38436
38418
|
}
|
|
@@ -38442,7 +38424,7 @@ var ScalarNot = class extends ScalarNode {
|
|
|
38442
38424
|
const input = yield* this.input.evaluate(context, tuple,);
|
|
38443
38425
|
return {
|
|
38444
38426
|
type: 'boolean',
|
|
38445
|
-
value: !
|
|
38427
|
+
value: !valueToBoolean(input,),
|
|
38446
38428
|
};
|
|
38447
38429
|
}
|
|
38448
38430
|
};
|
|
@@ -38470,9 +38452,6 @@ var ScalarNotIn = class extends ScalarNode {
|
|
|
38470
38452
|
getHash() {
|
|
38471
38453
|
return calculateHash('ScalarNotIn', this.left, this.right,);
|
|
38472
38454
|
}
|
|
38473
|
-
toString() {
|
|
38474
|
-
return `${this.left} NOT IN ${this.right}`;
|
|
38475
|
-
}
|
|
38476
38455
|
optimize(optimizer,) {
|
|
38477
38456
|
const leftCost = this.left.optimize(optimizer,);
|
|
38478
38457
|
const rightCost = this.right.optimize(optimizer,);
|
|
@@ -38510,21 +38489,19 @@ var ScalarVariable = class extends ScalarNode {
|
|
|
38510
38489
|
super(referencedFields, referencedOuterFields, true,);
|
|
38511
38490
|
this.field = field;
|
|
38512
38491
|
this.isOuterField = isOuterField;
|
|
38513
|
-
__publicField(this, 'definition',
|
|
38492
|
+
__publicField(this, 'definition',);
|
|
38493
|
+
this.definition = field.definition;
|
|
38514
38494
|
}
|
|
38515
38495
|
getHash() {
|
|
38516
38496
|
return calculateHash('ScalarVariable', this.field.id, this.isOuterField,);
|
|
38517
38497
|
}
|
|
38518
|
-
toString() {
|
|
38519
|
-
return `"${this.field.name}" /* ${this.field.id} */`;
|
|
38520
|
-
}
|
|
38521
38498
|
optimize() {
|
|
38522
38499
|
return new Cost(0,);
|
|
38523
38500
|
}
|
|
38524
38501
|
getOptimized() {
|
|
38525
38502
|
return this;
|
|
38526
38503
|
}
|
|
38527
|
-
//
|
|
38504
|
+
// biome-ignore lint/correctness/useYield: Required by the super class.
|
|
38528
38505
|
*evaluate(context, tuple,) {
|
|
38529
38506
|
if (this.isOuterField) {
|
|
38530
38507
|
assert(context, 'Context must exist',);
|
|
@@ -38850,7 +38827,8 @@ var EnforcerResolve = class extends EnforcerNode {
|
|
|
38850
38827
|
super(false,);
|
|
38851
38828
|
this.input = input;
|
|
38852
38829
|
this.fields = fields;
|
|
38853
|
-
__publicField(this, 'inputGroup',
|
|
38830
|
+
__publicField(this, 'inputGroup',);
|
|
38831
|
+
this.inputGroup = input.getGroup();
|
|
38854
38832
|
}
|
|
38855
38833
|
getHash() {
|
|
38856
38834
|
return calculateHash('EnforcerResolve', this.inputGroup.id, this.fields,);
|
|
@@ -38933,7 +38911,8 @@ var EnforcerSort = class extends EnforcerNode {
|
|
|
38933
38911
|
super(input.isSynchronous,);
|
|
38934
38912
|
this.input = input;
|
|
38935
38913
|
this.ordering = ordering;
|
|
38936
|
-
__publicField(this, 'inputGroup',
|
|
38914
|
+
__publicField(this, 'inputGroup',);
|
|
38915
|
+
this.inputGroup = input.getGroup();
|
|
38937
38916
|
}
|
|
38938
38917
|
getHash() {
|
|
38939
38918
|
return calculateHash('EnforcerSort', this.inputGroup.id, this.ordering,);
|