Commit Graph
8309 Commits
Author SHA1 Message Date
Robin Lejeune (role) c7b4035e26 [FIX] website: fix dropping form snippet
Since [1], dropping a form snippet generates a `TypeError: Cannot read
properties of undefined (reading 'disconnect')`.
Note that it only happens if this is the 1st snippet dropped, and if it
is dropped as a section, not as inner content of another snippet.

This is due to the SnippetEditor being destroyed before being started,
as `destroy()` is synchronous but `start()` is async. A field from
`s_website_form` (specifically the field `.s_website_form_dnone`) is
removed through `_addHiddenField()` when dropping a new form. The result
is that it gets destroyed immediately and tries to disconnect an
observer that doesn't exist yet, but the async start() ends a little
later - and creates + connects the observer that will never be
disconnected.

To solve the issue, this commit makes sure (1) in `destroy()` that the
observer was initiated and (2) in `start()` that if the SnippetEditor
was destroyed, it should not create an observer.

[1]: https://github.com/odoo/odoo/commit/f64c9f2

task-3598997

closes odoo/odoo#142291

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-20 04:58:29 +00:00
Arthur Detroux (ard) 458c26d307 [FIX] website: fix traceback when saving anchor with unchanged name
Since commit [1], anchor dialog is now in OWL. During adaptation, a line
of code was forgotten which lead to a traceback when an anchor is saved
with an unchanged name.

Steps to reproduce:

- Drop a Text-Image snippet and set an anchor on it.
- On the anchor notification, click on "Edit"
- In the dialog, do not modify the anchor name (or change it but then
  set the original one again)
- Click on "Save & Copy"
=> Traceback

[1]: https://github.com/odoo/odoo/commit/57ed8bc0bf9d1ae2b7542d677a4d7e8fd1899ea2

task-3576975

closes odoo/odoo#141936

Signed-off-by: Soukéina Bojabza (sobo) <sobo@odoo.com>
2023-11-20 04:58:28 +00:00
Arthur Detroux (ard) e820187381 [FIX] website: prevent creation of duplicate anchors
Before commit [1], anchors would not have a duplicate name as checks
were in place to prevent it from happening. However, after [1], those
checks were no longer valid. They would check in the global variable
document, which was no longer the editable document.

This commit fixes that by using the ownerDocument of the target, which
should always return the correct document.

Steps to reproduce:

- Drop a text snippet.
- Click on create anchor (link icon)
    -> notification shows "/#Text".
- Drop another text snippet.
- Click on create anchor (link icon)
    -> notification shows "/#Text".
=> It should instead show "/#Text2".

[1]: https://github.com/odoo/odoo/commit/31cc10b91dc7762e23b4bde9b945be0c4ce3fe3b

task-3576975

X-original-commit: fa75fe60b32537d3c564ddba8117207f468c1004
Part-of: odoo/odoo#141936
2023-11-20 04:58:28 +00:00
Odoo Translation Bot f6fe982853 [I18N] Update translation terms from Transifex 2023-11-19 00:28:08 +01:00
nda 4612f6a7ee [FIX] auth_signup, website: make reset password multi website friendly
The "reset password" feature does not take into account
multi-website.

steps to reproduce:
- create a website A
- uncheck 'Shared Customer Accounts' on website A
- create a portal user user@example.com on website A
- create a website B
- uncheck 'Shared Customer Accounts' on website B
- create a portal user user@example.com on website B
- reset password for user@example.com on any website

before this commit:
An error is raised "No account found for this login"
(which is false, actually 2 accounts are found)

after this commit:
Only the user linked to the current website is properly
selected

opw-3551540

closes odoo/odoo#142110

X-original-commit: a2196253d6cf90dca3042a777703e0679f74f542
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-11-16 23:35:57 +00:00
Robin Lejeune (role) f6d9f80e6e [FIX] website: prevent page overflow with mobile menu open
Since [commit 1] replaced the mobile menu, a bug appeared on Safari
where the `#wrapwrap` element would still be scrollable even with the
menu open and even though the `body` has `overflow: hidden;`.
This commit fixes it.

[commit 1]: https://github.com/odoo/odoo/commit/bc13176de8d66bbdc1c536017b1f046c5fd31a86

task-3584299

