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

MediaQuery class does not work with not all ... or multiple conditions #14695

Closed
jjones315 opened this issue Dec 12, 2024 · 0 comments · Fixed by #14699
Closed

MediaQuery class does not work with not all ... or multiple conditions #14695

jjones315 opened this issue Dec 12, 2024 · 0 comments · Fixed by #14699

Comments

@jjones315
Copy link

Describe the bug

The new svelte MediaQuery class from svelte/reactivity does not work with media queries with not all or multiple conditions.
For example not all and (min-width: 900px) and (max-width: 599px), (min-width: 900px) are both not working as intended, it appears thats since MediaQuery always wraps the query in parentheses it breaks some queries.

Reproduction

https://svelte.dev/playground/ec93d95e0c63434d9ba67439e4afe011?version=5.11.2

Logs

N/A

System Info

System:
    OS: Linux 5.15 Ubuntu 22.04.3 LTS 22.04.3 LTS (Jammy Jellyfish)
    CPU: (32) x64 13th Gen Intel(R) Core(TM) i9-13900
    Memory: 13.60 GB / 15.47 GB
    Container: Yes
    Shell: 5.1.16 - /bin/bash
  Binaries:
    Node: 20.18.0 - ~/.nvm/versions/node/v20.18.0/bin/node
    npm: 10.8.2 - ~/.nvm/versions/node/v20.18.0/bin/npm
    pnpm: 9.7.1 - /mnt/c/Users/jjones/AppData/Roaming/npm/pnpm
    bun: 1.1.15 - /mnt/c/Users/jjones/AppData/Roaming/npm/bun

Severity

annoyance

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 a pull request may close this issue.

1 participant