<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Odoo/addons/web_editor/static/src/js/common/utils.js, branch 14.0</title>
<subtitle>The current checkout of upstream Odoo</subtitle>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/'/>
<entry>
<title>[FIX] web_editor: restore adding bg video in some context</title>
<updated>2020-10-07T14:22:17+00:00</updated>
<author>
<name>qsm-odoo</name>
<email>qsm@odoo.com</email>
</author>
<published>2020-10-07T14:01:32+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=9c2d02f6e78a01eca02de90dd9406effa0308d27'/>
<id>9c2d02f6e78a01eca02de90dd9406effa0308d27</id>
<content type='text'>
Since [1] the feature was broken because of a traceback which occured
while trying parse a background image URL of an element which is not
in the DOM.

[1]: https://github.com/odoo/odoo/commit/7558dcce791f707e3f3470835133f91ec7ff074f

closes odoo/odoo#59425

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Since [1] the feature was broken because of a traceback which occured
while trying parse a background image URL of an element which is not
in the DOM.

[1]: https://github.com/odoo/odoo/commit/7558dcce791f707e3f3470835133f91ec7ff074f

closes odoo/odoo#59425

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] web_editor: fix background-image urls becoming absolute on drop</title>
<updated>2020-10-05T11:13:50+00:00</updated>
<author>
<name>Samuel Degueldre</name>
<email>sad@odoo.com</email>
</author>
<published>2020-10-05T11:13:50+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=7558dcce791f707e3f3470835133f91ec7ff074f'/>
<id>7558dcce791f707e3f3470835133f91ec7ff074f</id>
<content type='text'>
With the recent addition of the parallax option on all snippets,
background-image urls were being converted from relative to absolute on
snippet-drop. This was caused by trying to read the background-image's
url and setting it back onto the target, but there is no way to reliably
read a background-image url in relative form, so it was returned in
absolute form and then written back to the element as is.

This commit fixes that by always converting the absolute URL to relative
when they are on the same origin as the database.

task-2312878

closes odoo/odoo#59098

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With the recent addition of the parallax option on all snippets,
background-image urls were being converted from relative to absolute on
snippet-drop. This was caused by trying to read the background-image's
url and setting it back onto the target, but there is no way to reliably
read a background-image url in relative form, so it was returned in
absolute form and then written back to the element as is.

This commit fixes that by always converting the absolute URL to relative
when they are on the same origin as the database.

task-2312878

closes odoo/odoo#59098

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] web_editor, *: make media-dialog search odoo media-library</title>
<updated>2020-09-16T07:01:15+00:00</updated>
<author>
<name>Samuel Degueldre</name>
<email>sad@odoo.com</email>
</author>
<published>2020-08-12T10:15:51+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=7a1308b426f94b33e2bd55e5d58e661067e26ff3'/>
<id>7a1308b426f94b33e2bd55e5d58e661067e26ff3</id>
<content type='text'>
*: website, web_unsplash, website_blog

We have recently created an odoo media library that exposes a public API
for searching for open-source media, including dynamic SVGs that can be
used with the dynamic background-shape system to create illustrations
whose colors can be changed by the user. This commit adds the
corresponding client-side functionalty: search for the images in the
media-library, creating a corresponding attachment when selected, as
well as an option to customize the colors of the dynamic SVGs.

In the process, adaptations have been made in the web_unsplash module to
avoid duplicating code and to adapt code that was making assumptions
that are no longer valid.

To make new users more aware of this feature, all default images have
been hidden from the media-dialog, so that the user is prompted so
search for images. Some tests and tours that were relying on having
default images in the media-dialog (eg in website_blog) have been
adapted to match.

task-2316651
Linked to: odoo/iap-apps#235

closes odoo/odoo#56479

Signed-off-by: Jérémy Kersten (jke) &lt;jke@openerp.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
*: website, web_unsplash, website_blog

We have recently created an odoo media library that exposes a public API
for searching for open-source media, including dynamic SVGs that can be
used with the dynamic background-shape system to create illustrations
whose colors can be changed by the user. This commit adds the
corresponding client-side functionalty: search for the images in the
media-library, creating a corresponding attachment when selected, as
well as an option to customize the colors of the dynamic SVGs.

In the process, adaptations have been made in the web_unsplash module to
avoid duplicating code and to adapt code that was making assumptions
that are no longer valid.

To make new users more aware of this feature, all default images have
been hidden from the media-dialog, so that the user is prompted so
search for images. Some tests and tours that were relying on having
default images in the media-dialog (eg in website_blog) have been
adapted to match.

task-2316651
Linked to: odoo/iap-apps#235

closes odoo/odoo#56479

Signed-off-by: Jérémy Kersten (jke) &lt;jke@openerp.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] web_editor, website: add background shapes snippet option</title>
<updated>2020-08-07T15:34:45+00:00</updated>
<author>
<name>Samuel Degueldre</name>
<email>sad@odoo.com</email>
</author>
<published>2020-07-31T06:47:34+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=b84e0af742c51b88b4c108ebec2d0c7fff4b7483'/>
<id>b84e0af742c51b88b4c108ebec2d0c7fff4b7483</id>
<content type='text'>
This commit adds a new snippet option allowing the user to choose one of
a series of SVG shapes as their background, or to be overlaid over the
background image of a snippet and to customize the colors of those
shapes.

Part of https://github.com/odoo/odoo/pull/53017
task-2210790

closes odoo/odoo#53017

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit adds a new snippet option allowing the user to choose one of
a series of SVG shapes as their background, or to be overlaid over the
background image of a snippet and to customize the colors of those
shapes.

Part of https://github.com/odoo/odoo/pull/53017
task-2210790

