summaryrefslogtreecommitdiff
path: root/addons/mail/static/src/components/chat_window
AgeCommit message (Collapse)Author
2021-02-16[FIX] mail: odoo shortcuts doesn't work if chat window is focusedbit-odoo
Before this commit: When chat window is focused odoo shortcuts (with alt) did not work because of there is stop propagation in _onKeydown method. After this commit: Remove stop propagation. Now odoo shortcuts (with alt) work properly. Task-2388829 closes odoo/odoo#65478 Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-01-21[FIX] mail, *: significantly reduce number of useless rendersSébastien Theys
* = hr_holidays, im_livechat, website_livechat A huge amount of components where rendered for no reason, notably when typing a new message (at every key press), which significantly slowed down the interface. There were 2 causes to this number of renders: - OWL rendering all children automatically, even if their props didn't change, unless `shouldUpdate` is overridden, which is now done. - `useStore` selectors being way too generous in what they observed task-2399731 closes odoo/odoo#62703 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2021-01-15[FIX] mail, sms: restore mobile app back button handlersSébastien Theys
task-2347640 closes odoo/odoo#63313 Related: odoo/enterprise#15320 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-12-17[FIX] mail: inconsistency of new message styleAlexandre Kühn
The style of discuss new message (+) and chat window new message should be consistent, as they both cover the exact same feature. closes odoo/odoo#63496 Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-11-18[FIX] mail: avoid marking hint as resolved before message list renderSébastien Theys
This change highlighted issues with the async behavior of `useUpdate`, which was no longer necessary and therefore reverted. This in turn highlighted issue with animation of chat window unfolding, making restoring of scroll position not work as intended due to the message list not having its whole height available during some time after render. This animation being minor (and even annoying in some cases) it was decided to remove it. task-2387729 closes odoo/odoo#61881 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-11-16[FIX] mail: fix race conditions, especially with scrollSébastien Theys
The `_update` of some components must take place before the `_update` of other (usually sibling) components that might directly influence their layout. This is in particular the case for `_update` that are relying on height. Prevent force save of scroll position if there are pending hints to adjust it, and prevent pending hints from overriding new scroll value. Prevent flicker with message date. This should fix all known issues related to incorrectly saving or restoring scroll position. task-2344226 task-2358066 task-2369332 task-2372339 task-2373741 closes odoo/odoo#61054 Related: odoo/enterprise#14736 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-10-30[FIX] mail: remove chat window auto-focus on clickSébastien Theys
This causes more trouble than it's worth, especially with mobile keyboards. It also prevents from selecting any text in chat window threads. task-2372553 Part of task-2277543 closes odoo/odoo#61031 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-10-27[Fix] mail: ensures composer cleanup on message postThanh Dodeur
Before this commit, the state of the composer was not properly saving its state when focusing out, which caused erroneous composer states in some corner cases, like when posting messages on mobile in some browsers. This commit fixes this issue. opw-2366374 closes odoo/odoo#60841 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com> Co-authored-by: Sébastien Theys <seb@odoo.com>
2020-10-23[FIX] mail: do not return members of channels in channel_infoSébastien Theys
This PR has 3 parts: The members fix itself, which is necessary for performance reasons especially at init messaging, as per described in the task. Adding the partner name in the typing payload, because due to not knowing all members anymore, it is necessary to properly display who is typing. Restrict restoring scroll position only if the corresponding scroll height is available, to make the scroll feature and particularly the corresponding tests more robust. task-2360020 closes odoo/odoo#60091 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-21[IMP] mail: reintroduce channel mentions, canned responses, commandsJulien Giannone
task-2280308 closes odoo/odoo#58166 X-original-commit: b63d0d2ee5f3bff24a5e1e1cd962d59bebef082d Related: odoo/enterprise#13392 Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-09-04[FIX] mail, sms, snailmail: prevent message_fetch for hidden threadsXavier Dubuc
Automatically load messages from a thread cache only if the thread cache is used in at least one thread view. Ensure thread viewer don't keep thread view records alive when they are not displayed. This change is particularly important for performance, to avoid spamming RPC at init if many threads are opened in chat windows. task-2310623 closes odoo/odoo#57061 X-original-commit: dd6981c7812134e0588f80a157eaba45512cd68e Related: odoo/enterprise#12936 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-09-03[FIX] mail: add open chat when clicking on author im status iconSébastien Theys
task-2329538 closes odoo/odoo#57006 X-original-commit: bfb8d99baaadedb2d0492b6f378b13b3330d496a Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com> Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-28[FIX] mail, *: fix opens and redirects, adapt messaging menu closeSébastien Theys
task-2244279 task-2262862 task-2274993 task-2277537 task-2282238 closes odoo/odoo#56745 X-original-commit: 109f202 Related: odoo/enterprise#12761 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com> Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-28[FIX] mail, *: rename thread viewer to thread viewSébastien Theys
The "viewer" should be the "parent" not the view itself. This distinction will become important in a future commit to allow viewers to not display the view in some situations. Rename done as a standalone commit to ease diff readability. Part of task-2310623 closes odoo/odoo#56737 X-original-commit: 1b811e6a972d72de02965adda67c5b039bee023f Related: odoo/enterprise#12756 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com> Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-06[FIX] mail: allow folded chat windows to be shiftedXavier Dubuc
task-2313414 closes odoo/odoo#55593 X-original-commit: 609dab84c6085af1ab27ee142c6ee674d7d321e9 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com> Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-05[FIX] mail: tab cycling between chat windowDidier (did)
Before this commit, cycling between chat window in LTR language clycled in the wrong direction. This commit also handle the RTL language cycling. task-2279706 closes odoo/odoo#55456 X-original-commit: 638720f9d72616f2e921a475a5fdfd2ad9a2ab8b Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com> Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-08-03[FIX] mail: speed up insert by using localId instead of findSébastien Theys
Part of task-2308312 X-original-commit: 407dc9796543a27b6695c8d4da922c13dece5b38
2020-07-16[IMP] mail: focus the next chat window when closed by ESCDidier (did)
This allows user to close multiple windows with ESC key. task-2283891 closes odoo/odoo#54604 X-original-commit: bac3d7792a48f86a39f92e0fcfc18d522ce00d94 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-07-08[FIX] mail: bring back extended composer for mailing channelXavier Dubuc
task-2171877 task-2282377 task-2282382 closes odoo/odoo#54249 X-original-commit: acf8eb3e2e49c1ade638ff1f2fed4969f9944053 Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-07-07[FIX] mail: save scroll position of chat window when foldedXavier Dubuc
- Remove no more used ThreadViewer prop : messageListInitialScrollTop - Remove no more used ChatWindow prop : threadInitialScrollTop - Rename ThreadViewer field threadCacheInitialPosition to threadCacheInitialScrollPosition - Use the scroll position to set message list scroll on mounted - Fix old test which was not simulating correctly home menu show - Add tests to check that scroll position is correctly saved even if ChatWindow is folded - Fix traceback when showing/hiding home menu with a folded chat window task-2285691 closes odoo/odoo#54198 X-original-commit: 31123a94c156424b3962fe4aebc3cc60a7a89223 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com> Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2020-06-26[FIX] mail: fix (inbox reply) composer event handlers (and discard)Sébastien Theys
task-2092950 closes odoo/odoo#53731 X-original-commit: c29f5776594c4d2278ce163a78d8eb917fb672c0 Signed-off-by: Sébastien Theys (seb) <seb@odoo.com> Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-06-24[FIX] mail: fix folded new message chat window styleXavier Dubuc
task-2272492 closes odoo/odoo#53565 X-original-commit: dcaa91ffb84a7d9ca433fff1913df47513bb365a Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2020-06-15[REF] mail, *: refactor messaging with OWLSébastien Theys
This commit is a significant rewriting of client-side discuss, chatter, chat window, and messaging menu using OWL. The behavior should be broadly the same, with some slight functional changes here and there. From a technical standpoint, the code of messaging is mainly organized in 2 main groups of modules: - models, which are logical entities that depict the client-side state of messaging as a whole. - components, which are in charge of displaying information from models. This refactoring also introduces new JS guidelines regarding folder structure (/static) and naming rules for JS modules. Community PR: https://github.com/odoo/odoo/pull/39023 Enterprise PR: https://github.com/odoo/enterprise/pull/6249 Task-1914207 This PR is a collaborative work by Alexandre, Julien, Sébastien and Xavier, with the precious help of Lucas to speed it up towards the end. closes odoo/odoo#39023 Related: odoo/enterprise#6249 Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com> Co-authored-by: Alexandre Kühn <aku@odoo.com> Co-authored-by: Julien Giannone <jgi@odoo.com> Co-authored-by: Lucas Perais <lpe@odoo.com> Co-authored-by: Sébastien Theys <seb@odoo.com> Co-authored-by: Xavier Dubuc <xdu@odoo.com>