From a58f346f552c967de71ccfe871c28399d9cb9da9 Mon Sep 17 00:00:00 2001 From: Chris Hut Date: Mon, 26 Feb 2024 12:34:01 -0800 Subject: [PATCH] Hardcode links to CCM to be false (#20732) Hardcode links to CCM to be false - due to CCM deprecation Remove changelog item for breaking Ui change - since CCM linking no longer exists --- .changelog/20474.txt | 3 --- ui/packages/consul-ui/app/components/hcp-nav-item/index.js | 3 ++- ui/packages/consul-ui/app/services/hcp-link-status.js | 3 ++- ui/packages/consul-ui/tests/acceptance/link-to-hcp-test.js | 2 +- .../tests/integration/components/hcp-nav-item-test.js | 2 +- 5 files changed, 6 insertions(+), 7 deletions(-) delete mode 100644 .changelog/20474.txt diff --git a/.changelog/20474.txt b/.changelog/20474.txt deleted file mode 100644 index 8c0d514b866d..000000000000 --- a/.changelog/20474.txt +++ /dev/null @@ -1,3 +0,0 @@ -```release-note:breaking-change -ui: Adds a "Link to HCP Consul Central" modal with integration to side-nav and link to HCP banner. There will be an option to disable the Link to HCP banner from the UI in a follow-up release. -``` \ No newline at end of file diff --git a/ui/packages/consul-ui/app/components/hcp-nav-item/index.js b/ui/packages/consul-ui/app/components/hcp-nav-item/index.js index 741de542de77..b1fb989bec55 100644 --- a/ui/packages/consul-ui/app/components/hcp-nav-item/index.js +++ b/ui/packages/consul-ui/app/components/hcp-nav-item/index.js @@ -41,7 +41,8 @@ export default class HcpLinkItemComponent extends Component { return false; } - return true; + // With the death of Consul Central, we don't want to display the link nav item + return false; } get shouldShowBackToHcpItem() { diff --git a/ui/packages/consul-ui/app/services/hcp-link-status.js b/ui/packages/consul-ui/app/services/hcp-link-status.js index eab9764585ba..e8d7c3065348 100644 --- a/ui/packages/consul-ui/app/services/hcp-link-status.js +++ b/ui/packages/consul-ui/app/services/hcp-link-status.js @@ -14,7 +14,8 @@ export default class HcpLinkStatus extends Service { userDismissedBanner = false; get shouldDisplayBanner() { - return !this.userDismissedBanner && this.hasPermissionToLink; + // With the death of Consul Central, we don't want to display the link nav item + return false; } get hasPermissionToLink() { diff --git a/ui/packages/consul-ui/tests/acceptance/link-to-hcp-test.js b/ui/packages/consul-ui/tests/acceptance/link-to-hcp-test.js index 39d4cbc989f5..b9eb8263f8b3 100644 --- a/ui/packages/consul-ui/tests/acceptance/link-to-hcp-test.js +++ b/ui/packages/consul-ui/tests/acceptance/link-to-hcp-test.js @@ -12,7 +12,7 @@ const linkToHcpSelector = '[data-test-link-to-hcp]'; const linkToHcpBannerButtonSelector = '[data-test-link-to-hcp-banner-button]'; const linkToHcpModalSelector = '[data-test-link-to-hcp-modal]'; const linkToHcpModalCancelButtonSelector = '[data-test-link-to-hcp-modal-cancel-button]'; -module('Acceptance | link to hcp', function (hooks) { +module.skip('Acceptance | link to hcp', function (hooks) { setupApplicationTest(hooks); hooks.beforeEach(function () { diff --git a/ui/packages/consul-ui/tests/integration/components/hcp-nav-item-test.js b/ui/packages/consul-ui/tests/integration/components/hcp-nav-item-test.js index 32c784baf7ce..c3fcf93686ad 100644 --- a/ui/packages/consul-ui/tests/integration/components/hcp-nav-item-test.js +++ b/ui/packages/consul-ui/tests/integration/components/hcp-nav-item-test.js @@ -86,7 +86,7 @@ module('Integration | Component | hcp nav item', function (hooks) { }); }); - module('when rendered in self managed mode', function (hooks) { + module.skip('when rendered in self managed mode', function (hooks) { hooks.beforeEach(function () { this.owner.register( 'service:env',