Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CC-5545: Side Nav #19342

Merged
merged 31 commits into from
Nov 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
dfb4f5d
Initial work for sidenav
Oct 16, 2023
bdcbbef
Use HDS::Text
Oct 17, 2023
cafa053
Add resolution for ember-element-helper
Oct 17, 2023
aea4cc7
WIP dc selector
Oct 20, 2023
40f63db
Update HCP Home link
Oct 20, 2023
c24758f
DC selector
Oct 21, 2023
9974b22
Hook up remaining selectors
Oct 23, 2023
aad2e9f
Fix settings and tutorial links
Oct 23, 2023
62b6309
Remove comments
Oct 23, 2023
7abb5f9
Remove skip-links
Oct 23, 2023
48b4cb1
Replace auth with new dropdown
Oct 23, 2023
7bcc131
Use href-to helper for sidenav links
Oct 23, 2023
d1c6f00
Changelog
Oct 23, 2023
0b10672
Add description to NavSelector
Oct 23, 2023
ee0c342
Wrap version in footer and role
Oct 23, 2023
c0d5bd7
Fix login tests
Oct 24, 2023
3dad02d
Add data-test selectors for namespaces
Oct 24, 2023
462f11d
Fix datacenter disclosure menu test
Oct 24, 2023
4f9a509
Stop rendering auth dialog if acls are disabled
Oct 24, 2023
47d53a8
Update disabled selector state and token selector
Oct 24, 2023
246faa2
Fix logic in ACL selector
Oct 24, 2023
689d177
Fix HCP Home integration test
Oct 24, 2023
62047f4
Remove toggling the sidenav in tests
Oct 25, 2023
89809e9
Add sidenav to eng docs
Oct 25, 2023
a0c58e9
Re-add debug navigation for eng docs
Oct 25, 2023
745db65
Remove ember-in-viewport
Oct 26, 2023
b50c0bd
Remove unused styles
Oct 26, 2023
a7fad0b
Upgrade @hashicorp/design-system-componentseee
Oct 27, 2023
a7da001
Add translations for side-nav
Oct 27, 2023
2059f85
Only show back to hcp link if url is present
Oct 31, 2023
0b1aab5
Disable responsive due to a11y-dialog issue
Nov 6, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .changelog/19342.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:improvement
Replaces UI Side Nav with Helios Design System Side Nav. Adds dc/partition/namespace searching in Side Nav.
```
128 changes: 50 additions & 78 deletions ui/packages/consul-acls/app/components/consul/acl/selector/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -3,82 +3,54 @@
SPDX-License-Identifier: BUSL-1.1
}}

<li
class="acls-separator"
role="separator"
>
Access Controls
{{#if (not (can "use acls"))}}
<span
{{tooltip "ACLs are not currently enabled in this cluster"}}
></span>
{{/if}}
</li>
<li
data-test-main-nav-tokens
class={{if (is-href 'dc.acls.tokens' @dc.Name) 'is-active'}}
>
<a
href={{href-to 'dc.acls.tokens' @dc.Name}}
>
Tokens
</a>
</li>
{{#if (can "read acls")}}
<li
data-test-main-nav-policies
class={{if (is-href 'dc.acls.policies' @dc.Name) 'is-active'}}
>
<a
href={{href-to 'dc.acls.policies' @dc.Name}}
>
Policies
</a>
</li>
<li
data-test-main-nav-roles
class={{if (is-href 'dc.acls.roles' @dc.Name) 'is-active'}}
>
<a
href={{href-to 'dc.acls.roles' @dc.Name}}
>
Roles
</a>
</li>
<li
data-test-main-nav-auth-methods
class={{if (is-href 'dc.acls.auth-methods' @dc.Name) 'is-active'}}
>
<a
href={{href-to 'dc.acls.auth-methods' @dc.Name}}
>
Auth Methods
</a>
</li>
{{else if (not (can "use acls"))}}
<li
data-test-main-nav-policies
class={{if (is-href 'dc.acls.policies' @dc.Name) 'is-active'}}
>
<span>
Policies
</span>
</li>
<li
data-test-main-nav-roles
class={{if (is-href 'dc.acls.roles' @dc.Name) 'is-active'}}
>
<span>
Roles
</span>
</li>
<li
data-test-main-nav-auth-methods
class={{if (is-href 'dc.acls.auth-methods' @dc.Name) 'is-active'}}
>
<span>
Auth Methods
</span>
</li>
{{/if}}
{{#let @list as |SNL|}}
{{#if (can "use acls")}}
<SNL.Title>{{t "components.hashicorp-consul.side-nav.acls.title"}}</SNL.Title>
{{else}}
<SNL.Title {{tooltip (t "components.hashicorp-consul.side-nav.acls.tooltip")}}>
{{t "components.hashicorp-consul.side-nav.acls.title"}}
</SNL.Title>
{{/if}}

<SNL.Link
@text={{t "components.hashicorp-consul.side-nav.acls.tokens"}}
@href={{href-to "dc.acls.tokens" @dc.Name}}
@isHrefExternal={{false}}
@isActive={{is-href "dc.acls.tokens" @dc.Name}}
data-test-main-nav-tokens
/>

{{#if (can "read acls")}}
<SNL.Link
@text={{t "components.hashicorp-consul.side-nav.acls.policies"}}
@href={{href-to "dc.acls.policies" @dc.Name}}
@isHrefExternal={{false}}
@isActive={{is-href "dc.acls.policies" @dc.Name}}
data-test-main-nav-policies
/>
<SNL.Link
@text={{t "components.hashicorp-consul.side-nav.acls.roles"}}
@href={{href-to "dc.acls.roles" @dc.Name}}
@isHrefExternal={{false}}
@isActive={{is-href "dc.acls.roles" @dc.Name}}
data-test-main-nav-roles
/>
<SNL.Link
@text={{t "components.hashicorp-consul.side-nav.acls.auth-methods"}}
@href={{href-to "dc.acls.auth-methods" @dc.Name}}
@isHrefExternal={{false}}
@isActive={{is-href "dc.acls.auth-methods" @dc.Name}}
data-test-main-nav-auth-methods
/>
{{else if (not (can "use acls"))}}
<SNL.Item class="consul-disabled-nav" data-test-main-nav-policies>
{{t "components.hashicorp-consul.side-nav.acls.policies"}}
</SNL.Item>
<SNL.Item class="consul-disabled-nav" data-test-main-nav-roles>
{{t "components.hashicorp-consul.side-nav.acls.roles"}}
</SNL.Item>
<SNL.Item class="consul-disabled-nav" data-test-main-nav-auth-methods>
{{t "components.hashicorp-consul.side-nav.acls.auth-methods"}}
</SNL.Item>
{{/if}}
{{/let}}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

A self-contained component to allow the user to 'select' their token a.k.a.
log in. The component is mostly a wrapper around a composition of `<AuthDialog
/>`, `<AuthForm />`, `<AuthProfile />` and `<ModalDialog />`. The majority of
/>`, `<AuthForm />`, and `<ModalDialog />`. The majority of
the functionality is contained in those other components. This composition
mostly orchestrates the interactions between them i.e. wires them together.

Expand Down
Loading
Loading