diff --git a/addons/web_editor/static/shapes/Zigs/06.svg b/addons/web_editor/static/shapes/Zigs/06.svg
new file mode 100644
index 00000000000..bb73075f6b9
--- /dev/null
+++ b/addons/web_editor/static/shapes/Zigs/06.svg
@@ -0,0 +1,14 @@
+
diff --git a/addons/web_editor/static/shapes/convert.js b/addons/web_editor/static/shapes/convert.js
index 46e7d3ff991..2688f4aa86d 100644
--- a/addons/web_editor/static/shapes/convert.js
+++ b/addons/web_editor/static/shapes/convert.js
@@ -3,6 +3,8 @@
The following script can be used to convert SVGs exported from illustrator into
a format that's compatible with the shape system. It runs with nodejs. Some
manual conversion may be necessary.
+
+FIXME this script is out-dated.
*/
const fs = require('fs');
@@ -43,6 +45,7 @@ files.filter(f => f.endsWith('svg')).forEach(filePath => {
nonIsometric: fileName.includes('+'),
nonPaletteColors: nonPaletteColors && nonPaletteColors.length ? nonPaletteColors.join(' ') : null,
containsImage: svg.includes('`;
@@ -52,7 +55,7 @@ files.filter(f => f.endsWith('svg')).forEach(filePath => {
} else {
shape.size = '100% auto';
}
- shape.scss = `'${shape.page}/${shape.name}': ('position': ${shape.position[0]}, 'size': ${shape.size}, 'colors': (${shape.colors.join(', ')})${shape.repeatY ? ", 'repeat-y': true" : ""})`;
+ shape.scss = `'${shape.page}/${shape.name}': ('position': ${shape.position[0]}, 'size': ${shape.size}, 'colors': (${shape.colors.join(', ')})${shape.repeatX ? ", 'repeat-x': true" : ""}${shape.repeatY ? ", 'repeat-y': true" : ""})`;
shapes.push(shape);
});
const xml = shapes.map(shape => shape.optionXML).join('\n');
diff --git a/addons/web_editor/static/src/scss/web_editor.frontend.scss b/addons/web_editor/static/src/scss/web_editor.frontend.scss
index a4070004df5..dca621efeb6 100644
--- a/addons/web_editor/static/src/scss/web_editor.frontend.scss
+++ b/addons/web_editor/static/src/scss/web_editor.frontend.scss
@@ -68,9 +68,9 @@
background-image: url("/web_editor/shape/#{$module}/#{$shape}.svg?#{str-slice($url-params, 2)}");
background-position: map-get($style, 'position');
background-size: map-get($style, 'size');
- @if map-get($style, 'repeat-y') {
- background-repeat: repeat-y;
- }
+ background-repeat:
+ if(map-get($style, 'repeat-x'), repeat, no-repeat)
+ if(map-get($style, 'repeat-y'), repeat, no-repeat);
@each $mapping-name, $mapping in $extra-mappings {
$color-to-cc-bg-map: map-merge($default-color-to-cc-bg-map, $mapping or ());
diff --git a/addons/web_editor/static/src/scss/web_editor.variables.scss b/addons/web_editor/static/src/scss/web_editor.variables.scss
index 52d9fefdc6c..d79056ad1f1 100644
--- a/addons/web_editor/static/src/scss/web_editor.variables.scss
+++ b/addons/web_editor/static/src/scss/web_editor.variables.scss
@@ -783,6 +783,7 @@ $o-bg-shapes: ('web_editor': (
'Zigs/03': ('position': top, 'size': 100% auto, 'colors': (1), 'repeat-y': true),
'Zigs/04': ('position': bottom, 'size': 100% auto, 'colors': (1)),
'Zigs/05': ('position': bottom, 'size': 100% auto, 'colors': (3)),
+ 'Zigs/06': ('position': bottom, 'size': 30px 100%, 'colors': (4, 5), 'repeat-x': true),
));
@function change-shape-colors-mapping($module, $shape-name, $mapping, $shapes: $o-bg-shapes) {
diff --git a/addons/web_editor/views/snippets.xml b/addons/web_editor/views/snippets.xml
index a8e303a5ce7..86d3a891163 100644
--- a/addons/web_editor/views/snippets.xml
+++ b/addons/web_editor/views/snippets.xml
@@ -338,6 +338,7 @@
+