Ajoute les assets de partage Groupe KA servis à la racine (og.png, favicon.svg, apple-touch-icon)
- Trois routes FastAPI FileResponse : /og.png, /favicon.svg, /apple-touch-icon.png (fichiers dans src/api/web/) - index.html et contact.html : nouveau favicon SVG, apple-touch-icon, meta og:title/og:description/og:url/og:image 1200×630 + twitter:card/twitter:image Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
6 changed files +44 −2
modified
src/api/main.py
+17 −0
@@ -117,3 +117,20 @@ def contact(request: Request) -> Any: | ||
| 117 | 117 | "contacts": eco.get("contacts", []), |
| 118 | 118 | } |
| 119 | 119 | ) |
| 120 | + | |
| 121 | + | |
| 122 | +# Assets de marque Groupe KA servis à la racine du domaine (voir src/api/web/) : | |
| 123 | +# favicon SVG, icône iOS et image Open Graph 1200x630 referencée par les meta og:image. | |
| 124 | +@app.get("/favicon.svg", include_in_schema=False) | |
| 125 | +def favicon() -> FileResponse: | |
| 126 | + return FileResponse(WEB_DIR / "favicon.svg", media_type="image/svg+xml") | |
| 127 | + | |
| 128 | + | |
| 129 | +@app.get("/apple-touch-icon.png", include_in_schema=False) | |
| 130 | +def apple_touch_icon() -> FileResponse: | |
| 131 | + return FileResponse(WEB_DIR / "apple-touch-icon.png", media_type="image/png") | |
| 132 | + | |
| 133 | + | |
| 134 | +@app.get("/og.png", include_in_schema=False) | |
| 135 | +def og_image() -> FileResponse: | |
| 136 | + return FileResponse(WEB_DIR / "og.png", media_type="image/png") | |
added
src/api/web/apple-touch-icon.png
+0 −0
Binary file not shown.
modified
src/api/web/contact.html
+11 −1
@@ -17,7 +17,17 @@ Page /contact — courriels officiels Groupe KA (ecosystem.json) + compte KA ID. | ||
| 17 | 17 | <title>Contact — API-Ka — Un service Groupe KA</title> |
| 18 | 18 | <meta name="description" content="Joindre le Groupe KA : contact@groupe-ka.com (projets, partenariats et données), info@groupe-ka.com (médias) et admin@groupe-ka.com (légal, vie privée et Loi 25)."> |
| 19 | 19 | <meta name="theme-color" content="#f5f3ee"> |
| 20 | −<link rel="icon" href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Crect width='64' height='64' rx='12' fill='%23141814'/%3E%3Crect x='10' y='10' width='44' height='44' rx='8' fill='none' stroke='%233b5bdb' stroke-width='5'/%3E%3Ccircle cx='32' cy='32' r='7' fill='%233b5bdb'/%3E%3C/svg%3E"> | |
| 20 | +<link rel="icon" type="image/svg+xml" href="/favicon.svg"> | |
| 21 | +<link rel="apple-touch-icon" href="/apple-touch-icon.png"> | |
| 22 | +<meta property="og:title" content="Contact — API-Ka — Un service Groupe KA"> | |
| 23 | +<meta property="og:description" content="Joindre le Groupe KA : contact@groupe-ka.com (projets, partenariats et données), info@groupe-ka.com (médias) et admin@groupe-ka.com (légal, vie privée et Loi 25)."> | |
| 24 | +<meta property="og:url" content="https://www.api-ka.com/contact"> | |
| 25 | +<meta property="og:type" content="website"> | |
| 26 | +<meta property="og:image" content="https://www.api-ka.com/og.png"> | |
| 27 | +<meta property="og:image:width" content="1200"> | |
| 28 | +<meta property="og:image:height" content="630"> | |
| 29 | +<meta name="twitter:card" content="summary_large_image"> | |
| 30 | +<meta name="twitter:image" content="https://www.api-ka.com/og.png"> | |
| 21 | 31 | <link rel="preconnect" href="https://fonts.googleapis.com"> |
| 22 | 32 | <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> |
| 23 | 33 | <link href="https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap" rel="stylesheet"> |
added
src/api/web/favicon.svg
+5 −0
@@ -0,0 +1,5 @@ | ||
| 1 | +<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64"> | |
| 2 | +<rect width="64" height="64" rx="14" fill="#141814"/> | |
| 3 | +<rect x="4.5" y="4.5" width="55" height="55" rx="11" fill="none" stroke="#3b5bdb" stroke-opacity="0.35" stroke-width="2"/> | |
| 4 | +<text x="32" y="43" text-anchor="middle" font-family="'Space Grotesk','Arial Black',sans-serif" font-size="30" font-weight="700" letter-spacing="-1" fill="#3b5bdb" transform="rotate(-4 32 32)">Ka</text> | |
| 5 | +</svg> | |
| \ No newline at end of file | ||
modified
src/api/web/index.html
+11 −1
@@ -18,7 +18,17 @@ premier, accent indigo propre à API-Ka surchargé en :root ci-dessous. | ||
| 18 | 18 | <title>API-Ka — Un service Groupe KA</title> |
| 19 | 19 | <meta name="description" content="API publique centralisant chaque jour les données des services de l'écosystème Groupe KA — logements, propriétés, épicerie, véhicules, produits québécois, restaurants, sorties et créateurs. Documentation complète et playground interactif."> |
| 20 | 20 | <meta name="theme-color" content="#f5f3ee"> |
| 21 | −<link rel="icon" href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Crect width='64' height='64' rx='12' fill='%23141814'/%3E%3Crect x='10' y='10' width='44' height='44' rx='8' fill='none' stroke='%233b5bdb' stroke-width='5'/%3E%3Ccircle cx='32' cy='32' r='7' fill='%233b5bdb'/%3E%3C/svg%3E"> | |
| 21 | +<link rel="icon" type="image/svg+xml" href="/favicon.svg"> | |
| 22 | +<link rel="apple-touch-icon" href="/apple-touch-icon.png"> | |
| 23 | +<meta property="og:title" content="API-Ka — Un service Groupe KA"> | |
| 24 | +<meta property="og:description" content="API publique centralisant chaque jour les données des services de l'écosystème Groupe KA — logements, propriétés, épicerie, véhicules, produits québécois, restaurants, sorties et créateurs. Documentation complète et playground interactif."> | |
| 25 | +<meta property="og:url" content="https://www.api-ka.com/"> | |
| 26 | +<meta property="og:type" content="website"> | |
| 27 | +<meta property="og:image" content="https://www.api-ka.com/og.png"> | |
| 28 | +<meta property="og:image:width" content="1200"> | |
| 29 | +<meta property="og:image:height" content="630"> | |
| 30 | +<meta name="twitter:card" content="summary_large_image"> | |
| 31 | +<meta name="twitter:image" content="https://www.api-ka.com/og.png"> | |
| 22 | 32 | <link rel="preconnect" href="https://fonts.googleapis.com"> |
| 23 | 33 | <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> |
| 24 | 34 | <link href="https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap" rel="stylesheet"> |
added
src/api/web/og.png
+0 −0
Binary file not shown.