mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-15 11:21:09 +02:00
Move inactive projects out of active workspace: - bauntown (community website) - maerchenzauber (AI story generation) - memoro (voice memo app) - news (news aggregation) - nutriphi (nutrition tracking) - reader (reading app) - uload (URL shortener) - wisekeep (AI wisdom extraction) Update CLAUDE.md documentation: - Add presi to active projects - Document archived projects section - Update workspace configuration Archived apps can be re-activated by moving back to apps/ 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
35 lines
906 B
TypeScript
35 lines
906 B
TypeScript
import { useEffect } from 'react';
|
|
import { usePathname } from 'expo-router';
|
|
import { useAnalytics } from '../hooks/useAnalytics';
|
|
|
|
export const AnalyticsNavigationTracker = () => {
|
|
const pathname = usePathname();
|
|
const { screen } = useAnalytics();
|
|
|
|
useEffect(() => {
|
|
if (pathname) {
|
|
// Convert path to screen name: /memo/123 -> memo_detail
|
|
const segments = pathname.split('/').filter(Boolean);
|
|
let screenName = 'home';
|
|
|
|
if (segments.length > 0) {
|
|
// Handle dynamic routes
|
|
if (segments[0] === 'memo' && segments[1]) {
|
|
screenName = 'memo_detail';
|
|
} else if (segments[0] === 'space' && segments[1]) {
|
|
screenName = 'space_detail';
|
|
} else {
|
|
// Convert path to screen name
|
|
screenName = segments.join('_');
|
|
}
|
|
}
|
|
|
|
screen(screenName, {
|
|
path: pathname,
|
|
timestamp: new Date().toISOString(),
|
|
});
|
|
}
|
|
}, [pathname, screen]);
|
|
|
|
return null;
|
|
};
|