@abraca/nuxt 2.11.0 → 2.14.0
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 +15 -0
- package/dist/module.json +1 -1
- package/dist/module.mjs +9 -0
- package/dist/runtime/components/ACodeEditor.vue +123 -22
- package/dist/runtime/components/ADocPickerModal.d.vue.ts +31 -0
- package/dist/runtime/components/ADocPickerModal.vue +191 -0
- package/dist/runtime/components/ADocPickerModal.vue.d.ts +31 -0
- package/dist/runtime/components/ADocViewToggle.d.vue.ts +40 -0
- package/dist/runtime/components/ADocViewToggle.vue +234 -0
- package/dist/runtime/components/ADocViewToggle.vue.d.ts +40 -0
- package/dist/runtime/components/ADocumentTree.vue +66 -1
- package/dist/runtime/components/AEditor.d.vue.ts +17 -10
- package/dist/runtime/components/AEditor.vue +403 -167
- package/dist/runtime/components/AEditor.vue.d.ts +17 -10
- package/dist/runtime/components/ANodePanel.d.vue.ts +9 -1
- package/dist/runtime/components/ANodePanel.vue +553 -481
- package/dist/runtime/components/ANodePanel.vue.d.ts +9 -1
- package/dist/runtime/components/ATagsEditor.d.vue.ts +19 -0
- package/dist/runtime/components/ATagsEditor.vue +60 -0
- package/dist/runtime/components/ATagsEditor.vue.d.ts +19 -0
- package/dist/runtime/components/aware/AMedia.d.vue.ts +1 -1
- package/dist/runtime/components/aware/AMedia.vue.d.ts +1 -1
- package/dist/runtime/components/chat/AChatInput.d.vue.ts +11 -6
- package/dist/runtime/components/chat/AChatInput.vue +33 -2
- package/dist/runtime/components/chat/AChatInput.vue.d.ts +11 -6
- package/dist/runtime/components/chat/AChatList.d.vue.ts +12 -0
- package/dist/runtime/components/chat/AChatList.vue +76 -32
- package/dist/runtime/components/chat/AChatList.vue.d.ts +12 -0
- package/dist/runtime/components/chat/AChatMessages.d.vue.ts +4 -0
- package/dist/runtime/components/chat/AChatMessages.vue +57 -4
- package/dist/runtime/components/chat/AChatMessages.vue.d.ts +4 -0
- package/dist/runtime/components/chat/AChatPanel.d.vue.ts +6 -2
- package/dist/runtime/components/chat/AChatPanel.vue +17 -1
- package/dist/runtime/components/chat/AChatPanel.vue.d.ts +6 -2
- package/dist/runtime/components/chat/ANodeChatPanel.vue +1 -1
- package/dist/runtime/components/docs/ADocsSearch.d.vue.ts +1 -1
- package/dist/runtime/components/docs/ADocsSearch.vue.d.ts +1 -1
- package/dist/runtime/components/editor/ADocSuggestMenu.d.vue.ts +7 -0
- package/dist/runtime/components/editor/ADocSuggestMenu.vue +68 -0
- package/dist/runtime/components/editor/ADocSuggestMenu.vue.d.ts +7 -0
- package/dist/runtime/components/renderers/AChartRenderer.client.d.vue.ts +17 -0
- package/dist/runtime/components/renderers/AChartRenderer.client.vue +622 -0
- package/dist/runtime/components/renderers/AChartRenderer.client.vue.d.ts +17 -0
- package/dist/runtime/components/renderers/AGraphRenderer.vue +64 -15
- package/dist/runtime/components/renderers/calendar/ACalendarToolbar.d.vue.ts +2 -2
- package/dist/runtime/components/renderers/calendar/ACalendarToolbar.vue.d.ts +2 -2
- package/dist/runtime/components/renderers/media/MediaTransportBar.d.vue.ts +2 -2
- package/dist/runtime/components/renderers/media/MediaTransportBar.vue.d.ts +2 -2
- package/dist/runtime/components/renderers/sheets/ASheetsGrid.d.vue.ts +2 -2
- package/dist/runtime/components/renderers/sheets/ASheetsGrid.vue.d.ts +2 -2
- package/dist/runtime/components/settings/ASettingsAppearancePanel.d.vue.ts +3 -0
- package/dist/runtime/components/settings/ASettingsAppearancePanel.vue +67 -0
- package/dist/runtime/components/settings/ASettingsAppearancePanel.vue.d.ts +3 -0
- package/dist/runtime/components/settings/ASettingsGroup.d.vue.ts +24 -0
- package/dist/runtime/components/settings/ASettingsGroup.vue +31 -0
- package/dist/runtime/components/settings/ASettingsGroup.vue.d.ts +24 -0
- package/dist/runtime/components/settings/ASettingsModal.vue +84 -53
- package/dist/runtime/components/settings/ASettingsPlaceholder.d.vue.ts +20 -0
- package/dist/runtime/components/settings/ASettingsPlaceholder.vue +32 -0
- package/dist/runtime/components/settings/ASettingsPlaceholder.vue.d.ts +20 -0
- package/dist/runtime/components/settings/ASettingsRow.d.vue.ts +34 -0
- package/dist/runtime/components/settings/ASettingsRow.vue +34 -0
- package/dist/runtime/components/settings/ASettingsRow.vue.d.ts +34 -0
- package/dist/runtime/components/settings/sections.d.ts +37 -0
- package/dist/runtime/components/settings/sections.js +45 -0
- package/dist/runtime/components/shell/AUserMenu.d.vue.ts +2 -2
- package/dist/runtime/components/shell/AUserMenu.vue.d.ts +2 -2
- package/dist/runtime/components/shell/AUserProfilePopover.d.vue.ts +1 -1
- package/dist/runtime/components/shell/AUserProfilePopover.vue.d.ts +1 -1
- package/dist/runtime/composables/useChat.d.ts +22 -1
- package/dist/runtime/composables/useChat.js +79 -8
- package/dist/runtime/composables/useDocLinkPick.d.ts +9 -8
- package/dist/runtime/composables/useDocLinkPick.js +7 -18
- package/dist/runtime/composables/useDocSuggest.d.ts +34 -0
- package/dist/runtime/composables/useDocSuggest.js +56 -0
- package/dist/runtime/composables/useNodeContextMenu.d.ts +4 -0
- package/dist/runtime/composables/useNodeContextMenu.js +18 -0
- package/dist/runtime/composables/useSettingsModal.d.ts +1 -1
- package/dist/runtime/extensions/doc-link-drop.js +2 -2
- package/dist/runtime/extensions/doc-suggest.d.ts +28 -0
- package/dist/runtime/extensions/doc-suggest.js +85 -0
- package/dist/runtime/locale.d.ts +8 -0
- package/dist/runtime/locale.js +9 -1
- package/dist/runtime/utils/chatContent.d.ts +20 -2
- package/dist/runtime/utils/chatContent.js +20 -1
- package/dist/runtime/utils/codeHighlightStyle.d.ts +15 -0
- package/dist/runtime/utils/codeHighlightStyle.js +34 -0
- package/dist/runtime/utils/docTypes.js +43 -0
- package/dist/runtime/utils/loadCodeMirror.d.ts +1 -0
- package/dist/runtime/utils/loadCodeMirror.js +6 -3
- package/dist/runtime/utils/titleSync.d.ts +130 -0
- package/dist/runtime/utils/titleSync.js +53 -0
- package/package.json +12 -1
|
@@ -44,7 +44,9 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
44
44
|
focus: () => void | undefined;
|
|
45
45
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
46
46
|
close: () => any;
|
|
47
|
-
send: (content: string
|
|
47
|
+
send: (content: string, opts?: {
|
|
48
|
+
replyTo?: string;
|
|
49
|
+
} | undefined) => any;
|
|
48
50
|
"open-doc": (docId: string) => any;
|
|
49
51
|
"jump-to-quote": (docId: string, from: number, to: number) => any;
|
|
50
52
|
typing: () => any;
|
|
@@ -54,7 +56,9 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
54
56
|
}) => any;
|
|
55
57
|
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
56
58
|
onClose?: (() => any) | undefined;
|
|
57
|
-
onSend?: ((content: string
|
|
59
|
+
onSend?: ((content: string, opts?: {
|
|
60
|
+
replyTo?: string;
|
|
61
|
+
} | undefined) => any) | undefined;
|
|
58
62
|
"onOpen-doc"?: ((docId: string) => any) | undefined;
|
|
59
63
|
"onJump-to-quote"?: ((docId: string, from: number, to: number) => any) | undefined;
|
|
60
64
|
onTyping?: (() => any) | undefined;
|
|
@@ -17,6 +17,19 @@ const props = defineProps({
|
|
|
17
17
|
const emit = defineEmits(["send", "typing", "doc-drop", "open-doc", "jump-to-quote", "close"]);
|
|
18
18
|
const messagesContainer = ref(null);
|
|
19
19
|
const chatInputRef = ref(null);
|
|
20
|
+
const replyingTo = ref(null);
|
|
21
|
+
function startReply(message) {
|
|
22
|
+
replyingTo.value = message;
|
|
23
|
+
nextTick(() => chatInputRef.value?.focus());
|
|
24
|
+
}
|
|
25
|
+
function cancelReply() {
|
|
26
|
+
replyingTo.value = null;
|
|
27
|
+
}
|
|
28
|
+
function onSend(content) {
|
|
29
|
+
const replyTo = replyingTo.value?.id;
|
|
30
|
+
emit("send", content, replyTo ? { replyTo } : void 0);
|
|
31
|
+
replyingTo.value = null;
|
|
32
|
+
}
|
|
20
33
|
function scrollToBottom() {
|
|
21
34
|
if (messagesContainer.value) {
|
|
22
35
|
messagesContainer.value.scrollTop = messagesContainer.value.scrollHeight;
|
|
@@ -68,6 +81,7 @@ defineExpose({
|
|
|
68
81
|
:empty-subtext="emptySubtext"
|
|
69
82
|
@open-doc="(docId) => emit('open-doc', docId)"
|
|
70
83
|
@jump-to-quote="(docId, from, to) => emit('jump-to-quote', docId, from, to)"
|
|
84
|
+
@reply="startReply"
|
|
71
85
|
/>
|
|
72
86
|
|
|
73
87
|
<AChatAgentStatus :agents="activeAgents" />
|
|
@@ -81,9 +95,11 @@ defineExpose({
|
|
|
81
95
|
:can-send="canSend"
|
|
82
96
|
:placeholder="placeholder"
|
|
83
97
|
:mention-users="mentionUsers"
|
|
84
|
-
|
|
98
|
+
:reply-to="replyingTo"
|
|
99
|
+
@send="onSend"
|
|
85
100
|
@typing="emit('typing')"
|
|
86
101
|
@doc-drop="(payload) => emit('doc-drop', payload)"
|
|
102
|
+
@cancel-reply="cancelReply"
|
|
87
103
|
/>
|
|
88
104
|
</div>
|
|
89
105
|
</template>
|
|
@@ -44,7 +44,9 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
44
44
|
focus: () => void | undefined;
|
|
45
45
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
46
46
|
close: () => any;
|
|
47
|
-
send: (content: string
|
|
47
|
+
send: (content: string, opts?: {
|
|
48
|
+
replyTo?: string;
|
|
49
|
+
} | undefined) => any;
|
|
48
50
|
"open-doc": (docId: string) => any;
|
|
49
51
|
"jump-to-quote": (docId: string, from: number, to: number) => any;
|
|
50
52
|
typing: () => any;
|
|
@@ -54,7 +56,9 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
54
56
|
}) => any;
|
|
55
57
|
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
56
58
|
onClose?: (() => any) | undefined;
|
|
57
|
-
onSend?: ((content: string
|
|
59
|
+
onSend?: ((content: string, opts?: {
|
|
60
|
+
replyTo?: string;
|
|
61
|
+
} | undefined) => any) | undefined;
|
|
58
62
|
"onOpen-doc"?: ((docId: string) => any) | undefined;
|
|
59
63
|
"onJump-to-quote"?: ((docId: string, from: number, to: number) => any) | undefined;
|
|
60
64
|
onTyping?: (() => any) | undefined;
|
|
@@ -38,7 +38,7 @@ const typingUsersAdapted = computed(
|
|
|
38
38
|
:empty-text="emptyText"
|
|
39
39
|
:empty-subtext="emptySubtext"
|
|
40
40
|
can-send
|
|
41
|
-
@send="(content) => send(content)"
|
|
41
|
+
@send="(content, opts) => send(content, opts)"
|
|
42
42
|
@typing="typing"
|
|
43
43
|
@open-doc="(id) => emit('open-doc', id)"
|
|
44
44
|
@jump-to-quote="(id, from, to) => emit('jump-to-quote', id, from, to)"
|
|
@@ -239,8 +239,8 @@ declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<import
|
|
|
239
239
|
autofocus: boolean;
|
|
240
240
|
loading: boolean;
|
|
241
241
|
dismissible: boolean;
|
|
242
|
-
overlay: boolean;
|
|
243
242
|
colorMode: boolean;
|
|
243
|
+
overlay: boolean;
|
|
244
244
|
fullscreen: boolean;
|
|
245
245
|
modal: boolean;
|
|
246
246
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>, __VLS_Slots>;
|
|
@@ -239,8 +239,8 @@ declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<import
|
|
|
239
239
|
autofocus: boolean;
|
|
240
240
|
loading: boolean;
|
|
241
241
|
dismissible: boolean;
|
|
242
|
-
overlay: boolean;
|
|
243
242
|
colorMode: boolean;
|
|
243
|
+
overlay: boolean;
|
|
244
244
|
fullscreen: boolean;
|
|
245
245
|
modal: boolean;
|
|
246
246
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>, __VLS_Slots>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { DocSuggestPopupState } from '../../composables/useDocSuggest.js';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
state: DocSuggestPopupState;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_export: 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>;
|
|
6
|
+
declare const _default: typeof __VLS_export;
|
|
7
|
+
export default _default;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { computed, ref, watch, nextTick } from "vue";
|
|
3
|
+
const props = defineProps({
|
|
4
|
+
state: { type: Object, required: true }
|
|
5
|
+
});
|
|
6
|
+
const listRef = ref(null);
|
|
7
|
+
const style = computed(() => {
|
|
8
|
+
const r = props.state.rect;
|
|
9
|
+
if (!r) return {};
|
|
10
|
+
return {
|
|
11
|
+
left: `${Math.round(r.left)}px`,
|
|
12
|
+
top: `${Math.round(r.bottom + 6)}px`
|
|
13
|
+
};
|
|
14
|
+
});
|
|
15
|
+
watch(() => props.state.index, async () => {
|
|
16
|
+
await nextTick();
|
|
17
|
+
listRef.value?.querySelector('[data-active="true"]')?.scrollIntoView({ block: "nearest" });
|
|
18
|
+
});
|
|
19
|
+
function pick(item) {
|
|
20
|
+
props.state.onSelect?.(item);
|
|
21
|
+
}
|
|
22
|
+
</script>
|
|
23
|
+
|
|
24
|
+
<template>
|
|
25
|
+
<Teleport to="body">
|
|
26
|
+
<div
|
|
27
|
+
v-if="state.active && state.rect && state.items.length"
|
|
28
|
+
ref="listRef"
|
|
29
|
+
class="fixed z-[60] w-72 max-h-72 overflow-y-auto overflow-x-hidden rounded-(--ui-radius) border border-(--ui-border) bg-(--ui-bg) shadow-lg p-1"
|
|
30
|
+
:style="style"
|
|
31
|
+
@mousedown.prevent
|
|
32
|
+
>
|
|
33
|
+
<div class="flex items-center gap-1.5 px-2 py-1 text-[11px] font-medium text-(--ui-text-muted)">
|
|
34
|
+
<UIcon
|
|
35
|
+
:name="state.mode === 'embed' ? 'i-lucide-file-box' : 'i-lucide-file-symlink'"
|
|
36
|
+
class="size-3.5 shrink-0"
|
|
37
|
+
/>
|
|
38
|
+
<span>{{ state.mode === "embed" ? "Embed document" : "Link document" }}</span>
|
|
39
|
+
</div>
|
|
40
|
+
|
|
41
|
+
<button
|
|
42
|
+
v-for="(item, i) in state.items"
|
|
43
|
+
:key="item.id + ':' + i"
|
|
44
|
+
type="button"
|
|
45
|
+
:data-active="i === state.index"
|
|
46
|
+
class="w-full min-w-0 flex items-center gap-2 px-2 py-1.5 rounded-(--ui-radius) text-sm text-left text-(--ui-text)"
|
|
47
|
+
:class="i === state.index ? 'bg-(--ui-bg-elevated)' : 'hover:bg-(--ui-bg-elevated)/60'"
|
|
48
|
+
@click="pick(item)"
|
|
49
|
+
>
|
|
50
|
+
<UIcon
|
|
51
|
+
:name="item.icon"
|
|
52
|
+
class="size-4 shrink-0"
|
|
53
|
+
:class="item.isCreate ? 'text-(--ui-primary)' : 'text-(--ui-text-dimmed)'"
|
|
54
|
+
/>
|
|
55
|
+
<span class="flex-1 min-w-0 flex items-baseline gap-1.5 overflow-hidden">
|
|
56
|
+
<span
|
|
57
|
+
v-if="item.prefix"
|
|
58
|
+
class="text-xs text-(--ui-text-dimmed) truncate shrink-0 max-w-[45%]"
|
|
59
|
+
>{{ item.prefix }} /</span>
|
|
60
|
+
<span
|
|
61
|
+
class="truncate"
|
|
62
|
+
:class="item.isCreate ? 'text-(--ui-primary)' : ''"
|
|
63
|
+
>{{ item.label }}</span>
|
|
64
|
+
</span>
|
|
65
|
+
</button>
|
|
66
|
+
</div>
|
|
67
|
+
</Teleport>
|
|
68
|
+
</template>
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { DocSuggestPopupState } from '../../composables/useDocSuggest.js';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
state: DocSuggestPopupState;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_export: 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>;
|
|
6
|
+
declare const _default: typeof __VLS_export;
|
|
7
|
+
export default _default;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type RendererBaseProps } from '../../composables/useRendererBase.js';
|
|
2
|
+
type __VLS_Props = RendererBaseProps & {
|
|
3
|
+
followingUser?: string | null;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {
|
|
6
|
+
connectedUsers: import("vue").ComputedRef<{
|
|
7
|
+
clientId: number;
|
|
8
|
+
name: string;
|
|
9
|
+
color: string;
|
|
10
|
+
avatar: string | undefined;
|
|
11
|
+
publicKey: any;
|
|
12
|
+
}[]>;
|
|
13
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
14
|
+
followingUser: string | null;
|
|
15
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
16
|
+
declare const _default: typeof __VLS_export;
|
|
17
|
+
export default _default;
|