closes odoo/odoo#141154

Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-11-15 16:54:45 +00:00
qsm-odoo 1bbcd098f1 [FIX] website: prevent the header to be broken after CTA edition
The header call to action button template was extended by other ones
based on classes that can be changed using the Odoo editor. So if you
changed them, saved then toggle those other template options... you
broke your header.

closes odoo/odoo#141694

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-13 08:41:44 +00:00
Jorge Pinna Puissant afc8dde97a [FIX] base, web: log correctly error in assets
Since [1], when an error exists in an asset, the assets raise a not
found exception. The issue, is that, there is no feedback for the
developer to find the error.

Now, a new console log with the error details is shown.

[1] : bf3b6b0b8b

closes odoo/odoo#141705

Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2023-11-10 12:33:40 +00:00
Odoo Translation Bot 593ac17031 [I18N] Update translation terms from Transifex 2023-11-09 11:30:34 +01:00
Louis (wil) 68b4dfc2bb [I18N] *: import translations
closes odoo/odoo#141655

Related: odoo/enterprise#50484
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-11-08 20:48:14 +00:00
Bruno Boi ea83d3eb57 [REV] website: revert UrlAutocomplete displayed behind modal
This reverts commit 6c749a4b0d.

This commit was fixing an issue raised after a fix [1]
that is about to get reverted [2].

We will make a proper fix after the OXP2023 event.

[1]: https://github.com/odoo/odoo/commit/9682cfa174fb39ec9d9874951ea9ee2884058d96
[2]: https://github.com/odoo/odoo/pull/141401

closes odoo/odoo#141405

Signed-off-by: Romain Estievenart (res) <res@odoo.com>
2023-11-08 03:00:13 +00:00
Guillaume-gdi 2f3219c08f [FIX] web_editor, website: hide some text style outside the website app
This commit removes some text style options when the editor is used in
the backend. In the website it makes sense to have all the options but
in the other apps, it is not necessary to have all the options.

task-1958098

closes odoo/odoo#141412

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-07 23:57:46 +00:00
Antoine Vandevenne (anv) 1fb7571afb [FIX] *: retarget documentation links to 17.0
closes odoo/odoo#141406

Related: odoo/enterprise#50357
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2023-11-07 23:57:41 +00:00
qsm-odoo 351f5cf54e [REM] website: remove dead code related to o_navbar_toggler_container
closes odoo/odoo#141198

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-07 19:32:28 +00:00
qsm-odoo d9c0b8f5ca [IMP] website: optimize CSS for mobile navbar background color
The `o-bg-color` mixin was used to color the mobile navbar: it was
useless. First, in general, `o-bg-color` should rarely be used:
`o-apply-color` is best as it will call the other one when needed. Then,
this comes with many extra rules to color the text, inner subtitle, etc.
All of those rules are already inherited from the parent navbar: we only
want to re-apply the background-color on a sub element (the mobile
navbar) in this case.

Part-of: odoo/odoo#141198
2023-11-07 19:32:28 +00:00
Romain Derie a23e19cf95 [FIX] website: remove useless code messing with action todos
With the new website scraper (see enterprise counterpart), there would
be a failing test / flow due to the `ir.actions.todo` introduced by this
new module.

This is because when the testing suite is run, this module is installed
and after choosing a theme for a website, the next action is fetch and
executed.

But that doesn't make sense anymore, it seems to be code leftover
messing around. On top of code leftover, it's also probably never what
we want as when choosing a theme, we want the user to be redirected to
his website. Other TODO actions should not alter that.

The `action_launch()` code removed here is was initially introduced with
commit [1] which was coming with an override of this method in website
but this override was removed with commit [2], nullyfing the need of
this call.

The condition to show the loaded which is removed here was introduced
with commit [3] in case the edit mode was requested.
But that "if edit mode" condition was actually removed with commit [4].

All in all, what we want is to always show the loader and always
redirect to the website.

[1]: https://github.com/odoo/odoo/commit/c1e0b03d8b5482a5150a0973e1ca48d70864a4e1
[2]: https://github.com/odoo/odoo/commit/e8a5af2e28a4724f86783746706cb59175f086bf#diff-2eb3a36c4664b647c665047166b246667200bf5f18ec53c640a9612b0d5e06ceL69
[3]: https://github.com/odoo/odoo/commit/1ff7f1e8b6b5539311f94f9828d203ec233daccb
[4]: https://github.com/odoo/odoo/commit/e38808e1a77dab291beb4020a2bf3c248f88cdef

