openvibers/openvibe.search Commits

Search accepts Report's topics and Design's icons and themes (#198)

OP OpenVibers committed 11 days ago · 9e5fa61275 · 2 files, +5 −0

Changes

ddiff --git a/server/config.js b/server/config.js
iindex fd5a6a1..289cba1 100644
---- a/server/config.js
++++ b/server/config.js
@@@ -57,6 +57,8 @@ const DEFAULT_EVENT_OWNERS = ['wiki', 'blog', 'news', 'reviews', 'deals', 'coupo
// Owner-API writers through openvibe-publishing/search-relay (their own outbox, delivered by PUT/DELETE):
// OpenVibe.Meme's entries and OpenVibe.Exchange's listings.
'meme', 'exchange',
++ // OpenVibe.Report's Rundown topic pages and OpenVibe.Design's icon and theme pages (contracts 0.275.0).
++ 'report', 'design',
// Owner-API writers listed so their front-page card and ?owner= filter exist: OpenVibe.Video's uploads (MediaHub,
// service id media-hub; an event type has no hyphen), OpenVibe.Food's checked recipes and OpenVibe.Bot's model pages.
'media-hub', 'food', 'bot'];
ddiff --git a/server/web/page.js b/server/web/page.js
iindex 8a7a4c3..5fba587 100644
---- a/server/web/page.js
++++ b/server/web/page.js
@@@ -222,6 +222,8 @@ const SOURCES = {
tours: ['OpenVibe.Tours', 'Places to see, cities and self-guided walks, from OpenStreetMap and Wikivoyage.'],
meme: ['OpenVibe.Meme', 'Running jokes, catchphrases and memes, with where each one started.'],
exchange: ['OpenVibe.Exchange', 'Themes, templates and add-ons people share, with their permissions and licence.'],
++ report: ['OpenVibe.Report', 'The Rundown: what streamers talked about, topic by topic.'],
++ design: ['OpenVibe.Design', 'Icons and themes for every OpenVibe site, free to download.'],
};
const ICON_OF = { sources: 'docs', 'media-hub': 'video' };
// What a count of each kind is called on the front page ("10,621 job listings"); a kind not named here is "documents".
@@@ -236,6 +238,7 @@ const KIND_WORDS = {
'shoes/shoe': ['shoe model', 'shoe models'],
'tours/place': ['place to see', 'places to see'], 'tours/city': ['travel city', 'travel cities'], 'tours/route': ['self-guided walk', 'self-guided walks'],
'meme/entry': ['meme', 'memes'], 'exchange/listing': ['shared listing', 'shared listings'],
++ 'report/topic': ['Rundown topic', 'Rundown topics'], 'design/icon': ['icon', 'icons'], 'design/theme': ['theme', 'themes'],
};
const fmt = (n) => Number(n).toLocaleString('en-US');
const kindWords = (owner, type, n) => { const w = KIND_WORDS[`${owner}/${type}`]; return `${fmt(n)} ${w ? w[n === 1 ? 0 : 1] : n === 1 ? 'document' : 'documents'}`; };