MediaWiki:Common.js
Note: After saving, 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: Go to Menu → Settings (Opera → Preferences on a Mac) and then to Privacy & security → Clear browsing data → Cached images and files.
/* M'adrono Widget for Talmido - Completely Minimized */
$(document).ready(function() {
var script = document.createElement('script');
script.src = 'https://storage.googleapis.com/creatorsagi-scripts/creatorsagi-widget.min.js';
script.setAttribute('data-domain', 'ai.talmido.org');
script.setAttribute('data-dialog-title', 'Ask Madrono... 🙏');
script.setAttribute('data-mobile-button-text', 'Chat with Madrono');
script.setAttribute('data-dialog-subtitle', 'Your AI assistant for Malankara Orthodox Sunday School teaching');
script.setAttribute('data-primary-color', '#1aafe3');
script.setAttribute('data-placeholder-texts', '["Ask about lesson planning...", "How can I teach children about...", "Need help with Grade..."]');
// Add onload handler to minimize completely
script.onload = function() {
// Wait for widget to initialize
setTimeout(function() {
// Find and click the close button to minimize properly
var closeButton = document.getElementById('dialog-close-btn');
if (closeButton) {
closeButton.click();
} else {
// Fallback method if close button not found
var dialogBox = document.getElementById('dialog-box');
if (dialogBox) {
dialogBox.style.display = 'none';
}
var circleButton = document.querySelector('.desktop-circle-button');
if (circleButton) {
circleButton.style.display = 'flex';
}
}
}, 500); // Wait 500ms for widget to fully load
};
document.body.appendChild(script);
});