Repository Public
1// Icônes architecturales d'Immo-Ka : même géométrie que le symbole (toit à2// avant-toits retroussés, murs droits, porte, seuil), grille 24, trait 1,6.3// Les icônes universelles (recherche, fermer, retour, réglages, cœur, partage)4// restent celles de Lucide : la reconnaissance fonctionnelle passe avant la marque.56import type { SVGProps } from "react";78type P = SVGProps<SVGSVGElement> & { size?: number };910function Base({ size = 20, children, ...rest }: P & { children: React.ReactNode }) {11 return (12 <svg13 viewBox="0 0 24 24"14 width={size}15 height={size}16 fill="none"17 stroke="currentColor"18 strokeWidth={1.6}19 strokeLinecap="round"20 strokeLinejoin="round"21 aria-hidden22 {...rest}23 >24 {children}25 </svg>26 );27}2829/** Le toit du symbole : pignon et avant-toits retroussés (le larmier). */30const ROOF = "M2.8 11.2c1.6-.2 2.6-.8 3.7-1.8L12 4l5.5 5.400c1.1 1 2.1 1.6 3.7 1.8";31const WALLS = "M5.5 11.200V21M18.5 11.200V21";32const GROUND = "M2.5 21h19";3334/** Maison (porte fermée) */35export const IconHouse = (p: P) => (36 <Base {...p}>37 <path d={ROOF} />38 <path d={WALLS} />39 <path d="M10 21v-6.500h4V21" />40 <path d={GROUND} />41 </Base>42);4344/** Maison dont la porte est ouverte : entrer, explorer */45export const IconHouseOpen = (p: P) => (46 <Base {...p}>47 <path d={ROOF} />48 <path d={WALLS} />49 <path d="M10 21v-6.500h4V21" />50 <path d="M10 14.500l2.6 1v4.500L10 21" />51 <path d={GROUND} />52 </Base>53);5455/** Porte fermée */56export const IconDoorClosed = (p: P) => (57 <Base {...p}>58 <path d="M6 21V4.500A1.5 1.5 0 0 1 7.5 3h9A1.5 1.5 0 0 1 18 4.500V21" />59 <path d="M3.5 21h17" />60 <path d="M14.5 12v1.2" />61 </Base>62);6364/** Porte ouverte (entrouverte vers l'intérieur) */65export const IconDoorOpen = (p: P) => (66 <Base {...p}>67 <path d="M6 21V4.500A1.5 1.5 0 0 1 7.5 3h9A1.5 1.5 0 0 1 18 4.500V21" />68 <path d="M7.6 4.6 14 6.200v12.400L7.6 20.6" />69 <path d="M3.5 21h17" />70 <path d="M11.6 12v1.2" />71 </Base>72);7374/** Entrée : une flèche franchit l'encadrement */75export const IconEntrance = (p: P) => (76 <Base {...p}>77 <path d="M9 21V4.500A1.5 1.5 0 0 1 10.5 3h7A1.5 1.5 0 0 1 19 4.500V21" />78 <path d="M3 12h9" />79 <path d="m9.5 9 3 3-3 3" />80 <path d="M6.5 21h15" />81 </Base>82);8384/** Seuil */85export const IconThreshold = (p: P) => (86 <Base {...p}>87 <path d="M7 17V5.500A1.5 1.5 0 0 1 8.5 4h7A1.5 1.5 0 0 1 17 5.500V17" />88 <path d="M3 17h18" />89 <path d="M5 20.500h14" />90 </Base>91);9293/** Condo : immeuble à balcons */94export const IconCondo = (p: P) => (95 <Base {...p}>96 <path d="M6 21V4.500A1.5 1.5 0 0 1 7.5 3h9A1.5 1.5 0 0 1 18 4.500V21" />97 <path d="M9 7.500h6M9 11h6M9 14.500h6" />98 <path d="M10.5 21v-3h3v3" />99 <path d={GROUND} />100 </Base>101);102103/** Appartement (nom hérité) : même dessin que le condo */104export const IconApartment = IconCondo;105106/** Plex : deux étages, deux portes, corniche */107export const IconPlex = (p: P) => (108 <Base {...p}>109 <path d="M3 5.500h18" />110 <path d="M4.5 5.500V21M19.5 5.500V21" />111 <path d="M4.5 12.500h15" />112 <path d="M7.5 21v-5h3v5M13.5 21v-5h3v5" />113 <path d="M8 9h2M14 9h2" />114 <path d={GROUND} />115 </Base>116);117118/** Immeuble */119export const IconBuilding = (p: P) => (120 <Base {...p}>121 <path d="M5 21V4.500A1.5 1.5 0 0 1 6.5 3h7A1.5 1.5 0 0 1 15 4.500V21" />122 <path d="M15 10h3.500A1.5 1.5 0 0 1 20 11.500V21" />123 <path d="M8.5 7h3M8.5 10.500h3M8.5 14h3" />124 <path d="M9 21v-3.500h2V21" />125 <path d={GROUND} />126 </Base>127);128129/** Commerce : vitrine et auvent */130export const IconCommercial = (p: P) => (131 <Base {...p}>132 <path d="M4.5 5h15l1.5 5h-18Z" />133 <path d="M5 10v11M19 10v11" />134 <path d="M8 21v-6.500h3.500V21" />135 <path d="M14 14.500h2.500v3H14Z" />136 <path d={GROUND} />137 </Base>138);139140/** Terrain : une parcelle et son piquet */141export const IconLand = (p: P) => (142 <Base {...p}>143 <path d="M3 19.5 7 12h10l4 7.500Z" />144 <path d="M12 16V5" />145 <path d="M12 5.500h4.500l-1.2 1.5 1.2 1.500H12" />146 </Base>147);148149/** Chalet : toit qui descend jusqu'au sol */150export const IconCottage = (p: P) => (151 <Base {...p}>152 <path d="M4 21 12 4l8 17" />153 <path d="M10.2 21v-5h3.600v5" />154 <path d="M10.6 11.500h2.8" />155 <path d={GROUND} />156 </Base>157);158159/** Clé */160export const IconKey = (p: P) => (161 <Base {...p}>162 <circle cx="7.5" cy="12" r="4" />163 <path d="M11.5 12H21M18 12v3.500M15 12v2.5" />164 </Base>165);166167/** Visite libre : l'enseigne plantée devant la maison */168export const IconOpenHouse = (p: P) => (169 <Base {...p}>170 <path d="M6 21V4" />171 <path d="M6 6.500h11.5" />172 <path d="M9 6.500V8M15 6.500V8" />173 <path d="M8 8h8v7.500H8Z" />174 <path d="M11 15.500V12h2v3.5" />175 <path d="M3 21h7" />176 </Base>177);178179/** Visite : porte et regard */180export const IconVisit = (p: P) => (181 <Base {...p}>182 <path d="M5 21V4.500A1.5 1.5 0 0 1 6.5 3h8A1.5 1.5 0 0 1 16 4.500V10.5" />183 <path d="M2.5 21h8" />184 <path d="M12.5 17.500c1.2-2 2.8-3 4.5-3s3.3 1 4.5 3c-1.2 2-2.8 3-4.5 3s-3.3-1-4.5-3Z" />185 <circle cx="17" cy="17.5" r="1" />186 </Base>187);188189/** Inspection : la maison passée à la loupe */190export const IconInspection = (p: P) => (191 <Base {...p}>192 <path d={ROOF} />193 <path d="M5.5 11.200V21M18.5 11.200v.800" />194 <path d="M2.5 21h8.5" />195 <circle cx="16" cy="16.5" r="3.2" />196 <path d="m18.4 18.9 2.6 2.6" />197 </Base>198);199200/** Hypothèque : la maison et son taux */201export const IconMortgage = (p: P) => (202 <Base {...p}>203 <path d={ROOF} />204 <path d={WALLS} />205 <path d={GROUND} />206 <path d="m9.7 18.3 4.6-5" />207 <circle cx="9.7" cy="13.7" r="0.9" />208 <circle cx="14.3" cy="17.9" r="0.9" />209 </Base>210);211212/** Courtier : une personne et une maison */213export const IconBroker = (p: P) => (214 <Base {...p}>215 <circle cx="8" cy="7.5" r="3" />216 <path d="M2.5 20.500v-1.500A4.5 4.5 0 0 1 7 14.500h2a4.5 4.5 0 0 1 3 1.15" />217 <path d="m13.5 15.3 3.75-3.3 3.75 3.3" />218 <path d="M14.8 14.500v6h4.900v-6" />219 </Base>220);221222/** Agence, gestion immobilière : immeuble et clé */223export const IconManagement = (p: P) => (224 <Base {...p}>225 <path d="M4 21V4.500A1.5 1.5 0 0 1 5.5 3h7A1.5 1.5 0 0 1 14 4.500V10" />226 <path d="M7.5 7h3M7.5 10.500h3" />227 <path d="M2.5 21h8" />228 <circle cx="15" cy="17" r="2.5" />229 <path d="M17.5 17H22M20 17v2" />230 </Base>231);232export const IconAgency = IconManagement;233234/** Vendu : la maison et sa coche */235export const IconSold = (p: P) => (236 <Base {...p}>237 <path d={ROOF} />238 <path d="M5.5 11.200V21M18.5 11.200v1.3" />239 <path d="M2.5 21h9" />240 <path d="m13.8 17.7 2.3 2.3 4.4-4.8" />241 </Base>242);243244/** Propriété disponible (nom hérité) : même dessin que « vendu » inversé — porte et coche */245export const IconAvailable = (p: P) => (246 <Base {...p}>247 <path d="M5 21V4.500A1.5 1.5 0 0 1 6.5 3h8A1.5 1.5 0 0 1 16 4.500V11" />248 <path d="M2.5 21h10" />249 <path d="m14.5 17.5 2.2 2.2 4.3-4.6" />250 </Base>251);252253/** Nouvelle inscription : la maison et un plus */254export const IconNewListing = (p: P) => (255 <Base {...p}>256 <path d={ROOF} />257 <path d="M5.5 11.200V21M18.5 11.200v1" />258 <path d="M2.5 21h10" />259 <path d="M18 14.500v5.500M15.25 17.250h5.5" />260 </Base>261);262263/** Baisse de prix : l'étiquette et sa flèche */264export const IconPriceDrop = (p: P) => (265 <Base {...p}>266 <path d="M3.5 11.800V5a1.5 1.5 0 0 1 1.5-1.500h6.800a1.5 1.5 0 0 1 1.06.440l7.2 7.200a1.5 1.5 0 0 1 0 2.120l-6.8 6.800a1.5 1.5 0 0 1-2.12 0l-7.2-7.200a1.5 1.5 0 0 1-.440-1.060Z" />267 <path d="M12.5 9.500v6" />268 <path d="m10 13.2 2.5 2.5 2.5-2.5" />269 <circle cx="7.3" cy="7.3" r="0.8" />270 </Base>271);272273/** Propriété sauvegardée : porte et signet */274export const IconSaved = (p: P) => (275 <Base {...p}>276 <path d="M5 21V4.500A1.5 1.5 0 0 1 6.5 3h8A1.5 1.5 0 0 1 16 4.500V10" />277 <path d="M2.5 21h9.5" />278 <path d="M15.5 14h5v7l-2.5-1.800L15.5 21Z" />279 </Base>280);281282/** Quartier : trois façades */283export const IconNeighborhood = (p: P) => (284 <Base {...p}>285 <path d="M3 21V11l3.5-3L10 11v10" />286 <path d="M10 21V6.500A1.5 1.5 0 0 1 11.5 5h3A1.5 1.5 0 0 1 16 6.500V21" />287 <path d="M16 21v-8h3.500A1.5 1.5 0 0 1 21 14.500V21" />288 <path d="M1.5 21h21" />289 <path d="M6 21v-3h1V21M12.5 9h1M12.5 12.500h1" />290 </Base>291);292293/** Déménageur : le camion */294export const IconMover = (p: P) => (295 <Base {...p}>296 <path d="M2.5 6.500h11v10h-11Z" />297 <path d="M13.5 10h4l3.5 3.500v3h-7.5" />298 <circle cx="6.5" cy="17.5" r="1.8" />299 <circle cx="17" cy="17.5" r="1.8" />300 </Base>301);302303export const BRAND_ICONS = {304 Maison: IconHouse,305 "Maison ouverte": IconHouseOpen,306 Condo: IconCondo,307 Plex: IconPlex,308 Immeuble: IconBuilding,309 Commerce: IconCommercial,310 Terrain: IconLand,311 Chalet: IconCottage,312 "Porte fermée": IconDoorClosed,313 "Porte ouverte": IconDoorOpen,314 Entrée: IconEntrance,315 Seuil: IconThreshold,316 Clé: IconKey,317 "Visite libre": IconOpenHouse,318 Visite: IconVisit,319 Inspection: IconInspection,320 Hypothèque: IconMortgage,321 Courtier: IconBroker,322 Agence: IconManagement,323 Vendu: IconSold,324 "Nouvelle inscription": IconNewListing,325 "Baisse de prix": IconPriceDrop,326 "Propriété sauvegardée": IconSaved,327 Quartier: IconNeighborhood,328 Déménageur: IconMover,329} as const;330331/** Icône du type de propriété (libellé de l'API : Maison, Condo, Duplex, Terrain, Chalet…). */332export function iconForType(type: string | null | undefined) {333 const t = (type || "").toLowerCase();334 if (/condo|appart|loft/.test(t)) return IconCondo;335 if (/plex|revenu|multi/.test(t)) return IconPlex;336 if (/terrain|terre|lot/.test(t)) return IconLand;337 if (/chalet/.test(t)) return IconCottage;338 if (/commerc|bureau|industr/.test(t)) return IconCommercial;339 if (/immeuble/.test(t)) return IconBuilding;340 return IconHouse;341}342