mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-20 07:49:43 +02:00
Cleanup runTime.ts
This commit is contained in:
6
.github/workflows/e2e.yml
vendored
6
.github/workflows/e2e.yml
vendored
@@ -69,9 +69,6 @@ jobs:
|
|||||||
start: pnpm run dev
|
start: pnpm run dev
|
||||||
wait-on: 'http://localhost:9000'
|
wait-on: 'http://localhost:9000'
|
||||||
browser: chrome
|
browser: chrome
|
||||||
spec: |
|
|
||||||
cypress/integration/rendering/classDiagram.spec.js
|
|
||||||
cypress/integration/rendering/flowchart-v2.spec.js
|
|
||||||
|
|
||||||
- name: Move runtime data
|
- name: Move runtime data
|
||||||
if: ${{ steps.cache-snapshot.outputs.cache-hit != 'true' }}
|
if: ${{ steps.cache-snapshot.outputs.cache-hit != 'true' }}
|
||||||
@@ -148,9 +145,6 @@ jobs:
|
|||||||
# e.g. if this action was run from a fork
|
# e.g. if this action was run from a fork
|
||||||
record: ${{ secrets.CYPRESS_RECORD_KEY != '' }}
|
record: ${{ secrets.CYPRESS_RECORD_KEY != '' }}
|
||||||
parallel: ${{ secrets.CYPRESS_RECORD_KEY != '' }}
|
parallel: ${{ secrets.CYPRESS_RECORD_KEY != '' }}
|
||||||
spec: |
|
|
||||||
cypress/integration/rendering/classDiagram.spec.js
|
|
||||||
cypress/integration/rendering/flowchart-v2.spec.js
|
|
||||||
env:
|
env:
|
||||||
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
|
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
|
||||||
VITEST_COVERAGE: true
|
VITEST_COVERAGE: true
|
||||||
|
@@ -114,19 +114,18 @@ const htmlTable = (data: string[][]): string => {
|
|||||||
let table = `<table border='1' style="border-collapse: collapse">`;
|
let table = `<table border='1' style="border-collapse: collapse">`;
|
||||||
|
|
||||||
// Generate table header
|
// Generate table header
|
||||||
table += '<tr>';
|
table += `<tr>
|
||||||
for (const header of data[0]) {
|
${data
|
||||||
table += `<th>${header}</th>`;
|
.shift()!
|
||||||
}
|
.map((header) => `<th>${header}</th>`)
|
||||||
table += '</tr>';
|
.join('')}
|
||||||
|
</tr>`;
|
||||||
|
|
||||||
// Generate table rows
|
// Generate table rows
|
||||||
for (let i = 1; i < data.length; i++) {
|
for (const row of data) {
|
||||||
table += '<tr>';
|
table += `<tr>
|
||||||
for (let j = 0; j < data[i].length; j++) {
|
${row.map((cell) => `<td>${cell}</td>`).join('')}
|
||||||
table += `<td>${data[i][j]}</td>`;
|
</tr>`;
|
||||||
}
|
|
||||||
table += '</tr>';
|
|
||||||
}
|
}
|
||||||
|
|
||||||
table += '</table>';
|
table += '</table>';
|
||||||
|
Reference in New Issue
Block a user