diff options
author | Leif Åstrand <leif@vaadin.com> | 2014-03-18 15:40:01 +0200 |
---|---|---|
committer | Leif Åstrand <leif@vaadin.com> | 2014-03-18 15:40:50 +0200 |
commit | 4420f52578e245045677f88852f1ba3f405e88a3 (patch) | |
tree | 5f5c3f6c03326afe580f26eb395963f5c1e50804 /WebContent | |
parent | 5d0b53bad905a2f77e4e75a3e307a69824c9b87d (diff) | |
parent | 796063f898ef34bbbe457164976ae96c802c1bc7 (diff) | |
download | vaadin-framework-4420f52578e245045677f88852f1ba3f405e88a3.tar.gz vaadin-framework-4420f52578e245045677f88852f1ba3f405e88a3.zip |
Merge branch 'master' into grid
Change-Id: Ia9d156009a3f1b4e61f12eb415040670a52d7876
Diffstat (limited to 'WebContent')
-rw-r--r-- | WebContent/VAADIN/themes/base/base.scss | 4 | ||||
-rw-r--r-- | WebContent/VAADIN/themes/base/escalator/escalator.scss | 117 | ||||
-rw-r--r-- | WebContent/VAADIN/themes/base/grid/grid.scss | 3 | ||||
-rw-r--r-- | WebContent/VAADIN/themes/reindeer-tests/styles.css | 4 |
4 files changed, 128 insertions, 0 deletions
diff --git a/WebContent/VAADIN/themes/base/base.scss b/WebContent/VAADIN/themes/base/base.scss index fd3c5d067d..58274edacb 100644 --- a/WebContent/VAADIN/themes/base/base.scss +++ b/WebContent/VAADIN/themes/base/base.scss @@ -15,8 +15,10 @@ @import "inlinedatefield/inlinedatefield.scss"; @import "dragwrapper/dragwrapper.scss"; @import "embedded/embedded.scss"; +@import "escalator/escalator.scss"; @import "fonts/fonts.scss"; @import "formlayout/formlayout.scss"; +@import "grid/grid.scss"; @import "gridlayout/gridlayout.scss"; @import "label/label.scss"; @import "link/link.scss"; @@ -90,7 +92,9 @@ $line-height: normal; @include base-inline-datefield; @include base-dragwrapper; @include base-embedded; + @include base-escalator; @include base-formlayout; + @include base-grid; @include base-gridlayout; @include base-label; @include base-link; diff --git a/WebContent/VAADIN/themes/base/escalator/escalator.scss b/WebContent/VAADIN/themes/base/escalator/escalator.scss new file mode 100644 index 0000000000..6f85a541ee --- /dev/null +++ b/WebContent/VAADIN/themes/base/escalator/escalator.scss @@ -0,0 +1,117 @@ +@mixin base-escalator($primaryStyleName : v-escalator) { + +$background-color: white; +$border-color: #aaa; + +.#{$primaryStyleName} { + position: relative; + background-color: $background-color; +} + +.#{$primaryStyleName}-scroller { + position: absolute; + overflow: auto; + z-index: 20; +} + +.#{$primaryStyleName}-scroller-horizontal { + left: 0; /* Left position adjusted to align with frozen columns */ + right: 0; + bottom: 0; + overflow-y: hidden; + -ms-overflow-y: hidden; +} + +.#{$primaryStyleName}-scroller-vertical { + right: 0; + top: 0; /* this will be overridden by code, but it's a good default behavior */ + bottom: 0; /* this will be overridden by code, but it's a good default behavior */ + overflow-x: hidden; + -ms-overflow-x: hidden; +} + +.#{$primaryStyleName}-tablewrapper { + position: absolute; + overflow: hidden; +} + +.#{$primaryStyleName}-tablewrapper > table { + border-spacing: 0; + table-layout: fixed; + width: inherit; /* a decent default fallback */ +} + +.#{$primaryStyleName}-header, +.#{$primaryStyleName}-body, +.#{$primaryStyleName}-footer { + position: absolute; + left: 0; + width: inherit; + z-index: 10; +} + +.#{$primaryStyleName}-header { top: 0; } +.#{$primaryStyleName}-footer { bottom: 0; } + +.#{$primaryStyleName}-body { + z-index: 0; + top: 0; + + .#{$primaryStyleName}-row { + position: absolute; + top: 0; + left: 0; + } +} + +.#{$primaryStyleName}-row { + display: block; + + .v-ie8 & { + /* IE8 doesn't let table rows be longer than body only with display block. Moar hax. */ + float: left; + clear: left; + + /* + * The inline style of margin-top from the <tbody> to offset the header's dimension is, + * for some strange reason, inherited into each contained <tr>. + * We need to cancel it: + */ + margin-top: 0; + } + + > td, > th { + /* IE8 likes the bgcolor here instead of on the row */ + background-color: $background-color; + } +} + + +.#{$primaryStyleName}-row { + width: inherit; +} + +.#{$primaryStyleName}-cell { + display: block; + float: left; + border: 1px solid $border-color; + padding: 2px; + white-space: nowrap; + -moz-box-sizing: border-box; + box-sizing: border-box; + overflow:hidden; + + /* + * Because Vaadin changes the font size after the initial render, we + * need to mention the font size here explicitly, otherwise automatic + * row height detection gets broken. + */ + font-size: $font-size; +} + +.#{$primaryStyleName}-cell.frozen { + position: relative; + z-index: 0; +} + +} diff --git a/WebContent/VAADIN/themes/base/grid/grid.scss b/WebContent/VAADIN/themes/base/grid/grid.scss new file mode 100644 index 0000000000..9f7a2d8664 --- /dev/null +++ b/WebContent/VAADIN/themes/base/grid/grid.scss @@ -0,0 +1,3 @@ +@mixin base-grid($primaryStyleName : v-grid) { + @include base-escalator($primaryStyleName); +}
\ No newline at end of file diff --git a/WebContent/VAADIN/themes/reindeer-tests/styles.css b/WebContent/VAADIN/themes/reindeer-tests/styles.css index 679de01b9c..9dd88707d1 100644 --- a/WebContent/VAADIN/themes/reindeer-tests/styles.css +++ b/WebContent/VAADIN/themes/reindeer-tests/styles.css @@ -32,3 +32,7 @@ .popup-style .v-datefield-calendarpanel-body { background: yellow; } + +#escalator .v-escalator-body .v-escalator-cell { + height: 50px; +}
\ No newline at end of file |