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

fixedWidth breakpoints not working #1306

Open
2 tasks done
fengnan1002 opened this issue May 12, 2024 · 1 comment
Open
2 tasks done

fixedWidth breakpoints not working #1306

fengnan1002 opened this issue May 12, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@fengnan1002
Copy link

Checks

Version

4.1.4

Description

I want to have 83% fixedWidth for mobile only. So I added 100% fixedWidth through breakpoints but still 83% of width and mobile padding is keep applying.

Reproduction Link

No response

Steps to Reproduce

image

{
    "drag": true,
    "flickPower": 200,
    "flickMaxPages": 1,
    "mediaQuery": "min",
    "speed": 300,
    "start": 1,
    "type": "loop",
    "fixedWidth": "83%",
    "gap": "var(--spacing-xs)",
    "padding": {
        "left": "var(--layout-margin)",
        "right": "var(--layout-margin)"
    },
    "arrows": false,
    "destroy": false,
    "pagination": true,
    "breakpoints": {
        "1024": {
            "fixedWidth": '100%',
            "gap": 0,
            "padding": 0,
            "perMove": 1,
            "perPage": 1,
            "arrows": true,
            "destroy": false,
            "pagination": true
        }
    }
}

Expected Behaviour

Is it possible to updated fixedWidth on desktop using breakpoints?

@fengnan1002 fengnan1002 added the bug Something isn't working label May 12, 2024
@squidiw
Copy link

squidiw commented Jul 26, 2024

Using breakpoints without mediaQuery: 'min', use max-width for the breakpoints. So add mediaQuery: 'min', and then add your breakpoints and I believe it should work.

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