mirror of
https://github.com/plankanban/planka.git
synced 2025-12-10 17:23:16 +03:00
Compare commits
217 Commits
planka-1.0
...
8a288d1816
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8a288d1816 | ||
|
|
197ebc16db | ||
|
|
5c787d65a9 | ||
|
|
7e41a0167d | ||
|
|
c68ab99bfe | ||
|
|
561d2c77d4 | ||
|
|
6e44b2ad19 | ||
|
|
cd5685049e | ||
|
|
015562d8da | ||
|
|
7da8d8219b | ||
|
|
4ed0f02657 | ||
|
|
0736b8fea0 | ||
|
|
7a05bf2a30 | ||
|
|
d7cb2087e5 | ||
|
|
22baf5ab12 | ||
|
|
33a7a6ccb1 | ||
|
|
b4cbd32bf2 | ||
|
|
5a2564f575 | ||
|
|
3edcc5ae61 | ||
|
|
d99e949d07 | ||
|
|
f5000e8c40 | ||
|
|
d385a1c238 | ||
|
|
0d8edbbbc6 | ||
|
|
04e5124dfd | ||
|
|
3a84fb2d52 | ||
|
|
232a760a3d | ||
|
|
2f873dc82f | ||
|
|
c35e720265 | ||
|
|
fee300908c | ||
|
|
20d8f8ae53 | ||
|
|
39f970689a | ||
|
|
d8d4558b8e | ||
|
|
e080d30b32 | ||
|
|
1df346d590 | ||
|
|
35f33a38ff | ||
|
|
f968e1976b | ||
|
|
ab0dbc4b7f | ||
|
|
a52b41207a | ||
|
|
18104a486f | ||
|
|
213f6cddc9 | ||
|
|
393fdbc6d1 | ||
|
|
c6f4dcdb70 | ||
|
|
3a12bb7457 | ||
|
|
4985643e68 | ||
|
|
709dd91e82 | ||
|
|
97ddefc236 | ||
|
|
33eef6e068 | ||
|
|
230b31914c | ||
|
|
98f537c2bc | ||
|
|
c4e2221444 | ||
|
|
b4979d214f | ||
|
|
494800d131 | ||
|
|
dca4b65921 | ||
|
|
9a81c83f03 | ||
|
|
2c716a53c9 | ||
|
|
5636cf27c0 | ||
|
|
68549d0da8 | ||
|
|
4910600e6c | ||
|
|
7fea8f5362 | ||
|
|
5ad3134519 | ||
|
|
e6b4c33542 | ||
|
|
984b789e2e | ||
|
|
b47a337a4f | ||
|
|
5dc783c5b5 | ||
|
|
37bd4d1349 | ||
|
|
7da241c5a3 | ||
|
|
203fbd152d | ||
|
|
eb259a1482 | ||
|
|
9683227fbc | ||
|
|
5f34a737bb | ||
|
|
069813e49d | ||
|
|
fc8f434843 | ||
|
|
2b5068de21 | ||
|
|
d792e4064b | ||
|
|
6863f557a3 | ||
|
|
21033ad8bc | ||
|
|
4c5c7799f2 | ||
|
|
60a94f33fc | ||
|
|
4d77a1f596 | ||
|
|
2f4bcb0583 | ||
|
|
bb40a22563 | ||
|
|
22cde183ff | ||
|
|
168e556f06 | ||
|
|
2fc7d672f6 | ||
|
|
3dab4b8bea | ||
|
|
d3cf23d3aa | ||
|
|
a22afd0bed | ||
|
|
12c40d8ebe | ||
|
|
4d85b46e8f | ||
|
|
6515877eb6 | ||
|
|
cbb00d1d59 | ||
|
|
b4f6e24442 | ||
|
|
48e261ffc4 | ||
|
|
0049ba2145 | ||
|
|
a37a6b45b1 | ||
|
|
c272a65015 | ||
|
|
fb8a4a1c45 | ||
|
|
e2a9b30f46 | ||
|
|
4effc0ce23 | ||
|
|
001621eec7 | ||
|
|
5beafca07e | ||
|
|
d40b4d3224 | ||
|
|
ef35ec279e | ||
|
|
6dfb5ba024 | ||
|
|
df023439c1 | ||
|
|
e742cb4737 | ||
|
|
d8fbf2f909 | ||
|
|
fc9c94b3b6 | ||
|
|
2e0483d9e9 | ||
|
|
fdac299fc7 | ||
|
|
e659ed4a2d | ||
|
|
adf60c0c74 | ||
|
|
71b4fd32cc | ||
|
|
b3f226c10b | ||
|
|
b4be12eb28 | ||
|
|
3aba4d4a56 | ||
|
|
70cadcd974 | ||
|
|
230f50e3d9 | ||
|
|
49203e9d56 | ||
|
|
709a0d1758 | ||
|
|
69c75a03b1 | ||
|
|
4d40af9c8a | ||
|
|
b76ca9547f | ||
|
|
9d07178e57 | ||
|
|
4346b7040a | ||
|
|
b61b4e658f | ||
|
|
a8b9ac8165 | ||
|
|
a55fc08c43 | ||
|
|
76c7be5063 | ||
|
|
b22dba0d11 | ||
|
|
f0680831c2 | ||
|
|
e58a9f5d21 | ||
|
|
463b6284c7 | ||
|
|
f5653cde80 | ||
|
|
b37fc61b12 | ||
|
|
6988864808 | ||
|
|
c8cb1f4a20 | ||
|
|
774bdc2b64 | ||
|
|
b2e8c453b7 | ||
|
|
8df49a636a | ||
|
|
2d1a8658bb | ||
|
|
3126a40bba | ||
|
|
99a06ce1ae | ||
|
|
98a7f1c9a9 | ||
|
|
bdac15240f | ||
|
|
5a3a4240c6 | ||
|
|
144731ccb4 | ||
|
|
e24bb845c6 | ||
|
|
240b01e694 | ||
|
|
07483909b4 | ||
|
|
84dc0385af | ||
|
|
041199af8b | ||
|
|
f72ac437b9 | ||
|
|
128028c848 | ||
|
|
0f1e7ecc2c | ||
|
|
9ca49f1f51 | ||
|
|
8447f0c884 | ||
|
|
180984799c | ||
|
|
2b86484421 | ||
|
|
a6820162fb | ||
|
|
037a9101c2 | ||
|
|
754629e6a9 | ||
|
|
8bc1569242 | ||
|
|
1a8dcd9858 | ||
|
|
edda5dda79 | ||
|
|
6dbce8c790 | ||
|
|
b696fe0e4d | ||
|
|
7286ecaf35 | ||
|
|
2e6658221f | ||
|
|
63de346b0e | ||
|
|
585464eef3 | ||
|
|
c2bd31d523 | ||
|
|
21f90610bc | ||
|
|
608a7c983f | ||
|
|
dd5e0f448f | ||
|
|
c4a48d510b | ||
|
|
2f62d56242 | ||
|
|
4eb8b75c24 | ||
|
|
49770ea9ec | ||
|
|
40a84d0c8a | ||
|
|
9690f7b73f | ||
|
|
04b97b66cb | ||
|
|
46f4d5c1f8 | ||
|
|
fc7863aaaf | ||
|
|
6c2999044b | ||
|
|
a2495b664e | ||
|
|
e0374f30db | ||
|
|
665f9998dc | ||
|
|
fcf1fc4319 | ||
|
|
4e05b88ecf | ||
|
|
c0b0436851 | ||
|
|
eb2a3a2875 | ||
|
|
74274e511f | ||
|
|
40e107d6d4 | ||
|
|
39df82c1ce | ||
|
|
42817c5199 | ||
|
|
20b5351dfe | ||
|
|
978b2a7402 | ||
|
|
a7c1d4ca11 | ||
|
|
71e2c5d8df | ||
|
|
4049b4c396 | ||
|
|
f9d3e73651 | ||
|
|
86cfd155f2 | ||
|
|
777ff467f3 | ||
|
|
9fd9370120 | ||
|
|
2db75ed420 | ||
|
|
c05dcf45f2 | ||
|
|
d5fd2fd33b | ||
|
|
5d53f44fe8 | ||
|
|
3b8bec5743 | ||
|
|
652c5e9475 | ||
|
|
3aedbff5d0 | ||
|
|
eeb52d19bb | ||
|
|
f6568ce41b | ||
|
|
f43785c3d0 | ||
|
|
ac8361aee3 | ||
|
|
3bd8eba416 |
3
.github/ISSUE_TEMPLATE/2-feature-request.yml
vendored
3
.github/ISSUE_TEMPLATE/2-feature-request.yml
vendored
@@ -5,11 +5,12 @@ body:
|
||||
- type: dropdown
|
||||
id: idea-type
|
||||
attributes:
|
||||
label: Is this a feature for the backend or frontend?
|
||||
label: Which part of the project does this feature apply to?
|
||||
multiple: true
|
||||
options:
|
||||
- Backend
|
||||
- Frontend
|
||||
- Chart
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
|
||||
@@ -15,7 +15,7 @@ jobs:
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '18'
|
||||
node-version: '22'
|
||||
cache: 'npm'
|
||||
|
||||
- name: Update npm
|
||||
|
||||
20
.github/workflows/build-and-test.yml
vendored
20
.github/workflows/build-and-test.yml
vendored
@@ -13,9 +13,9 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
env:
|
||||
POSTGRES_DB: planka
|
||||
POSTGRES_USER: user
|
||||
POSTGRES_PASSWORD: password
|
||||
POSTGRES_USERNAME: planka
|
||||
POSTGRES_PASSWORD: planka
|
||||
POSTGRES_DATABASE: planka
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
@@ -24,15 +24,15 @@ jobs:
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '18'
|
||||
node-version: '22'
|
||||
cache: 'npm'
|
||||
|
||||
- name: Set up PostgreSQL
|
||||
uses: ikalnytskyi/action-setup-postgres@v5
|
||||
with:
|
||||
database: ${{ env.POSTGRES_DB }}
|
||||
username: ${{ env.POSTGRES_USER }}
|
||||
username: ${{ env.POSTGRES_USERNAME }}
|
||||
password: ${{ env.POSTGRES_PASSWORD }}
|
||||
database: ${{ env.POSTGRES_DATABASE }}
|
||||
|
||||
- name: Cache Node.js modules
|
||||
uses: actions/cache@v3
|
||||
@@ -58,7 +58,7 @@ jobs:
|
||||
client/tests/setup-symlinks.sh
|
||||
cd server
|
||||
cp .env.sample .env
|
||||
sed -i "s|^DATABASE_URL=.*|DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@localhost/${POSTGRES_DB}|" .env
|
||||
sed -i "s|^DATABASE_URL=.*|DATABASE_URL=postgresql://${POSTGRES_USERNAME}:${POSTGRES_PASSWORD}@localhost/${POSTGRES_DATABASE}|" .env
|
||||
npm run db:init
|
||||
npm start --prod &
|
||||
|
||||
@@ -67,6 +67,12 @@ jobs:
|
||||
sudo apt-get install wait-for-it -y
|
||||
wait-for-it -h localhost -p 1337 -t 10
|
||||
|
||||
- name: Seed database with terms signature
|
||||
run: |
|
||||
TERMS_SIGNATURE=$(sha256sum terms/en-US/extended.md | awk '{print $1}')
|
||||
PGPASSWORD=$POSTGRES_PASSWORD psql -h localhost -U $POSTGRES_USERNAME -d $POSTGRES_DATABASE -c "UPDATE user_account SET terms_signature = '$TERMS_SIGNATURE';"
|
||||
working-directory: ./server
|
||||
|
||||
- name: Run UI tests
|
||||
run: |
|
||||
npx playwright install chromium
|
||||
|
||||
2
.github/workflows/lint.yml
vendored
2
.github/workflows/lint.yml
vendored
@@ -16,7 +16,7 @@ jobs:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '18'
|
||||
node-version: '22'
|
||||
cache: 'npm'
|
||||
|
||||
- name: Cache Node.js modules
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
FROM node:18-alpine AS server-dependencies
|
||||
FROM node:22-alpine AS server-dependencies
|
||||
|
||||
RUN apk -U upgrade \
|
||||
&& apk add build-base python3 --no-cache
|
||||
@@ -6,11 +6,12 @@ RUN apk -U upgrade \
|
||||
WORKDIR /app
|
||||
|
||||
COPY server/package.json server/package-lock.json server/requirements.txt ./
|
||||
COPY server/patches ./patches
|
||||
|
||||
RUN npm install npm --global \
|
||||
&& npm install --omit=dev
|
||||
|
||||
FROM node:lts AS client
|
||||
FROM node:22 AS client
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
@@ -21,7 +22,7 @@ RUN npm install npm --global \
|
||||
|
||||
RUN DISABLE_ESLINT_PLUGIN=true npm run build
|
||||
|
||||
FROM node:18-alpine
|
||||
FROM node:22-alpine
|
||||
|
||||
RUN apk -U upgrade \
|
||||
&& apk add bash python3 --no-cache \
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
FROM node:18-alpine
|
||||
FROM node:22-alpine
|
||||
|
||||
RUN apk -U upgrade \
|
||||
&& apk add bash build-base python3 xdg-utils --no-cache \
|
||||
&& npm install npm --global
|
||||
|
||||
USER node
|
||||
WORKDIR /app
|
||||
|
||||
28
LICENSE.md
28
LICENSE.md
@@ -1,15 +1,17 @@
|
||||
**PLANKA Community License**
|
||||
|
||||
Version 1.0 - Last updated: May 2, 2025
|
||||
Version 1.1 - Last updated: May 20, 2025
|
||||
|
||||
Related files in English:
|
||||
|
||||
- PLANKA Community License EN.md (this file)
|
||||
- [PLANKA Enterprise License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md)
|
||||
- [PLANKA Commercial License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md)
|
||||
- [PLANKA License Guide EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20EN.md)
|
||||
|
||||
Related files in German:
|
||||
|
||||
- [PLANKA Community License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md)
|
||||
- [PLANKA Enterprise License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md)
|
||||
- [PLANKA Commercial License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md)
|
||||
- [PLANKA License Guide DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20DE.md)
|
||||
|
||||
---
|
||||
@@ -19,18 +21,18 @@ Related files in German:
|
||||
Files accessible to and marked for community use are licensed as follows:
|
||||
|
||||
- Content of branches other than the main branch (usually "master" or "main") is not licensed.
|
||||
- Source code files or other files that contain ".pe." (for "PLANKA Enterprise") in their file names or folder names or are otherwise marked as "PLANKA Enterprise" in their file headers or folders are NOT licensed under the "Fair Use License". These files are "PLANKA Enterprise" files and are licensed under the "PLANKA Enterprise License".
|
||||
- To use any "PLANKA Enterprise" files or sources, you must own a valid "PLANKA Enterprise License". You can read more about our commercial license in the [PLANKA Enterprise License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md).
|
||||
- Source code files or other files that contain ".pe." (for "PLANKA Pro/Enterprise") in their file names or folder names or are otherwise marked as "PLANKA Pro/Enterprise" in their file headers or folders are NOT licensed under the "Fair Use License". These files are "PLANKA Pro/Enterprise" files and are licensed under the "PLANKA Pro/Enterprise License".
|
||||
- To use any "PLANKA Pro/Enterprise" files or sources, you must own a valid "PLANKA Pro/Enterprise License". You can read more about our commercial license in the [PLANKA Commercial License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md).
|
||||
- All third-party components incorporated into our software are licensed under the original license provided by the owner of the applicable component.
|
||||
- Content outside of the above-mentioned files or restrictions is available under the "Fair Use License" as defined below.
|
||||
|
||||
## Fair Use License
|
||||
|
||||
Version 1.0
|
||||
Version 1.1
|
||||
|
||||
### Acceptance
|
||||
|
||||
By using the software, you agree to all of the terms and conditions below.
|
||||
By using the software, you agree to all of the terms and conditions above and below.
|
||||
|
||||
### Copyright License
|
||||
|
||||
@@ -40,9 +42,19 @@ The licensor grants you a non-exclusive, royalty-free, worldwide, non-sublicensa
|
||||
|
||||
"You may use the PLANKA name or logo only to describe that your service incorporates the software. Any other trademark use (e.g., in product names, domains, or marketing material) requires our prior written consent."
|
||||
|
||||
### Permitted Use
|
||||
|
||||
You may use or modify PLANKA (a) for personal, hobby, or educational purposes, (b) internally within your own organization, (c) for private hosting for a typical number of friends, family, or personal projects, (d) to provide free access to non-profit organizations (as recognized by applicable tax authorities), or if you are a recognized non-profit organization yourself involving external users into your mission, and (e) public educational institutions for academic/research purposes only.
|
||||
|
||||
### Restricted Use
|
||||
|
||||
Sharing accounts/credentials with third parties for business purposes or operating PLANKA as a hosted service for third parties for any commercial gain whatsoever is prohibited. Commercial gain includes any form of payment, advertising revenue, data monetization, or indirect commercial benefit or business advantage.
|
||||
|
||||
For all other PLANKA-based hosting services or shared use of PLANKA accounts across organizations, you need to buy a commercial PLANKA license.
|
||||
|
||||
### Limitations
|
||||
|
||||
You may use or modify the software (a) for personal, hobby, or educational purposes or (b) inside your own legal entity (including wholly owned subsidiaries) for workflows that are not offered as a paid product or as a cross-company service to a third party. Cross-company services or use between your legal entity and other unrelated third-party legal entities are explicitly prohibited. You may not alter, remove, or obscure any licensing, copyright, or other notices from the software provided by the licensor. Any use of the licensor's trademarks is subject to applicable law.
|
||||
You may not alter, remove, or obscure any licensing, copyright, or other notices from the software provided by the licensor. Any use of the licensor's trademarks is subject to applicable law.
|
||||
|
||||
### Patents
|
||||
|
||||
|
||||
35
LICENSES/PLANKA Commercial License DE.md
Normal file
35
LICENSES/PLANKA Commercial License DE.md
Normal file
@@ -0,0 +1,35 @@
|
||||
**PLANKA Commercial License**
|
||||
|
||||
Version 1.1 - Zuletzt aktualisiert: 20. Mai 2025
|
||||
|
||||
Zugehörige Dateien in Englisch:
|
||||
|
||||
- [PLANKA Community License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md)
|
||||
- [PLANKA Commercial License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md)
|
||||
- [PLANKA License Guide EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20EN.md)
|
||||
|
||||
Zugehörige Dateien in Deutsch:
|
||||
|
||||
- [PLANKA Community License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md)
|
||||
- PLANKA Commercial License DE.md (diese Datei)
|
||||
- [PLANKA License Guide DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20DE.md)
|
||||
|
||||
---
|
||||
|
||||
# PLANKA Pro/Enterprise-Lizenz
|
||||
|
||||
Copyright (c) 2025 bis heute von PLANKA Software GmbH.
|
||||
|
||||
Unsere Software und zugehörige Dokumentationsdateien (die "Software") dürfen nur dann produktiv genutzt werden, wenn Sie (und jede juristische Person, die Sie vertreten) eine gültige "PLANKA Pro/Enterprise-Lizenz" besitzen, die Ihrer Nutzung entspricht. Vorbehaltlich des vorstehenden Satzes steht es Ihnen frei, unsere Software zu modifizieren und Patches dafür zu veröffentlichen. Sie stimmen zu, dass die PLANKA Software GmbH und/oder ihre Lizenzgeber (falls zutreffend) alle Rechte, Titel und Ansprüche an und auf alle solche Modifikationen und/oder Patches behalten, und alle solche Modifikationen und/oder Patches dürfen nur mit einer gültigen "PLANKA Pro/Enterprise-Lizenz" für die entsprechende Nutzung verwendet, kopiert, modifiziert, angezeigt, verteilt oder anderweitig genutzt werden. Ungeachtet des Vorstehenden dürfen Sie die Software für Entwicklungs- und Testzwecke ohne Abonnement kopieren und modifizieren. Sie stimmen zu, dass PLANKA Software GmbH und/oder ihre Lizenzgeber (falls zutreffend) alle Rechte, Titel und Ansprüche an und auf alle solche Modifikationen behalten. Es werden Ihnen keine anderen Rechte gewährt als die, die hier ausdrücklich genannt sind. Vorbehaltlich des Vorstehenden ist es verboten, die Software zu kopieren, zusammenzuführen, zu veröffentlichen, zu verteilen, zu unterlizenzieren und/oder zu verkaufen.
|
||||
|
||||
#### Komponenten von Drittanbietern
|
||||
|
||||
Für alle Komponenten von Drittanbietern, die in unsere Software integriert sind, werden diese Komponenten unter der ursprünglichen Lizenz lizenziert, die vom Eigentümer der jeweiligen Komponente bereitgestellt wird.
|
||||
|
||||
## PLANKA Pro/Enterprise Repositories
|
||||
|
||||
Nach dem Kauf unserer "PLANKA Pro/Enterprise-Lizenz" erhalten Sie Zugang zu unseren "PLANKA Pro/Enterprise"-Repositories. Hier finden Sie unsere neuesten stabilen Builds, die umfangreiche, eingehende Tests bestanden haben und als kampferprobt gelten. Unter keinen Umständen dürfen Sie Dateien, Quellcode oder Teile aus unseren "PLANKA Pro/Enterprise"-Repositories ohne vorherige Genehmigung der PLANKA Software GmbH an Personen weitergeben, die nicht zugangsberechtigt sind.
|
||||
|
||||
## Eingeschränkte Garantie
|
||||
|
||||
UNSERE SOFTWARE WIRD "WIE SIE IST" BEREITGESTELLT, OHNE JEGLICHE GARANTIE, AUSDRÜCKLICH ODER IMPLIZIERT, EINSCHLIEßLICH, ABER NICHT BESCHRÄNKT AUF DIE GARANTIEN DER MARKTGÄNGIGKEIT, EIGNUNG FÜR EINEN BESTIMMTEN ZWECK UND NICHTVERLETZUNG VON RECHTEN DRITTER. IN KEINEM FALL HAFTEN DIE AUTOREN ODER URHEBERRECHTSINHABER FÜR ANSPRÜCHE, SCHÄDEN ODER ANDERE HAFTUNG, OB AUS VERTRAG, UNERLAUBTER HANDLUNG ODER ANDERWEITIG, DIE SICH AUS, AUS ODER IN VERBINDUNG MIT DER SOFTWARE ODER DER NUTZUNG ODER ANDEREN GESCHÄFTEN MIT DER SOFTWARE ERGEBEN.
|
||||
35
LICENSES/PLANKA Commercial License EN.md
Normal file
35
LICENSES/PLANKA Commercial License EN.md
Normal file
@@ -0,0 +1,35 @@
|
||||
**PLANKA Commercial License**
|
||||
|
||||
Version 1.1 - Last updated: May 20, 2025
|
||||
|
||||
Related files in English:
|
||||
|
||||
- [PLANKA Community License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md)
|
||||
- PLANKA Commercial License EN.md (this file)
|
||||
- [PLANKA License Guide EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20EN.md)
|
||||
|
||||
Related files in German:
|
||||
|
||||
- [PLANKA Community License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md)
|
||||
- [PLANKA Commercial License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md)
|
||||
- [PLANKA License Guide DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20DE.md)
|
||||
|
||||
---
|
||||
|
||||
# PLANKA Pro/Enterprise License
|
||||
|
||||
Copyright (c) 2025 to present by PLANKA Software GmbH.
|
||||
|
||||
Our software and associated documentation files (the "Software") may only be used in production if you (and any entity that you represent) hold a valid "PLANKA Pro/Enterprise License" corresponding to your usage. Subject to the foregoing sentence, you are free to modify our Software and publish patches for it. You agree that PLANKA Software GmbH and/or its licensors (as applicable) retain all right, title, and interest in and to all such modifications and/or patches, and all such modifications and/or patches may only be used, copied, modified, displayed, distributed, or otherwise exploited with a valid "PLANKA Pro/Enterprise License" for the corresponding usage. Notwithstanding the foregoing, you may copy and modify the Software for development and testing purposes without requiring a subscription. You agree that PLANKA Software GmbH and/or its licensors (as applicable) retain all right, title, and interest in and to all such modifications. You are not granted any other rights beyond what is expressly stated herein. Subject to the foregoing, it is forbidden to copy, merge, publish, distribute, sublicense, and/or sell the Software.
|
||||
|
||||
#### Third-Party Components
|
||||
|
||||
For all third-party components incorporated into our Software, those components are licensed under the original license provided by the owner of the applicable component.
|
||||
|
||||
## PLANKA Pro/Enterprise Repositories
|
||||
|
||||
After purchasing our "PLANKA Pro/Enterprise License", you get access to our "PLANKA Pro/Enterprise" repositories. Here you find our latest stable builds, which have passed extensive in-depth tests and are considered battle-proof. Under no circumstances are you allowed to pass files, source code, or any part of it from our "PLANKA Pro/Enterprise" repositories to anyone not eligible for access without prior permission from PLANKA Software GmbH.
|
||||
|
||||
## Limited Warranty
|
||||
|
||||
OUR SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
@@ -1,36 +1,38 @@
|
||||
**PLANKA Community License**
|
||||
|
||||
Version 1.0 - Zuletzt aktualisiert: 2. Mai 2025
|
||||
Version 1.1 - Zuletzt aktualisiert: 20. Mai 2025
|
||||
|
||||
Zugehörige Dateien in Englisch:
|
||||
|
||||
- [PLANKA Community License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md)
|
||||
- [PLANKA Enterprise License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md)
|
||||
- [PLANKA Commercial License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md)
|
||||
- [PLANKA License Guide EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20EN.md)
|
||||
|
||||
Zugehörige Dateien in Deutsch:
|
||||
|
||||
- PLANKA Community License DE.md (diese Datei)
|
||||
- [PLANKA Enterprise License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md)
|
||||
- [PLANKA Commercial License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md)
|
||||
- [PLANKA License Guide DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20DE.md)
|
||||
|
||||
---
|
||||
|
||||
# PLANKA-Gemeinnutzungslizenz
|
||||
# PLANKA Community-Lizenz
|
||||
|
||||
Für die Gemeinschaft zugängliche und gekennzeichnete Dateien sind wie folgt lizenziert:
|
||||
|
||||
- Inhalte von Sourcecode-Branches außer dem Hauptbranch (üblicherweise "master" oder "main") sind nicht zur Gemeinnutzung bestimmt und lizenziert.
|
||||
- Quellcode-Dateien oder andere Dateien, die ".pe." (für "PLANKA Enterprise") in ihren Datei- oder Ordnernamen enthalten oder anderweitig durch "PLANKA Enterprise" in ihren Dateiköpfen oder Ordnern als Unternehmenslizenz gekennzeichnet sind, sind NICHT unter der "Fair Use Lizenz" lizenziert. Diese Dateien sind "PLANKA Enterprise"-Dateien und sind unter der "PLANKA-Unternehmenslizenz" lizenziert.
|
||||
- Um "PLANKA Enterprise"-Dateien oder Quellen zu nutzen, müssen Sie eine gültige "PLANKA-Unternehmenslizenz" besitzen. Sie können mehr über unsere kommerzielle Lizenz in der [PLANKA Enterprise License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md) lesen.
|
||||
- Inhalte von Sourcecode-Branches außer dem Hauptbranch (üblicherweise "master" oder "main") sind nicht lizenziert.
|
||||
- Quellcode-Dateien oder andere Dateien, die ".pe." (für "PLANKA Pro/Enterprise") in ihren Datei- oder Ordnernamen enthalten oder anderweitig durch "PLANKA Pro/Enterprise" in ihren Dateiköpfen oder Ordnern gekennzeichnet sind, sind NICHT unter der "Fair Use Lizenz" lizenziert. Diese Dateien sind "PLANKA Pro/Enterprise"-Dateien und sind unter der "PLANKA Pro/Enterprise-Lizenz" lizenziert.
|
||||
- Um "PLANKA Pro/Enterprise"-Dateien oder Quellen zu nutzen, müssen Sie eine gültige "PLANKA Pro/Enterprise-Lizenz" besitzen. Sie können mehr über unsere kommerzielle Lizenz in der [PLANKA Commercial License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md) lesen.
|
||||
- Alle Komponenten von Drittanbietern, die in unsere Software integriert sind, sind unter der ursprünglichen Lizenz lizenziert, die vom Eigentümer der jeweiligen Komponente bereitgestellt wird.
|
||||
- Inhalte außerhalb der oben genannten Dateien oder Einschränkungen sind unter der "Fair Use Lizenz" verfügbar, wie unten definiert.
|
||||
|
||||
## Fair Use Lizenz
|
||||
|
||||
Version 1.0
|
||||
Version 1.1
|
||||
|
||||
### Annahme
|
||||
|
||||
Durch die Nutzung der Software stimmen Sie allen unten aufgeführten Bedingungen zu.
|
||||
Durch die Nutzung der Software stimmen Sie allen oben und unten aufgeführten Bedingungen zu.
|
||||
|
||||
### Urheberrechtslizenz
|
||||
|
||||
@@ -40,9 +42,19 @@ Der Lizenzgeber gewährt Ihnen eine nicht-exklusive, gebührenfreie, weltweite,
|
||||
|
||||
"Sie dürfen den Namen oder das Logo von PLANKA nur verwenden, um zu beschreiben, dass Ihr Dienst die Software enthält. Jede andere Markennutzung (z.B. in Produktnamen, Domains oder Marketingmaterial) bedarf unserer vorherigen schriftlichen Zustimmung."
|
||||
|
||||
### Erlaubte Nutzung
|
||||
|
||||
Sie dürfen PLANKA nutzen oder modifizieren (a) für persönliche, Hobby- oder Bildungszwecke, (b) intern innerhalb Ihrer eigenen Organisation, (c) für privates Hosting für eine typische Anzahl von Freunden, Familie oder persönlichen Projekten, (d) um gemeinnützigen Organisationen (wie von den jeweiligen Steuerbehörden anerkannt) kostenlosen Zugang zu gewähren, oder wenn Sie selbst eine anerkannte gemeinnützige Organisation sind, die externe Nutzer in Ihre Mission einbezieht, und (e) öffentliche Bildungseinrichtungen ausschließlich für akademische/Forschungszwecke.
|
||||
|
||||
### Eingeschränkte Nutzung
|
||||
|
||||
Das Teilen von Konten/Zugangsdaten mit Dritten für geschäftliche Zwecke oder der Betrieb von PLANKA als gehosteter Dienst für Dritte zu jeglichen kommerziellen Gewinn ist untersagt. Kommerzieller Gewinn umfasst jede Form von Zahlung, Werbeeinnahmen, Datenmonetarisierung oder indirekten kommerziellen Nutzen oder Geschäftsvorteil.
|
||||
|
||||
Für alle anderen PLANKA-basierten Hosting-Dienste oder die gemeinsame Nutzung von PLANKA-Konten zwischen Organisationen müssen Sie eine kommerzielle PLANKA-Lizenz erwerben.
|
||||
|
||||
### Einschränkungen
|
||||
|
||||
Sie dürfen die Software nutzen oder modifizieren (a) für persönliche, Hobby- oder Bildungszwecke oder (b) innerhalb Ihrer eigenen juristischen Person (einschließlich hundertprozentiger Tochtergesellschaften) für Arbeitsabläufe, die nicht als kostenpflichtiges Produkt oder als unternehmensübergreifender Dienst an Dritte angeboten werden. Unternehmensübergreifende Dienste oder Nutzung zwischen deren juristischen Personen und anderen nicht verbundenen dritten juristischen Personen sind ausdrücklich untersagt. Sie dürfen keine vom Lizenzgeber bereitgestellten Lizenz-, Urheber- oder anderen Hinweise in der Software verändern, entfernen oder verschleiern. Jede Nutzung der Marken des Lizenzgebers unterliegt dem geltenden Recht.
|
||||
Sie dürfen keine vom Lizenzgeber bereitgestellten Lizenz-, Urheber- oder anderen Hinweise in der Software verändern, entfernen oder verschleiern. Jede Nutzung der Marken des Lizenzgebers unterliegt dem geltenden Recht.
|
||||
|
||||
### Patente
|
||||
|
||||
|
||||
@@ -1,15 +1,17 @@
|
||||
**PLANKA Community License**
|
||||
|
||||
Version 1.0 - Last updated: May 2, 2025
|
||||
Version 1.1 - Last updated: May 20, 2025
|
||||
|
||||
Related files in English:
|
||||
|
||||
- PLANKA Community License EN.md (this file)
|
||||
- [PLANKA Enterprise License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md)
|
||||
- [PLANKA Commercial License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md)
|
||||
- [PLANKA License Guide EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20EN.md)
|
||||
|
||||
Related files in German:
|
||||
|
||||
- [PLANKA Community License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md)
|
||||
- [PLANKA Enterprise License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md)
|
||||
- [PLANKA Commercial License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md)
|
||||
- [PLANKA License Guide DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20DE.md)
|
||||
|
||||
---
|
||||
@@ -19,18 +21,18 @@ Related files in German:
|
||||
Files accessible to and marked for community use are licensed as follows:
|
||||
|
||||
- Content of branches other than the main branch (usually "master" or "main") is not licensed.
|
||||
- Source code files or other files that contain ".pe." (for "PLANKA Enterprise") in their file names or folder names or are otherwise marked as "PLANKA Enterprise" in their file headers or folders are NOT licensed under the "Fair Use License". These files are "PLANKA Enterprise" files and are licensed under the "PLANKA Enterprise License".
|
||||
- To use any "PLANKA Enterprise" files or sources, you must own a valid "PLANKA Enterprise License". You can read more about our commercial license in the [PLANKA Enterprise License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md).
|
||||
- Source code files or other files that contain ".pe." (for "PLANKA Pro/Enterprise") in their file names or folder names or are otherwise marked as "PLANKA Pro/Enterprise" in their file headers or folders are NOT licensed under the "Fair Use License". These files are "PLANKA Pro/Enterprise" files and are licensed under the "PLANKA Pro/Enterprise License".
|
||||
- To use any "PLANKA Pro/Enterprise" files or sources, you must own a valid "PLANKA Pro/Enterprise License". You can read more about our commercial license in the [PLANKA Commercial License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md).
|
||||
- All third-party components incorporated into our software are licensed under the original license provided by the owner of the applicable component.
|
||||
- Content outside of the above-mentioned files or restrictions is available under the "Fair Use License" as defined below.
|
||||
|
||||
## Fair Use License
|
||||
|
||||
Version 1.0
|
||||
Version 1.1
|
||||
|
||||
### Acceptance
|
||||
|
||||
By using the software, you agree to all of the terms and conditions below.
|
||||
By using the software, you agree to all of the terms and conditions above and below.
|
||||
|
||||
### Copyright License
|
||||
|
||||
@@ -40,9 +42,19 @@ The licensor grants you a non-exclusive, royalty-free, worldwide, non-sublicensa
|
||||
|
||||
"You may use the PLANKA name or logo only to describe that your service incorporates the software. Any other trademark use (e.g., in product names, domains, or marketing material) requires our prior written consent."
|
||||
|
||||
### Permitted Use
|
||||
|
||||
You may use or modify PLANKA (a) for personal, hobby, or educational purposes, (b) internally within your own organization, (c) for private hosting for a typical number of friends, family, or personal projects, (d) to provide free access to non-profit organizations (as recognized by applicable tax authorities), or if you are a recognized non-profit organization yourself involving external users into your mission, and (e) public educational institutions for academic/research purposes only.
|
||||
|
||||
### Restricted Use
|
||||
|
||||
Sharing accounts/credentials with third parties for business purposes or operating PLANKA as a hosted service for third parties for any commercial gain whatsoever is prohibited. Commercial gain includes any form of payment, advertising revenue, data monetization, or indirect commercial benefit or business advantage.
|
||||
|
||||
For all other PLANKA-based hosting services or shared use of PLANKA accounts across organizations, you need to buy a commercial PLANKA license.
|
||||
|
||||
### Limitations
|
||||
|
||||
You may use or modify the software (a) for personal, hobby, or educational purposes or (b) inside your own legal entity (including wholly owned subsidiaries) for workflows that are not offered as a paid product or as a cross-company service to a third party. Cross-company services or use between your legal entity and other unrelated third-party legal entities are explicitly prohibited. You may not alter, remove, or obscure any licensing, copyright, or other notices from the software provided by the licensor. Any use of the licensor's trademarks is subject to applicable law.
|
||||
You may not alter, remove, or obscure any licensing, copyright, or other notices from the software provided by the licensor. Any use of the licensor's trademarks is subject to applicable law.
|
||||
|
||||
### Patents
|
||||
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
**PLANKA Enterprise License**
|
||||
|
||||
Version 1.0 - Zuletzt aktualisiert: 2. Mai 2025
|
||||
|
||||
Zugehörige Dateien in Englisch:
|
||||
- [PLANKA Community License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md)
|
||||
- [PLANKA Enterprise License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md)
|
||||
- [PLANKA License Guide EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20EN.md)
|
||||
|
||||
Zugehörige Dateien in Deutsch:
|
||||
- [PLANKA Community License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md)
|
||||
- PLANKA Enterprise License DE.md (diese Datei)
|
||||
- [PLANKA License Guide DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20DE.md)
|
||||
|
||||
---
|
||||
|
||||
# PLANKA-Unternehmenslizenz
|
||||
|
||||
Copyright (c) 2025 von PLANKA Software GmbH.
|
||||
|
||||
Unsere Software und zugehörige Dokumentationsdateien (die "Software") dürfen nur dann produktiv genutzt werden, wenn Sie (und jede juristische Person, die Sie vertreten) eine gültige "PLANKA Enterprise License", also eine "PLANKA-Unternehmenslizenz" besitzen, die Ihrer Nutzung entspricht. Vorbehaltlich des vorstehenden Satzes steht es Ihnen frei, unsere Software zu modifizieren und Patches dafür zu veröffentlichen. Sie stimmen zu, dass die PLANKA Software GmbH und/oder ihre Lizenzgeber (falls zutreffend) alle Rechte, Titel und Ansprüche an und auf alle solche Modifikationen und/oder Patches behalten, und alle solche Modifikationen und/oder Patches dürfen nur mit einer gültigen "PLANKA-Unternehmenslizenz" für die entsprechende Nutzung verwendet, kopiert, modifiziert, angezeigt, verteilt oder anderweitig genutzt werden. Ungeachtet des Vorstehenden dürfen Sie die Software für Entwicklungs- und Testzwecke ohne Abonnement kopieren und modifizieren. Sie stimmen zu, dass PLANKA Software GmbH und/oder ihre Lizenzgeber (falls zutreffend) alle Rechte, Titel und Ansprüche an und auf alle solche Modifikationen behalten. Es werden Ihnen keine anderen Rechte gewährt als die, die hier ausdrücklich genannt sind. Vorbehaltlich des Vorstehenden ist es verboten, die Software zu kopieren, zusammenzuführen, zu veröffentlichen, zu verteilen, zu unterlizenzieren und/oder zu verkaufen.
|
||||
|
||||
#### Komponenten von Drittanbietern
|
||||
|
||||
Für alle Komponenten von Drittanbietern, die in unsere Software integriert sind, werden diese Komponenten unter der ursprünglichen Lizenz lizenziert, die vom Eigentümer der jeweiligen Komponente bereitgestellt wird.
|
||||
|
||||
## PLANKA Enterprise Repositories
|
||||
|
||||
Nach dem Kauf unserer "PLANKA-Unternehmenslizenz" erhalten Sie Zugang zu unseren "PLANKA Enterprise"-Repositories. Hier finden Sie unsere neuesten stabilen Builds, die umfangreiche, eingehende Tests bestanden haben und als kampferprobt gelten. Unter keinen Umständen dürfen Sie Dateien, Quellcode oder Teile aus unseren "PLANKA Enterprise"-Repositories ohne vorherige Genehmigung der PLANKA Software GmbH an Personen weitergeben, die nicht zugangsberechtigt sind-.
|
||||
|
||||
## Eingeschränkte Garantie
|
||||
|
||||
UNSERE SOFTWARE WIRD "WIE SIE IST" BEREITGESTELLT, OHNE JEGLICHE GARANTIE, AUSDRÜCKLICH ODER IMPLIZIERT, EINSCHLIEßLICH, ABER NICHT BESCHRÄNKT AUF DIE GARANTIEN DER MARKTGÄNGIGKEIT, EIGNUNG FÜR EINEN BESTIMMTEN ZWECK UND NICHTVERLETZUNG VON RECHTEN DRITTER. IN KEINEM FALL HAFTEN DIE AUTOREN ODER URHEBERRECHTSINHABER FÜR ANSPRÜCHE, SCHÄDEN ODER ANDERE HAFTUNG, OB AUS VERTRAG, UNERLAUBTER HANDLUNG ODER ANDERWEITIG, DIE SICH AUS, AUS ODER IN VERBINDUNG MIT DER SOFTWARE ODER DER NUTZUNG ODER ANDEREN GESCHÄFTEN MIT DER SOFTWARE ERGEBEN.
|
||||
@@ -1,33 +0,0 @@
|
||||
**PLANKA Enterprise License**
|
||||
|
||||
Version 1.0 - Last updated: May 2, 2025
|
||||
|
||||
Related files in English:
|
||||
- [PLANKA Community License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md)
|
||||
- PLANKA Enterprise License EN.md (this file)
|
||||
- [PLANKA License Guide EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20EN.md)
|
||||
|
||||
Related files in German:
|
||||
- [PLANKA Community License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md)
|
||||
- [PLANKA Enterprise License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md)
|
||||
- [PLANKA License Guide DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20DE.md)
|
||||
|
||||
---
|
||||
|
||||
# PLANKA Enterprise License
|
||||
|
||||
Copyright (c) 2025 to present by PLANKA Software GmbH.
|
||||
|
||||
Our software and associated documentation files (the "Software") may only be used in production if you (and any entity that you represent) hold a valid "PLANKA Enterprise License" corresponding to your usage. Subject to the foregoing sentence, you are free to modify our Software and publish patches for it. You agree that PLANKA Software GmbH and/or its licensors (as applicable) retain all right, title, and interest in and to all such modifications and/or patches, and all such modifications and/or patches may only be used, copied, modified, displayed, distributed, or otherwise exploited with a valid "PLANKA Enterprise License" for the corresponding usage. Notwithstanding the foregoing, you may copy and modify the Software for development and testing purposes without requiring a subscription. You agree that PLANKA Software GmbH and/or its licensors (as applicable) retain all right, title, and interest in and to all such modifications. You are not granted any other rights beyond what is expressly stated herein. Subject to the foregoing, it is forbidden to copy, merge, publish, distribute, sublicense, and/or sell the Software.
|
||||
|
||||
#### Third-Party Components
|
||||
|
||||
For all third-party components incorporated into our Software, those components are licensed under the original license provided by the owner of the applicable component.
|
||||
|
||||
## PLANKA Enterprise Repositories
|
||||
|
||||
After purchasing our "PLANKA Enterprise License", you get access to our "PLANKA Enterprise" repositories. Here you find our latest stable builds, which have passed extensive in-depth tests and are considered battle-proof. Under no circumstances are you allowed to pass files, source code, or any part of it from our "PLANKA Enterprise" repositories to anyone not eligible for access without prior permission from PLANKA Software GmbH.
|
||||
|
||||
## Limited Warranty
|
||||
|
||||
OUR SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
@@ -1,64 +1,66 @@
|
||||
**PLANKA License Guide**
|
||||
|
||||
Version 1.0 - Zuletzt aktualisiert: 2. Mai 2025
|
||||
Version 1.1 - Zuletzt aktualisiert: 20. Mai 2025
|
||||
|
||||
Zugehörige Dateien in Englisch:
|
||||
|
||||
- [PLANKA Community License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md)
|
||||
- [PLANKA Enterprise License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md)
|
||||
- [PLANKA Commercial License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md)
|
||||
- [PLANKA License Guide EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20EN.md)
|
||||
|
||||
Zugehörige Dateien in Deutsch:
|
||||
|
||||
- [PLANKA Community License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md)
|
||||
- [PLANKA Enterprise License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md)
|
||||
- [PLANKA Commercial License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md)
|
||||
- PLANKA License Guide DE.md (diese Datei)
|
||||
|
||||
---
|
||||
|
||||
## PLANKAs "Fair Use Lizenz" und "PLANLA-Unternehmenslizenz" (Enterprise License)
|
||||
## PLANKAs "Fair Use Lizenz" und die "PLANKA Pro/Enterprise-Lizenz"
|
||||
|
||||
Unsere [Fair Use Lizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md) und unsere [PLANKA-Unternehmenslizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md) basieren auf dem [fair-code](http://faircode.io)-Modell.
|
||||
Unsere [Fair Use Lizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md) und unsere [PLANKA Pro/Enterprise-Lizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md) basieren auf dem [fair-code](http://faircode.io)-Modell.
|
||||
|
||||
#### Proprietäre Lizenzen für Unternehmen und die "PLANKA-Bildungslizenz" (Educational License)
|
||||
### Spezielle Lizenzierung für Bildungseinrichtungen und gemeinnützige Organisationen
|
||||
|
||||
Wir bieten unseren Unternehmenskunden nach Absprache auch proprietäre Lizenzen sowie die "PLANKA-Bildungslizenz" für Schulen und Universitäten an. Bitte kontaktieren Sie uns für detaillierte Informationen unter [license@planka.group](mailto:license@planka.group).
|
||||
Bildungseinrichtungen und gemeinnützige Organisationen, die kommerzielle Funktionen oder eine Nutzung über unsere "Fair Use Lizenz" hinaus benötigen, sind eingeladen, uns für maßgeschneiderte Lizenzlösungen und Bildungspreise zu kontaktieren. Wir freuen uns darauf, Ihrer Organisation dabei zu helfen, ihre Mission zu erfüllen!
|
||||
|
||||
# Lizenz-FAQs
|
||||
|
||||
### Unter welcher Lizenz wird PLANKA angeboten?
|
||||
|
||||
PLANKA verwendet die [Fair Use Lizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md) und die [PLANKA-Unternehmenslizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md). Diese Lizenzen basieren auf dem [fair-code](http://faircode.io)-Modell.
|
||||
PLANKA verwendet die [Fair Use Lizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md) und die [PLANKA Pro/Enterprise-Lizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md). Diese Lizenzen basieren auf dem [fair-code](http://faircode.io)-Modell.
|
||||
|
||||
### Welcher Quellcode ist durch PLANKAs "Fair Use Lizenz" abgedeckt?
|
||||
|
||||
Die [Fair Use Lizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md) gilt für unseren Quellcode, der in unserem [GitHub-Hauptrepository](https://github.com/plankanban/planka) gehostet wird, mit folgenden Ausnahmen:
|
||||
|
||||
* Inhalte von Branches außer dem Hauptbranch (üblicherweise "master" oder "main").
|
||||
- Inhalte von Branches außer dem Hauptbranch (üblicherweise "master" oder "main").
|
||||
|
||||
* Quellcode-Dateien oder andere Dateien, die ".pe." (für "PLANKA Enterprise") in ihren Datei- oder Ordnernamen enthalten.
|
||||
- Quellcode-Dateien oder andere Dateien, die ".pe." (für "PLANKA Pro/Enterprise") in ihren Datei- oder Ordnernamen enthalten.
|
||||
|
||||
* Quellcode-Dateien, die in den Dateien oder Ordnern als "PLANKA Enterprise" gekennzeichnet sind.
|
||||
- Quellcode-Dateien, die in den Dateien oder Ordnern als "PLANKA Pro/Enterprise" gekennzeichnet sind.
|
||||
|
||||
* Quellcode in Ordnern, die separate Lizenzdateien enthalten, die sie eindeutig als "PLANKA Enterprise" kennzeichnen.
|
||||
- Quellcode in Ordnern, die separate Lizenzdateien enthalten, die sie eindeutig als "PLANKA Pro/Enterprise" kennzeichnen.
|
||||
|
||||
Diese Ausnahmen sind unter der [PLANKA-Unternehmenslizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md) lizenziert.
|
||||
Diese Ausnahmen sind unter der [PLANKA Pro/Enterprise-Lizenz](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md) lizenziert.
|
||||
|
||||
### Was genau ist die "Fair Use Lizenz"?
|
||||
|
||||
Die "Fair Use Lizenz" fällt in die Kategorie der sogenannten [fair-code](http://faircode.io)-Lizenzen. PLANKAs Lizenz basiert auf und erweitert die "Sustainable Use License", die von [n8n](https://n8n.io) eingeführt wurde und für deren Beratung wir sehr dankbar sind. Mit ähnlichen Zielen vor Augen haben wir beschlossen, deren Beispiel zu folgen und dieses Lizenz-Modell für unsere eigenen Bedürfnisse anzupassen. [Weiter unten](#warum-haben-sie-diese-lizenz-gewählt) können Sie nachlesen, warum wir diese Lizenzart gewählt haben.
|
||||
|
||||
Die Lizenz gewährt unseren Benutzern das kostenlose Recht, die Community Version der Software zu nutzen, zu modifizieren und abgeleitete Werke zu erstellen und weiterzugeben, mit drei Einschränkungen:
|
||||
Die Lizenz gewährt Ihnen das kostenlose Recht, die Software zu nutzen, zu modifizieren, abgeleitete Werke zu erstellen und weiterzugeben unter folgenden Bedingungen:
|
||||
|
||||
- Sie dürfen die Software nutzen oder modifizieren (a) für persönliche, Freizeit- oder Bildungszwecke oder (b) innerhalb Ihres eigenen Unternehmens bzw. Ihrer juristischen Person (einschließlich hundertprozentiger Tochtergesellschaften) für Arbeitsabläufe, die nicht als kostenpflichtiges Produkt oder als unternehmensübergreifender Dienst für Dritte angeboten werden.
|
||||
- Sie dürfen PLANKA nutzen oder modifizieren (a) für persönliche, Hobby- oder Bildungszwecke, (b) intern innerhalb Ihrer eigenen Organisation, (c) für privates Hosting für eine typische Anzahl von Freunden, Familie oder persönlichen Projekten, (d) um gemeinnützigen Organisationen (wie von den jeweiligen Steuerbehörden anerkannt) kostenlosen Zugang zu gewähren, oder wenn Sie selbst eine anerkannte gemeinnützige Organisation sind, die externe Nutzer in Ihre Mission einbezieht, und (e) öffentliche Bildungseinrichtungen ausschließlich für akademische/Forschungszwecke.
|
||||
|
||||
- Sie dürfen keine Lizenz-, Urheber- oder sonstigen Hinweise des Lizenzgebers in der Software ändern, entfernen oder verschleiern. Jede Verwendung des Namens, bzw. von Marken des Lizenzgebers unterliegen dem geltenden Recht.
|
||||
- Das Teilen von Konten/Zugangsdaten mit Dritten für geschäftliche Zwecke oder der Betrieb von PLANKA als gehosteter Dienst für Dritte zu jeglichen kommerziellen Gewinn ist untersagt. Kommerzieller Gewinn umfasst jede Form von Zahlung, Werbeeinnahmen, Datenmonetarisierung oder indirekten kommerziellen Nutzen oder Geschäftsvorteil.
|
||||
|
||||
- "Sie dürfen den Namen oder das Logo von PLANKA verwenden, um sachlich zu beschreiben, dass Ihr Dienst die PLANKA-Software enthält oder auf andere Weise nutzt. Jede andere Verwendung der Marke/des Namens (z.B. in Produktnamen oder -marken, Domainnamen oder Marketingmaterial) erfordert unsere vorherige schriftliche Zustimmung."
|
||||
- Sie dürfen keine vom Lizenzgeber bereitgestellten Lizenz-, Urheber- oder anderen Hinweise in der Software verändern, entfernen oder verschleiern. Jede Nutzung der Marken des Lizenzgebers unterliegt dem geltenden Recht.
|
||||
|
||||
### Was ist im Rahmen der Lizenz im Kontext von PLANKAs Produkten erlaubt und was NICHT?
|
||||
|
||||
Unsere Lizenz beschränkt die Nutzung auf "interne Geschäftszwecke". In der Praxis bedeutet dies, dass jegliche Nutzung erlaubt ist, es sei denn, Sie verkaufen ein Produkt, einen Dienst oder ein Modul, bei dem der Wert vollständig oder im Wesentlichen von der PLANKA-Funktionalität abgeleitet wird.
|
||||
Unsere Lizenz erlaubt die Nutzung für "interne Geschäftszwecke" sowie für persönliche, Hobby-, Bildungs- und begrenzte private Hosting-Szenarien. Sie verbietet jedoch die Nutzung von PLANKA für jede Form des kommerziellen Gewinns, wie z.B. den Verkauf eines Produkts oder einer Dienstleistung, bei dem der Wert in irgendeiner Form von PLANKAs Funktionalität abgeleitet wird, den Betrieb als kostenpflichtiger gehosteter Dienst, die Monetarisierung von Zugang oder Benutzerdaten oder die Erzielung anderer indirekter kommerzieller Vorteile.
|
||||
|
||||
###### Hier sind einige Beispiele, die nicht erlaubt wären:
|
||||
##### Hier sind einige Beispiele, die nicht erlaubt wären:
|
||||
|
||||
- PLANKA unter einem White-Label anzubieten und es Ihren Kunden oder Partnern gegen Geld anzubieten.
|
||||
|
||||
@@ -66,25 +68,25 @@ Unsere Lizenz beschränkt die Nutzung auf "interne Geschäftszwecke". In der Pra
|
||||
|
||||
- PLANKAs API für Dienste zu nutzen, für die Geld verlangt wird.
|
||||
|
||||
- Die Verwendung von PLANKA, um Ihre eigene Organisation mit anderen Organisationen oder Personen außerhalb Ihrer eigenen Organisation zu verbinden.
|
||||
- Die Verwendung von PLANKA, um Ihre eigene juristische Person mit juristischen Personen oder Personen außerhalb Ihrer Organisation im Kontext einer kommerziellen Beziehung zu verbinden.
|
||||
|
||||
- PLANKA zur Durchführung oder Unterstützung illegaler oder rechtswidriger Aktivitäten zu verwenden.
|
||||
|
||||
###### Die folgenden Beispiele sind unter unserer Lizenz erlaubt:
|
||||
##### Die folgenden Beispiele sind unter unserer Lizenz erlaubt:
|
||||
|
||||
- Verwendung von PLANKA zur Kontrolle Ihrer internen Prozesse und Verwaltung Ihrer internen Projekte.
|
||||
|
||||
- Integration von PLANKA in andere intern genutzte Produkte, um deren Fähigkeiten zu erweitern.
|
||||
|
||||
- Bereitstellung von Beratungs- oder Bildungsdienstleistungen im Zusammenhang mit PLANKA, zum Beispiel zum Aufbau oder zur Integration von Arbeitsabläufen für oder in Verbindung mit PLANKA oder zur Entwicklung benutzerdefinierter Module zur Erweiterung seiner Funktionalitäten.
|
||||
- Bereitstellung von Beratungs- oder öffentlichen Bildungsdienstleistungen im Zusammenhang mit PLANKA, zum Beispiel zum Aufbau oder zur Integration von Arbeitsabläufen für oder in Verbindung mit PLANKA oder zur Entwicklung benutzerdefinierter Module zur Erweiterung seiner Funktionalitäten.
|
||||
|
||||
- Unterstützung von PLANKA, zum Beispiel durch Einrichtung oder Wartung auf einem internen Firmenserver.
|
||||
|
||||
### Ist es erlaubt, PLANKA als Backend-Integration zu nutzen?
|
||||
|
||||
Wenn Sie PLANKA und sein Backend sowie zugehörige Dienste außerhalb der Grenzen interner Betriebsabläufe und Integrationen innerhalb Ihrer eigenen Organisation nutzen, müssen Sie eine "PLANKA-Unternehmenslizenz" erwerben. Dies gilt auch, wenn Sie PLANKA als Kern-Backend-Infrastruktur für Drittanbieteranwendungen, -dienste oder ein System nutzen möchten, das an externe Parteien verteilt wird oder von diesen genutzt wird.
|
||||
Wenn Sie PLANKA und seine Backend-Dienste über interne Betriebsabläufe innerhalb Ihrer eigenen Organisation hinaus nutzen, indem Sie Dritten Zugang für kommerziellen Gewinn ermöglichen, wie z.B. das Teilen von Konten mit Kunden oder den Verkauf eines Produkts oder einer Dienstleistung, bei dem der Wert in irgendeiner Form von PLANKAs Funktionalität abgeleitet wird, den Betrieb als kostenpflichtiger gehosteter Dienst, die Monetarisierung von Zugang oder Benutzerdaten oder die Erzielung anderer indirekter kommerzieller Vorteile, sind Sie verpflichtet, eine "PLANKA Pro/Enterprise-Lizenz" zu erwerben.
|
||||
|
||||
Jede Vereinbarung, welche die Unterlizenzierung, Umlabelung oder anderweitige Bereitstellung von PLANKA für externe Parteien oder die Integration von PLANKA in ein anderes Produkt beinhaltet, um als primärer Dienst für dieses Produkt zu fungieren, erfordert ebenfalls eine gültige "PLANKA-Unternehmenslizenz" oder proprietäre Lizenz, die für unsere Unternehmenskunden ebenfalls verfügbar ist.
|
||||
Dies umfasst Szenarien, in denen PLANKA als Kerninfrastruktur für Drittanbieterlösungen dient, von Benutzern außerhalb Ihrer juristischen Person als Teil eines kostenpflichtigen oder kommerziellen Angebots genutzt wird oder bei denen Sie PLANKA unterlizenzieren, neu verpacken oder anderweitig externen Parteien zur Verfügung stellen. Jede Vereinbarung, die die Integration von PLANKA in ein anderes Produkt beinhaltet, um als primärer Betriebsmotor für dieses Produkt zu dienen, erfordert ebenfalls eine gültige "PLANKA Pro/Enterprise-Lizenz" oder proprietäre Lizenz, die für unsere Unternehmenskunden verfügbar ist.
|
||||
|
||||
### Können Sie mir einige schnelle Beispiele geben, um kostenlose Nutzung vs. Unternehmensnutzung zu verdeutlichen?
|
||||
|
||||
@@ -108,39 +110,67 @@ Eine Schule oder gemeinnützige Organisation bündelt PLANKA in einem kostenlose
|
||||
|
||||
**ERLAUBT** unter der "Fair Use Lizenz". Da PLANKA kostenlos und ohne kommerzielle Einnahmen im Sinn weitergegeben wird, sind Sie mehr als willkommen, gemeinnützigen Einrichtungen und Schulen einen besseren Zugang zu PLANKA zu ermöglichen.
|
||||
|
||||
**JEDOCH** wenn Sie auch planen, Schülern und Studenten Zugang zu einer zentralen bzw. schulinternen PLANKA-Instanz zu gewähren, würde dies eine "PLANKA-Bildungslizenz" erfordern, die wir sehr gerne auf Anfrage anbieten.
|
||||
**JEDOCH** wenn Sie auch planen, Schülern und Studenten Zugang zu einer ansonsten schulinternen PLANKA-Instanz zu gewähren, würde dies unsere "PLANKA-Bildungslizenz" erfordern, die wir sehr gerne auf Anfrage anbieten.
|
||||
|
||||
##### Beispiel 4: PLANKA-Logins für Kunden und Partner bereitstellen
|
||||
|
||||
Um ein besseres Projekt-Feedback zu ermöglichen, bieten Sie Ihrem Kunden oder Jemandem aus einem Partnerunternehmen Zugang zu Projektboards innerhalb Ihres Unternehmens an. Sie können nun z.B. Karten kommentieren und auch von PLANKAs Echtzeit-Update-Funktionen profitieren.
|
||||
Um ein besseres Projekt-Feedback zu ermöglichen, bieten Sie Ihrem Kunden und jemandem aus einem Joint Venture, mit denen Sie beide eine kommerzielle Beziehung haben, Zugang zu Projektboards innerhalb Ihres Unternehmens an. Sie können nun z.B. Karten kommentieren und auch von PLANKAs Echtzeit-Update-Funktionen profitieren.
|
||||
|
||||
**NICHT ERLAUBT** unter der "Fair Use Lizenz". Das Anbieten von PLANKA als Teil eines kostenpflichtigen Dienstes für Dritte oder die Bereitstellung von PLANKA-Zugang für Drittbenutzer außerhalb Ihrer eigenen Organisation erfordert, dass Sie eine "PLANKA-Unternehmenslizenz" erwerben.
|
||||
**NICHT ERLAUBT** unter der "Fair Use Lizenz". Das Anbieten von PLANKA als Teil eines kostenpflichtigen Dienstes für Dritte oder die Bereitstellung von PLANKA-Zugang für Drittbenutzer außerhalb Ihrer eigenen juristischen Person im Kontext einer kommerziellen Beziehung erfordert, dass Sie eine "PLANKA Pro/Enterprise-Lizenz" registrieren.
|
||||
|
||||
##### Beispiel 5: PLANKA als gehostetes Produkt für andere Unternehmen anbieten
|
||||
|
||||
Sie möchten Geld damit verdienen, indem Sie PLANKA anderen Unternehmen, Freiberuflern oder anderen Personen zur Verfügung stellen damit diese Zugriff auf bzw. Kontrolle über ein PLANKA-System erhalten.
|
||||
Sie möchten Geld damit verdienen, indem Sie PLANKA Unternehmen, Freiberuflern und anderen Personen zur Verfügung stellen. Auf diese Weise haben sie einfachen Zugang zu Projektmanagement und -kontrolle von überall.
|
||||
|
||||
**NICHT ERLAUBT** unter der "Fair Use Lizenz". Der Verkauf PLANKA-basierter Dienste erfordert, dass Sie einer "PLANKA-Wiederverkäuferlizenz" (Hosting License) zustimmen. Wir haben eine spezielle Hosting-Vereinbarung und sehr günstige Hosting Lizenzpreise für diejenigen, die kostenpflichtige PLANKA-Dienste für Kunden anbieten oder einfach als Wiederverkäufer für unsere eigenen "PLANKA Corporate Hosting Services" fungieren möchten.
|
||||
**NICHT ERLAUBT** unter der "Fair Use Lizenz". Der Verkauf PLANKA-basierter Dienste erfordert, dass Sie einer "PLANKA-Wiederverkäuferlizenz" zustimmen. Wir haben eine spezielle Hosting-Vereinbarung für diejenigen, die kostenpflichtige PLANKA-Dienste für Kunden anbieten oder einfach als Wiederverkäufer für unsere eigenen "PLANKA Corporate Hosting Services" fungieren möchten.
|
||||
|
||||
---
|
||||
|
||||
### Kurzübersicht der "Fair Use Lizenz"
|
||||
|
||||
- Persönliche, Bildungs-, Hobby- oder interne Geschäftsnutzung:
|
||||
|
||||
Kostenlos nutzbar. Sie können PLANKA für sich selbst, Ihr Team oder Ihre Organisation für persönliche, Bildungs- oder interne operative Zwecke nutzen, modifizieren und hosten.
|
||||
|
||||
- Nutzung durch gemeinnützige Organisationen und öffentliche Bildungseinrichtungen:
|
||||
|
||||
Kostenlos für akademische oder Forschungszwecke nutzbar, vorausgesetzt die Organisation qualifiziert sich als gemeinnützig unter den geltenden Steuergesetzen. Keine Anmeldung oder spezielle Lizenz erforderlich.
|
||||
|
||||
- Bereitstellung von Zugang für Dritte für kommerziellen Gewinn:
|
||||
|
||||
Nicht erlaubt. Das Teilen von Konten oder Zugangsdaten mit Dritten für kommerziellen Gewinn ist unter der Lizenz verboten, auch wenn Sie nicht direkt für den Zugang berechnen.
|
||||
|
||||
- Hosting von PLANKA als kommerzieller Dienst:
|
||||
|
||||
Nicht erlaubt. Sie dürfen PLANKA nicht als gehosteten Dienst anbieten oder in ein kostenpflichtiges Produkt oder eine Dienstleistung integrieren, bei dem der Wert wesentlich von PLANKA stammt. Dies umfasst Werbeeinnahmen, Datenmonetarisierung oder indirekten kommerziellen Nutzen oder Geschäftsvorteil.
|
||||
|
||||
### Was, wenn ich PLANKA für etwas nutzen möchte, das nicht durch die Lizenz erlaubt ist?
|
||||
|
||||
Sie müssen eine separate kommerzielle Vereinbarung mit uns abschließen. Wir ermutigen Softwareintegratoren und technisches Personal dazu, PLANKA in ihre Produkte zu integrieren oder mit ihnen zu verbinden und unsere umfangreiche API zu nutzen, um Prozesse innerhalb ihres Unternehmens zu steuern - wir bitten sie nur, eine Vereinbarung zu unterzeichnen, die die Nutzungsbedingungen und die von PLANKA für die Nutzung des Produkts erforderlichen Lizenzgebühren festlegt. Durch unsere API kann PLANKA externe Systeme steuern oder auf sie reagieren. Sie können [hier](https://docs.planka.cloud/docs/category/api-reference) mehr darüber erfahren oder uns hierüber kontaktieren.
|
||||
Um die Grenzen der selbst gehosteten Community-Version zu überschreiten, benötigen Sie eine "PLANKA Pro/Enterprise-Lizenz". Sobald Sie sich bei uns registrieren, werden die Beschränkungen der "Fair Use Lizenz" nicht nur rechtlich aufgehoben, sondern Sie erhalten auch Zugang zum vollständigen Enterprise-Funktionsumfang.
|
||||
|
||||
Alternativ können Sie diese Grenzen durch ein Abonnement einer gehosteten Version - entweder Community oder Pro/Enterprise - überschreiten. Dies ermöglicht beispielsweise die Bereitstellung von Konten für Ihre Kunden.
|
||||
|
||||
Wenn Sie PLANKA als Dienstleistung für andere Organisationen anbieten oder PLANKA in Ihre eigene Software integrieren möchten, müssen Sie eine separate Umsatzvereinbarung mit uns abschließen. Wir ermutigen aktiv Softwareintegratoren und technisches Personal, PLANKA in ihre anderen Produkte zu integrieren und zu verbinden und unsere umfangreiche API zu nutzen, um auf Prozesse innerhalb ihres Unternehmens zu reagieren, sie zu steuern und zu beherrschen; wir bitten sie lediglich, eine Vereinbarung zu unterzeichnen, die die Nutzungsbedingungen und die von PLANKA für die Nutzung des Produkts erforderlichen Lizenzgebühren festlegt. Über PLANKAs API kann es externe Systeme steuern und auf sie reagieren. Sie können [hier](https://docs.planka.cloud/docs/category/api-reference/) mehr darüber erfahren oder uns kontaktieren.
|
||||
|
||||
Wenn Sie sich nicht sicher sind, ob der von Ihnen ins Auge gefasste Anwendungsfall einen internen Geschäftszweck darstellt oder nicht, werfen Sie einen Blick auf die [Beispiele oben](#können-sie-mir-einige-schnelle-beispiele-geben-um-kostenlose-nutzung-vs-unternehmensnutzung-zu-verdeutlichen), und falls Sie immer noch unsicher sind, kontaktieren Sie uns bitte unter [license@planka.group](mailto:license@planka.group).
|
||||
|
||||
### Warum nutzen Sie keine Standard-Open-Source-Lizenz?
|
||||
### Warum gibt es keine kommerzielle Lizenz für eine selbst-gehostete Community-Version um die "Fair Use License"-Beschränkungen aufzuheben?
|
||||
|
||||
Wir verbringen viel Zeit damit, ein einfaches, aber leistungsstarkes Tool zu erstellen, welches die Kontrolle und Beherrschung von Projekten zu einer angenehmen Erfahrung macht. Außerdem wollten wir, dass PLANKA so weit als möglich frei verfügbar ist, während wir gleichzeitig sicherstellen müssen, dass wir ein nachhaltiges und tragfähiges Geschäft aufbauen können. In dem wir unser Produkt kostenlos, und den Quellcode verfügbar und verteilbar machten, helfen wir allen, auf das Produkt zuzugreifen. Indem wir als Unternehmen tätig sind, können wir neue Funktionen entwickeln und veröffentlichen, Fehler beheben und langfristig zuverlässige Software mit wachsendem Umfang bereitstellen.
|
||||
Wir unterstützen die selbst-gehostete Community-Version über unsere GitHub- und Discord-Community-Kanäle, aber wir können nicht effizient direkten Telefon- oder E-Mail-Support für mehrere Versionen bereitstellen, während wir unseren Verpflichtungen gegenüber zahlenden Kunden nachkommen. Deshalb ist direkter Support ausschließlich Pro/Enterprise-Kunden vorbehalten.
|
||||
|
||||
Wir bieten jedoch professionelle Installationsdienste und monatliche Serviceverträge für die Einrichtung, Aktualisierung und Überwachung aller Versionen an, um Organisationen dabei zu helfen, das Beste aus ihrer PLANKA-Bereitstellung herauszuholen - bitte kontaktieren Sie uns unter [license@planka.group](mailto:license@planka.group).
|
||||
|
||||
### Warum nutzt PLANKA keine Standard-Open-Source-Lizenz?
|
||||
|
||||
Wir verbringen viel Zeit damit, ein einfaches, aber leistungsstarkes Tool zu erstellen, welches die Kontrolle und Beherrschung von Projekten zu einer angenehmen Erfahrung macht. Außerdem wollten wir, dass PLANKA so weit als möglich frei verfügbar ist, während wir gleichzeitig sicherstellen müssen, dass wir ein nachhaltiges und tragfähiges Geschäft aufbauen können. Indem wir unser Produkt kostenlos nutzbar, einfach verteilbar und quelloffen machten, helfen wir allen, auf das Produkt zuzugreifen. Indem wir als Unternehmen tätig sind, können wir langfristig neue Funktionen entwickeln und veröffentlichen, Fehler beheben und zuverlässige Software in großem Maßstab bereitstellen.
|
||||
|
||||
### Warum haben Sie diese Lizenz gewählt?
|
||||
|
||||
Wir glauben, dass die "Fair Use Lizenz" sowohl für die Gemeinschaft als auch für die Entwickler von Vorteil ist. Entwicklung ist ein kostspieliges Unterfangen, und eine Community-Version kostenlos weiterzugeben, ist ein Risiko, welches viele Unternehmen nicht überleben, ohne ihre Software oder ihr Unternehmen zu veräußern. Daher leben viele Open-Source-Unternehmen von Spenden oder Finanzinvestoren. Anstatt unsere Seele zu verkaufen, verkaufen wir Dienstleistungen und Softwarelizenzen. Auf diese Weise können wir weiter wachsen, programmieren und unsere Community unterstützen. Die kurze Antwort lautet also "Leben und leben lassen" - so denken wir über PLANKA.
|
||||
|
||||
Daher helfen wir dabei, [fair-code](https://faircode.io)-Software zu fördern, mit dem Ziel, sie zu einem bekannten Sammelbegriff zu machen, um Softwaremodelle wie Unseres zu beschreiben. Um jegliche Reibung um unsere proprietäre Lizenz auf ein absolutes Minimum zu beschränken, konzentrieren wir uns auf zwei Dinge:
|
||||
Daher helfen wir dabei, [fair-code](https://faircode.io)-Software zu fördern, mit dem Ziel, sie zu einem bekannten Sammelbegriff zu machen, um Softwaremodelle wie unseres zu beschreiben. Um jegliche Reibung um unsere proprietäre Lizenz auf ein absolutes Minimum zu beschränken, konzentrieren wir uns auf zwei Dinge:
|
||||
|
||||
1. Klare Sprache und minimale Länge - die Lizenz ist in klarem, präzisem Englisch bzw Deutsch geschrieben, mit nur den unbedingt notwendigen Klauseln.
|
||||
1. Klare Sprache und minimale Länge - die Lizenz ist in klarem, präzisem Deutsch (eine englische Version existiert ebenfalls) geschrieben, mit nur den unbedingt notwendigen Klauseln.
|
||||
|
||||
2. Förderung von fair-code - wir fördern aktiv das fair-code-Modell, damit die Menschen es als unkomplizierte, nachhaltige Möglichkeit erkennen, Software wie PLANKA zu teilen und zu verbessern.
|
||||
|
||||
@@ -158,7 +188,7 @@ Es ist einfach, mit den Code-Beiträgen zu PLANKA auf [GitHub](https://github.co
|
||||
|
||||
### Ist PLANKA Open Source?
|
||||
|
||||
PLANKAs Quellcode ist unter unserer "Fair Use Lizenz" frei verfügbar. Während dies nicht mit der strengen Definition der Open Source Initiative übereinstimmt (die keine Nutzungsbeschränkungen erlaubt), bietet PLANKA den meisten Benutzern, einschließlich Unternehmen, dennoch fast die selben Vorteile wie traditionelle Open-Source-Software.
|
||||
PLANKAs Quellcode ist unter der "Fair Use Lizenz" frei verfügbar. Während dies nicht mit der strengen Definition der Open Source Initiative übereinstimmt (die keine Nutzungsbeschränkungen erlaubt), bietet PLANKA den meisten Benutzern, einschließlich Unternehmen, dennoch fast die gleichen Vorteile wie traditionelle Open-Source-Software.
|
||||
|
||||
Wir befürworten, was oft als 'fair-code'-Modell bezeichnet wird - unser Code ist quelloffen und folgt einer einfachen "Leben und leben lassen"-Philosophie. Dieser Ansatz ermöglicht es uns, ein nachhaltiges Unternehmen zu führen und gleichzeitig Transparenz und Flexibilität für unsere Community zu bieten. Viele Unternehmen übernehmen diesen ausgewogenen Lizenzierungsansatz, der den Geist der Offenheit bewahrt und gleichzeitig die langfristige Lebensfähigkeit des Projekts sicherstellt. Wir sind stolz darauf, Teil dieser Bewegung zu sein!
|
||||
|
||||
@@ -174,8 +204,8 @@ Fair-code ist keine Softwarelizenz. Es beschreibt ein Softwaremodell, bei dem So
|
||||
|
||||
- Von ihren Autoren kommerziell eingeschränkt wird.
|
||||
|
||||
Unsere "Fair Use Lizenz" ist eine fair-code-Lizenz. Sie können mehr darüber lesen und andere Beispiele für fair-code-Lizenzen [hier](https://faircode.io) sehen. Um mit uns bzgl. Lizenzfragen in Verbindung zu treten, senden Sie bitte eine E-Mail an [license@planka.group](mailto:license@planka.group).
|
||||
Die "Fair Use Lizenz" ist eine fair-code-Lizenz. Sie können mehr darüber lesen und andere Beispiele für fair-code-Lizenzen [hier](https://faircode.io) sehen. Um mit uns bzgl. Lizenzfragen in Verbindung zu treten, senden Sie bitte eine E-Mail an [license@planka.group](mailto:license@planka.group).
|
||||
|
||||
### Kann ich diese Art der Lizenz für mein eigenes Projekt verwenden?
|
||||
### Kann ich die "Fair Use Lizenz" für mein eigenes Projekt verwenden?
|
||||
|
||||
Ja! Wir selbst haben die "Fair Use Lizenz" genutzt, indem wir den Fußstapfen anderer folgten, die auf ihrer Website und in ihrer Lizenz offen andere dazu einladen, dem fair-code-Pfad zu folgen. Und auch wir sind gespannt darauf, mehr Software zu sehen, die unsere "Fair Use Lizenz" verwendet.
|
||||
Ja! Wir selbst haben die "Fair Use Lizenz" genutzt, indem wir den Fußstapfen anderer folgten, die auf ihrer Website und in ihrer Lizenz offen andere dazu einladen, dem fair-code-Pfad zu folgen. Wie sie sind auch wir gespannt darauf, mehr Software zu sehen, die die "Fair Use Lizenz" verwendet.
|
||||
|
||||
@@ -1,64 +1,66 @@
|
||||
**PLANKA License Guide**
|
||||
|
||||
Version 1.0 - Last updated: May 2, 2025
|
||||
Version 1.1 - Last updated: May 20, 2025
|
||||
|
||||
Related files in English:
|
||||
|
||||
- [PLANKA Community License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md)
|
||||
- [PLANKA Enterprise License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md)
|
||||
- [PLANKA Commercial License EN.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md)
|
||||
- PLANKA License Guide EN.md (this file)
|
||||
|
||||
Related files in German:
|
||||
|
||||
- [PLANKA Community License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20DE.md)
|
||||
- [PLANKA Enterprise License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20DE.md)
|
||||
- [PLANKA Commercial License DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20DE.md)
|
||||
- [PLANKA License Guide DE.md](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20License%20Guide%20DE.md)
|
||||
|
||||
---
|
||||
|
||||
## PLANKA's "Fair Use License" and the "PLANKA Enterprise License"
|
||||
## PLANKA's "Fair Use License" and the "PLANKA Pro/Enterprise License"
|
||||
|
||||
Our [Fair Use License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md) and our [PLANKA Enterprise License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md) are based on the [fair-code](http://faircode.io) model.
|
||||
Our [Fair Use License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md) and our [PLANKA Pro/Enterprise License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md) are based on the [fair-code](http://faircode.io) model.
|
||||
|
||||
#### Proprietary licenses for enterprise and the "PLANKA Educational License"
|
||||
### Special licensing for educational & non-profit organizations
|
||||
|
||||
We offer proprietary licenses to our enterprise customers, but also the "PLANKA Educational License" for schools and universities. Please contact us for detailed information at [license@planka.group](mailto:license@planka.group).
|
||||
Educational institutions and non-profit organizations requiring commercial-level features or usage beyond our "Fair Use License" are encouraged to contact us for tailored licensing solutions and educational pricing. We look forward to helping your organization accomplish its mission!
|
||||
|
||||
# License FAQs
|
||||
|
||||
### What license do you use for PLANKA?
|
||||
|
||||
PLANKA uses the [Fair Use License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md) and the [PLANKA Enterprise License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md). These licenses are based on the [fair-code](http://faircode.io) model.
|
||||
PLANKA uses the [Fair Use License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md) and the [PLANKA Pro/Enterprise License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md). These licenses are based on the [fair-code](http://faircode.io) model.
|
||||
|
||||
### What source code is covered by the PLANKA's "Fair Use License"?
|
||||
|
||||
The [Fair Use License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md) applies to our source code hosted in our [main GitHub repository](https://github.com/plankanban/planka) except:
|
||||
|
||||
* Content of branches other than the main branch (usually "master" or "main").
|
||||
- Content of branches other than the main branch (usually "master" or "main").
|
||||
|
||||
* Source code files or other files that contain ".pe." (for "PLANKA Enterprise") in their file names or folder names.
|
||||
- Source code files or other files that contain ".pe." (for "PLANKA Pro/Enterprise") in their file names or folder names.
|
||||
|
||||
* Source code files that are marked as "PLANKA Enterprise" in their file headers or folders.
|
||||
- Source code files that are marked as "PLANKA Pro/Enterprise" in their file headers or folders.
|
||||
|
||||
* Source code in folders that contain separate license files that clearly mark them as "PLANKA Enterprise".
|
||||
- Source code in folders that contain separate license files that clearly mark them as "PLANKA Pro/Enterprise".
|
||||
|
||||
These exceptions are licensed under the [PLANKA Enterprise License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md).
|
||||
These exceptions are licensed under the [PLANKA Pro/Enterprise License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md).
|
||||
|
||||
### What is the "Fair Use License"?
|
||||
|
||||
The "Fair Use License" falls under the so-called [fair-code](http://faircode.io) licenses category. PLANKA's license is based on and extends the "Sustainable Use License" introduced by [n8n](https://n8n.io) who's advice was greatly appreciated. With similar goals in mind, we decided to follow their lead and adopt their model for our own needs. [Further below](#why-did-you-choose-this-license) you can read why we chose this license.
|
||||
|
||||
The license allows you the free right to use, modify, create derivative works, and redistribute with three limitations:
|
||||
The license allows you the free right to use, modify, create derivative works, and redistribute under the following conditions:
|
||||
|
||||
- You may use or modify the software (a) for personal, hobby, or educational purposes, or (b) inside your own legal entity (including wholly owned subsidiaries) for workflows that are not offered as a paid product or as a cross-company service to any third party.
|
||||
- You may use or modify PLANKA (a) for personal, hobby, or educational purposes, (b) internally within your own organization, (c) for private hosting for a typical number of friends, family, or personal projects, (d) to provide free access to non-profit organizations (as recognized by applicable tax authorities), or if you are a recognized non-profit organization yourself involving external users into your mission, and (e) public educational institutions for academic/research purposes only.
|
||||
|
||||
- You may not alter, remove, or obscure any licensing, copyright, or other notices of the licensor in the software. Any use of the licensor's trademarks is subject to applicable law.
|
||||
- Sharing accounts/credentials with third parties for business purposes or operating PLANKA as a hosted service for third parties for any commercial gain whatsoever is prohibited. Commercial gain includes any form of payment, advertising revenue, data monetization, or indirect commercial benefit or business advantage.
|
||||
|
||||
- "You may use the PLANKA name or logo to factually describe that your service incorporates or in other ways uses PLANKA software. Any other trademark use (e.g., in product names or brands, domain names, or marketing material) requires our prior written consent."
|
||||
- You may not alter, remove, or obscure any licensing, copyright, or other notices from the software provided by the licensor. Any use of the licensor's trademarks is subject to applicable law.
|
||||
|
||||
### What is and is NOT allowed under the license in the context of PLANKA's products?
|
||||
|
||||
Our license restricts use to "internal business purposes". In practice this means all use is allowed unless you are selling a product, service, or module in which the value derives entirely or substantially from PLANKA functionality.
|
||||
Our license allows use for "internal business purposes", as well as for personal, hobby, educational, and limited private hosting scenarios. However, it prohibits using PLANKA for any form of commercial gain, such as selling a product or service where the value derives in any form from PLANKA's functionality, operating it as a paid hosted service, monetizing access or user data, or deriving other indirect commercial benefits.
|
||||
|
||||
###### Here are some examples that would not be allowed:
|
||||
##### Here are some examples that would not be allowed:
|
||||
|
||||
- White-labeling PLANKA and offering it to your customers or affiliates for money.
|
||||
|
||||
@@ -66,25 +68,25 @@ Our license restricts use to "internal business purposes". In practice this mean
|
||||
|
||||
- Use PLANKA's API to power services for which money is charged.
|
||||
|
||||
- Use of PLANKA to connect your own legal entity with legal entities or persons outside your own legal entity.
|
||||
- Use of PLANKA to connect your own legal entity with legal entities or persons outside your organization in the context of a commercial relationship.
|
||||
|
||||
- Use PLANKA to conduct or support any kind of illegal or unlawful activity.
|
||||
|
||||
###### All of the following examples are allowed under our license:
|
||||
##### All of the following examples are allowed under our license:
|
||||
|
||||
- Using PLANKA to control your internal processes and manage your internal projects.
|
||||
|
||||
- Integrate PLANKA into other internally used products to enhance their capabilities.
|
||||
|
||||
- Providing consulting or educational services related to PLANKA, for example, to build or integrate workflows for or in connection with PLANKA or develop custom modules to extend its functionalities.
|
||||
- Providing consulting or public educational services related to PLANKA, for example, to build or integrate workflows for or in connection with PLANKA or develop custom modules to extend its functionalities.
|
||||
|
||||
- Supporting PLANKA, for example, by setting it up or maintaining it on an internal company server.
|
||||
|
||||
### Is it allowed to use PLANKA as a backend integration?
|
||||
|
||||
If you use PLANKA and its backend and related services outside the boundaries of internal operations and integrations within your own organization, you need to buy a "PLANKA Enterprise License". This also applies if you want to use PLANKA as a core backend infrastructure for third-party applications, services, or a system that is distributed to or accessed by external parties.
|
||||
If you use PLANKA and its backend services beyond internal operations within your own organization by enabling third-party access for commercial gain, such as sharing accounts with clients or selling a product or service where the value derives in any form from PLANKA's functionality, operating it as a paid hosted service, monetizing access or user data, or deriving other indirect commercial benefits, you are required to purchase a "PLANKA Pro/Enterprise License".
|
||||
|
||||
Any arrangement that involves sublicensing, repackaging, or otherwise making PLANKA available to external parties or integrating PLANKA into another product to serve as the primary operational engine for that product also requires a valid "PLANKA Enterprise License" or proprietary license available for our enterprise customers.
|
||||
This includes scenarios where PLANKA serves as core infrastructure for third-party solutions, is accessed by users outside your legal entity as part of a paid or commercial offering, or where you sublicense, repackage, or otherwise make PLANKA available to external parties. Any arrangement that involves integrating PLANKA into another product to serve as the primary operational engine for that product also requires a valid "PLANKA Pro/Enterprise License" or proprietary license available for our enterprise customers.
|
||||
|
||||
### Can you give me some quick examples to clarify free use vs. enterprise use?
|
||||
|
||||
@@ -112,9 +114,9 @@ A school or charity bundles PLANKA in a free, public Docker image for students w
|
||||
|
||||
##### Example 4: Provide PLANKA logins to clients and affiliates
|
||||
|
||||
To facilitate better project feedback, you offer your client and someone from a joint venture access to project boards inside your company. They can now comment on cards and also benefit from PLANKA's real-time update capabilities.
|
||||
To facilitate better project feedback, you offer your client and someone from a joint venture, both of whom you have a commercial relationship with, access to project boards inside your company. They can now comment on cards and also benefit from PLANKA's real-time update capabilities.
|
||||
|
||||
**NOT ALLOWED** under the "Fair Use License". Offering PLANKA as part of a paid service to third parties or providing PLANKA access to third-party users outside your own legal entity requires you to register a "PLANKA Enterprise License".
|
||||
**NOT ALLOWED** under the "Fair Use License". Offering PLANKA as part of a paid service to third parties or providing PLANKA access to third-party users outside your own legal entity in the context of a commercial relationship requires you to register a "PLANKA Pro/Enterprise License".
|
||||
|
||||
##### Example 5: Offer PLANKA as a hosted product to other companies
|
||||
|
||||
@@ -124,19 +126,47 @@ You want to earn money by providing PLANKA to companies, freelancers, and other
|
||||
|
||||
---
|
||||
|
||||
### Quick "Fair Use License" summary
|
||||
|
||||
- Personal, educational, hobby, or internal business use:
|
||||
|
||||
Free to use. You can use, modify, and host PLANKA for yourself, your team, or your organization for personal, educational, or internal operational purposes.
|
||||
|
||||
- Use by non-profits and public educational institutions:
|
||||
|
||||
Free to use for academic or research purposes, provided the organization qualifies as a non-profit under applicable tax laws. No application or special license is required.
|
||||
|
||||
- Providing access to third parties for any commercial gain:
|
||||
|
||||
Not allowed. Sharing accounts or credentials with third parties for any commercial gain is prohibited under the license, even if you are not directly charging for access.
|
||||
|
||||
- Hosting PLANKA as a commercial service:
|
||||
|
||||
Not allowed. You may not offer PLANKA as a hosted service or integrate it into a paid product or service where the value substantially comes from PLANKA. This includes advertising revenue, data monetization, or indirect commercial benefit or business advantage.
|
||||
|
||||
### What if I want to use PLANKA for something that's not permitted by the license?
|
||||
|
||||
You must sign a separate commercial agreement with us. We actively encourage software integrators and technical staff to integrate and connect PLANKA within their other products and use our extensive API to respond to, control, and master processes within their company; we just ask them to sign an agreement laying out the terms of use and the license fees required by PLANKA for using the product. Through PLANKA's API, it is capable of controlling and responding to external systems. You can learn more [here](https://docs.planka.cloud/docs/category/api-reference) or contact us about it.
|
||||
To exceed the limits of the self-hosted Community version, you'll need a "PLANKA Pro/Enterprise License". Once you register with us, the "Fair Use License" restrictions are not only legally lifted, but you also gain access to the full enterprise feature set.
|
||||
|
||||
Alternatively, you can exceed these limits by subscribing to a hosted version - either Community or Pro/Enterprise. This allows, for example, providing accounts for your customers.
|
||||
|
||||
If you want to provide PLANKA as a service for other organizations or integrate PLANKA into your own software, you must sign a separate revenue agreement with us. We actively encourage software integrators and technical staff to integrate and connect PLANKA within their other products and use our extensive API to respond to, control, and master processes within their company; we just ask them to sign an agreement laying out the terms of use and the license fees required by PLANKA for using the product. Through PLANKA's API, it is capable of controlling and responding to external systems. You can learn more [here](https://docs.planka.cloud/docs/category/api-reference/) or contact us about it.
|
||||
|
||||
If you are unsure whether the use case you have in mind constitutes an internal business purpose or not, take a look at the [examples above](#can-you-give-me-some-quick-examples-to-clarify-free-use-vs-enterprise-use), and if you're still not sure, please contact us at [license@planka.group](mailto:license@planka.group).
|
||||
|
||||
### Why don't you use a default open-source license?
|
||||
### Why isn't there a commercial license for a self-hosted Community version which lifts the "Fair Use License" limits?
|
||||
|
||||
We support the self-hosted Community version through our GitHub and Discord community channels, but we can't efficiently provide direct phone or email support for multiple versions while meeting our obligations to paying customers. That's why direct support is reserved exclusively for Pro/Enterprise customers.
|
||||
|
||||
However, we do offer professional installation services and monthly-based service contracts for setting up, updating, and monitoring all versions to help organizations get the most out of their PLANKA deployment - please contact us at [license@planka.group](mailto:license@planka.group).
|
||||
|
||||
### Why doesn't PLANKA use a default open-source license?
|
||||
|
||||
We spend a lot of time creating an easy yet powerful tool that makes controlling and mastering projects a fun experience. Also, we wanted PLANKA to be as widely and freely available as possible while also ensuring that we can build a sustainable and viable business. By making our product free to use, easy to distribute, and source-available, we help everyone access the product. By operating as a business, we can develop and release new features, fix bugs, and provide reliable software at scale long-term.
|
||||
|
||||
### Why did you choose this license?
|
||||
|
||||
We believe that the "Fair Use License" is beneficial for the community as well as for the developers. Development is a costly enterprise, and giving away a community version for free is a risk that many companies don't survive without selling software or the company. Therefore, many open-source companies live from donations or financial investors. Instead of selling our soul, we sell services and software licenses. This way we continue to grow, code, and support our community. So the short answer is "Live and let live" is how we feel about PLANKA.
|
||||
We believe that the "Fair Use License" is beneficial for the community as well as for the developers. Development is a costly enterprise, and giving away a Community version for free is a risk that many companies don't survive without selling software or the company. Therefore, many open-source companies live from donations or financial investors. Instead of selling our soul, we sell services and software licenses. This way we continue to grow, code, and support our community. So the short answer is "Live and let live" is how we feel about PLANKA.
|
||||
|
||||
Therefore, we are helping to promote [fair-code](https://faircode.io) software with the goal of making it a well-known umbrella term to describe software models like ours. To keep any friction around our proprietary license to an absolute minimum, we focus on two things:
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
**Project mastering driven by fun**
|
||||
|
||||
 [](https://github.com/plankanban/planka/pkgs/container/planka) [](https://github.com/plankanban/planka/graphs/contributors) [](https://discord.gg/WqqYNd7Jvt)
|
||||
 [](https://github.com/plankanban/planka/pkgs/container/planka) [](https://github.com/plankanban/planka/graphs/contributors) [](https://discord.gg/WqqYNd7Jvt)
|
||||
|
||||

|
||||
|
||||
@@ -37,7 +37,7 @@ For any security issues, please do not create a public issue on GitHub - instead
|
||||
|
||||
## License
|
||||
|
||||
PLANKA is [fair-code](https://faircode.io) distributed under the [Fair Use License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md) and [PLANKA Enterprise License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Enterprise%20License%20EN.md).
|
||||
PLANKA is [fair-code](https://faircode.io) distributed under the [Fair Use License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Community%20License%20EN.md) and [PLANKA Pro/Enterprise License](https://github.com/plankanban/planka/blob/master/LICENSES/PLANKA%20Commercial%20License%20EN.md).
|
||||
|
||||
- **Source Available**: The source code is always visible
|
||||
- **Self-Hostable**: Deploy and host it anywhere
|
||||
|
||||
@@ -15,13 +15,13 @@ type: application
|
||||
# This is the chart version. This version number should be incremented each time you make changes
|
||||
# to the chart and its templates, including the app version.
|
||||
# Versions are expected to follow Semantic Versioning (https://semver.org/)
|
||||
version: 1.0.1
|
||||
version: 1.1.1
|
||||
|
||||
# This is the version number of the application being deployed. This version number should be
|
||||
# incremented each time you make changes to the application. Versions are not expected to
|
||||
# follow Semantic Versioning. They should reflect the version the application is using.
|
||||
# It is recommended to use it with quotes.
|
||||
appVersion: "2.0.0-rc.2"
|
||||
appVersion: "2.0.0-rc.4"
|
||||
|
||||
dependencies:
|
||||
- alias: postgresql
|
||||
|
||||
@@ -109,3 +109,122 @@ If you want to host PLANKA for more than just playing around with, you might wan
|
||||
- Specify a password for `postgresql.auth.password` as there have been issues with the postgresql chart generating new passwords locking you out of the data you've already stored. (see [this issue](https://github.com/bitnami/charts/issues/2061))
|
||||
|
||||
Any questions or concerns, [raise an issue](https://github.com/Chris-Greaves/planka-helm-chart/issues/new).
|
||||
|
||||
## Advanced Configuration
|
||||
|
||||
### Extra Volume Mounts
|
||||
|
||||
The Helm chart supports mounting arbitrary ConfigMaps, Secrets, and Volumes to the PLANKA deployment using the `extraMounts` configuration. This is especially useful for scenarios like:
|
||||
|
||||
- Mounting custom CA certificates for OIDC with self-hosted identity providers
|
||||
- Adding custom configuration files
|
||||
- Mounting TLS certificates from existing secrets
|
||||
- Adding temporary or persistent storage volumes
|
||||
|
||||
**Note**: ConfigMaps and Secrets must be created separately before referencing them in `extraMounts`.
|
||||
|
||||
#### Basic Usage
|
||||
|
||||
Use the `extraMounts` section to mount any type of volume:
|
||||
|
||||
```yaml
|
||||
extraMounts:
|
||||
# Mount CA certificate from existing ConfigMap
|
||||
- name: ca-certs
|
||||
mountPath: /etc/ssl/certs/custom-ca.crt
|
||||
subPath: ca.crt
|
||||
readOnly: true
|
||||
configMap:
|
||||
name: ca-certificates # Must exist
|
||||
|
||||
# Mount TLS certificates from existing Secret
|
||||
- name: tls-certs
|
||||
mountPath: /etc/ssl/private
|
||||
readOnly: true
|
||||
secret:
|
||||
secretName: planka-tls-secret # Must exist
|
||||
items:
|
||||
- key: tls.crt
|
||||
path: server.crt
|
||||
- key: tls.key
|
||||
path: server.key
|
||||
|
||||
# Temporary storage
|
||||
- name: temp-storage
|
||||
mountPath: /tmp/planka-temp
|
||||
readOnly: false
|
||||
emptyDir:
|
||||
sizeLimit: 1Gi
|
||||
|
||||
# Host path mount
|
||||
- name: backup-storage
|
||||
mountPath: /var/lib/planka-backups
|
||||
readOnly: false
|
||||
hostPath:
|
||||
path: /var/lib/planka-backups
|
||||
type: DirectoryOrCreate
|
||||
|
||||
# NFS mount
|
||||
- name: nfs-storage
|
||||
mountPath: /shared/data
|
||||
readOnly: false
|
||||
nfs:
|
||||
server: nfs.example.com
|
||||
path: /exports/planka
|
||||
```
|
||||
|
||||
### OIDC with Self-Hosted Keycloak
|
||||
|
||||
A common use case is configuring OIDC with a self-hosted Keycloak instance that uses custom CA certificates.
|
||||
|
||||
First, create the CA certificate ConfigMap:
|
||||
```bash
|
||||
kubectl create configmap ca-certificates --from-file=ca.crt=/path/to/your/ca.crt
|
||||
```
|
||||
|
||||
Then configure the chart:
|
||||
```yaml
|
||||
# Mount custom CA certificate from existing ConfigMap
|
||||
extraMounts:
|
||||
- name: keycloak-ca
|
||||
mountPath: /etc/ssl/certs/keycloak-ca.crt
|
||||
subPath: ca.crt
|
||||
readOnly: true
|
||||
configMap:
|
||||
name: ca-certificates
|
||||
|
||||
# Configure Node.js to trust the custom CA
|
||||
extraEnv:
|
||||
- name: NODE_EXTRA_CA_CERTS
|
||||
value: "/etc/ssl/certs/keycloak-ca.crt"
|
||||
|
||||
# Enable OIDC
|
||||
oidc:
|
||||
enabled: true
|
||||
clientId: "planka-client"
|
||||
clientSecret: "your-client-secret"
|
||||
issuerUrl: "https://keycloak.example.com/realms/master"
|
||||
admin:
|
||||
roles:
|
||||
- "planka-admin"
|
||||
```
|
||||
|
||||
### Environment Variables from Secrets
|
||||
|
||||
You can reference values from existing secrets in environment variables:
|
||||
|
||||
```yaml
|
||||
extraEnv:
|
||||
- name: SMTP_PASSWORD
|
||||
valueFrom:
|
||||
secretName: smtp-credentials
|
||||
key: password
|
||||
- name: CUSTOM_API_KEY
|
||||
valueFrom:
|
||||
secretName: api-credentials
|
||||
key: api-key
|
||||
```
|
||||
|
||||
### Complete Example
|
||||
|
||||
See `values-example.yaml` for a comprehensive example that demonstrates all the advanced features including OIDC configuration with custom CA certificates.
|
||||
|
||||
@@ -4,6 +4,10 @@ metadata:
|
||||
name: {{ include "planka.fullname" . }}
|
||||
labels:
|
||||
{{- include "planka.labels" . | nindent 4 }}
|
||||
{{- with .Values.deploymentAnnotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if not .Values.autoscaling.enabled }}
|
||||
replicas: {{ .Values.replicaCount }}
|
||||
@@ -67,6 +71,19 @@ spec:
|
||||
subPath: app-logs
|
||||
name: emptydir
|
||||
{{- end }}
|
||||
{{- /* Extra volume mounts */}}
|
||||
{{- range .Values.extraMounts }}
|
||||
- name: {{ .name }}
|
||||
mountPath: {{ .mountPath }}
|
||||
{{- if .subPath }}
|
||||
subPath: {{ .subPath }}
|
||||
{{- end }}
|
||||
{{- if hasKey . "readOnly" }}
|
||||
readOnly: {{ .readOnly }}
|
||||
{{- else }}
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
resources:
|
||||
{{- toYaml .Values.resources | nindent 12 }}
|
||||
env:
|
||||
@@ -196,4 +213,31 @@ spec:
|
||||
{{- if .Values.securityContext.readOnlyRootFilesystem }}
|
||||
- name: emptydir
|
||||
emptyDir: {}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- /* Extra volumes */}}
|
||||
{{- range .Values.extraMounts }}
|
||||
- name: {{ .name }}
|
||||
{{- if .configMap }}
|
||||
configMap:
|
||||
{{- toYaml .configMap | nindent 12 }}
|
||||
{{- else if .secret }}
|
||||
secret:
|
||||
{{- toYaml .secret | nindent 12 }}
|
||||
{{- else if .emptyDir }}
|
||||
emptyDir:
|
||||
{{- toYaml .emptyDir | nindent 12 }}
|
||||
{{- else if .hostPath }}
|
||||
hostPath:
|
||||
{{- toYaml .hostPath | nindent 12 }}
|
||||
{{- else if .persistentVolumeClaim }}
|
||||
persistentVolumeClaim:
|
||||
{{- toYaml .persistentVolumeClaim | nindent 12 }}
|
||||
{{- else if .nfs }}
|
||||
nfs:
|
||||
{{- toYaml .nfs | nindent 12 }}
|
||||
{{- else }}
|
||||
{{- /* Support any other volume type by removing known mount-specific keys */}}
|
||||
{{- $volume := omit . "name" "mountPath" "subPath" "readOnly" }}
|
||||
{{- toYaml $volume | nindent 10 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
@@ -18,6 +18,9 @@ metadata:
|
||||
name: {{ $fullName }}
|
||||
labels:
|
||||
{{- include "planka.labels" . | nindent 4 }}
|
||||
{{- with .Values.ingress.labels }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.ingress.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
|
||||
@@ -27,6 +27,11 @@ existingSecretkeySecret: ""
|
||||
## NOTE: When it's set, the `admin_username` and `admin_password` parameters are ignored
|
||||
existingAdminCredsSecret: ""
|
||||
|
||||
admin_email: ""
|
||||
admin_password: ""
|
||||
admin_name: ""
|
||||
admin_username: ""
|
||||
|
||||
# Base url for PLANKA. Will override `ingress.hosts[0].host`
|
||||
# Defaults to `http://localhost:3000` if ingress is disabled.
|
||||
baseUrl: ""
|
||||
@@ -45,6 +50,9 @@ podAnnotations: {}
|
||||
podSecurityContext: {}
|
||||
# fsGroup: 2000
|
||||
|
||||
# Annotations to add to the deployment
|
||||
deploymentAnnotations: {}
|
||||
|
||||
securityContext: {}
|
||||
# capabilities:
|
||||
# drop:
|
||||
@@ -65,6 +73,7 @@ service:
|
||||
ingress:
|
||||
enabled: false
|
||||
className: ""
|
||||
labels: {}
|
||||
annotations: {}
|
||||
# kubernetes.io/ingress.class: nginx
|
||||
# kubernetes.io/tls-acme: "true"
|
||||
@@ -105,6 +114,11 @@ tolerations: []
|
||||
affinity: {}
|
||||
|
||||
postgresql:
|
||||
global:
|
||||
security:
|
||||
allowInsecureImages: true
|
||||
image:
|
||||
repository: bitnamilegacy/postgresql
|
||||
enabled: true
|
||||
auth:
|
||||
database: planka
|
||||
@@ -210,3 +224,65 @@ oidc:
|
||||
## key: key-inside-the-secret
|
||||
##
|
||||
extraEnv: []
|
||||
|
||||
## Example extraEnv for configuring SMTP
|
||||
## extraEnv:
|
||||
## - name: SMTP_HOST
|
||||
## value: "smtp.example.com"
|
||||
## - name: SMTP_PORT
|
||||
## value: "587"
|
||||
## - name: SMTP_NAME
|
||||
## value: "Your Name"
|
||||
## - name: SMTP_SECURE
|
||||
## value: "true"
|
||||
## - name: SMTP_TLS_REJECT_UNAUTHORIZED
|
||||
## value: "false"
|
||||
## - name: SMTP_USER
|
||||
## value: "your_email@example.com"
|
||||
## - name: SMTP_PASSWORD
|
||||
## value: "your_password"
|
||||
## - name: SMTP_FROM
|
||||
## value: "your_email@example.com"
|
||||
|
||||
## Extra volume mounts configuration
|
||||
## Mount ConfigMaps, Secrets, and arbitrary volumes to the PLANKA container
|
||||
## This allows mounting any pre-existing ConfigMaps, Secrets, or other volume types
|
||||
##
|
||||
extraMounts: []
|
||||
## Example extraMounts:
|
||||
## extraMounts:
|
||||
## - name: ca-certs
|
||||
## mountPath: /etc/ssl/certs/ca-certificates.crt
|
||||
## subPath: ca-bundle.crt
|
||||
## readOnly: true
|
||||
## configMap:
|
||||
## name: ca-certificates
|
||||
## - name: tls-certs
|
||||
## mountPath: /etc/ssl/private
|
||||
## readOnly: true
|
||||
## secret:
|
||||
## secretName: planka-tls
|
||||
## items:
|
||||
## - key: tls.crt
|
||||
## path: server.crt
|
||||
## - key: tls.key
|
||||
## path: server.key
|
||||
## - name: temp-storage
|
||||
## mountPath: /tmp/planka-temp
|
||||
## readOnly: false
|
||||
## emptyDir:
|
||||
## sizeLimit: 1Gi
|
||||
|
||||
## Example configuration for OIDC with self-hosted Keycloak using custom CA
|
||||
## (Requires pre-existing ConfigMap "ca-certificates")
|
||||
## extraMounts:
|
||||
## - name: keycloak-ca
|
||||
## mountPath: /etc/ssl/certs/keycloak-ca.crt
|
||||
## subPath: ca.crt
|
||||
## readOnly: true
|
||||
## configMap:
|
||||
## name: ca-certificates
|
||||
##
|
||||
## extraEnv:
|
||||
## - name: NODE_EXTRA_CA_CERTS
|
||||
## value: "/etc/ssl/certs/keycloak-ca.crt"
|
||||
|
||||
5269
client/package-lock.json
generated
5269
client/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
63
client/package.json
Executable file → Normal file
63
client/package.json
Executable file → Normal file
@@ -79,12 +79,13 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@ballerina/highlightjs-ballerina": "^1.0.1",
|
||||
"@diplodoc/cut-extension": "^0.7.3",
|
||||
"@diplodoc/transform": "^4.57.2",
|
||||
"@gravity-ui/markdown-editor": "^15.11.0",
|
||||
"@gravity-ui/uikit": "^7.11.0",
|
||||
"@diplodoc/cut-extension": "^0.7.4",
|
||||
"@diplodoc/transform": "^4.64.1",
|
||||
"@gravity-ui/components": "^4.16.0",
|
||||
"@gravity-ui/markdown-editor": "^15.25.0",
|
||||
"@gravity-ui/uikit": "^7.26.1",
|
||||
"@juggle/resize-observer": "^3.4.0",
|
||||
"@vitejs/plugin-react": "^4.4.1",
|
||||
"@vitejs/plugin-react": "^4.7.0",
|
||||
"browserslist-to-esbuild": "^2.1.1",
|
||||
"classnames": "^2.5.1",
|
||||
"date-fns": "^2.30.0",
|
||||
@@ -95,7 +96,7 @@
|
||||
"highlightjs-apex": "^1.5.0",
|
||||
"highlightjs-blade": "^0.1.0",
|
||||
"highlightjs-cobol": "^0.3.3",
|
||||
"highlightjs-cshtml-razor": "^2.1.1",
|
||||
"highlightjs-cshtml-razor": "^2.2.0",
|
||||
"highlightjs-gf": "^1.0.1",
|
||||
"highlightjs-jolie": "^0.1.8",
|
||||
"highlightjs-lean": "^1.2.0",
|
||||
@@ -113,19 +114,20 @@
|
||||
"highlightjs-zenscript": "^2.0.0",
|
||||
"hightlightjs-papyrus": "^0.0.4",
|
||||
"history": "^5.3.0",
|
||||
"i18next": "^23.16.8",
|
||||
"i18next-browser-languagedetector": "^8.1.0",
|
||||
"i18next": "^25.6.3",
|
||||
"i18next-browser-languagedetector": "^8.2.0",
|
||||
"initials": "^3.1.2",
|
||||
"javascript-time-ago": "^2.5.11",
|
||||
"javascript-time-ago": "^2.5.12",
|
||||
"js-cookie": "^3.0.5",
|
||||
"jwt-decode": "^4.0.0",
|
||||
"linkify-react": "^4.3.1",
|
||||
"linkifyjs": "^4.3.1",
|
||||
"linkify-react": "^4.3.2",
|
||||
"linkifyjs": "^4.3.2",
|
||||
"lodash": "^4.17.21",
|
||||
"lowlight": "^3.3.0",
|
||||
"markdown-it": "^13.0.2",
|
||||
"nanoid": "^5.1.5",
|
||||
"patch-package": "^8.0.0",
|
||||
"nanoid": "^5.1.6",
|
||||
"papaparse": "^5.5.3",
|
||||
"patch-package": "^8.0.1",
|
||||
"photoswipe": "^5.4.4",
|
||||
"prop-types": "^15.8.1",
|
||||
"react": "18.2.0",
|
||||
@@ -134,49 +136,50 @@
|
||||
"react-dom": "18.2.0",
|
||||
"react-dropzone": "^14.3.8",
|
||||
"react-frame-component": "^5.2.7",
|
||||
"react-hot-toast": "^2.5.2",
|
||||
"react-i18next": "^15.5.1",
|
||||
"react-hot-toast": "^2.6.0",
|
||||
"react-i18next": "^15.7.4",
|
||||
"react-input-mask": "^2.0.4",
|
||||
"react-intersection-observer": "^9.16.0",
|
||||
"react-mentions": "^4.4.10",
|
||||
"react-photoswipe-gallery": "^2.2.7",
|
||||
"react-redux": "^8.1.3",
|
||||
"react-router-dom": "^6.30.0",
|
||||
"react-router-dom": "^6.30.2",
|
||||
"react-textarea-autosize": "^8.5.9",
|
||||
"react-time-ago": "^7.3.3",
|
||||
"react-time-ago": "^7.3.5",
|
||||
"redux": "^4.2.1",
|
||||
"redux-logger": "^3.0.6",
|
||||
"redux-orm": "^0.16.2",
|
||||
"redux-saga": "^1.3.0",
|
||||
"redux-saga": "^1.4.2",
|
||||
"reselect": "^4.1.8",
|
||||
"sails.io.js": "^1.2.1",
|
||||
"sass-embedded": "^1.87.0",
|
||||
"sass-embedded": "^1.93.3",
|
||||
"semantic-ui-react": "^2.1.5",
|
||||
"socket.io-client": "^2.5.0",
|
||||
"validator": "^13.15.0",
|
||||
"vite": "^6.3.5",
|
||||
"validator": "^13.15.23",
|
||||
"vite": "^6.4.1",
|
||||
"vite-plugin-commonjs": "^0.10.4",
|
||||
"vite-plugin-node-polyfills": "^0.23.0",
|
||||
"vite-plugin-svgr": "^4.3.0",
|
||||
"vite-plugin-svgr": "^4.5.0",
|
||||
"zxcvbn": "^4.4.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/eslint-parser": "^7.27.1",
|
||||
"@babel/preset-env": "^7.27.2",
|
||||
"@cucumber/cucumber": "^11.2.0",
|
||||
"@babel/eslint-parser": "^7.28.5",
|
||||
"@babel/preset-env": "^7.28.5",
|
||||
"@cucumber/cucumber": "^11.3.0",
|
||||
"@cucumber/pretty-formatter": "^1.0.1",
|
||||
"@playwright/test": "^1.52.0",
|
||||
"@playwright/test": "^1.56.1",
|
||||
"babel-jest": "^29.7.0",
|
||||
"babel-preset-airbnb": "^5.0.0",
|
||||
"eslint": "^8.57.1",
|
||||
"eslint-config-airbnb": "^19.0.4",
|
||||
"eslint-config-prettier": "^9.1.0",
|
||||
"eslint-plugin-import": "^2.31.0",
|
||||
"eslint-config-prettier": "^9.1.2",
|
||||
"eslint-plugin-import": "^2.32.0",
|
||||
"eslint-plugin-jsx-a11y": "^6.10.2",
|
||||
"eslint-plugin-prettier": "^5.4.0",
|
||||
"eslint-plugin-prettier": "^5.5.4",
|
||||
"eslint-plugin-react": "^7.37.5",
|
||||
"eslint-plugin-react-hooks": "^4.6.2",
|
||||
"jest": "^29.7.0",
|
||||
"playwright": "^1.52.0",
|
||||
"playwright": "^1.56.1",
|
||||
"prettier": "3.3.3"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/node_modules/@gravity-ui/markdown-editor/build/esm/bundle/wysiwyg-preset.js b/node_modules/@gravity-ui/markdown-editor/build/esm/bundle/wysiwyg-preset.js
|
||||
index 2152fd6..ceda0c1 100644
|
||||
index 84c7781..3b2f51c 100644
|
||||
--- a/node_modules/@gravity-ui/markdown-editor/build/esm/bundle/wysiwyg-preset.js
|
||||
+++ b/node_modules/@gravity-ui/markdown-editor/build/esm/bundle/wysiwyg-preset.js
|
||||
@@ -101,7 +101,6 @@ export const BundlePreset = (builder, opts) => {
|
||||
@@ -10,10 +10,10 @@ index 2152fd6..ceda0c1 100644
|
||||
deflist: {
|
||||
deflistTermPlaceholder: () => i18nPlaceholder('deflist_term'),
|
||||
deflistDescPlaceholder: () => i18nPlaceholder('deflist_desc'),
|
||||
@@ -118,11 +117,6 @@ export const BundlePreset = (builder, opts) => {
|
||||
...opts.yfmNote,
|
||||
@@ -122,11 +121,6 @@ export const BundlePreset = (builder, opts) => {
|
||||
...opts.yfmTable,
|
||||
controls: opts.mobile ? false : opts.yfmTable?.controls,
|
||||
},
|
||||
yfmTable: { yfmTableCellPlaceholder: () => i18nPlaceholder('table_cell'), ...opts.yfmTable },
|
||||
- yfmFile: {
|
||||
- fileUploadHandler: opts.fileUploadHandler,
|
||||
- needToSetDimensionsForUploadedImages: opts.needToSetDimensionsForUploadedImages,
|
||||
@@ -22,14 +22,27 @@ index 2152fd6..ceda0c1 100644
|
||||
yfmHeading: {
|
||||
h1Key: f.toPM(A.Heading1),
|
||||
h2Key: f.toPM(A.Heading2),
|
||||
diff --git a/node_modules/@gravity-ui/markdown-editor/build/esm/extensions/yfm/YfmNote/YfmNoteSpecs/index.js b/node_modules/@gravity-ui/markdown-editor/build/esm/extensions/yfm/YfmNote/YfmNoteSpecs/index.js
|
||||
index 212c583..b709383 100644
|
||||
--- a/node_modules/@gravity-ui/markdown-editor/build/esm/extensions/yfm/YfmNote/YfmNoteSpecs/index.js
|
||||
+++ b/node_modules/@gravity-ui/markdown-editor/build/esm/extensions/yfm/YfmNote/YfmNoteSpecs/index.js
|
||||
@@ -10,7 +10,7 @@ export { noteType, noteTitleType } from "./utils.js";
|
||||
export const YfmNoteSpecs = (builder, opts) => {
|
||||
const schemaSpecs = getSchemaSpecs(opts, builder.context.get('placeholder'));
|
||||
builder
|
||||
- .configureMd((md) => md.use(yfmPlugin, { log, lang: getConfig().lang || 'en' }))
|
||||
+ .configureMd((md) => md.use(yfmPlugin, { log, lang: getConfig().lang || 'en', notesAutotitle: false }))
|
||||
.addNode(NoteNode.Note, () => ({
|
||||
spec: schemaSpecs[NoteNode.Note],
|
||||
toMd: serializerTokens[NoteNode.Note],
|
||||
diff --git a/node_modules/@gravity-ui/markdown-editor/build/esm/presets/yfm.js b/node_modules/@gravity-ui/markdown-editor/build/esm/presets/yfm.js
|
||||
index ed2a9db..f95b693 100644
|
||||
index ed2a9db..77f6d08 100644
|
||||
--- a/node_modules/@gravity-ui/markdown-editor/build/esm/presets/yfm.js
|
||||
+++ b/node_modules/@gravity-ui/markdown-editor/build/esm/presets/yfm.js
|
||||
@@ -1,5 +1,5 @@
|
||||
import { Deflist, Subscript, Superscript, Underline, } from "../extensions/markdown/index.js";
|
||||
-import { Checkbox, ImgSize, Monospace, Video, YfmConfigs, YfmCut, YfmFile, YfmHeading, YfmNote, YfmTable, YfmTabs, } from "../extensions/yfm/index.js";
|
||||
+import { ImgSize, Monospace, Video, YfmConfigs, YfmCut, YfmHeading, YfmNote, YfmTable } from "../extensions/yfm/index.js";
|
||||
+import { ImgSize, Monospace, Video, YfmConfigs, YfmCut, YfmHeading, YfmNote, YfmTable, } from "../extensions/yfm/index.js";
|
||||
import { DefaultPreset } from "./default.js";
|
||||
export const YfmPreset = (builder, opts) => {
|
||||
builder.use(DefaultPreset, { ...opts, image: false, heading: false });
|
||||
24
client/patches/react-mentions+4.4.10.patch
Normal file
24
client/patches/react-mentions+4.4.10.patch
Normal file
@@ -0,0 +1,24 @@
|
||||
diff --git a/node_modules/react-mentions/dist/react-mentions.esm.js b/node_modules/react-mentions/dist/react-mentions.esm.js
|
||||
index 2efebba..b244446 100644
|
||||
--- a/node_modules/react-mentions/dist/react-mentions.esm.js
|
||||
+++ b/node_modules/react-mentions/dist/react-mentions.esm.js
|
||||
@@ -1426,7 +1426,7 @@ var MentionsInput = /*#__PURE__*/function (_React$Component) {
|
||||
|
||||
var mentions = getMentions(newValue, config);
|
||||
|
||||
- if (ev.nativeEvent.isComposing && selectionStart === selectionEnd) {
|
||||
+ if ((ev.nativeEvent.isComposing || newValue.length < value.length) && selectionStart === selectionEnd) {
|
||||
_this.updateMentionsQueries(_this.inputElement.value, selectionStart);
|
||||
} // Propagate change
|
||||
// let handleChange = this.getOnChange(this.props) || emptyFunction;
|
||||
@@ -1454,7 +1454,9 @@ var MentionsInput = /*#__PURE__*/function (_React$Component) {
|
||||
var el = _this.inputElement;
|
||||
|
||||
if (ev.target.selectionStart === ev.target.selectionEnd) {
|
||||
- _this.updateMentionsQueries(el.value, ev.target.selectionStart);
|
||||
+ requestAnimationFrame(function () {
|
||||
+ _this.updateMentionsQueries(el.value, ev.target.selectionStart);
|
||||
+ });
|
||||
} else {
|
||||
_this.clearSuggestions();
|
||||
} // sync highlighters scroll position
|
||||
13
client/patches/react-photoswipe-gallery+2.2.7.patch
Normal file
13
client/patches/react-photoswipe-gallery+2.2.7.patch
Normal file
@@ -0,0 +1,13 @@
|
||||
diff --git a/node_modules/react-photoswipe-gallery/dist/gallery.js b/node_modules/react-photoswipe-gallery/dist/gallery.js
|
||||
index 53cc02c..f4baccb 100644
|
||||
--- a/node_modules/react-photoswipe-gallery/dist/gallery.js
|
||||
+++ b/node_modules/react-photoswipe-gallery/dist/gallery.js
|
||||
@@ -181,7 +181,7 @@ export const Gallery = ({
|
||||
alt
|
||||
} = pswpInstance.currSlide.data;
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
- el.innerHTML = caption || alt || '';
|
||||
+ el.textContent = caption || alt || '';
|
||||
});
|
||||
}
|
||||
});
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/node_modules/semantic-ui-react/dist/es/lib/doesNodeContainClick.js b/node_modules/semantic-ui-react/dist/es/lib/doesNodeContainClick.js
|
||||
index 6d06078..fb7534d 100644
|
||||
index 6d06078..e22d4f0 100644
|
||||
--- a/node_modules/semantic-ui-react/dist/es/lib/doesNodeContainClick.js
|
||||
+++ b/node_modules/semantic-ui-react/dist/es/lib/doesNodeContainClick.js
|
||||
@@ -17,13 +17,7 @@ var doesNodeContainClick = function doesNodeContainClick(node, e) {
|
||||
@@ -17,6 +17,113 @@ index 6d06078..fb7534d 100644
|
||||
} // Below logic handles cases where the e.target is no longer in the document.
|
||||
// The result of the click likely has removed the e.target node.
|
||||
// Instead of node.contains(), we'll identify the click by X/Y position.
|
||||
diff --git a/node_modules/semantic-ui-react/dist/es/modules/Dropdown/Dropdown.js b/node_modules/semantic-ui-react/dist/es/modules/Dropdown/Dropdown.js
|
||||
index 1cc1bab..0e178ee 100644
|
||||
--- a/node_modules/semantic-ui-react/dist/es/modules/Dropdown/Dropdown.js
|
||||
+++ b/node_modules/semantic-ui-react/dist/es/modules/Dropdown/Dropdown.js
|
||||
@@ -342,7 +342,7 @@ var Dropdown = /*#__PURE__*/function (_Component) {
|
||||
return;
|
||||
}
|
||||
|
||||
- if (searchQuery.length >= minCharacters || minCharacters === 1) {
|
||||
+ if (searchQuery.length >= minCharacters || minCharacters === 0) {
|
||||
_this.open(e);
|
||||
|
||||
return;
|
||||
@@ -480,7 +480,7 @@ var Dropdown = /*#__PURE__*/function (_Component) {
|
||||
} // close search dropdown if search query is too small
|
||||
|
||||
|
||||
- if (open && minCharacters !== 1 && newQuery.length < minCharacters) _this.close();
|
||||
+ if (open && minCharacters !== 0 && newQuery.length < minCharacters) _this.close();
|
||||
};
|
||||
|
||||
_this.handleKeyDown = function (e) {
|
||||
@@ -1048,7 +1048,7 @@ var Dropdown = /*#__PURE__*/function (_Component) {
|
||||
|
||||
if (!prevState.focus && this.state.focus) {
|
||||
if (!this.isMouseDown) {
|
||||
- var openable = !search || search && minCharacters === 1 && !this.state.open;
|
||||
+ var openable = !search || search && minCharacters === 0 && !this.state.open;
|
||||
if (openOnFocus && openable) this.open();
|
||||
}
|
||||
} else if (prevState.focus && !this.state.focus) {
|
||||
@@ -1436,7 +1436,7 @@ Dropdown.defaultProps = {
|
||||
closeOnEscape: true,
|
||||
deburr: false,
|
||||
icon: 'dropdown',
|
||||
- minCharacters: 1,
|
||||
+ minCharacters: 0,
|
||||
noResultsMessage: 'No results found.',
|
||||
openOnFocus: true,
|
||||
renderLabel: renderItemContent,
|
||||
diff --git a/node_modules/semantic-ui-react/dist/es/modules/Modal/Modal.js b/node_modules/semantic-ui-react/dist/es/modules/Modal/Modal.js
|
||||
index a39f694..c9c616a 100644
|
||||
--- a/node_modules/semantic-ui-react/dist/es/modules/Modal/Modal.js
|
||||
+++ b/node_modules/semantic-ui-react/dist/es/modules/Modal/Modal.js
|
||||
@@ -20,6 +20,7 @@ import ModalDescription from './ModalDescription';
|
||||
import ModalDimmer from './ModalDimmer';
|
||||
import ModalHeader from './ModalHeader';
|
||||
import { canFit, getLegacyStyles, isLegacy } from './utils';
|
||||
+var IS_WINDOWS = navigator.platform.startsWith('Win');
|
||||
|
||||
/**
|
||||
* A modal displays content that temporarily blocks interactions with the main view of a site.
|
||||
@@ -41,6 +42,7 @@ var Modal = /*#__PURE__*/function (_Component) {
|
||||
_this.ref = /*#__PURE__*/createRef();
|
||||
_this.dimmerRef = /*#__PURE__*/createRef();
|
||||
_this.latestDocumentMouseDownEvent = null;
|
||||
+ _this.latestWindowFocusTimeOnWindows = null;
|
||||
|
||||
_this.getMountNode = function () {
|
||||
return isBrowser() ? _this.props.mountNode || document.body : null;
|
||||
@@ -68,11 +70,17 @@ var Modal = /*#__PURE__*/function (_Component) {
|
||||
}));
|
||||
};
|
||||
|
||||
+ _this.handleWindowFocusOnWindows = function () {
|
||||
+ _this.latestWindowFocusTimeOnWindows = Date.now();
|
||||
+ };
|
||||
+
|
||||
_this.handleDocumentMouseDown = function (e) {
|
||||
+ if (_this.latestWindowFocusTimeOnWindows && Date.now() - _this.latestWindowFocusTimeOnWindows < 50) return;
|
||||
_this.latestDocumentMouseDownEvent = e;
|
||||
};
|
||||
|
||||
_this.handleDocumentClick = function (e) {
|
||||
+ if (!_this.latestDocumentMouseDownEvent) return;
|
||||
var closeOnDimmerClick = _this.props.closeOnDimmerClick;
|
||||
var currentDocumentMouseDownEvent = _this.latestDocumentMouseDownEvent;
|
||||
_this.latestDocumentMouseDownEvent = null;
|
||||
@@ -116,6 +124,13 @@ var Modal = /*#__PURE__*/function (_Component) {
|
||||
|
||||
_this.setPositionAndClassNames();
|
||||
|
||||
+ if (IS_WINDOWS) {
|
||||
+ eventStack.sub('focus', _this.handleWindowFocusOnWindows, {
|
||||
+ pool: eventPool,
|
||||
+ target: window
|
||||
+ });
|
||||
+ }
|
||||
+
|
||||
eventStack.sub('mousedown', _this.handleDocumentMouseDown, {
|
||||
pool: eventPool,
|
||||
target: _this.dimmerRef.current
|
||||
@@ -131,6 +146,14 @@ var Modal = /*#__PURE__*/function (_Component) {
|
||||
_this.handlePortalUnmount = function (e) {
|
||||
var eventPool = _this.props.eventPool;
|
||||
cancelAnimationFrame(_this.animationRequestId);
|
||||
+
|
||||
+ if (IS_WINDOWS) {
|
||||
+ eventStack.unsub('focus', _this.handleWindowFocusOnWindows, {
|
||||
+ pool: eventPool,
|
||||
+ target: window
|
||||
+ });
|
||||
+ }
|
||||
+
|
||||
eventStack.unsub('mousedown', _this.handleDocumentMouseDown, {
|
||||
pool: eventPool,
|
||||
target: _this.dimmerRef.current
|
||||
diff --git a/node_modules/semantic-ui-react/src/lib/doesNodeContainClick.js b/node_modules/semantic-ui-react/src/lib/doesNodeContainClick.js
|
||||
index d1ae271..43e1170 100644
|
||||
--- a/node_modules/semantic-ui-react/src/lib/doesNodeContainClick.js
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 9.4 KiB After Width: | Height: | Size: 2.5 KiB |
@@ -5,15 +5,39 @@
|
||||
|
||||
import ActionTypes from '../constants/ActionTypes';
|
||||
|
||||
const fetchActivities = (cardId) => ({
|
||||
type: ActionTypes.ACTIVITIES_FETCH,
|
||||
const fetchActivitiesInBoard = (boardId) => ({
|
||||
type: ActionTypes.ACTIVITIES_IN_BOARD_FETCH,
|
||||
payload: {
|
||||
boardId,
|
||||
},
|
||||
});
|
||||
|
||||
fetchActivitiesInBoard.success = (boardId, activities, users) => ({
|
||||
type: ActionTypes.ACTIVITIES_IN_BOARD_FETCH__SUCCESS,
|
||||
payload: {
|
||||
boardId,
|
||||
activities,
|
||||
users,
|
||||
},
|
||||
});
|
||||
|
||||
fetchActivitiesInBoard.failure = (boardId, error) => ({
|
||||
type: ActionTypes.ACTIVITIES_IN_BOARD_FETCH__FAILURE,
|
||||
payload: {
|
||||
boardId,
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const fetchActivitiesInCard = (cardId) => ({
|
||||
type: ActionTypes.ACTIVITIES_IN_CARD_FETCH,
|
||||
payload: {
|
||||
cardId,
|
||||
},
|
||||
});
|
||||
|
||||
fetchActivities.success = (cardId, activities, users) => ({
|
||||
type: ActionTypes.ACTIVITIES_FETCH__SUCCESS,
|
||||
fetchActivitiesInCard.success = (cardId, activities, users) => ({
|
||||
type: ActionTypes.ACTIVITIES_IN_CARD_FETCH__SUCCESS,
|
||||
payload: {
|
||||
cardId,
|
||||
activities,
|
||||
@@ -21,8 +45,8 @@ fetchActivities.success = (cardId, activities, users) => ({
|
||||
},
|
||||
});
|
||||
|
||||
fetchActivities.failure = (cardId, error) => ({
|
||||
type: ActionTypes.ACTIVITIES_FETCH__FAILURE,
|
||||
fetchActivitiesInCard.failure = (cardId, error) => ({
|
||||
type: ActionTypes.ACTIVITIES_IN_CARD_FETCH__FAILURE,
|
||||
payload: {
|
||||
cardId,
|
||||
error,
|
||||
@@ -37,6 +61,7 @@ const handleActivityCreate = (activity) => ({
|
||||
});
|
||||
|
||||
export default {
|
||||
fetchActivities,
|
||||
fetchActivitiesInBoard,
|
||||
fetchActivitiesInCard,
|
||||
handleActivityCreate,
|
||||
};
|
||||
|
||||
59
client/src/actions/config.js
Normal file
59
client/src/actions/config.js
Normal file
@@ -0,0 +1,59 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import ActionTypes from '../constants/ActionTypes';
|
||||
|
||||
const updateConfig = (data) => ({
|
||||
type: ActionTypes.CONFIG_UPDATE,
|
||||
payload: {
|
||||
data,
|
||||
},
|
||||
});
|
||||
|
||||
updateConfig.success = (config) => ({
|
||||
type: ActionTypes.CONFIG_UPDATE__SUCCESS,
|
||||
payload: {
|
||||
config,
|
||||
},
|
||||
});
|
||||
|
||||
updateConfig.failure = (error) => ({
|
||||
type: ActionTypes.CONFIG_UPDATE__FAILURE,
|
||||
payload: {
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const handleConfigUpdate = (config) => ({
|
||||
type: ActionTypes.CONFIG_UPDATE_HANDLE,
|
||||
payload: {
|
||||
config,
|
||||
},
|
||||
});
|
||||
|
||||
const testSmtpConfig = () => ({
|
||||
type: ActionTypes.SMTP_CONFIG_TEST,
|
||||
payload: {},
|
||||
});
|
||||
|
||||
testSmtpConfig.success = (logs) => ({
|
||||
type: ActionTypes.SMTP_CONFIG_TEST__SUCCESS,
|
||||
payload: {
|
||||
logs,
|
||||
},
|
||||
});
|
||||
|
||||
testSmtpConfig.failure = (error) => ({
|
||||
type: ActionTypes.SMTP_CONFIG_TEST__FAILURE,
|
||||
payload: {
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
export default {
|
||||
updateConfig,
|
||||
handleConfigUpdate,
|
||||
testSmtpConfig,
|
||||
};
|
||||
@@ -6,8 +6,10 @@
|
||||
import ActionTypes from '../constants/ActionTypes';
|
||||
|
||||
const initializeCore = (
|
||||
config,
|
||||
user,
|
||||
board,
|
||||
webhooks,
|
||||
users,
|
||||
projects,
|
||||
projectManagers,
|
||||
@@ -31,8 +33,10 @@ const initializeCore = (
|
||||
) => ({
|
||||
type: ActionTypes.CORE_INITIALIZE,
|
||||
payload: {
|
||||
config,
|
||||
user,
|
||||
board,
|
||||
webhooks,
|
||||
users,
|
||||
projects,
|
||||
projectManagers,
|
||||
@@ -56,10 +60,10 @@ const initializeCore = (
|
||||
},
|
||||
});
|
||||
|
||||
initializeCore.fetchConfig = (config) => ({
|
||||
type: ActionTypes.CORE_INITIALIZE__CONFIG_FETCH,
|
||||
initializeCore.fetchBootstrap = (bootstrap) => ({
|
||||
type: ActionTypes.CORE_INITIALIZE__BOOTSTRAP_FETCH,
|
||||
payload: {
|
||||
config,
|
||||
bootstrap,
|
||||
},
|
||||
});
|
||||
|
||||
@@ -89,8 +93,8 @@ const logout = () => ({
|
||||
payload: {},
|
||||
});
|
||||
|
||||
logout.invalidateAccessToken = () => ({
|
||||
type: ActionTypes.LOGOUT__ACCESS_TOKEN_INVALIDATE,
|
||||
logout.revokeAccessToken = () => ({
|
||||
type: ActionTypes.LOGOUT__ACCESS_TOKEN_REVOKE,
|
||||
payload: {},
|
||||
});
|
||||
|
||||
|
||||
@@ -8,6 +8,8 @@ import socket from './socket';
|
||||
import login from './login';
|
||||
import core from './core';
|
||||
import modals from './modals';
|
||||
import config from './config';
|
||||
import webhooks from './webhooks';
|
||||
import users from './users';
|
||||
import projects from './projects';
|
||||
import projectManagers from './project-managers';
|
||||
@@ -35,6 +37,8 @@ export default {
|
||||
...login,
|
||||
...core,
|
||||
...modals,
|
||||
...config,
|
||||
...webhooks,
|
||||
...users,
|
||||
...projects,
|
||||
...projectManagers,
|
||||
|
||||
@@ -58,10 +58,34 @@ updateList.failure = (id, error) => ({
|
||||
},
|
||||
});
|
||||
|
||||
const handleListUpdate = (list) => ({
|
||||
const handleListUpdate = (
|
||||
list,
|
||||
isFetched,
|
||||
users,
|
||||
cards,
|
||||
cardMemberships,
|
||||
cardLabels,
|
||||
taskLists,
|
||||
tasks,
|
||||
attachments,
|
||||
customFieldGroups,
|
||||
customFields,
|
||||
customFieldValues,
|
||||
) => ({
|
||||
type: ActionTypes.LIST_UPDATE_HANDLE,
|
||||
payload: {
|
||||
list,
|
||||
isFetched,
|
||||
users,
|
||||
cards,
|
||||
cardMemberships,
|
||||
cardLabels,
|
||||
taskLists,
|
||||
tasks,
|
||||
attachments,
|
||||
customFieldGroups,
|
||||
customFields,
|
||||
customFieldValues,
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
@@ -5,10 +5,10 @@
|
||||
|
||||
import ActionTypes from '../constants/ActionTypes';
|
||||
|
||||
const initializeLogin = (config) => ({
|
||||
const initializeLogin = (bootstrap) => ({
|
||||
type: ActionTypes.LOGIN_INITIALIZE,
|
||||
payload: {
|
||||
config,
|
||||
bootstrap,
|
||||
},
|
||||
});
|
||||
|
||||
@@ -26,10 +26,11 @@ authenticate.success = (accessToken) => ({
|
||||
},
|
||||
});
|
||||
|
||||
authenticate.failure = (error) => ({
|
||||
authenticate.failure = (error, terms) => ({
|
||||
type: ActionTypes.AUTHENTICATE__FAILURE,
|
||||
payload: {
|
||||
error,
|
||||
terms,
|
||||
},
|
||||
});
|
||||
|
||||
@@ -45,10 +46,11 @@ authenticateWithOidc.success = (accessToken) => ({
|
||||
},
|
||||
});
|
||||
|
||||
authenticateWithOidc.failure = (error) => ({
|
||||
authenticateWithOidc.failure = (error, terms) => ({
|
||||
type: ActionTypes.WITH_OIDC_AUTHENTICATE__FAILURE,
|
||||
payload: {
|
||||
error,
|
||||
terms,
|
||||
},
|
||||
});
|
||||
|
||||
@@ -57,9 +59,71 @@ const clearAuthenticateError = () => ({
|
||||
payload: {},
|
||||
});
|
||||
|
||||
const acceptTerms = (signature) => ({
|
||||
type: ActionTypes.TERMS_ACCEPT,
|
||||
payload: {
|
||||
signature,
|
||||
},
|
||||
});
|
||||
|
||||
acceptTerms.success = (accessToken) => ({
|
||||
type: ActionTypes.TERMS_ACCEPT__SUCCESS,
|
||||
payload: {
|
||||
accessToken,
|
||||
},
|
||||
});
|
||||
|
||||
acceptTerms.failure = (error) => ({
|
||||
type: ActionTypes.TERMS_ACCEPT__FAILURE,
|
||||
payload: {
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const cancelTerms = () => ({
|
||||
type: ActionTypes.TERMS_CANCEL,
|
||||
payload: {},
|
||||
});
|
||||
|
||||
cancelTerms.success = () => ({
|
||||
type: ActionTypes.TERMS_CANCEL__SUCCESS,
|
||||
payload: {},
|
||||
});
|
||||
|
||||
cancelTerms.failure = (error) => ({
|
||||
type: ActionTypes.TERMS_CANCEL__FAILURE,
|
||||
payload: {
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const updateTermsLanguage = (value) => ({
|
||||
type: ActionTypes.TERMS_LANGUAGE_UPDATE,
|
||||
payload: {
|
||||
value,
|
||||
},
|
||||
});
|
||||
|
||||
updateTermsLanguage.success = (terms) => ({
|
||||
type: ActionTypes.TERMS_LANGUAGE_UPDATE__SUCCESS,
|
||||
payload: {
|
||||
terms,
|
||||
},
|
||||
});
|
||||
|
||||
updateTermsLanguage.failure = (error) => ({
|
||||
type: ActionTypes.TERMS_LANGUAGE_UPDATE__FAILURE,
|
||||
payload: {
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
export default {
|
||||
initializeLogin,
|
||||
authenticate,
|
||||
authenticateWithOidc,
|
||||
clearAuthenticateError,
|
||||
acceptTerms,
|
||||
cancelTerms,
|
||||
updateTermsLanguage,
|
||||
};
|
||||
|
||||
@@ -11,9 +11,11 @@ const handleSocketDisconnect = () => ({
|
||||
});
|
||||
|
||||
const handleSocketReconnect = (
|
||||
bootstrap,
|
||||
config,
|
||||
user,
|
||||
board,
|
||||
webhooks,
|
||||
users,
|
||||
projects,
|
||||
projectManagers,
|
||||
@@ -37,9 +39,11 @@ const handleSocketReconnect = (
|
||||
) => ({
|
||||
type: ActionTypes.SOCKET_RECONNECT_HANDLE,
|
||||
payload: {
|
||||
bootstrap,
|
||||
config,
|
||||
user,
|
||||
board,
|
||||
webhooks,
|
||||
users,
|
||||
projects,
|
||||
projectManagers,
|
||||
|
||||
@@ -65,8 +65,10 @@ const handleUserUpdate = (
|
||||
user,
|
||||
projectIds,
|
||||
boardIds,
|
||||
bootstrap,
|
||||
config,
|
||||
board,
|
||||
webhooks,
|
||||
users,
|
||||
projects,
|
||||
projectManagers,
|
||||
@@ -93,8 +95,10 @@ const handleUserUpdate = (
|
||||
user,
|
||||
projectIds,
|
||||
boardIds,
|
||||
bootstrap,
|
||||
config,
|
||||
board,
|
||||
webhooks,
|
||||
users,
|
||||
projects,
|
||||
projectManagers,
|
||||
@@ -231,6 +235,58 @@ updateUserAvatar.failure = (id, error) => ({
|
||||
},
|
||||
});
|
||||
|
||||
const createUserApiKey = (id) => ({
|
||||
type: ActionTypes.USER_API_KEY_CREATE,
|
||||
payload: {
|
||||
id,
|
||||
},
|
||||
});
|
||||
|
||||
createUserApiKey.success = (user, apiKey) => ({
|
||||
type: ActionTypes.USER_API_KEY_CREATE__SUCCESS,
|
||||
payload: {
|
||||
user,
|
||||
apiKey,
|
||||
},
|
||||
});
|
||||
|
||||
createUserApiKey.failure = (id, error) => ({
|
||||
type: ActionTypes.USER_API_KEY_CREATE__FAILURE,
|
||||
payload: {
|
||||
id,
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const deleteUserApiKey = (id) => ({
|
||||
type: ActionTypes.USER_API_KEY_DELETE,
|
||||
payload: {
|
||||
id,
|
||||
},
|
||||
});
|
||||
|
||||
deleteUserApiKey.success = (user) => ({
|
||||
type: ActionTypes.USER_API_KEY_DELETE__SUCCESS,
|
||||
payload: {
|
||||
user,
|
||||
},
|
||||
});
|
||||
|
||||
deleteUserApiKey.failure = (id, error) => ({
|
||||
type: ActionTypes.USER_API_KEY_DELETE__FAILURE,
|
||||
payload: {
|
||||
id,
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const clearUserApiKeyValue = (id) => ({
|
||||
type: ActionTypes.USER_API_KEY_VALUE_CLEAR,
|
||||
payload: {
|
||||
id,
|
||||
},
|
||||
});
|
||||
|
||||
const deleteUser = (id) => ({
|
||||
type: ActionTypes.USER_DELETE,
|
||||
payload: {
|
||||
@@ -355,6 +411,9 @@ export default {
|
||||
updateUserUsername,
|
||||
clearUserUsernameUpdateError,
|
||||
updateUserAvatar,
|
||||
createUserApiKey,
|
||||
deleteUserApiKey,
|
||||
clearUserApiKeyValue,
|
||||
deleteUser,
|
||||
handleUserDelete,
|
||||
addUserToCard,
|
||||
|
||||
104
client/src/actions/webhooks.js
Normal file
104
client/src/actions/webhooks.js
Normal file
@@ -0,0 +1,104 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import ActionTypes from '../constants/ActionTypes';
|
||||
|
||||
const createWebhook = (webhook) => ({
|
||||
type: ActionTypes.WEBHOOK_CREATE,
|
||||
payload: {
|
||||
webhook,
|
||||
},
|
||||
});
|
||||
|
||||
createWebhook.success = (localId, webhook) => ({
|
||||
type: ActionTypes.WEBHOOK_CREATE__SUCCESS,
|
||||
payload: {
|
||||
localId,
|
||||
webhook,
|
||||
},
|
||||
});
|
||||
|
||||
createWebhook.failure = (localId, error) => ({
|
||||
type: ActionTypes.WEBHOOK_CREATE__FAILURE,
|
||||
payload: {
|
||||
localId,
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const handleWebhookCreate = (webhook) => ({
|
||||
type: ActionTypes.WEBHOOK_CREATE_HANDLE,
|
||||
payload: {
|
||||
webhook,
|
||||
},
|
||||
});
|
||||
|
||||
const updateWebhook = (id, data) => ({
|
||||
type: ActionTypes.WEBHOOK_UPDATE,
|
||||
payload: {
|
||||
id,
|
||||
data,
|
||||
},
|
||||
});
|
||||
|
||||
updateWebhook.success = (webhook) => ({
|
||||
type: ActionTypes.WEBHOOK_UPDATE__SUCCESS,
|
||||
payload: {
|
||||
webhook,
|
||||
},
|
||||
});
|
||||
|
||||
updateWebhook.failure = (id, error) => ({
|
||||
type: ActionTypes.WEBHOOK_UPDATE__FAILURE,
|
||||
payload: {
|
||||
id,
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const handleWebhookUpdate = (webhook) => ({
|
||||
type: ActionTypes.WEBHOOK_UPDATE_HANDLE,
|
||||
payload: {
|
||||
webhook,
|
||||
},
|
||||
});
|
||||
|
||||
const deleteWebhook = (id) => ({
|
||||
type: ActionTypes.WEBHOOK_DELETE,
|
||||
payload: {
|
||||
id,
|
||||
},
|
||||
});
|
||||
|
||||
deleteWebhook.success = (webhook) => ({
|
||||
type: ActionTypes.WEBHOOK_DELETE__SUCCESS,
|
||||
payload: {
|
||||
webhook,
|
||||
},
|
||||
});
|
||||
|
||||
deleteWebhook.failure = (id, error) => ({
|
||||
type: ActionTypes.WEBHOOK_DELETE__FAILURE,
|
||||
payload: {
|
||||
id,
|
||||
error,
|
||||
},
|
||||
});
|
||||
|
||||
const handleWebhookDelete = (webhook) => ({
|
||||
type: ActionTypes.WEBHOOK_DELETE_HANDLE,
|
||||
payload: {
|
||||
webhook,
|
||||
},
|
||||
});
|
||||
|
||||
export default {
|
||||
createWebhook,
|
||||
handleWebhookCreate,
|
||||
updateWebhook,
|
||||
handleWebhookUpdate,
|
||||
deleteWebhook,
|
||||
handleWebhookDelete,
|
||||
};
|
||||
@@ -13,10 +13,18 @@ const createAccessToken = (data, headers) =>
|
||||
const exchangeForAccessTokenWithOidc = (data, headers) =>
|
||||
http.post('/access-tokens/exchange-with-oidc?withHttpOnlyToken=true', data, headers);
|
||||
|
||||
// TODO: rename?
|
||||
const acceptTerms = (data, headers) => http.post('/access-tokens/accept-terms', data, headers);
|
||||
|
||||
const revokePendingToken = (data, headers) =>
|
||||
http.post('/access-tokens/revoke-pending-token', data, headers);
|
||||
|
||||
const deleteCurrentAccessToken = (headers) => http.delete('/access-tokens/me', undefined, headers);
|
||||
|
||||
export default {
|
||||
createAccessToken,
|
||||
exchangeForAccessTokenWithOidc,
|
||||
acceptTerms,
|
||||
revokePendingToken,
|
||||
deleteCurrentAccessToken,
|
||||
};
|
||||
|
||||
@@ -16,7 +16,13 @@ export const transformActivity = (activity) => ({
|
||||
|
||||
/* Actions */
|
||||
|
||||
const getActivities = (cardId, data, headers) =>
|
||||
const getBoardActivities = (boardId, data, headers) =>
|
||||
socket.get(`/boards/${boardId}/actions`, data, headers).then((body) => ({
|
||||
...body,
|
||||
items: body.items.map(transformActivity),
|
||||
}));
|
||||
|
||||
const getCardActivities = (cardId, data, headers) =>
|
||||
socket.get(`/cards/${cardId}/actions`, data, headers).then((body) => ({
|
||||
...body,
|
||||
items: body.items.map(transformActivity),
|
||||
@@ -32,6 +38,7 @@ const makeHandleActivityCreate = (next) => (body) => {
|
||||
};
|
||||
|
||||
export default {
|
||||
getActivities,
|
||||
getBoardActivities,
|
||||
getCardActivities,
|
||||
makeHandleActivityCreate,
|
||||
};
|
||||
|
||||
14
client/src/api/bootstrap.js
vendored
Normal file
14
client/src/api/bootstrap.js
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import http from './http';
|
||||
|
||||
/* Actions */
|
||||
|
||||
const getBootstrap = (headers) => http.get('/bootstrap', undefined, headers);
|
||||
|
||||
export default {
|
||||
getBootstrap,
|
||||
};
|
||||
@@ -3,12 +3,18 @@
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import http from './http';
|
||||
import socket from './socket';
|
||||
|
||||
/* Actions */
|
||||
|
||||
const getConfig = (headers) => http.get('/config', undefined, headers);
|
||||
const getConfig = (headers) => socket.get('/config', undefined, headers);
|
||||
|
||||
const updateConfig = (data, headers) => socket.patch('/config', data, headers);
|
||||
|
||||
const testSmtpConfig = (headers) => socket.post('/config/test-smtp', undefined, headers);
|
||||
|
||||
export default {
|
||||
getConfig,
|
||||
updateConfig,
|
||||
testSmtpConfig,
|
||||
};
|
||||
|
||||
@@ -7,10 +7,10 @@ import socket from './socket';
|
||||
|
||||
/* Actions */
|
||||
|
||||
const createCustomFieldGroupInBoard = (cardId, data, headers) =>
|
||||
const createBoardCustomFieldGroup = (cardId, data, headers) =>
|
||||
socket.post(`/boards/${cardId}/custom-field-groups`, data, headers);
|
||||
|
||||
const createCustomFieldGroupInCard = (cardId, data, headers) =>
|
||||
const createCardCustomFieldGroup = (cardId, data, headers) =>
|
||||
socket.post(`/cards/${cardId}/custom-field-groups`, data, headers);
|
||||
|
||||
const getCustomFieldGroup = (id, headers) =>
|
||||
@@ -23,8 +23,8 @@ const deleteCustomFieldGroup = (id, headers) =>
|
||||
socket.delete(`/custom-field-groups/${id}`, undefined, headers);
|
||||
|
||||
export default {
|
||||
createCustomFieldGroupInBoard,
|
||||
createCustomFieldGroupInCard,
|
||||
createBoardCustomFieldGroup,
|
||||
createCardCustomFieldGroup,
|
||||
getCustomFieldGroup,
|
||||
updateCustomFieldGroup,
|
||||
deleteCustomFieldGroup,
|
||||
|
||||
@@ -5,8 +5,11 @@
|
||||
|
||||
import http from './http';
|
||||
import socket from './socket';
|
||||
import config from './config';
|
||||
import bootstrap from './bootstrap';
|
||||
import terms from './terms';
|
||||
import accessTokens from './access-tokens';
|
||||
import config from './config';
|
||||
import webhooks from './webhooks';
|
||||
import users from './users';
|
||||
import projects from './projects';
|
||||
import projectManagers from './project-managers';
|
||||
@@ -33,8 +36,11 @@ import notificationServices from './notification-services';
|
||||
export { http, socket };
|
||||
|
||||
export default {
|
||||
...config,
|
||||
...bootstrap,
|
||||
...terms,
|
||||
...accessTokens,
|
||||
...config,
|
||||
...webhooks,
|
||||
...users,
|
||||
...projects,
|
||||
...projectManagers,
|
||||
|
||||
@@ -7,10 +7,10 @@ import socket from './socket';
|
||||
|
||||
/* Actions */
|
||||
|
||||
const createNotificationServiceInUser = (userId, data, headers) =>
|
||||
const createUserNotificationService = (userId, data, headers) =>
|
||||
socket.post(`/users/${userId}/notification-services`, data, headers);
|
||||
|
||||
const createNotificationServiceInBoard = (boardId, data, headers) =>
|
||||
const createBoardNotificationService = (boardId, data, headers) =>
|
||||
socket.post(`/boards/${boardId}/notification-services`, data, headers);
|
||||
|
||||
const updateNotificationService = (id, data, headers) =>
|
||||
@@ -23,8 +23,8 @@ const deleteNotificationService = (id, headers) =>
|
||||
socket.delete(`/notification-services/${id}`, undefined, headers);
|
||||
|
||||
export default {
|
||||
createNotificationServiceInUser,
|
||||
createNotificationServiceInBoard,
|
||||
createUserNotificationService,
|
||||
createBoardNotificationService,
|
||||
updateNotificationService,
|
||||
testNotificationService,
|
||||
deleteNotificationService,
|
||||
|
||||
@@ -16,6 +16,9 @@ export const transformNotification = (notification) => ({
|
||||
activityId: notification.actionId,
|
||||
}
|
||||
: notification),
|
||||
...(notification.createdAt && {
|
||||
createdAt: new Date(notification.createdAt),
|
||||
}),
|
||||
});
|
||||
|
||||
/* Actions */
|
||||
|
||||
15
client/src/api/terms.js
Normal file
15
client/src/api/terms.js
Normal file
@@ -0,0 +1,15 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import http from './http';
|
||||
|
||||
/* Actions */
|
||||
|
||||
const getTerms = (type, language, headers) =>
|
||||
http.get(`/terms/${type}${language ? `?language=${language}` : ''}`, undefined, headers);
|
||||
|
||||
export default {
|
||||
getTerms,
|
||||
};
|
||||
@@ -33,6 +33,9 @@ const updateUserUsername = (id, data, headers) =>
|
||||
|
||||
const updateUserAvatar = (id, data, headers) => http.post(`/users/${id}/avatar`, data, headers);
|
||||
|
||||
const createUserApiKey = (userId, headers) =>
|
||||
socket.post(`/users/${userId}/api-key`, undefined, headers);
|
||||
|
||||
const deleteUser = (id, headers) => socket.delete(`/users/${id}`, undefined, headers);
|
||||
|
||||
export default {
|
||||
@@ -45,5 +48,6 @@ export default {
|
||||
updateUserPassword,
|
||||
updateUserUsername,
|
||||
updateUserAvatar,
|
||||
createUserApiKey,
|
||||
deleteUser,
|
||||
};
|
||||
|
||||
23
client/src/api/webhooks.js
Executable file
23
client/src/api/webhooks.js
Executable file
@@ -0,0 +1,23 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import socket from './socket';
|
||||
|
||||
/* Actions */
|
||||
|
||||
const getWebhooks = (headers) => socket.get('/webhooks', undefined, headers);
|
||||
|
||||
const createWebhook = (data, headers) => socket.post('/webhooks', data, headers);
|
||||
|
||||
const updateWebhook = (id, data, headers) => socket.patch(`/webhooks/${id}`, data, headers);
|
||||
|
||||
const deleteWebhook = (id, headers) => socket.delete(`/webhooks/${id}`, undefined, headers);
|
||||
|
||||
export default {
|
||||
getWebhooks,
|
||||
createWebhook,
|
||||
updateWebhook,
|
||||
deleteWebhook,
|
||||
};
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 28 KiB |
@@ -0,0 +1,73 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import React, { useCallback } from 'react';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { useInView } from 'react-intersection-observer';
|
||||
import { Comment, Loader } from 'semantic-ui-react';
|
||||
|
||||
import selectors from '../../../selectors';
|
||||
import entryActions from '../../../entry-actions';
|
||||
import { useClosableModal } from '../../../hooks';
|
||||
import Item from './Item';
|
||||
|
||||
import styles from './BoardActivitiesModal.module.scss';
|
||||
|
||||
const BoardActivitiesModal = React.memo(() => {
|
||||
const activityIds = useSelector(selectors.selectActivityIdsForCurrentBoard);
|
||||
|
||||
const { isActivitiesFetching, isAllActivitiesFetched } = useSelector(
|
||||
selectors.selectCurrentBoard,
|
||||
);
|
||||
|
||||
const dispatch = useDispatch();
|
||||
const [t] = useTranslation();
|
||||
|
||||
const handleClose = useCallback(() => {
|
||||
dispatch(entryActions.closeModal());
|
||||
}, [dispatch]);
|
||||
|
||||
const [inViewRef] = useInView({
|
||||
threshold: 1,
|
||||
onChange: (inView) => {
|
||||
if (inView) {
|
||||
dispatch(entryActions.fetchActivitiesInCurrentBoard());
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
const [ClosableModal] = useClosableModal();
|
||||
|
||||
return (
|
||||
<ClosableModal closeIcon size="small" centered={false} onClose={handleClose}>
|
||||
<ClosableModal.Header>
|
||||
{t('common.boardActions', {
|
||||
context: 'title',
|
||||
})}
|
||||
</ClosableModal.Header>
|
||||
<ClosableModal.Content>
|
||||
<div className={styles.itemsWrapper}>
|
||||
<Comment.Group className={styles.items}>
|
||||
{activityIds.map((activityId) => (
|
||||
<Item key={activityId} id={activityId} />
|
||||
))}
|
||||
</Comment.Group>
|
||||
</div>
|
||||
{isActivitiesFetching !== undefined && isAllActivitiesFetched !== undefined && (
|
||||
<div className={styles.loaderWrapper}>
|
||||
{isActivitiesFetching ? (
|
||||
<Loader active inverted inline="centered" size="small" />
|
||||
) : (
|
||||
!isAllActivitiesFetched && <div ref={inViewRef} />
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
</ClosableModal.Content>
|
||||
</ClosableModal>
|
||||
);
|
||||
});
|
||||
|
||||
export default BoardActivitiesModal;
|
||||
@@ -0,0 +1,18 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
:global(#app) {
|
||||
.items {
|
||||
max-width: none;
|
||||
}
|
||||
|
||||
.itemsWrapper {
|
||||
margin-top: 12px;
|
||||
}
|
||||
|
||||
.loaderWrapper {
|
||||
margin-top: 10px;
|
||||
}
|
||||
}
|
||||
220
client/src/components/activities/BoardActivitiesModal/Item.jsx
Executable file
220
client/src/components/activities/BoardActivitiesModal/Item.jsx
Executable file
@@ -0,0 +1,220 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import React, { useMemo } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { useSelector } from 'react-redux';
|
||||
import { useTranslation, Trans } from 'react-i18next';
|
||||
import { Link } from 'react-router-dom';
|
||||
import { Comment } from 'semantic-ui-react';
|
||||
|
||||
import selectors from '../../../selectors';
|
||||
import Paths from '../../../constants/Paths';
|
||||
import { StaticUserIds } from '../../../constants/StaticUsers';
|
||||
import { ActivityTypes } from '../../../constants/Enums';
|
||||
import TimeAgo from '../../common/TimeAgo';
|
||||
import UserAvatar from '../../users/UserAvatar';
|
||||
|
||||
import styles from './Item.module.scss';
|
||||
|
||||
const Item = React.memo(({ id }) => {
|
||||
const selectActivityById = useMemo(() => selectors.makeSelectActivityById(), []);
|
||||
const selectUserById = useMemo(() => selectors.makeSelectUserById(), []);
|
||||
const selectCardById = useMemo(() => selectors.makeSelectCardById(), []);
|
||||
|
||||
const activity = useSelector((state) => selectActivityById(state, id));
|
||||
const user = useSelector((state) => selectUserById(state, activity.userId));
|
||||
const card = useSelector((state) => selectCardById(state, activity.cardId));
|
||||
|
||||
const [t] = useTranslation();
|
||||
|
||||
const userName =
|
||||
user.id === StaticUserIds.DELETED
|
||||
? t(`common.${user.name}`, {
|
||||
context: 'title',
|
||||
})
|
||||
: user.name;
|
||||
|
||||
const cardName = card ? card.name : activity.data.card.name;
|
||||
|
||||
let contentNode;
|
||||
switch (activity.type) {
|
||||
case ActivityTypes.CREATE_CARD: {
|
||||
const { list } = activity.data;
|
||||
const listName = list.name || t(`common.${list.type}`);
|
||||
|
||||
contentNode = (
|
||||
<Trans
|
||||
i18nKey="common.userAddedCardToList"
|
||||
values={{
|
||||
user: userName,
|
||||
card: cardName,
|
||||
list: listName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' added '}
|
||||
<Link to={Paths.CARDS.replace(':id', activity.cardId)}>{cardName}</Link>
|
||||
{' to '}
|
||||
{listName}
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
}
|
||||
case ActivityTypes.MOVE_CARD: {
|
||||
const { fromList, toList } = activity.data;
|
||||
|
||||
const fromListName = fromList.name || t(`common.${fromList.type}`);
|
||||
const toListName = toList.name || t(`common.${toList.type}`);
|
||||
|
||||
contentNode = (
|
||||
<Trans
|
||||
i18nKey="common.userMovedCardFromListToList"
|
||||
values={{
|
||||
user: userName,
|
||||
card: cardName,
|
||||
fromList: fromListName,
|
||||
toList: toListName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' moved '}
|
||||
<Link to={Paths.CARDS.replace(':id', activity.cardId)}>{cardName}</Link>
|
||||
{' from '}
|
||||
{fromListName}
|
||||
{' to '}
|
||||
{toListName}
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
}
|
||||
case ActivityTypes.ADD_MEMBER_TO_CARD:
|
||||
contentNode =
|
||||
user.id === activity.data.user.id ? (
|
||||
<Trans
|
||||
i18nKey="common.userJoinedCard"
|
||||
values={{
|
||||
user: userName,
|
||||
card: cardName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' joined '}
|
||||
<Link to={Paths.CARDS.replace(':id', activity.cardId)}>{cardName}</Link>
|
||||
</Trans>
|
||||
) : (
|
||||
<Trans
|
||||
i18nKey="common.userAddedUserToCard"
|
||||
values={{
|
||||
actorUser: userName,
|
||||
addedUser: activity.data.user.name,
|
||||
card: cardName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' added '}
|
||||
{activity.data.user.name}
|
||||
{' to '}
|
||||
<Link to={Paths.CARDS.replace(':id', activity.cardId)}>{cardName}</Link>
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
case ActivityTypes.REMOVE_MEMBER_FROM_CARD:
|
||||
contentNode =
|
||||
user.id === activity.data.user.id ? (
|
||||
<Trans
|
||||
i18nKey="common.userLeftCard"
|
||||
values={{
|
||||
user: userName,
|
||||
card: cardName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' left '}
|
||||
<Link to={Paths.CARDS.replace(':id', activity.cardId)}>{cardName}</Link>
|
||||
</Trans>
|
||||
) : (
|
||||
<Trans
|
||||
i18nKey="common.userRemovedUserFromCard"
|
||||
values={{
|
||||
actorUser: userName,
|
||||
removedUser: activity.data.user.name,
|
||||
card: cardName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' removed '}
|
||||
{activity.data.user.name}
|
||||
{' from '}
|
||||
<Link to={Paths.CARDS.replace(':id', activity.cardId)}>{cardName}</Link>
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
case ActivityTypes.COMPLETE_TASK:
|
||||
contentNode = (
|
||||
<Trans
|
||||
i18nKey="common.userCompletedTaskOnCard"
|
||||
values={{
|
||||
user: userName,
|
||||
task: activity.data.task.name,
|
||||
card: cardName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' completed '}
|
||||
{activity.data.task.name}
|
||||
{' on '}
|
||||
<Link to={Paths.CARDS.replace(':id', activity.cardId)}>{cardName}</Link>
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
case ActivityTypes.UNCOMPLETE_TASK:
|
||||
contentNode = (
|
||||
<Trans
|
||||
i18nKey="common.userMarkedTaskIncompleteOnCard"
|
||||
values={{
|
||||
user: userName,
|
||||
task: activity.data.task.name,
|
||||
card: cardName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' marked '}
|
||||
{activity.data.task.name}
|
||||
{' incomplete on '}
|
||||
<Link to={Paths.CARDS.replace(':id', activity.cardId)}>{cardName}</Link>
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
default:
|
||||
contentNode = null;
|
||||
}
|
||||
|
||||
return (
|
||||
<Comment>
|
||||
<span className={styles.user}>
|
||||
<UserAvatar id={activity.userId} />
|
||||
</span>
|
||||
<div className={styles.content}>
|
||||
<div>{contentNode}</div>
|
||||
<span className={styles.date}>
|
||||
<TimeAgo date={activity.createdAt} />
|
||||
</span>
|
||||
</div>
|
||||
</Comment>
|
||||
);
|
||||
});
|
||||
|
||||
Item.propTypes = {
|
||||
id: PropTypes.string.isRequired,
|
||||
};
|
||||
|
||||
export default Item;
|
||||
@@ -6,28 +6,22 @@
|
||||
:global(#app) {
|
||||
.author {
|
||||
color: #17394d;
|
||||
display: inline-block;
|
||||
font-weight: bold;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.content {
|
||||
border-bottom: 1px solid #092d4221;
|
||||
display: inline-block;
|
||||
line-height: 20px;
|
||||
padding-bottom: 14px;
|
||||
vertical-align: top;
|
||||
width: calc(100% - 40px);
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.date {
|
||||
color: #6b808c;
|
||||
display: inline-block;
|
||||
font-size: 12px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.text {
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.user {
|
||||
8
client/src/components/activities/BoardActivitiesModal/index.js
Executable file
8
client/src/components/activities/BoardActivitiesModal/index.js
Executable file
@@ -0,0 +1,8 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import BoardActivitiesModal from './BoardActivitiesModal';
|
||||
|
||||
export default BoardActivitiesModal;
|
||||
@@ -12,9 +12,9 @@ import selectors from '../../../selectors';
|
||||
import entryActions from '../../../entry-actions';
|
||||
import Item from './Item';
|
||||
|
||||
import styles from './Activities.module.scss';
|
||||
import styles from './CardActivities.module.scss';
|
||||
|
||||
const Activities = React.memo(() => {
|
||||
const CardActivities = React.memo(() => {
|
||||
const activityIds = useSelector(selectors.selectActivityIdsForCurrentCard);
|
||||
const { isActivitiesFetching, isAllActivitiesFetched } = useSelector(selectors.selectCurrentCard);
|
||||
|
||||
@@ -51,4 +51,4 @@ const Activities = React.memo(() => {
|
||||
);
|
||||
});
|
||||
|
||||
export default Activities;
|
||||
export default CardActivities;
|
||||
@@ -48,10 +48,8 @@ const Item = React.memo(({ id }) => {
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
<span className={styles.text}>
|
||||
{' added this card to '}
|
||||
{listName}
|
||||
</span>
|
||||
{' added this card to '}
|
||||
{listName}
|
||||
</Trans>
|
||||
);
|
||||
|
||||
@@ -73,17 +71,105 @@ const Item = React.memo(({ id }) => {
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
<span className={styles.text}>
|
||||
{' moved this card from '}
|
||||
{fromListName}
|
||||
{' to '}
|
||||
{toListName}
|
||||
</span>
|
||||
{' moved this card from '}
|
||||
{fromListName}
|
||||
{' to '}
|
||||
{toListName}
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
}
|
||||
case ActivityTypes.ADD_MEMBER_TO_CARD:
|
||||
contentNode =
|
||||
user.id === activity.data.user.id ? (
|
||||
<Trans
|
||||
i18nKey="common.userJoinedThisCard"
|
||||
values={{
|
||||
user: userName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' joined this card'}
|
||||
</Trans>
|
||||
) : (
|
||||
<Trans
|
||||
i18nKey="common.userAddedUserToThisCard"
|
||||
values={{
|
||||
actorUser: userName,
|
||||
addedUser: activity.data.user.name,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' added '}
|
||||
{activity.data.user.name}
|
||||
{' to this card'}
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
case ActivityTypes.REMOVE_MEMBER_FROM_CARD:
|
||||
contentNode =
|
||||
user.id === activity.data.user.id ? (
|
||||
<Trans
|
||||
i18nKey="common.userLeftThisCard"
|
||||
values={{
|
||||
user: userName,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' left this card'}
|
||||
</Trans>
|
||||
) : (
|
||||
<Trans
|
||||
i18nKey="common.userRemovedUserFromThisCard"
|
||||
values={{
|
||||
actorUser: userName,
|
||||
removedUser: activity.data.user.name,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' removed '}
|
||||
{activity.data.user.name}
|
||||
{' from this card'}
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
case ActivityTypes.COMPLETE_TASK:
|
||||
contentNode = (
|
||||
<Trans
|
||||
i18nKey="common.userCompletedTaskOnThisCard"
|
||||
values={{
|
||||
user: userName,
|
||||
task: activity.data.task.name,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' completed '}
|
||||
{activity.data.task.name}
|
||||
{' on this card'}
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
case ActivityTypes.UNCOMPLETE_TASK:
|
||||
contentNode = (
|
||||
<Trans
|
||||
i18nKey="common.userMarkedTaskIncompleteOnThisCard"
|
||||
values={{
|
||||
user: userName,
|
||||
task: activity.data.task.name,
|
||||
}}
|
||||
>
|
||||
<span className={styles.author}>{userName}</span>
|
||||
{' marked '}
|
||||
{activity.data.task.name}
|
||||
{' incomplete on this card'}
|
||||
</Trans>
|
||||
);
|
||||
|
||||
break;
|
||||
default:
|
||||
contentNode = null;
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
:global(#app) {
|
||||
.author {
|
||||
color: #17394d;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.content {
|
||||
border-bottom: 1px solid #092d4221;
|
||||
display: inline-block;
|
||||
line-height: 20px;
|
||||
padding-bottom: 14px;
|
||||
vertical-align: top;
|
||||
width: calc(100% - 40px);
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.date {
|
||||
color: #6b808c;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.user {
|
||||
display: inline-block;
|
||||
padding: 4px 8px 0 0;
|
||||
vertical-align: top;
|
||||
}
|
||||
}
|
||||
8
client/src/components/activities/CardActivities/index.js
Executable file
8
client/src/components/activities/CardActivities/index.js
Executable file
@@ -0,0 +1,8 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import CardActivities from './CardActivities';
|
||||
|
||||
export default CardActivities;
|
||||
@@ -7,7 +7,7 @@ import React, { useCallback } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { useDispatch } from 'react-redux';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { Menu } from 'semantic-ui-react';
|
||||
import { Icon, Menu } from 'semantic-ui-react';
|
||||
import { FilePicker, Popup } from '../../../lib/custom-ui';
|
||||
|
||||
import entryActions from '../../../entry-actions';
|
||||
@@ -47,6 +47,7 @@ const AddAttachmentStep = React.memo(({ onClose }) => {
|
||||
<Menu secondary vertical className={styles.menu}>
|
||||
<FilePicker multiple onSelect={handleFilesSelect}>
|
||||
<Menu.Item className={styles.menuItem}>
|
||||
<Icon name="computer" className={styles.menuItemIcon} />
|
||||
{t('common.fromComputer', {
|
||||
context: 'title',
|
||||
})}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
}
|
||||
|
||||
.menu {
|
||||
margin: -7px -12px -5px;
|
||||
margin: 0 -12px -5px;
|
||||
width: calc(100% + 24px);
|
||||
}
|
||||
|
||||
@@ -21,6 +21,11 @@
|
||||
padding-left: 14px;
|
||||
}
|
||||
|
||||
.menuItemIcon {
|
||||
float: left;
|
||||
margin: 0 0.5em 0 0;
|
||||
}
|
||||
|
||||
.tip {
|
||||
opacity: 0.5;
|
||||
}
|
||||
|
||||
121
client/src/components/attachments/Attachments/CsvViewer.jsx
Normal file
121
client/src/components/attachments/Attachments/CsvViewer.jsx
Normal file
@@ -0,0 +1,121 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import React, { useCallback, useEffect, useMemo, useState } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import classNames from 'classnames';
|
||||
import Papa from 'papaparse';
|
||||
import Frame from 'react-frame-component';
|
||||
import { Loader, Pagination, Table } from 'semantic-ui-react';
|
||||
|
||||
import styles from './CsvViewer.module.scss';
|
||||
|
||||
const ROWS_PER_PAGE = 50;
|
||||
|
||||
const CsvViewer = React.memo(({ src, className }) => {
|
||||
const [rows, setRows] = useState(null);
|
||||
const [currentPage, setCurrentPage] = useState(1);
|
||||
|
||||
const frameStyles = useMemo(
|
||||
() => [
|
||||
...Array.from(document.styleSheets).flatMap((styleSheet) =>
|
||||
Array.from(styleSheet.cssRules).map((cssRule) => cssRule.cssText),
|
||||
),
|
||||
'body{background:rgb(248,248,248);min-width:fit-content;overflow-x:visible}',
|
||||
'.frame-content{padding:40px}',
|
||||
'.frame-content>pre{margin:0}',
|
||||
'.hljs{padding:0}',
|
||||
'::-webkit-scrollbar{height:10px}',
|
||||
'.ui.pagination.menu{display:flex;justify-content:center;margin-top:20px;padding:10px 0}',
|
||||
],
|
||||
[],
|
||||
);
|
||||
|
||||
const handlePageChange = useCallback((_, { activePage }) => {
|
||||
setCurrentPage(activePage);
|
||||
}, []);
|
||||
|
||||
useEffect(() => {
|
||||
async function fetchFile() {
|
||||
try {
|
||||
const response = await fetch(src, {
|
||||
credentials: 'include',
|
||||
});
|
||||
|
||||
const text = await response.text();
|
||||
|
||||
Papa.parse(text, {
|
||||
skipEmptyLines: true,
|
||||
complete: ({ data }) => {
|
||||
setRows(data);
|
||||
},
|
||||
});
|
||||
} catch {
|
||||
/* empty */
|
||||
}
|
||||
}
|
||||
|
||||
fetchFile();
|
||||
}, [src]);
|
||||
|
||||
if (rows === null) {
|
||||
return <Loader active size="big" />;
|
||||
}
|
||||
|
||||
const startIndex = (currentPage - 1) * ROWS_PER_PAGE;
|
||||
const endIndex = startIndex + ROWS_PER_PAGE;
|
||||
const currentRows = rows.slice(startIndex, endIndex);
|
||||
const totalPages = Math.ceil(rows.length / ROWS_PER_PAGE);
|
||||
|
||||
return (
|
||||
<Frame
|
||||
head={<style>{frameStyles.join('')}</style>}
|
||||
className={classNames(styles.wrapper, className)}
|
||||
>
|
||||
<div>
|
||||
<Table celled compact>
|
||||
<Table.Header>
|
||||
<Table.Row>
|
||||
{rows[0].map((cell) => (
|
||||
<Table.HeaderCell key={cell}>{cell}</Table.HeaderCell>
|
||||
))}
|
||||
</Table.Row>
|
||||
</Table.Header>
|
||||
<Table.Body>
|
||||
{currentRows.slice(1).map((row) => (
|
||||
<Table.Row key={row}>
|
||||
{row.map((cell) => (
|
||||
<Table.Cell key={cell}>{cell}</Table.Cell>
|
||||
))}
|
||||
</Table.Row>
|
||||
))}
|
||||
</Table.Body>
|
||||
</Table>
|
||||
</div>
|
||||
{totalPages > 1 && (
|
||||
<Pagination
|
||||
secondary
|
||||
pointing
|
||||
totalPages={totalPages}
|
||||
activePage={currentPage}
|
||||
firstItem={null}
|
||||
lastItem={null}
|
||||
onPageChange={handlePageChange}
|
||||
/>
|
||||
)}
|
||||
</Frame>
|
||||
);
|
||||
});
|
||||
|
||||
CsvViewer.propTypes = {
|
||||
src: PropTypes.string.isRequired,
|
||||
className: PropTypes.string,
|
||||
};
|
||||
|
||||
CsvViewer.defaultProps = {
|
||||
className: undefined,
|
||||
};
|
||||
|
||||
export default CsvViewer;
|
||||
@@ -0,0 +1,14 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
:global(#app) {
|
||||
.wrapper {
|
||||
background: #fff;
|
||||
border: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
@@ -11,10 +11,13 @@ import { useTranslation } from 'react-i18next';
|
||||
import { Item as GalleryItem } from 'react-photoswipe-gallery';
|
||||
|
||||
import selectors from '../../../selectors';
|
||||
import Config from '../../../constants/Config';
|
||||
import Encodings from '../../../constants/Encodings';
|
||||
import { AttachmentTypes } from '../../../constants/Enums';
|
||||
import ItemContent from './ItemContent';
|
||||
import ContentViewer from './ContentViewer';
|
||||
import PdfViewer from './PdfViewer';
|
||||
import CsvViewer from './CsvViewer';
|
||||
|
||||
import styles from './Item.module.scss';
|
||||
|
||||
@@ -38,10 +41,8 @@ const Item = React.memo(({ id, isVisible }) => {
|
||||
switch (attachment.data.mimeType) {
|
||||
case 'application/pdf':
|
||||
content = (
|
||||
// eslint-disable-next-line jsx-a11y/alt-text
|
||||
<object
|
||||
data={attachment.data.url}
|
||||
type={attachment.data.mimeType}
|
||||
<PdfViewer
|
||||
src={attachment.data.url}
|
||||
className={classNames(styles.content, styles.contentViewer)}
|
||||
/>
|
||||
);
|
||||
@@ -58,6 +59,15 @@ const Item = React.memo(({ id, isVisible }) => {
|
||||
<audio controls src={attachment.data.url} className={styles.content} />
|
||||
);
|
||||
|
||||
break;
|
||||
case 'text/csv':
|
||||
content = (
|
||||
<CsvViewer
|
||||
src={attachment.data.url}
|
||||
className={classNames(styles.content, styles.contentViewer)}
|
||||
/>
|
||||
);
|
||||
|
||||
break;
|
||||
case 'video/mp4':
|
||||
case 'video/ogg':
|
||||
@@ -70,13 +80,21 @@ const Item = React.memo(({ id, isVisible }) => {
|
||||
break;
|
||||
default:
|
||||
if (attachment.data.encoding === Encodings.UTF8) {
|
||||
content = (
|
||||
<ContentViewer
|
||||
src={attachment.data.url}
|
||||
filename={attachment.data.filename}
|
||||
className={classNames(styles.content, styles.contentViewer)}
|
||||
/>
|
||||
);
|
||||
if (attachment.data.size <= Config.MAX_SIZE_TO_DISPLAY_CONTENT) {
|
||||
content = (
|
||||
<ContentViewer
|
||||
src={attachment.data.url}
|
||||
filename={attachment.data.filename}
|
||||
className={classNames(styles.content, styles.contentViewer)}
|
||||
/>
|
||||
);
|
||||
} else {
|
||||
content = (
|
||||
<span className={classNames(styles.content, styles.contentError)}>
|
||||
{t('common.contentOfThisAttachmentIsTooBigToDisplay')}
|
||||
</span>
|
||||
);
|
||||
}
|
||||
} else {
|
||||
content = (
|
||||
<span className={classNames(styles.content, styles.contentError)}>
|
||||
|
||||
@@ -23,6 +23,7 @@
|
||||
font-size: 20px;
|
||||
font-weight: bold;
|
||||
height: 20px;
|
||||
text-align: center;
|
||||
width: 470px;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ import { usePopupInClosableContext } from '../../../hooks';
|
||||
import { isListArchiveOrTrash } from '../../../utils/record-helpers';
|
||||
import { AttachmentTypes, BoardMembershipRoles } from '../../../constants/Enums';
|
||||
import EditStep from './EditStep';
|
||||
import Favicon from './Favicon';
|
||||
import Favicon from '../../common/Favicon';
|
||||
import TimeAgo from '../../common/TimeAgo';
|
||||
|
||||
import styles from './ItemContent.module.scss';
|
||||
@@ -54,6 +54,19 @@ const ItemContent = React.forwardRef(({ id, onOpen }, ref) => {
|
||||
}
|
||||
}, [onOpen, attachment.data]);
|
||||
|
||||
const handleDownloadClick = useCallback(
|
||||
(event) => {
|
||||
event.stopPropagation();
|
||||
|
||||
const linkElement = document.createElement('a');
|
||||
linkElement.href = attachment.data.url;
|
||||
linkElement.download = attachment.data.filename;
|
||||
linkElement.target = '_blank';
|
||||
linkElement.click();
|
||||
},
|
||||
[attachment.data],
|
||||
);
|
||||
|
||||
const handleToggleCoverClick = useCallback(
|
||||
(event) => {
|
||||
event.stopPropagation();
|
||||
@@ -114,25 +127,35 @@ const ItemContent = React.forwardRef(({ id, onOpen }, ref) => {
|
||||
<span className={styles.information}>
|
||||
<TimeAgo date={attachment.createdAt} />
|
||||
</span>
|
||||
{attachment.type === AttachmentTypes.FILE && attachment.data.image && canEdit && (
|
||||
{attachment.type === AttachmentTypes.FILE && (
|
||||
<span className={styles.options}>
|
||||
<button type="button" className={styles.option} onClick={handleToggleCoverClick}>
|
||||
<Icon
|
||||
name="window maximize outline"
|
||||
flipped="vertically"
|
||||
size="small"
|
||||
className={styles.optionIcon}
|
||||
/>
|
||||
<button type="button" className={styles.option} onClick={handleDownloadClick}>
|
||||
<Icon name="download" size="small" className={styles.optionIcon} />
|
||||
<span className={styles.optionText}>
|
||||
{isCover
|
||||
? t('action.removeCover', {
|
||||
context: 'title',
|
||||
})
|
||||
: t('action.makeCover', {
|
||||
context: 'title',
|
||||
})}
|
||||
{t('action.download', {
|
||||
context: 'title',
|
||||
})}
|
||||
</span>
|
||||
</button>
|
||||
{attachment.data.image && canEdit && (
|
||||
<button type="button" className={styles.option} onClick={handleToggleCoverClick}>
|
||||
<Icon
|
||||
name="window maximize outline"
|
||||
flipped="vertically"
|
||||
size="small"
|
||||
className={styles.optionIcon}
|
||||
/>
|
||||
<span className={styles.optionText}>
|
||||
{isCover
|
||||
? t('action.removeCover', {
|
||||
context: 'title',
|
||||
})
|
||||
: t('action.makeCover', {
|
||||
context: 'title',
|
||||
})}
|
||||
</span>
|
||||
</button>
|
||||
)}
|
||||
</span>
|
||||
)}
|
||||
</div>
|
||||
|
||||
@@ -52,6 +52,10 @@
|
||||
outline: none;
|
||||
padding: 0;
|
||||
|
||||
&:not(:last-child) {
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
color: #172b4d;
|
||||
}
|
||||
|
||||
26
client/src/components/attachments/Attachments/PdfViewer.jsx
Normal file
26
client/src/components/attachments/Attachments/PdfViewer.jsx
Normal file
@@ -0,0 +1,26 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import classNames from 'classnames';
|
||||
|
||||
import styles from './PdfViewer.module.scss';
|
||||
|
||||
const PdfViewer = React.memo(({ src, className }) => (
|
||||
// eslint-disable-next-line jsx-a11y/iframe-has-title
|
||||
<iframe src={src} type="application/pdf" className={classNames(styles.wrapper, className)} />
|
||||
));
|
||||
|
||||
PdfViewer.propTypes = {
|
||||
src: PropTypes.string.isRequired,
|
||||
className: PropTypes.string,
|
||||
};
|
||||
|
||||
PdfViewer.defaultProps = {
|
||||
className: undefined,
|
||||
};
|
||||
|
||||
export default PdfViewer;
|
||||
@@ -4,7 +4,7 @@
|
||||
*/
|
||||
|
||||
:global(#app) {
|
||||
.submitButton {
|
||||
margin-top: 12px;
|
||||
.wrapper {
|
||||
border: 0;
|
||||
}
|
||||
}
|
||||
@@ -121,7 +121,7 @@ const ActionsStep = React.memo(({ boardMembershipId, title, onBack, onClose }) =
|
||||
)}
|
||||
{user.organization && (
|
||||
<div className={styles.information}>
|
||||
<Icon name="briefcase" className={styles.informationIcon} />
|
||||
<Icon name="building" className={styles.informationIcon} />
|
||||
{user.organization}
|
||||
</div>
|
||||
)}
|
||||
|
||||
@@ -67,5 +67,6 @@
|
||||
font-size: 14px;
|
||||
line-height: 1.2;
|
||||
padding: 2px 0 2px 2px;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import orderBy from 'lodash/orderBy';
|
||||
import React, { useEffect, useMemo } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
@@ -31,10 +32,13 @@ const PureBoardMembershipsStep = React.memo(
|
||||
|
||||
const filteredItems = useMemo(
|
||||
() =>
|
||||
items.filter(
|
||||
({ user }) =>
|
||||
user.name.toLowerCase().includes(cleanSearch) ||
|
||||
(user.username && user.username.includes(cleanSearch)),
|
||||
orderBy(
|
||||
items.filter(
|
||||
({ user }) =>
|
||||
user.name.toLowerCase().includes(cleanSearch) ||
|
||||
(user.username && user.username.includes(cleanSearch)),
|
||||
),
|
||||
({ user }) => user.name.toLowerCase(),
|
||||
),
|
||||
[items, cleanSearch],
|
||||
);
|
||||
|
||||
@@ -9,20 +9,20 @@ import classNames from 'classnames';
|
||||
import { useDispatch } from 'react-redux';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { Button, Form, Icon } from 'semantic-ui-react';
|
||||
import { useDidUpdate, useToggle } from '../../../../lib/hooks';
|
||||
import { Input, Popup } from '../../../../lib/custom-ui';
|
||||
import { useDidUpdate, useToggle } from '../../../lib/hooks';
|
||||
import { Input, Popup } from '../../../lib/custom-ui';
|
||||
|
||||
import entryActions from '../../../../entry-actions';
|
||||
import { useForm, useNestedRef, useSteps } from '../../../../hooks';
|
||||
import entryActions from '../../../entry-actions';
|
||||
import { useForm, useNestedRef, useSteps } from '../../../hooks';
|
||||
import ImportStep from './ImportStep';
|
||||
|
||||
import styles from './AddStep.module.scss';
|
||||
import styles from './AddBoardStep.module.scss';
|
||||
|
||||
const StepTypes = {
|
||||
IMPORT: 'IMPORT',
|
||||
};
|
||||
|
||||
const AddStep = React.memo(({ onClose }) => {
|
||||
const AddBoardStep = React.memo(({ onClose }) => {
|
||||
const dispatch = useDispatch();
|
||||
const [t] = useTranslation();
|
||||
|
||||
@@ -123,8 +123,8 @@ const AddStep = React.memo(({ onClose }) => {
|
||||
);
|
||||
});
|
||||
|
||||
AddStep.propTypes = {
|
||||
AddBoardStep.propTypes = {
|
||||
onClose: PropTypes.func.isRequired,
|
||||
};
|
||||
|
||||
export default AddStep;
|
||||
export default AddBoardStep;
|
||||
@@ -7,7 +7,7 @@ import React, { useCallback } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { Button } from 'semantic-ui-react';
|
||||
import { FilePicker, Popup } from '../../../../lib/custom-ui';
|
||||
import { FilePicker, Popup } from '../../../lib/custom-ui';
|
||||
|
||||
import styles from './ImportStep.module.scss';
|
||||
|
||||
8
client/src/components/boards/AddBoardStep/index.js
Normal file
8
client/src/components/boards/AddBoardStep/index.js
Normal file
@@ -0,0 +1,8 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import AddBoardStep from './AddBoardStep';
|
||||
|
||||
export default AddBoardStep;
|
||||
@@ -7,14 +7,18 @@ import React from 'react';
|
||||
import { useSelector } from 'react-redux';
|
||||
|
||||
import selectors from '../../../selectors';
|
||||
import ModalTypes from '../../../constants/ModalTypes';
|
||||
import { BoardContexts, BoardViews } from '../../../constants/Enums';
|
||||
import KanbanContent from './KanbanContent';
|
||||
import FiniteContent from './FiniteContent';
|
||||
import EndlessContent from './EndlessContent';
|
||||
import ShortcutsProvider from './ShortcutsProvider';
|
||||
import CardModal from '../../cards/CardModal';
|
||||
import BoardActivitiesModal from '../../activities/BoardActivitiesModal';
|
||||
|
||||
const Board = React.memo(() => {
|
||||
const board = useSelector(selectors.selectCurrentBoard);
|
||||
const modal = useSelector(selectors.selectCurrentModal);
|
||||
const isCardModalOpened = useSelector((state) => !!selectors.selectPath(state).cardId);
|
||||
|
||||
let Content;
|
||||
@@ -35,10 +39,25 @@ const Board = React.memo(() => {
|
||||
}
|
||||
}
|
||||
|
||||
let modalNode = null;
|
||||
if (isCardModalOpened) {
|
||||
modalNode = <CardModal />;
|
||||
} else if (modal) {
|
||||
switch (modal.type) {
|
||||
case ModalTypes.BOARD_ACTIVITIES:
|
||||
modalNode = <BoardActivitiesModal />;
|
||||
|
||||
break;
|
||||
default:
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<>
|
||||
<Content />
|
||||
{isCardModalOpened && <CardModal />}
|
||||
<ShortcutsProvider>
|
||||
<Content />
|
||||
</ShortcutsProvider>
|
||||
{modalNode}
|
||||
</>
|
||||
);
|
||||
});
|
||||
|
||||
@@ -21,7 +21,7 @@ const FiniteContent = React.memo(() => {
|
||||
|
||||
const handleCardCreate = useCallback(
|
||||
(data, autoOpen) => {
|
||||
dispatch(entryActions.createCardInFirstFiniteList(data, autoOpen));
|
||||
dispatch(entryActions.createCardInFirstFiniteList(data, undefined, autoOpen));
|
||||
},
|
||||
[dispatch],
|
||||
);
|
||||
|
||||
295
client/src/components/boards/Board/ShortcutsProvider.jsx
Normal file
295
client/src/components/boards/Board/ShortcutsProvider.jsx
Normal file
@@ -0,0 +1,295 @@
|
||||
/*!
|
||||
* Copyright (c) 2024 PLANKA Software GmbH
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import React, { useCallback, useEffect, useMemo, useRef } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
import { push } from '../../../lib/redux-router';
|
||||
import { useDidUpdate } from '../../../lib/hooks';
|
||||
import { closePopup } from '../../../lib/popup';
|
||||
|
||||
import store from '../../../store';
|
||||
import selectors from '../../../selectors';
|
||||
import entryActions from '../../../entry-actions';
|
||||
import { isListArchiveOrTrash } from '../../../utils/record-helpers';
|
||||
import { isActiveTextElement } from '../../../utils/element-helpers';
|
||||
import { isModifierKeyPressed } from '../../../utils/event-helpers';
|
||||
import { BoardShortcutsContext } from '../../../contexts';
|
||||
import Paths from '../../../constants/Paths';
|
||||
import { BoardMembershipRoles, ListTypes } from '../../../constants/Enums';
|
||||
import CardActionsStep from '../../cards/CardActionsStep';
|
||||
|
||||
const canEditCardName = (boardMembership, list) => {
|
||||
if (isListArchiveOrTrash(list)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return boardMembership && boardMembership.role === BoardMembershipRoles.EDITOR;
|
||||
};
|
||||
|
||||
const canArchiveCard = (boardMembership, list) => {
|
||||
if (list.type === ListTypes.ARCHIVE) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return boardMembership && boardMembership.role === BoardMembershipRoles.EDITOR;
|
||||
};
|
||||
|
||||
const canUseCardMembers = (boardMembership, list) => {
|
||||
if (isListArchiveOrTrash(list)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return boardMembership && boardMembership.role === BoardMembershipRoles.EDITOR;
|
||||
};
|
||||
|
||||
const canUseCardLabels = (boardMembership, list) => {
|
||||
if (isListArchiveOrTrash(list)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return boardMembership && boardMembership.role === BoardMembershipRoles.EDITOR;
|
||||
};
|
||||
|
||||
const ShortcutsProvider = React.memo(({ children }) => {
|
||||
const { cardId, boardId } = useSelector(selectors.selectPath);
|
||||
|
||||
const dispatch = useDispatch();
|
||||
|
||||
const selectedCardRef = useRef(null);
|
||||
|
||||
const handleCardMouseEnter = useCallback((id, editName, openActions) => {
|
||||
selectedCardRef.current = {
|
||||
id,
|
||||
editName,
|
||||
openActions,
|
||||
};
|
||||
}, []);
|
||||
|
||||
const handleCardMouseLeave = useCallback(() => {
|
||||
selectedCardRef.current = null;
|
||||
}, []);
|
||||
|
||||
const contextValue = useMemo(
|
||||
() => [handleCardMouseEnter, handleCardMouseLeave],
|
||||
[handleCardMouseEnter, handleCardMouseLeave],
|
||||
);
|
||||
|
||||
useDidUpdate(() => {
|
||||
selectedCardRef.current = null;
|
||||
}, [cardId, boardId]);
|
||||
|
||||
useEffect(() => {
|
||||
const handleCardOpen = (event) => {
|
||||
if (!selectedCardRef.current) {
|
||||
return;
|
||||
}
|
||||
|
||||
const state = store.getState();
|
||||
const card = selectors.selectCardById(state, selectedCardRef.current.id);
|
||||
|
||||
if (!card || !card.isPersisted) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
|
||||
closePopup();
|
||||
dispatch(push(Paths.CARDS.replace(':id', card.id)));
|
||||
};
|
||||
|
||||
const handleCardNameEdit = (event) => {
|
||||
if (!selectedCardRef.current) {
|
||||
return;
|
||||
}
|
||||
|
||||
const state = store.getState();
|
||||
const card = selectors.selectCardById(state, selectedCardRef.current.id);
|
||||
|
||||
if (!card || !card.isPersisted) {
|
||||
return;
|
||||
}
|
||||
|
||||
const boardMembership = selectors.selectCurrentUserMembershipForCurrentBoard(state);
|
||||
const list = selectors.selectListById(state, card.listId);
|
||||
|
||||
if (!canEditCardName(boardMembership, list)) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
selectedCardRef.current.editName();
|
||||
};
|
||||
|
||||
const handleCardArchive = (event) => {
|
||||
if (!selectedCardRef.current) {
|
||||
return;
|
||||
}
|
||||
|
||||
const state = store.getState();
|
||||
const card = selectors.selectCardById(state, selectedCardRef.current.id);
|
||||
|
||||
if (!card || !card.isPersisted) {
|
||||
return;
|
||||
}
|
||||
|
||||
const boardMembership = selectors.selectCurrentUserMembershipForCurrentBoard(state);
|
||||
const list = selectors.selectListById(state, card.listId);
|
||||
|
||||
if (!canArchiveCard(boardMembership, list)) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
selectedCardRef.current.openActions(CardActionsStep.StepTypes.ARCHIVE);
|
||||
};
|
||||
|
||||
const handleCardMembers = (event) => {
|
||||
if (!selectedCardRef.current) {
|
||||
return;
|
||||
}
|
||||
|
||||
const state = store.getState();
|
||||
const card = selectors.selectCardById(state, selectedCardRef.current.id);
|
||||
|
||||
if (!card || !card.isPersisted) {
|
||||
return;
|
||||
}
|
||||
|
||||
const boardMembership = selectors.selectCurrentUserMembershipForCurrentBoard(state);
|
||||
const list = selectors.selectListById(state, card.listId);
|
||||
|
||||
if (!canUseCardMembers(boardMembership, list)) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
selectedCardRef.current.openActions(CardActionsStep.StepTypes.MEMBERS);
|
||||
};
|
||||
|
||||
const handleCardLabels = (event) => {
|
||||
if (!selectedCardRef.current) {
|
||||
return;
|
||||
}
|
||||
|
||||
const state = store.getState();
|
||||
const card = selectors.selectCardById(state, selectedCardRef.current.id);
|
||||
|
||||
if (!card || !card.isPersisted) {
|
||||
return;
|
||||
}
|
||||
|
||||
const boardMembership = selectors.selectCurrentUserMembershipForCurrentBoard(state);
|
||||
const list = selectors.selectListById(state, card.listId);
|
||||
|
||||
if (!canUseCardLabels(boardMembership, list)) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
selectedCardRef.current.openActions(CardActionsStep.StepTypes.LABELS);
|
||||
};
|
||||
|
||||
const handleLabelToCardAdd = (event) => {
|
||||
if (!selectedCardRef.current) {
|
||||
return;
|
||||
}
|
||||
|
||||
const state = store.getState();
|
||||
const card = selectors.selectCardById(state, selectedCardRef.current.id);
|
||||
|
||||
if (!card || !card.isPersisted) {
|
||||
return;
|
||||
}
|
||||
|
||||
const boardMembership = selectors.selectCurrentUserMembershipForCurrentBoard(state);
|
||||
const list = selectors.selectListById(state, card.listId);
|
||||
|
||||
if (!canUseCardLabels(boardMembership, list)) {
|
||||
return;
|
||||
}
|
||||
|
||||
const index = event.code === 'Digit0' ? 10 : parseInt(event.code.slice(-1), 10) - 1;
|
||||
const label = selectors.selectLabelsForCurrentBoard(state)[index];
|
||||
|
||||
if (!label) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
const labelIds = selectors.selectLabelIdsByCardId(state, card.id);
|
||||
|
||||
if (labelIds.includes(label.id)) {
|
||||
dispatch(entryActions.removeLabelFromCard(label.id, card.id));
|
||||
} else {
|
||||
dispatch(entryActions.addLabelToCard(label.id, card.id));
|
||||
}
|
||||
};
|
||||
|
||||
const handleKeyDown = (event) => {
|
||||
if (isActiveTextElement(event.target)) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (isModifierKeyPressed(event)) {
|
||||
return;
|
||||
}
|
||||
|
||||
switch (event.code) {
|
||||
case 'KeyE':
|
||||
case 'Enter':
|
||||
handleCardOpen(event);
|
||||
|
||||
break;
|
||||
case 'KeyL':
|
||||
handleCardLabels(event);
|
||||
|
||||
break;
|
||||
case 'KeyM':
|
||||
handleCardMembers(event);
|
||||
|
||||
break;
|
||||
case 'KeyT':
|
||||
handleCardNameEdit(event);
|
||||
|
||||
break;
|
||||
case 'KeyV':
|
||||
handleCardArchive(event);
|
||||
|
||||
break;
|
||||
case 'Digit1':
|
||||
case 'Digit2':
|
||||
case 'Digit3':
|
||||
case 'Digit4':
|
||||
case 'Digit5':
|
||||
case 'Digit6':
|
||||
case 'Digit7':
|
||||
case 'Digit8':
|
||||
case 'Digit9':
|
||||
case 'Digit0':
|
||||
handleLabelToCardAdd(event);
|
||||
|
||||
break;
|
||||
default:
|
||||
}
|
||||
};
|
||||
|
||||
window.addEventListener('keydown', handleKeyDown);
|
||||
|
||||
return () => {
|
||||
window.removeEventListener('keydown', handleKeyDown);
|
||||
};
|
||||
}, [dispatch]);
|
||||
|
||||
return (
|
||||
<BoardShortcutsContext.Provider value={contextValue}>{children}</BoardShortcutsContext.Provider>
|
||||
);
|
||||
});
|
||||
|
||||
ShortcutsProvider.propTypes = {
|
||||
children: PropTypes.element.isRequired,
|
||||
};
|
||||
|
||||
export default ShortcutsProvider;
|
||||
@@ -6,8 +6,12 @@
|
||||
import React from 'react';
|
||||
import classNames from 'classnames';
|
||||
import { useSelector } from 'react-redux';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { Icon } from 'semantic-ui-react';
|
||||
|
||||
import selectors from '../../../selectors';
|
||||
import { BoardContexts } from '../../../constants/Enums';
|
||||
import { BoardContextIcons } from '../../../constants/Icons';
|
||||
import Filters from './Filters';
|
||||
import RightSide from './RightSide';
|
||||
import BoardMemberships from '../../board-memberships/BoardMemberships';
|
||||
@@ -15,7 +19,15 @@ import BoardMemberships from '../../board-memberships/BoardMemberships';
|
||||
import styles from './BoardActions.module.scss';
|
||||
|
||||
const BoardActions = React.memo(() => {
|
||||
const boardContext = useSelector((state) => selectors.selectCurrentBoard(state).context);
|
||||
|
||||
const withContextTitle = boardContext !== BoardContexts.BOARD;
|
||||
|
||||
const withMemberships = useSelector((state) => {
|
||||
if (withContextTitle) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const boardMemberships = selectors.selectMembershipsForCurrentBoard(state);
|
||||
|
||||
if (boardMemberships.length > 0) {
|
||||
@@ -25,9 +37,19 @@ const BoardActions = React.memo(() => {
|
||||
return selectors.selectIsCurrentUserManagerForCurrentProject(state);
|
||||
});
|
||||
|
||||
const [t] = useTranslation();
|
||||
|
||||
return (
|
||||
<div className={styles.wrapper}>
|
||||
<div className={styles.actions}>
|
||||
{withContextTitle && (
|
||||
<div className={styles.action}>
|
||||
<div className={styles.contextTitle}>
|
||||
<Icon name={BoardContextIcons[boardContext]} className={styles.contextTitleIcon} />
|
||||
{t(`common.${boardContext}`)}
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
{withMemberships && (
|
||||
<div className={styles.action}>
|
||||
<BoardMemberships />
|
||||
|
||||
@@ -31,6 +31,18 @@
|
||||
height: 46px;
|
||||
}
|
||||
|
||||
.contextTitle {
|
||||
background: rgba(0, 0, 0, 0.08);
|
||||
border-radius: 3px;
|
||||
color: #fff;
|
||||
line-height: 34px;
|
||||
padding: 2px 14px;
|
||||
}
|
||||
|
||||
.contextTitleIcon {
|
||||
margin-right: 8px;
|
||||
}
|
||||
|
||||
.wrapper {
|
||||
overflow-x: auto;
|
||||
overflow-y: hidden;
|
||||
|
||||
@@ -21,14 +21,14 @@ import CustomFieldGroupsStep from '../../../custom-field-groups/CustomFieldGroup
|
||||
import styles from './ActionsStep.module.scss';
|
||||
|
||||
const StepTypes = {
|
||||
EMPTY_TRASH: 'EMPTY_TRASH',
|
||||
CUSTOM_FIELD_GROUPS: 'CUSTOM_FIELD_GROUPS',
|
||||
EMPTY_TRASH: 'EMPTY_TRASH',
|
||||
};
|
||||
|
||||
const ActionsStep = React.memo(({ onClose }) => {
|
||||
const board = useSelector(selectors.selectCurrentBoard);
|
||||
|
||||
const { withSubscribe, withTrashEmptier, withCustomFieldGroups } = useSelector((state) => {
|
||||
const { withSubscribe, withCustomFieldGroups, withTrashEmptier } = useSelector((state) => {
|
||||
const isManager = selectors.selectIsCurrentUserManagerForCurrentProject(state);
|
||||
const boardMembership = selectors.selectCurrentUserMembershipForCurrentBoard(state);
|
||||
|
||||
@@ -42,8 +42,8 @@ const ActionsStep = React.memo(({ onClose }) => {
|
||||
|
||||
return {
|
||||
withSubscribe: isMember, // TODO: rename?
|
||||
withTrashEmptier: board.context === BoardContexts.TRASH && (isManager || isEditor),
|
||||
withCustomFieldGroups: isEditor,
|
||||
withTrashEmptier: board.context === BoardContexts.TRASH && (isManager || isEditor),
|
||||
};
|
||||
}, shallowEqual);
|
||||
|
||||
@@ -69,21 +69,28 @@ const ActionsStep = React.memo(({ onClose }) => {
|
||||
[onClose, dispatch],
|
||||
);
|
||||
|
||||
const handleActivitiesClick = useCallback(() => {
|
||||
dispatch(entryActions.openBoardActivitiesModal());
|
||||
onClose();
|
||||
}, [onClose, dispatch]);
|
||||
|
||||
const handleEmptyTrashConfirm = useCallback(() => {
|
||||
dispatch(entryActions.clearTrashListInCurrentBoard());
|
||||
onClose();
|
||||
}, [onClose, dispatch]);
|
||||
|
||||
const handleEmptyTrashClick = useCallback(() => {
|
||||
openStep(StepTypes.EMPTY_TRASH);
|
||||
}, [openStep]);
|
||||
|
||||
const handleCustomFieldsClick = useCallback(() => {
|
||||
openStep(StepTypes.CUSTOM_FIELD_GROUPS);
|
||||
}, [openStep]);
|
||||
|
||||
const handleEmptyTrashClick = useCallback(() => {
|
||||
openStep(StepTypes.EMPTY_TRASH);
|
||||
}, [openStep]);
|
||||
|
||||
if (step) {
|
||||
switch (step.type) {
|
||||
case StepTypes.CUSTOM_FIELD_GROUPS:
|
||||
return <CustomFieldGroupsStep onBack={handleBack} onClose={onClose} />;
|
||||
case StepTypes.EMPTY_TRASH:
|
||||
return (
|
||||
<ConfirmationStep
|
||||
@@ -94,8 +101,6 @@ const ActionsStep = React.memo(({ onClose }) => {
|
||||
onBack={handleBack}
|
||||
/>
|
||||
);
|
||||
case StepTypes.CUSTOM_FIELD_GROUPS:
|
||||
return <CustomFieldGroupsStep onBack={handleBack} onClose={onClose} />;
|
||||
default:
|
||||
}
|
||||
}
|
||||
@@ -128,9 +133,15 @@ const ActionsStep = React.memo(({ onClose }) => {
|
||||
})}
|
||||
</Menu.Item>
|
||||
)}
|
||||
<Menu.Item className={styles.menuItem} onClick={handleActivitiesClick}>
|
||||
<Icon name="list ul" className={styles.menuItemIcon} />
|
||||
{t('common.actions', {
|
||||
context: 'title',
|
||||
})}
|
||||
</Menu.Item>
|
||||
{withTrashEmptier && (
|
||||
<>
|
||||
{(withSubscribe || withCustomFieldGroups) && <hr className={styles.divider} />}
|
||||
<hr className={styles.divider} />
|
||||
<Menu.Item className={styles.menuItem} onClick={handleEmptyTrashClick}>
|
||||
<Icon name="trash alternate outline" className={styles.menuItemIcon} />
|
||||
{t('action.emptyTrash', {
|
||||
@@ -140,7 +151,7 @@ const ActionsStep = React.memo(({ onClose }) => {
|
||||
</>
|
||||
)}
|
||||
<>
|
||||
{(withSubscribe || withTrashEmptier) && <hr className={styles.divider} />}
|
||||
<hr className={styles.divider} />
|
||||
{[BoardContexts.BOARD, BoardContexts.ARCHIVE, BoardContexts.TRASH].map((context) => (
|
||||
<Menu.Item
|
||||
key={context}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
}
|
||||
|
||||
.menu {
|
||||
margin: -7px -12px -5px;
|
||||
margin: 0 -12px -5px;
|
||||
width: calc(100% + 24px);
|
||||
}
|
||||
|
||||
@@ -23,6 +23,6 @@
|
||||
|
||||
.menuItemIcon {
|
||||
float: left;
|
||||
margin-right: 0.5em;
|
||||
margin: 0 0.5em 0 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,7 +11,7 @@ import { usePopup } from '../../../../lib/popup';
|
||||
import selectors from '../../../../selectors';
|
||||
import entryActions from '../../../../entry-actions';
|
||||
import { BoardContexts, BoardViews } from '../../../../constants/Enums';
|
||||
import { BoardContextIcons, BoardViewIcons } from '../../../../constants/Icons';
|
||||
import { BoardViewIcons } from '../../../../constants/Icons';
|
||||
import ActionsStep from './ActionsStep';
|
||||
|
||||
import styles from './RightSide.module.scss';
|
||||
@@ -56,7 +56,7 @@ const RightSide = React.memo(() => {
|
||||
<div className={styles.action}>
|
||||
<ActionsPopup>
|
||||
<button type="button" className={styles.button}>
|
||||
<Icon fitted name={BoardContextIcons[board.context]} />
|
||||
<Icon fitted name="ellipsis vertical" />
|
||||
</button>
|
||||
</ActionsPopup>
|
||||
</div>
|
||||
|
||||
@@ -43,6 +43,14 @@ const Others = React.memo(() => {
|
||||
className={styles.radio}
|
||||
onChange={handleChange}
|
||||
/>
|
||||
<Radio
|
||||
toggle
|
||||
name="expandTaskListsByDefault"
|
||||
checked={board.expandTaskListsByDefault}
|
||||
label={t('common.expandTaskListsByDefault')}
|
||||
className={styles.radio}
|
||||
onChange={handleChange}
|
||||
/>
|
||||
</Segment>
|
||||
);
|
||||
});
|
||||
|
||||
@@ -13,7 +13,7 @@ import selectors from '../../../selectors';
|
||||
import entryActions from '../../../entry-actions';
|
||||
import DroppableTypes from '../../../constants/DroppableTypes';
|
||||
import Item from './Item';
|
||||
import AddStep from './AddStep';
|
||||
import AddBoardStep from '../AddBoardStep';
|
||||
|
||||
import styles from './Boards.module.scss';
|
||||
import globalStyles from '../../../styles.module.scss';
|
||||
@@ -59,7 +59,7 @@ const Boards = React.memo(() => {
|
||||
});
|
||||
}, []);
|
||||
|
||||
const AddPopup = usePopup(AddStep);
|
||||
const AddBoardPopup = usePopup(AddBoardStep);
|
||||
|
||||
return (
|
||||
<div className={styles.wrapper} onWheel={handleWheel}>
|
||||
@@ -74,9 +74,9 @@ const Boards = React.memo(() => {
|
||||
))}
|
||||
{placeholder}
|
||||
{canAdd && (
|
||||
<AddPopup>
|
||||
<AddBoardPopup>
|
||||
<Button icon="plus" className={styles.addButton} />
|
||||
</AddPopup>
|
||||
</AddBoardPopup>
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
|
||||
@@ -166,7 +166,6 @@ const AddCard = React.memo(({ isOpened, className, onCreate, onClose }) => {
|
||||
placeholder={t('common.enterCardTitle')}
|
||||
maxLength={1024}
|
||||
minRows={3}
|
||||
spellCheck={false}
|
||||
className={styles.field}
|
||||
onKeyDown={handleFieldKeyDown}
|
||||
onChange={handleFieldChange}
|
||||
|
||||
@@ -3,25 +3,28 @@
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import React, { useCallback, useMemo, useState } from 'react';
|
||||
import upperFirst from 'lodash/upperFirst';
|
||||
import camelCase from 'lodash/camelCase';
|
||||
import React, { useCallback, useContext, useMemo, useRef, useState } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import classNames from 'classnames';
|
||||
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
import { Button, Icon } from 'semantic-ui-react';
|
||||
import { push } from '../../../lib/redux-router';
|
||||
import { usePopup } from '../../../lib/popup';
|
||||
import { closePopup, usePopup } from '../../../lib/popup';
|
||||
|
||||
import selectors from '../../../selectors';
|
||||
import { isListArchiveOrTrash } from '../../../utils/record-helpers';
|
||||
import { BoardShortcutsContext } from '../../../contexts';
|
||||
import Paths from '../../../constants/Paths';
|
||||
import { BoardMembershipRoles, CardTypes, ListTypes } from '../../../constants/Enums';
|
||||
import { BoardMembershipRoles, CardTypes } from '../../../constants/Enums';
|
||||
import ProjectContent from './ProjectContent';
|
||||
import StoryContent from './StoryContent';
|
||||
import InlineContent from './InlineContent';
|
||||
import EditName from './EditName';
|
||||
import ActionsStep from './ActionsStep';
|
||||
import CardActionsStep from '../CardActionsStep';
|
||||
|
||||
import styles from './Card.module.scss';
|
||||
import globalStyles from '../../../styles.module.scss';
|
||||
|
||||
const Card = React.memo(({ id, isInline }) => {
|
||||
const selectCardById = useMemo(() => selectors.makeSelectCardById(), []);
|
||||
@@ -29,6 +32,7 @@ const Card = React.memo(({ id, isInline }) => {
|
||||
const selectListById = useMemo(() => selectors.makeSelectListById(), []);
|
||||
|
||||
const card = useSelector((state) => selectCardById(state, id));
|
||||
const list = useSelector((state) => selectListById(state, card.listId));
|
||||
|
||||
const isHighlightedAsRecent = useSelector((state) => {
|
||||
const { turnOffRecentCardHighlighting } = selectors.selectCurrentUser(state);
|
||||
@@ -40,27 +44,16 @@ const Card = React.memo(({ id, isInline }) => {
|
||||
return selectIsCardWithIdRecent(state, id);
|
||||
});
|
||||
|
||||
const { isDisabled, canUseActions } = useSelector((state) => {
|
||||
const list = selectListById(state, card.listId);
|
||||
|
||||
const canUseActions = useSelector((state) => {
|
||||
const boardMembership = selectors.selectCurrentUserMembershipForCurrentBoard(state);
|
||||
const isEditor = !!boardMembership && boardMembership.role === BoardMembershipRoles.EDITOR;
|
||||
|
||||
if (isListArchiveOrTrash(list)) {
|
||||
return {
|
||||
isDisabled: false,
|
||||
canUseActions: isEditor,
|
||||
};
|
||||
}
|
||||
|
||||
return {
|
||||
isDisabled: list.type === ListTypes.CLOSED && !isEditor,
|
||||
canUseActions: isEditor,
|
||||
};
|
||||
}, shallowEqual);
|
||||
return !!boardMembership && boardMembership.role === BoardMembershipRoles.EDITOR;
|
||||
});
|
||||
|
||||
const dispatch = useDispatch();
|
||||
const [isEditNameOpened, setIsEditNameOpened] = useState(false);
|
||||
const [handleCardMouseEnter, handleCardMouseLeave] = useContext(BoardShortcutsContext);
|
||||
|
||||
const actionsPopupRef = useRef(null);
|
||||
|
||||
const handleClick = useCallback(() => {
|
||||
if (document.activeElement) {
|
||||
@@ -70,6 +63,33 @@ const Card = React.memo(({ id, isInline }) => {
|
||||
dispatch(push(Paths.CARDS.replace(':id', id)));
|
||||
}, [id, dispatch]);
|
||||
|
||||
const handleMouseEnter = useCallback(() => {
|
||||
handleCardMouseEnter(
|
||||
id,
|
||||
() => {
|
||||
setIsEditNameOpened(true);
|
||||
},
|
||||
(step) => {
|
||||
closePopup();
|
||||
|
||||
actionsPopupRef.current.open({
|
||||
defaultStep: step,
|
||||
});
|
||||
},
|
||||
);
|
||||
}, [id, handleCardMouseEnter]);
|
||||
|
||||
const handleContextMenu = useCallback((event) => {
|
||||
if (!actionsPopupRef.current) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
|
||||
closePopup();
|
||||
actionsPopupRef.current.open();
|
||||
}, []);
|
||||
|
||||
const handleNameEdit = useCallback(() => {
|
||||
setIsEditNameOpened(true);
|
||||
}, []);
|
||||
@@ -78,7 +98,7 @@ const Card = React.memo(({ id, isInline }) => {
|
||||
setIsEditNameOpened(false);
|
||||
}, []);
|
||||
|
||||
const ActionsPopup = usePopup(ActionsStep);
|
||||
const CardActionsPopup = usePopup(CardActionsStep);
|
||||
|
||||
if (isEditNameOpened) {
|
||||
return <EditName cardId={id} onClose={handleEditNameClose} />;
|
||||
@@ -101,33 +121,45 @@ const Card = React.memo(({ id, isInline }) => {
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
const colorLineNode = list.color && (
|
||||
<div
|
||||
className={classNames(
|
||||
styles.wrapper,
|
||||
isDisabled && styles.wrapperDisabled,
|
||||
isHighlightedAsRecent && styles.wrapperRecent,
|
||||
'card',
|
||||
styles.colorLine,
|
||||
globalStyles[`background${upperFirst(camelCase(list.color))}`],
|
||||
)}
|
||||
/>
|
||||
);
|
||||
|
||||
return (
|
||||
<div
|
||||
className={classNames(styles.wrapper, isHighlightedAsRecent && styles.wrapperRecent, 'card')}
|
||||
>
|
||||
{card.isPersisted ? (
|
||||
<>
|
||||
{/* eslint-disable-next-line jsx-a11y/click-events-have-key-events,
|
||||
jsx-a11y/no-static-element-interactions */}
|
||||
<div className={styles.content} onClick={handleClick}>
|
||||
<div
|
||||
className={classNames(styles.content, card.isClosed && styles.contentDisabled)}
|
||||
onMouseEnter={handleMouseEnter}
|
||||
onMouseLeave={handleCardMouseLeave}
|
||||
onClick={handleClick}
|
||||
onContextMenu={handleContextMenu}
|
||||
>
|
||||
<Content cardId={id} />
|
||||
{colorLineNode}
|
||||
</div>
|
||||
{canUseActions && (
|
||||
<ActionsPopup cardId={id} onNameEdit={handleNameEdit}>
|
||||
<CardActionsPopup ref={actionsPopupRef} cardId={id} onNameEdit={handleNameEdit}>
|
||||
<Button className={styles.actionsButton}>
|
||||
<Icon fitted name="pencil" size="small" />
|
||||
</Button>
|
||||
</ActionsPopup>
|
||||
</CardActionsPopup>
|
||||
)}
|
||||
</>
|
||||
) : (
|
||||
<span className={styles.content}>
|
||||
<span className={classNames(styles.content, card.isClosed && styles.contentDisabled)}>
|
||||
<Content cardId={id} />
|
||||
{colorLineNode}
|
||||
</span>
|
||||
)}
|
||||
</div>
|
||||
|
||||
@@ -28,6 +28,11 @@
|
||||
}
|
||||
}
|
||||
|
||||
.colorLine {
|
||||
border-radius: 0 0 3px 3px;
|
||||
height: 4px;
|
||||
}
|
||||
|
||||
.content {
|
||||
cursor: pointer;
|
||||
|
||||
@@ -38,6 +43,11 @@
|
||||
}
|
||||
}
|
||||
|
||||
.contentDisabled {
|
||||
filter: saturate(0.5);
|
||||
opacity: 0.64;
|
||||
}
|
||||
|
||||
.wrapper {
|
||||
background: #fff;
|
||||
border-radius: 3px;
|
||||
@@ -54,11 +64,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
.wrapperDisabled {
|
||||
filter: saturate(0.5);
|
||||
opacity: 0.64;
|
||||
}
|
||||
|
||||
.wrapperRecent:not(:hover) {
|
||||
overflow: hidden;
|
||||
|
||||
|
||||
@@ -96,7 +96,6 @@ const EditName = React.memo(({ cardId, onClose }) => {
|
||||
maxLength={1024}
|
||||
minRows={3}
|
||||
maxRows={8}
|
||||
spellCheck={false}
|
||||
className={styles.field}
|
||||
onKeyDown={handleFieldKeyDown}
|
||||
onChange={handleFieldChange}
|
||||
|
||||
@@ -28,6 +28,7 @@ const InlineContent = React.memo(({ cardId }) => {
|
||||
);
|
||||
|
||||
const card = useSelector((state) => selectCardById(state, cardId));
|
||||
const list = useSelector((state) => selectListById(state, card.listId));
|
||||
const labelIds = useSelector((state) => selectLabelIdsByCardId(state, cardId));
|
||||
|
||||
const notificationsTotal = useSelector((state) =>
|
||||
@@ -35,8 +36,6 @@ const InlineContent = React.memo(({ cardId }) => {
|
||||
);
|
||||
|
||||
const listName = useSelector((state) => {
|
||||
const list = selectListById(state, card.listId);
|
||||
|
||||
if (!list.name) {
|
||||
return null;
|
||||
}
|
||||
@@ -88,7 +87,9 @@ const InlineContent = React.memo(({ cardId }) => {
|
||||
))}
|
||||
</span>
|
||||
)}
|
||||
<span className={classNames(styles.attachments, styles.name)}>
|
||||
<span
|
||||
className={classNames(styles.attachments, styles.name, card.isClosed && styles.nameClosed)}
|
||||
>
|
||||
<div className={styles.hidable}>{card.name}</div>
|
||||
</span>
|
||||
{descriptionText && (
|
||||
|
||||
@@ -50,6 +50,10 @@
|
||||
max-width: 30%;
|
||||
}
|
||||
|
||||
.nameClosed {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
.notification {
|
||||
background: #eb5a46;
|
||||
color: #fff;
|
||||
|
||||
@@ -13,7 +13,7 @@ import selectors from '../../../selectors';
|
||||
import entryActions from '../../../entry-actions';
|
||||
import { startStopwatch, stopStopwatch } from '../../../utils/stopwatch';
|
||||
import { isListArchiveOrTrash } from '../../../utils/record-helpers';
|
||||
import { BoardMembershipRoles, BoardViews, ListTypes } from '../../../constants/Enums';
|
||||
import { BoardMembershipRoles, BoardViews } from '../../../constants/Enums';
|
||||
import TaskList from './TaskList';
|
||||
import DueDateChip from '../DueDateChip';
|
||||
import StopwatchChip from '../StopwatchChip';
|
||||
@@ -114,6 +114,7 @@ const ProjectContent = React.memo(({ cardId }) => {
|
||||
card.description ||
|
||||
card.dueDate ||
|
||||
card.stopwatch ||
|
||||
card.commentsTotal > 0 ||
|
||||
attachmentsTotal > 0 ||
|
||||
notificationsTotal > 0 ||
|
||||
listName;
|
||||
@@ -144,7 +145,7 @@ const ProjectContent = React.memo(({ cardId }) => {
|
||||
|
||||
return (
|
||||
<div className={styles.wrapper}>
|
||||
<div className={styles.name}>{card.name}</div>
|
||||
<div className={classNames(styles.name, card.isClosed && styles.nameClosed)}>{card.name}</div>
|
||||
{coverUrl && (
|
||||
<div className={styles.coverWrapper}>
|
||||
<img src={coverUrl} alt="" className={styles.cover} />
|
||||
@@ -189,7 +190,8 @@ const ProjectContent = React.memo(({ cardId }) => {
|
||||
<DueDateChip
|
||||
value={card.dueDate}
|
||||
size="tiny"
|
||||
withStatus={list.type !== ListTypes.CLOSED && !isListArchiveOrTrash(list)}
|
||||
isCompleted={card.isDueCompleted}
|
||||
withStatus={!card.isClosed}
|
||||
/>
|
||||
</span>
|
||||
)}
|
||||
@@ -226,6 +228,14 @@ const ProjectContent = React.memo(({ cardId }) => {
|
||||
</span>
|
||||
</span>
|
||||
)}
|
||||
{card.commentsTotal > 0 && (
|
||||
<span className={classNames(styles.attachment, styles.attachmentLeft)}>
|
||||
<span className={styles.attachmentContent}>
|
||||
<Icon name="comment outline" />
|
||||
{card.commentsTotal}
|
||||
</span>
|
||||
</span>
|
||||
)}
|
||||
</span>
|
||||
)}
|
||||
{!isCompact && usersNode}
|
||||
|
||||
@@ -84,6 +84,10 @@
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.nameClosed {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
.notification {
|
||||
background: #eb5a46;
|
||||
color: #fff;
|
||||
@@ -101,6 +105,12 @@
|
||||
|
||||
.wrapper {
|
||||
padding: 6px 8px 0;
|
||||
|
||||
&:after {
|
||||
clear: both;
|
||||
content: "";
|
||||
display: table;
|
||||
}
|
||||
}
|
||||
|
||||
:global(.card):hover {
|
||||
|
||||
@@ -40,6 +40,7 @@ const StoryContent = React.memo(({ cardId }) => {
|
||||
const selectAttachmentById = useMemo(() => selectors.makeSelectAttachmentById(), []);
|
||||
|
||||
const card = useSelector((state) => selectCardById(state, cardId));
|
||||
const list = useSelector((state) => selectListById(state, card.listId));
|
||||
const labelIds = useSelector((state) => selectLabelIdsByCardId(state, cardId));
|
||||
const attachmentsTotal = useSelector((state) => selectAttachmentsTotalByCardId(state, cardId));
|
||||
|
||||
@@ -52,8 +53,6 @@ const StoryContent = React.memo(({ cardId }) => {
|
||||
);
|
||||
|
||||
const listName = useSelector((state) => {
|
||||
const list = selectListById(state, card.listId);
|
||||
|
||||
if (!list.name) {
|
||||
return null;
|
||||
}
|
||||
@@ -106,7 +105,9 @@ const StoryContent = React.memo(({ cardId }) => {
|
||||
))}
|
||||
</span>
|
||||
)}
|
||||
<div className={styles.name}>{card.name}</div>
|
||||
<div className={classNames(styles.name, card.isClosed && styles.nameClosed)}>
|
||||
{card.name}
|
||||
</div>
|
||||
{card.description && <div className={styles.descriptionText}>{descriptionText}</div>}
|
||||
{(attachmentsTotal > 0 || notificationsTotal > 0 || listName) && (
|
||||
<span className={styles.attachments}>
|
||||
|
||||
@@ -74,6 +74,10 @@
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.nameClosed {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
.notification {
|
||||
background: #eb5a46;
|
||||
color: #fff;
|
||||
|
||||
@@ -3,24 +3,49 @@
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
import React, { useMemo } from 'react';
|
||||
import React, { useCallback, useMemo } from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import classNames from 'classnames';
|
||||
import { useSelector } from 'react-redux';
|
||||
import { Link } from 'react-router-dom';
|
||||
import { Icon } from 'semantic-ui-react';
|
||||
|
||||
import selectors from '../../../../selectors';
|
||||
import Paths from '../../../../constants/Paths';
|
||||
import Linkify from '../../../common/Linkify';
|
||||
|
||||
import styles from './Task.module.scss';
|
||||
|
||||
const Task = React.memo(({ id }) => {
|
||||
const selectTaskById = useMemo(() => selectors.makeSelectTaskById(), []);
|
||||
const selectLinkedCardById = useMemo(() => selectors.makeSelectCardById(), []);
|
||||
|
||||
const task = useSelector((state) => selectTaskById(state, id));
|
||||
|
||||
const linkedCard = useSelector(
|
||||
(state) => task.linkedCardId && selectLinkedCardById(state, task.linkedCardId),
|
||||
);
|
||||
|
||||
const handleLinkClick = useCallback((event) => {
|
||||
event.stopPropagation();
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<li className={classNames(styles.wrapper, task.isCompleted && styles.wrapperCompleted)}>
|
||||
<Linkify linkStopPropagation>{task.name}</Linkify>
|
||||
<li className={styles.wrapper}>
|
||||
{task.linkedCardId ? (
|
||||
<>
|
||||
<Icon name="exchange" size="small" className={styles.icon} />
|
||||
<span className={classNames(styles.name, task.isCompleted && styles.nameCompleted)}>
|
||||
<Link to={Paths.CARDS.replace(':id', task.linkedCardId)} onClick={handleLinkClick}>
|
||||
{linkedCard ? linkedCard.name : task.name}
|
||||
</Link>
|
||||
</span>
|
||||
</>
|
||||
) : (
|
||||
<span className={classNames(styles.name, task.isCompleted && styles.nameCompleted)}>
|
||||
<Linkify linkStopPropagation>{task.name}</Linkify>
|
||||
</span>
|
||||
)}
|
||||
</li>
|
||||
);
|
||||
});
|
||||
|
||||
@@ -4,6 +4,21 @@
|
||||
*/
|
||||
|
||||
:global(#app) {
|
||||
.icon {
|
||||
color: rgba(9, 30, 66, 0.24);
|
||||
}
|
||||
|
||||
.name {
|
||||
a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
|
||||
.nameCompleted {
|
||||
color: #aaa;
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
.wrapper {
|
||||
display: block;
|
||||
font-size: 12px;
|
||||
@@ -18,9 +33,4 @@
|
||||
left: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
.wrapperCompleted {
|
||||
color: #aaa;
|
||||
text-decoration: line-through;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@ import PropTypes from 'prop-types';
|
||||
import classNames from 'classnames';
|
||||
import { useSelector } from 'react-redux';
|
||||
import { Progress } from 'semantic-ui-react';
|
||||
import { useToggle } from '../../../../lib/hooks';
|
||||
import { useDidUpdate, useToggle } from '../../../../lib/hooks';
|
||||
|
||||
import selectors from '../../../../selectors';
|
||||
import Task from './Task';
|
||||
@@ -16,11 +16,22 @@ import Task from './Task';
|
||||
import styles from './TaskList.module.scss';
|
||||
|
||||
const TaskList = React.memo(({ id }) => {
|
||||
const selectTaskListById = useMemo(() => selectors.makeSelectTaskListById(), []);
|
||||
const selectTasksByTaskListId = useMemo(() => selectors.makeSelectTasksByTaskListId(), []);
|
||||
|
||||
const taskLists = useSelector((state) => selectTaskListById(state, id));
|
||||
const tasks = useSelector((state) => selectTasksByTaskListId(state, id));
|
||||
|
||||
const [isOpened, toggleOpened] = useToggle();
|
||||
const defaultIsOpened = useSelector(
|
||||
(state) => selectors.selectCurrentBoard(state).expandTaskListsByDefault,
|
||||
);
|
||||
|
||||
const [isOpened, toggleOpened] = useToggle(defaultIsOpened);
|
||||
|
||||
const filteredTasks = useMemo(
|
||||
() => (taskLists.hideCompletedTasks ? tasks.filter((task) => !task.isCompleted) : tasks),
|
||||
[taskLists.hideCompletedTasks, tasks],
|
||||
);
|
||||
|
||||
// TODO: move to selector?
|
||||
const completedTasksTotal = useMemo(
|
||||
@@ -30,12 +41,20 @@ const TaskList = React.memo(({ id }) => {
|
||||
|
||||
const handleToggleClick = useCallback(
|
||||
(event) => {
|
||||
if (filteredTasks.length === 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.stopPropagation();
|
||||
toggleOpened();
|
||||
},
|
||||
[toggleOpened],
|
||||
[toggleOpened, filteredTasks.length],
|
||||
);
|
||||
|
||||
useDidUpdate(() => {
|
||||
toggleOpened();
|
||||
}, [defaultIsOpened]);
|
||||
|
||||
if (tasks.length === 0) {
|
||||
return null;
|
||||
}
|
||||
@@ -44,7 +63,7 @@ const TaskList = React.memo(({ id }) => {
|
||||
<>
|
||||
{/* eslint-disable-next-line jsx-a11y/click-events-have-key-events,
|
||||
jsx-a11y/no-static-element-interactions */}
|
||||
<div className={styles.button} onClick={handleToggleClick}>
|
||||
<div className={styles.progressRow} onClick={handleToggleClick}>
|
||||
<span className={styles.progressWrapper}>
|
||||
<Progress
|
||||
autoSuccess
|
||||
@@ -56,14 +75,18 @@ const TaskList = React.memo(({ id }) => {
|
||||
/>
|
||||
</span>
|
||||
<span
|
||||
className={classNames(styles.count, isOpened ? styles.countOpened : styles.countClosed)}
|
||||
className={classNames(
|
||||
styles.count,
|
||||
filteredTasks.length > 0 && styles.countOpenable,
|
||||
filteredTasks.length > 0 && (isOpened ? styles.countOpened : styles.countClosed),
|
||||
)}
|
||||
>
|
||||
{completedTasksTotal}/{tasks.length}
|
||||
</span>
|
||||
</div>
|
||||
{isOpened && (
|
||||
{isOpened && filteredTasks.length > 0 && (
|
||||
<ul className={styles.tasks}>
|
||||
{tasks.map((task) => (
|
||||
{filteredTasks.map((task) => (
|
||||
<Task key={task.id} id={task.id} />
|
||||
))}
|
||||
</ul>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user