Your collection
-
-
-
- -
+ ${col.map((c) =>
+ keyed(
+ c.id,
+ html`
+
-
+ + + ${c.name} + + ++++ + + ++ ${c.description?.trim().length + ? unsafeHTML( + marked.parse(c.description, { async: false }), + ) + : nothing} +++ ${c.uri && !c.html + ? html` + + ` + : html` + + `} ++
+ `,
+ )
+ )}
+
+ You have not saved any facets yet. +
+`; + +/** + * @param {{ id: string }} _ + */ +function deleteFacet({ id }) { + return async () => { + const c = confirm("Are you sure you want to delete this facet?"); + if (!c) return; + + await Output.waitUntilLoaded(output.facets); + + output.facets.save( + output.facets.collection().filter((c) => !(c.id === id)), + ); + }; +} diff --git a/src/facets/you.vto b/src/facets/you.vto index 8881cfb7..ed3436ec 100644 --- a/src/facets/you.vto +++ b/src/facets/you.vto @@ -4,6 +4,20 @@ base: ../../ title: Your collection | Facets | Diffuse --- -Your collection
-Your collection
+ +
+
+
+
+
+
+
+
+
diff --git a/src/styles/diffuse/page.css b/src/styles/diffuse/page.css
index 05976bc8..f07545ce 100644
--- a/src/styles/diffuse/page.css
+++ b/src/styles/diffuse/page.css
@@ -141,12 +141,12 @@ ul.columns {
*/
.dropdown {
- background: var(--bg-color);
+ background: oklch(from var(--bg-color) calc(l - 0.05) c h);
border: 0;
border-radius: var(--radius-md);
box-shadow: var(--box-shadow-lg);
color: var(--text-color);
- font-size: var(--fs-xs);
+ font-size: var(--fs-sm);
margin: 0;
margin-top: var(--space-3xs);
padding: 0;
@@ -161,7 +161,8 @@ ul.columns {
& > a {
cursor: pointer;
display: block;
- padding: var(--space-3xs) var(--space-2xs);
+ min-width: var(--space-3xl);
+ padding: var(--space-xs) var(--space-sm);
text-decoration: none;
& > * {
@@ -181,6 +182,10 @@ ul.columns {
a:hover i {
opacity: 1;
}
+
+ .with-icon {
+ gap: var(--space-2xs);
+ }
}
/**
@@ -493,7 +498,6 @@ nav {
display: flex;
flex-wrap: wrap;
gap: var(--space-xs);
- margin-bottom: var(--space-lg);
margin-top: var(--space-md);
padding-bottom: var(--space-md);
}
+
+
+