import { jsxs as r, jsx as e } from "react/jsx-runtime";
import { Link as s } from "react-router-dom";
import { Globe as m, CheckCircle2 as a, Monitor as p, Code2 as h, Shield as x, AlertTriangle as v, Users as g, Smartphone as b, ExternalLink as o, ArrowRight as c } from "lucide-react";
import { useTranslation as N } from "react-i18next";
function f({ className: t }) {
  return /* @__PURE__ */ e("svg", { className: t, viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ e("path", { d: "M19.2 6.4h-2.4v1.6h2.4c.44 0 .8.36.8.8v6.4c0 .44-.36.8-.8.8h-4.8v1.6h4.8c1.32 0 2.4-1.08 2.4-2.4V8.8c0-1.32-1.08-2.4-2.4-2.4zM16 5.6c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-4 1.6H4.8C3.48 7.2 2.4 8.28 2.4 9.6v6.4c0 1.32 1.08 2.4 2.4 2.4h7.2c1.32 0 2.4-1.08 2.4-2.4V9.6c0-1.32-1.08-2.4-2.4-2.4zm.8 8.8c0 .44-.36.8-.8.8H4.8c-.44 0-.8-.36-.8-.8V9.6c0-.44.36-.8.8-.8H12c.44 0 .8.36.8.8v6.4zM8 4.8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2z" }) });
}
function i({ code: t, language: n = "csharp" }) {
  return /* @__PURE__ */ e("pre", { className: "bg-[var(--bg-tertiary)] rounded-lg p-4 overflow-x-auto", children: /* @__PURE__ */ e("code", { className: `language-${n} text-sm`, children: t }) });
}
function l({ number: t, title: n, children: d }) {
  return /* @__PURE__ */ r("div", { className: "flex gap-4", children: [
    /* @__PURE__ */ e("div", { className: "flex-shrink-0 w-8 h-8 rounded-full bg-[var(--color-primary-600)] text-white flex items-center justify-center font-bold text-sm", children: t }),
    /* @__PURE__ */ r("div", { className: "flex-1", children: [
      /* @__PURE__ */ e("h3", { className: "font-semibold mb-2", children: n }),
      /* @__PURE__ */ e("div", { className: "text-[var(--text-secondary)]", children: d })
    ] })
  ] });
}
function k() {
  const { t } = N("docs");
  return /* @__PURE__ */ r("div", { className: "space-y-8", children: [
    /* @__PURE__ */ r("div", { className: "flex items-center gap-2 text-sm text-[var(--text-secondary)]", children: [
      /* @__PURE__ */ e(s, { to: "/system/docs", className: "hover:text-[var(--color-primary-600)]", children: t("breadcrumb.documentation") }),
      /* @__PURE__ */ e("span", { children: "/" }),
      /* @__PURE__ */ e(s, { to: "/system/docs/developer", className: "hover:text-[var(--color-primary-600)]", children: t("breadcrumb.developer") }),
      /* @__PURE__ */ e("span", { children: "/" }),
      /* @__PURE__ */ e("span", { children: t("developer.teamsIntegration.title") })
    ] }),
    /* @__PURE__ */ r("div", { children: [
      /* @__PURE__ */ r("h1", { className: "text-3xl font-bold mb-4 flex items-center gap-3", children: [
        /* @__PURE__ */ e(f, { className: "w-8 h-8 text-[#6264A7]" }),
        t("developer.teamsIntegration.title")
      ] }),
      /* @__PURE__ */ e("p", { className: "text-lg text-[var(--text-secondary)]", children: t("developer.teamsIntegration.description") })
    ] }),
    /* @__PURE__ */ r("section", { className: "card p-6 bg-gradient-to-r from-[#6264A7]/10 to-transparent border-[#6264A7]/30", children: [
      /* @__PURE__ */ r("h2", { className: "text-xl font-bold mb-4 flex items-center gap-2", children: [
        /* @__PURE__ */ e(m, { className: "w-5 h-5 text-[#6264A7]" }),
        t("developer.teamsIntegration.overview.title")
      ] }),
      /* @__PURE__ */ e("p", { className: "text-[var(--text-secondary)] mb-4", children: t("developer.teamsIntegration.overview.description") }),
      /* @__PURE__ */ r("div", { className: "grid md:grid-cols-3 gap-4 mt-6", children: [
        /* @__PURE__ */ r("div", { className: "flex items-start gap-3", children: [
          /* @__PURE__ */ e(a, { className: "w-5 h-5 text-green-500 mt-0.5" }),
          /* @__PURE__ */ r("div", { children: [
            /* @__PURE__ */ e("p", { className: "font-semibold", children: t("developer.teamsIntegration.overview.benefit1") }),
            /* @__PURE__ */ e("p", { className: "text-sm text-[var(--text-secondary)]", children: t("developer.teamsIntegration.overview.benefit1Desc") })
          ] })
        ] }),
        /* @__PURE__ */ r("div", { className: "flex items-start gap-3", children: [
          /* @__PURE__ */ e(a, { className: "w-5 h-5 text-green-500 mt-0.5" }),
          /* @__PURE__ */ r("div", { children: [
            /* @__PURE__ */ e("p", { className: "font-semibold", children: t("developer.teamsIntegration.overview.benefit2") }),
            /* @__PURE__ */ e("p", { className: "text-sm text-[var(--text-secondary)]", children: t("developer.teamsIntegration.overview.benefit2Desc") })
          ] })
        ] }),
        /* @__PURE__ */ r("div", { className: "flex items-start gap-3", children: [
          /* @__PURE__ */ e(a, { className: "w-5 h-5 text-green-500 mt-0.5" }),
          /* @__PURE__ */ r("div", { children: [
            /* @__PURE__ */ e("p", { className: "font-semibold", children: t("developer.teamsIntegration.overview.benefit3") }),
            /* @__PURE__ */ e("p", { className: "text-sm text-[var(--text-secondary)]", children: t("developer.teamsIntegration.overview.benefit3Desc") })
          ] })
        ] })
      ] })
    ] }),
    /* @__PURE__ */ r("section", { className: "card p-6", children: [
      /* @__PURE__ */ r("h2", { className: "text-xl font-bold mb-6 flex items-center gap-2", children: [
        /* @__PURE__ */ e(p, { className: "w-5 h-5" }),
        t("developer.teamsIntegration.howItWorks.title")
      ] }),
      /* @__PURE__ */ r("div", { className: "space-y-6", children: [
        /* @__PURE__ */ r(l, { number: 1, title: t("developer.teamsIntegration.howItWorks.step1Title"), children: [
          /* @__PURE__ */ e("p", { children: t("developer.teamsIntegration.howItWorks.step1Desc") }),
          /* @__PURE__ */ e("div", { className: "mt-3 p-4 bg-[var(--bg-secondary)] rounded-lg", children: /* @__PURE__ */ r("p", { className: "font-mono text-sm", children: [
            'Teams → "+" → ',
            t("developer.teamsIntegration.howItWorks.step1Path")
          ] }) })
        ] }),
        /* @__PURE__ */ r(l, { number: 2, title: t("developer.teamsIntegration.howItWorks.step2Title"), children: [
          /* @__PURE__ */ e("p", { children: t("developer.teamsIntegration.howItWorks.step2Desc") }),
          /* @__PURE__ */ e("div", { className: "mt-3 p-4 bg-[var(--bg-secondary)] rounded-lg font-mono text-sm", children: "https://votre-domaine.com" })
        ] }),
        /* @__PURE__ */ e(l, { number: 3, title: t("developer.teamsIntegration.howItWorks.step3Title"), children: /* @__PURE__ */ e("p", { children: t("developer.teamsIntegration.howItWorks.step3Desc") }) })
      ] })
    ] }),
    /* @__PURE__ */ r("section", { className: "card p-6", children: [
      /* @__PURE__ */ r("h2", { className: "text-xl font-bold mb-4 flex items-center gap-2", children: [
        /* @__PURE__ */ e(h, { className: "w-5 h-5" }),
        t("developer.teamsIntegration.backendConfig.title")
      ] }),
      /* @__PURE__ */ e("p", { className: "text-[var(--text-secondary)] mb-4", children: t("developer.teamsIntegration.backendConfig.description") }),
      /* @__PURE__ */ e("h3", { className: "font-semibold mt-6 mb-2", children: t("developer.teamsIntegration.backendConfig.cspTitle") }),
      /* @__PURE__ */ e("p", { className: "text-[var(--text-secondary)] mb-3", children: t("developer.teamsIntegration.backendConfig.cspDesc") }),
      /* @__PURE__ */ e(i, { code: `// Program.cs ou middleware personnalise
app.Use(async (context, next) =>
{
    // Autoriser Teams a embarquer l'application dans un iframe
    context.Response.Headers["Content-Security-Policy"] =
        "frame-ancestors 'self' teams.microsoft.com *.teams.microsoft.com *.skype.com";

    // Supprimer X-Frame-Options si present (conflit avec CSP)
    context.Response.Headers.Remove("X-Frame-Options");

    await next();
});` }),
      /* @__PURE__ */ e("h3", { className: "font-semibold mt-6 mb-2", children: t("developer.teamsIntegration.backendConfig.corsTitle") }),
      /* @__PURE__ */ e("p", { className: "text-[var(--text-secondary)] mb-3", children: t("developer.teamsIntegration.backendConfig.corsDesc") }),
      /* @__PURE__ */ e(i, { code: `// appsettings.json
{
  "Cors": {
    "AllowedOrigins": [
      "https://votre-domaine.com",
      "https://teams.microsoft.com",
      "https://*.teams.microsoft.com"
    ]
  }
}`, language: "json" })
    ] }),
    /* @__PURE__ */ r("section", { className: "card p-6", children: [
      /* @__PURE__ */ r("h2", { className: "text-xl font-bold mb-4 flex items-center gap-2", children: [
        /* @__PURE__ */ e(x, { className: "w-5 h-5" }),
        t("developer.teamsIntegration.security.title")
      ] }),
      /* @__PURE__ */ r("div", { className: "space-y-4", children: [
        /* @__PURE__ */ r("div", { className: "flex items-start gap-3 p-4 bg-green-500/10 rounded-lg border border-green-500/30", children: [
          /* @__PURE__ */ e(a, { className: "w-5 h-5 text-green-500 mt-0.5" }),
          /* @__PURE__ */ r("div", { children: [
            /* @__PURE__ */ e("p", { className: "font-semibold text-green-700 dark:text-green-400", children: t("developer.teamsIntegration.security.ssoTitle") }),
            /* @__PURE__ */ e("p", { className: "text-sm text-[var(--text-secondary)]", children: t("developer.teamsIntegration.security.ssoDesc") })
          ] })
        ] }),
        /* @__PURE__ */ r("div", { className: "flex items-start gap-3 p-4 bg-green-500/10 rounded-lg border border-green-500/30", children: [
          /* @__PURE__ */ e(a, { className: "w-5 h-5 text-green-500 mt-0.5" }),
          /* @__PURE__ */ r("div", { children: [
            /* @__PURE__ */ e("p", { className: "font-semibold text-green-700 dark:text-green-400", children: t("developer.teamsIntegration.security.entraTitle") }),
            /* @__PURE__ */ e("p", { className: "text-sm text-[var(--text-secondary)]", children: t("developer.teamsIntegration.security.entraDesc") })
          ] })
        ] }),
        /* @__PURE__ */ r("div", { className: "flex items-start gap-3 p-4 bg-blue-500/10 rounded-lg border border-blue-500/30", children: [
          /* @__PURE__ */ e(v, { className: "w-5 h-5 text-blue-500 mt-0.5" }),
          /* @__PURE__ */ r("div", { children: [
            /* @__PURE__ */ e("p", { className: "font-semibold text-blue-700 dark:text-blue-400", children: t("developer.teamsIntegration.security.httpsTitle") }),
            /* @__PURE__ */ e("p", { className: "text-sm text-[var(--text-secondary)]", children: t("developer.teamsIntegration.security.httpsDesc") })
          ] })
        ] })
      ] })
    ] }),
    /* @__PURE__ */ r("section", { className: "card p-6", children: [
      /* @__PURE__ */ r("h2", { className: "text-xl font-bold mb-4 flex items-center gap-2", children: [
        /* @__PURE__ */ e(g, { className: "w-5 h-5" }),
        t("developer.teamsIntegration.comparison.title")
      ] }),
      /* @__PURE__ */ e("div", { className: "overflow-x-auto", children: /* @__PURE__ */ r("table", { className: "w-full text-sm", children: [
        /* @__PURE__ */ e("thead", { children: /* @__PURE__ */ r("tr", { className: "border-b border-[var(--border-color)]", children: [
          /* @__PURE__ */ e("th", { className: "text-left py-3 px-4", children: t("developer.teamsIntegration.comparison.feature") }),
          /* @__PURE__ */ e("th", { className: "text-center py-3 px-4", children: t("developer.teamsIntegration.comparison.websiteTab") }),
          /* @__PURE__ */ e("th", { className: "text-center py-3 px-4", children: t("developer.teamsIntegration.comparison.teamsApp") })
        ] }) }),
        /* @__PURE__ */ r("tbody", { children: [
          /* @__PURE__ */ r("tr", { className: "border-b border-[var(--border-color)]", children: [
            /* @__PURE__ */ e("td", { className: "py-3 px-4", children: t("developer.teamsIntegration.comparison.development") }),
            /* @__PURE__ */ r("td", { className: "text-center py-3 px-4 text-green-500", children: [
              "✓ ",
              t("developer.teamsIntegration.comparison.none")
            ] }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-amber-500", children: t("developer.teamsIntegration.comparison.required") })
          ] }),
          /* @__PURE__ */ r("tr", { className: "border-b border-[var(--border-color)]", children: [
            /* @__PURE__ */ e("td", { className: "py-3 px-4", children: t("developer.teamsIntegration.comparison.manifest") }),
            /* @__PURE__ */ r("td", { className: "text-center py-3 px-4 text-green-500", children: [
              "✓ ",
              t("developer.teamsIntegration.comparison.none")
            ] }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-amber-500", children: t("developer.teamsIntegration.comparison.required") })
          ] }),
          /* @__PURE__ */ r("tr", { className: "border-b border-[var(--border-color)]", children: [
            /* @__PURE__ */ e("td", { className: "py-3 px-4", children: t("developer.teamsIntegration.comparison.deployment") }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-green-500", children: t("developer.teamsIntegration.comparison.manual") }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4", children: t("developer.teamsIntegration.comparison.adminCenter") })
          ] }),
          /* @__PURE__ */ r("tr", { className: "border-b border-[var(--border-color)]", children: [
            /* @__PURE__ */ e("td", { className: "py-3 px-4", children: t("developer.teamsIntegration.comparison.sso") }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-green-500", children: "✓ Entra ID" }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-green-500", children: "✓ Entra ID" })
          ] }),
          /* @__PURE__ */ r("tr", { className: "border-b border-[var(--border-color)]", children: [
            /* @__PURE__ */ e("td", { className: "py-3 px-4", children: t("developer.teamsIntegration.comparison.notifications") }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-red-500", children: "✗" }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-green-500", children: "✓" })
          ] }),
          /* @__PURE__ */ r("tr", { children: [
            /* @__PURE__ */ e("td", { className: "py-3 px-4", children: t("developer.teamsIntegration.comparison.sidebarIcon") }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-red-500", children: "✗" }),
            /* @__PURE__ */ e("td", { className: "text-center py-3 px-4 text-green-500", children: "✓" })
          ] })
        ] })
      ] }) })
    ] }),
    /* @__PURE__ */ r("section", { className: "card p-6", children: [
      /* @__PURE__ */ r("h2", { className: "text-xl font-bold mb-4 flex items-center gap-2", children: [
        /* @__PURE__ */ e(b, { className: "w-5 h-5" }),
        t("developer.teamsIntegration.responsive.title")
      ] }),
      /* @__PURE__ */ e("p", { className: "text-[var(--text-secondary)] mb-4", children: t("developer.teamsIntegration.responsive.description") }),
      /* @__PURE__ */ r("ul", { className: "space-y-2", children: [
        /* @__PURE__ */ r("li", { className: "flex items-start gap-2", children: [
          /* @__PURE__ */ e(a, { className: "w-4 h-4 text-green-500 mt-1" }),
          /* @__PURE__ */ e("span", { className: "text-[var(--text-secondary)]", children: t("developer.teamsIntegration.responsive.tip1") })
        ] }),
        /* @__PURE__ */ r("li", { className: "flex items-start gap-2", children: [
          /* @__PURE__ */ e(a, { className: "w-4 h-4 text-green-500 mt-1" }),
          /* @__PURE__ */ e("span", { className: "text-[var(--text-secondary)]", children: t("developer.teamsIntegration.responsive.tip2") })
        ] }),
        /* @__PURE__ */ r("li", { className: "flex items-start gap-2", children: [
          /* @__PURE__ */ e(a, { className: "w-4 h-4 text-green-500 mt-1" }),
          /* @__PURE__ */ e("span", { className: "text-[var(--text-secondary)]", children: t("developer.teamsIntegration.responsive.tip3") })
        ] })
      ] })
    ] }),
    /* @__PURE__ */ r("section", { className: "card p-6 bg-[var(--bg-secondary)]", children: [
      /* @__PURE__ */ e("h2", { className: "text-xl font-bold mb-4", children: t("developer.teamsIntegration.resources.title") }),
      /* @__PURE__ */ r("div", { className: "space-y-3", children: [
        /* @__PURE__ */ r(
          "a",
          {
            href: "https://learn.microsoft.com/en-us/microsoftteams/platform/samples/integrate-web-apps-overview",
            target: "_blank",
            rel: "noopener noreferrer",
            className: "flex items-center gap-2 text-[var(--color-primary-600)] hover:underline",
            children: [
              /* @__PURE__ */ e(o, { className: "w-4 h-4" }),
              t("developer.teamsIntegration.resources.link1")
            ]
          }
        ),
        /* @__PURE__ */ r(
          "a",
          {
            href: "https://learn.microsoft.com/en-us/microsoftteams/platform/samples/integrating-web-apps",
            target: "_blank",
            rel: "noopener noreferrer",
            className: "flex items-center gap-2 text-[var(--color-primary-600)] hover:underline",
            children: [
              /* @__PURE__ */ e(o, { className: "w-4 h-4" }),
              t("developer.teamsIntegration.resources.link2")
            ]
          }
        ),
        /* @__PURE__ */ r(
          "a",
          {
            href: "https://learn.microsoft.com/en-us/shows/microsoft-learn-learn-together-developing-apps-for-teams/embedding-your-web-app-in-teams",
            target: "_blank",
            rel: "noopener noreferrer",
            className: "flex items-center gap-2 text-[var(--color-primary-600)] hover:underline",
            children: [
              /* @__PURE__ */ e(o, { className: "w-4 h-4" }),
              t("developer.teamsIntegration.resources.link3")
            ]
          }
        )
      ] })
    ] }),
    /* @__PURE__ */ r("div", { className: "flex justify-between pt-4 border-t border-[var(--border-color)]", children: [
      /* @__PURE__ */ r(
        s,
        {
          to: "/system/docs/developer/multi-tenant-mode",
          className: "flex items-center gap-2 text-[var(--color-primary-600)] hover:underline",
          children: [
            /* @__PURE__ */ e(c, { className: "w-4 h-4 rotate-180" }),
            t("developer.teamsIntegration.nav.previous")
          ]
        }
      ),
      /* @__PURE__ */ r(
        s,
        {
          to: "/system/docs/developer",
          className: "flex items-center gap-2 text-[var(--color-primary-600)] hover:underline",
          children: [
            t("developer.teamsIntegration.nav.backIndex"),
            /* @__PURE__ */ e(c, { className: "w-4 h-4" })
          ]
        }
      )
    ] })
  ] });
}
export {
  k as TeamsIntegrationPage
};
//# sourceMappingURL=TeamsIntegrationPage-BwhBcPAK.js.map