closes odoo/odoo#53017

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[REF] web_editor: move normalizeColor function to we-utils for reuse</title>
<updated>2020-08-07T15:15:52+00:00</updated>
<author>
<name>Samuel Degueldre</name>
<email>sad@odoo.com</email>
</author>
<published>2020-06-26T09:17:15+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=995b20fd6ac3eb121ed469df70492845c00ffb58'/>
<id>995b20fd6ac3eb121ed469df70492845c00ffb58</id>
<content type='text'>
Part of https://github.com/odoo/odoo/pull/53017
task-2210790</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Part of https://github.com/odoo/odoo/pull/53017
task-2210790</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] web_editor, *: restore editor UI for selected CSS variables</title>
<updated>2020-07-22T10:31:28+00:00</updated>
<author>
<name>qsm-odoo</name>
<email>qsm@odoo.com</email>
</author>
<published>2020-07-22T10:04:17+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=85531edd1be76287daeb54e1425cd3f59e1c138c'/>
<id>85531edd1be76287daeb54e1425cd3f59e1c138c</id>
<content type='text'>
*: website

Commit [1] broke the UI for some options related to CSS variables when
using Chrome. The commit made sure the string-value CSS variables are
printed with quotes, so that the JS representation of the CSS values can
distinguish them (strings = strings with surrounding quotes, others like
colors, numbers, etc = strings without surrounding quotes). With chrome,
the printed surrounding single quotes are read as double quotes for
strange reasons though... so the value "a" was not considered equal to
the value 'a'.

This commit makes sure surrounding quotes are normalized. This is done
through a new utility function to read CSS variables. This also makes
sure the values are trimmed, and colors normalized.

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

closes odoo/odoo#54757

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
*: website

Commit [1] broke the UI for some options related to CSS variables when
using Chrome. The commit made sure the string-value CSS variables are
printed with quotes, so that the JS representation of the CSS values can
distinguish them (strings = strings with surrounding quotes, others like
colors, numbers, etc = strings without surrounding quotes). With chrome,
the printed surrounding single quotes are read as double quotes for
strange reasons though... so the value "a" was not considered equal to
the value 'a'.

This commit makes sure surrounding quotes are normalized. This is done
through a new utility function to read CSS variables. This also makes
sure the values are trimmed, and colors normalized.

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

closes odoo/odoo#54757

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] web_editor: fix color classes for non-background properties</title>
<updated>2020-06-08T13:19:21+00:00</updated>
<author>
<name>qsm-odoo</name>
<email>qsm@odoo.com</email>
</author>
<published>2020-06-08T12:45:56+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=7813f7b555c9f9352fd631dbe3f9bc17c5538114'/>
<id>7813f7b555c9f9352fd631dbe3f9bc17c5538114</id>
<content type='text'>
The computed preview for non-background properties (e.g. borders) was
wrong in the left panel since the color presets classes were considered
by mistake.

Part of https://github.com/odoo/odoo/pull/52605

closes odoo/odoo#52605

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The computed preview for non-background properties (e.g. borders) was
wrong in the left panel since the color presets classes were considered
by mistake.

Part of https://github.com/odoo/odoo/pull/52605

closes odoo/odoo#52605

Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] web_editor, *: integrate new o_cc${xxx} classes in the colorpicker</title>
<updated>2020-06-02T09:42:19+00:00</updated>
<author>
<name>qsm-odoo</name>
<email>qsm@odoo.com</email>
</author>
<published>2020-05-28T10:04:43+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=d9c4d928f7c7e148d024cb56f53e6bfb98389f6d'/>
<id>d9c4d928f7c7e148d024cb56f53e6bfb98389f6d</id>
<content type='text'>
*: website

Part of https://github.com/odoo/odoo/pull/45856
task-2197038</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
*: website

Part of https://github.com/odoo/odoo/pull/45856
task-2197038</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] web_editor, *: make Colorpicker a Widget</title>
<updated>2020-05-14T22:45:33+00:00</updated>
<author>
<name>fja-odoo</name>
<email>fja@odoo.com</email>
</author>
<published>2020-05-06T08:45:53+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=a72c9adbe5e60ba178e431e42a81334f85786942'/>
<id>a72c9adbe5e60ba178e431e42a81334f85786942</id>
<content type='text'>
*: website, web

Move the colorpicker dialog logic into a colorpicker *widget*, which the
colorpicker dialog will now instantiate.

Part of https://github.com/odoo/odoo/pull/46088
task-2195313</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
*: website, web

Move the colorpicker dialog logic into a colorpicker *widget*, which the
colorpicker dialog will now instantiate.

Part of https://github.com/odoo/odoo/pull/46088
task-2195313</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] web_editor: allow non-alphabetic unit in data-unit</title>
<updated>2020-03-10T17:33:21+00:00</updated>
<author>
<name>Benjamin Vray</name>
<email>bvr@odoo.com</email>
</author>
<published>2020-03-10T11:06:01+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=4e48c3ce0fb9d572658083cf1d42170c8f020600'/>
<id>4e48c3ce0fb9d572658083cf1d42170c8f020600</id>
<content type='text'>
Allow non-alphabetic unit (like percentage) as data-unit value.

task-2194309

closes odoo/odoo#47325

X-original-commit: 1f3dd221134b7b5e5b0eac0ab2ffe447771998b9
Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Allow non-alphabetic unit (like percentage) as data-unit value.

task-2194309

closes odoo/odoo#47325

X-original-commit: 1f3dd221134b7b5e5b0eac0ab2ffe447771998b9
Signed-off-by: Quentin Smetz (qsm) &lt;qsm@odoo.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
