Fix CodeMirror 6 stories (#5834)

GitOrigin-RevId: 76f17bc02844dde61545b15e6a2e4f7c1bbcfdc7
This commit is contained in:
Alf Eaton 2021-11-22 11:24:03 +00:00 committed by Copybot
parent 3a2b5f06a2
commit 9e331d1176

View file

@ -14,6 +14,7 @@ export function setupContext() {
project: {},
$watch: () => {},
$applyAsync: () => {},
$broadcast: () => {},
ui: {
chatOpen: true,
pdfLayout: 'flat',
@ -22,6 +23,7 @@ export function setupContext() {
pdfViewer: 'js',
},
toggleHistory: () => {},
rootFolder: { type: 'folder', children: [] },
}
}
window._ide = {
@ -43,6 +45,13 @@ export function setupContext() {
console.log('open doc', id, options)
},
},
metadataManager: {
metadata: {
state: {
documents: {},
},
},
},
}
window.ExposedSettings = window.ExposedSettings || {}
window.ExposedSettings.appName = 'Overleaf'