#!/usr/bin/env python
# vim:fileencoding=utf-8

from calibre.web.feeds.news import BasicNewsRecipe


class ViknaSTB(BasicNewsRecipe):
    title = '\u0412\u0456\u043a\u043d\u0430-\u043d\u043e\u0432\u0438\u043d\u0438'
    __author__ = 'bugmen00t'
    description = '\u0423\u043a\u0440\u0430\u0457\u043d\u0441\u044c\u043a\u0430 \u0456\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0456\u0439\u043d\u0430 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u0430 \u0442\u0435\u043b\u0435\u043a\u0430\u043d\u0430\u043b\u0443 \u00ab\u0421\u0422\u0411\u00bb.'  # noqa: E501
    publisher = '\u0422\u041e\u0412 \u201c\u0421\u041b\u041c \u041d\u043e\u0432\u0438\u043d\u0438\u201d'
    category = 'newspaper'
    cover_url = 'https://yt3.ggpht.com/QZxhLPDcqhjMitCDPWbzk-Zs-ILbGo3ww1iuV9SIE1k0iqjoOIctT2d4BdyEsSAR6yWsbKbGWg=s900-c-k-c0x00ffffff-no-rj'
    language = 'uk'
    no_stylesheets = False
    remove_javascript = False
    auto_cleanup = False
    remove_empty_feeds = True
    oldest_article = 3
    max_articles_per_feed = 20

    remove_tags_before = dict(name='h1')

    remove_tags_after = dict(name='div', attrs={'class': 'content-wrapper'})

    remove_tags = [
        dict(name='div', attrs={'class': 'share-content-wrapper flex-wrapper'}),
        dict(name='div', attrs={'class': 'sticky-wrapper'}),
        dict(name='div', attrs={'class': 'promo-wrapper'}),
        dict(name='div', attrs={'class': 'mn-wrapper'}),
        dict(name='div', attrs={'class': 'news-tags border-btm-grey'}),
    ]

    feeds = [('\u0412\u0456\u043a\u043d\u0430', 'https://vikna.tv/feed/')]
