Skip to content

Commit fb06c96

Browse files
authored
Merge branch 'main' into move_email_to_celery
2 parents ce02929 + 21ee38c commit fb06c96

File tree

188 files changed

+5366
-5194
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

188 files changed

+5366
-5194
lines changed

.github/workflows/crowdin_upload.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,10 @@ jobs:
2323
uses: actions/checkout@v4
2424
# Backend i18n
2525
- name: Install Python
26-
uses: actions/setup-python@v3
26+
uses: actions/setup-python@v5
2727
with:
2828
python-version: "3.13.3"
29+
cache: "pip"
2930
- name: Upgrade pip and setuptools
3031
run: pip install --upgrade pip setuptools
3132
- name: Install development dependencies

.github/workflows/impress-frontend.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,3 +136,53 @@ jobs:
136136
name: playwright-other-report
137137
path: src/frontend/apps/e2e/report/
138138
retention-days: 7
139+
140+
bundle-size-check:
141+
runs-on: ubuntu-latest
142+
needs: install-dependencies
143+
if: github.event_name == 'pull_request'
144+
permissions:
145+
contents: read
146+
pull-requests: write
147+
issues: write
148+
steps:
149+
- name: Checkout repository
150+
uses: actions/checkout@v4
151+
152+
- name: Detect relevant changes
153+
id: changes
154+
uses: dorny/paths-filter@v2
155+
with:
156+
filters: |
157+
lock:
158+
- 'src/frontend/**/yarn.lock'
159+
app:
160+
- 'src/frontend/apps/impress/**'
161+
162+
- name: Restore the frontend cache
163+
uses: actions/cache@v4
164+
with:
165+
path: "src/frontend/**/node_modules"
166+
key: front-node_modules-${{ hashFiles('src/frontend/**/yarn.lock') }}
167+
fail-on-cache-miss: true
168+
169+
- name: Setup Node.js
170+
if: steps.changes.outputs.lock == 'true' || steps.changes.outputs.app == 'true'
171+
uses: actions/setup-node@v4
172+
with:
173+
node-version: "22.x"
174+
175+
- name: Check bundle size changes
176+
if: steps.changes.outputs.lock == 'true' || steps.changes.outputs.app == 'true'
177+
uses: preactjs/compressed-size-action@v2
178+
with:
179+
repo-token: "${{ secrets.GITHUB_TOKEN }}"
180+
build-script: "build"
181+
pattern: "./out/**/*.{css,js,html}"
182+
exclude: "{**/*.map,**/node_modules/**}"
183+
minimum-change-threshold: 500
184+
compression: "gzip"
185+
cwd: "./src/frontend/apps/impress"
186+
show-total: true
187+
strip-hash: "\\b\\w+\\."
188+
omit-unchanged: true

.github/workflows/impress.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,9 +89,10 @@ jobs:
8989
- name: Checkout repository
9090
uses: actions/checkout@v2
9191
- name: Install Python
92-
uses: actions/setup-python@v3
92+
uses: actions/setup-python@v5
9393
with:
9494
python-version: "3.13.3"
95+
cache: "pip"
9596
- name: Upgrade pip and setuptools
9697
run: pip install --upgrade pip setuptools
9798
- name: Install development dependencies
@@ -184,9 +185,10 @@ jobs:
184185
mc version enable impress/impress-media-storage"
185186
186187
- name: Install Python
187-
uses: actions/setup-python@v3
188+
uses: actions/setup-python@v5
188189
with:
189190
python-version: "3.13.3"
191+
cache: "pip"
190192

191193
- name: Install development dependencies
192194
run: pip install --user .[dev]

CHANGELOG.md

Lines changed: 34 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,38 @@ and this project adheres to
1010

1111
### Added
1212

