Commit Graph

1790 Commits

Author SHA1 Message Date
Anthony LC
ae9555284d (e2e) remove some flakiness
Service worker added some flakiness, we
activate the sw only if not from the CI.
We add as well the email of the user added in a
doc to the toast message. This way we can check
if the user was added correctly, this will remove
some flakiness in some tests.
2024-06-14 12:26:04 +02:00
Anthony LC
14a91a5698 🐛(frontend) mismatch between yjs dependency
Mismatch between yjs dependency, we set the
dependency globally to not have this problem
anymore.
2024-06-14 12:26:04 +02:00
Anthony LC
9f6dac53d4 (frontend) add offline mode support
Add a offline mode support from a service worker.
The service worker will cache the assets and the
visited pages to be able to work offline.
Created a fallback page for when the user is offline
and tries to access a page that is not cached.
2024-06-14 12:26:04 +02:00
Anthony LC
5ba35dbc1d ♻️(frontend) improve the ui error and message info ui
Improve the ui error and message info ui:
- Can use a icon in TextErrors component
- use mode the Alert component to display message info
2024-06-14 11:50:13 +02:00
Anthony LC
62098ec753 🐛(frontend) fix bug multi ws connection
In collaborative mode, only the first document
connected was being shared. This was due to the
fact that the webrtc server was managing only
one connection at a time. This commit fixes this
bug by managing multiple connections.
2024-06-13 12:20:23 +02:00
Jacques ROUSSEL
9e318f88be 🐛(CI) improve submodule
- remove deplucate declaration
- simplify helmfile
- use symlink
2024-06-11 10:40:39 +02:00
Anthony LC
63b565e720 💄(frontend) max img width with container width
The img could be much bigger than the page width
in a generated pdf. We limit the max img width
to the container width.
2024-06-10 13:28:38 +02:00
Anthony LC
e7fe153a81 🐛(frontend) fix break line on firefox
On firefox with collaborative mode, the last
upgrade of ProseMirror added a new line when
a another user was typing. This commit fixes this
issue.
2024-06-10 13:28:38 +02:00
Anthony LC
8e0850b13e 🐛(app-desk) fix fetchPriority warning
The upgrade to react@18.3.1 has a compatibility
issue with next@14.2.3. It creates a error warning
about the fetchPriority prop. This commit fixes the
issue by downgrading react to 18.2.0 as it was
before the last upgrade.
The next.js team is already aware of the issue and
it will be fixed in the next release.
2024-06-10 13:28:38 +02:00
Anthony LC
8fb18ed186 (frontend) add "@testing-library/dom
Recent update of @testing-library/react requires
@testing-library/dom to be installed as well.
2024-06-10 13:28:38 +02:00
renovate[bot]
bec6ff3d22 ⬆️(dependencies) update js dependencies 2024-06-10 13:28:38 +02:00
Anthony LC
0571aaabce ️(CI) improve docker build cache
Improve the caching by using docker buildx,
it should speed up the build process by using the
cache from the previous build.
2024-06-07 15:01:47 +02:00
Jacques ROUSSEL
e4bed84343 🐛(CI) fix ci issue
- fix get secret in ci
2024-06-07 14:05:51 +02:00
Jacques ROUSSEL
37f02893ed 🐛(CI) purge secret from repository
- Remove *.enc.*
- Adapt helmfile
- Adapt CI
2024-06-07 10:11:19 +02:00
Anthony LC
4e4e2e23e3 ️(e2e) unique login between tests
We will cache the login token in the browser
storage and reuse it between tests.
This will speed up the tests and reduce the
load on the server.
2024-06-06 22:31:43 +02:00
Anthony LC
b68015852c 🔊(changelog) add recents changes
Add some recents changes:
- (frontend) manage members (update role / list / remove)
- (frontend) change logo
- (frontend) pdf has title doc
- Fix the break line when generate PDF
2024-06-06 16:09:07 +02:00
Anthony LC
2f79d03acc ⬇️(frontend) downgrade @testing-library/react@16.0.0
downgrade @testing-library/react@16.0.0 to
@testing-library/react@15.0.7.

