PageSourceSearch

https://easyfie.com/superadmin/vendor/libs/toastr/toastr.js

js easyfie.com collected 2026-09-24 06:24:26 UTC 24,293 bytes, 138 lines download raw bytes

vendor: 1,144 bytes, lines 1-21
1/*
2 * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
3 * This devtool is neither made for production nor for readable output files.
4 * It uses "eval()" calls to create a separate source file in the browser devtools.
5 * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
6 * or disable the default devtool with "devtool: false".
7 * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
8 */
9(function webpackUniversalModuleDefinition(root, factory) {
10	if(typeof exports === 'object' && typeof module === 'object')
11		module.exports = factory(require("jQuery"));
12	else if(typeof define === 'function' && define.amd)
13		define(["jQuery"], factory);
14	else {
15		var a = typeof exports === 'object' ? factory(require("jQuery")) : factory(root["jQuery"]);
16		for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
17	}
18})(self, function(__WEBPACK_EXTERNAL_MODULE_jquery__) {
19return /******/ (function() { // webpackBootstrap
20/******/ 	var __webpack_modules__ = ({
21
22/***/ "./libs/toastr/toastr.js":
23/*!*******************************!*\
24  !*** ./libs/toastr/toastr.js ***!
25  \*******************************/
26/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
27
28"use strict";
29eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   toastr: function() { return /* reexport default from dynamic */ toastr_toastr__WEBPACK_IMPORTED_MODULE_0___default.a; }\n/* harmony export */ });\n/* harmony import */ var toastr_toastr__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! toastr/toastr */ \"./node_modules/toastr/toastr.js\");\n/* harmony import */ var toastr_toastr__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(toastr_toastr__WEBPACK_IMPORTED_MODULE_0__);\n\ntry {\n  window.toastr = (toastr_toastr__WEBPACK_IMPORTED_MODULE_0___default());\n} catch (e) {}\n\n\n//# sourceURL=webpack://Vuexy/./libs/toastr/toastr.js?");
30
31/***/ }),
32
vendor: 18,582 bytes, lines 33-41
33/***/ "./node_modules/toastr/toastr.js":
34/*!***************************************!*\
35  !*** ./node_modules/toastr/toastr.js ***!
36  \***************************************/
37/***/ (function(module, exports, __webpack_require__) {
38
39eval("var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*\n * Toastr\n * Copyright 2012-2015\n * Authors: John Papa, Hans Fjällemark, and Tim Ferrell.\n * All Rights Reserved.\n * Use, reproduction, distribution, and modification of this code is subject to the terms and\n * conditions of the MIT license, available at http://www.opensource.org/licenses/mit-license.php\n *\n * ARIA Support: Greta Krafsig\n *\n * Project: https://github.com/CodeSeven/toastr\n */\n/* global define */\n(function (define) {\n    !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(/*! jquery */ \"jquery\")], __WEBPACK_AMD_DEFINE_RESULT__ = (function ($) {\n        return (function () {\n            var $container;\n            var listener;\n            var toastId = 0;\n            var toastType = {\n                error: 'error',\n                info: 'info',\n                success: 'success',\n                warning: 'warning'\n            };\n\n            var toastr = {\n                clear: clear,\n                remove: remove,\n                error: error,\n                getContainer: getContainer,\n                info: info,\n                options: {},\n                subscribe: subscribe,\n                success: success,\n                version: '2.1.4',\n                warning: warning\n            };\n\n            var previousToast;\n\n            return toastr;\n\n            ////////////////\n\n            function error(message, title, optionsOverride) {\n                return notify({\n                    type: toastType.error,\n                    iconClass: getOptions().iconClasses.error,\n                    message: message,\n                    optionsOverride: optionsOverride,\n                    title: title\n                });\n            }\n\n            function getContainer(options, create) {\n                if (!options) { options = getOptions(); }\n                $container = $('#' + options.containerId);\n                if ($container.length) {\n                    return $container;\n                }\n                if (create) {\n                    $container = createContainer(options);\n                }\n                return $container;\n            }\n\n            function info(message, title, optionsOverride) {\n                return notify({\n                    type: toastType.info,\n                    iconClass: getOptions().iconClasses.info,\n                    message: message,\n                    optionsOverride: optionsOverride,\n                    title: title\n                });\n            }\n\n            function subscribe(callback) {\n                listener = callback;\n            }\n\n            function success(message, title, optionsOverride) {\n                return notify({\n                    type: toastType.success,\n                    iconClass: getOptions().iconClasses.success,\n                    message: message,\n                    optionsOverride: optionsOverride,\n                    title: title\n                });\n            }\n\n            function warning(message, title, optionsOverride) {\n                return notify({\n                    type: toastType.warning,\n                    iconClass: getOptions().iconClasses.warning,\n                    message: message,\n                    optionsOverride: optionsOverride,\n                    title: title\n                });\n            }\n\n            function clear($toastElement, clearOptions) {\n                var options = getOptions();\n                if (!$container) { getContainer(options); }\n                if (!clearToast($toastElement, options, clearOptions)) {\n                    clearContainer(options);\n                }\n            }\n\n            function remove($toastElement) {\n                var options = getOptions();\n                if (!$container) { getContainer(options); }\n                if ($toastElement && $(':focus', $toastElement).length === 0) {\n                    removeToast($toastElement);\n                    return;\n                }\n                if ($container.children().length) {\n                    $container.remove();\n                }\n            }\n\n            // internal functions\n\n            function clearContainer (options) {\n                var toastsToClear = $container.children();\n                for (var i = toastsToClear.length - 1; i >= 0; i--) {\n                    clearToast($(toastsToClear[i]), options);\n                }\n            }\n\n            function clearToast ($toastElement, options, clearOptions) {\n                var force = clearOptions && clearOptions.force ? clearOptions.force : false;\n                if ($toastElement && (force || $(':focus', $toastElement).length === 0)) {\n                    $toastElement[options.hideMethod]({\n                        duration: options.hideDuration,\n                        easing: options.hideEasing,\n                        complete: function () { removeToast($toastElement); }\n                    });\n                    return true;\n                }\n                return false;\n            }\n\n            function createContainer(options) {\n                $container = $('<div/>')\n                    .attr('id', options.containerId)\n                    .addClass(options.positionClass);\n\n                $container.appendTo($(options.target));\n                return $container;\n            }\n\n            function getDefaults() {\n                return {\n                    tapToDismiss: true,\n                    toastClass: 'toast',\n                    containerId: 'toast-container',\n                    debug: false,\n\n                    showMethod: 'fadeIn', //fadeIn, slideDown, and show are built into jQuery\n                    showDuration: 300,\n                    showEasing: 'swing', //swing and linear are built into jQuery\n                    onShown: undefined,\n                    hideMethod: 'fadeOut',\n                    hideDuration: 1000,\n                    hideEasing: 'swing',\n                    onHidden: undefined,\n                    closeMethod: false,\n                    closeDuration: false,\n                    closeEasing: false,\n                    closeOnHover: true,\n\n                    extendedTimeOut: 1000,\n                    iconClasses: {\n                        error: 'toast-error',\n                        info: 'toast-info',\n                        success: 'toast-success',\n                        warning: 'toast-warning'\n                    },\n                    iconClass: 'toast-info',\n                    positionClass: 'toast-top-right',\n                    timeOut: 5000, // Set timeOut and extendedTimeOut to 0 to make it sticky\n                    titleClass: 'toast-title',\n                    messageClass: 'toast-message',\n                    escapeHtml: false,\n                    target: 'body',\n                    closeHtml: '<button type=\"button\">&times;</button>',\n                    closeClass: 'toast-close-button',\n                    newestOnTop: true,\n                    preventDuplicates: false,\n                    progressBar: false,\n                    progressClass: 'toast-progress',\n                    rtl: false\n                };\n            }\n\n            function publish(args) {\n                if (!listener) { return; }\n                listener(args);\n            }\n\n            function notify(map) {\n                var options = getOptions();\n                var iconClass = map.iconClass || options.iconClass;\n\n                if (typeof (map.optionsOverride) !== 'undefined') {\n                    options = $.extend(options, map.optionsOverride);\n                    iconClass = map.optionsOverride.iconClass || iconClass;\n                }\n\n                if (shouldExit(options, map)) { return; }\n\n                toastId++;\n\n                $container = getContainer(options, true);\n\n                var intervalId = null;\n                var $toastElement = $('<div/>');\n                var $titleElement = $('<div/>');\n                var $messageElement = $('<div/>');\n                var $progressElement = $('<div/>');\n                var $closeElement = $(options.closeHtml);\n                var progressBar = {\n                    intervalId: null,\n                    hideEta: null,\n                    maxHideTime: null\n                };\n                var response = {\n                    toastId: toastId,\n                    state: 'visible',\n                    startTime: new Date(),\n                    options: options,\n                    map: map\n                };\n\n                personalizeToast();\n\n                displayToast();\n\n                handleEvents();\n\n                publish(response);\n\n                if (options.debug && console) {\n                    console.log(response);\n                }\n\n                return $toastElement;\n\n                function escapeHtml(source) {\n                    if (source == null) {\n                        source = '';\n                    }\n\n                    return source\n                        .replace(/&/g, '&amp;')\n                        .replace(/\"/g, '&quot;')\n                        .replace(/'/g, '&#39;')\n                        .replace(/</g, '&lt;')\n                        .replace(/>/g, '&gt;');\n                }\n\n                function personalizeToast() {\n                    setIcon();\n                    setTitle();\n                    setMessage();\n                    setCloseButton();\n                    setProgressBar();\n                    setRTL();\n                    setSequence();\n                    setAria();\n                }\n\n                function setAria() {\n                    var ariaValue = '';\n                    switch (map.iconClass) {\n                        case 'toast-success':\n                        case 'toast-info':\n                            ariaValue =  'polite';\n                            break;\n                        default:\n                            ariaValue = 'assertive';\n                    }\n                    $toastElement.attr('aria-live', ariaValue);\n                }\n\n                function handleEvents() {\n                    if (options.closeOnHover) {\n                        $toastElement.hover(stickAround, delayedHideToast);\n                    }\n\n                    if (!options.onclick && options.tapToDismiss) {\n                        $toastElement.click(hideToast);\n                    }\n\n                    if (options.closeButton && $closeElement) {\n                        $closeElement.click(function (event) {\n                            if (event.stopPropagation) {\n                                event.stopPropagation();\n                            } else if (event.cancelBubble !== undefined && event.cancelBubble !== true) {\n                                event.cancelBubble = true;\n                            }\n\n                            if (options.onCloseClick) {\n                                options.onCloseClick(event);\n                            }\n\n                            hideToast(true);\n                        });\n                    }\n\n                    if (options.onclick) {\n                        $toastElement.click(function (event) {\n                            options.onclick(event);\n                            hideToast();\n                        });\n                    }\n                }\n\n                function displayToast() {\n                    $toastElement.hide();\n\n                    $toastElement[options.showMethod](\n                        {duration: options.showDuration, easing: options.showEasing, complete: options.onShown}\n                    );\n\n                    if (options.timeOut > 0) {\n                        intervalId = setTimeout(hideToast, options.timeOut);\n                        progressBar.maxHideTime = parseFloat(options.timeOut);\n                        progressBar.hideEta = new Date().getTime() + progressBar.maxHideTime;\n                        if (options.progressBar) {\n                            progressBar.intervalId = setInterval(updateProgress, 10);\n                        }\n                    }\n                }\n\n                function setIcon() {\n                    if (map.iconClass) {\n                        $toastElement.addClass(options.toastClass).addClass(iconClass);\n                    }\n                }\n\n                function setSequence() {\n                    if (options.newestOnTop) {\n                        $container.prepend($toastElement);\n                    } else {\n                        $container.append($toastElement);\n                    }\n                }\n\n                function setTitle() {\n                    if (map.title) {\n                        var suffix = map.title;\n                        if (options.escapeHtml) {\n                            suffix = escapeHtml(map.title);\n                        }\n                        $titleElement.append(suffix).addClass(options.titleClass);\n                        $toastElement.append($titleElement);\n                    }\n                }\n\n                function setMessage() {\n                    if (map.message) {\n                        var suffix = map.message;\n                        if (options.escapeHtml) {\n                            suffix = escapeHtml(map.message);\n                        }\n                        $messageElement.append(suffix).addClass(options.messageClass);\n                        $toastElement.append($messageElement);\n                    }\n                }\n\n                function setCloseButton() {\n                    if (options.closeButton) {\n                        $closeElement.addClass(options.closeClass).attr('role', 'button');\n                        $toastElement.prepend($closeElement);\n                    }\n                }\n\n                function setProgressBar() {\n                    if (options.progressBar) {\n                        $progressElement.addClass(options.progressClass);\n                        $toastElement.prepend($progressElement);\n                    }\n                }\n\n                function setRTL() {\n                    if (options.rtl) {\n                        $toastElement.addClass('rtl');\n                    }\n                }\n\n                function shouldExit(options, map) {\n                    if (options.preventDuplicates) {\n                        if (map.message === previousToast) {\n                            return true;\n                        } else {\n                            previousToast = map.message;\n                        }\n                    }\n                    return false;\n                }\n\n                function hideToast(override) {\n                    var method = override && options.closeMethod !== false ? options.closeMethod : options.hideMethod;\n                    var duration = override && options.closeDuration !== false ?\n                        options.closeDuration : options.hideDuration;\n                    var easing = override && options.closeEasing !== false ? options.closeEasing : options.hideEasing;\n                    if ($(':focus', $toastElement).length && !override) {\n                        return;\n                    }\n                    clearTimeout(progressBar.intervalId);\n                    return $toastElement[method]({\n                        duration: duration,\n                        easing: easing,\n                        complete: function () {\n                            removeToast($toastElement);\n                            clearTimeout(intervalId);\n                            if (options.onHidden && response.state !== 'hidden') {\n                                options.onHidden();\n                            }\n                            response.state = 'hidden';\n                            response.endTime = new Date();\n                            publish(response);\n                        }\n                    });\n                }\n\n                function delayedHideToast() {\n                    if (options.timeOut > 0 || options.extendedTimeOut > 0) {\n                        intervalId = setTimeout(hideToast, options.extendedTimeOut);\n                        progressBar.maxHideTime = parseFloat(options.extendedTimeOut);\n                        progressBar.hideEta = new Date().getTime() + progressBar.maxHideTime;\n                    }\n                }\n\n                function stickAround() {\n                    clearTimeout(intervalId);\n                    progressBar.hideEta = 0;\n                    $toastElement.stop(true, true)[options.showMethod](\n                        {duration: options.showDuration, easing: options.showEasing}\n                    );\n                }\n\n                function updateProgress() {\n                    var percentage = ((progressBar.hideEta - (new Date().getTime())) / progressBar.maxHideTime) * 100;\n                    $progressElement.width(percentage + '%');\n                }\n            }\n\n            function getOptions() {\n                return $.extend({}, getDefaults(), toastr.options);\n            }\n\n            function removeToast($toastElement) {\n                if (!$container) { $container = getContainer(); }\n                if ($toastElement.is(':visible')) {\n                    return;\n                }\n                $toastElement.remove();\n                $toastElement = null;\n                if ($container.children().length === 0) {\n                    $container.remove();\n                    previousToast = undefined;\n                }\n            }\n\n        })();\n    }).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),\n\t\t__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));\n}(__webpack_require__.amdD));\n\n\n//# sourceURL=webpack://Vuexy/./node_modules/toastr/toastr.js?");
40
41/***/ })
vendor: 3,553 bytes, lines 41-138
41,
42
43/***/ "jquery":
44/*!*************************!*\
45  !*** external "jQuery" ***!
46  \*************************/
47/***/ (function(module) {
48
49"use strict";
50module.exports = __WEBPACK_EXTERNAL_MODULE_jquery__;
51
52/***/ })
53
54/******/ 	});
55/************************************************************************/
56/******/ 	// The module cache
57/******/ 	var __webpack_module_cache__ = {};
58/******/ 	
59/******/ 	// The require function
60/******/ 	function __webpack_require__(moduleId) {
61/******/ 		// Check if module is in cache
62/******/ 		var cachedModule = __webpack_module_cache__[moduleId];
63/******/ 		if (cachedModule !== undefined) {
64/******/ 			return cachedModule.exports;
65/******/ 		}
66/******/ 		// Create a new module (and put it into the cache)
67/******/ 		var module = __webpack_module_cache__[moduleId] = {
68/******/ 			// no module.id needed
69/******/ 			// no module.loaded needed
70/******/ 			exports: {}
71/******/ 		};
72/******/ 	
73/******/ 		// Execute the module function
74/******/ 		__webpack_modules__[moduleId](module, module.exports, __webpack_require__);
75/******/ 	
76/******/ 		// Return the exports of the module
77/******/ 		return module.exports;
78/******/ 	}
79/******/ 	
80/************************************************************************/
81/******/ 	/* webpack/runtime/amd define */
82/******/ 	!function() {
83/******/ 		__webpack_require__.amdD = function () {
84/******/ 			throw new Error('define cannot be used indirect');
85/******/ 		};
86/******/ 	}();
87/******/ 	
88/******/ 	/* webpack/runtime/compat get default export */
89/******/ 	!function() {
90/******/ 		// getDefaultExport function for compatibility with non-harmony modules
91/******/ 		__webpack_require__.n = function(module) {
92/******/ 			var getter = module && module.__esModule ?
93/******/ 				function() { return module['default']; } :
94/******/ 				function() { return module; };
95/******/ 			__webpack_require__.d(getter, { a: getter });
96/******/ 			return getter;
97/******/ 		};
98/******/ 	}();
99/******/ 	
100/******/ 	/* webpack/runtime/define property getters */
101/******/ 	!function() {
102/******/ 		// define getter functions for harmony exports
103/******/ 		__webpack_require__.d = function(exports, definition) {
104/******/ 			for(var key in definition) {
105/******/ 				if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
106/******/ 					Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
107/******/ 				}
108/******/ 			}
109/******/ 		};
110/******/ 	}();
111/******/ 	
112/******/ 	/* webpack/runtime/hasOwnProperty shorthand */
113/******/ 	!function() {
114/******/ 		__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }
115/******/ 	}();
116/******/ 	
117/******/ 	/* webpack/runtime/make namespace object */
118/******/ 	!function() {
119/******/ 		// define __esModule on exports
120/******/ 		__webpack_require__.r = function(exports) {
121/******/ 			if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
122/******/ 				Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
123/******/ 			}
124/******/ 			Object.defineProperty(exports, '__esModule', { value: true });
125/******/ 		};
126/******/ 	}();
127/******/ 	
128/************************************************************************/
129/******/ 	
130/******/ 	// startup
131/******/ 	// Load entry module and return exports
132/******/ 	// This entry module can't be inlined because the eval devtool is used.
133/******/ 	var __webpack_exports__ = __webpack_require__("./libs/toastr/toastr.js");
134/******/ 	
135/******/ 	return __webpack_exports__;
136/******/ })()
137;
138});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.