MediaWiki:Gadget-calc-cooking.js

From Idle Clans wiki
Revision as of 19:20, 10 June 2024 by Uraxys (talk | contribs) (Created page with "$(function () { var CLAN_HOUSES = ["Tent", "Barn", "Windmill", "House", "Manor", "Castle"]; var PERSONAL_HOUSES = ["Cardboard box", "Tent", "Van Down by the River", "Small cabin", "House"]; var SKILL_CAPE = ["None", "Tier 1", "Tier 2", "Tier 3", "Tier 4"]; var ENCHANTMENTS = ["None", "Common", "Rare", "Exceptional"]; var utils = idleClans.util; var data = idleClans.data; function addDropdown($element, $dropdown, title, alignment) { alignment = alignment || "le...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

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.
$(function () {
	var CLAN_HOUSES = ["Tent", "Barn", "Windmill", "House", "Manor", "Castle"];
	var PERSONAL_HOUSES = ["Cardboard box", "Tent", "Van Down by the River", "Small cabin", "House"];
	var SKILL_CAPE = ["None", "Tier 1", "Tier 2", "Tier 3", "Tier 4"];
	var ENCHANTMENTS = ["None", "Common", "Rare", "Exceptional"];

	var utils = idleClans.util;
	var data = idleClans.data;

	function addDropdown($element, $dropdown, title, alignment) {
		alignment = alignment || "left";

		$element.append("<div class='calc-label-" + alignment + "'>" + title + "</div>");
		$element.append($dropdown.$element);
	}

	function addHeader($element, title) {
		$element.append("<div class='calc-header'>" + title + "</div>");
	}