User:Jono Bean/common.js

From DQWiki
Jump to navigationJump to search

Note: After publishing, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Press Ctrl-F5.
/* Lorekeeper Widget Loader (Local Test) */
(function() {
    if (document.getElementById('lorekeeper-widget-container')) return;

    var container = document.createElement('div');
    container.id = 'lorekeeper-widget-container';
    container.style.cssText = 'position: fixed; bottom: 25px; right: 25px; z-index: 100000;';

    // Using your local dev server IP
    container.innerHTML = 
        '<iframe src="http://192.168.4.252:3000/lore?widget=true" ' +
        'style="width: 450px; height: 650px; border: 1px solid rgba(139, 92, 246, 0.4); ' +
        'border-radius: 32px; box-shadow: 0 25px 70px rgba(0,0,0,0.7); ' +
        'background: #09090b; display: block;" ' +
        'frameborder="0" allow="microphone; autoplay"></iframe>';

    document.body.appendChild(container);
})();