···1-# sv
2-3-Everything you need to build a Svelte project, powered by [`sv`](https://github.com/sveltejs/cli).
4-5-## Creating a project
6-7-If you're seeing this, you've probably already done this step. Congrats!
8-9-```sh
10-# create a new project in the current directory
11-npx sv create
12-13-# create a new project in my-app
14-npx sv create my-app
15-```
1617-## Developing
1819-Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
20-21-```sh
22-npm run dev
23-24-# or start the server and open the app in a new browser tab
25-npm run dev -- --open
26-```
27-28-## Building
29-30-To create a production version of your app:
31-32-```sh
33-npm run build
34-```
35-36-You can preview the production build with `npm run preview`.
37-38-> To deploy your app, you may need to install an [adapter](https://svelte.dev/docs/kit/adapters) for your target environment.
···1+# sunrise
0000000000000023+a cross-lexicon atproto viewer. powered by quickslice (hopefully).
45+collecting lexicons in the `lexicons/` directory and implementing a subset of these lexicons for display in a simple feed.
0000000000000000000
···1+{
2+ "lexicon": 1,
3+ "id": "app.bsky.contact.defs",
4+ "defs": {
5+ "matchAndContactIndex": {
6+ "description": "Associates a profile with the positional index of the contact import input in the call to `app.bsky.contact.importContacts`, so clients can know which phone caused a particular match.",
7+ "type": "object",
8+ "required": ["match", "contactIndex"],
9+ "properties": {
10+ "match": {
11+ "description": "Profile of the matched user.",
12+ "type": "ref",
13+ "ref": "app.bsky.actor.defs#profileView"
14+ },
15+ "contactIndex": {
16+ "description": "The index of this match in the import contact input.",
17+ "type": "integer",
18+ "minimum": 0,
19+ "maximum": 999
20+ }
21+ }
22+ },
23+ "syncStatus": {
24+ "type": "object",
25+ "required": ["syncedAt", "matchesCount"],
26+ "properties": {
27+ "syncedAt": {
28+ "description": "Last date when contacts where imported.",
29+ "type": "string",
30+ "format": "datetime"
31+ },
32+ "matchesCount": {
33+ "description": "Number of existing contact matches resulting of the user imports and of their imported contacts having imported the user. Matches stop being counted when the user either follows the matched contact or dismisses the match.",
34+ "type": "integer",
35+ "minimum": 0
36+ }
37+ }
38+ },
39+ "notification": {
40+ "description": "A stash object to be sent via bsync representing a notification to be created.",
41+ "type": "object",
42+ "required": ["from", "to"],
43+ "properties": {
44+ "from": {
45+ "description": "The DID of who this notification comes from.",
46+ "type": "string",
47+ "format": "did"
48+ },
49+ "to": {
50+ "description": "The DID of who this notification should go to.",
51+ "type": "string",
52+ "format": "did"
53+ }
54+ }
55+ }
56+ }
57+}
+15
lexicons/app/bsky/embed/defs.json
···000000000000000
···1+{
2+ "lexicon": 1,
3+ "id": "app.bsky.embed.defs",
4+ "defs": {
5+ "aspectRatio": {
6+ "type": "object",
7+ "description": "width:height represents an aspect ratio. It may be approximate, and may not correspond to absolute dimensions in any given unit.",
8+ "required": ["width", "height"],
9+ "properties": {
10+ "width": { "type": "integer", "minimum": 1 },
11+ "height": { "type": "integer", "minimum": 1 }
12+ }
13+ }
14+ }
15+}
···1+{
2+ "lexicon": 1,
3+ "id": "app.bsky.feed.post",
4+ "defs": {
5+ "main": {
6+ "type": "record",
7+ "description": "Record containing a Bluesky post.",
8+ "key": "tid",
9+ "record": {
10+ "type": "object",
11+ "required": ["text", "createdAt"],
12+ "properties": {
13+ "text": {
14+ "type": "string",
15+ "maxLength": 3000,
16+ "maxGraphemes": 300,
17+ "description": "The primary post content. May be an empty string, if there are embeds."
18+ },
19+ "entities": {
20+ "type": "array",
21+ "description": "DEPRECATED: replaced by app.bsky.richtext.facet.",
22+ "items": { "type": "ref", "ref": "#entity" }
23+ },
24+ "facets": {
25+ "type": "array",
26+ "description": "Annotations of text (mentions, URLs, hashtags, etc)",
27+ "items": { "type": "ref", "ref": "app.bsky.richtext.facet" }
28+ },
29+ "reply": { "type": "ref", "ref": "#replyRef" },
30+ "embed": {
31+ "type": "union",
32+ "refs": [
33+ "app.bsky.embed.images",
34+ "app.bsky.embed.video",
35+ "app.bsky.embed.external",
36+ "app.bsky.embed.record",
37+ "app.bsky.embed.recordWithMedia"
38+ ]
39+ },
40+ "langs": {
41+ "type": "array",
42+ "description": "Indicates human language of post primary text content.",
43+ "maxLength": 3,
44+ "items": { "type": "string", "format": "language" }
45+ },
46+ "labels": {
47+ "type": "union",
48+ "description": "Self-label values for this post. Effectively content warnings.",
49+ "refs": ["com.atproto.label.defs#selfLabels"]
50+ },
51+ "tags": {
52+ "type": "array",
53+ "description": "Additional hashtags, in addition to any included in post text and facets.",
54+ "maxLength": 8,
55+ "items": { "type": "string", "maxLength": 640, "maxGraphemes": 64 }
56+ },
57+ "createdAt": {
58+ "type": "string",
59+ "format": "datetime",
60+ "description": "Client-declared timestamp when this post was originally created."
61+ }
62+ }
63+ }
64+ },
65+ "replyRef": {
66+ "type": "object",
67+ "required": ["root", "parent"],
68+ "properties": {
69+ "root": { "type": "ref", "ref": "com.atproto.repo.strongRef" },
70+ "parent": { "type": "ref", "ref": "com.atproto.repo.strongRef" }
71+ }
72+ },
73+ "entity": {
74+ "type": "object",
75+ "description": "Deprecated: use facets instead.",
76+ "required": ["index", "type", "value"],
77+ "properties": {
78+ "index": { "type": "ref", "ref": "#textSlice" },
79+ "type": {
80+ "type": "string",
81+ "description": "Expected values are 'mention' and 'link'."
82+ },
83+ "value": { "type": "string" }
84+ }
85+ },
86+ "textSlice": {
87+ "type": "object",
88+ "description": "Deprecated. Use app.bsky.richtext instead -- A text segment. Start is inclusive, end is exclusive. Indices are for utf16-encoded strings.",
89+ "required": ["start", "end"],
90+ "properties": {
91+ "start": { "type": "integer", "minimum": 0 },
92+ "end": { "type": "integer", "minimum": 0 }
93+ }
94+ }
95+ }
96+}
+46
lexicons/app/bsky/feed/postgate.json
···0000000000000000000000000000000000000000000000
···1+{
2+ "lexicon": 1,
3+ "id": "app.bsky.feed.postgate",
4+ "defs": {
5+ "main": {
6+ "type": "record",
7+ "key": "tid",
8+ "description": "Record defining interaction rules for a post. The record key (rkey) of the postgate record must match the record key of the post, and that record must be in the same repository.",
9+ "record": {
10+ "type": "object",
11+ "required": ["post", "createdAt"],
12+ "properties": {
13+ "createdAt": { "type": "string", "format": "datetime" },
14+ "post": {
15+ "type": "string",
16+ "format": "at-uri",
17+ "description": "Reference (AT-URI) to the post record."
18+ },
19+ "detachedEmbeddingUris": {
20+ "type": "array",
21+ "maxLength": 50,
22+ "items": {
23+ "type": "string",
24+ "format": "at-uri"
25+ },
26+ "description": "List of AT-URIs embedding this post that the author has detached from."
27+ },
28+ "embeddingRules": {
29+ "description": "List of rules defining who can embed this post. If value is an empty array or is undefined, no particular rules apply and anyone can embed.",
30+ "type": "array",
31+ "maxLength": 5,
32+ "items": {
33+ "type": "union",
34+ "refs": ["#disableRule"]
35+ }
36+ }
37+ }
38+ }
39+ },
40+ "disableRule": {
41+ "type": "object",
42+ "description": "Disables embedding of this post.",
43+ "properties": {}
44+ }
45+ }
46+}
···1+{
2+ "lexicon": 1,
3+ "id": "app.bsky.richtext.facet",
4+ "defs": {
5+ "main": {
6+ "type": "object",
7+ "description": "Annotation of a sub-string within rich text.",
8+ "required": ["index", "features"],
9+ "properties": {
10+ "index": { "type": "ref", "ref": "#byteSlice" },
11+ "features": {
12+ "type": "array",
13+ "items": { "type": "union", "refs": ["#mention", "#link", "#tag"] }
14+ }
15+ }
16+ },
17+ "mention": {
18+ "type": "object",
19+ "description": "Facet feature for mention of another account. The text is usually a handle, including a '@' prefix, but the facet reference is a DID.",
20+ "required": ["did"],
21+ "properties": {
22+ "did": { "type": "string", "format": "did" }
23+ }
24+ },
25+ "link": {
26+ "type": "object",
27+ "description": "Facet feature for a URL. The text URL may have been simplified or truncated, but the facet reference should be a complete URL.",
28+ "required": ["uri"],
29+ "properties": {
30+ "uri": { "type": "string", "format": "uri" }
31+ }
32+ },
33+ "tag": {
34+ "type": "object",
35+ "description": "Facet feature for a hashtag. The text usually includes a '#' prefix, but the facet reference should not (except in the case of 'double hash tags').",
36+ "required": ["tag"],
37+ "properties": {
38+ "tag": { "type": "string", "maxLength": 640, "maxGraphemes": 64 }
39+ }
40+ },
41+ "byteSlice": {
42+ "type": "object",
43+ "description": "Specifies the sub-string range a facet feature applies to. Start index is inclusive, end index is exclusive. Indices are zero-indexed, counting bytes of the UTF-8 encoded text. NOTE: some languages, like Javascript, use UTF-16 or Unicode codepoints for string slice indexing; in these languages, convert to byte arrays before working with facets.",
44+ "required": ["byteStart", "byteEnd"],
45+ "properties": {
46+ "byteStart": { "type": "integer", "minimum": 0 },
47+ "byteEnd": { "type": "integer", "minimum": 0 }
48+ }
49+ }
50+ }
51+}
+28
lexicons/app/bsky/video/defs.json
···0000000000000000000000000000
···1+{
2+ "lexicon": 1,
3+ "id": "app.bsky.video.defs",
4+ "defs": {
5+ "jobStatus": {
6+ "type": "object",
7+ "required": ["jobId", "did", "state"],
8+ "properties": {
9+ "jobId": { "type": "string" },
10+ "did": { "type": "string", "format": "did" },
11+ "state": {
12+ "type": "string",
13+ "description": "The state of the video processing job. All values not listed as a known value indicate that the job is in process.",
14+ "knownValues": ["JOB_STATE_COMPLETED", "JOB_STATE_FAILED"]
15+ },
16+ "progress": {
17+ "type": "integer",
18+ "minimum": 0,
19+ "maximum": 100,
20+ "description": "Progress within the current processing state."
21+ },
22+ "blob": { "type": "blob" },
23+ "error": { "type": "string" },
24+ "message": { "type": "string" }
25+ }
26+ }
27+ }
28+}
···1+{
2+ "lexicon": 1,
3+ "id": "com.atproto.label.defs",
4+ "defs": {
5+ "label": {
6+ "type": "object",
7+ "description": "Metadata tag on an atproto resource (eg, repo or record).",
8+ "required": ["src", "uri", "val", "cts"],
9+ "properties": {
10+ "ver": {
11+ "type": "integer",
12+ "description": "The AT Protocol version of the label object."
13+ },
14+ "src": {
15+ "type": "string",
16+ "format": "did",
17+ "description": "DID of the actor who created this label."
18+ },
19+ "uri": {
20+ "type": "string",
21+ "format": "uri",
22+ "description": "AT URI of the record, repository (account), or other resource that this label applies to."
23+ },
24+ "cid": {
25+ "type": "string",
26+ "format": "cid",
27+ "description": "Optionally, CID specifying the specific version of 'uri' resource this label applies to."
28+ },
29+ "val": {
30+ "type": "string",
31+ "maxLength": 128,
32+ "description": "The short string name of the value or type of this label."
33+ },
34+ "neg": {
35+ "type": "boolean",
36+ "description": "If true, this is a negation label, overwriting a previous label."
37+ },
38+ "cts": {
39+ "type": "string",
40+ "format": "datetime",
41+ "description": "Timestamp when this label was created."
42+ },
43+ "exp": {
44+ "type": "string",
45+ "format": "datetime",
46+ "description": "Timestamp at which this label expires (no longer applies)."
47+ },
48+ "sig": {
49+ "type": "bytes",
50+ "description": "Signature of dag-cbor encoded label."
51+ }
52+ }
53+ },
54+ "selfLabels": {
55+ "type": "object",
56+ "description": "Metadata tags on an atproto record, published by the author within the record.",
57+ "required": ["values"],
58+ "properties": {
59+ "values": {
60+ "type": "array",
61+ "items": { "type": "ref", "ref": "#selfLabel" },
62+ "maxLength": 10
63+ }
64+ }
65+ },
66+ "selfLabel": {
67+ "type": "object",
68+ "description": "Metadata tag on an atproto record, published by the author within the record. Note that schemas should use #selfLabels, not #selfLabel.",
69+ "required": ["val"],
70+ "properties": {
71+ "val": {
72+ "type": "string",
73+ "maxLength": 128,
74+ "description": "The short string name of the value or type of this label."
75+ }
76+ }
77+ },
78+ "labelValueDefinition": {
79+ "type": "object",
80+ "description": "Declares a label value and its expected interpretations and behaviors.",
81+ "required": ["identifier", "severity", "blurs", "locales"],
82+ "properties": {
83+ "identifier": {
84+ "type": "string",
85+ "description": "The value of the label being defined. Must only include lowercase ascii and the '-' character ([a-z-]+).",
86+ "maxLength": 100,
87+ "maxGraphemes": 100
88+ },
89+ "severity": {
90+ "type": "string",
91+ "description": "How should a client visually convey this label? 'inform' means neutral and informational; 'alert' means negative and warning; 'none' means show nothing.",
92+ "knownValues": ["inform", "alert", "none"]
93+ },
94+ "blurs": {
95+ "type": "string",
96+ "description": "What should this label hide in the UI, if applied? 'content' hides all of the target; 'media' hides the images/video/audio; 'none' hides nothing.",
97+ "knownValues": ["content", "media", "none"]
98+ },
99+ "defaultSetting": {
100+ "type": "string",
101+ "description": "The default setting for this label.",
102+ "knownValues": ["ignore", "warn", "hide"],
103+ "default": "warn"
104+ },
105+ "adultOnly": {
106+ "type": "boolean",
107+ "description": "Does the user need to have adult content enabled in order to configure this label?"
108+ },
109+ "locales": {
110+ "type": "array",
111+ "items": { "type": "ref", "ref": "#labelValueDefinitionStrings" }
112+ }
113+ }
114+ },
115+ "labelValueDefinitionStrings": {
116+ "type": "object",
117+ "description": "Strings which describe the label in the UI, localized into a specific language.",
118+ "required": ["lang", "name", "description"],
119+ "properties": {
120+ "lang": {
121+ "type": "string",
122+ "description": "The code of the language these strings are written in.",
123+ "format": "language"
124+ },
125+ "name": {
126+ "type": "string",
127+ "description": "A short human-readable name for the label.",
128+ "maxGraphemes": 64,
129+ "maxLength": 640
130+ },
131+ "description": {
132+ "type": "string",
133+ "description": "A longer description of what the label means and why it might be applied.",
134+ "maxGraphemes": 10000,
135+ "maxLength": 100000
136+ }
137+ }
138+ },
139+ "labelValue": {
140+ "type": "string",
141+ "knownValues": [
142+ "!hide",
143+ "!no-promote",
144+ "!warn",
145+ "!no-unauthenticated",
146+ "dmca-violation",
147+ "doxxing",
148+ "porn",
149+ "sexual",
150+ "nudity",
151+ "nsfl",
152+ "gore"
153+ ]
154+ }
155+ }
156+}