Confirmation Alerts

Confirmation alert template

安裝腳本?
作者推薦腳本

您可能也會喜歡 Alert Messages

安裝腳本

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         Confirmation Alerts
// @namespace    http://tampermonkey.net/
// @homepage     https://greasyfork.org/users/946530-purefishmonke
// @version      1.2
// @description  Confirmation alert template
// @supportURL   https://discord.com/invite/XZ8JqgYg93
// @author       DevFish
// @match        https://*/*
// @license      MIT
// ==/UserScript==

///Config///
var keybind = 192 // 192 = BACKTICK (`), find more at https://keycode.info
var conftxt = "Click A Button" // Switch the text inside the "" to whatever you want
var confrmtxt = "Confirmed" // Switch the text inside the "" to whatever you want
var canceltxt = "Cancelled" // Switch the text inside the "" to whatever you want

/// Main Script (Do not edit) ///
window.onkeydown=function(event){if(event.keyCode===keybind){if(confirm(conftxt)==true){alert(confrmtxt)}else{alert(canceltxt)}}}