dev-process-kit 0.0.16 → 0.0.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/{shared-B0kk4Png.js → shared-8NAMqG0U.js} +1 -1
- package/dist/chunks/{shared-DLpKWOi6.js → shared-B00JP4in.js} +1 -1
- package/dist/chunks/shared-B5lBiq5s.js +1 -0
- package/dist/chunks/{shared-56aw61Mt.js → shared-BtN-8ibq.js} +1 -1
- package/dist/chunks/{shared-CYcKSitA.js → shared-C6QYWD8M.js} +3 -3
- package/dist/chunks/{shared-CHPc3-vO.js → shared-CUPe-wfx.js} +1 -1
- package/dist/chunks/{shared-BMyu-cIr.js → shared-CWKqlSx3.js} +1 -1
- package/dist/chunks/shared-CpTDkEui.js +3751 -0
- package/dist/chunks/shared-CtHWU02m.js +1 -0
- package/dist/chunks/{shared-6yS1zZwk.js → shared-DEjjuQMh.js} +1 -1
- package/dist/chunks/{shared-DlMlDHZ3.js → shared-DRvgJdY6.js} +1 -1
- package/dist/chunks/{shared-DFT6VIi_.js → shared-DWY93NpU.js} +1 -1
- package/dist/chunks/{shared-C1OgX-P6.js → shared-DXaIVZ_z.js} +56 -56
- package/dist/chunks/{shared-BqyO8tFt.js → shared-DzxR5Yzc.js} +1 -1
- package/dist/chunks/{shared-wOFcYu2a.js → shared-Ezic-gbC.js} +1 -1
- package/dist/chunks/{shared-BYBLt-RG.js → shared-IQ2sflGo.js} +1 -1
- package/dist/components.js +1 -1
- package/dist/index.js +1 -1
- package/dist/templates/delegation-poker.js +1 -1
- package/dist/templates/event-storming.js +1 -1
- package/dist/templates/example-mapping.js +1 -1
- package/dist/templates/grill.js +1 -1
- package/dist/templates/plain.js +1 -1
- package/dist/templates/prototype.js +1 -1
- package/dist/templates/slides.js +1 -1
- package/dist/templates/task-board.js +1 -1
- package/dist/templates/usm.js +1 -1
- package/dist/templates/whiteboard.js +1 -1
- package/package.json +1 -1
- package/dist/chunks/shared-DdefS1nG.js +0 -1
- package/dist/chunks/shared-DewUyNUX.js +0 -2245
- package/dist/chunks/shared-sTu0Wlge.js +0 -1
|
@@ -1,2245 +0,0 @@
|
|
|
1
|
-
import{ad as yt,aP as kt,ae as z,af as B,ag as P,aB as L,ah as u,aA as D,aj as b,ak as f,aO as xt,b5 as St,ai as be,p as m,au as g,v as q,az as V,P as wt,e as Tt,a0 as $t,V as T,R as y,a7 as j,a2 as Z,G as Et,a4 as l,aU as M,a3 as v,a8 as Lt,j as At,aa as _t,aS as It,aT as Rt,A as Ot,l as K,a5 as A,aE as Y,J as Dt,B as Mt,K as ve,aI as Nt,z as fe,h as Ct,at as Bt,T as ye,a1 as Yt,a9 as Ut,aJ as zt,b6 as Pt}from"./shared-C1OgX-P6.js";import{s as Vt}from"./shared-D4K7KsfJ.js";import{D as Gt}from"./shared-sTu0Wlge.js";import{r as le,D as Ft}from"./shared-DdefS1nG.js";const jt=[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"m16 9-5.5 5.5L8 12"}]],Kt=[["path",{d:"M10.1 2.182a10 10 0 0 1 3.8 0"}],["path",{d:"M13.9 21.818a10 10 0 0 1-3.8 0"}],["path",{d:"M17.609 3.721a10 10 0 0 1 2.69 2.7"}],["path",{d:"M2.182 13.9a10 10 0 0 1 0-3.8"}],["path",{d:"M20.279 17.609a10 10 0 0 1-2.7 2.69"}],["path",{d:"M21.818 10.1a10 10 0 0 1 0 3.8"}],["path",{d:"M3.721 6.391a10 10 0 0 1 2.7-2.69"}],["path",{d:"M6.391 20.279a10 10 0 0 1-2.69-2.7"}]],qt=[["circle",{cx:"12",cy:"12",r:"10"}],["line",{x1:"10",x2:"10",y1:"15",y2:"9"}],["line",{x1:"14",x2:"14",y1:"15",y2:"9"}]],Ht=[["path",{d:"M9 9.003a1 1 0 0 1 1.517-.859l4.997 2.997a1 1 0 0 1 0 1.718l-4.997 2.997A1 1 0 0 1 9 14.996z"}],["circle",{cx:"12",cy:"12",r:"10"}]],Wt=[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"m15 9-6 6"}],["path",{d:"m9 9 6 6"}]],Xt=[["circle",{cx:"12",cy:"12",r:"10"}]],Zt=[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"M12 6v6l4 2"}]],Jt=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0"}],["circle",{cx:"12",cy:"12",r:"3"}]],Qt=[["path",{d:"M4 22V4a1 1 0 0 1 .4-.8A6 6 0 0 1 8 2c3 0 5 2 7.333 2q2 0 3.067-.8A1 1 0 0 1 20 4v10a1 1 0 0 1-.4.8A6 6 0 0 1 16 16c-3 0-5-2-8-2a6 6 0 0 0-4 1.528"}]],ea=[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5"}],["path",{d:"M9 18h6"}],["path",{d:"M10 22h4"}]],Q=["gray","blue","violet","green","amber","accent"],ke=["progress","circle","lightbulb","flag","play","clock","eye","pause","check","x"],ta=z({id:b(u(),f(1)),name:b(u(),f(1))}),aa=z({id:D,name:b(u(),f(1)),actor:L(u()),steps:B(P(ta),[])}),sa=z({id:b(u(),f(1)),name:b(u(),f(1)),timeframe:L(u()),description:L(u())}),H=be(Q),de=be(ke),pe=b(u(),St(),xt(e=>/^https?:\/\//i.test(e),"a link must be an http(s) URL")),ia=z({url:pe,label:L(b(u(),f(1)))}),na=z({id:D,name:b(u(),f(1)),tone:B(H),icon:B(de)}),ra=z({id:D,name:b(u(),f(1)),tone:B(H)}),oa=z({id:D,name:b(u(),f(1)),description:L(u()),activityId:b(u(),f(1)),stepId:b(u(),f(1)),milestoneId:L(u()),statusId:L(u()),links:L(P(ia)),labelIds:L(P(b(u(),f(1))))}),la=z({title:L(u()),activities:B(P(aa),[]),milestones:B(P(sa),[]),statuses:B(P(na),[]),labels:B(P(ra),[]),stories:B(P(oa),[])}),ce=e=>Q[e%Q.length]??"gray",xe=e=>ce(e+1),Se=e=>{const t=yt(la,e),a=t.statuses[0]?.id,s={...t,stories:a===void 0?t.stories:t.stories.map(d=>d.statusId===void 0?{...d,statusId:a}:d),statuses:t.statuses.map((d,x)=>({...d,tone:d.tone??ce(x),icon:d.icon??"progress"})),labels:t.labels.map((d,x)=>({...d,tone:d.tone??xe(x)}))},i=new Map;for(const d of s.activities)for(const x of d.steps)i.set(x.id,d.id);const n=new Set(s.milestones.map(d=>d.id)),r=new Set(s.statuses.map(d=>d.id)),o=new Set(s.labels.map(d=>d.id)),p=new Set,c=(d,x)=>{if(p.has(x))throw new Error(`duplicate id "${x}" in ${d}`);p.add(x)};for(const d of s.activities){c("activities",d.id);for(const x of d.steps)c("steps",x.id)}for(const d of s.milestones)c("milestones",d.id);for(const d of s.statuses)c("statuses",d.id);for(const d of s.labels)c("labels",d.id);for(const d of s.stories){c("stories",d.id);const x=i.get(d.stepId);if(x===void 0||x!==d.activityId)throw new Error(`story "${d.id}" references unknown activityId/stepId`);if(d.milestoneId!==void 0&&!n.has(d.milestoneId))throw new Error(`story "${d.id}" references unknown milestoneId "${d.milestoneId}"`);const R=(d.links??[]).map(w=>w.url);if(new Set(R).size!==R.length)throw new Error(`story "${d.id}" links the same URL twice`);if(d.statusId!==void 0&&!r.has(d.statusId))throw new Error(`story "${d.id}" references unknown statusId "${d.statusId}"`);const k=d.labelIds??[];if(new Set(k).size!==k.length)throw new Error(`story "${d.id}" has a label twice`);const E=k.find(w=>!o.has(w));if(E!==void 0)throw new Error(`story "${d.id}" references unknown labelId "${E}"`)}return s},we=()=>({activities:[],milestones:[],statuses:[],labels:[],stories:[]}),U=(e,t)=>{if(t!==void 0)return e.activities.find(a=>a.id===t)},ee=(e,t)=>`${e}.${t}`,$=(e,t)=>{if(t===void 0)return;const a=kt(t,2);if(a){const[s,i]=a;if(s===void 0||i===void 0)return;const n=e.activities.find(o=>o.id===s),r=n?.steps.find(o=>o.id===i);return n&&r?{activity:n,step:r}:void 0}if(!t.includes("."))for(const s of e.activities){const i=s.steps.find(n=>n.id===t);if(i)return{activity:s,step:i}}},N=(e,t)=>{if(t!==void 0)return e.milestones.find(a=>a.id===t)},_=(e,t)=>{if(t!==void 0)return e.statuses.find(a=>a.id===t)},I=(e,t)=>{if(t!==void 0)return e.labels.find(a=>a.id===t)},da=(e,t)=>{const a=new Set(t.labelIds??[]);return e.labels.filter(s=>a.has(s.id))},S=(e,t)=>{if(t!==void 0)return e.stories.find(a=>a.id===t)},ue=e=>e.activities.flatMap(t=>t.steps.map(a=>({activity:t,step:a}))),pa=e=>({...e,stories:Vt(e.stories,[t=>`${t.activityId}/${t.stepId}/${t.milestoneId??""}`])}),te=(e,t,a)=>e.stories.filter(s=>s.stepId===t&&(s.milestoneId??void 0)===a),Te=(e,t,a)=>e.stories.filter(s=>s.activityId===t&&(s.milestoneId??void 0)===a),G=e=>[...e.activities.map(t=>t.id),...e.activities.flatMap(t=>t.steps.map(a=>a.id)),...e.milestones.map(t=>t.id),...e.statuses.map(t=>t.id),...e.labels.map(t=>t.id),...e.stories.map(t=>t.id)],$e=(e,t)=>e.stories.filter(a=>a.stepId===t).length,h={SET_ACTIVITY_NAME:m("SET_ACTIVITY_NAME","activity",g({name:b(u(),f(1))})),SET_ACTIVITY_ACTOR:m("SET_ACTIVITY_ACTOR","activity",g({actor:u()})),SET_STEP_NAME:m("SET_STEP_NAME","step",g({name:b(u(),f(1))})),REORDER_STEP:m("REORDER_STEP","step",g({after:V(u())}),{mode:"sequence"}),ADD_ACTIVITY:m("ADD_ACTIVITY","page",g({id:D,name:b(u(),f(1))}),{dedupeKey:q}),ADD_STEP:m("ADD_STEP","activity",g({id:D,name:b(u(),f(1))}),{dedupeKey:q}),DELETE_ACTIVITY:m("DELETE_ACTIVITY","activity",g({})),DELETE_STEP:m("DELETE_STEP","step",g({})),SET_STORY_NAME:m("SET_STORY_NAME","story",g({name:b(u(),f(1))})),SET_STORY_DESCRIPTION:m("SET_STORY_DESCRIPTION","story",g({description:u()})),SET_STORY_MILESTONE:m("SET_STORY_MILESTONE","story",g({milestoneId:V(u())})),MOVE_STORY:m("MOVE_STORY","story",g({activityId:b(u(),f(1)),stepId:b(u(),f(1)),milestoneId:V(u()),after:V(u())}),{mode:"sequence"}),REORDER_STORY:m("REORDER_STORY","story",g({after:V(u())}),{mode:"sequence"}),ADD_STORY:m("ADD_STORY","step",g({id:D,name:b(u(),f(1)),activityId:b(u(),f(1)),milestoneId:L(u())}),{dedupeKey:q}),DELETE_STORY:m("DELETE_STORY","story",g({})),ADD_STORY_LINK:m("ADD_STORY_LINK","story",g({url:pe,label:L(b(u(),f(1)))})),REMOVE_STORY_LINK:m("REMOVE_STORY_LINK","story",g({url:u()})),SET_STORY_STATUS:m("SET_STORY_STATUS","story",g({statusId:b(u(),f(1))})),SET_MILESTONE_NAME:m("SET_MILESTONE_NAME","milestone",g({name:b(u(),f(1))})),ADD_MILESTONE:m("ADD_MILESTONE","page",g({id:D,name:b(u(),f(1))}),{dedupeKey:q}),DELETE_MILESTONE:m("DELETE_MILESTONE","milestone",g({})),REORDER_MILESTONE:m("REORDER_MILESTONE","milestone",g({after:V(u())}),{mode:"sequence"}),ADD_STATUS:m("ADD_STATUS","page",g({id:D,name:b(u(),f(1)),tone:H,icon:L(de)}),{dedupeKey:q}),SET_STATUS_NAME:m("SET_STATUS_NAME","status",g({name:b(u(),f(1))})),SET_STATUS_TONE:m("SET_STATUS_TONE","status",g({tone:H})),SET_STATUS_ICON:m("SET_STATUS_ICON","status",g({icon:de})),DELETE_STATUS:m("DELETE_STATUS","status",g({})),REORDER_STATUS:m("REORDER_STATUS","status",g({after:V(u())}),{mode:"sequence"}),ADD_LABEL:m("ADD_LABEL","page",g({id:D,name:b(u(),f(1)),tone:H}),{dedupeKey:q}),SET_LABEL_NAME:m("SET_LABEL_NAME","label",g({name:b(u(),f(1))})),SET_LABEL_TONE:m("SET_LABEL_TONE","label",g({tone:H})),DELETE_LABEL:m("DELETE_LABEL","label",g({})),REORDER_LABEL:m("REORDER_LABEL","label",g({after:V(u())}),{mode:"sequence"}),ADD_STORY_LABEL:m("ADD_STORY_LABEL","story",g({labelId:b(u(),f(1))})),REMOVE_STORY_LABEL:m("REMOVE_STORY_LABEL","story",g({labelId:b(u(),f(1))}))},ca={setActivityName:(e,t)=>({type:"SET_ACTIVITY_NAME",target:{type:"activity",id:e},payload:{name:t}}),setStepName:(e,t)=>({type:"SET_STEP_NAME",target:{type:"step",id:e},payload:{name:t}})},Ee=(e,t)=>{const a=wt(h,t);if(a===null)return null;const s=a.target.id;switch(a.type){case"SET_ACTIVITY_NAME":{const{name:i}=a.payload;return e.activities.some(n=>n.id===s)?{...e,activities:e.activities.map(n=>n.id===s?{...n,name:i}:n)}:null}case"SET_ACTIVITY_ACTOR":{const i=a.payload.actor.trim();return e.activities.some(n=>n.id===s)?{...e,activities:e.activities.map(n=>{if(n.id!==s)return n;const{actor:r,...o}=n;return i===""?o:{...o,actor:i}})}:null}case"SET_STEP_NAME":{const{name:i}=a.payload,n=$(e,s);return n?{...e,activities:e.activities.map(r=>r.id===n.activity.id?{...r,steps:r.steps.map(o=>o.id===n.step.id?{...o,name:i}:o)}:r)}:null}case"REORDER_STEP":{const{after:i}=a.payload,n=$(e,s);if(!n)return null;const r=i===null?null:$(e,i);if(i!==null&&(!r||r.activity.id!==n.activity.id))return null;const o=ae(n.activity.steps,n.step.id,r?.step.id??null);return o===null?null:{...e,activities:e.activities.map(p=>p.id===n.activity.id?{...p,steps:o}:p)}}case"ADD_ACTIVITY":{const i=a.payload;return e.activities.some(n=>n.id===i.id)?e:{...e,activities:[...e.activities,{id:i.id,name:i.name,steps:[]}]}}case"ADD_STEP":{const i=a.payload,n=e.activities.find(r=>r.id===s);return n?n.steps.some(r=>r.id===i.id)?e:{...e,activities:e.activities.map(r=>r.id===s?{...r,steps:[...r.steps,{id:i.id,name:i.name}]}:r)}:null}case"DELETE_ACTIVITY":{const i=e.activities.find(r=>r.id===s);if(!i)return null;const n=new Set(i.steps.map(r=>r.id));return{...e,activities:e.activities.filter(r=>r.id!==s),stories:e.stories.filter(r=>r.activityId!==s&&!n.has(r.stepId))}}case"DELETE_STEP":{const i=$(e,s);return i?{...e,activities:e.activities.map(n=>n.id===i.activity.id?{...n,steps:n.steps.filter(r=>r.id!==i.step.id)}:n),stories:e.stories.filter(n=>n.activityId!==i.activity.id||n.stepId!==i.step.id)}:null}case"SET_STORY_NAME":{const{name:i}=a.payload;return F(e,s,n=>({...n,name:i}))}case"SET_STORY_DESCRIPTION":{const{description:i}=a.payload;return F(e,s,n=>({...n,description:i}))}case"SET_STORY_MILESTONE":{const{milestoneId:i}=a.payload;return i!==null&&!N(e,i)?null:F(e,s,n=>i===null?me(n):{...n,milestoneId:i})}case"MOVE_STORY":{const i=a.payload,n=S(e,s);if(!n)return null;const r=$(e,i.stepId);if(!r||r.activity.id!==i.activityId||i.milestoneId!==null&&!N(e,i.milestoneId))return null;const o=i.milestoneId??void 0,p=o===void 0?{...me(n),activityId:r.activity.id,stepId:r.step.id}:{...n,activityId:r.activity.id,stepId:r.step.id,milestoneId:o};return Ae(e,p,i.after)}case"REORDER_STORY":{const{after:i}=a.payload,n=S(e,s);return n?Ae(e,n,i,!0):null}case"ADD_STORY":{const i=a.payload,n=$(e,t.target.id);if(!n||n.activity.id!==i.activityId||i.milestoneId!==void 0&&!N(e,i.milestoneId))return null;if(e.stories.some(o=>o.id===i.id))return e;const r={id:i.id,name:i.name,activityId:i.activityId,stepId:n.step.id,...i.milestoneId===void 0?{}:{milestoneId:i.milestoneId},...e.statuses[0]===void 0?{}:{statusId:e.statuses[0].id}};return{...e,stories:[...e.stories,r]}}case"DELETE_STORY":return e.stories.some(i=>i.id===s)?{...e,stories:e.stories.filter(i=>i.id!==s)}:null;case"ADD_STORY_LINK":{const{url:i,label:n}=a.payload,r=S(e,s);if(!r)return null;if(r.links?.some(p=>p.url===i))return e;const o=n===void 0?{url:i}:{url:i,label:n};return F(e,s,p=>({...p,links:[...p.links??[],o]}))}case"REMOVE_STORY_LINK":{const{url:i}=a.payload;return S(e,s)?.links?.some(r=>r.url===i)?F(e,s,r=>{const o=(r.links??[]).filter(d=>d.url!==i),{links:p,...c}=r;return o.length===0?c:{...c,links:o}}):null}case"SET_STORY_STATUS":{const{statusId:i}=a.payload;return _(e,i)?F(e,s,n=>({...n,statusId:i})):null}case"SET_MILESTONE_NAME":{const{name:i}=a.payload;return e.milestones.some(n=>n.id===s)?{...e,milestones:e.milestones.map(n=>n.id===s?{...n,name:i}:n)}:null}case"ADD_MILESTONE":{const i=a.payload;return e.milestones.some(n=>n.id===i.id)?e:{...e,milestones:[...e.milestones,{id:i.id,name:i.name}]}}case"DELETE_MILESTONE":return e.milestones.some(i=>i.id===s)?{...e,milestones:e.milestones.filter(i=>i.id!==s),stories:e.stories.map(i=>i.milestoneId===s?me(i):i)}:null;case"REORDER_MILESTONE":{const{after:i}=a.payload,n=ae(e.milestones,s,i);return n===null?null:{...e,milestones:n}}case"ADD_STATUS":{const{id:i,name:n,tone:r,icon:o}=a.payload;if(e.statuses.some(c=>c.id===i))return e;const p=[...e.statuses,{id:i,name:n,tone:r,icon:o??"progress"}];return e.statuses.length===0?{...e,statuses:p,stories:e.stories.map(c=>({...c,statusId:i}))}:{...e,statuses:p}}case"SET_STATUS_NAME":{const{name:i}=a.payload;return _(e,s)?{...e,statuses:e.statuses.map(n=>n.id===s?{...n,name:i}:n)}:null}case"SET_STATUS_TONE":{const{tone:i}=a.payload;return _(e,s)?{...e,statuses:e.statuses.map(n=>n.id===s?{...n,tone:i}:n)}:null}case"SET_STATUS_ICON":{const{icon:i}=a.payload;return _(e,s)?{...e,statuses:e.statuses.map(n=>n.id===s?{...n,icon:i}:n)}:null}case"DELETE_STATUS":{if(!_(e,s))return null;const i=e.statuses.filter(r=>r.id!==s),n=i[0]?.id;return{...e,statuses:i,stories:e.stories.map(r=>r.statusId!==s?r:n===void 0?ua(r):{...r,statusId:n})}}case"REORDER_STATUS":{const{after:i}=a.payload,n=ae(e.statuses,s,i);return n===null?null:{...e,statuses:n}}case"ADD_LABEL":{const{id:i,name:n,tone:r}=a.payload;return I(e,i)?e:{...e,labels:[...e.labels,{id:i,name:n,tone:r}]}}case"SET_LABEL_NAME":{const{name:i}=a.payload;return I(e,s)?{...e,labels:e.labels.map(n=>n.id===s?{...n,name:i}:n)}:null}case"SET_LABEL_TONE":{const{tone:i}=a.payload;return I(e,s)?{...e,labels:e.labels.map(n=>n.id===s?{...n,tone:i}:n)}:null}case"DELETE_LABEL":return I(e,s)?{...e,labels:e.labels.filter(i=>i.id!==s),stories:e.stories.map(i=>i.labelIds?.includes(s)?Le(i,s):i)}:null;case"REORDER_LABEL":{const{after:i}=a.payload,n=ae(e.labels,s,i);return n===null?null:{...e,labels:n}}case"ADD_STORY_LABEL":{const{labelId:i}=a.payload,n=S(e,s);return!n||!I(e,i)?null:n.labelIds?.includes(i)?e:F(e,s,r=>({...r,labelIds:[...r.labelIds??[],i]}))}case"REMOVE_STORY_LABEL":{const{labelId:i}=a.payload;return S(e,s)?.labelIds?.includes(i)?F(e,s,n=>Le(n,i)):null}default:return Tt(a)}},F=(e,t,a)=>e.stories.some(s=>s.id===t)?{...e,stories:e.stories.map(s=>s.id===t?a(s):s)}:null,me=e=>{const{milestoneId:t,...a}=e;return a},Le=(e,t)=>{const{labelIds:a=[],...s}=e,i=a.filter(n=>n!==t);return i.length===0?s:{...s,labelIds:i}},ua=e=>{const{statusId:t,...a}=e;return a},Ae=(e,t,a,s=!1)=>{const i=t.milestoneId??void 0,n=e.stories.filter(k=>k.id!==t.id),r=n.filter(k=>k.stepId===t.stepId&&(k.milestoneId??void 0)===i);if(a!==null){const k=n.find(E=>E.id===a);if(!k||k.stepId!==t.stepId||(k.milestoneId??void 0)!==i)return null;if(s){const E=S(e,t.id);if(!E||k.stepId!==E.stepId||(k.milestoneId??void 0)!==(E.milestoneId??void 0))return null}}const o=a===null?[t,...r]:_e(r,t,a),p=n.findIndex(k=>k.stepId===t.stepId&&(k.milestoneId??void 0)===i),c=new Set(r.map(k=>k.id)),d=n.filter(k=>!c.has(k.id)),x=p<0?d.length:Math.min(p,d.length),R=[...d.slice(0,x),...o,...d.slice(x)];return{...e,stories:R}},ae=(e,t,a)=>{if(!e.some(n=>n.id===t)||a!==null&&!e.some(n=>n.id===a))return null;if(a===t)return[...e];const s=e.find(n=>n.id===t);if(s===void 0)return null;const i=e.filter(n=>n.id!==t);return _e(i,s,a)},_e=(e,t,a)=>{const s=[...e],i=a===null?-1:s.findIndex(n=>n.id===a);return s.splice(i+1,0,t),s},se=$t({en:{renameActivity:"Rename activity",changeActivityActor:"Change whose experience",renameStep:"Rename step",reorderStep:"Reorder step",addActivity:"Add activity",addStep:"Add step",deleteActivity:"Delete activity",deleteStep:"Delete step",renameStory:"Rename story",updateStoryDescription:"Update story description",changeMilestone:"Change milestone",moveStory:"Move story",reorderStory:"Reorder story",addStory:"Add story",deleteStory:"Delete story",renameMilestone:"Rename milestone",addMilestone:"Add milestone",deleteMilestone:"Delete milestone",reorderMilestone:"Reorder milestone",changeStoryStatus:"Change story status",addStatus:"Add status",renameStatus:"Rename status",changeStatusTone:"Change status color",changeStatusIcon:"Change status icon",addStoryLink:"Link to story",removeStoryLink:"Unlink from story",deleteStatus:"Delete status",reorderStatus:"Reorder status",addLabel:"Add label",renameLabel:"Rename label",changeLabelTone:"Change label color",deleteLabel:"Delete label",reorderLabel:"Reorder label",addStoryLabel:"Label story",removeStoryLabel:"Unlabel story",toValue:e=>`\u2192 \u201C${e}\u201D`,fromTo:(e,t)=>`\u201C${e}\u201D \u2192 \u201C${t}\u201D`,added:e=>`+ \u201C${e}\u201D`,removed:e=>`\u2212 \u201C${e}\u201D`,toFront:"\u2192 To the front",afterName:e=>`\u2192 Right after \u201C${e}\u201D`,toUnassigned:"\u2192 Unassigned",toName:e=>`\u2192 ${e}`,activityGroup:"Activity",stepGroup:"Step",storyGroup:"Story",milestoneGroup:"Milestone",statusGroup:"Status",labelGroup:"Label",mapGroup:"Map",targetLabel:(e,t)=>`${e} \xB7 ${t}`,targetMissing:(e,t)=>`${e} \xB7 ${t} (missing)`,wholeMap:"Whole map",unassigned:"Unassigned",emptyTitle:"No backbone yet",emptyBody:"Add activities and steps, and the story map appears here.",firstActivityButton:"+ First activity",groupingLabel:"Group by",groupViewTab:"Activity group",groupAxisHeader:"Activity group \u2192",activityAxis:"Activity \u2192",milestoneAxis:"Milestone \u2193",stepNameLabel:"Step name",activityNameLabel:"Activity name",milestoneNameLabel:"Milestone name",addStepAria:"Add a step to this activity",newActivityButton:"+ Activity",newMilestoneButton:"+ Milestone",addCellButton:"+ Add",addStoryCellAria:"Add a story to this cell",storyCount:e=>e===1?"1 story":`${e} stories`,pageTabsLabel:"Page",mapTab:"User Story Mapping",milestonesTab:"Milestones",statusesTab:"Statuses",labelsTab:"Labels",shareOfStories:e=>`${e}% of all stories`,coverageLabel:"Backbone coverage",coverage:(e,t)=>`${e} / ${t} steps`,storiesLabel:"Stories",timeframeUnset:"Timing not set",milestoneNoDescription:"No description yet.",noMilestonesTitle:"No milestones yet",noMilestonesBody:"Add a milestone to slice the map into releases.",commentCountAria:e=>e===1?"1 comment":`${e} comments`,statusNameLabel:"Status name",statusToneLabel:"Color",toneName:e=>({gray:"Gray",blue:"Blue",violet:"Violet",green:"Green",amber:"Amber",accent:"Orange"})[e],statusIconLabel:"Icon",iconName:e=>({progress:"Progress ring",circle:"Circle",lightbulb:"Light bulb",flag:"Flag",play:"Play",clock:"Clock",eye:"Eye",pause:"Pause",check:"Check",x:"Cross"})[e],statusShare:(e,t)=>`${e===1?"1 story":`${e} stories`} \xB7 ${t}%`,statusFilterLabel:"Status",clearFilter:"Clear",progressAria:e=>`Progress: ${e}`,activityActorLabel:"Who",noStatusesTitle:"No statuses yet",noStatusesBody:"Add statuses such as Idea / Ready / Done, and the map colors each story by where it stands.",newStatusButton:"+ Status",moveUpAria:"Move up",moveDownAria:"Move down",deleteStatusAria:"Delete this status",labelNameLabel:"Label name",noLabelsTitle:"No labels yet",noLabelsBody:"Add labels such as Dev / PdM to sort stories however the team likes. The kit gives them no meaning.",newLabelButton:"+ Label",deleteLabelAria:"Delete this label",moveDialogLabel:"Step to move to",moveDialogSelectLabel:"Destination",moveConfirm:"Move",moveCancel:"Cancel",storyStatusLabel:"Status",panelLabel:e=>`Story: ${e}`,closePanelAria:"Close",storyTitleLabel:"Title",storyDescriptionLabel:"Description",storyLinksLabel:"Links",storyLabelsLabel:"Labels",storyNoLabels:"No labels yet.",manageLabels:"Manage labels",linkUrlLabel:"URL",addLinkButton:"Add",removeLinkAria:e=>`Remove ${e}`,deleteStoryButton:"Delete story",storyCommentsLabel:"Comments",commentSubmit:"Comment",storyStatusAria:e=>`Status: ${e}`,newActivityName:"New activity",newStepName:"New step",newMilestoneName:"New milestone",newStoryName:"New story",newStatusName:"New status",newLabelName:"New label"},ja:{renameActivity:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3\u540D\u3092\u5909\u66F4",changeActivityActor:"\u4F53\u9A13\u3059\u308B\u4EBA\u3092\u5909\u66F4",renameStep:"\u30B9\u30C6\u30C3\u30D7\u540D\u3092\u5909\u66F4",reorderStep:"\u30B9\u30C6\u30C3\u30D7\u306E\u9806\u5E8F\u3092\u5909\u66F4",addActivity:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3\u3092\u8FFD\u52A0",addStep:"\u30B9\u30C6\u30C3\u30D7\u3092\u8FFD\u52A0",deleteActivity:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3\u3092\u524A\u9664",deleteStep:"\u30B9\u30C6\u30C3\u30D7\u3092\u524A\u9664",renameStory:"\u30B9\u30C8\u30FC\u30EA\u30FC\u540D\u3092\u5909\u66F4",updateStoryDescription:"\u30B9\u30C8\u30FC\u30EA\u30FC\u306E\u8AAC\u660E\u3092\u66F4\u65B0",changeMilestone:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3\u3092\u5909\u66F4",moveStory:"\u30B9\u30C8\u30FC\u30EA\u30FC\u3092\u79FB\u52D5",reorderStory:"\u30B9\u30C8\u30FC\u30EA\u30FC\u306E\u9806\u5E8F\u3092\u5909\u66F4",addStory:"\u30B9\u30C8\u30FC\u30EA\u30FC\u3092\u8FFD\u52A0",deleteStory:"\u30B9\u30C8\u30FC\u30EA\u30FC\u3092\u524A\u9664",renameMilestone:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3\u540D\u3092\u5909\u66F4",addMilestone:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3\u3092\u8FFD\u52A0",deleteMilestone:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3\u3092\u524A\u9664",reorderMilestone:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3\u306E\u9806\u5E8F\u3092\u5909\u66F4",changeStoryStatus:"\u30B9\u30C8\u30FC\u30EA\u30FC\u306E\u30B9\u30C6\u30FC\u30BF\u30B9\u3092\u5909\u66F4",addStatus:"\u30B9\u30C6\u30FC\u30BF\u30B9\u3092\u8FFD\u52A0",renameStatus:"\u30B9\u30C6\u30FC\u30BF\u30B9\u540D\u3092\u5909\u66F4",changeStatusTone:"\u30B9\u30C6\u30FC\u30BF\u30B9\u306E\u8272\u3092\u5909\u66F4",changeStatusIcon:"\u30B9\u30C6\u30FC\u30BF\u30B9\u306E\u30A2\u30A4\u30B3\u30F3\u3092\u5909\u66F4",addStoryLink:"\u30B9\u30C8\u30FC\u30EA\u30FC\u306B\u30EA\u30F3\u30AF\u3092\u8FFD\u52A0",removeStoryLink:"\u30B9\u30C8\u30FC\u30EA\u30FC\u306E\u30EA\u30F3\u30AF\u3092\u524A\u9664",deleteStatus:"\u30B9\u30C6\u30FC\u30BF\u30B9\u3092\u524A\u9664",reorderStatus:"\u30B9\u30C6\u30FC\u30BF\u30B9\u306E\u9806\u5E8F\u3092\u5909\u66F4",addLabel:"\u30E9\u30D9\u30EB\u3092\u8FFD\u52A0",renameLabel:"\u30E9\u30D9\u30EB\u540D\u3092\u5909\u66F4",changeLabelTone:"\u30E9\u30D9\u30EB\u306E\u8272\u3092\u5909\u66F4",deleteLabel:"\u30E9\u30D9\u30EB\u3092\u524A\u9664",reorderLabel:"\u30E9\u30D9\u30EB\u306E\u9806\u5E8F\u3092\u5909\u66F4",addStoryLabel:"\u30B9\u30C8\u30FC\u30EA\u30FC\u306B\u30E9\u30D9\u30EB\u3092\u4ED8\u4E0E",removeStoryLabel:"\u30B9\u30C8\u30FC\u30EA\u30FC\u306E\u30E9\u30D9\u30EB\u3092\u5916\u3059",toValue:e=>`\u2192 \u300C${e}\u300D`,fromTo:(e,t)=>`\u300C${e}\u300D\u2192\u300C${t}\u300D`,added:e=>`+ \u300C${e}\u300D`,removed:e=>`\u2212 \u300C${e}\u300D`,toFront:"\u2192 \u5148\u982D\u3078",afterName:e=>`\u2192 \u300C${e}\u300D\u306E\u76F4\u5F8C\u3078`,toUnassigned:"\u2192 \u672A\u5272\u5F53\u3078",toName:e=>`\u2192 ${e}`,activityGroup:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3",stepGroup:"\u30B9\u30C6\u30C3\u30D7",storyGroup:"\u30B9\u30C8\u30FC\u30EA\u30FC",milestoneGroup:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3",statusGroup:"\u30B9\u30C6\u30FC\u30BF\u30B9",labelGroup:"\u30E9\u30D9\u30EB",mapGroup:"\u30DE\u30C3\u30D7",targetLabel:(e,t)=>`${e} \xB7 ${t}`,targetMissing:(e,t)=>`${e} \xB7 ${t} (missing)`,wholeMap:"\u30DE\u30C3\u30D7\u5168\u4F53",unassigned:"\u672A\u5272\u5F53",emptyTitle:"\u30D0\u30C3\u30AF\u30DC\u30FC\u30F3\u304C\u307E\u3060\u3042\u308A\u307E\u305B\u3093",emptyBody:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3\u3068\u30B9\u30C6\u30C3\u30D7\u3092\u8FFD\u52A0\u3059\u308B\u3068\u3001\u3053\u3053\u306B\u30B9\u30C8\u30FC\u30EA\u30FC\u30DE\u30C3\u30D7\u304C\u73FE\u308C\u307E\u3059\u3002",firstActivityButton:"+ \u6700\u521D\u306E\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3",groupingLabel:"\u307E\u3068\u3081\u308B\u5358\u4F4D",groupViewTab:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3\u30B0\u30EB\u30FC\u30D7",groupAxisHeader:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3\u30B0\u30EB\u30FC\u30D7 \u2192",activityAxis:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3 \u2192",milestoneAxis:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3 \u2193",stepNameLabel:"\u30B9\u30C6\u30C3\u30D7\u540D",activityNameLabel:"\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3\u540D",milestoneNameLabel:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3\u540D",addStepAria:"\u3053\u306E\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3\u306B\u30B9\u30C6\u30C3\u30D7\u3092\u8FFD\u52A0",newActivityButton:"+ \u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3",newMilestoneButton:"+ \u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3",addCellButton:"+ \u8FFD\u52A0",addStoryCellAria:"\u3053\u306E\u30DE\u30B9\u306B\u30B9\u30C8\u30FC\u30EA\u30FC\u3092\u8FFD\u52A0",storyCount:e=>`${e} \u30B9\u30C8\u30FC\u30EA\u30FC`,pageTabsLabel:"\u30DA\u30FC\u30B8",mapTab:"User Story Mapping",milestonesTab:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3",statusesTab:"\u30B9\u30C6\u30FC\u30BF\u30B9",labelsTab:"\u30E9\u30D9\u30EB",shareOfStories:e=>`\u5168\u30B9\u30C8\u30FC\u30EA\u30FC\u306E ${e}%`,coverageLabel:"\u30D0\u30C3\u30AF\u30DC\u30FC\u30F3\u306E\u7DB2\u7F85",coverage:(e,t)=>`${e} / ${t} \u30B9\u30C6\u30C3\u30D7`,storiesLabel:"\u30B9\u30C8\u30FC\u30EA\u30FC",timeframeUnset:"\u6642\u671F\u672A\u5B9A",milestoneNoDescription:"\u8AAC\u660E\u306F\u307E\u3060\u3042\u308A\u307E\u305B\u3093\u3002",noMilestonesTitle:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3\u304C\u307E\u3060\u3042\u308A\u307E\u305B\u3093",noMilestonesBody:"\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3\u3092\u8FFD\u52A0\u3059\u308B\u3068\u3001\u30DE\u30C3\u30D7\u3092\u30EA\u30EA\u30FC\u30B9\u3054\u3068\u306B\u533A\u5207\u308C\u307E\u3059\u3002",commentCountAria:e=>`\u30B3\u30E1\u30F3\u30C8 ${e} \u4EF6`,statusNameLabel:"\u30B9\u30C6\u30FC\u30BF\u30B9\u540D",statusToneLabel:"\u8272",toneName:e=>({gray:"\u30B0\u30EC\u30FC",blue:"\u9752",violet:"\u7D2B",green:"\u7DD1",amber:"\u9EC4",accent:"\u30AA\u30EC\u30F3\u30B8"})[e],statusIconLabel:"\u30A2\u30A4\u30B3\u30F3",iconName:e=>({progress:"\u9032\u6357\u30EA\u30F3\u30B0",circle:"\u5186",lightbulb:"\u96FB\u7403",flag:"\u65D7",play:"\u518D\u751F",clock:"\u6642\u8A08",eye:"\u76EE",pause:"\u4E00\u6642\u505C\u6B62",check:"\u30C1\u30A7\u30C3\u30AF",x:"\u30D0\u30C4"})[e],statusShare:(e,t)=>`${e} \u30B9\u30C8\u30FC\u30EA\u30FC \xB7 ${t}%`,statusFilterLabel:"\u30B9\u30C6\u30FC\u30BF\u30B9",clearFilter:"\u30AF\u30EA\u30A2",progressAria:e=>`\u9032\u307F\u5177\u5408: ${e}`,activityActorLabel:"\u8AB0\u306E\u4F53\u9A13",noStatusesTitle:"\u30B9\u30C6\u30FC\u30BF\u30B9\u304C\u307E\u3060\u3042\u308A\u307E\u305B\u3093",noStatusesBody:"Idea / Ready / Done \u306E\u3088\u3046\u306A\u30B9\u30C6\u30FC\u30BF\u30B9\u3092\u8FFD\u52A0\u3059\u308B\u3068\u3001\u30DE\u30C3\u30D7\u306E\u30AB\u30FC\u30C9\u304C\u9032\u307F\u5177\u5408\u3067\u8272\u5206\u3051\u3055\u308C\u307E\u3059\u3002",newStatusButton:"+ \u30B9\u30C6\u30FC\u30BF\u30B9",moveUpAria:"\u4E0A\u3078\u79FB\u52D5",moveDownAria:"\u4E0B\u3078\u79FB\u52D5",deleteStatusAria:"\u3053\u306E\u30B9\u30C6\u30FC\u30BF\u30B9\u3092\u524A\u9664",labelNameLabel:"\u30E9\u30D9\u30EB\u540D",noLabelsTitle:"\u30E9\u30D9\u30EB\u304C\u307E\u3060\u3042\u308A\u307E\u305B\u3093",noLabelsBody:"Dev / PdM \u306E\u3088\u3046\u306A\u30E9\u30D9\u30EB\u3092\u8FFD\u52A0\u3059\u308B\u3068\u3001\u30C1\u30FC\u30E0\u306E\u904B\u7528\u306B\u5408\u308F\u305B\u3066\u30B9\u30C8\u30FC\u30EA\u30FC\u3092\u533A\u5206\u3051\u3067\u304D\u307E\u3059\u3002\u30E9\u30D9\u30EB\u306E\u610F\u5473\u306F\u4ED5\u7D44\u307F\u5074\u3067\u306F\u6C7A\u3081\u307E\u305B\u3093\u3002",newLabelButton:"+ \u30E9\u30D9\u30EB",deleteLabelAria:"\u3053\u306E\u30E9\u30D9\u30EB\u3092\u524A\u9664",moveDialogLabel:"\u79FB\u52D5\u5148\u306E\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3",moveDialogSelectLabel:"\u79FB\u52D5\u5148",moveConfirm:"\u79FB\u52D5\u3059\u308B",moveCancel:"\u30AD\u30E3\u30F3\u30BB\u30EB",storyStatusLabel:"\u30B9\u30C6\u30FC\u30BF\u30B9",panelLabel:e=>`\u30B9\u30C8\u30FC\u30EA\u30FC: ${e}`,closePanelAria:"\u9589\u3058\u308B",storyTitleLabel:"\u30BF\u30A4\u30C8\u30EB",storyDescriptionLabel:"\u8AAC\u660E",storyLinksLabel:"\u30EA\u30F3\u30AF",storyLabelsLabel:"\u30E9\u30D9\u30EB",storyNoLabels:"\u30E9\u30D9\u30EB\u306F\u307E\u3060\u3042\u308A\u307E\u305B\u3093\u3002",manageLabels:"\u30E9\u30D9\u30EB\u3092\u7BA1\u7406",linkUrlLabel:"URL",addLinkButton:"\u8FFD\u52A0",removeLinkAria:e=>`${e} \u3092\u5916\u3059`,deleteStoryButton:"\u30B9\u30C8\u30FC\u30EA\u30FC\u3092\u524A\u9664",storyCommentsLabel:"\u30B3\u30E1\u30F3\u30C8",commentSubmit:"\u30B3\u30E1\u30F3\u30C8\u3059\u308B",storyStatusAria:e=>`\u30B9\u30C6\u30FC\u30BF\u30B9: ${e}`,newActivityName:"\u65B0\u3057\u3044\u30A2\u30AF\u30C6\u30A3\u30D3\u30C6\u30A3",newStepName:"\u65B0\u3057\u3044\u30B9\u30C6\u30C3\u30D7",newMilestoneName:"\u65B0\u3057\u3044\u30DE\u30A4\u30EB\u30B9\u30C8\u30FC\u30F3",newStoryName:"\u65B0\u3057\u3044\u30B9\u30C8\u30FC\u30EA\u30FC",newStatusName:"\u65B0\u3057\u3044\u30B9\u30C6\u30FC\u30BF\u30B9",newLabelName:"\u65B0\u3057\u3044\u30E9\u30D9\u30EB"}}),ge=/^[A-Z][A-Z0-9]+-\d+$/,Ie=e=>{let t=e;try{t=decodeURIComponent(e)}catch{}return t.replace(/[-_+]+/g," ").trim()},ma=(e,t)=>{if(e!=="github.com")return null;const[a,s,i,n]=t;if(a===void 0)return{kind:"github",text:"GitHub",title:"github.com"};if(s===void 0)return{kind:"github",text:a,title:a};const r=`${a}/${s}`;return(i==="issues"||i==="pull"||i==="discussions")&&n&&/^\d+$/.test(n)?{kind:"github",text:`#${n}`,title:`${r}#${n}`}:i==="commit"&&n?{kind:"github",text:n.slice(0,7),title:`${r}@${n}`}:{kind:"github",text:r,title:r}},ga=(e,t)=>{if(e!=="gitlab.com")return null;const a=t.indexOf("-"),s=(a<0?t:t.slice(0,a)).join("/"),i=a<0?void 0:t[a+1],n=a<0?void 0:t[a+2];if(n&&/^\d+$/.test(n)){if(i==="issues")return{kind:"gitlab",text:`#${n}`,title:`${s}#${n}`};if(i==="merge_requests")return{kind:"gitlab",text:`!${n}`,title:`${s}!${n}`}}return{kind:"gitlab",text:s||"GitLab",title:s||e}},ha=(e,t,a)=>{if(!t.endsWith(".atlassian.net")&&!t.startsWith("jira."))return null;const s=(a[0]==="browse"?a[1]:void 0)??e.searchParams.get("selectedIssue")??a.find(i=>ge.test(i));return s&&ge.test(s)?{kind:"jira",text:s,title:`${t} ${s}`}:{kind:"jira",text:"Jira",title:t}},ba=(e,t)=>{if(e!=="linear.app")return null;const a=t[1]==="issue"?t[2]?.toUpperCase():void 0;return a&&ge.test(a)?{kind:"linear",text:a,title:a}:{kind:"linear",text:"Linear",title:e}},va=(e,t)=>{if(e!=="figma.com")return null;const[a,,s]=t;if((a==="file"||a==="design"||a==="proto"||a==="board")&&s){const i=Ie(s);return{kind:"figma",text:i,title:i}}return{kind:"figma",text:"Figma",title:e}},fa=(e,t)=>{if(e!=="notion.so"&&!e.endsWith(".notion.site"))return null;const s=(t.at(-1)??"").replace(/-?[0-9a-f]{32}$/i,""),i=s===""?"Notion":Ie(s);return{kind:"notion",text:i,title:i}},ie=e=>{let t;try{t=new URL(e)}catch{return{kind:"web",text:e,title:e}}const a=t.hostname.replace(/^www\./,""),s=t.pathname.split("/").filter(i=>i!=="");return ma(a,s)??ga(a,s)??ha(t,a,s)??ba(a,s)??va(a,s)??fa(a,s)??{kind:"web",text:a,title:e}},Re=e=>{const t=e.tab;return t==="milestones"||t==="statuses"||t==="labels"?t:"map"},ne=e=>{const t=e.statuses.length-1;return e.statuses.map((a,s)=>({id:a.id,name:a.name,tone:a.tone,icon:a.icon,progress:t<=0?1:s/t}))},Oe=(e,t)=>e.find(a=>a.id===t.statusId),De=(e,t)=>ne(e).map(a=>({...a,count:t.filter(s=>s.statusId===a.id).length})).filter(a=>a.count>0),re=(e,t)=>{const a=t.status;if(a===void 0||a==="")return new Set;const s=new Set(a.split(","));return new Set(e.statuses.map(i=>i.id).filter(i=>s.has(i)))},Me=(e,t)=>{const a=e.statuses.map(s=>s.id).filter(s=>t.has(s));return a.length===0?null:a.join(",")},ya=(e,t)=>{const a=new Set(e);return a.has(t)?a.delete(t):a.add(t),a},Ne=(e,t)=>e.size===0?!0:t.statusId!==void 0&&e.has(t.statusId),C=(e,t,a)=>{const s=typeof a=="string"?a:"",i=typeof t=="string"?t:void 0;return i===void 0?e.toValue(s):e.fromTo(i,s)},J=(e,t)=>typeof t=="string"?e.afterName(t):e.toFront,ka={SET_ACTIVITY_NAME:(e,t,a)=>({title:e.renameActivity,tone:"update",body:C(e,U(a,t.target.id)?.name,y(h.SET_ACTIVITY_NAME,t).name??"")}),SET_ACTIVITY_ACTOR:(e,t,a)=>{const s=y(h.SET_ACTIVITY_ACTOR,t).actor.trim();return{title:e.changeActivityActor,tone:"update",body:s===""?e.removed(U(a,t.target.id)?.actor??""):C(e,U(a,t.target.id)?.actor,s)}},SET_STEP_NAME:(e,t,a)=>({title:e.renameStep,tone:"update",body:C(e,$(a,t.target.id)?.step.name,y(h.SET_STEP_NAME,t).name??"")}),REORDER_STEP:(e,t)=>({title:e.reorderStep,tone:"move",body:J(e,y(h.REORDER_STEP,t).after)}),ADD_ACTIVITY:(e,t)=>({title:e.addActivity,tone:"create",body:e.added(String(y(h.ADD_ACTIVITY,t).name??""))}),ADD_STEP:(e,t)=>({title:e.addStep,tone:"create",body:e.added(String(y(h.ADD_STEP,t).name??""))}),DELETE_ACTIVITY:(e,t,a)=>({title:e.deleteActivity,tone:"delete",body:e.removed(U(a,t.target.id)?.name??t.target.id)}),DELETE_STEP:(e,t,a)=>({title:e.deleteStep,tone:"delete",body:e.removed($(a,t.target.id)?.step.name??t.target.id)}),SET_STORY_NAME:(e,t,a)=>({title:e.renameStory,tone:"update",body:C(e,S(a,t.target.id)?.name,y(h.SET_STORY_NAME,t).name??"")}),SET_STORY_DESCRIPTION:(e,t)=>({title:e.updateStoryDescription,tone:"update",body:e.toValue(String(y(h.SET_STORY_DESCRIPTION,t).description??"").slice(0,90))}),SET_STORY_MILESTONE:(e,t,a)=>{const s=y(h.SET_STORY_MILESTONE,t).milestoneId;return{title:e.changeMilestone,tone:"move",body:s==null?e.toUnassigned:e.toName(N(a,String(s))?.name??String(s))}},MOVE_STORY:(e,t,a)=>({title:e.moveStory,tone:"move",body:e.toName($(a,String(y(h.MOVE_STORY,t).stepId))?.step.name??String(y(h.MOVE_STORY,t).stepId??""))}),REORDER_STORY:(e,t)=>({title:e.reorderStory,tone:"move",body:J(e,y(h.REORDER_STORY,t).after)}),ADD_STORY:(e,t)=>({title:e.addStory,tone:"create",body:e.added(String(y(h.ADD_STORY,t).name??""))}),DELETE_STORY:(e,t,a)=>({title:e.deleteStory,tone:"delete",body:e.removed(S(a,t.target.id)?.name??t.target.id)}),SET_MILESTONE_NAME:(e,t,a)=>({title:e.renameMilestone,tone:"update",body:C(e,N(a,t.target.id)?.name,y(h.SET_MILESTONE_NAME,t).name??"")}),ADD_MILESTONE:(e,t)=>({title:e.addMilestone,tone:"create",body:e.added(String(y(h.ADD_MILESTONE,t).name??""))}),DELETE_MILESTONE:(e,t,a)=>({title:e.deleteMilestone,tone:"delete",body:e.removed(N(a,t.target.id)?.name??t.target.id)}),REORDER_MILESTONE:(e,t)=>({title:e.reorderMilestone,tone:"move",body:J(e,y(h.REORDER_MILESTONE,t).after)}),ADD_STORY_LINK:(e,t)=>{const{url:a,label:s}=y(h.ADD_STORY_LINK,t);return{title:e.addStoryLink,tone:"create",body:e.added(s??ie(a).title)}},REMOVE_STORY_LINK:(e,t,a)=>{const{url:s}=y(h.REMOVE_STORY_LINK,t),i=S(a,t.target.id)?.links?.find(n=>n.url===s);return{title:e.removeStoryLink,tone:"delete",body:e.removed(i?.label??ie(s).title)}},SET_STORY_STATUS:(e,t,a)=>{const s=y(h.SET_STORY_STATUS,t).statusId;return{title:e.changeStoryStatus,tone:"update",body:e.toName(_(a,s)?.name??s)}},ADD_STATUS:(e,t)=>({title:e.addStatus,tone:"create",body:e.added(y(h.ADD_STATUS,t).name)}),SET_STATUS_NAME:(e,t,a)=>({title:e.renameStatus,tone:"update",body:C(e,_(a,t.target.id)?.name,y(h.SET_STATUS_NAME,t).name)}),SET_STATUS_TONE:(e,t,a)=>{const s=_(a,t.target.id)?.tone,i=y(h.SET_STATUS_TONE,t).tone;return{title:e.changeStatusTone,tone:"update",body:C(e,s===void 0?void 0:e.toneName(s),e.toneName(i))}},SET_STATUS_ICON:(e,t,a)=>{const s=_(a,t.target.id)?.icon,i=y(h.SET_STATUS_ICON,t).icon;return{title:e.changeStatusIcon,tone:"update",body:C(e,s===void 0?void 0:e.iconName(s),e.iconName(i))}},DELETE_STATUS:(e,t,a)=>({title:e.deleteStatus,tone:"delete",body:e.removed(_(a,t.target.id)?.name??t.target.id)}),REORDER_STATUS:(e,t)=>({title:e.reorderStatus,tone:"move",body:J(e,y(h.REORDER_STATUS,t).after)}),ADD_LABEL:(e,t)=>({title:e.addLabel,tone:"create",body:e.added(y(h.ADD_LABEL,t).name)}),SET_LABEL_NAME:(e,t,a)=>({title:e.renameLabel,tone:"update",body:C(e,I(a,t.target.id)?.name,y(h.SET_LABEL_NAME,t).name)}),SET_LABEL_TONE:(e,t,a)=>{const s=I(a,t.target.id)?.tone,i=y(h.SET_LABEL_TONE,t).tone;return{title:e.changeLabelTone,tone:"update",body:C(e,s===void 0?void 0:e.toneName(s),e.toneName(i))}},DELETE_LABEL:(e,t,a)=>({title:e.deleteLabel,tone:"delete",body:e.removed(I(a,t.target.id)?.name??t.target.id)}),REORDER_LABEL:(e,t)=>({title:e.reorderLabel,tone:"move",body:J(e,y(h.REORDER_LABEL,t).after)}),ADD_STORY_LABEL:(e,t,a)=>{const s=y(h.ADD_STORY_LABEL,t).labelId;return{title:e.addStoryLabel,tone:"create",body:e.added(I(a,s)?.name??s)}},REMOVE_STORY_LABEL:(e,t,a)=>{const s=y(h.REMOVE_STORY_LABEL,t).labelId;return{title:e.removeStoryLabel,tone:"delete",body:e.removed(I(a,s)?.name??s)}}},Ce=(e,t,a,s)=>{let i;try{const n=ka[t.type];i=n?n(e,t,s??a):{title:t.type,tone:"meta"}}catch{i={title:t.type,tone:"meta"}}return{title:i.title,targetLabel:Ye(e,a,t.target),tone:i.tone,...i.body===void 0?{}:{summary:i.body}}},Be=e=>`${e.type} ${T(e.target)} ${JSON.stringify(e.payload)}`,Ye=(e,t,a)=>{try{switch(a.type){case"activity":{const s=U(t,a.id);return s?e.targetLabel(e.activityGroup,s.name):e.targetMissing(e.activityGroup,a.id)}case"step":{const s=$(t,a.id)?.step;return s?e.targetLabel(e.stepGroup,s.name):e.targetMissing(e.stepGroup,a.id)}case"story":{const s=S(t,a.id);return s?e.targetLabel(e.storyGroup,s.name):e.targetMissing(e.storyGroup,a.id)}case"milestone":{const s=N(t,a.id);return s?e.targetLabel(e.milestoneGroup,s.name):e.targetMissing(e.milestoneGroup,a.id)}case"status":{const s=_(t,a.id);return s?e.targetLabel(e.statusGroup,s.name):e.targetMissing(e.statusGroup,a.id)}case"label":{const s=I(t,a.id);return s?e.targetLabel(e.labelGroup,s.name):e.targetMissing(e.labelGroup,a.id)}case"page":return e.targetLabel(e.mapGroup,he(t));default:return`${a.type} \xB7 ${a.id}`}}catch{return`${a.type} \xB7 ${a.id}`}},Ue=(e,t,a)=>{const s=[{value:"page:usm",label:e.wholeMap,group:e.mapGroup}];for(const i of t.activities){s.push({value:T({type:"activity",id:i.id}),label:i.name,group:e.activityGroup});for(const n of i.steps)s.push({value:T({type:"step",id:ee(i.id,n.id)}),label:`${i.name} \u203A ${n.name}`,group:e.stepGroup})}for(const i of t.milestones)s.push({value:T({type:"milestone",id:i.id}),label:i.name,group:e.milestoneGroup});for(const i of t.statuses)s.push({value:T({type:"status",id:i.id}),label:i.name,group:e.statusGroup});for(const i of t.labels)s.push({value:T({type:"label",id:i.id}),label:i.name,group:e.labelGroup});for(const i of t.stories)s.push({value:T({type:"story",id:i.id}),label:i.name,group:e.storyGroup});return s},ze=(e,t,a)=>{const s=t.stories.find(i=>i.id===a.story);if(s)return{value:T({type:"story",id:s.id}),label:s.name,group:e.storyGroup};for(const i of t.activities){const n=i.steps.find(r=>r.id===a.step);if(n)return{value:T({type:"step",id:ee(i.id,n.id)}),label:n.name,group:e.stepGroup}}return null},he=e=>e.title??"User Story Mapping",xa=e=>{switch(e.type){case"story":return{tab:null,status:null};case"step":case"activity":return{tab:null,view:null};case"milestone":return{tab:"milestones"};case"status":return{tab:"statuses"};case"label":return{tab:"labels"};default:return null}},Pe=(e,t)=>{const a=$(e,t.step),s=a?.activity??U(e,t.activity)??e.activities[0],i=a?.step??s?.steps.find(c=>c.id===t.step)??s?.steps[0],n=S(e,t.story),r={...t};s?r.activity=s.id:delete r.activity,i?r.step=i.id:delete r.step,n?r.story=n.id:delete r.story,r.view=t.view==="group"?"group":"activity";const o=Me(e,re(e,t));o===null?delete r.status:r.status=o;const p=Re(t);return p==="map"?delete r.tab:r.tab=p,r},Ve=(e,t)=>{switch(t.type){case"activity":return U(e,t.id)!==void 0;case"step":return $(e,t.id)!==void 0;case"story":return S(e,t.id)!==void 0;case"milestone":return N(e,t.id)!==void 0;case"status":return _(e,t.id)!==void 0;case"label":return I(e,t.id)!==void 0;case"page":return!0;default:return!1}},Ge=e=>{const t=se(e);return{name:"usm",label:"User Story Mapping",parseBase:Se,emptyBase:we,actions:h,apply:Ee,canonicalState:pa,hasTarget:Ve,canonicalTarget:(a,s)=>{if(s.type!=="step")return s;const i=$(a,s.id);return i?{...s,id:ee(i.activity.id,i.step.id)}:s},describe:(a,s,i)=>Ce(t,a,s,i),serialize:Be,resolveNavigation:Pe,navigationFor:(a,s)=>xa(s),commentTargets:(a,s)=>Ue(t,a),currentTarget:(a,s)=>ze(t,a,s),title:he}},Sa={github:j`<path fill-rule="evenodd" d="M8 0c4.42 0 8 3.58 8 8a8.013 8.013 0 0 1-5.45 7.59c-.4.08-.55-.17-.55-.38 0-.27.01-1.13.01-2.2 0-.75-.25-1.23-.54-1.48 1.78-.2 3.65-.88 3.65-3.95 0-.88-.31-1.59-.82-2.15.08-.2.36-1.02-.08-2.12 0 0-.67-.22-2.2.82-.64-.18-1.32-.27-2-.27-.68 0-1.36.09-2 .27-1.53-1.03-2.2-.82-2.2-.82-.44 1.1-.16 1.92-.08 2.12-.51.56-.82 1.28-.82 2.15 0 3.06 1.86 3.75 3.64 3.95-.23.2-.44.55-.51 1.07-.46.21-1.61.55-2.33-.66-.15-.24-.6-.83-1.23-.82-.67.01-.27.38.01.53.34.19.73.9.82 1.13.16.45.68 1.31 2.69.94 0 .67.01 1.3.01 1.49 0 .21-.15.45-.55.38A7.995 7.995 0 0 1 0 8c0-4.42 3.58-8 8-8Z"></path>`,gitlab:j`<path d="M8 15 1.2 9.9a.7.7 0 0 1-.25-.78L2.7 2.6a.35.35 0 0 1 .66 0L5.1 7.6h5.8l1.74-5a.35.35 0 0 1 .66 0l1.75 6.52a.7.7 0 0 1-.25.78z"></path>`,jira:j`<path d="M14.6 7.4 8.6 1.4 8 .8 3.5 5.3 1.4 7.4a.85.85 0 0 0 0 1.2l4.1 4.1L8 15.2l4.5-4.5.07-.07 2.03-2.03a.85.85 0 0 0 0-1.2zM8 9.9 5.9 8 8 5.9 10.1 8z"></path>`,linear:j`<path d="M1.2 9.4a6.9 6.9 0 0 0 5.4 5.4zM1 7.3l7.7 7.7a7 7 0 0 0 1.9-.5L1.5 5.4a7 7 0 0 0-.5 1.9zm1.2-3.1 9.6 9.6a7 7 0 0 0 1.2-1.1L3.3 3a7 7 0 0 0-1.1 1.2zM4.3 2.3a7 7 0 1 1 9.4 9.4z"></path>`,figma:j`<path d="M5.5 1h2.3v4.6H5.5a2.3 2.3 0 1 1 0-4.6zm2.3 0h2.3a2.3 2.3 0 1 1 0 4.6H7.8zm2.3 4.6a2.3 2.3 0 1 1 0 4.6 2.3 2.3 0 0 1 0-4.6zM5.5 5.6h2.3v4.6H5.5a2.3 2.3 0 1 1 0-4.6zm0 4.6h2.3v2.3a2.3 2.3 0 1 1-2.3-2.3z"></path>`,notion:j`<path fill-rule="evenodd" d="M2.5 1.6 11 1c1 0 1.3.1 2 .6l2.1 1.5c.4.3.5.4.5.7v9.6c0 .7-.3 1.1-1.1 1.2l-9.4.6c-.6 0-.9-.1-1.2-.5L1.9 12c-.3-.5-.5-.8-.5-1.3V2.8c0-.6.3-1.1 1.1-1.2zM5 4.4v8.9l8.6-.5V4zm1 1.2 2.9-.2 3 4.7V5.6l-.8-.1v-.5l2-.1v.6l-.6.1v6.1l-.9.1-3.5-5.4v4.9l.8.2v.5l-2.3.1v-.5l.6-.2V6.4l-.8-.1z"></path>`},Fe=e=>e==="web"?Et():l`<svg class="link-mark" viewBox="0 0 16 16" aria-hidden="true">${Sa[e]}</svg>`,je=Z`
|
|
2
|
-
.link-mark {
|
|
3
|
-
fill: currentColor;
|
|
4
|
-
}
|
|
5
|
-
.link-chip {
|
|
6
|
-
display: inline-flex;
|
|
7
|
-
align-items: center;
|
|
8
|
-
gap: 5px;
|
|
9
|
-
min-width: 0;
|
|
10
|
-
max-width: 100%;
|
|
11
|
-
padding: 1px 8px 1px 6px;
|
|
12
|
-
border: 1px solid var(--dpk-rule-strong);
|
|
13
|
-
border-radius: 999px;
|
|
14
|
-
background: var(--dpk-paper-raised);
|
|
15
|
-
color: var(--dpk-ink-soft);
|
|
16
|
-
font-family: var(--dpk-mono);
|
|
17
|
-
font-size: 10.5px;
|
|
18
|
-
font-weight: 600;
|
|
19
|
-
line-height: 18px;
|
|
20
|
-
text-decoration: none;
|
|
21
|
-
transition:
|
|
22
|
-
color 140ms var(--dpk-ease),
|
|
23
|
-
border-color 140ms var(--dpk-ease);
|
|
24
|
-
}
|
|
25
|
-
.link-chip:hover {
|
|
26
|
-
border-color: var(--dpk-ink-faint);
|
|
27
|
-
color: var(--dpk-ink);
|
|
28
|
-
}
|
|
29
|
-
.link-chip:focus-visible {
|
|
30
|
-
outline: none;
|
|
31
|
-
box-shadow: var(--dpk-focus);
|
|
32
|
-
}
|
|
33
|
-
.link-chip svg {
|
|
34
|
-
flex: none;
|
|
35
|
-
width: 12px;
|
|
36
|
-
height: 12px;
|
|
37
|
-
}
|
|
38
|
-
.link-chip span {
|
|
39
|
-
overflow: hidden;
|
|
40
|
-
text-overflow: ellipsis;
|
|
41
|
-
white-space: nowrap;
|
|
42
|
-
}
|
|
43
|
-
`,O=e=>`--usm-tone: var(--dpk-${e==null||e==="gray"?"ink-faint":e})`,Ke={circle:M(Xt),lightbulb:M(ea),flag:M(Qt),play:M(Ht),clock:M(Zt),eye:M(Jt),pause:M(qt),check:M(jt),x:M(Wt)},wa=M(Kt),Ta=e=>{if(e>=1)return Ke.check();const t=2*Math.PI*4.5;return l`<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" aria-hidden="true">
|
|
44
|
-
<circle cx="12" cy="12" r="10"></circle>
|
|
45
|
-
${e>0?j`<circle
|
|
46
|
-
class="si-pie"
|
|
47
|
-
cx="12"
|
|
48
|
-
cy="12"
|
|
49
|
-
r="4.5"
|
|
50
|
-
stroke-dasharray=${`${e*t} ${t}`}
|
|
51
|
-
transform="rotate(-90 12 12)"
|
|
52
|
-
></circle>`:v}
|
|
53
|
-
</svg>`},W=e=>{const t=e===void 0?wa():e.icon==="progress"?Ta(e.progress??1):Ke[e.icon]();return l`<span class="status-icon">${t}</span>`},qe=(e,t)=>e.length===0?v:l`<span class="status-bar" role="img" aria-label=${t}>
|
|
54
|
-
${e.map(a=>l`<span
|
|
55
|
-
class="status-bar-part"
|
|
56
|
-
data-status=${a.id}
|
|
57
|
-
title=${`${a.name}: ${a.count}`}
|
|
58
|
-
style=${`${O(a.tone)};flex-grow:${a.count}`}
|
|
59
|
-
></span>`)}
|
|
60
|
-
</span>`,He=Z`
|
|
61
|
-
.status-icon {
|
|
62
|
-
display: block;
|
|
63
|
-
flex: none;
|
|
64
|
-
width: 16px;
|
|
65
|
-
height: 16px;
|
|
66
|
-
color: var(--usm-tone);
|
|
67
|
-
}
|
|
68
|
-
.status-icon svg {
|
|
69
|
-
display: block;
|
|
70
|
-
width: 100%;
|
|
71
|
-
height: 100%;
|
|
72
|
-
}
|
|
73
|
-
.status-icon .si-pie {
|
|
74
|
-
stroke-width: 9;
|
|
75
|
-
}
|
|
76
|
-
.status-bar {
|
|
77
|
-
display: flex;
|
|
78
|
-
gap: 2px;
|
|
79
|
-
height: 6px;
|
|
80
|
-
min-width: 0;
|
|
81
|
-
}
|
|
82
|
-
.status-bar-part {
|
|
83
|
-
min-width: 4px;
|
|
84
|
-
border-radius: 3px;
|
|
85
|
-
background: var(--usm-tone);
|
|
86
|
-
}
|
|
87
|
-
.status-bar-part[data-status=''] {
|
|
88
|
-
background: color-mix(in srgb, var(--dpk-ink-faint) 30%, transparent);
|
|
89
|
-
}
|
|
90
|
-
`,$a=3,Ea=Z`
|
|
91
|
-
/*
|
|
92
|
-
* The card wears its status's color the way a modern board does: a flat,
|
|
93
|
-
* barely tinted face and a hairline edge in that hue, with a neutral, soft
|
|
94
|
-
* elevation. Tints are mixed in OKLab so every hue stays clean instead of
|
|
95
|
-
* turning muddy.
|
|
96
|
-
*/
|
|
97
|
-
:host {
|
|
98
|
-
--card-tone: var(--usm-tone, var(--dpk-ink-faint));
|
|
99
|
-
position: relative;
|
|
100
|
-
display: grid;
|
|
101
|
-
gap: 8px;
|
|
102
|
-
padding: 12px 13px;
|
|
103
|
-
border: 1px solid color-mix(in oklab, var(--card-tone) 24%, var(--dpk-rule));
|
|
104
|
-
border-radius: 12px;
|
|
105
|
-
background: color-mix(in oklab, var(--card-tone) 6%, var(--dpk-paper-raised));
|
|
106
|
-
box-shadow:
|
|
107
|
-
0 1px 1px var(--dpk-shade-1),
|
|
108
|
-
0 2px 6px -3px var(--dpk-shade-2);
|
|
109
|
-
cursor: pointer;
|
|
110
|
-
transition:
|
|
111
|
-
box-shadow 180ms var(--dpk-ease),
|
|
112
|
-
transform 180ms var(--dpk-ease),
|
|
113
|
-
border-color 180ms var(--dpk-ease);
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
:host(:hover) {
|
|
117
|
-
border-color: color-mix(in oklab, var(--card-tone) 45%, var(--dpk-rule));
|
|
118
|
-
box-shadow:
|
|
119
|
-
0 1px 2px var(--dpk-shade-1),
|
|
120
|
-
0 8px 20px -10px var(--dpk-shade-3);
|
|
121
|
-
transform: translateY(-1px);
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
:host([focused]) {
|
|
125
|
-
border-color: var(--dpk-blue);
|
|
126
|
-
box-shadow:
|
|
127
|
-
0 0 0 3px color-mix(in oklab, var(--dpk-blue) 20%, transparent),
|
|
128
|
-
0 8px 20px -10px var(--dpk-shade-3);
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
/* The card is the button that opens its story; the keyboard ring is the focused look. */
|
|
132
|
-
:host(:focus-visible) {
|
|
133
|
-
outline: none;
|
|
134
|
-
border-color: var(--dpk-blue);
|
|
135
|
-
box-shadow: var(--dpk-focus);
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
:host([dragging]) {
|
|
139
|
-
opacity: 0.45;
|
|
140
|
-
transform: none;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
.card-head {
|
|
144
|
-
display: flex;
|
|
145
|
-
align-items: flex-start;
|
|
146
|
-
gap: 8px;
|
|
147
|
-
min-width: 0;
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
.card-status {
|
|
151
|
-
flex: none;
|
|
152
|
-
display: inline-flex;
|
|
153
|
-
margin-top: 1.5px;
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
.card-name {
|
|
157
|
-
flex: 1 1 auto;
|
|
158
|
-
min-width: 0;
|
|
159
|
-
color: var(--dpk-ink);
|
|
160
|
-
font-size: 13px;
|
|
161
|
-
font-weight: 600;
|
|
162
|
-
letter-spacing: -0.01em;
|
|
163
|
-
line-height: 1.45;
|
|
164
|
-
overflow-wrap: anywhere;
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
/* The description, rendered from Markdown and cut after three lines. */
|
|
168
|
-
.card-text {
|
|
169
|
-
display: -webkit-box;
|
|
170
|
-
-webkit-box-orient: vertical;
|
|
171
|
-
-webkit-line-clamp: 3;
|
|
172
|
-
overflow: hidden;
|
|
173
|
-
color: var(--dpk-ink-soft);
|
|
174
|
-
font-size: 12px;
|
|
175
|
-
line-height: 1.55;
|
|
176
|
-
overflow-wrap: anywhere;
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
.card-text > * {
|
|
180
|
-
margin: 0;
|
|
181
|
-
}
|
|
182
|
-
|
|
183
|
-
/* A heading in the description reads as a line of the preview, not a title over the card. */
|
|
184
|
-
.card-text :is(h1, h2, h3, h4, h5, h6) {
|
|
185
|
-
font-size: inherit;
|
|
186
|
-
font-weight: 650;
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
.card-text ul,
|
|
190
|
-
.card-text ol {
|
|
191
|
-
padding-left: 1.2em;
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
.card-text code {
|
|
195
|
-
padding: 0 3px;
|
|
196
|
-
border-radius: 4px;
|
|
197
|
-
background: var(--dpk-paper-inset);
|
|
198
|
-
font-family: var(--dpk-mono);
|
|
199
|
-
font-size: 0.92em;
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
.card-text a {
|
|
203
|
-
color: var(--dpk-blue);
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
/* Where the story sits and what was said about it. */
|
|
207
|
-
.card-foot {
|
|
208
|
-
display: flex;
|
|
209
|
-
align-items: center;
|
|
210
|
-
gap: 6px;
|
|
211
|
-
min-width: 0;
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
.card-chip {
|
|
215
|
-
display: inline-flex;
|
|
216
|
-
align-items: center;
|
|
217
|
-
gap: 4px;
|
|
218
|
-
min-width: 0;
|
|
219
|
-
padding: 1px 7px;
|
|
220
|
-
border-radius: 6px;
|
|
221
|
-
background: color-mix(in oklab, var(--card-tone) 10%, var(--dpk-paper-sunken));
|
|
222
|
-
color: var(--dpk-ink-soft);
|
|
223
|
-
font-size: 10.5px;
|
|
224
|
-
font-weight: 600;
|
|
225
|
-
line-height: 18px;
|
|
226
|
-
}
|
|
227
|
-
|
|
228
|
-
.card-chip span {
|
|
229
|
-
overflow: hidden;
|
|
230
|
-
text-overflow: ellipsis;
|
|
231
|
-
white-space: nowrap;
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
.card-chip[data-kind='comments'] {
|
|
235
|
-
margin-left: auto;
|
|
236
|
-
background: transparent;
|
|
237
|
-
color: var(--dpk-ink-faint);
|
|
238
|
-
font-family: var(--dpk-mono);
|
|
239
|
-
font-variant-numeric: tabular-nums;
|
|
240
|
-
}
|
|
241
|
-
|
|
242
|
-
.card-chip svg {
|
|
243
|
-
flex: none;
|
|
244
|
-
width: 12px;
|
|
245
|
-
height: 12px;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
/* The labels the story carries, each in its own color. */
|
|
249
|
-
.card-labels {
|
|
250
|
-
display: flex;
|
|
251
|
-
flex-wrap: wrap;
|
|
252
|
-
gap: 4px;
|
|
253
|
-
min-width: 0;
|
|
254
|
-
}
|
|
255
|
-
|
|
256
|
-
.label-chip {
|
|
257
|
-
display: inline-flex;
|
|
258
|
-
align-items: center;
|
|
259
|
-
gap: 5px;
|
|
260
|
-
min-width: 0;
|
|
261
|
-
max-width: 100%;
|
|
262
|
-
padding: 0 7px;
|
|
263
|
-
border: 1px solid color-mix(in oklab, var(--usm-tone) 35%, transparent);
|
|
264
|
-
border-radius: 999px;
|
|
265
|
-
background: color-mix(in oklab, var(--usm-tone) 12%, var(--dpk-paper-raised));
|
|
266
|
-
color: var(--dpk-ink);
|
|
267
|
-
font-size: 10.5px;
|
|
268
|
-
font-weight: 600;
|
|
269
|
-
line-height: 17px;
|
|
270
|
-
overflow: hidden;
|
|
271
|
-
text-overflow: ellipsis;
|
|
272
|
-
white-space: nowrap;
|
|
273
|
-
}
|
|
274
|
-
|
|
275
|
-
.label-chip::before {
|
|
276
|
-
content: '';
|
|
277
|
-
flex: none;
|
|
278
|
-
width: 6px;
|
|
279
|
-
height: 6px;
|
|
280
|
-
border-radius: 50%;
|
|
281
|
-
background: var(--usm-tone);
|
|
282
|
-
}
|
|
283
|
-
|
|
284
|
-
.card-links {
|
|
285
|
-
display: flex;
|
|
286
|
-
flex-wrap: wrap;
|
|
287
|
-
gap: 4px;
|
|
288
|
-
min-width: 0;
|
|
289
|
-
}
|
|
290
|
-
|
|
291
|
-
.card-links .link-chip {
|
|
292
|
-
border-color: color-mix(in oklab, var(--card-tone) 16%, var(--dpk-rule));
|
|
293
|
-
background: var(--dpk-paper-raised);
|
|
294
|
-
}
|
|
295
|
-
`;class La extends Lt{static{this.styles=[At,He,je,Ea]}static{this.properties={story:{attribute:!1},stepName:{attribute:!1},statuses:{attribute:!1},labels:{attribute:!1},notes:{attribute:!1},focused:{type:Boolean,reflect:!0},dragging:{type:Boolean,reflect:!0}}}#a=new _t(this);constructor(){super(),this.story=null,this.stepName="",this.statuses=[],this.labels=[],this.notes=[],this.focused=!1,this.dragging=!1}render(){const t=this.story;if(!t)return v;const a=se(this.#a.locale),s=this.stepName!==""||this.notes.length>0;return l`
|
|
296
|
-
<div class="card-head">
|
|
297
|
-
${this.statuses.length===0?v:this.#e(a,t)}
|
|
298
|
-
<div class="card-name"><span>${t.name}</span></div>
|
|
299
|
-
</div>
|
|
300
|
-
${t.description?l`<div class="card-text" @click=${_a}>${It(Rt(t.description))}</div>`:v}
|
|
301
|
-
${this.labels.length>0?Aa(this.labels):v}
|
|
302
|
-
${t.links&&t.links.length>0?this.#t(t.links):v}
|
|
303
|
-
${s?l`<div class="card-foot">
|
|
304
|
-
${this.stepName===""?v:l`<span class="card-chip" data-kind="step"><span>${this.stepName}</span></span>`}
|
|
305
|
-
${this.notes.length>0?l`<span
|
|
306
|
-
class="card-chip"
|
|
307
|
-
data-kind="comments"
|
|
308
|
-
aria-label=${a.commentCountAria(this.notes.length)}
|
|
309
|
-
>
|
|
310
|
-
${Ot()}<span>${this.notes.length}</span>
|
|
311
|
-
</span>`:v}
|
|
312
|
-
</div>`:v}
|
|
313
|
-
`}#e(t,a){const s=Oe(this.statuses,a);if(!s)return v;const i=s.name;return l`<span class="card-status" role="img" aria-label=${t.storyStatusAria(i)} title=${i}>
|
|
314
|
-
${W(s)}
|
|
315
|
-
</span>`}#t(t){const a=t.slice(0,$a);return l`<div class="card-links">
|
|
316
|
-
${a.map(s=>{const i=ie(s.url);return l`<a
|
|
317
|
-
class="link-chip"
|
|
318
|
-
data-kind=${i.kind}
|
|
319
|
-
href=${s.url}
|
|
320
|
-
target="_blank"
|
|
321
|
-
rel="noopener noreferrer"
|
|
322
|
-
title=${s.label??i.title}
|
|
323
|
-
draggable="false"
|
|
324
|
-
tabindex="-1"
|
|
325
|
-
@click=${n=>n.stopPropagation()}
|
|
326
|
-
>${Fe(i.kind)}<span>${s.label??i.text}</span></a
|
|
327
|
-
>`})}
|
|
328
|
-
${t.length>a.length?l`<span class="link-chip">+${t.length-a.length}</span>`:v}
|
|
329
|
-
</div>`}}const Aa=e=>l`<div class="card-labels">
|
|
330
|
-
${e.map(t=>l`<span class="label-chip" data-label=${t.id} style=${O(t.tone)}>${t.name}</span>`)}
|
|
331
|
-
</div>`,_a=e=>{e.target instanceof Element&&e.target.closest("a")&&e.stopPropagation()},Ia=()=>{customElements.get("dpk-internal-usm-story-card")||customElements.define("dpk-internal-usm-story-card",La)},Ra=(e,t,a)=>{const s=e.at(-1)??null;if(t===null||a==="end")return s;const i=e.indexOf(t);return i<0?s:a==="after"?t:i===0?null:e.at(i-1)??null},We=(e,t,a,s,i)=>{const n=te(e,t.stepId,t.milestoneId).map(r=>r.id);return{type:"MOVE_STORY",target:{type:"story",id:a},payload:{activityId:t.activityId,stepId:t.stepId,milestoneId:t.milestoneId??null,after:le(n,a,s,i)}}},Xe=(e,t,a,s,i,n)=>{const r=S(e,s);if(!r||r.activityId!==t)return null;const o=Te(e,t,a).map(p=>p.id);return{type:"MOVE_STORY",target:{type:"story",id:s},payload:{activityId:t,stepId:r.stepId,milestoneId:a??null,after:le(o,s,i,n)}}},Ze=(e,t,a,s,i)=>{const n=te(e,s,i).filter(r=>r.id!==t);return{type:"MOVE_STORY",target:{type:"story",id:t},payload:{activityId:a,stepId:s,milestoneId:i??null,after:n.at(-1)?.id??null}}},Je=(e,t,a,s)=>e.includes(t)?{type:"REORDER_MILESTONE",target:{type:"milestone",id:t},payload:{after:le(e,t,a,s)}}:null,Oa=e=>{const t=e.stories.length;return{rows:e.labels.map((s,i)=>{const n=e.stories.filter(r=>r.labelIds?.includes(s.id)).length;return{id:s.id,name:s.name,tone:s.tone,previousId:e.labels[i-1]?.id??null,nextId:e.labels[i+1]?.id??null,storyCount:n,share:t===0?0:n/t}})}},Da=e=>{const t=e.stories.length,a=ue(e);return e.milestones.map((s,i)=>{const n=e.stories.filter(o=>o.milestoneId===s.id),r=new Set(n.map(o=>o.stepId));return{id:s.id,ordinal:i+1,name:s.name,timeframe:s.timeframe?.trim()??"",description:s.description?.trim()??"",storyCount:n.length,share:t===0?0:n.length/t,coverage:{covered:a.filter(({step:o})=>r.has(o.id)).length,total:a.length},progress:De(e,n)}})},Qe=(e,t)=>{const a=K("new-activity",G(t.state));if(!t.dispatch({type:"ADD_ACTIVITY",target:{type:"page",id:"usm"},payload:{id:a,name:e.newActivityName}}).ok)return;const i=K("new-step",[...G(t.state),a]);t.dispatch({type:"ADD_STEP",target:{type:"activity",id:a},payload:{id:i,name:e.newStepName}}),t.navigate({activity:a,step:null,story:null})},Ma=(e,t,a)=>{const s=K("new-step",G(t.state));t.dispatch({type:"ADD_STEP",target:{type:"activity",id:a},payload:{id:s,name:e.newStepName}})},et=(e,t)=>{const a=K("new-milestone",G(t.state));t.dispatch({type:"ADD_MILESTONE",target:{type:"page",id:"usm"},payload:{id:a,name:e.newMilestoneName}})},tt=(e,t,a,s,i)=>{const n=K("new-story",G(t.state));t.dispatch({type:"ADD_STORY",target:{type:"step",id:s},payload:{id:n,name:e.newStoryName,activityId:a,...i===void 0?{}:{milestoneId:i}}}).ok&&t.navigate({activity:a,step:s,story:n})},Na=(e,t)=>{const a=K("new-status",G(t.state));t.dispatch({type:"ADD_STATUS",target:{type:"page",id:"usm"},payload:{id:a,name:e.newStatusName,tone:ce(t.state.statuses.length)}})},Ca=(e,t)=>{const a=K("new-label",G(t.state));t.dispatch({type:"ADD_LABEL",target:{type:"page",id:"usm"},payload:{id:a,name:e.newLabelName,tone:xe(t.state.labels.length)}})},at=(e,t)=>{const a=s=>t.stories.filter(i=>i.milestoneId===s).length;return[...t.milestones.map(({id:s,name:i,timeframe:n})=>({id:s,name:i,timeframe:n?.trim()??"",storyCount:a(s)})),{id:void 0,name:e.unassigned,timeframe:"",storyCount:a(void 0)}]},Ba=(e,t)=>l`
|
|
332
|
-
<div class="empty">
|
|
333
|
-
<h2>${e.emptyTitle}</h2>
|
|
334
|
-
<p>${e.emptyBody}</p>
|
|
335
|
-
<button class="dpk-btn dpk-btn--accent" type="button" @click=${()=>Qe(e,t)}>
|
|
336
|
-
${e.firstActivityButton}
|
|
337
|
-
</button>
|
|
338
|
-
</div>
|
|
339
|
-
`,Ya=e=>{const{m:t,context:a}=e,s=ue(a.state);return s.length===0?Ba(t,a):l`${Ua(t,a)}
|
|
340
|
-
${st(a)==="activity"?Pa(e,s):Va(e)}`},Ua=(e,t)=>{const{state:a}=t;if(a.statuses.length===0)return v;const s=re(a,t.navigation),i=ne(a),n=o=>a.stories.filter(p=>p.statusId===o).length,r=o=>{const p=o.id,c=s.has(p);return l`<a
|
|
341
|
-
class="filter-chip"
|
|
342
|
-
role="checkbox"
|
|
343
|
-
data-status=${p}
|
|
344
|
-
aria-checked=${String(c)}
|
|
345
|
-
style=${O(o.tone)}
|
|
346
|
-
href=${t.hashFor({status:Me(a,ya(s,p))})}
|
|
347
|
-
>${W(o)}<span class="filter-name" title=${o.name}>${o.name}</span
|
|
348
|
-
><span class="filter-count">${n(p)}</span></a
|
|
349
|
-
>`};return l`<div class="map-toolbar" role="group" aria-label=${e.statusFilterLabel} data-testid="usm-status-filter">
|
|
350
|
-
<span class="filter-label">${e.statusFilterLabel}</span>
|
|
351
|
-
${i.map(r)}
|
|
352
|
-
${s.size===0?v:l`<a class="filter-clear" href=${t.hashFor({status:null})}>${e.clearFilter}</a>`}
|
|
353
|
-
</div>`},st=e=>e.navigation.view==="group"?"group":"activity",za=(e,t)=>{const a=st(t);return l`<div class="segmented view-tabs" role="tablist" aria-label=${e.groupingLabel}>
|
|
354
|
-
${it(t,"activity",a,e.activityGroup)}
|
|
355
|
-
${it(t,"group",a,e.groupViewTab)}
|
|
356
|
-
</div>`},it=(e,t,a,s)=>{const i=t===a;return l`<a
|
|
357
|
-
class="tab"
|
|
358
|
-
role="tab"
|
|
359
|
-
data-current=${String(i)}
|
|
360
|
-
aria-selected=${i?"true":"false"}
|
|
361
|
-
href=${e.hashFor({view:t})}
|
|
362
|
-
>${s}</a
|
|
363
|
-
>`},Pa=(e,t)=>{const{m:a,context:s}=e,{state:i}=s,n=at(a,i);return l`
|
|
364
|
-
<div class="map-scroll">
|
|
365
|
-
<div class="map" style=${`--cols:${t.length+1}`} data-testid="usm-map">
|
|
366
|
-
<div class="map-head">
|
|
367
|
-
<div class="map-row">
|
|
368
|
-
<div class="corner">
|
|
369
|
-
<span class="dpk-label">${a.groupAxisHeader}</span>
|
|
370
|
-
</div>
|
|
371
|
-
${A(i.activities,r=>r.id,r=>rt(a,s,r.id,`grid-column: span ${Math.max(r.steps.length,1)}`))}
|
|
372
|
-
${ot(a,s)}
|
|
373
|
-
</div>
|
|
374
|
-
<div class="map-row">
|
|
375
|
-
${nt(a)}
|
|
376
|
-
${A(t,({activity:r,step:o})=>`${r.id}.${o.id}`,({activity:r,step:o})=>l`
|
|
377
|
-
<div
|
|
378
|
-
class="col-head"
|
|
379
|
-
data-current=${String(s.navigation.step===o.id)}
|
|
380
|
-
data-dpk-target=${T({type:"step",id:ee(r.id,o.id)})}
|
|
381
|
-
>
|
|
382
|
-
<h4>
|
|
383
|
-
<dpk-component-inline-edit
|
|
384
|
-
.value=${o.name}
|
|
385
|
-
.label=${a.stepNameLabel}
|
|
386
|
-
@dpk-commit=${Y(p=>s.dispatch({type:"SET_STEP_NAME",target:{type:"step",id:o.id},payload:{name:p}}))}
|
|
387
|
-
@click=${p=>p.stopPropagation()}
|
|
388
|
-
></dpk-component-inline-edit>
|
|
389
|
-
</h4>
|
|
390
|
-
<span class="count">${$e(i,o.id)}</span>
|
|
391
|
-
</div>
|
|
392
|
-
`)}
|
|
393
|
-
<div class="corner"><span class="dpk-label">—</span></div>
|
|
394
|
-
</div>
|
|
395
|
-
</div>
|
|
396
|
-
${A(n,r=>r.id,r=>dt(e,r,l`${A(t,({activity:o,step:p})=>`${o.id}.${p.id}`,({activity:o,step:p})=>Fa(e,{activityId:o.id,stepId:p.id,milestoneId:r.id}))}`))}
|
|
397
|
-
${lt(a,s,t.length)}
|
|
398
|
-
</div>
|
|
399
|
-
</div>
|
|
400
|
-
`},Va=e=>{const{m:t,context:a}=e,{state:s}=a,i=at(t,s);return l`
|
|
401
|
-
<div class="map-scroll">
|
|
402
|
-
<div class="map" style=${`--cols:${s.activities.length+1}`} data-testid="usm-map-group">
|
|
403
|
-
<div class="map-head">
|
|
404
|
-
<div class="map-row">
|
|
405
|
-
${nt(t)}
|
|
406
|
-
${A(s.activities,n=>n.id,n=>rt(t,a,n.id,void 0,!0))}
|
|
407
|
-
${ot(t,a)}
|
|
408
|
-
</div>
|
|
409
|
-
</div>
|
|
410
|
-
${A(i,n=>n.id,n=>dt(e,n,l`${A(s.activities,r=>r.id,r=>ja(e,r.id,n.id))}`))}
|
|
411
|
-
${lt(t,a,s.activities.length)}
|
|
412
|
-
</div>
|
|
413
|
-
</div>
|
|
414
|
-
`},nt=e=>l`<div class="corner">
|
|
415
|
-
<span class="dpk-label">${e.activityAxis}</span>
|
|
416
|
-
<span class="dpk-label">${e.milestoneAxis}</span>
|
|
417
|
-
</div>`,rt=(e,t,a,s,i=!1)=>{const{state:n}=t,r=n.activities.find(c=>c.id===a);if(!r)return l`<div class="act-head"></div>`;const o=n.stories.filter(c=>c.activityId===r.id),p=De(n,o);return l`
|
|
418
|
-
<div
|
|
419
|
-
class="act-head"
|
|
420
|
-
style=${s??""}
|
|
421
|
-
data-activity=${r.id}
|
|
422
|
-
data-dpk-target=${T({type:"activity",id:r.id})}
|
|
423
|
-
>
|
|
424
|
-
<div class="act-title">
|
|
425
|
-
<dpk-component-inline-edit
|
|
426
|
-
.value=${r.name}
|
|
427
|
-
.label=${e.activityNameLabel}
|
|
428
|
-
@dpk-commit=${Y(c=>t.dispatch({type:"SET_ACTIVITY_NAME",target:{type:"activity",id:r.id},payload:{name:c}}))}
|
|
429
|
-
></dpk-component-inline-edit>
|
|
430
|
-
<span class="count">${o.length}</span>
|
|
431
|
-
<button
|
|
432
|
-
class="dpk-icon-btn"
|
|
433
|
-
type="button"
|
|
434
|
-
aria-label=${e.addStepAria}
|
|
435
|
-
@click=${()=>Ma(e,t,r.id)}
|
|
436
|
-
>
|
|
437
|
-
${Dt()}
|
|
438
|
-
</button>
|
|
439
|
-
</div>
|
|
440
|
-
<div class="act-meta">
|
|
441
|
-
<span class="act-actor" data-empty=${String(r.actor===void 0)}>
|
|
442
|
-
<dpk-component-inline-edit
|
|
443
|
-
truncate
|
|
444
|
-
.value=${r.actor??""}
|
|
445
|
-
.label=${e.activityActorLabel}
|
|
446
|
-
.placeholder=${e.activityActorLabel}
|
|
447
|
-
@dpk-commit=${Y(c=>t.dispatch({type:"SET_ACTIVITY_ACTOR",target:{type:"activity",id:r.id},payload:{actor:c}}))}
|
|
448
|
-
></dpk-component-inline-edit>
|
|
449
|
-
</span>
|
|
450
|
-
${qe(p,e.progressAria(p.map(c=>`${c.name} ${c.count}`).join(", ")))}
|
|
451
|
-
</div>
|
|
452
|
-
${i&&r.steps.length>0?l`<ol class="act-steps">
|
|
453
|
-
${r.steps.map(c=>l`<li>${c.name}</li>`)}
|
|
454
|
-
</ol>`:v}
|
|
455
|
-
</div>
|
|
456
|
-
`},ot=(e,t)=>l`<div class="act-head">
|
|
457
|
-
<button class="dpk-btn dpk-btn--ghost" type="button" @click=${()=>Qe(e,t)}>
|
|
458
|
-
${e.newActivityButton}
|
|
459
|
-
</button>
|
|
460
|
-
</div>`,lt=(e,t,a)=>l`<div class="map-row">
|
|
461
|
-
<div class="row-lead">
|
|
462
|
-
<div class="row-head">
|
|
463
|
-
<button class="dpk-btn dpk-btn--ghost" type="button" @click=${()=>et(e,t)}>
|
|
464
|
-
${e.newMilestoneButton}
|
|
465
|
-
</button>
|
|
466
|
-
</div>
|
|
467
|
-
</div>
|
|
468
|
-
${Array.from({length:a+1},()=>l`<div class="cell"></div>`)}
|
|
469
|
-
</div>`,dt=(e,t,a)=>{const{m:s,context:i,drag:n,handlers:r}=e,o=t.id;if(o===void 0)return l`<div
|
|
470
|
-
class="map-row"
|
|
471
|
-
data-unassigned="true"
|
|
472
|
-
data-draggable="false"
|
|
473
|
-
data-row-dragging="false"
|
|
474
|
-
data-row-drop="false"
|
|
475
|
-
>
|
|
476
|
-
<div class="row-lead">
|
|
477
|
-
<div class="row-head" data-milestone="" draggable="false"><span>${t.name}</span></div>
|
|
478
|
-
${pt(s,t)}
|
|
479
|
-
</div>
|
|
480
|
-
${a}
|
|
481
|
-
<div class="cell"></div>
|
|
482
|
-
</div>`;const p=Ga(s,i,o,t.name),c=`row:${o}`,d=n.target({key:c,accepts:"milestone",hovered:qa,onDrop:R=>r.dropOnMilestoneRow(o,R)}),x=n.source({type:"milestone",id:o});return l`
|
|
483
|
-
<div
|
|
484
|
-
class="map-row"
|
|
485
|
-
data-draggable="true"
|
|
486
|
-
data-row-dragging=${String(n.isDragging("milestone",o))}
|
|
487
|
-
data-row-drop=${String(n.isOver(c))}
|
|
488
|
-
@dragenter=${d.dragenter}
|
|
489
|
-
@dragover=${d.dragover}
|
|
490
|
-
@dragleave=${d.dragleave}
|
|
491
|
-
@drop=${d.drop}
|
|
492
|
-
>
|
|
493
|
-
<div class="row-lead">
|
|
494
|
-
<div
|
|
495
|
-
class="row-head"
|
|
496
|
-
data-milestone=${o}
|
|
497
|
-
data-dpk-target=${T({type:"milestone",id:o})}
|
|
498
|
-
draggable="true"
|
|
499
|
-
@dragstart=${R=>{Ka(R),x.dragstart(R)}}
|
|
500
|
-
@dragend=${x.dragend}
|
|
501
|
-
>
|
|
502
|
-
<span class="row-grip" aria-hidden="true">${Mt()}</span>${p}
|
|
503
|
-
</div>
|
|
504
|
-
${pt(s,t)}
|
|
505
|
-
</div>
|
|
506
|
-
${a}
|
|
507
|
-
<div class="cell"></div>
|
|
508
|
-
</div>
|
|
509
|
-
`},pt=(e,t)=>l`<div class="row-meta">
|
|
510
|
-
${t.timeframe===""?v:l`<span class="row-timeframe">${t.timeframe}</span>`}
|
|
511
|
-
<span class="row-count">${e.storyCount(t.storyCount)}</span>
|
|
512
|
-
</div>`,Ga=(e,t,a,s)=>l`<dpk-component-inline-edit
|
|
513
|
-
draggable="false"
|
|
514
|
-
.value=${s}
|
|
515
|
-
.label=${e.milestoneNameLabel}
|
|
516
|
-
@dpk-commit=${Y(i=>t.dispatch({type:"SET_MILESTONE_NAME",target:{type:"milestone",id:a},payload:{name:i}}))}
|
|
517
|
-
></dpk-component-inline-edit>`,Fa=(e,t)=>{const{m:a,context:s,drag:i,handlers:n}=e,r=re(s.state,s.navigation),o=te(s.state,t.stepId,t.milestoneId).filter(d=>Ne(r,d)),p=`cell:${t.stepId}:${t.milestoneId??""}`,c=i.target({key:p,accepts:"story",hovered:ut,onDrop:d=>n.dropOnCell(t,d)});return l`
|
|
518
|
-
<div
|
|
519
|
-
class="cell"
|
|
520
|
-
data-step=${t.stepId}
|
|
521
|
-
data-milestone=${t.milestoneId??""}
|
|
522
|
-
data-drop=${String(i.isOver(p))}
|
|
523
|
-
@dragenter=${c.dragenter}
|
|
524
|
-
@dragover=${c.dragover}
|
|
525
|
-
@dragleave=${c.dragleave}
|
|
526
|
-
@drop=${c.drop}
|
|
527
|
-
>
|
|
528
|
-
<div class="card-list" data-testid=${`cell-${t.stepId}-${t.milestoneId??"unassigned"}`}>
|
|
529
|
-
${A(o,d=>d.id,d=>ct(e,d,""))}
|
|
530
|
-
</div>
|
|
531
|
-
<button
|
|
532
|
-
class="dpk-btn dpk-btn--ghost add-cell"
|
|
533
|
-
type="button"
|
|
534
|
-
title=${a.addStoryCellAria}
|
|
535
|
-
@click=${()=>tt(a,s,t.activityId,t.stepId,t.milestoneId)}
|
|
536
|
-
>
|
|
537
|
-
${a.addCellButton}
|
|
538
|
-
</button>
|
|
539
|
-
</div>
|
|
540
|
-
`},ja=(e,t,a)=>{const{m:s,context:i,drag:n,handlers:r}=e,{state:o}=i,p=re(o,i.navigation),c=Te(o,t,a).filter(w=>Ne(p,w)),d=o.activities.find(w=>w.id===t)?.steps??[],x=d[0],R=w=>d.find(ft=>ft.id===w)?.name??"",k=`group:${t}:${a??""}`,E=n.target({key:k,accepts:"story",hovered:ut,onDrop:w=>r.dropOnGroupCell(t,a,w)});return l`
|
|
541
|
-
<div
|
|
542
|
-
class="cell"
|
|
543
|
-
data-activity=${t}
|
|
544
|
-
data-milestone=${a??""}
|
|
545
|
-
data-drop=${String(n.isOver(k))}
|
|
546
|
-
@dragenter=${E.dragenter}
|
|
547
|
-
@dragover=${E.dragover}
|
|
548
|
-
@dragleave=${E.dragleave}
|
|
549
|
-
@drop=${E.drop}
|
|
550
|
-
>
|
|
551
|
-
<div class="card-list" data-testid=${`group-cell-${t}-${a??"unassigned"}`}>
|
|
552
|
-
${A(c,w=>w.id,w=>ct(e,w,R(w.stepId)))}
|
|
553
|
-
</div>
|
|
554
|
-
${x?l`<button
|
|
555
|
-
class="dpk-btn dpk-btn--ghost add-cell"
|
|
556
|
-
type="button"
|
|
557
|
-
aria-label=${s.addStoryCellAria}
|
|
558
|
-
@click=${()=>tt(s,i,t,x.id,a)}
|
|
559
|
-
>
|
|
560
|
-
${s.addCellButton}
|
|
561
|
-
</button>`:v}
|
|
562
|
-
</div>
|
|
563
|
-
`},ct=(e,t,a)=>{const{context:s,drag:i,handlers:n}=e,r=ne(s.state),o=s.comments.filter(c=>c.target.type==="story"&&c.target.id===t.id),p=i.source({type:"story",id:t.id});return l`<dpk-internal-usm-story-card
|
|
564
|
-
data-story=${t.id}
|
|
565
|
-
data-status=${t.statusId??""}
|
|
566
|
-
data-dpk-target=${T({type:"story",id:t.id})}
|
|
567
|
-
draggable="true"
|
|
568
|
-
tabindex="0"
|
|
569
|
-
role="button"
|
|
570
|
-
aria-haspopup="dialog"
|
|
571
|
-
aria-label=${t.name}
|
|
572
|
-
style=${O(Oe(r,t)?.tone)}
|
|
573
|
-
.story=${t}
|
|
574
|
-
.stepName=${a}
|
|
575
|
-
.statuses=${r}
|
|
576
|
-
.labels=${da(s.state,t)}
|
|
577
|
-
.notes=${o}
|
|
578
|
-
@click=${()=>n.selectStory(t.id)}
|
|
579
|
-
@keydown=${c=>{c.composedPath()[0]!==c.currentTarget||c.key!=="Enter"&&c.key!==" "||(c.preventDefault(),n.selectStory(t.id))}}
|
|
580
|
-
?focused=${s.navigation.story===t.id}
|
|
581
|
-
?dragging=${i.isDragging("story",t.id)}
|
|
582
|
-
@dragstart=${p.dragstart}
|
|
583
|
-
@dragend=${p.dragend}
|
|
584
|
-
></dpk-internal-usm-story-card>`},ut=e=>{const t=e.target instanceof Element?e.target.closest("dpk-internal-usm-story-card"):null;return t?{id:t.getAttribute("data-story"),element:t}:null},Ka=e=>{const a=(e.currentTarget instanceof Element?e.currentTarget:null)?.closest(".map-row");if(!a||!e.dataTransfer)return;const s=a.getBoundingClientRect();e.dataTransfer.setDragImage(a,e.clientX-s.left,e.clientY-s.top)},qa=e=>{const t=e.target instanceof Element?e.target.closest(".map-row"):null,a=t?.querySelector(".row-head[data-milestone]");if(!t||!a)return null;const s=a.getAttribute("data-milestone");return{id:s===""?null:s,element:t}},Ha=(e,t,a,s)=>l`
|
|
585
|
-
<section class="st-overview" data-testid="usm-statuses">
|
|
586
|
-
${a.rows.length===0?l`<div class="empty">
|
|
587
|
-
<h2>${e.noStatusesTitle}</h2>
|
|
588
|
-
<p>${e.noStatusesBody}</p>
|
|
589
|
-
</div>`:v}
|
|
590
|
-
<ol class="st-list">
|
|
591
|
-
${A(a.rows,i=>i.id,i=>Wa(e,t,i,s))}
|
|
592
|
-
</ol>
|
|
593
|
-
<div>
|
|
594
|
-
<button class="dpk-btn dpk-btn--ghost" type="button" @click=${()=>Na(e,t)}>
|
|
595
|
-
${e.newStatusButton}
|
|
596
|
-
</button>
|
|
597
|
-
</div>
|
|
598
|
-
</section>
|
|
599
|
-
`,Wa=(e,t,a,s)=>{const i=s.openFor===a.id,n={type:"status",id:a.id},r=o=>{t.dispatch({type:"REORDER_STATUS",target:n,payload:{after:o}})};return l`
|
|
600
|
-
<li class="st-row" data-status=${a.id} data-dpk-target=${T(n)} style=${O(a.tone)}>
|
|
601
|
-
<button
|
|
602
|
-
class="st-icon-trigger"
|
|
603
|
-
type="button"
|
|
604
|
-
data-icon-trigger=${a.id}
|
|
605
|
-
aria-haspopup="menu"
|
|
606
|
-
aria-expanded=${String(i)}
|
|
607
|
-
aria-label=${`${e.statusIconLabel}: ${e.iconName(a.icon)}`}
|
|
608
|
-
title=${e.iconName(a.icon)}
|
|
609
|
-
@click=${()=>s.toggle(a.id)}
|
|
610
|
-
>
|
|
611
|
-
${W(a)}
|
|
612
|
-
</button>
|
|
613
|
-
${i?Xa(e,t,a,s):v}
|
|
614
|
-
<span class="st-name">
|
|
615
|
-
<dpk-component-inline-edit
|
|
616
|
-
.value=${a.name}
|
|
617
|
-
.label=${e.statusNameLabel}
|
|
618
|
-
@dpk-commit=${Y(o=>t.dispatch({type:"SET_STATUS_NAME",target:n,payload:{name:o}}))}
|
|
619
|
-
></dpk-component-inline-edit>
|
|
620
|
-
</span>
|
|
621
|
-
${ht(e,a.storyCount,a.share)}
|
|
622
|
-
${mt(e,a.tone,o=>t.dispatch({type:"SET_STATUS_TONE",target:n,payload:{tone:o}}))}
|
|
623
|
-
${gt(e,{ids:t.state.statuses.map(o=>o.id),row:a,deleteLabel:e.deleteStatusAria,reorder:r,remove:()=>t.dispatch({type:"DELETE_STATUS",target:n,payload:{}})})}
|
|
624
|
-
</li>
|
|
625
|
-
`},Xa=(e,t,a,s)=>l`<div
|
|
626
|
-
id="icon-menu"
|
|
627
|
-
class="comment-pop icon-menu"
|
|
628
|
-
popover="manual"
|
|
629
|
-
role="menu"
|
|
630
|
-
aria-label=${e.statusIconLabel}
|
|
631
|
-
style=${O(a.tone)}
|
|
632
|
-
@keydown=${i=>{i.key==="Escape"&&(i.preventDefault(),s.close())}}
|
|
633
|
-
>
|
|
634
|
-
${ke.map(i=>l`<button
|
|
635
|
-
class="icon-option"
|
|
636
|
-
type="button"
|
|
637
|
-
role="menuitemradio"
|
|
638
|
-
data-icon=${i}
|
|
639
|
-
title=${e.iconName(i)}
|
|
640
|
-
aria-label=${e.iconName(i)}
|
|
641
|
-
aria-checked=${String(i===a.icon)}
|
|
642
|
-
@click=${()=>{i!==a.icon&&t.dispatch({type:"SET_STATUS_ICON",target:{type:"status",id:a.id},payload:{icon:i}}),s.close()}}
|
|
643
|
-
>
|
|
644
|
-
${W({icon:i,progress:a.progress})}
|
|
645
|
-
</button>`)}
|
|
646
|
-
</div>`,mt=(e,t,a)=>l`<span class="st-tones" role="radiogroup" aria-label=${e.statusToneLabel}>
|
|
647
|
-
${Q.map(s=>l`<button
|
|
648
|
-
class="st-tone"
|
|
649
|
-
type="button"
|
|
650
|
-
role="radio"
|
|
651
|
-
data-tone=${s}
|
|
652
|
-
style=${O(s)}
|
|
653
|
-
title=${e.toneName(s)}
|
|
654
|
-
aria-label=${e.toneName(s)}
|
|
655
|
-
aria-checked=${s===t?"true":"false"}
|
|
656
|
-
@click=${()=>{s!==t&&a(s)}}
|
|
657
|
-
></button>`)}
|
|
658
|
-
</span>`,gt=(e,t)=>l`<span class="st-tools">
|
|
659
|
-
<button
|
|
660
|
-
class="dpk-icon-btn"
|
|
661
|
-
type="button"
|
|
662
|
-
aria-label=${e.moveUpAria}
|
|
663
|
-
?disabled=${t.row.previousId===null}
|
|
664
|
-
@click=${()=>t.reorder(Za(t.ids,t.row.previousId))}
|
|
665
|
-
>
|
|
666
|
-
↑
|
|
667
|
-
</button>
|
|
668
|
-
<button
|
|
669
|
-
class="dpk-icon-btn"
|
|
670
|
-
type="button"
|
|
671
|
-
aria-label=${e.moveDownAria}
|
|
672
|
-
?disabled=${t.row.nextId===null}
|
|
673
|
-
@click=${()=>t.reorder(t.row.nextId)}
|
|
674
|
-
>
|
|
675
|
-
↓
|
|
676
|
-
</button>
|
|
677
|
-
<button class="dpk-icon-btn" type="button" data-role="delete" aria-label=${t.deleteLabel} @click=${t.remove}>
|
|
678
|
-
${ve()}
|
|
679
|
-
</button>
|
|
680
|
-
</span>`,Za=(e,t)=>{const a=t===null?-1:e.indexOf(t);return a<=0?null:e[a-1]??null},ht=(e,t,a)=>l`
|
|
681
|
-
<span class="st-share">
|
|
682
|
-
<span class="st-share-text">${e.statusShare(t,Math.round(a*100))}</span>
|
|
683
|
-
<span class="st-meter" aria-hidden="true"><span style=${`width:${a*100}%`}></span></span>
|
|
684
|
-
</span>
|
|
685
|
-
`,Ja=(e,t,a)=>l`
|
|
686
|
-
<section class="st-overview" data-testid="usm-labels">
|
|
687
|
-
${a.rows.length===0?l`<div class="empty">
|
|
688
|
-
<h2>${e.noLabelsTitle}</h2>
|
|
689
|
-
<p>${e.noLabelsBody}</p>
|
|
690
|
-
</div>`:v}
|
|
691
|
-
<ol class="st-list">
|
|
692
|
-
${A(a.rows,s=>s.id,s=>Qa(e,t,s))}
|
|
693
|
-
</ol>
|
|
694
|
-
<div>
|
|
695
|
-
<button class="dpk-btn dpk-btn--ghost" type="button" @click=${()=>Ca(e,t)}>
|
|
696
|
-
${e.newLabelButton}
|
|
697
|
-
</button>
|
|
698
|
-
</div>
|
|
699
|
-
</section>
|
|
700
|
-
`,Qa=(e,t,a)=>{const s={type:"label",id:a.id};return l`
|
|
701
|
-
<li class="st-row" data-label=${a.id} data-dpk-target=${T(s)} style=${O(a.tone)}>
|
|
702
|
-
<span class="label-swatch" aria-hidden="true"></span>
|
|
703
|
-
<span class="st-name">
|
|
704
|
-
<dpk-component-inline-edit
|
|
705
|
-
.value=${a.name}
|
|
706
|
-
.label=${e.labelNameLabel}
|
|
707
|
-
@dpk-commit=${Y(i=>t.dispatch({type:"SET_LABEL_NAME",target:s,payload:{name:i}}))}
|
|
708
|
-
></dpk-component-inline-edit>
|
|
709
|
-
</span>
|
|
710
|
-
${ht(e,a.storyCount,a.share)}
|
|
711
|
-
${mt(e,a.tone,i=>t.dispatch({type:"SET_LABEL_TONE",target:s,payload:{tone:i}}))}
|
|
712
|
-
${gt(e,{ids:t.state.labels.map(i=>i.id),row:a,deleteLabel:e.deleteLabelAria,reorder:i=>t.dispatch({type:"REORDER_LABEL",target:s,payload:{after:i}}),remove:()=>t.dispatch({type:"DELETE_LABEL",target:s,payload:{}})})}
|
|
713
|
-
</li>
|
|
714
|
-
`},es=(e,t,a)=>l`
|
|
715
|
-
<section class="ms-overview" data-testid="usm-milestones">
|
|
716
|
-
${a.length===0?l`<div class="empty">
|
|
717
|
-
<h2>${e.noMilestonesTitle}</h2>
|
|
718
|
-
<p>${e.noMilestonesBody}</p>
|
|
719
|
-
</div>`:v}
|
|
720
|
-
<ol class="ms-timeline">
|
|
721
|
-
${A(a,s=>s.id,s=>ts(e,t,s))}
|
|
722
|
-
<li class="ms-add">
|
|
723
|
-
<span class="ms-when" aria-hidden="true"></span>
|
|
724
|
-
<span class="ms-rail" aria-hidden="true"><span class="ms-node ms-node--add"></span></span>
|
|
725
|
-
<div class="ms-body">
|
|
726
|
-
<button class="dpk-btn dpk-btn--ghost" type="button" @click=${()=>et(e,t)}>
|
|
727
|
-
${e.newMilestoneButton}
|
|
728
|
-
</button>
|
|
729
|
-
</div>
|
|
730
|
-
</li>
|
|
731
|
-
</ol>
|
|
732
|
-
</section>
|
|
733
|
-
`,ts=(e,t,a)=>{const s=a.id;return l`
|
|
734
|
-
<li class="ms-entry" data-milestone-card=${s} data-dpk-target=${T({type:"milestone",id:s})}>
|
|
735
|
-
<div class="ms-when">
|
|
736
|
-
${a.timeframe===""?l`<span class="ms-timeframe" data-empty="true">${e.timeframeUnset}</span>`:l`<span class="ms-timeframe">${a.timeframe}</span>`}
|
|
737
|
-
</div>
|
|
738
|
-
<span class="ms-rail" aria-hidden="true"><span class="ms-node">${a.ordinal}</span></span>
|
|
739
|
-
<article class="ms-body">
|
|
740
|
-
<h3 class="ms-name">
|
|
741
|
-
<dpk-component-inline-edit
|
|
742
|
-
.value=${a.name}
|
|
743
|
-
.label=${e.milestoneNameLabel}
|
|
744
|
-
@dpk-commit=${Y(i=>t.dispatch({type:"SET_MILESTONE_NAME",target:{type:"milestone",id:s},payload:{name:i}}))}
|
|
745
|
-
></dpk-component-inline-edit>
|
|
746
|
-
</h3>
|
|
747
|
-
${a.description===""?l`<p class="ms-description" data-empty="true">${e.milestoneNoDescription}</p>`:l`<p class="ms-description">${a.description}</p>`}
|
|
748
|
-
<dl class="ms-facts">
|
|
749
|
-
<div>
|
|
750
|
-
<dt>${e.storiesLabel}</dt>
|
|
751
|
-
<dd>
|
|
752
|
-
<strong>${a.storyCount}</strong>
|
|
753
|
-
<span>${e.shareOfStories(Math.round(a.share*100))}</span>
|
|
754
|
-
</dd>
|
|
755
|
-
</div>
|
|
756
|
-
<div>
|
|
757
|
-
<dt>${e.coverageLabel}</dt>
|
|
758
|
-
<dd>
|
|
759
|
-
<strong>${e.coverage(a.coverage.covered,a.coverage.total)}</strong>
|
|
760
|
-
<span class="ms-meter" aria-hidden="true">
|
|
761
|
-
<span
|
|
762
|
-
style=${`width:${a.coverage.total===0?0:a.coverage.covered/a.coverage.total*100}%`}
|
|
763
|
-
></span>
|
|
764
|
-
</span>
|
|
765
|
-
</dd>
|
|
766
|
-
</div>
|
|
767
|
-
</dl>
|
|
768
|
-
${a.progress.length===0?v:as(e,a)}
|
|
769
|
-
</article>
|
|
770
|
-
</li>
|
|
771
|
-
`},as=(e,t)=>l`
|
|
772
|
-
<div class="ms-breakdown">
|
|
773
|
-
${qe(t.progress,e.progressAria(t.progress.map(a=>`${a.name} ${a.count}`).join(", ")))}
|
|
774
|
-
<ul class="ms-legend" aria-hidden="true">
|
|
775
|
-
${t.progress.map(a=>l`<li data-status=${a.id} style=${O(a.tone)}>
|
|
776
|
-
${W(a)}
|
|
777
|
-
<span class="ms-breakdown-name">${a.name}</span>
|
|
778
|
-
<span class="ms-breakdown-count">${a.count}</span>
|
|
779
|
-
</li>`)}
|
|
780
|
-
</ul>
|
|
781
|
-
</div>
|
|
782
|
-
`,ss=(e,t,a,s)=>{if(a.kind!=="picking-step")return v;const i=S(t.state,a.storyId),n=U(t.state,a.activityId);if(!i||!n)return v;const r=n.steps[0]?.id;return l`<div class="comment-pop move-dialog" id="move-dialog" popover="manual">
|
|
783
|
-
<span class="dpk-label">${e.moveDialogLabel}</span>
|
|
784
|
-
<select class="dpk-select" aria-label=${e.moveDialogSelectLabel} data-move-dialog>
|
|
785
|
-
${n.steps.map(o=>l`<option value=${o.id} ?selected=${o.id===r}>${o.name}</option>`)}
|
|
786
|
-
</select>
|
|
787
|
-
<div class="pop-actions">
|
|
788
|
-
<button
|
|
789
|
-
class="dpk-btn dpk-btn--accent"
|
|
790
|
-
type="button"
|
|
791
|
-
@click=${o=>{const c=(Nt(o.currentTarget,HTMLElement)?.closest("#move-dialog")??null)?.querySelector("select")?.value??r;c?s.confirm(c):s.cancel()}}
|
|
792
|
-
>
|
|
793
|
-
${e.moveConfirm}
|
|
794
|
-
</button>
|
|
795
|
-
<button class="dpk-btn" type="button" @click=${s.cancel}>${e.moveCancel}</button>
|
|
796
|
-
</div>
|
|
797
|
-
</div>`},is=(e,t,a)=>{const{state:s}=t;return l`
|
|
798
|
-
<div class="board-bar">
|
|
799
|
-
<div class="page-tabs" role="tablist" aria-label=${e.pageTabsLabel}>
|
|
800
|
-
${oe(t,"map",a,e.mapTab,s.stories.length)}
|
|
801
|
-
${oe(t,"milestones",a,e.milestonesTab,s.milestones.length)}
|
|
802
|
-
${oe(t,"statuses",a,e.statusesTab,s.statuses.length)}
|
|
803
|
-
${oe(t,"labels",a,e.labelsTab,s.labels.length)}
|
|
804
|
-
</div>
|
|
805
|
-
${a==="map"&&s.activities.some(i=>i.steps.length>0)?za(e,t):v}
|
|
806
|
-
</div>
|
|
807
|
-
`},oe=(e,t,a,s,i)=>l`<a
|
|
808
|
-
role="tab"
|
|
809
|
-
data-tab=${t}
|
|
810
|
-
aria-selected=${t===a?"true":"false"}
|
|
811
|
-
href=${e.hashFor({tab:t==="map"?null:t})}
|
|
812
|
-
>${s}<span class="page-tab-count">${i}</span></a
|
|
813
|
-
>`,ns=e=>S(e.state,e.navigation.story),rs=(e,t,a)=>{const{state:s}=t,i={type:"story",id:a.id},n=()=>t.navigate({story:null}),r=$(s,`${a.activityId}.${a.stepId}`),o=N(s,a.milestoneId);return l`<aside
|
|
814
|
-
class="story-panel"
|
|
815
|
-
role="dialog"
|
|
816
|
-
aria-label=${e.panelLabel(a.name)}
|
|
817
|
-
data-testid="usm-story-panel"
|
|
818
|
-
data-story=${a.id}
|
|
819
|
-
tabindex="-1"
|
|
820
|
-
>
|
|
821
|
-
<header class="sp-head">
|
|
822
|
-
<span class="sp-where">
|
|
823
|
-
${r?l`<span>${r.activity.name}</span><span>${r.step.name}</span>`:v}
|
|
824
|
-
<span>${o?.name??e.unassigned}</span>
|
|
825
|
-
</span>
|
|
826
|
-
<button class="dpk-icon-btn" type="button" data-role="close" aria-label=${e.closePanelAria} @click=${n}>
|
|
827
|
-
${fe()}
|
|
828
|
-
</button>
|
|
829
|
-
</header>
|
|
830
|
-
<div class="sp-body">
|
|
831
|
-
<h2 class="sp-title">
|
|
832
|
-
<dpk-component-inline-edit
|
|
833
|
-
wrap
|
|
834
|
-
.value=${a.name}
|
|
835
|
-
.label=${e.storyTitleLabel}
|
|
836
|
-
@dpk-commit=${Y(p=>t.dispatch({type:"SET_STORY_NAME",target:i,payload:{name:p}}))}
|
|
837
|
-
></dpk-component-inline-edit>
|
|
838
|
-
</h2>
|
|
839
|
-
${s.statuses.length===0?v:os(e,t,a)}
|
|
840
|
-
${ls(e,t,a)}
|
|
841
|
-
<section class="sp-field">
|
|
842
|
-
<h3>${e.storyDescriptionLabel}</h3>
|
|
843
|
-
<dpk-component-inline-edit
|
|
844
|
-
multiline
|
|
845
|
-
markdown
|
|
846
|
-
class="sp-description"
|
|
847
|
-
.value=${a.description??""}
|
|
848
|
-
.label=${e.storyDescriptionLabel}
|
|
849
|
-
@dpk-commit=${Y(p=>t.dispatch({type:"SET_STORY_DESCRIPTION",target:i,payload:{description:p}}))}
|
|
850
|
-
></dpk-component-inline-edit>
|
|
851
|
-
</section>
|
|
852
|
-
${ds(e,t,a)} ${ps(e,t,a)}
|
|
853
|
-
</div>
|
|
854
|
-
<footer class="sp-foot">
|
|
855
|
-
<button
|
|
856
|
-
class="dpk-btn dpk-btn--ghost sp-delete"
|
|
857
|
-
type="button"
|
|
858
|
-
@click=${()=>{t.dispatch({type:"DELETE_STORY",target:i,payload:{}}).ok&&n()}}
|
|
859
|
-
>
|
|
860
|
-
${ve()}<span>${e.deleteStoryButton}</span>
|
|
861
|
-
</button>
|
|
862
|
-
</footer>
|
|
863
|
-
</aside>`},os=(e,t,a)=>{const s=ne(t.state),i=a.statusId;return l`<section class="sp-field">
|
|
864
|
-
<h3 id="sp-status-label">${e.storyStatusLabel}</h3>
|
|
865
|
-
<div class="sp-statuses" role="radiogroup" aria-labelledby="sp-status-label">
|
|
866
|
-
${s.map(n=>l`<button
|
|
867
|
-
class="sp-status"
|
|
868
|
-
type="button"
|
|
869
|
-
role="radio"
|
|
870
|
-
data-status=${n.id}
|
|
871
|
-
aria-checked=${String(n.id===i)}
|
|
872
|
-
style=${O(n.tone)}
|
|
873
|
-
@click=${()=>{n.id!==i&&t.dispatch({type:"SET_STORY_STATUS",target:{type:"story",id:a.id},payload:{statusId:n.id}})}}
|
|
874
|
-
>
|
|
875
|
-
${W(n)}<span>${n.name}</span>
|
|
876
|
-
</button>`)}
|
|
877
|
-
</div>
|
|
878
|
-
</section>`},ls=(e,t,a)=>{const s={type:"story",id:a.id},i=new Set(a.labelIds??[]);return l`<section class="sp-field">
|
|
879
|
-
<h3 id="sp-labels-label" class="sp-field-head">
|
|
880
|
-
<span>${e.storyLabelsLabel}</span>
|
|
881
|
-
<a class="sp-manage" href=${t.hashFor({tab:"labels",story:null})}>${e.manageLabels}</a>
|
|
882
|
-
</h3>
|
|
883
|
-
${t.state.labels.length===0?l`<p class="sp-empty">${e.storyNoLabels}</p>`:l`<div class="sp-labels" role="group" aria-labelledby="sp-labels-label">
|
|
884
|
-
${t.state.labels.map(n=>{const r=i.has(n.id);return l`<button
|
|
885
|
-
class="sp-label"
|
|
886
|
-
type="button"
|
|
887
|
-
data-label=${n.id}
|
|
888
|
-
aria-pressed=${String(r)}
|
|
889
|
-
style=${O(n.tone)}
|
|
890
|
-
@click=${()=>t.dispatch({type:r?"REMOVE_STORY_LABEL":"ADD_STORY_LABEL",target:s,payload:{labelId:n.id}})}
|
|
891
|
-
>
|
|
892
|
-
<span class="sp-label-dot" aria-hidden="true"></span><span>${n.name}</span>
|
|
893
|
-
</button>`})}
|
|
894
|
-
</div>`}
|
|
895
|
-
</section>`},ds=(e,t,a)=>{const s={type:"story",id:a.id},i=a.links??[],n=r=>{r.preventDefault();const o=r.currentTarget instanceof HTMLFormElement?r.currentTarget:null,p=o?.querySelector("input");if(!o||!p)return;const c=p.value.trim();if(!Bt(pe,c).success){p.setAttribute("aria-invalid","true");return}t.dispatch({type:"ADD_STORY_LINK",target:s,payload:{url:c}}).ok&&(p.removeAttribute("aria-invalid"),o.reset())};return l`<section class="sp-field">
|
|
896
|
-
<h3>${e.storyLinksLabel}</h3>
|
|
897
|
-
${i.length===0?v:l`<ul class="sp-links">
|
|
898
|
-
${i.map(r=>{const o=ie(r.url),p=r.label??o.text;return l`<li data-kind=${o.kind}>
|
|
899
|
-
<a class="sp-link" href=${r.url} target="_blank" rel="noopener noreferrer" title=${r.url}>
|
|
900
|
-
${Fe(o.kind)}
|
|
901
|
-
<span class="sp-link-text">${p}</span>
|
|
902
|
-
<span class="sp-link-url">${o.title===p?r.url:o.title}</span>
|
|
903
|
-
</a>
|
|
904
|
-
<button
|
|
905
|
-
class="dpk-icon-btn"
|
|
906
|
-
type="button"
|
|
907
|
-
aria-label=${e.removeLinkAria(p)}
|
|
908
|
-
@click=${()=>t.dispatch({type:"REMOVE_STORY_LINK",target:s,payload:{url:r.url}})}
|
|
909
|
-
>
|
|
910
|
-
${fe()}
|
|
911
|
-
</button>
|
|
912
|
-
</li>`})}
|
|
913
|
-
</ul>`}
|
|
914
|
-
<form class="sp-add-link" @submit=${n}>
|
|
915
|
-
<input
|
|
916
|
-
class="dpk-input"
|
|
917
|
-
type="url"
|
|
918
|
-
inputmode="url"
|
|
919
|
-
placeholder="https://"
|
|
920
|
-
aria-label=${e.linkUrlLabel}
|
|
921
|
-
@input=${r=>{r.currentTarget instanceof HTMLInputElement&&r.currentTarget.removeAttribute("aria-invalid")}}
|
|
922
|
-
/>
|
|
923
|
-
<button class="dpk-btn" type="submit">${e.addLinkButton}</button>
|
|
924
|
-
</form>
|
|
925
|
-
</section>`},ps=(e,t,a)=>{const s=t.comments.filter(n=>n.target.type==="story"&&n.target.id===a.id),i=n=>{const r=n.querySelector("textarea"),o=r?.value.trim()??"";if(!r||o==="")return;t.dispatch({type:"comment",target:`story:${a.id}`,payload:{body:o}}).ok&&(r.value="")};return l`<section class="sp-field sp-comments">
|
|
926
|
-
<h3>${e.storyCommentsLabel}${s.length>0?l`<span class="sp-count">${s.length}</span>`:v}</h3>
|
|
927
|
-
${s.length===0?v:l`<ol class="sp-comment-list">
|
|
928
|
-
${s.map(n=>l`<li>${Ct(n)}</li>`)}
|
|
929
|
-
</ol>`}
|
|
930
|
-
<form
|
|
931
|
-
class="sp-comment-form"
|
|
932
|
-
@submit=${n=>{n.preventDefault(),n.currentTarget instanceof HTMLFormElement&&i(n.currentTarget)}}
|
|
933
|
-
>
|
|
934
|
-
<textarea
|
|
935
|
-
class="dpk-textarea"
|
|
936
|
-
rows="3"
|
|
937
|
-
aria-label=${e.storyCommentsLabel}
|
|
938
|
-
data-dpk-text-key=${`story:${a.id}`}
|
|
939
|
-
@keydown=${n=>{if(n.isComposing||n.key!=="Enter"||!(n.ctrlKey||n.metaKey))return;n.preventDefault();const r=n.currentTarget instanceof HTMLElement?n.currentTarget.closest("form"):null;r&&i(r)}}
|
|
940
|
-
></textarea>
|
|
941
|
-
<div class="sp-comment-actions">
|
|
942
|
-
<button class="dpk-btn dpk-btn--accent" type="submit">${e.commentSubmit}</button>
|
|
943
|
-
</div>
|
|
944
|
-
</form>
|
|
945
|
-
</section>`},cs=Z`
|
|
946
|
-
/* Over the main column's edge, below the header: the page's own controls stay in reach. */
|
|
947
|
-
.story-panel {
|
|
948
|
-
position: absolute;
|
|
949
|
-
top: 0;
|
|
950
|
-
right: 0;
|
|
951
|
-
bottom: 0;
|
|
952
|
-
z-index: 20;
|
|
953
|
-
display: grid;
|
|
954
|
-
grid-template-rows: auto minmax(0, 1fr) auto;
|
|
955
|
-
width: min(420px, 100%);
|
|
956
|
-
border-left: 1px solid var(--dpk-rule-strong);
|
|
957
|
-
background: var(--dpk-paper-raised);
|
|
958
|
-
box-shadow: var(--dpk-shadow-lg);
|
|
959
|
-
animation: sp-slide-in 220ms var(--dpk-ease);
|
|
960
|
-
}
|
|
961
|
-
/* The panel takes the focus when it opens; the ring belongs to its controls. */
|
|
962
|
-
.story-panel:focus {
|
|
963
|
-
outline: none;
|
|
964
|
-
}
|
|
965
|
-
@keyframes sp-slide-in {
|
|
966
|
-
from {
|
|
967
|
-
opacity: 0;
|
|
968
|
-
transform: translateX(24px);
|
|
969
|
-
}
|
|
970
|
-
}
|
|
971
|
-
.sp-head {
|
|
972
|
-
display: flex;
|
|
973
|
-
align-items: center;
|
|
974
|
-
gap: 10px;
|
|
975
|
-
padding: 14px 22px 12px;
|
|
976
|
-
min-height: 60px;
|
|
977
|
-
box-sizing: border-box;
|
|
978
|
-
border-bottom: 1px solid var(--dpk-rule);
|
|
979
|
-
}
|
|
980
|
-
.sp-where {
|
|
981
|
-
display: flex;
|
|
982
|
-
flex-wrap: wrap;
|
|
983
|
-
gap: 2px 0;
|
|
984
|
-
flex: 1 1 auto;
|
|
985
|
-
min-width: 0;
|
|
986
|
-
color: var(--dpk-ink-faint);
|
|
987
|
-
font-size: 11.5px;
|
|
988
|
-
font-weight: 600;
|
|
989
|
-
}
|
|
990
|
-
.sp-where > span + span::before {
|
|
991
|
-
content: '›';
|
|
992
|
-
margin: 0 6px;
|
|
993
|
-
color: var(--dpk-rule-strong);
|
|
994
|
-
}
|
|
995
|
-
.sp-body {
|
|
996
|
-
display: grid;
|
|
997
|
-
align-content: start;
|
|
998
|
-
gap: 22px;
|
|
999
|
-
overflow: auto;
|
|
1000
|
-
padding: 18px 22px 24px;
|
|
1001
|
-
}
|
|
1002
|
-
.sp-title {
|
|
1003
|
-
margin: 0;
|
|
1004
|
-
font-size: 19px;
|
|
1005
|
-
font-weight: 700;
|
|
1006
|
-
letter-spacing: -0.015em;
|
|
1007
|
-
line-height: 1.35;
|
|
1008
|
-
}
|
|
1009
|
-
.sp-title dpk-component-inline-edit {
|
|
1010
|
-
display: block;
|
|
1011
|
-
margin: 0 -4px;
|
|
1012
|
-
}
|
|
1013
|
-
.sp-field {
|
|
1014
|
-
display: grid;
|
|
1015
|
-
gap: 8px;
|
|
1016
|
-
}
|
|
1017
|
-
.sp-field h3 {
|
|
1018
|
-
margin: 0;
|
|
1019
|
-
color: var(--dpk-ink-faint);
|
|
1020
|
-
font-size: 11px;
|
|
1021
|
-
font-weight: 650;
|
|
1022
|
-
letter-spacing: 0.04em;
|
|
1023
|
-
text-transform: uppercase;
|
|
1024
|
-
}
|
|
1025
|
-
.sp-statuses {
|
|
1026
|
-
display: flex;
|
|
1027
|
-
flex-wrap: wrap;
|
|
1028
|
-
gap: 6px;
|
|
1029
|
-
}
|
|
1030
|
-
.sp-status {
|
|
1031
|
-
display: inline-flex;
|
|
1032
|
-
align-items: center;
|
|
1033
|
-
gap: 7px;
|
|
1034
|
-
padding: 5px 12px 5px 9px;
|
|
1035
|
-
border: 1px solid var(--dpk-rule-strong);
|
|
1036
|
-
border-radius: 999px;
|
|
1037
|
-
background: var(--dpk-paper-raised);
|
|
1038
|
-
color: var(--dpk-ink);
|
|
1039
|
-
font: inherit;
|
|
1040
|
-
font-size: 12.5px;
|
|
1041
|
-
font-weight: 600;
|
|
1042
|
-
cursor: pointer;
|
|
1043
|
-
transition:
|
|
1044
|
-
background 140ms var(--dpk-ease),
|
|
1045
|
-
border-color 140ms var(--dpk-ease);
|
|
1046
|
-
}
|
|
1047
|
-
.sp-status:hover {
|
|
1048
|
-
border-color: color-mix(in oklab, var(--usm-tone) 60%, var(--dpk-rule-strong));
|
|
1049
|
-
}
|
|
1050
|
-
.sp-status:focus-visible {
|
|
1051
|
-
outline: none;
|
|
1052
|
-
box-shadow: var(--dpk-focus);
|
|
1053
|
-
}
|
|
1054
|
-
.sp-status[aria-checked='true'] {
|
|
1055
|
-
border-color: var(--usm-tone);
|
|
1056
|
-
background: color-mix(in oklab, var(--usm-tone) 14%, var(--dpk-paper-raised));
|
|
1057
|
-
box-shadow: inset 0 0 0 1px var(--usm-tone);
|
|
1058
|
-
}
|
|
1059
|
-
.sp-field-head {
|
|
1060
|
-
display: flex;
|
|
1061
|
-
align-items: baseline;
|
|
1062
|
-
justify-content: space-between;
|
|
1063
|
-
gap: 8px;
|
|
1064
|
-
}
|
|
1065
|
-
.sp-manage {
|
|
1066
|
-
color: var(--dpk-ink-faint);
|
|
1067
|
-
font-size: 11px;
|
|
1068
|
-
font-weight: 600;
|
|
1069
|
-
letter-spacing: 0;
|
|
1070
|
-
text-transform: none;
|
|
1071
|
-
}
|
|
1072
|
-
.sp-manage:hover {
|
|
1073
|
-
color: var(--dpk-blue);
|
|
1074
|
-
}
|
|
1075
|
-
.sp-empty {
|
|
1076
|
-
margin: 0;
|
|
1077
|
-
color: var(--dpk-ink-faint);
|
|
1078
|
-
font-size: 12.5px;
|
|
1079
|
-
}
|
|
1080
|
-
.sp-labels {
|
|
1081
|
-
display: flex;
|
|
1082
|
-
flex-wrap: wrap;
|
|
1083
|
-
gap: 6px;
|
|
1084
|
-
}
|
|
1085
|
-
.sp-label {
|
|
1086
|
-
display: inline-flex;
|
|
1087
|
-
align-items: center;
|
|
1088
|
-
gap: 6px;
|
|
1089
|
-
padding: 3px 10px 3px 8px;
|
|
1090
|
-
border: 1px dashed var(--dpk-rule-strong);
|
|
1091
|
-
border-radius: 999px;
|
|
1092
|
-
background: transparent;
|
|
1093
|
-
color: var(--dpk-ink-soft);
|
|
1094
|
-
font: inherit;
|
|
1095
|
-
font-size: 12px;
|
|
1096
|
-
font-weight: 600;
|
|
1097
|
-
cursor: pointer;
|
|
1098
|
-
transition:
|
|
1099
|
-
background 140ms var(--dpk-ease),
|
|
1100
|
-
border-color 140ms var(--dpk-ease);
|
|
1101
|
-
}
|
|
1102
|
-
.sp-label:hover {
|
|
1103
|
-
border-color: color-mix(in oklab, var(--usm-tone) 60%, var(--dpk-rule-strong));
|
|
1104
|
-
}
|
|
1105
|
-
.sp-label:focus-visible {
|
|
1106
|
-
outline: none;
|
|
1107
|
-
box-shadow: var(--dpk-focus);
|
|
1108
|
-
}
|
|
1109
|
-
.sp-label[aria-pressed='true'] {
|
|
1110
|
-
border-style: solid;
|
|
1111
|
-
border-color: color-mix(in oklab, var(--usm-tone) 55%, transparent);
|
|
1112
|
-
background: color-mix(in oklab, var(--usm-tone) 14%, var(--dpk-paper-raised));
|
|
1113
|
-
color: var(--dpk-ink);
|
|
1114
|
-
}
|
|
1115
|
-
.sp-label-dot {
|
|
1116
|
-
width: 7px;
|
|
1117
|
-
height: 7px;
|
|
1118
|
-
border-radius: 50%;
|
|
1119
|
-
background: var(--usm-tone);
|
|
1120
|
-
opacity: 0.5;
|
|
1121
|
-
}
|
|
1122
|
-
.sp-label[aria-pressed='true'] .sp-label-dot {
|
|
1123
|
-
opacity: 1;
|
|
1124
|
-
}
|
|
1125
|
-
.sp-description {
|
|
1126
|
-
display: block;
|
|
1127
|
-
margin: 0 -4px;
|
|
1128
|
-
color: var(--dpk-ink-soft);
|
|
1129
|
-
font-size: 13px;
|
|
1130
|
-
line-height: 1.65;
|
|
1131
|
-
}
|
|
1132
|
-
.sp-links {
|
|
1133
|
-
display: grid;
|
|
1134
|
-
gap: 4px;
|
|
1135
|
-
margin: 0;
|
|
1136
|
-
padding: 0;
|
|
1137
|
-
list-style: none;
|
|
1138
|
-
}
|
|
1139
|
-
.sp-links li {
|
|
1140
|
-
display: flex;
|
|
1141
|
-
align-items: center;
|
|
1142
|
-
gap: 4px;
|
|
1143
|
-
border: 1px solid var(--dpk-rule);
|
|
1144
|
-
border-radius: var(--dpk-radius-sm);
|
|
1145
|
-
background: var(--dpk-paper-sunken);
|
|
1146
|
-
}
|
|
1147
|
-
.sp-link {
|
|
1148
|
-
display: grid;
|
|
1149
|
-
grid-template-columns: 16px minmax(0, 1fr);
|
|
1150
|
-
column-gap: 9px;
|
|
1151
|
-
align-items: center;
|
|
1152
|
-
flex: 1 1 auto;
|
|
1153
|
-
min-width: 0;
|
|
1154
|
-
padding: 7px 4px 7px 10px;
|
|
1155
|
-
color: var(--dpk-ink);
|
|
1156
|
-
text-decoration: none;
|
|
1157
|
-
}
|
|
1158
|
-
.sp-link:hover .sp-link-text {
|
|
1159
|
-
text-decoration: underline;
|
|
1160
|
-
}
|
|
1161
|
-
.sp-link svg {
|
|
1162
|
-
grid-row: span 2;
|
|
1163
|
-
width: 16px;
|
|
1164
|
-
height: 16px;
|
|
1165
|
-
color: var(--dpk-ink-soft);
|
|
1166
|
-
}
|
|
1167
|
-
.sp-link-text {
|
|
1168
|
-
overflow: hidden;
|
|
1169
|
-
font-family: var(--dpk-mono);
|
|
1170
|
-
font-size: 12.5px;
|
|
1171
|
-
font-weight: 650;
|
|
1172
|
-
text-overflow: ellipsis;
|
|
1173
|
-
white-space: nowrap;
|
|
1174
|
-
}
|
|
1175
|
-
.sp-link-url {
|
|
1176
|
-
overflow: hidden;
|
|
1177
|
-
color: var(--dpk-ink-faint);
|
|
1178
|
-
font-size: 11px;
|
|
1179
|
-
text-overflow: ellipsis;
|
|
1180
|
-
white-space: nowrap;
|
|
1181
|
-
}
|
|
1182
|
-
.sp-add-link {
|
|
1183
|
-
display: flex;
|
|
1184
|
-
gap: 6px;
|
|
1185
|
-
}
|
|
1186
|
-
.sp-add-link input {
|
|
1187
|
-
flex: 1 1 auto;
|
|
1188
|
-
min-width: 0;
|
|
1189
|
-
}
|
|
1190
|
-
.sp-add-link input[aria-invalid='true'] {
|
|
1191
|
-
border-color: var(--dpk-accent);
|
|
1192
|
-
box-shadow: 0 0 0 2px color-mix(in srgb, var(--dpk-accent) 22%, transparent);
|
|
1193
|
-
}
|
|
1194
|
-
/* The handoff dock floats at the bottom right, so the footer keeps left. */
|
|
1195
|
-
.sp-field h3 .sp-count {
|
|
1196
|
-
margin-left: 6px;
|
|
1197
|
-
font-family: var(--dpk-mono);
|
|
1198
|
-
letter-spacing: 0;
|
|
1199
|
-
}
|
|
1200
|
-
.sp-comment-list {
|
|
1201
|
-
display: grid;
|
|
1202
|
-
gap: 6px;
|
|
1203
|
-
margin: 0;
|
|
1204
|
-
padding: 0;
|
|
1205
|
-
list-style: none;
|
|
1206
|
-
}
|
|
1207
|
-
.sp-comment-list li {
|
|
1208
|
-
padding: 8px 11px;
|
|
1209
|
-
border-radius: var(--dpk-radius-sm);
|
|
1210
|
-
background: var(--dpk-paper-sunken);
|
|
1211
|
-
color: var(--dpk-ink);
|
|
1212
|
-
font-size: 12.5px;
|
|
1213
|
-
line-height: 1.6;
|
|
1214
|
-
white-space: pre-wrap;
|
|
1215
|
-
overflow-wrap: anywhere;
|
|
1216
|
-
}
|
|
1217
|
-
.sp-comment-form {
|
|
1218
|
-
display: grid;
|
|
1219
|
-
gap: 6px;
|
|
1220
|
-
}
|
|
1221
|
-
.sp-comment-form textarea {
|
|
1222
|
-
resize: vertical;
|
|
1223
|
-
min-height: 64px;
|
|
1224
|
-
}
|
|
1225
|
-
.sp-comment-actions {
|
|
1226
|
-
display: flex;
|
|
1227
|
-
justify-content: flex-end;
|
|
1228
|
-
}
|
|
1229
|
-
.sp-foot {
|
|
1230
|
-
display: flex;
|
|
1231
|
-
justify-content: flex-start;
|
|
1232
|
-
padding: 12px 22px;
|
|
1233
|
-
border-top: 1px solid var(--dpk-rule);
|
|
1234
|
-
}
|
|
1235
|
-
.sp-delete {
|
|
1236
|
-
display: inline-flex;
|
|
1237
|
-
align-items: center;
|
|
1238
|
-
gap: 6px;
|
|
1239
|
-
color: var(--dpk-ink-soft);
|
|
1240
|
-
}
|
|
1241
|
-
.sp-delete svg {
|
|
1242
|
-
width: 14px;
|
|
1243
|
-
height: 14px;
|
|
1244
|
-
}
|
|
1245
|
-
`,us=e=>{const t=e.stories.length,a=n=>t===0?0:n/t,s=n=>e.stories.filter(r=>r.statusId===n).length;return{rows:e.statuses.map((n,r)=>{const o=s(n.id);return{id:n.id,name:n.name,tone:n.tone,icon:n.icon,progress:e.statuses.length<=1?1:r/(e.statuses.length-1),previousId:e.statuses[r-1]?.id??null,nextId:e.statuses[r+1]?.id??null,storyCount:o,share:a(o)}})}},ms=Z`
|
|
1246
|
-
:host {
|
|
1247
|
-
--dpk-usm-accent: var(--dpk-blue);
|
|
1248
|
-
}
|
|
1249
|
-
/*
|
|
1250
|
-
* A wide table must scroll inside itself and never widen the template shell.
|
|
1251
|
-
* It scrolls both ways so the backbone can stick to its top and the
|
|
1252
|
-
* milestone column to its left: a box that scrolls only sideways still
|
|
1253
|
-
* becomes the sticky ancestor, and its top would never move. Capped near the
|
|
1254
|
-
* viewport height, it fits under the tab bar once the page brings it up.
|
|
1255
|
-
*/
|
|
1256
|
-
.map-scroll {
|
|
1257
|
-
min-width: 0;
|
|
1258
|
-
max-width: 100%;
|
|
1259
|
-
max-height: max(320px, calc(100dvh - 170px));
|
|
1260
|
-
overflow: auto;
|
|
1261
|
-
overscroll-behavior-x: contain;
|
|
1262
|
-
border: 1px solid var(--dpk-rule);
|
|
1263
|
-
border-radius: var(--dpk-radius-lg);
|
|
1264
|
-
background: var(--dpk-paper-sunken);
|
|
1265
|
-
box-shadow: var(--dpk-shadow);
|
|
1266
|
-
}
|
|
1267
|
-
.map {
|
|
1268
|
-
display: grid;
|
|
1269
|
-
gap: 0;
|
|
1270
|
-
min-width: max-content;
|
|
1271
|
-
/* The map scrolls on its own: its last row clears the hand-off dock at the end of that scroll. */
|
|
1272
|
-
padding-bottom: var(--dpk-dock-clearance, 0px);
|
|
1273
|
-
}
|
|
1274
|
-
.map-row {
|
|
1275
|
-
display: grid;
|
|
1276
|
-
grid-template-columns: 140px repeat(var(--cols), minmax(180px, 240px));
|
|
1277
|
-
}
|
|
1278
|
-
.map-row + .map-row {
|
|
1279
|
-
border-top: 1px solid var(--dpk-rule);
|
|
1280
|
-
}
|
|
1281
|
-
|
|
1282
|
-
/* The backbone (activities and steps) stays at the top while the rows scroll. */
|
|
1283
|
-
.map-head {
|
|
1284
|
-
position: sticky;
|
|
1285
|
-
top: 0;
|
|
1286
|
-
z-index: 3;
|
|
1287
|
-
border-bottom: 1px solid var(--dpk-rule-strong);
|
|
1288
|
-
box-shadow: 0 8px 14px -12px var(--dpk-shade-3);
|
|
1289
|
-
}
|
|
1290
|
-
|
|
1291
|
-
/* The leading column (axis corners and milestone labels) stays at the left
|
|
1292
|
-
while the steps scroll sideways; it is opaque so cards pass under it. */
|
|
1293
|
-
.corner:first-child,
|
|
1294
|
-
.row-lead {
|
|
1295
|
-
position: sticky;
|
|
1296
|
-
left: 0;
|
|
1297
|
-
z-index: 2;
|
|
1298
|
-
box-shadow: 1px 0 0 var(--dpk-rule);
|
|
1299
|
-
}
|
|
1300
|
-
.row-lead {
|
|
1301
|
-
display: flex;
|
|
1302
|
-
flex-direction: column;
|
|
1303
|
-
align-items: flex-start;
|
|
1304
|
-
justify-content: center;
|
|
1305
|
-
gap: 2px;
|
|
1306
|
-
min-width: 0;
|
|
1307
|
-
padding: 8px 6px 8px 4px;
|
|
1308
|
-
background: var(--dpk-paper-sunken);
|
|
1309
|
-
}
|
|
1310
|
-
/* Row names and their meta line share one column: past the grip (15px), its
|
|
1311
|
-
gap (6px) and the inline edit's own padding (4px). */
|
|
1312
|
-
.row-lead {
|
|
1313
|
-
--usm-row-indent: 25px;
|
|
1314
|
-
}
|
|
1315
|
-
.row-meta {
|
|
1316
|
-
display: flex;
|
|
1317
|
-
flex-wrap: wrap;
|
|
1318
|
-
gap: 2px 8px;
|
|
1319
|
-
padding-left: var(--usm-row-indent);
|
|
1320
|
-
font-size: 10.5px;
|
|
1321
|
-
color: var(--dpk-ink-faint);
|
|
1322
|
-
}
|
|
1323
|
-
.row-timeframe {
|
|
1324
|
-
color: var(--dpk-ink-soft);
|
|
1325
|
-
font-weight: 600;
|
|
1326
|
-
}
|
|
1327
|
-
.row-count {
|
|
1328
|
-
font-family: var(--dpk-mono);
|
|
1329
|
-
font-variant-numeric: tabular-nums;
|
|
1330
|
-
}
|
|
1331
|
-
.corner,
|
|
1332
|
-
.act-head,
|
|
1333
|
-
.col-head,
|
|
1334
|
-
.row-head,
|
|
1335
|
-
.cell {
|
|
1336
|
-
padding: 10px;
|
|
1337
|
-
}
|
|
1338
|
-
.corner {
|
|
1339
|
-
background: var(--dpk-paper-sunken);
|
|
1340
|
-
display: grid;
|
|
1341
|
-
gap: 3px;
|
|
1342
|
-
align-content: start;
|
|
1343
|
-
}
|
|
1344
|
-
|
|
1345
|
-
/* Above the content: the page tabs (map / milestones) and, on the map, the
|
|
1346
|
-
unit toggle (group band vs one column per activity). */
|
|
1347
|
-
/* The grid's status filter: one toggle per status, which also reads as the
|
|
1348
|
-
legend of the card colors. */
|
|
1349
|
-
.map-toolbar {
|
|
1350
|
-
display: flex;
|
|
1351
|
-
flex-wrap: wrap;
|
|
1352
|
-
align-items: center;
|
|
1353
|
-
gap: 6px;
|
|
1354
|
-
margin: 16px 0 12px;
|
|
1355
|
-
}
|
|
1356
|
-
.filter-label {
|
|
1357
|
-
margin-right: 4px;
|
|
1358
|
-
color: var(--dpk-ink-faint);
|
|
1359
|
-
font-size: 11px;
|
|
1360
|
-
font-weight: 650;
|
|
1361
|
-
letter-spacing: 0.04em;
|
|
1362
|
-
text-transform: uppercase;
|
|
1363
|
-
}
|
|
1364
|
-
.filter-chip {
|
|
1365
|
-
display: inline-flex;
|
|
1366
|
-
align-items: center;
|
|
1367
|
-
gap: 6px;
|
|
1368
|
-
min-width: 0;
|
|
1369
|
-
max-width: 100%;
|
|
1370
|
-
padding: 3px 9px 3px 7px;
|
|
1371
|
-
border: 1px solid var(--dpk-rule-strong);
|
|
1372
|
-
border-radius: 999px;
|
|
1373
|
-
background: var(--dpk-paper-raised);
|
|
1374
|
-
box-shadow: var(--dpk-bevel), var(--dpk-shadow-xs);
|
|
1375
|
-
color: var(--dpk-ink);
|
|
1376
|
-
font-size: 12px;
|
|
1377
|
-
font-weight: 600;
|
|
1378
|
-
text-decoration: none;
|
|
1379
|
-
transition:
|
|
1380
|
-
background 140ms var(--dpk-ease),
|
|
1381
|
-
border-color 140ms var(--dpk-ease);
|
|
1382
|
-
}
|
|
1383
|
-
/* A long status name ends in an ellipsis; the chip stays a one-line pill. */
|
|
1384
|
-
.filter-chip > :not(.filter-name) {
|
|
1385
|
-
flex: none;
|
|
1386
|
-
}
|
|
1387
|
-
.filter-name {
|
|
1388
|
-
min-width: 0;
|
|
1389
|
-
overflow: hidden;
|
|
1390
|
-
text-overflow: ellipsis;
|
|
1391
|
-
white-space: nowrap;
|
|
1392
|
-
}
|
|
1393
|
-
.filter-chip:hover {
|
|
1394
|
-
border-color: color-mix(in oklab, var(--usm-tone) 60%, var(--dpk-rule-strong));
|
|
1395
|
-
}
|
|
1396
|
-
.filter-chip:focus-visible {
|
|
1397
|
-
outline: none;
|
|
1398
|
-
box-shadow: var(--dpk-focus);
|
|
1399
|
-
}
|
|
1400
|
-
.filter-chip[aria-checked='true'] {
|
|
1401
|
-
border-color: var(--usm-tone);
|
|
1402
|
-
background: color-mix(in oklab, var(--usm-tone) 14%, var(--dpk-paper-raised));
|
|
1403
|
-
box-shadow: inset 0 0 0 1px var(--usm-tone);
|
|
1404
|
-
}
|
|
1405
|
-
.filter-count {
|
|
1406
|
-
line-height: 1;
|
|
1407
|
-
color: var(--dpk-ink-faint);
|
|
1408
|
-
font-family: var(--dpk-mono);
|
|
1409
|
-
font-size: 10.5px;
|
|
1410
|
-
font-variant-numeric: tabular-nums;
|
|
1411
|
-
}
|
|
1412
|
-
.filter-clear {
|
|
1413
|
-
margin-left: 4px;
|
|
1414
|
-
color: var(--dpk-blue);
|
|
1415
|
-
font-size: 12px;
|
|
1416
|
-
font-weight: 600;
|
|
1417
|
-
text-decoration: none;
|
|
1418
|
-
}
|
|
1419
|
-
.filter-clear:hover {
|
|
1420
|
-
text-decoration: underline;
|
|
1421
|
-
}
|
|
1422
|
-
|
|
1423
|
-
.board-bar {
|
|
1424
|
-
border-bottom: 1px solid var(--dpk-rule);
|
|
1425
|
-
/* Stays on top while a long milestone list scrolls under it. */
|
|
1426
|
-
position: sticky;
|
|
1427
|
-
top: 0;
|
|
1428
|
-
z-index: 5;
|
|
1429
|
-
margin: -24px -24px 0;
|
|
1430
|
-
padding: 12px 24px;
|
|
1431
|
-
background: var(--dpk-glass);
|
|
1432
|
-
backdrop-filter: saturate(1.6) blur(14px);
|
|
1433
|
-
display: flex;
|
|
1434
|
-
flex-wrap: wrap;
|
|
1435
|
-
align-items: center;
|
|
1436
|
-
gap: 10px 14px;
|
|
1437
|
-
min-width: 0;
|
|
1438
|
-
}
|
|
1439
|
-
|
|
1440
|
-
/* The two pages: an underlined tab strip, heavier than the view toggle. It
|
|
1441
|
-
scrolls sideways on a phone rather than cutting off the last tab; the
|
|
1442
|
-
bottom padding keeps the selected tab's underline inside the scroller. */
|
|
1443
|
-
.page-tabs {
|
|
1444
|
-
display: inline-flex;
|
|
1445
|
-
gap: 4px;
|
|
1446
|
-
min-width: 0;
|
|
1447
|
-
max-width: 100%;
|
|
1448
|
-
margin-right: auto;
|
|
1449
|
-
margin-bottom: -13px;
|
|
1450
|
-
padding-bottom: 13px;
|
|
1451
|
-
overflow-x: auto;
|
|
1452
|
-
scrollbar-width: none;
|
|
1453
|
-
}
|
|
1454
|
-
.page-tabs [role='tab'] {
|
|
1455
|
-
position: relative;
|
|
1456
|
-
display: inline-flex;
|
|
1457
|
-
align-items: center;
|
|
1458
|
-
gap: 8px;
|
|
1459
|
-
padding: 7px 12px;
|
|
1460
|
-
border-radius: var(--dpk-radius-sm);
|
|
1461
|
-
color: var(--dpk-ink-soft);
|
|
1462
|
-
font-size: 13.5px;
|
|
1463
|
-
font-weight: 600;
|
|
1464
|
-
letter-spacing: -0.005em;
|
|
1465
|
-
text-decoration: none;
|
|
1466
|
-
white-space: nowrap;
|
|
1467
|
-
transition:
|
|
1468
|
-
color 160ms var(--dpk-ease),
|
|
1469
|
-
background 160ms var(--dpk-ease);
|
|
1470
|
-
}
|
|
1471
|
-
.page-tabs [role='tab']:hover {
|
|
1472
|
-
color: var(--dpk-ink);
|
|
1473
|
-
background: var(--dpk-paper-inset);
|
|
1474
|
-
}
|
|
1475
|
-
.page-tabs [role='tab']:focus-visible {
|
|
1476
|
-
outline: none;
|
|
1477
|
-
box-shadow: var(--dpk-focus);
|
|
1478
|
-
}
|
|
1479
|
-
.page-tabs [role='tab'][aria-selected='true'] {
|
|
1480
|
-
color: var(--dpk-ink);
|
|
1481
|
-
font-weight: 700;
|
|
1482
|
-
}
|
|
1483
|
-
.page-tabs [role='tab'][aria-selected='true']::after {
|
|
1484
|
-
content: '';
|
|
1485
|
-
position: absolute;
|
|
1486
|
-
left: 12px;
|
|
1487
|
-
right: 12px;
|
|
1488
|
-
bottom: -13px;
|
|
1489
|
-
height: 2px;
|
|
1490
|
-
border-radius: 2px;
|
|
1491
|
-
background: var(--dpk-usm-accent);
|
|
1492
|
-
}
|
|
1493
|
-
.page-tab-count {
|
|
1494
|
-
min-width: 18px;
|
|
1495
|
-
padding: 0 6px;
|
|
1496
|
-
border-radius: 999px;
|
|
1497
|
-
background: var(--dpk-rule);
|
|
1498
|
-
color: var(--dpk-ink-soft);
|
|
1499
|
-
font-family: var(--dpk-mono);
|
|
1500
|
-
font-size: 10.5px;
|
|
1501
|
-
font-weight: 650;
|
|
1502
|
-
font-variant-numeric: tabular-nums;
|
|
1503
|
-
line-height: 17px;
|
|
1504
|
-
text-align: center;
|
|
1505
|
-
}
|
|
1506
|
-
[role='tab'][aria-selected='true'] .page-tab-count {
|
|
1507
|
-
background: var(--dpk-blue-soft);
|
|
1508
|
-
color: var(--dpk-blue);
|
|
1509
|
-
}
|
|
1510
|
-
|
|
1511
|
-
/* A sunken track with the selected segment raised on top of it. */
|
|
1512
|
-
.segmented {
|
|
1513
|
-
display: inline-flex;
|
|
1514
|
-
gap: 2px;
|
|
1515
|
-
padding: 3px;
|
|
1516
|
-
max-width: 100%;
|
|
1517
|
-
overflow-x: auto;
|
|
1518
|
-
scrollbar-width: none;
|
|
1519
|
-
border: 1px solid var(--dpk-rule);
|
|
1520
|
-
border-radius: 999px;
|
|
1521
|
-
background: var(--dpk-paper-sunken);
|
|
1522
|
-
box-shadow: inset 0 1px 3px var(--dpk-shade-1);
|
|
1523
|
-
}
|
|
1524
|
-
|
|
1525
|
-
.tab {
|
|
1526
|
-
padding: 5px 14px;
|
|
1527
|
-
border-radius: 999px;
|
|
1528
|
-
font-size: 12px;
|
|
1529
|
-
font-weight: 550;
|
|
1530
|
-
text-decoration: none;
|
|
1531
|
-
color: var(--dpk-ink-soft);
|
|
1532
|
-
white-space: nowrap;
|
|
1533
|
-
transition:
|
|
1534
|
-
background 160ms var(--dpk-ease),
|
|
1535
|
-
color 160ms var(--dpk-ease),
|
|
1536
|
-
box-shadow 160ms var(--dpk-ease);
|
|
1537
|
-
}
|
|
1538
|
-
|
|
1539
|
-
.tab:hover {
|
|
1540
|
-
color: var(--dpk-ink);
|
|
1541
|
-
background: var(--dpk-paper-inset);
|
|
1542
|
-
}
|
|
1543
|
-
|
|
1544
|
-
.tab[data-current='true'] {
|
|
1545
|
-
background: var(--dpk-paper-raised);
|
|
1546
|
-
color: var(--dpk-ink);
|
|
1547
|
-
font-weight: 650;
|
|
1548
|
-
box-shadow: var(--dpk-bevel), var(--dpk-shadow-xs);
|
|
1549
|
-
}
|
|
1550
|
-
|
|
1551
|
-
/* Activity band: raised above the working canvas. A head spans its steps,
|
|
1552
|
-
so its contents stay in view beside the sticky column while the map
|
|
1553
|
-
scrolls sideways. */
|
|
1554
|
-
.act-head {
|
|
1555
|
-
position: relative;
|
|
1556
|
-
display: grid;
|
|
1557
|
-
align-content: start;
|
|
1558
|
-
gap: 7px;
|
|
1559
|
-
border-left: 1px solid var(--dpk-rule);
|
|
1560
|
-
background: var(--dpk-paper-raised);
|
|
1561
|
-
box-shadow:
|
|
1562
|
-
var(--dpk-bevel),
|
|
1563
|
-
inset 0 -1px 0 var(--dpk-rule-strong);
|
|
1564
|
-
font-size: 13px;
|
|
1565
|
-
font-weight: 650;
|
|
1566
|
-
letter-spacing: -0.005em;
|
|
1567
|
-
}
|
|
1568
|
-
.act-title,
|
|
1569
|
-
.act-meta,
|
|
1570
|
-
.act-steps {
|
|
1571
|
-
position: sticky;
|
|
1572
|
-
left: 150px;
|
|
1573
|
-
width: min(100%, 340px);
|
|
1574
|
-
min-width: 0;
|
|
1575
|
-
}
|
|
1576
|
-
.act-title {
|
|
1577
|
-
display: flex;
|
|
1578
|
-
align-items: center;
|
|
1579
|
-
gap: 8px;
|
|
1580
|
-
}
|
|
1581
|
-
.act-title > dpk-component-inline-edit {
|
|
1582
|
-
flex: 1 1 auto;
|
|
1583
|
-
min-width: 0;
|
|
1584
|
-
}
|
|
1585
|
-
.act-meta {
|
|
1586
|
-
display: flex;
|
|
1587
|
-
align-items: center;
|
|
1588
|
-
gap: 10px;
|
|
1589
|
-
}
|
|
1590
|
-
.act-meta .status-bar {
|
|
1591
|
-
flex: 1 1 auto;
|
|
1592
|
-
}
|
|
1593
|
-
/* Whose experience the activity is: a label, editable in place. */
|
|
1594
|
-
.act-actor {
|
|
1595
|
-
flex: none;
|
|
1596
|
-
max-width: 60%;
|
|
1597
|
-
padding: 0 4px;
|
|
1598
|
-
border-radius: 999px;
|
|
1599
|
-
background: var(--dpk-blue-soft);
|
|
1600
|
-
color: var(--dpk-blue);
|
|
1601
|
-
font-size: 11px;
|
|
1602
|
-
font-weight: 650;
|
|
1603
|
-
line-height: 20px;
|
|
1604
|
-
}
|
|
1605
|
-
.act-actor[data-empty='true'] {
|
|
1606
|
-
background: transparent;
|
|
1607
|
-
opacity: 0;
|
|
1608
|
-
transition: opacity 150ms ease;
|
|
1609
|
-
}
|
|
1610
|
-
.act-head:hover .act-actor[data-empty='true'],
|
|
1611
|
-
.act-actor[data-empty='true']:focus-within {
|
|
1612
|
-
opacity: 1;
|
|
1613
|
-
}
|
|
1614
|
-
/* The group view gives the steps no columns; the head lists them instead. */
|
|
1615
|
-
.act-steps {
|
|
1616
|
-
display: grid;
|
|
1617
|
-
gap: 3px;
|
|
1618
|
-
margin: 0;
|
|
1619
|
-
padding: 0 0 0 18px;
|
|
1620
|
-
color: var(--dpk-ink-soft);
|
|
1621
|
-
font-size: 11.5px;
|
|
1622
|
-
font-weight: 500;
|
|
1623
|
-
line-height: 1.45;
|
|
1624
|
-
}
|
|
1625
|
-
.act-steps li::marker {
|
|
1626
|
-
color: var(--dpk-ink-faint);
|
|
1627
|
-
font-family: var(--dpk-mono);
|
|
1628
|
-
font-size: 10px;
|
|
1629
|
-
}
|
|
1630
|
-
.act-head .count,
|
|
1631
|
-
.col-head .count {
|
|
1632
|
-
flex: 0 0 auto;
|
|
1633
|
-
padding: 0 6px;
|
|
1634
|
-
border-radius: 999px;
|
|
1635
|
-
background: var(--dpk-rule);
|
|
1636
|
-
line-height: 16px;
|
|
1637
|
-
}
|
|
1638
|
-
.col-head {
|
|
1639
|
-
display: flex;
|
|
1640
|
-
align-items: center;
|
|
1641
|
-
gap: 6px;
|
|
1642
|
-
border-left: 1px solid var(--dpk-rule);
|
|
1643
|
-
background: var(--dpk-paper-sunken);
|
|
1644
|
-
transition: background 160ms var(--dpk-ease);
|
|
1645
|
-
}
|
|
1646
|
-
.col-head h4 {
|
|
1647
|
-
flex: 1 1 auto;
|
|
1648
|
-
min-width: 0;
|
|
1649
|
-
}
|
|
1650
|
-
.col-head[data-current='true'] {
|
|
1651
|
-
background: color-mix(in srgb, var(--dpk-usm-accent) 8%, var(--dpk-paper-sunken));
|
|
1652
|
-
}
|
|
1653
|
-
.col-head h4 {
|
|
1654
|
-
font-size: 13px;
|
|
1655
|
-
font-weight: 600;
|
|
1656
|
-
margin: 0;
|
|
1657
|
-
}
|
|
1658
|
-
|
|
1659
|
-
.row-head {
|
|
1660
|
-
display: flex;
|
|
1661
|
-
align-items: center;
|
|
1662
|
-
gap: 6px;
|
|
1663
|
-
}
|
|
1664
|
-
|
|
1665
|
-
/* Milestone row label: plain text with a grip, not a chip. The "add
|
|
1666
|
-
milestone" row reuses \`.row-head\` for its ghost button. */
|
|
1667
|
-
.row-head[data-milestone] {
|
|
1668
|
-
align-self: stretch;
|
|
1669
|
-
margin: 0;
|
|
1670
|
-
padding: 0 6px 0 0;
|
|
1671
|
-
color: var(--dpk-ink);
|
|
1672
|
-
font-size: 12.5px;
|
|
1673
|
-
font-weight: 650;
|
|
1674
|
-
max-width: 100%;
|
|
1675
|
-
}
|
|
1676
|
-
|
|
1677
|
-
.row-head[draggable='true'] {
|
|
1678
|
-
cursor: grab;
|
|
1679
|
-
-webkit-user-select: none;
|
|
1680
|
-
user-select: none;
|
|
1681
|
-
}
|
|
1682
|
-
|
|
1683
|
-
.row-head[draggable='true'] dpk-component-inline-edit {
|
|
1684
|
-
-webkit-user-drag: none;
|
|
1685
|
-
}
|
|
1686
|
-
|
|
1687
|
-
.row-head[draggable='true']:active {
|
|
1688
|
-
cursor: grabbing;
|
|
1689
|
-
}
|
|
1690
|
-
|
|
1691
|
-
.row-grip {
|
|
1692
|
-
flex: 0 0 auto;
|
|
1693
|
-
display: inline-flex;
|
|
1694
|
-
color: var(--dpk-ink-faint);
|
|
1695
|
-
}
|
|
1696
|
-
|
|
1697
|
-
.row-grip svg {
|
|
1698
|
-
display: block;
|
|
1699
|
-
width: 15px;
|
|
1700
|
-
height: 15px;
|
|
1701
|
-
}
|
|
1702
|
-
|
|
1703
|
-
/* Row-level drag affordance: only the grip answers the hover. */
|
|
1704
|
-
.map-row[data-draggable='true']:hover .row-grip {
|
|
1705
|
-
color: var(--dpk-blue);
|
|
1706
|
-
}
|
|
1707
|
-
.map-row[data-draggable='true'] {
|
|
1708
|
-
cursor: grab;
|
|
1709
|
-
}
|
|
1710
|
-
.map-row[data-draggable='true']:active {
|
|
1711
|
-
cursor: grabbing;
|
|
1712
|
-
}
|
|
1713
|
-
|
|
1714
|
-
/*
|
|
1715
|
-
* Dragging state: entire row fades. Never disable pointer events on the
|
|
1716
|
-
* source here: Lit applies this state in the microtask right after
|
|
1717
|
-
* \`dragstart\`, and Blink then re-hit-tests the pointer and aborts the drag
|
|
1718
|
-
* when the source is no longer under it.
|
|
1719
|
-
*/
|
|
1720
|
-
.map-row[data-row-dragging='true'] {
|
|
1721
|
-
opacity: 0.45;
|
|
1722
|
-
}
|
|
1723
|
-
|
|
1724
|
-
/* Drop target: entire row highlights. */
|
|
1725
|
-
.map-row[data-row-drop='true'] {
|
|
1726
|
-
outline: 2px dashed var(--dpk-blue);
|
|
1727
|
-
outline-offset: -2px;
|
|
1728
|
-
}
|
|
1729
|
-
|
|
1730
|
-
/* Unassigned is a holding area, not a release: its label is quieter. */
|
|
1731
|
-
.map-row[data-unassigned='true'] .row-head {
|
|
1732
|
-
padding-left: var(--usm-row-indent);
|
|
1733
|
-
color: var(--dpk-ink-soft);
|
|
1734
|
-
}
|
|
1735
|
-
|
|
1736
|
-
/* Cells are the working canvas: sunken, with a quiet dot lattice, so raised
|
|
1737
|
-
story cards read as things placed on the board. */
|
|
1738
|
-
.cell {
|
|
1739
|
-
border-left: 1px solid var(--dpk-rule);
|
|
1740
|
-
border-top: 1px solid var(--dpk-rule);
|
|
1741
|
-
display: flex;
|
|
1742
|
-
flex-direction: column;
|
|
1743
|
-
gap: 8px;
|
|
1744
|
-
min-height: 100px;
|
|
1745
|
-
background: var(--dpk-dots), var(--dpk-paper-sunken);
|
|
1746
|
-
transition: background 160ms var(--dpk-ease);
|
|
1747
|
-
}
|
|
1748
|
-
.cell[data-drop='true'] {
|
|
1749
|
-
outline: 2px dashed var(--dpk-blue);
|
|
1750
|
-
outline-offset: -2px;
|
|
1751
|
-
}
|
|
1752
|
-
.card-list {
|
|
1753
|
-
display: grid;
|
|
1754
|
-
gap: 10px;
|
|
1755
|
-
align-content: start;
|
|
1756
|
-
flex: 1 1 auto;
|
|
1757
|
-
}
|
|
1758
|
-
.add-cell {
|
|
1759
|
-
margin-top: auto;
|
|
1760
|
-
opacity: 0;
|
|
1761
|
-
transition:
|
|
1762
|
-
opacity 180ms var(--dpk-ease),
|
|
1763
|
-
background 160ms var(--dpk-ease),
|
|
1764
|
-
border-color 160ms var(--dpk-ease),
|
|
1765
|
-
color 160ms var(--dpk-ease);
|
|
1766
|
-
border: 1px dashed var(--dpk-rule-strong);
|
|
1767
|
-
border-radius: var(--dpk-radius-sm);
|
|
1768
|
-
background: transparent;
|
|
1769
|
-
color: var(--dpk-ink-faint);
|
|
1770
|
-
padding: 4px 8px;
|
|
1771
|
-
font-size: 11.5px;
|
|
1772
|
-
}
|
|
1773
|
-
.add-cell:hover {
|
|
1774
|
-
background: var(--dpk-blue-soft);
|
|
1775
|
-
border-color: var(--dpk-blue);
|
|
1776
|
-
color: var(--dpk-blue);
|
|
1777
|
-
}
|
|
1778
|
-
.cell:hover .add-cell {
|
|
1779
|
-
opacity: 1;
|
|
1780
|
-
}
|
|
1781
|
-
.empty {
|
|
1782
|
-
border: 1px dashed var(--dpk-rule-strong);
|
|
1783
|
-
border-radius: var(--dpk-radius-lg);
|
|
1784
|
-
padding: 28px 24px;
|
|
1785
|
-
background: var(--dpk-dots), var(--dpk-paper-sunken);
|
|
1786
|
-
max-width: 620px;
|
|
1787
|
-
display: grid;
|
|
1788
|
-
gap: 10px;
|
|
1789
|
-
}
|
|
1790
|
-
.count {
|
|
1791
|
-
font-family: var(--dpk-mono);
|
|
1792
|
-
font-variant-numeric: tabular-nums;
|
|
1793
|
-
font-size: 10px;
|
|
1794
|
-
color: var(--dpk-ink-faint);
|
|
1795
|
-
}
|
|
1796
|
-
|
|
1797
|
-
/* ------------------------------------------------------ milestones tab */
|
|
1798
|
-
|
|
1799
|
-
/* The release slices as a timeline, like the experience section of a
|
|
1800
|
-
portfolio: when on the left, one node per slice on a single rail, what
|
|
1801
|
-
and how big on the right. Nothing is boxed; the rail carries the order. */
|
|
1802
|
-
.ms-overview {
|
|
1803
|
-
--ms-node: 30px;
|
|
1804
|
-
--ms-when: 132px;
|
|
1805
|
-
--ms-gap: 44px;
|
|
1806
|
-
display: grid;
|
|
1807
|
-
gap: 28px;
|
|
1808
|
-
max-width: 920px;
|
|
1809
|
-
padding: 28px 0 40px;
|
|
1810
|
-
}
|
|
1811
|
-
.ms-timeline {
|
|
1812
|
-
margin: 0;
|
|
1813
|
-
padding: 0;
|
|
1814
|
-
list-style: none;
|
|
1815
|
-
}
|
|
1816
|
-
.ms-entry,
|
|
1817
|
-
.ms-add {
|
|
1818
|
-
display: grid;
|
|
1819
|
-
grid-template-columns: var(--ms-when) var(--ms-node) minmax(0, 1fr);
|
|
1820
|
-
grid-template-areas: 'when rail body';
|
|
1821
|
-
column-gap: 24px;
|
|
1822
|
-
}
|
|
1823
|
-
.ms-entry {
|
|
1824
|
-
padding-bottom: var(--ms-gap);
|
|
1825
|
-
}
|
|
1826
|
-
.ms-when {
|
|
1827
|
-
grid-area: when;
|
|
1828
|
-
display: flex;
|
|
1829
|
-
justify-content: flex-end;
|
|
1830
|
-
padding-top: 5px;
|
|
1831
|
-
}
|
|
1832
|
-
.ms-timeframe {
|
|
1833
|
-
color: var(--dpk-ink);
|
|
1834
|
-
font-size: 13px;
|
|
1835
|
-
font-weight: 650;
|
|
1836
|
-
font-variant-numeric: tabular-nums;
|
|
1837
|
-
letter-spacing: 0.01em;
|
|
1838
|
-
text-align: right;
|
|
1839
|
-
}
|
|
1840
|
-
.ms-timeframe[data-empty='true'] {
|
|
1841
|
-
color: var(--dpk-ink-faint);
|
|
1842
|
-
font-weight: 500;
|
|
1843
|
-
}
|
|
1844
|
-
|
|
1845
|
-
/* The rail runs through every entry's padding, so the nodes read as one line;
|
|
1846
|
-
it starts at the first node and fades out into the add node. */
|
|
1847
|
-
.ms-rail {
|
|
1848
|
-
grid-area: rail;
|
|
1849
|
-
position: relative;
|
|
1850
|
-
display: flex;
|
|
1851
|
-
justify-content: center;
|
|
1852
|
-
}
|
|
1853
|
-
.ms-rail::before {
|
|
1854
|
-
content: '';
|
|
1855
|
-
position: absolute;
|
|
1856
|
-
top: 0;
|
|
1857
|
-
bottom: calc(-1 * var(--ms-gap));
|
|
1858
|
-
left: calc(50% - 1px);
|
|
1859
|
-
width: 2px;
|
|
1860
|
-
border-radius: 1px;
|
|
1861
|
-
background: var(--dpk-rule-strong);
|
|
1862
|
-
}
|
|
1863
|
-
.ms-entry:first-child .ms-rail::before {
|
|
1864
|
-
top: calc(var(--ms-node) / 2);
|
|
1865
|
-
}
|
|
1866
|
-
.ms-add .ms-rail::before {
|
|
1867
|
-
bottom: auto;
|
|
1868
|
-
height: calc(var(--ms-node) / 2);
|
|
1869
|
-
background: repeating-linear-gradient(to bottom, var(--dpk-rule-strong) 0 3px, transparent 3px 7px);
|
|
1870
|
-
}
|
|
1871
|
-
.ms-node {
|
|
1872
|
-
position: relative;
|
|
1873
|
-
display: grid;
|
|
1874
|
-
place-items: center;
|
|
1875
|
-
width: var(--ms-node);
|
|
1876
|
-
height: var(--ms-node);
|
|
1877
|
-
box-sizing: border-box;
|
|
1878
|
-
border: 1px solid var(--dpk-rule-strong);
|
|
1879
|
-
border-radius: 50%;
|
|
1880
|
-
background: var(--dpk-paper-raised);
|
|
1881
|
-
color: var(--dpk-ink);
|
|
1882
|
-
font-family: var(--dpk-mono);
|
|
1883
|
-
font-size: 12px;
|
|
1884
|
-
font-weight: 700;
|
|
1885
|
-
font-variant-numeric: tabular-nums;
|
|
1886
|
-
/* A ring of page color cuts the rail around the node. */
|
|
1887
|
-
box-shadow:
|
|
1888
|
-
0 0 0 5px var(--dpk-paper),
|
|
1889
|
-
var(--dpk-bevel),
|
|
1890
|
-
var(--dpk-shadow-xs);
|
|
1891
|
-
transition:
|
|
1892
|
-
border-color 160ms var(--dpk-ease),
|
|
1893
|
-
color 160ms var(--dpk-ease);
|
|
1894
|
-
}
|
|
1895
|
-
.ms-entry:hover .ms-node,
|
|
1896
|
-
.ms-entry:focus-within .ms-node {
|
|
1897
|
-
border-color: var(--dpk-blue);
|
|
1898
|
-
color: var(--dpk-blue-strong);
|
|
1899
|
-
}
|
|
1900
|
-
.ms-node--add {
|
|
1901
|
-
border-style: dashed;
|
|
1902
|
-
background: var(--dpk-paper);
|
|
1903
|
-
box-shadow: 0 0 0 5px var(--dpk-paper);
|
|
1904
|
-
}
|
|
1905
|
-
.ms-node--add::before,
|
|
1906
|
-
.ms-node--add::after {
|
|
1907
|
-
content: '';
|
|
1908
|
-
position: absolute;
|
|
1909
|
-
left: 50%;
|
|
1910
|
-
top: 50%;
|
|
1911
|
-
width: 10px;
|
|
1912
|
-
height: 1.5px;
|
|
1913
|
-
border-radius: 1px;
|
|
1914
|
-
background: var(--dpk-ink-faint);
|
|
1915
|
-
transform: translate(-50%, -50%);
|
|
1916
|
-
}
|
|
1917
|
-
.ms-node--add::after {
|
|
1918
|
-
transform: translate(-50%, -50%) rotate(90deg);
|
|
1919
|
-
}
|
|
1920
|
-
.ms-add .ms-body {
|
|
1921
|
-
display: flex;
|
|
1922
|
-
align-items: center;
|
|
1923
|
-
min-height: var(--ms-node);
|
|
1924
|
-
}
|
|
1925
|
-
/* The label lines up with the names above; the button's padding hangs out. */
|
|
1926
|
-
.ms-add .dpk-btn {
|
|
1927
|
-
margin-left: -12px;
|
|
1928
|
-
}
|
|
1929
|
-
|
|
1930
|
-
.ms-body {
|
|
1931
|
-
grid-area: body;
|
|
1932
|
-
display: grid;
|
|
1933
|
-
gap: 10px;
|
|
1934
|
-
min-width: 0;
|
|
1935
|
-
justify-items: start;
|
|
1936
|
-
}
|
|
1937
|
-
.ms-name {
|
|
1938
|
-
justify-self: stretch;
|
|
1939
|
-
min-width: 0;
|
|
1940
|
-
margin: 0;
|
|
1941
|
-
padding-top: 1px;
|
|
1942
|
-
font-size: 19px;
|
|
1943
|
-
font-weight: 700;
|
|
1944
|
-
line-height: 1.4;
|
|
1945
|
-
letter-spacing: -0.015em;
|
|
1946
|
-
}
|
|
1947
|
-
/* The field pads its text by 4px; pull it out by as much so the name lines
|
|
1948
|
-
up with the description and keeps its place when editing starts. */
|
|
1949
|
-
.ms-name dpk-component-inline-edit {
|
|
1950
|
-
display: block;
|
|
1951
|
-
margin: 0 -4px;
|
|
1952
|
-
}
|
|
1953
|
-
.ms-description {
|
|
1954
|
-
margin: 0;
|
|
1955
|
-
max-width: 64ch;
|
|
1956
|
-
color: var(--dpk-ink-soft);
|
|
1957
|
-
font-size: 14px;
|
|
1958
|
-
line-height: 1.75;
|
|
1959
|
-
white-space: pre-wrap;
|
|
1960
|
-
}
|
|
1961
|
-
.ms-description[data-empty='true'] {
|
|
1962
|
-
color: var(--dpk-ink-faint);
|
|
1963
|
-
font-size: 13px;
|
|
1964
|
-
}
|
|
1965
|
-
.ms-facts {
|
|
1966
|
-
display: flex;
|
|
1967
|
-
flex-wrap: wrap;
|
|
1968
|
-
gap: 10px 36px;
|
|
1969
|
-
margin: 6px 0 0;
|
|
1970
|
-
}
|
|
1971
|
-
.ms-facts dt {
|
|
1972
|
-
margin-bottom: 3px;
|
|
1973
|
-
color: var(--dpk-ink-faint);
|
|
1974
|
-
font-size: 11px;
|
|
1975
|
-
font-weight: 600;
|
|
1976
|
-
letter-spacing: 0.02em;
|
|
1977
|
-
}
|
|
1978
|
-
.ms-facts dd {
|
|
1979
|
-
display: flex;
|
|
1980
|
-
align-items: center;
|
|
1981
|
-
gap: 10px;
|
|
1982
|
-
margin: 0;
|
|
1983
|
-
color: var(--dpk-ink-faint);
|
|
1984
|
-
font-size: 12px;
|
|
1985
|
-
}
|
|
1986
|
-
.ms-facts strong {
|
|
1987
|
-
color: var(--dpk-ink);
|
|
1988
|
-
font-size: 15px;
|
|
1989
|
-
font-weight: 650;
|
|
1990
|
-
font-variant-numeric: tabular-nums;
|
|
1991
|
-
}
|
|
1992
|
-
.ms-meter {
|
|
1993
|
-
display: block;
|
|
1994
|
-
width: 72px;
|
|
1995
|
-
height: 4px;
|
|
1996
|
-
border-radius: 2px;
|
|
1997
|
-
background: var(--dpk-paper-inset);
|
|
1998
|
-
overflow: hidden;
|
|
1999
|
-
}
|
|
2000
|
-
.ms-meter > span {
|
|
2001
|
-
display: block;
|
|
2002
|
-
height: 100%;
|
|
2003
|
-
border-radius: inherit;
|
|
2004
|
-
background: var(--dpk-blue);
|
|
2005
|
-
}
|
|
2006
|
-
|
|
2007
|
-
/* Where the slice's stories sit across the backbone, in activity tones. */
|
|
2008
|
-
.ms-breakdown {
|
|
2009
|
-
display: grid;
|
|
2010
|
-
gap: 10px;
|
|
2011
|
-
width: min(100%, 460px);
|
|
2012
|
-
margin-top: 4px;
|
|
2013
|
-
}
|
|
2014
|
-
.ms-breakdown .status-bar {
|
|
2015
|
-
height: 8px;
|
|
2016
|
-
}
|
|
2017
|
-
.ms-legend {
|
|
2018
|
-
display: flex;
|
|
2019
|
-
flex-wrap: wrap;
|
|
2020
|
-
gap: 6px 16px;
|
|
2021
|
-
margin: 0;
|
|
2022
|
-
padding: 0;
|
|
2023
|
-
list-style: none;
|
|
2024
|
-
}
|
|
2025
|
-
.ms-legend li {
|
|
2026
|
-
display: inline-flex;
|
|
2027
|
-
align-items: center;
|
|
2028
|
-
gap: 6px;
|
|
2029
|
-
color: var(--dpk-ink-soft);
|
|
2030
|
-
font-size: 12px;
|
|
2031
|
-
}
|
|
2032
|
-
.ms-breakdown-count {
|
|
2033
|
-
color: var(--dpk-ink-faint);
|
|
2034
|
-
font-family: var(--dpk-mono);
|
|
2035
|
-
font-size: 11px;
|
|
2036
|
-
font-variant-numeric: tabular-nums;
|
|
2037
|
-
}
|
|
2038
|
-
|
|
2039
|
-
/* Narrow: the date moves above the name, the rail stays on the left. */
|
|
2040
|
-
@media (max-width: 640px) {
|
|
2041
|
-
.ms-overview {
|
|
2042
|
-
--ms-node: 26px;
|
|
2043
|
-
}
|
|
2044
|
-
.ms-entry,
|
|
2045
|
-
.ms-add {
|
|
2046
|
-
grid-template-columns: var(--ms-node) minmax(0, 1fr);
|
|
2047
|
-
grid-template-areas:
|
|
2048
|
-
'rail when'
|
|
2049
|
-
'rail body';
|
|
2050
|
-
column-gap: 16px;
|
|
2051
|
-
}
|
|
2052
|
-
.ms-add {
|
|
2053
|
-
grid-template-areas: 'rail body';
|
|
2054
|
-
}
|
|
2055
|
-
.ms-add .ms-when {
|
|
2056
|
-
display: none;
|
|
2057
|
-
}
|
|
2058
|
-
.ms-when {
|
|
2059
|
-
justify-content: flex-start;
|
|
2060
|
-
padding: 4px 0 2px;
|
|
2061
|
-
}
|
|
2062
|
-
.ms-timeframe {
|
|
2063
|
-
text-align: left;
|
|
2064
|
-
}
|
|
2065
|
-
}
|
|
2066
|
-
|
|
2067
|
-
/* ------------------------------------------------------- statuses tab */
|
|
2068
|
-
|
|
2069
|
-
/* The statuses in order, one row each: color, name, how many stories stand
|
|
2070
|
-
there, the palette to recolor it, and the order / delete tools. */
|
|
2071
|
-
.st-overview {
|
|
2072
|
-
display: grid;
|
|
2073
|
-
gap: 20px;
|
|
2074
|
-
max-width: 1040px;
|
|
2075
|
-
padding: 28px 0 40px;
|
|
2076
|
-
}
|
|
2077
|
-
.st-list {
|
|
2078
|
-
display: grid;
|
|
2079
|
-
margin: 0;
|
|
2080
|
-
padding: 0;
|
|
2081
|
-
list-style: none;
|
|
2082
|
-
border: 1px solid var(--dpk-rule);
|
|
2083
|
-
border-radius: var(--dpk-radius-lg);
|
|
2084
|
-
background: var(--dpk-paper-raised);
|
|
2085
|
-
box-shadow: var(--dpk-shadow-xs);
|
|
2086
|
-
}
|
|
2087
|
-
.st-row {
|
|
2088
|
-
display: grid;
|
|
2089
|
-
/* Fixed tool columns keep the unset row, which has no tools, in line. */
|
|
2090
|
-
grid-template-columns: 16px minmax(120px, 1fr) minmax(140px, 200px) 150px 84px;
|
|
2091
|
-
align-items: center;
|
|
2092
|
-
gap: 14px;
|
|
2093
|
-
padding: 12px 16px;
|
|
2094
|
-
}
|
|
2095
|
-
.st-row + .st-row {
|
|
2096
|
-
border-top: 1px solid var(--dpk-rule);
|
|
2097
|
-
}
|
|
2098
|
-
.st-name {
|
|
2099
|
-
min-width: 0;
|
|
2100
|
-
font-size: 14px;
|
|
2101
|
-
font-weight: 650;
|
|
2102
|
-
}
|
|
2103
|
-
.st-share {
|
|
2104
|
-
display: grid;
|
|
2105
|
-
gap: 5px;
|
|
2106
|
-
}
|
|
2107
|
-
.st-share-text {
|
|
2108
|
-
color: var(--dpk-ink-faint);
|
|
2109
|
-
font-family: var(--dpk-mono);
|
|
2110
|
-
font-size: 11px;
|
|
2111
|
-
font-variant-numeric: tabular-nums;
|
|
2112
|
-
}
|
|
2113
|
-
.st-meter {
|
|
2114
|
-
height: 5px;
|
|
2115
|
-
border-radius: 3px;
|
|
2116
|
-
background: var(--dpk-paper-sunken);
|
|
2117
|
-
overflow: hidden;
|
|
2118
|
-
}
|
|
2119
|
-
.st-meter > span {
|
|
2120
|
-
display: block;
|
|
2121
|
-
height: 100%;
|
|
2122
|
-
border-radius: 3px;
|
|
2123
|
-
background: var(--usm-tone);
|
|
2124
|
-
}
|
|
2125
|
-
.st-tones {
|
|
2126
|
-
display: inline-flex;
|
|
2127
|
-
flex-wrap: wrap;
|
|
2128
|
-
gap: 5px;
|
|
2129
|
-
}
|
|
2130
|
-
/* The status's own icon opens the menu of icons. */
|
|
2131
|
-
.st-icon-trigger {
|
|
2132
|
-
display: inline-grid;
|
|
2133
|
-
place-items: center;
|
|
2134
|
-
width: 30px;
|
|
2135
|
-
height: 30px;
|
|
2136
|
-
margin: -7px;
|
|
2137
|
-
padding: 0;
|
|
2138
|
-
border: 1px solid transparent;
|
|
2139
|
-
border-radius: var(--dpk-radius-sm);
|
|
2140
|
-
background: transparent;
|
|
2141
|
-
cursor: pointer;
|
|
2142
|
-
transition:
|
|
2143
|
-
background 140ms var(--dpk-ease),
|
|
2144
|
-
border-color 140ms var(--dpk-ease);
|
|
2145
|
-
}
|
|
2146
|
-
.st-icon-trigger:hover,
|
|
2147
|
-
.st-icon-trigger[aria-expanded='true'] {
|
|
2148
|
-
border-color: var(--dpk-rule-strong);
|
|
2149
|
-
background: var(--dpk-paper-raised);
|
|
2150
|
-
box-shadow: var(--dpk-shadow-xs);
|
|
2151
|
-
}
|
|
2152
|
-
.st-icon-trigger:focus-visible {
|
|
2153
|
-
outline: none;
|
|
2154
|
-
box-shadow: var(--dpk-focus);
|
|
2155
|
-
}
|
|
2156
|
-
.comment-pop.icon-menu {
|
|
2157
|
-
grid-template-columns: repeat(5, 36px);
|
|
2158
|
-
gap: 4px;
|
|
2159
|
-
padding: 8px;
|
|
2160
|
-
}
|
|
2161
|
-
.icon-option {
|
|
2162
|
-
display: inline-grid;
|
|
2163
|
-
place-items: center;
|
|
2164
|
-
width: 36px;
|
|
2165
|
-
height: 36px;
|
|
2166
|
-
padding: 0;
|
|
2167
|
-
border: 1px solid transparent;
|
|
2168
|
-
border-radius: var(--dpk-radius-sm);
|
|
2169
|
-
background: transparent;
|
|
2170
|
-
cursor: pointer;
|
|
2171
|
-
}
|
|
2172
|
-
.icon-option .status-icon {
|
|
2173
|
-
width: 18px;
|
|
2174
|
-
height: 18px;
|
|
2175
|
-
}
|
|
2176
|
-
.icon-option:hover,
|
|
2177
|
-
.icon-option:focus-visible {
|
|
2178
|
-
outline: none;
|
|
2179
|
-
background: var(--dpk-paper-inset);
|
|
2180
|
-
}
|
|
2181
|
-
.icon-option[aria-checked='true'] {
|
|
2182
|
-
border-color: color-mix(in oklab, var(--usm-tone) 55%, transparent);
|
|
2183
|
-
background: color-mix(in oklab, var(--usm-tone) 12%, transparent);
|
|
2184
|
-
}
|
|
2185
|
-
.st-tone {
|
|
2186
|
-
width: 18px;
|
|
2187
|
-
height: 18px;
|
|
2188
|
-
padding: 0;
|
|
2189
|
-
border: 2px solid var(--dpk-paper-raised);
|
|
2190
|
-
border-radius: 50%;
|
|
2191
|
-
background: var(--usm-tone);
|
|
2192
|
-
box-shadow: 0 0 0 1px var(--dpk-rule-strong);
|
|
2193
|
-
cursor: pointer;
|
|
2194
|
-
transition: box-shadow 150ms ease;
|
|
2195
|
-
}
|
|
2196
|
-
.st-tone:hover {
|
|
2197
|
-
box-shadow: 0 0 0 1px var(--usm-tone);
|
|
2198
|
-
}
|
|
2199
|
-
.st-tone[aria-checked='true'] {
|
|
2200
|
-
box-shadow: 0 0 0 2px var(--usm-tone);
|
|
2201
|
-
}
|
|
2202
|
-
.st-tone:focus-visible {
|
|
2203
|
-
outline: none;
|
|
2204
|
-
box-shadow: var(--dpk-focus);
|
|
2205
|
-
}
|
|
2206
|
-
/* A label's color, where a status shows its icon. */
|
|
2207
|
-
.label-swatch {
|
|
2208
|
-
width: 12px;
|
|
2209
|
-
height: 12px;
|
|
2210
|
-
border-radius: 4px;
|
|
2211
|
-
background: var(--usm-tone);
|
|
2212
|
-
}
|
|
2213
|
-
.st-tools {
|
|
2214
|
-
display: inline-flex;
|
|
2215
|
-
gap: 2px;
|
|
2216
|
-
}
|
|
2217
|
-
.st-tools .dpk-icon-btn {
|
|
2218
|
-
width: 26px;
|
|
2219
|
-
height: 26px;
|
|
2220
|
-
font-size: 13px;
|
|
2221
|
-
}
|
|
2222
|
-
@media (max-width: 640px) {
|
|
2223
|
-
.st-row {
|
|
2224
|
-
grid-template-columns: 16px minmax(0, 1fr) auto;
|
|
2225
|
-
row-gap: 8px;
|
|
2226
|
-
}
|
|
2227
|
-
.st-share,
|
|
2228
|
-
.st-tones {
|
|
2229
|
-
grid-column: 2 / -1;
|
|
2230
|
-
}
|
|
2231
|
-
/* The tools stay on the name's row, so the rows below are the name's width. */
|
|
2232
|
-
.st-tools {
|
|
2233
|
-
grid-column: 3;
|
|
2234
|
-
grid-row: 1;
|
|
2235
|
-
}
|
|
2236
|
-
}
|
|
2237
|
-
|
|
2238
|
-
/* Step picker shown after a cross-activity drop. */
|
|
2239
|
-
.move-dialog {
|
|
2240
|
-
min-width: 220px;
|
|
2241
|
-
}
|
|
2242
|
-
`,X={kind:"idle"},gs={width:300,height:240},hs={width:228,height:116};class bt extends ye{static{this.styles=[ye.styles,ms,He,je,cs,Yt]}definitionFor(t){return Ge(t)}static{this.properties={mode:{state:!0}}}#a=new Ft(this);#e=new Ut(this);#t=null;#i=null;constructor(){super(),this.mode=X,new Gt(this,{open:()=>this.#s()!==null,closesOn:t=>this.#n(t),ownsEscape:t=>this.mode.kind==="idle"&&(t.includes(this)||t[0]===document.body||t[0]===document.documentElement),dismiss:()=>this.context().navigate({story:null})})}renderRegions(t){return{main:this.#l(t)}}updated(){if(super.updated(),this.#o(),this.#r(),this.mode.kind==="picking-icon"){const a=this.renderRoot.querySelector("#icon-menu"),s=this.renderRoot.querySelector(`[data-icon-trigger="${CSS.escape(this.mode.statusId)}"]`);a&&s&&this.#e.open(a,s,hs);return}if(this.mode.kind!=="picking-step")return;const t=this.renderRoot.querySelector("#move-dialog");t&&this.#e.open(t,zt(this.mode.point.x,this.mode.point.y),gs)}#s(){return this.renderRoot.querySelector(".story-panel")}#n(t){const a=this.#s(),s=this.renderRoot.querySelector(".dpk-main");return!a||!s||t.includes(a)||!t.includes(s)?!1:!t.some(i=>i instanceof Element&&(i.localName==="dpk-internal-usm-story-card"||i.hasAttribute("popover")))}#r(){const t=this.#s(),a=t?.dataset.story??null,s=this.#t;if(a===s)return;this.#t=a;const i=this.shadowRoot?.activeElement??null;if(t){(!i||!t.contains(i))&&t.focus({preventScroll:!0});return}s===null||i!==null&&i.isConnected||this.renderRoot.querySelector(`dpk-internal-usm-story-card[data-story="${CSS.escape(s)}"]`)?.focus({preventScroll:!0})}#o(){const t=this.renderRoot.querySelector(".page-tabs"),a=t?.querySelector('[aria-selected="true"]'),s=a?.getAttribute("href")??null;!t||!a||s===this.#i||(this.#i=s,Pt(t,a))}#l(t){const a=se(this.locale),s=Re(t.navigation);return l`
|
|
2243
|
-
${is(a,t,s)} ${this.#p(a,t,s)} ${this.#d(a,t,s)}
|
|
2244
|
-
${ss(a,t,this.mode,{confirm:i=>this.#b(i),cancel:()=>this.mode=X})}
|
|
2245
|
-
`}#d(t,a,s){if(s!=="map")return v;const i=ns(a);return i?rs(t,a,i):v}#p(t,a,s){switch(s){case"milestones":return es(t,a,Da(a.state));case"statuses":return Ha(t,a,us(a.state),{openFor:this.mode.kind==="picking-icon"?this.mode.statusId:null,toggle:i=>{const n=this.mode.kind==="picking-icon"&&this.mode.statusId===i;this.mode=n?X:{kind:"picking-icon",statusId:i}},close:()=>this.mode=X});case"labels":return Ja(t,a,Oa(a.state));case"map":return this.#c(t,a)}}#c(t,a){return Ya({m:t,context:a,drag:this.#a,handlers:{selectStory:s=>this.#u(s),dropOnCell:(s,i)=>this.#m(s,i),dropOnGroupCell:(s,i,n)=>this.#g(s,i,n),dropOnMilestoneRow:(s,i)=>this.#h(s,i)}})}#u(t){const a=this.context(),s=S(a.state,t);s&&a.navigate({step:s.stepId,story:s.id})}#m(t,a){const s=this.context();s.dispatch(We(s.state,t,a.item.id,a.hoveredId,a.place))}#g(t,a,s){const i=this.context(),n=S(i.state,s.item.id);if(!n)return;if(n.activityId!==t){this.mode={kind:"picking-step",storyId:n.id,activityId:t,milestoneId:a,point:{x:s.event.clientX,y:s.event.clientY}};return}const r=Xe(i.state,t,a,n.id,s.hoveredId,s.place);r&&i.dispatch(r)}#h(t,a){const s=this.context(),i=s.state.milestones.map(r=>r.id),n=Je(i,a.item.id,a.hoveredId,a.place);n&&s.dispatch(n)}#b(t){const a=this.mode;if(a.kind!=="picking-step")return;const s=this.context();s.dispatch(Ze(s.state,a.storyId,a.activityId,t,a.milestoneId)),this.mode=X}}const vt=()=>{Ia(),customElements.get("dpk-template-usm")||customElements.define("dpk-template-usm",bt)},bs=Object.freeze(Object.defineProperty({__proto__:null,DpkTemplateUsm:bt,IDLE_MODE:X,allUsmIds:G,applyUsmAction:Ee,defineUsmElement:vt,describeUsmAction:Ce,dropAfter:Ra,emptyUsmBase:we,findActivity:U,findMilestone:N,findStep:$,findStory:S,flatSteps:ue,parseUsmBase:Se,resolveCellDrop:We,resolveGroupDrop:Xe,resolveMilestoneDrop:Je,resolvePickedStepMove:Ze,resolveUsmNavigation:Pe,serializeUsmAction:Be,storiesInCell:te,storyCountForStep:$e,usmAction:ca,usmActions:h,usmCommentTargets:Ue,usmCurrentTarget:ze,usmDefinitionFor:Ge,usmHasTarget:Ve,usmMessages:se,usmTargetLabel:Ye,usmTitle:he},Symbol.toStringTag,{value:"Module"}));export{vt as d,bs as i};
|