How can I get posts to plugin?

How can I get posts to plugin?

I want to sort posts like ‘flaged posts(saved posts)’ in my plugin.

I think “search_results.tsx” in the source code corresponds to the contents of the right sidebar,

is there a way to import or copy that component into my plugin the same?