From 1217b6de34cc5f23cc73d8d37a51c4616a3780ab Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Sun, 26 Oct 2025 15:07:38 +0100 Subject: OPML export/import frss:priority (#8158) Follow-up of https://github.com/FreshRSS/FreshRSS/pull/7583 --- app/views/helpers/export/opml.phtml | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'app/views') diff --git a/app/views/helpers/export/opml.phtml b/app/views/helpers/export/opml.phtml index fba6d2498..de044332e 100644 --- a/app/views/helpers/export/opml.phtml +++ b/app/views/helpers/export/opml.phtml @@ -38,6 +38,15 @@ function feedsToOutlines(array $feeds, bool $excludeMutedFeeds = false): array { break; } + $outline['frss:priority'] = match ($feed->priority()) { + FreshRSS_Feed::PRIORITY_IMPORTANT => FreshRSS_Export_Service::PRIORITY_IMPORTANT, + FreshRSS_Feed::PRIORITY_MAIN_STREAM => null, // Default + FreshRSS_Feed::PRIORITY_CATEGORY => FreshRSS_Export_Service::PRIORITY_CATEGORY, + FreshRSS_Feed::PRIORITY_FEED => FreshRSS_Export_Service::PRIORITY_FEED, + FreshRSS_Feed::PRIORITY_HIDDEN => FreshRSS_Export_Service::PRIORITY_HIDDEN, + default => null, + }; + if ($feed->kind() === FreshRSS_Feed::KIND_HTML_XPATH || $feed->kind() === FreshRSS_Feed::KIND_XML_XPATH) { /** @var array */ $xPathSettings = $feed->attributeArray('xpath') ?? []; -- cgit v1.2.3