PageSourceSearch

https://delphigrc.org/assets/Research-B05CxYpc.js

js delphigrc.org collected 2026-10-04 00:26:06 UTC 4,957 bytes, 1 lines download raw bytes

1import{r as e,j as t,L as s}from"./vendor-react-BH6F5oQJ.js";import{s as r,H as a,f as n,p as i,e as o}from"./index-dRqPaCFl.js";import{u as c}from"./usePages-B42aSg8W.js";import{L as l}from"./LazyRichTextEditor-ByQjI7gT.js";import{S as d,b as m,X as h,A as p}from"./vendor-icons-CaI5__By.js";import"./vendor-ui-B4WC06Sp.js";import"./vendor-query-CC4VRGyP.js";import"./vendor-supabase-COwyE4EW.js";const x=()=>{const{getPageBySlug:x,updatePage:u,loading:g}=c(),[j,f]=e.useState(null),[y,b]=e.useState(!1),[v,N]=e.useState(!1),[w,C]=e.useState("");e.useEffect(()=>{k(),R()},[]);const k=async()=>{try{const{data:{user:e}}=await r.auth.getUser();if(!e)return void b(!1);const{data:t}=await r.from("user_roles").select("role").eq("user_id",e.id);b((null==t?void 0:t.some(e=>"super_admin"===e.role))||!1)}catch(e){b(!1)}},R=async()=>{const e=await x("research");f(e),(null==e?void 0:e.content)&&"object"==typeof e.content&&"html"in e.content&&C(e.content.html)};return g?t.jsx("div",{className:"min-h-screen bg-background",children:t.jsx("div",{className:"container mx-auto px-4 pt-32 pb-20",children:t.jsx("p",{className:"text-center text-muted-foreground",children:"Loading..."})})}):t.jsxs("div",{className:"min-h-screen bg-background",children:[t.jsxs(a,{children:[t.jsx("title",{children:"Research & Publications on Eurasian Security | Delphi Global Research Center"}),t.jsx("meta",{name:"description",content:"Comprehensive research, policy briefs, and academic publications on Eurasian security, Russia-China relations, NATO strategy, and regional dynamics. Expert analysis from leading scholars."}),t.jsx("meta",{name:"keywords",content:"research papers, policy briefs, Eurasian security research, international relations publications, think tank research, academic analysis, strategic studies"}),t.jsx("meta",{property:"og:type",content:"website"}),t.jsx("meta",{property:"og:title",content:"Research & Publications | Delphi Global Research Center"}),t.jsx("meta",{property:"og:description",content:"Comprehensive research on Eurasian security and regional dynamics. Policy briefs and expert analysis."}),t.jsx("meta",{property:"og:url",content:"https://delphigrc.org/research"}),t.jsx("meta",{property:"og:site_name",content:"Delphi Global Research Center"}),t.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),t.jsx("meta",{name:"twitter:site",content:"@DelphiGRC"}),t.jsx("meta",{name:"twitter:title",content:"Research & Publications | Delphi Global Research Center"}),t.jsx("meta",{name:"twitter:description",content:"Comprehensive research on Eurasian security and regional dynamics."}),t.jsx("link",{rel:"canonical",href:"https://delphigrc.org/research"}),t.jsx("link",{rel:"alternate",hrefLang:"en",href:"https://delphigrc.org/research"}),t.jsx("link",{rel:"alternate",hrefLang:"x-default",href:"https://delphigrc.org/research"})]}),t.jsx("main",{className:"container mx-auto px-4 pt-32 pb-20",children:t.jsxs("div",{className:"max-w-7xl mx-auto",children:[t.jsxs("div",{className:"flex justify-between items-center mb-6",children:[t.jsx("h1",{className:"text-5xl font-bold text-gradient",children:"Research"}),y&&t.jsx("div",{className:"flex gap-2",children:v?t.jsxs(t.Fragment,{children:[t.jsxs(n,{onClick:async()=>{if(!j)return;const e=await u(j.id,{content:{html:w}});e&&(f(e),N(!1))},size:"sm",children:[t.jsx(m,{className:"w-4 h-4 mr-2"}),"Save"]}),t.jsxs(n,{onClick:()=>{const e=null==j?void 0:j.content;C(e&&"object"==typeof e&&"html"in e&&e.html||""),N(!1)},variant:"outline",size:"sm",children:[t.jsx(h,{className:"w-4 h-4 mr-2"}),"Cancel"]})]}):t.jsxs(n,{onClick:()=>N(!0),size:"sm",children:[t.jsx(d,{className:"w-4 h-4 mr-2"}),"Edit Page"]})})]}),v?t.jsx("div",{className:"prose prose-lg max-w-none",children:t.jsx(l,{content:w,onChange:C,placeholder:"Start writing your research content..."})}):t.jsx("div",{className:"prose prose-lg max-w-none",children:(null==j?void 0:j.content)&&"object"==typeof j.content&&"html"in j.content&&j.content.html?t.jsx("div",{dangerouslySetInnerHTML:{__html:i.sanitize(j.content.html)}}):t.jsxs("p",{className:"text-muted-foreground",children:["No content yet. ",y&&"Click Edit Page to start writing."]})}),t.jsxs("section",{className:"mt-12",children:[t.jsx("h2",{className:"mb-6 font-heading text-2xl font-bold text-foreground",children:"Research areas"}),t.jsx("div",{className:"grid gap-4 sm:grid-cols-2 lg:grid-cols-3",children:Object.entries(o).map(([e,r])=>t.jsxs(s,{to:r,className:"group flex items-center justify-between rounded-xl border border-border bg-card p-5 transition-all hover:border-primary/30 hover:shadow-lg focus:outline-none focus-visible:ring-2 focus-visible:ring-primary",children:[t.jsx("span",{className:"font-heading text-lg font-semibold text-foreground group-hover:text-primary",children:e}),t.jsx(p,{className:"h-5 w-5 shrink-0 text-primary transition-transform group-hover:translate-x-1","aria-hidden":"true"})]},r))})]})]})})]})};export{x as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.