13-
- ✨(helm) Service Account support for K8s Resources in Helm Charts #778
14-
- ✨(backend) allow masking documents from the list view #1171
13+
- 👷(CI) add bundle size check job #1268
14+
15+
### Changed
16+
17+
- ♻️(docs-app) Switch from Jest tests to Vitest #1269
18+
- ⚡️(frontend) improve accessibility:
19+
- #1248
20+
- #1235
21+
- #1275
22+
- #1255
23+
- #1262
24+
- #1244
25+
- #1270
26+
- #1282
27+
- ♻️(backend) fallback to email identifier when no name #1298
28+
- 🐛(backend) allow ASCII characters in user sub field #1295
29+
30+
### Fixed
31+
32+
- 🐛(makefile) Windows compatibility fix for Docker volume mounting #1264
33+
- 🐛(minio) fix user permission error with Minio and Windows #1264
34+
- 🐛(frontend) fix export when quote block and inline code #1319
35+
36+
## [3.5.0] - 2025-07-31
37+
38+
### Added
39+
40+
- ✨(helm) Service Account support for K8s Resources in Helm Charts #780
41+
- ✨(backend) allow masking documents from the list view #1172
1542
- ✨(frontend) subdocs can manage link reach #1190
1643
- ✨(frontend) add duplicate action to doc tree #1175
44+
- ✨(frontend) Interlinking doc #904
1745
- ✨(frontend) add multi columns support for editor #1219
1846

1947
### Changed
@@ -23,6 +51,7 @@ and this project adheres to
2351
- 🔧(project) change env.d system by using local files #1200
2452
- ⚡️(frontend) improve tree stability #1207
2553
- ⚡️(frontend) improve accessibility #1232
54+
- 🛂(frontend) block drag n drop when not desktop #1239
2655
- ⚡(backend) move email sending to celery
2756

2857
### Fixed
@@ -31,6 +60,7 @@ and this project adheres to
3160
- 🐛(frontend) fix empty left panel after deleting root doc #1197
3261
- 🐛(helm) charts generate invalid YAML for collaboration API / WS #890
3362
- 🐛(frontend) 401 redirection overridden #1214
63+
- 🐛(frontend) include root parent in search #1243
3464

3565
## [3.4.2] - 2025-07-18
3666

