PageSourceSearch

https://kp.gov.pk/assets/ProfileModal-8fsoQrkR.js

js kp.gov.pk collected 2026-09-24 18:58:20 UTC 6,065 bytes, 1 lines download raw bytes

1import{u as r,j as e,U as d}from"./index-D43MT5hw.js";import{M as o}from"./index-DEwnEsq1.js";function c({children:a,tone:s="emerald"}){const l={emerald:"bg-emerald-500/10 text-emerald-700 ring-emerald-600/20",slate:"bg-slate-500/10 text-slate-700 ring-slate-600/20",rose:"bg-rose-500/10 text-rose-700 ring-rose-600/20",amber:"bg-amber-500/10 text-amber-700 ring-amber-600/20"};return e.jsxs("span",{className:["inline-flex items-center gap-1 rounded-full px-2.5 py-1 text-xs font-semibold ring-1",l[s]??l.slate].join(" "),children:[e.jsx("span",{className:"h-1.5 w-1.5 rounded-full bg-current opacity-70"}),a]})}function i({label:a,value:s}){return e.jsxs("div",{className:"space-y-1",children:[e.jsx("div",{className:"text-xs font-medium text-slate-500",children:a}),e.jsx("div",{className:"text-sm font-semibold text-slate-900",children:s||"—"})]})}function x({rows:a}){return e.jsx("div",{className:"overflow-x-auto rounded-xl ring-1 ring-slate-200",children:e.jsxs("table",{className:"min-w-[640px] w-full text-left text-sm",children:[e.jsx("thead",{className:"background-linear text-white",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-4 py-3 font-semibold",children:"Position"}),e.jsx("th",{className:"px-4 py-3 font-semibold",children:"Portfolio"}),e.jsx("th",{className:"px-4 py-3 font-semibold",children:"From"}),e.jsx("th",{className:"px-4 py-3 font-semibold",children:"To"})]})}),e.jsx("tbody",{className:"divide-y divide-slate-200 bg-white",children:a.map((s,l)=>e.jsxs("tr",{className:"hover:bg-slate-50/60",children:[e.jsx("td",{className:"px-4 py-3",children:e.jsx("span",{className:"inline-flex rounded-full bg-slate-900/5 px-2 py-1 text-xs font-semibold text-slate-800 whitespace-nowrap",children:s.position_type})}),e.jsx("td",{className:"px-4 py-3 text-slate-900 whitespace-nowrap",children:s.department}),e.jsxs("td",{className:"px-4 py-3 text-slate-700 whitespace-nowrap",children:[e.jsx("div",{children:s.working_from_date}),s.notification?.url&&e.jsxs("a",{href:s.notification.url,download:!0,target:"_blank",rel:"noreferrer",className:"mt-1 flex items-center gap-2 cursor-pointer text-xs font-medium text-sky-600 hover:underline",children:[e.jsx(d,{}),e.jsx("span",{children:"Notification"})]})]}),e.jsx("td",{className:"px-4 py-3 whitespace-nowrap",children:s.working_till_date===null?e.jsx("span",{className:"inline-flex rounded-full bg-emerald-500/10 px-2 py-1 text-xs font-semibold text-emerald-700 ring-1 ring-emerald-600/20",children:"Present"}):e.jsx("span",{className:"text-slate-700",children:s.working_till_date})})]},l))})]})})}function p({open:a,onClose:s,profile:l}){const t=l??[],n=r();return e.jsx(o,{open:a,onClose:s,size:"xl",titleId:"profile-modal-title",children:e.jsxs("div",{className:"flex max-h-[90vh] flex-col overflow-hidden",children:[e.jsxs("div",{className:"relative shrink-0",children:[e.jsx("div",{className:"bg-linear-to-r from-white via-white to-white px-4 py-4 sm:px-6 sm:py-5",children:e.jsxs("div",{className:"flex items-start justify-between gap-3",children:[e.jsxs("div",{className:"flex min-w-0 items-start gap-3 sm:gap-4",children:[t?.image_path&&e.jsx("img",{src:t?.image_path,alt:"",loading:"lazy",className:"h-12 w-12 rounded-2xl object-cover ring-2 ring-white/15 sm:h-14 sm:w-14"}),e.jsxs("div",{className:"min-w-0 text-black",children:[e.jsx("h2",{id:"profile-modal-title",className:"truncate text-base font-bold tracking-tight sm:text-lg",children:t?.name}),e.jsxs("div",{className:"mt-0.5 text-xs text-black/75 sm:text-sm",children:[e.jsx("span",{className:"font-semibold",children:t?.position_type}),e.jsx("span",{className:"mx-2 text-black/35",children:"•"}),e.jsxs("span",{className:"break-words",children:[t?.department," • ",t?.halqa]})]}),e.jsx("div",{className:"mt-2",children:e.jsx(c,{tone:"emerald",children:t?.status})})]})]}),e.jsx("button",{onClick:s,className:"shrink-0 rounded-xl p-2 text-black/70 hover:bg-slate-100 hover:text-black focus:outline-none focus:ring-2 focus:ring-slate-300","aria-label":"Close",type:"button",children:e.jsx("svg",{viewBox:"0 0 24 24",className:"h-5 w-5",fill:"none",stroke:"currentColor",strokeWidth:"2",children:e.jsx("path",{d:"M6 6l12 12M18 6L6 18"})})})]})}),e.jsx("div",{className:"h-px bg-slate-200"})]}),e.jsx("div",{className:"flex-1 overflow-y-auto",children:e.jsxs("div",{className:"grid gap-4 p-4 sm:gap-6 sm:p-6 md:grid-cols-12",children:[e.jsx("div",{className:"md:col-span-3",children:e.jsx("div",{className:"rounded-2xl bg-slate-50 p-4 ring-1 ring-slate-200 sm:p-5",children:e.jsxs("div",{className:"space-y-4",children:[e.jsx(i,{label:"Email",value:t?.email}),e.jsx("div",{className:"h-px bg-slate-200"}),e.jsx(i,{label:"Phone",value:t?.contact_no}),e.jsx("div",{className:"h-px bg-slate-200"}),e.jsx(i,{label:"Office No",value:t?.office_no}),e.jsx("div",{className:"h-px bg-slate-200"}),e.jsx(i,{label:"Address",value:t?.address})]})})}),e.jsxs("div",{className:"md:col-span-9 min-w-0",children:[e.jsx("div",{className:"flex items-center gap-2 rounded-xl p-1",children:e.jsx("h3",{className:"text-lg font-semibold sm:text-xl",children:"History"})}),e.jsx("div",{className:"mt-2",children:t?.history?.length?e.jsx(x,{rows:t.history}):e.jsx("div",{className:"rounded-2xl bg-white p-5 ring-1 ring-slate-200",children:e.jsx("div",{className:"text-sm text-slate-600",children:"Data not found"})})})]})]})}),e.jsxs("div",{className:"shrink-0 flex flex-col gap-2 border-t border-slate-200 bg-white px-4 py-3 sm:flex-row sm:items-center sm:justify-between sm:px-6 sm:py-4",children:[e.jsxs("button",{onClick:()=>{n(`/member-gallery/${l?.position_type||l?.position}`)},className:"rounded-xl background-linear px-4 py-2 text-sm font-semibold text-white focus:outline-none focus:ring-2 focus:ring-slate-400",type:"button",children:[l?.position_type||l?.position," Gallery"]}),e.jsx("button",{onClick:s,className:"rounded-xl border border-slate-300 px-4 py-2 text-sm font-semibold text-slate-700 hover:bg-slate-100 focus:outline-none focus:ring-2 focus:ring-slate-400",type:"button",children:"Close"})]})]})})}export{p as P};

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.