summaryrefslogtreecommitdiffstats
path: root/WebContent/VAADIN/themes/liferay
diff options
context:
space:
mode:
authorJohn Ahlroos <john@vaadin.com>2012-10-12 16:05:49 +0300
committerJohn Ahlroos <john@vaadin.com>2012-10-16 13:05:41 +0300
commit014f752f5620433cc0f429821c6464534227dfc9 (patch)
tree43293e5b330a752397d68344333f3d9a43d0648c /WebContent/VAADIN/themes/liferay
parent081d5dc14015838be5b358632474997a8b8855ba (diff)
downloadvaadin-framework-014f752f5620433cc0f429821c6464534227dfc9.tar.gz
vaadin-framework-014f752f5620433cc0f429821c6464534227dfc9.zip
Fixed primary stylename handling for Datefield and InlineDatefield #9903
Change-Id: I4fb460a19a2bf40131172319070edde78851c4a7
Diffstat (limited to 'WebContent/VAADIN/themes/liferay')
-rw-r--r--WebContent/VAADIN/themes/liferay/datefield/datefield.scss76
-rw-r--r--WebContent/VAADIN/themes/liferay/inlinedatefield/inlinedatefield.scss8
-rw-r--r--WebContent/VAADIN/themes/liferay/liferay.scss2
3 files changed, 48 insertions, 38 deletions
diff --git a/WebContent/VAADIN/themes/liferay/datefield/datefield.scss b/WebContent/VAADIN/themes/liferay/datefield/datefield.scss
index 4bfc810b52..ad26907a18 100644
--- a/WebContent/VAADIN/themes/liferay/datefield/datefield.scss
+++ b/WebContent/VAADIN/themes/liferay/datefield/datefield.scss
@@ -1,56 +1,56 @@
-@mixin liferay-datefield {
+@mixin liferay-datefield($name : v-datefield) {
-.v-datefield-popup {
+.#{$name}-popup {
padding: 3px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
}
-.v-datefield-calendarpanel-header {
+.#{$name}-calendarpanel-header {
height: 28px;
}
-.v-datefield-calendarpanel:focus {
+.#{$name}-calendarpanel:focus {
outline: none;
}
-.v-datefield-calendarpanel-body {
+.#{$name}-calendarpanel-body {
text-align: right;
vertical-align: top;
}
-.v-datefield-popupcalendar .v-datefield-button {
+.#{$name}-popupcalendar .#{$name}-button {
background: transparent url(../common/buttons_sprites.png) no-repeat 0 -48px;
width: 24px;
height: 24px;
border: none;
}
-.v-datefield-popupcalendar .v-datefield-button:hover {
+.#{$name}-popupcalendar .#{$name}-button:hover {
background-position: 0px -72px;
}
-.v-datefield-popupcalendar .v-datefield-button:focus {
+.#{$name}-popupcalendar .#{$name}-button:focus {
background-position: 0px -96px;
}
-.v-datefield-month .v-datefield-calendarpanel-month,
-.v-datefield-day .v-datefield-calendarpanel-month,
-.v-datefield-full .v-datefield-calendarpanel-month {
+.#{$name}-month .#{$name}-calendarpanel-month,
+.#{$name}-day .#{$name}-calendarpanel-month,
+.#{$name}-full .#{$name}-calendarpanel-month {
width: 124px;
}
-.v-datefield-year .v-datefield-calendarpanel-month {
+.#{$name}-year .#{$name}-calendarpanel-month {
width: 35px;
}
-.v-datefield-calendarpanel-month {
+.#{$name}-calendarpanel-month {
background: transparent url(datefield_sprites.png) repeat-x 0 -112px;
font-weight: bold;
}
-span.v-datefield-calendarpanel-month {
+span.#{$name}-calendarpanel-month {
display: block;
text-align: center;
background: transparent;
@@ -58,15 +58,15 @@ span.v-datefield-calendarpanel-month {
padding: 1px 3px 0;
}
-.v-datefield-calendarpanel-prevyear,
-.v-datefield-calendarpanel-nextyear {
+.#{$name}-calendarpanel-prevyear,
+.#{$name}-calendarpanel-nextyear {
width: 22px;
}
-.v-datefield-calendarpanel-prevyear button,
-.v-datefield-calendarpanel-prevmonth button,
-.v-datefield-calendarpanel-nextmonth button,
-.v-datefield-calendarpanel-nextyear button {
+.#{$name}-calendarpanel-prevyear button,
+.#{$name}-calendarpanel-prevmonth button,
+.#{$name}-calendarpanel-nextmonth button,
+.#{$name}-calendarpanel-nextyear button {
width: 22px;
height: 28px;
border: none;
@@ -83,42 +83,42 @@ span.v-datefield-calendarpanel-month {
border-radius: 0;
}
-.v-ie .v-datefield-calendarpanel-prevyear button,
-.v-ie .v-datefield-calendarpanel-nextyear button,
-.v-ie .v-datefield-calendarpanel-prevmonth button,
-.v-ie .v-datefield-calendarpanel-nextmonth button {
+.v-ie .#{$name}-calendarpanel-prevyear button,
+.v-ie .#{$name}-calendarpanel-nextyear button,
+.v-ie .#{$name}-calendarpanel-prevmonth button,
+.v-ie .#{$name}-calendarpanel-nextmonth button {
text-indent: 0;
font-size: 1px;
}
-.v-datefield-calendarpanel-prevmonth button {
+.#{$name}-calendarpanel-prevmonth button {
background-position: 0 -56px;
}
-.v-datefield-calendarpanel-prevmonth {
+.#{$name}-calendarpanel-prevmonth {
background: transparent url(datefield_sprites.png) repeat-x 0 -112px;
}
-.v-datefield-calendarpanel-nextyear button {
+.#{$name}-calendarpanel-nextyear button {
background-position: 0 -28px;
width: 100%;
min-width: 22px;
}
-.v-datefield-calendarpanel-nextmonth button {
+.#{$name}-calendarpanel-nextmonth button {
background-position: 0 -84px;
}
-.v-datefield-calendarpanel-nextmonth {
+.#{$name}-calendarpanel-nextmonth {
background: transparent url(datefield_sprites.png) repeat-x 0 -112px;
}
-.v-datefield-calendarpanel-prevyear button {
+.#{$name}-calendarpanel-prevyear button {
width: 100%;
min-width: 22px;
}
-.v-datefield-calendarpanel-day {
+.#{$name}-calendarpanel-day {
display: block;
width: 22px;
margin: 0 0 3px 3px;
@@ -132,37 +132,37 @@ span.v-datefield-calendarpanel-month {
border-radius: 4px;
}
-.v-datefield-calendarpanel-day-today {
+.#{$name}-calendarpanel-day-today {
font-weight: bold;
}
-.v-datefield-calendarpanel-day-selected {
+.#{$name}-calendarpanel-day-selected {
background: #b5b5b5 url(/html/themes/classic/images/application/state_active_bg.png) repeat-x 0 0;
color: #000;
border-color: #555;
}
-.v-datefield-calendarpanel-day-focused {
+.#{$name}-calendarpanel-day-focused {
outline: 1px dotted #555;
}
-.v-datefield-calendarpanel-weekdays {
+.#{$name}-calendarpanel-weekdays {
text-align: center;
}
-.v-datefield-calendarpanel-weekdays strong {
+.#{$name}-calendarpanel-weekdays strong {
font-weight: normal;
}
-.v-datefield-calendarpanel-weeknumber {
+.#{$name}-calendarpanel-weeknumber {
display: block;
border: none;
padding: 2px 0 2px 0;
margin: 0;
}
-.v-datefield-calendarpanel-body table {
+.#{$name}-calendarpanel-body table {
margin: 0 auto;
width: 200px;
}
diff --git a/WebContent/VAADIN/themes/liferay/inlinedatefield/inlinedatefield.scss b/WebContent/VAADIN/themes/liferay/inlinedatefield/inlinedatefield.scss
new file mode 100644
index 0000000000..58aa928ee8
--- /dev/null
+++ b/WebContent/VAADIN/themes/liferay/inlinedatefield/inlinedatefield.scss
@@ -0,0 +1,8 @@
+@mixin liferay-inlinedatefield ($name : v-inline-datefield) {
+
+ @include liferay-datefield(v-inline-datefield);
+
+ .#{$name} {
+ line-height:19px; /* Override popup datefields line-height:0 to get correct line heights */
+ }
+} \ No newline at end of file
diff --git a/WebContent/VAADIN/themes/liferay/liferay.scss b/WebContent/VAADIN/themes/liferay/liferay.scss
index 7ec561ffc9..3128e48c76 100644
--- a/WebContent/VAADIN/themes/liferay/liferay.scss
+++ b/WebContent/VAADIN/themes/liferay/liferay.scss
@@ -7,6 +7,7 @@
@import "contextmenu/contextmenu.scss";
@import "datefield/datefield.scss";
+@import "inlinedatefield/inlinedatefield.scss";
@import "formlayout/formlayout.scss";
@import "menubar/menubar.scss";
@import "notification/notification.scss";
@@ -32,6 +33,7 @@
@include liferay-common;
@include liferay-contextmenu;
@include liferay-datefield;
+ @include liferay-inlinedatefield;
@include liferay-formlayout;
@include liferay-menubar;
@include liferay-notification;