@@ -674,7 +704,8 @@ and this project adheres to
674704
- ✨(frontend) Coming Soon page (#67)
675705
- 🚀 Impress, project to manage your documents easily and collaboratively.
676706

677-
[unreleased]: https://github.com/suitenumerique/docs/compare/v3.4.2...main
707+
[unreleased]: https://github.com/suitenumerique/docs/compare/v3.5.0...main
708+
[v3.5.0]: https://github.com/suitenumerique/docs/releases/v3.5.0
678709
[v3.4.2]: https://github.com/suitenumerique/docs/releases/v3.4.2
679710
[v3.4.1]: https://github.com/suitenumerique/docs/releases/v3.4.1
680711
[v3.4.0]: https://github.com/suitenumerique/docs/releases/v3.4.0

Makefile

Lines changed: 75 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,13 @@ DB_PORT = 5432
3535

3636
# -- Docker
3737
# Get the current user ID to use for docker run and docker exec commands
38-
DOCKER_UID = $(shell id -u)
39-
DOCKER_GID = $(shell id -g)
40-
DOCKER_USER = $(DOCKER_UID):$(DOCKER_GID)
38+
ifeq ($(OS),Windows_NT)
39+
DOCKER_USER := 0:0 # run containers as root on Windows
40+
else
41+
DOCKER_UID := $(shell id -u)
42+
DOCKER_GID := $(shell id -g)
43+
DOCKER_USER := $(DOCKER_UID):$(DOCKER_GID)
44+
endif
4145
COMPOSE = DOCKER_USER=$(DOCKER_USER) docker compose
4246
COMPOSE_E2E = DOCKER_USER=$(DOCKER_USER) docker compose -f compose.yml -f compose-e2e.yml
4347
COMPOSE_EXEC = $(COMPOSE) exec
@@ -48,7 +52,7 @@ COMPOSE_RUN_CROWDIN = $(COMPOSE_RUN) crowdin crowdin
4852

4953
# -- Backend
5054
MANAGE = $(COMPOSE_RUN_APP) python manage.py
51-
MAIL_YARN = $(COMPOSE_RUN) -w /app/src/mail node yarn
55+
MAIL_YARN = $(COMPOSE_RUN) -w //app/src/mail node yarn
5256

5357
# -- Frontend
5458
PATH_FRONT = ./src/frontend
@@ -89,13 +93,77 @@ post-bootstrap: \
8993
mails-build
9094
.PHONY: post-bootstrap
9195

92-
93-
bootstrap: ## Prepare Docker developmentimages for the project
96+
pre-beautiful-bootstrap: ## Display a welcome message before bootstrap
97+
ifeq ($(OS),Windows_NT)
98+
@echo ""
99+
@echo "================================================================================"
100+
@echo ""
101+
@echo " Welcome to Docs - Collaborative Text Editing from La Suite!"
102+
@echo ""
103+
@echo " This will set up your development environment with:"
104+
@echo " - Docker containers for all services"
105+
@echo " - Database migrations and static files"
106+
@echo " - Frontend dependencies and build"
107+
@echo " - Environment configuration files"
108+
@echo ""
109+
@echo " Services will be available at:"
110+
@echo " - Frontend: http://localhost:3000"
111+
@echo " - API: http://localhost:8071"
112+
@echo " - Admin: http://localhost:8071/admin"
113+
@echo ""
114+
@echo "================================================================================"
115+
@echo ""
116+
@echo "Starting bootstrap process..."
117+
else
118+
@echo "$(BOLD)"
119+
@echo "╔══════════════════════════════════════════════════════════════════════════════╗"
120+
@echo "║ ║"
121+
@echo "║ 🚀 Welcome to Docs - Collaborative Text Editing from La Suite ! 🚀 ║"
122+
@echo "║ ║"
123+
@echo "║ This will set up your development environment with : ║"
124+
@echo "║ • Docker containers for all services ║"
125+
@echo "║ • Database migrations and static files ║"
126+
@echo "║ • Frontend dependencies and build ║"
127+
@echo "║ • Environment configuration files ║"
128+
@echo "║ ║"
129+
@echo "║ Services will be available at: ║"
130+
@echo "║ • Frontend: http://localhost:3000 ║"
131+
@echo "║ • API: http://localhost:8071 ║"
132+
@echo "║ • Admin: http://localhost:8071/admin ║"
133+
@echo "║ ║"
134+
@echo "╚══════════════════════════════════════════════════════════════════════════════╝"
135+
@echo "$(RESET)"
136+
@echo "$(GREEN)Starting bootstrap process...$(RESET)"
137+
endif
138+
@echo ""
139+
.PHONY: pre-beautiful-bootstrap
140+
141+
post-beautiful-bootstrap: ## Display a success message after bootstrap
142+
@echo ""
143+
ifeq ($(OS),Windows_NT)
144+
@echo "Bootstrap completed successfully!"
145+
@echo ""
146+
@echo "Next steps:"
147+
@echo " - Visit http://localhost:3000 to access the application"
148+
@echo " - Run 'make help' to see all available commands"
149+
else
150+
@echo "$(GREEN)🎉 Bootstrap completed successfully!$(RESET)"
151+
@echo ""
152+
@echo "$(BOLD)Next steps:$(RESET)"
153+
@echo " • Visit http://localhost:3000 to access the application"
154+
@echo " • Run 'make help' to see all available commands"
155+
endif
156+
@echo ""
157+
.PHONY: post-beautiful-bootstrap
158+
159+
bootstrap: ## Prepare the project for local development
94160
bootstrap: \
161+
pre-beautiful-bootstrap \
95162
pre-bootstrap \
96163
build \
97164
post-bootstrap \
98-
run
165+
run \
166+
post-beautiful-bootstrap
99167
.PHONY: bootstrap
100168

101169
bootstrap-e2e: ## Prepare Docker production images to be used for e2e tests

README.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,23 @@ Docs is a collaborative text editor designed to address common challenges in kno
4949
* 📚 Turn your team's collaborative work into organized knowledge with Subpages.
5050

5151
### Self-host
52-
🚀 Docs is easy to install on your own servers
5352

54-
Available methods: Helm chart, Nix package
55-
56-
In the works: Docker Compose, YunoHost
57-
58-
⚠️ For some advanced features (ex: Export as PDF) Docs relies on XL packages from BlockNote. These are licenced under AGPL-3.0 and are not MIT compatible. You can perfectly use Docs without these packages by setting the environment variable `PUBLISH_AS_MIT` to true. That way you'll build an image of the application without the features that are not MIT compatible. Read the [environment variables documentation](/docs/env.md) for more information.
53+
#### 🚀 Docs is easy to install on your own servers
54+
We use Kubernetes for our [production instance](https://docs.numerique.gouv.fr/) but also support Docker Compose. The community contributed a couple other methods (Nix, YunoHost etc.) check out the [docs](/docs/installation/README.md) to get detailed instructions and examples.
55+
56+
#### 🌍 Known instances
57+
We hope to see many more, here is an incomplete list of public Docs instances (urls listed in alphabetical order). Feel free to make a PR to add ones that are not listed below🙏
58+
59+
| | | |
60+
| --- | --- | ------- |
61+
| Url | Org | Public |
62+
| docs.numerique.gouv.fr | DINUM | French public agents working for the central administration and the extended public sphere. ProConnect is required to login in or sign up|
63+
| docs.suite.anct.gouv.fr | ANCT | French public agents working for the territorial administration and the extended public sphere. ProConnect is required to login in or sign up|
64+
| notes.demo.opendesk.eu | ZenDiS | Demo instance of OpenDesk. Request access to get credentials |
65+
| notes.liiib.re | lasuite.coop | Free and open demo to all. Content and accounts are reset after one month |
66+
67+
#### ⚠️ Advanced features
68+
For some advanced features (ex: Export as PDF) Docs relies on XL packages from BlockNote. These are licenced under GPL and are not MIT compatible. You can perfectly use Docs without these packages by setting the environment variable `PUBLISH_AS_MIT` to true. That way you'll build an image of the application without the features that are not MIT compatible. Read the [environment variables documentation](/docs/env.md) for more information.
5969

6070
## Getting started 🔧
6171

bin/_config.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,10 @@ function _set_user() {
3838
# options: docker compose command options
3939
# ARGS : docker compose command arguments
4040
function _docker_compose() {
41+
# Set DOCKER_USER for Windows compatibility with MinIO
42+
if [[ "$OSTYPE" == "msys" || "$OSTYPE" == "cygwin" || -n "${WSL_DISTRO_NAME:-}" ]]; then
43+
export DOCKER_USER="0:0"
44+
fi
4145

4246
echo "🐳(compose) file: '${COMPOSE_FILE}'"
4347
docker compose \

docker/files/production/etc/nginx/conf.d/default.conf.template

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ server {
1111
server_name localhost;
1212
charset utf-8;
1313

14+
# increase max upload size
15+
client_max_body_size 10m;
16+
1417
# Disables server version feedback on pages and in headers
1518
server_tokens off;
1619

@@ -68,7 +71,7 @@ server {
6871
proxy_set_header Host $host;
6972
}
7073

71-
location /collaboration/api/ {
74+
location /collaboration/api/ {
7275
# Collaboration server
7376
proxy_pass http://${YPROVIDER_HOST}:4444;
7477
proxy_set_header Host $host;
@@ -95,7 +98,7 @@ server {
9598

9699
add_header Content-Security-Policy "default-src 'none'" always;
97100
}
98-
101+
99102
location /media-auth {
100103
proxy_pass http://docs_backend/api/v1.0/documents/media-auth/;
101104
proxy_set_header X-Forwarded-Proto https;
@@ -109,4 +112,4 @@ server {
109112
proxy_set_header Content-Length "";
110113
proxy_set_header X-Original-Method $request_method;
111114
}
112-
}
115+
}

docs/env.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,9 +135,9 @@ NODE_ENV=production NEXT_PUBLIC_PUBLISH_AS_MIT=false yarn build
135135
| PUBLISH_AS_MIT | Removes packages whose licences are incompatible with the MIT licence (see below) | true |
136136

137137
Packages with licences incompatible with the MIT licence:
138-
* `xl-docx-exporter`: [AGPL-3.0](https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-docx-exporter/LICENSE),
139-
* `xl-pdf-exporter`: [AGPL-3.0](https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-pdf-exporter/LICENSE),
140-
* `xl-multi-column`: [AGPL-3.0](https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-multi-column/LICENSE).
138+
* `xl-docx-exporter`: [GPL](https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-docx-exporter/LICENSE),
139+
* `xl-pdf-exporter`: [GPL](https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-pdf-exporter/LICENSE),
140+
* `xl-multi-column`: [GPL](https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-multi-column/LICENSE).
141141

142142
In `.env.development`, `PUBLISH_AS_MIT` is set to `false`, allowing developers to test Docs with all its features.
143143

0 commit comments

Comments
 (0)