You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 7, 2024. It is now read-only.
<ThemePreviewheading="Light scheme with success theme for content and positive for primary button and content"scheme="light"theme="success"themeControls="positive" />
62
67
<ThemePreviewheading="Dark scheme with success theme for content and positive for primary button and content"scheme="dark"theme="success"themeControls="positive" />
@@ -70,82 +75,49 @@ To generate class names responsible for changin color theme use `toSchemeClass(c
70
75
<ThemePreviewheading="Dark scheme with danger themed primary button on primary themed content"scheme="dark"theme="primary"themeControls="danger"controls />
71
76
<ThemePreviewheading="System scheme with danger themed primary button on primary themed content"scheme="system"theme="primary"themeControls="danger"controls />
72
77
</Stack>
78
+
</StyleProvider>
73
79
74
-
## Theming the Layout
80
+
## Theming interface
75
81
76
-
With `Layout` component you are already able to set theme and scheme on 3 main parts of your admin application:
82
+
In Contember you need to use `ColorSchemeProvider`to set the color schema for its children. The `ColorSchemeProvider` accepts `scheme` prop which can be either `light`, `dark` or `system`.
77
83
78
-
1. The whole app, including the side bar with navigation
79
-
2. Page content (applied by the `PageLayout` component)
80
-
3. Title bar of the page content (applied by the `PageLayout` component)
81
-
82
-
### Scheme props
83
-
84
-
Prop | Type | Description
85
-
--------------|----------|------------
86
-
`scheme` | [`Scheme`](#appendix-available-theme-and-scheme-values) | Sets the scheme of all layout parts
87
-
`pageScheme` | [`Scheme`](#appendix-available-theme-and-scheme-values) | Sets the page scheme of the page part of the layout
88
-
`titleScheme` | [`Scheme`](#appendix-available-theme-and-scheme-values) | Sets the scheme of the page title
89
-
90
-
### Theme props
91
-
92
-
You can fine-tune layout using only the props to target specific regions of the layout, also you can target the content of the controls independently. See the table for the list of affected regions by the props.
93
-
94
-
Prop | Type | Lyout content | Layout controls | Page content | Page controls | Page title content | Page title controls |
Content and controls theme can be set using `contentThemeClassName` and `controlsThemeClassName` helper functions. These functions accept `theme` argument which can be either `primary`, `secondary`, `tertiary`, `success`, `warn` or `danger`.
_**Note:**Internally, Contemberusesthe`*-above`schemavariantstomakecompoentsstandout (lighter) and`*-below`schemavariantstopushthemalitthetotheback (darker). Wedon't endorse nor discourage you to use these in your layouts._
0 commit comments