rimelight-components 2.1.37 → 2.1.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/module.d.mts +9 -0
- package/dist/module.d.ts +9 -0
- package/dist/module.json +1 -1
- package/dist/module.mjs +15 -1
- package/dist/runtime/auth/index.d.ts +3 -0
- package/dist/runtime/auth/index.js +3 -0
- package/dist/runtime/auth/index.mjs +3 -0
- package/dist/runtime/auth/permissions.d.ts +201 -0
- package/dist/runtime/auth/permissions.js +32 -0
- package/dist/runtime/auth/permissions.mjs +32 -0
- package/dist/runtime/auth/restricted-usernames.d.ts +25 -0
- package/dist/runtime/auth/restricted-usernames.js +236 -0
- package/dist/runtime/auth/restricted-usernames.mjs +236 -0
- package/dist/runtime/auth/utils.d.ts +10 -0
- package/dist/runtime/auth/utils.js +20 -0
- package/dist/runtime/auth/utils.mjs +20 -0
- package/dist/runtime/components/FloatingToolsOverlay.d.vue.ts +3 -0
- package/dist/runtime/components/FloatingToolsOverlay.vue +74 -0
- package/dist/runtime/components/FloatingToolsOverlay.vue.d.ts +3 -0
- package/dist/runtime/components/app/Footer.vue +1 -1
- package/dist/runtime/components/app/Header.vue +1 -1
- package/dist/runtime/components/app/Image.vue +1 -1
- package/dist/runtime/components/app/Logo.vue +1 -1
- package/dist/runtime/components/app/NewsletterSignup.vue +1 -1
- package/dist/runtime/components/app/ScrollToTop.vue +1 -1
- package/dist/runtime/components/cards/TeamCard.vue +1 -1
- package/dist/runtime/components/content/Callout.vue +1 -1
- package/dist/runtime/components/content/Section.vue +1 -1
- package/dist/runtime/components/dashboard/NotificationsSlideover.d.vue.ts +3 -0
- package/dist/runtime/components/dashboard/NotificationsSlideover.vue +49 -0
- package/dist/runtime/components/dashboard/NotificationsSlideover.vue.d.ts +3 -0
- package/dist/runtime/components/dashboard/QuickActions.d.vue.ts +3 -0
- package/dist/runtime/components/dashboard/QuickActions.vue +36 -0
- package/dist/runtime/components/dashboard/QuickActions.vue.d.ts +3 -0
- package/dist/runtime/components/dashboard/TeamsMenu.d.vue.ts +6 -0
- package/dist/runtime/components/dashboard/TeamsMenu.vue +77 -0
- package/dist/runtime/components/dashboard/TeamsMenu.vue.d.ts +6 -0
- package/dist/runtime/components/dashboard/customers/AddModal.d.vue.ts +3 -0
- package/dist/runtime/components/dashboard/customers/AddModal.vue +45 -0
- package/dist/runtime/components/dashboard/customers/AddModal.vue.d.ts +3 -0
- package/dist/runtime/components/dashboard/customers/DeleteModal.d.vue.ts +16 -0
- package/dist/runtime/components/dashboard/customers/DeleteModal.vue +28 -0
- package/dist/runtime/components/dashboard/customers/DeleteModal.vue.d.ts +16 -0
- package/dist/runtime/components/dashboard/floating-tools/FocusTimerTool.d.vue.ts +3 -0
- package/dist/runtime/components/dashboard/floating-tools/FocusTimerTool.vue +37 -0
- package/dist/runtime/components/dashboard/floating-tools/FocusTimerTool.vue.d.ts +3 -0
- package/dist/runtime/components/headings/H1.d.vue.ts +13 -0
- package/dist/runtime/components/headings/H1.vue +9 -0
- package/dist/runtime/components/headings/H1.vue.d.ts +13 -0
- package/dist/runtime/components/headings/H2.d.vue.ts +13 -0
- package/dist/runtime/components/headings/H2.vue +9 -0
- package/dist/runtime/components/headings/H2.vue.d.ts +13 -0
- package/dist/runtime/components/headings/H3.d.vue.ts +13 -0
- package/dist/runtime/components/headings/H3.vue +9 -0
- package/dist/runtime/components/headings/H3.vue.d.ts +13 -0
- package/dist/runtime/components/headings/H4.d.vue.ts +13 -0
- package/dist/runtime/components/headings/H4.vue +9 -0
- package/dist/runtime/components/headings/H4.vue.d.ts +13 -0
- package/dist/runtime/components/headings/H5.d.vue.ts +13 -0
- package/dist/runtime/components/headings/H5.vue +9 -0
- package/dist/runtime/components/headings/H5.vue.d.ts +13 -0
- package/dist/runtime/components/headings/H6.d.vue.ts +13 -0
- package/dist/runtime/components/headings/H6.vue +9 -0
- package/dist/runtime/components/headings/H6.vue.d.ts +13 -0
- package/dist/runtime/components/modals/ConfirmModal.d.vue.ts +3 -0
- package/dist/runtime/components/modals/ConfirmModal.vue +36 -0
- package/dist/runtime/components/modals/ConfirmModal.vue.d.ts +3 -0
- package/dist/runtime/components/nodes/LinkNode.vue +1 -1
- package/dist/runtime/components/nodes/TextNode.vue +1 -1
- package/dist/runtime/components/notes/NoteCard.d.vue.ts +31 -0
- package/dist/runtime/components/notes/NoteCard.vue +86 -0
- package/dist/runtime/components/notes/NoteCard.vue.d.ts +31 -0
- package/dist/runtime/components/notes/NoteModal.d.vue.ts +35 -0
- package/dist/runtime/components/notes/NoteModal.vue +224 -0
- package/dist/runtime/components/notes/NoteModal.vue.d.ts +35 -0
- package/dist/runtime/components/page/PageMention.vue +1 -1
- package/dist/runtime/components/page/PageSurround.vue +1 -1
- package/dist/runtime/components/page/PageTOC.vue +1 -1
- package/dist/runtime/components/swatches/ColorSwatch.vue +1 -1
- package/dist/runtime/components/swatches/FontSwatch.vue +1 -1
- package/dist/runtime/components/swatches/ImageSwatch.vue +1 -1
- package/dist/runtime/components/utilities/Placeholder.vue +1 -1
- package/dist/runtime/composables/app/index.d.ts +4 -0
- package/dist/runtime/composables/app/index.js +4 -0
- package/dist/runtime/composables/app/index.mjs +4 -0
- package/dist/runtime/composables/app/useApi.d.ts +9 -0
- package/dist/runtime/composables/app/useApi.js +56 -0
- package/dist/runtime/composables/app/useApi.mjs +56 -0
- package/dist/runtime/composables/app/useConfirm.d.ts +18 -0
- package/dist/runtime/composables/app/useConfirm.js +56 -0
- package/dist/runtime/composables/app/useConfirm.mjs +56 -0
- package/dist/runtime/composables/components/index.d.ts +1 -0
- package/dist/runtime/composables/components/index.js +1 -0
- package/dist/runtime/composables/components/index.mjs +1 -0
- package/dist/runtime/composables/dashboard/index.d.ts +5 -0
- package/dist/runtime/composables/dashboard/index.js +5 -0
- package/dist/runtime/composables/dashboard/index.mjs +5 -0
- package/dist/runtime/composables/dashboard/useDashboard.d.ts +3 -0
- package/dist/runtime/composables/dashboard/useDashboard.js +18 -0
- package/dist/runtime/composables/dashboard/useDashboard.mjs +18 -0
- package/dist/runtime/composables/dashboard/useFloatingTools.d.ts +19 -0
- package/dist/runtime/composables/dashboard/useFloatingTools.js +44 -0
- package/dist/runtime/composables/dashboard/useFloatingTools.mjs +44 -0
- package/dist/runtime/composables/dashboard/useFocusTimer.d.ts +44 -0
- package/dist/runtime/composables/dashboard/useFocusTimer.js +141 -0
- package/dist/runtime/composables/dashboard/useFocusTimer.mjs +141 -0
- package/dist/runtime/composables/dashboard/useNotes.d.ts +9 -0
- package/dist/runtime/composables/dashboard/useNotes.js +57 -0
- package/dist/runtime/composables/dashboard/useNotes.mjs +57 -0
- package/dist/runtime/composables/dashboard/useQuickActions.d.ts +15 -0
- package/dist/runtime/composables/dashboard/useQuickActions.js +19 -0
- package/dist/runtime/composables/dashboard/useQuickActions.mjs +19 -0
- package/dist/runtime/composables/index.d.ts +4 -7
- package/dist/runtime/composables/index.js +4 -7
- package/dist/runtime/composables/index.mjs +4 -7
- package/dist/runtime/composables/pages/index.d.ts +4 -0
- package/dist/runtime/composables/pages/index.js +4 -0
- package/dist/runtime/composables/pages/index.mjs +4 -0
- package/dist/runtime/composables/{useBlockEditor.d.ts → pages/useBlockEditor.d.ts} +131 -131
- package/dist/runtime/composables/{useInfobox.d.ts → pages/useInfobox.d.ts} +1 -1
- package/dist/runtime/composables/{usePageEditor.d.ts → pages/usePageEditor.d.ts} +1 -1
- package/dist/runtime/composables/{usePageRegistry.d.ts → pages/usePageRegistry.d.ts} +2 -2
- package/dist/runtime/db/auth.d.ts +2096 -0
- package/dist/runtime/db/auth.js +268 -0
- package/dist/runtime/db/auth.mjs +268 -0
- package/dist/runtime/db/index.d.ts +1 -0
- package/dist/runtime/db/index.js +1 -0
- package/dist/runtime/db/index.mjs +1 -0
- package/dist/runtime/types/index.d.ts +1 -0
- package/dist/runtime/types/index.js +1 -0
- package/dist/runtime/types/index.mjs +1 -0
- package/dist/runtime/types/utils.d.ts +51 -0
- package/dist/runtime/types/utils.js +0 -0
- package/dist/runtime/types/utils.mjs +0 -0
- package/package.json +4 -2
- /package/dist/runtime/composables/{useDateRange.d.ts → app/useDateRange.d.ts} +0 -0
- /package/dist/runtime/composables/{useDateRange.js → app/useDateRange.js} +0 -0
- /package/dist/runtime/composables/{useDateRange.mjs → app/useDateRange.mjs} +0 -0
- /package/dist/runtime/composables/{useHeaderStack.d.ts → app/useHeaderStack.d.ts} +0 -0
- /package/dist/runtime/composables/{useHeaderStack.js → app/useHeaderStack.js} +0 -0
- /package/dist/runtime/composables/{useHeaderStack.mjs → app/useHeaderStack.mjs} +0 -0
- /package/dist/runtime/composables/{useRC.d.ts → components/useRC.d.ts} +0 -0
- /package/dist/runtime/composables/{useRC.js → components/useRC.js} +0 -0
- /package/dist/runtime/composables/{useRC.mjs → components/useRC.mjs} +0 -0
- /package/dist/runtime/composables/{useBlockEditor.js → pages/useBlockEditor.js} +0 -0
- /package/dist/runtime/composables/{useBlockEditor.mjs → pages/useBlockEditor.mjs} +0 -0
- /package/dist/runtime/composables/{useInfobox.js → pages/useInfobox.js} +0 -0
- /package/dist/runtime/composables/{useInfobox.mjs → pages/useInfobox.mjs} +0 -0
- /package/dist/runtime/composables/{usePageEditor.js → pages/usePageEditor.js} +0 -0
- /package/dist/runtime/composables/{usePageEditor.mjs → pages/usePageEditor.mjs} +0 -0
- /package/dist/runtime/composables/{usePageRegistry.js → pages/usePageRegistry.js} +0 -0
- /package/dist/runtime/composables/{usePageRegistry.mjs → pages/usePageRegistry.mjs} +0 -0
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import * as z from "zod";
|
|
3
|
+
import {} from "@nuxt/ui";
|
|
4
|
+
import { useToast } from "@nuxt/ui/composables";
|
|
5
|
+
import { ref, reactive } from "vue";
|
|
6
|
+
const schema = z.object({
|
|
7
|
+
name: z.string().min(2, "Too short"),
|
|
8
|
+
email: z.string().email("Invalid email")
|
|
9
|
+
});
|
|
10
|
+
const open = ref(false);
|
|
11
|
+
const state = reactive({
|
|
12
|
+
name: void 0,
|
|
13
|
+
email: void 0
|
|
14
|
+
});
|
|
15
|
+
const toast = useToast();
|
|
16
|
+
async function onSubmit(event) {
|
|
17
|
+
toast.add({
|
|
18
|
+
title: "Success",
|
|
19
|
+
description: `New customer ${event.data.name} added`,
|
|
20
|
+
color: "success"
|
|
21
|
+
});
|
|
22
|
+
open.value = false;
|
|
23
|
+
}
|
|
24
|
+
</script>
|
|
25
|
+
|
|
26
|
+
<template>
|
|
27
|
+
<UModal v-model:open="open" title="New customer" description="Add a new customer to the database">
|
|
28
|
+
<UButton label="New customer" icon="lucide:plus" />
|
|
29
|
+
|
|
30
|
+
<template #body>
|
|
31
|
+
<UForm :schema="schema" :state="state" class="space-y-4" @submit="onSubmit">
|
|
32
|
+
<UFormField label="Name" placeholder="John Doe" name="name">
|
|
33
|
+
<UInput v-model="state.name" class="w-full" />
|
|
34
|
+
</UFormField>
|
|
35
|
+
<UFormField label="Email" placeholder="john.doe@example.com" name="email">
|
|
36
|
+
<UInput v-model="state.email" class="w-full" />
|
|
37
|
+
</UFormField>
|
|
38
|
+
<div class="flex justify-end gap-2">
|
|
39
|
+
<UButton label="Cancel" color="neutral" variant="subtle" @click="open = false" />
|
|
40
|
+
<UButton label="Create" color="primary" variant="solid" type="submit" />
|
|
41
|
+
</div>
|
|
42
|
+
</UForm>
|
|
43
|
+
</template>
|
|
44
|
+
</UModal>
|
|
45
|
+
</template>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
declare const _default: typeof __VLS_export;
|
|
3
|
+
export default _default;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
count?: number;
|
|
3
|
+
};
|
|
4
|
+
declare var __VLS_8: {};
|
|
5
|
+
type __VLS_Slots = {} & {
|
|
6
|
+
default?: (props: typeof __VLS_8) => any;
|
|
7
|
+
};
|
|
8
|
+
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
9
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
10
|
+
declare const _default: typeof __VLS_export;
|
|
11
|
+
export default _default;
|
|
12
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
13
|
+
new (): {
|
|
14
|
+
$slots: S;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { ref } from "vue";
|
|
3
|
+
const { count = 0 } = defineProps({
|
|
4
|
+
count: { type: Number, required: false }
|
|
5
|
+
});
|
|
6
|
+
const open = ref(false);
|
|
7
|
+
async function onSubmit() {
|
|
8
|
+
await new Promise((resolve) => setTimeout(resolve, 1e3));
|
|
9
|
+
open.value = false;
|
|
10
|
+
}
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<template>
|
|
14
|
+
<UModal
|
|
15
|
+
v-model:open="open"
|
|
16
|
+
:title="`Delete ${count} customer${count > 1 ? 's' : ''}`"
|
|
17
|
+
:description="`Are you sure, this action cannot be undone.`"
|
|
18
|
+
>
|
|
19
|
+
<slot />
|
|
20
|
+
|
|
21
|
+
<template #body>
|
|
22
|
+
<div class="flex justify-end gap-2">
|
|
23
|
+
<UButton label="Cancel" color="neutral" variant="subtle" @click="open = false" />
|
|
24
|
+
<UButton label="Delete" color="error" variant="solid" loading-auto @click="onSubmit" />
|
|
25
|
+
</div>
|
|
26
|
+
</template>
|
|
27
|
+
</UModal>
|
|
28
|
+
</template>
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
count?: number;
|
|
3
|
+
};
|
|
4
|
+
declare var __VLS_8: {};
|
|
5
|
+
type __VLS_Slots = {} & {
|
|
6
|
+
default?: (props: typeof __VLS_8) => any;
|
|
7
|
+
};
|
|
8
|
+
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
9
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
10
|
+
declare const _default: typeof __VLS_export;
|
|
11
|
+
export default _default;
|
|
12
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
13
|
+
new (): {
|
|
14
|
+
$slots: S;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
declare const _default: typeof __VLS_export;
|
|
3
|
+
export default _default;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { useFocusTimer } from "~/src/runtime/composables";
|
|
3
|
+
const focusTimer = useFocusTimer();
|
|
4
|
+
</script>
|
|
5
|
+
|
|
6
|
+
<template>
|
|
7
|
+
<div class="flex flex-col gap-sm">
|
|
8
|
+
<UProgress :model-value="focusTimer.progress.value" size="sm" color="primary" />
|
|
9
|
+
|
|
10
|
+
<div class="flex flex-col items-center">
|
|
11
|
+
<div class="text-4xl font-bold tabular-nums">
|
|
12
|
+
{{ focusTimer.formattedTime.value }}
|
|
13
|
+
</div>
|
|
14
|
+
<div class="text-md text-muted uppercase">
|
|
15
|
+
{{ focusTimer.mode.value.replace("-", " ") }}
|
|
16
|
+
</div>
|
|
17
|
+
</div>
|
|
18
|
+
|
|
19
|
+
<div class="flex items-center gap-sm">
|
|
20
|
+
<UButton
|
|
21
|
+
:icon="focusTimer.isRunning.value ? 'lucide:pause' : 'lucide:play'"
|
|
22
|
+
:label="focusTimer.isRunning.value ? 'Pause' : 'Start'"
|
|
23
|
+
:color="focusTimer.isRunning.value ? 'warning' : 'primary'"
|
|
24
|
+
block
|
|
25
|
+
size="sm"
|
|
26
|
+
@click="focusTimer.isRunning.value ? focusTimer.pauseTimer() : focusTimer.startTimer()"
|
|
27
|
+
/>
|
|
28
|
+
<UButton
|
|
29
|
+
icon="lucide:rotate-ccw"
|
|
30
|
+
color="neutral"
|
|
31
|
+
variant="ghost"
|
|
32
|
+
size="sm"
|
|
33
|
+
@click="focusTimer.resetTimer()"
|
|
34
|
+
/>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
</template>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
declare const _default: typeof __VLS_export;
|
|
3
|
+
export default _default;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_base: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
7
|
+
declare const _default: typeof __VLS_export;
|
|
8
|
+
export default _default;
|
|
9
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
10
|
+
new (): {
|
|
11
|
+
$slots: S;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
declare const _default: typeof __VLS_export;
|
|
3
|
+
export default _default;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { useConfirm } from "~/src/runtime/composables";
|
|
3
|
+
import { computed } from "vue";
|
|
4
|
+
const { state, handleConfirm, handleCancel } = useConfirm();
|
|
5
|
+
const isOpen = computed({
|
|
6
|
+
get: () => state.value.isVisible,
|
|
7
|
+
set: (value) => {
|
|
8
|
+
state.value.isVisible = value;
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<template>
|
|
14
|
+
<UModal
|
|
15
|
+
v-model:open="isOpen"
|
|
16
|
+
:title="state.options.title"
|
|
17
|
+
:description="state.options.description"
|
|
18
|
+
>
|
|
19
|
+
<template #body>
|
|
20
|
+
<div class="flex flex-row justify-between gap-sm">
|
|
21
|
+
<UButton
|
|
22
|
+
color="error"
|
|
23
|
+
variant="outline"
|
|
24
|
+
:label="state.options.cancelLabel"
|
|
25
|
+
@click="handleCancel"
|
|
26
|
+
/>
|
|
27
|
+
<UButton
|
|
28
|
+
:color="state.options.danger ? 'error' : 'success'"
|
|
29
|
+
:variant="state.options.danger ? 'subtle' : 'solid'"
|
|
30
|
+
:label="state.options.confirmLabel"
|
|
31
|
+
@click="handleConfirm"
|
|
32
|
+
/>
|
|
33
|
+
</div>
|
|
34
|
+
</template>
|
|
35
|
+
</UModal>
|
|
36
|
+
</template>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
declare const _default: typeof __VLS_export;
|
|
3
|
+
export default _default;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
import { computed } from "vue";
|
|
3
3
|
import { tv } from "../../internal/tv";
|
|
4
|
-
import { useRC } from "
|
|
4
|
+
import { useRC } from "~/src/runtime/composables";
|
|
5
5
|
const { href, target, content, rc: rcProp } = defineProps({
|
|
6
6
|
href: { type: String, required: true },
|
|
7
7
|
target: { type: String, required: false },
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
import { tv } from "../../internal/tv";
|
|
3
|
-
import { useRC } from "
|
|
3
|
+
import { useRC } from "~/src/runtime/composables";
|
|
4
4
|
const { content, rc: rcProp } = defineProps({
|
|
5
5
|
content: { type: String, required: true },
|
|
6
6
|
rc: { type: Object, required: false }
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { Note } from "../../db/auth.js";
|
|
2
|
+
export interface NoteCardProps {
|
|
3
|
+
note: Note;
|
|
4
|
+
}
|
|
5
|
+
type __VLS_Props = NoteCardProps;
|
|
6
|
+
export interface NoteCardEmits {
|
|
7
|
+
(e: "click"): void;
|
|
8
|
+
(e: "togglePin"): void;
|
|
9
|
+
(e: "archive"): void;
|
|
10
|
+
(e: "delete"): void;
|
|
11
|
+
}
|
|
12
|
+
type __VLS_ModelProps = {
|
|
13
|
+
"selected"?: boolean;
|
|
14
|
+
};
|
|
15
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
16
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
17
|
+
"update:selected": (value: boolean) => any;
|
|
18
|
+
} & {
|
|
19
|
+
delete: () => any;
|
|
20
|
+
archive: () => any;
|
|
21
|
+
togglePin: () => any;
|
|
22
|
+
click: () => any;
|
|
23
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
24
|
+
onDelete?: (() => any) | undefined;
|
|
25
|
+
onArchive?: (() => any) | undefined;
|
|
26
|
+
onTogglePin?: (() => any) | undefined;
|
|
27
|
+
onClick?: (() => any) | undefined;
|
|
28
|
+
"onUpdate:selected"?: ((value: boolean) => any) | undefined;
|
|
29
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
30
|
+
declare const _default: typeof __VLS_export;
|
|
31
|
+
export default _default;
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { ref } from "vue";
|
|
3
|
+
const selected = defineModel("selected", { type: Boolean, ...{ default: false } });
|
|
4
|
+
const isHovered = ref(false);
|
|
5
|
+
const { note } = defineProps({
|
|
6
|
+
note: { type: Object, required: true }
|
|
7
|
+
});
|
|
8
|
+
const emit = defineEmits(["click", "togglePin", "archive", "delete"]);
|
|
9
|
+
</script>
|
|
10
|
+
|
|
11
|
+
<template>
|
|
12
|
+
<div
|
|
13
|
+
class="group relative flex flex-col"
|
|
14
|
+
@mouseenter="isHovered = true"
|
|
15
|
+
@mouseleave="isHovered = false"
|
|
16
|
+
>
|
|
17
|
+
<UCard
|
|
18
|
+
variant="soft"
|
|
19
|
+
class="h-48 cursor-pointer transition-all duration-200 hover:ring-2 hover:ring-primary-500/20"
|
|
20
|
+
:ui="{ body: 'flex flex-col gap-sm justify-between h-full' }"
|
|
21
|
+
@click="emit('click')"
|
|
22
|
+
>
|
|
23
|
+
<template #default>
|
|
24
|
+
<div class="flex flex-col gap-xs">
|
|
25
|
+
<h4 v-if="note.title" class="line-clamp-1 text-md font-bold break-words">
|
|
26
|
+
{{ note.title }}
|
|
27
|
+
</h4>
|
|
28
|
+
<p
|
|
29
|
+
v-if="note.content"
|
|
30
|
+
class="line-clamp-3 text-sm break-words whitespace-pre-line text-dimmed"
|
|
31
|
+
>
|
|
32
|
+
{{ note.content }}
|
|
33
|
+
</p>
|
|
34
|
+
</div>
|
|
35
|
+
<div
|
|
36
|
+
v-if="note.labels?.length"
|
|
37
|
+
class="flex flex-row flex-nowrap gap-xs overflow-hidden mask-[linear-gradient(90deg,black_85%,transparent)]"
|
|
38
|
+
>
|
|
39
|
+
<UBadge
|
|
40
|
+
v-for="labelEntry in note.labels"
|
|
41
|
+
:key="labelEntry.label.id"
|
|
42
|
+
color="neutral"
|
|
43
|
+
variant="subtle"
|
|
44
|
+
size="sm"
|
|
45
|
+
class="shrink-0 truncate"
|
|
46
|
+
>
|
|
47
|
+
{{ labelEntry.label.name }}
|
|
48
|
+
</UBadge>
|
|
49
|
+
</div>
|
|
50
|
+
</template>
|
|
51
|
+
</UCard>
|
|
52
|
+
<div
|
|
53
|
+
v-if="selected || isHovered"
|
|
54
|
+
class="absolute top-2 left-2 z-20 transition-opacity duration-200"
|
|
55
|
+
>
|
|
56
|
+
<UCheckbox v-model="selected" color="primary" size="lg" @click.stop />
|
|
57
|
+
</div>
|
|
58
|
+
<div class="absolute top-2 right-2 z-20 flex flex-col gap-xs transition-opacity duration-200">
|
|
59
|
+
<UButton
|
|
60
|
+
v-if="note.isPinned || isHovered"
|
|
61
|
+
:icon="note.isPinned ? 'lucide:pin-off' : 'lucide:pin'"
|
|
62
|
+
variant="ghost"
|
|
63
|
+
size="xs"
|
|
64
|
+
:class="
|
|
65
|
+
note.isPinned ? 'opacity-100' : 'opacity-0 group-hover:opacity-100'
|
|
66
|
+
"
|
|
67
|
+
@click.stop="emit('togglePin')"
|
|
68
|
+
/>
|
|
69
|
+
<UButton
|
|
70
|
+
v-if="isHovered"
|
|
71
|
+
:icon="note.isArchived ? 'lucide:archive-x' : 'lucide:archive-restore'"
|
|
72
|
+
variant="ghost"
|
|
73
|
+
size="xs"
|
|
74
|
+
@click.stop="emit('archive')"
|
|
75
|
+
/>
|
|
76
|
+
<UButton
|
|
77
|
+
v-if="isHovered"
|
|
78
|
+
icon="lucide:trash-2"
|
|
79
|
+
variant="ghost"
|
|
80
|
+
color="error"
|
|
81
|
+
size="xs"
|
|
82
|
+
@click.stop="emit('delete')"
|
|
83
|
+
/>
|
|
84
|
+
</div>
|
|
85
|
+
</div>
|
|
86
|
+
</template>
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { Note } from "../../db/auth.js";
|
|
2
|
+
export interface NoteCardProps {
|
|
3
|
+
note: Note;
|
|
4
|
+
}
|
|
5
|
+
type __VLS_Props = NoteCardProps;
|
|
6
|
+
export interface NoteCardEmits {
|
|
7
|
+
(e: "click"): void;
|
|
8
|
+
(e: "togglePin"): void;
|
|
9
|
+
(e: "archive"): void;
|
|
10
|
+
(e: "delete"): void;
|
|
11
|
+
}
|
|
12
|
+
type __VLS_ModelProps = {
|
|
13
|
+
"selected"?: boolean;
|
|
14
|
+
};
|
|
15
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
16
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
17
|
+
"update:selected": (value: boolean) => any;
|
|
18
|
+
} & {
|
|
19
|
+
delete: () => any;
|
|
20
|
+
archive: () => any;
|
|
21
|
+
togglePin: () => any;
|
|
22
|
+
click: () => any;
|
|
23
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
24
|
+
onDelete?: (() => any) | undefined;
|
|
25
|
+
onArchive?: (() => any) | undefined;
|
|
26
|
+
onTogglePin?: (() => any) | undefined;
|
|
27
|
+
onClick?: (() => any) | undefined;
|
|
28
|
+
"onUpdate:selected"?: ((value: boolean) => any) | undefined;
|
|
29
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
30
|
+
declare const _default: typeof __VLS_export;
|
|
31
|
+
export default _default;
|