1 |
commit: 1efc3cf32e61f00629e576088517094b7a7e5c29 |
2 |
Author: Ulrich Müller <ulm <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Feb 26 20:17:04 2020 +0000 |
4 |
Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Mar 1 21:40:45 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/devmanual.git/commit/?id=1efc3cf3 |
7 |
|
8 |
devbook.xsl: Assign a default "depth" value for printParentDocs. |
9 |
|
10 |
The depth of the current document from the document root looks like |
11 |
a reasonable default. |
12 |
|
13 |
There is no "path" parameter, so remove it from the caller. |
14 |
|
15 |
Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org> |
16 |
|
17 |
devbook.xsl | 7 ++----- |
18 |
1 file changed, 2 insertions(+), 5 deletions(-) |
19 |
|
20 |
diff --git a/devbook.xsl b/devbook.xsl |
21 |
index a22366c..8024e7f 100644 |
22 |
--- a/devbook.xsl |
23 |
+++ b/devbook.xsl |
24 |
@@ -602,10 +602,7 @@ |
25 |
<div class="row"> |
26 |
<div class="col-md010"> |
27 |
<ol class="breadcrumb"> |
28 |
- <xsl:call-template name="printParentDocs"> |
29 |
- <xsl:with-param name="path" select="/guide/@self"/> |
30 |
- <xsl:with-param name="depth" select="string-length(/guide/@self)-string-length(translate(/guide/@self, '/' , ''))"/> |
31 |
- </xsl:call-template> |
32 |
+ <xsl:call-template name="printParentDocs"/> |
33 |
</ol> |
34 |
</div> |
35 |
</div> |
36 |
@@ -805,7 +802,7 @@ |
37 |
</xsl:template> |
38 |
|
39 |
<xsl:template name="printParentDocs"> |
40 |
- <xsl:param name="depth"/> |
41 |
+ <xsl:param name="depth" select="string-length(/guide/@self)-string-length(translate(/guide/@self, '/', ''))"/> |
42 |
<xsl:choose> |
43 |
<xsl:when test="$depth > 0"> |
44 |
<xsl:variable name="relative_path_depth_recursion"> |