From 2649b9b859f5b2ef8fb9ddd324b665480e305f6e Mon Sep 17 00:00:00 2001 From: Ville Brofeldt Date: Mon, 30 Sep 2024 14:21:28 -0700 Subject: [PATCH] docs(dashboard): add docs for named and index colors --- docs/docs/faq.mdx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/docs/docs/faq.mdx b/docs/docs/faq.mdx index 2fe0df7238c19..e7b166bb212fa 100644 --- a/docs/docs/faq.mdx +++ b/docs/docs/faq.mdx @@ -174,13 +174,16 @@ You can take a look at this Flask-AppBuilder ## Is there a way to force the dashboard to use specific colors? It is possible on a per-dashboard basis by providing a mapping of labels to colors in the JSON -Metadata attribute using the `label_colors` key. +Metadata attribute using the `label_colors` key. You can use either the full hex color, a named color, +like `red`, `coral` or `lightblue`, or the index in the current color palette (0 for first color, 1 for +second etc). Example: ```json { "label_colors": { - "Girls": "#FF69B4", - "Boys": "#ADD8E6" + "foo": "#FF69B4", + "bar": "lightblue", + "baz": 0 } } ```