♻️(frontend) refactor thread query cache management (#642)

The thread query is an infinite one and the frontend logic is
based on the structuralSharing concept of react-query to
optimiscally update the react query cache on thread mutation in
order to improve ux. This part is a tricky one and it's easy to
introduce regression, that's why refactor it by moving the corresponding
logic into a mailbox-cache module, use a better naming (pin instead of optimistic)
and battle test it.
This commit is contained in:
Jean-Baptiste PENRATH
2026-05-06 19:39:07 +02:00
committed by GitHub
parent ad3307e448
commit 6be3b9e129
33 changed files with 1533 additions and 521 deletions
+7 -5
View File
@@ -1860,14 +1860,11 @@
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/TreeLabel"
}
"$ref": "#/components/schemas/Label"
}
}
},
"description": "Created labels in hierarchical structure"
"description": "Created label"
},
"400": {
"content": {
@@ -6933,6 +6930,10 @@
"description": "Color of the label in hex format (e.g. #FF0000)",
"maxLength": 7
},
"display_name": {
"type": "string",
"readOnly": true
},
"mailbox": {
"type": "string",
"format": "uuid",
@@ -6958,6 +6959,7 @@
}
},
"required": [
"display_name",
"id",
"mailbox",
"name",