Skip to content

Commit 5b1b175

Browse files
committed
chore(bluemoji): update lexicons
1 parent ba1d3ad commit 5b1b175

File tree

16 files changed

+570
-151
lines changed

16 files changed

+570
-151
lines changed

lexicons-bluemoji/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
https://github.com/aendra-rininsland/bluemoji/tree/9badb73d81451af6259e744305a511b1c71008cd/schema
1+
https://github.com/aendra-rininsland/bluemoji/tree/802a236415645e765a40fb02b6dc1e04344058f5/schema

lexicons-bluemoji/blue.moji/collection/defs.json

-14
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,6 @@
22
"lexicon": 1,
33
"id": "blue.moji.collection.defs",
44
"defs": {
5-
"itemView": {
6-
"type": "object",
7-
"required": ["name", "assets"],
8-
"properties": {
9-
"name": { "type": "string" },
10-
"alt": { "type": "string" },
11-
"createdAt": { "type": "string", "format": "datetime" },
12-
"assets": {
13-
"type": "ref",
14-
"ref": "blue.moji.collection.item#formats_v0"
15-
},
16-
"adultOnly": { "type": "boolean", "default": false }
17-
}
18-
},
195
"collectionView": {
206
"type": "object",
217
"required": ["uri", "cid", "creator", "name", "indexedAt"],
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
{
2+
"lexicon": 1,
3+
"id": "blue.moji.collection.getItem",
4+
"defs": {
5+
"main": {
6+
"type": "query",
7+
"description": "Get a single emoji from a repository. Requires auth.",
8+
"parameters": {
9+
"type": "params",
10+
"required": ["repo", "name"],
11+
"properties": {
12+
"repo": {
13+
"type": "string",
14+
"format": "at-identifier",
15+
"description": "The handle or DID of the repo."
16+
},
17+
"name": {
18+
"type": "string",
19+
"description": "The Bluemoji alias/rkey."
20+
}
21+
}
22+
},
23+
"output": {
24+
"encoding": "application/json",
25+
"schema": {
26+
"type": "object",
27+
"required": ["uri", "item"],
28+
"properties": {
29+
"uri": { "type": "string", "format": "at-uri" },
30+
"item": {
31+
"type": "ref",
32+
"ref": "blue.moji.collection.item#itemView"
33+
}
34+
}
35+
}
36+
}
37+
}
38+
}
39+
}

lexicons-bluemoji/blue.moji/collection/item.json

+16-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@
2828
"description": "Self-label values for this emoji. Effectively content warnings.",
2929
"refs": ["com.atproto.label.defs#selfLabels"]
3030
},
31-
"copyOf": { "type": "string", "format": "at-uri" }
31+
"copyOf": { "type": "string", "format": "at-uri" },
32+
"fallbackText": { "type": "string", "maxLength": 1, "default": "" }
3233
}
3334
}
3435
},
@@ -56,6 +57,20 @@
5657
"type": "bytes",
5758
"maxLength": 65536,
5859
"description": "64kb should be enough for anybody"
60+
},
61+
"itemView": {
62+
"type": "object",
63+
"required": ["name", "formats"],
64+
"properties": {
65+
"name": { "type": "string" },
66+
"alt": { "type": "string" },
67+
"createdAt": { "type": "string", "format": "datetime" },
68+
"formats": {
69+
"type": "ref",
70+
"ref": "#formats_v0"
71+
},
72+
"adultOnly": { "type": "boolean", "default": false }
73+
}
5974
}
6075
}
6176
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
{
2+
"lexicon": 1,
3+
"id": "blue.moji.collection.listCollection",
4+
"defs": {
5+
"main": {
6+
"type": "query",
7+
"description": "List a range of Bluemoji in a repository, matching a specific collection. Requires auth.",
8+
"parameters": {
9+
"type": "params",
10+
"properties": {
11+
"limit": {
12+
"type": "integer",
13+
"minimum": 1,
14+
"maximum": 100,
15+
"default": 50,
16+
"description": "The number of records to return."
17+
},
18+
"cursor": { "type": "string" },
19+
"reverse": {
20+
"type": "boolean",
21+
"description": "Flag to reverse the order of the returned records."
22+
}
23+
}
24+
},
25+
"output": {
26+
"encoding": "application/json",
27+
"schema": {
28+
"type": "object",
29+
"required": ["items"],
30+
"properties": {
31+
"cursor": { "type": "string" },
32+
"items": {
33+
"type": "array",
34+
"items": {
35+
"type": "ref",
36+
"ref": "blue.moji.collection.item#itemView"
37+
}
38+
}
39+
}
40+
}
41+
}
42+
},
43+
"itemView": {
44+
"type": "object",
45+
"required": ["uri", "record"],
46+
"properties": {
47+
"uri": { "type": "string", "format": "at-uri" },
48+
"record": { "type": "ref", "ref": "blue.moji.collection.item#itemView" }
49+
}
50+
}
51+
}
52+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
{
2+
"lexicon": 1,
3+
"id": "blue.moji.collection.putItem",
4+
"defs": {
5+
"main": {
6+
"type": "procedure",
7+
"description": "Write a Bluemoji record, creating or updating it as needed. Requires auth, implemented by AppView.",
8+
"input": {
9+
"encoding": "application/json",
10+
"schema": {
11+
"type": "object",
12+
"required": ["repo", "item"],
13+
"properties": {
14+
"repo": {
15+
"type": "string",
16+
"format": "at-identifier",
17+
"description": "The handle or DID of the repo (aka, current account)."
18+
},
19+
"validate": {
20+
"type": "boolean",
21+
"default": true,
22+
"description": "Can be set to 'false' to skip Lexicon schema validation of record data."
23+
},
24+
"item": {
25+
"type": "ref",
26+
"ref": "blue.moji.collection.item#itemView"
27+
}
28+
}
29+
}
30+
},
31+
"output": {
32+
"encoding": "application/json",
33+
"schema": {
34+
"type": "object",
35+
"required": ["uri"],
36+
"properties": {
37+
"uri": { "type": "string", "format": "at-uri" }
38+
}
39+
}
40+
},
41+
"errors": []
42+
}
43+
}
44+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
{
2+
"lexicon": 1,
3+
"id": "blue.moji.collection.saveToCollection",
4+
"defs": {
5+
"main": {
6+
"type": "procedure",
7+
"description": "Copy a single emoji from another repo. Requires auth.",
8+
"input": {
9+
"encoding": "application/json",
10+
"schema": {
11+
"type": "object",
12+
"required": ["source", "name"],
13+
"properties": {
14+
"source": {
15+
"type": "string",
16+
"format": "at-identifier",
17+
"description": "The handle or DID of the repo to copy from."
18+
},
19+
"name": {
20+
"type": "string",
21+
"description": "The source Bluemoji name/rkey.",
22+
"maxLength": 15
23+
},
24+
"renameTo": {
25+
"type": "string",
26+
"description": "The alias to save the Bluemoji to in the current logged-in user's repo."
27+
}
28+
}
29+
}
30+
},
31+
"output": {
32+
"encoding": "application/json",
33+
"schema": {
34+
"type": "object",
35+
"required": ["uri", "item"],
36+
"properties": {
37+
"uri": { "type": "string", "format": "at-uri" },
38+
"item": {
39+
"type": "ref",
40+
"ref": "blue.moji.collection.item#itemView"
41+
}
42+
}
43+
}
44+
},
45+
"errors": [
46+
{
47+
"name": "EmojiNotFound",
48+
"description": "Indicates the named Bluemoji was not found in the source repo."
49+
},
50+
{
51+
"name": "DestinationExists",
52+
"description": "Indicates another Bluemoji with the same name already exists in the source repo. Set renameTo to rename."
53+
}
54+
]
55+
}
56+
}
57+
}

lexicons-bluemoji/blue.moji/pack/getPack.json

-34
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,40 @@
11
{
22
"lexicon": 1,
3-
"id": "blue.moji.pack.defs",
3+
"id": "blue.moji.packs.defs",
44
"defs": {
5-
"bluemojiPackView": {
5+
"packViewBasic": {
66
"type": "object",
7-
"required": ["uri", "cid", "record", "creator", "indexedAt"],
7+
"required": ["uri", "cid", "name"],
88
"properties": {
99
"uri": { "type": "string", "format": "at-uri" },
1010
"cid": { "type": "string", "format": "cid" },
11-
"record": { "type": "unknown" },
12-
"creator": {
13-
"type": "ref",
14-
"ref": "app.bsky.actor.defs#profileViewBasic"
15-
},
16-
"items": { "type": "ref", "ref": "#listViewBasic" },
17-
"listItemsSample": {
18-
"type": "array",
19-
"maxLength": 12,
20-
"items": { "type": "ref", "ref": "#listItemView" }
11+
"name": { "type": "string", "maxLength": 64, "minLength": 1 },
12+
"description": {
13+
"type": "string",
14+
"maxGraphemes": 300,
15+
"maxLength": 3000
2116
},
22-
"labels": {
17+
"descriptionFacets": {
2318
"type": "array",
24-
"items": { "type": "ref", "ref": "com.atproto.label.defs#label" }
19+
"items": { "type": "ref", "ref": "blue.moji.richtext.facet" }
2520
},
26-
"indexedAt": { "type": "string", "format": "datetime" }
27-
}
28-
},
29-
"listViewBasic": {
30-
"type": "object",
31-
"required": ["uri", "cid", "name"],
32-
"properties": {
33-
"uri": { "type": "string", "format": "at-uri" },
34-
"cid": { "type": "string", "format": "cid" },
35-
"name": { "type": "string", "maxLength": 64, "minLength": 1 },
3621
"avatar": { "type": "string", "format": "uri" },
37-
"listItemCount": { "type": "integer", "minimum": 0 },
22+
"itemCount": { "type": "integer", "minimum": 0 },
3823
"labels": {
3924
"type": "array",
4025
"items": { "type": "ref", "ref": "com.atproto.label.defs#label" }
4126
},
27+
"viewer": { "type": "ref", "ref": "#packViewerState" },
4228
"indexedAt": { "type": "string", "format": "datetime" }
4329
}
4430
},
45-
"listView": {
31+
"packView": {
4632
"type": "object",
4733
"required": ["uri", "cid", "creator", "name", "indexedAt"],
4834
"properties": {
4935
"uri": { "type": "string", "format": "at-uri" },
5036
"cid": { "type": "string", "format": "cid" },
51-
"creator": {
52-
"type": "ref",
53-
"ref": "app.bsky.actor.defs#profileViewBasic"
54-
},
37+
"creator": { "type": "ref", "ref": "app.bsky.actor.defs#profileView" },
5538
"name": { "type": "string", "maxLength": 64, "minLength": 1 },
5639
"description": {
5740
"type": "string",
@@ -63,24 +46,31 @@
6346
"items": { "type": "ref", "ref": "app.bsky.richtext.facet" }
6447
},
6548
"avatar": { "type": "string", "format": "uri" },
66-
"listItemCount": { "type": "integer", "minimum": 0 },
49+
"packItemCount": { "type": "integer", "minimum": 0 },
6750
"labels": {
6851
"type": "array",
6952
"items": { "type": "ref", "ref": "com.atproto.label.defs#label" }
7053
},
54+
"viewer": { "type": "ref", "ref": "#packViewerState" },
7155
"indexedAt": { "type": "string", "format": "datetime" }
7256
}
7357
},
74-
"listItemView": {
58+
"packItemView": {
7559
"type": "object",
7660
"required": ["uri", "subject"],
7761
"properties": {
7862
"uri": { "type": "string", "format": "at-uri" },
7963
"subject": {
8064
"type": "ref",
81-
"ref": "blue.moji.collection.defs#itemView"
65+
"ref": "blue.moji.collection.item#itemView"
8266
}
8367
}
68+
},
69+
"packViewerState": {
70+
"type": "object",
71+
"properties": {
72+
"savedToCollection": { "type": "boolean" }
73+
}
8474
}
8575
}
8676
}

0 commit comments

Comments
 (0)