added what im watching
This commit is contained in:
@@ -9,7 +9,7 @@ export const nodes = [
|
||||
export const server_loads = [];
|
||||
|
||||
export const dictionary = {
|
||||
"/": [2]
|
||||
"/": [~2]
|
||||
};
|
||||
|
||||
export const hooks = {
|
||||
|
||||
@@ -7,7 +7,7 @@ export const options = {
|
||||
csrf_trusted_origins: [],
|
||||
service_worker_options: undefined,
|
||||
templates: {
|
||||
app: ({ head, body, assets, nonce, env }) => "<!doctype html>\n<html lang=\"en\">\n\t<head>\n\t\t<meta charset=\"utf-8\" />\n\t\t<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\" />\n\t\t<meta name=\"text-scale\" content=\"scale\" />\n\t\t" + head + "\n\t</head>\n\t<body data-sveltekit-preload-data=\"hover\">\n\t\t<div style=\"display: contents\">" + body + "</div>\n\t</body>\n</html>\n",
|
||||
app: ({ head, body, assets, nonce, env }) => "<!doctype html>\n<html lang=\"en\">\n\t<head>\n\t\t<!-- Fonts -->\n\t\t<link rel=\"preconnect\" href=\"https://fonts.googleapis.com\" />\n\t\t<link rel=\"preconnect\" href=\"https://fonts.gstatic.com\" crossorigin />\n\t\t<link\n\t\t\thref=\"https://fonts.googleapis.com/css2?family=Squada+One&display=swap\"\n\t\t\trel=\"stylesheet\"\n\t\t/>\n\t\t<link rel=\"preconnect\" href=\"https://fonts.googleapis.com\" />\n\t\t<link rel=\"preconnect\" href=\"https://fonts.gstatic.com\" crossorigin />\n\t\t<link\n\t\t\thref=\"https://fonts.googleapis.com/css2?family=Fira+Mono:wght@400;500;700&display=swap\"\n\t\t\trel=\"stylesheet\"\n\t\t/>\n\n\t\t<!-- Not Fonts -->\n\t\t<meta charset=\"utf-8\" />\n\t\t<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\" />\n\t\t<meta name=\"text-scale\" content=\"scale\" />\n\t\t" + head + "\n\t</head>\n\t<style>\n\t\t.fira-mono-regular {\n\t\t\tfont-family: 'Fira Mono', monospace;\n\t\t\tfont-weight: 400;\n\t\t\tfont-style: normal;\n\t\t}\n\n\t\t.fira-mono-medium {\n\t\t\tfont-family: 'Fira Mono', monospace;\n\t\t\tfont-weight: 500;\n\t\t\tfont-style: normal;\n\t\t}\n\n\t\t.fira-mono-bold {\n\t\t\tfont-family: 'Fira Mono', monospace;\n\t\t\tfont-weight: 700;\n\t\t\tfont-style: normal;\n\t\t}\n\t</style>\n\t<body class=\"fira-mono-regular bg-ctp-mantle text-ctp-text\" data-sveltekit-preload-data=\"hover\">\n\t\t<div style=\"display: contents\">" + body + "</div>\n\t</body>\n</html>\n",
|
||||
error
|
||||
}
|
||||
};
|
||||
|
||||
@@ -9,5 +9,6 @@ export const assets = [
|
||||
|
||||
export const routes = [
|
||||
{"id":"/","page":true,"endpoint":false},
|
||||
{"id":"/artwork/[itemId]","page":false,"endpoint":true}
|
||||
{"id":"/artwork/[itemId]","page":false,"endpoint":true},
|
||||
{"id":"/posters/[itemId]","page":false,"endpoint":true}
|
||||
];
|
||||
4
.svelte-kit/generated/dev/env/config.js
vendored
4
.svelte-kit/generated/dev/env/config.js
vendored
@@ -23,7 +23,9 @@ export function set_env(env) {
|
||||
dynamic_private_env.JELLYFIN_PLAYLIST_ID = JELLYFIN_PLAYLIST_ID;
|
||||
const JELLYFIN_USER_ID = validate(variables, env.JELLYFIN_USER_ID, "JELLYFIN_USER_ID", issues);
|
||||
dynamic_private_env.JELLYFIN_USER_ID = JELLYFIN_USER_ID;
|
||||
const JELLYFIN_LIBRARY_ID = validate(variables, env.JELLYFIN_LIBRARY_ID, "JELLYFIN_LIBRARY_ID", issues);
|
||||
dynamic_private_env.JELLYFIN_LIBRARY_ID = JELLYFIN_LIBRARY_ID;
|
||||
handle_issues(issues);
|
||||
}
|
||||
|
||||
set_env({JELLYFIN_URL:"http://192.168.1.180:8096",JELLYFIN_API_KEY:"2727181a933049dcbc8d63cf0bcc15f3",JELLYFIN_PLAYLIST_ID:"e3088b1ab54766ad3668bc71a574a2f7",JELLYFIN_USER_ID:"5824596713e44e8c949f529e1a081393"});
|
||||
set_env({JELLYFIN_URL:"http://192.168.1.180:8096",JELLYFIN_API_KEY:"2727181a933049dcbc8d63cf0bcc15f3",JELLYFIN_PLAYLIST_ID:"e3088b1ab54766ad3668bc71a574a2f7",JELLYFIN_USER_ID:"5824596713e44e8c949f529e1a081393",JELLYFIN_LIBRARY_ID:"a656b907eb3a73532e40e44b968d0225"});
|
||||
@@ -4,3 +4,4 @@ export const JELLYFIN_URL = env.JELLYFIN_URL;
|
||||
export const JELLYFIN_API_KEY = env.JELLYFIN_API_KEY;
|
||||
export const JELLYFIN_PLAYLIST_ID = env.JELLYFIN_PLAYLIST_ID;
|
||||
export const JELLYFIN_USER_ID = env.JELLYFIN_USER_ID;
|
||||
export const JELLYFIN_LIBRARY_ID = env.JELLYFIN_LIBRARY_ID;
|
||||
|
||||
@@ -3,5 +3,5 @@ globalThis.__sveltekit_dev = {
|
||||
env: {
|
||||
// empty
|
||||
},
|
||||
version: "1793725498340"
|
||||
version: "1793733574808"
|
||||
};
|
||||
@@ -4,5 +4,8 @@
|
||||
],
|
||||
"/artwork/[itemId]": [
|
||||
"src/routes/artwork/[itemId]/+server.ts"
|
||||
],
|
||||
"/posters/[itemId]": [
|
||||
"src/routes/posters/[itemId]/+server.ts"
|
||||
]
|
||||
}
|
||||
10
.svelte-kit/types/src/routes/posters/[itemId]/$types.d.ts
vendored
Normal file
10
.svelte-kit/types/src/routes/posters/[itemId]/$types.d.ts
vendored
Normal file
@@ -0,0 +1,10 @@
|
||||
import type * as Kit from '@sveltejs/kit';
|
||||
import { MatcherParam } from '@sveltejs/kit/params';
|
||||
|
||||
type Expand<T> = T extends infer O ? { [K in keyof O]: O[K] } : never;
|
||||
type RouteParams = { itemId: string };
|
||||
type RouteId = '/posters/[itemId]';
|
||||
|
||||
export type EntryGenerator = () => Promise<Array<RouteParams>> | Array<RouteParams>;
|
||||
export type RequestHandler = Kit.RequestHandler<RouteParams, RouteId>;
|
||||
export type RequestEvent = Kit.RequestEvent<RouteParams, RouteId>;
|
||||
@@ -1,16 +1,20 @@
|
||||
// @ts-nocheck
|
||||
import type { PageServerLoad } from './$types';
|
||||
import { getLatestPlaylistSong } from '#lib/server/jellyfin';
|
||||
import { JELLYFIN_PLAYLIST_ID } from '$app/env/private';
|
||||
import { getLatestPlaylistSong, getLatestWatchedSeries } from '#lib/server/jellyfin';
|
||||
import { JELLYFIN_PLAYLIST_ID, JELLYFIN_LIBRARY_ID } from '$app/env/private';
|
||||
|
||||
export const load = () => {
|
||||
const latestSong = getLatestPlaylistSong(globalThis.fetch, JELLYFIN_PLAYLIST_ID);
|
||||
console.log(JELLYFIN_LIBRARY_ID);
|
||||
const latestSeries = getLatestWatchedSeries(globalThis.fetch, JELLYFIN_LIBRARY_ID);
|
||||
|
||||
latestSong.catch(() => {});
|
||||
latestSeries.catch(() => {});
|
||||
|
||||
return {
|
||||
streamed: {
|
||||
latestSong
|
||||
latestSong,
|
||||
latestSeries
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user