Merge pull request #29 from sgotti/npm_update_deps
npm: update dependencies
This commit is contained in:
commit
3fa224d0be
|
@ -1,5 +1,5 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
presets: [
|
presets: [
|
||||||
'@vue/app'
|
'@vue/cli-plugin-babel/preset'
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
37
package.json
37
package.json
|
@ -1,7 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "agola-web",
|
"name": "agola-web",
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"license": "Apache-2.0",
|
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"serve": "vue-cli-service serve",
|
"serve": "vue-cli-service serve",
|
||||||
|
@ -9,27 +8,30 @@
|
||||||
"lint": "vue-cli-service lint"
|
"lint": "vue-cli-service lint"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdi/font": "^3.9.97",
|
"@mdi/font": "^4.9.95",
|
||||||
"ansi_up": "^4.0.4",
|
"ansi_up": "^4.0.4",
|
||||||
|
"core-js": "^3.6.4",
|
||||||
"moment": "^2.23.0",
|
"moment": "^2.23.0",
|
||||||
"moment-duration-format": "^2.3.2",
|
"moment-duration-format": "^2.3.2",
|
||||||
"v-click-outside-x": "^4.0.19",
|
"v-click-outside-x": "^4.1.0",
|
||||||
"vue": "^2.6.10",
|
"vue": "^2.6.11",
|
||||||
"vue-router": "^3.1.3",
|
"vue-router": "^3.1.5",
|
||||||
"vue2-filters": "^0.6.1",
|
"vue2-filters": "^0.9.1",
|
||||||
"vuex": "^3.1.1"
|
"vuex": "^3.1.2"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@vue/cli-plugin-babel": "^3.11.0",
|
"@vue/cli-plugin-babel": "~4.2.2",
|
||||||
"@vue/cli-plugin-eslint": "^3.11.0",
|
"@vue/cli-plugin-eslint": "~4.2.2",
|
||||||
"@vue/cli-service": "^3.11.0",
|
"@vue/cli-plugin-router": "^4.2.2",
|
||||||
|
"@vue/cli-plugin-vuex": "^4.2.2",
|
||||||
|
"@vue/cli-service": "~4.2.2",
|
||||||
"babel-eslint": "^10.0.3",
|
"babel-eslint": "^10.0.3",
|
||||||
"eslint": "^5.16.0",
|
"eslint": "^6.7.2",
|
||||||
"eslint-plugin-vue": "^5.2.3",
|
"eslint-plugin-vue": "^6.1.2",
|
||||||
"node-sass": "^4.12.0",
|
"node-sass": "^4.13.1",
|
||||||
"sass-loader": "^7.3.1",
|
"sass-loader": "^8.0.2",
|
||||||
"tailwindcss": "^1.1.2",
|
"tailwindcss": "^1.2.0",
|
||||||
"vue-template-compiler": "^2.6.10"
|
"vue-template-compiler": "^2.6.11"
|
||||||
},
|
},
|
||||||
"eslintConfig": {
|
"eslintConfig": {
|
||||||
"root": true,
|
"root": true,
|
||||||
|
@ -49,5 +51,6 @@
|
||||||
"> 1%",
|
"> 1%",
|
||||||
"last 2 versions",
|
"last 2 versions",
|
||||||
"not ie <= 8"
|
"not ie <= 8"
|
||||||
]
|
],
|
||||||
|
"license": "Apache-2.0"
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,13 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="overflow-x-auto">
|
<div class="overflow-x-auto">
|
||||||
<svg version="1.1" :width="width" :height="height" class="svg-content" scroll overflow="scroll">
|
<svg
|
||||||
|
version="1.1"
|
||||||
|
:width="width"
|
||||||
|
:height="height"
|
||||||
|
class="svg-content"
|
||||||
|
scroll
|
||||||
|
overflow="scroll"
|
||||||
|
>
|
||||||
<g v-for="(segment, i) in segments" v-bind:key="segment + i">
|
<g v-for="(segment, i) in segments" v-bind:key="segment + i">
|
||||||
<line
|
<line
|
||||||
:x1="segment.x1"
|
:x1="segment.x1"
|
||||||
|
@ -33,18 +40,19 @@
|
||||||
tag="a"
|
tag="a"
|
||||||
:to="task.link"
|
:to="task.link"
|
||||||
class="px-1 flex flex-col border border-l-0 rounded-r"
|
class="px-1 flex flex-col border border-l-0 rounded-r"
|
||||||
:style="{ height: taskHeight +'px'}"
|
:style="{ height: taskHeight + 'px' }"
|
||||||
:title="task.name"
|
:title="task.name"
|
||||||
>
|
>
|
||||||
<div class="flex justify-end">
|
<div class="flex justify-end">
|
||||||
<div class="text-right text-xs">{{ task.duration }}</div>
|
<div class="text-right text-xs">{{ task.duration }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="font-bold truncate">{{task.name}}</div>
|
<div class="font-bold truncate">{{ task.name }}</div>
|
||||||
<div class="flex justify-end">
|
<div class="flex justify-end">
|
||||||
<span
|
<span
|
||||||
v-if="task.waiting_approval"
|
v-if="task.waiting_approval"
|
||||||
class="bg-gray-200 rounded-full px-2 py-0 text-xs text-center font-semibold"
|
class="bg-gray-200 rounded-full px-2 py-0 text-xs text-center font-semibold"
|
||||||
>Waiting Approval</span>
|
>Waiting Approval</span
|
||||||
|
>
|
||||||
</div>
|
</div>
|
||||||
</router-link>
|
</router-link>
|
||||||
</div>
|
</div>
|
||||||
|
@ -52,7 +60,7 @@
|
||||||
</foreignObject>
|
</foreignObject>
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
@ -217,12 +225,6 @@ export default {
|
||||||
return levelTasks;
|
return levelTasks;
|
||||||
};
|
};
|
||||||
|
|
||||||
let levelTasksByRow = function(tasks, level) {
|
|
||||||
return levelTasks(tasks, level).sort((a, b) =>
|
|
||||||
a.row > b.row ? 1 : b.row > a.row ? -1 : 0
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
let levelsTasksByRow = function(tasks, startLevel) {
|
let levelsTasksByRow = function(tasks, startLevel) {
|
||||||
return levelsTasks(tasks, startLevel).sort((a, b) =>
|
return levelsTasks(tasks, startLevel).sort((a, b) =>
|
||||||
a.row > b.row ? 1 : b.row > a.row ? -1 : 0
|
a.row > b.row ? 1 : b.row > a.row ? -1 : 0
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import store from "@/store";
|
import store from "@/store";
|
||||||
|
|
||||||
const ID_TOKEN_KEY = 'id_token';
|
const ID_TOKEN_KEY = "id_token";
|
||||||
const USER_KEY = 'user';
|
const USER_KEY = "user";
|
||||||
const LOGIN_REDIRECT_KEY = 'login_redirect';
|
const LOGIN_REDIRECT_KEY = "login_redirect";
|
||||||
|
|
||||||
let API_URL = window.CONFIG.API_URL;
|
let API_URL = window.CONFIG.API_URL;
|
||||||
let API_BASE_PATH = window.CONFIG.API_BASE_PATH;
|
let API_BASE_PATH = window.CONFIG.API_BASE_PATH;
|
||||||
|
@ -10,13 +10,13 @@ let API_BASE_PATH = window.CONFIG.API_BASE_PATH;
|
||||||
export function setLoggedUser(token, user) {
|
export function setLoggedUser(token, user) {
|
||||||
setIdToken(token);
|
setIdToken(token);
|
||||||
setUser(user);
|
setUser(user);
|
||||||
store.dispatch('setUser', user)
|
store.dispatch("setUser", user);
|
||||||
}
|
}
|
||||||
|
|
||||||
export function doLogout() {
|
export function doLogout() {
|
||||||
unsetIdToken();
|
unsetIdToken();
|
||||||
unsetUser()
|
unsetUser();
|
||||||
store.dispatch('setUser', null)
|
store.dispatch("setUser", null);
|
||||||
}
|
}
|
||||||
|
|
||||||
export function apiurlwithtoken(path) {
|
export function apiurlwithtoken(path) {
|
||||||
|
@ -25,7 +25,7 @@ export function apiurlwithtoken(path) {
|
||||||
if (idToken) {
|
if (idToken) {
|
||||||
u.searchParams.append("access_token", idToken);
|
u.searchParams.append("access_token", idToken);
|
||||||
}
|
}
|
||||||
return u
|
return u;
|
||||||
}
|
}
|
||||||
|
|
||||||
export function apiurl(path) {
|
export function apiurl(path) {
|
||||||
|
@ -50,48 +50,36 @@ export function oauth2callbackurl() {
|
||||||
|
|
||||||
export async function loginapi(init) {
|
export async function loginapi(init) {
|
||||||
if (init === undefined) {
|
if (init === undefined) {
|
||||||
init = {}
|
init = {};
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
return await window.fetch(loginurl(), init);
|
||||||
return await window.fetch(loginurl(), init)
|
|
||||||
} catch (e) {
|
|
||||||
throw e
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function registerapi(init) {
|
export async function registerapi(init) {
|
||||||
if (init === undefined) {
|
if (init === undefined) {
|
||||||
init = {}
|
init = {};
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
return await window.fetch(registerurl(), init);
|
||||||
return await window.fetch(registerurl(), init)
|
|
||||||
} catch (e) {
|
|
||||||
throw e
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetch(url, init, signal) {
|
export async function fetch(url, init, signal) {
|
||||||
if (!init) {
|
if (!init) {
|
||||||
init = {}
|
init = {};
|
||||||
}
|
}
|
||||||
if (init.headers === undefined) {
|
if (init.headers === undefined) {
|
||||||
init["headers"] = {}
|
init["headers"] = {};
|
||||||
}
|
}
|
||||||
if (signal) {
|
if (signal) {
|
||||||
init["signal"] = signal;
|
init["signal"] = signal;
|
||||||
}
|
}
|
||||||
let idToken = getIdToken();
|
let idToken = getIdToken();
|
||||||
if (idToken) {
|
if (idToken) {
|
||||||
init.headers["Authorization"] = "bearer " + idToken
|
init.headers["Authorization"] = "bearer " + idToken;
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
return await window.fetch(url, init);
|
||||||
return await window.fetch(url, init)
|
|
||||||
} catch (e) {
|
|
||||||
throw e
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export function setIdToken(idToken) {
|
export function setIdToken(idToken) {
|
||||||
|
@ -113,9 +101,9 @@ export function setUser(user) {
|
||||||
export function getUser() {
|
export function getUser() {
|
||||||
let user = localStorage.getItem(USER_KEY);
|
let user = localStorage.getItem(USER_KEY);
|
||||||
if (user) {
|
if (user) {
|
||||||
return JSON.parse(user)
|
return JSON.parse(user);
|
||||||
}
|
}
|
||||||
return null
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
export function unsetUser() {
|
export function unsetUser() {
|
||||||
|
|
|
@ -5,6 +5,9 @@ module.exports = {
|
||||||
center: true,
|
center: true,
|
||||||
padding: '2rem',
|
padding: '2rem',
|
||||||
},
|
},
|
||||||
|
fontFamily: {
|
||||||
|
'sans': ['Segoe UI', 'Roboto', 'Helvetica Neue', 'Arial', 'Noto Sans', 'sans-serif', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji']
|
||||||
|
},
|
||||||
borderWidth: {
|
borderWidth: {
|
||||||
default: '1px',
|
default: '1px',
|
||||||
'0': '0',
|
'0': '0',
|
||||||
|
|
Loading…
Reference in New Issue