From c394d068fdd33537765ebd761f74ee7479166322 Mon Sep 17 00:00:00 2001 From: Benoit Perigaud <8754100+b-per@users.noreply.github.com> Date: Wed, 18 Jan 2023 23:55:51 +0100 Subject: [PATCH] Add the ability to define `docs` config (#26) * Add the ability to define `docs` config Add the schema for `docs` to define the nodes colors: https://docs.getdbt.com/reference/resource-configs/docs * Add regex for valid `node_color` --- schemas/dbt_project.json | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/schemas/dbt_project.json b/schemas/dbt_project.json index e4c0c71..cfeb594 100644 --- a/schemas/dbt_project.json +++ b/schemas/dbt_project.json @@ -234,6 +234,9 @@ }, "+tags": { "$ref": "#/$defs/string_or_array_of_strings" + }, + "+docs": { + "$ref": "#/$defs/docs_config" } }, "additionalProperties": { @@ -363,6 +366,23 @@ "additionalProperties": { "$ref": "#/$defs/test_configs" } + }, + "docs_config": { + "title": "Docs config", + "type": "object", + "description": "Configurations for the appearance of nodes in the dbt documentation.", + "properties": { + "node_color": { + "type": "string", + "description": "The color of the node on the DAG in the documentation. It must be an Hex code or a valid CSS color name.", + "pattern": "^(#[a-fA-F0-9]{3}|#[a-fA-F0-9]{6}|[^#][a-zA-Z]*)$" + }, + "show": { + "type": "boolean", + "default": true + } + }, + "additionalProperties": false } } }