@redpanda-data/docs-extensions-and-macros 4.7.4 → 4.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (26) hide show
  1. package/bin/doc-tools.js +90 -20
  2. package/package.json +1 -1
  3. package/tools/property-extractor/Makefile +64 -24
  4. package/tools/property-extractor/generate-handlebars-docs.js +344 -0
  5. package/tools/property-extractor/helpers/and.js +10 -0
  6. package/tools/property-extractor/helpers/eq.js +9 -0
  7. package/tools/property-extractor/helpers/formatPropertyValue.js +128 -0
  8. package/tools/property-extractor/helpers/formatUnits.js +26 -0
  9. package/tools/property-extractor/helpers/index.js +13 -0
  10. package/tools/property-extractor/helpers/join.js +18 -0
  11. package/tools/property-extractor/helpers/ne.js +9 -0
  12. package/tools/property-extractor/helpers/not.js +8 -0
  13. package/tools/property-extractor/helpers/or.js +10 -0
  14. package/tools/property-extractor/helpers/renderPropertyExample.js +42 -0
  15. package/tools/property-extractor/package-lock.json +77 -0
  16. package/tools/property-extractor/package.json +6 -0
  17. package/tools/property-extractor/property_extractor.py +1163 -20
  18. package/tools/property-extractor/requirements.txt +1 -0
  19. package/tools/property-extractor/templates/deprecated-properties.hbs +25 -0
  20. package/tools/property-extractor/templates/deprecated-property.hbs +7 -0
  21. package/tools/property-extractor/templates/property-page.hbs +22 -0
  22. package/tools/property-extractor/templates/property.hbs +70 -0
  23. package/tools/property-extractor/templates/topic-property.hbs +59 -0
  24. package/tools/property-extractor/topic_property_extractor.py +630 -0
  25. package/tools/property-extractor/transformers.py +80 -4
  26. package/tools/property-extractor/json-to-asciidoc/generate_docs.py +0 -466
@@ -1,2 +1,3 @@
1
1
  tree_sitter==0.21.1
2
2
  setuptools>=42.0.0
