Skip to content

Commit 79f4d08

Browse files
authored
Merge branch 'main' into feat/embbeded-block
2 parents ddd3530 + e504f43 commit 79f4d08

File tree

96 files changed

+1613
-845
lines changed

Some content is hidden

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

96 files changed

+1613
-845
lines changed

.dockerignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,4 @@ db.sqlite3
3434

3535
# Frontend
3636
node_modules
37+
.next

.gitattributes

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Set the default behavior for all files
2+
* text=auto eol=lf
3+
4+
# Binary files (should not be modified)
5+
*.png binary
6+
*.jpg binary
7+
*.jpeg binary
8+
*.gif binary
9+
*.ico binary
10+
*.mov binary
11+
*.mp4 binary
12+
*.mp3 binary
13+
*.flv binary
14+
*.fla binary
15+
*.swf binary
16+
*.gz binary
17+
*.zip binary
18+
*.7z binary
19+
*.ttf binary
20+
*.woff binary
21+
*.woff2 binary
22+
*.eot binary
23+
*.pdf binary

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,22 @@
11
## Purpose
22

3-
Description...
3+
Describe the purpose of this pull request.
44

55

66
## Proposal
77

8-
Description...
8+
- [ ] item 1...
9+
- [ ] item 2...
910

10-
- [] item 1...
11-
- [] item 2...
11+
## External contributions
12+
13+
Thank you for your contribution! 🎉
14+
15+
Please ensure the following items are checked before submitting your pull request:
16+
- [ ] I have read and followed the [contributing guidelines](https://github.com/suitenumerique/docs/blob/main/CONTRIBUTING.md)
17+
- [ ] I have read and agreed to the [Code of Conduct](https://github.com/suitenumerique/docs/blob/main/CODE_OF_CONDUCT.md)
18+
- [ ] I have signed off my commits with `git commit --signoff` (DCO compliance)
19+
- [ ] I have signed my commits with my SSH or GPG key (`git commit -S`)
20+
- [ ] My commit messages follow the required format: `<gitmoji>(type) title description`
21+
- [ ] I have added a changelog entry under `## [Unreleased]` section (if noticeable change)
22+
- [ ] I have added corresponding tests for new features or bug fixes (if applicable)

.github/workflows/crowdin_download.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
install-dependencies:
1111
uses: ./.github/workflows/dependencies.yml
1212
with:
13-
node_version: '20.x'
13+
node_version: '22.x'
1414
with-front-dependencies-installation: true
1515

1616
synchronize-with-crowdin:

.github/workflows/crowdin_upload.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
install-dependencies:
1111
uses: ./.github/workflows/dependencies.yml
1212
with:
13-
node_version: '20.x'
13+
node_version: '22.x'
1414
with-front-dependencies-installation: true
1515
with-build_mails: true
1616

.github/workflows/dependencies.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ on:
55
inputs:
66
node_version:
77
required: false
8-
default: '20.x'
8+
default: '22.x'
99
type: string
1010
with-front-dependencies-installation:
1111
type: boolean

.github/workflows/impress-frontend.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
install-dependencies:
1414
uses: ./.github/workflows/dependencies.yml
1515
with:
16-
node_version: '20.x'
16+
node_version: '22.x'
1717
with-front-dependencies-installation: true
1818

1919
test-front:
@@ -26,7 +26,7 @@ jobs:
2626
- name: Setup Node.js
2727
uses: actions/setup-node@v4
2828
with:
29-
node-version: "20.x"
29+
node-version: "22.x"
3030

3131
- name: Restore the frontend cache
3232
uses: actions/cache@v4
@@ -48,7 +48,7 @@ jobs:
4848
- name: Setup Node.js
4949
uses: actions/setup-node@v4
5050
with:
51-
node-version: "20.x"
51+
node-version: "22.x"
5252
- name: Restore the frontend cache
5353
uses: actions/cache@v4
5454
with:
@@ -70,7 +70,7 @@ jobs:
7070
- name: Setup Node.js
7171
uses: actions/setup-node@v4
7272
with:
73-
node-version: "20.x"
73+
node-version: "22.x"
7474

7575
- name: Restore the frontend cache
7676
uses: actions/cache@v4
@@ -86,7 +86,7 @@ jobs:
8686
run: cd src/frontend/apps/e2e && yarn install --frozen-lockfile && yarn install-playwright chromium
8787

8888
- name: Start Docker services
89-
run: make bootstrap FLUSH_ARGS='--no-input' cache=
89+
run: make bootstrap-e2e FLUSH_ARGS='--no-input'
9090

9191
- name: Run e2e tests
9292
run: cd src/frontend/ && yarn e2e:test --project='chromium'
@@ -109,7 +109,7 @@ jobs:
109109
- name: Setup Node.js
110110
uses: actions/setup-node@v4
111111
with:
112-
node-version: "20.x"
112+
node-version: "22.x"
113113

114114
- name: Restore the frontend cache
115115
uses: actions/cache@v4
@@ -125,7 +125,7 @@ jobs:
125125
run: cd src/frontend/apps/e2e && yarn install --frozen-lockfile && yarn install-playwright firefox webkit chromium
126126

127127
- name: Start Docker services
128-
run: make bootstrap FLUSH_ARGS='--no-input' cache=
128+
run: make bootstrap-e2e FLUSH_ARGS='--no-input'
129129

130130
- name: Run e2e tests
131131
run: cd src/frontend/ && yarn e2e:test --project=firefox --project=webkit

CHANGELOG.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,27 @@ and this project adheres to
88

99
## [Unreleased]
1010

11+
### Added
12+
13+
- ✨(frontend) add customization for translations #857
14+
- 📝(project) add troubleshoot doc #1066
15+
- 📝(project) add system-requirement doc #1066
16+
17+
### Changed
18+
19+
- 📌(yjs) stop pinning node to minor version on yjs docker image #1005
20+
- 🧑‍💻(docker) add .next to .dockerignore #1055
21+
- 🧑‍💻(docker) handle frontend development images with docker compose #1033
22+
- 🧑‍💻(docker) add y-provider config to development environment #1057
23+
24+
### Fixed
25+
26+
-🐛(frontend) table of content disappearing #982
27+
-🐛(frontend) fix multiple EmojiPicker #1012
28+
-🐛(frontend) fix meta title #1017
29+
-🔧(git) set LF line endings for all text files #1032
30+
31+
1132
## [3.3.0] - 2025-05-06
1233

1334
### Added

Makefile

Lines changed: 47 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ DOCKER_UID = $(shell id -u)
3939
DOCKER_GID = $(shell id -g)
4040
DOCKER_USER = $(DOCKER_UID):$(DOCKER_GID)
4141
COMPOSE = DOCKER_USER=$(DOCKER_USER) docker compose
42+
COMPOSE_E2E = DOCKER_USER=$(DOCKER_USER) docker compose -f compose.yml -f compose-e2e.yml
4243
COMPOSE_EXEC = $(COMPOSE) exec
4344
COMPOSE_EXEC_APP = $(COMPOSE_EXEC) app-dev
4445
COMPOSE_RUN = $(COMPOSE) run --rm
@@ -74,22 +75,39 @@ create-env-files: \
7475
env.d/development/kc_postgresql
7576
.PHONY: create-env-files
7677

77-
bootstrap: ## Prepare Docker images for the project
78-
bootstrap: \
78+
pre-bootstrap: \
7979
data/media \
8080
data/static \
81-
create-env-files \
82-
build \
81+
create-env-files
82+
.PHONY: pre-bootstrap
83+
84+
post-bootstrap: \
8385
migrate \
8486
demo \
8587
back-i18n-compile \
8688
mails-install \
87-
mails-build \
89+
mails-build
90+
.PHONY: post-bootstrap
91+
92+
93+
bootstrap: ## Prepare Docker developmentimages for the project
94+
bootstrap: \
95+
pre-bootstrap \
96+
build \
97+
post-bootstrap \
8898
run
8999
.PHONY: bootstrap
90100

101+
bootstrap-e2e: ## Prepare Docker production images to be used for e2e tests
102+
bootstrap-e2e: \
103+
pre-bootstrap \
104+
build-e2e \
105+
post-bootstrap \
106+
run-e2e
107+
.PHONY: bootstrap-e2e
108+
91109
# -- Docker/compose
92-
build: cache ?= --no-cache
110+
build: cache ?=
93111
build: ## build the project containers
94112
@$(MAKE) build-backend cache=$(cache)
95113
@$(MAKE) build-yjs-provider cache=$(cache)
@@ -103,16 +121,23 @@ build-backend: ## build the app-dev container
103121

104122
build-yjs-provider: cache ?=
105123
build-yjs-provider: ## build the y-provider container
106-
@$(COMPOSE) build y-provider $(cache)
124+
@$(COMPOSE) build y-provider-development $(cache)
107125
.PHONY: build-yjs-provider
108126

109127
build-frontend: cache ?=
110128
build-frontend: ## build the frontend container
111-
@$(COMPOSE) build frontend $(cache)
129+
@$(COMPOSE) build frontend-development $(cache)
112130
.PHONY: build-frontend
113131

132+
build-e2e: cache ?=
133+
build-e2e: ## build the e2e container
134+
@$(MAKE) build-backend cache=$(cache)
135+
@$(COMPOSE_E2E) build frontend $(cache)
136+
@$(COMPOSE_E2E) build y-provider $(cache)
137+
.PHONY: build-e2e
138+
114139
down: ## stop and remove containers, networks, images, and volumes
115-
@$(COMPOSE) down
140+
@$(COMPOSE_E2E) down
116141
.PHONY: down
117142

118143
logs: ## display app-dev logs (follow mode)
@@ -121,22 +146,30 @@ logs: ## display app-dev logs (follow mode)
121146

122147
run-backend: ## Start only the backend application and all needed services
123148
@$(COMPOSE) up --force-recreate -d celery-dev
124-
@$(COMPOSE) up --force-recreate -d y-provider
149+
@$(COMPOSE) up --force-recreate -d y-provider-development
125150
@$(COMPOSE) up --force-recreate -d nginx
126151
.PHONY: run-backend
127152

128153
run: ## start the wsgi (production) and development server
129154
run:
130155
@$(MAKE) run-backend
131-
@$(COMPOSE) up --force-recreate -d frontend
156+
@$(COMPOSE) up --force-recreate -d frontend-development
132157
.PHONY: run
133158

159+
run-e2e: ## start the e2e server
160+
run-e2e:
161+
@$(MAKE) run-backend
162+
@$(COMPOSE_E2E) stop y-provider-development
163+
@$(COMPOSE_E2E) up --force-recreate -d frontend
164+
@$(COMPOSE_E2E) up --force-recreate -d y-provider
165+
.PHONY: run-e2e
166+
134167
status: ## an alias for "docker compose ps"
135-
@$(COMPOSE) ps
168+
@$(COMPOSE_E2E) ps
136169
.PHONY: status
137170

138171
stop: ## stop the development server using Docker
139-
@$(COMPOSE) stop
172+
@$(COMPOSE_E2E) stop
140173
.PHONY: stop
141174

142175
# -- Backend
@@ -315,7 +348,7 @@ frontend-lint: ## run the frontend linter
315348
.PHONY: frontend-lint
316349

317350
run-frontend-development: ## Run the frontend in development mode
318-
@$(COMPOSE) stop frontend
351+
@$(COMPOSE) stop frontend frontend-development
319352
cd $(PATH_FRONT_IMPRESS) && yarn dev
320353
.PHONY: run-frontend-development
321354

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,11 +93,11 @@ The easiest way to start working on the project is to use [GNU Make](https://www
9393
$ make bootstrap FLUSH_ARGS='--no-input'
9494
```
9595

96-
This command builds the `app` container, installs dependencies, performs database migrations and compiles translations. It's a good idea to use this command each time you are pulling code from the project repository to avoid dependency-related or migration-related issues.
96+
This command builds the `app-dev` and `frontend-dev` containers, installs dependencies, performs database migrations and compiles translations. It's a good idea to use this command each time you are pulling code from the project repository to avoid dependency-related or migration-related issues.
9797

9898
Your Docker services should now be up and running 🎉
9999

100-
You can access to the project by going to <http://localhost:3000>.
100+
You can access the project by going to <http://localhost:3000>.
101101

102102
You will be prompted to log in. The default credentials are:
103103

@@ -106,7 +106,7 @@ username: impress
106106
password: impress
107107
```
108108

109-
📝 Note that if you need to run them afterwards, you can use the eponym Make rule:
109+
📝 Note that if you need to run them afterwards, you can use the eponymous Make rule:
110110

111111
```shellscript
112112
$ make run

UPGRADE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ the following command inside your docker container:
1818

1919
## [3.3.0] - 2025-05-22
2020

21-
⚠️ 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/docs/env.md) for more information.
21+
⚠️ 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.
2222

2323
The footer is now configurable from a customization file. To override the default one, you can
2424
use the `THEME_CUSTOMIZATION_FILE_PATH` environment variable to point to your customization file.

bin/_config.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ REPO_DIR="$(cd "$( dirname "${BASH_SOURCE[0]}" )/.." && pwd)"
66
UNSET_USER=0
77

88
TERRAFORM_DIRECTORY="./env.d/terraform"
9-
COMPOSE_FILE="${REPO_DIR}/docker-compose.yml"
9+
COMPOSE_FILE="${REPO_DIR}/compose.yml"
1010

1111

1212
# _set_user: set (or unset) default user id used to run docker commands

compose-e2e.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
services:
2+
3+
frontend:
4+
user: "${DOCKER_USER:-1000}"
5+
build:
6+
context: .
7+
dockerfile: ./src/frontend/Dockerfile
8+
target: frontend-production
9+
args:
10+
API_ORIGIN: "http://localhost:8071"
11+
PUBLISH_AS_MIT: "false"
12+
SW_DEACTIVATED: "true"
13+
image: impress:frontend-production
14+
ports:
15+
- "3000:3000"
16+
17+
y-provider:
18+
user: ${DOCKER_USER:-1000}
19+
build:
20+
context: .
21+
dockerfile: ./src/frontend/servers/y-provider/Dockerfile
22+
target: y-provider
23+
image: impress:y-provider-production
24+
restart: unless-stopped
25+
env_file:
26+
- env.d/development/common
27+
ports:
28+
- "4444:4444"

0 commit comments

Comments
 (0)