aboutsummaryrefslogtreecommitdiff
path: root/stardoc/templates/markdown_tables
diff options
context:
space:
mode:
Diffstat (limited to 'stardoc/templates/markdown_tables')
-rw-r--r--stardoc/templates/markdown_tables/aspect.vm4
-rw-r--r--stardoc/templates/markdown_tables/func.vm8
-rw-r--r--stardoc/templates/markdown_tables/header.vm2
-rw-r--r--stardoc/templates/markdown_tables/module_extension.vm34
-rw-r--r--stardoc/templates/markdown_tables/provider.vm2
-rw-r--r--stardoc/templates/markdown_tables/repository_rule.vm31
-rw-r--r--stardoc/templates/markdown_tables/rule.vm4
7 files changed, 10 insertions, 75 deletions
diff --git a/stardoc/templates/markdown_tables/aspect.vm b/stardoc/templates/markdown_tables/aspect.vm
index 36aa47a..aa9f13b 100644
--- a/stardoc/templates/markdown_tables/aspect.vm
+++ b/stardoc/templates/markdown_tables/aspect.vm
@@ -6,7 +6,7 @@
${util.aspectSummary($aspectName, $aspectInfo)}
</pre>
-$aspectInfo.getDocString()
+${util.htmlEscape($aspectInfo.getDocString())}
**ASPECT ATTRIBUTES**
@@ -27,6 +27,6 @@ $aspectInfo.getDocString()
| Name | Description | Type | Mandatory | Default |
| :------------- | :------------- | :------------- | :------------- | :------------- |
#foreach ($attribute in $aspectInfo.getAttributeList())
-| <a id="${aspectName}-${attribute.name}"></a>$attribute.name | #if(!$attribute.docString.isEmpty()) ${util.markdownCellFormat($attribute.docString)} #else - #end | ${util.attributeTypeString($attribute)} | ${util.mandatoryString($attribute)} | #if(!$attribute.defaultValue.isEmpty()) ${util.markdownCodeSpan($attribute.defaultValue)} #end |
+| <a id="${aspectName}-${attribute.name}"></a>$attribute.name | #if(!$attribute.docString.isEmpty()) ${util.markdownCellFormat($attribute.docString)} #else - #end | ${util.attributeTypeString($attribute)} | ${util.mandatoryString($attribute)} | #if(!$attribute.defaultValue.isEmpty()) <code>${util.htmlEscape($attribute.defaultValue)}</code> #end |
#end
#end
diff --git a/stardoc/templates/markdown_tables/func.vm b/stardoc/templates/markdown_tables/func.vm
index e53b81a..5275d08 100644
--- a/stardoc/templates/markdown_tables/func.vm
+++ b/stardoc/templates/markdown_tables/func.vm
@@ -6,7 +6,7 @@
${util.funcSummary($funcInfo)}
</pre>
-${funcInfo.docString}
+${util.htmlEscape($funcInfo.docString)}
#if (!$funcInfo.getParameterList().isEmpty())
**PARAMETERS**
@@ -15,18 +15,18 @@ ${funcInfo.docString}
| Name | Description | Default Value |
| :------------- | :------------- | :------------- |
#foreach ($param in $funcInfo.getParameterList())
-| <a id="${funcInfo.functionName}-${param.name}"></a>$param.name | #if(!$param.docString.isEmpty()) ${util.markdownCellFormat($param.docString)} #else <p align="center"> - </p> #end | #if(!$param.getDefaultValue().isEmpty()) ${util.markdownCodeSpan($param.defaultValue)} #else none #end|
+| <a id="${funcInfo.functionName}-${param.name}"></a>$param.name | #if(!$param.docString.isEmpty()) ${util.markdownCellFormat($param.docString)} #else <p align="center"> - </p> #end | #if(!$param.getDefaultValue().isEmpty()) <code>${util.htmlEscape($param.getDefaultValue())}</code> #else none #end|
#end
#end
#if (!$funcInfo.getReturn().docString.isEmpty())
**RETURNS**
-${funcInfo.getReturn().docString}
+${util.htmlEscape($funcInfo.getReturn().docString)}
#end
#if (!$funcInfo.getDeprecated().docString.isEmpty())
**DEPRECATED**
-${funcInfo.getDeprecated().docString}
+${util.htmlEscape($funcInfo.getDeprecated().docString)}
#end
diff --git a/stardoc/templates/markdown_tables/header.vm b/stardoc/templates/markdown_tables/header.vm
index 5556ad6..2b47292 100644
--- a/stardoc/templates/markdown_tables/header.vm
+++ b/stardoc/templates/markdown_tables/header.vm
@@ -1,3 +1,3 @@
<!-- Generated with Stardoc: http://skydoc.bazel.build -->
-${moduleDocstring}
+${util.htmlEscape($moduleDocstring)}
diff --git a/stardoc/templates/markdown_tables/module_extension.vm b/stardoc/templates/markdown_tables/module_extension.vm
deleted file mode 100644
index 0ef7367..0000000
--- a/stardoc/templates/markdown_tables/module_extension.vm
+++ /dev/null
@@ -1,34 +0,0 @@
-<a id="${extensionName}"></a>
-
-#[[##]]# ${extensionName}
-
-<pre>
-${util.moduleExtensionSummary($extensionName, $extensionInfo)}
-</pre>
-#if (!$extensionInfo.docString.isEmpty())
-
-${extensionInfo.docString}
-#end
-
-#if (!$extensionInfo.getTagClassList().isEmpty())
-
-**TAG CLASSES**
-#foreach ($tagClass in $extensionInfo.getTagClassList())
-
-<a id="${extensionName}.${tagClass.tagName}"></a>
-
-#[[###]]# ${tagClass.tagName}
-#if (!$tagClass.docString.isEmpty())
-
-${tagClass.docString}
-#end
-
-**Attributes**
-
-| Name | Description | Type | Mandatory | Default |
-| :------------- | :------------- | :------------- | :------------- | :------------- |
-#foreach ($attribute in $tagClass.getAttributeList())
-| <a id="${extensionName}.${tagClass.tagName}-${attribute.name}"></a>$attribute.name | #if(!$attribute.docString.isEmpty()) ${util.markdownCellFormat($attribute.docString)} #else - #end | ${util.attributeTypeString($attribute)} | ${util.mandatoryString($attribute)} | #if(!$attribute.defaultValue.isEmpty()) ${util.markdownCodeSpan($attribute.defaultValue)} #end |
-#end
-#end
-#end
diff --git a/stardoc/templates/markdown_tables/provider.vm b/stardoc/templates/markdown_tables/provider.vm
index 0a866db..7ab4c60 100644
--- a/stardoc/templates/markdown_tables/provider.vm
+++ b/stardoc/templates/markdown_tables/provider.vm
@@ -6,7 +6,7 @@
${util.providerSummary($providerName, $providerInfo)}
</pre>
-${providerInfo.docString}
+${util.htmlEscape($providerInfo.docString)}
**FIELDS**
diff --git a/stardoc/templates/markdown_tables/repository_rule.vm b/stardoc/templates/markdown_tables/repository_rule.vm
deleted file mode 100644
index ed4a2a9..0000000
--- a/stardoc/templates/markdown_tables/repository_rule.vm
+++ /dev/null
@@ -1,31 +0,0 @@
-<a id="${ruleName}"></a>
-
-#[[##]]# ${ruleName}
-
-<pre>
-${util.repositoryRuleSummary($ruleName, $ruleInfo)}
-</pre>
-#if (!$ruleInfo.docString.isEmpty())
-
-${ruleInfo.docString}
-#end
-
-**ATTRIBUTES**
-
-#if (!$ruleInfo.getAttributeList().isEmpty())
-
-| Name | Description | Type | Mandatory | Default |
-| :------------- | :------------- | :------------- | :------------- | :------------- |
-#foreach ($attribute in $ruleInfo.getAttributeList())
-| <a id="${ruleName}-${attribute.name}"></a>$attribute.name | #if(!$attribute.docString.isEmpty()) ${util.markdownCellFormat($attribute.docString)} #else - #end | ${util.attributeTypeString($attribute)} | ${util.mandatoryString($attribute)} | #if(!$attribute.defaultValue.isEmpty()) ${util.markdownCodeSpan($attribute.defaultValue)} #end |
-#end
-#end
-#if (!$ruleInfo.getEnvironList().isEmpty())
-
-**ENVIRONMENT VARIABLES**
-
-This repository rule depends on the following environment variables:
-#foreach ($var in $ruleInfo.getEnvironList())
-* ${util.markdownCodeSpan($var)}
-#end
-#end
diff --git a/stardoc/templates/markdown_tables/rule.vm b/stardoc/templates/markdown_tables/rule.vm
index 0b73239..06d9a1f 100644
--- a/stardoc/templates/markdown_tables/rule.vm
+++ b/stardoc/templates/markdown_tables/rule.vm
@@ -6,7 +6,7 @@
${util.ruleSummary($ruleName, $ruleInfo)}
</pre>
-${ruleInfo.docString}
+${util.htmlEscape($ruleInfo.docString)}
**ATTRIBUTES**
@@ -15,6 +15,6 @@ ${ruleInfo.docString}
| Name | Description | Type | Mandatory | Default |
| :------------- | :------------- | :------------- | :------------- | :------------- |
#foreach ($attribute in $ruleInfo.getAttributeList())
-| <a id="${ruleName}-${attribute.name}"></a>$attribute.name | #if(!$attribute.docString.isEmpty()) ${util.markdownCellFormat($attribute.docString)} #else - #end | ${util.attributeTypeString($attribute)} | ${util.mandatoryString($attribute)} | #if(!$attribute.defaultValue.isEmpty()) ${util.markdownCodeSpan($attribute.defaultValue)} #end |
+| <a id="${ruleName}-${attribute.name}"></a>$attribute.name | #if(!$attribute.docString.isEmpty()) ${util.markdownCellFormat($attribute.docString)} #else - #end | ${util.attributeTypeString($attribute)} | ${util.mandatoryString($attribute)} | #if(!$attribute.defaultValue.isEmpty())<code>${util.htmlEscape($attribute.defaultValue)}</code>#end |
#end
#end