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

next: Dialog opens once and once closed, does not open again #770

Closed
JYLN opened this issue Oct 16, 2024 · 2 comments
Closed

next: Dialog opens once and once closed, does not open again #770

JYLN opened this issue Oct 16, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@JYLN
Copy link

JYLN commented Oct 16, 2024

Describe the bug

The issue I'm noticing is I'm trying to build out a dialog, however, with the latest next version, the Dialog opens once. Once it opens, and it responds to close, the Dialog won't open again and the Trigger won't respond to cursor or click events to open the Dialog again.

I'm not sure if this is related to #755, but wanted to open this in-case it's a different issue. I don't have enough knowledge navigating the new Svelte 5 states as I've tried tracking down the potential issue and haven't come up with anything to open a pull request with

Reproduction

https://stackblitz.com/edit/stackblitz-starters-js8g1a?file=src%2Froutes%2F%2Bpage.svelte

Logs

N/A

System Info

System:
    OS: Linux 5.0 undefined
    CPU: (8) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
    Memory: 0 Bytes / 0 Bytes
    Shell: 1.0 - /bin/jsh
  Binaries:
    Node: 18.20.3 - /usr/local/bin/node
    Yarn: 1.22.19 - /usr/local/bin/yarn
    npm: 10.2.3 - /usr/local/bin/npm
    pnpm: 8.15.6 - /usr/local/bin/pnpm
  npmPackages:
    @sveltejs/kit: ^2.0.0 => 2.7.1 
    bits-ui: ^1.0.0-next.17 => 1.0.0-next.17 
    svelte: ^5.0.0-next.1 => 5.0.0-next.268

Severity

annoyance

@huntabyte
Copy link
Owner

This is interesting. I can, in fact, reproduce the behavior in the Stackblitz, but I am unable to reproduce it in the Bits docs site/elsewhere (like https://next.shadcn-svelte.com/docs/components/dialog).

I see what the issue is though. It's not properly restoring the <body> styles. I'll look into this one because it's definitely strange.

@huntabyte huntabyte added bug Something isn't working next labels Oct 16, 2024
@huntabyte
Copy link
Owner

Fixed in bits-ui@next

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants