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

Refactor component styling API for extension components #210

Merged
merged 3 commits into from
Oct 28, 2023

Conversation

devkanro
Copy link
Collaborator

This PR improves the theme's ComponentStyling API and provides a more usable and easy-to-understand pattern for extending controls.

Before:

IntUiTheme(
    themeDefinition,
    componentStyling = {
        themeDefinition.decoratedWindowComponentStyling() + themeDefinition.extensionComponentStyling() + themeDefinition.extensionComponent2Styling() + themeDefinition.extensionComponent3Styling()
    }
) {
    Box {}
}

After:

IntUiTheme(
    themeDefinition,
    componentStyling = {
        provideDecoratedWindowComponentStyling()
        provideExtensionComponentStyling()
        provideExtensionComponent2Styling()
        provideExtensionComponent3Styling()
    }
) {
    Box {}
}

@devkanro devkanro requested a review from rock3r October 27, 2023 14:56
@devkanro devkanro merged commit 8ee3402 into JetBrains:main Oct 28, 2023
6 checks passed
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 this pull request may close these issues.

2 participants