impr:完善okSweetAlert2

master
bobi 2019-11-02 18:13:36 +08:00
parent 68fcb95f08
commit c2f6c5a2c8
1 changed files with 6 additions and 7 deletions

View File

@ -33,9 +33,7 @@ layui.use(["okSweetAlert2"], function () {
okSweetAlert2.fire({ okSweetAlert2.fire({
type: "info", type: "info",
title: "<strong>HTML <u>example</u></strong>", title: "<strong>HTML <u>example</u></strong>",
html: "You can use <b>bold text</b>, " + html: "You can use <b>bold text</b>, <a href='http://git.xlbweb.cn/ok-admin' target='_blank'>links</a> and other HTML tags",
"<a href='http://git.xlbweb.cn/ok-admin' target='_blank'>links</a> " +
"and other HTML tags",
showCloseButton: true, showCloseButton: true,
showCancelButton: true, showCancelButton: true,
focusConfirm: false, focusConfirm: false,
@ -74,11 +72,14 @@ layui.use(["okSweetAlert2"], function () {
<!--js逻辑--> <!--js逻辑-->
<script src="../../lib/layui/layui.js"></script> <script src="../../lib/layui/layui.js"></script>
<script> <script>
layui.use(["code", "okSweetAlert2"], function () { layui.use(["util", "code", "okSweetAlert2"], function () {
let util = layui.util;
let code = layui.code; let code = layui.code;
let okSweetAlert2 = layui.okSweetAlert2; let okSweetAlert2 = layui.okSweetAlert2;
let $ = layui.jquery; let $ = layui.jquery;
util.fixbar({});
code({ code({
elem: "pre", elem: "pre",
title: "代码示例" title: "代码示例"
@ -109,9 +110,7 @@ layui.use(["okSweetAlert2"], function () {
okSweetAlert2.fire({ okSweetAlert2.fire({
type: "info", type: "info",
title: "<strong>HTML <u>example</u></strong>", title: "<strong>HTML <u>example</u></strong>",
html: "You can use <b>bold text</b>, " + html: "You can use <b>bold text</b>, <a href='http://git.xlbweb.cn/ok-admin' target='_blank'>links</a> and other HTML tags",
"<a href='http://git.xlbweb.cn/ok-admin' target='_blank'>links</a> " +
"and other HTML tags",
showCloseButton: true, showCloseButton: true,
showCancelButton: true, showCancelButton: true,
focusConfirm: false, focusConfirm: false,