@ai-matrx/records 0.57.0 → 0.57.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -76,6 +76,7 @@ __export(src_exports, {
76
76
  VALUE_ALTERNATE_KEYS: () => VALUE_ALTERNATE_KEYS,
77
77
  VALUE_ENVELOPE_KEYS: () => VALUE_ENVELOPE_KEYS,
78
78
  actionRefusals: () => actionRefusals,
79
+ allowsOtherValues: () => allowsOtherValues,
79
80
  archivedByLine: () => archivedByLine,
80
81
  archivedWhen: () => archivedWhen,
81
82
  asPermissionLevel: () => asPermissionLevel,
@@ -249,6 +250,11 @@ function highestLevel(left, right) {
249
250
  return ORDINAL[left] >= ORDINAL[right] ? left : right;
250
251
  }
251
252
 
253
+ // src/field.ts
254
+ function allowsOtherValues(field) {
255
+ return field.type === "list" && field.config?.["allow_other"] === true;
256
+ }
257
+
252
258
  // src/choice.ts
253
259
  var UUID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
254
260
  function optionKey(option) {
@@ -1623,6 +1629,7 @@ var STORE_DOORS = [
1623
1629
  { name: "table_declare", args: "p_organization_id uuid, p_spec jsonb", returns: "uuid", security: "definer" },
1624
1630
  { name: "table_decorate", args: "p_organization_id uuid, p_table_id uuid, p_path text[], p_value jsonb DEFAULT NULL::jsonb", returns: "jsonb", security: "definer" },
1625
1631
  { name: "table_decorations", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
1632
+ { name: "table_facts", args: "p_organization_id uuid", returns: "TABLE(table_id uuid, visibility text, mine boolean)", security: "definer" },
1626
1633
  { name: "table_from_example", args: "p_organization_id uuid, p_home_id uuid, p_example jsonb", returns: "jsonb", security: "definer" },
1627
1634
  { name: "table_has_a_visible_record", args: "p_user uuid, p_organization_id uuid, p_table_id uuid", returns: "boolean", security: "definer" },
1628
1635
  { name: "table_is_live", args: "p_organization_id uuid, p_table_id uuid", returns: "boolean", security: "invoker" },