format.js

Former-commit-id: 8243984da4fe1cef02128249e3553a390da9aa8b
Former-commit-id: 71a9ff274c3158e5b3284a6252bef69cfcd0d680
Former-commit-id: 37de1e7e35cf19efa01f2011d012ef53e2065d2e
This commit is contained in:
李杨 2018-01-16 16:11:53 +08:00
parent 903d62c012
commit 3ee77c7059
4 changed files with 10 additions and 9 deletions

View File

@ -0,0 +1 @@
770af54da1a6e44b05382c9d304243620d6da715

View File

@ -2,6 +2,7 @@
<Container type="ghost">
<el-card class="mb">
<QuillEditor
style="min-height: 200px;"
v-model="value"
@text-change="textChangeHandler"
@selection-change="selectionChangeHandler"
@ -9,24 +10,24 @@
</QuillEditor>
</el-card>
<el-card>
<Highlight :code="format"></Highlight>
<Highlight :code="formated"></Highlight>
</el-card>
</Container>
</template>
<script>
import HTMLFormat from './fn'
import formator from '@/assets/library/tool/format.js'
import value from './value'
export default {
data () {
return {
HTMLFormat,
formator,
value
}
},
computed: {
format () {
return HTMLFormat(this.value)
formated () {
return formator(this.value)
}
},
methods: {

View File

@ -1 +0,0 @@
b18165d6428d78e9e4430801d1ba8f34d558c23b

View File

@ -1,9 +1,9 @@
export default `<p>
<strong class="ql-size-large" style="color: rgb(0, 138, 0);">
export default `<p class="ql-align-center">
<strong class="ql-size-large" style="color: rgb(65, 184, 131);">
D2 Admin
</strong>
by
<strong class="ql-size-large" style="color: rgb(0, 138, 0);">
<strong class="ql-size-large" style="color: rgb(65, 184, 131);">
vue.js
</strong>
</p>`