### Install Material Solid Packages Source: https://context7.com/deminearchiver/material-solid/llms.txt Installs the necessary packages for Material Solid components, theming, and utilities using npm, yarn, or pnpm. ```bash npm install @material-solid/components @material-solid/vanilla-extract @material-solid/utils ``` ```bash yarn add @material-solid/components @material-solid/vanilla-extract @material-solid/utils ``` ```bash pnpm install @material-solid/components @material-solid/vanilla-extract @material-solid/utils ``` -------------------------------- ### Slider Component Examples (SolidJS) Source: https://context7.com/deminearchiver/material-solid/llms.txt Provides examples of the Slider component from @material-solid/components for selecting values within a range. It shows how to set minimum/maximum values, steps, format labels, and handle value changes for different use cases like volume and brightness. ```tsx import { Slider } from "@material-solid/components"; import { createSignal } from "solid-js"; function VolumeControl() { const [volume, setVolume] = createSignal(50); const [brightness, setBrightness] = createSignal(0.7); return ( <> `${val}%`} /> { setBrightness(val); applyBrightness(val); }} valueFormatter={(val) => Math.round(val * 100)} labelFormatter={(val) => `${val}%`} /> ); } ``` -------------------------------- ### IconButton Component Examples (SolidJS) Source: https://context7.com/deminearchiver/material-solid/llms.txt Demonstrates the usage of the IconButton component from @material-solid/components with various variants (regular, filled, filledTonal, outlined) and properties like disabled, onClick, selected, and as a link. It shows how to include Material Symbols for icons. ```tsx import { IconButton } from "@material-solid/components"; // Regular icon button (no background) menu // Filled icon button console.log("favorite")}> favorite // Filled tonal with selection state {isBookmarked() ? "bookmark" : "bookmark_border"} // Outlined icon button share // Icon button as link settings ``` -------------------------------- ### Switch Component Implementation (SolidJS) Source: https://context7.com/deminearchiver/material-solid/llms.txt Illustrates the use of the Switch component from @material-solid/components for binary on/off states. It demonstrates binding to signals, handling change events, and customizing the selected/unselected icons. ```tsx import { Switch } from "@material-solid/components"; import { createSignal } from "solid-js"; function SettingsPanel() { const [darkMode, setDarkMode] = createSignal(false); const [notifications, setNotifications] = createSignal(true); return ( <> ); } ``` -------------------------------- ### MultiProvider Utility for Context Nesting (SolidJS) Source: https://context7.com/deminearchiver/material-solid/llms.txt Demonstrates the MultiProvider utility from @material-solid/utils for cleanly nesting multiple SolidJS context providers. It accepts an array of providers and their corresponding values, simplifying context management in applications. ```tsx import { MultiProvider } from "@material-solid/utils"; import { ThemeContext, AuthContext, I18nContext } from "./contexts"; function App() { return ( ); } ``` -------------------------------- ### Create Material Design Theme with Vanilla Extract Source: https://context7.com/deminearchiver/material-solid/llms.txt Generates a Material Design 3 theme from a seed color using Material Solid's theming system and Vanilla Extract. Supports dynamic color schemes and defines theme contracts for application-wide styling. ```typescript import { createMaterialTheme } from "@material-solid/vanilla-extract"; import { createTheme, style } from "@vanilla-extract/css"; const materialTheme = createMaterialTheme({ color: { seed: Hct.fromInt(0xFF6200EE), variant: "tonalSpot", contrastLevel: 0, }, typeface: { brand: ["Roboto", "sans-serif"], plain: ["Roboto", "sans-serif"], }, }); const themeContract = materialTheme.createContract(); const lightTheme = createTheme(themeContract, materialTheme.createTheme("light")); const darkTheme = createTheme(themeContract, materialTheme.createTheme("dark")); const appStyle = style({ backgroundColor: themeContract.color.surface, color: themeContract.color.onSurface, }); ``` -------------------------------- ### Material Solid Button Component Variants Source: https://context7.com/deminearchiver/material-solid/llms.txt Demonstrates the usage of Material Design 3 button components in SolidJS, showcasing five variants (elevated, filled, filledTonal, outlined, text) with options for icons, labels, and event handling. ```tsx import { Button } from "@material-solid/components"; // Elevated button with leading icon console.log("clicked")} /> // Filled button (highest emphasis) // Filled tonal button (medium emphasis) // Outlined button // Text button (lowest emphasis) // Full variant specification ); } // Ripple automatically handles: // - Touch and pointer events // - Press and release animations // - Hover states // - Focus states // - Forced colors mode ``` -------------------------------- ### Material Solid Text Field Component Source: https://context7.com/deminearchiver/material-solid/llms.txt Implements Material Design 3 text input fields in SolidJS, supporting both filled and outlined variants. Includes features like labels, placeholders, input handling, and programmatic focus control. ```tsx import { FilledTextField } from "@material-solid/components"; import { createSignal } from "solid-js"; function LoginForm() { const [email, setEmail] = createSignal(""); const [password, setPassword] = createSignal(""); let fieldRef; return ( <> setEmail(e.currentTarget.value)} onChange={(e) => console.log("Email changed:", e.currentTarget.value)} /> setPassword(e.currentTarget.value)} /> ); } ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.