Commit Graph

523 Commits

Author SHA1 Message Date
Anthony LC
e807237dbe 🔒️(frontend) fix props vulnerability in Interlinking
We were not properly sanitizing props passed to the
InterlinkingLinkInlineContent component, which could
lead to XSS attacks. This commit remove most of the
props and only keep the necessary ones.
2026-01-13 13:13:51 +01:00
Anto59290
fa6f3e8b7c 💄(frontend) fix icon position in callout block
Make sure the icon in the callout block is aligned to the top instead of
centered when we have multi-line content.

Signed-off-by: Anto59290 <antonin59290@hotmail.com>
2026-01-12 14:49:50 +01:00
Cyril
b1a18b2477 (frontend) add missing label to improve a11y and pass axe checks
enhances a11y by adding label to fix axe tool errors on missing attributes

Signed-off-by: Cyril <c.gromoff@gmail.com>
2026-01-12 09:06:19 +01:00
Manuel Raynaud
55fe73d001 (backend) use langfuse to monitor AI actions
We want to monitor AI actions. For this we choose to use langfuse. As
this usage is optional, we load langfuse sdk only if settings are
configured. Also, the openai client from langfuse is a dropin
replacement of openai client, so we only have to change how openai is
imported.
2026-01-09 14:38:56 +00:00
Christopher Spelt
39b9c8b5a9 🐛(backend) fix TRASHBIN_CUTOFF_DAYS type error
Fixes `TRASHBIN_CUTOFF_DAYS` type as described in #1777.

Signed-off-by: ChristopherSpelt <christopherspelt@icloud.com>
2026-01-09 14:00:23 +00:00
Cyril
b56ebf19af ️(frontend) make html export accessible to screen reader users
adjusted structure and semantics to ensure proper sr interpretation

Signed-off-by: Cyril <c.gromoff@gmail.com>
2026-01-09 09:08:12 +01:00
Manuel Raynaud
f28da7c2c2 🔒️(backend) validate more strictly url used by cors-proxy endpoint
The cors-proxy endpoint allow to download images host externally without
being blocked by cors headers. The response is filter on the return
content-type to avoid disclosure and the usage of this endpoint as the
proxy used by attacker. We want to restrict the usage of this endpoint
by filtering on non legit ips used. This filter avoid exploitation of
Server Side Request Forgery (SSRF).
2026-01-08 15:58:00 +01:00
Pierre Ozoux
dd2d2862be 🔒(helm) set default security context
In order to be able to deploy this in a restricted k8s cluster, we set
this default security context.

We set it as default because it doesn't change the way the app runs.

So it is better to be more secured by default.

Signed-off-by: Pierre Ozoux Krebber <pierre@ozoux.net>
2026-01-08 14:53:16 +00:00
Anthony LC
8901c6ee33 📝(docs) Add language configuration documentation
Add comprehensive guide explaining how to override LANGUAGES settings
using the DJANGO_LANGUAGES environment variable. Documentation includes:

- Default language configuration
- Environment variable format and examples
- Configuration for development, production, and Docker Compose
- Complete list of 15 available languages with translation files
- Language code formatting guidelines
- Testing and troubleshooting sections
2026-01-08 12:55:49 +01:00
Antonin
f7d697d9bd (backend) fix flaky test in user search api
Make sure the full is never John for the first user in order to make
sure we always have only 2 users (as the search is performed on both the
email and the full name).
    
Fixes #1765
    
Signed-off-by: Anto59290 <antonin59290@hotmail.com>
2026-01-08 11:50:07 +00:00
Anthony LC
ab92fc43d6 (export) add PDF regression tests
To avoid regression issues in PDF export
functionality, this commit introduces end-to-end
tests that compare exported PDFs against
known good reference files.
We compare the PDF on most of the blocks
that the editor supports.
If during a Blocknote release or pull request
there are intentional changes, the reference
files would need to be updated accordingly.
It can be done by uncommenting the line
in the test that saves the newly generated
PDF to the assets folder.
2026-01-08 11:32:58 +01:00
Christopher Spelt
43a1a76a2f (backend) add documents/all endpoint with descendants
External dashboards need to find the latest updated documents across
the entire hierarchy. Currently this requires many API calls to
/documents/ and /documents/{id}/children for each level.
   
This endpoint allows retrieving all accessible documents in a single
request, enabling dashboards to efficiently display recently changed
documents regardless of their position in the hierarchy.
    