3
+ pyyaml>=6.0
@@ -0,0 +1,25 @@
1
+ {{#if deprecated}}
2
+ = Deprecated Configuration Properties
3
+ :description: This is an exhaustive list of all the deprecated properties.
4
+
5
+ This is an exhaustive list of all the deprecated properties.
6
+
7
+ {{#if brokerProperties}}
8
+ == Broker properties
9
+
10
+ {{#each brokerProperties}}
11
+ {{> deprecated-property}}
12
+
13
+ {{/each}}
14
+ {{/if}}
15
+
16
+ {{#if clusterProperties}}
17
+ == Cluster properties
18
+
19
+ {{#each clusterProperties}}
20
+ {{> deprecated-property}}
21
+
22
+ {{/each}}
23
+ {{/if}}
24
+
25
+ {{/if}}
@@ -0,0 +1,7 @@
1
+ === `{{name}}`
2
+
3
+ {{#if description}}
4
+ {{{description}}}
5
+ {{else}}
6
+ No description available.
7
+ {{/if}}
@@ -0,0 +1,22 @@
1
+ = {{pageTitle}}
2
+ {{#if pageAliases}}
3
+ :page-aliases: {{join pageAliases ", "}}
4
+ {{/if}}
5
+ :description: {{description}}
6
+
7
+ {{{intro}}}
8
+
9
+ {{#if sectionTitle}}
10
+ == {{sectionTitle}}
11
+ {{/if}}
12
+
13
+ {{#if sectionIntro}}
14
+ {{{sectionIntro}}}
15
+ {{/if}}
16
+
17
+ {{#each groups}}
18
+ {{#each this.properties}}
19
+ {{> (lookup ../this "template")}}
20
+
21
+ {{/each}}
22
+ {{/each}}
@@ -0,0 +1,70 @@
1
+ === {{name}}
2
+
3
+ {{#if version}}
4
+ *Introduced in {{version}}*
5
+
6
+ {{/if}}
7
+ {{#if description}}
8
+ {{{description}}}
9
+ {{else}}
10
+ No description available.
11
+ {{/if}}
12
+
13
+ {{#if units}}
14
+ *Unit:* {{units}}
15
+
16
+ {{else}}
17
+ {{#if (formatUnits name)}}
18
+ *Unit:* {{formatUnits name}}
19
+
20
+ {{/if}}
21
+ {{/if}}
22
+ {{#if (ne defined_in "src/v/config/node_config.cc")}}
23
+ {{#if (ne needs_restart undefined)}}
24
+ *Requires restart:* {{#if needs_restart}}Yes{{else}}No{{/if}}
25
+
26
+ {{/if}}
27
+ {{/if}}
28
+ {{#if visibility}}
29
+ *Visibility:* `{{visibility}}`
30
+
31
+ {{/if}}
32
+ {{#if type}}
33
+ *Type:* {{type}}
34
+
35
+ {{/if}}
36
+ {{#if (and minimum maximum)}}
37
+ *Accepted values:* [`{{minimum}}`, `{{maximum}}`]
38
+
39
+ {{else}}
40
+ {{#if minimum}}
41
+ *Minimum value:* `{{minimum}}`
42
+
43
+ {{/if}}
44
+ {{#if maximum}}
45
+ *Maximum value:* `{{maximum}}`
46
+
47
+ {{/if}}
48
+ {{/if}}
49
+ {{#if (ne default undefined)}}
50
+ *Default:* `{{formatPropertyValue default type}}`
51
+
52
+ {{/if}}
53
+ *Nullable:* {{#if nullable}}Yes{{else}}No{{/if}}
54
+
55
+ {{#if example}}
56
+ {{{renderPropertyExample this}}}
57
+ {{/if}}
58
+
59
+ {{#if aliases}}
60
+ *Aliases:* {{join aliases ", "}}
61
+
62
+ {{/if}}
63
+ {{#if is_deprecated}}
64
+ [WARNING]
65
+ ====
66
+ This property is deprecated.
67
+ ====
68
+
69
+ {{/if}}
70
+ ---
@@ -0,0 +1,59 @@
1
+ === {{name}}
2
+
3
+ {{#if version}}
4
+ *Introduced in {{version}}*
5
+
6
+ {{/if}}
7
+ {{#if description}}
8
+ {{{description}}}
9
+ {{else}}
10
+ No description available.
11
+ {{/if}}
12
+
13
+ {{#if type}}
14
+ *Type:* {{type}}
15
+
16
+ {{/if}}
17
+ {{#if acceptable_values}}
18
+ *Accepted values:* {{{acceptable_values}}}
19
+
20
+ {{/if}}
21
+ {{#if corresponding_cluster_property}}
22
+ *Related cluster property:* xref:reference:cluster-properties.adoc#{{corresponding_cluster_property}}[{{corresponding_cluster_property}}]
23
+
24
+ {{/if}}
25
+ {{#if (and minimum maximum)}}
26
+ *Accepted values:* [`{{minimum}}`, `{{maximum}}`]
27
+
28
+ {{else}}
29
+ {{#if minimum}}
30
+ *Minimum value:* `{{minimum}}`
31
+
32
+ {{/if}}
33
+ {{#if maximum}}
34
+ *Maximum value:* `{{maximum}}`
35
+
36
+ {{/if}}
37
+ {{/if}}
38
+ {{#if (ne default undefined)}}
39
+ *Default:* `{{formatPropertyValue default type}}`
40
+
41
+ {{/if}}
42
+ *Nullable:* {{#if nullable}}Yes{{else}}No{{/if}}
43
+
44
+ {{#if example}}
45
+ {{{renderPropertyExample this}}}
46
+ {{/if}}
47
+
48
+ {{#if aliases}}
49
+ *Aliases:* {{join aliases ", "}}
50
+
51
+ {{/if}}
52
+ {{#if is_deprecated}}
53
+ [WARNING]
54
+ ====
55
+ This property is deprecated.
56
+ ====
57
+
58
+ {{/if}}
59
+ ---