@nuxtseo/pro-indexing 0.1.4 → 0.1.5

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.
@@ -3,16 +3,20 @@ import type { GscdumpCanonicalMismatchesResponse, GscdumpIndexingUrlsResponse }
3
3
  import type { UiTableColumn } from '@nuxtseo/design-system/app/shared/table'
4
4
  import type { Component, VNode } from 'vue'
5
5
  import type { IndexingSite } from '../../shared/source'
6
+ import type { IndexingUrlsFacet } from '../../shared/urls-query'
6
7
  import { gscConsoleUrl } from '@gscdump/sdk/gsc-console-url'
7
- import { indexingActionForIssue } from '@gscdump/sdk/indexing'
8
+ import { indexingActionForIssue, parseIndexCohortFilter } from '@gscdump/sdk/indexing'
8
9
  import { issueDetails, severityOrder } from '@gscdump/sdk/indexing-issues'
9
10
  import { DISPLAY_LOCALE, useProHumanFriendlyNumber } from '@nuxtseo/design-system/app/composables/formatting'
11
+ import { fillCopy } from '@nuxtseo/pro-shell/shared/copy'
10
12
  import { navigateTo, useRoute } from 'nuxt/app'
11
13
  import { computed, h, onMounted, ref, watch } from 'vue'
12
14
  import { UiButton, UiChip, UiDataList, UiIcon, UiMetricLabel as UiMetricLabelCell, UiPopover, UiSeverityDot, UiSkeleton, UiSyncDot } from '#components'
13
15
  import { useToast } from '#imports'
14
- import { issueIcons, severityConfig as issueSeverityConfig } from '../../shared/issue-display'
16
+ import { issueIcons } from '../../shared/issue-display'
17
+ import { parseIndexingUrlsQuery } from '../../shared/urls-query'
15
18
  import { useIndexingSource } from '../composables/useIndexingSource'
19
+ import { useProIndexingCopy } from '../composables/useProIndexingCopy'
16
20
  import IndexingCrawlPipeline from './IndexingCrawlPipeline.vue'
17
21
  import IndexingUrlsTableShell from './IndexingUrlsTableShell.vue'
18
22
 
