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

Highlight active link in nav bar #2324

Merged
merged 3 commits into from
Sep 12, 2024

Conversation

laurakwhit
Copy link
Contributor

Description & motivation 💭

Indicates the active navigation link in the sidebar with the same style as on hover.

Screenshots (if applicable) 📸

Screenshot 2024-09-12 at 11 10 13 AM Screenshot 2024-09-12 at 11 10 36 AM

Design Considerations 🎨

Testing 🧪

How was this tested 👻

  • Manual testing
  • E2E tests added
  • Unit tests added

Steps for others to test: 🚶🏽‍♂️🚶🏽‍♀️

Checklists

Draft Checklist

Merge Checklist

Issue(s) closed

DT-2429

Docs

Any docs updates needed?

@laurakwhit laurakwhit requested review from rossedfort and a team as code owners September 12, 2024 18:11
Copy link

vercel bot commented Sep 12, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
holocene ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 12, 2024 7:02pm

@@ -29,7 +32,8 @@
aria-disabled={disabled}
class:disabled
tabindex={disabled ? -1 : 0}
class="mb-1 flex items-center whitespace-nowrap rounded-lg p-1 pl-2 text-sm font-medium hover:bg-white hover:text-black group-[.surface-primary]:hover:bg-black group-[.surface-primary]:hover:text-white group-[.surface-primary]:dark:hover:bg-white group-[.surface-primary]:dark:hover:text-black"
class:active={isActive($page.url.href)}
Copy link
Contributor

Choose a reason for hiding this comment

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

Get a lot of errors for this lil guy

Copy link
Contributor

Choose a reason for hiding this comment

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

Whenever you change namespace in namespace switcher it errors and crashes UI

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added a fix. Looks like isActive was still undefined despite setting () => false as the default initial value 🤔

@laurakwhit laurakwhit marked this pull request as draft September 12, 2024 18:30
@laurakwhit laurakwhit changed the base branch from main to codefreeze-09.12.24 September 12, 2024 21:33
@laurakwhit laurakwhit merged commit bd34e6e into codefreeze-09.12.24 Sep 12, 2024
14 checks passed
@laurakwhit laurakwhit deleted the highlight-active-link-in-nav-bar branch September 12, 2024 21:53
Alex-Tideman added a commit that referenced this pull request Sep 24, 2024
* Accordion component updates (#2316)

* Fix styling for non-expandable Accordion

* Update padding on Card to match Accordion

* Add AccordionGroup

* Make ring inset on focus-within

* Fix imports and A11y warning

* Highlight active link in nav bar (#2324)

* Add active styling for nav item

* Add isActive check for nav links

* Account for if isActive is undefined

* Add http api port and async update flag (#2314)

* Show all possible failures for WorkflowTaskError (#2328)

* Use AccordionGroup to show all possible failures

* Dont use red text

* Move source to accordion

* Add pending task component and move into accordion group

* Fixes from Laura's review

* Bump express from 4.19.2 to 4.20.0 (#2323)

Bumps [express](https://github.com/expressjs/express) from 4.19.2 to 4.20.0.
- [Release notes](https://github.com/expressjs/express/releases)
- [Changelog](https://github.com/expressjs/express/blob/master/History.md)
- [Commits](expressjs/express@4.19.2...4.20.0)

---
updated-dependencies:
- dependency-name: express
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump vite from 5.0.13 to 5.2.14 (#2329)

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.0.13 to 5.2.14.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.2.14/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.2.14/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Update go to 1.22.6 (#2334)

* Update go to 1.23

* Use 1.22.6

* Remove work files

* Add go.work to gitignore

* Remove Start Workflow input preview, add error alert for invalid input (#2338)

* Remove preview codeblock, add error for invalid json

* Remove console

* Translate

* Update Label spacing (#2336)

* Update Combobox Label spacing to match Select

* Update Label spacing on Holocene components to match Select and Input

* Update Label spacing on custom components

---------

Co-authored-by: Alex Tideman <[email protected]>

* Add env var to disable workflow count refresh (#2312)

* Event Type multiselect dropdown with All/None options (#2339)

* Move event type filters into a multiselect dropdown

* Set smaller width on mobile

* Add some padding to json view and don't include status filter

* Update snapshots

* Remove unused code

* Remove camelcase

* Fix typo

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: Laura Whitaker <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants