import { initPendingReviewDms } from "@wp/js/pending-review-dms";

export async function reviewDMsPage() {

  const status_selector = document.getElementById("status");
  status_selector.addEventListener("change", async function (e) {
    e.preventDefault();
    const currentUrl = new URL(window.location.href);
    const urlParams = currentUrl.searchParams;
    urlParams.set('status', status_selector.value);
    window.location.href = currentUrl.toString();
  });
  await initPendingReviewDms(true);
}
