jQuery Undo

码农软件 · 软件分类 · 其他jQuery插件 · 2020-01-15 15:28:18

软件介绍

This plugin provides a global undo utility.

You can add undo items to the stack with:

   $.undo(callback, target, message)

Where the callback function knows how to perform the actual undo-ing when executed.  This will automatically display the message (or a default one created if that parameter is absent) and an "Undo" link within items matching the '.undo' selector (which is customizable by setting $.undo.notice.selector. If no action is taken within 60 seconds, this message is hidden. If the "Undo" link is clicked or you manually call:

   $.undo()

then the plugin will execute the callback function (passing in the target as the parameter, if a target was provided).

If you simply create an empty <div class="undo"></div> in your page and start adding undo functions to $.undo(undoAction), things should "just work" as described above.  If you want more explicit control of the displayed messages, there are a variety of settings and functions you can alter in $.undo.notice that can help you customize the behavior or plug
the functionality into your own custom markup.

To enable the use of Ctrl-z to trigger undo execution, you can call:

$.undo.supportsCtrlz(true)


By default this is disabled.

The recommended CSS for the classes involved is:

.undo {
    background: #FFF1A8;
    color: black;
    display: none;
    font-size: 85%;
    font-weight: bold;
    margin:3px 0px;;
    padding: 5px 15px;
    text-align: center;
}
.undo-message {
    text-align: center;
}
a.undo-execute {
    color: blue;
    padding: 0px 2px 0px 10px;
}
a.undo-cancel {
    font-size: 80%;
    text-decoration: none;
    vertical-align: center;
}



本文地址:https://codercto.com/soft/d/23442.html

Essential C++中文版

Essential C++中文版

[美] Stanley B. Lippman / 侯捷 / 华中科技大学出版社 / 2001-8 / 39.80元

书中以4个面向来表现C++的本质:procedural(程序性的)、generic(泛型的)、object-based(个别对象的)、object-oriented(面向对象的),全书围绕着一系列逐渐繁复的程序问题,以及用以解决这些问题的语言特性。循此方式,读者不只学到C++的函数和结构,也会学习到它们的设计目的和基本原理。一起来看看 《Essential C++中文版》 这本书的介绍吧!

SHA 加密
SHA 加密

SHA 加密工具

XML、JSON 在线转换
XML、JSON 在线转换

在线XML、JSON转换工具

html转js在线工具
html转js在线工具

html转js在线工具