Replies: 2 comments
-
|
@segunadebayo Anything i can do here? |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
You can do this today with export default defineConfig({
preflight: true,
globalCss: {
'ul, ol': { listStyle: 'revert' },
'*, *::before, *::after': { borderColor: 'gray.200' },
},
})For more control, you can use the export default defineConfig({
preflight: true,
hooks: {
'config:resolved': ({ config }) => {
config.globalCss = {
...config.globalCss,
'ul, ol': { listStyle: 'revert' },
}
return config
},
},
})Both approaches keep preflight enabled so you get upstream updates, while only changing the parts you need. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Description
Please add the ability to override, extend, or exclude specific styles within the
preflightconfiguration option inpanda.config.ts, rather than it being limited to a boolean or scope configuration.Problem Statement/Justification
Currently, the
preflightoption is effectively "all-or-nothing." While it supports scoping, it does not allow granular control over the generated reset styles.Proposed Solution or API
If a developer needs to modify the default preflight (e.g., to preserve default list styles, change the default border color, or opt-out of specific element resets), the current workflows are suboptimal:
preflight: falseand manually copy/paste the entire Panda reset into globalCss just to change a few lines. This creates a maintenance burden as the project no longer benefits from upstream updates to Panda's preflight.Introducing a configuration API such as
preflight: { extend: { ... } }orpreflight: { exclude: [...] }would allow for a cleaner, type-safe, and more maintainable way to handle base style customizations directly within the Panda configuration ecosystem.Alternatives
No response
Additional Information
No response
Beta Was this translation helpful? Give feedback.
All reactions