diff options
| author | Aaron Bohy <aab@odoo.com> | 2016-04-21 13:58:22 +0200 |
|---|---|---|
| committer | Géry Debongnie <ged@odoo.com> | 2016-04-21 15:21:42 +0200 |
| commit | 6768bbfcc02e0f498110cda2ba9adbc2fd23d24c (patch) | |
| tree | 7dccb1019434582874b285276189b1b3dcbb96a9 /addons/web/static/src/less/utils.less | |
| parent | e1bfd3fbda97ac7a64a585b07be161d5be606cf9 (diff) | |
| parent | 8e440b173e3b273b3aac541f2ec12527f67dfa60 (diff) | |
[MERGE] *: stop duplicating web
Avoid duplicating web addon in enterprise by extracting a common basis.
Enterprise features stay in enterprise, but use that common basis.
In web, mainly:
- JS refactoring and linting
- Conversion of .sass into .less split into multiple files
- Templates cleaning and DOM simplification
- Re-generation of web.pot, and update of .po files
Minor tweaks in some other addons to make them work with this new structure.
Diffstat (limited to 'addons/web/static/src/less/utils.less')
| -rw-r--r-- | addons/web/static/src/less/utils.less | 45 |
1 files changed, 37 insertions, 8 deletions
diff --git a/addons/web/static/src/less/utils.less b/addons/web/static/src/less/utils.less index 302f79edf03..836ae6453dc 100644 --- a/addons/web/static/src/less/utils.less +++ b/addons/web/static/src/less/utils.less @@ -116,14 +116,6 @@ background-size: @size; } -// Background gradient -.o-linear-gradient(@deg: 45deg, @start-color: #555, @end-color: #333) { - background-repeat: repeat-x; - background-image: -webkit-linear-gradient(@deg, @start-color, @end-color); - background-image: -o-linear-gradient(@deg, @start-color, @end-color); - background-image: linear-gradient(@deg, @start-color, @end-color); -} - // ------------------------------------------------------------------ // Dropdowns // ------------------------------------------------------------------ @@ -221,3 +213,40 @@ text-overflow: ellipsis; vertical-align: top; // To update display context changed by overflow:hidden } + +// ------------------------------------------------------------------ +// Gradients +// ------------------------------------------------------------------ +.o-linear-gradient(@deg: 45deg, @start-color: #555, @end-color: #333) { + background-repeat: repeat-x; + background-image: -webkit-linear-gradient(@deg, @start-color, @end-color); + background-image: -o-linear-gradient(@deg, @start-color, @end-color); + background-image: linear-gradient(@deg, @start-color, @end-color); +} +.o-vertical-gradient(@startColor: #555, @endColor: #333) { + background-color: mix(@startColor, @endColor); + background-image: -webkit-gradient(linear, left top, left bottom, from(@startColor), to(@endColor)); + background-image: -webkit-linear-gradient(top, @startColor, @endColor); + background-image: -moz-linear-gradient(top, @startColor, @endColor); + background-image: -ms-linear-gradient(top, @startColor, @endColor); + background-image: -o-linear-gradient(top, @startColor, @endColor); + background-image: linear-gradient(to bottom, @startColor, @endColor); +} +.o-skew-gradient(@startColor: #555, @endColor: #333) { + background-color: @endColor; + background: -moz-linear-gradient(135deg, @endColor, @startColor); + background: -o-linear-gradient(135deg, @startColor, @endColor); + background: -webkit-gradient(linear, left top, right bottom, from(@startColor), to(@endColor)); + background: -ms-linear-gradient(top, @startColor, @endColor); +} + +// ------------------------------------------------------------------ +// Transform +// ------------------------------------------------------------------ +.o-transform(@transform) { + -webkit-transform: @transform; + -moz-transform: @transform; + -ms-transform: @transform; + -o-transform: @transform; + transform: @transform; +} |
