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

Clean up contributor audio user experience #418

Merged
merged 7 commits into from
May 7, 2024
Merged

Conversation

CharlieMcVicker
Copy link
Collaborator

Based on external feedback the audio contribution experience has been changed to:

  • Feature a more typical and eye-catching "Record" button
  • Separate file-uploading and recording functionality ("Upload audio" and "Record audio" are now separate parts of the panel)

Old:
Bildschirmfoto 2024-04-25 um 5 10 34 PM

New:
Bildschirmfoto 2024-04-25 um 5 08 33 PM

Copy link

netlify bot commented Apr 25, 2024

Deploy Preview for dailp ready!

Name Link
🔨 Latest commit e6f2dc2
🔍 Latest deploy log https://app.netlify.com/sites/dailp/deploys/66310ef5a658450008e848e8
😎 Deploy Preview https://deploy-preview-418--dailp.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Comment on lines +324 to 333
export const useCognitoUserGroups = (): UserGroup[] => {
const { user } = useContext(UserContext)
const groups: string[] =
user?.getSignInUserSession()?.getIdToken().payload["cognito:groups"] ?? []
return groups
.map((g) => g.toUpperCase())
.filter((g): g is UserGroup =>
Object.values(UserGroup).includes(g as UserGroup)
)
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We have a type for this so I decided we should up cast. Thoughts?

disabled={!(userRole == UserRole.EDITOR)}
disabled={!(userRole == UserRole.Editor)}
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Maybe this should be userGroups.includes(Dailp.UserGroup.Editors)

@GracefulLemming GracefulLemming merged commit 29f10f5 into main May 7, 2024
5 checks passed
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