Web::CSS::MediaQueries::Serializer
Serialization of Media Queries
SYNOPSIS
use Web::CSS::MediaQueries::Serializer;
my $s = Web::CSS::MediaQueries::Serializer->new;
warn $s->serialize_mq_list ($mq_list)
DESCRIPTION
The Web::CSS::MediaQueries::Serializer
object can be used to serialize the parsed representation of media queries (as returned by the Web::CSS::MediaQueries::Parser object) into the canonical string representation of it.
METHODS
Following methods are available:
$serializer = Web::CSS::MediaQueries::Serializer->new
-
Return a new instance of the serializer.
$string = $serializer->serialize_mq ($mq)
-
Serialize the specified media query construct into the textual representation of the media query, as specified by the Media Queries and CSSOM specifications.
$string = $serializer->serialize_mq_list ($mq_list)
-
Serialize the specified media query list construct into the textual representation of the media query list, as specified by the Media Queries and CSSOM specifications.
SPECIFICATIONS
- MQ
-
Media Queries
<http://dev.w3.org/csswg/mediaqueries/>
. - CSSOM
-
CSSOM
<http://dev.w3.org/csswg/cssom/#media-queries>
.If a media query contains the 'only' keyword, the string "only" followed by a U+0020 SPACE character MUST be prepended to the result of the serialize a media query steps.
SEE ALSO
AUTHOR
Wakaba <wakaba@suikawiki.org>.
LICENSE
Copyright 2008-2013 Wakaba <wakaba@suikawiki.org>.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.