def meta(self):
from lxml import etree
- # Wrong! should be metadata
- d = {}
+ metadata = {}
data = self.materialize()
data = data.replace(u'\ufeff', '')
header = t.find('.//header')
if header is None:
header = etree.fromstring(data).find('.//{http://nowoczesnapolska.org.pl/sst#}header')
- d['title'] = getattr(header, 'text', ' ') or ' '
+ metadata['title'] = getattr(header, 'text', ' ') or ' '
#print 'meta', d['title']
m = t.find('metadata')
if m is not None:
c = m.find('{http://purl.org/dc/elements/1.1/}relation.coverimage.url')
if c is not None:
- d['cover_url'] = c.text
+ metadata['cover_url'] = c.text
c = m.find('{http://purl.org/dc/elements/1.1/}audience')
if c is not None:
- d['audience'] = c.text
+ metadata['audience'] = c.text
- return d
+ return metadata
def can_edit(self, user):
if self.owner_user:
}
h1, h2 > a > p, h3 {
- color: none;
+ color: unset;
}
div.class {
}
#more-shorthands {
- margin: 0;
+ margin: 0.1%;
padding: 1px 0 2px 0;
font: normal small/20px 'Trebuchet MS', Verdana, sans-serif;
font: 0/0 a;
width: .1em;
background-color: #009998;
background: -webkit-gradient(linear, left top, left bottom, from(red), to(blue));
- margin: ;
.nested-multiple {
multiple-semi-colons: yes;;;;;;
};