Merge pull request #13090 from awanlin/topic/revert-heading-size

[TechDocs] Fix large headings
This commit is contained in:
Eric Peterson
2022-08-16 10:22:46 +02:00
committed by GitHub
2 changed files with 7 additions and 1 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-techdocs': patch
---
Added back reduction in size, this fixes the extremely large TeachDocs headings
@@ -47,7 +47,8 @@ ${headings.reduce<string>((style, heading) => {
let factor: number | string = 1;
if (typeof value === 'number') {
// convert px to rem
factor = value / htmlFontSize;
// 60% of the size defined because it is too big
factor = (value / htmlFontSize) * 0.6;
}
if (typeof value === 'string') {
factor = value.replace('rem', '');