fix bug historial

This commit is contained in:
David Ascanio 2026-06-04 00:10:30 -03:00
parent 1cf37c0184
commit 763a77d4f5
3 changed files with 8 additions and 2 deletions

View File

@ -66,6 +66,7 @@ const props = defineProps<{
selectedHit?: TypesenseParagraphHit | null
selectedMatchingHits?: TypesenseParagraphHit[] | null
accentColor?: 'green' | 'blue'
noTrackVisit?: boolean
}>()
const emits = defineEmits(['close'])
@ -103,7 +104,7 @@ watch(
() => [props.collection, props.document?.id] as const,
([collection, id]) => {
if (!collection || !id || !props.document) return
history.visit(collection, toSearchHit(props.document))
if (!props.noTrackVisit) history.visit(collection, toSearchHit(props.document))
},
{ immediate: true }
)

View File

@ -31,6 +31,7 @@ const props = defineProps<{
document: EntrelineaDoc
collection?: string
highlightedText?: string | null
noTrackVisit?: boolean
}>()
const emits = defineEmits<{ close: [] }>()
@ -104,7 +105,7 @@ watch(
() => [props.collection, props.document?.id] as const,
([collection, id]) => {
if (!collection || !id) return
history.visit(collection, toSearchHit(props.document))
if (!props.noTrackVisit) history.visit(collection, toSearchHit(props.document))
},
{ immediate: true }
)

View File

@ -563,6 +563,7 @@ const nearLimit = computed(() => histTotal.value >= Math.floor(HISTORY_LIMIT * 0
v-if="selected && !isMobile && isEntrelinea"
:document="selectedEntrelineaDoc!"
:collection="selectedCollection"
no-track-visit
@close="selected = null"
/>
<!-- Resto (actividades, conferencias) detalle completo con párrafos. -->
@ -573,6 +574,7 @@ const nearLimit = computed(() => histTotal.value >= Math.floor(HISTORY_LIMIT * 0
:paragraphs="detailParagraphs"
:paragraphs-loading="detailParagraphsLoading"
:collection="selectedCollection!"
no-track-visit
@close="selected = null"
/>
<div v-else-if="!selected" class="hidden lg:flex flex-1 items-center justify-center">
@ -591,6 +593,7 @@ const nearLimit = computed(() => histTotal.value >= Math.floor(HISTORY_LIMIT * 0
v-if="selected && isEntrelinea"
:document="selectedEntrelineaDoc!"
:collection="selectedCollection"
no-track-visit
@close="selected = null"
/>
<PublicationDetail
@ -600,6 +603,7 @@ const nearLimit = computed(() => histTotal.value >= Math.floor(HISTORY_LIMIT * 0
:paragraphs="detailParagraphs"
:paragraphs-loading="detailParagraphsLoading"
:collection="selectedCollection!"
no-track-visit
@close="selected = null"
/>
</template>