add css_color definition to color theme schema

This commit is contained in:
James Brumond 2022-10-17 23:12:57 -07:00
parent 1eea7b828e
commit ecdbb9fe2c
Signed by: james
GPG Key ID: 24BA25B8B303B023

View File

@ -12,210 +12,235 @@
"description": "Contains the values that will be used to populate the CSS variables controlling the UI theme", "description": "Contains the values that will be used to populate the CSS variables controlling the UI theme",
"properties": { "properties": {
"sun": { "sun": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"moon": { "moon": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_main": { "bg_main": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_light": { "bg_light": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_heavy": { "bg_heavy": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_popup_mask": { "bg_popup_mask": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"line": { "line": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_heading": { "text_heading": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_body": { "text_body": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_light": { "text_light": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_link": { "text_link": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_link_active": { "text_link_active": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_link_visited": { "text_link_visited": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_highlight": { "text_highlight": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_text_highlight": { "bg_text_highlight": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_selection": { "text_selection": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_text_selection": { "bg_text_selection": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_button_primary": { "bg_button_primary": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_button_primary_hover": { "bg_button_primary_hover": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_button_primary": { "text_button_primary": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_button_secondary": { "bg_button_secondary": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_button_secondary_hover": { "bg_button_secondary_hover": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_button_secondary": { "text_button_secondary": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_error_box": { "bg_error_box": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"border_error_box": { "border_error_box": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"text_error_box": { "text_error_box": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"bg_input": { "bg_input": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"border_input": { "border_input": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"border_input_invalid": { "border_input_invalid": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"icon_active_indicator": { "icon_active_indicator": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"icon_success_indicator": { "icon_success_indicator": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"icon_failure_indicator": { "icon_failure_indicator": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"icon_warning_indicator": { "icon_warning_indicator": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_axis": { "chart_axis": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_text": { "chart_text": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_guideline": { "chart_guideline": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_0": { "chart_data_0": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_1": { "chart_data_1": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_2": { "chart_data_2": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_3": { "chart_data_3": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_4": { "chart_data_4": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_5": { "chart_data_5": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_6": { "chart_data_6": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_7": { "chart_data_7": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_8": { "chart_data_8": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"chart_data_9": { "chart_data_9": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_normal": { "code_normal": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_shadow": { "code_shadow": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_background": { "code_background": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_selection": { "code_selection": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_comment": { "code_comment": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_punc": { "code_punc": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_operator": { "code_operator": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_const_literal": { "code_const_literal": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_number_literal": { "code_number_literal": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_boolean_literal": { "code_boolean_literal": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_tag": { "code_tag": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_string": { "code_string": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_keyword": { "code_keyword": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_func_name": { "code_func_name": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_class_name": { "code_class_name": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_regex_important": { "code_regex_important": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_variable": { "code_variable": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_builtin": { "code_builtin": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_attr_name": { "code_attr_name": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_gutter_divider": { "code_gutter_divider": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_line_number": { "code_line_number": {
"type": "string" "$ref": "#/definitions/css_color"
}, },
"code_line_highlight": { "code_line_highlight": {
"type": "string" "$ref": "#/definitions/css_color"
} }
} }
} }
},
"definitions": {
"css_color": {
"description": "A valid CSS color value (see https://developer.mozilla.org/en-US/docs/Web/CSS/color_value)",
"oneOf": [
{
"type": "string",
"format": "regex",
"pattern": "^(#[0-9a-fA-F]{3}(?:[0-9a-fA-F]{3}(?:[0-9a-fA-F]{2})?)?)$",
"examples": [ "#000", "#ff0000", "#ffccaa88" ]
},
{
"type": "string",
"format": "regex",
"pattern": "^(rgb\\(\\s*([0-9]{1,3})\\s*,\\s*([0-9]{1,3})\\s*,\\s*([0-9]{1,3})\\s*\\))$",
"examples": [ "rgb(10, 70, 130)" ]
},
{
"type": "string",
"format": "regex",
"pattern": "^(rgba\\(\\s*([0-9]{1,3})\\s*,\\s*([0-9]{1,3})\\s*,\\s*([0-9]{1,3})\\s*,\\s*([01]|[01]?\\.[0-9]{1,3})\\s*\\))$",
"examples": [ "rgba(10, 70, 130, 0.5)" ]
}
]
}
} }
} }