@toolproof-npm/shared 0.1.36 → 0.1.37

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.
@@ -11,7 +11,7 @@ export declare const CONSTANTS: {
11
11
  readonly tp_resources: "tp-resources";
12
12
  };
13
13
  readonly COLLECTIONS: {
14
- readonly resourceshapes: "resourceshapes";
14
+ readonly shapes: "shapes";
15
15
  readonly resources: "resources";
16
16
  };
17
17
  readonly FILTER: {
@@ -19,11 +19,11 @@ export declare const CONSTANTS: {
19
19
  readonly specials: "specials";
20
20
  };
21
21
  };
22
- readonly RESOURCESHAPES: {
22
+ readonly SHAPES: {
23
23
  readonly formats: "formats";
24
24
  readonly types: "types";
25
25
  };
26
- readonly RESOURCESHAPES_PSEUDO: {
26
+ readonly ROLES: {
27
27
  readonly roles: "roles";
28
28
  };
29
29
  readonly RESOURCES: {
package/dist/constants.js CHANGED
@@ -11,7 +11,7 @@ export const CONSTANTS = {
11
11
  tp_resources: 'tp-resources',
12
12
  },
13
13
  COLLECTIONS: {
14
- resourceshapes: 'resourceshapes',
14
+ shapes: 'shapes',
15
15
  resources: 'resources',
16
16
  },
17
17
  FILTER: {
@@ -19,11 +19,11 @@ export const CONSTANTS = {
19
19
  specials: 'specials',
20
20
  }
21
21
  },
22
- RESOURCESHAPES: {
22
+ SHAPES: {
23
23
  formats: 'formats',
24
24
  types: 'types',
25
25
  },
26
- RESOURCESHAPES_PSEUDO: {
26
+ ROLES: {
27
27
  roles: 'roles',
28
28
  },
29
29
  RESOURCES: {
@@ -4,12 +4,12 @@ export function getNewId(identifiable) {
4
4
  const base = identifiable.toUpperCase();
5
5
  const normalized = base.endsWith('S') ? base.slice(0, -1) : base;
6
6
  const prefix = normalized + '-';
7
- const docRef = dbAdmin.collection(CONSTANTS.STORAGE.COLLECTIONS.resourceshapes).doc(identifiable).collection(CONSTANTS.STORAGE.FILTER.members).doc();
7
+ const docRef = dbAdmin.collection(CONSTANTS.STORAGE.COLLECTIONS.shapes).doc(identifiable).collection(CONSTANTS.STORAGE.FILTER.members).doc();
8
8
  return prefix + docRef.id;
9
9
  }
10
10
  export async function listResourceShapesMeta(groupKey, filterConfig) {
11
11
  const baseRef = dbAdmin
12
- .collection(CONSTANTS.STORAGE.COLLECTIONS.resourceshapes)
12
+ .collection(CONSTANTS.STORAGE.COLLECTIONS.shapes)
13
13
  .doc(groupKey);
14
14
  const entries = await Promise.all([
15
15
  filterConfig.members
package/dist/types.d.ts CHANGED
@@ -1,10 +1,10 @@
1
1
  import type { ResourceIdJson, ExecutionIdJson, ResourceRoleIdJson, ResourceRoleValueJson, ResourceTypeIdJson, ResourceFormatMetaJson, ResourceFormatDataJson, ResourceTypeMetaJson, ResourceTypeDataJson, ResourceMetaJson, ResourceDataJson } from '@toolproof-npm/schema';
2
2
  import { CONSTANTS } from './constants.js';
3
3
  export type BucketConst = typeof CONSTANTS.STORAGE.BUCKETS.tp_shapes | typeof CONSTANTS.STORAGE.BUCKETS.tp_resources;
4
- export type CollectionConst = typeof CONSTANTS.STORAGE.COLLECTIONS.resourceshapes | typeof CONSTANTS.STORAGE.COLLECTIONS.resources;
4
+ export type CollectionConst = typeof CONSTANTS.STORAGE.COLLECTIONS.shapes | typeof CONSTANTS.STORAGE.COLLECTIONS.resources;
5
5
  export type FilterConst = typeof CONSTANTS.STORAGE.FILTER.members | typeof CONSTANTS.STORAGE.FILTER.specials;
6
- export type ResourceShapeConst = typeof CONSTANTS.RESOURCESHAPES.formats | typeof CONSTANTS.RESOURCESHAPES.types;
7
- export type ResourceRoleConst = typeof CONSTANTS.RESOURCESHAPES_PSEUDO.roles;
6
+ export type ResourceShapeConst = typeof CONSTANTS.SHAPES.formats | typeof CONSTANTS.SHAPES.types;
7
+ export type ResourceRoleConst = typeof CONSTANTS.ROLES.roles;
8
8
  export type ResourceConst = typeof CONSTANTS.RESOURCES.resources;
9
9
  export type StepConst = typeof CONSTANTS.STEP.work | typeof CONSTANTS.STEP.branch | typeof CONSTANTS.STEP.while | typeof CONSTANTS.STEP.for;
10
10
  export type WorkflowConst = typeof CONSTANTS.WORKFLOW.workflow | typeof CONSTANTS.WORKFLOW.workflowSpec | typeof CONSTANTS.WORKFLOW.execution;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@toolproof-npm/shared",
3
- "version": "0.1.36",
3
+ "version": "0.1.37",
4
4
  "description": "Core library utilities for ToolProof",
5
5
  "keywords": [
6
6
  "toolproof",