first commit
This commit is contained in:
4
services/web/cypress/support/ct/codemirror.ts
Normal file
4
services/web/cypress/support/ct/codemirror.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import { EditorView } from '@codemirror/view'
|
||||
|
||||
// @ts-ignore (disable EditContext-based editing until stable)
|
||||
EditorView.EDIT_CONTEXT = false
|
14
services/web/cypress/support/ct/commands/index.ts
Normal file
14
services/web/cypress/support/ct/commands/index.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import { mount } from 'cypress/react'
|
||||
|
||||
// eslint-disable-next-line no-unused-vars,@typescript-eslint/no-namespace
|
||||
declare global {
|
||||
// eslint-disable-next-line @typescript-eslint/no-namespace,no-unused-vars
|
||||
namespace Cypress {
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
interface Chainable {
|
||||
mount: typeof mount
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Cypress.Commands.add('mount', mount)
|
16
services/web/cypress/support/ct/window.ts
Normal file
16
services/web/cypress/support/ct/window.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
export function resetMeta() {
|
||||
window.metaAttributesCache = new Map()
|
||||
window.metaAttributesCache.set('ol-i18n', { currentLangCode: 'en' })
|
||||
window.metaAttributesCache.set('ol-ExposedSettings', {
|
||||
appName: 'Overleaf',
|
||||
validRootDocExtensions: ['tex', 'Rtex', 'ltx', 'Rnw'],
|
||||
fileIgnorePattern:
|
||||
'**/{{__MACOSX,.git,.texpadtmp,.R}{,/**},.!(latexmkrc),*.{dvi,aux,log,toc,out,pdfsync,synctex,synctex(busy),fdb_latexmk,fls,nlo,ind,glo,gls,glg,bbl,blg,doc,docx,gz,swp}}',
|
||||
hasLinkedProjectFileFeature: true,
|
||||
hasLinkedProjectOutputFileFeature: true,
|
||||
hasLinkUrlFeature: true,
|
||||
})
|
||||
}
|
||||
|
||||
// Populate meta for top-level access in modules on import
|
||||
resetMeta()
|
Reference in New Issue
Block a user