您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
MalayalaKit: JavaScript library for creating customizable web menus with tabs, buttons, switches, and input elements.
当前为
此脚本不应直接安装。它是供其他脚本使用的外部库,要使用该库请加入元指令 // @require https://update.greasyfork.icu/scripts/482771/1314237/Malayala%20Kit.js
MalayalaKit is a lightweight JavaScript library designed to facilitate the creation of customizable and interactive menus for web applications. It offers a simple and intuitive API for constructing menus with tabs, buttons, switches, and input elements. The library provides a set of predefined styles for a sleek and modern appearance.
Key Features:
The library's design allows developers to quickly integrate and configure menus within their web projects. It includes built-in styling for a visually appealing experience, but developers can also customize the appearance to suit their application's design.
To use MalayalaKit, developers can instantiate a menu, add tabs with associated content, and include buttons, switches, and input elements within each tab. The library simplifies the process of creating dynamic and responsive menus for web applications.
var toastManager = new MalayalaKit.ToastManager();
var kit = new MalayalaKit.CreateMenu({
title: "MalayalaKit",
icon: "",
size: { width: 500, height: 400 },
position: { top: 50, left: 50 },
hotkey: { keyCode: 77, ctrlKey: true, altKey: false, shiftKey: false }
});
var general = new MalayalaKit.Tab("General");
general.addButton({ label: "Show All Toasts", buttonLabel: "Show Toasts", onclick: function () {
toastManager.showToast({ message: 'Toast Message!', duration: 5000});
toastManager.showToast({ message: 'Toast Message!' });
toastManager.showToast({ message: 'Toast Message!', type: 'info' });
toastManager.showToast({ message: 'Toast Message!', type: 'warning' });
toastManager.showToast({ message: 'Toast Message!', type: 'error' });
}
});
general.addButton({ label: "Button Label", style: "border", buttonLabel: "Buton Text", onclick: function () {
toastManager.showToast({ message: 'Clicked', type: 'info' });
}
});
general.addSwitch({ label: "Switch Label", value: true, onchange: function (value) {
toastManager.showToast({ message: 'Switch value: ' + value, type: 'info' });
}
});
general.addInput({ label: "Number Input", placeholder: "Enter a Number", type: "number", value: 0, onchange: function (value) {
toastManager.showToast({ message: 'Number input value: ' + value, type: 'info' });
}
});
general.addHotkey({
label: "Hotkey",
value: { keyCode: 77, ctrlKey: true, altKey: false, shiftKey: false },
onlistener: function (event) {
toastManager.showToast({ message: 'Hotkey value: ' + event, type: 'info' });
}
});
kit.addTab(general);
var tab2 = new MalayalaKit.Tab("Tab 2");
tab2.addButton({ buttonLabel: "Hide", onclick: function () {
kit.toggleMenu();
}
});
tab2.addSlider({ label: 'Slider Label', min: 0, max: 100, value: 50, oninput: function (value) {
toastManager.showToast({ message: 'Slider Value: ' + value, type: 'info' });
}
});
tab2.addColorPicker({ label: 'Color Picker Label', value: '#ff0000', oninput: function (color) {
toastManager.showToast({ message: 'Selected Color: ' + color, type: 'info' });
}
});
kit.addTab(tab2);
MalayalaKit.setLanguage('ml'); // Supported languages: en, tr, ml, ta, hi, ko, ja, it, ar, fr
kit.render();