# Colors

In order to define color tokens in your project, add `colors` property in `shopstory/config.ts`:

```typescript
export const shopstoryConfig = {
  //...
  colors: [
    {
      id: "green",
      label: "Green",
      value: "#83d1c4",
    },
    {
      id: "purple",
      label: "Purple",
      value: "#78517c",
    },
    {
      id: "orange",
      label: "Orange",
      value: "#f17950",
    },
    {
      id: "black",
      label: "Black",
      value: "#000000",
      mapTo: ["$dark", "$backgroundDark"] // black mapped to 2 master tokens
    },
    {
      id: "white",
      label: "White",
      value: "#ffffff",
      mapTo: ["$light", "$backgroundLight"] // white mapped to 2 master tokens
    }
  ],
}
```

## Master tokens

Shopstory comes with 4 color master tokens:

<table><thead><tr><th width="225">Token</th><th>Description</th></tr></thead><tbody><tr><td><code>$dark</code></td><td>Dark foreground text displayed on light backgrounds, usually black.</td></tr><tr><td><code>$light</code></td><td>Light foreground text displayed on dark backgrounds, usually white. </td></tr><tr><td><code>$backgroundDark</code></td><td>Primary dark background color</td></tr><tr><td><code>$backgroundLight</code></td><td>Primary light background color</td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.shopstory.app/design-tokens/colors.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
