From ClinicChartSettings.schema.yaml (cleo/ClinicChartSettings.schema
)
---
$id: https://skeleton.botmd.io/cleo/ClinicChartSettings.schema
$schema: http://json-schema.org/draft-07/schema#
title: Clinic Chart Settings
description: Schema for configuring the look and feel of a patient chart.
type: object
additionalProperties: false
required: [title, chartType, series]
properties:
title:
title: Title # So meta
description: Title of the chart for display to the user. Will be passed through i18n.
type: string
minLength: 1
#end title
subtitle:
title: Subtitle
description: subtitle of the chart for display to the user. Will be passed through i18n.
type: string
minLength: 1
#end subtitle
chartType:
title: Chart Type
description: Type of the chart, either `scatter`, `singleLine` or `multiLine`.
enum: [scatter, singleLine, multiLine]
#end chartType
key:
title: Key
description: key identifying which chart is being display. i.e HR, BP
type: string
minLength: 1
#end unit
combineClinicalParametersData:
title: combineClinicalParametersData
description: For example in the case of Alexandra, we combine the BG data Reading values with time taken (i.e After Meal, before Meal, etc...)
type: boolean
#end combineClinicalParametersData
manualSorting:
title: manualSorting
description: Use to determine if we do the sorting manually or use the predefined sorting functionality that comes with the library
type: boolean
#end manualSorting
legend:
title: Legend
description: Props for configuring the legend of the series. It will be passed to [`VictoryLegend`](https://formidable.com/open-source/victory/docs/victory-legend). If not specified, legends will not be used for the chart.
type: object
#end legend
unit:
title: Unit
description: Unit associated with the average result. i.e %, °C.
type: string
minLength: 1
#end unit
decimalPlaces:
title: DecimalPlaces
description: How many decimal places to show after each entry. ie. 1
type: number
minimum: 0
#end decimalPlaces
clinicalParameters:
title: Clinical Parameters
description: Clinical parameters that will be displayed on this chart. This will be used to filter submission values in GQL (and reduce network traffic). It can be either `name` or `uid` of parameter. Defaults to returning all parameter values.
type: array
minItems: 1
items:
type: string
minLength: 1
#end items
#end clinicalParameters
yAxis:
title: Y-Axis
description: Props for configuring the y-axis of the chart. It will be passed to [`VictoryAxis`](https://formidable.com/open-source/victory/docs/victory-axis#victoryaxis).
type: object
#end yAxis
tableViewColumns:
title: Table columns
description: Representation of the graph in table view, columns definition. The properties of these columns are similar to the table config
type: array
minItems: 1
items:
type: object
additionalProperties: true
required: []
#end tableViewColumns
series:
title: Series
description: Settings for each *series* to display in the chart.
type: array
minItems: 1
items:
type: object
additionalProperties: false
required: [title]
properties:
title:
title: Title
description: Title of the line / series. This will be used for default in legends, etc.
type: string
minLength: 1
#end title
symbolStyle:
title: Symbol Style
description: Props for configuring the symbols/data points of the series. It will be passed to the chart as [`style.data`](https://formidable.com/open-source/victory/docs/common-props#style).
type: object
#end symbolStyle
lineStyle:
title: Line Style
description: Props for configuring the line of the series. It will be passed to the chart as [`style.data`](https://formidable.com/open-source/victory/docs/common-props#style). This is only applicable for `line` charts.
type: object
#end lineStyle
tooltipTemplate:
title: Tooltip Template
description: >-
Template string defining how tooltips for data points are shown. Supported variables are:
- `${submission[uid]}`: UID of submission.
- `${submission[created_on]}`: Submission date of submission.
- `${submission_value[<name_with_group>]}`: Submission value for clinical parameter `name_with_group`. Example: `${submission_value[BP Systolic]}`.
- `${submission_value[<uid>]}`: Submission value for clinical parameter with UID `uid`. Example: `${submission_value[xxxxx123456789012345678901234567]}`.
type: string
minLength: 1
#end tooltipTemplate
#end series
#end properties