diff --git a/plugins/scaffolder/report-alpha.api.md b/plugins/scaffolder/report-alpha.api.md index 4abaab2898..8d0abc262f 100644 --- a/plugins/scaffolder/report-alpha.api.md +++ b/plugins/scaffolder/report-alpha.api.md @@ -325,12 +325,10 @@ export const scaffolderTranslationRef: TranslationRef< readonly 'templateEditorToolbar.installedActionsDocumentationTooltip': 'Installed Actions Documentation'; readonly 'templateEditorToolbar.addToCatalogButton': 'Publish'; readonly 'templateEditorToolbar.addToCatalogDialogTitle': 'Publish changes'; - readonly 'templateEditorToolbar.addToCatalogDialogContent.introduction': 'Follow the instructions below to create or update a template:'; - readonly 'templateEditorToolbar.addToCatalogDialogContent.step1': 'Save the template files in a local directory'; - readonly 'templateEditorToolbar.addToCatalogDialogContent.step2': 'Create a pull request to a new or existing git repository'; - readonly 'templateEditorToolbar.addToCatalogDialogContent.step3': 'If the template already exists, the changes will be reflected in the software catalog once the pull request gets merged'; - readonly 'templateEditorToolbar.addToCatalogDialogContent.step4': 'But if you are creating a new template, follow the documentation linked below to register the new template repository in software catalog'; - readonly 'templateEditorToolbar.addToCatalogDialogActions.closeButton': 'Close'; + readonly 'templateEditorToolbar.addToCatalogDialogContent.stepsIntroduction': 'Follow the instructions below to create or update a template:'; + readonly 'templateEditorToolbar.addToCatalogDialogContent.stepsListItems': 'Save the template files in a local directory\nCreate a pull request to a new or existing git repository\nIf the template already exists, the changes will be reflected in the software catalog once the pull request gets merged\nBut if you are creating a new template, follow the documentation linked below to register the new template repository in software catalog'; + readonly 'templateEditorToolbar.addToCatalogDialogActions.documentationUrl': 'https://backstage.io/docs/features/software-templates/adding-templates/'; + readonly 'templateEditorToolbar.addToCatalogDialogActions.documentationButton': 'Go to the documentation'; } >; diff --git a/plugins/scaffolder/src/alpha/components/TemplateEditorPage/TemplateEditorToolbar.tsx b/plugins/scaffolder/src/alpha/components/TemplateEditorPage/TemplateEditorToolbar.tsx index 0d78bd675c..8e3124f833 100644 --- a/plugins/scaffolder/src/alpha/components/TemplateEditorPage/TemplateEditorToolbar.tsx +++ b/plugins/scaffolder/src/alpha/components/TemplateEditorPage/TemplateEditorToolbar.tsx @@ -31,7 +31,6 @@ import DialogActions from '@material-ui/core/DialogActions'; import ExtensionIcon from '@material-ui/icons/Extension'; import DescriptionIcon from '@material-ui/icons/Description'; -import { Link } from '@backstage/core-components'; import { FieldExtensionOptions } from '@backstage/plugin-scaffolder-react'; import { ActionPageContent } from '../../../components/ActionsPage/ActionsPage'; @@ -137,31 +136,30 @@ export function TemplateEditorToolbar(props: { {t( - 'templateEditorToolbar.addToCatalogDialogContent.introduction', + 'templateEditorToolbar.addToCatalogDialogContent.stepsIntroduction', )} -
    -
  1. - {t('templateEditorToolbar.addToCatalogDialogContent.step1')} -
  2. -
  3. - {t('templateEditorToolbar.addToCatalogDialogContent.step2')} -
  4. -
  5. - {t('templateEditorToolbar.addToCatalogDialogContent.step3')} -
  6. -
  7. - {t('templateEditorToolbar.addToCatalogDialogContent.step4')} -
    - - https://backstage.io/docs/features/software-templates/adding-templates/ - -
  8. -
+
- diff --git a/plugins/scaffolder/src/translation.ts b/plugins/scaffolder/src/translation.ts index 72fc76e497..4399678948 100644 --- a/plugins/scaffolder/src/translation.ts +++ b/plugins/scaffolder/src/translation.ts @@ -304,17 +304,15 @@ export const scaffolderTranslationRef = createTranslationRef({ addToCatalogButton: 'Publish', addToCatalogDialogTitle: 'Publish changes', addToCatalogDialogContent: { - introduction: + stepsIntroduction: 'Follow the instructions below to create or update a template:', - step1: 'Save the template files in a local directory', - step2: 'Create a pull request to a new or existing git repository', - step3: - 'If the template already exists, the changes will be reflected in the software catalog once the pull request gets merged', - step4: - 'But if you are creating a new template, follow the documentation linked below to register the new template repository in software catalog', + stepsListItems: + 'Save the template files in a local directory\nCreate a pull request to a new or existing git repository\nIf the template already exists, the changes will be reflected in the software catalog once the pull request gets merged\nBut if you are creating a new template, follow the documentation linked below to register the new template repository in software catalog', }, addToCatalogDialogActions: { - closeButton: 'Close', + documentationButton: 'Go to the documentation', + documentationUrl: + 'https://backstage.io/docs/features/software-templates/adding-templates/', }, }, },