Print.js
Print.js copied to clipboard
class or style font-size is not working
Such as, I use Print.js,I want to get a new font-size, i put it in class or style,It's not working, how
Try to use an printjs v1.3.1, printjs add font-size: font_size !important
on new version.It caused some font-size
to be ignored.
Or wait for the author to release v2.
+1
set font_size: "" in printjs settings seems to working to be a work around for this
+1
set font_size: "" in printjs settings seems to working to be a work around for this
const style = '@page { } ' +'@media print { .f-14{ font-size: 14ppx }' ;
printJS({
printable: "printTable",
type: "html",
header: null,
targetStyles: ["*"],
style: style,
});
I wrote this way, but I still don't work. How did you write it?
set font_size: "" in printjs settings seems to working to be a work around for this
const style = '@page { } ' +'@media print { .f-14{ font-size: 14ppx }' ; printJS({ printable: "printTable", type: "html", header: null, targetStyles: ["*"], style: style, }); I wrote this way, but I still don't work. How did you write it?
u should set font_size: ''
same:
printJS({
printable: "printTable",
type: "html",
header: null,
targetStyles: ["*"],
style: style,
font_size: ''
});
set font_size: "" in printjs settings seems to working to be a work around for this
const style = '@page { } ' +'@media print { .f-14{ font-size: 14ppx }' ; printJS({ printable: "printTable", type: "html", header: null, targetStyles: ["*"], style: style, }); I wrote this way, but I still don't work. How did you write it?
u should set
font_size: ''
same:printJS({ printable: "printTable", type: "html", header: null, targetStyles: ["*"], style: style, font_size: '' });
thanks!
nb