You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
caddy-hugo2/assets/simplemde/dist/simplemde.min.js

7 lines
270 KiB

/**
* simplemde v1.11.2
* Copyright Next Step Webs, Inc.
* @link https://github.com/NextStepWebs/simplemde-markdown-editor
* @license MIT
*/
!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).SimpleMDE=e()}}(function(){return function e(t,n,r){function i(a,l){if(!n[a]){if(!t[a]){var s="function"==typeof require&&require;if(!l&&s)return s(a,!0);if(o)return o(a,!0);var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var u=n[a]={exports:{}};t[a][0].call(u.exports,function(e){var n=t[a][1][e];return i(n||e)},u,u.exports,e,t,n,r)}return n[a].exports}for(var o="function"==typeof require&&require,a=0;a<r.length;a++)i(r[a]);return i}({1:[function(e,t,n){"use strict";function r(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");return"="===e[t-2]?2:"="===e[t-1]?1:0}function i(e){return a[e>>18&63]+a[e>>12&63]+a[e>>6&63]+a[63&e]}function o(e,t,n){for(var r,o=[],a=t;a<n;a+=3)r=(e[a]<<16)+(e[a+1]<<8)+e[a+2],o.push(i(r));return o.join("")}n.byteLength=function(e){return 3*e.length/4-r(e)},n.toByteArray=function(e){var t,n,i,o,a,c,u=e.length;a=r(e),c=new s(3*u/4-a),i=a>0?u-4:u;var f=0;for(t=0,n=0;t<i;t+=4,n+=3)o=l[e.charCodeAt(t)]<<18|l[e.charCodeAt(t+1)]<<12|l[e.charCodeAt(t+2)]<<6|l[e.charCodeAt(t+3)],c[f++]=o>>16&255,c[f++]=o>>8&255,c[f++]=255&o;return 2===a?(o=l[e.charCodeAt(t)]<<2|l[e.charCodeAt(t+1)]>>4,c[f++]=255&o):1===a&&(o=l[e.charCodeAt(t)]<<10|l[e.charCodeAt(t+1)]<<4|l[e.charCodeAt(t+2)]>>2,c[f++]=o>>8&255,c[f++]=255&o),c},n.fromByteArray=function(e){for(var t,n=e.length,r=n%3,i="",l=[],s=0,c=n-r;s<c;s+=16383)l.push(o(e,s,s+16383>c?c:s+16383));return 1===r?(t=e[n-1],i+=a[t>>2],i+=a[t<<4&63],i+="=="):2===r&&(t=(e[n-2]<<8)+e[n-1],i+=a[t>>10],i+=a[t>>4&63],i+=a[t<<2&63],i+="="),l.push(i),l.join("")};for(var a=[],l=[],s="undefined"!=typeof Uint8Array?Uint8Array:Array,c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",u=0,f=c.length;u<f;++u)a[u]=c[u],l[c.charCodeAt(u)]=u;l["-".charCodeAt(0)]=62,l["_".charCodeAt(0)]=63},{}],2:[function(e,t,n){},{}],3:[function(e,t,n){"use strict";function r(e){if(e>K)throw new RangeError("Invalid typed array length");var t=new Uint8Array(e);return t.__proto__=i.prototype,t}function i(e,t,n){if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return s(e)}return o(e,t,n)}function o(e,t,n){if("number"==typeof e)throw new TypeError('"value" argument must not be a number');return e instanceof ArrayBuffer?f(e,t,n):"string"==typeof e?c(e,t):h(e)}function a(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function l(e,t,n){return a(e),e<=0?r(e):void 0!==t?"string"==typeof n?r(e).fill(t,n):r(e).fill(t):r(e)}function s(e){return a(e),r(e<0?0:0|d(e))}function c(e,t){if("string"==typeof t&&""!==t||(t="utf8"),!i.isEncoding(t))throw new TypeError('"encoding" must be a valid string encoding');var n=0|p(e,t),o=r(n),a=o.write(e,t);return a!==n&&(o=o.slice(0,a)),o}function u(e){for(var t=e.length<0?0:0|d(e.length),n=r(t),i=0;i<t;i+=1)n[i]=255&e[i];return n}function f(e,t,n){if(t<0||e.byteLength<t)throw new RangeError("'offset' is out of bounds");if(e.byteLength<t+(n||0))throw new RangeError("'length' is out of bounds");var r;return r=void 0===t&&void 0===n?new Uint8Array(e):void 0===n?new Uint8Array(e,t):new Uint8Array(e,t,n),r.__proto__=i.prototype,r}function h(e){if(i.isBuffer(e)){var t=0|d(e.length),n=r(t);return 0===n.length?n:(e.copy(n,0,0,t),n)}if(e){if(q(e)||"length"in e)return"number"!=typeof e.length||G(e.length)?r(0):u(e);if("Buffer"===e.type&&Array.isArray(e.data))return u(e.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function d(e){if(e>=K)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+K.toString(16)+" bytes");return 0|e}function p(e,t){if(i.isBuffer(e))return e.length;if(q(e)||