{"componentChunkName":"component---src-templates-simple-markdown-js","path":"/developer-portal/colors/","matchPath":"","result":{"data":{"markdownRemark":{"html":"<h1 style=\"position:relative;\"><a href=\"#colors\" aria-label=\"colors permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a><div class=\"hidden-anchor\" id=\"colors\"></div>Colors</h1>\n<blockquote>\n<p>“Color is a power which directly influences the soul.” - Wassily Kandinsky</p>\n</blockquote>\n<p>Colors are set within the <code class=\"language-text\">theme.ts</code> file.\nThe <code class=\"language-text\">theme.ts</code> file contains a typescript variable named <code class=\"language-text\">theme</code> which controls the colors, styles and typography.</p>\n<div class=\"code-wrapper\">\n        <div class=\"gatsby-code-button-container\"\n             data-toaster-id=\"82993558577481580000\"\n             data-toaster-duration=\"1500\"\n             onClick=\"copyCodeToClipboard(`export const theme = {`, `82993558577481580000`)\"\n        >\n          <div class=\"gatsby-code-button\" title=\"Copy the code snippet\">Copy</div>\n          <div class=\"done-indicator done-indicator-82993558577481580000\">Copied</div>\n        </div>\n        <div class=\"gatsby-highlight\" data-language=\"ts\"><pre class=\"language-ts\"><code class=\"language-ts\"><span class=\"token keyword\">export</span> <span class=\"token keyword\">const</span> theme <span class=\"token operator\">=</span> <span class=\"token punctuation\">{</span></code></pre></div>\n      </div>\n<p>The included <code class=\"language-text\">theme.ts</code> includes all of the configuration options (most are commented out as default settings with two slashes <code class=\"language-text\">//</code>).\nUncomment them to override the theme.</p>\n<h2 style=\"position:relative;\"><a href=\"#change-the-primary-color\" aria-label=\"change the primary color permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a><div class=\"hidden-anchor\" id=\"change-the-primary-color\"></div>Change the primary color</h2>\n<p>Find this section of the theme file.</p>\n<div class=\"code-wrapper\">\n        <div class=\"gatsby-code-button-container\"\n             data-toaster-id=\"32276605636221633000\"\n             data-toaster-duration=\"1500\"\n             onClick=\"copyCodeToClipboard(`  colors: {\n    // tonalOffset: 0.2,\n    primary: {\n      main: '#FFFFFF',\n      // light: ({ colors }) => lighten(colors.tonalOffset, colors.primary.main),\n      // dark: ({ colors }) => darken(colors.tonalOffset, colors.primary.main),\n      // contrastText: ({ colors }) => readableColor(colors.primary.main),\n    },`, `32276605636221633000`)\"\n        >\n          <div class=\"gatsby-code-button\" title=\"Copy the code snippet\">Copy</div>\n          <div class=\"done-indicator done-indicator-32276605636221633000\">Copied</div>\n        </div>\n        <div class=\"gatsby-highlight\" data-language=\"ts\"><pre class=\"language-ts\"><code class=\"language-ts\">  colors<span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n    <span class=\"token comment\">// tonalOffset: 0.2,</span>\n    primary<span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n      main<span class=\"token operator\">:</span> <span class=\"token string\">'#FFFFFF'</span><span class=\"token punctuation\">,</span>\n      <span class=\"token comment\">// light: ({ colors }) => lighten(colors.tonalOffset, colors.primary.main),</span>\n      <span class=\"token comment\">// dark: ({ colors }) => darken(colors.tonalOffset, colors.primary.main),</span>\n      <span class=\"token comment\">// contrastText: ({ colors }) => readableColor(colors.primary.main),</span>\n    <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span></code></pre></div>\n      </div>\n<p>Change the color.\nNot sure what to change it to?\nTry randomly guessing a hexadecimal value (0-9 and a-f are valid values).\nIt also accepts human friendly colors like <code class=\"language-text\">orange</code>.</p>\n<h2 style=\"position:relative;\"><a href=\"#change-the-primary-text-color\" aria-label=\"change the primary text color permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a><div class=\"hidden-anchor\" id=\"change-the-primary-text-color\"></div>Change the primary text color</h2>\n<p>Or not...</p>\n<div class=\"code-wrapper\">\n        <div class=\"gatsby-code-button-container\"\n             data-toaster-id=\"99791139067609970000\"\n             data-toaster-duration=\"1500\"\n             onClick=\"copyCodeToClipboard(`    text: {\n      primary: '#FFFFFF',\n      // secondary: '#4e566d',\n    },`, `99791139067609970000`)\"\n        >\n          <div class=\"gatsby-code-button\" title=\"Copy the code snippet\">Copy</div>\n          <div class=\"done-indicator done-indicator-99791139067609970000\">Copied</div>\n        </div>\n        <div class=\"gatsby-highlight\" data-language=\"ts\"><pre class=\"language-ts\"><code class=\"language-ts\">    text<span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n      primary<span class=\"token operator\">:</span> <span class=\"token string\">'#FFFFFF'</span><span class=\"token punctuation\">,</span>\n      <span class=\"token comment\">// secondary: '#4e566d',</span>\n    <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span></code></pre></div>\n      </div>\n<h2 style=\"position:relative;\"><a href=\"#change-the-footer-background-color\" aria-label=\"change the footer background color permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a><div class=\"hidden-anchor\" id=\"change-the-footer-background-color\"></div>Change the footer background color</h2>\n<p>Pick a color.</p>\n<p>Or change any other colors you want.</p>\n<div class=\"code-wrapper\">\n        <div class=\"gatsby-code-button-container\"\n             data-toaster-id=\"46792541170445844000\"\n             data-toaster-duration=\"1500\"\n             onClick=\"copyCodeToClipboard(`    footer: {\n      main: '#FFFFFF',\n      // main: ({ colors }) => colors.primary.main,\n      contrastText: 'white'\n    },`, `46792541170445844000`)\"\n        >\n          <div class=\"gatsby-code-button\" title=\"Copy the code snippet\">Copy</div>\n          <div class=\"done-indicator done-indicator-46792541170445844000\">Copied</div>\n        </div>\n        <div class=\"gatsby-highlight\" data-language=\"ts\"><pre class=\"language-ts\"><code class=\"language-ts\">    footer<span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n      main<span class=\"token operator\">:</span> <span class=\"token string\">'#FFFFFF'</span><span class=\"token punctuation\">,</span>\n      <span class=\"token comment\">// main: ({ colors }) => colors.primary.main,</span>\n      contrastText<span class=\"token operator\">:</span> <span class=\"token string\">'white'</span>\n    <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span></code></pre></div>\n      </div>\n<h2 style=\"position:relative;\"><a href=\"#free-time\" aria-label=\"free time permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a><div class=\"hidden-anchor\" id=\"free-time\"></div>Free time</h2>\n<p>Play with some various colors.</p>\n<p>Notice you can use typescript to calculate colors, if you wish.\nThat is beyond the scope of this training exercise.</p>","headings":[{"value":"Colors","depth":1},{"value":"Change the primary color","depth":2},{"value":"Change the primary text color","depth":2},{"value":"Change the footer background color","depth":2},{"value":"Free time","depth":2}]},"contentItem":{"data":{"lastModified":"2025-12-17T21:55:39.000Z","enableToc":null,"disableLastModified":null,"tocMaxDepth":null,"requestLogin":false}},"siteConfig":{"enableToc":true,"disableLastModified":false,"tocMaxDepth":4}},"pageContext":{"matchPath":"","id":"a3eab4a0-49ce-5850-9c11-eb7b982febc8__redocly content/developer-portal/colors/","seo":{"title":"Colors","description":null,"image":"","keywords":null,"jsonLd":null,"lang":null},"pageId":"developer-portal/colors.md","pageBaseUrl":"/developer-portal/colors","type":"markdown","toc":{"enable":true,"maxDepth":4,"headings":[{"depth":1,"value":"Colors","id":"colors"},{"depth":2,"value":"Change the primary color","id":"change-the-primary-color"},{"depth":2,"value":"Change the primary text color","id":"change-the-primary-text-color"},{"depth":2,"value":"Change the footer background color","id":"change-the-footer-background-color"},{"depth":2,"value":"Free time","id":"free-time"}]},"data":{"title":""},"catalogInfo":null,"link":"/developer-portal/colors/","sidebarName":"","isLanding":false,"showPrevButton":null,"showNextButton":null,"apiVersions":null,"apiVersionId":null,"isDefaultApiVersion":null}},"staticQueryHashes":["1123603147","1180902673","1302185487","1344209882","1398840060","1520077861","1975142765","2667623876","2950305614","3743992808","561138138"]}