2025-10-09 15:48:23 +02:00
|
|
|
<script lang="ts">
|
|
|
|
|
import { bookmark_del, bookmarks_store } from "lib/Bookmarks";
|
2025-10-10 00:12:14 +02:00
|
|
|
import { fs_encode_path } from "lib/FilesystemAPI";
|
2025-10-09 15:48:23 +02:00
|
|
|
import { highlight_current_page } from "lib/HighlightCurrentPage";
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
{#each $bookmarks_store as bookmark}
|
|
|
|
|
<div class="row">
|
2025-10-10 00:12:14 +02:00
|
|
|
<a class="button" href="/d{fs_encode_path(bookmark.path)}" use:highlight_current_page>
|
2025-10-09 15:48:23 +02:00
|
|
|
<i class="icon">{bookmark.icon}</i>
|
|
|
|
|
<span class="hide_small">{bookmark.label}</span>
|
|
|
|
|
</a>
|
2025-10-13 16:05:50 +02:00
|
|
|
<button onclick={() => bookmark_del(bookmark.id)}>
|
2025-10-09 15:48:23 +02:00
|
|
|
<i class="icon">delete</i>
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
|
|
|
|
{/each}
|
|
|
|
|
|
|
|
|
|
<style>
|
|
|
|
|
.row {
|
|
|
|
|
display: flex;
|
|
|
|
|
flex-direction: row;
|
|
|
|
|
}
|
|
|
|
|
.row>a {
|
|
|
|
|
flex: 1 1 auto;
|
|
|
|
|
}
|
|
|
|
|
.row>button {
|
|
|
|
|
flex: 0 0 auto;
|
|
|
|
|
}
|
|
|
|
|
.button {
|
|
|
|
|
background: none;
|
|
|
|
|
box-shadow: none;
|
|
|
|
|
}
|
|
|
|
|
@media(max-width: 1000px) {
|
|
|
|
|
.hide_small {
|
|
|
|
|
display: none;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</style>
|