Skip to content
This repository has been archived by the owner on Sep 18, 2019. It is now read-only.

Commit

Permalink
Add support for @page:blank pseudo-class
Browse files Browse the repository at this point in the history
  • Loading branch information
liZe committed Aug 23, 2012
1 parent 7852a27 commit d2cf7f0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tinycss/page3.py
Expand Up @@ -130,7 +130,7 @@ def parse_page_selector(self, head):
The ``head`` attribute of an unparsed :class:`AtRule`.
:returns:
A page selector. For CSS 2.1, this is 'first', 'left', 'right'
or None.
or None. 'blank' is added by GCPM.
:raises:
:class`~parsing.ParseError` on invalid selectors
Expand All @@ -151,7 +151,8 @@ def parse_page_selector(self, head):
and head[1].type == 'IDENT'):
pseudo_class = head[1].value
specificity = {
'first': (1, 0), 'left': (0, 1), 'right': (0, 1),
'first': (1, 0), 'blank': (1, 0),
'left': (0, 1), 'right': (0, 1),
}.get(pseudo_class)
if specificity:
return (name, pseudo_class), (name_specificity + specificity)
Expand Down

0 comments on commit d2cf7f0

Please sign in to comment.