We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
developper
simplify API
use theme in environment in view without the forceTheme in API
Today for Border the OUDSBorder propose init(forceTo theme: OUDSTheme? = nil, colorScheme: ColorScheme? = nil) { forcedTheme = theme forcedColorScheme = colorScheme }
to remove this init we should wrapp the OUDSBorder into the OUDSThemeableViewlike this
OUDSThemeableView(theme: theme) { OUDSBorder() }
In the test UI content:
for borderWidth in NamedBorderWidth.allCases { let illustration = OUDSThemeableView(theme: theme) { OUDSBorder().illustration(for: borderWidth) .background(self.orangeTheme.colorBgPrimary.color(for: self.lightScheme)) } let hostingVC = UIHostingController(rootView: illustration) let snapshotName = "\(theme.name)_\(scaled.rawValue)_\(interfaceStyle == .light ? "Light" : "Dark")" assertSnapshot(of: hostingVC, as: .image(traits: UITraitCollection(userInterfaceStyle: interfaceStyle)), named: snapshotName) }
No response
The text was updated successfully, but these errors were encountered:
Tayebsed93
Successfully merging a pull request may close this issue.
Prerequisites
As a
developper
... I want to
simplify API
... so that I can
use theme in environment in view without the forceTheme in API
Motivation and context
Today for Border the OUDSBorder propose
init(forceTo theme: OUDSTheme? = nil, colorScheme: ColorScheme? = nil) {
forcedTheme = theme
forcedColorScheme = colorScheme
}
to remove this init we should wrapp the OUDSBorder into the OUDSThemeableViewlike this
Proposed Solution
In the test UI content:
Other
No response
Contact Details
No response
The text was updated successfully, but these errors were encountered: