mirror of
https://github.com/BetterSEQTA/BetterSEQTA-Plus.git
synced 2026-06-06 03:34:40 +00:00
feat: visual improvements
This commit is contained in:
+1
-1
@@ -78,7 +78,7 @@
|
|||||||
"codemirror": "^6.0.1",
|
"codemirror": "^6.0.1",
|
||||||
"color": "^5.0.0",
|
"color": "^5.0.0",
|
||||||
"dompurify": "^3.2.4",
|
"dompurify": "^3.2.4",
|
||||||
"embeddia": "^1.1.3",
|
"embeddia": "^1.1.4",
|
||||||
"embla-carousel-autoplay": "^8.5.2",
|
"embla-carousel-autoplay": "^8.5.2",
|
||||||
"embla-carousel-svelte": "^8.5.2",
|
"embla-carousel-svelte": "^8.5.2",
|
||||||
"events": "^3.3.0",
|
"events": "^3.3.0",
|
||||||
|
|||||||
@@ -111,6 +111,11 @@
|
|||||||
isLoading = true;
|
isLoading = true;
|
||||||
selectedIndex = 0;
|
selectedIndex = 0;
|
||||||
|
|
||||||
|
tick().then(() => {
|
||||||
|
const selectedElement = resultsList?.querySelector(`li:nth-child(1)`);
|
||||||
|
selectedElement?.scrollIntoView({ block: 'nearest' });
|
||||||
|
});
|
||||||
|
|
||||||
const term = searchTerm.trim().toLowerCase();
|
const term = searchTerm.trim().toLowerCase();
|
||||||
|
|
||||||
if (commandsFuse && dynamicContentFuse) {
|
if (commandsFuse && dynamicContentFuse) {
|
||||||
@@ -143,20 +148,12 @@
|
|||||||
searchTerm = '';
|
searchTerm = '';
|
||||||
selectedIndex = 0;
|
selectedIndex = 0;
|
||||||
combinedResults = [];
|
combinedResults = [];
|
||||||
tick().then(() => {
|
|
||||||
const selectedElement = resultsList?.querySelector(`li:nth-child(1)`);
|
|
||||||
selectedElement?.scrollIntoView({ block: 'nearest' });
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
$effect(() => {
|
$effect(() => {
|
||||||
if (combinedResults.length === 0 && calculatorResult && commandPalleteOpen) {
|
if (combinedResults.length === 0 && calculatorResult && commandPalleteOpen) {
|
||||||
selectedIndex = 0;
|
selectedIndex = 0;
|
||||||
tick().then(() => {
|
|
||||||
const selectedElement = resultsList?.querySelector(`li:nth-child(1)`);
|
|
||||||
selectedElement?.scrollIntoView({ block: 'nearest' });
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -232,7 +229,7 @@
|
|||||||
role="button"
|
role="button"
|
||||||
tabindex="0">
|
tabindex="0">
|
||||||
<div
|
<div
|
||||||
class="w-full max-w-2xl overflow-clip rounded-xl ring-1 shadow-2xl ring-black/5 dark:ring-white/10 { transparencyEffects ? 'bg-white/80 dark:bg-zinc-900/80 backdrop-blur' : 'bg-white dark:bg-zinc-900' }"
|
class="w-full max-w-2xl overflow-clip rounded-xl ring-1 shadow-2xl ring-black/5 dark:ring-white/10 { transparencyEffects ? 'bg-white/80 dark:bg-zinc-900/80 backdrop-blur-xl' : 'bg-white dark:bg-zinc-900' }"
|
||||||
transition:scale={{ duration: 100, start: 0.95, opacity: 0, easing: circOut }}
|
transition:scale={{ duration: 100, start: 0.95, opacity: 0, easing: circOut }}
|
||||||
onclick={(e: MouseEvent) => {
|
onclick={(e: MouseEvent) => {
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
@@ -276,7 +273,7 @@
|
|||||||
{#if result.type === 'command'}
|
{#if result.type === 'command'}
|
||||||
{@const staticItem = item as StaticCommandItem}
|
{@const staticItem = item as StaticCommandItem}
|
||||||
<button
|
<button
|
||||||
class="w-full flex items-center px-2 py-1.5 rounded-lg select-none cursor-pointer group
|
class="w-full flex items-center px-2 py-1.5 rounded-lg select-none cursor-pointer group transition-colors duration-100
|
||||||
{isSelected ? 'bg-zinc-900/5 dark:bg-white/10 text-zinc-900 dark:text-white' : 'hover:bg-zinc-500/5 dark:hover:bg-white/5 text-zinc-800 dark:text-zinc-200'}"
|
{isSelected ? 'bg-zinc-900/5 dark:bg-white/10 text-zinc-900 dark:text-white' : 'hover:bg-zinc-500/5 dark:hover:bg-white/5 text-zinc-800 dark:text-zinc-200'}"
|
||||||
onclick={() => executeItemAction(staticItem)}
|
onclick={() => executeItemAction(staticItem)}
|
||||||
>
|
>
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<button
|
<button
|
||||||
class="w-full flex flex-col px-2 py-1.5 rounded-lg select-none cursor-pointer group
|
class="w-full flex flex-col px-2 py-1.5 rounded-lg select-none cursor-pointer group transition-colors duration-100
|
||||||
{isSelected ? 'bg-zinc-900/5 dark:bg-white/10 text-zinc-900 dark:text-white' : 'hover:bg-zinc-500/5 dark:hover:bg-white/5 text-zinc-800 dark:text-zinc-200'}"
|
{isSelected ? 'bg-zinc-900/5 dark:bg-white/10 text-zinc-900 dark:text-white' : 'hover:bg-zinc-500/5 dark:hover:bg-white/5 text-zinc-800 dark:text-zinc-200'}"
|
||||||
>
|
>
|
||||||
<div class="flex items-center w-full">
|
<div class="flex items-center w-full">
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<button
|
<button
|
||||||
class="w-full flex flex-col px-2 py-1.5 rounded-lg select-none cursor-pointer group
|
class="w-full flex flex-col px-2 py-1.5 rounded-lg select-none cursor-pointer group transition-colors duration-100
|
||||||
{isSelected ? 'bg-zinc-900/5 dark:bg-white/10 text-zinc-900 dark:text-white' : 'hover:bg-zinc-500/5 dark:hover:bg-white/5 text-zinc-800 dark:text-zinc-200'}"
|
{isSelected ? 'bg-zinc-900/5 dark:bg-white/10 text-zinc-900 dark:text-white' : 'hover:bg-zinc-500/5 dark:hover:bg-white/5 text-zinc-800 dark:text-zinc-200'}"
|
||||||
>
|
>
|
||||||
<div class="flex items-center w-full">
|
<div class="flex items-center w-full">
|
||||||
|
|||||||
@@ -18,8 +18,7 @@ export const forumsJob: Job = {
|
|||||||
id: "forums",
|
id: "forums",
|
||||||
label: "Forums",
|
label: "Forums",
|
||||||
renderComponentId: "forum",
|
renderComponentId: "forum",
|
||||||
//frequency: { type: "expiry", afterMs: 30 * 24 * 60 * 60 * 1000 }, // 30 days
|
frequency: { type: "expiry", afterMs: 30 * 24 * 60 * 60 * 1000 }, // 30 days
|
||||||
frequency: { type: "interval", ms: 1000 }, // 1s
|
|
||||||
|
|
||||||
run: async (ctx) => {
|
run: async (ctx) => {
|
||||||
const existingIds = new Set(
|
const existingIds = new Set(
|
||||||
|
|||||||
@@ -10,6 +10,3 @@ export const renderComponentMap: Record<string, typeof SvelteComponent> = {
|
|||||||
// subject: SubjectComponent,
|
// subject: SubjectComponent,
|
||||||
// etc...
|
// etc...
|
||||||
};
|
};
|
||||||
|
|
||||||
void AssessmentItem;
|
|
||||||
void ForumItem;
|
|
||||||
Reference in New Issue
Block a user