Skip to content

[CPL-19563] add tabs, dateRangeFilter opts #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
99 changes: 60 additions & 39 deletions 202412121147.json
Original file line number Diff line number Diff line change
Expand Up @@ -408,44 +408,6 @@
}
]
},
"funnel": {
"allOf": [
{ "$ref": "#/$defs/commonComponent" },
{
"type": "object",
"properties": {
"type": {
"type": "string",
"const": "funnel"
},
"series": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "The name of the series as shown in the legend, tooltip etc. See e.g. https://api.highcharts.com/highcharts/series.line.name"
},
"type": {
"type": "string",
"description": "Set series type if the chart is a combination of different series types. See https://www.highcharts.com/docs/chart-and-series-types/combining-chart-types"
},
"query": {
"$ref": "#/$defs/query"
}
},
"required": ["query"]
}
},
"format": {
"$ref": "#/$defs/formatProperties"
}
},
"required": ["type", "series"]
}
]
},
"pie-chart": {
"allOf": [
{ "$ref": "#/$defs/commonComponent" },
Expand Down Expand Up @@ -785,6 +747,46 @@
]
}
},
"tabs": {
"type": "array",
"minItems": 1,
"items": {
"type": "object",
"properties": {
"title": {
"type": "string",
"description": "The title of the tab"
},
"layout": {
"$ref": "#/$defs/layout"
},
"insights": {
"type": "array",
"description": "Components to use for insights.",
"items": { "$ref": "#/$defs/insights" }
},
"components": {
"type": "array",
"description": "Components to render on the dashboard.",
"items": {
"oneOf": [
{ "$ref": "#/$defs/scorecard" },
{ "$ref": "#/$defs/chart" },
{ "$ref": "#/$defs/pie-chart" },
{ "$ref": "#/$defs/table" },
{ "$ref": "#/$defs/bar-chart" },
{ "$ref": "#/$defs/map" },
{ "$ref": "#/$defs/gauge" },
{ "$ref": "#/$defs/funnel" },
{ "$ref": "#/$defs/header" }
]
}
}
},
"required": ["title", "layout", "components"],
"additionalProperties": false
}
},
"dateRangeFilter": {
"type": "object",
"description": "Date range filter options.",
Expand All @@ -798,7 +800,18 @@
"type": "integer",
"description": "The number of days in the past to show data for.",
"default": 31
},
"monthsInThePast": {
"type": "integer",
"description": "The number of months in the past to show data for. Needs precision to be specified."
},
"precision": {
"enum": ["fullToFull", "fullToDate", "dateToDate"],
"description": "Precision of the date range to be applied for data filtering:\nfullToFull - from the first day of 'n' last month to last day of last month,\nfullToDate - from the first day of 'n' last month to today,\ndateToDate - from day 'n' months ago to today"
}
},
"dependentRequired": {
"monthsInThePast": ["precision"]
}
},
"rowFilterDisabled": {
Expand All @@ -816,5 +829,13 @@
}
}
},
"required": ["schemaVersion", "layout", "components"]
"required": ["schemaVersion"],
"oneOf": [
{
"required": ["layout", "components"]
},
{
"required": ["tabs"]
}
]
}