File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -33,17 +33,25 @@ components.forEach(component => {
33
33
if ( isParentComponent ) {
34
34
content += `sidebar_position: 1\n` ;
35
35
}
36
- content += `sidebar_label : ${ componentName } \n` ;
36
+ content += `id : ${ component . name } \n` ;
37
37
content += `title: ${ component . name } \n` ;
38
+ content += `sidebar_label: ${ componentName } \n` ;
38
39
content += `---\n` ;
39
40
40
41
/* General */
41
42
content += `${ component . description } \n` ;
42
43
content += `[(code example)](${ component . example } )\n` ;
43
44
44
45
if ( component . extends ) {
46
+ let extendsText = component . extends ?. join ( ', ' ) ;
47
+ if ( component . extendsLink ) {
48
+ extendsText = `[${ extendsText } ](${ component . extendsLink } )` ;
49
+ } else {
50
+ extendsText = `[${ extendsText } ](${ extendsText } )` ;
51
+
52
+ }
45
53
content += `:::info\n` ;
46
- content += `This component extends **${ component . extends ?. join ( ', ' ) } ** props.\n` ;
54
+ content += `This component extends **${ extendsText } ** props.\n` ;
47
55
content += `:::\n` ;
48
56
}
49
57
You can’t perform that action at this time.
0 commit comments