Text size not changing

1 Answer 938 Views
General Discussions PDF Processing Styling Styling / Themes TreeList TreeView
Vlad
Top achievements
Rank 1
Vlad asked on 08 Jul 2021, 01:41 PM

Hi , there. 

Recently i tried to use Kendo for React to create PDF document.  But i faced with one issue, i cannot change font size of text. 

No matter what properties i use, and what tags i am using it's always same size, even for <h1>

The wierdest thing that everything else working fine colors, margin, font colors, etc.

This is the example of  code which i am using.

 

.title {
  font-size30pt !important;
  colorgreen;
  font-weightbold;
}

 

return (
    <div>
      <PDFExport
        ref={pdfExportComponent}
        paperSize="A4"
        fileName='Dossiers Export'
      >
        <div style={{height: '2%', width: '100%', background:'#e6ecf0'}}>
         <p className = 'title'>styled</p>
        </div>
      </PDFExport>
    </div>
  );
})

 

Does anyone else faced with this issue. ?

1 Answer, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 09 Jul 2021, 05:20 AM

Hello, Vlad,

I tested this locally and it was working as expected:

https://stackblitz.com/edit/react-yxy5he?file=index.html

Please check if using px instead of pt will make a difference:

https://www.telerik.com/kendo-react-ui/components/drawing/pdf-output/dimensions-css-units/

Regards,
Stefan
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
General Discussions PDF Processing Styling Styling / Themes TreeList TreeView
Asked by
Vlad
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Share this question
or