setTimeout(() => {
  const a = document.querySelector("#google_translate_element select");

  a[0].innerHTML =
    '<img src="http://placehold.it/350x350" width="400px" height="150px"> English';
  a[1].innerHTML = "<img src='../src/assets/images/DINsocket.png' /> German";
  console.log("a", a[1].innerHTML);
  console.log("a", a[0].innerHTML);
}, 2000);

function googleTranslateElementInit() {
  new google.translate.TranslateElement(
    {
      autoDisplay: true,
      includedLanguages: "de,en",
    },
    "google_translate_element"
  );

  setTimeout(() => {
    changeLangToDE();
  }, 1000);
}

function changeLangToDE() {
  let ele = document.querySelector("#google_translate_element select");
  ele.selectedIndex = 2;
  ele.dispatchEvent(new Event("change"));
}
