Some checks failed
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 7m17s
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 7m28s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 6m32s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 6m48s
CI / PHP 8.3 / mysql:8.0 (pull_request) Failing after 8m51s
CI / PHP 8.4 / mysql:8.0 (pull_request) Failing after 8m52s
CI / PHP 8.3 / mysql:8.4 (pull_request) Failing after 7m31s
CI / Bekannte Sicherheitslücken in Paketen (pull_request) Successful in 52s
CI / PHP 8.4 / mysql:8.4 (pull_request) Failing after 7m51s
CI / Build-Artefakte aktuell (pull_request) Successful in 1m22s
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
1 line
No EOL
7.6 KiB
JavaScript
1 line
No EOL
7.6 KiB
JavaScript
import{D as e,E as t,Ht as n,On as r,Yt as i,Zn as a,_ as o,b as s,bt as c,mt as l,o as u,qt as d,tr as f,v as p,vn as m,w as h,y as g}from"./runtime-core.esm-bundler-B8D2lM98.js";import{b as _,w as v}from"./runtime-dom.esm-bundler-BEWGoe8n.js";import{a as y,i as ee,o as te,s as b}from"./dist--2OKCVzt.js";import{t as x}from"./createLucideIcon-VlaMqNX_.js";import{t as S}from"./loader-circle-Wr6tQn-J.js";import{i as C}from"./PopoverTrigger-Cah311ye.js";import{t as w}from"./trash-CONUPzoz.js";import{n as ne}from"./lib-Be7KNAML.js";import{A as re,C as ie,D as T,N as E,S as D,St as O,_ as k,u as A,w as j,y as M}from"./app-9hFE_0ay.js";import{t as N}from"./StatusBadge-B45sWNYi.js";import{n as P,t as F}from"./SupportButton-Cd8vi8Pd.js";var I=x({name:`badge-check`,size:24,node:[[`path`,{d:`M3.85 8.62a4 4 0 0 1 4.78-4.77 4 4 0 0 1 6.74 0 4 4 0 0 1 4.78 4.78 4 4 0 0 1 0 6.74 4 4 0 0 1-4.77 4.78 4 4 0 0 1-6.75 0 4 4 0 0 1-4.78-4.77 4 4 0 0 1 0-6.76Z`,key:`3c2336`}],[`path`,{d:`m16 9-5.5 5.5L8 12`,key:`xofnsj`}]],aliases:[`verified`]}),L={class:`inline-flex flex-wrap items-center gap-2`},R={class:`grid items-start gap-6 lg:grid-cols-12`},z={class:`grid min-w-0 gap-6 lg:col-span-8`},B={class:`flex gap-5`},V={class:`min-w-0 flex-1`},H={class:`text-[15px] leading-relaxed whitespace-pre-line`},U={key:0,class:`mt-5 flex items-center gap-2.5 border-t pt-4 text-sm`},W={key:0,class:`rounded-lg border border-brand/30 bg-brand-soft/60 p-5`},G={class:`flex items-center gap-2 text-sm font-semibold text-brand-text`},K={class:`mt-2 text-sm leading-relaxed whitespace-pre-line`},ae={key:0,class:`mt-2 text-xs text-muted-foreground`},q={key:0,class:`-mx-5 mb-5 divide-y border-y`},J={class:`min-w-0 flex-1`},oe={class:`flex flex-wrap items-center gap-x-2 text-sm`},se={class:`font-semibold`},ce={key:0,class:`inline-flex items-center gap-1 text-xs font-medium text-brand-text`},le={class:`text-xs text-muted-foreground`},ue={class:`mt-1 text-sm leading-relaxed whitespace-pre-line`},de={key:0,class:`text-[13px] text-destructive`},fe={class:`flex flex-wrap items-center justify-between gap-3`},pe={key:0,class:`flex items-center gap-2 text-sm`},me={key:1},he={class:`grid gap-6 lg:col-span-4`},ge=[`value`],Y={__name:`Show`,props:{idea:{type:Object,required:!0},statuses:{type:Object,required:!0}},setup(x){let Y=x,X=te();n(()=>X.props.flash.status,e=>e&&ne.success(e),{immediate:!0});let Z=m(!1),Q=y({body:``,official:!1});function _e(){Q.post(`/ideen/${Y.idea.id}/kommentare`,{preserveScroll:!0,onSuccess:()=>Q.reset()})}function ve(e){window.confirm(`Kommentar löschen?`)&&b.delete(`/ideen/${Y.idea.id}/kommentare/${e.id}`,{preserveScroll:!0})}let $=y({status:Y.idea.status,status_note:Y.idea.status_note??``});function ye(){$.put(`/ideen/${Y.idea.id}/status`,{preserveScroll:!0})}function be(){window.confirm(`Idee „${Y.idea.title}“ löschen?`)&&b.delete(`/ideen/${Y.idea.id}`)}return(n,m)=>(l(),p(j,{title:x.idea.title},{default:d(()=>[e(ie,{title:x.idea.title,breadcrumbs:[{label:`Ideenbox`,href:`/ideen`}]},h({description:d(()=>[o(`span`,L,[e(N,{status:x.idea.status,label:x.idea.status_label},null,8,[`status`,`label`]),t(` eingereicht `+f(r(E)(x.idea.created_at)),1),x.idea.author?g(``,!0):(l(),s(u,{key:0},[t(` · anonym`)],64))])]),_:2},[x.idea.can_edit||x.idea.can_manage?{name:`actions`,fn:d(()=>[x.idea.can_edit?(l(),p(r(k),{key:0,variant:`outline`,size:`sm`,onClick:m[0]||=e=>Z.value=!0},{default:d(()=>[e(r(O)),m[6]||=t(` Bearbeiten`,-1)]),_:1})):g(``,!0),e(r(k),{variant:`ghost`,size:`sm`,class:`text-destructive hover:text-destructive`,onClick:be},{default:d(()=>[e(r(w)),m[7]||=t(` Löschen`,-1)]),_:1})]),key:`0`}:void 0]),1032,[`title`]),o(`div`,R,[o(`div`,z,[e(D,null,{default:d(()=>[o(`div`,B,[e(F,{idea:x.idea,disabled:x.idea.mine,large:``},null,8,[`idea`,`disabled`]),o(`div`,V,[o(`p`,H,f(x.idea.body),1),x.idea.author?(l(),s(`div`,U,[e(T,{person:x.idea.author,class:`size-8`},null,8,[`person`]),e(r(ee),{href:`/personen/${x.idea.author.id}`,class:`font-medium hover:underline`},{default:d(()=>[t(f(x.idea.author.name),1)]),_:1},8,[`href`])])):g(``,!0)])])]),_:1}),x.idea.status_note?(l(),s(`section`,W,[o(`h2`,G,[e(r(I),{class:`size-4`}),t(` Rückmeldung: `+f(x.idea.status_label),1)]),o(`p`,K,f(x.idea.status_note),1),x.idea.status_changed_at?(l(),s(`p`,ae,f(r(re)(x.idea.status_changed_at)),1)):g(``,!0)])):g(``,!0),e(D,{id:`kommentare`,title:`Kommentare (${x.idea.comment_list.length})`},{default:d(()=>[x.idea.comment_list.length?(l(),s(`ul`,q,[(l(!0),s(u,null,c(x.idea.comment_list,n=>(l(),s(`li`,{key:n.id,class:a([`flex gap-3 px-5 py-4`,{"bg-brand-soft/40":n.official}])},[n.author?(l(),p(T,{key:0,person:n.author,class:`size-9`},null,8,[`person`])):g(``,!0),o(`div`,J,[o(`p`,oe,[o(`span`,se,f(n.author?.name??`Gelöschtes Konto`),1),n.official?(l(),s(`span`,ce,[e(r(I),{class:`size-3.5`}),m[8]||=t(` Gremium`,-1)])):g(``,!0),o(`span`,le,f(r(E)(n.created_at)),1)]),o(`p`,ue,f(n.body),1)]),n.can_delete?(l(),p(r(k),{key:1,variant:`ghost`,size:`icon`,class:`size-7 shrink-0 text-muted-foreground hover:text-destructive`,"aria-label":`Kommentar löschen`,onClick:e=>ve(n)},{default:d(()=>[e(r(w),{class:`size-3.5`})]),_:1},8,[`onClick`])):g(``,!0)],2))),128))])):g(``,!0),o(`form`,{class:`grid gap-3`,onSubmit:v(_e,[`prevent`])},[e(r(A),{modelValue:r(Q).body,"onUpdate:modelValue":m[1]||=e=>r(Q).body=e,rows:`3`,maxlength:`3000`,placeholder:`Ihre Meinung, Ergänzungen oder Erfahrungen …`,"aria-label":`Kommentar`},null,8,[`modelValue`]),r(Q).errors.body?(l(),s(`p`,de,f(r(Q).errors.body),1)):g(``,!0),o(`div`,fe,[x.idea.can_manage?(l(),s(`label`,pe,[e(r(C),{modelValue:r(Q).official,"onUpdate:modelValue":m[2]||=e=>r(Q).official=e},null,8,[`modelValue`]),m[9]||=t(` Als Antwort des Gremiums`,-1)])):(l(),s(`span`,me)),e(r(k),{type:`submit`,disabled:r(Q).processing||!r(Q).body.trim()},{default:d(()=>[r(Q).processing?(l(),p(r(S),{key:0,class:`animate-spin`})):g(``,!0),m[10]||=t(` Kommentieren `,-1)]),_:1},8,[`disabled`])])],32)]),_:1},8,[`title`])]),o(`aside`,he,[x.idea.can_manage?(l(),p(D,{key:0,title:`Bewertung (Gremium)`},{default:d(()=>[o(`form`,{class:`grid gap-4`,onSubmit:v(ye,[`prevent`])},[e(M,{id:`idea-status`,label:`Status`},{default:d(()=>[i(o(`select`,{id:`idea-status`,"onUpdate:modelValue":m[3]||=e=>r($).status=e,class:`h-9 w-full rounded-md border bg-background px-2 text-sm`},[(l(!0),s(u,null,c(x.statuses,(e,t)=>(l(),s(`option`,{key:t,value:t},f(e),9,ge))),128))],512),[[_,r($).status]])]),_:1}),e(M,{id:`idea-note`,label:`Rückmeldung (für alle sichtbar)`,error:r($).errors.status_note},{default:d(()=>[e(r(A),{id:`idea-note`,modelValue:r($).status_note,"onUpdate:modelValue":m[4]||=e=>r($).status_note=e,rows:`5`,maxlength:`3000`,placeholder:`z. B. Wird im Frühjahr umgesetzt. / Leider nicht möglich, weil …`},null,8,[`modelValue`])]),_:1},8,[`error`]),m[12]||=o(`p`,{class:`text-xs text-muted-foreground`},`Bei einem neuen Status bekommen die einreichende Person und alle Unterstützenden Bescheid.`,-1),e(r(k),{type:`submit`,disabled:r($).processing||!r($).isDirty},{default:d(()=>[r($).processing?(l(),p(r(S),{key:0,class:`animate-spin`})):g(``,!0),m[11]||=t(` Speichern`,-1)]),_:1},8,[`disabled`])],32)]),_:1})):g(``,!0),e(D,{title:`So funktioniert’s`},{default:d(()=>[...m[13]||=[o(`ol`,{class:`grid list-decimal gap-2 pl-4 text-[13px] text-muted-foreground`},[o(`li`,null,`Ideen sind für alle sichtbar und lassen sich unterstützen und kommentieren.`),o(`li`,null,`Das Gremium sichtet neue Ideen, prüft sie und gibt eine Rückmeldung.`),o(`li`,null,`Wer eine Idee eingereicht oder unterstützt hat, erfährt, wie es ausgeht.`)],-1)]]),_:1})])]),x.idea.can_edit?(l(),p(P,{key:0,open:Z.value,"onUpdate:open":m[5]||=e=>Z.value=e,idea:x.idea},null,8,[`open`,`idea`])):g(``,!0)]),_:1},8,[`title`]))}};export{Y as default}; |