Jump to content

User:Editingthingsforlife/vector-2022.js: Difference between revisions

From Madness Descent (Roblox) Wiki
Editingthingsforlife (talk | contribs)
Created page with "public class WikiTheme { // Define theme properties for an eerie, uncanny aesthetic private static final String PRIMARY_COLOR = "#1E2528"; // Dark, muted teal-gray private static final String SECONDARY_COLOR = "#D8E0E3"; // Off-white, slightly unsettling private static final String ACCENT_COLOR = "#4A5B66"; // Cold, muted blue private static final String FONT_FAMILY = "'Roboto', sans-serif"; // Clean but slightly sterile private static final doubl..."
 
Editingthingsforlife (talk | contribs)
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
public class WikiTheme {
$(document).ready(function () {
    // Define theme properties for an eerie, uncanny aesthetic
  // === Add Madness Theme Class ===
    private static final String PRIMARY_COLOR = "#1E2528"; // Dark, muted teal-gray
  document.body.classList.add('madness-theme');
    private static final String SECONDARY_COLOR = "#D8E0E3"; // Off-white, slightly unsettling
    private static final String ACCENT_COLOR = "#4A5B66"; // Cold, muted blue
    private static final String FONT_FAMILY = "'Roboto', sans-serif"; // Clean but slightly sterile
    private static final double OPACITY = 0.95; // Slight transparency for unease
    private static final String BACKGROUND_GRADIENT = "linear-gradient(135deg, #1E2528, #2A3439)";


    // Method to apply theme to Vector-2022 skin
  // === Tools Panel Toggle ===
    public void applyEerieTheme() {
  const toolsPanel = document.querySelector('#vector-page-tools');
        // Set global styles
  if (toolsPanel) {
        setBackground(BACKGROUND_GRADIENT);
    toolsPanel.classList.add('collapsed');
        setFont(FONT_FAMILY, "1.1em", "300");
        setOpacity(OPACITY);


        // Style header (masthead)
    const toggleBtn = document.createElement('div');
        styleHeader(PRIMARY_COLOR, SECONDARY_COLOR, "box-shadow: 0 2px 5px rgba(0,0,0,0.5)");
    toggleBtn.id = 'page-tools-toggle';
    toggleBtn.innerText = '☰ Tools';
    document.body.appendChild(toggleBtn);


        // Style content area
    toggleBtn.addEventListener('click', () => {
        styleContent(SECONDARY_COLOR, ACCENT_COLOR, "border: 1px solid #4A5B66; border-radius: 5px");
      toolsPanel.classList.toggle('collapsed');
    });
  }


        // Style links to feel slightly off
  // === Apply Theme to Special Pages ===
        styleLinks(ACCENT_COLOR, "text-decoration: none; transition: color 0.3s ease-in-out");
  $('.mw-editform, .mw-changeslist, .mw-page-info, .oo-ui-fieldLayout, .mw-specialpages-body').css({
    'background-color': '#1f1410',
    'border': '2px solid #ff2c2c',
    'padding': '20px',
    'border-radius': '8px',
    'box-shadow': '0 0 10px #ff0000'
  });


        // Add subtle animations for unease
  $('textarea, input, select').css({
        addHoverEffects("transform: scale(1.02); filter: brightness(0.9)");
    'background-color': '#2b1b15',
    }
    'color': '#fff',
 
     'border': '1px solid #ff3b3b'
    // Method to simulate CSS injection into MediaWiki
  });
    public void injectCSS(String cssRules) {
});
        // Pseudo-method to write to MediaWiki:Common.css
        System.out.println("Injecting CSS: " + cssRules);
     }
 
    public static void main(String[] args) {
        WikiTheme theme = new WikiTheme();
        theme.applyEerieTheme();
    }
}

Latest revision as of 13:50, 14 May 2025

$(document).ready(function () {
  // === Add Madness Theme Class ===
  document.body.classList.add('madness-theme');

  // === Tools Panel Toggle ===
  const toolsPanel = document.querySelector('#vector-page-tools');
  if (toolsPanel) {
    toolsPanel.classList.add('collapsed');

    const toggleBtn = document.createElement('div');
    toggleBtn.id = 'page-tools-toggle';
    toggleBtn.innerText = '☰ Tools';
    document.body.appendChild(toggleBtn);

    toggleBtn.addEventListener('click', () => {
      toolsPanel.classList.toggle('collapsed');
    });
  }

  // === Apply Theme to Special Pages ===
  $('.mw-editform, .mw-changeslist, .mw-page-info, .oo-ui-fieldLayout, .mw-specialpages-body').css({
    'background-color': '#1f1410',
    'border': '2px solid #ff2c2c',
    'padding': '20px',
    'border-radius': '8px',
    'box-shadow': '0 0 10px #ff0000'
  });

  $('textarea, input, select').css({
    'background-color': '#2b1b15',
    'color': '#fff',
    'border': '1px solid #ff3b3b'
  });
});
Cookies help us deliver our services. By using our services, you agree to our use of cookies.