@ai-matrx/records 0.77.2 → 0.78.0
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/CHANGELOG.md +15 -0
- package/dist/app-table/index.cjs +94 -5
- package/dist/app-table/index.cjs.map +1 -1
- package/dist/app-table/index.d.cts +7 -7
- package/dist/app-table/index.d.ts +7 -7
- package/dist/app-table/index.js +94 -5
- package/dist/app-table/index.js.map +1 -1
- package/dist/{client-DZ3UcU4_.d.cts → client-BExNR0TK.d.cts} +5 -5
- package/dist/{client-ZIxyAOdh.d.ts → client-Byn_UthM.d.ts} +5 -5
- package/dist/core/index.cjs +98 -7
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.d.cts +11 -11
- package/dist/core/index.d.ts +11 -11
- package/dist/core/index.js +98 -7
- package/dist/core/index.js.map +1 -1
- package/dist/data/index.cjs +90 -1
- package/dist/data/index.cjs.map +1 -1
- package/dist/data/index.d.cts +6 -6
- package/dist/data/index.d.ts +6 -6
- package/dist/data/index.js +90 -1
- package/dist/data/index.js.map +1 -1
- package/dist/{declareTable-BYZdFrt5.d.cts → declareTable-CgrEusy8.d.cts} +4 -4
- package/dist/{declareTable-DGSJMqGx.d.ts → declareTable-DWOh53eK.d.ts} +4 -4
- package/dist/{field-D7I9yck6.d.ts → field-B2bvpqcE.d.ts} +1 -1
- package/dist/{field-BTW7h7Wh.d.cts → field-t9aefszx.d.cts} +1 -1
- package/dist/index.cjs +6 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +7 -7
- package/dist/index.d.ts +7 -7
- package/dist/index.js +6 -2
- package/dist/index.js.map +1 -1
- package/dist/memory/index.cjs +6 -1
- package/dist/memory/index.cjs.map +1 -1
- package/dist/memory/index.d.cts +6 -6
- package/dist/memory/index.d.ts +6 -6
- package/dist/memory/index.js +6 -1
- package/dist/memory/index.js.map +1 -1
- package/dist/{ports-CaYEF1dG.d.ts → ports-Ch4Ym0tj.d.ts} +7 -1
- package/dist/{ports-PpvsH1cQ.d.cts → ports-Cjl-IjFa.d.cts} +7 -1
- package/dist/react/index.cjs +98 -7
- package/dist/react/index.cjs.map +1 -1
- package/dist/react/index.d.cts +16 -0
- package/dist/react/index.d.ts +16 -0
- package/dist/react/index.js +98 -7
- package/dist/react/index.js.map +1 -1
- package/dist/realtime/index.d.cts +2 -2
- package/dist/realtime/index.d.ts +2 -2
- package/dist/{record-B7iwye2k.d.cts → record-Ba1F1CNS.d.cts} +10 -0
- package/dist/{record-B7iwye2k.d.ts → record-Ba1F1CNS.d.ts} +10 -0
- package/dist/{subscription-BWaRPLyo.d.ts → subscription-CccP6N93.d.ts} +1 -1
- package/dist/{subscription-Br30ZwIt.d.cts → subscription-DGCrwwSR.d.cts} +1 -1
- package/dist/{table-kind-Da21ZLdJ.d.ts → table-kind-BMWi8G37.d.ts} +3 -3
- package/dist/{table-kind-HAQ6WNxZ.d.cts → table-kind-BoelIMjr.d.cts} +3 -3
- package/dist/templates/index.cjs +6 -2
- package/dist/templates/index.cjs.map +1 -1
- package/dist/templates/index.d.cts +9 -9
- package/dist/templates/index.d.ts +9 -9
- package/dist/templates/index.js +6 -2
- package/dist/templates/index.js.map +1 -1
- package/dist/{types-DrJLOqVi.d.ts → types-CiHdoATO.d.ts} +2 -2
- package/dist/{types-DWZ5_3by.d.ts → types-CtyMwJvy.d.ts} +2 -2
- package/dist/{types-DYoWzHwJ.d.cts → types-D-Mhiodh.d.cts} +2 -2
- package/dist/{types-LvxsZ6Zv.d.cts → types-euaQwxnB.d.cts} +2 -2
- package/dist/use-cases/index.cjs.map +1 -1
- package/dist/use-cases/index.d.cts +5 -5
- package/dist/use-cases/index.d.ts +5 -5
- package/dist/use-cases/index.js.map +1 -1
- package/dist/{validate-j0WQoC3C.d.ts → validate-B-p3YPgA.d.ts} +1 -1
- package/dist/{validate-CRdXE73G.d.cts → validate-COvMcv8z.d.cts} +1 -1
- package/package.json +4 -4
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { A as AgentSnapshotRow, T as TemplateSpec, a as TemplateTable, S as SharedBlockId, C as CapabilityWord, b as TemplateField, c as TemplateAgent, d as TemplateAutomation, e as TemplateBooking, f as TemplateChecklist, g as TemplateDashboard, h as TemplateDigest, i as TemplateDocument, j as TemplateDrillDown, k as TemplateDimensions, l as TemplateForm, m as TemplateNotification, n as TemplatePortal, o as TemplateRowAction, p as TemplateStageRules, q as TemplateView, r as TemplateMergeBinding, s as TemplateTryIt, t as TemplateWorkflow, u as TemplateFootprint, I as IndustryGroup, v as TemplateJob, w as TeachesFeature, x as TemplateViewKind, y as TemplateBookingWindow } from '../types-
|
|
2
|
-
export { z as CAPABILITY_WORDS, B as CATALOGUE_QUOTAS, D as CATALOGUE_STATUSES, E as CHOICE_COLORS, F as CHOICE_COLORS_DISTINCT_UP_TO, G as CatalogueRow, H as CatalogueStatus, J as ChoiceColor, K as ConfidentialLevel, L as ConfidentialRequest, M as DEFAULT_TEMPLATE_AGENT, N as ENTITY_REFERENCE_KINDS, O as INDUSTRY_GROUPS, R as RELATIVE_DATE, P as RetiredId, Q as SHARED_BLOCKS, U as SHARED_BLOCK_IDS, V as STRENGTHS, W as SharedBlock, X as SharedBlockField, Y as SharedBlockUse, Z as Strength, _ as TABLE_KERNEL_ID, $ as TEACHES_FEATURES, a0 as TEMPLATE_AUDIENCES, a1 as TEMPLATE_EXTRA_KINDS, a2 as TEMPLATE_JOBS, a3 as TEMPLATE_REFERENCE_DATE, a4 as TEMPLATE_SPEC_VERSION, a5 as TEMPLATE_VIEW_KINDS, a6 as TemplateAgentQuestion, a7 as TemplateAgentVariable, a8 as TemplateAudience, a9 as TemplateCalendarView, aa as TemplateChecklistStep, ab as TemplateConfidential, ac as TemplateConfidentialReader, ad as TemplateDashboardBlock, ae as TemplateDimensionOverride, af as TemplateDrillPath, ag as TemplateExtra, ah as TemplateExtraAgent, ai as TemplateExtraAgentVariable, aj as TemplateExtraKind, ak as TemplateFormField, al as TemplateFoundation, am as TemplateGalleryView, an as TemplateGridView, ao as TemplateGuideStep, ap as TemplateKanbanView, aq as TemplateMeasureOverride, ar as TemplatePortalTable, as as TemplateProvenance, at as TemplateSource, au as TemplateTableSettings, av as TemplateTimelineView, aw as TemplateViewSort, ax as UseCaseSingulars, ay as WalkAction, az as WalkAssertion, aA as WalkImport, aB as WalkMove, aC as WalkStep, aD as confidentialPending, aE as confidentialRequests, aF as footprintOf, aG as membersAddRowsSteps, aH as tableSettingsProblems, aI as whenRule } from '../types-
|
|
3
|
-
import { i as AggregateMeasure, r as AggregateFilter } from '../subscription-
|
|
4
|
-
import { U as UseCase, o as UseCaseRelationship } from '../types-
|
|
5
|
-
import { U as UseCaseProblem } from '../validate-
|
|
6
|
-
export { R as RESOLVABLE_FIELD_TYPE_WORDS } from '../validate-
|
|
7
|
-
import { b as RecordsDataSource } from '../ports-
|
|
8
|
-
import '../record-
|
|
9
|
-
import '../field-
|
|
1
|
+
import { A as AgentSnapshotRow, T as TemplateSpec, a as TemplateTable, S as SharedBlockId, C as CapabilityWord, b as TemplateField, c as TemplateAgent, d as TemplateAutomation, e as TemplateBooking, f as TemplateChecklist, g as TemplateDashboard, h as TemplateDigest, i as TemplateDocument, j as TemplateDrillDown, k as TemplateDimensions, l as TemplateForm, m as TemplateNotification, n as TemplatePortal, o as TemplateRowAction, p as TemplateStageRules, q as TemplateView, r as TemplateMergeBinding, s as TemplateTryIt, t as TemplateWorkflow, u as TemplateFootprint, I as IndustryGroup, v as TemplateJob, w as TeachesFeature, x as TemplateViewKind, y as TemplateBookingWindow } from '../types-euaQwxnB.cjs';
|
|
2
|
+
export { z as CAPABILITY_WORDS, B as CATALOGUE_QUOTAS, D as CATALOGUE_STATUSES, E as CHOICE_COLORS, F as CHOICE_COLORS_DISTINCT_UP_TO, G as CatalogueRow, H as CatalogueStatus, J as ChoiceColor, K as ConfidentialLevel, L as ConfidentialRequest, M as DEFAULT_TEMPLATE_AGENT, N as ENTITY_REFERENCE_KINDS, O as INDUSTRY_GROUPS, R as RELATIVE_DATE, P as RetiredId, Q as SHARED_BLOCKS, U as SHARED_BLOCK_IDS, V as STRENGTHS, W as SharedBlock, X as SharedBlockField, Y as SharedBlockUse, Z as Strength, _ as TABLE_KERNEL_ID, $ as TEACHES_FEATURES, a0 as TEMPLATE_AUDIENCES, a1 as TEMPLATE_EXTRA_KINDS, a2 as TEMPLATE_JOBS, a3 as TEMPLATE_REFERENCE_DATE, a4 as TEMPLATE_SPEC_VERSION, a5 as TEMPLATE_VIEW_KINDS, a6 as TemplateAgentQuestion, a7 as TemplateAgentVariable, a8 as TemplateAudience, a9 as TemplateCalendarView, aa as TemplateChecklistStep, ab as TemplateConfidential, ac as TemplateConfidentialReader, ad as TemplateDashboardBlock, ae as TemplateDimensionOverride, af as TemplateDrillPath, ag as TemplateExtra, ah as TemplateExtraAgent, ai as TemplateExtraAgentVariable, aj as TemplateExtraKind, ak as TemplateFormField, al as TemplateFoundation, am as TemplateGalleryView, an as TemplateGridView, ao as TemplateGuideStep, ap as TemplateKanbanView, aq as TemplateMeasureOverride, ar as TemplatePortalTable, as as TemplateProvenance, at as TemplateSource, au as TemplateTableSettings, av as TemplateTimelineView, aw as TemplateViewSort, ax as UseCaseSingulars, ay as WalkAction, az as WalkAssertion, aA as WalkImport, aB as WalkMove, aC as WalkStep, aD as confidentialPending, aE as confidentialRequests, aF as footprintOf, aG as membersAddRowsSteps, aH as tableSettingsProblems, aI as whenRule } from '../types-euaQwxnB.cjs';
|
|
3
|
+
import { i as AggregateMeasure, r as AggregateFilter } from '../subscription-DGCrwwSR.cjs';
|
|
4
|
+
import { U as UseCase, o as UseCaseRelationship } from '../types-D-Mhiodh.cjs';
|
|
5
|
+
import { U as UseCaseProblem } from '../validate-COvMcv8z.cjs';
|
|
6
|
+
export { R as RESOLVABLE_FIELD_TYPE_WORDS } from '../validate-COvMcv8z.cjs';
|
|
7
|
+
import { b as RecordsDataSource } from '../ports-Cjl-IjFa.cjs';
|
|
8
|
+
import '../record-Ba1F1CNS.cjs';
|
|
9
|
+
import '../field-t9aefszx.cjs';
|
|
10
10
|
|
|
11
11
|
/** The UTC offset ("-04:00") of a local wall-clock moment in an IANA zone. */
|
|
12
12
|
declare function zoneOffset(localIso: string, timeZone: string): string;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { A as AgentSnapshotRow, T as TemplateSpec, a as TemplateTable, S as SharedBlockId, C as CapabilityWord, b as TemplateField, c as TemplateAgent, d as TemplateAutomation, e as TemplateBooking, f as TemplateChecklist, g as TemplateDashboard, h as TemplateDigest, i as TemplateDocument, j as TemplateDrillDown, k as TemplateDimensions, l as TemplateForm, m as TemplateNotification, n as TemplatePortal, o as TemplateRowAction, p as TemplateStageRules, q as TemplateView, r as TemplateMergeBinding, s as TemplateTryIt, t as TemplateWorkflow, u as TemplateFootprint, I as IndustryGroup, v as TemplateJob, w as TeachesFeature, x as TemplateViewKind, y as TemplateBookingWindow } from '../types-
|
|
2
|
-
export { z as CAPABILITY_WORDS, B as CATALOGUE_QUOTAS, D as CATALOGUE_STATUSES, E as CHOICE_COLORS, F as CHOICE_COLORS_DISTINCT_UP_TO, G as CatalogueRow, H as CatalogueStatus, J as ChoiceColor, K as ConfidentialLevel, L as ConfidentialRequest, M as DEFAULT_TEMPLATE_AGENT, N as ENTITY_REFERENCE_KINDS, O as INDUSTRY_GROUPS, R as RELATIVE_DATE, P as RetiredId, Q as SHARED_BLOCKS, U as SHARED_BLOCK_IDS, V as STRENGTHS, W as SharedBlock, X as SharedBlockField, Y as SharedBlockUse, Z as Strength, _ as TABLE_KERNEL_ID, $ as TEACHES_FEATURES, a0 as TEMPLATE_AUDIENCES, a1 as TEMPLATE_EXTRA_KINDS, a2 as TEMPLATE_JOBS, a3 as TEMPLATE_REFERENCE_DATE, a4 as TEMPLATE_SPEC_VERSION, a5 as TEMPLATE_VIEW_KINDS, a6 as TemplateAgentQuestion, a7 as TemplateAgentVariable, a8 as TemplateAudience, a9 as TemplateCalendarView, aa as TemplateChecklistStep, ab as TemplateConfidential, ac as TemplateConfidentialReader, ad as TemplateDashboardBlock, ae as TemplateDimensionOverride, af as TemplateDrillPath, ag as TemplateExtra, ah as TemplateExtraAgent, ai as TemplateExtraAgentVariable, aj as TemplateExtraKind, ak as TemplateFormField, al as TemplateFoundation, am as TemplateGalleryView, an as TemplateGridView, ao as TemplateGuideStep, ap as TemplateKanbanView, aq as TemplateMeasureOverride, ar as TemplatePortalTable, as as TemplateProvenance, at as TemplateSource, au as TemplateTableSettings, av as TemplateTimelineView, aw as TemplateViewSort, ax as UseCaseSingulars, ay as WalkAction, az as WalkAssertion, aA as WalkImport, aB as WalkMove, aC as WalkStep, aD as confidentialPending, aE as confidentialRequests, aF as footprintOf, aG as membersAddRowsSteps, aH as tableSettingsProblems, aI as whenRule } from '../types-
|
|
3
|
-
import { i as AggregateMeasure, r as AggregateFilter } from '../subscription-
|
|
4
|
-
import { U as UseCase, o as UseCaseRelationship } from '../types-
|
|
5
|
-
import { U as UseCaseProblem } from '../validate-
|
|
6
|
-
export { R as RESOLVABLE_FIELD_TYPE_WORDS } from '../validate-
|
|
7
|
-
import { b as RecordsDataSource } from '../ports-
|
|
8
|
-
import '../record-
|
|
9
|
-
import '../field-
|
|
1
|
+
import { A as AgentSnapshotRow, T as TemplateSpec, a as TemplateTable, S as SharedBlockId, C as CapabilityWord, b as TemplateField, c as TemplateAgent, d as TemplateAutomation, e as TemplateBooking, f as TemplateChecklist, g as TemplateDashboard, h as TemplateDigest, i as TemplateDocument, j as TemplateDrillDown, k as TemplateDimensions, l as TemplateForm, m as TemplateNotification, n as TemplatePortal, o as TemplateRowAction, p as TemplateStageRules, q as TemplateView, r as TemplateMergeBinding, s as TemplateTryIt, t as TemplateWorkflow, u as TemplateFootprint, I as IndustryGroup, v as TemplateJob, w as TeachesFeature, x as TemplateViewKind, y as TemplateBookingWindow } from '../types-CtyMwJvy.js';
|
|
2
|
+
export { z as CAPABILITY_WORDS, B as CATALOGUE_QUOTAS, D as CATALOGUE_STATUSES, E as CHOICE_COLORS, F as CHOICE_COLORS_DISTINCT_UP_TO, G as CatalogueRow, H as CatalogueStatus, J as ChoiceColor, K as ConfidentialLevel, L as ConfidentialRequest, M as DEFAULT_TEMPLATE_AGENT, N as ENTITY_REFERENCE_KINDS, O as INDUSTRY_GROUPS, R as RELATIVE_DATE, P as RetiredId, Q as SHARED_BLOCKS, U as SHARED_BLOCK_IDS, V as STRENGTHS, W as SharedBlock, X as SharedBlockField, Y as SharedBlockUse, Z as Strength, _ as TABLE_KERNEL_ID, $ as TEACHES_FEATURES, a0 as TEMPLATE_AUDIENCES, a1 as TEMPLATE_EXTRA_KINDS, a2 as TEMPLATE_JOBS, a3 as TEMPLATE_REFERENCE_DATE, a4 as TEMPLATE_SPEC_VERSION, a5 as TEMPLATE_VIEW_KINDS, a6 as TemplateAgentQuestion, a7 as TemplateAgentVariable, a8 as TemplateAudience, a9 as TemplateCalendarView, aa as TemplateChecklistStep, ab as TemplateConfidential, ac as TemplateConfidentialReader, ad as TemplateDashboardBlock, ae as TemplateDimensionOverride, af as TemplateDrillPath, ag as TemplateExtra, ah as TemplateExtraAgent, ai as TemplateExtraAgentVariable, aj as TemplateExtraKind, ak as TemplateFormField, al as TemplateFoundation, am as TemplateGalleryView, an as TemplateGridView, ao as TemplateGuideStep, ap as TemplateKanbanView, aq as TemplateMeasureOverride, ar as TemplatePortalTable, as as TemplateProvenance, at as TemplateSource, au as TemplateTableSettings, av as TemplateTimelineView, aw as TemplateViewSort, ax as UseCaseSingulars, ay as WalkAction, az as WalkAssertion, aA as WalkImport, aB as WalkMove, aC as WalkStep, aD as confidentialPending, aE as confidentialRequests, aF as footprintOf, aG as membersAddRowsSteps, aH as tableSettingsProblems, aI as whenRule } from '../types-CtyMwJvy.js';
|
|
3
|
+
import { i as AggregateMeasure, r as AggregateFilter } from '../subscription-CccP6N93.js';
|
|
4
|
+
import { U as UseCase, o as UseCaseRelationship } from '../types-CiHdoATO.js';
|
|
5
|
+
import { U as UseCaseProblem } from '../validate-B-p3YPgA.js';
|
|
6
|
+
export { R as RESOLVABLE_FIELD_TYPE_WORDS } from '../validate-B-p3YPgA.js';
|
|
7
|
+
import { b as RecordsDataSource } from '../ports-Ch4Ym0tj.js';
|
|
8
|
+
import '../record-Ba1F1CNS.js';
|
|
9
|
+
import '../field-B2bvpqcE.js';
|
|
10
10
|
|
|
11
11
|
/** The UTC offset ("-04:00") of a local wall-clock moment in an IANA zone. */
|
|
12
12
|
declare function zoneOffset(localIso: string, timeZone: string): string;
|
package/dist/templates/index.js
CHANGED
|
@@ -325,6 +325,9 @@ function footprintOf(spec) {
|
|
|
325
325
|
}
|
|
326
326
|
var CATALOGUE_STATUSES = ["planned", "authoring", "checking", "waiting_on_lane_10", "ready", "published", "retired"];
|
|
327
327
|
|
|
328
|
+
// src/templates/validate.ts
|
|
329
|
+
import { isUuidShape } from "@ai-matrx/kit/uuid";
|
|
330
|
+
|
|
328
331
|
// src/templates/confidential.ts
|
|
329
332
|
var TABLE_KERNEL_ID = "11111111-0000-4000-8000-000000000001";
|
|
330
333
|
var sqlText = (s) => `'${s.replace(/'/g, "''")}'`;
|
|
@@ -768,6 +771,7 @@ var STORE_DOORS = [
|
|
|
768
771
|
{ name: "data_home", args: "p_organization_id uuid DEFAULT NULL::uuid, p_search text DEFAULT NULL::text, p_include_app_tables boolean DEFAULT false", returns: "jsonb", security: "definer" },
|
|
769
772
|
{ name: "data_home_changed_by", args: "p_asks jsonb", returns: "TABLE(organization_id uuid, id uuid, at timestamp with time zone, who text)", security: "definer" },
|
|
770
773
|
{ name: "data_home_items", args: "p_organization_id uuid DEFAULT NULL::uuid", returns: "TABLE(kind text, organization_id uuid, organization_name text, item_id uuid, table_id uuid, table_name text, item_row jsonb)", security: "definer" },
|
|
774
|
+
{ name: "data_home_slim", args: "p_organization_id uuid DEFAULT NULL::uuid, p_search text DEFAULT NULL::text, p_include_app_tables boolean DEFAULT false", returns: "jsonb", security: "invoker" },
|
|
771
775
|
{ name: "data_home_tables", args: "p_organization_id uuid DEFAULT NULL::uuid", returns: "TABLE(table_id uuid, table_name text, organization_id uuid, organization_name text, member boolean, visibility text, updated_at timestamp with time zone, mine boolean, shared_with_me boolean, kept_by_the_app boolean, kind text, team boolean, system boolean, created_by uuid)", security: "definer" },
|
|
772
776
|
{ name: "data_home_tables", args: "p_organization_id uuid, p_include_app_tables boolean", returns: "TABLE(table_id uuid, table_name text, organization_id uuid, organization_name text, member boolean, visibility text, updated_at timestamp with time zone, mine boolean, shared_with_me boolean, kept_by_the_app boolean, kind text, team boolean, system boolean, created_by uuid)", security: "invoker" },
|
|
773
777
|
{ name: "declared_conversation", args: "", returns: "uuid", security: "invoker" },
|
|
@@ -1348,6 +1352,7 @@ var STORE_DOORS = [
|
|
|
1348
1352
|
{ name: "table_list_everywhere", args: "p_organization_id uuid DEFAULT NULL::uuid", returns: "jsonb", security: "definer" },
|
|
1349
1353
|
{ name: "table_list_everywhere", args: "p_organization_id uuid, p_include_app_tables boolean", returns: "jsonb", security: "invoker" },
|
|
1350
1354
|
{ name: "table_move", args: "p_table_id uuid, p_to_organization_id uuid, p_expected_version integer DEFAULT NULL::integer", returns: "jsonb", security: "definer" },
|
|
1355
|
+
{ name: "table_page_bundle", args: "p_organization_id uuid, p_table_id uuid, p_view_id uuid DEFAULT NULL::uuid", returns: "jsonb", security: "invoker" },
|
|
1351
1356
|
{ name: "table_placement", args: "p_organization_id uuid, p_table_id uuid, p_data jsonb, p_is_kernel boolean DEFAULT false", returns: "jsonb", security: "invoker" },
|
|
1352
1357
|
{ name: "table_record_ceiling", args: "", returns: "integer", security: "invoker" },
|
|
1353
1358
|
{ name: "table_record_ceiling", args: "p_organization_id uuid", returns: "integer", security: "invoker" },
|
|
@@ -3437,7 +3442,6 @@ var sortedJson = (v) => JSON.stringify(Object.keys(v).sort().map((k) => [k, v[k]
|
|
|
3437
3442
|
var filled = (v) => storeText(v) !== null && storeText(v) !== "" && !(Array.isArray(v) && v.length === 0);
|
|
3438
3443
|
var THING_NAME = /^(section|class|course|period|room|bay|item|job|role|team|pool|machine|program|plan|service|procedure|product|group|neighborhood|listing|grant|deal|bid|engagement|matter|account|company|route|site|location|project|event|campaign|unit|vehicle|truck|table|field|view|form)_name$/;
|
|
3439
3444
|
var FILE_VALUE_RE = /^@file:([A-Za-z0-9_.-]+)$/;
|
|
3440
|
-
var UUID_RE = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
3441
3445
|
function attachmentProblems(raw, assets) {
|
|
3442
3446
|
const out = [];
|
|
3443
3447
|
const say = (at, says) => out.push({ at, says });
|
|
@@ -3453,7 +3457,7 @@ function attachmentProblems(raw, assets) {
|
|
|
3453
3457
|
if (!a.key || !/^[A-Za-z0-9_.-]+$/.test(a.key)) return say(`${at}.key`, "Each picture has a key (letters, digits, _ . -).");
|
|
3454
3458
|
if (keys.has(a.key)) say(`${at}.key`, `"${a.key}" is listed twice.`);
|
|
3455
3459
|
keys.add(a.key);
|
|
3456
|
-
if (!a.fileId || !
|
|
3460
|
+
if (!a.fileId || !isUuidShape(a.fileId)) say(`${at}.fileId`, `"${a.key}" needs the file id from templates/ASSETS.json.`);
|
|
3457
3461
|
if (!a.name || !a.mime || typeof a.bytes !== "number") say(at, `"${a.key}" copies name, mime and bytes from templates/ASSETS.json.`);
|
|
3458
3462
|
if (library) {
|
|
3459
3463
|
const asset = library.get(a.key);
|