diff options
| author | winter | 2024-12-31 16:25:22 +0000 |
|---|---|---|
| committer | winter | 2024-12-31 16:25:22 +0000 |
| commit | 982e6213622bcb78a40d17f54cda27225a1d84b3 (patch) | |
| tree | 0a81d8fc183238dca959a4ab848c9cd1d241ef27 /templates | |
| parent | ad554b48e7dc355d9b33eede98f4e3e829fd867e (diff) | |
rework timelines. inclusion reasons supported now
Diffstat (limited to 'templates')
| -rw-r--r-- | templates/global_timeline.php | 10 | ||||
| -rw-r--r-- | templates/local_timeline.php | 10 | ||||
| -rw-r--r-- | templates/reason_reshared.php | 10 | ||||
| -rw-r--r-- | templates/timeline.php | 11 |
4 files changed, 21 insertions, 20 deletions
diff --git a/templates/global_timeline.php b/templates/global_timeline.php deleted file mode 100644 index f475656..0000000 --- a/templates/global_timeline.php +++ /dev/null @@ -1,10 +0,0 @@ -<?php call_template('skeleton', ['pageTitle' => __('timeline.global')], function () { - global $notes; - call_template('alertbox', [ - 'variety' => 'info', - 'message' => __('timeline.global.description') - ]); - foreach ($notes as $n) { - call_template('note', ['note' => $n]); - } -});
\ No newline at end of file diff --git a/templates/local_timeline.php b/templates/local_timeline.php deleted file mode 100644 index 9d9027c..0000000 --- a/templates/local_timeline.php +++ /dev/null @@ -1,10 +0,0 @@ -<?php call_template('skeleton', ['pageTitle' => __('timeline.local')], function () { - global $notes; - call_template('alertbox', [ - 'variety' => 'info', - 'message' => __('timeline.local.description') - ]); - foreach ($notes as $n) { - call_template('note', ['note' => $n]); - } -});
\ No newline at end of file diff --git a/templates/reason_reshared.php b/templates/reason_reshared.php new file mode 100644 index 0000000..2c1e4c5 --- /dev/null +++ b/templates/reason_reshared.php @@ -0,0 +1,10 @@ +<div class="timelineReason"> + <span class="icon material-symbols-outlined">repeat</span> + <span> + <?php + $handle = $actor->getFullHandle(); + $name = htmlspecialchars($actor->displayName); + printf(__('note.resharedBy'), "<a href=\"/@/$handle\">$name</a>"); + ?> + </span> +</div>
\ No newline at end of file diff --git a/templates/timeline.php b/templates/timeline.php new file mode 100644 index 0000000..7ba2fbf --- /dev/null +++ b/templates/timeline.php @@ -0,0 +1,11 @@ +<?php call_template('skeleton', ['pageTitle' => __("timeline.$kind")], function () { + global $items, $kind; + call_template('alertbox', [ + 'variety' => 'info', + 'message' => __("timeline.$kind.description") + ]); + foreach ($items as $item) { + $item->getReason()?->renderAsHtml(); + $item->getObject()->renderAsHtml(); + } +});
\ No newline at end of file |
