Skip to content

[Feature]: Popover component #14

Closed

Description

@cschmatzler

Prerequisites

  • I have searched existing issues to ensure this feature hasn't been requested already
  • I have checked the documentation to confirm this feature doesn't exist
  • This feature aligns with the project's goals and would benefit the community

Feature type

New Component

Component name

Popover

Feature description

This, but styled in a way that fits the rest of the design system: https://react-spectrum.adobe.com/react-aria/Popover.html

Problem statement

Building a data filter that needs a popover triggered by a button.

Proposed solution

No response

Proposed API design

<Popover
    open={open}
    onOpenChange={async value => {
      setOpen(value);
      if (!value) setTimeout(() => setProperty(undefined), 100);
    }}
  >
    <PopoverTrigger asChild>
      <Button variant="outline" className={cx("h-7", hasFilters && "w-fit !px-2")}>
        <FunnelIcon className="size-4" />
        {!hasFilters && <span>{t("Filter")}</span>}
      </Button>
    </PopoverTrigger>
    <PopoverContent align="start" side="bottom" className="w-fit p-0">
      {content}
    </PopoverContent>
  </Popover>

Use cases

No response

Alternatives considered

No response

Examples from other libraries

https://ui.shadcn.com/docs/components/popover

Priority level

Medium - Would improve my workflow

Requirements

  • Must be accessible (WCAG 2.1 AA compliant)
  • Must be responsive (mobile-first)
  • Must follow existing design patterns
  • Must be TypeScript compatible
  • Must work with keyboard navigation
  • Must work with screen readers
  • Must have comprehensive documentation
  • Must include Storybook stories

Contribution

  • I'm willing to implement this feature
  • I'm willing to help with design/specification
  • I'm willing to help with testing
  • I'm willing to help with documentation

Activity

  1. deebov commented on Jul 17, 2025

    @deebov
    Contributor

    Hey @cschmatzler, thanks for the idea. We already have a popover component as part of the select component. Does this answer your question?

  2. cschmatzler commented on Jul 17, 2025

    @cschmatzler
    Author

    Ah, great! I'd definitely surface it in the documentation as its own component, since I've been searching for it outside of Select.
    Thanks for the quick reply!

  3. deebov commented on Jul 17, 2025

    @deebov
    Contributor

    Thanks for the suggestion! I'll look if we can make a generic popover component that can be re-used in other places.

  4. locked and limited conversation to collaborators on Jul 17, 2025
  5. converted this issue into a discussion #15 on Jul 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions