Current hashtag behaviour in Lola.
How tags work today in lola-kifuliiru-web, what is intentionally out of scope for now, and what we plan to add. Task tracking: LOLA-FEATURE-PLAN.md → social-hashtags-001.
Tags are partially supported. A hashtag is plain text inside a post body (#Kifuliiru). The app can render those segments as links and search for them as text. There is no dedicated tags table, tag index, tag page, or composer UI for adding tags.
The desktop right rail shows a small curated list of community tags as shortcuts into search.
When a post contains #word, the feed renders it as a clickable link.
| Piece | Location | |-------|----------| | Parser + links | src/components/feed/PostContentWithHashtags.tsx | | Used in feed cards | src/components/feed/PostCard.tsx | | Used in post detail | src/components/feed/PostDetailDialog.tsx |
Rules (current parser):
# followed by Unicode letters, numbers, or _ (e.g. #Kifuliiru, #Bafuliiru, #umuundu)./?q=%23{tag} (home URL with q query param).Below Language Pulse, the right sidebar shows a Tags section.
| Piece | Location | |-------|----------| | UI | src/components/lola/LolaSidebarTags.tsx | | Curated list + link helper | src/lib/lola-sidebar-tags.ts | | Shell placement | src/components/lola/shell/LolaShellDesktopRail.tsx |
Curated tags (as of this doc):
KifuliiruAbaanduumuunduimikolwaBafuliiruEach chip links to the same URL shape as in-post hashtags: /?q=%23{tag}.
Copy: title key lola.sidebar.tags — English and Kifuliiru use Tags; French Étiquettes; Swahili Lebo.
Clicking a hashtag or sidebar chip does not filter the main feed timeline. It sets ?q= on the home route, which opens the search dialog and runs a text search.
| Piece | Location | |-------|----------| | Search dialog | src/components/lola/LolaSidebarSearch.tsx | | Post search | feedService.searchActivities() in src/services/feed-service.ts | | Empty state copy | lola.no_search_results in src/lib/translations.ts |
Search behaviour:
q from URL (searchParams.get('q')).feed_activities fields: content, content_kifuliiru, content_kiswahili, content_french, content_english (case-insensitive ilike).userService.searchUsers().#Kifuliiru matches posts whose body contains that literal substring (including the # if the author typed it)./explore has static “search idea” chips (e.g. Kifuliiru, translation) that link to /explore?q=…. Those are plain text search hints, not the same curated list as the right-rail tags and not hashtag URLs.
| Gap | Notes | |-----|--------| | Tags table / index | No tags or post_tags in Supabase; nothing indexed on publish. | | Tag pages | No /tags/Kifuliiru or dedicated tag feed view. | | Feed filter by tag | Main timeline does not narrow when ?q=#tag is present; only the search overlay runs. | | Composer support | No tag picker, autocomplete, or validation in CreatePost. | | Trending / counts | No “how many posts use #imikolwa” or trending sidebar from real usage. | | Moderation / canonical tags | No approved tag list enforced in posts (sidebar list is editorial only). | | Mobile right rail | Tag chips are on the desktop right rail; mobile menu still uses other sidebar blocks (e.g. people suggestions on small screens). |
Feature plan status: social-hashtags-001 — Partial.
Classifying posts with type tags (e.g. #Imyazi, #Umwazi → news) and topic tags (e.g. #imikolwa, #Bafuliiru) — then feed tabs for grouped browsing — is specified in LOLA-CONTENT-TYPES.md. That work adds capture into feed_activities.metadata on publish; this doc covers today’s text-only hashtags.
Suggested phases (align with social-hashtags-001 and discovery work in LOLA-FEATURE-PLAN.md §3). Content types / tabs: see LOLA-CONTENT-TYPES.md.
# for search so #Kifuliiru and Kifuliiru behave the same.tags + feed_activity_tags (names TBD).# → suggest tags (from curated list + recent).Kifuliiru, Bafuliiru, etc.).To make a post findable via tags now, authors should include the hashtag in the post text, for example:
Uyu mukolwa gwa Kifuliiru #imikolwa #Bafuliiru
```text
Sidebar chips and in-post links only help if that exact text (or close substring) appears in searchable content fields.
---
## Key files
| File | Role | |------|------| | `src/lib/lola-sidebar-tags.ts` | Curated tag list + search URL helper | | `src/components/lola/LolaSidebarTags.tsx` | Right-rail Tags UI | | `src/components/feed/PostContentWithHashtags.tsx` | In-post `#` rendering | | `src/components/lola/LolaSidebarSearch.tsx` | `?q=` → search dialog | | `src/services/feed-service.ts` | `searchActivities()` text search | | `src/lib/translations.ts` | `lola.sidebar.tags`, `lola.no_search_results` |
---
## Related docs
- [LOLA-CONTENT-TYPES.md](/lola-kifuliiru/guides/content-types) — type vs topic tags, `#Imyazi` / `#Umwazi`, metadata, feed tabs (planned)
- [LOLA-FEATURE-PLAN.md](/lola-kifuliiru/guides/feature-plan) — `social-hashtags-001`, `social-content-types-001`, `social-feed-tabs-001`
- Language Pulse / sidebar layout — pulse and tags share the desktop right rail (`LolaShellDesktopRail`)