优化首屏加载
Former-commit-id: 723180773c9659aadf9d0a8b78fb3df43ff33be4 Former-commit-id: 65d1e1a4ecb2ec399aaa379abdfbc31d7a93e324 Former-commit-id: 18e30c7c4ecfb08200dc34fd1edf01793137bf70 Former-commit-id: 978c19d88848ad206f3185c991228fce12a97791 [formerly c3f067d88fe1d3931f221fb1bc055ff956bf175c] Former-commit-id: 2b7498ad2c171fc00107bf6b4dce573727096483 Former-commit-id: c337da25d51bc40ed1748eba81c3a6f7a3ebfd46 Former-commit-id: abded2cd6a968e2fb0f947488e9e6722ad2395c8 Former-commit-id: 7432bdd4a52d519509696232f69b23e1901d2223 Former-commit-id: d082a88de791e2147ebf6c2ff35ad7c9acc42a87
This commit is contained in:
@@ -51,7 +51,7 @@ module.exports = [
|
||||
name: 'element-ui',
|
||||
library: 'ELEMENT',
|
||||
css: 'https://cdn.jsdelivr.net/npm/element-ui@2.13.0/lib/theme-chalk/index.css',
|
||||
js: 'https://cdn.jsdelivr.net/npm/element-ui@2.13.0/lib/index.min.js'
|
||||
js: 'https://cdn.jsdelivr.net/npm/element-ui@2.13.0/lib/index.js'
|
||||
},
|
||||
{
|
||||
name: 'vue-grid-layout',
|
||||
@@ -59,17 +59,11 @@ module.exports = [
|
||||
css: '',
|
||||
js: 'https://unpkg.com/vue-grid-layout@2.3.4/dist/vue-grid-layout.umd.min.js'
|
||||
},
|
||||
{
|
||||
name: 'highlight.js',
|
||||
library: 'hljs',
|
||||
css: 'https://cdn.jsdelivr.net/npm/highlight.js@9.17.1/styles/github.min.css',
|
||||
js: 'https://cdn.jsdelivr.net/npm/highlight.js@9.17.1/lib/index.min.js'
|
||||
},
|
||||
{
|
||||
name: 'mockjs',
|
||||
library: 'Mock',
|
||||
css: '',
|
||||
js: 'https://cdn.jsdelivr.net/npm/mockjs@1.1.0/dist/mock-min.js'
|
||||
js: 'https://cdn.jsdelivr.net/npm/mockjs@1.1.0/dist/mock.min.js'
|
||||
},
|
||||
{
|
||||
name: 'lodash',
|
||||
@@ -117,6 +111,6 @@ module.exports = [
|
||||
name: 'hotkeys-js',
|
||||
library: 'hotkeys',
|
||||
css: '',
|
||||
js: 'https://cdn.jsdelivr.net/npm/hotkeys-js@3.7.3/dist/hotkeys.min.js'
|
||||
js: 'https://cdn.jsdelivr.net/npm/hotkeys-js@3.7.3/dist/hotkeys.js'
|
||||
}
|
||||
]
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
// http://highlightjs.readthedocs.io/en/latest/api.html#configure-options
|
||||
import highlight from 'highlight.js'
|
||||
import htmlFormat from './libs/htmlFormat'
|
||||
import './libs/style.github.css'
|
||||
export default {
|
||||
name: 'd2-highlight',
|
||||
props: {
|
||||
|
||||
99
src/components/d2-highlight/libs/style.github.css
Normal file
99
src/components/d2-highlight/libs/style.github.css
Normal file
@@ -0,0 +1,99 @@
|
||||
/*
|
||||
|
||||
github.com style (c) Vasily Polovnyov <vast@whiteants.net>
|
||||
|
||||
*/
|
||||
|
||||
.hljs {
|
||||
display: block;
|
||||
overflow-x: auto;
|
||||
padding: 0.5em;
|
||||
color: #333;
|
||||
background: #f8f8f8;
|
||||
}
|
||||
|
||||
.hljs-comment,
|
||||
.hljs-quote {
|
||||
color: #998;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.hljs-keyword,
|
||||
.hljs-selector-tag,
|
||||
.hljs-subst {
|
||||
color: #333;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.hljs-number,
|
||||
.hljs-literal,
|
||||
.hljs-variable,
|
||||
.hljs-template-variable,
|
||||
.hljs-tag .hljs-attr {
|
||||
color: #008080;
|
||||
}
|
||||
|
||||
.hljs-string,
|
||||
.hljs-doctag {
|
||||
color: #d14;
|
||||
}
|
||||
|
||||
.hljs-title,
|
||||
.hljs-section,
|
||||
.hljs-selector-id {
|
||||
color: #900;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.hljs-subst {
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.hljs-type,
|
||||
.hljs-class .hljs-title {
|
||||
color: #458;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.hljs-tag,
|
||||
.hljs-name,
|
||||
.hljs-attribute {
|
||||
color: #000080;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.hljs-regexp,
|
||||
.hljs-link {
|
||||
color: #009926;
|
||||
}
|
||||
|
||||
.hljs-symbol,
|
||||
.hljs-bullet {
|
||||
color: #990073;
|
||||
}
|
||||
|
||||
.hljs-built_in,
|
||||
.hljs-builtin-name {
|
||||
color: #0086b3;
|
||||
}
|
||||
|
||||
.hljs-meta {
|
||||
color: #999;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.hljs-deletion {
|
||||
background: #fdd;
|
||||
}
|
||||
|
||||
.hljs-addition {
|
||||
background: #dfd;
|
||||
}
|
||||
|
||||
.hljs-emphasis {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.hljs-strong {
|
||||
font-weight: bold;
|
||||
}
|
||||
Reference in New Issue
Block a user