social bookmarking for atproto

[lexicons] Remove minimum length limits due to bugs

hexmani.ac 444604ad 66c3593b

verified
Changed files
+29 -52
backend
static
lexdocs
social
lexicons
lib
lexicons
types
social
clippr
-9
backend/static/api.json
··· 198 198 "displayName": { 199 199 "type": "string", 200 200 "description": "The display name associated to the profile", 201 - "minLength": 1, 202 201 "maxLength": 64 203 202 }, 204 203 "description": { ··· 327 326 "displayName": { 328 327 "type": "string", 329 328 "description": "A display name to be shown on a profile", 330 - "minLength": 1, 331 329 "maxLength": 64 332 330 }, 333 331 "description": { ··· 361 359 "type": "string", 362 360 "description": "The URL of the bookmark. Cannot be left empty or be modified after creation.", 363 361 "format": "uri", 364 - "minLength": 3, 365 362 "maxLength": 2000 366 363 }, 367 364 "title": { 368 365 "type": "string", 369 366 "description": "The title of the bookmark. If left empty, reuse the URL.", 370 - "minLength": 1, 371 367 "maxLength": 2048 372 368 }, 373 369 "description": { 374 370 "type": "string", 375 371 "description": "A description of the bookmark's content. This should be ripped from the URL metadata and be static for all records using the URL.", 376 - "minLength": 1, 377 372 "maxLength": 4096 378 373 }, 379 374 "notes": { 380 375 "type": "string", 381 376 "description": "User-written notes for the bookmark. Public and personal.", 382 - "minLength": 1, 383 377 "maxLength": 10000 384 378 }, 385 379 "tags": { ··· 423 417 "name": { 424 418 "type": "string", 425 419 "description": "A de-duplicated string containing the name of the tag", 426 - "minLength": 1, 427 420 "maxLength": 64 428 421 }, 429 422 "color": { 430 423 "type": "string", 431 424 "description": "A hexadecimal color code", 432 - "minLength": 4, 433 425 "maxLength": 7 434 426 }, 435 427 "description": { 436 428 "type": "string", 437 429 "description": "A description of the tag for additional context", 438 - "minLength": 1, 439 430 "maxLength": 5000 440 431 }, 441 432 "createdAt": {
-2
lexdocs/social/clippr/actor/defs.json
··· 22 22 }, 23 23 "displayName": { 24 24 "type": "string", 25 - "minGraphemes": 1, 26 - "minLength": 10, 27 25 "maxGraphemes": 64, 28 26 "maxLength": 640, 29 27 "description": "The display name associated to the profile"
-2
lexdocs/social/clippr/actor/profile.json
··· 16 16 "displayName": { 17 17 "type": "string", 18 18 "description": "A display name to be shown on a profile", 19 - "minGraphemes": 1, 20 - "minLength": 10, 21 19 "maxGraphemes": 64, 22 20 "maxLength": 640 23 21 },
-8
lexdocs/social/clippr/feed/clip.json
··· 20 20 "type": "string", 21 21 "format": "uri", 22 22 "description": "The URL of the bookmark. Cannot be left empty or be modified after creation.", 23 - "minGraphemes": 3, 24 - "minLength": 30, 25 23 "maxGraphemes": 2000, 26 24 "maxLength": 20000 27 25 }, 28 26 "title": { 29 27 "type": "string", 30 28 "description": "The title of the bookmark. If left empty, reuse the URL.", 31 - "minGraphemes": 1, 32 - "minLength": 10, 33 29 "maxGraphemes": 2048, 34 30 "maxLength": 20480 35 31 }, 36 32 "description": { 37 33 "type": "string", 38 34 "description": "A description of the bookmark's content. This should be ripped from the URL metadata and be static for all records using the URL.", 39 - "minGraphemes": 1, 40 - "minLength": 10, 41 35 "maxGraphemes": 4096, 42 36 "maxLength": 40960 43 37 }, 44 38 "notes": { 45 39 "type": "string", 46 40 "description": "User-written notes for the bookmark. Public and personal.", 47 - "minGraphemes": 1, 48 - "minLength": 10, 49 41 "maxGraphemes": 10000, 50 42 "maxLength": 100000 51 43 },
-6
lexdocs/social/clippr/feed/tag.json
··· 15 15 "properties": { 16 16 "name": { 17 17 "type": "string", 18 - "minGraphemes": 1, 19 - "minLength": 10, 20 18 "maxGraphemes": 64, 21 19 "maxLength": 640, 22 20 "description": "A de-duplicated string containing the name of the tag" 23 21 }, 24 22 "color": { 25 23 "type": "string", 26 - "minGraphemes": 4, 27 - "minLength": 40, 28 24 "maxGraphemes": 7, 29 25 "maxLength": 70, 30 26 "description": "A hexadecimal color code" 31 27 }, 32 28 "description": { 33 29 "type": "string", 34 - "minGraphemes": 1, 35 - "minLength": 10, 36 30 "maxGraphemes": 5000, 37 31 "maxLength": 50000, 38 32 "description": "A description of the tag for additional context"
+4
lexicons/CHANGELOG.md
··· 1 1 # changelog for @clipprjs/lexicons 2 2 3 + ## v1.0.1 4 + 5 + * remove minimum character prompts due to schema validation errors that broke otherwise valid records 6 + 3 7 ## v1.0.0 4 8 5 9 > this version should be considered as the starting point for a usable Lexicon API. previous versions should be ignored.
+2 -2
lexicons/lib/lexicons/types/social/clippr/actor/defs.ts
··· 25 25 did: /*#__PURE__*/ v.didString(), 26 26 displayName: /*#__PURE__*/ v.optional( 27 27 /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 28 - /*#__PURE__*/ v.stringLength(10, 640), 29 - /*#__PURE__*/ v.stringGraphemes(1, 64), 28 + /*#__PURE__*/ v.stringLength(0, 640), 29 + /*#__PURE__*/ v.stringGraphemes(0, 64), 30 30 ]), 31 31 ), 32 32 handle: /*#__PURE__*/ v.handleString(),
+2 -2
lexicons/lib/lexicons/types/social/clippr/actor/profile.ts
··· 21 21 ]), 22 22 ), 23 23 displayName: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 24 - /*#__PURE__*/ v.stringLength(10, 640), 25 - /*#__PURE__*/ v.stringGraphemes(1, 64), 24 + /*#__PURE__*/ v.stringLength(0, 640), 25 + /*#__PURE__*/ v.stringGraphemes(0, 64), 26 26 ]), 27 27 }), 28 28 );
+8 -8
lexicons/lib/lexicons/types/social/clippr/feed/clip.ts
··· 15 15 $type: /*#__PURE__*/ v.literal("social.clippr.feed.clip"), 16 16 createdAt: /*#__PURE__*/ v.datetimeString(), 17 17 description: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 18 - /*#__PURE__*/ v.stringLength(10, 40960), 19 - /*#__PURE__*/ v.stringGraphemes(1, 4096), 18 + /*#__PURE__*/ v.stringLength(0, 40960), 19 + /*#__PURE__*/ v.stringGraphemes(0, 4096), 20 20 ]), 21 21 languages: /*#__PURE__*/ v.optional( 22 22 /*#__PURE__*/ v.constrain( ··· 26 26 ), 27 27 notes: /*#__PURE__*/ v.optional( 28 28 /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 29 - /*#__PURE__*/ v.stringLength(10, 100000), 30 - /*#__PURE__*/ v.stringGraphemes(1, 10000), 29 + /*#__PURE__*/ v.stringLength(0, 100000), 30 + /*#__PURE__*/ v.stringGraphemes(0, 10000), 31 31 ]), 32 32 ), 33 33 get tags() { ··· 36 36 ); 37 37 }, 38 38 title: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 39 - /*#__PURE__*/ v.stringLength(10, 20480), 40 - /*#__PURE__*/ v.stringGraphemes(1, 2048), 39 + /*#__PURE__*/ v.stringLength(0, 20480), 40 + /*#__PURE__*/ v.stringGraphemes(0, 2048), 41 41 ]), 42 42 unlisted: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.boolean(), false), 43 43 unread: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.boolean(), true), 44 44 url: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.genericUriString(), [ 45 - /*#__PURE__*/ v.stringLength(30, 20000), 46 - /*#__PURE__*/ v.stringGraphemes(3, 2000), 45 + /*#__PURE__*/ v.stringLength(0, 20000), 46 + /*#__PURE__*/ v.stringGraphemes(0, 2000), 47 47 ]), 48 48 }), 49 49 );
+6 -6
lexicons/lib/lexicons/types/social/clippr/feed/tag.ts
··· 14 14 $type: /*#__PURE__*/ v.literal("social.clippr.feed.tag"), 15 15 color: /*#__PURE__*/ v.optional( 16 16 /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 17 - /*#__PURE__*/ v.stringLength(40, 70), 18 - /*#__PURE__*/ v.stringGraphemes(4, 7), 17 + /*#__PURE__*/ v.stringLength(0, 70), 18 + /*#__PURE__*/ v.stringGraphemes(0, 7), 19 19 ]), 20 20 ), 21 21 createdAt: /*#__PURE__*/ v.datetimeString(), 22 22 description: /*#__PURE__*/ v.optional( 23 23 /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 24 - /*#__PURE__*/ v.stringLength(10, 50000), 25 - /*#__PURE__*/ v.stringGraphemes(1, 5000), 24 + /*#__PURE__*/ v.stringLength(0, 50000), 25 + /*#__PURE__*/ v.stringGraphemes(0, 5000), 26 26 ]), 27 27 ), 28 28 name: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 29 - /*#__PURE__*/ v.stringLength(10, 640), 30 - /*#__PURE__*/ v.stringGraphemes(1, 64), 29 + /*#__PURE__*/ v.stringLength(0, 640), 30 + /*#__PURE__*/ v.stringGraphemes(0, 64), 31 31 ]), 32 32 }), 33 33 );
+2 -2
lexicons/package.json
··· 1 1 { 2 2 "type": "module", 3 3 "name": "@clipprjs/lexicons", 4 - "version": "1.0.0", 4 + "version": "1.0.1", 5 5 "description": "Clippr schema definitions", 6 6 "license": "AGPL-3.0-only", 7 7 "private": false, ··· 29 29 "prepublish": "rm -rf dist; pnpm run build" 30 30 }, 31 31 "dependencies": { 32 - "@atcute/atproto": "^3.1.0", 32 + "@atcute/atproto": "^3.1.1", 33 33 "@atcute/lexicons": "^1.1.0" 34 34 }, 35 35 "devDependencies": {
+5 -5
lexicons/pnpm-lock.yaml
··· 9 9 .: 10 10 dependencies: 11 11 '@atcute/atproto': 12 - specifier: ^3.1.0 13 - version: 3.1.0 12 + specifier: ^3.1.1 13 + version: 3.1.1 14 14 '@atcute/lexicons': 15 15 specifier: ^1.1.0 16 16 version: 1.1.0 ··· 24 24 25 25 packages: 26 26 27 - '@atcute/atproto@3.1.0': 28 - resolution: {integrity: sha512-aJbDsY7FcIh8APWKAimBtshPwqoRE056tc0UV6vw4TW4e3nYaHedoJmKhlh/k8KQWxyw64MQThNGMaC89HNoTg==} 27 + '@atcute/atproto@3.1.1': 28 + resolution: {integrity: sha512-D+RLTIPF0xLu7BPZY8KSewAPemJFh+3n3zeQ3ROsLxbTtCHbrTDMAmAFexaVRAPGcPYrwXaBUlv7yZjScJolMg==} 29 29 30 30 '@atcute/lex-cli@2.1.1': 31 31 resolution: {integrity: sha512-QaR0sOP8Z24opGHKsSfleDbP/ahUb6HECkVaOqSwG7ORZzbLK1w0265o1BRjCVr2dT6FxlsMUa2Ge85JMA9bxg==} ··· 64 64 65 65 snapshots: 66 66 67 - '@atcute/atproto@3.1.0': 67 + '@atcute/atproto@3.1.1': 68 68 dependencies: 69 69 '@atcute/lexicons': 1.1.0 70 70