Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -195,23 +195,6 @@ export const postsContentSelector = () =>
// reply-tweets
'[data-testid="tweet"] + div div div[lang][dir]',
].join(),
).concat(
querySelectorAll('[data-testid="tweet"] > div:last-child').map((x) => {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this looks like a feature. do you sure you're going to remove the whole section?

const textElement = x.querySelector('[role="group"]')?.parentElement?.querySelector('div[lang]') as
| HTMLDivElement
| undefined

if (textElement) return textElement

// There's no textElement as there's only a twitter summary card parsed by a single url.
const summaryCardElement = x
.querySelector('[role="group"]')
?.parentElement?.querySelector('[data-testid="card.wrapper"]')?.previousElementSibling as
| HTMLDivElement
| undefined

return summaryCardElement
}), // timeline page for new twitter
)

export const postAvatarsContentSelector = () =>
Expand Down