diff --git a/src/app/components/ChannelMessage.svelte b/src/app/components/ChannelMessage.svelte
index f1d187fc..e6bee1e9 100644
--- a/src/app/components/ChannelMessage.svelte
+++ b/src/app/components/ChannelMessage.svelte
@@ -79,10 +79,10 @@
+
{#if !isHead}
{/if}
diff --git a/src/app/components/Content.svelte b/src/app/components/Content.svelte
index d905fd7a..339d344c 100644
--- a/src/app/components/Content.svelte
+++ b/src/app/components/Content.svelte
@@ -47,9 +47,9 @@
const isBlock = (i: number) => {
const parsed = fullContent[i]
- if (!parsed || hideMedia) return true
+ if (!parsed || hideMedia) return false
- if (isLink(parsed) && isStartOrEnd(i) && $userSettingValues.show_media) {
+ if (isLink(parsed) && $userSettingValues.show_media && isStartOrEnd(i)) {
return true
}
@@ -64,14 +64,18 @@
const parsed = fullContent[i]
if (!parsed || isNewline(parsed)) return true
- if (isText(parsed)) return parsed.value.match(/^\s+$/)
+ if (isText(parsed)) return Boolean(parsed.value.match(/^\s+$/))
return false
}
- const isStartAndEnd = (i: number) => Boolean(isBoundary(i - 1) && isBoundary(i + 1))
+ const isStart = (i: number) => isBoundary(i - 1)
- const isStartOrEnd = (i: number) => Boolean(isBoundary(i - 1) || isBoundary(i + 1))
+ const isEnd = (i: number) => isBoundary(i + 1)
+
+ const isStartAndEnd = (i: number) => isStart(i) && isEnd(i)
+
+ const isStartOrEnd = (i: number) => isStart(i) || isEnd(i)
const ignoreWarning = () => {
warning = null
diff --git a/src/app/components/ContentQuote.svelte b/src/app/components/ContentQuote.svelte
index f600793e..7ee1705b 100644
--- a/src/app/components/ContentQuote.svelte
+++ b/src/app/components/ContentQuote.svelte
@@ -24,10 +24,20 @@
const entity = id ? nip19.neventEncode({id, relays}) : addr.toNaddr()
const scrollToEvent = (id: string) => {
- const element = document.querySelector(`[data-event="${id}"]`)
+ const element = document.querySelector(`[data-event="${id}"]`) as any
if (element) {
element.scrollIntoView({behavior: "smooth"})
+ element.style =
+ "filter: brightness(1.5); transition-property: all; transition-duration: 400ms;"
+
+ setTimeout(() => {
+ element.style = "transition-property: all; transition-duration: 300ms;"
+ }, 800)
+
+ setTimeout(() => {
+ element.style = ""
+ }, 800 + 400)
}
return Boolean(element)
diff --git a/src/app/components/ReactionSummary.svelte b/src/app/components/ReactionSummary.svelte
index 8c95edfb..fabb0a6e 100644
--- a/src/app/components/ReactionSummary.svelte
+++ b/src/app/components/ReactionSummary.svelte
@@ -35,7 +35,7 @@
-
+ {#key $page.url.pathname}
+
+ {/key}
diff --git a/src/routes/spaces/+layout.svelte b/src/routes/spaces/+layout.svelte
new file mode 100644
index 00000000..62dc2a2a
--- /dev/null
+++ b/src/routes/spaces/+layout.svelte
@@ -0,0 +1,7 @@
+
+
+{#key $page.params.relay}
+
+{/key}
diff --git a/src/routes/spaces/[relay]/+layout.svelte b/src/routes/spaces/[relay]/+layout.svelte
index 22965ab2..66c87439 100644
--- a/src/routes/spaces/[relay]/+layout.svelte
+++ b/src/routes/spaces/[relay]/+layout.svelte
@@ -60,5 +60,7 @@
-
+ {#key $page.url.pathname}
+
+ {/key}