This content originally appeared on Manuel Matuzović - Web development blog and was authored by Manuel Matuzović
The initial-letter
property specifies size and sink for initial letters.
@supports (-webkit-initial-letter: 1) or (initial-letter: 1) {
p::first-letter {
-webkit-initial-letter: 3;
initial-letter: 3;
}
}
The property takes two arguments. The first one defines the size of the initial letter in terms of how many lines it occupies. The optional second argument defines the number of lines the initial letter should sink. If it's omitted, it equals the initial letter size.
p::first-letter {
initial-letter: 2;
}
1 as the second argument indicates a raised initial.
p::first-letter {
initial-letter: 2 1;
}
Values greater than 1 indicate a sunken initial letter.
p::first-letter {
initial-letter: 2 5;
}
Note: This property is currently only supported in Safari with a prefix, but it's coming to Chromium browsers soon.
My blog doesn't support comments yet, but you can reply via blog@matuzo.at.
This content originally appeared on Manuel Matuzović - Web development blog and was authored by Manuel Matuzović
Manuel Matuzović | Sciencx (2023-01-23T09:38:54+00:00) Day 86: the initial-letter property. Retrieved from https://www.scien.cx/2023/01/23/day-86-the-initial-letter-property/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.