{ "lexicon": 1, "id": "com.deckbelcher.richtext.facet", "defs": { "byteSlice": { "type": "object", "description": "Specifies the sub-string range a facet feature applies to.\nStart index is inclusive, end index is exclusive.\nIndices are zero-indexed, counting bytes of the UTF-8 encoded text.", "required": [ "byteStart", "byteEnd" ], "properties": { "byteEnd": { "type": "integer", "minimum": 0 }, "byteStart": { "type": "integer", "minimum": 0 } } }, "link": { "type": "object", "description": "Facet feature for a URL.\nThe text URL may have been simplified or truncated, but the facet reference should be a complete URL.", "required": [ "uri" ], "properties": { "uri": { "type": "string", "format": "uri" } } }, "main": { "type": "object", "description": "Annotation of a sub-string within rich text.\nExtends Bluesky's facet system to support DeckBelcher-specific features.", "required": [ "index", "features" ], "properties": { "features": { "type": "array", "items": { "type": "union", "refs": [ "#mention", "#link", "#tag" ] } }, "index": { "type": "ref", "ref": "#byteSlice" } } }, "mention": { "type": "object", "description": "Facet feature for mention of another account.\nThe text is usually a handle, including an `@` prefix, but the facet reference is a DID.", "required": [ "did" ], "properties": { "did": { "type": "string", "format": "did" } } }, "tag": { "type": "object", "description": "Facet feature for a hashtag.\nThe text usually includes a '#' prefix, but the facet reference should not.", "required": [ "tag" ], "properties": { "tag": { "type": "string", "maxLength": 640, "maxGraphemes": 64 } } } } }