Skip to content

Commit

Permalink
Merge pull request #4 from Inspiration1/dev
Browse files Browse the repository at this point in the history
Update dependencies
  • Loading branch information
inspiration1 authored Dec 17, 2019
2 parents 5ce6e06 + 0280490 commit c8aa5d8
Show file tree
Hide file tree
Showing 44 changed files with 250 additions and 203 deletions.
3 changes: 2 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/public
/public,
/node_modules
61 changes: 41 additions & 20 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,21 +1,42 @@
module.exports = {
root: true,
'extends': [
'plugin:vue/essential',
'@vue/standard'
],
rules: {
// allow async-await
'generator-star-spacing': 'off',
// allow debugger during development
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'vue/no-parsing-error': [2, {
'x-invalid-end-tag': false
}],
'no-undef': 'off',
'camelcase': 'off'
},
parserOptions: {
parser: 'babel-eslint'
}
}
root: true,
"env": {
"browser": true,
"es6": true
},
"extends": [
"plugin:vue/essential",
'@vue/standard'
],
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parserOptions": {
"ecmaVersion": 2018,
"sourceType": "module",
parser: 'babel-eslint'
},
"plugins": [
"vue"
],
"rules": {
// allow async-await
'generator-star-spacing': 'off',
// allow debugger during development
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'vue/no-parsing-error': [2, {
'x-invalid-end-tag': false
}],
'no-undef': 'off',
'camelcase': 'off',
'indent': [
'error',
2,
{
SwitchCase: 1,
flatTernaryExpressions: true
}
]
}
};
67 changes: 37 additions & 30 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,64 +1,71 @@
{
"name": "asteroid",
"version": "1.1.0",
"author": "Zoe<[email protected]>",
"version": "1.2.0",
"private": false,
"author": "Zoe<[email protected]>",
"scripts": {
"dev": "vue-cli-service serve --open",
"build": "vue-cli-service build",
"lint": "vue-cli-service lint",
"test:unit": "vue-cli-service test:unit",
"test:e2e": "vue-cli-service test:e2e"
"test:e2e": "vue-cli-service test:e2e",
"lint": "vue-cli-service lint",
"dev": "vue-cli-service serve --open"
},
"dependencies": {
"@antv/data-set": "^0.10.2",
"@antv/g2": "^3.4.10",
"@fullcalendar/core": "^4.2.0",
"@fullcalendar/daygrid": "^4.2.0",
"@fullcalendar/interaction": "^4.2.0",
"@fullcalendar/timegrid": "^4.2.0",
"@fullcalendar/vue": "^4.2.2",
"@tinymce/tinymce-vue": "^2.0.0",
"axios": "^0.18.0",
"@antv/g2": "^3.5.11",
"@fullcalendar/core": "^4.3.1",
"@fullcalendar/daygrid": "^4.3.0",
"@fullcalendar/interaction": "^4.3.0",
"@fullcalendar/timegrid": "^4.3.0",
"@fullcalendar/vue": "^4.3.1",
"@tinymce/tinymce-vue": "^3.0.1",
"axios": "^0.19.0",
"clipboard": "^2.0.0",
"codemirror": "^5.38.0",
"countup": "^1.8.2",
"cropperjs": "^1.2.2",
"dayjs": "^1.7.7",
"echarts": "^4.0.4",
"html2canvas": "^1.0.0-alpha.12",
"iview": "^3.2.2",
"iview-area": "^1.5.17",
"iview": "^3.5.3",
"iview-area": "^1.6.0",
"jquery": "^3.3.1",
"js-cookie": "^2.2.0",
"moment": "^2.24.0",
"qrcodejs2": "0.0.2",
"simplemde": "^1.11.2",
"sortablejs": "^1.7.0",
"tinymce": "^5.0.1",
"tinymce": "^5.1.2",
"tree-table-vue": "^1.1.0",
"v-org-tree": "^1.0.6",
"viser-vue": "^2.4.5",
"vue": "^2.5.10",
"vue-i18n": "^7.8.0",
"vue-router": "^3.0.1",
"vuedraggable": "^2.16.0",
"vuex": "^3.0.1",
"vue": "^2.6.10",
"vue-i18n": "^8.15.1",
"vue-router": "^3.1.3",
"vuedraggable": "^2.23.2",
"vuex": "^3.1.2",
"wangeditor": "^3.1.1",
"xlsx": "^0.13.3"
"xlsx": "^0.15.3"
},
"devDependencies": {
"@vue/cli-plugin-babel": "^3.0.1",
"@vue/cli-plugin-eslint": "^3.0.1",
"@vue/cli-plugin-unit-mocha": "^3.0.1",
"@vue/cli-service": "^3.0.1",
"@vue/eslint-config-standard": "^3.0.0-beta.10",
"@vue/cli-plugin-babel": "^4.1.1",
"@vue/cli-plugin-eslint": "^4.1.1",
"@vue/cli-plugin-unit-mocha": "^4.1.1",
"@vue/cli-service": "^4.1.1",
"@vue/eslint-config-standard": "^5.0.0",
"@vue/test-utils": "^1.0.0-beta.10",
"babel-eslint": "^10.0.3",
"chai": "^4.1.2",
"eslint": "^5.16.0",
"eslint-plugin-cypress": "^2.0.1",
"less": "^2.7.3",
"less-loader": "^4.0.5",
"lint-staged": "^6.0.0",
"eslint-plugin-import": "^2.19.1",
"eslint-plugin-node": "^10.0.0",
"eslint-plugin-promise": "^4.2.1",
"eslint-plugin-standard": "^4.0.1",
"eslint-plugin-vue": "^5.0.0",
"less": "^3.10.3",
"less-loader": "^5.0.0",
"lint-staged": "^9.5.0",
"mockjs": "^1.0.1-beta3",
"vue-template-compiler": "^2.5.13"
},
Expand Down
6 changes: 3 additions & 3 deletions src/components/charts/bar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ export default {
},
mounted () {
this.$nextTick(() => {
let xAxisData = Object.keys(this.value)
let seriesData = Object.values(this.value)
let option = {
const xAxisData = Object.keys(this.value)
const seriesData = Object.values(this.value)
const option = {
title: {
text: this.text,
subtext: this.subtext,
Expand Down
4 changes: 2 additions & 2 deletions src/components/charts/pie.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ export default {
},
mounted () {
this.$nextTick(() => {
let legend = this.value.map(_ => _.name)
let option = {
const legend = this.value.map(_ => _.name)
const option = {
title: {
text: this.text,
subtext: this.subtext,
Expand Down
8 changes: 4 additions & 4 deletions src/components/count-to/count-to.vue
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ export default {
}
},
transformValue (val) {
let len = this.unit.length
const len = this.unit.length
let res = {
endVal: 0,
unitText: ''
Expand All @@ -141,7 +141,7 @@ export default {
getValue (val) {
let res = 0
if (this.simplify) {
let { endVal, unitText } = this.transformValue(val)
const { endVal, unitText } = this.transformValue(val)
this.unitText = unitText
res = endVal
} else {
Expand All @@ -152,7 +152,7 @@ export default {
},
mounted () {
this.$nextTick(() => {
let endVal = this.getValue(this.end)
const endVal = this.getValue(this.end)
this.counter = new CountUp(this.counterId, this.startVal, endVal, this.decimals, this.duration, {
useEasing: !this.uneasing,
useGrouping: this.useGroup,
Expand All @@ -166,7 +166,7 @@ export default {
},
watch: {
end (newVal) {
let endVal = this.getValue(newVal)
const endVal = this.getValue(newVal)
this.counter.update(endVal)
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/cropper/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ export default {
},
mounted () {
this.$nextTick(() => {
let dom = document.getElementById(this.imgId)
const dom = document.getElementById(this.imgId)
this.cropper = new Cropper(dom, {
preview: `#${this.previewId}`,
checkCrossOrigin: true
Expand Down
4 changes: 2 additions & 2 deletions src/components/editor/editor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export default {
mounted () {
this.editor = new Editor(`#${this.editorId}`)
this.editor.customConfig.onchange = (html) => {
let text = this.editor.txt.text()
const text = this.editor.txt.text()
if (this.cache) localStorage.editorCache = html
this.$emit('input', this.valueType === 'html' ? html : text)
this.$emit('on-change', html, text)
Expand All @@ -62,7 +62,7 @@ export default {
// create这个方法一定要在所有配置项之后调用
this.editor.create()
// 如果本地有存储加载本地存储内容
let html = this.value || localStorage.editorCache
const html = this.value || localStorage.editorCache
if (html) this.editor.txt.html(html)
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/main/components/a-back-top/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export default {
this.backTop = this.containerEle.scrollTop >= this.height
},
back () {
let target = typeof this.container === 'string' ? this.containerEle : (document.documentElement || document.body)
const target = typeof this.container === 'string' ? this.containerEle : (document.documentElement || document.body)
const sTop = target.scrollTop
scrollTop(this.containerEle, sTop, 0, this.duration)
this.$emit('on-click')
Expand Down
2 changes: 1 addition & 1 deletion src/components/main/components/fullscreen/fullscreen.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export default {
},
methods: {
handleFullscreen () {
let main = document.body
const main = document.body
if (this.value) {
if (document.exitFullscreen) {
document.exitFullscreen()
Expand Down
4 changes: 2 additions & 2 deletions src/components/main/components/side-menu/collapsed-menu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import { findNodeUpperByClasses } from '@/libs/util'
export default {
name: 'CollapsedMenu',
mixins: [ mixin, itemMixin ],
mixins: [mixin, itemMixin],
props: {
hideTitle: {
type: Boolean,
Expand Down Expand Up @@ -44,7 +44,7 @@ export default {
}
},
mounted () {
let dropdown = findNodeUpperByClasses(this.$refs.dropdown.$el, ['ivu-select-dropdown', 'ivu-dropdown-transfer'])
const dropdown = findNodeUpperByClasses(this.$refs.dropdown.$el, ['ivu-select-dropdown', 'ivu-dropdown-transfer'])
if (dropdown) dropdown.style.overflow = 'visible'
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ import mixin from './mixin'
import itemMixin from './item-mixin'
export default {
name: 'SideMenuItem',
mixins: [ mixin, itemMixin ]
mixins: [mixin, itemMixin]
}
</script>
8 changes: 4 additions & 4 deletions src/components/main/components/side-menu/side-menu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,16 @@
</template>
<script>
import SideMenuItem from './side-menu-item.vue'
import CollapsedMenu from './collapsed-menu.vue'
// import CollapsedMenu from './collapsed-menu.vue'
import { getUnion } from '@/libs/tools'
import mixin from './mixin'
export default {
name: 'SideMenu',
mixins: [ mixin ],
mixins: [mixin],
components: {
SideMenuItem,
CollapsedMenu
SideMenuItem
// CollapsedMenu
},
props: {
menuList: {
Expand Down
8 changes: 4 additions & 4 deletions src/components/main/components/tags-nav/tags-nav.vue
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,11 @@ export default {
handleTagsOption (type) {
if (type.includes('all')) {
// 关闭所有,除了home
let res = this.list.filter(item => item.name === this.$config.homeName)
const res = this.list.filter(item => item.name === this.$config.homeName)
this.$emit('on-close', res, 'all')
} else if (type.includes('others')) {
// 关闭除当前页和home页的其他页
let res = this.list.filter(item => routeEqual(this.currentRouteObj, item) || item.name === this.$config.homeName)
const res = this.list.filter(item => routeEqual(this.currentRouteObj, item) || item.name === this.$config.homeName)
this.$emit('on-close', res, 'others', this.currentRouteObj)
setTimeout(() => {
this.getTagElementByRoute(this.currentRouteObj)
Expand All @@ -132,7 +132,7 @@ export default {
}
},
close (route) {
let res = this.list.filter(item => !routeEqual(route, item))
const res = this.list.filter(item => !routeEqual(route, item))
this.$emit('on-close', res, undefined, route)
},
handleClick (item) {
Expand Down Expand Up @@ -165,7 +165,7 @@ export default {
this.refsTag = this.$refs.tagsPageOpened
this.refsTag.forEach((item, index) => {
if (routeEqual(route, item.$attrs['data-route-item'])) {
let tag = this.refsTag[index].$el
const tag = this.refsTag[index].$el
this.moveToView(tag)
}
})
Expand Down
4 changes: 2 additions & 2 deletions src/components/markdown/markdown.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export default {
methods: {
addEvents () {
this.editor.codemirror.on('change', () => {
let value = this.editor.value()
const value = this.editor.value()
if (this.localCache) localStorage.markdownContent = value
this.$emit('input', value)
this.$emit('on-change', value)
Expand All @@ -55,7 +55,7 @@ export default {
* https://codemirror.net/doc/manual.html#events
*/
this.addEvents()
let content = localStorage.markdownContent
const content = localStorage.markdownContent
if (content) this.editor.value(content)
}
}
Expand Down
4 changes: 2 additions & 2 deletions src/components/paste-editor/paste-editor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export default {
* @description 处理粘贴操作
*/
handleContentChanged (content) {
let pasteData = content.trim()
const pasteData = content.trim()
this.$emit('on-content-change', pasteData)
let rows = pasteData.split((/[\n\u0085\u2028\u2029]|\r\n?/g)).map(row => {
return row.split('\t')
Expand All @@ -70,7 +70,7 @@ export default {
const len = this.rowNum
if (len === 0) return
while (++i < len) {
let item = this.pasteDataArr[i]
const item = this.pasteDataArr[i]
if (item.length !== this.colNum && (!(i === len - 1 && item.length === 1 && item[0] === '') || i !== len - 1)) {
this.markIncorrectRow(i)
this.$emit('on-error', i)
Expand Down
Loading

0 comments on commit c8aa5d8

Please sign in to comment.