[0.9.1] Mobile: Personal/Community filter the home hive from any page

- Turn the header Personal/Community tabs into links to
  /activity?hive=personal|community, so they work on every page (they take
  you to the home and filter the hexagons), not only while already on
  /activity — no more dead buttons off the home.
- Drop the "All" tab: entering shows all 10 categories; clicking a filter
  that is already active toggles it off and shows all again.
- Filter the hive server-side (renderHiveNav reads the request filter set
  by the middleware) instead of the CSS radio-hack, and drop the now-dead
  half-filter CSS. Active tab is highlighted via the .active class.
This commit is contained in:
s1to 2026-08-04 11:46:19 +02:00
parent d5dac39bfd
commit 7f85389a88
4 changed files with 19 additions and 24 deletions

View file

@ -8598,6 +8598,8 @@ const middleware = [
},
async (ctx, next) => {
if (!ctx.path.startsWith('/assets/') && !ctx.path.startsWith('/image/') && !ctx.path.startsWith('/blob/') && !ctx.path.startsWith('/qr') && !ctx.path.startsWith('/c/')) {
// filtro del hive (Personal/Community) del home; lo leen la topbar (enlaces) y renderHiveNav (categorías mostradas)
global.__OASIS_HIVE_FILTER__ = (ctx.path === '/activity' && (ctx.query.hive === 'personal' || ctx.query.hive === 'community')) ? ctx.query.hive : '';
const now = Date.now();
if (now - sharedState.getLastRefresh() > 60000) {
sharedState.setLastRefresh(now);