You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rave.apache.org by ja...@apache.org on 2011/11/22 15:57:35 UTC
svn commit: r1205027 - in
/incubator/rave/trunk/rave-portal-resources/src/main/webapp:
WEB-INF/jsp/views/home.jsp WEB-INF/jsp/views/mobile_home.jsp
WEB-INF/jsp/views/store.jsp WEB-INF/jsp/views/widget.jsp css/default.css
Author: jasha
Date: Tue Nov 22 14:57:34 2011
New Revision: 1205027
URL: http://svn.apache.org/viewvc?rev=1205027&view=rev
Log:
RAVE-312 Scale widgets/gadgets over the entire width of the screen
Add mediaquery support for IE<9
Fix inline-blocks in IE7
Modified:
incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/home.jsp
incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/mobile_home.jsp
incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/store.jsp
incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/widget.jsp
incubator/rave/trunk/rave-portal-resources/src/main/webapp/css/default.css
Modified: incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/home.jsp
URL: http://svn.apache.org/viewvc/incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/home.jsp?rev=1205027&r1=1205026&r2=1205027&view=diff
==============================================================================
--- incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/home.jsp (original)
+++ incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/home.jsp Tue Nov 22 14:57:34 2011
@@ -92,8 +92,10 @@
</div>
<%--render the main page content (regions/widgets) --%>
<div id="pageContent">
- <c:forEach var="region" items="${page.regions}">
- <div class="region" id="region-${region.entityId}-id">
+ <div class="regions">
+ <c:forEach var="region" items="${page.regions}" varStatus="status">
+ <%--@elvariable id="region" type="org.apache.rave.portal.model.Region"--%>
+ <div class="region <c:out value="${page.pageLayout.code}"/>_${status.count}" id="region-${region.entityId}-id">
<c:forEach var="regionWidget" items="${region.regionWidgets}">
<div class="widget-wrapper" id="widget-${regionWidget.entityId}-wrapper">
<div class="widget-title-bar">
@@ -101,7 +103,7 @@
<div id="widget-${regionWidget.entityId}-title" class="widget-title">
<c:choose>
<c:when test="${not empty regionWidget.widget.titleUrl}">
- <a href="${regionWidget.widget.titleUrl}" rel="external"><c:out value="${regionWidget.widget.title}"/></a>
+ <a href="<c:out value="${regionWidget.widget.titleUrl}"/>" rel="external"><c:out value="${regionWidget.widget.title}"/></a>
</c:when>
<c:otherwise>
<c:out value="${regionWidget.widget.title}"/>
@@ -145,6 +147,8 @@
</c:forEach>
</div>
</c:forEach>
+ </div>
+
<div class="clear-float"> </div>
</div>
<fmt:message key="page.general.addnewpage" var="addNewPageTitle"/>
@@ -212,6 +216,7 @@
<script src="//ajax.aspnetcdn.com/ajax/jQuery/jquery-1.6.1.min.js"></script>
<script src="//ajax.aspnetcdn.com/ajax/jquery.ui/1.8.13/jquery-ui.min.js"></script>
<script src="//ajax.aspnetcdn.com/ajax/jquery.validate/1.8.1/jquery.validate.min.js"></script>
+<!--[if lt IE 9]><script src=//css3-mediaqueries-js.googlecode.com/svn/trunk/css3-mediaqueries.js></script><![endif]-->
<portal:render-script location="${'AFTER_LIB'}" />
<portal:render-script location="${'BEFORE_RAVE'}" />
<script src="<spring:url value="/script/rave.js"/>"></script>
Modified: incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/mobile_home.jsp
URL: http://svn.apache.org/viewvc/incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/mobile_home.jsp?rev=1205027&r1=1205026&r2=1205027&view=diff
==============================================================================
--- incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/mobile_home.jsp (original)
+++ incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/mobile_home.jsp Tue Nov 22 14:57:34 2011
@@ -76,7 +76,7 @@
<%-- the mobile view will only show one column of widgets --%>
<div id="pageContent" class="pageContent-mobile">
<c:forEach var="region" items="${page.regions}">
- <div class="region region-mobile" id="region-${region.entityId}-id">
+ <div class="region-mobile" id="region-${region.entityId}-id">
<c:forEach var="regionWidget" items="${region.regionWidgets}">
<div class="widget-wrapper widget-wrapper-mobile" id="widget-${regionWidget.entityId}-wrapper">
<div class="widget-title-bar widget-title-bar-mobile" onclick="rave.toggleMobileWidget(${regionWidget.entityId});">
Modified: incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/store.jsp
URL: http://svn.apache.org/viewvc/incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/store.jsp?rev=1205027&r1=1205026&r2=1205027&view=diff
==============================================================================
--- incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/store.jsp (original)
+++ incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/store.jsp Tue Nov 22 14:57:34 2011
@@ -170,6 +170,7 @@
<script src="//ajax.aspnetcdn.com/ajax/jQuery/jquery-1.6.1.min.js"></script>
<script src="//ajax.aspnetcdn.com/ajax/jquery.ui/1.8.13/jquery-ui.min.js"></script>
+<!--[if lt IE 9]><script src=//css3-mediaqueries-js.googlecode.com/svn/trunk/css3-mediaqueries.js></script><![endif]-->
<script src="<spring:url value="/script/rave.js"/>"></script>
<script src="<spring:url value="/script/rave_api.js"/>"></script>
<script src="<spring:url value="/script/rave_store.js"/>"></script>
Modified: incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/widget.jsp
URL: http://svn.apache.org/viewvc/incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/widget.jsp?rev=1205027&r1=1205026&r2=1205027&view=diff
==============================================================================
--- incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/widget.jsp (original)
+++ incubator/rave/trunk/rave-portal-resources/src/main/webapp/WEB-INF/jsp/views/widget.jsp Tue Nov 22 14:57:34 2011
@@ -171,6 +171,7 @@
</div>
<script src="//ajax.aspnetcdn.com/ajax/jQuery/jquery-1.6.1.min.js"></script>
<script src="//ajax.aspnetcdn.com/ajax/jquery.ui/1.8.13/jquery-ui.min.js"></script>
+ <!--[if lt IE 9]><script src=//css3-mediaqueries-js.googlecode.com/svn/trunk/css3-mediaqueries.js></script><![endif]-->
<script src="<spring:url value="/script/rave.js"/>"></script>
<script src="<spring:url value="/script/rave_api.js"/>"></script>
<script src="<spring:url value="/script/rave_store.js"/>"></script>
Modified: incubator/rave/trunk/rave-portal-resources/src/main/webapp/css/default.css
URL: http://svn.apache.org/viewvc/incubator/rave/trunk/rave-portal-resources/src/main/webapp/css/default.css?rev=1205027&r1=1205026&r2=1205027&view=diff
==============================================================================
--- incubator/rave/trunk/rave-portal-resources/src/main/webapp/css/default.css (original)
+++ incubator/rave/trunk/rave-portal-resources/src/main/webapp/css/default.css Tue Nov 22 14:57:34 2011
@@ -217,14 +217,6 @@ header h1 {
vertical-align: top;
}
-.widget-a {
- color: white;
- width: 100px;
- text-align: center;
- float: right;
- margin-right: 2%;
-}
-
.widget-wrapper {
vertical-align: top;
margin-bottom: 20px;
@@ -236,6 +228,7 @@ header h1 {
.widget-title-bar {
color: #FFFFFF;
+ background-color: #666666;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#999999", endColorstr="#666666");
background: -moz-linear-gradient(center top , #999 0%, #666 25%) repeat scroll 0 0 transparent;
background: -webkit-gradient(linear, left top, left bottom, from(#999), to(#666));
@@ -308,12 +301,16 @@ header h1 {
background-color: yellow;
}
+.regions {
+ width: 100%;
+ overflow-x: hidden;
+}
+
.region {
float: left;
display: block;
- padding: 5px 5px 100px 5px; /*** bottom padding is needed for dnd when region is empty ***/
+ padding: 5px 0 100px 0; /*** bottom padding is needed for dnd when region is empty ***/
margin-right: 20px;
- min-width:300px;
width: auto;
height: 100%;
}
@@ -328,10 +325,60 @@ header h1 {
.region-dragging {
height: 200%;
- min-width: 250px;
border: 1px solid black;
}
+.columns_1_1 {
+ width: 90%;
+}
+
+.columns_2_1, .columns_2_2 {
+ width: 45%;
+}
+
+.columns_2wn_1 {
+ width: 60%;
+}
+
+.columns_2wn_2 {
+ width: 30%;
+}
+
+.columns_3_1, .columns_3_2, .columns_3_3 {
+ width: 30%
+}
+
+.columns_3nwn_1, .columns_3nwn_3 {
+ width: 22%;
+}
+
+.columns_3nwn_2 {
+ width: 45%;
+}
+
+.columns_4_1, .columns_4_2, .columns_4_3, .columns_4_4 {
+ width: 22%;
+}
+
+.columns_3nwn_1_bottom_1, .columns_3nwn_1_bottom_3 {
+ width: 22%;
+ padding-bottom: 5em;
+}
+
+.columns_3nwn_1_bottom_2 {
+ width: 45%;
+ padding-bottom: 5em;
+}
+
+.columns_3nwn_1_bottom_4 {
+ width: 93%;
+ clear: both;
+}
+
+.columns_2_2, .columns_3_3, .columns_3nwn_3, .columns_4_4, .columns_3nwn_1_bottom_3, .columns_3nwn_1_bottom_4 {
+ margin-right: 0;
+}
+
.storeSearch, .storeBox {
margin: 5px auto;
width: 60%
@@ -451,6 +498,9 @@ button.widget-toolbar-btn-min {
display: inline-block;
vertical-align: middle;
cursor: pointer;
+ /* IE 7 hacks for inline-block */
+ zoom: 1;
+ *display: inline;
}
/* Form fields */
@@ -525,6 +575,9 @@ span.error, label.error {
height: 25px;
position: relative;
top: 1px;
+ /* IE 7 hacks for inline-block */
+ zoom: 1;
+ *display: inline;
}
.rave-ui-tab a, .rave-ui-tab a:visited {
@@ -590,6 +643,9 @@ span.error, label.error {
margin-left: 10px;
padding-bottom: 4px;
padding-top: 3px;
+ /* IE 7 hacks for inline-block */
+ zoom: 1;
+ *display: inline;
}
#pageContent, .pageContent {
@@ -608,6 +664,9 @@ span.error, label.error {
display: inline-block;
padding: 5px 10px;
cursor: pointer;
+ /* IE 7 hacks for inline-block */
+ zoom: 1;
+ *display: inline;
}
/* page menu related styles */
@@ -615,6 +674,9 @@ span.error, label.error {
position: relative;
display: inline-block;
vertical-align: middle;
+ /* IE 7 hacks for inline-block */
+ zoom: 1;
+ *display: inline;
}
.page-menu {
border: 1px solid black;
@@ -646,6 +708,9 @@ span.error, label.error {
position: relative;
display: inline-block;
vertical-align: middle;
+ /* IE 7 hacks for inline-block */
+ zoom: 1;
+ *display: inline;
}
.widget-menu {
border: 1px solid black;
@@ -903,7 +968,7 @@ span.error, label.error {
@media all and (max-width: 500px) {
body {
- font-size: 1em;
+ font-size: 0.8em;
}
header {
@@ -958,4 +1023,15 @@ span.error, label.error {
margin-top: 0;
}
+ .region {
+ clear: both;
+ width: 100%;
+ margin: 0;
+ padding: 1em 0;
+ }
+
+ .widget, .widget-title-bar {
+ box-shadow: none;
+ border: 1px solid #767676;
+ }
}
\ No newline at end of file