diff --git a/cypress/integration/diagramUpdate.spec.ts b/cypress/integration/diagramUpdate.spec.ts index 640e4e4e9d..b0075aa2f9 100644 --- a/cypress/integration/diagramUpdate.spec.ts +++ b/cypress/integration/diagramUpdate.spec.ts @@ -32,10 +32,12 @@ describe('Auto sync tests', () => { }); it('supports commenting code out/in', () => { - cy.get('#editor').type('{uparrow} {cmd}/'); + const cmd = Cypress.platform === 'darwin' ? 'meta' : 'ctrl'; + + cy.get('#editor').type(`{uparrow}{${cmd}}/`); cy.get('#view').contains('Car').should('not.exist'); - cy.get('#editor').type('{uparrow} {cmd}/'); + cy.get('#editor').type(`{uparrow}{${cmd}}/`); cy.get('#view').contains('Car').should('exist'); }); }); diff --git a/cypress/snapshots.js b/cypress/snapshots.js index d023001fe4..95cbdd6ee8 100644 --- a/cypress/snapshots.js +++ b/cypress/snapshots.js @@ -16,7 +16,7 @@ module.exports = { "1": "{\"code\":\"graph TD\\n A[Party] -->|Get money| B(Go shopping!!)\\n \",\"mermaid\":\"{\\n \\\"theme\\\": \\\"forest\\\",\\n \\\"test\\\": \\\"hello world\\\"\\n}\",\"updateEditor\":false,\"autoSync\":true,\"updateDiagram\":true,\"loader\":{\"type\":\"files\",\"config\":{\"codeURL\":\"https://gist.githubusercontent.com/sidharthv96/6268a23e673a533dcb198f241fd7012a/raw/4eb03887e6a41397e80bdcdbf94017c498f8f1e2/code.mmd\",\"configURL\":\"https://gist.githubusercontent.com/sidharthv96/6268a23e673a533dcb198f241fd7012a/raw/4eb03887e6a41397e80bdcdbf94017c498f8f1e2/config.json\"}}}" } }, - "__version": "9.2.0", + "__version": "9.3.1", "Auto sync tests": { "should dim diagram when code is edited": { "1": "{\"code\":\"graph TD\\n A[Christmas] -->|Get money| B(Go shopping)\\n B --> C{Let me think}\\n C -->|One| D[Laptop]\\n C -->|Two| E[iPhone]\\n C -->|Three| F[fa:fa-car Car]\\n C --> Test\",\"mermaid\":\"{\\n \\\"theme\\\": \\\"default\\\"\\n}\",\"updateEditor\":false,\"autoSync\":false,\"updateDiagram\":false}" diff --git a/package.json b/package.json index 79ab0ce8ec..a38aeac5eb 100644 --- a/package.json +++ b/package.json @@ -58,7 +58,7 @@ "mermaid": "8.13.10", "moment": "^2.29.1", "monaco-editor": "^0.31.1", - "monaco-mermaid": "^1.0.2", + "monaco-mermaid": "^1.0.3", "pako": "2.0.4", "random-word-slugs": "^0.1.6" }, diff --git a/yarn.lock b/yarn.lock index feeaeaad4f..c59d9ebe1c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3155,7 +3155,7 @@ monaco-editor@^0.31.1: resolved "https://registry.yarnpkg.com/monaco-editor/-/monaco-editor-0.31.1.tgz#67f597b3e45679d1f551237e12a3a42c4438b97b" integrity sha512-FYPwxGZAeP6mRRyrr5XTGHD9gRXVjy7GUzF4IPChnyt3fS5WrNxIkS8DNujWf6EQy0Zlzpxw8oTVE+mWI2/D1Q== -monaco-mermaid@^1.0.2: +monaco-mermaid@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/monaco-mermaid/-/monaco-mermaid-1.0.3.tgz#807bf5a0635723684029646b716a2ba97dd6a175" integrity sha512-SOtoCXxfUXCh8j09OhgambkQ8eqbifaK2YYt2lAo5YXIk/iRXdprvBVhLOJNx1gTMtRNINixALGaTy5StYfiqw==