// (function (global, factory) {
// typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
// typeof define === 'function' && define.amd ? define(factory) :
// (global.nativeToast = factory());
// }(this, (function () { 'use strict';
// /*
// object-assign
// (c) Sindre Sorhus
// @license MIT
// */
// /* eslint-disable no-unused-vars */
// var getOwnPropertySymbols = Object.getOwnPropertySymbols;
// var hasOwnProperty = Object.prototype.hasOwnProperty;
// var propIsEnumerable = Object.prototype.propertyIsEnumerable;
// function toObject(val) {
// if (val === null || val === undefined) {
// throw new TypeError('Object.assign cannot be called with null or undefined');
// }
// return Object(val);
// }
// function shouldUseNative() {
// try {
// if (!Object.assign) {
// return false;
// }
// // Detect buggy property enumeration order in older V8 versions.
// // https://bugs.chromium.org/p/v8/issues/detail?id=4118
// var test1 = new String('abc'); // eslint-disable-line no-new-wrappers
// test1[5] = 'de';
// if (Object.getOwnPropertyNames(test1)[0] === '5') {
// return false;
// }
// // https://bugs.chromium.org/p/v8/issues/detail?id=3056
// var test2 = {};
// for (var i = 0; i < 10; i++) {
// test2['_' + String.fromCharCode(i)] = i;
// }
// var order2 = Object.getOwnPropertyNames(test2).map(function (n) {
// return test2[n];
// });
// if (order2.join('') !== '0123456789') {
// return false;
// }
// // https://bugs.chromium.org/p/v8/issues/detail?id=3056
// var test3 = {};
// 'abcdefghijklmnopqrst'.split('').forEach(function (letter) {
// test3[letter] = letter;
// });
// if (Object.keys(Object.assign({}, test3)).join('') !==
// 'abcdefghijklmnopqrst') {
// return false;
// }
// return true;
// } catch (err) {
// // We don't expect any of the above to throw, but better to be safe.
// return false;
// }
// }
// var index = shouldUseNative() ? Object.assign : function (target, source) {
// var arguments$1 = arguments;
// var from;
// var to = toObject(target);
// var symbols;
// for (var s = 1; s < arguments.length; s++) {
// from = Object(arguments$1[s]);
// for (var key in from) {
// if (hasOwnProperty.call(from, key)) {
// to[key] = from[key];
// }
// }
// if (getOwnPropertySymbols) {
// symbols = getOwnPropertySymbols(from);
// for (var i = 0; i < symbols.length; i++) {
// if (propIsEnumerable.call(from, symbols[i])) {
// to[symbols[i]] = from[symbols[i]];
// }
// }
// }
// }
// return to;
// };
// var prevToast = null;
// // var icons = {
// // warning: "<svg viewBox=\"0 0 32 32\" width=\"32\" height=\"32\" fill=\"none\" stroke=\"currentcolor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"6.25%\"><path d=\"M8 17 C8 12 9 6 16 6 23 6 24 12 24 17 24 22 27 25 27 25 L5 25 C5 25 8 22 8 17 Z M20 25 C20 25 20 29 16 29 12 29 12 25 12 25 M16 3 L16 6\" /></svg>",
// // success: "<svg viewBox=\"0 0 32 32\" width=\"32\" height=\"32\" fill=\"none\" stroke=\"currentcolor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"6.25%\"><path d=\"M2 20 L12 28 30 4\" /></svg>",
// // info: "<svg viewBox=\"0 0 32 32\" width=\"32\" height=\"32\" fill=\"none\" stroke=\"currentcolor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"6.25%\"><path d=\"M16 14 L16 23 M16 8 L16 10\" /><circle cx=\"16\" cy=\"16\" r=\"14\" /></svg>",
// // error: "<svg viewBox=\"0 0 32 32\" width=\"32\" height=\"32\" fill=\"none\" stroke=\"currentcolor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"6.25%\"><path d=\"M16 3 L30 29 2 29 Z M16 11 L16 19 M16 23 L16 25\" /></svg>"
// // };
// var icons = {
// warning: "",
// success: "",
// info: "",
// error: ""
// }
// var Toast = function Toast(ref) {
// if ( ref === void 0 ) ref = {};
// var message = ref.message; if ( message === void 0 ) message = '';
// var position = ref.position; if ( position === void 0 ) position = 'bottom';
// var timeout = ref.timeout; if ( timeout === void 0 ) timeout = 4000;
// var el = ref.el; if ( el === void 0 ) el = document.body;
// var square = ref.square; if ( square === void 0 ) square = false;
// var type = ref.type; if ( type === void 0 ) type = '';
// var debug = ref.debug; if ( debug === void 0 ) debug = false;
// var edge = ref.edge; if ( edge === void 0 ) edge = false;
// if (prevToast) {
// prevToast.destroy();
// }
// this.message = message;
// this.position = position;
// this.el = el;
// this.timeout = timeout;
// this.toast = document.createElement('div');
// this.toast.className = "native-toast native-toast-" + (this.position);
// if (type) {
// this.toast.className += " native-toast-" + type;
// // this.message = "<span class=\"native-toast-icon-" + type + "\">" + (icons[type] || '') + "</span>" + (this.message);
// }
// this.toast.innerHTML = this.message;
// if (edge) {
// this.toast.className += ' native-toast-edge';
// }
// if (square) {
// this.toast.style.borderRadius = '3px';
// }
// this.el.appendChild(this.toast);
// prevToast = this;
// this.show();
// if (!debug) {
// this.hide();
// }
// };
// Toast.prototype.show = function show () {
// var this$1 = this;
// setTimeout(function () {
// this$1.toast.classList.add('native-toast-shown');
// }, 300);
// };
// Toast.prototype.hide = function hide () {
// var this$1 = this;
// setTimeout(function () {
// this$1.destroy();
// }, this.timeout);
// };
// Toast.prototype.destroy = function destroy () {
// var this$1 = this;
// if (!this.toast) { return }
// this.toast.classList.remove('native-toast-shown');
// setTimeout(function () {
// if (this$1.toast) {
// this$1.el.removeChild(this$1.toast);
// this$1.toast = null;
// }
// }, 300);
// };
// function toast(options) {
// return new Toast(options)
// }
// var loop = function () {
// var type = list[i];
// toast[type] = function (options) { return toast(index({}, {type: type}, options)); };
// };
// for (var i = 0, list = ['success', 'info', 'warning', 'error']; i < list.length; i += 1) loop();
// return toast;
// })));
// var log = {
// success : function(){
// // console.log.apply(this, arguments);
// nativeToast({
// message: arguments[0],
// type: 'success'
// })
// },
// info: function(){
// // console.info.apply(this, arguments);
// nativeToast({
// message: arguments[0],
// type: 'info'
// })
// },
// warn: function(){
// // console.warn.apply(this, arguments);
// nativeToast({
// message: arguments[0],
// type: 'warning'
// })
// },
// error: function(){
// // console.error.apply(this, arguments);
// nativeToast({
// message: arguments[0],
// type: 'error'
// })
// }
// };
// var ajax = function (url, option, callback) {
// var defaultOption = {
// method: 'GET',
// dataType: 'JSON'
// }
// if (typeof option === 'function') {
// callback = option
// option = defaultOption
// } else {
// for (var key in defaultOption) {
// if (defaultOption.hasOwnProperty(key) && option[key] === undefined) {
// option[key] = defaultOption[key]
// }
// }
// }
// var xhr = new XMLHttpRequest()
// xhr.onreadystatechange = function () {
// if (xhr.readyState === 4) {
// if ((xhr.status >= 200 && xhr.status < 300) || xhr.status == 304 || (xhr.status == 0 && protocol == 'file:')) {
// var response = xhr.responseText
// if (option.dataType === 'JSON') {
// try {
// response = JSON.parse(response)
// } catch (err) {
// return callback(err)
// }
// callback(null, response)
// } else {
// callback(new Error(url + ' request failed'))
// }
// }
// }
// }
// xhr.open(option.method || 'GET', url)
// x
没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
![rar](https://img-home.csdnimg.cn/images/20210720083606.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![thumb](https://img-home.csdnimg.cn/images/20210720083646.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![rar](https://img-home.csdnimg.cn/images/20210720083606.png)
![rar](https://img-home.csdnimg.cn/images/20210720083606.png)
收起资源包目录
![package](https://csdnimg.cn/release/downloadcmsfe/public/img/package.f3fc750b.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/PNG.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/JPG.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/PNG.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/PNG.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/PNG.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/PNG.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![folder](https://csdnimg.cn/release/downloadcmsfe/public/img/folder.005fa2e5.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/JPG.png)
![file-type](https://csdnimg.cn/release/download/static_files/pc/images/minetype/UNKNOWN.png)
共 31 条
- 1
资源评论
![avatar-default](https://csdnimg.cn/release/downloadcmsfe/public/img/lazyLogo2.1882d7f4.png)
![avatar](https://profile-avatar.csdnimg.cn/cce9b7209c5642d689f603c2d8463aee_u014740628.jpg!1)
![avatar-vip](https://csdnimg.cn/release/downloadcmsfe/public/img/user-vip.1c89f3c5.png)
逃逸的卡路里
- 粉丝: 7523
- 资源: 3640
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助
![voice](https://csdnimg.cn/release/downloadcmsfe/public/img/voice.245cc511.png)
![center-task](https://csdnimg.cn/release/downloadcmsfe/public/img/center-task.c2eda91a.png)
安全验证
文档复制为VIP权益,开通VIP直接复制
![dialog-icon](https://csdnimg.cn/release/downloadcmsfe/public/img/green-success.6a4acb44.png)