Compare commits

..

5 Commits

Author SHA1 Message Date
81dcf5ebe7 Try to build Docker image for Pull Requests
All checks were successful
continuous-integration/drone/pr Build is passing
2024-04-23 22:48:01 +02:00
7433d25716 Add missing trailing slash 2024-04-23 22:47:54 +02:00
7feee07d35 Merge pull request '♻️ Optimize Dockerfile' (!85) from optimize-dockerfile into main
Some checks failed
continuous-integration/drone/push Build is failing
Reviewed-on: #85
Reviewed-by: srsh <srsh@noreply.git.wtf-eg.de>
2024-04-23 22:26:14 +02:00
c79ada2123 ISSUE-58| Move profile visiblity (!87)
All checks were successful
continuous-integration/drone/push Build is passing
Move switch profile visibility button to save bar
Rename Save button to save as draft and offer save and publish

Fixes kompetenzinventar/ki-doku#58

Reviewed-on: #87
Reviewed-by: srsh <srsh@noreply.git.wtf-eg.de>
Co-authored-by: Nikolai Gotzmann <self@ngotzmann.net>
Co-committed-by: Nikolai Gotzmann <self@ngotzmann.net>
2024-02-20 20:26:54 +01:00
f8e78d1cc8 ♻️ Optimize Dockerfile
All checks were successful
continuous-integration/drone/pr Build is passing
- add all non-essential files to .dockerignore
- improve cachability by layers
- re-order lines to reduce layer generation
2024-01-12 18:42:27 +01:00
9 changed files with 16952 additions and 9604 deletions

View File

@ -1,2 +1,11 @@
.browserslistrc
.dockerignore
.drone.yml
.editorconfig
.git .git
.gitignore
.reuse
Dockerfile
LICENSES
README.md
node_modules node_modules

View File

@ -21,6 +21,13 @@ steps:
commands: commands:
- npm ci - npm ci
- npm run lint - npm run lint
- name: docker-build
image: plugins/docker
settings:
registry: git.wtf-eg.de
repo: git.wtf-eg.de/kompetenzinventar/frontend
target: ki-frontend
dry_run: true
--- ---
kind: pipeline kind: pipeline

View File

@ -8,7 +8,7 @@ module.exports = {
'eslint:recommended' 'eslint:recommended'
], ],
parserOptions: { parserOptions: {
parser: '@babel/eslint-parser' parser: 'babel-eslint'
}, },
rules: { rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off', 'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',

View File

@ -2,19 +2,27 @@
# #
# SPDX-License-Identifier: AGPL-3.0-or-later # SPDX-License-Identifier: AGPL-3.0-or-later
FROM node:20-alpine as builder FROM node:14-alpine as builder
COPY . ./ COPY package.json package-lock.json ./
RUN npm install
COPY .eslintrc.js .
COPY babel.config.js .
COPY public public
COPY src src
RUN npm ci && npm run build RUN npm ci && npm run build
FROM nginx as ki-frontend FROM nginx as ki-frontend
COPY --from=builder /dist/ /usr/share/nginx/html/
COPY etc/nginx/conf.d/default.conf /etc/nginx/conf.d/default.conf
LABEL org.opencontainers.image.source=https://git.wtf-eg.de/kompetenzinventar/ki-frontend.git LABEL org.opencontainers.image.source=https://git.wtf-eg.de/kompetenzinventar/ki-frontend.git
LABEL org.opencontainers.image.url=https://git.wtf-eg.de/kompetenzinventar/ki-frontend LABEL org.opencontainers.image.url=https://git.wtf-eg.de/kompetenzinventar/ki-frontend
LABEL org.opencontainers.image.documentation=https://git.wtf-eg.de/kompetenzinventar/ki-frontend#docker LABEL org.opencontainers.image.documentation=https://git.wtf-eg.de/kompetenzinventar/ki-frontend#docker
LABEL org.opencontainers.image.vendor="WTF Kooperative eG" LABEL org.opencontainers.image.vendor="WTF Kooperative eG"
WORKDIR /usr/share/nginx/html
COPY etc/nginx/conf.d/default.conf /etc/nginx/conf.d/default.conf
COPY --from=builder /dist .

26458
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -7,22 +7,22 @@
"lint": "vue-cli-service lint" "lint": "vue-cli-service lint"
}, },
"devDependencies": { "devDependencies": {
"@vue/cli-plugin-babel": "~5.0.8", "@vue/cli-plugin-babel": "^4.5.0",
"@vue/cli-plugin-eslint": "~5.0.8", "@vue/cli-plugin-eslint": "^4.5.0",
"@vue/cli-plugin-router": "~5.0.8", "@vue/cli-plugin-router": "^4.5.0",
"@vue/cli-service": "~5.0.8", "@vue/cli-service": "^4.5.0",
"@vue/compiler-sfc": "^3.0.0", "@vue/compiler-sfc": "^3.0.0",
"@babel/eslint-parser": "7.23.10", "babel-eslint": "^10.1.0",
"bootstrap": "^5.3.2", "bootstrap": "^5.0.1",
"bootstrap-icons": "^1.11.3", "bootstrap-icons": "^1.5.0",
"core-js": "^3.6.5", "core-js": "^3.6.5",
"eslint": "^7.32.0", "eslint": "^6.7.2",
"eslint-plugin-vue": "^7.0.0", "eslint-plugin-vue": "^7.0.0",
"sass": "^1.37.5", "sass": "^1.37.5",
"sass-loader": "^10.2.0", "sass-loader": "^10.2.0",
"v-tooltip": "^4.0.0-beta.17", "v-tooltip": "^4.0.0-alpha.1",
"vue": "^3.4.0", "vue": "^3.0.0",
"vue-router": "^4.2.5", "vue-router": "^4.0.0-0",
"vuex": "^4.1.0" "vuex": "^4.0.2"
} }
} }

