Theme Toggle
Optional component offering ability to dynamically toggle between themes
Description
The Theme Toggle component can be rendered by passing the toggle
prop to the Svelvet component. By default, this will toggle between light and dark themes. For additional customization, import the component and pass the entire thing as a child of Svelvet. As of version 10 update, a save button was added to the Theme Toggle component. This button saves the state of the canvas as a JSON string to local storage and reconstructs the graph based on this data.
A string associated with a custom theme created using a :root[svelvet-theme="theme-name"]
CSS
selector. Svelvet reserves light
and dark
.
A string associated with a custom theme created using a :root[svelvet-theme="theme-name"]
CSS
selector. Svelvet reserves light
and dark
.
Enum controlling corner positioning of button element.
Color of background.
Color of icon.