diff --git a/package-lock.json b/package-lock.json index d4fc7485b87..32757cdc921 100644 --- a/package-lock.json +++ b/package-lock.json @@ -65010,7 +65010,7 @@ }, "packages/common": { "name": "@esri/hub-common", - "version": "14.71.2", + "version": "14.72.2", "license": "Apache-2.0", "dependencies": { "@terraformer/arcgis": "^2.1.2", diff --git a/packages/common/src/projects/_internal/ProjectUiSchemaEdit.ts b/packages/common/src/projects/_internal/ProjectUiSchemaEdit.ts index 59cc93f2c59..11841a5341a 100644 --- a/packages/common/src/projects/_internal/ProjectUiSchemaEdit.ts +++ b/packages/common/src/projects/_internal/ProjectUiSchemaEdit.ts @@ -259,46 +259,45 @@ export const buildUiSchema = async ( }, ], }, - // NOTE: temporarily commenting out for release. - // { - // type: "Section", - // labelKey: `${i18nScope}.sections.callToAction.label`, - // options: { - // helperText: { - // labelKey: `${i18nScope}.sections.callToAction.helperText`, - // }, - // }, - // elements: [ - // { - // scope: "/properties/view/properties/heroActions", - // type: "Control", - // options: { - // control: "hub-composite-input-action-links", - // type: "button", - // catalogs: getFeaturedContentCatalogs(context.currentUser), // for now we'll just re-use this util to get the catalogs - // facets: [ - // { - // label: `{{${i18nScope}.fields.callToAction.facets.type:translate}}`, - // key: "type", - // display: "multi-select", - // field: "type", - // options: [], - // operation: "OR", - // aggLimit: 100, - // }, - // { - // label: `{{${i18nScope}.fields.callToAction.facets.sharing:translate}}`, - // key: "access", - // display: "multi-select", - // field: "access", - // options: [], - // operation: "OR", - // }, - // ], - // }, - // }, - // ], - // }, + { + type: "Section", + labelKey: `${i18nScope}.sections.callToAction.label`, + options: { + helperText: { + labelKey: `${i18nScope}.sections.callToAction.helperText`, + }, + }, + elements: [ + { + scope: "/properties/view/properties/heroActions", + type: "Control", + options: { + control: "hub-composite-input-action-links", + type: "button", + catalogs: getFeaturedContentCatalogs(context.currentUser), // for now we'll just re-use this util to get the catalogs + facets: [ + { + label: `{{${i18nScope}.fields.callToAction.facets.type:translate}}`, + key: "type", + display: "multi-select", + field: "type", + options: [], + operation: "OR", + aggLimit: 100, + }, + { + label: `{{${i18nScope}.fields.callToAction.facets.sharing:translate}}`, + key: "access", + display: "multi-select", + field: "access", + options: [], + operation: "OR", + }, + ], + }, + }, + ], + }, ], }; }; diff --git a/packages/common/test/projects/_internal/ProjectUiSchemaEdit.test.ts b/packages/common/test/projects/_internal/ProjectUiSchemaEdit.test.ts index 59d6f552ed6..00791d8a310 100644 --- a/packages/common/test/projects/_internal/ProjectUiSchemaEdit.test.ts +++ b/packages/common/test/projects/_internal/ProjectUiSchemaEdit.test.ts @@ -274,46 +274,45 @@ describe("buildUiSchema: project edit", () => { }, ], }, - // TODO: uncomment after release and we add CTA back - // { - // type: "Section", - // labelKey: "some.scope.sections.callToAction.label", - // options: { - // helperText: { - // labelKey: "some.scope.sections.callToAction.helperText", - // }, - // }, - // elements: [ - // { - // scope: "/properties/view/properties/heroActions", - // type: "Control", - // options: { - // control: "hub-composite-input-action-links", - // type: "button", - // catalogs: {}, - // facets: [ - // { - // label: `{{some.scope.fields.callToAction.facets.type:translate}}`, - // key: "type", - // display: "multi-select", - // field: "type", - // options: [], - // operation: "OR", - // aggLimit: 100, - // }, - // { - // label: `{{some.scope.fields.callToAction.facets.sharing:translate}}`, - // key: "access", - // display: "multi-select", - // field: "access", - // options: [], - // operation: "OR", - // }, - // ], - // }, - // }, - // ], - // }, + { + type: "Section", + labelKey: "some.scope.sections.callToAction.label", + options: { + helperText: { + labelKey: "some.scope.sections.callToAction.helperText", + }, + }, + elements: [ + { + scope: "/properties/view/properties/heroActions", + type: "Control", + options: { + control: "hub-composite-input-action-links", + type: "button", + catalogs: {}, + facets: [ + { + label: `{{some.scope.fields.callToAction.facets.type:translate}}`, + key: "type", + display: "multi-select", + field: "type", + options: [], + operation: "OR", + aggLimit: 100, + }, + { + label: `{{some.scope.fields.callToAction.facets.sharing:translate}}`, + key: "access", + display: "multi-select", + field: "access", + options: [], + operation: "OR", + }, + ], + }, + }, + ], + }, ], }); }); @@ -586,46 +585,45 @@ describe("buildUiSchema: project edit", () => { }, ], }, - // TODO: uncomment after release and we add CTA back - // { - // type: "Section", - // labelKey: "some.scope.sections.callToAction.label", - // options: { - // helperText: { - // labelKey: "some.scope.sections.callToAction.helperText", - // }, - // }, - // elements: [ - // { - // scope: "/properties/view/properties/heroActions", - // type: "Control", - // options: { - // control: "hub-composite-input-action-links", - // type: "button", - // catalogs: {}, - // facets: [ - // { - // label: `{{some.scope.fields.callToAction.facets.type:translate}}`, - // key: "type", - // display: "multi-select", - // field: "type", - // options: [], - // operation: "OR", - // aggLimit: 100, - // }, - // { - // label: `{{some.scope.fields.callToAction.facets.sharing:translate}}`, - // key: "access", - // display: "multi-select", - // field: "access", - // options: [], - // operation: "OR", - // }, - // ], - // }, - // }, - // ], - // }, + { + type: "Section", + labelKey: "some.scope.sections.callToAction.label", + options: { + helperText: { + labelKey: "some.scope.sections.callToAction.helperText", + }, + }, + elements: [ + { + scope: "/properties/view/properties/heroActions", + type: "Control", + options: { + control: "hub-composite-input-action-links", + type: "button", + catalogs: {}, + facets: [ + { + label: `{{some.scope.fields.callToAction.facets.type:translate}}`, + key: "type", + display: "multi-select", + field: "type", + options: [], + operation: "OR", + aggLimit: 100, + }, + { + label: `{{some.scope.fields.callToAction.facets.sharing:translate}}`, + key: "access", + display: "multi-select", + field: "access", + options: [], + operation: "OR", + }, + ], + }, + }, + ], + }, ], }); });