closes odoo/odoo#141450

Related: odoo/enterprise#50161
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-11-07 19:32:20 +00:00
FrancoisGe 5674e221c4 [FIX] web, *: clicking on a button that crashes does not enabled buttons
In many situations, when you click on a button, you want to disable all
the other buttons while it is running.
Currently, in each of these situations, we duplicate the same code that
disabled all the buttons and enabled them afterwards. Unfortunately, in
many cases, if the code executed crashes, the buttons are not enabled.
In this commit, we're going to create a helper so that we have a single
version of the code that correctly handles crashes. This helper will
disabled all the buttons, then execute the click code and enabled all the
buttons afterwards. If the code crashes, it will also enbaled them.

The problem has been reported for the Settings Form view:
When you edit this view and click save, if an error occurs in the save,
all the buttons remain disabled.

closes odoo/odoo#140938

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-11-07 19:32:17 +00:00
qsm-odoo 1fa701c436 [FIX] website: properly allow to edit header texts and links
The text and links in the header configurations were always the root
elements that were editable. For them to be properly editable, we need
their container (at minimum) to be the root editable element. Indeed,
on root editable elements, only the class and style can be changed (if
not dynamic). But changing a link requires to change the href, the
target. Changing a text style requires to change the tag entirely, etc.

For this to work, the `_link_class` configuration was removed, it was in
fact mostly useless and actually even breaking some layouts. So doing
this fix actually improves the design as well. For the layout were it
made sense, it actually became useless by refactoring the templates.
This was necessary anyway for texts which did not use `_link_class` but
were root editable nodes anyway because of the `t-if` conditions laying
around.

closes odoo/odoo#140869

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-07 19:32:16 +00:00
qsm-odoo 7f3ad07cf6 [FIX] website: remove useless class configuration for header text
The configurable text in the header templates has a `_link_class`
option which sometimes was set to add the "nav-link" class on the
links in the default header texts... but that class was already there
no matter the config.

This removes the double class addition.

Part-of: odoo/odoo#140869
2023-11-07 19:32:16 +00:00
Guillaume-gdi b7d5d2686a [IMP] website: reduce padding of the website loader
This commit reduces the padding of the website loader to prevent too
much line breaks of the text.

task-3557675

closes odoo/odoo#138921

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-07 17:57:09 +00:00
Guillaume-gdi ebd09603c1 [IMP] website: add a fake loader during website install
This commit adds a fake loader during website install. [Another commit]
already added a loader during extra module install. The goal here is to
have a loader even if there is no extra module to install. This should
make the user think the install is faster and prevent him from leaving.

This commits also improves the loader when there are extra modules to
install. We split the loader in two parts: one for the modules install
(70%) and another for the rest of the install (30%).

Note that to test this feature properly, you need to be in a multiple
workers environment.

[Another commit]: https://github.com/odoo/odoo/commit/ab6564be94533a64a0a942202f0860423ec7dc4d

task-3557675

