-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[IMP] to_backend_theme: change background image
- Loading branch information
1 parent
11c585f
commit d61b9bc
Showing
9 changed files
with
144 additions
and
11 deletions.
There are no files selected for viewing
27 changes: 24 additions & 3 deletions
27
to_backend_theme/static/src/components/apps_menu/apps_menu.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,31 @@ | ||
:root { | ||
.o_grid_apps_menu[data-theme="viindoo"] { | ||
.o_apps_menu_opened[data-theme="viindoo"] { | ||
--app-menu-background: url("/to_backend_theme/static/src/img/home-menu-bg-overlay.svg") | ||
|
||
} | ||
|
||
.o_apps_menu_opened[data-theme="milk"] { | ||
--app-menu-background: url("/web_responsive/static/src/img/home-menu-bg-overlay.svg"), | ||
linear-gradient( | ||
to bottom, | ||
#{$app-menu-background-color}, | ||
#{desaturate(lighten($app-menu-background-color, 20%), 15)} | ||
); | ||
} | ||
|
||
.o_apps_menu_opened[data-theme="community"] { | ||
--app-menu-background: url("/web_responsive/static/src/img/home-menu-bg-overlay.svg"), | ||
linear-gradient( | ||
to bottom, | ||
#{$brand-primary-dark}, | ||
#{desaturate(lighten($brand-primary-dark, 20%), 15)} | ||
#{$o-brand-primary}, | ||
#{desaturate(lighten($o-brand-primary, 20%), 15)} | ||
); | ||
} | ||
} | ||
.app-menu-container { | ||
background: none !important | ||
} | ||
|
||
.o_apps_menu_opened { | ||
background: var(--app-menu-background); | ||
} |
7 changes: 7 additions & 0 deletions
7
to_backend_theme/static/src/components/apps_menu/apps_menu.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<templates> | ||
<t t-inherit="web.NavBar.AppsMenu" t-inherit-mode="extension"> | ||
<xpath expr="//Dropdown" position="attributes"> | ||
<attribute name="class">'o_navbar_apps_menu d-none'</attribute> | ||
</xpath> | ||
</t> | ||
</templates> |
19 changes: 19 additions & 0 deletions
19
to_backend_theme/static/src/components/apps_menu/apps_menu_service.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/** @odoo-module **/ | ||
|
||
import { session } from "@web/session"; | ||
import { onMounted } from "@odoo/owl"; | ||
import { AppsMenuAction } from "@web_responsive/components/apps_menu/apps_menu_service"; | ||
import { patch } from "@web/core/utils/patch"; | ||
|
||
|
||
patch(AppsMenuAction.prototype, { | ||
setup() { | ||
super.setup(); | ||
onMounted(() => { | ||
this.theme = session.apps_menu.theme || "viindoo"; | ||
document.body.setAttribute('data-theme', this.theme); | ||
}) | ||
}, | ||
}); | ||
|
||
|
6 changes: 3 additions & 3 deletions
6
to_backend_theme/static/src/components/apps_menu_item/apps_menu_item.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
:root { | ||
.o_grid_apps_menu[data-theme="viindoo"] { | ||
--app-menu-text-color: white; | ||
--app-menu-text-shadow: 1px 1px 1px #{rgba(black, 0.4)}; | ||
--app-menu-hover-background: #{rgba(white, 0.2)}; | ||
--app-menu-text-color: "#374151"; | ||
// --app-menu-text-shadow: 1px 1px 1px #{rgba(black, 0.4)}; | ||
// --app-menu-hover-background: #{rgba(white, 0.2)}; | ||
} | ||
} |
5 changes: 3 additions & 2 deletions
5
to_backend_theme/static/src/components/menu_canonical_searchbar/searchbar.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
:root { | ||
.o_grid_apps_menu[data-theme="viindoo"] { | ||
--apps-menu-scrollbar-background: white; | ||
--apps-menu-empty-search-color: white; | ||
--app-menu-text-color: #374151; | ||
--apps-menu-scrollbar-background: #374151; | ||
--apps-menu-empty-search-color: #374151; | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
viin_brand_common/static/src/webclient/navbar/navbar_variables.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
$o-navbar-entry-color: #374151 !default; | ||
$o-navbar-background: none !default; |