mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-08-22 17:56:43 +02:00
chore: no lint for html in md
This commit is contained in:
@@ -13,7 +13,13 @@
|
|||||||
},
|
},
|
||||||
"sourceType": "module"
|
"sourceType": "module"
|
||||||
},
|
},
|
||||||
"extends": ["eslint:recommended", "plugin:jsdoc/recommended", "plugin:json/recommended", "plugin:markdown/recommended", "plugin:prettier/recommended"],
|
"extends": [
|
||||||
|
"eslint:recommended",
|
||||||
|
"plugin:jsdoc/recommended",
|
||||||
|
"plugin:json/recommended",
|
||||||
|
"plugin:markdown/recommended",
|
||||||
|
"plugin:prettier/recommended"
|
||||||
|
],
|
||||||
"plugins": ["html", "jest", "jsdoc", "json", "prettier"],
|
"plugins": ["html", "jest", "jsdoc", "json", "prettier"],
|
||||||
"rules": {
|
"rules": {
|
||||||
"no-prototype-builtins": "off",
|
"no-prototype-builtins": "off",
|
||||||
@@ -35,6 +41,12 @@
|
|||||||
"no-undef": "off",
|
"no-undef": "off",
|
||||||
"jsdoc/require-jsdoc": "off"
|
"jsdoc/require-jsdoc": "off"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"files": "./**/*.md/*.html",
|
||||||
|
"rules": {
|
||||||
|
"prettier/prettier": "off"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@@ -402,7 +402,9 @@ click Shape2 call callbackFunction() "This is a tooltip for a callback"
|
|||||||
|
|
||||||
```html
|
```html
|
||||||
<script>
|
<script>
|
||||||
var callbackFunction = function(){ alert('A callback was triggered'); }
|
var callbackFunction = function () {
|
||||||
|
alert('A callback was triggered');
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -452,8 +454,14 @@ Beginners tip, a full example using interactive links in an html context:
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
var callback = function(){ alert('A callback was triggered'); }; var config = { startOnLoad:true,
|
var callback = function () {
|
||||||
securityLevel:'loose', }; mermaid.initialize(config);
|
alert('A callback was triggered');
|
||||||
|
};
|
||||||
|
var config = {
|
||||||
|
startOnLoad: true,
|
||||||
|
securityLevel: 'loose'
|
||||||
|
};
|
||||||
|
mermaid.initialize(config);
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
```
|
```
|
||||||
|
@@ -414,7 +414,9 @@ Examples of tooltip usage below:
|
|||||||
|
|
||||||
```html
|
```html
|
||||||
<script>
|
<script>
|
||||||
var callback = function(){ alert('A callback was triggered'); };
|
var callback = function () {
|
||||||
|
alert('A callback was triggered');
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -462,8 +464,18 @@ Beginners tip, a full example using interactive links in a html context:
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
var callback = function(){ alert('A callback was triggered'); }; var config = { startOnLoad:true,
|
var callback = function () {
|
||||||
flowchart:{ useMaxWidth:true, htmlLabels:true, curve:'cardinal', }, securityLevel:'loose', };
|
alert('A callback was triggered');
|
||||||
|
};
|
||||||
|
var config = {
|
||||||
|
startOnLoad: true,
|
||||||
|
flowchart: {
|
||||||
|
useMaxWidth: true,
|
||||||
|
htmlLabels: true,
|
||||||
|
curve: 'cardinal'
|
||||||
|
}
|
||||||
|
securityLevel:'loose'
|
||||||
|
};
|
||||||
mermaid.initialize(config);
|
mermaid.initialize(config);
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
@@ -565,14 +577,12 @@ below:
|
|||||||
|
|
||||||
**Example style**
|
**Example style**
|
||||||
|
|
||||||
```html
|
```css
|
||||||
<style>
|
.cssClass > rect {
|
||||||
.cssClass > rect{
|
fill: #FF0000;
|
||||||
fill:#FF0000;
|
stroke: #FFFF00;
|
||||||
stroke:#FFFF00;
|
stroke-width: 4px;
|
||||||
stroke-width:4px;
|
}
|
||||||
}
|
|
||||||
</style>
|
|
||||||
```
|
```
|
||||||
|
|
||||||
**Example definition**
|
**Example definition**
|
||||||
|
@@ -435,7 +435,9 @@ Examples of tooltip usage below:
|
|||||||
|
|
||||||
```html
|
```html
|
||||||
<script>
|
<script>
|
||||||
var callback = function(){ alert('A callback was triggered'); };
|
var callback = function () {
|
||||||
|
alert('A callback was triggered');
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -484,8 +486,14 @@ Beginners tip, a full example using interactive links in a html context:
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
var callback = function(){ alert('A callback was triggered'); }; var config = { startOnLoad:true,
|
var callback = function () {
|
||||||
flowchart:{ useMaxWidth:true, htmlLabels:true, curve:'cardinal', }, securityLevel:'loose', };
|
alert('A callback was triggered');
|
||||||
|
};
|
||||||
|
var config = {
|
||||||
|
startOnLoad: true,
|
||||||
|
flowchart: { useMaxWidth: true, htmlLabels: true, curve: 'cardinal' },
|
||||||
|
securityLevel:'loose'
|
||||||
|
};
|
||||||
mermaid.initialize(config);
|
mermaid.initialize(config);
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
|
@@ -28,6 +28,7 @@ gantt
|
|||||||
Task in sec :2014-01-12 , 12d
|
Task in sec :2014-01-12 , 12d
|
||||||
another task : 24d
|
another task : 24d
|
||||||
```
|
```
|
||||||
|
|
||||||
## Syntax
|
## Syntax
|
||||||
|
|
||||||
```mermaid-example
|
```mermaid-example
|
||||||
@@ -64,6 +65,7 @@ gantt
|
|||||||
```
|
```
|
||||||
|
|
||||||
It is possible to set multiple dependencies separated by space:
|
It is possible to set multiple dependencies separated by space:
|
||||||
|
|
||||||
```mermaid-example
|
```mermaid-example
|
||||||
gantt
|
gantt
|
||||||
apple :a, 2017-07-20, 1w
|
apple :a, 2017-07-20, 1w
|
||||||
@@ -82,10 +84,9 @@ You can divide the chart into various sections, for example to separate differen
|
|||||||
|
|
||||||
To do so, start a line with the `section` keyword and give it a name. (Note that unlike with the [title for the entire chart](#title), this name is *required*.
|
To do so, start a line with the `section` keyword and give it a name. (Note that unlike with the [title for the entire chart](#title), this name is *required*.
|
||||||
|
|
||||||
|
|
||||||
### Milestones
|
### Milestones
|
||||||
|
|
||||||
You can add milestones to the diagrams. Milestones differ from tasks as they represent a single instant in time and are identified by the keyword `milestone`. Below is an example on how to use milestones. As you may notice, the exact location of the milestone is determined by the initial date for the milestone and the "duration" of the task this way: *initial date*+*duration*/2.
|
You can add milestones to the diagrams. Milestones differ from tasks as they represent a single instant in time and are identified by the keyword `milestone`. Below is an example on how to use milestones. As you may notice, the exact location of the milestone is determined by the initial date for the milestone and the "duration" of the task this way: *initial date*+*duration*/2.
|
||||||
|
|
||||||
```mermaid-example
|
```mermaid-example
|
||||||
gantt
|
gantt
|
||||||
@@ -102,7 +103,6 @@ Final milestone : milestone, m2, 18:14, 2min
|
|||||||
|
|
||||||
`dateFormat` defines the format of the date **input** of your gantt elements. How these dates are represented in the rendered chart **output** are defined by `axisFormat`.
|
`dateFormat` defines the format of the date **input** of your gantt elements. How these dates are represented in the rendered chart **output** are defined by `axisFormat`.
|
||||||
|
|
||||||
|
|
||||||
### Input date format
|
### Input date format
|
||||||
|
|
||||||
The default input date format is `YYYY-MM-DD`. You can define your custom ``dateFormat``.
|
The default input date format is `YYYY-MM-DD`. You can define your custom ``dateFormat``.
|
||||||
@@ -331,9 +331,17 @@ Beginners tip, a full example using interactive links in an html context:
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
var printArguments = function(arg1, arg2, arg3) { alert('printArguments called with arguments: ' +
|
var printArguments = function(arg1, arg2, arg3) {
|
||||||
arg1 + ', ' + arg2 + ', ' + arg3); }; var printTask = function(taskId) { alert('taskId: ' + taskId);
|
alert('printArguments called with arguments: ' + arg1 + ', ' + arg2 + ', ' + arg3);
|
||||||
}; var config = { startOnLoad:true, securityLevel:'loose', }; mermaid.initialize(config);
|
}
|
||||||
|
var printTask = function(taskId) {
|
||||||
|
alert('taskId: ' + taskId);
|
||||||
|
}
|
||||||
|
var config = {
|
||||||
|
startOnLoad:true,
|
||||||
|
securityLevel:'loose',
|
||||||
|
};
|
||||||
|
mermaid.initialize(config);
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
```
|
```
|
||||||
|
Reference in New Issue
Block a user