feat: display total FAQ count in Related FAQs dialog (#13433)
## Description Display the total count of generated FAQs in the Related FAQs dialog title to give users immediate visibility into how many FAQs were generated from a document. ## Type of change Please delete options that are not relevant. - [ ] New feature (non-breaking change which adds functionality) ## Snapshots? <img width="717" height="268" alt="Screenshot 2026-02-04 at 1 47 36 AM" src="https://github.com/user-attachments/assets/c3e927ce-6d09-499d-8d02-8a44e0c353e2" /> ## Checklist: - [ ] My code follows the style guidelines of this project - [ ] I have performed a self-review of my code - [ ] I have commented on my code, particularly in hard-to-understand areas - [ ] I have made corresponding changes to the documentation - [ ] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] New and existing unit tests pass locally with my changes - [ ] Any dependent changes have been merged and published in downstream modules <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Low Risk** > Small UI-only change using existing store metadata; risk is limited to incorrect/blank counts if `meta.totalCount` is missing or stale. > > **Overview** > Updates the `RelatedResponses` dialog to display the total related response count in the title by reading `captainResponses/getMeta.totalCount` (defaulting to 0) and appending it as `(<count>)`. > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit 7cd67c9991faceeff33d33c319e324b1c6cf73f4. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY -->
This commit is contained in:
committed by
GitHub
parent
9eb3ee44a8
commit
7ade9061a8
@@ -18,7 +18,9 @@ const dialogRef = ref(null);
|
||||
|
||||
const uiFlags = useMapGetter('captainResponses/getUIFlags');
|
||||
const responses = useMapGetter('captainResponses/getRecords');
|
||||
const meta = useMapGetter('captainResponses/getMeta');
|
||||
const isFetching = computed(() => uiFlags.value.fetchingList);
|
||||
const totalCount = computed(() => meta.value.totalCount || 0);
|
||||
|
||||
const handleClose = () => {
|
||||
emit('close');
|
||||
@@ -37,7 +39,7 @@ defineExpose({ dialogRef });
|
||||
<Dialog
|
||||
ref="dialogRef"
|
||||
type="edit"
|
||||
:title="t('CAPTAIN.DOCUMENTS.RELATED_RESPONSES.TITLE')"
|
||||
:title="`${t('CAPTAIN.DOCUMENTS.RELATED_RESPONSES.TITLE')} (${totalCount})`"
|
||||
:description="t('CAPTAIN.DOCUMENTS.RELATED_RESPONSES.DESCRIPTION')"
|
||||
:show-cancel-button="false"
|
||||
:show-confirm-button="false"
|
||||
|
||||
Reference in New Issue
Block a user