mirror of
https://github.com/wanglin2/mind-map.git
synced 2026-02-23 03:17:41 +08:00
Demo: update
This commit is contained in:
parent
95d7a3ac41
commit
fd85085cb7
File diff suppressed because one or more lines are too long
2
dist/js/app.js
vendored
2
dist/js/app.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,7 +1,7 @@
|
||||
<!DOCTYPE html><html lang=""><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,user-scalable=no,initial-scale=1,maximum-scale=1,minimum-scale=1"><link rel="icon" href="dist/logo.ico"><title>思绪思维导图</title><script>// 自定义静态资源的路径
|
||||
window.externalPublicPath = './dist/'
|
||||
// 接管应用
|
||||
window.takeOverApp = false</script><link href="dist/css/chunk-vendors.css?24f8b73deb3c00d9b87f" rel="stylesheet"><link href="dist/css/app.css?24f8b73deb3c00d9b87f" rel="stylesheet"></head><body><noscript><strong>We're sorry but thoughts doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div><script>const getDataFromBackend = () => {
|
||||
window.takeOverApp = false</script><link href="dist/css/chunk-vendors.css?153f5047fdc3ef873534" rel="stylesheet"><link href="dist/css/app.css?153f5047fdc3ef873534" rel="stylesheet"></head><body><noscript><strong>We're sorry but thoughts doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div><script>const getDataFromBackend = () => {
|
||||
return new Promise((resolve, reject) => {
|
||||
setTimeout(() => {
|
||||
resolve({
|
||||
@ -66,4 +66,4 @@
|
||||
// 可以通过window.$bus.$on()来监听应用的一些事件
|
||||
// 实例化页面
|
||||
window.initApp()
|
||||
}</script><script src="dist/js/chunk-vendors.js?24f8b73deb3c00d9b87f"></script><script src="dist/js/app.js?24f8b73deb3c00d9b87f"></script></body></html>
|
||||
}</script><script src="dist/js/chunk-vendors.js?153f5047fdc3ef873534"></script><script src="dist/js/app.js?153f5047fdc3ef873534"></script></body></html>
|
||||
@ -266,23 +266,29 @@ export default {
|
||||
} else {
|
||||
dirHandle = node.data.handle
|
||||
}
|
||||
const list = []
|
||||
const dirList = []
|
||||
const fileList = []
|
||||
for await (const [key, value] of dirHandle.entries()) {
|
||||
const isFile = value.kind === 'file'
|
||||
if (isFile && !/\.(smm|xmind|md|json)$/.test(value.name)) {
|
||||
continue
|
||||
}
|
||||
const enableEdit = isFile && /\.smm$/.test(value.name)
|
||||
list.push({
|
||||
const data = {
|
||||
id: key,
|
||||
name: value.name,
|
||||
type: value.kind,
|
||||
handle: value,
|
||||
leaf: isFile,
|
||||
enableEdit
|
||||
})
|
||||
}
|
||||
if (isFile) {
|
||||
fileList.push(data)
|
||||
} else {
|
||||
dirList.push(data)
|
||||
}
|
||||
}
|
||||
resolve(list)
|
||||
resolve([...dirList, ...fileList])
|
||||
} catch (error) {
|
||||
console.log(error)
|
||||
this.fileTreeVisible = false
|
||||
@ -574,6 +580,7 @@ export default {
|
||||
overflow: hidden;
|
||||
border-radius: 5px;
|
||||
min-width: 200px;
|
||||
box-shadow: 0 2px 16px 0 rgba(0, 0, 0, 0.06);
|
||||
|
||||
&.expand {
|
||||
height: 300px;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user