Getting Started
To install the TORCH Glare Components Library manually, follow these steps.
Docs
{
"path": "./src" // the path where you want to install the components
}
npm install glare-typography@latest mapping-color-system@latest glare-torch-mode@latest
npm install tailwindcss-animate tailwind-scrollbar-hide
const { plugin: plugin, mappingVars } = require('mapping-color-system')
module.exports = {
content: [
...
// put your path that your use in glare.json file. for example:
"./src/**/*.{js,ts,jsx,tsx,mdx}",
],
theme: {
extend: {
colors: mappingVars,
},
},
plugins: [
plugin,
require('tailwindcss-animate'),
require('tailwind-scrollbar-hide'),
require('glare-typography'),
require('glare-torch-mode'),
function ({ addVariant }: any) {
addVariant("rtl", '&[dir="rtl"]');
addVariant("ltr", '&[dir="ltr"]');
},
],
};
<head>
<link
href="https://cdn.jsdelivr.net/npm/[email protected]/fonts/remixicon.css"
rel="stylesheet"
/>
<link
rel="stylesheet"
href="https://cdn.statically.io/gh/TORCH-Corp/SF-PRO-FONT/main/font/fonts.css"
/>
<link
rel="preload"
href="https://cdn.statically.io/gh/TORCH-Corp/SF-PRO-FONT/main/font/SF-Pro.woff2"
as="font"
type="font/woff2"
/>
</head>
npx torch-glare@latest add
npx torch-glare@latest add Button
import { Button } from "./Button";
function App() {
return (
<Button variant="PrimeStyle" size="M">
Click Me
</Button>
);
}
rm -rf node_modules package-lock.json