CSS for portal workspace

git-svn-id: https://svn.libreccm.org/ccm/trunk@2857 8810af33-2d31-482b-a856-94f89814c4df
master
jensp 2014-09-16 12:07:00 +00:00
parent 562eb2de72
commit fbdc364b25
2 changed files with 278 additions and 143 deletions

View File

@ -4,9 +4,9 @@ Only for putting the columns in the right place.
*/ */
div#workspace div.portalColumn { div#workspace div.portalColumn {
float: left; float: left;
} }
div#workspace div.portalColumn:last-child { div#workspace div.portalColumn:last-child {
@ -14,13 +14,53 @@ div#workspace div.portalColumn:last-child {
} }
div#workspace div.editPortlet:hover { div#workspace div.editPortlet:hover {
/*border: 1px solid #ccc;*/ /*border: 1px solid #ccc;*/
background-color: #eee; outline: 1px outset #444;
} }
div#workspace div.moveLeft.disabled img { div#workspace div.editPortlet:hover {
/*border: 1px solid #ccc;*/
background-color: #eee;
}
div#workspace ul.portletActions:after {
content: " ";
display: block;
clear: both;
visibility: hidden;
}
div#workspace ul.portletActions li {
float: left;
width: 16.66%;
text-align: center;
padding-top: 0.2em;
}
div#workspace ul.portletActions li:last-child {
/*float: right;*/
}
div#workspace ul.portletActions li.moveLeft img,
div#workspace ul.portletActions li.moveUp img,
div#workspace ul.portletActions li.customize img,
div#workspace ul.portletActions li.delete img,
div#workspace ul.portletActions li.moveDown img,
div#workspace ul.portletActions li.moveRight img {
opacity: 1.00;
}
div#workspace ul.portletActions li.moveLeft.disabled img,
div#workspace ul.portletActions li.moveUp.disabled img,
div#workspace ul.portletActions li.customize.disabled img,
div#workspace ul.portletActions li.delete.disabled img,
div#workspace ul.portletActions li.moveDown.disabled img,
div#workspace ul.portletActions li.moveRight.disabled img {
opacity: 0.25; opacity: 0.25;
} }

View File