View File

@ -21,11 +21,3 @@
.search-card{ .search-card{
height: 100%; height: 100%;
} }
.card-body {
background-color: #fff;
}
.list-group-flush > .list-group-item {
background-color: #fff;
}

View File

@ -95,10 +95,11 @@ export default {
console.error(error); console.error(error);
} }
}, },
async submitFormEdit() { async submitFormEdit(isProfileVisible) {
this.showErrorMessage = false this.showErrorMessage = false
this.showSuccessMessage = false this.showSuccessMessage = false
const userId = store.state.currentUserId const userId = store.state.currentUserId
this.profile.visible = isProfileVisible;
try { try {
const body = JSON.stringify(this.profile) const body = JSON.stringify(this.profile)

View File

@ -12,25 +12,8 @@ SPDX-License-Identifier: AGPL-3.0-or-later
</div> </div>
</div> </div>
<div class="container"> <div class="container">
<form @submit.prevent="submitFormEdit()"> <form @submit.prevent="submitFormEdit(false)">
<Section title="Grunddaten"> <Section title="Grunddaten">
<div class="mb-4">
<div class="form-check form-switch">
<input
class="form-check-input"
type="checkbox"
role="switch"
v-model="profile.visible"
id="visibility"
>
<label
class="form-check-label"
for="visibility">
Profil für angemeldete Benutzer sichtbar
</label>
</div>
</div>
<div class="row mb-4"> <div class="row mb-4">
<div class="col-12 col-md-4 mb-3 mb-md-0"> <div class="col-12 col-md-4 mb-3 mb-md-0">
<label class="form-label">Nickname</label> <label class="form-label">Nickname</label>
@ -223,10 +206,16 @@ SPDX-License-Identifier: AGPL-3.0-or-later
Gespeichert Gespeichert
</div> </div>
<button <button
class="btn btn-primary ms-3" class="btn btn-secondary ms-3"
@click="submitFormEdit()" @click="submitFormEdit(false)"
> >
Speichern Entwurf Speichern
</button>
<button
class="btn btn-primary ms-3"
@click="submitFormEdit(true)"
>
Speichern und Veröffentlichen
</button> </button>
</div> </div>
</div> </div>