Skip to content

Commit 4cbcd57

Browse files
committed
refactor(web): scroll resources container
1 parent 7b2b440 commit 4cbcd57

File tree

2 files changed

+38
-5
lines changed

2 files changed

+38
-5
lines changed

web/src/index.css

+16
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,19 @@
1313
width: 100vw;
1414
height: 100vh;
1515
}
16+
17+
::-webkit-scrollbar {
18+
width: 2px;
19+
}
20+
21+
::-webkit-scrollbar-track {
22+
background: #25262b;
23+
}
24+
25+
::-webkit-scrollbar-thumb {
26+
background: #909296;
27+
}
28+
29+
::-webkit-scrollbar-thumb:hover {
30+
background: #a6a7ab;
31+
}

web/src/pages/root/Root.svelte

+22-5
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,31 @@
33
import { IconSearch } from '@tabler/icons-svelte';
44
import { router } from 'tinro';
55
6-
const resources = ['ox_core', 'oxmysql', 'ox_inventory', 'ox_doorlock', 'ox_lib', 'ox_vehicleshop', 'ox_target'];
6+
const resources = [
7+
'ox_core',
8+
'oxmysql',
9+
'ox_inventory',
10+
'ox_doorlock',
11+
'ox_lib',
12+
'ox_vehicleshop',
13+
'ox_target',
14+
'ox_core',
15+
'oxmysql',
16+
'ox_inventory',
17+
'ox_doorlock',
18+
'ox_lib',
19+
'ox_vehicleshop',
20+
'ox_target',
21+
];
722
</script>
823

924
<div class="p-4 w-full h-full flex justify-between gap-4">
10-
<div class="bg-dark-700 p-4 flex flex-col w-2/3 rounded-md">
11-
<p class="text-2xl mb-4">Resources</p>
12-
<Input icon={IconSearch} />
13-
<div class="flex flex-col gap-3 mt-6">
25+
<div class="bg-dark-700 p-4 pr-0 flex flex-col w-2/3 rounded-md">
26+
<div class="pr-4">
27+
<p class="text-2xl mb-4">Resources</p>
28+
<Input icon={IconSearch} />
29+
</div>
30+
<div class="flex flex-col gap-3 mt-6 overflow-y-auto pr-4">
1431
{#each resources as resource}
1532
<button
1633
on:click={() => router.goto(`/${resource}`)}

0 commit comments

Comments
 (0)