from __future__ import absolute_import, division, print_function, unicode_literals

from calibre.web.feeds.news import BasicNewsRecipe


class EchoMsk(BasicNewsRecipe):
    title = '\u042d\u0425\u041e'
    __author__ = 'bugmen00t'
    description = (
        '\u042d\u0425\u041e - \u043a\u0430\u043a \u043d\u0430 \u0441\u0442\u0430\u0440\u043e\u043c'
        ' \u0434\u043e\u0431\u0440\u043e\u043c \u0440\u0430\u0434\u0438\u043e'
    )
    publisher = 'Radio Echo GmbH'
    category = 'news'
    cover_url = 'https://echofm.online/logo.png'
    language = 'ru'
    no_stylesheets = True
    remove_javascript = False
    auto_cleanup = False
    oldest_article = 7
    max_articles_per_feed = 50

    remove_tags_before = dict(name='article')

    remove_tags_after = dict(name='article')

    remove_tags = [
        dict(name='span', attrs={'class': 'sc-7b4cbb79-0 guzUFC'}),
        dict(name='div', attrs={'class': 'sc-f94c4ef5-0 frGiYu'}),
        dict(name='div', attrs={'class': 'sc-f94c4ef5-0 frGiYu'}),
    ]

    feeds = [
        ('\u0413\u043b\u0430\u0432\u043d\u043e\u0435', 'https://echofm.online/feed'),
        ('\u041d\u043e\u0432\u043e\u0441\u0442\u0438', 'https://echofm.online/news/feed'),
        ('\u041c\u043d\u0435\u043d\u0438\u044f', 'https://echofm.online/opinions/feed'),
        ('\u0414\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u044b', 'https://echofm.online/documents/feed'),
    ]
