From 5ec155c7ce964c9b806a33914bdf6cf823f854ba Mon Sep 17 00:00:00 2001 From: Jesse Mazzella Date: Mon, 4 Dec 2023 15:58:43 -0800 Subject: [PATCH 1/6] chore: bump version to `3.3.0-next` (#7273) Co-authored-by: John Hill --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 7180e9f073..c81dfff95d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "openmct", - "version": "3.2.0-next", + "version": "3.3.0-next", "description": "The Open MCT core platform", "devDependencies": { "@babel/eslint-parser": "7.22.5", From a3e0a0f694dbff721ee70a3e7bbc11fa2889fea0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Dec 2023 19:29:58 -0500 Subject: [PATCH 2/6] chore(deps-dev): bump @vue/compiler-sfc from 3.3.8 to 3.3.10 (#7270) Bumps [@vue/compiler-sfc](https://github.com/vuejs/core/tree/HEAD/packages/compiler-sfc) from 3.3.8 to 3.3.10. - [Release notes](https://github.com/vuejs/core/releases) - [Changelog](https://github.com/vuejs/core/blob/main/CHANGELOG.md) - [Commits](https://github.com/vuejs/core/commits/v3.3.10/packages/compiler-sfc) --- updated-dependencies: - dependency-name: "@vue/compiler-sfc" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: John Hill --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c81dfff95d..f9fce20c42 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "@types/eventemitter3": "1.2.0", "@types/jasmine": "5.1.2", "@types/lodash": "4.14.192", - "@vue/compiler-sfc": "3.3.8", + "@vue/compiler-sfc": "3.3.10", "babel-loader": "9.1.0", "babel-plugin-istanbul": "6.1.1", "codecov": "3.8.3", From 2d9c0414f72c583e2894d81cc80ab1bad09e06c6 Mon Sep 17 00:00:00 2001 From: Scott Bell Date: Tue, 5 Dec 2023 04:12:24 +0100 Subject: [PATCH 3/6] Inconsistent behavior with multiple annotations in imagery (#7261) * fix opacity issue * wip, though selection still weird * remove debugging * plots still have issue with last tag * add some better tests * Apply suggestions from code review Co-authored-by: David Tsay <3614296+davetsay@users.noreply.github.com> * remove hardlined classnames * case sensitivity * good job tests finding issue --------- Co-authored-by: David Tsay <3614296+davetsay@users.noreply.github.com> Co-authored-by: John Hill --- .../imagery/exampleImagery.e2e.spec.js | 8 ++ .../plugins/notebook/tags.e2e.spec.js | 18 ++++ .../plugins/plot/tagging.e2e.spec.js | 23 +++++ .../imagery/components/AnnotationsCanvas.vue | 86 ++++++++++++++----- .../annotations/AnnotationsInspectorView.vue | 4 +- .../annotations/tags/TagEditor.vue | 9 +- .../annotations/tags/TagEditorClassNames.js | 9 ++ .../annotations/tags/TagSelection.vue | 7 +- .../notebook/components/NotebookComponent.vue | 7 ++ .../notebook/components/NotebookEntry.vue | 8 +- src/plugins/plot/MctPlot.vue | 14 ++- 11 files changed, 159 insertions(+), 34 deletions(-) create mode 100644 src/plugins/inspectorViews/annotations/tags/TagEditorClassNames.js diff --git a/e2e/tests/functional/plugins/imagery/exampleImagery.e2e.spec.js b/e2e/tests/functional/plugins/imagery/exampleImagery.e2e.spec.js index c7ae0f4235..a5204cdb94 100644 --- a/e2e/tests/functional/plugins/imagery/exampleImagery.e2e.spec.js +++ b/e2e/tests/functional/plugins/imagery/exampleImagery.e2e.spec.js @@ -247,6 +247,14 @@ test.describe('Example Imagery Object', () => { await page.mouse.click(canvasCenterX - 50, canvasCenterY - 50); await expect(page.getByText('Driving')).toBeVisible(); await expect(page.getByText('Science')).toBeVisible(); + + // add another tag and expect it to appear without changing selection + await page.getByRole('button', { name: /Add Tag/ }).click(); + await page.getByPlaceholder('Type to select tag').click(); + await page.getByText('Drilling').click(); + await expect(page.getByText('Driving')).toBeVisible(); + await expect(page.getByText('Science')).toBeVisible(); + await expect(page.getByText('Drilling')).toBeVisible(); }); test('Can use + - buttons to zoom on the image @unstable', async ({ page }) => { diff --git a/e2e/tests/functional/plugins/notebook/tags.e2e.spec.js b/e2e/tests/functional/plugins/notebook/tags.e2e.spec.js index b4c9270b00..b520bf1fb5 100644 --- a/e2e/tests/functional/plugins/notebook/tags.e2e.spec.js +++ b/e2e/tests/functional/plugins/notebook/tags.e2e.spec.js @@ -224,4 +224,22 @@ test.describe('Tagging in Notebooks @addInit', () => { // Verify the AutoComplete field is hidden await expect(page.locator('[placeholder="Type to select tag"]')).toBeHidden(); }); + test('Can start to add a tag, click away, and add a tag', async ({ page }) => { + await createNotebookEntryAndTags(page); + + await page.getByRole('tab', { name: 'Annotations' }).click(); + + // Click on the body simulating a click outside the autocomplete) + await page.locator('body').click(); + await page.locator(`[aria-label="Notebook Entry"]`).click(); + + await page.hover(`button:has-text("Add Tag")`); + await page.locator(`button:has-text("Add Tag")`).click(); + + // Click inside the tag search input + await page.locator('[placeholder="Type to select tag"]').click(); + // Select the "Driving" tag + await page.locator('[aria-label="Autocomplete Options"] >> text=Drilling').click(); + await expect(page.getByLabel('Notebook Entries').getByText('Drilling')).toBeVisible(); + }); }); diff --git a/e2e/tests/functional/plugins/plot/tagging.e2e.spec.js b/e2e/tests/functional/plugins/plot/tagging.e2e.spec.js index 6b0fdd1176..84f65def9e 100644 --- a/e2e/tests/functional/plugins/plot/tagging.e2e.spec.js +++ b/e2e/tests/functional/plugins/plot/tagging.e2e.spec.js @@ -165,6 +165,29 @@ test.describe('Plot Tagging', () => { await expect(page.getByText('Science')).toBeVisible(); await expect(page.getByText('Driving')).toBeHidden(); + + // click elsewhere + await page.locator('body').click(); + //click on tagged plot point again + await canvas.click({ + position: { + x: 100, + y: 100 + } + }); + // Add driving tag again + await page.getByText('Annotations').click(); + await page.getByRole('button', { name: /Add Tag/ }).click(); + await page.getByPlaceholder('Type to select tag').click(); + await page.getByText('Driving').click(); + await expect(page.getByText('Science')).toBeVisible(); + await expect(page.getByText('Driving')).toBeVisible(); + + // Delete Driving again + await page.hover('[aria-label="Tag"]:has-text("Driving")'); + await page.locator('[aria-label="Remove tag Driving"]').click(); + await expect(page.getByText('Science')).toBeVisible(); + await expect(page.getByText('Driving')).toBeHidden(); } test.beforeEach(async ({ page }) => { diff --git a/src/plugins/imagery/components/AnnotationsCanvas.vue b/src/plugins/imagery/components/AnnotationsCanvas.vue index 66d99d6196..f5d03313dc 100644 --- a/src/plugins/imagery/components/AnnotationsCanvas.vue +++ b/src/plugins/imagery/components/AnnotationsCanvas.vue @@ -33,8 +33,11 @@