aboutsummaryrefslogtreecommitdiffhomepage
path: root/templates
diff options
context:
space:
mode:
Diffstat (limited to 'templates')
-rw-r--r--templates/note.php2
-rw-r--r--templates/thread_page.php7
2 files changed, 7 insertions, 2 deletions
diff --git a/templates/note.php b/templates/note.php
index 3fc86ba..56f1322 100644
--- a/templates/note.php
+++ b/templates/note.php
@@ -9,7 +9,7 @@ if ($user != null) {
$interKinds = array_map(fn($inter) => $inter->kind, $interactions);
}
?>
-<article class="note">
+<article class="note <?= $selected ? 'selected' : '' ?>">
<a href="/@/<?= $note->author->getFullHandle() ?>">
<?php call_template('actor_avatar', ['actor' => $note->author]); ?>
</a>
diff --git a/templates/thread_page.php b/templates/thread_page.php
index 73d8f0b..e5e5389 100644
--- a/templates/thread_page.php
+++ b/templates/thread_page.php
@@ -1,8 +1,13 @@
<?php
+use Digitigrade\Model\Note;
+
call_template('skeleton', [
'pageTitle' => '"' . $note->plainContent . '" - @' . $note->author->getFullHandle(),
'renderTitleHeading' => false
], function () {
global $note;
- call_template('note', ['note' => $note]);
+ $notes = Note::findAllInThread($note->threadApex ?? $note);
+ foreach ($notes as $n) {
+ call_template('note', ['note' => $n, 'selected' => $n == $note]);
+ }
}); \ No newline at end of file