Skip to content

Commit

Permalink
Improved layout of vocabulary, fixed messages for missing name and de…
Browse files Browse the repository at this point in the history
…scription
  • Loading branch information
Lloyd McKenzie committed Feb 8, 2020
1 parent cbf6454 commit a60cc9c
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 22 deletions.
17 changes: 10 additions & 7 deletions layouts/layout-valueset.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,23 @@
<!--ReleaseHeader--><p id="publish-box">Publish Box goes here</p><!--EndReleaseHeader-->
<a name="root"> </a>
<h2 id="root">{{site.data.pages[page.path].title}}</h2>
{% assign intro = site.data.pages[page.path].intro %}
{% if site.data.pages[page.path].intro != null %}
<div style="display:inline-block">
{% include {{intro}} %}
</div>
{% endif %}
<p>
<b>Summary</b>
</p>

{%include {{[type]}}-{{[id]}}-summary.xhtml%}

<p>
<b>References</b>
</p>
{%include {{[type]}}-{{[id]}}-xref.xhtml%}

{% assign intro = site.data.pages[page.path].intro %}
{% if site.data.pages[page.path].intro != null %}
<div style="display:inline-block">
{% include {{intro}} %}
</div>
{% endif %}

<a name="definition"> </a>
<h3 id="definition">Content Logical Definition</h3>

Expand Down
32 changes: 17 additions & 15 deletions scripts/onGenerate.qa.xslt
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,22 @@
<xsl:apply-templates select="f:definition/f:resource"/>
</xsl:template>
<xsl:template match="@*|node()"/>
<xsl:template match="f:definition/f:resource[not(f:name)]">
<xsl:call-template name="raiseIssue">
<xsl:with-param name="severity">error</xsl:with-param>
<xsl:with-param name="code">required</xsl:with-param>
<xsl:with-param name="details">Unable to find name for the resource. Names are mandatory to allow proper population of the artifact list.</xsl:with-param>
<xsl:with-param name="location" select="concat('ImplementationGuide.definition.resource[', count(preceding::f:resource), ']')"/>
</xsl:call-template>
</xsl:template>
<xsl:template match="f:definition/f:resource[not(f:description)]">
<xsl:call-template name="raiseIssue">
<xsl:with-param name="severity">warning</xsl:with-param>
<xsl:with-param name="code">invariant</xsl:with-param>
<xsl:with-param name="details">Unable to find description for the resource. Descriptions are strongly encouraged to allow proper population of the artifact list.</xsl:with-param>
<xsl:with-param name="location" select="concat('ImplementationGuide.definition.resource[', count(preceding::f:resource), ']')"/>
</xsl:call-template>
<xsl:template match="f:definition/f:resource">
<xsl:if test="not(f:name)">
<xsl:call-template name="raiseIssue">
<xsl:with-param name="severity">error</xsl:with-param>
<xsl:with-param name="code">required</xsl:with-param>
<xsl:with-param name="details" select="concat('Unable to find name for the resource ', f:reference/f:reference/@value, '. Names are mandatory to allow proper population of the artifact list.')"/>
<xsl:with-param name="location" select="concat('ImplementationGuide.definition.resource[', count(preceding::f:resource), ']')"/>
</xsl:call-template>
</xsl:if>
<xsl:if test="not(f:description)">
<xsl:call-template name="raiseIssue">
<xsl:with-param name="severity">warning</xsl:with-param>
<xsl:with-param name="code">invariant</xsl:with-param>
<xsl:with-param name="details" select="concat('Unable to find description for the resource ', f:reference/f:reference/@value, '. Descriptions are strongly encouraged to allow proper population of the artifact list.')"/>
<xsl:with-param name="location" select="concat('ImplementationGuide.definition.resource[', count(preceding::f:resource), ']')"/>
</xsl:call-template>
</xsl:if>
</xsl:template>
</xsl:stylesheet>

0 comments on commit a60cc9c

Please sign in to comment.