Part-of: odoo/odoo#138921
2023-11-07 17:57:09 +00:00
Benoit Socias 2b2122a3c6 [FIX] website: make generated templates noupdate
Since [1] when the generation of missing configurator templates and new
page templates was introduced, `_load_xmlid` was called for every
generated record so that `_process_end` does not delete them after a
module update.
Unfortunately, this trick does not work when using the "Upgrade" command
on the Website app in the Apps view. (or calling
```py
env['ir.module.module'].search([
    ('name', '=', 'website')
]).button_immediate_upgrade()`
```
from the shell): in that case, the `self.pool` onto which the xmlids
were registered was a different instance from the one accessed by
`_process_end`.

This commit avoids this problem by making the generated templates
`noupdate: True`, thus preventing `_process_end` from deleting them.

Steps to reproduce:
- Install website with -i
- Go to Apps, search Website, upgrade Website
=> In the logs you can see that some templates are deleted at the end of
   the upgrade
- Website configurator: a business website, furniture store, get leads,
  choose a palette, about us + services + pricing + privacy policy,
  choose the center template (loftspace)
=> You see some crash in the logs

[1]: https://github.com/odoo/odoo/commit/a2f8e18b76e52e1a349b77691d0af18edc09a1be

closes odoo/odoo#140986

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-07 15:12:47 +00:00
Robin Lejeune (role) 7eda184589 [FIX] web_editor, website: allow links to unreachable pages
Since commit [1] removed `legacyRejectPromiseHandler()`, trying to edit
a link leading to an HTTP error triggers an "Uncaught Promise" error.
This commit makes sure such links do not cause a traceback: the link
popover is just less detailed (no title, favicon).

[1]: https://github.com/odoo/odoo/commit/fcb16a3b1bd373726ffb54f0fbe41fb6d1784769

task-3584686

closes odoo/odoo#141225

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-06 18:11:35 +00:00
Louis (wil) af5a5f4986 [I18N] *: export source terms
closes odoo/odoo#141127

Related: odoo/enterprise#50247
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-11-06 16:55:41 +00:00
Romain Estievenart 6c749a4b0d [FIX] website: UrlAutocomplete is displayed behind the modal
Since this fix[1] of the overlapping. The `UrlAutocomplete` wasn't
working as expected, The `AutoCompleteWithPage` dropdown is displayed
behind the dialog when it was inside a dialog.

Steps to reproduce:

* Open the `Website` app
* Click on `Site` > `Edit Menu` > `Add Menu Item`
* Start to type in the url field, the dropdown is displayed behind the
  dialog. => bug

Link

[1]: https://github.com/odoo/odoo/commit/9682cfa174fb39ec9d9874951ea9ee2884058d96

closes odoo/odoo#141159

Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
2023-11-06 12:32:07 +00:00
Benjamin Vray 988a215339 [FIX] web_editor: fix anchor link selector broken
Steps to reproduce the bug:

- In website edit mode, drag and drop an 'Image-Text' snippet onto the
page.
- Click on the button in the second column of the snippet.
- Type "/" in the URL input of the link options in the customize panel.
- Open the 'Page Anchor' selector and select the '#top' anchor.
- Bug: The anchor is not added to the link in the URL input.

The bug was introduced by this commit [1]. Indeed, the events in the
'Start' of LinkTools were no longer attached to the main element but
directly to the event target. This means that in this particular case
where the 'we-button' elements are created after the 'Start', the click
event had no effect because no event was properly attached to it.

This commit also includes test steps to prevent this bug from
reoccurring in the future.

[1]: https://github.com/odoo/odoo/commit/d7245d2abf528d093226c80e40975e63d61e8997

task-3580414

closes odoo/odoo#141034

X-original-commit: 72eb761545c51c9dc7c6490c0ce0e38650dfa985
Signed-off-by: Benoit Socias (bso) <bso@odoo.com>
2023-11-06 12:32:01 +00:00
Romain Derie d64b4adf1e [IMP] website: allow fallback images when industry image not set
When creating a new website through the configurator, the images that
will be used on the website will be the one specified by the selected
industry.

We recently introduced 2 new images with commit [1] for which the
industries have no images set as we did not have time to do it.
It would require going through the ~4000 industries and finding a
relevant image on Unsplash for it.

This commit is simply using another existing set image instead.

Indeed, if an industry hasn't set an image, the theme one will be used
instead, which is less ideal.

Step to reproduce:
- Create a new website
- Select "Garden furniture store"
- Select the Orchid theme (the one in the middle to this day)
- Drag & drop the Banner snippet, 2 out of the 3 images used in this
  snippet will use the theme images (images about flowers) instead of
  images of furniture (related to the selected industry)

[1]: https://github.com/odoo/odoo/commit/3cbdf754ff8fac8a77887c4307b658cb86b0be1d

closes odoo/odoo#141117

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-06 11:16:48 +00:00
Louis (loco) f13a8afdbc [FIX] website: re-render the visibility selector on field label change
Steps to reproduce the bug:
- Add a form on the website.
- Add two fields on the form ("A" and "B").
- Change the conditional visibility of "B" and put it to "Visible only
if".
- Change the label of "B" and set it to "A".
- Try to change the dependent field.

-> "A" is still on the list of the eligible dependent fields. It should
not be the case as setting this field as a dependent field would create
a circular dependency.

To solve the problem, the file visibility selector is rerendered after
modifying a field label. Because of the `_findCircular()` check at the
rerendering, the problematic field will not be displayed in the list of
of the eligible dependent fields.

task-3291044

closes odoo/odoo#140928

X-original-commit: 788218dff61e65f2213c31ebc660183ef3e73087
Signed-off-by: Arthur Detroux (ard) <ard@odoo.com>
Signed-off-by: Colin Louis (loco) <loco@odoo.com>
2023-11-06 11:16:42 +00:00
Louis (loco) 92e3cf48b2 [FIX] website: prevent circular dependency of renamed fields
Steps to reproduce the bug:
- Drop a "Form" snippet on the website.
- Change the "Label" of the first field (and put it to "test" for
example).
- Select the last field and change its visibility so that it depends on
the first field.
- Change the "Label" of the selected field and put it to the same than
the first one ("test").
- Save.

-> Traceback "Maximum call stack exceeded" appears.

At the end of the procedure, the last field visibility depends on itself
and a circular visibility dependency is created. To solve the problem,
this commit checks that the renamed field does not bring a circular
dependency while updating the dependencies. If it is the case, the
problematic dependency is deleted.
To resolve this bug, the `visitedFields` set has been introduced. Its
goal is to register the already visited fields to not enter an infinite
check loop. Let's take an example to illustrate this: Imagine there is a
form of type A->B->C->D. In this form, the field "A" depends on "B" that
depends on "C" that depends on "D". Imagine you rename "D" by "B". You
now have A->B->C->B. The system will check that the renamed field does
not create a circular dependency. To do so, it will apply
`_recursiveFindCircular` with "A" as the `targetFieldEl` and "B" as the
`dependentFieldEl`. Because there is a circular dependency between "C"
and "B", the system would enter in an infinite loop. Note that we do not
notify the system if such indirect circular dependency has been found as
it will be detected as a direct circular dependency  while the system
will apply `_recursiveFindCircular` with `C` as the `targetFieldEl`.

task-3291044

X-original-commit: 5f0b62fc30867e03e69a824d5e426bf3f74c8ff5
Part-of: odoo/odoo#140928
2023-11-06 11:16:42 +00:00
Louis (loco) 34e4049b80 [FIX] website: prevent circular dependency of duplicated fields
Steps to reproduce the bug:
- Drop a "Form" snippet on the website.
- Add three fields and rename them by "a", "b" and "b".
- Change the conditional visibility of the first "b" and make it depend
on "a".
- Change the conditional visibility of "a" and make it depend on "b".
- Save.

-> Traceback "Maximum call stack exceeded" appears.

A field with a conditional visibility is visible if at at least one
field with the dependency name is visible. The problem is that in our
case, it exists a circular dependency between "a" and one of the "b"
leading to an infinite loop during this check. Before this commit all
the fields of the form were checked and all the labels of the fields
that do not create a circular dependency were proposed in the file
visibility selector. The problem is that in our case, one of the "b"
field does not create a circular dependency while the other does. To
solve the problem, the `_recursiveFindCircular()` function has been
adapted in order to not propose a label that would create a circular
dependency in the file visibility selector.

task-3291044

X-original-commit: f010b128be29e884c89dd58f1c575a163e229d5b
Part-of: odoo/odoo#140928
2023-11-06 11:16:42 +00:00
Odoo Translation Bot 5d2bc9e9b3 [I18N] Update translation terms from Transifex 2023-11-05 00:21:55 +01:00
Romain Estievenart eb399b5251 [FIX] website: Missing border-0 on AutoCompleteWithPages container
There is a visual "glitch" in the website builder, there is a 2px white
bar (2x1px border) at the bottom of the screen in edit mode.

Steps to reproduce:

* Enter edit mode on a page
* Drag & drop a few snippets to have a scrollbar
  => The bottom white bar appears

closes odoo/odoo#140979

Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
2023-11-04 12:21:46 +00:00
Romain Estievenart 969e83c2b3 [FIX] website: AutoCompleteWithPages doesn't work correctly on Safari.
Since we remove jQuery UI[1], the owl component `AutoCompleteWithPages`
doesn't work correctly on Safari.

When we clicked on the `AutoCompleteWithPages` input the code in the
`AutoComplete` component `onFocus` make a selection on the input of the
`AutoComplete` component and not on the `AutoCompleteWithPages` input
this make a unwanted effect such as blur the clicked input and focus
the other input. This commit fixes that.

Steps to reproduce:

* With Safari, open the `Website` app
* Click on `Site` > `Edit Menu` > `Add Menu Item`
* You can't type in the url field and if you spam click on its.
  Sometimes, it produces a browser crashes

Links

[1]: https://github.com/odoo/odoo/commit/99f5ae32d3ee4a3dcc75e31ad0a88f42d6ce3589

Part-of: odoo/odoo#140979
2023-11-04 12:21:46 +00:00
Brieuc-brd 3a76a9326e [FIX] website: adapt offcanvas menu height on mobile
Prior to this commit, on mobile, we couldn't see the entire offcanvas
menu because the browser's UI was hidding part of it.

To fix that, this commit adapts the height of the offcanvas menu using
`dvh` unit.

task-3582657

closes odoo/odoo#141032

Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-11-04 09:05:37 +00:00
xO-Tx 9cd1b671f4 [IMP] website, web_editor: integrate new text highlights designs
task-3285817

closes odoo/odoo#140372

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-04 00:38:25 +00:00
stefanorigano (SRI) 9a17a7aa07 [IMP] website, web_editor: restore default inputs to white + add config
This PR refactor the "inputs design system" by reverting the correlation
'$input-bg == $light == color-3', initially introduced by #120302.

Beside ensuring color-consistency, the former system aimed to simplify
palette edition by clarifying how color-3 was used (simply all the UI
elements...).

While the former system was responsive to user customization and
color-presets, it didn't necessarily delight everyone's discerning
taste, at least not with default settings/palette.

This commit enforces a classic "white with borders" design that's
independent from the color palette and doesn't adapt to color-presets.
The rationale behind this decision is that the need for non-white inputs
is "nonexistent" and exceptional cases should be addressed using the
SCSS editor.

As a workaround to ease edition for users that still wants to challenge
themselves with the creation of "not standard" palettes/designs, this
commit introduce a colorPicker option assigned to $input-bg.
The hope is that this new controller help users finding a "compromise
color" that could work with any color-presets.

task-3568806

closes odoo/odoo#139642

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-04 00:38:19 +00:00
Benoit Socias 261d803239 [IMP] website: remove duplicate and conflicting classes
When introducing the templates for the "new page" feature in [1], on
some elements classes ended up being specified twice, or being added
without removing a contradicting class (e.g. different bottom paddings)

This commit adjusts the blocks of the new page templates so that:
- no class appears twice
- only the visually applied class of several conflicting classes is kept

For `pt*`, `pb*` and `o_cc*` the class with the highest number is the
visually applied one.

[1]: https://github.com/odoo/odoo/commit/b27d52c193a08fe6a4471c844afa3d01a33ccace

task-3562147

closes odoo/odoo#139572

Related: odoo/design-themes#731
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-11-04 00:38:18 +00:00
Robin Lejeune (role) b1414d3c30 [FIX] website, website_sale: remove forced options views in headers
Since [this PR], some headers have some preselected options. For
instance, by default the header_sales_one displays social icons without
colors and a CTA button with rounded sides. However, if one modifies the
option in the panel, it appears to be working, but upon save it goes
back to no_icon_color / rounded sides.
This happens because the option is forced by the header template. That
behavior takes the precedence over the user's option choice.

As there is no proper way to make it work without modifying the model,
this commit removes the forced option on the templates for Odoo 17.
It should be properly reintroduced in master.

[this PR]: https://github.com/odoo/odoo/pull/119650

task-3576074

closes odoo/odoo#140669

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-03 16:43:35 +00:00
Robin Lejeune (role) 143bdfa13d [FIX] web_editor, website: fix columns mobile orders
This follows [commit 1], which introduced a way to separately reorder
columns on mobile and desktop.
This commit replaces the custom mobile order classes with the Bootstrap
`.order-x` classes.
It also ensures those orders are not used for mass mailing in case the
editor composes their email on a small window. The reorder would indeed
not have any effect for the end users in such a case.

[commit 1]: https://github.com/odoo/odoo/commit/710d000f1872fd99b41d52ec3d6923756bba7cba

task-3576046

closes odoo/odoo#140362

Signed-off-by: Arthur Detroux (ard) <ard@odoo.com>
2023-11-03 16:43:29 +00:00
Benoit Socias fd7afa25f0 [FIX] website: restore button font-family in theme options
Since [1] when the layout of the theme options was reorganized, the
button's font-family option was not displayed anymore.

This commit restores the button's font-family inside the "Button"
section, before the button "Padding" options.

[1]: https://github.com/odoo/odoo/commit/388e4bb2bfcaebdd4ff30277fb49a034592d7086

task-3478355

closes odoo/odoo#140692

X-original-commit: 718ae15606fe452da26fe9c4fa9c90cc443fd8f1
Signed-off-by: Soukéina Bojabza (sobo) <sobo@odoo.com>
Signed-off-by: Benoit Socias (bso) <bso@odoo.com>
2023-11-03 10:46:08 +00:00
Nicolas Bayet cbed990924 [FIX] website: prevent unbreakable rollback in autoHideMenu
Whenever calling `_adapt` in `autoHideMenu`, whenever the odooEditor
is active, some mutations could trigger the unbreakable rollback of
the odoo editor. We should not check for unbreakable in `_adapt` as
the unbreakable mechanism is not meant to be used in that context.

task-3439226

closes odoo/odoo#139209

Related: odoo/enterprise#49220
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
2023-11-02 21:02:44 +00:00
Samuel Degueldre 02aac0f59c [FIX] website: add step delay
Part-of: odoo/odoo#139209
2023-11-02 21:02:44 +00:00
Samuel Degueldre eaa6e4fdb3 [FIX] website: correctly debounce adaptAnchor
Previously, we attempted to debounce in what appeared to be an override
of the onWillStart method, but this method doesn't actually exist on the
parent classes and as such is never registered with the onWillStart
hook. This commit fixes that by registering it in an override of the
setup method instead.

task-3439226

Part-of: odoo/odoo#139209
2023-11-02 21:02:44 +00:00
Romain Estievenart 99f5ae32d3 [REF] web(site): migrate jQuery.autocomplete to owl component
Adapt the website industry selection autocomplete inside the
configurator to use the autocomplete owl component instead of jquery
autocomplete

task-3439226

Part-of: odoo/odoo#139209
2023-11-02 21:02:44 +00:00
Romain Estievenart 86a9171ec7 [REF] web(site): migrate jQueryUI urlautocomplete to owl component
*: web, website, website_form_project

Remove the jQuery UI Widget `urlautocomplete` by using made some
refactor to allow usage of the owl component.

task-3439226

Part-of: odoo/odoo#139209
2023-11-02 21:02:44 +00:00
Antoine (anso) f3a9952065 [FIX] website: set s_text_cover background as primary
This commit sets `s_text_cover` default color preset to `o_cc4` to make
it look more like the header of "Anelusia theme" that was the initial
reference for the design of this snippet.

It also fixes a typo in `o_ccx` class introduced in commit [1] at the
same time actually.

[1]: https://github.com/odoo/odoo/commit/5ac340b1b27c9527463e2eed65fe2e7768b36702

task-3568868

closes odoo/odoo#140721

X-original-commit: 66f63ab23159fae86ba81369287e1cf8aac66d87
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-11-02 16:57:57 +00:00
Antoine Guenet 9b06f097b8 [IMP] web_editor, website: reorganize non-floating toolbar buttons
This rearranges the non-floating toolbar buttons so that the AI, animate
and highlight buttons are grouped together at the bottom and take up the
full width of the toolbar, and so that the options appear below them.

task-3572337

closes odoo/odoo#139857

Signed-off-by: Geelen Sébastien (sge) <sge@odoo.com>
2023-11-02 16:57:48 +00:00
Louis (wil) a46c800d53 [I18N] *: export source terms
closes odoo/odoo#140529

Related: odoo/enterprise#49925
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-10-31 15:54:32 +00:00
Benjamin Vray ad8feceedf [FIX] website: fix hover effect and Images Wall
Steps to reproduce the bug:

- In Website edit mode, drag and drop an "Images Wall" snippet onto the
page.
- Click on the first image of this snippet.
- In the "Animation" options of the image, select "On Hover".
- Save the page.
- Click on the first image of the "Images Wall" snippet.
- Bug: The image in the slideshow still has the overlay that appeared
due to the hover effect.

This commit fixes this issue by resetting images to their original
source in the slideshow.

task-3562305

closes odoo/odoo#139695

Signed-off-by: Soukéina Bojabza (sobo) <sobo@odoo.com>
2023-10-31 13:26:39 +00:00
Morgane (morm) 6b1d11a60d [IMP] website: search button color
Prior to this commit, the button with the search icon, inside the search
bar,  was `primary, which is not consistent with the filters that are
`light`.

Part-of: odoo/odoo#137729
2023-10-31 13:26:38 +00:00