From c5d8341c453e3e92da4472ed5c11c2d79a603d61 Mon Sep 17 00:00:00 2001 From: yamashush <38120991+yamashush@users.noreply.github.com> Date: Fri, 12 Jan 2024 19:51:14 +0900 Subject: [PATCH] fix(frontend): improves UI/UX of aliases modal Signed-off-by: yamashush <38120991+yamashush@users.noreply.github.com> --- frontend/locales/en.json | 1 + .../aliases-add-form.spec.tsx.snap | 4 +- .../aliases-list-entry.spec.tsx.snap | 70 ++++++++++--------- .../aliases-modal/aliases-add-form.tsx | 6 +- .../aliases-modal/aliases-list-entry.spec.tsx | 4 +- .../aliases-modal/aliases-list-entry.tsx | 27 ++++--- 6 files changed, 57 insertions(+), 55 deletions(-) diff --git a/frontend/locales/en.json b/frontend/locales/en.json index 1b468ef21..b7884a0c0 100644 --- a/frontend/locales/en.json +++ b/frontend/locales/en.json @@ -441,6 +441,7 @@ "addAlias": "Add alias", "makePrimary": "Mark this alias as primary", "isPrimary": "This is the primary alias", + "primaryLabel": "Primary Alias", "removeAlias": "Remove this alias", "errorAddingAlias": "The chosen alias can not be added to this note", "errorRemovingAlias": "There was an error removing the alias", diff --git a/frontend/src/components/editor-page/sidebar/specific-sidebar-entries/aliases-sidebar-entry/aliases-modal/__snapshots__/aliases-add-form.spec.tsx.snap b/frontend/src/components/editor-page/sidebar/specific-sidebar-entries/aliases-sidebar-entry/aliases-modal/__snapshots__/aliases-add-form.spec.tsx.snap index 4fb774a3a..d4cb68ea1 100644 --- a/frontend/src/components/editor-page/sidebar/specific-sidebar-entries/aliases-sidebar-entry/aliases-modal/__snapshots__/aliases-add-form.spec.tsx.snap +++ b/frontend/src/components/editor-page/sidebar/specific-sidebar-entries/aliases-sidebar-entry/aliases-modal/__snapshots__/aliases-add-form.spec.tsx.snap @@ -14,13 +14,13 @@ exports[`AliasesAddForm renders the input form 1`] = ` value="" /> diff --git a/frontend/src/components/editor-page/sidebar/specific-sidebar-entries/aliases-sidebar-entry/aliases-modal/__snapshots__/aliases-list-entry.spec.tsx.snap b/frontend/src/components/editor-page/sidebar/specific-sidebar-entries/aliases-sidebar-entry/aliases-modal/__snapshots__/aliases-list-entry.spec.tsx.snap index 2277f6a9b..c24e3fccc 100644 --- a/frontend/src/components/editor-page/sidebar/specific-sidebar-entries/aliases-sidebar-entry/aliases-modal/__snapshots__/aliases-list-entry.spec.tsx.snap +++ b/frontend/src/components/editor-page/sidebar/specific-sidebar-entries/aliases-sidebar-entry/aliases-modal/__snapshots__/aliases-list-entry.spec.tsx.snap @@ -1,23 +1,23 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`AliasesListEntry disables button in AliasesListEntry if it's not primary 1`] = ` +exports[`AliasesListEntry adds aliasPrimaryBadge & removes aliasButtonMakePrimary in AliasesListEntry if it's primary 1`] = `