managarten/apps/context/apps/mobile/utils/markdownProcessor.ts
Till-JS bb0e0cf5cb 🚚 feat(context): integrate context app into monorepo
Restructure the context app (formerly basetext) to follow the monorepo
pattern with proper workspace configuration.

Changes:
- Move app files to apps/context/apps/mobile/
- Rename package to @context/mobile
- Update bundle ID to com.manacore.context
- Create pnpm-workspace.yaml for project workspace
- Add dev scripts to root package.json
- Update CLAUDE.md with project documentation

The app structure is prepared for future web/backend additions.

Note: Existing TypeScript errors in the original codebase are preserved.
These should be fixed in a follow-up PR.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-05 15:09:04 +01:00

24 lines
703 B
TypeScript

/**
* Utility functions for processing markdown syntax
*/
/**
* Processes content in markdown
*
* @param content The markdown content to process
* @param isDark Whether dark mode is enabled
* @returns Processed markdown content
*/
export const processAIContentBlocks = (content: string, isDark: boolean): string => {
// Wir entfernen alle speziellen Marker, die früher für die Unterscheidung
// zwischen Benutzer- und KI-Eingaben verwendet wurden
if (!content) return '';
// Entferne alle Marker
let processedContent = content
.replace(/\/\/\/ KI Antwort, .*?, .*?\n\n/g, '')
.replace(/\/\/\/ Nutzer, .*?, .*?\n\n/g, '')
.replace(/\n\n\/\/\//g, '');
return processedContent;
};