From 0e97eee15ff5b3b30a9aef030a28c52bd8dd7dea Mon Sep 17 00:00:00 2001 From: Sergey Solodyagin Date: Wed, 13 Oct 2021 21:51:08 +0300 Subject: [PATCH] chore: now "rowLabelWidth" is number feat: added prop "gridSize" --- .prettierrc | 19 ---- .prettierrc.js | 19 ++++ package-lock.json | 4 +- package.json | 57 ++++++------ src/GGanttBar.vue | 15 ++-- src/GGanttChart.vue | 11 ++- src/GGanttGrid.vue | 42 ++++----- src/GGanttRow.vue | 51 +++++------ src/GGanttTimeaxis.vue | 35 ++++---- src/GanttasticThemeColors.js | 165 +++++++++++++++++------------------ src/Playground.vue | 34 ++++---- 11 files changed, 222 insertions(+), 230 deletions(-) delete mode 100644 .prettierrc create mode 100644 .prettierrc.js diff --git a/.prettierrc b/.prettierrc deleted file mode 100644 index 3f29e9c..0000000 --- a/.prettierrc +++ /dev/null @@ -1,19 +0,0 @@ -{ - // "arrowParens": "always", - "bracketSpacing": true, - // "embeddedLanguageFormatting": "auto", - // "htmlWhitespaceSensitivity": "css", - // "insertPragma": false, - // "jsxBracketSameLine": false, - // "jsxSingleQuote": false, - // "printWidth": 80, - // "proseWrap": "preserve", - // "quoteProps": "as-needed", - // "requirePragma": false, - "semi": false, - "singleQuote": true, - "tabWidth": 2, - "trailingComma": "es5", - "useTabs": false, - "vueIndentScriptAndStyle": true - } \ No newline at end of file diff --git a/.prettierrc.js b/.prettierrc.js new file mode 100644 index 0000000..b803251 --- /dev/null +++ b/.prettierrc.js @@ -0,0 +1,19 @@ +module.exports = { + arrowParens: 'always', + bracketSpacing: true, + // "embeddedLanguageFormatting": "auto", + // "htmlWhitespaceSensitivity": "css", + // "insertPragma": false, + // "jsxBracketSameLine": false, + // "jsxSingleQuote": false, + // "printWidth": 80, + // "proseWrap": "preserve", + // "quoteProps": "as-needed", + // "requirePragma": false, + semi: false, + singleQuote: true, + tabWidth: 2, + trailingComma: 'es5', + useTabs: false, + vueIndentScriptAndStyle: true, +} diff --git a/package-lock.json b/package-lock.json index e16f114..9cbf298 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@tenrok/vue-ganttastic", - "version": "0.10.2", + "version": "0.10.6", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@tenrok/vue-ganttastic", - "version": "0.10.2", + "version": "0.10.6", "license": "MIT", "dependencies": { "vue": "^2.6.14" diff --git a/package.json b/package.json index a2d1f0e..9da25ef 100644 --- a/package.json +++ b/package.json @@ -1,17 +1,26 @@ { "name": "@tenrok/vue-ganttastic", - "version": "0.10.2", + "version": "0.10.6", "description": "A simple and customizable Gantt chart component for Vue.js", + "keywords": [ + "gantt", + "chart", + "bar", + "diagram", + "vue", + "vuejs", + "ganttastic" + ], + "homepage": "https://github.com/tenrok/vue-ganttastic#readme", + "bugs": { + "url": "https://github.com/tenrok/vue-ganttastic/issues" + }, + "license": "MIT", "author": { "name": "Marko Zunic", "email": "marko.zunic06@gmail.com", "url": "https://github.com/InfectoOne/vue-ganttastic" }, - "license": "MIT", - "repository": { - "type": "git", - "url": "git+https://github.com/tenrok/vue-ganttastic.git" - }, "contributors": [ { "name": "Yicone Wong", @@ -22,23 +31,22 @@ "url": "https://github.com/solodyagin" } ], - "main": "./dist/index.js", - "scripts": { - "test": "echo \"Error: no test specified\" && exit 1", - "build": "bili" - }, "files": [ "dist/*" ], - "keywords": [ - "gantt", - "chart", - "bar", - "diagram", - "vue", - "vuejs", - "ganttastic" - ], + "main": "./dist/index.js", + "repository": { + "type": "git", + "url": "git+https://github.com/tenrok/vue-ganttastic.git" + }, + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1", + "build": "bili --plugin.vue", + "serve": "vue serve ./src/Playground.vue" + }, + "dependencies": { + "vue": "^2.6.14" + }, "devDependencies": { "bili": "^4.10.0", "rollup-plugin-vue": "^5.1.9", @@ -46,12 +54,5 @@ }, "peerDependencies": { "moment": "^2.26.0" - }, - "dependencies": { - "vue": "^2.6.14" - }, - "bugs": { - "url": "https://github.com/tenrok/vue-ganttastic/issues" - }, - "homepage": "https://github.com/tenrok/vue-ganttastic#readme" + } } diff --git a/src/GGanttBar.vue b/src/GGanttBar.vue index d3b3e43..d59571e 100644 --- a/src/GGanttBar.vue +++ b/src/GGanttBar.vue @@ -1,8 +1,8 @@ @@ -46,15 +46,16 @@ export default { data() { return { chartStart: '2020-03-02 00:00', - chartEnd: '2020-03-31 10:00', + chartEnd: '2020-03-10 10:00', precision: 'day', pushOnOverlap: true, isMagnetic: true, grid: true, + gridSize: 50, rowHeight: 40, - rowLabelWidth: '200px', + rowLabelWidth: 200, hideTimeaxis: false, - highlightOnHover: false, + highlightOnHover: true, hours: [...Array(24).keys()], highlightedHours: [10, 12], showContextmenu: false, @@ -220,6 +221,3 @@ export default { }, } - - \ No newline at end of file