@diagonal-hq/cli 0.21.0 → 0.21.1

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.
Files changed (2) hide show
  1. package/dist/cli.mjs +4 -1
  2. package/package.json +1 -1
package/dist/cli.mjs CHANGED
@@ -301842,6 +301842,9 @@ function notificationTypeEntries(notifications) {
301842
301842
  }
301843
301843
  return { entries };
301844
301844
  }
301845
+ function recordHoldsValue(field2) {
301846
+ return field2.required === true && field2.type !== "relation" && field2.type !== "password";
301847
+ }
301845
301848
  function workflowResourceEntries(resources, openResources = []) {
301846
301849
  const resourcesBySlug = new Map([
301847
301850
  ...openResources.map((resource) => [resource.slug, null]),
@@ -301863,7 +301866,7 @@ function workflowResourceEntries(resources, openResources = []) {
301863
301866
  const inputType = field2.type === "relation" ? `${type} | Array<{ id: string }>` : type;
301864
301867
  const key = propertyKey(field2.key);
301865
301868
  input.push(`${key}?: ${inputType} | null`);
301866
- record.push(`${key}: ${type} | null`);
301869
+ record.push(recordHoldsValue(field2) ? `${key}: ${type}` : `${key}: ${type} | null`);
301867
301870
  }
301868
301871
  const capabilities = Object.keys(resource.capabilities ?? {}).toSorted(byteOrder).map((capability) => `'${capability}'`);
301869
301872
  entries.push(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@diagonal-hq/cli",
3
- "version": "0.21.0",
3
+ "version": "0.21.1",
4
4
  "description": "The diagonal CLI and the configuration helpers for file-based Diagonal workspaces.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "repository": {