Skip to content

Commit

Permalink
Handle box-header and box-toolbar within container-box correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
jenshp committed Oct 16, 2023
1 parent 91e10bb commit 23e2583
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion template/screen-macro/DefaultScreenMacros.qvt.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,13 @@ ${sri.renderSectionInclude(.node)}
<#assign boxType = ec.resource.expandNoL10n(.node["@type"], "")!>
<#if !boxType?has_content><#assign boxType = "default"></#if>
<q-card flat bordered padding class="q-ma-sm">
<q-expansion-item switch-toggle-side <#if contBoxDivId?has_content> id="${contBoxDivId}"</#if> label="${ec.getResource().expand(boxHeader["@title"]!"", "")?html}" <#if ec.getResource().expandNoL10n(.node["@initial"]!, "") != "closed">default-opened</#if> header-class="m-container-box text-h5<#if boxType?has_content> text-${boxType}</#if>">
<q-expansion-item switch-toggle-side <#if contBoxDivId?has_content> id="${contBoxDivId}"</#if> <#if ec.getResource().expandNoL10n(.node["@initial"]!, "") != "closed">default-opened</#if> header-class="m-container-box text-h5<#if boxType?has_content> text-${boxType}</#if>">
<#if .node["box-header"]?has_content || boxHeader["@title"]?has_content>
<template v-slot:header>
<#if boxHeader["@title"]?has_content><h5>${ec.getResource().expand(boxHeader["@title"]!"", "")?html}</h5></#if>
<#if .node["box-header"]?has_content><#recurse .node["box-header"][0]></#if>
</template>
</#if>
<#if .node["box-toolbar"]?has_content><q-toolbar><#recurse .node["box-toolbar"][0]></q-toolbar></#if>
<#if .node["box-body"]?has_content><q-card><q-card-section><#recurse .node["box-body"][0]></q-card-section></q-card></#if>
<#if .node["box-body-nopad"]?has_content><q-card><q-card-section><#recurse .node["box-body-nopad"][0]></q-card-section></q-card></#if>
Expand Down

0 comments on commit 23e2583

Please sign in to comment.