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

Improve Popover API #1013

Merged
merged 13 commits into from
Jul 5, 2021
Merged

Improve Popover API #1013

merged 13 commits into from
Jul 5, 2021

Conversation

amelako
Copy link
Contributor

@amelako amelako commented Jul 1, 2021

Addresses #723.

Purpose

Some improvements for the Popover API and accessibility.

Approach and changes

Remove ref from trigger component in the Popover
Move the isOpen state outside of component
Add aria-expanded prop to trigger component
Add modifiers prop for custom Popper modifier support

Definition of done

  • Development completed
  • Reviewers assigned
  • Unit and integration tests
  • Meets minimum browser support
  • Meets accessibility requirements

@amelako amelako requested a review from a team as a code owner July 1, 2021 13:19
@amelako amelako requested review from connor-baer and removed request for a team July 1, 2021 13:19
@sumup-clark
Copy link

sumup-clark bot commented Jul 1, 2021

Hey @amelako,
we are super excited that you are contributing! 🎉There's one more thing you need to do. Please accept our Contributor License Agreement. It helps you and us to collaborate on clear terms and focus on what we love most: code.

Thanks!

@changeset-bot
Copy link

changeset-bot bot commented Jul 1, 2021

🦋 Changeset detected

Latest commit: a3964db

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@sumup/circuit-ui Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel
Copy link

vercel bot commented Jul 1, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/sumup/oss-circuit-ui/HW82PbFKt2BXXWFi6nbstiKZUVP9
✅ Preview: https://oss-circuit-ui-git-popover-fix-sumup.vercel.app

@codecov
Copy link

codecov bot commented Jul 1, 2021

Codecov Report

Merging #1013 (a3964db) into next (e76f2d0) will decrease coverage by 0.02%.
The diff coverage is 94.73%.

Impacted file tree graph

@@            Coverage Diff             @@
##             next    #1013      +/-   ##
==========================================
- Coverage   91.05%   91.03%   -0.03%     
==========================================
  Files         161      161              
  Lines        2684     2689       +5     
  Branches      794      798       +4     
==========================================
+ Hits         2444     2448       +4     
- Misses        214      215       +1     
  Partials       26       26              
Impacted Files Coverage Δ
packages/circuit-ui/components/Popover/Popover.tsx 96.87% <94.73%> (-1.44%) ⬇️

@connor-baer connor-baer linked an issue Jul 1, 2021 that may be closed by this pull request
Copy link
Member

@connor-baer connor-baer left a comment

Choose a reason for hiding this comment

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

I like how the tests are simpler now ✨

Let's address two more things in this PR:

  • Adding transitions for the bottom sheet on mobile
  • Adding support for custom Popper modifiers

packages/circuit-ui/components/Popover/Popover.stories.tsx Outdated Show resolved Hide resolved
packages/circuit-ui/components/Popover/Popover.tsx Outdated Show resolved Hide resolved
packages/circuit-ui/components/Popover/Popover.tsx Outdated Show resolved Hide resolved
@connor-baer connor-baer enabled auto-merge (squash) July 5, 2021 07:41
@connor-baer connor-baer disabled auto-merge July 5, 2021 07:41
@amelako amelako merged commit d5e528b into next Jul 5, 2021
@amelako amelako deleted the popover-fix branch July 5, 2021 10:16
@github-actions github-actions bot mentioned this pull request Jul 5, 2021
This was referenced Aug 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add popover menu component
2 participants