mirror of
https://github.com/seriousm4x/UpSnap.git
synced 2026-11-28 12:53:04 +00:00
Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 8a4969f2e1 | |||
| fc94d0b209 | |||
| 31d43bcb1f | |||
| ce0efdd58b | |||
| 63ef2a1e8c | |||
| 8cfdb8a8fd | |||
| ab782cbb4a |
@@ -22,7 +22,7 @@
|
||||
"@sveltejs/adapter-static": "^3.0.8",
|
||||
"@sveltejs/kit": "^2.22.2",
|
||||
"@sveltejs/vite-plugin-svelte": "^5.1.0",
|
||||
"daisyui": "^5.0.43",
|
||||
"daisyui": "^5.0.46",
|
||||
"eslint": "^9.30.1",
|
||||
"eslint-config-prettier": "^10.1.5",
|
||||
"eslint-plugin-svelte": "^3.10.1",
|
||||
@@ -31,12 +31,12 @@
|
||||
"prettier": "^3.6.2",
|
||||
"prettier-plugin-svelte": "^3.4.0",
|
||||
"prettier-plugin-tailwindcss": "^0.6.13",
|
||||
"svelte": "^5.35.0",
|
||||
"svelte": "^5.35.4",
|
||||
"svelte-check": "^4.2.2",
|
||||
"tailwindcss": "^4.1.11",
|
||||
"tslib": "^2.8.1",
|
||||
"typescript": "^5.8.3",
|
||||
"typescript-eslint": "^8.35.1",
|
||||
"typescript-eslint": "^8.36.0",
|
||||
"vite": "^6.3.5"
|
||||
},
|
||||
"type": "module",
|
||||
|
||||
Generated
+624
-1551
File diff suppressed because it is too large
Load Diff
@@ -181,7 +181,7 @@
|
||||
</div>
|
||||
<div class="hidden {$settingsPub?.website_title ? 'lg:flex' : 'md:flex'}">
|
||||
{#if $settingsPub?.website_title}
|
||||
<span class="px-2">{$settingsPub?.website_title}</span>
|
||||
<span class="self-center px-2">{$settingsPub?.website_title}</span>
|
||||
{/if}
|
||||
<ul class="menu menu-horizontal h-full gap-1 px-1">
|
||||
<li class="h-full">
|
||||
|
||||
@@ -60,21 +60,18 @@
|
||||
)
|
||||
return;
|
||||
|
||||
if (
|
||||
settingsPrivClone.interval === '' ||
|
||||
!(await parseCron(settingsPrivClone.interval)) ||
|
||||
Object.keys(cronParser.parseString(settingsPrivClone.interval).errors).length > 0
|
||||
) {
|
||||
try {
|
||||
cronParser.parse(settingsPrivClone.interval);
|
||||
} catch {
|
||||
toast.error(m.settings_invalid_cron());
|
||||
throw new Error(`failed to parse cron: ` + settingsPrivClone.interval);
|
||||
}
|
||||
|
||||
if (settingsPrivClone.interval === '' || !(await parseCron(settingsPrivClone.interval))) {
|
||||
toast.error(m.settings_invalid_cron());
|
||||
throw new Error('ping_interval not valid');
|
||||
}
|
||||
|
||||
if (faviconInputElement.files !== null && faviconInputElement.files?.length > 0) {
|
||||
let form = new FormData();
|
||||
form.append('favicon', faviconInputElement.files[0]);
|
||||
const res = await $pocketbase.collection('settings_public').update(settingsPubClone.id, form);
|
||||
settingsPub.set(res as SettingsPublic);
|
||||
}
|
||||
await $pocketbase
|
||||
.collection('settings_public')
|
||||
.update(settingsPubClone.id, settingsPubClone)
|
||||
@@ -84,6 +81,14 @@
|
||||
.catch((err) => {
|
||||
toast.error(err.message);
|
||||
});
|
||||
|
||||
if (faviconInputElement.files !== null && faviconInputElement.files?.length > 0) {
|
||||
let form = new FormData();
|
||||
form.append('favicon', faviconInputElement.files[0]);
|
||||
const res = await $pocketbase.collection('settings_public').update(settingsPubClone.id, form);
|
||||
settingsPub.set(res as SettingsPublic);
|
||||
}
|
||||
|
||||
await $pocketbase
|
||||
.collection('settings_private')
|
||||
.update(settingsPrivClone.id, settingsPrivClone)
|
||||
|
||||
Reference in New Issue
Block a user