Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-awesome-skeleton

Package Overview
Dependencies
Maintainers
1
Versions
26
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-awesome-skeleton - npm Package Compare versions

Comparing version 0.0.24 to 0.0.25

dist/example/index.d.ts

4

dist/index.js

@@ -14,3 +14,3 @@ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("SkeletonPlugin",[],t):"object"==typeof exports?exports.SkeletonPlugin=t():e.SkeletonPlugin=t()}(window,(function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="/",r(r.s=2)}([function(e,t,r){"use strict";e.exports=r(3)},function(e,t,r){var n;

* LICENSE file in the root directory of this source tree.
*/var n=r(4),o="function"==typeof Symbol&&Symbol.for,u=o?Symbol.for("react.element"):60103,i=o?Symbol.for("react.portal"):60106,c=o?Symbol.for("react.fragment"):60107,l=o?Symbol.for("react.strict_mode"):60108,a=o?Symbol.for("react.profiler"):60114,s=o?Symbol.for("react.provider"):60109,f=o?Symbol.for("react.context"):60110,p=o?Symbol.for("react.forward_ref"):60112,y=o?Symbol.for("react.suspense"):60113;o&&Symbol.for("react.suspense_list");var d=o?Symbol.for("react.memo"):60115,m=o?Symbol.for("react.lazy"):60116;o&&Symbol.for("react.fundamental"),o&&Symbol.for("react.responder"),o&&Symbol.for("react.scope");var h="function"==typeof Symbol&&Symbol.iterator;function b(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var v={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g={};function j(e,t,r){this.props=e,this.context=t,this.refs=g,this.updater=r||v}function S(){}function O(e,t,r){this.props=e,this.context=t,this.refs=g,this.updater=r||v}j.prototype.isReactComponent={},j.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error(b(85));this.updater.enqueueSetState(this,e,t,"setState")},j.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},S.prototype=j.prototype;var w=O.prototype=new S;w.constructor=O,n(w,j.prototype),w.isPureReactComponent=!0;var x={current:null},_={current:null},k=Object.prototype.hasOwnProperty,C={key:!0,ref:!0,__self:!0,__source:!0};function $(e,t,r){var n,o={},i=null,c=null;if(null!=t)for(n in void 0!==t.ref&&(c=t.ref),void 0!==t.key&&(i=""+t.key),t)k.call(t,n)&&!C.hasOwnProperty(n)&&(o[n]=t[n]);var l=arguments.length-2;if(1===l)o.children=r;else if(1<l){for(var a=Array(l),s=0;s<l;s++)a[s]=arguments[s+2];o.children=a}if(e&&e.defaultProps)for(n in l=e.defaultProps)void 0===o[n]&&(o[n]=l[n]);return{$$typeof:u,type:e,key:i,ref:c,props:o,_owner:_.current}}function E(e){return"object"==typeof e&&null!==e&&e.$$typeof===u}var P=/\/+/g,R=[];function A(e,t,r,n){if(R.length){var o=R.pop();return o.result=e,o.keyPrefix=t,o.func=r,o.context=n,o.count=0,o}return{result:e,keyPrefix:t,func:r,context:n,count:0}}function N(e){e.result=null,e.keyPrefix=null,e.func=null,e.context=null,e.count=0,10>R.length&&R.push(e)}function q(e,t,r){return null==e?0:function e(t,r,n,o){var c=typeof t;"undefined"!==c&&"boolean"!==c||(t=null);var l=!1;if(null===t)l=!0;else switch(c){case"string":case"number":l=!0;break;case"object":switch(t.$$typeof){case u:case i:l=!0}}if(l)return n(o,t,""===r?"."+M(t,0):r),1;if(l=0,r=""===r?".":r+":",Array.isArray(t))for(var a=0;a<t.length;a++){var s=r+M(c=t[a],a);l+=e(c,s,n,o)}else if(null===t||"object"!=typeof t?s=null:s="function"==typeof(s=h&&t[h]||t["@@iterator"])?s:null,"function"==typeof s)for(t=s.call(t),a=0;!(c=t.next()).done;)l+=e(c=c.value,s=r+M(c,a++),n,o);else if("object"===c)throw n=""+t,Error(b(31,"[object Object]"===n?"object with keys {"+Object.keys(t).join(", ")+"}":n,""));return l}(e,"",t,r)}function M(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+(""+e).replace(/[=:]/g,(function(e){return t[e]}))}(e.key):t.toString(36)}function I(e,t){e.func.call(e.context,t,e.count++)}function U(e,t,r){var n=e.result,o=e.keyPrefix;e=e.func.call(e.context,t,e.count++),Array.isArray(e)?T(e,n,r,(function(e){return e})):null!=e&&(E(e)&&(e=function(e,t){return{$$typeof:u,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(e,o+(!e.key||t&&t.key===e.key?"":(""+e.key).replace(P,"$&/")+"/")+r)),n.push(e))}function T(e,t,r,n,o){var u="";null!=r&&(u=(""+r).replace(P,"$&/")+"/"),q(e,U,t=A(t,u,n,o)),N(t)}function F(){var e=x.current;if(null===e)throw Error(b(321));return e}var L={Children:{map:function(e,t,r){if(null==e)return e;var n=[];return T(e,n,null,t,r),n},forEach:function(e,t,r){if(null==e)return e;q(e,I,t=A(null,null,t,r)),N(t)},count:function(e){return q(e,(function(){return null}),null)},toArray:function(e){var t=[];return T(e,t,null,(function(e){return e})),t},only:function(e){if(!E(e))throw Error(b(143));return e}},createRef:function(){return{current:null}},Component:j,PureComponent:O,createContext:function(e,t){return void 0===t&&(t=null),(e={$$typeof:f,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},forwardRef:function(e){return{$$typeof:p,render:e}},lazy:function(e){return{$$typeof:m,_ctor:e,_status:-1,_result:null}},memo:function(e,t){return{$$typeof:d,type:e,compare:void 0===t?null:t}},useCallback:function(e,t){return F().useCallback(e,t)},useContext:function(e,t){return F().useContext(e,t)},useEffect:function(e,t){return F().useEffect(e,t)},useImperativeHandle:function(e,t,r){return F().useImperativeHandle(e,t,r)},useDebugValue:function(){},useLayoutEffect:function(e,t){return F().useLayoutEffect(e,t)},useMemo:function(e,t){return F().useMemo(e,t)},useReducer:function(e,t,r){return F().useReducer(e,t,r)},useRef:function(e){return F().useRef(e)},useState:function(e){return F().useState(e)},Fragment:c,Profiler:a,StrictMode:l,Suspense:y,createElement:$,cloneElement:function(e,t,r){if(null==e)throw Error(b(267,e));var o=n({},e.props),i=e.key,c=e.ref,l=e._owner;if(null!=t){if(void 0!==t.ref&&(c=t.ref,l=_.current),void 0!==t.key&&(i=""+t.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(s in t)k.call(t,s)&&!C.hasOwnProperty(s)&&(o[s]=void 0===t[s]&&void 0!==a?a[s]:t[s])}var s=arguments.length-2;if(1===s)o.children=r;else if(1<s){a=Array(s);for(var f=0;f<s;f++)a[f]=arguments[f+2];o.children=a}return{$$typeof:u,type:e.type,key:i,ref:c,props:o,_owner:l}},createFactory:function(e){var t=$.bind(null,e);return t.type=e,t},isValidElement:E,version:"16.11.0",__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactCurrentDispatcher:x,ReactCurrentBatchConfig:{suspense:null},ReactCurrentOwner:_,IsSomeRendererActing:{current:!1},assign:n}},z={default:L},D=z&&L||z;e.exports=D.default||D},function(e,t,r){"use strict";
*/var n=r(4),o="function"==typeof Symbol&&Symbol.for,u=o?Symbol.for("react.element"):60103,i=o?Symbol.for("react.portal"):60106,c=o?Symbol.for("react.fragment"):60107,l=o?Symbol.for("react.strict_mode"):60108,a=o?Symbol.for("react.profiler"):60114,s=o?Symbol.for("react.provider"):60109,f=o?Symbol.for("react.context"):60110,p=o?Symbol.for("react.forward_ref"):60112,y=o?Symbol.for("react.suspense"):60113;o&&Symbol.for("react.suspense_list");var d=o?Symbol.for("react.memo"):60115,m=o?Symbol.for("react.lazy"):60116;o&&Symbol.for("react.fundamental"),o&&Symbol.for("react.responder"),o&&Symbol.for("react.scope");var h="function"==typeof Symbol&&Symbol.iterator;function b(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var v={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g={};function j(e,t,r){this.props=e,this.context=t,this.refs=g,this.updater=r||v}function O(){}function S(e,t,r){this.props=e,this.context=t,this.refs=g,this.updater=r||v}j.prototype.isReactComponent={},j.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error(b(85));this.updater.enqueueSetState(this,e,t,"setState")},j.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},O.prototype=j.prototype;var w=S.prototype=new O;w.constructor=S,n(w,j.prototype),w.isPureReactComponent=!0;var x={current:null},_={current:null},k=Object.prototype.hasOwnProperty,C={key:!0,ref:!0,__self:!0,__source:!0};function $(e,t,r){var n,o={},i=null,c=null;if(null!=t)for(n in void 0!==t.ref&&(c=t.ref),void 0!==t.key&&(i=""+t.key),t)k.call(t,n)&&!C.hasOwnProperty(n)&&(o[n]=t[n]);var l=arguments.length-2;if(1===l)o.children=r;else if(1<l){for(var a=Array(l),s=0;s<l;s++)a[s]=arguments[s+2];o.children=a}if(e&&e.defaultProps)for(n in l=e.defaultProps)void 0===o[n]&&(o[n]=l[n]);return{$$typeof:u,type:e,key:i,ref:c,props:o,_owner:_.current}}function E(e){return"object"==typeof e&&null!==e&&e.$$typeof===u}var P=/\/+/g,R=[];function A(e,t,r,n){if(R.length){var o=R.pop();return o.result=e,o.keyPrefix=t,o.func=r,o.context=n,o.count=0,o}return{result:e,keyPrefix:t,func:r,context:n,count:0}}function N(e){e.result=null,e.keyPrefix=null,e.func=null,e.context=null,e.count=0,10>R.length&&R.push(e)}function q(e,t,r){return null==e?0:function e(t,r,n,o){var c=typeof t;"undefined"!==c&&"boolean"!==c||(t=null);var l=!1;if(null===t)l=!0;else switch(c){case"string":case"number":l=!0;break;case"object":switch(t.$$typeof){case u:case i:l=!0}}if(l)return n(o,t,""===r?"."+M(t,0):r),1;if(l=0,r=""===r?".":r+":",Array.isArray(t))for(var a=0;a<t.length;a++){var s=r+M(c=t[a],a);l+=e(c,s,n,o)}else if(null===t||"object"!=typeof t?s=null:s="function"==typeof(s=h&&t[h]||t["@@iterator"])?s:null,"function"==typeof s)for(t=s.call(t),a=0;!(c=t.next()).done;)l+=e(c=c.value,s=r+M(c,a++),n,o);else if("object"===c)throw n=""+t,Error(b(31,"[object Object]"===n?"object with keys {"+Object.keys(t).join(", ")+"}":n,""));return l}(e,"",t,r)}function M(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+(""+e).replace(/[=:]/g,(function(e){return t[e]}))}(e.key):t.toString(36)}function I(e,t){e.func.call(e.context,t,e.count++)}function U(e,t,r){var n=e.result,o=e.keyPrefix;e=e.func.call(e.context,t,e.count++),Array.isArray(e)?T(e,n,r,(function(e){return e})):null!=e&&(E(e)&&(e=function(e,t){return{$$typeof:u,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(e,o+(!e.key||t&&t.key===e.key?"":(""+e.key).replace(P,"$&/")+"/")+r)),n.push(e))}function T(e,t,r,n,o){var u="";null!=r&&(u=(""+r).replace(P,"$&/")+"/"),q(e,U,t=A(t,u,n,o)),N(t)}function F(){var e=x.current;if(null===e)throw Error(b(321));return e}var L={Children:{map:function(e,t,r){if(null==e)return e;var n=[];return T(e,n,null,t,r),n},forEach:function(e,t,r){if(null==e)return e;q(e,I,t=A(null,null,t,r)),N(t)},count:function(e){return q(e,(function(){return null}),null)},toArray:function(e){var t=[];return T(e,t,null,(function(e){return e})),t},only:function(e){if(!E(e))throw Error(b(143));return e}},createRef:function(){return{current:null}},Component:j,PureComponent:S,createContext:function(e,t){return void 0===t&&(t=null),(e={$$typeof:f,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},forwardRef:function(e){return{$$typeof:p,render:e}},lazy:function(e){return{$$typeof:m,_ctor:e,_status:-1,_result:null}},memo:function(e,t){return{$$typeof:d,type:e,compare:void 0===t?null:t}},useCallback:function(e,t){return F().useCallback(e,t)},useContext:function(e,t){return F().useContext(e,t)},useEffect:function(e,t){return F().useEffect(e,t)},useImperativeHandle:function(e,t,r){return F().useImperativeHandle(e,t,r)},useDebugValue:function(){},useLayoutEffect:function(e,t){return F().useLayoutEffect(e,t)},useMemo:function(e,t){return F().useMemo(e,t)},useReducer:function(e,t,r){return F().useReducer(e,t,r)},useRef:function(e){return F().useRef(e)},useState:function(e){return F().useState(e)},Fragment:c,Profiler:a,StrictMode:l,Suspense:y,createElement:$,cloneElement:function(e,t,r){if(null==e)throw Error(b(267,e));var o=n({},e.props),i=e.key,c=e.ref,l=e._owner;if(null!=t){if(void 0!==t.ref&&(c=t.ref,l=_.current),void 0!==t.key&&(i=""+t.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(s in t)k.call(t,s)&&!C.hasOwnProperty(s)&&(o[s]=void 0===t[s]&&void 0!==a?a[s]:t[s])}var s=arguments.length-2;if(1===s)o.children=r;else if(1<s){a=Array(s);for(var f=0;f<s;f++)a[f]=arguments[f+2];o.children=a}return{$$typeof:u,type:e.type,key:i,ref:c,props:o,_owner:l}},createFactory:function(e){var t=$.bind(null,e);return t.type=e,t},isValidElement:E,version:"16.11.0",__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactCurrentDispatcher:x,ReactCurrentBatchConfig:{suspense:null},ReactCurrentOwner:_,IsSomeRendererActing:{current:!1},assign:n}},z={default:L},D=z&&L||z;e.exports=D.default||D},function(e,t,r){"use strict";
/*

@@ -20,3 +20,3 @@ object-assign

@license MIT
*/var n=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable;function i(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var r,c,l=i(e),a=1;a<arguments.length;a++){for(var s in r=Object(arguments[a]))o.call(r,s)&&(l[s]=r[s]);if(n){c=n(r);for(var f=0;f<c.length;f++)u.call(r,c[f])&&(l[c[f]]=r[c[f]])}}return l}},function(e,t,r){},function(e,t,r){"use strict";r.r(t);var n=r(0),o=(r(5),r(1)),u=r.n(o);class i extends n.Component{constructor(){super(...arguments),this.getWidth=e=>{const{width:t,rows:r=2}=this.props;return Array.isArray(t)?t[e]:r-1===e?t:void 0}}render(){const{rows:e,className:t,style:r,prefixCls:o}=this.props,i=[...Array(e)].map((e,t)=>n.createElement("li",{key:t,style:{width:this.getWidth(t)}}));return n.createElement("ul",{className:u()(o,t),style:r},i)}}var c=i;var l=({className:e,width:t,style:r,prefixCls:o})=>n.createElement("h3",{className:u()(o,e),style:Object.assign({width:t},r)});class a extends n.Component{render(){const{prefixCls:e,className:t,style:r,size:o,shape:i,order:c}=this.props,l=u()({[`${e}-lg`]:"large"===o,[`${e}-sm`]:"small"===o}),a=u()({[`${e}-circle`]:"circle"===i,[`${e}-square`]:"square"===i}),s="number"==typeof o?{width:o,height:o,lineHeight:`${o}px`}:{},f={order:c};return n.createElement("span",{className:u()(e,t,l,a),style:Object.assign(Object.assign(Object.assign({},s),r),f)})}}a.defaultProps={size:"large",order:0};var s=a;const f=n.createContext(null).Consumer;function p(e){return e&&"object"==typeof e?e:{}}class y extends n.Component{constructor(){super(...arguments),this.renderSkeleton=()=>{const{prefixCls:e="homework-skeleton",active:t,title:r,paragraph:o,avatar:i,className:a,children:f,loading:y}=this.props;if(y||!("loading"in this.props)){const f=!!i,y=!!r,d=!!o;let m,h;if(f){const t=Object.assign(Object.assign({prefixCls:`${e}-avatar`},function(e,t){return e&&!t?{shape:"square"}:{shape:"circle"}}(y,d)),p(i));m=n.createElement(s,Object.assign({},t))}if(y||d){let t,u;if(y){const o=Object.assign(Object.assign({prefixCls:`${e}-title`},function(e,t){let r={};return e&&t&&(r.width="50%"),!e&&t&&(r.width="35%"),r}(f,d)),p(r));t=n.createElement(l,Object.assign({},o))}if(d){const t=Object.assign(Object.assign({prefixCls:`${e}-paragraph`},function(e,t){let r={};return e&&t||(r.width="65%"),r.rows=!e&&t?3:2,r}(f,y)),p(o));u=n.createElement(c,Object.assign({},t))}h=n.createElement("div",{className:`${e}-content`},t,u)}const b=u()(e,a,{[`${e}-with-avatar`]:f,[`${e}-active`]:t});return n.createElement("div",{className:b},m,h)}return f}}render(){return n.createElement(f,null,this.renderSkeleton)}}y.defaultProps={avatar:!1,title:!0,paragraph:!0};var d=y;r.d(t,"Skeleton",(function(){return d}))}])}));
*/var n=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable;function i(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var r,c,l=i(e),a=1;a<arguments.length;a++){for(var s in r=Object(arguments[a]))o.call(r,s)&&(l[s]=r[s]);if(n){c=n(r);for(var f=0;f<c.length;f++)u.call(r,c[f])&&(l[c[f]]=r[c[f]])}}return l}},function(e,t,r){},function(e,t,r){"use strict";r.r(t);var n=r(0),o=(r(5),r(1)),u=r.n(o);class i extends n.Component{constructor(){super(...arguments),this.getWidth=e=>{const{width:t,rows:r=2}=this.props;return Array.isArray(t)?t[e]:r-1===e?t:void 0}}render(){const{rows:e,className:t,style:r,prefixCls:o}=this.props,i=[...Array(e)].map((e,t)=>n.createElement("li",{key:t,style:{width:this.getWidth(t)}}));return n.createElement("ul",{className:u()(o,t),style:r},i)}}var c=i;var l=({className:e,width:t,style:r,prefixCls:o})=>n.createElement("h3",{className:u()(o,e),style:Object.assign({width:t},r)});class a extends n.Component{render(){const{prefixCls:e,className:t,style:r,size:o,shape:i,order:c}=this.props,l=u()({[`${e}-lg`]:"large"===o,[`${e}-sm`]:"small"===o}),a=u()({[`${e}-circle`]:"circle"===i,[`${e}-square`]:"square"===i}),s="number"==typeof o?{width:o,height:o,lineHeight:`${o}px`}:{},f={order:c};return n.createElement("span",{className:u()(e,t,l,a),style:Object.assign(Object.assign(Object.assign({},s),r),f)})}}a.defaultProps={size:"large",order:0};var s=a;const f=n.createContext(null).Consumer;function p(e){return e&&"object"==typeof e?e:{}}class y extends n.Component{constructor(){super(...arguments),this.renderSkeleton=()=>{const{prefixCls:e="homework-skeleton",active:t,title:r,paragraph:o,avatar:i,className:a,children:f,loading:y}=this.props;if(y||!("loading"in this.props)){const f=!!i,y=!!r,d=!!o;let m,h;if(f){const t=Object.assign(Object.assign({prefixCls:`${e}-avatar`},function(e,t){return e&&!t?{shape:"square"}:{shape:"circle"}}(y,d)),p(i));m=n.createElement(s,Object.assign({},t))}if(y||d){let t,u;if(y){const o=Object.assign(Object.assign({prefixCls:`${e}-title`},function(e,t){let r={};return e&&t&&(r.width="50%"),!e&&t&&(r.width="35%"),r}(f,d)),p(r));t=n.createElement(l,Object.assign({},o))}if(d){const t=Object.assign(Object.assign({prefixCls:`${e}-paragraph`},function(e,t){let r={};return e&&t||(r.width="65%"),r.rows=!e&&t?3:2,r}(f,y)),p(o));u=n.createElement(c,Object.assign({},t))}h=n.createElement("div",{className:`${e}-content`},t,u)}const b=u()(e,a,{[`${e}-with-avatar`]:f,[`${e}-active`]:t});return n.createElement("div",{className:b},m,h)}return f}}render(){return n.createElement(f,null,this.renderSkeleton)}}y.defaultProps={avatar:!1,title:!0,paragraph:!0};var d=y;t.default=d}])}));
//# sourceMappingURL=index.js.map
{
"name": "react-awesome-skeleton",
"version": "0.0.24",
"version": "0.0.25",
"description": " better loading effect",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc