A music player that connects to your cloud/distributed storage.
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

feat: playlist definition

+83 -2
+1
deno.jsonc
··· 139 139 // .ts 140 140 "./definitions/types/sh/diffuse/output/constituent.ts": "./src/definitions/types/sh/diffuse/output/constituent.ts", 141 141 "./definitions/types/sh/diffuse/output/favourite.ts": "./src/definitions/types/sh/diffuse/output/favourite.ts", 142 + "./definitions/types/sh/diffuse/output/playlist.ts": "./src/definitions/types/sh/diffuse/output/playlist.ts", 142 143 "./definitions/types/sh/diffuse/output/track.ts": "./src/definitions/types/sh/diffuse/output/track.ts", 143 144 }, 144 145 "tasks": {
+1
src/definitions/index.ts
··· 1 1 export * as ShDiffuseOutputConstituent from "./types/sh/diffuse/output/constituent.js"; 2 2 export * as ShDiffuseOutputFavourite from "./types/sh/diffuse/output/favourite.js"; 3 + export * as ShDiffuseOutputPlaylist from "./types/sh/diffuse/output/playlist.js"; 3 4 export * as ShDiffuseOutputTrack from "./types/sh/diffuse/output/track.js";
+75
src/definitions/output/playlist.json
··· 1 + { 2 + "lexicon": 1, 3 + "id": "sh.diffuse.output.playlist", 4 + "defs": { 5 + "main": { 6 + "type": "record", 7 + "record": { 8 + "type": "object", 9 + "required": ["collection", "items", "name"], 10 + "nullable": ["autoGenerate"], 11 + "properties": { 12 + "autoGenerate": { 13 + "type": "ref", 14 + "ref": "#autoGenerate" 15 + }, 16 + "collection": { 17 + "type": "boolean", 18 + "default": false, 19 + "description": "If this property is set to true, the playlist items should not be presented in order. It's considered a collection of tracks." 20 + }, 21 + "items": { 22 + "type": "array", 23 + "items": { 24 + "type": "ref", 25 + "ref": "#item" 26 + } 27 + }, 28 + "name": { 29 + "type": "string" 30 + } 31 + } 32 + } 33 + }, 34 + "autoGenerate": { 35 + "type": "object", 36 + "description": "Auto-generate the items of the playlist, overriding the included items. If this property is set, the playlist should always be treated as a collection.", 37 + "required": ["criteria"], 38 + "properties": { 39 + "criteria": { 40 + "type": "array", 41 + "items": { "type": "ref", "ref": "#criterion" } 42 + } 43 + } 44 + }, 45 + "criterion": { 46 + "type": "object", 47 + "required": ["field", "value"], 48 + "properties": { 49 + "field": { "type": "string" }, 50 + "transformations": { 51 + "type": "array", 52 + "items": { "type": "ref", "ref": "#transformation" } 53 + }, 54 + "value": { 55 + "type": "unknown", 56 + "description": "Value that should be matched belonging to the given field" 57 + } 58 + } 59 + }, 60 + "item": { 61 + "type": "object", 62 + "required": ["criteria"], 63 + "properties": { 64 + "criteria": { 65 + "type": "array", 66 + "items": { "type": "ref", "ref": "#criterion" } 67 + } 68 + } 69 + }, 70 + "transformation": { 71 + "type": "string", 72 + "description": "Transformation to apply to the field value before comparison" 73 + } 74 + } 75 + }
+6 -2
src/definitions/types.d.ts
··· 2 2 Main as Constituent, 3 3 } from "./types/sh/diffuse/output/constituent.ts"; 4 4 5 + export type { Main as Favourite } from "./types/sh/diffuse/output/favourite.ts"; 6 + 5 7 export type { 8 + AutoGenerate as PlaylistAutoGeneration, 6 9 Criterion, 7 - Main as Favourite, 10 + Item as PlaylistItem, 11 + Main as Playlist, 8 12 Transformation, 9 - } from "./types/sh/diffuse/output/favourite.ts"; 13 + } from "./types/sh/diffuse/output/playlist.ts"; 10 14 11 15 export type { 12 16 Main as Track,