Signed-off-by: ChristopherSpelt <christopherspelt@icloud.com>
2026-01-08 09:33:55 +00:00
Cyril
62213812ee 🐛(frontend) fix clickable main content regression
removes accidental clickable area introduced by the skip-to-content feature
2026-01-08 09:32:21 +01:00
Anthony LC
3d2b018927 🔖(minor) release 4.3.0
Added:
- (helm) redirecting system
- 📱(frontend) add comments for smaller device
- (project) add custom js support via config

Changed:
- 🥅(frontend) intercept 401 error on GET threads
- 🦺(frontend) check content type pdf on PdfBlock
- ✈️(frontend) pause Posthog when offline

Fixed:
- 🐛(frontend) fix tables deletion
- 🐛(frontend) fix children not display when first resize
2026-01-06 10:29:35 +01:00
Anthony LC
ea3a4a6da3 (project) add custom js support via config
From the config, we can add custom JS file URL
to be included in the frontend.
2026-01-05 15:06:53 +01:00
Anthony LC
b78ad27a71 🐛(frontend) fix children not display when first resize
When we resize the window for the first time, then
open the panel, the children were not displayed.
This fix this issue.
2026-01-05 13:21:54 +01:00
Anthony LC
e4b8ffb304 ✈️(frontend) pause Posthog when offline
Posthog keeps trying to send events when the user
is offline, causing the network request queue to fill up
and slowing down the app. This commit pauses Posthog
when the user is offline and resumes it when back online.
2026-01-05 12:07:47 +01:00
Anthony LC
78c7ab247b 🦺(frontend) check content type pdf on PdfBlock
Pdfblock was quite permissive on the content type
it was accepting. Now it checks that the content
type is exactly 'application/pdf' before rendering
the PDF viewer.
2026-01-05 11:47:55 +01:00
Anthony LC
b0bd6e2c01 🥅(frontend) intercept 401 error on GET threads
We intercept 401 errors on GET /threads to avoid
spamming Sentry with authentication errors
when users are not logged in.
2026-01-05 11:23:43 +01:00
Anthony LC
a73d9c1c78 📱(frontend) add comments for smaller device
Add comments support for mobile devices by
removing the desktop-only restriction and
ensuring the UI adapts well to smaller screens.
2026-01-05 10:04:37 +01:00
Anthony LC
a920daf05b ⬆️(dependencies) bump to blocknote 0.45.0
Bump to BlockNote 0.45.0 to get the latest
features and fixes.
This release includes the fix for the table
deletion that breaks the editor when
deleting tables.
2025-12-22 10:53:12 +01:00
Anthony LC
efaec45bfd (helm) create ingress-redirects template
Create a new Helm template for ingress redirects
and update the values.yaml file accordingly.
We will be able to manage ingress redirects
through Helm charts easily.
2025-12-22 10:11:54 +01:00
Anthony LC
fb368ef86f 🔖(minor) release 4.2.0
Added:
- (backend) allow to create a new user in a marketing system
- (backend) add async indexation of documents on save
  (or access save)
- (backend) add debounce mechanism to limit indexation jobs
- (api) add API route to search for indexed documents in Find
- 🥅(frontend) add boundary error page

Changed:
- 🛂(backend) stop throttling collaboration servers
- 🚸(backend) use unaccented full name for user search
- 🌐(backend) internationalize demo
- (frontend) improve accessibility:
  - ️Improve keyboard accessibility for the document tree

Fixed:
- 🐛(frontend) paste content with comments from another document
- 🐛(frontend) Select text + Go back one page crash the app
2025-12-17 17:03:27 +01:00
Anthony LC
e340463d35 🐛(frontend) fix versioning conflict
We switching from one version to the other, depending on
the blocks inside, the version editor could
crash due to conflicts between the different versions.
We now reset the previous content
when switching version to avoid these conflicts.
2025-12-17 17:03:27 +01:00
Anthony LC
344e9a83e4 🥅(frontend) add boundary error page
Add a custom error page to handle unexpected errors
gracefully. This page provides users with options
to navigate back to the home page or refresh
the current page, enhancing the overall user
experience during error scenarios.
It is quite hard to test this page, it cannot
be trigger in development mode, we have to build
the app and have a real error in production to
see it.
2025-12-17 09:26:15 +01:00
Cyril
48aa4971ec (frontend) keyboard support in sub-documents with f2 options access
adds f2 shortcut to open options menu in sub-documents

Signed-off-by: Cyril <c.gromoff@gmail.com>

(frontend) adds f2 shortcut using a fakenode since it's outside the treeview

Signed-off-by: Cyril <c.gromoff@gmail.com>

