diff --git a/app/Http/Resources/DocumentResource.php b/app/Http/Resources/DocumentResource.php index 8bba97b9..bf277042 100644 --- a/app/Http/Resources/DocumentResource.php +++ b/app/Http/Resources/DocumentResource.php @@ -26,6 +26,7 @@ public function toArray(Request $request): array 'link' => $this->link, 'summary' => $this->summary, 'summary_markdown' => $summary, + 'original_content' => str($this->original_content)->markdown(), 'type' => str($this->type->name)->title()->toString(), 'status' => str($this->status->name)->headline()->toString(), 'document_chunks_count' => $this->document_chunks()->where('section_number', 0)->count(), diff --git a/resources/js/Pages/Collection/Components/ShowDocument.vue b/resources/js/Pages/Collection/Components/ShowDocument.vue index 5ffb9d8e..a324fd74 100644 --- a/resources/js/Pages/Collection/Components/ShowDocument.vue +++ b/resources/js/Pages/Collection/Components/ShowDocument.vue @@ -38,24 +38,40 @@ type="button" class="btn btn-ghost rounded-none" @click="toggleEdit"> edit -

Summary:

-
-
-
-
-
-
+ +
+

Summary:

+
+
+
+
+
+
+
+
+
+
+
-
-
- +
+
+
@@ -86,6 +102,12 @@ const props = defineProps({ open: Boolean, }); +const activeTab = ref('summary'); + +const toggleTab = (tab) => { + activeTab.value = tab; +} + const documentToShow = ref(props.document); onMounted(() => {