Warning: session_start(): Session cannot be started after headers have already been sent in /home/tvrreohg/public_html/manga.php on line 13
3 Døªj¿5ã@s–ddlmZmZmZmZddlmZddd„Zdd„Zddd „Z dd d „Z d d „Z dd„Z d dd„Z d!dd„Zd"dd„Zd#dd„Zdd„Zdd„ZdS)$é)ÚAtRuleÚ DeclarationÚ ParseErrorÚ QualifiedRule)Úparse_component_value_listFcCst|tƒrt||ƒ}t|ƒS)aqIterate component values out of string or component values iterable. :type input: :obj:`str` or :term:`iterable` :param input: A string or an iterable of :term:`component values`. :type skip_comments: :obj:`bool` :param skip_comments: If the input is a string, ignore all CSS comments. :returns: An iterator yielding :term:`component values`. )Ú isinstanceÚstrrÚiter)ÚinputÚ skip_comments©r ú3/tmp/pip-build-_d5lkt3n/tinycss2/tinycss2/parser.pyÚ_to_token_iterators  rcCs x|D]}|jdkr|SqWdS)zçReturn the next significant (neither whitespace or comment) token. :type tokens: :term:`iterator` :param tokens: An iterator yielding :term:`component values`. :returns: A :term:`component value`, or :obj:`None`. Ú whitespaceÚcommentN)rr)Útype)ÚtokensÚtokenr r r Ú_next_significants  rcCsRt||ƒ}t|ƒ}t|ƒ}|dkr0tddddƒS|dk rJt|j|jddƒS|SdS)aúParse a single :diagram:`component value`. This is used e.g. for an attribute value referred to by ``attr(foo length)``. :type input: :obj:`str` or :term:`iterable` :param input: A string or an iterable of :term:`component values`. :type skip_comments: :obj:`bool` :param skip_comments: If the input is a string, ignore all CSS comments. :returns: A :term:`component value` (that is neither whitespace or comment), or a :class:`~tinycss2.ast.ParseError`. NrÚemptyzInput is emptyz extra-inputzGot more than one token)rrrÚ source_lineÚ source_column)r r rÚfirstÚsecondr r r Úparse_one_component_value"s  rcCs2t||ƒ}t|ƒ}|dkr(tddddƒSt||ƒS)a?Parse a single :diagram:`declaration`. This is used e.g. for a declaration in an `@supports `_ test. :type input: :obj:`str` or :term:`iterable` :param input: A string or an iterable of :term:`component values`. :type skip_comments: :obj:`bool` :param skip_comments: If the input is a string, ignore all CSS comments. :returns: A :class:`~tinycss2.ast.Declaration` or :class:`~tinycss2.ast.ParseError`. Any whitespace or comment before the ``:`` colon is dropped. NrrzInput is empty)rrrÚ_parse_declaration)r r rÚ first_tokenr r r Úparse_one_declaration>s  rc Cs |}|jdkr&t|j|jdd|jƒSt|ƒ}|dkrHt|j|jddƒS|dkrht|j|jdd|jƒSg}d}xht|ƒD]\\}}|dkrœ|d krœd }|}n0|d kr¾|jdkr¾|jd kr¾d }n|jdkrÌd}|j|ƒqzW|d krì||d…=t|j|j|j |j||d kƒS)a§Parse a declaration. Consume :obj:`tokens` until the end of the declaration or the first error. :type first_token: :term:`component value` :param first_token: The first component value of the rule. :type tokens: :term:`iterator` :param tokens: An iterator yielding :term:`component values`. :returns: A :class:`~tinycss2.ast.Declaration` or :class:`~tinycss2.ast.ParseError`. ÚidentÚinvalidz.Expected for declaration name, got %s.Nz,Expected ':' after declaration name, got EOFú:z,Expected ':' after declaration name, got %s.Úvalueú!ZbangZ importantrr)rr) rrrrrÚ enumerateÚ lower_valueÚappendrr!) rrÚnameZcolonr!ÚstateÚirZ bang_positionr r r rVs:         rcCs4g}x |D]}|dkrP|j|ƒq Wt|t|ƒƒS)z=Like :func:`_parse_declaration`, but stop at the first ``;``.ú;)r%rr )rrZother_declaration_tokensrr r r Ú_consume_declaration_in_list‡s  r*cCsˆt||ƒ}g}xt|D]l}|jdkr2|s€|j|ƒq|jdkrL|s€|j|ƒq|jdkrh|jt||ƒƒq|dkr|jt||ƒƒqW|S)uMParse a :diagram:`declaration list` (which may also contain at-rules). This is used e.g. for the :attr:`~tinycss2.ast.QualifiedRule.content` of a style rule or ``@page`` rule, or for the ``style`` attribute of an HTML element. In contexts that don’t expect any at-rule, all :class:`~tinycss2.ast.AtRule` objects should simply be rejected as invalid. :type input: :obj:`str` or :term:`iterable` :param input: A string or an iterable of :term:`component values`. :type skip_comments: :obj:`bool` :param skip_comments: Ignore CSS comments at the top-level of the list. If the input is a string, ignore all comments. :type skip_whitespace: :obj:`bool` :param skip_whitespace: Ignore whitespace at the top-level of the list. Whitespace is still preserved in the :attr:`~tinycss2.ast.Declaration.value` of declarations and the :attr:`~tinycss2.ast.AtRule.prelude` and :attr:`~tinycss2.ast.AtRule.content` of at-rules. :returns: A list of :class:`~tinycss2.ast.Declaration`, :class:`~tinycss2.ast.AtRule`, :class:`~tinycss2.ast.Comment` (if ``skip_comments`` is false), :class:`~tinycss2.ast.WhitespaceToken` (if ``skip_whitespace`` is false), and :class:`~tinycss2.ast.ParseError` objects rrz at-keywordr))rrr%Ú_consume_at_ruler*)r r Úskip_whitespacerÚresultrr r r Úparse_declaration_list‘s"       r.cCs^t||ƒ}t|ƒ}|dkr(tddddƒSt||ƒ}t|ƒ}|dk rZt|j|jdd|jƒS|S)a¬Parse a single :diagram:`qualified rule` or :diagram:`at-rule`. This would be used e.g. by `insertRule() `_ in an implementation of CSSOM. :type input: :obj:`str` or :term:`iterable` :param input: A string or an iterable of :term:`component values`. :type skip_comments: :obj:`bool` :param skip_comments: If the input is a string, ignore all CSS comments. :returns: A :class:`~tinycss2.ast.QualifiedRule`, :class:`~tinycss2.ast.AtRule`, or :class:`~tinycss2.ast.ParseError` objects. Any whitespace or comment before or after the rule is dropped. NrrzInput is emptyz extra-inputz4Expected a single rule, got %s after the first rule.)rrrÚ _consume_rulerrr)r r rrZruleÚnextr r r Úparse_one_ruleÃs    r1cCsdt||ƒ}g}xP|D]H}|jdkr2|s\|j|ƒq|jdkrL|s\|j|ƒq|jt||ƒƒqW|S)a§Parse a non-top-level :diagram:`rule list`. This is used for parsing the :attr:`~tinycss2.ast.AtRule.content` of nested rules like ``@media``. This differs from :func:`parse_stylesheet` in that top-level ```` tokens are not ignored. :type input: :obj:`str` or :term:`iterable` :param input: A string or an iterable of :term:`component values`. :type skip_comments: :obj:`bool` :param skip_comments: Ignore CSS comments at the top-level of the list. If the input is a string, ignore all comments. :type skip_whitespace: :obj:`bool` :param skip_whitespace: Ignore whitespace at the top-level of the list. Whitespace is still preserved in the :attr:`~tinycss2.ast.QualifiedRule.prelude` and the :attr:`~tinycss2.ast.QualifiedRule.content` of rules. :returns: A list of :class:`~tinycss2.ast.QualifiedRule`, :class:`~tinycss2.ast.AtRule`, :class:`~tinycss2.ast.Comment` (if ``skip_comments`` is false), :class:`~tinycss2.ast.WhitespaceToken` (if ``skip_whitespace`` is false), and :class:`~tinycss2.ast.ParseError` objects. rr)rrr%r/)r r r,rr-rr r r Úparse_rule_listås      r2cCslt||ƒ}g}xX|D]P}|jdkr2|sd|j|ƒq|jdkrL|sd|j|ƒq|dkr|jt||ƒƒqW|S)a²Parse :diagram:`stylesheet` from text. This is used e.g. for a ``