@base44-preview/cli 0.0.32-pr.252.7bf9ea3 → 0.0.32-pr.253.ed8d752
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/cli/index.js +7 -15
- package/dist/cli/index.js.map +3 -3
- package/package.json +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -185349,7 +185349,7 @@ var FieldConditionSchema = exports_external.union([
|
|
|
185349
185349
|
exports_external.number(),
|
|
185350
185350
|
exports_external.boolean(),
|
|
185351
185351
|
exports_external.null(),
|
|
185352
|
-
exports_external.
|
|
185352
|
+
exports_external.looseObject({
|
|
185353
185353
|
$in: exports_external.unknown().optional(),
|
|
185354
185354
|
$nin: exports_external.unknown().optional(),
|
|
185355
185355
|
$ne: exports_external.unknown().optional(),
|
|
@@ -185403,24 +185403,16 @@ var isValidFieldCondition = (value) => {
|
|
|
185403
185403
|
}
|
|
185404
185404
|
return false;
|
|
185405
185405
|
};
|
|
185406
|
-
var RefineRLSConditionSchema = RLSConditionSchema.refine((val) => Object.entries(val).every(([key, value]) =>
|
|
185407
|
-
if (rlsConditionAllowedKeys.has(key)) {
|
|
185408
|
-
return true;
|
|
185409
|
-
}
|
|
185410
|
-
if (key.startsWith("data.")) {
|
|
185411
|
-
return isValidFieldCondition(value);
|
|
185412
|
-
}
|
|
185413
|
-
return isValidFieldCondition(value);
|
|
185414
|
-
}), "Keys must be known RLS keys or match data.* pattern with valid value");
|
|
185406
|
+
var RefineRLSConditionSchema = RLSConditionSchema.refine((val) => Object.entries(val).every(([key, value]) => rlsConditionAllowedKeys.has(key) || isValidFieldCondition(value)), "Field condition values must be a primitive or an operator object ($in, $nin, $ne, $all)");
|
|
185415
185407
|
var RLSRuleSchema = exports_external.union([exports_external.boolean(), RefineRLSConditionSchema]);
|
|
185416
|
-
var EntityRLSSchema = exports_external.
|
|
185408
|
+
var EntityRLSSchema = exports_external.looseObject({
|
|
185417
185409
|
create: RLSRuleSchema.optional(),
|
|
185418
185410
|
read: RLSRuleSchema.optional(),
|
|
185419
185411
|
update: RLSRuleSchema.optional(),
|
|
185420
185412
|
delete: RLSRuleSchema.optional(),
|
|
185421
185413
|
write: RLSRuleSchema.optional()
|
|
185422
185414
|
});
|
|
185423
|
-
var FieldRLSSchema = exports_external.
|
|
185415
|
+
var FieldRLSSchema = exports_external.looseObject({
|
|
185424
185416
|
read: RLSRuleSchema.optional(),
|
|
185425
185417
|
write: RLSRuleSchema.optional(),
|
|
185426
185418
|
create: RLSRuleSchema.optional(),
|
|
@@ -185428,7 +185420,7 @@ var FieldRLSSchema = exports_external.strictObject({
|
|
|
185428
185420
|
delete: RLSRuleSchema.optional()
|
|
185429
185421
|
});
|
|
185430
185422
|
var PropertyDefinitionSchema = exports_external.looseObject({
|
|
185431
|
-
type: exports_external.string(),
|
|
185423
|
+
type: exports_external.string().optional(),
|
|
185432
185424
|
title: exports_external.string().optional(),
|
|
185433
185425
|
description: exports_external.string().optional(),
|
|
185434
185426
|
minLength: exports_external.number().int().min(0).optional(),
|
|
@@ -185452,7 +185444,7 @@ var PropertyDefinitionSchema = exports_external.looseObject({
|
|
|
185452
185444
|
});
|
|
185453
185445
|
var EntitySchema = exports_external.looseObject({
|
|
185454
185446
|
type: exports_external.literal("object").default("object"),
|
|
185455
|
-
name: exports_external.string().min(1).regex(/^[a-zA-Z0-
|
|
185447
|
+
name: exports_external.string().min(1).regex(/^[a-zA-Z0-9]+$/, "Entity name must be alphanumeric only"),
|
|
185456
185448
|
title: exports_external.string().optional(),
|
|
185457
185449
|
description: exports_external.string().optional(),
|
|
185458
185450
|
properties: exports_external.record(exports_external.string(), PropertyDefinitionSchema).default({}),
|
|
@@ -199759,4 +199751,4 @@ export {
|
|
|
199759
199751
|
CLIExitError
|
|
199760
199752
|
};
|
|
199761
199753
|
|
|
199762
|
-
//# debugId=
|
|
199754
|
+
//# debugId=AF03C92ADCD7DDC664756E2164756E21
|