MCPcopy Create free account
hub / github.com/QLHazyCoder/FlowPilot / getRowPreviewText

Function getRowPreviewText

content/gmail-mail.js:366–400  ·  view source on GitHub ↗
(row)

Source from the content-addressed store, hash-verified

364}
365
366function getRowPreviewText(row) {
367 const sender = normalizeText(
368 row.querySelector('.zF, .yP, span[email], [email]')?.textContent
369 || row.querySelector('[email]')?.getAttribute?.('email')
370 || ''
371 );
372
373 const subject = normalizeText(
374 row.querySelector('.bog [data-thread-id], .bog [data-legacy-thread-id], .bog, .y6, .bqe')?.textContent
375 || ''
376 );
377
378 const digest = normalizeText(
379 row.querySelector('.y2, .afn, .a4W, .bog + .y2')?.textContent
380 || ''
381 );
382
383 const timeText = normalizeText(
384 row.querySelector('td.xW span')?.getAttribute?.('title')
385 || row.querySelector('td.xW span, td.xW time')?.getAttribute?.('title')
386 || row.querySelector('td.xW span, td.xW time')?.textContent
387 || ''
388 );
389
390 const fullText = normalizeText(row.textContent || row.innerText || '');
391
392 return {
393 sender,
394 subject,
395 digest,
396 timeText,
397 fullText,
398 combinedText: normalizeText([sender, subject, digest, timeText, fullText].filter(Boolean).join(' ')),
399 };
400}
401
402function getRowTimestamp(row) {
403 const timeCell = row.querySelector('td.xW span, td.xW time, td.xW [title]');

Callers 2

getRowFingerprintFunction · 0.85
handlePollEmailFunction · 0.85

Calls 1

normalizeTextFunction · 0.70

Tested by

no test coverage detected