@@ -27,16 +31,9 @@ type ConsolidationTargetRow = GscdumpCanonicalMismatchesResponse['consolidationT
27
31
  interface RichResultDistributionRow { type: string, valid: number, invalid: number }
28
32
  type StatusKey = 'indexed' | 'not_indexed'
29
33
 
30
- const { site, pageSize = 25, initialIssue, initialSearch, initialFacet, initialStatus, initialPage = 1, shell, forceSkeleton = false } = defineProps<{
34
+ const { site, pageSize = 25, shell, forceSkeleton = false } = defineProps<{
31
35
  site: IndexingSite | null | undefined
32
36
  pageSize?: number
33
- initialIssue?: string
34
- initialSearch?: string
35
- /** URLs-table facet (`canonical_mismatch` | `rich_results`), from `?facet=`. */
36
- initialFacet?: string
37
- /** Shareable URL status filter. An issue filter wins when both are supplied. */
38
- initialStatus?: StatusKey
39
- initialPage?: number
40
37
  /** The site's own table shell. It takes the props, events, and slots of `IndexingUrlsTableShell`. */
41
38
  shell?: Component
42
39
  /** Show the loading skeleton, for a site's design review mode. */
@@ -44,12 +41,19 @@ const { site, pageSize = 25, initialIssue, initialSearch, initialFacet, initialS
44
41
  }>()
45
42
 
46
43
  const source = useIndexingSource()
44
+ const copy = useProIndexingCopy().urls
47
45
  const siteRef = () => site ?? null
48
46
  const TableShell = computed(() => shell ?? IndexingUrlsTableShell)
49
47
 
50
48
  const route = useRoute()
51
49
 
52
- type TableQueryKey = 'facet' | 'issue' | 'page' | 'search' | 'status'
50
+ // The route query is the table's filter state: `issue`, `facet`, `status`,
51
+ // `search` and `page`. The table writes it on each change and follows it, so
52
+ // Back and Forward re-filter in place and a filtered view stays a link.
53
+ const tableQuery = computed(() => parseIndexingUrlsQuery(route.query))
54
+ const mountQuery = tableQuery.value
55
+
56
+ type TableQueryKey = 'cohort' | 'facet' | 'issue' | 'page' | 'search' | 'status'
53
57
 
54
58
  function updateRouteQuery(
55
59
  updates: Partial<Record<TableQueryKey, string | undefined>>,
@@ -65,16 +69,15 @@ function updateRouteQuery(
65
69
  void navigateTo({ query }, replace ? { replace: true } : undefined)
66
70
  }
67
71
 
68
- // Active facet (canonical_mismatch | rich_results). The page keys this component
69
- // on `route.query.facet`, so a facet change arrives as a fresh mount.
70
- const facet = ref<string | undefined>(initialFacet)
72
+ // Active facet (canonical_mismatch | rich_results).
73
+ const facet = ref<IndexingUrlsFacet | undefined>(mountQuery.facet)
71
74
  const isRichResultsFacet = computed(() => facet.value === 'rich_results')
72
75
 
73
76
  const facetLabel = computed(() => {
74
77
  if (facet.value === 'canonical_mismatch')
75
- return 'Canonical mismatch'
78
+ return copy.facetCanonicalMismatch
76
79
  if (facet.value === 'rich_results')
77
- return 'Rich results'
80
+ return copy.facetRichResults
78
81
  return facet.value ?? ''
79
82
  })
80
83
 
@@ -86,17 +89,32 @@ function clearFacet() {
86
89
  updateRouteQuery({ facet: undefined, issue: undefined, page: undefined })
87
90
  }
88
91
 
89
- const page = ref(initialPage)
92
+ const page = ref(mountQuery.page)
90
93
 
91
94
  // Internal search
92
- const q = ref(initialSearch || '')
95
+ const q = ref(mountQuery.search ?? '')
96
+
97
+ // An exact Index cohort (`?cohort=`), read only by a source with the
98
+ // `cohortFilter` capability. It narrows the status filter, never replaces it.
99
+ const cohortFilterSupported = source?.cohortFilter === true
100
+ const cohort = ref<string | undefined>(cohortFilterSupported ? mountQuery.cohort : undefined)
101
+ const cohortLabel = computed(() => {
102
+ const parsed = parseIndexCohortFilter(cohort.value)
103
+ return parsed._tag === 'ok' ? parsed.filter.key : ''
104
+ })
105
+
106
+ function clearCohort() {
107
+ cohort.value = undefined
108
+ page.value = 1
109
+ updateRouteQuery({ cohort: undefined, page: undefined })
110
+ }
93
111
 
94
112
  // The API accepts one status. A single-select control keeps the URL and request exact.
95
- const statusFilter = ref<StatusKey | undefined>(initialIssue ? undefined : initialStatus)
113
+ const statusFilter = ref<StatusKey | undefined>(mountQuery.status)
96
114
 
97
115
  const statusFilters = [
98
- { key: 'indexed' as StatusKey, label: 'Indexed', icon: 'success', tooltip: 'Only URLs Google currently reports as indexed.' },
99
- { key: 'not_indexed' as StatusKey, label: 'Not indexed', icon: 'error', tooltip: 'Only URLs Google does not currently report as indexed.' },
116
+ { key: 'indexed' as StatusKey, label: copy.statusIndexed, icon: 'success', tooltip: copy.statusIndexedTooltip },
117
+ { key: 'not_indexed' as StatusKey, label: copy.statusNotIndexed, icon: 'error', tooltip: copy.statusNotIndexedTooltip },
100
118
  ]
101
119
 
102
120
  function toggleStatusFilter(key: string) {
@@ -119,9 +137,7 @@ function toggleStatusFilter(key: string) {
119
137
  // The `canonical_mismatch` facet filters SERVER-side: gscdump's `getIndexingUrls`
120
138
  // accepts `issue=canonical_mismatch` (verified in gscdump's INDEXING_ISSUE_FILTERS),
121
139
  // so we drive the existing `issue` param rather than client-filtering the sample.
122
- const issueFilter = ref<string | undefined>(
123
- initialIssue ?? (initialFacet === 'canonical_mismatch' ? 'canonical_mismatch' : undefined),
124
- )
140
+ const issueFilter = ref<string | undefined>(mountQuery.issue)
125
141
 
126
142
  const diagnosticsRead = source?.diagnostics(siteRef) ?? null
127
143
  const diagnosticsData = computed(() => diagnosticsRead?.data.value ?? null)
@@ -138,7 +154,6 @@ const issuesBySeverity = computed(() => {
138
154
  return severityOrder
139
155
  .map(severity => ({
140
156
  severity,
141
- config: issueSeverityConfig[severity],
142
157
  issues: diagnosticsData.value!.issues.filter(i => i.severity === severity && i.count > 0),
143
158
  }))
144
159
  .filter(g => g.issues.length > 0)
@@ -194,11 +209,13 @@ function handleIssueClick(issueType: string) {
194
209
 
195
210
  function clearTableFilters() {
196
211
  q.value = ''
212
+ cohort.value = undefined
197
213
  statusFilter.value = undefined
198
214
  issueFilter.value = undefined
199
215
  facet.value = undefined
200
216
  page.value = 1
201
217
  updateRouteQuery({
218
+ cohort: undefined,
202
219
  facet: undefined,
203
220
  issue: undefined,
204
221
  search: undefined,
@@ -225,14 +242,13 @@ function updatePage(nextPage: number) {
225
242
  })
226
243
  }
227
244
 
228
- watch(() => initialSearch, (value) => {
229
- q.value = value || ''
230
- })
231
- watch(() => initialStatus, (value) => {
232
- statusFilter.value = initialIssue ? undefined : value
233
- })
234
- watch(() => initialPage, (value) => {
235
- page.value = value
245
+ watch(tableQuery, (next) => {
246
+ q.value = next.search ?? ''
247
+ issueFilter.value = next.issue
248
+ statusFilter.value = next.status
249
+ facet.value = next.facet
250
+ cohort.value = cohortFilterSupported ? next.cohort : undefined
251
+ page.value = next.page
236
252
  })
237
253
 
238
254
  // --- URL table data ---
@@ -243,6 +259,7 @@ const params = computed(() => ({
243
259
  status: statusFilter.value,
244
260
  issue: issueFilter.value || undefined,
245
261
  search: q.value || undefined,
262
+ ...(cohort.value ? { cohort: cohort.value } : {}),
246
263
  }))
247
264
 
248
265
  const urlsRead = source?.urls(siteRef, params) ?? null
@@ -345,7 +362,15 @@ const indexingGscSiteLabel = computed(() => {
345
362
  // --- Manual re-inspection ---
346
363
  const inspectUrls = source?.inspect?.() ?? null
347
364
  const inflightUrls = ref(new Set<string>())
348
- const inspectBudgetRemaining = ref<number | null>(null)
365
+ // The daily URL Inspection checks left, as the last `inspect` call reported them.
366
+ const inspectQuota = ref<{ remaining: number, limit: number } | null>(null)
367
+ const inspectBudgetRemaining = computed(() => inspectQuota.value?.remaining ?? null)
368
+ const recheckTitle = computed(() => {
369
+ const quota = inspectQuota.value
370
+ if (quota?.remaining === 0)
371
+ return copy.recheckLimitTooltip
372
+ return quota ? fillCopy(copy.recheckRemainingTooltip, quota) : copy.recheckTooltip
373
+ })
349
374
  const toast = useToast()
350
375
 
351
376
  async function handleReinspect(url: GscdumpIndexingUrl) {
@@ -355,21 +380,21 @@ async function handleReinspect(url: GscdumpIndexingUrl) {
355
380
  try {
356
381
  const res = await inspectUrls(site, [url.url])
357
382
  if ('error' in res && res.error === 'rate_limited') {
358
- inspectBudgetRemaining.value = 0
383
+ inspectQuota.value = { remaining: 0, limit: res.rateLimit?.limit ?? inspectQuota.value?.limit ?? 0 }
359
384
  toast.add({
360
- title: 'Daily inspection limit reached',
361
- description: `Google\'s URL Inspection budget for this site resets in ~${Math.round(res.retryAfterSeconds / 3600)}h.`,
385
+ title: copy.limitTitle,
386
+ description: fillCopy(copy.limitBody, { hours: Math.round(res.retryAfterSeconds / 3600) }),
362
387
  color: 'warning',
363
388
  icon: 'clock',
364
389
  })
365
390
  return
366
391
  }
367
392
  const ok = res as Exclude<typeof res, { error: 'rate_limited' }>
368
- inspectBudgetRemaining.value = ok.rateLimit.remaining
393
+ inspectQuota.value = { remaining: ok.rateLimit.remaining, limit: ok.rateLimit.limit }
369
394
  if (ok.results.length > 0) {
370
395
  toast.add({
371
- title: 'Re-checked with Google',
372
- description: `${url.url} — ${ok.results[0]!.coverageState ?? ok.results[0]!.verdict ?? 'updated'}`,
396
+ title: copy.recheckedTitle,
397
+ description: fillCopy(copy.recheckedBody, { url: url.url, state: ok.results[0]!.coverageState ?? ok.results[0]!.verdict ?? copy.recheckedUpdated }),
373
398
  color: 'success',
374
399
  icon: 'check',
375
400
  })
@@ -377,7 +402,7 @@ async function handleReinspect(url: GscdumpIndexingUrl) {
377
402
  }
378
403
  else if (ok.errors.length > 0) {
379
404
  toast.add({
380
- title: 'Re-check failed',
405
+ title: copy.recheckFailedTitle,
381
406
  description: ok.errors[0]!.error,
382
407
  color: 'error',
383
408
  icon: 'warning',
@@ -386,8 +411,8 @@ async function handleReinspect(url: GscdumpIndexingUrl) {
386
411
  }
387
412
  catch (e) {
388
413
  toast.add({
389
- title: 'Re-check failed',
390
- description: e instanceof Error ? e.message : 'Unknown error',
414
+ title: copy.recheckFailedTitle,
415
+ description: e instanceof Error ? e.message : copy.unknownError,
391
416
  color: 'error',
392
417
  icon: 'warning',
393
418
  })
@@ -402,22 +427,22 @@ const isLoading = computed(() => hydrated.value && (forceSkeleton || (fetchStatu
402
427
 
403
428
  function formatDate(dateStr: string | null): string {
404
429
  if (!dateStr)
405
- return '—'
430
+ return copy.noValue
406
431
  const date = new Date(dateStr)
407
432
  const now = new Date()
408
433
  const diff = now.getTime() - date.getTime()
409
434
  const days = Math.floor(diff / (24 * 60 * 60 * 1000))
410
435
 
411
436
  if (days === 0)
412
- return 'Today'
437
+ return copy.today
413
438
  if (days === 1)
414
- return 'Yesterday'
439
+ return copy.yesterday
415
440
  return new Intl.DateTimeFormat(DISPLAY_LOCALE, { month: 'short', day: 'numeric' }).format(date)
416
441
  }
417
442
 
418
443
  function formatFullDate(dateStr: string | null): string {
419
444
  if (!dateStr)
420
- return '—'
445
+ return copy.noValue
421
446
  const date = new Date(dateStr)
422
447
  return new Intl.DateTimeFormat(DISPLAY_LOCALE, { month: 'short', day: 'numeric', year: 'numeric', hour: '2-digit', minute: '2-digit' }).format(date)
423
448
  }
@@ -454,73 +479,24 @@ function inSitemap(url: GscdumpIndexingUrl): boolean | null {
454
479
  return null
455
480
  }
456
481
 
457
- const indexingStateLabels: Record<string, string> = {
458
- INDEXING_ALLOWED: 'Allowed',
459
- INDEXING_NOT_ALLOWED: 'Not allowed',
460
- INDEXING_STATE_UNSPECIFIED: 'Unknown',
461
- }
462
-
463
- const robotsTxtStateLabels: Record<string, string> = {
464
- ALLOWED: 'Allowed',
465
- DISALLOWED: 'Blocked',
466
- ROBOTS_TXT_STATE_UNSPECIFIED: 'Unknown',
467
- }
468
-
469
- const pageFetchStateLabels: Record<string, string> = {
470
- SUCCESSFUL: 'Successful',
471
- SOFT_404: 'Soft 404',
472
- SERVER_ERROR: 'Server error',
473
- REDIRECT_ERROR: 'Redirect error',
474
- ACCESS_DENIED: 'Access denied',
475
- BLOCKED_ROBOTS_TXT: 'Blocked by robots',
476
- NOT_FOUND: 'Not found',
477
- PAGE_FETCH_STATE_UNSPECIFIED: 'Unknown',
478
- }
479
-
480
- const crawlerLabels: Record<string, string> = {
481
- DESKTOP: 'Desktop',
482
- MOBILE: 'Mobile',
483
- CRAWLING_USER_AGENT_UNSPECIFIED: 'Unknown',
484
- }
485
-
486
- const verdictLabels: Record<string, string> = {
487
- PASS: 'Indexed',
488
- FAIL: 'Not indexed',
489
- PARTIAL: 'Partial',
490
- NEUTRAL: 'Not indexed',
491
- VERDICT_UNSPECIFIED: 'Unknown',
492
- }
493
-
482
+ const indexingStateLabels: Readonly<Record<string, string>> = copy.indexingStates
483
+ const robotsTxtStateLabels: Readonly<Record<string, string>> = copy.robotsTxtStates
484
+ const pageFetchStateLabels: Readonly<Record<string, string>> = copy.pageFetchStates
485
+ const crawlerLabels: Readonly<Record<string, string>> = copy.crawlers
486
+ const verdictLabels: Readonly<Record<string, string>> = copy.verdicts
494
487
  // Short labels for verbose GSC coverage state strings
495
- const coverageShortLabels: Record<string, string> = {
496
- 'Submitted and indexed': 'Indexed',
497
- 'Indexed, not submitted in sitemap': 'Indexed (no sitemap)',
498
- 'Crawled - currently not indexed': 'Crawled, not indexed',
499
- 'Discovered - currently not indexed': 'Discovered, not indexed',
500
- 'URL is unknown to Google': 'Unknown to Google',
501
- 'Page with redirect': 'Redirect',
502
- 'Blocked by robots.txt': 'Blocked (robots)',
503
- 'Excluded by \'noindex\' tag': 'Noindex',
504
- 'Soft 404': 'Soft 404',
505
- 'Not found (404)': '404',
506
- 'Server error (5xx)': 'Server error',
507
- 'Duplicate without user-selected canonical': 'Duplicate',
508
- 'Duplicate, Google chose different canonical than user': 'Canonical mismatch',
509
- 'Alternate page with proper canonical tag': 'Canonical alternate',
510
- 'Blocked due to unauthorized request (401)': 'Auth required',
511
- 'Blocked due to access forbidden (403)': 'Forbidden',
512
- }
488
+ const coverageShortLabels: Readonly<Record<string, string>> = copy.coverageStates
513
489
 
514
490
  function shortCoverage(raw: string | null | undefined): string {
515
491
  if (!raw)
516
- return '—'
492
+ return copy.noValue
517
493
  return coverageShortLabels[raw] || raw
518
494
  }
519
495
 
520
- function humanize(raw: string | null | undefined, labels: Record<string, string>) {
496
+ function humanize(raw: string | null | undefined, labels: Readonly<Record<string, string>>) {
521
497
  if (!raw)
522
- return '—'
523
- return labels[raw] || raw.replace(/_/g, ' ').replace(/\b\w/g, c => c.toUpperCase()).replace(/\s(Unspecified|State)/gi, '').trim() || '—'
498
+ return copy.noValue
499
+ return labels[raw] || raw.replace(/_/g, ' ').replace(/\b\w/g, c => c.toUpperCase()).replace(/\s(Unspecified|State)/gi, '').trim() || copy.noValue
524
500
  }
525
501
 
526
502
  type SeverityType = 'success' | 'error' | 'warning' | 'neutral'
@@ -543,7 +519,7 @@ const columns = computed<UiTableColumn<GscdumpIndexingUrl>[]>(() => {
543
519
  const cols: UiTableColumn<GscdumpIndexingUrl>[] = [
544
520
  {
545
521
  accessorKey: 'url',
546
- header: () => renderHeader('URL'),
522
+ header: () => renderHeader(copy.columnUrl),
547
523
  rowHeader: true,
548
524
  cell: ({ row }) => {
549
525
  const url = row.original
@@ -553,7 +529,7 @@ const columns = computed<UiTableColumn<GscdumpIndexingUrl>[]>(() => {
553
529
  'href': url.url,
554
530
  'target': '_blank',
555
531
  'rel': 'noopener',
556
- 'aria-label': `Open ${getPath(url.url)} in new tab`,
532
+ 'aria-label': fillCopy(copy.openInNewTab, { path: getPath(url.url) }),
557
533
  'class': 'inline-flex min-h-11 min-w-11 shrink-0 items-center justify-center rounded-md opacity-100 outline-none motion-safe:transition-opacity focus-visible:opacity-100 focus-visible:ring-2 focus-visible:ring-primary sm:min-h-0 sm:min-w-0 sm:opacity-0 sm:group-hover/url:opacity-100',
558
534
  'onClick': (e: Event) => e.stopPropagation(),
559
535
  }, [
@@ -564,11 +540,11 @@ const columns = computed<UiTableColumn<GscdumpIndexingUrl>[]>(() => {
564
540
  },
565
541
  {
566
542
  accessorKey: 'verdict',
567
- header: () => renderHeader('Status'),
543
+ header: () => renderHeader(copy.columnStatus),
568
544
  cell: ({ row }) => {
569
545
  const url = row.original
570
546
  if (url.verdict === 'PASS')
571
- return h('span', { class: 'text-xs text-muted' }, 'Indexed')
547
+ return h('span', { class: 'text-xs text-muted' }, humanize(url.verdict, verdictLabels))
572
548
  return h(UiSeverityDot, {
573
549
  severity: stateSeverity(url.verdict, ['PASS']),
574
550
  label: humanize(url.verdict, verdictLabels),
@@ -579,7 +555,7 @@ const columns = computed<UiTableColumn<GscdumpIndexingUrl>[]>(() => {
579
555
 
580
556
  cols.push({
581
557
  accessorKey: 'coverageState',
582
- header: () => renderHeader('Coverage'),
558
+ header: () => renderHeader(copy.columnCoverage),
583
559
  visibleFrom: 'md',
584
560
  cell: ({ row }) => {
585
561
  const url = row.original
@@ -592,21 +568,21 @@ const columns = computed<UiTableColumn<GscdumpIndexingUrl>[]>(() => {
592
568
 
593
569
  cols.push({
594
570
  id: 'inSitemap',
595
- header: () => renderHeader('In sitemap'),
571
+ header: () => renderHeader(copy.columnInSitemap),
596
572
  visibleFrom: 'md',
597
573
  cell: ({ row }) => {
598
574
  const member = inSitemap(row.original)
599
575
  if (member === null)
600
- return h('span', { class: 'text-xs text-dimmed' }, '—')
576
+ return h('span', { class: 'text-xs text-dimmed' }, copy.noValue)
601
577
  return member
602
- ? h('span', { class: 'text-xs text-muted' }, 'In sitemap')
603
- : h(UiSeverityDot, { severity: 'warning' as const, label: 'Not in sitemap' })
578
+ ? h('span', { class: 'text-xs text-muted' }, copy.inSitemap)
579
+ : h(UiSeverityDot, { severity: 'warning' as const, label: copy.notInSitemap })
604
580
  },
605
581
  })
606
582
 
607
583
  cols.push({
608
584
  accessorKey: 'lastCrawlTime',
609
- header: () => renderHeader('Last crawl'),
585
+ header: () => renderHeader(copy.columnLastCrawl),
610
586
  visibleFrom: 'lg',
611
587
  cell: ({ row }) => {
612
588
  const url = row.original
@@ -615,29 +591,29 @@ const columns = computed<UiTableColumn<GscdumpIndexingUrl>[]>(() => {
615
591
  })
616
592
  cols.push({
617
593
  id: 'flags',
618
- header: () => renderHeader('Flags'),
594
+ header: () => renderHeader(copy.columnFlags),
619
595
  align: 'center' as const,
620
596
  visibleFrom: 'lg',
621
597
  cell: ({ row }) => {
622
598
  const url = row.original
623
599
  const flags: VNode[] = []
624
600
  if (hasCanonicalMismatch(url)) {
625
- flags.push(h('div', { class: 'size-5 rounded bg-accented flex items-center justify-center', title: 'Canonical Mismatch' }, [
601
+ flags.push(h('div', { class: 'size-5 rounded bg-accented flex items-center justify-center', title: copy.flagCanonicalMismatch }, [
626
602
  h(UiIcon, { name: 'compare', class: 'size-3 text-muted' }),
627
603
  ]))
628
604
  }
629
605
  if (url.crawlingUserAgent === 'DESKTOP') {
630
- flags.push(h('div', { class: 'size-5 rounded bg-accented flex items-center justify-center', title: 'Desktop Crawl' }, [
606
+ flags.push(h('div', { class: 'size-5 rounded bg-accented flex items-center justify-center', title: copy.flagDesktopCrawl }, [
631
607
  h(UiIcon, { name: 'monitor', class: 'size-3 text-muted' }),
632
608
  ]))
633
609
  }
634
610
  if (url.pageFetchState === 'SOFT_404') {
635
- flags.push(h('div', { class: 'size-5 rounded bg-accented flex items-center justify-center', title: 'Soft 404' }, [
611
+ flags.push(h('div', { class: 'size-5 rounded bg-accented flex items-center justify-center', title: copy.flagSoft404 }, [
636
612
  h(UiIcon, { name: 'file-x', class: 'size-3 text-muted' }),
637
613
  ]))
638
614
  }
639
615
  if (url.richResultsVerdict === 'PASS') {
640
- flags.push(h('div', { class: 'size-5 rounded bg-accented flex items-center justify-center', title: 'Rich Results' }, [
616
+ flags.push(h('div', { class: 'size-5 rounded bg-accented flex items-center justify-center', title: copy.flagRichResults }, [
641
617
  h(UiIcon, { name: 'ai', class: 'size-3 text-muted' }),
642
618
  ]))
643
619
  }
@@ -668,14 +644,14 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
668
644
  <!-- Facet panel: consolidation targets (canonical_mismatch) -->
669
645
  <UiDataList
670
646
  v-if="facet === 'canonical_mismatch'"
671
- title="Consolidation targets"
647
+ :title="copy.consolidationTitle"
672
648
  icon="compare"
673
- tooltip="Google is folding these pages onto another canonical. Point your canonical at the same URL, or remove the duplication."
649
+ :tooltip="copy.consolidationTooltip"
674
650
  :items="consolidationData?.consolidationTargets ?? []"
675
651
  :loading="consolidationStatus === 'pending'"
676
652
  :bar-value="consolidationTargetCount"
677
653
  empty-icon="compare"
678
- empty-text="No consolidation targets found."
654
+ :empty-text="copy.consolidationEmpty"
679
655
  >
680
656
  <template #default="{ item }">
681
657
  <a
@@ -685,7 +661,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
685
661
  class="font-mono text-sm truncate text-default hover:text-primary motion-safe:transition-colors"
686
662
  :title="item.google_canonical"
687
663
  >{{ getPath(item.google_canonical) }}</a>
688
- <span class="text-sm text-muted shrink-0">{{ item.count }} pages</span>
664
+ <span class="text-sm text-muted shrink-0">{{ fillCopy(copy.consolidationCount, { count: item.count }) }}</span>
689
665
  </template>
690
666
  </UiDataList>
691
667
 
@@ -693,26 +669,26 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
693
669
  <div v-else-if="facet === 'rich_results'" class="space-y-2">
694
670
  <div class="flex items-baseline justify-between gap-3 px-1">
695
671
  <p class="text-mini font-semibold uppercase tracking-[0.08em] text-dimmed">
696
- Rich results · across {{ richResultsScopeCount }} URLs on this page
672
+ {{ fillCopy(copy.richResultsScope, { count: richResultsScopeCount }) }}
697
673
  </p>
698
674
  <p v-if="richResultsInvalidTotal" class="text-xs font-medium text-error shrink-0">
699
- Review {{ richResultsInvalidTotal }} invalid
675
+ {{ fillCopy(copy.richResultsInvalid, { count: richResultsInvalidTotal }) }}
700
676
  </p>
701
677
  <p v-else class="text-xs text-muted shrink-0">
702
- All valid
678
+ {{ copy.richResultsAllValid }}
703
679
  </p>
704
680
  </div>
705
681
  <UiDataList
706
682
  :items="richResultsDistribution"
707
683
  :bar-value="richResultsTotal"
708
684
  empty-icon="ai"
709
- empty-text="No rich results on this page."
685
+ :empty-text="copy.richResultsEmpty"
710
686
  >
711
687
  <template #default="{ item }">
712
688
  <span class="text-sm font-medium text-default truncate">{{ item.type }}</span>
713
689
  <span class="text-sm shrink-0 tabular-nums">
714
- <span class="text-muted">{{ item.valid }} valid</span>
715
- <span v-if="item.invalid" class="text-error ml-2">{{ item.invalid }} invalid</span>
690
+ <span class="text-muted">{{ fillCopy(copy.richResultsValidCount, { count: item.valid }) }}</span>
691
+ <span v-if="item.invalid" class="text-error ml-2">{{ fillCopy(copy.richResultsInvalidCount, { count: item.invalid }) }}</span>
716
692
  </span>
717
693
  </template>
718
694
  </UiDataList>
@@ -721,7 +697,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
721
697
  <!-- No-facet summary line: sitemap membership of the URLs on this page. -->
722
698
  <p v-else-if="notInSitemapCount > 0" class="text-xs text-muted px-1">
723
699
  <span class="font-medium text-default">{{ notInSitemapCount }}</span>
724
- of the {{ displayUrls.length }} URLs on this page {{ notInSitemapCount === 1 ? 'is' : 'are' }} not in your current sitemap.
700
+ {{ fillCopy(notInSitemapCount === 1 ? copy.notInSitemapOne : copy.notInSitemapMany, { total: displayUrls.length }) }}
725
701
  </p>
726
702
 
727
703
  <component
@@ -738,17 +714,17 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
738
714
  :page-size="pageSize"
739
715
  :columns="columns"
740
716
  :has-cached-data="Boolean(data)"
741
- :has-external-filter="Boolean(issueFilter || facet)"
717
+ :has-external-filter="Boolean(issueFilter || facet || cohort)"
742
718
  :show-saved-filters="false"
743
719
  :row-id="indexingUrlId"
744
- :initial-expanded-row-id="initialIssue ? displayUrls[0]?.url : undefined"
720
+ :initial-expanded-row-id="mountQuery.issue ? displayUrls[0]?.url : undefined"
745
721
  table-size="xs"
746
- table-label="Indexing URLs"
747
- search-placeholder="Search URLs…"
722
+ :table-label="copy.tableLabel"
723
+ :search-placeholder="copy.searchPlaceholder"
748
724
  empty-icon="file-search"
749
- empty-title="No URLs found"
750
- empty-default-description="URLs will appear here once Google returns URL Inspection evidence."
751
- item-label="URLs"
725
+ :empty-title="copy.emptyTitle"
726
+ :empty-default-description="copy.emptyBody"
727
+ :item-label="copy.itemLabel"
752
728
  row-clickable
753
729
  @update:q="updateSearch"
754
730
  @update:page="updatePage"
@@ -766,7 +742,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
766
742
  icon="success"
767
743
  role="status"
768
744
  >
769
- No issues
745
+ {{ copy.noIssues }}
770
746
  </UiChip>
771
747
 
772
748
  <UiPopover v-else-if="hasAnyIssues" v-model:open="issuePopoverOpen">
@@ -774,11 +750,11 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
774
750
  purpose="secondary"
775
751
  size="xs"
776
752
  class="min-h-11 sm:min-h-0"
777
- aria-label="Filter by issue type"
753
+ :aria-label="copy.issuesMenuLabel"
778
754
  :aria-expanded="issuePopoverOpen"
779
755
  >
780
756
  <UiIcon name="warning" class="size-3.5" aria-hidden="true" />
781
- <span>Issues</span>
757
+ <span>{{ copy.issuesMenu }}</span>
782
758
  <span v-if="totalErrorCount" class="tabular-nums text-error">{{ useProHumanFriendlyNumber(totalErrorCount) }}</span>
783
759
  <span v-else-if="totalWarningCount" class="tabular-nums text-warning">{{ useProHumanFriendlyNumber(totalWarningCount) }}</span>
784
760
  <UiIcon
@@ -793,7 +769,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
793
769
  <div class="max-h-80 w-72 space-y-1 overflow-y-auto p-1.5">
794
770
  <template v-for="group in issuesBySeverity" :key="group.severity">
795
771
  <div class="px-2 pb-1 pt-2 text-label text-dimmed">
796
- <UiSeverityDot :severity="group.severity === 'error' ? 'error' : group.severity === 'warning' ? 'warning' : 'info'" :label="group.config.label" />
772
+ <UiSeverityDot :severity="group.severity === 'error' ? 'error' : group.severity === 'warning' ? 'warning' : 'info'" :label="group.severity === 'error' ? copy.severityError : group.severity === 'warning' ? copy.severityWarning : copy.severityInfo" />
797
773
  </div>
798
774
  <UiButton
799
775
  v-for="issue in group.issues"
@@ -819,7 +795,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
819
795
  purpose="secondary"
820
796
  size="xs"
821
797
  class="min-h-11 sm:min-h-0"
822
- :aria-label="`Clear ${activeIssueData.label} filter`"
798
+ :aria-label="fillCopy(copy.clearFilter, { label: activeIssueData.label })"
823
799
  @click="handleIssueClick(activeIssueData.type)"
824
800
  >
825
801
  <UiIcon :name="issueIcons[activeIssueData.type] || 'caution'" class="size-3 text-muted" aria-hidden="true" />
@@ -833,7 +809,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
833
809
  purpose="secondary"
834
810
  size="xs"
835
811
  class="min-h-11 sm:min-h-0"
836
- :aria-label="`Clear ${facetLabel} filter`"
812
+ :aria-label="fillCopy(copy.clearFilter, { label: facetLabel })"
837
813
  @click="clearFacet"
838
814
  >
839
815
  <UiIcon :name="facet === 'canonical_mismatch' ? 'compare' : 'ai'" class="size-3 text-muted" aria-hidden="true" />
@@ -841,7 +817,19 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
841
817
  <UiIcon name="close" class="size-3 text-dimmed" aria-hidden="true" />
842
818
  </UiButton>
843
819
 
844
- <UiSyncDot v-if="fetchStatus === 'pending' && data" status="syncing" label="Refreshing" />
820
+ <UiButton
821
+ v-if="cohort"
822
+ purpose="secondary"
823
+ size="xs"
824
+ class="min-h-11 sm:min-h-0"
825
+ :aria-label="fillCopy(copy.clearFilter, { label: cohortLabel })"
826
+ @click="clearCohort"
827
+ >
828
+ {{ fillCopy(copy.cohortChip, { label: cohortLabel }) }}
829
+ <UiIcon name="close" class="size-3 text-dimmed" aria-hidden="true" />
830
+ </UiButton>
831
+
832
+ <UiSyncDot v-if="fetchStatus === 'pending' && data" status="syncing" :label="copy.refreshing" />
845
833
  </template>
846
834
 
847
835
  <template #notices>
@@ -870,7 +858,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
870
858
  {{ activeIssueData.label }}
871
859
  </h4>
872
860
  <p class="mt-0.5 text-sm text-muted">
873
- {{ useProHumanFriendlyNumber(activeIssueData.count) }} URLs affected
861
+ {{ fillCopy(copy.affected, { count: useProHumanFriendlyNumber(activeIssueData.count) }) }}
874
862
  </p>
875
863
  <p class="mt-1.5 text-sm leading-relaxed text-muted">
876
864
  {{ activeIssueData.description }}
@@ -892,7 +880,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
892
880
  <section
893
881
  v-if="activeRemediation"
894
882
  class="mb-3 border-b border-default pb-3"
895
- aria-label="Recommended remediation"
883
+ :aria-label="copy.remediationLabel"
896
884
  >
897
885
  <p class="text-label">
898
886
  {{ activeRemediation.title }}
@@ -901,7 +889,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
901
889
  {{ activeRemediation.detail }}
902
890
  </p>
903
891
  <p class="mt-2 text-sm text-muted">
904
- <span class="font-medium text-default">Why:</span>
892
+ <span class="font-medium text-default">{{ copy.why }}</span>
905
893
  {{ activeRemediation.why }}
906
894
  </p>
907
895
  <UiButton
@@ -920,10 +908,10 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
920
908
  class="mb-3"
921
909
  variant="inline"
922
910
  :steps="[
923
- { label: 'Robots.txt', status: stateSeverity(url.robotsTxtState, ['ALLOWED']), value: humanize(url.robotsTxtState, robotsTxtStateLabels) },
924
- { label: 'Fetch', status: stateSeverity(url.pageFetchState, ['SUCCESSFUL']), value: humanize(url.pageFetchState, pageFetchStateLabels) },
925
- { label: 'Indexing', status: stateSeverity(url.indexingState, ['INDEXING_ALLOWED']), value: humanize(url.indexingState, indexingStateLabels) },
926
- { label: 'Verdict', status: stateSeverity(url.verdict, ['PASS']), value: humanize(url.verdict, verdictLabels) },
911
+ { label: copy.stageRobots, status: stateSeverity(url.robotsTxtState, ['ALLOWED']), value: humanize(url.robotsTxtState, robotsTxtStateLabels) },
912
+ { label: copy.stageFetch, status: stateSeverity(url.pageFetchState, ['SUCCESSFUL']), value: humanize(url.pageFetchState, pageFetchStateLabels) },
913
+ { label: copy.stageIndexing, status: stateSeverity(url.indexingState, ['INDEXING_ALLOWED']), value: humanize(url.indexingState, indexingStateLabels) },
914
+ { label: copy.stageVerdict, status: stateSeverity(url.verdict, ['PASS']), value: humanize(url.verdict, verdictLabels) },
927
915
  ]"
928
916
  />
929
917
 
@@ -941,25 +929,25 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
941
929
  <div class="idx-detail-grid">
942
930
  <!-- Crawler -->
943
931
  <div class="idx-detail">
944
- <span class="idx-detail-label">Crawler</span>
932
+ <span class="idx-detail-label">{{ copy.detailCrawler }}</span>
945
933
  <span class="text-xs text-muted">{{ humanize(url.crawlingUserAgent ?? '', crawlerLabels) }}</span>
946
934
  </div>
947
935
 
948
936
  <!-- Last crawl -->
949
937
  <div class="idx-detail">
950
- <span class="idx-detail-label">Last Crawl</span>
938
+ <span class="idx-detail-label">{{ copy.detailLastCrawl }}</span>
951
939
  <span class="text-xs font-medium text-default">{{ formatFullDate(url.lastCrawlTime) }}</span>
952
940
  </div>
953
941
 
954
942
  <!-- Checks -->
955
943
  <div class="idx-detail">
956
- <span class="idx-detail-label">Checks</span>
944
+ <span class="idx-detail-label">{{ copy.detailChecks }}</span>
957
945
  <span class="text-xs text-muted">{{ url.checkCount }}</span>
958
946
  </div>
959
947
 
960
948
  <!-- Rich Results -->
961
949
  <div v-if="url.richResultsVerdict && !url.richResultsVerdict.includes('UNSPECIFIED')" class="idx-detail">
962
- <span class="idx-detail-label">Rich Results</span>
950
+ <span class="idx-detail-label">{{ copy.detailRichResults }}</span>
963
951
  <div class="flex flex-wrap items-center gap-1.5">
964
952
  <UiSeverityDot :severity="stateSeverity(url.richResultsVerdict, ['PASS'])" :label="humanize(url.richResultsVerdict, verdictLabels)" />
965
953
  <span
@@ -976,16 +964,16 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
976
964
  <!-- Canonicals -->
977
965
  <div v-if="url.userCanonical || url.googleCanonical" class="idx-canonicals">
978
966
  <div class="idx-detail">
979
- <span class="idx-detail-label">Canonical</span>
967
+ <span class="idx-detail-label">{{ copy.detailCanonical }}</span>
980
968
  <span class="text-xs text-muted font-mono truncate" :title="url.userCanonical || undefined">
981
- {{ url.userCanonical ? getPath(url.userCanonical) : '—' }}
969
+ {{ url.userCanonical ? getPath(url.userCanonical) : copy.noValue }}
982
970
  </span>
983
971
  </div>
984
972
  <div v-if="hasCanonicalMismatch(url)" class="idx-detail">
985
- <span class="idx-detail-label">Google sees</span>
973
+ <span class="idx-detail-label">{{ copy.detailGoogleCanonical }}</span>
986
974
  <span class="text-xs font-mono truncate text-warning" :title="url.googleCanonical || undefined">
987
- {{ url.googleCanonical ? canonicalDisplayLabel(url.googleCanonical, url.canonicalMismatchKind) : '—' }}
988
- <span class="idx-chip text-warning ml-1">mismatch</span>
975
+ {{ url.googleCanonical ? canonicalDisplayLabel(url.googleCanonical, url.canonicalMismatchKind) : copy.noValue }}
976
+ <span class="idx-chip text-warning ml-1">{{ copy.detailMismatch }}</span>
989
977
  </span>
990
978
  </div>
991
979
  </div>
@@ -999,7 +987,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
999
987
  class="min-h-11 sm:min-h-0"
1000
988
  purpose="secondary"
1001
989
  icon="external"
1002
- label="Open URL"
990
+ :label="copy.openUrl"
1003
991
  />
1004
992
  <UiButton
1005
993
  :href="gscConsoleUrl({ siteLabel: indexingGscSiteLabel, resource: 'url-inspection', page: url.url })"
@@ -1008,7 +996,7 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
1008
996
  class="min-h-11 sm:min-h-0"
1009
997
  purpose="secondary"
1010
998
  icon="search"
1011
- label="Inspect in GSC"
999
+ :label="copy.inspectInGsc"
1012
1000
  />
1013
1001
  <UiButton
1014
1002
  v-if="inspectUrls"
@@ -1016,9 +1004,9 @@ function indexingUrlId(row: GscdumpIndexingUrl): string {
1016
1004
  class="min-h-11 sm:min-h-0"
1017
1005
  purpose="secondary"
1018
1006
  :icon="inflightUrls.has(url.url) ? 'loading' : 'refresh'"
1019
- :label="inflightUrls.has(url.url) ? 'Re-checking…' : 'Re-check with Google'"
1007
+ :label="inflightUrls.has(url.url) ? copy.rechecking : copy.recheck"
1020
1008
  :disabled="inflightUrls.has(url.url) || inspectBudgetRemaining === 0"
1021
- v-bind="{ title: inspectBudgetRemaining === 0 ? 'Daily inspection limit reached for this site' : 'Hit Google URL Inspection now (uses 1 of your daily 1800 site budget)' }"
1009
+ v-bind="{ title: recheckTitle }"
1022
1010
  @click="handleReinspect(url)"
1023
1011
  />
1024
1012
  </div>