/** * Types V1 — Carte 3 AEP "Trouver du taf en archi" * Source : public/data/plateformes-taff.json * Spec figée : 0 INBOX/PROMPTS/cascade-megaboum/MP-TAFF-app-trouver-du-taf.md */ export type AxeScore = "✅" | "⚠️" | "❌"; export type TagGlobal = "recommande" | "sous-reserve" | "a-eviter"; export type Secteur = | "renovation" | "construction-neuve" | "urbanisme" | "architecture-interieure" | "paysage" | "mar-conseil" | "transversal"; export type TypePlateforme = | "b2c-mise-en-relation" // V1 cible (Travaux.com, Habitatpresto, etc.) | "appel-offre-public" // V1 onglet bonus light | "communaute-pro"; // backlog V2 (Welow, etc.) export type CoutEntree = "gratuit" | "freemium" | "abonnement" | "lead-paye" | "commission"; export type ZoneGeo = "france-entiere" | "regional" | string; export interface ScoringTaff { // Pour b2c-mise-en-relation : tous les 5 axes sont remplis. // Pour appel-offre-public : seuls transparence + matching sont remplis, // les 3 autres sont null (scoring simplifié décision F du MP). remuneration: AxeScore | null; transparence: AxeScore; pratiques: AxeScore | null; ecologie: AxeScore | null; matching: AxeScore; tag_global: TagGlobal; justification_tag: string; // 1-2 phrases pourquoi ce tag } export interface Commentaire { id: string; date: string; auteur_pseudo: string; contenu: string; modere: boolean; } export interface PlateformeTaff { id: string; // slug-kebab nom: string; url: string; type: TypePlateforme; description: string; // IA 250 mots (5 sections fixes ≤50 mots) description_courte: string; // IA 30 mots (carte preview) scoring: ScoringTaff; secteurs_servis: Secteur[]; zone_geo: ZoneGeo; // si "regional", précise zones cout_entree: CoutEntree; date_creation_fiche: string; // ISO date_derniere_maj: string; // ISO — pour pipeline trimestriel source_donnees: string[]; // URLs scrapées flag_validation_jules: boolean; // true si tag ❌ validé manuellement commentaires?: Commentaire[]; } export interface PlateformesTaffData { meta: { version: string; date_generation: string; // ISO total: number; repartition: { recommande: number; sous_reserve: number; a_eviter: number; }; repartition_type: { b2c: number; appel_offre_public: number; }; }; plateformes: PlateformeTaff[]; } // ── Helpers ──────────────────────────────────────────────────────────────────── export const FAMILLES_SECTEUR: { id: Secteur; label: string; color: string }[] = [ { id: "renovation", label: "Rénovation", color: "#5a7a4a" }, { id: "construction-neuve", label: "Construction neuve", color: "#3d6a8c" }, { id: "urbanisme", label: "Urbanisme", color: "#6b3fa0" }, { id: "architecture-interieure", label: "Archi intérieure", color: "#a85d3e" }, { id: "paysage", label: "Paysage", color: "#5a7a4a" }, { id: "mar-conseil", label: "MAR / Conseil", color: "#c4a472" }, { id: "transversal", label: "Transversal", color: "#888888" }, ]; export const TAG_LABELS: Record = { "recommande": { label: "Recommandé AEP", emoji: "✅", color: "#5a7a4a" }, "sous-reserve": { label: "Sous réserve", emoji: "⚠️", color: "#c4a472" }, "a-eviter": { label: "À éviter", emoji: "❌", color: "#a85d3e" }, };