summaryrefslogtreecommitdiff
path: root/addons/web_unsplash/static/src/xml
diff options
context:
space:
mode:
authorAndrea Ulliana <aul@odoo.com>2018-11-27 09:19:45 +0000
committerqsm-odoo <qsm@odoo.com>2018-12-04 10:06:11 +0000
commit1f847a1e2eed63086448ceb451bd1a2f87c8c641 (patch)
treec8b321dd526200e4c520929b874bca5496f81b82 /addons/web_unsplash/static/src/xml
parent7d6a9924e5bb8ff14defeaa07002c08920222d7b (diff)
[IMP] web_editor, *: improve media dialog
* web_unsplash, website_sale - Visual improvements and cleaning in each tab: video, documents, pictogram, images. - Only one search input for both the local library and unsplash. - Replace the idea of multiple pages by adding a 'Load More' button. task-1896705
Diffstat (limited to 'addons/web_unsplash/static/src/xml')
-rw-r--r--addons/web_unsplash/static/src/xml/unsplash_image_widget.xml25
1 files changed, 17 insertions, 8 deletions
diff --git a/addons/web_unsplash/static/src/xml/unsplash_image_widget.xml b/addons/web_unsplash/static/src/xml/unsplash_image_widget.xml
index 05202e073b2..cc826a17aa2 100644
--- a/addons/web_unsplash/static/src/xml/unsplash_image_widget.xml
+++ b/addons/web_unsplash/static/src/xml/unsplash_image_widget.xml
@@ -2,14 +2,23 @@
<templates id="template" xml:space="preserve">
<t t-extend="web_editor.dialog.image">
- <t t-jquery=".o_media_image_card .form-inline" t-operation="append">
- <div class="ml-auto border-left pl-4">
- <span class="d-block font-weight-bold">Photos by <a href="https://unsplash.com" target="_blank">Unsplash</a></span>
- <input type="text" class="form-control unsplash_search mr8" placeholder="Search free high-resolution photos" style="width: 250px;"/>
- </div>
- </t>
<t t-jquery=".existing-attachments" t-operation="after">
- <div class="unsplash_img_container container-fluid"></div>
+ <div class="unsplash_img_container"></div>
+ </t>
+</t>
+
+<t t-extend="web_editor.dialog.files.submenu">
+ <t t-jquery=".o_search_div" t-operation="append">
+ <div class="dropdown-menu o_dropdown_search w-100" style="background-color:#efefef;">
+ <button class="dropdown-item o_search_an_image o_size_dropdown_item" type="button">
+ Search among my images for:
+ <div class="font-weight-bold o_search_value_input"></div>
+ </button>
+ <button class="dropdown-item o_search_from_unsplash o_size_dropdown_item" type="button">
+ Search from Unsplash for:
+ <div class="font-weight-bold o_search_value_input"></div>
+ </button>
+ </div>
</t>
</t>
@@ -17,7 +26,7 @@
<div class="row mt16" t-as="row" t-foreach="rows">
<div class="col-sm-2 o_unsplash_img_cell text-center" t-as="img" t-foreach="row">
<div class="o_image o_webimage" t-att-data-imgid="img.id" t-att-data-url="img.urls.regular" t-att-data-download-url="img.links.download_location">
- <img class="img-fluid" t-att-src="img.urls.thumb" />
+ <img class="img-fluid" t-att-src="img.urls.thumb"/>
</div>
<div class="author_name"><a t-att-href="img.user.links.html" target="_blank"><t t-esc="img.user.name"/></a></div>
</div>