Some checks failed
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 8m15s
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 8m16s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 8m10s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 8m15s
CI / PHP 8.3 / mysql:8.0 (pull_request) Failing after 10m23s
CI / PHP 8.4 / mysql:8.0 (pull_request) Failing after 10m41s
CI / PHP 8.3 / mysql:8.4 (pull_request) Failing after 8m59s
CI / PHP 8.4 / mysql:8.4 (pull_request) Failing after 9m1s
CI / Bekannte Sicherheitslücken in Paketen (pull_request) Successful in 49s
CI / Build-Artefakte aktuell (pull_request) Successful in 1m11s
Das Portal legt den Rahmen selbst um jede Plugin-Seite; AppLayout aus @inhaus/ui setzt dort nur noch den Titel. Detailseiten nutzen PageHeader. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
1 line
No EOL
2.5 KiB
JavaScript
1 line
No EOL
2.5 KiB
JavaScript
import{C as e,D as t,M as n,P as r,S as i,T as a,w as o,x as s}from"./ui-DTELwomD.js";import{C as c,O as l,S as u,T as d,_t as f,a as p,g as m,k as h,kt as g,nt as _,ot as v,q as y,rt as b,w as x,wt as S,z as C}from"./framework-CFqPLBV8.js";import{E as w,o as T}from"./app-DIZuUM-n.js";var E={class:`grid gap-1.5`},D={key:0,class:`text-[13px] text-destructive`},O={key:0,class:`grid gap-1.5`},k={__name:`NewPageDialog`,props:C({parentId:{type:Number,default:null},parentTitle:{type:String,default:``}},{open:{type:Boolean,default:!1},openModifiers:{}}),emits:C([`before-create`],[`update:open`]),setup(C,{emit:k}){let A=C,j=_(C,`open`),M=k,N=p({title:``,parent_id:null,template_id:null}),P=f([]);b(j,async e=>{if(e){N.reset(),N.clearErrors();try{P.value=(await w.get(`/redaktion/bausteine?kind=template`)).snippets}catch{P.value=[]}}});async function F(){M(`before-create`),N.parent_id=A.parentId,N.post(`/redaktion/seiten`)}return(f,p)=>(y(),c(S(t),{open:j.value,"onUpdate:open":p[3]||=e=>j.value=e},{default:v(()=>[h(S(a),{class:`sm:max-w-md`},{default:v(()=>[h(S(i),null,{default:v(()=>[h(S(s),null,{default:v(()=>[l(g(C.parentId?`Unterseite anlegen`:`Neue Seite`),1)]),_:1}),C.parentId?(y(),c(S(o),{key:0},{default:v(()=>[l(`Unter „`+g(C.parentTitle)+`“. Die Seite ist erst nach dem Veröffentlichen sichtbar.`,1)]),_:1})):(y(),c(S(o),{key:1},{default:v(()=>[...p[4]||=[l(`Auf der obersten Ebene. Die Seite ist erst nach dem Veröffentlichen sichtbar.`,-1)]]),_:1}))]),_:1}),u(`form`,{class:`grid gap-4`,onSubmit:m(F,[`prevent`])},[u(`label`,E,[p[5]||=u(`span`,{class:`text-[13px] font-medium`},`Titel`,-1),h(S(n),{modelValue:S(N).title,"onUpdate:modelValue":p[0]||=e=>S(N).title=e,maxlength:`200`,autofocus:``,"aria-invalid":!!S(N).errors.title},null,8,[`modelValue`,`aria-invalid`]),S(N).errors.title?(y(),d(`span`,D,g(S(N).errors.title),1)):x(``,!0)]),P.value.length?(y(),d(`label`,O,[p[6]||=u(`span`,{class:`text-[13px] font-medium`},`Vorlage`,-1),h(T,{modelValue:S(N).template_id,"onUpdate:modelValue":p[1]||=e=>S(N).template_id=e,options:[{value:null,label:`Leere Seite`},...P.value.map(e=>({value:e.id,label:e.description?`${e.name} – ${e.description}`:e.name}))]},null,8,[`modelValue`,`options`])])):x(``,!0),h(S(e),null,{default:v(()=>[h(S(r),{type:`button`,variant:`outline`,onClick:p[2]||=e=>j.value=!1},{default:v(()=>[...p[7]||=[l(`Abbrechen`,-1)]]),_:1}),h(S(r),{type:`submit`,disabled:S(N).processing||!S(N).title.trim()},{default:v(()=>[...p[8]||=[l(`Anlegen und bearbeiten`,-1)]]),_:1},8,[`disabled`])]),_:1})],32)]),_:1})]),_:1},8,[`open`]))}};export{k as t}; |