@abraca/nuxt 2.52.0 → 2.54.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.json +1 -1
- package/dist/runtime/components/ADocRenderer.vue +6 -3
- package/dist/runtime/components/ADocSubPageList.vue +1 -0
- package/dist/runtime/components/ADocumentTree.vue +1 -0
- package/dist/runtime/components/AEditor.d.vue.ts +10 -10
- package/dist/runtime/components/AEditor.vue +246 -235
- package/dist/runtime/components/AEditor.vue.d.ts +10 -10
- package/dist/runtime/components/ANodePanel.d.vue.ts +10 -0
- package/dist/runtime/components/ANodePanel.vue +40 -12
- package/dist/runtime/components/ANodePanel.vue.d.ts +10 -0
- package/dist/runtime/components/ANodeSettingsPanel.d.vue.ts +8 -0
- package/dist/runtime/components/ANodeSettingsPanel.vue +22 -8
- package/dist/runtime/components/ANodeSettingsPanel.vue.d.ts +8 -0
- package/dist/runtime/components/aware/APresenceBlobs.vue +9 -2
- package/dist/runtime/components/renderers/ACalendarRenderer.vue +1 -0
- package/dist/runtime/components/renderers/AChartRenderer.client.vue +1 -0
- package/dist/runtime/components/renderers/AChecklistRenderer.vue +1 -0
- package/dist/runtime/components/renderers/ADashboardRenderer.vue +1 -0
- package/dist/runtime/components/renderers/AGalleryRenderer.vue +1 -0
- package/dist/runtime/components/renderers/AGraphRenderer.vue +1 -0
- package/dist/runtime/components/renderers/AKanbanRenderer.vue +1 -0
- package/dist/runtime/components/renderers/AMapRenderer.vue +1 -0
- package/dist/runtime/components/renderers/AMediaRenderer.vue +1 -0
- package/dist/runtime/components/renderers/AOutlineRenderer.vue +1 -0
- package/dist/runtime/components/renderers/AOverviewRenderer.vue +1 -0
- package/dist/runtime/components/renderers/ASheetsRenderer.client.vue +1 -0
- package/dist/runtime/components/renderers/ASlidesRenderer.vue +1 -0
- package/dist/runtime/components/renderers/ATableRenderer.vue +1 -0
- package/dist/runtime/components/renderers/ATimelineRenderer.vue +1 -0
- package/dist/runtime/components/shell/ADocPanelSettings.d.vue.ts +8 -0
- package/dist/runtime/components/shell/ADocPanelSettings.vue +5 -2
- package/dist/runtime/components/shell/ADocPanelSettings.vue.d.ts +8 -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/composables/useNodePanel.d.ts +11 -4
- package/dist/runtime/composables/useNodePanel.js +2 -17
- package/dist/runtime/composables/useProviderRole.d.ts +17 -0
- package/dist/runtime/composables/useProviderRole.js +22 -0
- package/dist/runtime/composables/useYDoc.js +27 -5
- package/dist/runtime/extensions/views/DocLinkView.vue +5 -4
- package/dist/runtime/extensions/views/DocumentMetaView.vue +50 -0
- package/package.json +1 -1
package/dist/module.json
CHANGED
|
@@ -5,6 +5,7 @@ import { useAbracadabra } from "../composables/useAbracadabra";
|
|
|
5
5
|
import { useSpaceConnections } from "../composables/useSpaceConnections";
|
|
6
6
|
import { usePluginRegistry } from "../composables/usePluginRegistry";
|
|
7
7
|
import { useDocumentPermissions } from "../composables/useDocumentPermissions";
|
|
8
|
+
import { useProviderRole } from "../composables/useProviderRole";
|
|
8
9
|
import { resolveDocType } from "../utils/docTypes";
|
|
9
10
|
const props = defineProps({
|
|
10
11
|
docId: { type: String, required: true },
|
|
@@ -23,11 +24,13 @@ const docType = computed(() => props.entry?.type ?? resolvedEntry.value?.type ??
|
|
|
23
24
|
const docMeta = computed(() => props.entry?.meta ?? resolvedEntry.value?.meta ?? {});
|
|
24
25
|
const registry = usePluginRegistry();
|
|
25
26
|
const docTypeDef = computed(() => resolveDocType(docType.value, registry));
|
|
26
|
-
const
|
|
27
|
+
const childProvider = shallowRef(null);
|
|
28
|
+
const childProviderRole = useProviderRole(() => childProvider.value);
|
|
29
|
+
const roleForDoc = computed(() => childProviderRole.value ?? abra.effectiveRole.value);
|
|
30
|
+
const { canWrite: canWriteRole } = useDocumentPermissions(roleForDoc);
|
|
27
31
|
const effectiveEditable = computed(
|
|
28
|
-
() => props.editable !== false && (!
|
|
32
|
+
() => props.editable !== false && (!roleForDoc.value || canWriteRole.value)
|
|
29
33
|
);
|
|
30
|
-
const childProvider = shallowRef(null);
|
|
31
34
|
async function loadChildProvider(id) {
|
|
32
35
|
childProvider.value = null;
|
|
33
36
|
if (!id) return;
|
|
@@ -998,6 +998,7 @@ const isDragActive = computed(() => tiptapDragActive.value || externalDragActive
|
|
|
998
998
|
:node-label="openNodeLabel"
|
|
999
999
|
:child-provider="openNodeProvider"
|
|
1000
1000
|
:is-loading="nodePanelLoading"
|
|
1001
|
+
:editable="editable"
|
|
1001
1002
|
@close="closePanel"
|
|
1002
1003
|
/>
|
|
1003
1004
|
</div>
|
|
@@ -61,7 +61,7 @@ type __VLS_ModelProps = {
|
|
|
61
61
|
modelValue?: any;
|
|
62
62
|
};
|
|
63
63
|
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
64
|
-
declare var
|
|
64
|
+
declare var __VLS_57: {
|
|
65
65
|
editor: any;
|
|
66
66
|
connectedUsers: {
|
|
67
67
|
name: string;
|
|
@@ -70,25 +70,25 @@ declare var __VLS_58: {
|
|
|
70
70
|
docId?: string | undefined;
|
|
71
71
|
}[];
|
|
72
72
|
ready: boolean;
|
|
73
|
-
},
|
|
73
|
+
}, __VLS_66: {
|
|
74
74
|
editor: any;
|
|
75
|
-
},
|
|
75
|
+
}, __VLS_74: {
|
|
76
76
|
editor: any;
|
|
77
|
-
},
|
|
77
|
+
}, __VLS_82: {
|
|
78
78
|
editor: any;
|
|
79
|
-
},
|
|
79
|
+
}, __VLS_85: {
|
|
80
80
|
editor: any;
|
|
81
81
|
};
|
|
82
82
|
type __VLS_Slots = {} & {
|
|
83
|
-
default?: (props: typeof
|
|
83
|
+
default?: (props: typeof __VLS_57) => any;
|
|
84
84
|
} & {
|
|
85
|
-
link?: (props: typeof
|
|
85
|
+
link?: (props: typeof __VLS_66) => any;
|
|
86
86
|
} & {
|
|
87
|
-
'doc-link'?: (props: typeof
|
|
87
|
+
'doc-link'?: (props: typeof __VLS_74) => any;
|
|
88
88
|
} & {
|
|
89
|
-
'create-child-doc'?: (props: typeof
|
|
89
|
+
'create-child-doc'?: (props: typeof __VLS_82) => any;
|
|
90
90
|
} & {
|
|
91
|
-
'send-to-chat'?: (props: typeof
|
|
91
|
+
'send-to-chat'?: (props: typeof __VLS_85) => any;
|
|
92
92
|
};
|
|
93
93
|
declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
|
|
94
94
|
editor: import("vue").ComputedRef<any>;
|