# Sosialoka Design System > Tokens, components and patterns shared by Loka Musik, Cover Clearance, Lokasign and My Loka Link. Tokens, components and patterns for Loka Musik, Cover Clearance, Lokasign and My Loka Link, in React, Vue and Flutter. Pick a product to see the whole site in its colors. - [Browse components](https://design.sosialoka.tech/components/) - [Set up a project](https://design.sosialoka.tech/web/) - [Foundations](https://design.sosialoka.tech/foundations/color/): Color, type, icons, spacing, radius, elevation and motion, all as tokens. - [Components](https://design.sosialoka.tech/components/): Controls and surfaces for React and Vue, with the Flutter code beside them. - [Patterns](https://design.sosialoka.tech/patterns/login/): Whole screens: login, dashboard, lists, forms and the states between them. ## Most used components - [Button](https://design.sosialoka.tech/components/button/): Starting an action. - [Input](https://design.sosialoka.tech/components/input/): One line of text. - [Select](https://design.sosialoka.tech/components/select/): Picking one value from a short list. - [Switch](https://design.sosialoka.tech/components/switch/): A setting that applies right away. - [Card](https://design.sosialoka.tech/components/card/): Grouping content on its own surface. - [Table](https://design.sosialoka.tech/components/table/): Records in rows and columns, with pagination. - [Dialog](https://design.sosialoka.tech/components/dialog/): A decision or a short form over the page. - [Toast](https://design.sosialoka.tech/components/toast/): Confirming an action. ## Products - **Loka Musik**: music distribution and royalties. - **Cover Clearance**: licensing for cover songs. - **Lokasign**: electronic signatures. - **My Loka Link**: link pages for music artists. Screens that belong to no product, such as internal tools or a partner's first prototype, use the [neutral theme](https://design.sosialoka.tech/add-a-product/#neutral-theme). A new product gets its own theme with [one command](https://design.sosialoka.tech/add-a-product/). ## Start building Pick your platform. Each guide installs the theme for your product and points to the components. | Platform | What you get | | --- | --- | | [Web](https://design.sosialoka.tech/web/) | React and Vue components from the Sosialoka registry, or the CSS tokens for any web app, with Tailwind v4 utilities. | | [Flutter](https://design.sosialoka.tech/flutter/) | The `sosialoka_ui` package: themes for `shadcn_ui` and Material widgets. | | [Use with AI agents](https://design.sosialoka.tech/ai-agents/) | The MCP server, llms.txt and an AGENTS.md snippet, so agents build with the system. | ## Use the patterns [Patterns](https://design.sosialoka.tech/patterns/login/) show whole screens built from the components: login, the dashboard frame, list, detail and form pages, empty, loading and error states, and the My Loka Link artist page. Login and the dashboard frame install as blocks; the rest are guides with code to copy. [Content](https://design.sosialoka.tech/content/) sets how the copy on those screens reads. ## For AI agents Every page is also available as Markdown: add `.md` to its address, or use the buttons under the page title. [/llms.txt](https://design.sosialoka.tech/llms.txt) lists every page with a one-line summary, and [/llms-full.txt](https://design.sosialoka.tech/llms-full.txt) holds the whole documentation in one file. The Indonesian versions live under `/id/`. --- # Web > Set up a React, Vue or plain web project with the Sosialoka theme, tokens and components. Web projects get the Sosialoka look in one of two ways: - **React or Vue with shadcn:** install your product's theme, then the components, from the Sosialoka registry. Most products start here. - **Any other web app:** load the CSS tokens, with or without Tailwind, and build on the variables. ## Set up a shadcn project React components are built on Base UI and installed with `shadcn`; Vue components are built on Reka UI and installed with `shadcn-vue`. Both copy the source into your project, so you own the code. 1. Start from a project where shadcn (React) or shadcn-vue (Vue) is already set up. 2. Install the theme for your product. It writes the Sosialoka colors for light and dark mode, the fonts and the radius into your global CSS: ```bash # React npx shadcn@latest add https://design.sosialoka.tech/r/react/theme-coverclearance.json # Vue npx shadcn-vue@latest add https://design.sosialoka.tech/r/vue/theme-coverclearance.json ``` Swap `coverclearance` for `lokamusik`, `lokasign`, `mylokalink`, or `neutral` for a screen that belongs to no product. A fresh shadcn project imports the Geist font; remove that import, since the theme sets Plus Jakarta Sans for text and headings. Installed a theme before? Install it again to get newer tokens such as `overlay`, which dialogs and sheets use. 3. Install components from the Sosialoka registry, for example: ```bash npx shadcn@latest add https://design.sosialoka.tech/r/react/button.json npx shadcn-vue@latest add https://design.sosialoka.tech/r/vue/button.json ``` 4. Load Plus Jakarta Sans in your product. Turn on dark mode with the `.dark` class on the root element, as shadcn projects do; the theme writes its dark values under `.dark`. Every component and its install command is listed in [Components](https://design.sosialoka.tech/components/). [Patterns](https://design.sosialoka.tech/patterns/login/) show whole screens built from them. ## Use the tokens without shadcn Set the product and the mode on the root element. `data-brand` is required; `data-theme` takes `light` or `dark`, and the `.dark` class works too. Without a dark marker, the light values apply. ```html ``` | File | Use it for | | --- | --- | | [/tokens/sosialoka.css](https://design.sosialoka.tech/tokens/sosialoka.css) | Any web app. CSS variables for every theme and the tenant accent presets. | | [/tokens/tailwind.css](https://design.sosialoka.tech/tokens/tailwind.css) | Tailwind v4. Maps the variables to utilities such as `bg-primary`, `text-muted-foreground` and `rounded-md`. | | [/tokens.json](https://design.sosialoka.tech/tokens.json) | Design tools and agents. Every token in the DTCG 2025.10 format. | | [/tokens/lokasign-light.json](https://design.sosialoka.tech/tokens/lokasign-light.json) | Resolved values for one theme. Swap the file name for any other theme. | In a Tailwind v4 project: ```css @import "tailwindcss"; @import "./sosialoka.css"; @import "./tailwind.css"; ``` Tokens name the fonts but don't ship them. Load Plus Jakarta Sans for the interface and JetBrains Mono for code in your product. ## Tenant accent A page that takes a tenant's or an artist's color sets a preset on its own root element. Presets are `blue`, `orange`, `teal` and `red`. ```html
``` Inside it, the `tenant-accent` tokens switch to the preset. Every other token keeps the product colors. --- # Flutter > The sosialoka_ui package gives Flutter apps the Sosialoka themes for shadcn_ui and Material. The `sosialoka_ui` package gives a Flutter app the Sosialoka theme of its product, for `shadcn_ui` widgets and for Material widgets, in light and dark mode. ## Install The package installs from the design system repository: ```yaml dependencies: shadcn_ui: ^0.59.0 sosialoka_ui: git: url: https://gitlab.com/sosialoka/design-system.git path: flutter ``` ## Set the theme Pick your product with `SosialokaBrand`, or `SosialokaBrand.neutral` for an app that belongs to no product. `SosialokaTheme.shad` builds the `shadcn_ui` theme, and `SosialokaTheme.material` builds a matching Material theme for screens that still use Material widgets. ```dart import 'package:flutter/material.dart'; import 'package:shadcn_ui/shadcn_ui.dart'; import 'package:sosialoka_ui/sosialoka_ui.dart'; class App extends StatelessWidget { const App({super.key}); @override Widget build(BuildContext context) { const brand = SosialokaBrand.coverclearance; return ShadApp.custom( theme: SosialokaTheme.shad(brand, Brightness.light), darkTheme: SosialokaTheme.shad(brand, Brightness.dark), appBuilder: (context) => MaterialApp( theme: SosialokaTheme.material(brand, Brightness.light), darkTheme: SosialokaTheme.material(brand, Brightness.dark), builder: (context, child) => ShadAppBuilder(child: child!), home: const HomeScreen(), ), ); } } ``` Moving screens over one at a time works: Material screens and `shadcn_ui` screens share the same colors and radius. ## Extra colors `shadcn_ui` has no field for the status colors, soft tints, tenant accents or brand colors. Read them from the theme with `context.sosialoka`: ```dart ShadBadge( backgroundColor: context.sosialoka.successSoft, foregroundColor: context.sosialoka.success, child: const Text('Selesai'), ); ``` The raw values, radius, spacing and text sizes are also available as constants: `SosialokaColors`, `SosialokaRadius`, `SosialokaSpace` and `SosialokaText`. The same constants are in one file, [/tokens/sosialoka_tokens.dart](https://design.sosialoka.tech/tokens/sosialoka_tokens.dart), for an app without the package. ## Font The themes set Plus Jakarta Sans through the `google_fonts` package, which downloads the font on first use. An app that must work offline should bundle the font files and declare them in its `pubspec.yaml`. ## Examples Every component page shows its Flutter code in the Flutter tab. The same code runs in the gallery app in `flutter/example` of the repository, where `flutter analyze` and a render test under every brand and mode check it. --- # Use with AI agents > Connect Claude Code, Cursor, VS Code, Codex or Gemini CLI to the design system through its MCP server, llms.txt, the registry and an AGENTS.md snippet. AI agents can read the whole design system in open formats, so any agent, Claude or not, builds UI with the same tokens, components and patterns as the docs. ## What agents can read | Source | Use it for | | --- | --- | | Page URL + `.md`, such as [/components/button.md](https://design.sosialoka.tech/components/button.md) | One page as Markdown. Every page also has **Copy as Markdown** and **Download .md** buttons. | | [/llms.txt](https://design.sosialoka.tech/llms.txt) and [/id/llms.txt](https://design.sosialoka.tech/id/llms.txt) | The index of every page with a one-sentence summary ([llmstxt.org](https://llmstxt.org)). | | [/llms-full.txt](https://design.sosialoka.tech/llms-full.txt) and [/id/llms-full.txt](https://design.sosialoka.tech/id/llms-full.txt) | Every page in one file. | | [/tokens.json](https://design.sosialoka.tech/tokens.json) and `/tokens/.json` | Every token in the DTCG format, and the resolved values of one theme. | | [/r/react/registry.json](https://design.sosialoka.tech/r/react/registry.json) and [/r/vue/registry.json](https://design.sosialoka.tech/r/vue/registry.json) | The shadcn registries of the React and Vue components. | | [/sosialoka-design-system-docs.zip](https://design.sosialoka.tech/sosialoka-design-system-docs.zip) | All of the above in one download. | | `https://design.sosialoka.tech/mcp` | The MCP server: search, pages, components, patterns and tokens as tools. | ## Connect the MCP server The server speaks MCP over Streamable HTTP at `https://design.sosialoka.tech/mcp`. It needs no login: everything it serves is public. Name it `sosialoka-design` so the AGENTS.md snippet below finds it. ### Claude Code ```bash claude mcp add --transport http sosialoka-design https://design.sosialoka.tech/mcp ``` Add `--scope project` to write it to the repository's `.mcp.json`, so the whole team gets it. ### Cursor In `.cursor/mcp.json` of the project, or `~/.cursor/mcp.json` for every project: ```json { "mcpServers": { "sosialoka-design": { "url": "https://design.sosialoka.tech/mcp" } } } ``` ### VS Code In `.vscode/mcp.json`: ```json { "servers": { "sosialoka-design": { "type": "http", "url": "https://design.sosialoka.tech/mcp" } } } ``` ### Codex In `~/.codex/config.toml`: ```toml [mcp_servers.sosialoka-design] url = "https://design.sosialoka.tech/mcp" ``` ### Gemini CLI In `~/.gemini/settings.json`, or `.gemini/settings.json` of the project: ```json { "mcpServers": { "sosialoka-design": { "httpUrl": "https://design.sosialoka.tech/mcp" } } } ``` ## Tools Every tool returns Markdown. Tools that take `locale` accept `en` (the default) or `id`. | Tool | Arguments | Returns | | --- | --- | --- | | `search_docs` | `query`, `locale`, `limit` | The matching pages, with the path to pass to `get_page`. | | `get_page` | `path`, `locale` | One page. The path can be `foundations/color`, `/id/content/` or a full page URL. | | `list_components` | none | Every component with its frameworks, and every page pattern. | | `get_component` | `name`, `platform`, `locale` | A component guide with its install commands and code. `platform` (`react`, `vue` or `flutter`) keeps one platform's code. | | `get_tokens` | `theme` | The resolved values of one theme. Without `theme`, the theme list and the link to the full DTCG file. | | `list_themes` | none | The themes and how to switch them. | | `get_pattern` | `name`, `locale` | A page pattern, such as `login`, `dashboard`, `list` or `form`, with its code. | ## Install components through the shadcn MCP The React registry also works with the official shadcn MCP server, so an agent can search the Sosialoka components and install them by name. Add the registry to `components.json`: ```json { "registries": { "@sosialoka": "https://design.sosialoka.tech/r/react/{name}.json" } } ``` Then set up the shadcn MCP server for your agent (`claude`, `cursor` or `vscode`): ```bash npx shadcn@latest mcp init --client claude ``` `mcp init` cannot write the Codex config, so for Codex add this to `~/.codex/config.toml`: ```toml [mcp_servers.shadcn] command = "npx" args = ["shadcn@latest", "mcp"] ``` Ask for an item by its registry name, such as "add @sosialoka/button". The shadcn MCP serves the React registry; in a Vue project, the agent takes the `shadcn-vue` install command from `get_component` or from the component page. ## Add the rules to your repo Paste this into the `AGENTS.md`, `CLAUDE.md`, `GEMINI.md` or `.cursor/rules` file of a product repository. It is also at [/AGENTS.md](https://design.sosialoka.tech/AGENTS.md). ````markdown ## Sosialoka Design System This product uses the Sosialoka Design System (https://design.sosialoka.tech). Follow it for every UI change. - **Read before you build.** Index: https://design.sosialoka.tech/llms.txt (Indonesian: https://design.sosialoka.tech/id/llms.txt). Every page is Markdown at its URL + `.md`. - **Use the MCP server when it is connected** (`sosialoka-design`, https://design.sosialoka.tech/mcp): `search_docs`, `get_component` with `platform`, `get_pattern`, `get_tokens` with a theme. - **Install components from the registry; don't rewrite them.** - React: `npx shadcn@latest add https://design.sosialoka.tech/r/react/.json` - Vue: `npx shadcn-vue@latest add https://design.sosialoka.tech/r/vue/.json` - Install your product's theme first: https://design.sosialoka.tech/web.md - Flutter: the `sosialoka_ui` package (https://design.sosialoka.tech/flutter.md). - **Use tokens, never raw values:** `bg-primary`, `text-muted-foreground`, `border-input`, `rounded-md`. No hex colors, no pixel radius. - **Set the theme on the root element:** `data-brand` = your product (`lokamusik`, `coverclearance`, `lokasign`, `mylokalink`), or `neutral` when the screen belongs to no product; `data-theme` = `light` or `dark`. - **Icons:** Lucide. **UI font:** Plus Jakarta Sans. - **Labels sit above inputs.** One primary action per screen. - **Copy** (https://design.sosialoka.tech/content.md): Indonesian uses "kamu", never "Anda". Short, active sentences. Error messages come from the backend; the client only disables the button. ```` ## Download everything [sosialoka-design-system-docs.zip](https://design.sosialoka.tech/sosialoka-design-system-docs.zip) holds every page as Markdown in English and Indonesian, the `llms.txt` and `llms-full.txt` files, `tokens.json`, one `tokens/.json` file per theme and `AGENTS.md`. It is rebuilt with every release of the site. --- # Add a product > Give a new Sosialoka product its own light and dark theme from its logo color with one command, and use the neutral theme when a screen belongs to no product. Every brand is listed once, in `tokens/brands.json`. The token build, the registry, the Flutter package and this site all read that list, so a new product takes one command, its logos and a few lines of docs. ## Before you start - **The logo color,** as `#RRGGBB`. It becomes `primary` in light mode as it is: a product's primary is always its logo color. - **The logo files,** one for light grounds and one for dark grounds, in SVG or PNG. - **An id:** lowercase letters and digits, such as `lokaticket`. It becomes the `data-brand` value, the theme file names and the Flutter enum value, so pick it once. ## 1. Generate the themes In the design system repository: ```bash pnpm new-brand lokaticket --name "Loka Ticket" --logo "#B83A0B" --summary "Ticketing for music events." ``` The command writes `tokens/themes/lokaticket-light.tokens.json` and `lokaticket-dark.tokens.json`, adds the product to `tokens/brands.json`, and runs the contrast check on the two new themes. | Option | Use it for | | --- | --- | | `--name` | The product name as people read it. Required. | | `--logo` | The logo color. Required. | | `--summary` | One line, in English, on what the product does. Required. | | `--secondary` | A second logo color, for gradients and the login hero. | | `--dark-primary` | `primary` in dark mode, when the derived one doesn't suit the logo. | | `--font` | The display font for brand moments. Defaults to Plus Jakarta Sans. | | `--fallback` | `sans-serif` or `serif`, after the display font. | | `--sample` | A line set in the display font on the Brand page. Write it the way the login hero would say it. | ## How the colors are made | Tokens | Light | Dark | | --- | --- | --- | | `primary` | The logo color | The logo color, lightened until dark text reads on it | | `primary-foreground` | White or dark ink, whichever reads on the logo color and on its hover | Dark ink | | `background`, `card`, `muted`, `border` | Near white, with a trace of the logo hue | Near black, with a trace of the logo hue | | `foreground`, `muted-foreground`, `input` | Stepped until they reach 4.5:1, or 3:1 for `input` | Same | | `primary-soft`, `primary-text` | A pale tint, and the logo color darkened until it reads as text | A deep tint, and a light version of the logo color | | `chart-1` | The logo color, darkened only if it needs to reach 3:1 | The logo color, lightened only if needed | | `brand-*` | The logo colors, the same in both modes | Same | A gray logo gives gray neutrals, because the tint never carries more color than the logo has. The result is a starting point: open the theme files, tune what doesn't feel like the product, and run `pnpm check`, which holds every pair to the contrast it needs. ### When the check reports a pair Some logo colors, such as a bright pink or orange, can't carry white or dark text at 4.5:1. The command keeps the logo color and lists those pairs. Don't swap in a different `primary` on your own: ask the design system owner. They either accept the pair as an exception in `packages/tokens/src/contrast.ts`, as they did for the Cover Clearance orange, or choose another primary. ## 2. Add the logos Put the files in `site/public/brand/` and list them in the product's entry in `tokens/brands.json`: ```json "logos": [ { "variant": "light-ground", "file": "lokaticket.svg", "alt": "Loka Ticket logo, for light grounds" }, { "variant": "dark-ground", "file": "lokaticket-white.svg", "alt": "Loka Ticket logo, white, for dark grounds" } ] ``` The Brand page shows them in its logo grid, and the font specimen picks up the display font and the sample line. ## 3. Load a new display font If the display font isn't one the site already loads, add its `@fontsource-variable` package to `site/` and import it in `FontSpecimen.astro` and `block-preview.css`. Products load their own fonts. ## 4. Add the product to the docs - On the [Brand](https://design.sosialoka.tech/brand/) page, a section with the product's brand tokens: ``. - On the home page, a line in the product list. - In `site/public/AGENTS.md`, the id in the `data-brand` list. Write each change in English and in Indonesian, under `id/`. ## 5. Check and commit Run `pnpm check`. It rebuilds everything that reads the list: - `sosialoka.css` with `[data-brand="lokaticket"]` for light and dark mode - the registry themes `theme-lokaticket.json` for React and Vue - the Flutter enum value `SosialokaBrand.lokaticket` in `tokens.g.dart` - the brand selector on this site and the theme list of the MCP server Commit the theme files, `tokens/brands.json`, the logos and `flutter/lib/src/generated/tokens.g.dart`. The product then installs its theme like any other: ```bash npx shadcn@latest add https://design.sosialoka.tech/r/react/theme-lokaticket.json ``` ```dart ShadApp(theme: SosialokaTheme.shad(SosialokaBrand.lokaticket, Brightness.light)); ``` ## Neutral theme `neutral` is a graphite theme: gray surfaces, a near-black `primary` in light mode and a light gray one in dark mode. It belongs to no product. Use it for: - work a vendor or partner starts before the product's brand is set - internal tools and prototypes - screens that serve several products at once A product with its own logo gets its own theme instead. The neutral theme installs and switches like the others: ```html ``` ```bash npx shadcn@latest add https://design.sosialoka.tech/r/react/theme-neutral.json ``` ```dart ShadApp(theme: SosialokaTheme.shad(SosialokaBrand.neutral, Brightness.light)); ``` --- # Brand > How Sosialoka products look like one family while each keeps its own name, logo and color. Sosialoka products follow an endorsed brand model: each product keeps its own name, logo and color, and Sosialoka stands behind all of them. To bring in a new product, see [Add a product](https://design.sosialoka.tech/add-a-product/). ## Product line Login screens and product footers carry the line **from [Sosialoka mark] Sosialoka**: the word "from", the Sosialoka mark, then the name. "from" says Sosialoka owns the product. Don't write "Powered by", which reads as a technology vendor. ## Logos - Sosialoka mark: [sosialoka.png](https://design.sosialoka.tech/brand/sosialoka.png) - Loka Musik logo, for light grounds: [lokamusik.svg](https://design.sosialoka.tech/brand/lokamusik.svg) - Loka Musik logo, white text, for dark grounds: [lokamusik-white.svg](https://design.sosialoka.tech/brand/lokamusik-white.svg) - Cover Clearance logo, color: [coverclearance.svg](https://design.sosialoka.tech/brand/coverclearance.svg) - Cover Clearance logo, white, for dark grounds: [coverclearance-white.svg](https://design.sosialoka.tech/brand/coverclearance-white.svg) - Lokasign logo, for light grounds: [lokasign.png](https://design.sosialoka.tech/brand/lokasign.png) - Lokasign logo, for dark grounds: [lokasign-dark.png](https://design.sosialoka.tech/brand/lokasign-dark.png) - My Loka Link lockup, for light grounds: [mylokalink.svg](https://design.sosialoka.tech/brand/mylokalink.svg) - My Loka Link lockup, for dark grounds: [mylokalink-white.svg](https://design.sosialoka.tech/brand/mylokalink-white.svg) - Use the files as they are. Don't redraw, recolor, stretch, rotate or add effects. - Use the white or dark-ground version on dark backgrounds. - The light and dark versions of a logo differ only in the color of the lettering; the mark keeps its colors. ## Brand colors Each product's `primary` is its logo color. The `brand-*` tokens hold the logo colors themselves and stay the same in light and dark mode; use them only in brand moments such as the login hero. ### Loka Musik | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | brand-primary | `--brand-primary` | #660032 | Logo color, the same in both modes; brand moments only. | | brand-secondary | `--brand-secondary` | #FF8FC6 | Second logo color, used in gradients and brand moments only. | | brand-ground | `--brand-ground` | #660032 | Ground color of the login hero and other brand moments. | | brand-ground-foreground | `--brand-ground-foreground` | #FFFFFF | Text on brand-ground, as in the login hero. | | font-brand | `--font-brand` | Poppins, sans-serif | Display font for brand moments only, such as the login hero. | | font-brand-weight | `--font-brand-weight` | 600 | Weight of the display font in brand moments. | | font-brand-stretch | `--font-brand-stretch` | 100% | font-stretch of the display font in brand moments. | | font-brand-tracking | `--font-brand-tracking` | -0.02em | letter-spacing of the display font in brand moments. | ### Cover Clearance | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | brand-primary | `--brand-primary` | #E48725 | Logo color, the same in both modes; brand moments only. | | brand-secondary | `--brand-secondary` | #0576BB | Second logo color, used in gradients and brand moments only. | | brand-ground | `--brand-ground` | #E48725 | Ground color of the login hero and other brand moments. | | brand-ground-foreground | `--brand-ground-foreground` | #1A1F2E | Text on brand-ground, as in the login hero. | | font-brand | `--font-brand` | "Rethink Sans Variable", "Rethink Sans", sans-serif | Display font for brand moments only, such as the login hero. | | font-brand-weight | `--font-brand-weight` | 800 | Weight of the display font in brand moments. | | font-brand-stretch | `--font-brand-stretch` | 100% | font-stretch of the display font in brand moments. | | font-brand-tracking | `--font-brand-tracking` | -0.02em | letter-spacing of the display font in brand moments. | ### Lokasign | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | brand-primary | `--brand-primary` | #0060EF | Logo color, the same in both modes; brand moments only. | | brand-secondary | `--brand-secondary` | #7DAEFF | Second logo color, used in gradients and brand moments only. | | brand-ground | `--brand-ground` | #001D43 | Ground color of the login hero and other brand moments. | | brand-ground-foreground | `--brand-ground-foreground` | #FFFFFF | Text on brand-ground, as in the login hero. | | font-brand | `--font-brand` | "Newsreader Variable", Newsreader, Georgia, serif | Display font for brand moments only, such as the login hero. | | font-brand-weight | `--font-brand-weight` | 500 | Weight of the display font in brand moments. | | font-brand-stretch | `--font-brand-stretch` | 100% | font-stretch of the display font in brand moments. | | font-brand-tracking | `--font-brand-tracking` | -0.01em | letter-spacing of the display font in brand moments. | ### My Loka Link | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | brand-primary | `--brand-primary` | #0A66C2 | Logo color, the same in both modes; brand moments only. | | brand-secondary | `--brand-secondary` | #00B8C8 | Second logo color, used in gradients and brand moments only. | | brand-ground | `--brand-ground` | #0A66C2 | Ground color of the login hero and other brand moments. | | brand-ground-foreground | `--brand-ground-foreground` | #FFFFFF | Text on brand-ground, as in the login hero. | | font-brand | `--font-brand` | "Plus Jakarta Sans Variable", "Plus Jakarta Sans", sans-serif | Display font for brand moments only, such as the login hero. | | font-brand-weight | `--font-brand-weight` | 800 | Weight of the display font in brand moments. | | font-brand-stretch | `--font-brand-stretch` | 100% | font-stretch of the display font in brand moments. | | font-brand-tracking | `--font-brand-tracking` | -0.035em | letter-spacing of the display font in brand moments. | ## Three font layers | Layer | Where | Font | | --- | --- | --- | | Logo | The logo only | Each product's own. Never retype a logo. | | Display | [Brand moments](#brand-moments) only | One per product, shown below | | UI | Everything else: tables, forms, buttons, text | Plus Jakarta Sans in every product | | Product | Display font | Weight | Width | Sample | | --- | --- | --- | --- | --- | | Loka Musik | Poppins | 600 | 100% | Rilis musikmu ke semua platform. | | Cover Clearance | Rethink Sans | 800 | 100% | Pilih lagu yang ingin kamu cover. | | Lokasign | Newsreader | 500 | 100% | Tanda tangan sah, *dari mana saja.* | | My Loka Link | Plus Jakarta Sans | 800 | 100% | Semua link musikmu di satu tempat. | ## Brand moments A brand moment is a place where the product speaks in its own voice. There are three: - **Login hero:** the left half of the login screen. - **Welcome screens:** onboarding and the first screen of an empty account. - **Top of the home screen:** the first screen after sign-in, on phones and on the web. On the home screen, `font-brand` may set only: - the greeting, such as "Halo, Bayu."; - the title of the one featured card at the top; - headline figures, such as total revenue or the count on a summary card. The featured card may sit on `brand-ground`, the logo color. On it: - text and icons use `brand-ground-foreground`; - the main action is a `secondary` button, and other actions are `ghost` buttons in `brand-ground-foreground`; - a badge is `outline`, with its text and border in `brand-ground-foreground`. Only that one card goes on `brand-ground`; every other card on the home screen stays on `card`. Section headings, lists, tables, forms, buttons, badges, the top bar and the navigation stay in `font-sans`, on the home screen too. Set `font-brand` with its weight and tracking tokens, at `text-2xl` or larger; smaller, it reads as body text in the wrong font. --- # Color > Semantic color tokens for every theme, each product and the neutral theme in light and dark mode. Components ask for a role such as `primary` or `muted-foreground`, never a hex value, so the same component works in every theme. ## Roles - `background`: the page ground behind cards. - `foreground`: main text. - `card` and `popover`: cards, menus and form surfaces. - `muted` and `muted-foreground`: quiet surfaces and secondary text. - `border` and `input`: dividers and control borders. - `primary` and `primary-foreground`: the main action, in the product's logo color. - `primary-soft` and `primary-text`: tinted surfaces and small primary-colored text such as links. - `ring`: the keyboard focus ring. - `sidebar-*`: the dashboard sidebar. `secondary` and `accent` keep their shadcn meaning: a quiet button fill and a hover background. Neither one is a brand color. ## All themes | Token | lokamusik-light | lokamusik-dark | coverclearance-light | coverclearance-dark | lokasign-light | lokasign-dark | mylokalink-light | mylokalink-dark | neutral-light | neutral-dark | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | background | #FDF9FA | #1C0F16 | #F9F8F6 | #0A0D14 | #F3F6FB | #001D43 | #FFFFFF | #0B1620 | #FAFAFD | #0E0E11 | | foreground | #1C0F16 | #F5F5F5 | #181B1F | #DBDEE3 | #001D43 | #EEF3FB | #1C3B4E | #F2F6F8 | #1A1A1D | #E6E6EA | | card | #FFFFFF | #26181F | #FFFFFF | #12161E | #FFFFFF | #0A2A57 | #FFFFFF | #13212B | #FFFFFF | #17171A | | muted | #F5F5F5 | #2E2028 | #F2F0EC | #1B1F29 | #EAF0F8 | #0F3466 | #ECF6FC | #1A2B36 | #F2F2F6 | #1F1F22 | | muted-foreground | #4A3A42 | #B4A7AA | #625D56 | #A0A5AE | #4A5B78 | #A9BAD6 | #657078 | #87939B | #636366 | #AAAAAE | | border | #ECE4E6 | #3A2B33 | #ECE9E3 | #262B36 | #D5DEEC | #1D4478 | #DCE8F1 | #23343F | #E6E6EA | #2B2B2E | | input | #998D90 | #7A6871 | #908F8D | #5F646D | #7D8FA9 | #5376A6 | #8A969E | #606B72 | #909093 | #68686C | | primary | #660032 | #FF8FC6 | #E48725 | #E87F34 | #0060EF | #7DAEFF | #0A66C2 | #65A7F9 | #27272A | #E4E4E7 | | primary-foreground | #FFFFFF | #660032 | #FFFFFF | #180600 | #FFFFFF | #001D43 | #FFFFFF | #0B1620 | #FFFFFF | #0D0D10 | | primary-soft | #FFEEF6 | #3D001E | #FFEEE1 | #371C0B | #E6EFFE | #0F3466 | #ECF4FF | #162C47 | #F3F3F4 | #29292A | | primary-text | #660032 | #FF8FC6 | #A8530A | #EF9F67 | #0050C8 | #7DAEFF | #0A66C2 | #72A7EB | #27272A | #E4E4E7 | | ring | #660032 | #FF8FC6 | #A8530A | #E87F34 | #0060EF | #7DAEFF | #0A66C2 | #65A7F9 | #27272A | #E4E4E7 | | card-foreground | #1C0F16 | #F5F5F5 | #181B1F | #DBDEE3 | #001D43 | #EEF3FB | #1C3B4E | #F2F6F8 | #1A1A1D | #E6E6EA | | popover | #FFFFFF | #26181F | #FFFFFF | #12161E | #FFFFFF | #0A2A57 | #FFFFFF | #13212B | #FFFFFF | #17171A | | popover-foreground | #1C0F16 | #F5F5F5 | #181B1F | #DBDEE3 | #001D43 | #EEF3FB | #1C3B4E | #F2F6F8 | #1A1A1D | #E6E6EA | | secondary | #F5F5F5 | #2E2028 | #F2F0EC | #1B1F29 | #EAF0F8 | #0F3466 | #ECF6FC | #1A2B36 | #F2F2F6 | #1F1F22 | | secondary-foreground | #1C0F16 | #F5F5F5 | #181B1F | #DBDEE3 | #001D43 | #EEF3FB | #1C3B4E | #F2F6F8 | #1A1A1D | #E6E6EA | | accent | #F5F5F5 | #2E2028 | #F2F0EC | #1B1F29 | #EAF0F8 | #0F3466 | #ECF6FC | #1A2B36 | #F2F2F6 | #1F1F22 | | accent-foreground | #1C0F16 | #F5F5F5 | #181B1F | #DBDEE3 | #001D43 | #EEF3FB | #1C3B4E | #F2F6F8 | #1A1A1D | #E6E6EA | | sidebar | #FFFFFF | #26181F | #FFFFFF | #12161E | #FFFFFF | #0A2A57 | #FFFFFF | #13212B | #FFFFFF | #17171A | | sidebar-foreground | #1C0F16 | #F5F5F5 | #181B1F | #DBDEE3 | #001D43 | #EEF3FB | #1C3B4E | #F2F6F8 | #1A1A1D | #E6E6EA | | sidebar-border | #ECE4E6 | #3A2B33 | #ECE9E3 | #262B36 | #D5DEEC | #1D4478 | #DCE8F1 | #23343F | #E6E6EA | #2B2B2E | | sidebar-accent | #FFEEF6 | #3D001E | #FFEEE1 | #371C0B | #E6EFFE | #0F3466 | #ECF4FF | #162C47 | #F3F3F4 | #29292A | | sidebar-accent-foreground | #660032 | #FF8FC6 | #A8530A | #EF9F67 | #0050C8 | #7DAEFF | #0A66C2 | #72A7EB | #27272A | #E4E4E7 | | sidebar-primary | #660032 | #FF8FC6 | #E48725 | #E87F34 | #0060EF | #7DAEFF | #0A66C2 | #65A7F9 | #27272A | #E4E4E7 | | sidebar-primary-foreground | #FFFFFF | #660032 | #FFFFFF | #180600 | #FFFFFF | #001D43 | #FFFFFF | #0B1620 | #FFFFFF | #0D0D10 | | sidebar-ring | #660032 | #FF8FC6 | #A8530A | #E87F34 | #0060EF | #7DAEFF | #0A66C2 | #65A7F9 | #27272A | #E4E4E7 | | tenant-accent | #660032 | #FF8FC6 | #E48725 | #E87F34 | #0060EF | #7DAEFF | #0A66C2 | #65A7F9 | #27272A | #E4E4E7 | | tenant-accent-foreground | #FFFFFF | #660032 | #FFFFFF | #180600 | #FFFFFF | #001D43 | #FFFFFF | #0B1620 | #FFFFFF | #0D0D10 | | tenant-accent-soft | #FFEEF6 | #3D001E | #FFEEE1 | #371C0B | #E6EFFE | #0F3466 | #ECF4FF | #162C47 | #F3F3F4 | #29292A | | tenant-accent-text | #660032 | #FF8FC6 | #A8530A | #EF9F67 | #0050C8 | #7DAEFF | #0A66C2 | #72A7EB | #27272A | #E4E4E7 | ## Status Status colors are the same in every product. `success`, `warning` and `destructive` carry color; `info` is a neutral slate, so it never looks like the blue actions of Lokasign or My Loka Link. Color alone never carries a status: always pair it with a word or an icon. ### Light | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | success | `--success` | #0B6B5E | Status color for done, approved, published; text and icons on background, card and success-soft. | | success-foreground | `--success-foreground` | #FFFFFF | Text on a solid success fill. | | success-soft | `--success-soft` | #DDF3EF | Background of success badges and banners; text on it uses success. | | warning | `--warning` | #8A4B00 | Status color for pending, waiting for review; text and icons on background, card and warning-soft. | | warning-foreground | `--warning-foreground` | #FFFFFF | Text on a solid warning fill. | | warning-soft | `--warning-soft` | #FFF1D6 | Background of warning badges and banners; text on it uses warning. | | destructive | `--destructive` | #B42318 | Status color for errors, rejected, delete actions; text and icons on background, card and destructive-soft. | | destructive-foreground | `--destructive-foreground` | #FFFFFF | Text on a solid destructive fill. | | destructive-soft | `--destructive-soft` | #FDE7E4 | Background of destructive badges and banners; text on it uses destructive. | | info | `--info` | #475467 | Neutral status for information and tips; slate so it never reads as a brand action. Text and icons on background, card and info-soft. | | info-foreground | `--info-foreground` | #FFFFFF | Text on a solid info fill. | | info-soft | `--info-soft` | #EEF1F5 | Background of info badges and banners; text on it uses info. | ### Dark | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | success | `--success` | #4FD1B5 | Status color for done, approved, published; text and icons on background, card and success-soft. | | success-foreground | `--success-foreground` | #0B1620 | Text on a solid success fill. | | success-soft | `--success-soft` | #12302B | Background of success badges and banners; text on it uses success. | | warning | `--warning` | #F5B544 | Status color for pending, waiting for review; text and icons on background, card and warning-soft. | | warning-foreground | `--warning-foreground` | #0B1620 | Text on a solid warning fill. | | warning-soft | `--warning-soft` | #3A2C0F | Background of warning badges and banners; text on it uses warning. | | destructive | `--destructive` | #FF8A75 | Status color for errors, rejected, delete actions; text and icons on background, card and destructive-soft. | | destructive-foreground | `--destructive-foreground` | #0B1620 | Text on a solid destructive fill. | | destructive-soft | `--destructive-soft` | #3A1A16 | Background of destructive badges and banners; text on it uses destructive. | | info | `--info` | #B4BFCC | Neutral status for information and tips; slate so it never reads as a brand action. Text and icons on background, card and info-soft. | | info-foreground | `--info-foreground` | #0B1620 | Text on a solid info fill. | | info-soft | `--info-soft` | #1E2733 | Background of info badges and banners; text on it uses info. | ## Chart palette Charts use five series colors, `chart-1` to `chart-5`, in that order. `chart-1` is the product's own hue; `chart-2` to `chart-5` (magenta, teal, olive, indigo) are the same in every product and never reuse a status color. Every series reaches 3:1 on `background` and `card`, and the order passes the color-blind checks for neighboring series. Cover Clearance light steps its orange down to `#C2620E` for `chart-1`, because `#E48725` stays under 3:1 on its background. More than five series fold into "Lainnya". See [Chart](https://design.sosialoka.tech/components/chart/). ### Light | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | chart-2 | `--chart-2` | #C2185B | Second chart series (magenta); the same in every product, never a status color. | | chart-3 | `--chart-3` | #0087A3 | Third chart series (teal); the same in every product, never a status color. | | chart-4 | `--chart-4` | #6B7A00 | Fourth chart series (olive); the same in every product, never a status color. | | chart-5 | `--chart-5` | #5B4FCF | Fifth chart series (indigo); the same in every product, never a status color. | | chart-1 | `--chart-1` | #C2620E | First chart series: the brand hue, stepped where needed to reach 3:1 on background and card. | ### Dark | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | chart-2 | `--chart-2` | #D94E85 | Second chart series (magenta); the same in every product, never a status color. | | chart-3 | `--chart-3` | #14A3B8 | Third chart series (teal); the same in every product, never a status color. | | chart-4 | `--chart-4` | #8C9A17 | Fourth chart series (olive); the same in every product, never a status color. | | chart-5 | `--chart-5` | #7B6FE0 | Fifth chart series (indigo); the same in every product, never a status color. | | chart-1 | `--chart-1` | #C9701F | First chart series: the brand hue, stepped where needed to reach 3:1 on background and card. | ## Tenant accent presets My Loka Link artist pages and Ruang Loka Musik tenants take their own accent color. Set `data-tenant-accent` on the page root to one of the presets below; the four `tenant-accent` tokens switch, and nothing else changes. Without a preset, the tenant tokens follow `primary`. ### Light | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | blue · tenant-accent | `--tenant-accent` | #0A66C2 | Tenant or artist accent fill; defaults to primary until a preset applies. Preset "blue", light mode. | | blue · tenant-accent-foreground | `--tenant-accent-foreground` | #FFFFFF | Text on tenant-accent. Preset "blue", light mode. | | blue · tenant-accent-soft | `--tenant-accent-soft` | #ECF4FF | Tinted surface in the tenant accent. Preset "blue", light mode. | | blue · tenant-accent-text | `--tenant-accent-text` | #0A66C2 | Text in the tenant accent on background, card and tenant-accent-soft. Preset "blue", light mode. | | orange · tenant-accent | `--tenant-accent` | #C4530F | Tenant or artist accent fill; defaults to primary until a preset applies. Preset "orange", light mode. | | orange · tenant-accent-foreground | `--tenant-accent-foreground` | #FFFFFF | Text on tenant-accent. Preset "orange", light mode. | | orange · tenant-accent-soft | `--tenant-accent-soft` | #FFEDE0 | Tinted surface in the tenant accent. Preset "orange", light mode. | | orange · tenant-accent-text | `--tenant-accent-text` | #AB4400 | Text in the tenant accent on background, card and tenant-accent-soft. Preset "orange", light mode. | | teal · tenant-accent | `--tenant-accent` | #007B76 | Tenant or artist accent fill; defaults to primary until a preset applies. Preset "teal", light mode. | | teal · tenant-accent-foreground | `--tenant-accent-foreground` | #FFFFFF | Text on tenant-accent. Preset "teal", light mode. | | teal · tenant-accent-soft | `--tenant-accent-soft` | #DCF9F6 | Tinted surface in the tenant accent. Preset "teal", light mode. | | teal · tenant-accent-text | `--tenant-accent-text` | #006D69 | Text in the tenant accent on background, card and tenant-accent-soft. Preset "teal", light mode. | | red · tenant-accent | `--tenant-accent` | #BE222A | Tenant or artist accent fill; defaults to primary until a preset applies. Preset "red", light mode. | | red · tenant-accent-foreground | `--tenant-accent-foreground` | #FFFFFF | Text on tenant-accent. Preset "red", light mode. | | red · tenant-accent-soft | `--tenant-accent-soft` | #FFECEB | Tinted surface in the tenant accent. Preset "red", light mode. | | red · tenant-accent-text | `--tenant-accent-text` | #B32228 | Text in the tenant accent on background, card and tenant-accent-soft. Preset "red", light mode. | ### Dark | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | blue · tenant-accent | `--tenant-accent` | #65A7F9 | Tenant or artist accent fill; defaults to primary until a preset applies. Preset "blue", dark mode. | | blue · tenant-accent-foreground | `--tenant-accent-foreground` | #1C3B4E | Text on tenant-accent. Preset "blue", dark mode. | | blue · tenant-accent-soft | `--tenant-accent-soft` | #162C47 | Tinted surface in the tenant accent. Preset "blue", dark mode. | | blue · tenant-accent-text | `--tenant-accent-text` | #72A7EB | Text in the tenant accent on background, card and tenant-accent-soft. Preset "blue", dark mode. | | orange · tenant-accent | `--tenant-accent` | #F49752 | Tenant or artist accent fill; defaults to primary until a preset applies. Preset "orange", dark mode. | | orange · tenant-accent-foreground | `--tenant-accent-foreground` | #241005 | Text on tenant-accent. Preset "orange", dark mode. | | orange · tenant-accent-soft | `--tenant-accent-soft` | #3A1E0E | Tinted surface in the tenant accent. Preset "orange", dark mode. | | orange · tenant-accent-text | `--tenant-accent-text` | #F9A870 | Text in the tenant accent on background, card and tenant-accent-soft. Preset "orange", dark mode. | | teal · tenant-accent | `--tenant-accent` | #55CEC0 | Tenant or artist accent fill; defaults to primary until a preset applies. Preset "teal", dark mode. | | teal · tenant-accent-foreground | `--tenant-accent-foreground` | #001C1A | Text on tenant-accent. Preset "teal", dark mode. | | teal · tenant-accent-soft | `--tenant-accent-soft` | #092D2B | Tinted surface in the tenant accent. Preset "teal", dark mode. | | teal · tenant-accent-text | `--tenant-accent-text` | #69D3C6 | Text in the tenant accent on background, card and tenant-accent-soft. Preset "teal", dark mode. | | red · tenant-accent | `--tenant-accent` | #F68482 | Tenant or artist accent fill; defaults to primary until a preset applies. Preset "red", dark mode. | | red · tenant-accent-foreground | `--tenant-accent-foreground` | #250E0D | Text on tenant-accent. Preset "red", dark mode. | | red · tenant-accent-soft | `--tenant-accent-soft` | #3B1C1B | Tinted surface in the tenant accent. Preset "red", dark mode. | | red · tenant-accent-text | `--tenant-accent-text` | #F99E9B | Text in the tenant accent on background, card and tenant-accent-soft. Preset "red", dark mode. | ## Contrast - Text reaches at least 4.5:1 against the surface it sits on, in every theme and every tenant preset. - Focus rings and the borders of inputs, selects and checkboxes (`input`) reach at least 3:1. - A test checks every pair on each build, so a token change that breaks contrast fails the build. One pair is a known exception: white text on Cover Clearance orange in light mode reaches 2.7:1. Cover Clearance keeps its logo color as the primary fill by owner decision. Keep labels on that fill short and bold. --- # Typography > Three font layers and the UI type scale. Every product sets its interface in Plus Jakarta Sans; display fonts appear only in brand moments, and logos keep their own lettering. ## Fonts | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | font-sans | `--font-sans` | "Plus Jakarta Sans Variable", "Plus Jakarta Sans", ui-sans-serif, system-ui, sans-serif | Shared UI font for every product: tables, forms, buttons and text. | | font-mono | `--font-mono` | "JetBrains Mono Variable", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace | Code, IDs, timestamps and tabular data. | - Use `font-sans` for all interface text. - Use `font-mono` for codes, IDs, timestamps and data that must line up. - Use `font-brand` only in brand moments: the login hero, welcome screens and the top of the home screen. See [Brand moments](https://design.sosialoka.tech/brand/#brand-moments). ## Scale | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | text-xs | `--text-xs` | 0.75rem | Font size for captions, badges and table meta. | | text-xs--line-height | `--text-xs--line-height` | 1rem | Line height paired with text-xs. | | text-sm | `--text-sm` | 0.875rem | Font size for default UI text: table cells, inputs, buttons. | | text-sm--line-height | `--text-sm--line-height` | 1.25rem | Line height paired with text-sm. | | text-base | `--text-base` | 1rem | Font size for body copy and form text on wide layouts. | | text-base--line-height | `--text-base--line-height` | 1.5rem | Line height paired with text-base. | | text-lg | `--text-lg` | 1.125rem | Font size for lead paragraphs and card titles. | | text-lg--line-height | `--text-lg--line-height` | 1.75rem | Line height paired with text-lg. | | text-xl | `--text-xl` | 1.25rem | Font size for section headings inside a page. | | text-xl--line-height | `--text-xl--line-height` | 1.75rem | Line height paired with text-xl. | | text-2xl | `--text-2xl` | 1.5rem | Font size for page titles in the dashboard. | | text-2xl--line-height | `--text-2xl--line-height` | 2rem | Line height paired with text-2xl. | | text-3xl | `--text-3xl` | 1.875rem | Font size for large page titles and empty-state headlines. | | text-3xl--line-height | `--text-3xl--line-height` | 2.25rem | Line height paired with text-3xl. | | text-4xl | `--text-4xl` | 2.25rem | Font size for hero numbers and marketing headlines. | | text-4xl--line-height | `--text-4xl--line-height` | 2.5rem | Line height paired with text-4xl. | - Use sentence case for titles, buttons and labels. - Use `font-variant-numeric: tabular-nums` wherever numbers line up in columns. --- # Icons > One icon set for every product, with fixed sizes, stroke and an action dictionary. Every product uses [Lucide](https://lucide.dev). Cover Clearance and Lokasign still use Tabler on some screens; those icons move to Lucide when each screen moves to this design system. | Package | Import | | --- | --- | | React | `import { Trash2Icon } from "lucide-react"` | | Vue | `import { Trash2 } from "@lucide/vue"` | | Flutter | `Icon(LucideIcons.trash2)`, from `shadcn_ui` | ## Size - **16px** (`size-4`) inside controls and next to text: buttons, inputs, badges, menu items. - **20px** (`size-5`) in navigation: the sidebar, the bottom nav and the top bar. - **24px** (`size-6`) in empty states. ## Stroke and color - The stroke stays at Lucide's default of 2 in every product. Do not thin or thicken it per brand. - Icons take `currentColor`, so they follow the text color of their control. Color an icon by coloring its text, never with a fill. ## Accessibility - A decorative icon next to a label gets `aria-hidden="true"`. - A button that shows only an icon needs an `aria-label` and a [Tooltip](https://design.sosialoka.tech/components/tooltip/) with the same words. - Status icons (success, warning, error) always come with text. The icon never carries the meaning alone. ## Icon dictionary Use the same icon for the same action in every product. If an action is not listed, pick from Lucide and add it here. | Action | Lucide | React | Vue | Flutter | | --- | --- | --- | --- | --- | | Add | plus | PlusIcon | Plus | LucideIcons.plus | | Edit | pencil | PencilIcon | Pencil | LucideIcons.pencil | | Delete | trash-2 | Trash2Icon | Trash2 | LucideIcons.trash2 | | Search | search | SearchIcon | Search | LucideIcons.search | | Filter | list-filter | ListFilterIcon | ListFilter | LucideIcons.listFilter | | Sort | arrow-up-down | ArrowUpDownIcon | ArrowUpDown | LucideIcons.arrowUpDown | | Download | download | DownloadIcon | Download | LucideIcons.download | | Upload | upload | UploadIcon | Upload | LucideIcons.upload | | Notifications | bell | BellIcon | Bell | LucideIcons.bell | | Settings | settings | SettingsIcon | Settings | LucideIcons.settings | | Account | user | UserIcon | User | LucideIcons.user | | Sign out | log-out | LogOutIcon | LogOut | LucideIcons.logOut | | Release | disc | DiscIcon | Disc | LucideIcons.disc | | Royalties | chart-column | ChartColumnIcon | ChartColumn | LucideIcons.chartColumn | | Document | file-text | FileTextIcon | FileText | LucideIcons.fileText | | Song | music | MusicIcon | Music | LucideIcons.music | | Artist | mic-vocal | MicVocalIcon | MicVocal | LucideIcons.micVocal | | Link | link | LinkIcon | Link | LucideIcons.link | | Copy | copy | CopyIcon | Copy | LucideIcons.copy | | Close | x | XIcon | X | LucideIcons.x | | Back | chevron-left | ChevronLeftIcon | ChevronLeft | LucideIcons.chevronLeft | | Info | info | InfoIcon | Info | LucideIcons.info | | Success | circle-check | CircleCheckIcon | CircleCheck | LucideIcons.circleCheck | | Warning | triangle-alert | TriangleAlertIcon | TriangleAlert | LucideIcons.triangleAlert | | Error | circle-alert | CircleAlertIcon | CircleAlert | LucideIcons.circleAlert | --- # Spacing > A 4px spacing scale for padding, gaps and page layout. All spacing comes from one 4px scale, so padding and gaps line up across products. | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | space-1 | `--space-1` | 4px | Gap between an icon and its label. | | space-2 | `--space-2` | 8px | Padding inside small controls; gap between related items. | | space-3 | `--space-3` | 12px | Gap between form fields in a row. | | space-4 | `--space-4` | 16px | Card padding on mobile; gap between form fields. | | space-5 | `--space-5` | 20px | Page gutter on mobile. | | space-6 | `--space-6` | 24px | Card padding on desktop. | | space-8 | `--space-8` | 32px | Gap between page sections. | | space-10 | `--space-10` | 40px | Gap between large dashboard sections. | | space-12 | `--space-12` | 48px | Top spacing of a page header. | | space-16 | `--space-16` | 64px | Spacing around hero blocks. | In Tailwind v4 the base unit is `--spacing: 4px`, so `p-4` is 16px, the same as `space-4`. --- # Radius > Corner radius for controls, cards and dialogs. Corners grow with the size of the surface: controls are the tightest, dialogs the softest. | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | radius | `--radius` | 12px | shadcn base radius; equals radius-lg. | | radius-sm | `--radius-sm` | 6px | Badges, checkboxes and small chips. | | radius-md | `--radius-md` | 8px | Inputs and buttons. | | radius-lg | `--radius-lg` | 12px | Cards, including the floating search card. | | radius-xl | `--radius-xl` | 16px | Dialogs and sheets. | | radius-full | `--radius-full` | 9999px | Controls that are round by nature: avatars, switches, radios, progress bars, stepper circles, carousel dots and the drawer handle. Buttons are never pills, except the dashboard language selector. | - Inputs and buttons: `radius-md`. - Cards, including the dashboard's floating header card: `radius-lg`. - Dialogs and sheets: `radius-xl`. - Buttons follow the input radius and are never pills. `radius-full` is for controls that are round by nature (avatars, switches, radios, progress, carousel dots) and for the language pill in the dashboard header. --- # Elevation > Three shadow levels; borders separate cards first. Cards are set apart by a border first; a shadow marks something that floats above the page. ## Light | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | elevation-sm | `--elevation-sm` | 0 1px 2px 0 #1018280D | Selected tabs and slightly raised controls. | | elevation-md | `--elevation-md` | 0 1px 2px 0 #1018280A, 0 12px 32px -8px #10182814 | Cards that float, such as the dashboard search card. | | elevation-lg | `--elevation-lg` | 0 12px 30px -6px #10182838 | Menus, popovers, toasts and dialogs. | ## Dark | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | elevation-sm | `--elevation-sm` | 0 1px 3px 0 #00000059 | Selected tabs and slightly raised controls. | | elevation-md | `--elevation-md` | 0 1px 3px 0 #00000059, 0 12px 32px -8px #00000080 | Cards that float, such as the dashboard search card. | | elevation-lg | `--elevation-lg` | 0 12px 32px -4px #000000CC | Menus, popovers, toasts and dialogs. | ## Overlay Dialogs and sheets dim the page behind them with the `overlay` token, a translucent layer that is lighter in light mode and deeper in dark mode. | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | overlay | `--overlay` | #10182866 | Translucent layer behind dialogs and sheets. | | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | overlay | `--overlay` | #000000A3 | Translucent layer behind dialogs and sheets. | ## Use - The floating header card of the dashboard uses `elevation-md`. - Menus, popovers, toasts and dialogs use `elevation-lg`. - In Tailwind v4 the levels map to `shadow-sm`, `shadow-md` and `shadow-lg`. --- # Motion > Durations, easing curves and the login hero animation. Motion is quiet in the interface and saved for one orchestrated moment: the login hero. | Token | CSS variable | Value | Use | | --- | --- | --- | --- | | duration-fast | `--duration-fast` | 160ms | Hover and press feedback. | | duration-base | `--duration-base` | 300ms | Fades, color changes and small reveals. | | duration-slow | `--duration-slow` | 700ms | Lead text entering in the login hero. | | duration-sheet | `--duration-sheet` | 1050ms | Login hero sheet-in and sheet-out between chapters. | | duration-chapter | `--duration-chapter` | 7000ms | Time each login hero chapter stays on screen. | | ease-standard | `--ease-standard` | cubic-bezier(0.22, 1, 0.36, 1) | Default easing for entering elements. | | ease-expo | `--ease-expo` | cubic-bezier(0.16, 1, 0.3, 1) | Word-up and art-settle in the login hero. | | ease-in-out | `--ease-in-out` | cubic-bezier(0.76, 0, 0.24, 1) | Sheet transitions between login hero chapters. | ## Login hero The left half of every login screen is a brand moment that cycles through chapters. - Each chapter stays for `duration-chapter` (7 seconds). - A new chapter's sheet rises in over `duration-sheet` (1050ms) with `ease-in-out`. - Headline words rise one by one in 900ms with `ease-expo`, starting at 420ms with 40ms between words. - The illustration settles in 1300ms with `ease-expo`. - Progress bars show the current chapter, and a pause button stops the cycle. - The cycle pauses on hover, on keyboard focus and when the tab is hidden. - With `prefers-reduced-motion: reduce`, chapters switch without movement. - Below the `lg` breakpoint the hero is hidden and the form fills the screen. --- # Components > Sosialoka components for React and Vue, installed from the Sosialoka registry with the shadcn CLI. Sosialoka components are shadcn components with the Sosialoka tokens, radius and status colors built in, for React and Vue. React components are built on Base UI and installed with `shadcn`; Vue components are built on Reka UI and installed with `shadcn-vue`. Both copy the source into your project, so you own the code. ## Set up a project Install your product's theme first, then the components you need. The steps for React and Vue are on [Web](https://design.sosialoka.tech/web/#set-up-a-shadcn-project); a single component installs like this: ```bash npx shadcn@latest add https://design.sosialoka.tech/r/react/button.json npx shadcn-vue@latest add https://design.sosialoka.tech/r/vue/button.json ``` For Flutter, set up the `sosialoka_ui` package on [Flutter](https://design.sosialoka.tech/flutter/) and copy the code from each component's Flutter tab. ## Components ### Actions | Component | Use it for | | --- | --- | | [Button](https://design.sosialoka.tech/components/button/) | Starting an action. | | [Dropdown Menu](https://design.sosialoka.tech/components/dropdown-menu/) | Actions behind one button. | | [Command](https://design.sosialoka.tech/components/command/) | Searching from the keyboard, and the header search card. | ### Forms | Component | Use it for | | --- | --- | | [Input](https://design.sosialoka.tech/components/input/) | One line of text. | | [Input Group](https://design.sosialoka.tech/components/input-group/) | An input with an icon, text or a button attached, such as search or a password. | | [Textarea](https://design.sosialoka.tech/components/textarea/) | Several lines of text. | | [Label](https://design.sosialoka.tech/components/label/) | Naming a form control. | | [Field](https://design.sosialoka.tech/components/field/) | A label, a hint and the backend's error around one control. | | [Checkbox](https://design.sosialoka.tech/components/checkbox/) | Turning one option on or off. | | [Radio Group](https://design.sosialoka.tech/components/radio-group/) | Picking one of a few visible options. | | [Switch](https://design.sosialoka.tech/components/switch/) | A setting that applies right away. | | [Slider](https://design.sosialoka.tech/components/slider/) | Picking a value or a range on a track, such as a preview to cut. | | [Toggle Group](https://design.sosialoka.tech/components/toggle-group/) | Filter chips above a list, such as statuses. | | [Select](https://design.sosialoka.tech/components/select/) | Picking one value from a short list. | | [Combobox](https://design.sosialoka.tech/components/combobox/) | Picking from a long list by typing. | | [Calendar](https://design.sosialoka.tech/components/calendar/) | A month to pick a day from, on the page. | | [Date Picker](https://design.sosialoka.tech/components/date-picker/) | A date field that opens a calendar. | | [Input OTP](https://design.sosialoka.tech/components/input-otp/) | A one-time code in six boxes. | | [File Upload](https://design.sosialoka.tech/components/file-upload/) | Dropping or choosing files, with size and progress. | ### Display | Component | Use it for | | --- | --- | | [Badge](https://design.sosialoka.tech/components/badge/) | Showing a status or a short label. | | [Alert](https://design.sosialoka.tech/components/alert/) | A message that stays on the page, in a status color. | | [Card](https://design.sosialoka.tech/components/card/) | Grouping content on its own surface. | | [Carousel](https://design.sosialoka.tech/components/carousel/) | A row of cards to slide through, such as the latest releases. | | [Item](https://design.sosialoka.tech/components/item/) | A list row on phones and in panels. | | [Accordion](https://design.sosialoka.tech/components/accordion/) | Sections that open one at a time. | | [Separator](https://design.sosialoka.tech/components/separator/) | A thin line between groups. | | [Avatar](https://design.sosialoka.tech/components/avatar/) | A person or artist as a picture or initials. | | [Timeline](https://design.sosialoka.tech/components/timeline/) | What happened to a record, newest first. | ### Navigation | Component | Use it for | | --- | --- | | [Tabs](https://design.sosialoka.tech/components/tabs/) | Switching between views of the same content. | | [Breadcrumb](https://design.sosialoka.tech/components/breadcrumb/) | The path back from a deep page. | | [Stepper](https://design.sosialoka.tech/components/stepper/) | The steps of a flow and where you are. | | [Sidebar](https://design.sosialoka.tech/components/sidebar/) | The main navigation of a dashboard. | ### Data | Component | Use it for | | --- | --- | | [Table](https://design.sosialoka.tech/components/table/) | Records in rows and columns, with pagination. | | [Chart](https://design.sosialoka.tech/components/chart/) | Numbers over time or across categories, with a table of the same numbers. | ### Overlays | Component | Use it for | | --- | --- | | [Dialog](https://design.sosialoka.tech/components/dialog/) | A decision or a short form over the page. | | [Alert Dialog](https://design.sosialoka.tech/components/alert-dialog/) | Confirming an action that can't be undone. | | [Sheet](https://design.sosialoka.tech/components/sheet/) | Filters or details in a panel from the edge. | | [Drawer](https://design.sosialoka.tech/components/drawer/) | A bottom sheet on phones. | | [Popover](https://design.sosialoka.tech/components/popover/) | Extra content or a short task beside its trigger. | | [Tooltip](https://design.sosialoka.tech/components/tooltip/) | Naming an icon-only control. | ### Feedback | Component | Use it for | | --- | --- | | [Toast](https://design.sosialoka.tech/components/toast/) | Confirming an action. | | [Progress](https://design.sosialoka.tech/components/progress/) | How far an upload or import has come. | | [Spinner](https://design.sosialoka.tech/components/spinner/) | A short wait, or a button that is saving. | | [Skeleton](https://design.sosialoka.tech/components/skeleton/) | Placeholders while content loads. | ## Supporting items Some components install smaller Sosialoka items with them: `toggle` comes with Toggle Group, `pagination` with Table, `native-select` with the Vue Calendar (for its month and year pickers), and React components use the `use-mobile` hook. They follow the same tokens, so you can also use them on their own. --- # Button > Starts an action, such as saving a form or opening a dialog. A button starts an action on the current page; use a link when the action takes the person somewhere else. ## When to use - Use one `default` button for the main action of a form, card or dialog. - Use `secondary` or `outline` for the other actions next to it. - Use `ghost` in toolbars and dense rows, and `link` inside running text. - Use `destructive` only for actions that delete or cancel something. - Don't use a button to navigate to another page; use a link. _Live preview of the React and Vue versions: https://design.sosialoka.tech/components/button/_ ### Do and don't - **Do:** Use one default button for the main action; the others are outline or secondary. - **Don't:** Don't give two actions the same weight; people can't tell which one moves them forward. ## Anatomy 1. Container, on the control radius 2. Label 3. Outline variant for a second action A button is a label, with an optional icon before or after it. It sits on the control radius (`radius-md`, 8px) and is never a pill. ## Variants | Variant | Looks | Use it for | | --- | --- | --- | | `default` | `primary` fill, `primary-foreground` text | The main action. One per area. | | `secondary` | `secondary` fill | A second action with less weight. | | `outline` | `border` outline on `background` | Neutral actions next to the main one. | | `ghost` | No fill until hover | Toolbars, table rows, icon buttons. | | `destructive` | `destructive` text on a soft destructive fill | Delete, reject or cancel. | | `link` | `primary` text, underlined on hover | Actions inside a sentence. | Sizes: `xs`, `sm`, `default`, `lg`, and square `icon`, `icon-xs`, `icon-sm`, `icon-lg` for icon-only buttons. ## Props | React | Vue | Flutter | Type | Default | Use | | --- | --- | --- | --- | --- | --- | | `variant` | `variant` | named constructor (`ShadButton.outline`) | see Variants | `default` | Visual weight. | | `size` | `size` | `size` (`ShadButtonSize`) | see Variants | `default` | Height and padding. | | `disabled` | `disabled` | `enabled: false` | boolean | `false` | Blocks the action. | | `onClick` | `@click` | `onPressed` | function | none | Runs the action. | ## Code **React** ```tsx import { Button } from "@/components/ui/button" export default function ButtonDemo() { return (
) } ``` **Vue** ```vue ``` **Flutter** ```dart import 'package:flutter/widgets.dart'; import 'package:shadcn_ui/shadcn_ui.dart'; class ButtonDemo extends StatelessWidget { const ButtonDemo({super.key}); @override Widget build(BuildContext context) { return Wrap( spacing: 8, runSpacing: 8, children: [ ShadButton(onPressed: () {}, child: const Text('Simpan')), ShadButton.secondary(onPressed: () {}, child: const Text('Simpan draf')), ShadButton.outline(onPressed: () {}, child: const Text('Lihat detail')), ShadButton.ghost(onPressed: () {}, child: const Text('Batal')), ShadButton.destructive(onPressed: () {}, child: const Text('Hapus')), ShadButton.link(onPressed: () {}, child: const Text('Pelajari lebih lanjut')), ], ); } } ``` ## Install **React** ```bash npx shadcn@latest add https://design.sosialoka.tech/r/react/button.json ``` **Vue** ```bash npx shadcn-vue@latest add https://design.sosialoka.tech/r/vue/button.json ``` ## Accessibility - Renders a native `button`, so Enter and Space trigger it. - Every icon-only button needs an `aria-label`. - The focus ring uses `ring` and shows only for keyboard focus. - Keep the label to the action itself: "Simpan", not "Klik di sini". --- # Input > A single-line text field. An input takes one line of text, such as a name, an email address or a search term. ## When to use - Use it for short, free text. - Use [Select](https://design.sosialoka.tech/components/select/) when the answer comes from a short list. - Always pair it with a [Label](https://design.sosialoka.tech/components/label/); a placeholder is not a label. _Live preview of the React and Vue versions: https://design.sosialoka.tech/components/input/_ ### Do and don't - **Do:** Put the label above the field, where it stays while people type. - **Don't:** Don't use the placeholder as the label; it disappears as soon as people type. ## Anatomy 1. Label above the field 2. Field with an input border 3. Value 4. Caret Label above the field, the field itself, then an optional hint below it. The field uses `input` for its border, `radius-md` for its corners and `ring` for focus. ## Variants There is one style. Invalid fields set `aria-invalid`, which turns the border and the focus ring `destructive`. ## Props | React | Vue | Flutter | Type | Default | Use | | --- | --- | --- | --- | --- | --- | | `value` / `defaultValue` | `v-model` / `default-value` | `controller` / `initialValue` | string | none | The text. | | `type` | `type` | `keyboardType` | string | `text` | Keyboard and validation hints. | | `disabled` | `disabled` | `enabled: false` | boolean | `false` | Blocks typing. | | `aria-invalid` | `aria-invalid` | `validator` | boolean | `false` | Marks the value as wrong. | ## Code **React** ```tsx import { Input } from "@/components/ui/input" import { Label } from "@/components/ui/label" export default function InputDemo() { return (

