-
Notifications
You must be signed in to change notification settings - Fork 478
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
32 changed files
with
680 additions
and
155 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# sensible defaults | ||
|
||
sources: | ||
# Defaults for finding 0, 3, 10002 events | ||
- kinds: | ||
- 0 | ||
- 3 | ||
- 10002 | ||
relays: | ||
- 'wss://purplepag.es' | ||
- 'wss://user.kindpag.es' | ||
- 'wss://relay.nostr.band' | ||
|
||
# Defaults for finding 10166 and 30166 events | ||
- kinds: | ||
- 10166 | ||
- 30166 | ||
- relays: | ||
- wss://relay.nostr.watch | ||
- wss://relaypag.es | ||
|
||
# These are considered "preferred" and as default for unauthenticated users | ||
# this is used to prevent abuse that has no recourse. | ||
pubkeys: | ||
- '' | ||
|
||
# Defaults for finding wiki events | ||
kinds: | ||
- 30818 | ||
relays: | ||
- 'wss://relay.wikifreedia.xyz' | ||
pubkeys: | ||
- '' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
liveness: | ||
onlineThresholdMultiplier: 1.5 | ||
DeathThreshold: 30d | ||
content: | ||
nip66: | ||
relays: | ||
- 'wss://purplepag.es' | ||
- 'wss://user.kindpag.es' | ||
- 'wss://relay.nostr.band' | ||
pubkeys: | ||
- '' | ||
userMeta: | ||
relays: | ||
- 'wss://purplepag.es' | ||
- 'wss://user.kindpag.es' | ||
- 'wss://relay.nostr.band' | ||
wiki: | ||
relays: | ||
- 'wss://relay.wikifreedia.xyz' | ||
pubkeys: | ||
- '' | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<script lang="ts"> | ||
import { parseNote } from "$utils/notes"; | ||
import type { NostrEvent } from "@nostrwatch/route66/models"; | ||
import { onMount } from "svelte"; | ||
import { writable, type Writable } from "svelte/store"; | ||
export let note: NostrEvent; | ||
export let parserOptions: any | undefined = { | ||
removeHashtags: true, | ||
nip19: true, | ||
markdown: true, | ||
images: true, | ||
videos: true, | ||
truncate: true, | ||
truncateLength: 100, | ||
sanitize: false, | ||
replaceAmpersand: true, | ||
}; | ||
let content: Writable<string | undefined> = writable(undefined); | ||
onMount(() => { | ||
content = parseNote(note.content, parserOptions); | ||
}); | ||
</script> | ||
{@html $content} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
<script lang="ts"> | ||
import type { NostrEvent } from "@nostrwatch/route66/models"; | ||
import type { Readable } from "svelte/motion"; | ||
import { writable, type Writable } from "svelte/store"; | ||
import FeedNoteContent from "../feeds/FeedNoteContent.svelte"; | ||
import Button from "$ui/button/button.svelte"; | ||
export let wikis: Readable<NostrEvent[]> | Writable<NostrEvent[]>; | ||
let expanded: Writable<boolean> = writable(false); | ||
$: expandedClass = $expanded? '' : 'line-clamp-[5]'; | ||
</script> | ||
|
||
<section class="wiki {expandedClass}"> | ||
{#each $wikis as wiki (wiki)} | ||
<FeedNoteContent note={wiki} parserOptions={{ | ||
truncate: false, | ||
markdown: true | ||
}} /> | ||
{/each} | ||
</section> | ||
|
||
<Button | ||
size="sm" | ||
variant="secondary" | ||
class="mt-10" | ||
on:click={() => expanded.set(!$expanded)}> | ||
|
||
{$expanded? 'show less' : 'read more'} | ||
</Button> | ||
|
||
<style lang="postcss" global> | ||
.wiki { | ||
@apply p-4 m-auto; | ||
} | ||
.wiki > h2 { | ||
@apply text-lg py-5 mb-5 w-full border-b-[1px]; | ||
} | ||
.wiki * { | ||
@apply leading-relaxed; | ||
} | ||
.wiki > p { | ||
@apply block !my-10; | ||
} | ||
.wiki table { | ||
@apply border border-white/5 w-full bg-black/5 dark:bg-white/5; | ||
} | ||
.wiki table th { | ||
@apply underline; | ||
} | ||
.wiki table td, .wiki table th { | ||
@apply border border-white/5 py-2 px-3; | ||
} | ||
.wiki table td:first-child, | ||
.wiki table th:first-child { | ||
@apply font-bold text-center; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.