CSS::D...::Style(3pm)
π CSS::DOM::Rule::Style π
okay so bestie, welcome to the manual page for CSS::DOM::Rule::Style β yes that's the whole name, the header up top just clipped it like a bad crop, no cap.
β¨ NAME β¨
CSS::DOM::Rule::Style β it's the CSS style rule class for CSS::DOM. that's it, that's the vibe. π
πΈ VERSION πΈ
Version 0.17 β she's giving established, she's giving stable. π
π¦ SYNOPSIS π¦
here's the whole little moment, verbatim, don't touch it:
use CSS::DOM;
my $ruleset = CSS::DOM->parse(
'p:firstline, h3 { font-weight: bold }'
)->cssRules->[0];
$ruleset->selectorText; # 'p:firstline, h3'
$ruleset->style; # a CSS::DOM::Style object
$ruleset->style->fontWeight; # 'bold'
see how she parses a whole ruleset, pulls the first rule out of cssRules, reads back the selector text, grabs the style object, and then just casually reads fontWeight off it like it's nothing? main character energy fr fr. π₯
π DESCRIPTION π
so this module implements CSS style rules for CSS::DOM. she inherits from CSS::DOM::Rule, and she implements the CSSStyleRule DOM interface. that's the whole personality. iconic, honestly. π
π METHODS π
π selectorText
returns a string representing the selector(s). and if you pass an argument? she sets it. she's flexible like that, we love a method with range. β¨
π style
returns the CSS::DOM::Style object that represents the declaration block of this rule. that's where all the actual styling lives, iykyk. π
π₯ SEE ALSO π₯
CSS::DOMCSS::DOM::StyleCSS::DOM::Rule
go read those too bestie, they're all in the same friend group. π«Ά
and that's the page!! this whole thing is perl v5.36.0 flavored, dated 2023-08-02, and it's part of the User Contributed Perl Documentation situation. mwah, go style something gorgeous. πβ¨
π¦ where this page comes from
- debian trixie: libcss-dom-perl 0.17-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libcss-dom-perl 0.17-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libcss-dom-perl 0.17-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libcss-dom-perl 0.17-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms