主题
Gantt Diagram Config Schema
txt
https://mermaid.js.org/schemas/config.schema.json#/$defs/GanttDiagramConfig
包含特定于甘特图的配置的对象
Abstract | Extensible | Status | Identifiable | Custom Properties | Additional Properties | Access Restrictions | Defined In |
---|---|---|---|---|---|---|---|
Can be instantiated | No | Unknown status | No | Forbidden | Allowed | none | config.schema.json* |
GanttDiagramConfig Type
object
(Gantt Diagram Config)
all of
GanttDiagramConfig Properties
Property | Type | Required | Nullable | Defined by |
---|---|---|---|---|
titleTopMargin | integer | Required | cannot be null | Mermaid Config |
barHeight | integer | Required | cannot be null | Mermaid Config |
barGap | integer | Optional | cannot be null | Mermaid Config |
topPadding | integer | Required | cannot be null | Mermaid Config |
rightPadding | integer | Required | cannot be null | Mermaid Config |
leftPadding | integer | Required | cannot be null | Mermaid Config |
gridLineStartPadding | integer | Required | cannot be null | Mermaid Config |
fontSize | integer | Required | cannot be null | Mermaid Config |
sectionFontSize | integer | Required | cannot be null | Mermaid Config |
numberSectionStyles | integer | Required | cannot be null | Mermaid Config |
axisFormat | string | Required | cannot be null | Mermaid Config |
tickInterval | string | Optional | cannot be null | Mermaid Config |
topAxis | boolean | Required | cannot be null | Mermaid Config |
displayMode | string | Optional | cannot be null | Mermaid Config |
weekday | string | Required | cannot be null | Mermaid Config |
titleTopMargin
图表上方文本的顶部边距
titleTopMargin
is required
Type:
integer
cannot be null
defined in: Mermaid Config
titleTopMargin Type
integer
titleTopMargin Constraints
minimum: the value of this number must greater than or equal to: 0
titleTopMargin Default Value
The default value is:
json
25
barHeight
图形中条形的高度
barHeight
is required
Type:
integer
cannot be null
defined in: Mermaid Config
barHeight Type
integer
barHeight Constraints
minimum: the value of this number must greater than or equal to: 0
barHeight Default Value
The default value is:
json
20
barGap
甘特图中不同活动之间的边距
barGap
is optional
Type:
integer
cannot be null
defined in: Mermaid Config
barGap Type
integer
barGap Constraints
minimum: the value of this number must greater than or equal to: 0
barGap Default Value
The default value is:
json
4
topPadding
标题和甘特图之间以及轴和甘特图之间的边距。
topPadding
is required
Type:
integer
cannot be null
defined in: Mermaid Config
topPadding Type
integer
topPadding Constraints
minimum: the value of this number must greater than or equal to: 0
topPadding Default Value
The default value is:
json
50
rightPadding
分配给活动右侧部分名称的空间
rightPadding
is required
Type:
integer
cannot be null
defined in: Mermaid Config
rightPadding Type
integer
rightPadding Constraints
minimum: the value of this number must greater than or equal to: 0
rightPadding Default Value
The default value is:
json
75
leftPadding
分配给活动左侧部分名称的空间
leftPadding
is required
Type:
integer
cannot be null
defined in: Mermaid Config
leftPadding Type
integer
leftPadding Constraints
minimum: the value of this number must greater than or equal to: 0
leftPadding Default Value
The default value is:
json
75
gridLineStartPadding
网格线的垂直起始位置
gridLineStartPadding
is required
Type:
integer
cannot be null
defined in: Mermaid Config
gridLineStartPadding Type
integer
gridLineStartPadding Constraints
minimum: the value of this number must greater than or equal to: 0
gridLineStartPadding Default Value
The default value is:
json
35
fontSize
字体大小
fontSize
is required
Type:
integer
cannot be null
defined in: Mermaid Config
fontSize Type
integer
fontSize Constraints
minimum: the value of this number must greater than or equal to: 0
fontSize Default Value
The default value is:
json
11
sectionFontSize
各部分的字体大小
sectionFontSize
is required
Type:
integer
cannot be null
defined in: Mermaid Config
tsType:
string | number
sectionFontSize Type
integer
sectionFontSize Constraints
minimum: the value of this number must greater than or equal to: 0
sectionFontSize Default Value
The default value is:
json
11
numberSectionStyles
交替部分样式的数量
numberSectionStyles
is required
Type:
integer
cannot be null
defined in: Mermaid Config
numberSectionStyles Type
integer
numberSectionStyles Constraints
minimum: the value of this number must greater than or equal to: 0
numberSectionStyles Default Value
The default value is:
json
4
axisFormat
轴的日期/时间格式这可能需要调整以匹配你的语言环境和首选项。
axisFormat
is required
Type:
string
cannot be null
defined in: Mermaid Config
axisFormat Type
string
axisFormat Default Value
The default value is:
json
"%Y-%m-%d"
tickInterval
轴刻度
Pattern is:
javascript
/^([1-9][0-9]*)(millisecond|second|minute|hour|day|week|month)$/;
tickInterval
is optional
Type:
string
cannot be null
defined in: Mermaid Config
tickInterval Type
string
tickInterval Constraints
pattern: the string must match the following regular expression:
javascript
/^([1-9][0-9]*)(millisecond|second|minute|hour|day|week|month)$/
topAxis
设置此标志后,日期标签将添加到图表顶部
topAxis
is required
Type:
boolean
cannot be null
defined in: Mermaid Config
topAxis Type
boolean
displayMode
控制显示模式。
displayMode
is optional
Type:
string
cannot be null
defined in: Mermaid Config
displayMode Type
string
displayMode Constraints
enum: the value of this property must be equal to one of the following values:
Value | Explanation |
---|---|
"" | |
"compact" | Enables displaying multiple tasks on the same row. |
weekday
基于一周的间隔应在哪一天开始
weekday
is required
Type:
string
cannot be null
defined in: Mermaid Config
weekday Type
string
weekday Constraints
enum: the value of this property must be equal to one of the following values:
Value | Explanation |
---|---|
"monday" | |
"tuesday" | |
"wednesday" | |
"thursday" | |
"friday" | |
"saturday" | |
"sunday" |
weekday Default Value
The default value is:
json
"sunday"