@ -201,153 +201,248 @@
<xsl:template match="bebop:portlet[portlet:action]"> <xsl:template match="bebop:portlet[portlet:action]">
<div class="editPortlet"> <div class="editPortlet">
<div class="moveLeft"> <ul class="portletActions">
<xsl:choose> <li class="moveLeft">
<xsl:when test="portlet:action[@name='moveLeft'] and @cellNumber != '1'"> <xsl:choose>
<xsl:apply-templates select="portlet:action[@name='moveLeft']"> <xsl:when test="portlet:action[@name='moveLeft'] and @cellNumber != '1'">
<xsl:with-param name="src"> <xsl:apply-templates select="portlet:action[@name='moveLeft']">
<xsl:call-template name="mandalay:linkParser"> <xsl:with-param name="src">
<xsl:with-param name="link"> <xsl:call-template name="mandalay:linkParser">
<xsl:call-template name="mandalay:getSetting"> <xsl:with-param name="link">
<xsl:with-param name="module" select="'portal'"/> <xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="setting" select="'setImage/moveLeft'"/> <xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="default" select="'/images/portal/moveLeft.gif'"/> <xsl:with-param name="setting" select="'setImage/moveLeft'"/>
</xsl:call-template> <xsl:with-param name="default" select="'/images/portal/moveLeft.gif'"/>
</xsl:with-param> </xsl:call-template>
<xsl:with-param name="prefix" select="$theme-prefix"/> </xsl:with-param>
</xsl:call-template> <xsl:with-param name="prefix" select="$theme-prefix"/>
</xsl:with-param> </xsl:call-template>
<xsl:with-param name="title" select="@name"/> </xsl:with-param>
<xsl:with-param name="alt" select="'&lt;'"/> <xsl:with-param name="title" select="@name"/>
</xsl:apply-templates> <xsl:with-param name="alt" select="'&lt;'"/>
</xsl:when> </xsl:apply-templates>
<xsl:otherwise> </xsl:when>
<xsl:attribute name="class"> <xsl:otherwise>
<xsl:value-of select="'moveLeft disabled'"/> <xsl:attribute name="class">
</xsl:attribute> <xsl:value-of select="'moveLeft disabled'"/>
<xsl:variable name="img-src">
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="setting" select="'setImage/moveLeft'"/>
<xsl:with-param name="default" select="'/images/portal/moveLeft.gif'"/>
</xsl:call-template>
</xsl:variable>
<img>
<xsl:attribute name="src">
<xsl:value-of select="concat($theme-prefix, $img-src)"/>
</xsl:attribute> </xsl:attribute>
</img> <xsl:variable name="img-src">
</xsl:otherwise> <xsl:call-template name="mandalay:getSetting">
</xsl:choose> <xsl:with-param name="module" select="'portal'"/>
</div> <xsl:with-param name="setting" select="'setImage/moveLeft'"/>
<div class="moveUp"> <xsl:with-param name="default" select="'/images/portal/moveLeft.gif'"/>
<xsl:if test="portlet:action[@name='moveUp'] and position() != '1'"> </xsl:call-template>
<xsl:apply-templates select="portlet:action[@name='moveUp']"> </xsl:variable>
<xsl:with-param name="src"> <img>
<xsl:call-template name="mandalay:linkParser"> <xsl:attribute name="src">
<xsl:with-param name="link"> <xsl:value-of select="concat($theme-prefix, $img-src)"/>
<xsl:call-template name="mandalay:getSetting"> </xsl:attribute>
<xsl:with-param name="module" select="'portal'"/> </img>
<xsl:with-param name="setting" select="'setImage/moveUp'"/> </xsl:otherwise>
<xsl:with-param name="default" select="'/images/portal/moveUp.gif'"/> </xsl:choose>
</li>
<li class="moveUp">
<xsl:choose>
<xsl:when test="portlet:action[@name='moveUp'] and position() != '1'">
<xsl:apply-templates select="portlet:action[@name='moveUp']">
<xsl:with-param name="src">
<xsl:call-template name="mandalay:linkParser">
<xsl:with-param name="link">
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="setting" select="'setImage/moveUp'"/>
<xsl:with-param name="default" select="'/images/portal/moveUp.gif'"/>
</xsl:call-template>
</xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/>
</xsl:call-template> </xsl:call-template>
</xsl:with-param> </xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/> <xsl:with-param name="title" select="@name"/>
</xsl:call-template> <xsl:with-param name="alt" select="'^'"/>
</xsl:with-param> </xsl:apply-templates>
<xsl:with-param name="title" select="@name"/> </xsl:when>
<xsl:with-param name="alt" select="'^'"/> <xsl:otherwise>
</xsl:apply-templates> <xsl:attribute name="class">
</xsl:if> <xsl:value-of select="'moveUp disabled'"/>
</div> </xsl:attribute>
<div class="customize"> <xsl:variable name="img-src">
<xsl:if test="portlet:action[@name='customize']"> <xsl:call-template name="mandalay:getSetting">
<xsl:apply-templates select="portlet:action[@name='customize']"> <xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="src"> <xsl:with-param name="setting" select="'setImage/moveUp'"/>
<xsl:call-template name="mandalay:linkParser"> <xsl:with-param name="default" select="'/images/portal/moveUp.gif'"/>
<xsl:with-param name="link"> </xsl:call-template>
<xsl:call-template name="mandalay:getSetting"> </xsl:variable>
<xsl:with-param name="module" select="'portal'"/> <img>
<xsl:with-param name="setting" select="'setImage/customize'"/> <xsl:attribute name="src">
<xsl:with-param name="default" select="'/images/portal/customize.gif'"/> <xsl:value-of select="concat($theme-prefix, $img-src)"/>
</xsl:attribute>
</img>
</xsl:otherwise>
</xsl:choose>
</li>
<li class="customize">
<xsl:choose>
<xsl:when test="portlet:action[@name='customize']">
<xsl:apply-templates select="portlet:action[@name='customize']">
<xsl:with-param name="src">
<xsl:call-template name="mandalay:linkParser">
<xsl:with-param name="link">
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="setting" select="'setImage/customize'"/>
<xsl:with-param name="default" select="'/images/portal/customize.gif'"/>
</xsl:call-template>
</xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/>
</xsl:call-template> </xsl:call-template>
</xsl:with-param> </xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/> <xsl:with-param name="title" select="@name"/>
</xsl:call-template> <xsl:with-param name="alt" select="'C'"/>
</xsl:with-param> </xsl:apply-templates>
<xsl:with-param name="title" select="@name"/> </xsl:when>
<xsl:with-param name="alt" select="'C'"/> <xsl:otherwise>
</xsl:apply-templates> <xsl:attribute name="class">
</xsl:if> <xsl:value-of select="'customize disabled'"/>
</div> </xsl:attribute>
<div class="delete"> <xsl:variable name="img-src">
<xsl:if test="portlet:action[@name='delete']"> <xsl:call-template name="mandalay:getSetting">
<xsl:apply-templates select="portlet:action[@name='delete']"> <xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="src"> <xsl:with-param name="setting" select="'setImage/customize'"/>
<xsl:call-template name="mandalay:linkParser"> <xsl:with-param name="default" select="'/images/portal/customize.gif'"/>
<xsl:with-param name="link"> </xsl:call-template>
<xsl:call-template name="mandalay:getSetting"> </xsl:variable>
<xsl:with-param name="module" select="'portal'"/> <img>
<xsl:with-param name="setting" select="'setImage/delete'"/> <xsl:attribute name="src">
<xsl:with-param name="default" select="'/images/portal/delete.gif'"/> <xsl:value-of select="concat($theme-prefix, $img-src)"/>
</xsl:attribute>
</img>
</xsl:otherwise>
</xsl:choose>
</li>
<li class="delete">
<xsl:choose>
<xsl:when test="portlet:action[@name='delete']">
<xsl:apply-templates select="portlet:action[@name='delete']">
<xsl:with-param name="src">
<xsl:call-template name="mandalay:linkParser">
<xsl:with-param name="link">
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="setting" select="'setImage/delete'"/>
<xsl:with-param name="default" select="'/images/portal/delete.gif'"/>
</xsl:call-template>
</xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/>
</xsl:call-template> </xsl:call-template>
</xsl:with-param> </xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/> <xsl:with-param name="title" select="@name"/>
</xsl:call-template> <xsl:with-param name="alt" select="'X'"/>
</xsl:with-param> </xsl:apply-templates>
<xsl:with-param name="title" select="@name"/> </xsl:when>
<xsl:with-param name="alt" select="'X'"/> <xsl:otherwise>
</xsl:apply-templates> <xsl:attribute name="class">
</xsl:if> <xsl:value-of select="'delete disabled'"/>
</div> </xsl:attribute>
<div class="moveDown"> <xsl:variable name="img-src">
<!-- DE Das letzte bebop:portlet ist immer das Widget zum hinzugügen weiterer Portlets, <xsl:call-template name="mandalay:getSetting">
daher wird hier einer abgezogen, damit das letze verschiebare Portlet kein <xsl:with-param name="module" select="'portal'"/>
Verschieben nach unten zuläßt. --> <xsl:with-param name="setting" select="'setImage/delete'"/>
<!-- EN The last bebop:portlet is always the widget to add another portlet, so <xsl:with-param name="default" select="'/images/portal/delete.gif'"/>
we substract 1 to ensure that the last movable portlet doesn't have a </xsl:call-template>
move down button. --> </xsl:variable>
<xsl:if test="portlet:action[@name='moveDown'] and position() &lt; last() - 1"> <img>
<xsl:apply-templates select="portlet:action[@name='moveDown']"> <xsl:attribute name="src">
<xsl:with-param name="src"> <xsl:value-of select="concat($theme-prefix, $img-src)"/>
<xsl:call-template name="mandalay:linkParser"> </xsl:attribute>
<xsl:with-param name="link"> </img>
<xsl:call-template name="mandalay:getSetting"> </xsl:otherwise>
<xsl:with-param name="module" select="'portal'"/> </xsl:choose>
<xsl:with-param name="setting" select="'setImage/moveDown'"/> </li>
<xsl:with-param name="default" select="'/images/portal/moveDown.gif'"/> <li class="moveDown">
<xsl:choose>
<!-- DE Das letzte bebop:portlet ist immer das Widget zum hinzugügen weiterer Portlets,
daher wird hier einer abgezogen, damit das letze verschiebare Portlet kein
Verschieben nach unten zuläßt. -->
<!-- EN The last bebop:portlet is always the widget to add another portlet, so
we substract 1 to ensure that the last movable portlet doesn't have a
move down button. -->
<xsl:when test="portlet:action[@name='moveDown'] and position() &lt; last() - 1">
<xsl:apply-templates select="portlet:action[@name='moveDown']">
<xsl:with-param name="src">
<xsl:call-template name="mandalay:linkParser">
<xsl:with-param name="link">
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="setting" select="'setImage/moveDown'"/>
<xsl:with-param name="default" select="'/images/portal/moveDown.gif'"/>
</xsl:call-template>
</xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/>
</xsl:call-template> </xsl:call-template>
</xsl:with-param> </xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/> <xsl:with-param name="title" select="@name"/>
</xsl:call-template> <xsl:with-param name="alt" select="'v'"/>
</xsl:with-param> </xsl:apply-templates>
<xsl:with-param name="title" select="@name"/> </xsl:when>
<xsl:with-param name="alt" select="'v'"/> <xsl:otherwise>
</xsl:apply-templates> <xsl:attribute name="class">
</xsl:if> <xsl:value-of select="'moveDown disabled'"/>
</div> </xsl:attribute>
<div class="moveRight"> <xsl:variable name="img-src">
<xsl:if test="portlet:action[@name='moveRight'] and @cellNumber != substring-before(../@style, ' ')"> <xsl:call-template name="mandalay:getSetting">
<xsl:apply-templates select="portlet:action[@name='moveRight']"> <xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="src"> <xsl:with-param name="setting" select="'setImage/moveDown'"/>
<xsl:call-template name="mandalay:linkParser"> <xsl:with-param name="default" select="'/images/portal/moveDown.gif'"/>
<xsl:with-param name="link"> </xsl:call-template>
<xsl:call-template name="mandalay:getSetting"> </xsl:variable>
<xsl:with-param name="module" select="'portal'"/> <img>
<xsl:with-param name="setting" select="'setImage/moveRight'"/> <xsl:attribute name="src">
<xsl:with-param name="default" select="'/images/portal/moveRight.gif'"/> <xsl:value-of select="concat($theme-prefix, $img-src)"/>
</xsl:attribute>
</img>
</xsl:otherwise>
</xsl:choose>
</li>
<li class="moveRight">
<xsl:choose>
<xsl:when test="portlet:action[@name='moveRight'] and @cellNumber != substring-before(../@style, ' ')">
<xsl:apply-templates select="portlet:action[@name='moveRight']">
<xsl:with-param name="src">
<xsl:call-template name="mandalay:linkParser">
<xsl:with-param name="link">
<xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="setting" select="'setImage/moveRight'"/>
<xsl:with-param name="default" select="'/images/portal/moveRight.gif'"/>
</xsl:call-template>
</xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/>
</xsl:call-template> </xsl:call-template>
</xsl:with-param> </xsl:with-param>
<xsl:with-param name="prefix" select="$theme-prefix"/> <xsl:with-param name="title" select="@name"/>
</xsl:call-template> <xsl:with-param name="alt" select="'&gt;'"/>
</xsl:with-param> </xsl:apply-templates>
<xsl:with-param name="title" select="@name"/> </xsl:when>
<xsl:with-param name="alt" select="'&gt;'"/> <xsl:otherwise>
</xsl:apply-templates> <xsl:attribute name="class">
</xsl:if> <xsl:value-of select="'moveRight disabled'"/>
</div> </xsl:attribute>
<div class="bottomRight"> <xsl:variable name="img-src">
</div> <xsl:call-template name="mandalay:getSetting">
<xsl:with-param name="module" select="'portal'"/>
<xsl:with-param name="setting" select="'setImage/moveRight'"/>
<xsl:with-param name="default" select="'/images/portal/moveRight.gif'"/>
</xsl:call-template>
</xsl:variable>
<img>
<xsl:attribute name="src">
<xsl:value-of select="concat($theme-prefix, $img-src)"/>
</xsl:attribute>
</img>
</xsl:otherwise>
</xsl:choose>
</li>
</ul>
<div class="portlet"> <div class="portlet">
<!-- DE Wähle alle Kindknoten mit Ausnahme von portlet:action aus --> <!-- DE Wähle alle Kindknoten mit Ausnahme von portlet:action aus -->
<!-- EN Select all child nodes except portlet:action --> <!-- EN Select all child nodes except portlet:action -->