@budibase/shared-core 2.9.19 → 2.9.20
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/package.json +19 -11
- package/dist/tsconfig.build.tsbuildinfo +0 -1
- package/src/constants.ts +0 -98
- package/src/filters.ts +0 -473
- package/src/helpers/helpers.ts +0 -85
- package/src/helpers/index.ts +0 -2
- package/src/helpers/integrations.ts +0 -18
- package/src/index.ts +0 -5
- package/src/sdk/documents/applications.ts +0 -35
- package/src/sdk/documents/index.ts +0 -2
- package/src/sdk/documents/users.ts +0 -62
- package/src/sdk/index.ts +0 -1
- package/src/utils.ts +0 -45
package/package.json
CHANGED
|
@@ -1,15 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@budibase/shared-core",
|
|
3
|
-
"version": "2.9.
|
|
3
|
+
"version": "2.9.20",
|
|
4
4
|
"description": "Shared data utils",
|
|
5
|
-
"main": "
|
|
6
|
-
"types": "
|
|
7
|
-
"exports": {
|
|
8
|
-
".": {
|
|
9
|
-
"import": "./dist/index.js",
|
|
10
|
-
"require": "./src/index.ts"
|
|
11
|
-
}
|
|
12
|
-
},
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"types": "dist/index.d.ts",
|
|
13
7
|
"author": "Budibase",
|
|
14
8
|
"license": "GPL-3.0",
|
|
15
9
|
"scripts": {
|
|
@@ -20,12 +14,26 @@
|
|
|
20
14
|
"check:types": "tsc -p tsconfig.json --noEmit --paths null"
|
|
21
15
|
},
|
|
22
16
|
"dependencies": {
|
|
23
|
-
"@budibase/types": "2.9.
|
|
17
|
+
"@budibase/types": "2.9.20"
|
|
24
18
|
},
|
|
25
19
|
"devDependencies": {
|
|
26
20
|
"concurrently": "^7.6.0",
|
|
27
21
|
"rimraf": "3.0.2",
|
|
28
22
|
"typescript": "4.7.3"
|
|
29
23
|
},
|
|
30
|
-
"
|
|
24
|
+
"nx": {
|
|
25
|
+
"targets": {
|
|
26
|
+
"build": {
|
|
27
|
+
"dependsOn": [
|
|
28
|
+
{
|
|
29
|
+
"projects": [
|
|
30
|
+
"@budibase/types"
|
|
31
|
+
],
|
|
32
|
+
"target": "build"
|
|
33
|
+
}
|
|
34
|
+
]
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
"gitHead": "11d253164ee6128d5c472c7994a9119f415a5e36"
|
|
31
39
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"program":{"fileNames":["../../../node_modules/typescript/lib/lib.es5.d.ts","../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../node_modules/typescript/lib/lib.es2019.d.ts","../../../node_modules/typescript/lib/lib.es2020.d.ts","../../../node_modules/typescript/lib/lib.dom.d.ts","../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../node_modules/typescript/lib/lib.es2020.date.d.ts","../../../node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2020.string.d.ts","../../../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../node_modules/typescript/lib/lib.es2020.number.d.ts","../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../src/constants.ts","../../../node_modules/@types/node/ts4.8/assert.d.ts","../../../node_modules/@types/node/ts4.8/assert/strict.d.ts","../../../node_modules/@types/node/ts4.8/globals.d.ts","../../../node_modules/@types/node/ts4.8/async_hooks.d.ts","../../../node_modules/@types/node/ts4.8/buffer.d.ts","../../../node_modules/@types/node/ts4.8/child_process.d.ts","../../../node_modules/@types/node/ts4.8/cluster.d.ts","../../../node_modules/@types/node/ts4.8/console.d.ts","../../../node_modules/@types/node/ts4.8/constants.d.ts","../../../node_modules/@types/node/ts4.8/crypto.d.ts","../../../node_modules/@types/node/ts4.8/dgram.d.ts","../../../node_modules/@types/node/ts4.8/diagnostics_channel.d.ts","../../../node_modules/@types/node/ts4.8/dns.d.ts","../../../node_modules/@types/node/ts4.8/dns/promises.d.ts","../../../node_modules/@types/node/ts4.8/domain.d.ts","../../../node_modules/@types/node/ts4.8/dom-events.d.ts","../../../node_modules/@types/node/ts4.8/events.d.ts","../../../node_modules/@types/node/ts4.8/fs.d.ts","../../../node_modules/@types/node/ts4.8/fs/promises.d.ts","../../../node_modules/@types/node/ts4.8/http.d.ts","../../../node_modules/@types/node/ts4.8/http2.d.ts","../../../node_modules/@types/node/ts4.8/https.d.ts","../../../node_modules/@types/node/ts4.8/inspector.d.ts","../../../node_modules/@types/node/ts4.8/module.d.ts","../../../node_modules/@types/node/ts4.8/net.d.ts","../../../node_modules/@types/node/ts4.8/os.d.ts","../../../node_modules/@types/node/ts4.8/path.d.ts","../../../node_modules/@types/node/ts4.8/perf_hooks.d.ts","../../../node_modules/@types/node/ts4.8/process.d.ts","../../../node_modules/@types/node/ts4.8/punycode.d.ts","../../../node_modules/@types/node/ts4.8/querystring.d.ts","../../../node_modules/@types/node/ts4.8/readline.d.ts","../../../node_modules/@types/node/ts4.8/readline/promises.d.ts","../../../node_modules/@types/node/ts4.8/repl.d.ts","../../../node_modules/@types/node/ts4.8/stream.d.ts","../../../node_modules/@types/node/ts4.8/stream/promises.d.ts","../../../node_modules/@types/node/ts4.8/stream/consumers.d.ts","../../../node_modules/@types/node/ts4.8/stream/web.d.ts","../../../node_modules/@types/node/ts4.8/string_decoder.d.ts","../../../node_modules/@types/node/ts4.8/test.d.ts","../../../node_modules/@types/node/ts4.8/timers.d.ts","../../../node_modules/@types/node/ts4.8/timers/promises.d.ts","../../../node_modules/@types/node/ts4.8/tls.d.ts","../../../node_modules/@types/node/ts4.8/trace_events.d.ts","../../../node_modules/@types/node/ts4.8/tty.d.ts","../../../node_modules/@types/node/ts4.8/url.d.ts","../../../node_modules/@types/node/ts4.8/util.d.ts","../../../node_modules/@types/node/ts4.8/v8.d.ts","../../../node_modules/@types/node/ts4.8/vm.d.ts","../../../node_modules/@types/node/ts4.8/wasi.d.ts","../../../node_modules/@types/node/ts4.8/worker_threads.d.ts","../../../node_modules/@types/node/ts4.8/zlib.d.ts","../../../node_modules/@types/node/ts4.8/globals.global.d.ts","../../../node_modules/@types/node/ts4.8/index.d.ts","../../../node_modules/ioredis/built/types.d.ts","../../../node_modules/ioredis/built/Command.d.ts","../../../node_modules/ioredis/built/ScanStream.d.ts","../../../node_modules/ioredis/built/utils/RedisCommander.d.ts","../../../node_modules/ioredis/built/transaction.d.ts","../../../node_modules/ioredis/built/utils/Commander.d.ts","../../../node_modules/ioredis/built/connectors/AbstractConnector.d.ts","../../../node_modules/ioredis/built/connectors/ConnectorConstructor.d.ts","../../../node_modules/ioredis/built/connectors/SentinelConnector/types.d.ts","../../../node_modules/ioredis/built/connectors/SentinelConnector/SentinelIterator.d.ts","../../../node_modules/ioredis/built/connectors/SentinelConnector/index.d.ts","../../../node_modules/ioredis/built/connectors/StandaloneConnector.d.ts","../../../node_modules/ioredis/built/redis/RedisOptions.d.ts","../../../node_modules/ioredis/built/cluster/util.d.ts","../../../node_modules/ioredis/built/cluster/ClusterOptions.d.ts","../../../node_modules/ioredis/built/cluster/index.d.ts","../../../node_modules/denque/index.d.ts","../../../node_modules/ioredis/built/SubscriptionSet.d.ts","../../../node_modules/ioredis/built/DataHandler.d.ts","../../../node_modules/ioredis/built/Redis.d.ts","../../../node_modules/ioredis/built/Pipeline.d.ts","../../../node_modules/ioredis/built/index.d.ts","../../../node_modules/bull/index.d.ts","../../types/src/sdk/automations/index.ts","../../types/src/sdk/hosting.ts","../../types/src/sdk/events/identification.ts","../../types/src/sdk/events/event.ts","../../types/src/sdk/events/app.ts","../../types/src/sdk/events/auth.ts","../../types/src/sdk/events/automation.ts","../../types/src/sdk/events/email.ts","../../types/src/sdk/events/datasource.ts","../../types/src/sdk/events/layout.ts","../../types/src/shared/typeUtils.ts","../../types/src/shared/index.ts","../../types/src/sdk/licensing/license.ts","../../types/src/sdk/licensing/plan.ts","../../types/src/sdk/licensing/quota.ts","../../types/src/sdk/licensing/feature.ts","../../types/src/sdk/licensing/billing.ts","../../types/src/sdk/licensing/index.ts","../../types/src/sdk/events/license.ts","../../types/src/sdk/events/version.ts","../../types/src/sdk/events/query.ts","../../types/src/sdk/events/role.ts","../../types/src/sdk/events/rows.ts","../../types/src/sdk/events/screen.ts","../../types/src/sdk/events/serve.ts","../../types/src/sdk/events/table.ts","../../types/src/sdk/events/user.ts","../../types/src/sdk/events/view.ts","../../types/src/sdk/events/account.ts","../../types/src/sdk/events/backfill.ts","../../types/src/sdk/events/userGroup.ts","../../types/src/sdk/events/plugin.ts","../../types/src/sdk/events/backup.ts","../../types/src/sdk/events/environmentVariable.ts","../../types/src/api/account/accounts.ts","../../types/src/api/account/user.ts","../../types/src/api/account/license.ts","../../types/src/api/account/status.ts","../../types/src/api/account/index.ts","../../types/src/api/web/analytics.ts","../../types/src/api/web/auth.ts","../../types/src/api/web/user.ts","../../types/src/api/web/errors.ts","../../types/src/api/web/debug.ts","../../types/src/api/web/schedule.ts","../../types/src/api/web/system/environment.ts","../../types/src/api/web/system/index.ts","../../types/src/api/web/app/backup.ts","../../types/src/api/web/app/datasource.ts","../../types/src/documents/document.ts","../../types/src/documents/app/row.ts","../../types/src/api/web/app/row.ts","../../types/src/api/web/app/view.ts","../../types/src/api/web/app/rows.ts","../../types/src/api/web/app/table.ts","../../types/src/api/web/app/index.ts","../../types/src/api/web/global/environmentVariables.ts","../../types/src/api/web/global/auditLogs.ts","../../types/src/api/web/global/events.ts","../../types/src/api/web/global/configs.ts","../../../node_modules/scim-patch/lib/src/errors/scimErrors.d.ts","../../../node_modules/scim-patch/lib/src/types/types.d.ts","../../../node_modules/scim-patch/lib/src/scimPatch.d.ts","../../types/src/api/web/global/scim/shared.ts","../../types/src/api/web/global/scim/users.ts","../../types/src/api/web/global/scim/groups.ts","../../types/src/api/web/global/scim/index.ts","../../types/src/api/web/global/license.ts","../../types/src/api/web/global/index.ts","../../types/src/api/web/pagination.ts","../../types/src/api/web/index.ts","../../types/src/api/index.ts","../../types/src/sdk/events/auditLog.ts","../../types/src/sdk/events/index.ts","../../types/src/sdk/context.ts","../../types/src/sdk/migrations.ts","../../types/src/sdk/datasources.ts","../../types/src/sdk/search.ts","../../../node_modules/@types/accepts/index.d.ts","../../../node_modules/@types/keygrip/index.d.ts","../../../node_modules/@types/range-parser/index.d.ts","../../../node_modules/@types/qs/index.d.ts","../../../node_modules/@types/express-serve-static-core/index.d.ts","../../../node_modules/@types/mime/Mime.d.ts","../../../node_modules/@types/mime/index.d.ts","../../../node_modules/@types/serve-static/index.d.ts","../../../node_modules/@types/connect/index.d.ts","../../../node_modules/@types/body-parser/index.d.ts","../../../node_modules/@types/express/index.d.ts","../../../node_modules/@types/cookies/index.d.ts","../../../node_modules/@types/http-assert/index.d.ts","../../../node_modules/@types/http-errors/index.d.ts","../../../node_modules/@types/content-disposition/index.d.ts","../../../node_modules/@types/koa-compose/node_modules/@types/koa/index.d.ts","../../../node_modules/@types/koa-compose/index.d.ts","../../../node_modules/@types/koa/index.d.ts","../../../node_modules/@types/formidable/Formidable.d.ts","../../../node_modules/@types/formidable/parsers/index.d.ts","../../../node_modules/@types/formidable/PersistentFile.d.ts","../../../node_modules/@types/formidable/VolatileFile.d.ts","../../../node_modules/@types/formidable/FormidableError.d.ts","../../../node_modules/@types/formidable/index.d.ts","../../types/src/sdk/koa.ts","../../types/src/sdk/auth.ts","../../../node_modules/@types/bluebird/index.d.ts","../../../node_modules/@types/redlock/index.d.ts","../../types/src/sdk/locks.ts","../../../node_modules/@budibase/nano/lib/nano.d.ts","../../../node_modules/@types/ms/index.d.ts","../../../node_modules/@types/debug/index.d.ts","../../../node_modules/@types/pouchdb-find/index.d.ts","../../../node_modules/@types/pouchdb-core/index.d.ts","../../../node_modules/@types/pouchdb-adapter-cordova-sqlite/index.d.ts","../../../node_modules/@types/pouchdb-adapter-fruitdown/index.d.ts","../../../node_modules/@types/pouchdb-adapter-http/index.d.ts","../../../node_modules/@types/pouchdb-adapter-idb/index.d.ts","../../../node_modules/@types/pouchdb-adapter-leveldb/index.d.ts","../../../node_modules/@types/pouchdb-adapter-localstorage/index.d.ts","../../../node_modules/@types/pouchdb-adapter-memory/index.d.ts","../../../node_modules/@types/pouchdb-adapter-websql/index.d.ts","../../../node_modules/@types/pouchdb-adapter-node-websql/index.d.ts","../../../node_modules/@types/pouchdb-mapreduce/index.d.ts","../../../node_modules/@types/pouchdb-replication/index.d.ts","../../../node_modules/@types/pouchdb-browser/index.d.ts","../../../node_modules/@types/pouchdb-http/index.d.ts","../../../node_modules/@types/pouchdb-node/index.d.ts","../../../node_modules/@types/pouchdb/index.d.ts","../../types/src/sdk/db.ts","../../types/src/sdk/middleware/matchers.ts","../../types/src/sdk/middleware/tenancy.ts","../../types/src/sdk/middleware/index.ts","../../types/src/sdk/featureFlag.ts","../../types/src/sdk/environmentVariables.ts","../../types/src/sdk/auditLogs.ts","../../types/src/sdk/user.ts","../../types/src/sdk/sso.ts","../../types/src/sdk/cli/constants.ts","../../types/src/sdk/cli/index.ts","../../types/src/sdk/websocket.ts","../../types/src/sdk/permissions.ts","../../types/src/sdk/index.ts","../../types/src/documents/global/config.ts","../../types/src/documents/global/user.ts","../../types/src/documents/global/userGroup.ts","../../types/src/documents/global/plugin.ts","../../types/src/documents/global/quotas.ts","../../types/src/documents/global/schedule.ts","../../types/src/documents/global/templates.ts","../../types/src/documents/global/environmentVariables.ts","../../types/src/documents/global/auditLogs.ts","../../types/src/documents/global/index.ts","../../types/src/documents/account/account.ts","../../types/src/documents/account/user.ts","../../types/src/documents/account/index.ts","../../types/src/documents/app/app.ts","../../types/src/documents/app/automation.ts","../../types/src/documents/app/view.ts","../../types/src/documents/app/table/constants.ts","../../types/src/documents/app/table/schema.ts","../../types/src/documents/app/table/table.ts","../../types/src/documents/app/table/index.ts","../../types/src/documents/app/datasource.ts","../../types/src/documents/app/layout.ts","../../types/src/documents/app/query.ts","../../types/src/documents/app/role.ts","../../types/src/documents/app/component.ts","../../types/src/documents/app/screen.ts","../../types/src/documents/app/user.ts","../../types/src/documents/app/backup.ts","../../types/src/documents/app/webhook.ts","../../types/src/documents/app/links.ts","../../types/src/documents/app/index.ts","../../types/src/documents/platform/info.ts","../../types/src/documents/platform/users.ts","../../types/src/documents/platform/accounts.ts","../../types/src/documents/platform/tenants.ts","../../types/src/documents/platform/index.ts","../../types/src/documents/pouch.ts","../../types/src/documents/index.ts","../../types/src/core/installation.ts","../../types/src/core/index.ts","../../types/src/index.ts","../src/helpers/helpers.ts","../src/helpers/integrations.ts","../src/helpers/index.ts","../src/filters.ts","../src/utils.ts","../src/sdk/documents/applications.ts","../src/sdk/documents/users.ts","../src/sdk/documents/index.ts","../src/sdk/index.ts","../src/index.ts"],"fileInfos":[{"version":"f5c28122bee592cfaf5c72ed7bcc47f453b79778ffa6e301f45d21a0970719d4","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","e6b724280c694a9f588847f754198fb96c43d805f065c3a5b28bbc9594541c84","1fc5ab7a764205c68fa10d381b08417795fc73111d6dd16b5b1ed36badb743d9",{"version":"3f149f903dd20dfeb7c80e228b659f0e436532de772469980dbd00702cc05cc1","affectsGlobalScope":true},{"version":"adb996790133eb33b33aadb9c09f15c2c575e71fb57a62de8bf74dbf59ec7dfb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"181f1784c6c10b751631b24ce60c7f78b20665db4550b335be179217bacc0d5f","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"09aa50414b80c023553090e2f53827f007a301bc34b0495bfb2c3c08ab9ad1eb","affectsGlobalScope":true},{"version":"d7f680a43f8cd12a6b6122c07c54ba40952b0c8aa140dcfcf32eb9e6cb028596","affectsGlobalScope":true},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"cd483c056da900716879771893a3c9772b66c3c88f8943b4205aec738a94b1d0","affectsGlobalScope":true},{"version":"b248e32ca52e8f5571390a4142558ae4f203ae2f94d5bac38a3084d529ef4e58","affectsGlobalScope":true},{"version":"c37f8a49593a0030eecb51bbfa270e709bec9d79a6cc3bb851ef348d4e6b26f8","affectsGlobalScope":true},{"version":"5c4156a45a0ed065e676dd025742932d98adfcc188fd263ba11438e3fa06dee6","signature":"81b7f64a170bd1400a4442023ebae837b81738cd398a4fe69a84353853ab1c4e"},"7e771891adaa85b690266bc37bd6eb43bc57eecc4b54693ead36467e7369952a","a69c09dbea52352f479d3e7ac949fde3d17b195abe90b045d619f747b38d6d1a",{"version":"02873d070f9cb79f50833fbf4a9a27ac578a2edf8ddb8421eba1b37faba83bfb","affectsGlobalScope":true},"21a167fec8f933752fb8157f06d28fab6817af3ad9b0bdb1908a10762391eab9",{"version":"c0db280fa6b09d7b8d6720a19a47f485956a41ee0e6914f1b704033eb69c6058","affectsGlobalScope":true},"374ca798f244e464346f14301dc2a8b4b111af1a83b49fffef5906c338a1f922","5a94487653355b56018122d92392beb2e5f4a6c63ba5cef83bbe1c99775ef713",{"version":"d5135ad93b33adcce80b18f8065087934cdc1730d63db58562edcf017e1aad9b","affectsGlobalScope":true},"82408ed3e959ddc60d3e9904481b5a8dc16469928257af22a3f7d1a3bc7fd8c4","dab86d9604fe40854ef3c0a6f9e8948873dc3509213418e5e457f410fd11200f","bb9c4ffa5e6290c6980b63c815cdd1625876dadb2efaf77edbe82984be93e55e","489532ff54b714f0e0939947a1c560e516d3ae93d51d639ab02e907a0e950114","f30bb836526d930a74593f7b0f5c1c46d10856415a8f69e5e2fc3db80371e362","14b5aa23c5d0ae1907bc696ac7b6915d88f7d85799cc0dc2dcf98fbce2c5a67c","5c439dafdc09abe4d6c260a96b822fa0ba5be7203c71a63ab1f1423cd9e838ea",{"version":"6b526a5ec4a401ca7c26cfe6a48e641d8f30af76673bad3b06a1b4504594a960","affectsGlobalScope":true},{"version":"816ad2e607a96de5bcac7d437f843f5afd8957f1fa5eefa6bba8e4ed7ca8fd84","affectsGlobalScope":true},"cec36af22f514322f870e81d30675c78df82ae8bf4863f5fd4e4424c040c678d","d903fafe96674bc0b2ac38a5be4a8fc07b14c2548d1cdb165a80ea24c44c0c54","5eec82ac21f84d83586c59a16b9b8502d34505d1393393556682fe7e7fde9ef2","04eb6578a588d6a46f50299b55f30e3a04ef27d0c5a46c57d8fcc211cd530faa","8d3c583a07e0c37e876908c2d5da575019f689df8d9fa4c081d99119d53dba22","2c828a5405191d006115ab34e191b8474bc6c86ffdc401d1a9864b1b6e088a58",{"version":"e8b18c6385ff784228a6f369694fcf1a6b475355ba89090a88de13587a9391d5","affectsGlobalScope":true},"d4ac44f01d42f541631c5fc88d0ed8efac29a3a3ad9a745d9fd58f8b61ed132e","7c013aa892414a7fdcfd861ae524a668eaa3ede8c7c0acafaf611948122c8d93","b0973c3cbcdc59b37bf477731d468696ecaf442593ec51bab497a613a580fe30",{"version":"4989e92ba5b69b182d2caaea6295af52b7dc73a4f7a2e336a676722884e7139d","affectsGlobalScope":true},{"version":"b3624aed92dab6da8484280d3cb3e2f4130ec3f4ef3f8201c95144ae9e898bb6","affectsGlobalScope":true},"5153a2fd150e46ce57bb3f8db1318d33f6ad3261ed70ceeff92281c0608c74a3","210d54cd652ec0fec8c8916e4af59bb341065576ecda039842f9ffb2e908507c","36b03690b628eab08703d63f04eaa89c5df202e5f1edf3989f13ad389cd2c091","0effadd232a20498b11308058e334d3339cc5bf8c4c858393e38d9d4c0013dcf","25846d43937c672bab7e8195f3d881f93495df712ee901860effc109918938cc","3163f47436da41706c6e2b3c1511f3b7cce9f9f3905b2f3e01246c48b4ba7d14","1b952304137851e45bc009785de89ada562d9376177c97e37702e39e60c2f1ff","69ee23dd0d215b09907ad30d23f88b7790c93329d1faf31d7835552a10cf7cbf","44b8b584a338b190a59f4f6929d072431950c7bd92ec2694821c11bce180c8a5","23b89798789dffbd437c0c423f5d02d11f9736aea73d6abf16db4f812ff36eda","223c37f62ce09a3d99e77498acdee7b2705a4ae14552fbdb4093600cd9164f3f",{"version":"970a90f76d4d219ad60819d61f5994514087ba94c985647a3474a5a3d12714ed","affectsGlobalScope":true},"e10177274a35a9d07c825615340b2fcde2f610f53f3fb40269fd196b4288dda6","4c8525f256873c7ba3135338c647eaf0ca7115a1a2805ae2d0056629461186ce","3c13ef48634e7b5012fcf7e8fce7496352c2d779a7201389ca96a2a81ee4314d","5d0a25ec910fa36595f85a67ac992d7a53dd4064a1ba6aea1c9f14ab73a023f2",{"version":"f0900cd5d00fe1263ff41201fb8073dbeb984397e4af3b8002a5c207a30bdc33","affectsGlobalScope":true},{"version":"4c50342e1b65d3bee2ed4ab18f84842d5724ad11083bd666d8705dc7a6079d80","affectsGlobalScope":true},"06d7c42d256f0ce6afe1b2b6cfbc97ab391f29dadb00dd0ae8e8f23f5bc916c3","ec4bd1b200670fb567920db572d6701ed42a9641d09c4ff6869768c8f81b404c","e59a892d87e72733e2a9ca21611b9beb52977be2696c7ba4b216cbbb9a48f5aa",{"version":"da26af7362f53d122283bc69fed862b9a9fe27e01bc6a69d1d682e0e5a4df3e6","affectsGlobalScope":true},"8a300fa9b698845a1f9c41ecbe2c5966634582a8e2020d51abcace9b55aa959e",{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true},"652ee9c5103e89102d87bc20d167a02a0e3e5e53665674466c8cfea8a9e418c7","e8a5beb73e49b5a4899f12b21fa436f4088f5c6b22ed3e6718fcdf526539d851","911484710eb1feaf615cb68eb5875cbfb8edab2a032f0e4fe5a7f8b17e3a997c","4b16f3af68c203b4518ce37421fbb64d8e52f3b454796cd62157cfca503b1e08","4fc05cd35f313ea6bc2cd52bfd0d3d1a79c894aeaeffd7c285153cb7d243f19b","29994a97447d10d003957bcc0c9355c272d8cf0f97143eb1ade331676e860945","6865b4ef724cb739f8f1511295f7ce77c52c67ff4af27e07b61471d81de8ecfc","9cddf06f2bc6753a8628670a737754b5c7e93e2cfe982a300a0b43cf98a7d032","3f8e68bd94e82fe4362553aa03030fcf94c381716ce3599d242535b0d9953e49","63e628515ec7017458620e1624c594c9bd76382f606890c8eebf2532bcab3b7c","355d5e2ba58012bc059e347a70aa8b72d18d82f0c3491e9660adaf852648f032","0c543e751bbd130170ed4efdeca5ff681d06a99f70b5d6fe7defad449d08023d","c301dded041994ed4899a7cf08d1d6261a94788da88a4318c1c2338512431a03","236c2990d130b924b4442194bdafefa400fcbd0c125a5e2c3e106a0dbe43eaad","ded3d0fb8ac3980ae7edcc723cc2ad35da1798d52cceff51c92abe320432ceeb","fbb60baf8c207f19aa1131365e57e1c7974a4f7434c1f8d12e13508961fb20ec","00011159f97bde4bdb1913f30ef185e6948b8d7ad022b1f829284dfc78feaabf","ed849d616865076f44a41c87f27698f7cdf230290c44bafc71d7c2bc6919b202","9a0a0af04065ddfecc29d2b090659fce57f46f64c7a04a9ba63835ef2b2d0efa","10297d22a9209a718b9883a384db19249b206a0897e95f2b9afeed3144601cb0","620d6e0143dba8d88239e321315ddfb662283da3ada6b00cbc935d5c2cee4202","34d206f6ba993e601dade2791944bdf742ab0f7a8caccc661106c87438f4f904","05ca49cc7ba9111f6c816ecfadb9305fffeb579840961ee8286cc89749f06ebd","7a8f88a3c2fe242340d912d47b31c0d7e16ce609550ddf72542c20fc38c991f9","5e139257f9b90215d61bac13b093782d06abb768640a2fb3062039cfd2d946f1","cc2fb422a777f2187f47e33bf5203c03577fae95c5dc2c5faf1ada278d26cff3","ce5c86b8f1033248357b7075d048418e46928045911ccd30bd72cb0f4753cfda","b9301d962c7dcc772e53c17ee80835cd0a5c2ca916560e6d8b996c9dac3bfce4","82323a27cc057988f9b022d6b412f5aabcab30582b1a1bd8599233eab7bd40b9","229af036201c8a479cba224ee7d2223e1ffd8e4bc4042367b4e3f5cea2c4aabf","2871eaae8c12a6498f7977a2a0ad3e0e98566fe652ccbd5b2f231d89e7c26931","45aa3f5403e3da5c87ec79dd06119933edd9540a0522569c9010f1a287ea4985","4c9afec411a6e61f530508ff294d4cab72a54f5581a4d2fe2bbdffef5b8c3284","b4e67ffaf8e9f286845f3beb1a0621a337c533e46270f9bd4e7e48169ed707aa","214b34f0d9b1ba6ec55978ba085984a5b67be9ae574bd29ca59e7a13c0f5b906","91dc2dd51eec0d463cfe61a93c35edfc5c47e8273b69b8eef40494a70e54d56e","0dbd6925493462522d38684914c22b3f483bcbd8d9f5ad4f9f301425f7bc6646","e247399fdbeb968316720e3f0d9260218f3368a7e145182201a0340c1543fde8","f7c485727e60d18b477fb695785c762e9912345aeaf1f5506cc1c691475364f0","c81d4fdb34876b868ff4ef7a6a79e0a72490441672bcd032d33db8ff9a3e35a4","848ae9219cfab69670efed029061e740794a1009e60ceac545ff923a13313a42","1c0bafd7ac74d3a109a0ce46281e0d1f4b0a32368894c626daed0405e19b6474","1a12710ebcabd69a215c70d44e030a0c46dda1fce1aa3b7ffa873851981814e9","23bd67eb3caf0344aa1a4a3b9e2a88f4dd4a7204cda42e532f54612cfd61a7af","643b4a91e77e5a597388564b6d1fd6256dfdd326d92c8dd03b1abf803780276b","aa52289c977c5958f9367bac59e747c7709ac5b8f275aaab677805921917b07e","dcf1f7a5efd432c62e9fe0730cf4ee32383ecb0ad791299339cf8cd6d650ae8e","b6157f47fe18e423ad88dec02d9ff674ae06e609a4662fba265c2df71ac532e1","cdca530ff27125096dd59e3d44c6e22d8b82591aa62c2823b667b06ae6788cc0","4e5558edf57dcf00bb63d102838dab79663b05957c68b768fa33e9c66e92996a","ed933637fb372d64e8be51391a7d631e98ad1d23b95ac0d9a3b5e85b24d64717","f69ac66ed5f71ee0e9d14c044b811d557dd3e6138db0fff1107c45a8a8f25d96","f53557bbfa5bce74e6535ce28af9591a798228aa4aa2bcc1fd71c36578799ab1","5043f7e9b57906fb49f7dfed3364f1a810536f7ca0baeb2a7d3e18ae6673383c","2394368278ec630534c33341fc776c24c39a1741c815ae8e16bf58134bbcc416","b411161dffe5330ad16fc42bdd111f9f0fa33785d04e4def05d902023b6b0050","1010c8b335100effcd5713544584d9e78eaf7f5d187ef526d1f87bb52b3185d0","ee1a1cc5ea76cd31df56458ada4a5656e23fd004e8d18375083c13dc6921ddb9","c9041745d48194175d9b03fbc83cab45feebe8f7324e67b211cff748349a37b6","6bc71fe92fda2de09dcc163a0996d7e1f9cc003c0ceefe878b3c6f14d7d95af8","cac65e926c86e6e6fc456e08add0734c39154fe74afe02c9a290e54118a12b87","c8a32c9b70802c9a1b4034a5c03b63fbb6d2fde2650bf2593c78d3423db2a959","623f74fa56ef796a1d0157f727ea698beeeefb25eabeec4ce626a842f647c0a7","1c2554c26f344519d93205560c59afc78db6eb1f93ba6f43e6087cd77073c55b","fcb1512a3b2bac87bc232e18cfea03c3fa8587e99d894d799265c4160adac6e3","2f02112a1103e5bb7ac66300e7542ca2bdea76d7b58aead716341269bea1ac9a","143a0e5d6e7e88cc3bbb4a401106ed1c4bf32ca3bf5f9abe8ccec03aaf1afda5","56afbae02873067df19ae433f1351096415cb4066530d495e6f3513e830b2df1","5aeb8ae904f59fac9e431cb11bf9d0bfbbc41499ce01665de8e3abcd42084683","ce0a498063936ac0c3887cc7460310832b514aaf95851f0bbff914dc9b57198e","13cd76f99dc3a10924365badcc5a0835713ff120e02c7f61111bca8f1107bde8","0143ef72551e966dc13ec32bb267ec003707ffed939322beeaeb42be06d32a03","7482a369d4012cd67c54c581a7ffa45ebb496b8c46e1c5abcac70ece1573f840","676d1477cefe2a51af0868eaf1f6fd54978edad68468ebf55e93b6dd9d833455","bd82203c3b911bfa6c25c3be997c8f7ba28cc2bf4da50030c80109ffc5255270","42e0ccad011ee7bc6eb4a73bf5096e170d2739ae3a50b129e30db89a9e0a0bb2","56401d53790195ceb8c27120eca639a433372b241f4a14a6f5a1ac84162e14a3","a52fec1145b48a7d383c40c5a57ef2e3e92e9047460b3989648a73817e967c68","e483f74040428414fa180bab7647656d0a8bbd1f224b2f4e5ebc43f33db9408d","93cb9ab3b688489084c21ef618c94eae86ee9577dd5144a15fbbbd0f37eeab84","3ba20eb1d66b8f34ab569d30fb1835ecbff8e3f6f235e38712f4bc50da95ddaa","e94ce39bd3264c994e8d9c1a7aecda2eec943679fa3e9347521ab28c6cbfd8cd","88251a831769c396c025511e75cd64d87c5aff201a43bb4f0c0b729690c8b9b1","7ededf4537038ea7487f5e14d30754c629bbba6c9e890ed7b6eb55fb6e83e1af","d566db3d6d32137e32caaba4263d8d251751a5750cdbfd22376216521f6fc858","fa41729dead31728b7797085a5c72cfd620ba436e6453cfe6ec63037688309c6","90e9449a209e2d19ebf92d76f9cf616583aeeb3d7445e0f4759a1360e0e4612a","2f76e8269c67b46b2d8a237b0d436a599e301fc9f15b9c0df3be6a2894cc93c9","318f08e58a2cc6ae3da2facddb409d87ac20c2b656796b983df26384445cd27f","63f26e163f4c4eee19680bd50151f8081fa86e634d4e3f186a3637058927372f","b1510a148984e6be03e02217068d9b26dfe6413a4a2b583a7a91b18669179553","79d031d0f4a7aaccba134fcbfcfddcb3c9fb9928e0e34a58cb8121649ac96805","dfecf9e7f659014cedf729a49f02a7ccffb0c35266fc318d50f5e492933ee2b9","dfda175b1f7307e6dfde84445320ec3020ec2ec7274d231437a05866f7cc6801","222feaad9c02ffd70f0b6493a95a941aa4271b9608c72d57cbb9d95f7fb16753","2ef61dcc79e971ce3c346521e7b79643a84d4208bf80ce3dd94339f419bd909c","5077aadbeef23605098b3dd01357183aa31dbfe3c0f02caa4cfe8dc7f98edbb7","ff756a87010fa97054a21e06b997e2f92ac276679484ae0f7504367c5b568fea","5c50d9341324813cb73d3a15b1e56971e56a8bbc2139029a0cf426c0efb3233a","7ee928e608f05c9002a2f5e0c4dd8aa687231859f7c4a436094bc5bc16e8030c","53ebbd156702e50a6dbb9579f0bf8192129185601942da6a13c0dd4765d754e4","fb8e72a58a2bf4da300573d674b7a25c8f2ce1a0a5b2ba80ef68f5d66857c8bb","6738101ae8e56cd3879ab3f99630ada7d78097fc9fd334df7e766216778ca219","ce013414484233b24f42c0fcfca48a60bb66ab4e13c82953662305e8f1ee4925","16d51f964ec125ad2024cf03f0af444b3bc3ec3614d9345cc54d09bab45c9a4c","ba601641fac98c229ccd4a303f747de376d761babb33229bb7153bed9356c9cc",{"version":"c5dd1fef4cd4aaffc78786047bed5ae6fc1200d19a1946cbc4e2d3ed4d62c8fa","affectsGlobalScope":true},"5b9ecf7da4d71cf3832dbb8336150fa924631811f488ad4690c2dfec2b4fb1d7","951c85f75aac041dddbedfedf565886a7b494e29ec1532e2a9b4a6180560b50e","e6f0cb9d8cb2e38bec66e032e73caa3e7c6671f21ed7196acb821aec462051f2","6d829824ead8999f87b6df21200df3c6150391b894b4e80662caa462bd48d073","afc559c1b93df37c25aef6b3dfa2d64325b0e112e887ee18bf7e6f4ec383fc90","43cdd474c5aa3340da4816bb8f1ae7f3b1bcf9e70d997afc36a0f2c432378c84","eb96a2321f717bccc3e49e104e299152984b927ea4546b559ae631c06565819c","e98185f4249720ace1921d59c1ff4612fa5c633a183fc9bf28e2e7b8e3c7fd51","f463d61cf39c3a6a5f96cdf7adfdb72a0b1d663f7b5d5b6dd042adba835430c2","204dbe6c72467fb14bbe8f06510b11fb541b6ce29580c6e10ebd3bdb2eb0c1f9","3a9b877f47119ac64aab98c61cae91a304ddeb6e8285ccd824a6aa665ffaeb95","5006668996956580886022c05108e32c742823e1b5652aff7914917233731518","0c52f5366c9146ad79b546e70162c659972a2798522806e8283f3137feab3965","ac9788076b6b9e4514ff1286de37bf90f8e2c1dd7a772c2e746232eaa4184233","49d41b881040e728bc28d463806cdff98b64c69e9da721adcf0ec34345f691b5","0623c302651761724ec920bb95a27d9d47ea71f7e6ef7e4d6f60bd05c86cf50c","b6e465de1852a328392b432b13ee8334b209f3493053e85aa8f0b5f78368d634","afc87a77703487af971af992374f59a6cc729411cd8498a492eb14cce49f092b","2c26ca5810ebbf0129a279811816d6fd703b79b087c1bd723e3dd9bfe75681da","c77000c4b47237afbdb842ce9c4c8581521d17a43c73fbe4351e41d844e6ac63","61a7daacc55ac6eaa7fbd9997e64b7c799979f843a9916eb733dc5746f423304","338bd7c3518b05b4c473971be0e5f8f854aca7cdb00d1b97192c14860f4ebf2f","9f4b16c9bb8cf258ef8c5f258dff2ab2e453b22c2251253f27287502c5ff54b8","b43944351256f23caff0685e5f2e44f467f1dee2561f9ce5dac37b3e356ab9c3","f5a8011ef75fbd0daf9be4e8d668e8c59a954a3cf5768fb977633f363697fc0d","6a9c5127096b35264eb7cd21b2417bfc1d42cceca9ba4ce2bb0c3410b7816042","78828b06c0d3b586954015e9ebde5480b009e166c71244763bda328ec0920f41",{"version":"05bcf7cdd90fde4f5eccd2228833dc9516d55f65cf2f34d9716436ccfdeaf373","affectsGlobalScope":true},{"version":"2e332da5d628517bf415be2851b1954512b83f6bae4a98ed9786c6d4bf837bb8","affectsGlobalScope":true},{"version":"0ccdb32b10deec10f96dd2269690fc07db39ff6f9ccbb16d99f72e9f54f5576e","affectsGlobalScope":true},{"version":"eaa52db1743cc9bbaf4132bcec47862c20f0d1a90c697928538717db348d04f2","affectsGlobalScope":true},{"version":"838524a3cc660f7bbb104ffa15febad659d1ef1633dac47340bfbfcbbbffdb08","affectsGlobalScope":true},{"version":"50a03e74fae4542ecfb326b34517ec2e058aee15bcb60af5b2e41c5e2db0d079","affectsGlobalScope":true},{"version":"55fa94d97752ac80305ab40cfcfaff0e09686f17cf62af290c449d7c3ee8b36a","affectsGlobalScope":true},{"version":"b634704c5a9e9bbfa08f5a5cf15ced9a5cc3c6deb705d9ff991767c748df16d0","affectsGlobalScope":true},{"version":"2658596fba5dc1f249defa7a040e62dac43c7cffe2f0cc74aacca79f382d478c","affectsGlobalScope":true},{"version":"d252bde46b7594f8f90a45d59181b08134ee8c4919ebb2ba7088ba26056bf621","affectsGlobalScope":true},"4398ad7456600ca5a642700180784400f990850a24b9e670d525ee897d0e06ac",{"version":"ab07d0ccd50b935d94c4abc2d1c894c57e3c872e845ace48c155b1f7f0382138","affectsGlobalScope":true},{"version":"10e86904b516b4280894d60f6062a126601c972987f9d1bd084908b9f41f2c4c","affectsGlobalScope":true},"4d737cdd77685ed65bd61d375375cae446fb0f46f711bbb3ef3f81a350212569","78aaf57ca7d006729a4b490598ebfc293c734702a32418c3ec072d958ab885df",{"version":"c3a71f48965f53df96b6532bd2d3df26f59b74329166281fca68d932a6402312","affectsGlobalScope":true},"45c31e764a94467bb99a8ab1733869142ad188a1caee2d41e764391378089caf","994b3e37c3ff31814fd6b380231b28593d5a366820ad48699ab8505f6875ce4b","1fe6a1471ea9e3d299fc11d46c8f6d33ea32924f2bb835793af6d9cf081ebf89","5e2f0937d793fc9355742ca1bfde5c926e0c4305d36f4aab98067bf9cd25abe6","c24ad307b747eb0737bb2189521b7542a1751266206dc151a6eac1675faff413","62467ba747e6a2ff5c3ebfb8f8ac59b48f1a28f73eb7c6b9068d90016c47a840","54892bdcf9b5c13c9758575d4e5317e032850f726ad1c0a9cf689ea13d96af8b","22001fa9bc521f7f8bbb9f861d768138c8d2f34c925b2f7359c5c7b8381fce7a","2416328692e9325bceb947f3aefe248ff890e33a12d97c650f960bf66bcb7261","122319a37511aa93dcd30118642c13aca0c96fde72a88518bb048ebcde3a4cb3","6f3a5fd9bccbb0597eac90013aa05a625da74471e0673cc9c0a523d483fe65aa","7ce791eab05da7215bfa0bfd516e30001c8af7f0fd0c611e5e3218cef9c992e5","c56a70d1e7d8bec1a5ce246ce71db4272eebfa57ab32b837976d282450252e51","d4d4908f060adc05df0ee839704c216579d399489ad40a3143a4667e0d60cd58","aeab5afd036d8aae9c4fbd781fb29ed795ef6e7b7007d8b6ccd60036213ccc8b","83e0d4e2606afa8e7fadc715add59d1c55ddd17be8e410fbc16ffb23daba24b1","7fc983825d9e2f689d1cf0904b775ffb606de09c6d07738a89eba01ce90d14f6","dcabdd70509c7e6f2da94a0d7db4c466de248c9c847d61ce1ff280e152637243","e0a0227eacb42608c8720090bd23555bcd2ed4d4ffbd4deb697d005a07a7d6d1","c729d034507ba27fa5da4b9f95fa420b712a8e50190c98bfb876b2aec9c803fe","e28f6d16eec2a55bbac070a930ed6477187d63131e301c982a05aef0e926d081","acb6eaf0a8d6cd35295ac41816daf9e00cd5685a24e29ccd832c50b15184ce64","96bc22c39fa0f0846d2dcced5db92fd84f3ceb90f753bfb73101505f159403fa","34275d6120a28568b777920331262c242bba566d1757cb5bab999dcd14e9d4a1","8f3a8bded555cc4f9d4242c2628d1fe848be08b6f734f67c5b705bcf320b5d05","e6ea899479811e1c641f9492d36621a7b557f30620ffda286651d875167cf548","a5f697744940fc979055182ce7d2adcb3f87603367530b0129e6a442bb94b5db","85e0b9eaeabf529f8bb740575ccb8c8d382303302f2ee52f9d2afe85222d1810","55560ff4c419e55688c9ec6f9d734e735186200d2dd9f8c3a2dfb3e6cac272dd","cc25e277351a137e877f7d15bf79e8038ee9dcde472581d2cb3370d308849e4e","ead1d47c5c74e955f77f915afcfb335f810cc4de8d0cdaa3b6db61404ac8033d","268e80000aad48f80efa418743b1c767cb3269b9c876fbb521012064809aea18","5e630cac30dba8d8787154482d9561fbb9f732d29427452194a7c8464447ec47","4d04955b14fe7beec6747d18c3d087d744baa5839b0e73e9541268f47825a3da","a8126d0d722f6124c6f93f3fb032e09a6344f9a2ef273fecf5ccd2f3f493277f","53a64e9f1a3bd8e5381fe7ad95aba89e4a34df019b0b6888b0693a04e2b13c72","c8a2055310d50decc608c825eb89a3b099258349e83000396c0cfb36b64c706a","180acec84126e021125723f53e0649aa2af55bab83d646b7511d4481c11b744d","431b31ffcf842adebc8c79d9bd08d2983e618d018d4a02baedb33d078c754a1c","851a8520a62fe5edc3bd3b7d41dab5819bb01f541a6544f0a80441860e6d71c6","59a50ee813a1556644f8c466056a39a68c4aa4b92d0a8783fc561a1c65182577","b0d8f1ac4057772100cc40de25db8a5743b6f5aca50876fd0ca85fd54cc3d3d8","66e3826b09793b21f201f97db58cdf80784e3849ad42e90c8f0c072ca0337089","5af6cf95cbf6a36f2f0a4bb018bc1cd90fdd5907598db73c99060ed89ee9f830","3ec197a797793caed862517e7932ae342f1fddfc6ee495c3292d4a9426d3f169","78ce3171fb60b891ccd880ae48f278e3a3fe6663cdeacea86e087f11be3e6c3c","8c99213d1d9ac83db53893e1f66fc476a77b336bf0b473145c79f7d242ca15de","ebfb0cf59e3016515c8130d54da857e44c6d3e3114dd20d815f26e3161430736","6e6a0847c92b56147c7305fe612f929d734d49740a9f320388277430f9fa932e","a08dc598a8d92273505da4cb60562640c6067fd0c53d2569afd58eca095d7fbb","285b65036b421ab4b3806eeebae1f34060d5ee1fff679196f8e3e0f356e9a6f3","b2f3ac4b3c6fc88856673d854521224a3514ef0004441196cb8ab8bc530e707b","2d507428287091d0e891efbba40cf64b82fddca876cd9cbf6ab80a20c94d7ea3","168ecd7d9bdeb10c2c102fa468ea499fcd575ede7cfaa5f8aeef05bccef40888","f3605fac76572d36e83c853bda9ff11ded4dfe054d0e611f49741a52c0981bcd","3eab4545c2b6507f0ff9b7c1fc3aeb95eba1084e67c7370848385ea11e13a7a0",{"version":"3f74861b67c01b4fbb02f92a87cbff4e6c812e386b833f272b705f2b95c9a6ee","signature":"dd70ae40b15b6a926ec618c13ec73d554199eed730894d44e2c8d84c9325a4b7"},{"version":"05b90731ea267460f4587f8cd89ee500567d3fb286d6ede911b9a5fc6ba8af1a","signature":"47c84bc2fd7abf676f705b400b8925aba0074040f44c46bff544120185da6662"},{"version":"ae3c6325d7867b6bf3f7f8e8005c117d9f51939387728d31d86ea5e56aeb1e85","signature":"ced0fc745106d6553a064ccb265eb9c38750296fba3f9dc4dd0a040847ce1d06"},{"version":"23dd0ddcf42e61b4ef1c08cadbcc55dd50f9c47c8c3d8c837f6980e7f2c5959f","signature":"2971d92e1d6a8771c5402392976271d4ed95996b5b29370abebba2a80ddfc37a"},{"version":"efa06b009d5fc92cc1413bbd89f5bc3a7c92d0b7627777d3ce3a069e69398933","signature":"562592b4a84c13be17b7479048c9b5baf7676342903e4fb0466d2e11fb17ae78"},{"version":"a989b11c4e44f44939cc289bf7bf20c8f4255a297a689b87112965a704c8fb83","signature":"4c50608a2c8ff396d3530ed9152f19eb3dfb817a934fec4b55f1b25064a67c26"},{"version":"ea02b1ce01b06c09ea091975e5b97d325871c5897cc21c7c0fe45654aad9f82d","signature":"c342ec8a341c8ffd6d38fadb40b1633a034c22f140855c97e0601a6b73a2d2a8"},{"version":"ff7ca060d50f4469bd3e999d16f2a4e92c4aba6fb29ae35e3d0d06b7efd5d2a6","signature":"eb1c88c9e3f826a4c80fcc2f900db2ad4b89986fc344e3b51f7e371779bcc5e4"},{"version":"1a5a9ed5b75f3dbc0aac04e146f10b51dea3e596b6790df1188986c4cddb0a73","signature":"e33eceaae91387c62fd80bdf0b2f0c3a8d1e942d2a943829691ed875c6223e7e"},{"version":"30284ebd3c639db2a99b8cd819059e88aac73faf97065c2848272720e6db047b","signature":"3e7235f5125776bb36c3e63f6d2a76d1cb1081545ad37f7c41e40b4c82ce7cc0"}],"options":{"declaration":true,"emitDeclarationOnly":true,"esModuleInterop":true,"noImplicitAny":true,"outDir":"./","skipLibCheck":true,"sourceMap":true,"strict":true,"target":2},"fileIdsList":[[59,89,96],[62,89,96],[89],[62,89,96,206],[62,89,96,199,206,208],[89,228],[59,62,89,96,200,201],[89,201,202,205,207],[62,89,221],[59,89,221],[89,218],[77,89,96,216,217,218,219,220],[77,89,221],[89,213],[59,62,63,67,73,88,89,96,198,199,209,210,211,212,214],[89,204],[89,203],[43,89],[46,89],[47,52,80,89],[48,59,60,67,77,88,89],[48,49,59,67,89],[50,89],[51,52,60,68,89],[52,77,85,89],[53,55,59,67,89],[54,89],[55,56,89],[59,89],[57,59,89],[59,60,61,77,88,89],[59,60,61,74,77,80,89],[89,93],[55,62,67,77,88,89],[59,60,62,63,67,77,85,88,89],[62,64,77,85,88,89],[43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95],[59,65,89],[66,88,89],[55,59,67,77,89],[68,89],[69,89],[46,70,89],[71,87,89,93],[72,89],[73,89],[59,74,75,89],[74,76,89,91],[47,59,77,78,79,80,89],[47,77,79,89],[77,78,89],[80,89],[81,89],[59,83,84,89],[83,84,89],[52,67,77,85,89],[86,89],[67,87,89],[47,62,73,88,89],[52,89],[77,89,90],[89,91],[89,92],[47,52,59,61,70,77,88,89,91,93],[77,89,94],[89,231],[89,231,239],[89,231,234,235,239,241,242],[89,229,230],[89,231,234],[89,231,234,236,241,242],[89,230,231],[89,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245],[59,89,224],[62,89,96,204],[59,89,118],[89,96,97],[59,89,96,97,113,114],[89,98,102,112,116],[59,89,96,97,98,99,101,102,109,112,113,115],[77,89,96],[89,98],[55,89,96,102,109,110],[59,89,96,97,98,99,101,102,110,111,116],[55,89,96],[89,97],[89,103],[89,105],[59,85,89,96,97,103,105,106,111],[89,109],[67,85,89,96,97,103],[89,97,98,99,100,103,107,108,109,110,111,112,116,117],[89,102,104,107,108],[89,100],[67,85,89,96],[89,97,98,100],[89,180,181],[42,89,301,304],[89,301],[89,302,303],[42,89,304,305,306,310],[89,307,308],[89,301,307],[89,309],[89,260,298],[89,154,155,156,157],[89,131,260,298],[89,158,190],[89,298],[89,167,168,171,172,173,174],[89,170],[89,190,260,301],[89,176,177,178,179,186,187],[89,182,183],[89,183,184,185],[89,182],[89,159,160,161,162,163,164,166,175,188,189],[89,165],[89,299],[89,131,260,270],[89,271,272],[59,89,169,270],[89,169,301],[89,169],[89,169,260,280],[89,169,170,274,275,276,280,281,282,283,284,285,286,287,288,289,290],[89,169,285],[89,277,278,279],[89,170,277],[89,169,260,276,278],[89,191,260,280],[89,169,260],[89,261,262,263,264,265,266,267,268,269],[89,260],[89,169,191],[89,169,270,273,291,296,297],[89,292,293,294,295],[89,131,191,260,298,300],[89,193,298],[89,121,222],[89,119,298],[89,193],[89,256],[77,89,227,246,301],[89,123],[89,123,191],[89,123,298],[89,121,122],[89,122,123,124,125,126,127,128,129,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,192],[89,137],[89,123,301],[89,120,121,137,193,194,195,196,197,222,223,226,247,250,251,252,253,254,255,257,258,259],[89,215,221,260,298],[89,133],[89,132,133,134,135,136],[89,131,137],[89,225],[89,248,249],[89,191,196,298],[89,254,298],[89,130],[42,301],[301],[302,303],[42,304,305,306,310],[307,308],[309]],"referencedMap":[[227,1],[198,2],[224,3],[207,4],[206,2],[212,3],[209,5],[229,6],[202,7],[208,8],[216,9],[220,3],[218,10],[219,11],[221,12],[217,13],[210,3],[211,3],[199,3],[214,14],[213,15],[215,15],[203,16],[204,17],[228,3],[43,18],[44,18],[46,19],[47,20],[48,21],[49,22],[50,23],[51,24],[52,25],[53,26],[54,27],[55,28],[56,28],[58,29],[57,30],[59,29],[60,31],[61,32],[45,33],[95,3],[62,34],[63,35],[64,36],[96,37],[65,38],[66,39],[67,40],[68,41],[69,42],[70,43],[71,44],[72,45],[73,46],[74,47],[75,47],[76,48],[77,49],[79,50],[78,51],[80,52],[81,53],[82,3],[83,54],[84,55],[85,56],[86,57],[87,58],[88,59],[89,60],[90,61],[91,62],[92,63],[93,64],[94,65],[232,66],[233,66],[234,66],[235,66],[236,66],[237,66],[238,66],[240,67],[239,66],[243,68],[231,69],[230,66],[244,70],[241,66],[245,71],[242,72],[246,73],[201,3],[200,3],[225,74],[205,75],[119,76],[113,3],[98,77],[115,78],[117,79],[116,80],[99,81],[114,82],[111,83],[112,84],[110,85],[103,86],[104,87],[106,88],[107,89],[105,90],[108,91],[118,92],[109,93],[101,94],[97,95],[102,96],[100,77],[180,3],[182,97],[181,3],[8,3],[10,3],[9,3],[2,3],[11,3],[12,3],[13,3],[14,3],[15,3],[16,3],[17,3],[18,3],[3,3],[4,3],[22,3],[19,3],[20,3],[21,3],[23,3],[24,3],[25,3],[5,3],[26,3],[27,3],[28,3],[29,3],[6,3],[30,3],[31,3],[32,3],[33,3],[7,3],[34,3],[39,3],[40,3],[35,3],[36,3],[37,3],[38,3],[1,3],[41,3],[42,3],[305,98],[302,99],[304,100],[303,99],[311,101],[307,99],[309,102],[308,103],[310,104],[306,3],[154,105],[158,106],[156,107],[157,3],[155,3],[191,108],[159,3],[167,109],[168,109],[175,110],[171,111],[173,109],[174,109],[172,109],[160,3],[163,3],[162,3],[177,112],[179,109],[176,3],[178,3],[188,113],[187,3],[185,114],[186,115],[183,116],[184,114],[190,117],[189,3],[164,109],[165,3],[166,118],[161,109],[300,119],[299,3],[271,120],[273,121],[272,3],[274,105],[275,122],[288,123],[285,124],[281,125],[291,126],[282,124],[290,124],[283,124],[284,124],[170,124],[286,127],[277,3],[280,128],[278,129],[279,130],[287,124],[276,131],[289,124],[169,3],[269,132],[261,124],[268,124],[270,133],[264,124],[265,134],[266,124],[267,124],[262,124],[263,135],[298,136],[294,124],[296,137],[292,124],[295,124],[293,124],[297,3],[301,138],[253,139],[223,140],[120,141],[256,142],[257,143],[194,139],[196,109],[247,144],[252,3],[148,145],[124,145],[192,146],[125,147],[126,145],[149,145],[152,147],[128,145],[127,145],[153,145],[123,148],[122,134],[193,149],[129,145],[138,150],[151,151],[140,145],[141,145],[142,145],[143,145],[144,145],[145,145],[146,145],[150,145],[139,145],[147,147],[251,3],[121,3],[260,152],[222,153],[136,154],[135,154],[137,155],[132,156],[133,3],[134,150],[226,157],[250,158],[248,3],[249,3],[195,3],[259,3],[197,159],[255,160],[254,3],[258,3],[131,161],[130,3]],"exportedModulesMap":[[227,1],[198,2],[224,3],[207,4],[206,2],[212,3],[209,5],[229,6],[202,7],[208,8],[216,9],[220,3],[218,10],[219,11],[221,12],[217,13],[210,3],[211,3],[199,3],[214,14],[213,15],[215,15],[203,16],[204,17],[228,3],[43,18],[44,18],[46,19],[47,20],[48,21],[49,22],[50,23],[51,24],[52,25],[53,26],[54,27],[55,28],[56,28],[58,29],[57,30],[59,29],[60,31],[61,32],[45,33],[95,3],[62,34],[63,35],[64,36],[96,37],[65,38],[66,39],[67,40],[68,41],[69,42],[70,43],[71,44],[72,45],[73,46],[74,47],[75,47],[76,48],[77,49],[79,50],[78,51],[80,52],[81,53],[82,3],[83,54],[84,55],[85,56],[86,57],[87,58],[88,59],[89,60],[90,61],[91,62],[92,63],[93,64],[94,65],[232,66],[233,66],[234,66],[235,66],[236,66],[237,66],[238,66],[240,67],[239,66],[243,68],[231,69],[230,66],[244,70],[241,66],[245,71],[242,72],[246,73],[201,3],[200,3],[225,74],[205,75],[119,76],[113,3],[98,77],[115,78],[117,79],[116,80],[99,81],[114,82],[111,83],[112,84],[110,85],[103,86],[104,87],[106,88],[107,89],[105,90],[108,91],[118,92],[109,93],[101,94],[97,95],[102,96],[100,77],[180,3],[182,97],[181,3],[8,3],[10,3],[9,3],[2,3],[11,3],[12,3],[13,3],[14,3],[15,3],[16,3],[17,3],[18,3],[3,3],[4,3],[22,3],[19,3],[20,3],[21,3],[23,3],[24,3],[25,3],[5,3],[26,3],[27,3],[28,3],[29,3],[6,3],[30,3],[31,3],[32,3],[33,3],[7,3],[34,3],[39,3],[40,3],[35,3],[36,3],[37,3],[38,3],[1,3],[41,3],[305,162],[302,163],[304,164],[303,163],[311,165],[309,166],[308,163],[310,167],[154,105],[158,106],[156,107],[157,3],[155,3],[191,108],[159,3],[167,109],[168,109],[175,110],[171,111],[173,109],[174,109],[172,109],[160,3],[163,3],[162,3],[177,112],[179,109],[176,3],[178,3],[188,113],[187,3],[185,114],[186,115],[183,116],[184,114],[190,117],[189,3],[164,109],[165,3],[166,118],[161,109],[300,119],[299,3],[271,120],[273,121],[272,3],[274,105],[275,122],[288,123],[285,124],[281,125],[291,126],[282,124],[290,124],[283,124],[284,124],[170,124],[286,127],[277,3],[280,128],[278,129],[279,130],[287,124],[276,131],[289,124],[169,3],[269,132],[261,124],[268,124],[270,133],[264,124],[265,134],[266,124],[267,124],[262,124],[263,135],[298,136],[294,124],[296,137],[292,124],[295,124],[293,124],[297,3],[301,138],[253,139],[223,140],[120,141],[256,142],[257,143],[194,139],[196,109],[247,144],[252,3],[148,145],[124,145],[192,146],[125,147],[126,145],[149,145],[152,147],[128,145],[127,145],[153,145],[123,148],[122,134],[193,149],[129,145],[138,150],[151,151],[140,145],[141,145],[142,145],[143,145],[144,145],[145,145],[146,145],[150,145],[139,145],[147,147],[251,3],[121,3],[260,152],[222,153],[136,154],[135,154],[137,155],[132,156],[133,3],[134,150],[226,157],[250,158],[248,3],[249,3],[195,3],[259,3],[197,159],[255,160],[254,3],[258,3],[131,161],[130,3]],"semanticDiagnosticsPerFile":[227,198,224,207,206,212,209,229,202,208,216,220,218,219,221,217,210,211,199,214,213,215,203,204,228,43,44,46,47,48,49,50,51,52,53,54,55,56,58,57,59,60,61,45,95,62,63,64,96,65,66,67,68,69,70,71,72,73,74,75,76,77,79,78,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,232,233,234,235,236,237,238,240,239,243,231,230,244,241,245,242,246,201,200,225,205,119,113,98,115,117,116,99,114,111,112,110,103,104,106,107,105,108,118,109,101,97,102,100,180,182,181,8,10,9,2,11,12,13,14,15,16,17,18,3,4,22,19,20,21,23,24,25,5,26,27,28,29,6,30,31,32,33,7,34,39,40,35,36,37,38,1,41,42,305,302,304,303,311,307,309,308,310,306,154,158,156,157,155,191,159,167,168,175,171,173,174,172,160,163,162,177,179,176,178,188,187,185,186,183,184,190,189,164,165,166,161,300,299,271,273,272,274,275,288,285,281,291,282,290,283,284,170,286,277,280,278,279,287,276,289,169,269,261,268,270,264,265,266,267,262,263,298,294,296,292,295,293,297,301,253,223,120,256,257,194,196,247,252,148,124,192,125,126,149,152,128,127,153,123,122,193,129,138,151,140,141,142,143,144,145,146,150,139,147,251,121,260,222,136,135,137,132,133,134,226,250,248,249,195,259,197,255,254,258,131,130]},"version":"4.7.3"}
|
package/src/constants.ts
DELETED
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
export const OperatorOptions = {
|
|
2
|
-
Equals: {
|
|
3
|
-
value: "equal",
|
|
4
|
-
label: "Equals",
|
|
5
|
-
},
|
|
6
|
-
NotEquals: {
|
|
7
|
-
value: "notEqual",
|
|
8
|
-
label: "Not equals",
|
|
9
|
-
},
|
|
10
|
-
Empty: {
|
|
11
|
-
value: "empty",
|
|
12
|
-
label: "Is empty",
|
|
13
|
-
},
|
|
14
|
-
NotEmpty: {
|
|
15
|
-
value: "notEmpty",
|
|
16
|
-
label: "Is not empty",
|
|
17
|
-
},
|
|
18
|
-
StartsWith: {
|
|
19
|
-
value: "string",
|
|
20
|
-
label: "Starts with",
|
|
21
|
-
},
|
|
22
|
-
Like: {
|
|
23
|
-
value: "fuzzy",
|
|
24
|
-
label: "Like",
|
|
25
|
-
},
|
|
26
|
-
MoreThan: {
|
|
27
|
-
value: "rangeLow",
|
|
28
|
-
label: "More than or equal to",
|
|
29
|
-
},
|
|
30
|
-
LessThan: {
|
|
31
|
-
value: "rangeHigh",
|
|
32
|
-
label: "Less than or equal to",
|
|
33
|
-
},
|
|
34
|
-
Contains: {
|
|
35
|
-
value: "contains",
|
|
36
|
-
label: "Contains",
|
|
37
|
-
},
|
|
38
|
-
NotContains: {
|
|
39
|
-
value: "notContains",
|
|
40
|
-
label: "Does not contain",
|
|
41
|
-
},
|
|
42
|
-
In: {
|
|
43
|
-
value: "oneOf",
|
|
44
|
-
label: "Is in",
|
|
45
|
-
},
|
|
46
|
-
ContainsAny: {
|
|
47
|
-
value: "containsAny",
|
|
48
|
-
label: "Has any",
|
|
49
|
-
},
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
export const SqlNumberTypeRangeMap = {
|
|
53
|
-
integer: {
|
|
54
|
-
max: 2147483647,
|
|
55
|
-
min: -2147483648,
|
|
56
|
-
},
|
|
57
|
-
int: {
|
|
58
|
-
max: 2147483647,
|
|
59
|
-
min: -2147483648,
|
|
60
|
-
},
|
|
61
|
-
smallint: {
|
|
62
|
-
max: 32767,
|
|
63
|
-
min: -32768,
|
|
64
|
-
},
|
|
65
|
-
mediumint: {
|
|
66
|
-
max: 8388607,
|
|
67
|
-
min: -8388608,
|
|
68
|
-
},
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
export enum SocketEvent {
|
|
72
|
-
UserUpdate = "UserUpdate",
|
|
73
|
-
UserDisconnect = "UserDisconnect",
|
|
74
|
-
Heartbeat = "Heartbeat",
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
export enum GridSocketEvent {
|
|
78
|
-
RowChange = "RowChange",
|
|
79
|
-
TableChange = "TableChange",
|
|
80
|
-
SelectTable = "SelectTable",
|
|
81
|
-
SelectCell = "SelectCell",
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
export enum BuilderSocketEvent {
|
|
85
|
-
SelectApp = "SelectApp",
|
|
86
|
-
TableChange = "TableChange",
|
|
87
|
-
DatasourceChange = "DatasourceChange",
|
|
88
|
-
LockTransfer = "LockTransfer",
|
|
89
|
-
ScreenChange = "ScreenChange",
|
|
90
|
-
AppMetadataChange = "AppMetadataChange",
|
|
91
|
-
SelectResource = "SelectResource",
|
|
92
|
-
AppPublishChange = "AppPublishChange",
|
|
93
|
-
AutomationChange = "AutomationChange",
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
export const SocketSessionTTL = 60
|
|
97
|
-
export const ValidQueryNameRegex = /^[^()]*$/
|
|
98
|
-
export const ValidColumnNameRegex = /^[_a-zA-Z0-9\s]*$/g
|
package/src/filters.ts
DELETED
|
@@ -1,473 +0,0 @@
|
|
|
1
|
-
import { Datasource, FieldType, SortDirection, SortType } from "@budibase/types"
|
|
2
|
-
import { OperatorOptions, SqlNumberTypeRangeMap } from "./constants"
|
|
3
|
-
import { deepGet } from "./helpers"
|
|
4
|
-
|
|
5
|
-
const HBS_REGEX = /{{([^{].*?)}}/g
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* Returns the valid operator options for a certain data type
|
|
9
|
-
* @param type the data type
|
|
10
|
-
*/
|
|
11
|
-
export const getValidOperatorsForType = (
|
|
12
|
-
type: FieldType,
|
|
13
|
-
field: string,
|
|
14
|
-
datasource: Datasource & { tableId: any } // TODO: is this table id ever populated?
|
|
15
|
-
) => {
|
|
16
|
-
const Op = OperatorOptions
|
|
17
|
-
const stringOps = [
|
|
18
|
-
Op.Equals,
|
|
19
|
-
Op.NotEquals,
|
|
20
|
-
Op.StartsWith,
|
|
21
|
-
Op.Like,
|
|
22
|
-
Op.Empty,
|
|
23
|
-
Op.NotEmpty,
|
|
24
|
-
Op.In,
|
|
25
|
-
]
|
|
26
|
-
const numOps = [
|
|
27
|
-
Op.Equals,
|
|
28
|
-
Op.NotEquals,
|
|
29
|
-
Op.MoreThan,
|
|
30
|
-
Op.LessThan,
|
|
31
|
-
Op.Empty,
|
|
32
|
-
Op.NotEmpty,
|
|
33
|
-
Op.In,
|
|
34
|
-
]
|
|
35
|
-
let ops: {
|
|
36
|
-
value: string
|
|
37
|
-
label: string
|
|
38
|
-
}[] = []
|
|
39
|
-
if (type === "string") {
|
|
40
|
-
ops = stringOps
|
|
41
|
-
} else if (type === "number" || type === "bigint") {
|
|
42
|
-
ops = numOps
|
|
43
|
-
} else if (type === "options") {
|
|
44
|
-
ops = [Op.Equals, Op.NotEquals, Op.Empty, Op.NotEmpty, Op.In]
|
|
45
|
-
} else if (type === "array") {
|
|
46
|
-
ops = [Op.Contains, Op.NotContains, Op.Empty, Op.NotEmpty, Op.ContainsAny]
|
|
47
|
-
} else if (type === "boolean") {
|
|
48
|
-
ops = [Op.Equals, Op.NotEquals, Op.Empty, Op.NotEmpty]
|
|
49
|
-
} else if (type === "longform") {
|
|
50
|
-
ops = stringOps
|
|
51
|
-
} else if (type === "datetime") {
|
|
52
|
-
ops = numOps
|
|
53
|
-
} else if (type === "formula") {
|
|
54
|
-
ops = stringOps.concat([Op.MoreThan, Op.LessThan])
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
// Only allow equal/not equal for _id in SQL tables
|
|
58
|
-
const externalTable = datasource?.tableId?.includes("datasource_plus")
|
|
59
|
-
if (field === "_id" && externalTable) {
|
|
60
|
-
ops = [Op.Equals, Op.NotEquals, Op.In]
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
return ops
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
/**
|
|
67
|
-
* Operators which do not support empty strings as values
|
|
68
|
-
*/
|
|
69
|
-
export const NoEmptyFilterStrings = [
|
|
70
|
-
OperatorOptions.StartsWith.value,
|
|
71
|
-
OperatorOptions.Like.value,
|
|
72
|
-
OperatorOptions.Equals.value,
|
|
73
|
-
OperatorOptions.NotEquals.value,
|
|
74
|
-
OperatorOptions.Contains.value,
|
|
75
|
-
OperatorOptions.NotContains.value,
|
|
76
|
-
] as (keyof QueryFields)[]
|
|
77
|
-
|
|
78
|
-
/**
|
|
79
|
-
* Removes any fields that contain empty strings that would cause inconsistent
|
|
80
|
-
* behaviour with how backend tables are filtered (no value means no filter).
|
|
81
|
-
*/
|
|
82
|
-
const cleanupQuery = (query: Query) => {
|
|
83
|
-
if (!query) {
|
|
84
|
-
return query
|
|
85
|
-
}
|
|
86
|
-
for (let filterField of NoEmptyFilterStrings) {
|
|
87
|
-
if (!query[filterField]) {
|
|
88
|
-
continue
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
for (let [key, value] of Object.entries(query[filterField]!)) {
|
|
92
|
-
if (value == null || value === "") {
|
|
93
|
-
delete query[filterField]![key]
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
return query
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
/**
|
|
101
|
-
* Removes a numeric prefix on field names designed to give fields uniqueness
|
|
102
|
-
*/
|
|
103
|
-
const removeKeyNumbering = (key: string) => {
|
|
104
|
-
if (typeof key === "string" && key.match(/\d[0-9]*:/g) != null) {
|
|
105
|
-
const parts = key.split(":")
|
|
106
|
-
parts.shift()
|
|
107
|
-
return parts.join(":")
|
|
108
|
-
} else {
|
|
109
|
-
return key
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
type Filter = {
|
|
114
|
-
operator: keyof Query
|
|
115
|
-
field: string
|
|
116
|
-
type: any
|
|
117
|
-
value: any
|
|
118
|
-
externalType: keyof typeof SqlNumberTypeRangeMap
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
type Query = QueryFields & QueryConfig
|
|
122
|
-
type QueryFields = {
|
|
123
|
-
string?: {
|
|
124
|
-
[key: string]: string
|
|
125
|
-
}
|
|
126
|
-
fuzzy?: {
|
|
127
|
-
[key: string]: string
|
|
128
|
-
}
|
|
129
|
-
range?: {
|
|
130
|
-
[key: string]: {
|
|
131
|
-
high: number | string
|
|
132
|
-
low: number | string
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
equal?: {
|
|
136
|
-
[key: string]: any
|
|
137
|
-
}
|
|
138
|
-
notEqual?: {
|
|
139
|
-
[key: string]: any
|
|
140
|
-
}
|
|
141
|
-
empty?: {
|
|
142
|
-
[key: string]: any
|
|
143
|
-
}
|
|
144
|
-
notEmpty?: {
|
|
145
|
-
[key: string]: any
|
|
146
|
-
}
|
|
147
|
-
oneOf?: {
|
|
148
|
-
[key: string]: any[]
|
|
149
|
-
}
|
|
150
|
-
contains?: {
|
|
151
|
-
[key: string]: any[]
|
|
152
|
-
}
|
|
153
|
-
notContains?: {
|
|
154
|
-
[key: string]: any[]
|
|
155
|
-
}
|
|
156
|
-
containsAny?: {
|
|
157
|
-
[key: string]: any[]
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
type QueryConfig = {
|
|
162
|
-
allOr?: boolean
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
type QueryFieldsType = keyof QueryFields
|
|
166
|
-
|
|
167
|
-
/**
|
|
168
|
-
* Builds a lucene JSON query from the filter structure generated in the builder
|
|
169
|
-
* @param filter the builder filter structure
|
|
170
|
-
*/
|
|
171
|
-
export const buildLuceneQuery = (filter: Filter[]) => {
|
|
172
|
-
let query: Query = {
|
|
173
|
-
string: {},
|
|
174
|
-
fuzzy: {},
|
|
175
|
-
range: {},
|
|
176
|
-
equal: {},
|
|
177
|
-
notEqual: {},
|
|
178
|
-
empty: {},
|
|
179
|
-
notEmpty: {},
|
|
180
|
-
contains: {},
|
|
181
|
-
notContains: {},
|
|
182
|
-
oneOf: {},
|
|
183
|
-
containsAny: {},
|
|
184
|
-
}
|
|
185
|
-
if (Array.isArray(filter)) {
|
|
186
|
-
filter.forEach(expression => {
|
|
187
|
-
let { operator, field, type, value, externalType } = expression
|
|
188
|
-
const isHbs =
|
|
189
|
-
typeof value === "string" && (value.match(HBS_REGEX) || []).length > 0
|
|
190
|
-
// Parse all values into correct types
|
|
191
|
-
if (operator === "allOr") {
|
|
192
|
-
query.allOr = true
|
|
193
|
-
return
|
|
194
|
-
}
|
|
195
|
-
if (
|
|
196
|
-
type === "datetime" &&
|
|
197
|
-
!isHbs &&
|
|
198
|
-
operator !== "empty" &&
|
|
199
|
-
operator !== "notEmpty"
|
|
200
|
-
) {
|
|
201
|
-
// Ensure date value is a valid date and parse into correct format
|
|
202
|
-
if (!value) {
|
|
203
|
-
return
|
|
204
|
-
}
|
|
205
|
-
try {
|
|
206
|
-
value = new Date(value).toISOString()
|
|
207
|
-
} catch (error) {
|
|
208
|
-
return
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
if (type === "number" && typeof value === "string") {
|
|
212
|
-
if (operator === "oneOf") {
|
|
213
|
-
value = value.split(",").map(item => parseFloat(item))
|
|
214
|
-
} else if (!isHbs) {
|
|
215
|
-
value = parseFloat(value)
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
if (type === "boolean") {
|
|
219
|
-
value = `${value}`?.toLowerCase() === "true"
|
|
220
|
-
}
|
|
221
|
-
if (
|
|
222
|
-
["contains", "notContains", "containsAny"].includes(operator) &&
|
|
223
|
-
type === "array" &&
|
|
224
|
-
typeof value === "string"
|
|
225
|
-
) {
|
|
226
|
-
value = value.split(",")
|
|
227
|
-
}
|
|
228
|
-
if (operator.startsWith("range") && query.range) {
|
|
229
|
-
const minint =
|
|
230
|
-
SqlNumberTypeRangeMap[externalType]?.min || Number.MIN_SAFE_INTEGER
|
|
231
|
-
const maxint =
|
|
232
|
-
SqlNumberTypeRangeMap[externalType]?.max || Number.MAX_SAFE_INTEGER
|
|
233
|
-
if (!query.range[field]) {
|
|
234
|
-
query.range[field] = {
|
|
235
|
-
low: type === "number" ? minint : "0000-00-00T00:00:00.000Z",
|
|
236
|
-
high: type === "number" ? maxint : "9999-00-00T00:00:00.000Z",
|
|
237
|
-
}
|
|
238
|
-
}
|
|
239
|
-
if ((operator as any) === "rangeLow" && value != null && value !== "") {
|
|
240
|
-
query.range[field].low = value
|
|
241
|
-
} else if (
|
|
242
|
-
(operator as any) === "rangeHigh" &&
|
|
243
|
-
value != null &&
|
|
244
|
-
value !== ""
|
|
245
|
-
) {
|
|
246
|
-
query.range[field].high = value
|
|
247
|
-
}
|
|
248
|
-
} else if (query[operator]) {
|
|
249
|
-
if (type === "boolean") {
|
|
250
|
-
// Transform boolean filters to cope with null.
|
|
251
|
-
// "equals false" needs to be "not equals true"
|
|
252
|
-
// "not equals false" needs to be "equals true"
|
|
253
|
-
if (operator === "equal" && value === false) {
|
|
254
|
-
query.notEqual = query.notEqual || {}
|
|
255
|
-
query.notEqual[field] = true
|
|
256
|
-
} else if (operator === "notEqual" && value === false) {
|
|
257
|
-
query.equal = query.equal || {}
|
|
258
|
-
query.equal[field] = true
|
|
259
|
-
} else {
|
|
260
|
-
query[operator] = query[operator] || {}
|
|
261
|
-
query[operator]![field] = value
|
|
262
|
-
}
|
|
263
|
-
} else {
|
|
264
|
-
query[operator] = query[operator] || {}
|
|
265
|
-
query[operator]![field] = value
|
|
266
|
-
}
|
|
267
|
-
}
|
|
268
|
-
})
|
|
269
|
-
}
|
|
270
|
-
return query
|
|
271
|
-
}
|
|
272
|
-
|
|
273
|
-
/**
|
|
274
|
-
* Performs a client-side lucene search on an array of data
|
|
275
|
-
* @param docs the data
|
|
276
|
-
* @param query the JSON lucene query
|
|
277
|
-
*/
|
|
278
|
-
export const runLuceneQuery = (docs: any[], query?: Query) => {
|
|
279
|
-
if (!docs || !Array.isArray(docs)) {
|
|
280
|
-
return []
|
|
281
|
-
}
|
|
282
|
-
if (!query) {
|
|
283
|
-
return docs
|
|
284
|
-
}
|
|
285
|
-
|
|
286
|
-
// Make query consistent first
|
|
287
|
-
query = cleanupQuery(query)
|
|
288
|
-
|
|
289
|
-
// Iterates over a set of filters and evaluates a fail function against a doc
|
|
290
|
-
const match =
|
|
291
|
-
(
|
|
292
|
-
type: QueryFieldsType,
|
|
293
|
-
failFn: (docValue: any, testValue: any) => boolean
|
|
294
|
-
) =>
|
|
295
|
-
(doc: any) => {
|
|
296
|
-
const filters = Object.entries(query![type] || {})
|
|
297
|
-
for (let i = 0; i < filters.length; i++) {
|
|
298
|
-
const [key, testValue] = filters[i]
|
|
299
|
-
const docValue = deepGet(doc, removeKeyNumbering(key))
|
|
300
|
-
if (failFn(docValue, testValue)) {
|
|
301
|
-
return false
|
|
302
|
-
}
|
|
303
|
-
}
|
|
304
|
-
return true
|
|
305
|
-
}
|
|
306
|
-
|
|
307
|
-
// Process a string match (fails if the value does not start with the string)
|
|
308
|
-
const stringMatch = match("string", (docValue: string, testValue: string) => {
|
|
309
|
-
return (
|
|
310
|
-
!docValue || !docValue?.toLowerCase().startsWith(testValue?.toLowerCase())
|
|
311
|
-
)
|
|
312
|
-
})
|
|
313
|
-
|
|
314
|
-
// Process a fuzzy match (treat the same as starts with when running locally)
|
|
315
|
-
const fuzzyMatch = match("fuzzy", (docValue: string, testValue: string) => {
|
|
316
|
-
return (
|
|
317
|
-
!docValue || !docValue?.toLowerCase().startsWith(testValue?.toLowerCase())
|
|
318
|
-
)
|
|
319
|
-
})
|
|
320
|
-
|
|
321
|
-
// Process a range match
|
|
322
|
-
const rangeMatch = match(
|
|
323
|
-
"range",
|
|
324
|
-
(
|
|
325
|
-
docValue: string | number | null,
|
|
326
|
-
testValue: { low: number; high: number }
|
|
327
|
-
) => {
|
|
328
|
-
return (
|
|
329
|
-
docValue == null ||
|
|
330
|
-
docValue === "" ||
|
|
331
|
-
+docValue < testValue.low ||
|
|
332
|
-
+docValue > testValue.high
|
|
333
|
-
)
|
|
334
|
-
}
|
|
335
|
-
)
|
|
336
|
-
|
|
337
|
-
// Process an equal match (fails if the value is different)
|
|
338
|
-
const equalMatch = match(
|
|
339
|
-
"equal",
|
|
340
|
-
(docValue: any, testValue: string | null) => {
|
|
341
|
-
return testValue != null && testValue !== "" && docValue !== testValue
|
|
342
|
-
}
|
|
343
|
-
)
|
|
344
|
-
|
|
345
|
-
// Process a not-equal match (fails if the value is the same)
|
|
346
|
-
const notEqualMatch = match(
|
|
347
|
-
"notEqual",
|
|
348
|
-
(docValue: any, testValue: string | null) => {
|
|
349
|
-
return testValue != null && testValue !== "" && docValue === testValue
|
|
350
|
-
}
|
|
351
|
-
)
|
|
352
|
-
|
|
353
|
-
// Process an empty match (fails if the value is not empty)
|
|
354
|
-
const emptyMatch = match("empty", (docValue: string | null) => {
|
|
355
|
-
return docValue != null && docValue !== ""
|
|
356
|
-
})
|
|
357
|
-
|
|
358
|
-
// Process a not-empty match (fails is the value is empty)
|
|
359
|
-
const notEmptyMatch = match("notEmpty", (docValue: string | null) => {
|
|
360
|
-
return docValue == null || docValue === ""
|
|
361
|
-
})
|
|
362
|
-
|
|
363
|
-
// Process an includes match (fails if the value is not included)
|
|
364
|
-
const oneOf = match("oneOf", (docValue: any, testValue: any) => {
|
|
365
|
-
if (typeof testValue === "string") {
|
|
366
|
-
testValue = testValue.split(",")
|
|
367
|
-
if (typeof docValue === "number") {
|
|
368
|
-
testValue = testValue.map((item: string) => parseFloat(item))
|
|
369
|
-
}
|
|
370
|
-
}
|
|
371
|
-
return !testValue?.includes(docValue)
|
|
372
|
-
})
|
|
373
|
-
|
|
374
|
-
const containsAny = match("containsAny", (docValue: any, testValue: any) => {
|
|
375
|
-
return !docValue?.includes(...testValue)
|
|
376
|
-
})
|
|
377
|
-
|
|
378
|
-
const contains = match(
|
|
379
|
-
"contains",
|
|
380
|
-
(docValue: string | any[], testValue: any[]) => {
|
|
381
|
-
return !testValue?.every((item: any) => docValue?.includes(item))
|
|
382
|
-
}
|
|
383
|
-
)
|
|
384
|
-
|
|
385
|
-
const notContains = match(
|
|
386
|
-
"notContains",
|
|
387
|
-
(docValue: string | any[], testValue: any[]) => {
|
|
388
|
-
return testValue?.every((item: any) => docValue?.includes(item))
|
|
389
|
-
}
|
|
390
|
-
)
|
|
391
|
-
|
|
392
|
-
// Match a document against all criteria
|
|
393
|
-
const docMatch = (doc: any) => {
|
|
394
|
-
return (
|
|
395
|
-
stringMatch(doc) &&
|
|
396
|
-
fuzzyMatch(doc) &&
|
|
397
|
-
rangeMatch(doc) &&
|
|
398
|
-
equalMatch(doc) &&
|
|
399
|
-
notEqualMatch(doc) &&
|
|
400
|
-
emptyMatch(doc) &&
|
|
401
|
-
notEmptyMatch(doc) &&
|
|
402
|
-
oneOf(doc) &&
|
|
403
|
-
contains(doc) &&
|
|
404
|
-
containsAny(doc) &&
|
|
405
|
-
notContains(doc)
|
|
406
|
-
)
|
|
407
|
-
}
|
|
408
|
-
|
|
409
|
-
// Process all docs
|
|
410
|
-
return docs.filter(docMatch)
|
|
411
|
-
}
|
|
412
|
-
|
|
413
|
-
/**
|
|
414
|
-
* Performs a client-side sort from the equivalent server-side lucene sort
|
|
415
|
-
* parameters.
|
|
416
|
-
* @param docs the data
|
|
417
|
-
* @param sort the sort column
|
|
418
|
-
* @param sortOrder the sort order ("ascending" or "descending")
|
|
419
|
-
* @param sortType the type of sort ("string" or "number")
|
|
420
|
-
*/
|
|
421
|
-
export const luceneSort = (
|
|
422
|
-
docs: any[],
|
|
423
|
-
sort: string,
|
|
424
|
-
sortOrder: SortDirection,
|
|
425
|
-
sortType = SortType.STRING
|
|
426
|
-
) => {
|
|
427
|
-
if (!sort || !sortOrder || !sortType) {
|
|
428
|
-
return docs
|
|
429
|
-
}
|
|
430
|
-
const parse =
|
|
431
|
-
sortType === "string" ? (x: any) => `${x}` : (x: string) => parseFloat(x)
|
|
432
|
-
return docs
|
|
433
|
-
.slice()
|
|
434
|
-
.sort((a: { [x: string]: any }, b: { [x: string]: any }) => {
|
|
435
|
-
const colA = parse(a[sort])
|
|
436
|
-
const colB = parse(b[sort])
|
|
437
|
-
if (sortOrder.toLowerCase() === "descending") {
|
|
438
|
-
return colA > colB ? -1 : 1
|
|
439
|
-
} else {
|
|
440
|
-
return colA > colB ? 1 : -1
|
|
441
|
-
}
|
|
442
|
-
})
|
|
443
|
-
}
|
|
444
|
-
|
|
445
|
-
/**
|
|
446
|
-
* Limits the specified docs to the specified number of rows from the equivalent
|
|
447
|
-
* server-side lucene limit parameters.
|
|
448
|
-
* @param docs the data
|
|
449
|
-
* @param limit the number of docs to limit to
|
|
450
|
-
*/
|
|
451
|
-
export const luceneLimit = (docs: any[], limit: string) => {
|
|
452
|
-
const numLimit = parseFloat(limit)
|
|
453
|
-
if (isNaN(numLimit)) {
|
|
454
|
-
return docs
|
|
455
|
-
}
|
|
456
|
-
return docs.slice(0, numLimit)
|
|
457
|
-
}
|
|
458
|
-
|
|
459
|
-
export const hasFilters = (query?: Query) => {
|
|
460
|
-
if (!query) {
|
|
461
|
-
return false
|
|
462
|
-
}
|
|
463
|
-
const skipped = ["allOr"]
|
|
464
|
-
for (let [key, value] of Object.entries(query)) {
|
|
465
|
-
if (skipped.includes(key) || typeof value !== "object") {
|
|
466
|
-
continue
|
|
467
|
-
}
|
|
468
|
-
if (Object.keys(value).length !== 0) {
|
|
469
|
-
return true
|
|
470
|
-
}
|
|
471
|
-
}
|
|
472
|
-
return false
|
|
473
|
-
}
|
package/src/helpers/helpers.ts
DELETED
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
import { User } from "@budibase/types"
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Gets a key within an object. The key supports dot syntax for retrieving deep
|
|
5
|
-
* fields - e.g. "a.b.c".
|
|
6
|
-
* Exact matches of keys with dots in them take precedence over nested keys of
|
|
7
|
-
* the same path - e.g. getting "a.b" from { "a.b": "foo", a: { b: "bar" } }
|
|
8
|
-
* will return "foo" over "bar".
|
|
9
|
-
* @param obj the object
|
|
10
|
-
* @param key the key
|
|
11
|
-
* @return {*|null} the value or null if a value was not found for this key
|
|
12
|
-
*/
|
|
13
|
-
export const deepGet = (obj: { [x: string]: any }, key: string) => {
|
|
14
|
-
if (!obj || !key) {
|
|
15
|
-
return null
|
|
16
|
-
}
|
|
17
|
-
if (Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
18
|
-
return obj[key]
|
|
19
|
-
}
|
|
20
|
-
const split = key.split(".")
|
|
21
|
-
for (let i = 0; i < split.length; i++) {
|
|
22
|
-
obj = obj?.[split[i]]
|
|
23
|
-
}
|
|
24
|
-
return obj
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
/**
|
|
28
|
-
* Gets the initials to show in a user avatar.
|
|
29
|
-
* @param user the user
|
|
30
|
-
*/
|
|
31
|
-
export const getUserInitials = (user: User) => {
|
|
32
|
-
if (!user) {
|
|
33
|
-
return "?"
|
|
34
|
-
}
|
|
35
|
-
let initials = ""
|
|
36
|
-
initials += user.firstName ? user.firstName[0] : ""
|
|
37
|
-
initials += user.lastName ? user.lastName[0] : ""
|
|
38
|
-
if (initials !== "") {
|
|
39
|
-
return initials
|
|
40
|
-
}
|
|
41
|
-
return user.email?.[0] || "U"
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
/**
|
|
45
|
-
* Gets a deterministic colour for a particular user
|
|
46
|
-
* @param user the user
|
|
47
|
-
*/
|
|
48
|
-
export const getUserColor = (user: User) => {
|
|
49
|
-
let id = user?._id
|
|
50
|
-
if (!id) {
|
|
51
|
-
return "var(--spectrum-global-color-blue-400)"
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
// In order to generate the same color for global users as app users, we need
|
|
55
|
-
// to remove the app-specific table prefix
|
|
56
|
-
id = id.replace("ro_ta_users_", "")
|
|
57
|
-
|
|
58
|
-
// Generate a hue based on the ID
|
|
59
|
-
let hue = 1
|
|
60
|
-
for (let i = 0; i < id.length; i++) {
|
|
61
|
-
hue += id.charCodeAt(i)
|
|
62
|
-
hue = hue % 36
|
|
63
|
-
}
|
|
64
|
-
return `hsl(${hue * 10}, 50%, 40%)`
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
/**
|
|
68
|
-
* Gets a friendly label to describe who a user is.
|
|
69
|
-
* @param user the user
|
|
70
|
-
*/
|
|
71
|
-
export const getUserLabel = (user: User) => {
|
|
72
|
-
if (!user) {
|
|
73
|
-
return ""
|
|
74
|
-
}
|
|
75
|
-
const { firstName, lastName, email } = user
|
|
76
|
-
if (firstName && lastName) {
|
|
77
|
-
return `${firstName} ${lastName}`
|
|
78
|
-
} else if (firstName) {
|
|
79
|
-
return firstName
|
|
80
|
-
} else if (lastName) {
|
|
81
|
-
return lastName
|
|
82
|
-
} else {
|
|
83
|
-
return email
|
|
84
|
-
}
|
|
85
|
-
}
|
package/src/helpers/index.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { Datasource, SourceName } from "@budibase/types"
|
|
2
|
-
|
|
3
|
-
export function isGoogleSheets(type: SourceName) {
|
|
4
|
-
return type === SourceName.GOOGLE_SHEETS
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
export function isSQL(datasource: Datasource): boolean {
|
|
8
|
-
if (!datasource || !datasource.source) {
|
|
9
|
-
return false
|
|
10
|
-
}
|
|
11
|
-
const SQL = [
|
|
12
|
-
SourceName.POSTGRES,
|
|
13
|
-
SourceName.SQL_SERVER,
|
|
14
|
-
SourceName.MYSQL,
|
|
15
|
-
SourceName.ORACLE,
|
|
16
|
-
]
|
|
17
|
-
return SQL.indexOf(datasource.source) !== -1
|
|
18
|
-
}
|
package/src/index.ts
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { DocumentType, prefixed } from "@budibase/types"
|
|
2
|
-
|
|
3
|
-
const APP_PREFIX = prefixed(DocumentType.APP)
|
|
4
|
-
const APP_DEV_PREFIX = prefixed(DocumentType.APP_DEV)
|
|
5
|
-
|
|
6
|
-
export function getDevAppID(appId: string) {
|
|
7
|
-
if (!appId) {
|
|
8
|
-
throw new Error("No app ID provided")
|
|
9
|
-
}
|
|
10
|
-
if (appId.startsWith(APP_DEV_PREFIX)) {
|
|
11
|
-
return appId
|
|
12
|
-
}
|
|
13
|
-
// split to take off the app_ element, then join it together incase any other app_ exist
|
|
14
|
-
const split = appId.split(APP_PREFIX)
|
|
15
|
-
split.shift()
|
|
16
|
-
const rest = split.join(APP_PREFIX)
|
|
17
|
-
return `${APP_DEV_PREFIX}${rest}`
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
/**
|
|
21
|
-
* Convert a development app ID to a deployed app ID.
|
|
22
|
-
*/
|
|
23
|
-
export function getProdAppID(appId: string) {
|
|
24
|
-
if (!appId) {
|
|
25
|
-
throw new Error("No app ID provided")
|
|
26
|
-
}
|
|
27
|
-
if (!appId.startsWith(APP_DEV_PREFIX)) {
|
|
28
|
-
return appId
|
|
29
|
-
}
|
|
30
|
-
// split to take off the app_dev element, then join it together incase any other app_ exist
|
|
31
|
-
const split = appId.split(APP_DEV_PREFIX)
|
|
32
|
-
split.shift()
|
|
33
|
-
const rest = split.join(APP_DEV_PREFIX)
|
|
34
|
-
return `${APP_PREFIX}${rest}`
|
|
35
|
-
}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
import { ContextUser, User } from "@budibase/types"
|
|
2
|
-
import { getProdAppID } from "./applications"
|
|
3
|
-
|
|
4
|
-
// checks if a user is specifically a builder, given an app ID
|
|
5
|
-
export function isBuilder(user: User | ContextUser, appId?: string): boolean {
|
|
6
|
-
if (!user) {
|
|
7
|
-
return false
|
|
8
|
-
}
|
|
9
|
-
if (user.builder?.global) {
|
|
10
|
-
return true
|
|
11
|
-
} else if (appId && user.builder?.apps?.includes(getProdAppID(appId))) {
|
|
12
|
-
return true
|
|
13
|
-
}
|
|
14
|
-
return false
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export function isGlobalBuilder(user: User | ContextUser): boolean {
|
|
18
|
-
return (isBuilder(user) && !hasAppBuilderPermissions(user)) || isAdmin(user)
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
// alias for hasAdminPermission, currently do the same thing
|
|
22
|
-
// in future whether someone has admin permissions and whether they are
|
|
23
|
-
// an admin for a specific resource could be separated
|
|
24
|
-
export function isAdmin(user: User | ContextUser): boolean {
|
|
25
|
-
if (!user) {
|
|
26
|
-
return false
|
|
27
|
-
}
|
|
28
|
-
return hasAdminPermissions(user)
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
export function isAdminOrBuilder(
|
|
32
|
-
user: User | ContextUser,
|
|
33
|
-
appId?: string
|
|
34
|
-
): boolean {
|
|
35
|
-
return isBuilder(user, appId) || isAdmin(user)
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
// check if they are a builder within an app (not necessarily a global builder)
|
|
39
|
-
export function hasAppBuilderPermissions(user?: User | ContextUser): boolean {
|
|
40
|
-
if (!user) {
|
|
41
|
-
return false
|
|
42
|
-
}
|
|
43
|
-
const appLength = user.builder?.apps?.length
|
|
44
|
-
const isGlobalBuilder = !!user.builder?.global
|
|
45
|
-
return !isGlobalBuilder && appLength != null && appLength > 0
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
// checks if a user is capable of building any app
|
|
49
|
-
export function hasBuilderPermissions(user?: User | ContextUser): boolean {
|
|
50
|
-
if (!user) {
|
|
51
|
-
return false
|
|
52
|
-
}
|
|
53
|
-
return user.builder?.global || hasAppBuilderPermissions(user)
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
// checks if a user is capable of being an admin
|
|
57
|
-
export function hasAdminPermissions(user?: User | ContextUser): boolean {
|
|
58
|
-
if (!user) {
|
|
59
|
-
return false
|
|
60
|
-
}
|
|
61
|
-
return !!user.admin?.global
|
|
62
|
-
}
|
package/src/sdk/index.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./documents"
|
package/src/utils.ts
DELETED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
export function unreachable(
|
|
2
|
-
value: never,
|
|
3
|
-
message = `No such case in exhaustive switch: ${value}`
|
|
4
|
-
) {
|
|
5
|
-
throw new Error(message)
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
export async function parallelForeach<T>(
|
|
9
|
-
items: T[],
|
|
10
|
-
task: (item: T) => Promise<void>,
|
|
11
|
-
maxConcurrency: number
|
|
12
|
-
): Promise<void> {
|
|
13
|
-
const promises: Promise<void>[] = []
|
|
14
|
-
let index = 0
|
|
15
|
-
|
|
16
|
-
const processItem = async (item: T) => {
|
|
17
|
-
try {
|
|
18
|
-
await task(item)
|
|
19
|
-
} finally {
|
|
20
|
-
processNext()
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
const processNext = () => {
|
|
25
|
-
if (index >= items.length) {
|
|
26
|
-
// No more items to process
|
|
27
|
-
return
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
const item = items[index]
|
|
31
|
-
index++
|
|
32
|
-
|
|
33
|
-
const promise = processItem(item)
|
|
34
|
-
promises.push(promise)
|
|
35
|
-
|
|
36
|
-
if (promises.length >= maxConcurrency) {
|
|
37
|
-
Promise.race(promises).then(processNext)
|
|
38
|
-
} else {
|
|
39
|
-
processNext()
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
processNext()
|
|
43
|
-
|
|
44
|
-
await Promise.all(promises)
|
|
45
|
-
}
|