Skip to content

Conversation

beagins
Copy link
Contributor

@beagins beagins commented May 1, 2025

🥁 Drumroll: merging to main

Description

  • Updates to the Namespace Picker:
    • Implement using Hds::Dropdown component
    • Support search across namespaces
    • Support navigate to namespace on Enter
    • Action buttons to refresh & manage namespaces (if user has appropriate capabilities)
    • Implemented frontend infinite scroll to handle many namespaces
    • Update component from js to ts
    • Handle errors and edge cases
    • Test coverage
  • Enterprise tests are passing ✅

    248 tests completed in 161597 milliseconds, with 0 failed, 10 skipped, and 0 todo.
    1468 assertions of 1468 passed, 0 failed.

Screenshot 2025-05-01 at 3 30 24 PM Screenshot 2025-05-01 at 3 30 38 PM Screenshot 2025-05-01 at 3 30 51 PM Screenshot 2025-05-01 at 3 31 33 PM

TODO only if you're a HashiCorp employee

  • Backport Labels: If this fix needs to be backported, use the appropriate backport/ label that matches the desired release branch. Note that in the CE repo, the latest release branch will look like backport/x.x.x, but older release branches will be backport/ent/x.x.x+ent.
    • LTS: If this fixes a critical security vulnerability or severity 1 bug, it will also need to be backported to the current LTS versions of Vault. To ensure this, use all available enterprise labels.
  • ENT Breakage: If this PR either 1) removes a public function OR 2) changes the signature
    of a public function, even if that change is in a CE file, double check that
    applying the patch for this PR to the ENT repo and running tests doesn't
    break any tests. Sometimes ENT only tests rely on public functions in CE
    files.
  • Jira: If this change has an associated Jira, it's referenced either
    in the PR description, commit message, or branch name.
  • RFC: If this change has an associated RFC, please link it in the description.
  • ENT PR: If this change has an associated ENT PR, please link it in the
    description. Also, make sure the changelog is in this PR, not in your ENT PR.

@github-actions github-actions bot added the hashicorp-contributed-pr If the PR is HashiCorp (i.e. not-community) contributed label May 1, 2025
@beagins beagins changed the title Vault 34216/namespace picker feature branch [VAULT-34216] UI: Namespace picker feature branch May 1, 2025
@beagins beagins added the ui label May 1, 2025
@beagins beagins added this to the 1.20.0-rc milestone May 1, 2025
Copy link

github-actions bot commented May 1, 2025

CI Results:
All Go tests succeeded! ✅

@beagins beagins force-pushed the VAULT-34216/namespace-picker-feature-branch branch from 793e82f to b401229 Compare May 1, 2025 23:47
@beagins beagins marked this pull request as ready for review May 1, 2025 23:53
@beagins beagins requested review from a team as code owners May 1, 2025 23:53
@beagins beagins requested a review from kpcraig May 1, 2025 23:53
Copy link

github-actions bot commented May 1, 2025

Build Results:
All builds succeeded! ✅

UP = 'ArrowUp',
RIGHT = 'ArrowRight',
DOWN = 'ArrowDown',
T = 'F5',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does T map to F5?

Copy link
Contributor Author

@beagins beagins May 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a good question!! I was replacing these keys one-for-one from key-codes.js. In the deprecated key-codes file, the T key is mapped to key code 116, which is F5. But I'm not sure why they used T instead of F5 as the key. It looks like there are currently no references to the T key-code... so I've just pushed a commit to removed all unused key code props. Thanks for catching this Lane!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good! I wasn't sure where these were all from, and that once seemed a little opaque, so good follow-up!

lane-wetmore
lane-wetmore previously approved these changes May 2, 2025
DOWN: 40,
T: 116,
BACKSPACE: 8,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗒️ Note: removing unused key codes

lane-wetmore
lane-wetmore previously approved these changes May 2, 2025
beagins and others added 11 commits May 5, 2025 10:51
…ponent (#30068)

* [VAULT-34482] UI: Update Namespace Picker to use HDS Super Select component

* changelog updates

* update jsdoc

* update classname

* update test comment

* remove unnecessary label attribute

* move hbs file to components directory alongside js file

* fix replication test

* undo changes to replication test

* test update
…pace count label (#30183)

* [VAULT-35046] Show namespace count label; use Hds::Dropdown instead of Hds::Superselect

* address misc pr comments

* update tests

* address PR comment

* Update ui/app/components/namespace-picker.hbs

Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>

* Update ui/app/components/namespace-picker.hbs

Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>

* address PR comments: update tests

* use getter for namespace label

---------

Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
…30433)

* [VAULT-34483] UI: implement front-end pagination via infinite scroll

* remove unnecessary height definition

* fix test: Integration | Component | sidebar-frame: it should render namespace picker in sidebar footer

* update comment

* move visibleNamespaceOptions into a getter so that it updates when search input is cleared

* handle edge case: display current namespace when no other namespaces listed
* [VAULT-35780] address TODOs

* wrap manage & refresh buttons in Hds::ButtonSet

* fix failing integration tests

* remove unnecessary import mirage

* fix undefined

* fix flaky tests

* styling updates

* don't show search help text when there are no namespaces matching the search criteria
@beagins beagins force-pushed the VAULT-34216/namespace-picker-feature-branch branch from 0c7ed48 to 5606b59 Compare May 5, 2025 18:26
@beagins beagins merged commit fe9f18b into main May 5, 2025
33 checks passed
@beagins beagins deleted the VAULT-34216/namespace-picker-feature-branch branch May 5, 2025 23:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hashicorp-contributed-pr If the PR is HashiCorp (i.e. not-community) contributed ui
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants