Repository navigation
Open and write MindManager .mmap maps - #3
Merged
Merged
Conversation
MindManager keeps its maps in a zip holding Document.xml (X5 and later;
the Mac builds of MindManager 10 wrote flat XML), and Cartocortex now
reads and writes that. Reading is the strict XML parser from the old
.xmind files (no DOCTYPE, predefined entities only): texts, notes (the
XHTML note and its plain-text preview), links, task priorities (Prio1-9)
and progress (TaskPercentage), fill and text colour ("aarrggbb", alpha
first), folding, relationships (as the map's relationship lines),
floating topics and callouts. The growth direction of the central topic
opens as a logic-left, logic-right or two-sided map. Writing goes the
other way (Save as .mmap and a new "Export MindManager" button): one map
per sheet, so extra sheets may not show in MindManager itself, and topic
links to other topics, pictures, per-word style, boundaries and
summaries are not carried. The unzip of the .xmind reader is exported
for the .mmap reader.
Agent: Vibe (Mistral, glm-5-latest-short)
Relu-par-humain: Martin-PB
This was referenced Oct 17, 2026
Reading mints a fresh topic id for every node, so the two reads of the same sample never agreed on their ids and the test could not pass. The comparison now drops the ids and the topic links pointing at them, the same fix the FreeMind branch already carries. Agent: Vibe (Mistral, glm-5-latest-short) Relu-par-humain: Martin-PB
Resolve the conflicts in files.ts (keep main's parseDocReport with the import report and add the .mmap branch to it) and README.md (keep the MindManager paragraph, main's unzip limit and the safety rule naming MindManager). Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G2FX9kDHnPYmocPxX3w7ov
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Intention
Deuxième étape du programme « tous les formats de mind map » (après la PR #1 sur FreeMind
.mm, sur laquelle celle-ci est basée — fusionner #1 d'abord) : ouvrir et écrire les cartes MindManager.mmap. C'est un zip contenantDocument.xml(MindManager X5 et suivants) ; les builds MindManager 10 pour Mac écrivaient du XML plat, que le lecteur accepte aussi.Réalisation
src/mindmanager.ts(nouveau) — lecteur/écrivain.mmap. Lecture : le parseur XML strict du lecteur.xmind(pas de DOCTYPE, entités prédéfinies uniquement), sur le zip ou le XML plat. Textes, notes (XHTML et sonPreviewPlainText, plus le schéma simplifiéNotes), liens (les#xpointer(...)pointant vers un topic sont ignorés), prioritésurn:mindjet:Prio1-9et progressionTaskPercentage, couleurs « aarrggbb » (alpha d'abord ; alpha00= pas de couleur), pliage, relations (remappées vers nos ids, comme lignes de relation), topics flottants (mm → px) et callouts (ouverts comme enfants ordinaires). La direction de croissance du topic central (SubTopicsShape, ou le défaut duStyleGroup) ouvre en Logic (left), Logic (right) ou Map (réordonnée droite d'abord, comme le fait MindManager). Écriture : un<ap:OneTopic>par sheet dans un zip minimal (Document.xml,[Content_Types].xml,_rels/.rels).src/mindmanager.test.ts(nouveau) — 5 tests : document complet, schéma simplifié, fichiers refusés, aller-retour zip, direction de croissance + XML plat, couleurs.src/xmind.ts—unzipest exporté pour le lecteur.mmap.src/files.ts—docBytes/parseDocgèrent.mmap; filtres Open et Save as.src/files.test.ts— aller-retour.mmapviadocBytes/parseDoc.src/App.tsx— entrée « Export MindManager » dans le menu Export.README.md— paragraphe MindManager, phrase Save as, règle d'import.Pertes documentées (écriture) : les liens d'un topic vers un autre topic, les images, le style par mot, les frontières et les résumés ne passent pas ; plusieurs sheets donnent plusieurs cartes, qui peuvent ne pas s'afficher dans MindManager lui-même.
Ce que l'agent a fait et ce que l'humain a changé
Le format vient de l'importeur MindManager de Freeplane (
mindmanager2mm.xsl) et de celui de WiseMapping (MindManagerImporter.ts), la spécification officielle n'étant pas publique. Le module a été validé par un jumeau exécutable dans un bac à sable TypeScript : 63 contrôles passent (lecture du document complet, schéma simplifié, refus des fichiers invalides, aller-retour zip, directions de croissance, couleurs et cas tordus).npm test,tscetnpm run buildn'ont PAS été tournés par l'agent (pas de Node dans le bac à sable), et la CI ne se déclenche pas sur les branchesmp-*(seulementmainetfeat/*) : ce sont donc les vérifications humaines ci-dessous qui valident. Le format n'a jamais été vérifié contre un vrai MindManager. (Au passage : le premier commit de la PR #1 avait un bug d'encodage, corrigé sur sa branche par75c75abavant celle-ci.)Vérifications humaines
npm testnpm run build.mmapexporté par MindManager, puis réexporter depuis Cartocortex et rouvrir dans MindManager