react-native-web-headroom
Version:
React Native Web Headroom
3 lines (2 loc) • 25.3 kB
JavaScript
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("preact"),require("glamor")):"function"==typeof define&&define.amd?define(["preact","glamor"],t):e.glamorous=t(e.preact,e.Glamor)}(this,function(e,t){"use strict";e=e&&e.hasOwnProperty("default")?e.default:e;var r=["a","abbr","acronym","address","applet","area","article","aside","audio","b","base","basefont","bdi","bdo","bgsound","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","command","content","data","datalist","dd","del","details","dfn","dialog","dir","div","dl","dt","element","em","embed","fieldset","figcaption","figure","font","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","image","img","input","ins","isindex","kbd","keygen","label","legend","li","link","listing","main","map","mark","marquee","math","menu","menuitem","meta","meter","multicol","nav","nextid","nobr","noembed","noframes","noscript","object","ol","optgroup","option","output","p","param","picture","plaintext","pre","progress","q","rb","rbc","rp","rt","rtc","ruby","s","samp","script","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","svg","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","tt","u","ul","var","video","wbr","xmp"].concat(["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","animation","audio","canvas","circle","clipPath","color-profile","cursor","defs","desc","discard","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","handler","hatch","hatchpath","hkern","iframe","image","line","linearGradient","listener","marker","mask","mesh","meshgradient","meshpatch","meshrow","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","prefetch","radialGradient","rect","script","set","solidColor","solidcolor","stop","style","svg","switch","symbol","tbreak","text","textArea","textPath","title","tref","tspan","unknown","use","video","view","vkern"]).filter(function(e,t,r){return r.indexOf(e)===t}),o="__glamorous__",n=void 0;if(e.PropTypes||(n=function(){return n},["array","bool","func","number","object","string","symbol","any","arrayOf","element","instanceOf","node","objectOf","oneOf","oneOfType","shape","exact"].forEach(function(e){n[e]=n})),!e.Children){var a={map:function(e,t,r){return null==e?null:(e=a.toArray(e),r&&r!==e&&(t=t.bind(r)),e.map(t))},forEach:function(e,t,r){if(null==e)return null;e=a.toArray(e),r&&r!==e&&(t=t.bind(r)),e.forEach(t)},count:function(e){return e&&e.length||0},only:function(e){if(1!==(e=a.toArray(e)).length)throw new Error("Children.only() expects only one child.");return e[0]},toArray:function(e){return null==e?[]:[].concat(e)}};e.Children=a}n=n||e.PropTypes;var i=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},l=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)},p=function(e,t){var r={};for(var o in e)t.indexOf(o)>=0||Object.prototype.hasOwnProperty.call(e,o)&&(r[o]=e[o]);return r},u=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t};function c(t){var r,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},p=a.noWarn,c=void 0!==p&&p,d=a.createElement,f=void 0===d||d,m=function(e){function r(){var t,o;i(this,r);for(var n=arguments.length,a=Array(n),s=0;s<n;s++)a[s]=arguments[s];return t=o=u(this,e.call.apply(e,[this].concat(a))),o.warned=c,o.state={theme:{}},o.setTheme=function(e){return o.setState({theme:e})},u(o,t)}return l(r,e),r.prototype.componentWillMount=function(){this.context[o];var e=this.props.theme;this.context[o]?this.setTheme(e||this.context[o].getState()):this.setTheme(e||{})},r.prototype.componentWillReceiveProps=function(e){this.props.theme!==e.theme&&this.setTheme(e.theme)},r.prototype.componentDidMount=function(){this.context[o]&&!this.props.theme&&(this.subscriptionId=this.context[o].subscribe(this.setTheme))},r.prototype.componentWillUnmount=function(){this.subscriptionId&&this.context[o].unsubscribe(this.subscriptionId)},r.prototype.render=function(){return f?h(t,s({},this.props,this.state)):t.call(this,s({},this.props,this.state),this.context)},r}(e.Component),g=((r={})[o]=n.object,r),y=null;return Object.defineProperty(m,"contextTypes",{enumerable:!0,configurable:!0,set:function(e){y=e},get:function(){return y?s({},g,y):g}}),m}var d=function(e){var t=f.call(e);return"[object Function]"===t||"function"==typeof e&&"[object RegExp]"!==t||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)},f=Object.prototype.toString;var m=function(e){return null!=e&&"object"==typeof e&&!1===Array.isArray(e)};function g(e){return!0===m(e)&&"[object Object]"===Object.prototype.toString.call(e)}var y,b;var v=function(t){function r(){var e,o;i(this,r);for(var n=arguments.length,a=Array(n),s=0;s<n;s++)a[s]=arguments[s];return e=o=u(this,t.call.apply(t,[this].concat(a))),o.setOuterTheme=function(e){o.outerTheme=e,void 0!==o.broadcast&&o.publishTheme()},u(o,e)}return l(r,t),r.prototype.getTheme=function(e){var t,r,o,n=e||this.props.theme;if(d(n)){var a=n(this.outerTheme);if(!1===g(t=a)||"function"!=typeof(r=t.constructor)||!1===g(o=r.prototype)||!1===o.hasOwnProperty("isPrototypeOf"))throw new Error("[ThemeProvider] Please return an object from your theme function, i.e. theme={() => ({})}!");return a}return s({},this.outerTheme,n)},r.prototype.getChildContext=function(){var e;return(e={})[o]=this.broadcast,e},r.prototype.publishTheme=function(e){this.broadcast.setState(this.getTheme(e))},r.prototype.componentDidMount=function(){this.context[o]&&(this.subscriptionId=this.context[o].subscribe(this.setOuterTheme))},r.prototype.componentWillMount=function(){var e,t,r,n;this.context[o]&&this.setOuterTheme(this.context[o].getState()),this.broadcast=(e=this.getTheme(this.props.theme),t={},r=1,n=e,{getState:function(){return n},setState:function(e){n=e;for(var r=Object.keys(t),o=0,a=r.length;o<a;o++)t[r[o]]&&t[r[o]](e)},subscribe:function(e){if("function"!=typeof e)throw new Error("listener must be a function.");var o=r;return t[o]=e,r+=1,o},unsubscribe:function(e){t[e]=void 0}})},r.prototype.componentWillReceiveProps=function(e){this.props.theme!==e.theme&&this.publishTheme(e.theme)},r.prototype.componentWillUnmount=function(){this.subscriptionId&&this.context[o].unsubscribe(this.subscriptionId)},r.prototype.render=function(){return this.props.children?e.Children.only(this.props.children):null},r}(e.Component);function C(e){var t=[],r=[];return e.toString().split(" ").forEach(function(e){if(0===e.indexOf("css-")){var o=((n={})["data-"+e]="",n);r.push(o)}else t.push(e);var n}),{glamorlessClassName:t,glamorStyles:r}}function x(e){var r=e.styles,o=e.props,n=e.cssOverrides,a=e.cssProp,i=e.context,s=(e.displayName,function e(t,r,o){var n=void 0;var a=[];var i=[];for(var s=0;s<t.length;s++){for(n=t[s];"function"==typeof n;)n=n(r,o);if("string"==typeof n){var l=C(n),p=l.glamorStyles,u=l.glamorlessClassName;a.push.apply(a,p),i.push.apply(i,u)}else if(Array.isArray(n)){var c=e(n,r,o);a.push.apply(a,c.mappedArgs),i.push.apply(i,c.nonGlamorClassNames)}else a.push(n)}return{mappedArgs:a,nonGlamorClassNames:i}}([].concat(r,[o.className,n,a]),o,i)),l=s.mappedArgs,p=s.nonGlamorClassNames;return(t.css.apply(void 0,[null].concat(l)).toString()+" "+p.join(" ").trim()).trim()}function w(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return Array.isArray(e)?e:[e]}function k(e,t){return e?e.concat(t):t}function O(e){return e.rootEl?e.rootEl:e.comp||e}function T(e,t,r,o){var n,a=null==(n=o)||"number"==typeof n||"boolean"==typeof n?o:r(o),i=t.get(a);return void 0===i&&(i=e.call(this,o),t.set(a,i)),i}function P(e,t,r){var o=Array.prototype.slice.call(arguments,3),n=r(o),a=t.get(n);return void 0===a&&(a=e.apply(this,o),t.set(n,a)),a}function S(e,t,r,o,n){return r.bind(t,e,o,n)}function E(e,t){return S(e,this,1===e.length?T:P,t.cache.create(),t.serializer)}function A(){return JSON.stringify(arguments)}function M(){this.cache=Object.create(null)}v.childContextTypes=((y={})[o]=n.object.isRequired,y),v.contextTypes=((b={})[o]=n.object,b),M.prototype.has=function(e){return e in this.cache},M.prototype.get=function(e){return this.cache[e]},M.prototype.set=function(e,t){this.cache[e]=t};var D={create:function(){return new M}},F=function(e,t){var r=t&&t.cache?t.cache:D,o=t&&t.serializer?t.serializer:A;return(t&&t.strategy?t.strategy:E)(e,{cache:r,serializer:o})},j={variadic:function(e,t){return S(e,this,P,t.cache.create(),t.serializer)},monadic:function(e,t){return S(e,this,T,t.cache.create(),t.serializer)}};F.strategies=j;var L,R,N=["coords","download","href","name","rel","shape","target","type"],z=["title"],I=["alt","height","name","width"],U=["alt","coords","download","href","rel","shape","target","type"],G=["controls","loop","muted","preload","src"],q=["href","target"],W=["size"],B=["dir"],_=["cite"],H=["disabled","form","name","type","value"],V=["height","width"],K=["span","width"],X=["span","width"],Y=["value"],Z=["cite"],J=["open"],$=["title"],Q=["open"],ee=["height","src","type","width"],te=["disabled","form","name"],re=["size"],oe=["accept","action","method","name","target"],ne=["name","scrolling","src"],ae=["cols","rows"],ie=["profile"],se=["size","width"],le=["manifest"],pe=["height","name","sandbox","scrolling","src","width"],ue=["alt","height","name","sizes","src","width"],ce=["accept","alt","autoCapitalize","autoCorrect","autoSave","checked","defaultChecked","defaultValue","disabled","form","height","list","max","min","multiple","name","onChange","pattern","placeholder","required","results","size","src","step","title","type","value","width"],de=["cite"],fe=["challenge","disabled","form","name"],he=["form"],me=["type","value"],ge=["color","href","integrity","media","nonce","rel","scope","sizes","target","title","type"],ye=["name"],be=["content","name"],ve=["high","low","max","min","optimum","value"],Ce=["data","form","height","name","type","width"],xe=["reversed","start","type"],we=["disabled","label"],ke=["disabled","label","selected","value"],Oe=["form","name"],Te=["name","type","value"],Pe=["width"],Se=["max","value"],Ee=["cite"],Ae=["async","defer","integrity","nonce","src","type"],Me=["defaultValue","disabled","form","multiple","name","onChange","required","size","value"],De=["name"],Fe=["media","sizes","src","type"],je=["media","nonce","title","type"],Le=["summary","width"],Re=["headers","height","scope","width"],Ne=["autoCapitalize","autoCorrect","cols","defaultValue","disabled","form","name","onChange","placeholder","required","rows","value","wrap"],ze=["headers","height","scope","width"],Ie=["default","kind","label","src"],Ue=["type"],Ge=["controls","height","loop","muted","playsInline","poster","preload","src","width"],qe=["accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baseProfile","baselineShift","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","color","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","height","horizAdvX","horizOriginX","ideographic","imageRendering","in","in2","intercept","k","k1","k2","k3","k4","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","points","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","scale","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","vHanging","vIdeographic","vMathematical","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","viewBox","viewTarget","visibility","width","widths","wordSpacing","writingMode","x","x1","x2","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlSpace","xmlns","xmlnsXlink","y","y1","y2","yChannelSelector","z","zoomAndPan"],We={html:["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","math","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rb","rp","rt","rtc","ruby","s","samp","script","section","select","slot","small","source","span","strong","style","sub","summary","sup","svg","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr"],svg:["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignObject","g","glyph","glyphRef","hkern","image","line","linearGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"]},Be={a:N,abbr:z,applet:I,area:U,audio:G,base:q,basefont:W,bdo:B,blockquote:_,button:H,canvas:V,col:K,colgroup:X,data:Y,del:Z,details:J,dfn:$,dialog:Q,embed:ee,fieldset:te,font:re,form:oe,frame:ne,frameset:ae,head:ie,hr:se,html:le,iframe:pe,img:ue,input:ce,ins:de,keygen:fe,label:he,li:me,link:ge,map:ye,meta:be,meter:ve,object:Ce,ol:xe,optgroup:we,option:ke,output:Oe,param:Te,pre:Pe,progress:Se,q:Ee,script:Ae,select:Me,slot:De,source:Fe,style:je,table:Le,td:Re,textarea:Ne,th:ze,track:Ie,ul:Ue,video:Ge,svg:qe,elements:We,"*":["about","acceptCharset","accessKey","allowFullScreen","allowTransparency","autoComplete","autoFocus","autoPlay","capture","cellPadding","cellSpacing","charSet","classID","className","colSpan","contentEditable","contextMenu","crossOrigin","dangerouslySetInnerHTML","datatype","dateTime","dir","draggable","encType","formAction","formEncType","formMethod","formNoValidate","formTarget","frameBorder","hidden","hrefLang","htmlFor","httpEquiv","icon","id","inlist","inputMode","is","itemID","itemProp","itemRef","itemScope","itemType","keyParams","keyType","lang","marginHeight","marginWidth","maxLength","mediaGroup","minLength","noValidate","prefix","property","radioGroup","readOnly","resource","role","rowSpan","scoped","seamless","security","spellCheck","srcDoc","srcLang","srcSet","style","suppressContentEditableWarning","tabIndex","title","typeof","unselectable","useMap","vocab","wmode"]},_e=Object.freeze({a:N,abbr:z,applet:I,area:U,audio:G,base:q,basefont:W,bdo:B,blockquote:_,button:H,canvas:V,col:K,colgroup:X,data:Y,del:Z,details:J,dfn:$,dialog:Q,embed:ee,fieldset:te,font:re,form:oe,frame:ne,frameset:ae,head:ie,hr:se,html:le,iframe:pe,img:ue,input:ce,ins:de,keygen:fe,label:he,li:me,link:ge,map:ye,meta:be,meter:ve,object:Ce,ol:xe,optgroup:we,option:ke,output:Oe,param:Te,pre:Pe,progress:Se,q:Ee,script:Ae,select:Me,slot:De,source:Fe,style:je,table:Le,td:Re,textarea:Ne,th:ze,track:Ie,ul:Ue,video:Ge,svg:qe,elements:We,default:Be}),He=_e&&Be||_e,Ve=(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=He,e.exports=He}(L={exports:{}},L.exports),L.exports),Ke=(R=Ve)&&R.__esModule&&Object.prototype.hasOwnProperty.call(R,"default")?R.default:R,Xe=["children","dangerouslySetInnerHTML","key","ref","autoFocus","defaultValue","valueLink","defaultChecked","checkedLink","innerHTML","suppressContentEditableWarning","onFocusIn","onFocusOut","className","onCopy","onCut","onPaste","onCompositionEnd","onCompositionStart","onCompositionUpdate","onKeyDown","onKeyPress","onKeyUp","onFocus","onBlur","onChange","onInput","onInvalid","onSubmit","onClick","onContextMenu","onDoubleClick","onDrag","onDragEnd","onDragEnter","onDragExit","onDragLeave","onDragOver","onDragStart","onDrop","onMouseDown","onMouseEnter","onMouseLeave","onMouseMove","onMouseOut","onMouseOver","onMouseUp","onSelect","onTouchCancel","onTouchEnd","onTouchMove","onTouchStart","onScroll","onWheel","onAbort","onCanPlay","onCanPlayThrough","onDurationChange","onEmptied","onEncrypted","onEnded","onError","onLoadedData","onLoadedMetadata","onLoadStart","onPause","onPlay","onPlaying","onProgress","onRateChange","onSeeked","onSeeking","onStalled","onSuspend","onTimeUpdate","onVolumeChange","onWaiting","onLoad","onAnimationStart","onAnimationEnd","onAnimationIteration","onTransitionEnd","onCopyCapture","onCutCapture","onPasteCapture","onCompositionEndCapture","onCompositionStartCapture","onCompositionUpdateCapture","onKeyDownCapture","onKeyPressCapture","onKeyUpCapture","onFocusCapture","onBlurCapture","onChangeCapture","onInputCapture","onSubmitCapture","onClickCapture","onContextMenuCapture","onDoubleClickCapture","onDragCapture","onDragEndCapture","onDragEnterCapture","onDragExitCapture","onDragLeaveCapture","onDragOverCapture","onDragStartCapture","onDropCapture","onMouseDownCapture","onMouseEnterCapture","onMouseLeaveCapture","onMouseMoveCapture","onMouseOutCapture","onMouseOverCapture","onMouseUpCapture","onSelectCapture","onTouchCancelCapture","onTouchEndCapture","onTouchMoveCapture","onTouchStartCapture","onScrollCapture","onWheelCapture","onAbortCapture","onCanPlayCapture","onCanPlayThroughCapture","onDurationChangeCapture","onEmptiedCapture","onEncryptedCapture","onEndedCapture","onErrorCapture","onLoadedDataCapture","onLoadedMetadataCapture","onLoadStartCapture","onPauseCapture","onPlayCapture","onPlayingCapture","onProgressCapture","onRateChangeCapture","onSeekedCapture","onSeekingCapture","onStalledCapture","onSuspendCapture","onTimeUpdateCapture","onVolumeChangeCapture","onWaitingCapture","onLoadCapture","onAnimationStartCapture","onAnimationEndCapture","onAnimationIterationCapture","onTransitionEndCapture"];Xe.push("autocomplete","autofocus","class","for","onDblClick","onSearch","slot","srcset");var Ye=Ke["*"],Ze=Ke.elements.svg,Je=Ke.elements.html,$e=["color","height","width"],Qe=RegExp.prototype.test.bind(new RegExp("^(data|aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$")),et=function(e){return"svg"===e||-1===Je.indexOf(e)&&-1!==Ze.indexOf(e)},tt=F(function(e,t){return"string"!=typeof e||(function(e,t){var r=void 0;return r=et(t)?Ke.svg:Ke[t]||[],-1!==Ye.indexOf(e)||-1!==r.indexOf(e)}(t,e)||function(e){return-1!==Xe.indexOf(e)}(t)||Qe(t.toLowerCase()))&&(!function(e){return-1!==$e.indexOf(e)}(t)||et(e))});var rt=function(t){return function r(o){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=n.rootEl,i=n.displayName,l=n.shouldClassNameUpdate,u=n.filterProps,d=void 0===u?[]:u,f=n.forwardProps,h=void 0===f?[]:f,m=n.propsAreCssOverrides,g=void 0===m?o.propsAreCssOverrides:m,y=n.withProps;return Object.assign(v,{withConfig:b}),v;function b(e){return r(o,s({},n,e))}function v(){for(var n=arguments.length,u=Array(n),f=0;f<n;f++)u[f]=arguments[f];var m=c(function(r,o){var n=function(e,t,r){if(!l)return!0;var o=!0;return r&&(l(r.props,e,r.context,t)||(o=!1)),o}(r=function e(t,r,o,n){return t.forEach(function(t){return"function"==typeof t?Object.assign(r,t(Object.assign({},r,o),n)):Array.isArray(t)?Object.assign(r,e(t,r,o,n)):Object.assign(r,t)}),Object.assign(r,o)}(m.propsToApply,{},r,o),o,this.previous);l&&(this.previous={props:r,context:o});var a=t(r,m),i=a.toForward,p=a.cssOverrides,u=a.cssProp;return this.className=n?x({styles:m.styles,props:r,cssOverrides:p,cssProp:u,context:o,displayName:m.displayName}):this.className,e.createElement(m.comp,s({ref:"innerRef"in i?void 0:r.innerRef},i,{className:this.className}))},{noWarn:!0,createElement:!1});return Object.assign(m,function(e){var t=e.comp,r=e.styles,o=e.rootEl,n=e.filterProps,a=e.forwardProps,i=e.displayName,s=e.propsToApply,l=t.comp?t.comp:t,p=t.propsToApply?[].concat(t.propsToApply,w(s)):w(s);return{styles:k(t.styles,r),comp:l,rootEl:o||O(t),forwardProps:k(t.forwardProps,a),filterProps:k(t.filterProps,n),displayName:i||"glamorous("+function(e){return"string"==typeof e?e:e.displayName||e.name||"unknown"}(t)+")",propsToApply:p}}({comp:o,styles:u,rootEl:a,filterProps:d,forwardProps:h,displayName:i,propsToApply:y}),{isGlamorousComponent:!0,propsAreCssOverrides:g,withComponent:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=m.forwardProps,n=m.filterProps,a=p(m,["forwardProps","filterProps"]);return r(s({},a,{comp:e,rootEl:O(e)}),s({forwardProps:o,filterProps:n},t))()},withProps:function(){for(var e=arguments.length,t=Array(e),o=0;o<e;o++)t[o]=arguments[o];return r(m,{withProps:t})()},withConfig:b}),m}}}(function(e,t){var r=t.propsAreCssOverrides,o=t.rootEl,n=t.filterProps,a=t.forwardProps,i=e.css,s=e.innerRef,l=(e.theme,e.className,e.glam,p(e,["css","innerRef","theme","className","glam"]));void 0!==s&&-1!==a.indexOf("innerRef")&&(l.innerRef=s);var u={toForward:{},cssProp:i,cssOverrides:{}};return r||"string"==typeof o||0!==n.length?Object.keys(l).reduce(function(e,t){return-1!==n.indexOf(t)?e:(-1!==a.indexOf(t)||tt(o,t)?e.toForward[t]=l[t]:r&&(e.cssOverrides[t]=l[t]),e)},u):(u.toForward=l,u)});Object.assign(rt,r.reduce(function(e,t){return e[t]=rt(t),e},{})),Object.assign(rt,r.reduce(function(e,t){var r,o=(r=t).slice(0,1).toUpperCase()+r.slice(1);return e[o]=rt[t](),e[o].displayName="glamorous."+o,e[o].propsAreCssOverrides=!0,e},{})),rt.default=rt;var ot=Object.freeze({default:rt,ThemeProvider:v,withTheme:c}),nt=rt;return Object.assign(nt,Object.keys(ot).reduce(function(e,t){return"default"!==t&&(e[t]=ot[t]),e},{})),nt});
//# sourceMappingURL=glamorous.umd.min.js.map