summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
inline | side by side (from parent 1:
865f81d)
It is more usual for “Previous Page” and “Next Page” to always show and
“First Page” and “Latest Page” to only show when they differ.
The prior behaviour was the opposite.
document.body.querySelector("h1").textContent = "subject" in meta
? `#${topic}`
: `@${topic}`
document.body.querySelector("h1").textContent = "subject" in meta
? `#${topic}`
: `@${topic}`
- if (meta.first != location) {
+ const { first, prev, next, current, items } = meta
+ if (first && first != location && first != prev) {
const a = nav
.insertBefore(document.createElement("p"), dl)
.appendChild(document.createElement("a"))
const a = nav
.insertBefore(document.createElement("p"), dl)
.appendChild(document.createElement("a"))
a.textContent = "First Page" }
a.textContent = "First Page" }
- if (meta.prev && meta.prev != meta.first) {
const a = nav
.insertBefore(document.createElement("p"), dl)
.appendChild(document.createElement("a"))
const a = nav
.insertBefore(document.createElement("p"), dl)
.appendChild(document.createElement("a"))
a.textContent = "Previous Page" }
let prevDate = undefined
a.textContent = "Previous Page" }
let prevDate = undefined
- for (const status of meta.items) {
+ for (const status of items) {
if (status.created != prevDate) dl.appendChild(document.createElement("dt")).textContent = status.created
const a = dl
.appendChild(document.createElement("dd"))
if (status.created != prevDate) dl.appendChild(document.createElement("dt")).textContent = status.created
const a = dl
.appendChild(document.createElement("dd"))
a.textContent = chars.length > 28
? "".concat(...chars.slice(0, 27), "…")
: summaryText || status.identifier }
a.textContent = chars.length > 28
? "".concat(...chars.slice(0, 27), "…")
: summaryText || status.identifier }
- if (meta.next && meta.next != meta.current) {
const a = nav
.appendChild(document.createElement("p"))
.appendChild(document.createElement("a"))
const a = nav
.appendChild(document.createElement("p"))
.appendChild(document.createElement("a"))
a.textContent = "Next Page" }
a.textContent = "Next Page" }
- if (meta.current != location) {
+ if (current && current != location && current != next) {
const a = nav
.appendChild(document.createElement("p"))
.appendChild(document.createElement("a"))
const a = nav
.appendChild(document.createElement("p"))
.appendChild(document.createElement("a"))
a.textContent = "Latest Page" } })
</SCRIPT>
a.textContent = "Latest Page" } })
</SCRIPT>