(frontend) add sr-only instructions with aria-describedby links

improves screen reader support with contextual accessibility guidance

Signed-off-by: Cyril <c.gromoff@gmail.com>

(frontend) add e2e test to check focus behavior with F2 shortcut

ensures F2 correctly focuses the expected UI element

Signed-off-by: Cyril <c.gromoff@gmail.com>
2025-12-17 08:26:48 +01:00
Fabre Florian
bf978b5376 (backend) refactor indexation signals and fix circular import issues
Signed-off-by: Fabre Florian <ffabre@hybird.org>
2025-12-16 22:10:03 +01:00
Anthony LC
23216d549e 🛂(backend) stop throttling collaboration servers
We observe some throttling pick here and there.
We observed that when the collaboration has a
problem, it is retrying to connect, leading to more
requests to the django backend. At one point, the
throttling is reached and the user would not
be able to use the application anymore.
Now when the request comes from a collaboration
server, we do not throttle it anymore.
2025-12-16 14:13:30 +01:00
Anthony LC
4cf0e15406 ⬆️(dependencies) bump blocknote to 0.44.2
We bump the blocknote dependencies to version
0.44.2 to incorporate the latest features
and bug fixes.
It seems to fix an issue with Titap, when the text
was selected and the user clicked
on the Go Back button of the browser, the
application was crashing.
"[tiptap error]: The editor view is not available.
Cannot access view['dom']. The editor may not be
mounted yet."
2025-12-16 10:48:41 +01:00
Anthony LC
31bd475418 🐛(frontend) paste content with comments from another document
When pasting comments, the data-bn-thread-id
attribute is present in the clipboard data.
This indicates that the pasted content contains comments.
But if the content with comments comes from another
document, it will create orphaned comments that
are not linked to this document and create errors.
To avoid this, we refresh the threads to ensure
that only comments relevant to the current document
are displayed.
2025-12-15 17:17:21 +01:00
Sylvain Boissel
08fb191e6b 🌐(backend) internationalize demo
This allows the demo to generate user and filenames with other locales
than English, for all languages defined in the project's settings.
In particular, it allows the generation of accented names, which were
previously missing.
2025-12-15 12:43:57 +01:00
Sylvain Boissel
a49f3b6b32 📝(changelog) move entry in unreleased section
The changelog line was at the wrong place after rebase
2025-12-15 12:02:00 +01:00
Sylvain Boissel
96299f4b7f 🚸(backend) use unaccented full name for user search
We have the user full name through OIDC in the database, but the search only
used the email field.
This change allows to search for a user by their first and/or
last name (fix #929).
Given that user names are more likely than emails to include diacritics, it
unaccents both the query and the database entry for search (fix #1091).
It also unaccents for email so that internationalized domain names are
managed whether or not the accent is included in the search.
An unaccented gin index is added on users full_name an email fields.
Using a manual migration because a wrapper around unaccent is necessary
to make it IMMUTABLE (cf.
https://stackoverflow.com/questions/9063402/ )
2025-12-15 11:22:26 +01:00
Manuel Raynaud
d65d0d1450 📝(changelog) move entry in unreleased section
The commit f5425f5 was created before release 4.1.0 but merged after and
the corresponding entry has not been move in the unreleased section.
2025-12-10 17:23:26 +01:00
Manuel Raynaud
8091cbca23 (backend) allow to create a new user in a marketing system
We want to create a new user in a marketing system to create a dedicated
onboarding for each of them. The marketing service is implemented in the
django-lasuite library and it is possible to pick the backend we want
or implement a new one following the documentation on this library.
2025-12-10 16:30:00 +01:00
Anthony LC
12cc79b640 🔖(minor) release 4.1.0
Added:
- ️(frontend) export html

Changed:
- (frontend) improve accessibility:
  - (frontend) add skip to content button for keyboard
    accessibility
  - (frontend) fix toggle panel button a11y labels
- 🔒️(frontend) remove dangerouslySetInnerHTML from codebase
- ️(frontend) improve Comments feature

Fixed:
- 🐛(nginx) fix / location to handle new static pages
2025-12-10 11:50:14 +01:00
Anthony LC
af15e77713 🐛(frontend) keep editor mounted when resize window
When resizing the window and crossing the desktop
breakpoint, the editor was unmounted. It could
lead to loss of data if there were unsaved changes,
and tiptap crash if the toolbar was used while the
editor was unmounted.
It was caused by the ResizableLeftPanel component
which was rerendering the editor.
We now keep the editor mounted when resizing
the window, by keeping the ResizableLeftPanel
component rendered but setting its size to 0
and disabling the resize handle.
2025-12-10 11:50:14 +01:00
Anthony LC
9c575e397c 🔒️(frontend) remove dangerouslySetInnerHTML from codebase
dangerouslySetInnerHTML were introduced to quickly
render translated strings containing HTML,
but they can lead to security vulnerabilities
if not handled properly.
Better to use React components to ensure safety.
2025-12-09 11:34:25 +01:00
Anthony LC
a6b472aa51 ️(frontend) improve Comments feature
Improve the comments feature to reduce annoyance:
- gives focus on input when opening comment threads
- hide comment button when mobile view
- improve contrast of overline commented text
- remove thread if last comment deleted
- scroll to bottom thread when adding new comment
2025-12-09 11:17:42 +01:00
Cyril
acdde81a3d (frontend) fix toggle panel button a11y with dynamic label
improves screen sr by updating label and state indication dynamically

Signed-off-by: Cyril <c.gromoff@gmail.com>
2025-12-09 09:57:12 +01:00
Cyril
9b03754f88 (e2e) add test for accessible html export from export modal
checks generated zip contains html and embedded media files

Signed-off-by: Cyril <c.gromoff@gmail.com>
2025-12-09 09:24:14 +01:00
Manuel Raynaud
54fe70d662 🐛(nginx) fix / location to handle new static pages
The / location is not trying the $uri/index.html file. We should try
this instad of $uri/ because when a new static page is added, we always
have this pattern.
2025-12-03 12:14:19 +01:00
Cyril
1e37007be9 (a11y) add skip to content button for keyboard accessibility
add SkipToContent component to meet RGAA skiplink requirement

Signed-off-by: Cyril <c.gromoff@gmail.com>

(frontend) add e2e test for skiplink and fix broken accessibility test

ensures skiplink behavior is tested and stabilizes a failing accessibility test

Signed-off-by: Cyril <c.gromoff@gmail.com>
2025-12-02 13:37:58 +01:00
Anthony LC
77df9783b7 🔖(major) release 4.0.0
Added:
-  Add comments feature to the editor
- (backend) Comments on text editor
- (frontend) link to create new doc

Changed:
- ️(sw) stop to cache external resources likes videos
- 💥(frontend) upgrade to ui-kit v2
- ️(frontend) improve perf on upload and table of contents
- (frontend) improve accessibility:
  - (frontend) improve share modal button accessibility
  - (frontend) improve screen reader support in DocShare modal

Fixed:
- 🐛(frontend) fix toolbar not activated when reader
- 🐛(frontend) preserve left panel width on window resize
- 🐛(frontend) prevent duplicate as first character in title
2025-12-02 10:01:48 +01:00
Anthony LC
7475b7c3bc (frontend) link to create new doc
We create a special URL to create a new doc,
we can set the doc with the URL param to set
the visibility, the permission and the title.
2025-12-01 15:08:25 +01:00
Anthony LC
9aeedd1d03 ️(frontend) improve UploadFile process
We notices that `context.getChanges` was very
greedy, on a large document with multiple
users collaborating, it caused performance issues.
We change the way that we track a upload by
listening onUploadEnd event instead of tracking
all changes in the document.
When a doc opens, we check if there are any ongoing
uploads and resume them.
We fix as well a race condition that could happen
when multiple collaborators were on a document
during an upload.
2025-12-01 10:31:46 +01:00
Anthony LC
29104dfe2d 💥(frontend) upgrade to ui-kit v2
Upgrade Docs to Ui-Kit v2 and apply new color
scheme from LaSuite design system.
This commit will probably create breaking changes if
user has custom styles applied to their docs.
2025-11-26 11:32:18 +01:00
Anthony LC
785c9b21cf ️(sw) stop to cache external resources likes videos
Some videos from external sources can be very
large and slow to cache. To improve performance, we
decided to stop caching these resources in the
service worker.
We will cache only images and fonts from external
sources.
The videos will maybe not be available when offline
mode.
2025-11-26 10:27:15 +01:00
Cyril
3fee1f2081 (frontend) prevent duplicate emoji when used as first char in title
ensures icon and title are visually distinct in sub-document headers

Signed-off-by: Cyril <c.gromoff@gmail.com>
2025-11-25 15:38:30 +01:00
Cyril
5f9968d81e (frontend) improve screen reader support in DocShare modal
adds relevant aria-labels to enhance accessibility for assistive technologies

Signed-off-by: Cyril <c.gromoff@gmail.com>
2025-11-25 15:02:36 +01:00