#!/usr/pkg/bin/python3.13

__license__ = 'GPL v3'
from calibre.web.feeds.news import BasicNewsRecipe


class ppeRecipe(BasicNewsRecipe):
    __author__ = u'Artur Stachecki <artur.stachecki@gmail.com>'
    language = 'pl'
    title = u'ppe.pl'
    category = u'News'
    description = u'Portal o konsolach i grach wideo.'
    extra_css = '.categories > li {list-style: none; display: inline;} .galmini > li {list-style: none; float: left;} .calibre_navbar {clear: both;}'
    remove_empty_feeds = True
    no_stylesheets = True
    oldest_article = 7
    max_articles_per_feed = 100
    remove_javascript = True
    remove_empty_feeds = True
    remove_attributes = ['style']

    keep_only_tags = [dict(attrs={'class': 'box'})]
    remove_tags = [dict(attrs={'class': ['voltage-1', 'voltage-2',
                                         'encyklopedia', 'nag', 'related', 'comment_form', 'komentarze-box']})]

    feeds = [
        ('Newsy', 'http://ppe.pl/rss.html'),
        ('Recenzje', 'http://ppe.pl/rss-recenzje.html'),
        ('Publicystyka', 'http://ppe.pl/rss-publicystyka.html'),
    ]
