Gruppen 1.2.1: Beitragsseite in Lesebreite; Fehler beim Öffnen eines Beitrags ohne Sprungmarke behoben
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
e7e92c5624
commit
da90d764e3
6 changed files with 7 additions and 7 deletions
2
dist/assets/style-9URDqoQM.css
vendored
2
dist/assets/style-9URDqoQM.css
vendored
File diff suppressed because one or more lines are too long
2
dist/assets/style-B47C9pxK.css
vendored
Normal file
2
dist/assets/style-B47C9pxK.css
vendored
Normal file
File diff suppressed because one or more lines are too long
2
dist/inhaus.json
vendored
2
dist/inhaus.json
vendored
|
|
@ -7,6 +7,6 @@
|
|||
"widgets/Recent": "widgets/Recent.js"
|
||||
},
|
||||
"css": [
|
||||
"assets/style-9URDqoQM.css"
|
||||
"assets/style-B47C9pxK.css"
|
||||
]
|
||||
}
|
||||
2
dist/pages/Post.js
vendored
2
dist/pages/Post.js
vendored
|
|
@ -1 +1 @@
|
|||
import{i as e,t}from"../chunks/PostCard-ClNPcHNo.js";import{Fragment as n,createBlock as r,createCommentVNode as i,createElementBlock as a,createElementVNode as o,createTextVNode as s,createVNode as c,onMounted as l,openBlock as u,renderList as d,toDisplayString as f,unref as p,withCtx as m}from"vue";import{router as h}from"@inertiajs/vue3";import{AppLayout as g,Button as _,PageHeader as v,http as y,toast as b}from"@inhaus/ui";var x={class:`ih:mx-auto ih:grid ih:max-w-4xl ih:gap-4`},S={key:0,class:`ih:rounded-md ih:border ih:border-destructive/30 ih:bg-destructive/5 ih:p-3 ih:text-sm`},C={class:`ih:flex ih:items-center ih:gap-2 ih:font-medium`},w={class:`ih:mt-1 ih:list-disc ih:pl-6 ih:text-muted-foreground`},T={__name:`Post`,props:{group:{type:Object,required:!0},post:{type:Object,required:!0},comments:{type:Array,required:!0},reactions:{type:Array,required:!0},reports:{type:Array,default:()=>[]}},setup(T){let E=T;l(()=>{(location.hash&&document.querySelector(location.hash))?.scrollIntoView({block:`center`})});async function D(){await y.post(`/gruppen/beitraege/${E.post.id}/meldungen-erledigt`),b.success(`Meldungen erledigt`),h.reload()}return(l,y)=>(u(),r(p(g),{title:`Beitrag in ${T.group.name}`},{default:m(()=>[c(p(v),{title:`Beitrag`,breadcrumbs:[{label:`Gruppen`,href:`/gruppen`},{label:T.group.name,href:T.group.url}]},null,8,[`breadcrumbs`]),o(`div`,x,[T.reports.length?(u(),a(`div`,S,[o(`p`,C,[c(p(e),{class:`ih:size-4 ih:text-destructive`}),s(` `+f(T.reports.length)+` `+f(T.reports.length===1?`Meldung`:`Meldungen`),1)]),o(`ul`,w,[(u(!0),a(n,null,d(T.reports,e=>(u(),a(`li`,{key:e.id},f(e.comment_id?`Kommentar: `:``)+f(e.reason),1))),128))]),c(p(_),{size:`sm`,variant:`outline`,class:`ih:mt-2`,onClick:D},{default:m(()=>[...y[1]||=[s(`In Ordnung – erledigt`,-1)]]),_:1})])):i(``,!0),c(t,{post:T.post,reactions:T.reactions,"full-comments":T.comments,onDeleted:y[0]||=e=>p(h).visit(T.group.url)},null,8,[`post`,`reactions`,`full-comments`])])]),_:1},8,[`title`]))}};export{T as default};
|
||||
import{i as e,t}from"../chunks/PostCard-ClNPcHNo.js";import{Fragment as n,createBlock as r,createCommentVNode as i,createElementBlock as a,createElementVNode as o,createTextVNode as s,createVNode as c,onMounted as l,openBlock as u,renderList as d,toDisplayString as f,unref as p,withCtx as m}from"vue";import{router as h}from"@inertiajs/vue3";import{AppLayout as g,Button as _,PageHeader as v,http as y,toast as b}from"@inhaus/ui";var x={class:`ih:mx-auto ih:grid ih:max-w-4xl ih:gap-4`},S={key:0,class:`ih:rounded-md ih:border ih:border-destructive/30 ih:bg-destructive/5 ih:p-3 ih:text-sm`},C={class:`ih:flex ih:items-center ih:gap-2 ih:font-medium`},w={class:`ih:mt-1 ih:list-disc ih:pl-6 ih:text-muted-foreground`},T={__name:`Post`,props:{group:{type:Object,required:!0},post:{type:Object,required:!0},comments:{type:Array,required:!0},reactions:{type:Array,required:!0},reports:{type:Array,default:()=>[]}},setup(T){let E=T;l(()=>{(location.hash?document.querySelector(location.hash):null)?.scrollIntoView({block:`center`})});async function D(){await y.post(`/gruppen/beitraege/${E.post.id}/meldungen-erledigt`),b.success(`Meldungen erledigt`),h.reload()}return(l,y)=>(u(),r(p(g),{title:`Beitrag in ${T.group.name}`,width:`medium`},{default:m(()=>[c(p(v),{title:`Beitrag`,breadcrumbs:[{label:`Gruppen`,href:`/gruppen`},{label:T.group.name,href:T.group.url}]},null,8,[`breadcrumbs`]),o(`div`,x,[T.reports.length?(u(),a(`div`,S,[o(`p`,C,[c(p(e),{class:`ih:size-4 ih:text-destructive`}),s(` `+f(T.reports.length)+` `+f(T.reports.length===1?`Meldung`:`Meldungen`),1)]),o(`ul`,w,[(u(!0),a(n,null,d(T.reports,e=>(u(),a(`li`,{key:e.id},f(e.comment_id?`Kommentar: `:``)+f(e.reason),1))),128))]),c(p(_),{size:`sm`,variant:`outline`,class:`ih:mt-2`,onClick:D},{default:m(()=>[...y[1]||=[s(`In Ordnung – erledigt`,-1)]]),_:1})])):i(``,!0),c(t,{post:T.post,reactions:T.reactions,"full-comments":T.comments,onDeleted:y[0]||=e=>p(h).visit(T.group.url)},null,8,[`post`,`reactions`,`full-comments`])])]),_:1},8,[`title`]))}};export{T as default};
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"slug": "gruppen",
|
||||
"name": "Gruppen",
|
||||
"version": "1.2.0",
|
||||
"version": "1.2.1",
|
||||
"description": "Diskussionsgruppen wie bei Facebook: offen, geschlossen (Beitritt auf Anfrage) oder privat (nur auf Einladung). Beiträge mit Fotos, Dateien und Umfragen, Reaktionen, Kommentare mit Antworten, Anpinnen, Melden und Moderation.",
|
||||
"author": "Loheide",
|
||||
"namespace": "Inhaus\\Plugins\\Gruppen\\",
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ const props = defineProps({
|
|||
});
|
||||
|
||||
onMounted(() => {
|
||||
const target = location.hash && document.querySelector(location.hash);
|
||||
const target = location.hash ? document.querySelector(location.hash) : null;
|
||||
target?.scrollIntoView({ block: 'center' });
|
||||
});
|
||||
|
||||
|
|
@ -26,7 +26,7 @@ async function resolve() {
|
|||
</script>
|
||||
|
||||
<template>
|
||||
<AppLayout :title="`Beitrag in ${group.name}`">
|
||||
<AppLayout :title="`Beitrag in ${group.name}`" width="medium">
|
||||
<PageHeader title="Beitrag" :breadcrumbs="[{ label: 'Gruppen', href: '/gruppen' }, { label: group.name, href: group.url }]" />
|
||||
<div class="ih:mx-auto ih:grid ih:max-w-4xl ih:gap-4">
|
||||
<div v-if="reports.length" class="ih:rounded-md ih:border ih:border-destructive/30 ih:bg-destructive/5 ih:p-3 ih:text-sm">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue