Add configurable columns to directory view
This commit is contained in:
1 parent
f3522f370f
commit
a12424ef66
11 files changed
+181
-59
No files matched your search
@@ -6,20 +6,22 @@ let {
|
||||
style = "",
|
||||
large_icon = false,
|
||||
small_icon = false,
|
||||
children
|
||||
children,
|
||||
onclick,
|
||||
}: {
|
||||
text?: string;
|
||||
style?: string;
|
||||
large_icon?: boolean;
|
||||
small_icon?: boolean;
|
||||
children?: import('svelte').Snippet;
|
||||
onclick?: (e: MouseEvent) => void;
|
||||
} = $props();
|
||||
|
||||
let failed = $state(false)
|
||||
let success = $state(false)
|
||||
|
||||
// Exported so it can be called manually
|
||||
export const copy = () => {
|
||||
export const copy = (e: MouseEvent) => {
|
||||
try {
|
||||
copy_text(text)
|
||||
success = true
|
||||
@@ -32,6 +34,10 @@ export const copy = () => {
|
||||
success = false
|
||||
failed = false
|
||||
}, 10000)
|
||||
|
||||
if (onclick !== undefined) {
|
||||
onclick(e)
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
Reference in new issue
Block a user