Internet Roadtrip Permanent Radio - The Wave

Overrides Internet Roadtrip radio with The Wave 100.9 FM.

// ==UserScript==
// @name         Internet Roadtrip Permanent Radio - The Wave
// @description  Overrides Internet Roadtrip radio with The Wave 100.9 FM.
// @namespace    http://tampermonkey.net/
// @match        https://neal.fun/internet-roadtrip/
// @version      1.0
// @author       TotallyNotSamm
// @license      MIT
// @run-at       document-end
// @require      https://cdn.jsdelivr.net/npm/[email protected]
// @icon         https://cdn-profiles.tunein.com/s343210/images/logog.jpg?t=1
// ==/UserScript==

(async function () {
  if (!IRF.isInternetRoadtrip) return;

  const container = await IRF.vdom.container;
  const originalUpdateData = container.methods.updateData;

  container.state.updateData = new Proxy(originalUpdateData, {
    apply: (target, thisArg, args) => {
      args[0].station = {
        name: "The Wave 100.9 FM",
        url: "https://mbsradio-ais.leanstream.co/CKTOFM-MP3",
        distance: 0,
      };

       IRF.vdom.radio.then(radio => {
        if (radio.state.isPoweredOn) {
          radio.state.stationInfo = "PLAYING";
        } else {
          radio.state.stationInfo = "TUNE IN";
        }
      });
      return Reflect.apply(target, thisArg, args);
    }
  });

})();