# Fetch full multipage articles
single_page_link: //a[contains(@class, 'ts-one-page')]

# Content is here
body: //article

# General cleanup
strip: //nav
strip: //button
strip: //iframe
strip_id_or_class: hcf-hidden
strip_id_or_class: ts-user-quote
strip_id_or_class: ts-abo-link
strip_id_or_class: ts-homepage-link
strip_id_or_class: ts-recommendation
strip_id_or_class: newsletter
strip: //div[@element-type='embedWrapper']

# strip related-articles, pubDate, footer
strip: //aside
strip: //time/parent::p
strip: //a[@data-gtm-class='article-home-link']/parent::p/self::* | //a[@data-gtm-class='article-home-link']/parent::p/following-sibling::*

# Fix pictures and captions
strip: //picture/source
strip: //img/@srcset
replace_string(<a class="ts-gallery): <p class="ts-gallery
replace_string(<figcaption class="ts-caption">): <br><small><em>
replace_string(</figcaption>): </em></small>
# Fix image galleries
replace_string(<a class=" ajaxify): <p class="ajaxify
replace_string(<div class="ts-caption"><div><p>): <small><em>

# Try it yourself
test_url: https://www.tagesspiegel.de/berlin/das-leben-der-berliner-u-bahn-schnorrer-ich-hatte-mal-eine-firma-das-war-geil-/20489728.html
test_url: https://www.tagesspiegel.de/berlin/bezirke/wedding/wedding-jetzt/auf-der-suche-nach-einem-stadtteil-wilder-weiter-wedding/8757156.html
test_url: https://www.tagesspiegel.de/berlin/olympia-in-berlin-der-flughafen-tegel-soll-das-olympische-dorf-werden/10645036.html
test_url: https://www.tagesspiegel.de/mediacenter/fotostrecken/berlin/bildergalerie-kreuzberger-der-woche/9305534.html
