luvi 440c72f2aa [FIX] web: fix draggable with touch input
This commit fixes some isues with touch behaviors in the drag and
drop feature. Since commit (1), pointer events are used instead of
mouse events in the draggable hook. This makes the drag and drop
available with touch, but some issues appeared.

The following issues have been adressed by the commit:
- Scrolling in a kanban view has become difficult, since items are
dragged, and columns are moved. A simple scroll in the view to show
other items was nearly impossible without interacting with elements.
A small delay has now be introduced in the draggable_hook_builder by
default for touch interactions. The user has to do a long press (500ms)
to instanciate the drag sequence.

- on Windows laptops, the hasTouch helper would not return true, even
on PCs and tablets with a touchscreen, because 'ontouchstart' is not
present in the window object. It meant that any touch feature was not
working properly (e.g. moving icons from the home screen).
This commit adds a mediaQuery check right after the current check on
the window object, to also consider those laptops as touch devices.

Tests have been added to check the behavior of the touch drag, and the
presence of a bouncing animation when initiated. The corresponding drag
helper now has the possibility to set a custom pointerType.

task-3436591

closes odoo/odoo#132373

X-original-commit: 4c5cf0962f91d05085fea75e9c26ecdca9c0eb13
Signed-off-by: Julien Mougenot (jum) <jum@odoo.com>
2023-08-19 12:01:57 +02:00
2023-08-14 20:24:57 +02:00
…
…
…
…
…

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%