Preact

Preact bundled

Цей скрипт не слід встановлювати безпосередньо. Це - бібліотека для інших скриптів для включення в мета директиву // @require https://update.greasyfork.org/scripts/396836/775091/Preact.js

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(У мене вже є менеджер скриптів, дайте мені встановити його!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         Preact
// @namespace    eisen-stein
// @version      1.0.0
// @description  Preact bundled
// ==/UserScript==

!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.preact=n():e.preact=n()}(window,(function(){return function(e){var n={};function t(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,t),r.l=!0,r.exports}return t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:o})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(t.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var r in e)t.d(o,r,function(n){return e[n]}.bind(null,r));return o},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="",t(t.s=0)}([function(e,n,t){"use strict";t.r(n);var o,r,l,u,_,i,c,f={},s=[],p=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord/i;function a(e,n){for(var t in n)e[t]=n[t];return e}function d(e){var n=e.parentNode;n&&n.removeChild(e)}function h(e,n,t){var o,r=arguments,l={};for(o in n)"key"!==o&&"ref"!==o&&(l[o]=n[o]);if(arguments.length>3)for(t=[t],o=3;o<arguments.length;o++)t.push(r[o]);if(null!=t&&(l.children=t),"function"==typeof e&&null!=e.defaultProps)for(o in e.defaultProps)void 0===l[o]&&(l[o]=e.defaultProps[o]);return y(e,l,n&&n.key,n&&n.ref)}function y(e,n,t,r){var l={type:e,props:n,key:t,ref:r,__k:null,__:null,__b:0,__e:null,__d:null,__c:null,constructor:void 0};return o.vnode&&o.vnode(l),l}function v(){return{}}function m(e){return e.children}function g(e,n){this.props=e,this.context=n}function b(e,n){if(null==n)return e.__?b(e.__,e.__.__k.indexOf(e)+1):null;for(var t;n<e.__k.length;n++)if(null!=(t=e.__k[n])&&null!=t.__e)return t.__e;return"function"==typeof e.type?b(e):null}function k(e){var n,t;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,n=0;n<e.__k.length;n++)if(null!=(t=e.__k[n])&&null!=t.__e){e.__e=e.__c.base=t.__e;break}return k(e)}}function x(e){(!e.__d&&(e.__d=!0)&&1===l.push(e)||_!==o.debounceRendering)&&((_=o.debounceRendering)||u)(w)}function w(){var e,n,t,o,r,u,_;for(l.sort((function(e,n){return n.__v.__b-e.__v.__b}));e=l.pop();)e.__d&&(t=void 0,o=void 0,u=(r=(n=e).__v).__e,(_=n.__P)&&(t=[],o=N(_,r,a({},r),n.__n,void 0!==_.ownerSVGElement,null,t,null==u?b(r):u),T(t,r),o!=u&&k(r)))}function C(e,n,t,o,r,l,u,_,i){var c,p,a,h,y,v,m,g=t&&t.__k||s,k=g.length;if(_==f&&(_=null!=l?l[0]:k?b(t,0):null),c=0,n.__k=S(n.__k,(function(t){if(null!=t){if(t.__=n,t.__b=n.__b+1,null===(a=g[c])||a&&t.key==a.key&&t.type===a.type)g[c]=void 0;else for(p=0;p<k;p++){if((a=g[p])&&t.key==a.key&&t.type===a.type){g[p]=void 0;break}a=null}if(h=N(e,t,a=a||f,o,r,l,u,_,i),(p=t.ref)&&a.ref!=p&&(m||(m=[]),a.ref&&m.push(a.ref,null,t),m.push(p,t.__c||h,t)),null!=h){if(null==v&&(v=h),null!=t.__d)h=t.__d,t.__d=null;else if(l==a||h!=_||null==h.parentNode){e:if(null==_||_.parentNode!==e)e.appendChild(h);else{for(y=_,p=0;(y=y.nextSibling)&&p<k;p+=2)if(y==h)break e;e.insertBefore(h,_)}"option"==n.type&&(e.value="")}_=h.nextSibling,"function"==typeof n.type&&(n.__d=h)}}return c++,t})),n.__e=v,null!=l&&"function"!=typeof n.type)for(c=l.length;c--;)null!=l[c]&&d(l[c]);for(c=k;c--;)null!=g[c]&&j(g[c],g[c]);if(m)for(c=0;c<m.length;c++)M(m[c],m[++c],m[++c])}function S(e,n,t){if(null==t&&(t=[]),null==e||"boolean"==typeof e)n&&t.push(n(null));else if(Array.isArray(e))for(var o=0;o<e.length;o++)S(e[o],n,t);else t.push(n?n("string"==typeof e||"number"==typeof e?y(null,e,null,null):null!=e.__e||null!=e.__c?y(e.type,e.props,e.key,null):e):e);return t}function P(e,n,t){"-"===n[0]?e.setProperty(n,t):e[n]="number"==typeof t&&!1===p.test(n)?t+"px":null==t?"":t}function E(e,n,t,o,r){var l,u,_,i,c;if(r?"className"===n&&(n="class"):"class"===n&&(n="className"),"key"===n||"children"===n);else if("style"===n)if(l=e.style,"string"==typeof t)l.cssText=t;else{if("string"==typeof o&&(l.cssText="",o=null),o)for(u in o)t&&u in t||P(l,u,"");if(t)for(_ in t)o&&t[_]===o[_]||P(l,_,t[_])}else"o"===n[0]&&"n"===n[1]?(i=n!==(n=n.replace(/Capture$/,"")),c=n.toLowerCase(),n=(c in e?c:n).slice(2),t?(o||e.addEventListener(n,U,i),(e.l||(e.l={}))[n]=t):e.removeEventListener(n,U,i)):"list"!==n&&"tagName"!==n&&"form"!==n&&"type"!==n&&!r&&n in e?e[n]=null==t?"":t:"function"!=typeof t&&"dangerouslySetInnerHTML"!==n&&(n!==(n=n.replace(/^xlink:?/,""))?null==t||!1===t?e.removeAttributeNS("http://www.w3.org/1999/xlink",n.toLowerCase()):e.setAttributeNS("http://www.w3.org/1999/xlink",n.toLowerCase(),t):null==t||!1===t?e.removeAttribute(n):e.setAttribute(n,t))}function U(e){this.l[e.type](o.event?o.event(e):e)}function N(e,n,t,r,l,u,_,i,c){var f,s,p,d,h,y,v,b,k,x,w=n.type;if(void 0!==n.constructor)return null;(f=o.__b)&&f(n);try{e:if("function"==typeof w){if(b=n.props,k=(f=w.contextType)&&r[f.__c],x=f?k?k.props.value:f.__:r,t.__c?v=(s=n.__c=t.__c).__=s.__E:("prototype"in w&&w.prototype.render?n.__c=s=new w(b,x):(n.__c=s=new g(b,x),s.constructor=w,s.render=O),k&&k.sub(s),s.props=b,s.state||(s.state={}),s.context=x,s.__n=r,p=s.__d=!0,s.__h=[]),null==s.__s&&(s.__s=s.state),null!=w.getDerivedStateFromProps&&(s.__s==s.state&&(s.__s=a({},s.__s)),a(s.__s,w.getDerivedStateFromProps(b,s.__s))),d=s.props,h=s.state,p)null==w.getDerivedStateFromProps&&null!=s.componentWillMount&&s.componentWillMount(),null!=s.componentDidMount&&s.__h.push(s.componentDidMount);else{if(null==w.getDerivedStateFromProps&&b!==d&&null!=s.componentWillReceiveProps&&s.componentWillReceiveProps(b,x),!s.__e&&null!=s.shouldComponentUpdate&&!1===s.shouldComponentUpdate(b,s.__s,x)){for(s.props=b,s.state=s.__s,s.__d=!1,s.__v=n,n.__e=t.__e,n.__k=t.__k,s.__h.length&&_.push(s),f=0;f<n.__k.length;f++)n.__k[f]&&(n.__k[f].__=n);break e}null!=s.componentWillUpdate&&s.componentWillUpdate(b,s.__s,x),null!=s.componentDidUpdate&&s.__h.push((function(){s.componentDidUpdate(d,h,y)}))}s.context=x,s.props=b,s.state=s.__s,(f=o.__r)&&f(n),s.__d=!1,s.__v=n,s.__P=e,f=s.render(s.props,s.state,s.context),n.__k=S(null!=f&&f.type==m&&null==f.key?f.props.children:f),null!=s.getChildContext&&(r=a(a({},r),s.getChildContext())),p||null==s.getSnapshotBeforeUpdate||(y=s.getSnapshotBeforeUpdate(d,h)),C(e,n,t,r,l,u,_,i,c),s.base=n.__e,s.__h.length&&_.push(s),v&&(s.__E=s.__=null),s.__e=null}else n.__e=D(t.__e,n,t,r,l,u,_,c);(f=o.diffed)&&f(n)}catch(e){o.__e(e,n,t)}return n.__e}function T(e,n){o.__c&&o.__c(n,e),e.some((function(n){try{e=n.__h,n.__h=[],e.some((function(e){e.call(n)}))}catch(e){o.__e(e,n.__v)}}))}function D(e,n,t,o,r,l,u,_){var i,c,p,a,d,h=t.props,y=n.props;if(r="svg"===n.type||r,null==e&&null!=l)for(i=0;i<l.length;i++)if(null!=(c=l[i])&&(null===n.type?3===c.nodeType:c.localName===n.type)){e=c,l[i]=null;break}if(null==e){if(null===n.type)return document.createTextNode(y);e=r?document.createElementNS("http://www.w3.org/2000/svg",n.type):document.createElement(n.type),l=null}if(null===n.type)null!=l&&(l[l.indexOf(e)]=null),h!==y&&e.data!=y&&(e.data=y);else if(n!==t){if(null!=l&&(l=s.slice.call(e.childNodes)),p=(h=t.props||f).dangerouslySetInnerHTML,a=y.dangerouslySetInnerHTML,!_){if(h===f)for(h={},d=0;d<e.attributes.length;d++)h[e.attributes[d].name]=e.attributes[d].value;(a||p)&&(a&&p&&a.__html==p.__html||(e.innerHTML=a&&a.__html||""))}(function(e,n,t,o,r){var l;for(l in t)l in n||E(e,l,null,t[l],o);for(l in n)r&&"function"!=typeof n[l]||"value"===l||"checked"===l||t[l]===n[l]||E(e,l,n[l],t[l],o)})(e,y,h,r,_),n.__k=n.props.children,a||C(e,n,t,o,"foreignObject"!==n.type&&r,l,u,f,_),_||("value"in y&&void 0!==y.value&&y.value!==e.value&&(e.value=null==y.value?"":y.value),"checked"in y&&void 0!==y.checked&&y.checked!==e.checked&&(e.checked=y.checked))}return e}function M(e,n,t){try{"function"==typeof e?e(n):e.current=n}catch(e){o.__e(e,t)}}function j(e,n,t){var r,l,u;if(o.unmount&&o.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||M(r,null,n)),t||"function"==typeof e.type||(t=null!=(l=e.__e)),e.__e=e.__d=null,null!=(r=e.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){o.__e(e,n)}r.base=r.__P=null}if(r=e.__k)for(u=0;u<r.length;u++)r[u]&&j(r[u],n,t);null!=l&&d(l)}function O(e,n,t){return this.constructor(e,t)}function W(e,n,t){var r,l,u;o.__&&o.__(e,n),l=(r=t===i)?null:t&&t.__k||n.__k,e=h(m,null,[e]),u=[],N(n,(r?n:t||n).__k=e,l||f,f,void 0!==n.ownerSVGElement,t&&!r?[t]:l?null:s.slice.call(n.childNodes),u,t||f,r),T(u,e)}function L(e,n){W(e,n,i)}function A(e,n){return n=a(a({},e.props),n),arguments.length>2&&(n.children=s.slice.call(arguments,2)),y(e.type,n,n.key||e.key,n.ref||e.ref)}function F(e){var n={},t={__c:"__cC"+c++,__:e,Consumer:function(e,n){return e.children(n)},Provider:function(e){var o,r=this;return this.getChildContext||(o=[],this.getChildContext=function(){return n[t.__c]=r,n},this.shouldComponentUpdate=function(n){e.value!==n.value&&o.some((function(e){e.context=n.value,x(e)}))},this.sub=function(e){o.push(e);var n=e.componentWillUnmount;e.componentWillUnmount=function(){o.splice(o.indexOf(e),1),n&&n.call(e)}}),e.children}};return t.Consumer.contextType=t,t}o={__e:function(e,n){for(var t,o;n=n.__;)if((t=n.__c)&&!t.__)try{if(t.constructor&&null!=t.constructor.getDerivedStateFromError&&(o=!0,t.setState(t.constructor.getDerivedStateFromError(e))),null!=t.componentDidCatch&&(o=!0,t.componentDidCatch(e)),o)return x(t.__E=t)}catch(n){e=n}throw e}},r=function(e){return null!=e&&void 0===e.constructor},g.prototype.setState=function(e,n){var t;t=this.__s!==this.state?this.__s:this.__s=a({},this.state),"function"==typeof e&&(e=e(t,this.props)),e&&a(t,e),null!=e&&this.__v&&(this.__e=!1,n&&this.__h.push(n),x(this))},g.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),x(this))},g.prototype.render=m,l=[],u="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,i=f,c=0,t.d(n,"render",(function(){return W})),t.d(n,"hydrate",(function(){return L})),t.d(n,"createElement",(function(){return h})),t.d(n,"h",(function(){return h})),t.d(n,"Fragment",(function(){return m})),t.d(n,"createRef",(function(){return v})),t.d(n,"isValidElement",(function(){return r})),t.d(n,"Component",(function(){return g})),t.d(n,"cloneElement",(function(){return A})),t.d(n,"createContext",(function(){return F})),t.d(n,"toChildArray",(function(){return S})),t.d(n,"_unmount",(function(){return j})),t.d(n,"options",(function(){return o}))}])}));