feat(v12-n): Carte O fusion noeud central + palette minimaliste encre/papier/ocre
- YAML: fusion 3 noeuds confus (centre + ncs-politique + medecine-corps-social) en 1 seul noeud central 'Contrat social + Medecine du corps social' - Build script: toutes les thematiques rattachees directement au centre (suppression mapping NCS/MDCS), radius central 30px, projets 18px - CarteO.vue palette V1.2: central #0F172A (encre), essais #FFFFFF stroke encre, projets #B45309 (ocre conserve) - Labels: inscrit dans le cercle (blanc) pour central+projets, a droite (encre douce) pour essais - Label central long split sur 2-3 lignes via splitCentralLabel() - Background: #FAFAF7 (papier, raccord colonnes laterales) - Liens: #94A3B8 opacity 0.4 1px 17 nodes / 19 edges. Build SSR 5 pages prerender + server, 0 warning.
This commit is contained in:
@@ -11,12 +11,12 @@ const REPO_ROOT = path.resolve(__dirname, '..')
|
||||
const SOURCE = path.join(REPO_ROOT, 'public/data/carte-o-source.yaml')
|
||||
const OUTPUT = path.join(REPO_ROOT, 'public/data/carte-o.json')
|
||||
|
||||
// radius par niveau + nature
|
||||
// radius par niveau + nature (V1.2-N palette minimaliste)
|
||||
function getRadius(niveau, nature) {
|
||||
if (niveau === 0) return 28
|
||||
if (niveau === 1) return 18
|
||||
if (niveau === 2 && nature === 'projet') return 14
|
||||
return 10
|
||||
if (niveau === 0) return 30
|
||||
if (nature === 'projet') return 18
|
||||
if (niveau === 1) return 16
|
||||
return 12
|
||||
}
|
||||
|
||||
// compat backward : nature -> family
|
||||
@@ -24,30 +24,8 @@ function getFamily(nature) {
|
||||
return nature === 'projet' ? 'ressource' : 'concept'
|
||||
}
|
||||
|
||||
// thematiques rattachees directement au centre (ni ncs-politique ni medecine-corps-social)
|
||||
const CENTRE_THEMATIQUES = new Set([
|
||||
'medias-critique',
|
||||
'justice-securite',
|
||||
'agriculture',
|
||||
'urbanisme',
|
||||
'geopolitique',
|
||||
])
|
||||
|
||||
const NCS_THEMATIQUES = new Set([
|
||||
'systemique',
|
||||
'pratiques-collectives',
|
||||
'pouvoir-domination',
|
||||
'post-croissance',
|
||||
'education',
|
||||
])
|
||||
|
||||
const MDCS_THEMATIQUES = new Set([
|
||||
'art-narration',
|
||||
'sante-globale',
|
||||
'spiritualite',
|
||||
'ia-technologie',
|
||||
'anthropocene',
|
||||
])
|
||||
// V1.2-N : noeud central fusionne -> toutes les thematiques sont rattachees au centre
|
||||
// (les anciens groupes NCS_THEMATIQUES / MDCS_THEMATIQUES sont supprimes avec leurs sous-noeuds)
|
||||
|
||||
async function main() {
|
||||
const raw = await fs.readFile(SOURCE, 'utf-8')
|
||||
@@ -80,20 +58,16 @@ async function main() {
|
||||
const centreId = data.centre.id
|
||||
addNode(data.centre)
|
||||
|
||||
for (const cf of data.concepts_force) {
|
||||
// concepts_force vide en V1.2-N (fusionne dans le centre)
|
||||
for (const cf of (data.concepts_force || [])) {
|
||||
addNode(cf)
|
||||
addEdge(centreId, cf.id)
|
||||
}
|
||||
|
||||
// toutes les thematiques rattachees directement au noeud central
|
||||
for (const th of data.thematiques) {
|
||||
addNode(th)
|
||||
if (NCS_THEMATIQUES.has(th.id)) {
|
||||
addEdge('ncs-politique', th.id)
|
||||
} else if (MDCS_THEMATIQUES.has(th.id)) {
|
||||
addEdge('medecine-corps-social', th.id)
|
||||
} else if (CENTRE_THEMATIQUES.has(th.id)) {
|
||||
addEdge(centreId, th.id)
|
||||
}
|
||||
addEdge(centreId, th.id)
|
||||
}
|
||||
|
||||
for (const proj of data.projets) {
|
||||
|
||||
Reference in New Issue
Block a user