Skip to content

Add Workspace switcher to Referrals page#1464

Merged
gigxz merged 27 commits into
mainfrom
gig/8937-hmis-workspaces
May 19, 2026
Merged

Add Workspace switcher to Referrals page#1464
gigxz merged 27 commits into
mainfrom
gig/8937-hmis-workspaces

Conversation

@gigxz

@gigxz gigxz commented May 8, 2026

Copy link
Copy Markdown
Collaborator

Description

Issue: https://github.com/open-path/Green-River/issues/9204
Depends on Backend PR: greenriver/hmis-warehouse#6455
Opened against #1456 because it depends on referral refactor

  • If workspaces are configured for referrals, render a "workspace switcher" that supports filtering all tabs by a project group.
  • If no workspaces are configured, there is no change to the UI
  • Components WorkspaceSelect and useWorkspaceSelector are implemented generically (not CE-specific) so they can be re-used if we introduce workspace switchers elsewhere, such as the User Dashboard.

See issue for how to test

Screenshot 2026-05-08 at 3 24 59 PM

Type of change

New feature

Checklist before requesting review

  • I have performed a self-review of my code
  • I have run the code that is being changed under ideal conditions, and it doesn't fail
  • I have used Axe DevTools to scan for accessibility issues (or not applicable)
  • My code includes comments and/or descriptive variable names to help other engineers understand the intent (or not applicable)
  • I have updated the documentation (or not applicable)
  • If it's not obvious how to test this change, I have provided testing instructions in this PR or the related issue

@gigxz gigxz requested a review from martha May 8, 2026 19:28
@gigxz gigxz marked this pull request as draft May 8, 2026 19:28
Base automatically changed from mke/9157-referral-refactor to release-213 May 13, 2026 20:54
@gigxz gigxz marked this pull request as ready for review May 13, 2026 21:42

@martha martha left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good to me. I don't think any of my comments are blocking. Thanks @gigxz ! Speedy work! 🚄

Comment thread src/modules/ce/components/ReferralsPage.tsx Outdated
Comment thread src/modules/ce/components/ReferralsPage.tsx Outdated
Comment thread src/components/elements/input/WorkspaceSelect.tsx Outdated
Comment thread src/modules/ce/components/ReferralsPage.tsx Outdated
Comment on lines +50 to +71
sx={{
minWidth: 240,
'& .MuiInputBase-input': { fontWeight: 600, color: 'primary.dark' },
}}
textInputProps={{
InputProps: {
startAdornment: (
<InputAdornment
position='start'
aria-hidden='true'
sx={{ ml: 1, mr: 0 }}
>
<Box
component='span'
sx={{
width: 12,
height: 12,
borderRadius: '50%',
bgcolor: 'primary.main',
}}
/>
</InputAdornment>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I have a couple concerns about the dot + main color on the select component. I started typing up a comment here, but then decided I'll put my design comments in a thread over in Figma, for better separation of concerns :) Figma thread

Code-wise, if we do end up choosing to establish this pattern as part of our design language, I would prefer to put the custom styling in a thin presentational wrapper around GenericSelect. We could call it something like AccentedSelect, PrimaryColorSelect, BrandedSelect, etc. The dot and custom color could live there, and the component would pass the rest of its props down directly to the GenericSelect it renders.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I believe the purpose is probably to bring some visual attention to the context switcher on the page and differentiate it from other "input"-type selectors.
Looks like your question is still open in Figma. For now, I just moved the adornment into its own component (within the same file) and added a note saying we can pull it out to another component or variant for re-use when needed.

Even if designs change, I think it'll be non-blocking for merge because nobody will see this functionality yet (not until we add any Workspace records)

@gigxz gigxz changed the base branch from release-213 to main May 19, 2026 16:21
@gigxz gigxz merged commit e154efb into main May 19, 2026
4 checks passed
@gigxz gigxz deleted the gig/8937-hmis-workspaces branch May 19, 2026 18:03
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