Some modules are not available in the latest
version, their documentation is not available yet.
2024-06-06 16:09:07 +02:00
Anthony LC
8762a7bc92 ♻️(frontend) adapt BlockNote to the last version
A recent relase of the BlockNote component
has changed the way it is used. This commit
adapts the BlockNoteEditor and BlockNoteToolbar
components to the new version of the BlockNote.
2024-06-06 16:09:07 +02:00
Anthony LC
589b0eab32 🐛(app-desk) fix fetchPriority warning
The upgrade to react@18.3.1 has a compatibility
issue with next@14.2.3. It creates a error warning
about the fetchPriority prop. This commit fixes the
issue by downgrading react to 18.2.0 as it was
before the last upgrade.
The next.js team is already aware of the issue and
it will be fixed in the next release.
2024-06-06 16:09:07 +02:00
renovate[bot]
44f4a37814 ⬆️(dependencies) update js dependencies 2024-06-06 16:09:07 +02:00
Anthony LC
6c76f7faab ♻️(frontend) improve html for pdf
Blocknote json to html is not perfect, so we need
to improve it to provide a better html for
the pdf generation.
It is the first step to improve the html,
we will continue to improve it in the future.
We have now the break line.
It is e2e tested so if blocknote change the conversion
we will know it.
2024-06-06 12:43:25 +02:00
Anthony LC
201d776d1b ♻️(frontend) doc title as title for pdf export
Our pdf export was named impress-document.pdf,
now it is named after the document title.
We sanitize the title by removing special characters,
replacing spaces with underscores and putting it
in lowercase.
2024-06-06 12:43:25 +02:00
Anthony LC
e7f2317b41 ♻️(backend) simplify the template
For the first version, we will use a simple template.
Only the gouv logo will be displayed.
2024-06-06 12:43:25 +02:00
Anthony LC
206c7f11ae (e2e) flaky saves the doc when we quit pages
Stop to check "saves the doc when we quit pages"
with webkit browser. It is flaky.
2024-06-06 12:43:25 +02:00
Anthony LC
615f92ded3 💄(frontend) change logo with the pad one
Change the logo with the pad one.
2024-06-06 12:43:25 +02:00
Anthony LC
da3ad91283 ♻️(frontend) add api versionning per request
We were using the version of the api from the
.env file, but we could have different versions
of the api in the same app. So we now use the
version from the request.
2024-06-06 12:43:25 +02:00
Anthony LC
197b16c5d0 (frontend) add modal to delete a member
Add modal to delete a member.
2024-06-05 21:50:30 +02:00
Anthony LC
cce0331b68 (frontend) add modal to update role of a member
Add modal to update role of a member.
2024-06-05 21:50:30 +02:00
Anthony LC
380ac0cbcf (frontend) add members grid
Add members grid to display all members
of a doc and their roles.
2024-06-05 21:50:30 +02:00
Anthony LC
1779b7bab4 🏷️(frontend) adapt accesses types
We updated the types of the accesses to
get more information about the accesses.
2024-06-05 21:50:30 +02:00
Anthony LC
7b5698a370 👔(backend) object user on DocumentAccessSerializer
user field was displaying the userid, but we
need to return the user object on the
DocumentAccessSerializer, so we can show the
user email on the frontend.
We add the user_id field in write_only mode, so
we can keep create and update.
2024-06-05 21:50:30 +02:00
Anthony LC
f039b2aa3b 🌐(frontend) legal pages translatable
Makes the legal pages translatable.
2024-06-05 10:37:02 +02:00
Anthony LC
8531e0dd08 🐛(i18n) comma in keys
Having a comma in the keys broke the parser.
This commit allows the comma in keys.
2024-06-05 10:37:02 +02:00
Anthony LC
e2586b1d8e 🚚(frontend) move to members/members-add
Move addUsers to members/members-add.
Rename some of the occurences of user to member.
2024-05-31 11:51:29 +02:00
Anthony LC
327a5f2ed4 🤡(demo) generate dummy user
To search users we need to have some dummy data users.
We add some dummy users when we run the `make demo`
command.
2024-05-31 11:51:29 +02:00
Anthony LC
1e62320803 💚(app-desk) add template mail for e2e
The tests e2e need the mail template to
send the invitation to the user.
We are now caching the mail template instead
of using a artifact, thanks to that we can
build only the mail template if the cache is
invalidated, so we save time and resources.
2024-05-31 11:51:29 +02:00
Anthony LC
ff7341e544 (frontend) improve some tests
Improve some tests to check the states depend
the user's role.
2024-05-31 11:51:29 +02:00
Anthony LC
038c3d6207 🧑‍💻(mail) make commands windows friendly
Make the commands windows friendly.
2024-05-31 11:51:29 +02:00
Anthony LC
2b67d0bd26 (frontend) add or invite users to a doc
Add or invite a user to a doc.
If the user is already in the system,
the user will be added to the doc,
otherwise, the user will be invited to the doc.
2024-05-31 11:51:29 +02:00
Anthony LC
d30ac8ee4e 🐛(CI) fix job check changelog
The job was everytime failing.
This commit fixes the issue.
2024-05-31 10:34:15 +02:00
Anthony LC
c05b98ce0d 🔧(helm) create ingress_ws
The ingress was the same for the frontend, the
backend and the websocket, but the websocket
needs to be handled differently, so we created
a new ingress specifically for the websocket.
2024-05-31 10:34:15 +02:00
Anthony LC
3d594a99d5 🔨(frontend) add room to ws signaling url
Add the room to the ws signaling url so that
the ingress controller can route the request
to the correct pod.
2024-05-31 10:34:15 +02:00
Anthony LC
b47e60d6ec 🔧(helm) sticky session by request_uri
It helps to keep the same pod for the same
request_uri, so that multiple users from the
same room are not dispatched to different pods.
2024-05-31 10:34:15 +02:00
Anthony LC
f40f0d35cb 🧑‍💻(tilt) sync only y-webrtc-signaling app
We were listening all the frontend, but we can
just listen to the y-webrtc-signaling app.
This app doesn't change often moreover.
2024-05-31 10:34:15 +02:00
Anthony LC
f1227ed037 🚨(CI) fix linter backend
The linter in the CI was checking only the
impress directory. We were passing near some lint
issues. Now the linter checks the whole backend
directory.
2024-05-31 10:12:28 +02:00
Anthony LC
dbd4477e9a 👔(backend) change field displayed on users endpoint
Change the field displayed on the users endpoint.
We need the email field to be displayed.
2024-05-31 10:12:28 +02:00
Anthony LC
b4b308bda9 (backend) search users
We need to search users by their email.
For that we will use the trigram similarity algorithm
provided by PostgreSQL. To use it we have to
activate the pg_trgm extension in postgres db.
To query the email we will use the query param
`q`.
We have another query param `document_id`, it is
necessary to exclude the users that have already
access to the document.
2024-05-31 10:12:28 +02:00
Jacques ROUSSEL
2b456c231f 💚(CI) improve changelog ci
Disable changelog when the label is not present
2024-05-30 16:57:45 +02:00
Jacques ROUSSEL
72bb079f10 👷(helm) preprod configuration
This PR adds the preprod configuration
for the helm chart.
2024-05-30 16:57:45 +02:00
Anthony LC
06af320d61 🚀(docker) dockerize frontend dev
Dockerize the frontend development environment
to make it easy to display the frontend
development environment in the browser.

We don't mix it with the command `make run` to
let it kind of optional to run the frontend
in a docker container. We let it optional because
the hot reload doesn't work well in the docker
container. The volume synch make it a bit slower
as well. So, we let the developer decide to run
the frontend in a docker container or not.
2024-05-30 15:42:34 +02:00