提交 09ce2f5c 编写于 作者: F Félix Queiruga

Refactor the sectioning of the /manage page

- Use the <section> HTML elements
- Add some spacing between sections to improve readability
上级 b46cfa4b
......@@ -47,51 +47,54 @@ THE SOFTWARE.
</div>
<j:forEach var="category" items="${it.categorizedManagementLinks.entrySet()}">
<h2>${category.key.label}</h2>
<div class="manage-page__row">
<j:forEach var="m" items="${category.value}">
<j:set var="icon" value="${m.iconClassName != null ? m.iconClassName : m.iconFileName}" />
<j:if test="${icon!=null}">
<div class="manage-option manage-page__column">
<j:set var="iconUrl" value="${icon.startsWith('/') ? resURL+icon : imagesURL + '/48x48/' + icon}" />
<j:set var="alt" value="${icon.replaceAll('\\d*\\.[^.]+$', '')}"/>
${taskTags!=null and attrs.contextMenu!='false' ? taskTags.add(m.urlName, iconUrl, m.displayName, m.requiresPOST, m.requiresConfirmation) : null}
<j:choose>
<j:when test="${m.requiresConfirmation}">
<l:confirmationLink href="${m.urlName}" post="${m.requiresPOST}" message="${%are.you.sure(m.displayName)}">
<img class="icon" src="${iconUrl}" />
<dl>
<dt>${m.displayName}</dt>
<dd><j:out value="${m.description}"/></dd>
<dd><st:include it="${m}" page="info.jelly" optional="true"/></dd>
</dl>
</l:confirmationLink>
</j:when>
<j:when test="${m.requiresPOST}">
<f:link href="${m.urlName}" post="${m.requiresPOST}">
<img class="icon" src="${iconUrl}" alt="[${%alt}]"/>
<dl>
<dt>${m.displayName}</dt>
<dd><j:out value="${m.description}"/></dd>
<dd><st:include it="${m}" page="info.jelly" optional="true"/></dd>
</dl>
</f:link>
</j:when>
<j:otherwise>
<a href="${m.urlName}" title="${m.displayName}">
<img class="icon" src="${iconUrl}" alt="manage-option"/>
<dl>
<dt>${m.displayName}</dt>
<dd><j:out value="${m.description}"/></dd>
<dd><st:include it="${m}" page="info.jelly" optional="true"/></dd>
</dl>
</a>
</j:otherwise>
</j:choose>
</div>
</j:if>
</j:forEach>
</div>
<section class="manage-page__category">
<h2>${category.key.label}</h2>
<div class="manage-page__row">
<j:forEach var="m" items="${category.value}">
<j:set var="icon" value="${m.iconClassName != null ? m.iconClassName : m.iconFileName}" />
<j:if test="${icon!=null}">
<div class="manage-option manage-page__column">
<j:set var="iconUrl" value="${icon.startsWith('/') ? resURL+icon : imagesURL + '/48x48/' + icon}" />
<j:set var="alt" value="${icon.replaceAll('\\d*\\.[^.]+$', '')}"/>
${taskTags!=null and attrs.contextMenu!='false' ? taskTags.add(m.urlName, iconUrl, m.displayName, m.requiresPOST, m.requiresConfirmation) : null}
<j:choose>
<j:when test="${m.requiresConfirmation}">
<l:confirmationLink href="${m.urlName}" post="${m.requiresPOST}" message="${%are.you.sure(m.displayName)}">
<img class="icon" src="${iconUrl}" />
<dl>
<dt>${m.displayName}</dt>
<dd><j:out value="${m.description}"/></dd>
<dd><st:include it="${m}" page="info.jelly" optional="true"/></dd>
</dl>
</l:confirmationLink>
</j:when>
<j:when test="${m.requiresPOST}">
<f:link href="${m.urlName}" post="${m.requiresPOST}">
<img class="icon" src="${iconUrl}" alt="[${%alt}]"/>
<dl>
<dt>${m.displayName}</dt>
<dd><j:out value="${m.description}"/></dd>
<dd><st:include it="${m}" page="info.jelly" optional="true"/></dd>
</dl>
</f:link>
</j:when>
<j:otherwise>
<a href="${m.urlName}" title="${m.displayName}">
<img class="icon" src="${iconUrl}" alt="manage-option"/>
<dl>
<dt>${m.displayName}</dt>
<dd><j:out value="${m.description}"/></dd>
<dd><st:include it="${m}" page="info.jelly" optional="true"/></dd>
</dl>
</a>
</j:otherwise>
</j:choose>
</div>
</j:if>
</j:forEach>
</div>
</section>
</j:forEach>
</l:main-panel>
......
.manage-page__category {
&:not(:last-child) {
margin-bottom: 1.5rem;
}
}
.manage-page__row {
display: block;
display: flex;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册