- Repo for opensource odoo website theme (since V13.0)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

49 lines
3.2 KiB

5 years ago
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <odoo>
  3. <template id="theme_customize" inherit_id="theme_common.theme_customize">
  4. <xpath expr="//content[@id='theme_customize_content_navbar']/*" position="before">
  5. <list string="Menu">
  6. <checkbox><opt id="option_hamburger_menu" string="Hamburger" data-xmlid="theme_monglia.website_custom_navigation, theme_monglia.website_custom_navigation_variables, website.no_autohide_menu" data-reload="/"/></checkbox>
  7. <opt data-depends="option_hamburger_menu" string="Left" data-xmlid=""/>
  8. <opt data-depends="option_hamburger_menu" string="Right" data-xmlid="theme_monglia.option_navigation_right_style"/>
  9. </list>
  10. </xpath>
  11. </template>
  12. <template id="website_custom_navigation" inherit_id="website.layout" priority="1">
  13. <xpath expr="//div[@id='wrapwrap']//header//*[hasclass('navbar-toggler')]" position="replace"/>
  14. <xpath expr="//div[@id='wrapwrap']//header//*[hasclass('navbar-brand')]" position="replace">
  15. <h1>$0</h1>
  16. </xpath>
  17. <xpath expr="//div[@id='wrapwrap']//header//*[hasclass('navbar-collapse')]" position="attributes">
  18. <attribute name="class"/>
  19. </xpath>
  20. <xpath expr="//div[@id='wrapwrap']//header//*[@id='top_menu']" position="attributes">
  21. <attribute name="class">nav navbar-nav</attribute>
  22. </xpath>
  23. <xpath expr="//div[@id='wrapwrap']//header//*[@id='top_menu']/*[hasclass('divider')]" position="replace"/>
  24. <xpath expr="//div[@id='wrapwrap']//header//div[hasclass('container')]" position="inside">
  25. <h2>
  26. <a t-att-href="website.social_facebook" t-if="website.social_facebook"><i class="fa fa-facebook-square"/></a>
  27. <a t-att-href="website.social_twitter" t-if="website.social_twitter"><i class="fa fa-twitter"/></a>
  28. <a t-att-href="website.social_linkedin" t-if="website.social_linkedin"><i class="fa fa-linkedin"/></a>
  29. <a t-att-href="website.social_youtube" t-if="website.social_youtube"><i class="fa fa-youtube-play"/></a>
  30. <a t-att-href="website.social_github" t-if="website.social_github"><i class="fa fa-github"/></a>
  31. <a t-att-href="website.social_instagram" t-if="website.social_instagram"><i class="fa fa-instagram"/></a>
  32. </h2>
  33. </xpath>
  34. <xpath expr="//div[@id='wrapwrap']//header//div[hasclass('container')]" position="after">
  35. <div id="menuToggle"><i class="fa fa-bars"/></div>
  36. </xpath>
  37. </template>
  38. <template id="website_custom_navigation_variables" inherit_id="theme_monglia._assets_primary_variables">
  39. <xpath expr="//link[last()]" position="after">
  40. <link rel="stylesheet" type="text/scss" href="/theme_monglia/static/src/scss/options/nav/hamburger_layout_variables.scss"/>
  41. </xpath>
  42. </template>
  43. <template id="option_navigation_right_style" inherit_id="theme_monglia.website_custom_navigation_variables" active="False">
  44. <xpath expr="//link[last()]" position="after">
  45. <link rel="stylesheet" type="text/scss" href="/theme_monglia/static/src/scss/options/nav/option_navigation_right.scss"/>
  46. </xpath>
  47. </template>
  48. </odoo>