Ke sini kami kirim kabar penting untukmu.

) } ``` **Vue** ```vue ``` **Flutter** ```dart import 'package:flutter/widgets.dart'; import 'package:shadcn_ui/shadcn_ui.dart'; class InputDemo extends StatelessWidget { const InputDemo({super.key}); @override Widget build(BuildContext context) { return ConstrainedBox( constraints: const BoxConstraints(maxWidth: 384), child: ShadInputFormField( id: 'email', label: const Text('Email'), keyboardType: TextInputType.emailAddress, description: const Text('Ke sini kami kirim kabar penting untukmu.'), ), ); } } ``` ## Install **React** ```bash npx shadcn@latest add https://design.sosialoka.tech/r/react/input.json ``` **Vue** ```bash npx shadcn-vue@latest add https://design.sosialoka.tech/r/vue/input.json ``` ## Accessibility - Link the label with `htmlFor` (React) or `for` (Vue) and the field's `id`. - Link the hint with `aria-describedby` so screen readers read it. - Error text comes from the backend; show it below the field and set `aria-invalid`. --- # Input Group > An input with buttons, icons or text attached. An input group attaches an icon, text or a small button to an input, inside one border. ## When to use - **Search:** a search icon before the input. - **Password:** a button after the input that shows or hides the password. This is the Sosialoka password field; there is no separate password component. - **Units and prefixes:** text such as `Rp` or `.id` before or after the value. - Don't put the main action of a form inside the group; it goes in the form footer. _Live preview of the React and Vue versions: https://design.sosialoka.tech/components/input-group/_ ## Anatomy 1. Leading icon 2. Input 3. Attached button 1. **Group** (`InputGroup`): one `input` border on `radius-md`, `h-9` tall. Focus on the input rings the whole group. 2. **Addon** (`InputGroupAddon`): an icon, text or button, at `inline-start` (before) or `inline-end` (after). 3. **Control** (`InputGroupInput` or `InputGroupTextarea`): the field itself, without its own border. ## Variants | Addon position | Use it for | | --- | --- | | `inline-start` | A search icon, a currency such as `Rp`. | | `inline-end` | The show-password button, a unit, a clear button. | | `block-start` / `block-end` | A label or actions above or below an `InputGroupTextarea`. | ## Props | React | Vue | Flutter | Type | Default | Use | | --- | --- | --- | --- | --- | --- | | `InputGroupAddon align` | `InputGroupAddon align` | `leading` / `trailing` on `ShadInput` | `inline-start`, `inline-end`, `block-start`, `block-end` | `inline-start` | Where the addon sits. | | `InputGroupButton size` | `InputGroupButton size` | `ShadIconButton` in `trailing` | `xs`, `sm`, `icon-xs`, `icon-sm` | `xs` | A small button inside the group. | | `type` on `InputGroupInput` | `type` on `InputGroupInput` | `obscureText` | text | `text` | `password` hides the text; `search` makes a search field. | ## Code **React** ```tsx import { useId, useState } from "react" import { EyeIcon, EyeOffIcon, SearchIcon } from "lucide-react" import { Field, FieldLabel } from "@/components/ui/field" import { InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput } from "@/components/ui/input-group" export default function InputGroupDemo() { const id = useId() const [visible, setVisible] = useState(false) return (
Kata sandi setVisible((v) => !v)} > {visible ? : }
) } ``` **Vue** ```vue ``` **Flutter** ```dart import 'package:flutter/widgets.dart'; import 'package:shadcn_ui/shadcn_ui.dart'; class InputGroupDemo extends StatefulWidget { const InputGroupDemo({super.key}); @override State createState() => _InputGroupDemoState(); } class _InputGroupDemoState extends State { bool visible = false; @override Widget build(BuildContext context) { return ConstrainedBox( constraints: const BoxConstraints(maxWidth: 384), child: Column( mainAxisSize: MainAxisSize.min, crossAxisAlignment: CrossAxisAlignment.stretch, spacing: 24, children: [ const ShadInput( placeholder: Text('Cari rilis'), leading: Icon(LucideIcons.search, size: 16), ), ShadInputFormField( id: 'password', label: const Text('Kata sandi'), obscureText: !visible, trailing: Semantics( label: visible ? 'Sembunyikan kata sandi' : 'Tampilkan kata sandi', toggled: visible, child: ShadIconButton.ghost( width: 24, height: 24, icon: Icon(visible ? LucideIcons.eyeOff : LucideIcons.eye, size: 16), onPressed: () => setState(() => visible = !visible), ), ), ), ], ), ); } } ``` ## Install **React** ```bash npx shadcn@latest add https://design.sosialoka.tech/r/react/input-group.json ``` **Vue** ```bash npx shadcn-vue@latest add https://design.sosialoka.tech/r/vue/input-group.json ``` ## Accessibility - The input keeps its own label: a visible label in a Field, or an `aria-label` such as "Cari rilis" for a search field with only an icon. - The show-password button says what it does: `aria-label` "Tampilkan kata sandi" / "Sembunyikan kata sandi", with `aria-pressed` while the password shows. - Icons in addons are decorative and need no label. --- # Textarea > A multi-line text field. A textarea takes text that runs over several lines, such as notes or a description, and grows with its content. ## When to use - Use it for notes, descriptions and messages. - Use an Input for one line, such as a name or a title. - Put it in a Field, with a hint that says the limit, such as "Paling banyak 500 karakter." _Live preview of the React and Vue versions: https://design.sosialoka.tech/components/textarea/_ ## Anatomy 1. Label 2. Field that grows with its text 3. Resize handle A box on `radius-md` with an `input` border, at least `min-h-16` tall, that grows with its content (`field-sizing-content`). Focus shows the `ring`; an invalid value turns the border `destructive`. ## Variants There is one style. ## Props | React | Vue | Flutter | Type | Default | Use | | --- | --- | --- | --- | --- | --- | | `value` / `defaultValue` | `v-model` / `default-value` | `controller` / `initialValue` | text | none | The text. | | `maxLength` | `maxlength` | `maxLength` | number | none | The longest text allowed. Say it in the hint too. | | `rows` | `rows` | `minHeight` | number | grows with content | The starting height. | | `aria-invalid` | `aria-invalid` | `forceErrorText` on `ShadTextareaFormField` | boolean | `false` | Marks a refused value. | | `disabled` | `disabled` | `enabled: false` | boolean | `false` | Blocks typing. | ## Code **React** ```tsx import { useId } from "react" import { Field, FieldDescription, FieldLabel } from "@/components/ui/field" import { Textarea } from "@/components/ui/textarea" export default function TextareaDemo() { const id = useId() return ( Catatan untuk tim