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

@progress/kendo-react-layout

Package Overview
Dependencies
Maintainers
1
Versions
1234
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@progress/kendo-react-layout - npm Package Compare versions

Comparing version 0.2.0-dev.201801231552 to 0.2.0

2

dist/systemjs/kendo-react-layout.js

@@ -1,1 +0,1 @@

System.register("@progress/kendo-react-layout",["react","prop-types","classnames","@progress/kendo-react-animation"],function(e){var t,n,r,o;function i(e){return e.__useDefault?e.default:e}return{setters:[function(e){t=i(e)},function(e){n=i(e)},function(e){r=i(e)},function(e){o=i(e)}],execute:function(){!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}n.m=e,n.c=t,n.p="",n(0)}([function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=r(1);n.TabStrip=o.default;var i=r(7);n.TabStripContent=i.default;var a=r(4);n.TabStripNavigation=a.default;var s=r(5);n.TabStripNavigationItem=s.default;var l=r(9);n.TabStripTab=l.default;var c=r(10);n.PanelBar=c.default;var p=r(11);n.PanelBarItem=p.default;var d=r(12);n.PanelBarUtils=d.default,function(t){for(var n in t)e(n,t[n])}(n)},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(4),c=n(7),p=n(6),d=function(e){function t(){var t,n=null!==e&&e.apply(this,arguments)||this;return n._element=null,n.keyBinding=((t={})[37]=function(){return n.prevNavigatableTab()},t[39]=function(){return n.nextNavigatableTab()},t[40]=function(){return n.nextNavigatableTab()},t[38]=function(){return n.prevNavigatableTab()},t[36]=function(){return 0},t[35]=function(){return a.Children.count(n.props.children)-1},t),n.onSelect=function(e){n.props.selected!==e&&n.props.onSelect&&n.props.onSelect({selected:e})},n.onKeyDown=function(e){var t;switch(9!==e.keyCode&&e.preventDefault(),e.keyCode){case 37:t=n.keyBinding[n.invertKeys(37,39)];break;case 39:t=n.keyBinding[n.invertKeys(39,37)];break;case 38:t=n.keyBinding[38];break;case 40:t=n.keyBinding[40]}t&&n.onSelect(t())},n.firstNavigatableTab=function(){var e=n.props.children,t=a.Children.count(e);if(e)for(var r=0;r<t;r++)if(!e[r].props.disabled)return r},n.lastNavigatableTab=function(){var e=n.props.children,t=a.Children.count(e);if(e)for(var r=t-1;r>0;r--)if(!e[r].props.disabled)return r},n.prevNavigatableTab=function(){var e=n.props,t=e.children,r=e.selected,o=r?r-1:-1;if(o<0)return n.lastNavigatableTab();if(t)for(var i=o;i>-1;i--){if(!t[i].props.disabled)return i;if(0===i)return n.lastNavigatableTab()}},n.nextNavigatableTab=function(){var e=n.props,t=e.children,r=e.selected,o=r?r+1:1,i=a.Children.count(t);if(o>=i)return n.firstNavigatableTab();if(t)for(var s=o;s<i;s++){if(!t[s].props.disabled)return s;if(s+1===i)return n.firstNavigatableTab()}},n.renderContent=function(e){var t=n.props,r=t.selected,o=t.children,s=t.tabContentStyle;return r<a.Children.count(o)&&r>-1?a.createElement(c.default,i({index:r},e,{style:s})):null},n}return o(t,e),t.prototype.render=function(){var e,t=this,n=i({},this.props,{selected:this.props.selected,onSelect:this.onSelect}),r=n.tabPosition,o=n.tabIndex,s=void 0===o?0:o,c="bottom"===r,d=p(((e={})["k-widget"]=!0,e["k-header"]=!0,e["k-floatwrap"]=!0,e["k-tabstrip"]=!0,e["k-tabstrip-left"]="left"===r,e["k-tabstrip-right"]="right"===r,e["k-tabstrip-bottom"]="bottom"===r,e["k-tabstrip-top"]="top"===r,e));return a.createElement("div",{ref:function(e){t._element=e},dir:this.props.dir,className:d,onKeyDown:this.onKeyDown,style:this.props.style},!c&&a.createElement(l.default,i({},n,{tabIndex:s})),this.renderContent(n),c&&a.createElement(l.default,i({},n,{tabIndex:s})))},t.prototype.invertKeys=function(e,t){return this._element&&"rtl"===getComputedStyle(this._element).direction||!1?t:e},t}(a.Component);d.propTypes={animation:s.bool,children:s.oneOfType([s.element,s.arrayOf(s.element)]),onSelect:s.func,selected:s.number,style:s.object,tabContentStyle:s.object,tabPosition:s.string,tabIndex:s.number,dir:s.string},d.defaultProps={animation:!0,tabPosition:"top"},t.default=d},function(e,n){e.exports=t},function(e,t){e.exports=n},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(5),c=n(6),p=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.render=function(){var e,t,n=this.props,r=n.selected,o=n.children,s=n.onSelect,p=a.Children.count(o);o&&(e=(t=p,Array.apply(null,Array(t))).map(function(e,t,n){return{first:0===t,last:t===n.length-1}}).map(function(e,t){var n={active:r===t,disabled:o[t].props.disabled,index:t,title:o[t].props.title,onSelect:s};return a.createElement(l.default,i({key:t},n))}));var d=c("k-tabstrip-items","k-reset");return a.createElement("ul",{className:d,role:"tablist",tabIndex:this.props.tabIndex},e)},t}(a.Component);p.propTypes={children:s.oneOfType([s.element,s.arrayOf(s.element)]),onSelect:s.func,selected:s.number,tabIndex:s.number},t.default=p},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(6),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.onClick=function(){t.props.onSelect&&t.props.onSelect(t.props.index)},t}return o(t,e),t.prototype.render=function(){var e,t=this.props,n=t.active,r=t.disabled,o=t.title,s=void 0===o?"Untitled":o,c={"aria-selected":n,role:"tab",onClick:r?void 0:this.onClick},p=l(((e={})["k-item"]=!0,e["k-state-default"]=!(r||n),e["k-state-disabled"]=r,e["k-state-active"]=n,e["k-tab-on-top"]=n,e));return a.createElement("li",i({},c,{className:p}),a.createElement("span",{className:"k-link"},s))},t}(a.Component);c.propTypes={active:s.bool,disabled:s.bool,index:s.number,onSelect:s.func,title:s.oneOfType([s.string,s.element])},t.default=c},function(e,t){e.exports=r},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(8),c=n(6),p=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.renderContent=function(e){var t={role:"tabpanel","aria-expanded":"true"},n=a.Children.toArray(e)[this.props.selected];return this.props.animation?a.createElement(l.Fade,{style:{position:"initial"},appear:!0},a.createElement("div",i({},t,{key:this.props.index}),n.props.children)):a.createElement("div",i({},t,{key:this.props.index}),n.props.children)},t.prototype.render=function(){var e=c("k-content","k-state-active");return a.createElement("div",{className:e,style:this.props.style},this.renderContent(this.props.children))},t}(a.Component);p.propTypes={animation:s.bool,children:s.oneOfType([s.element,s.arrayOf(s.element)]),selected:s.number,style:s.object},t.default=p},function(e,t){e.exports=o},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var i=n(2),a=n(3),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t}(i.Component);s.propTypes={disabled:a.bool,children:a.oneOfType([a.element,a.node]),title:a.oneOfType([a.string,a.element,a.node])},t.default=s},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(11),c=n(12),p=n(13),d=n(14),u=function(e){function t(t){var n=e.call(this,t)||this;return n._element=null,n.handleSelect=function(e){n._selectionService.select(e.uniquePrivateKey,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children),n.state.expanded),n._selectionService.focus(e.uniquePrivateKey,0,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children))},n.onSelect=function(e,t){n.setState({selected:e.props.uniquePrivateKey,expanded:t},function(){n.props.onSelect&&n.props.onSelect.call(void 0,{target:e,action:"select"})})},n.onFocus=function(e){n.activeDescendant=e.props.id,n.setState({focused:e.props.uniquePrivateKey})},n.handleWrapperFocus=function(e){n.setState({wrapperFocused:"focus"===e.nativeEvent.type})},n.handleKeyDown=function(e){9!==e.keyCode&&e.preventDefault();var t=n._element&&"rtl"===getComputedStyle(n._element).direction||!1;n._navigationService.navigate(e,t)},n.onNavigate=function(e){switch(e){case d.NavigationAction.Previous:n._selectionService.focus(n.state.focused,-1,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children));break;case d.NavigationAction.Next:n._selectionService.focus(n.state.focused,1,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children));break;case d.NavigationAction.Toggle:n._selectionService.select(n.state.focused,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children),n.state.expanded)}},n.state=c.getInitialState(t,t.expandMode||"multiple"),n._selectionService=new p.default(n.onSelect,n.onFocus,n.props.expandMode||"multiple"),n._navigationService=new d.default(n.onNavigate),n}return o(t,e),t.prototype.componentWillReceiveProps=function(e){e.expandMode!==this.props.expandMode&&this._selectionService.setExpandMode(e.expandMode),e.selected!==this.state.selected&&void 0!==e.selected&&this.setState({selected:e.selected})},t.prototype.render=function(){var e=this,t={"aria-activedescendant":this.activeDescendant},n=c.renderChildren(this.props.animation,this.state,this.handleSelect,this.props.children);return a.createElement("div",i({ref:function(t){e._element=t},dir:this.props.dir,role:"tree",tabIndex:0,onKeyDown:this.handleKeyDown,onFocus:this.handleWrapperFocus,onBlur:this.handleWrapperFocus,className:"k-widget k-panelbar k-reset k-header"},t),n)},t}(a.Component);u.propTypes={animation:s.bool,children:function(e,t){var n=e[t];if(n)if(n instanceof Array)for(var r=0,o=n;r<o.length;r++){var i=o[r];if(!i.type||i.type!==l.default)return new Error("PanelBar children should be either PanelBarItem or Array of PanelBarItem.")}else if(n.type!==l.default)return new Error("PanelBar child should be either PanelBarItem or Array of PanelBarItem.")},dir:s.string,selected:s.string,expanded:s.arrayOf(s.string),focused:s.string,expandMode:s.oneOf(["single","multiple"]),className:s.string,onSelect:s.func},u.defaultProps={expandMode:"multiple",animation:!0},t.default=u},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(6),c=n(8);var p=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleItemClick=function(){var e=t.props,n=e.onSelect,r=e.disabled,o=e.id;n&&!r&&n.call(void 0,{uniquePrivateKey:t.props.uniquePrivateKey,id:o,target:t})},t}return o(t,e),t.prototype.render=function(){var e,t=this.props,n=t.id,r=t.children,o=t.title,s=t.uniquePrivateKey,p=t.disabled,d=t.selected,u=t.focused,f=t.expanded,h=t.className,v=t.root,y=t.headerClassName,b=t.animation,m={role:"treeitem","aria-disabled":p,"aria-hidden":!p&&!f,"aria-selected":!p&&d,"aria-expanded":!p&&f&&!!r},_=l({"k-item":!0,"k-state-default":!p,"k-state-expanded":f&&!!r,"k-state-disabled":p},h),g=l({"k-link":!0,"k-header":v,"k-state-selected":!p&&d,"k-state-focused":!p&&u},y),x=l(((e={})["k-icon"]=!0,e["k-i-arrow-n"]=f&&!!r,e["k-panelbar-collapse"]=f&&!!r,e["k-i-arrow-s"]=!f&&!!r,e["k-panelbar-expand"]=!f&&!!r,e)),k=function(e){var t=e.imageUrl,n=e.icon,r=e.iconClass;if(t)return a.createElement("img",{role:"presentation",className:"k-image",src:t});if(n){var o=l("k-icon","k-i-"+n);return a.createElement("span",{role:"presentation",className:o})}return r?a.createElement("span",{role:"presentation",className:r}):null}(this.props),O=!p&&r?a.createElement("span",{className:x}):null,P=!p&&f?a.createElement("div",{role:"group",className:"k-panel k-group"},r):null,C=void 0!==b&&!b||p||!r?P:a.createElement(c.Reveal,{transitionEnterDuration:200,transitionExitDuration:200,key:s+"_animation",style:{position:"static"},children:P});return a.createElement("div",i({id:n,className:_},m),a.createElement("span",{className:g,onClick:this.handleItemClick},k,o,O),C)},t}(a.PureComponent);p.propTypes={animation:s.bool,children:s.any,className:s.string,expanded:s.bool,disabled:s.bool,onSelect:s.func,selected:s.bool,root:s.bool,title:s.oneOfType([s.string,s.element]),id:s.oneOfType([s.string,s.number]),focused:s.bool},p.defaultProps={title:"Untitled"},t.default=p},function(e,t,n){"use strict";var r=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(11),a=function(e){return e.map(function(e,t){var n;return e.content&&(n=e.content),e.children&&(n=a(e.children)),o.createElement(i.default,r({},e,{children:n,key:e.id||t}))})};t.renderChildren=function(e,n,a,s,l,c,p){return void 0===e&&(e=!0),void 0===l&&(l=!0),void 0===c&&(c=!0),void 0===p&&(p=[]),o.Children.map(s,function(s,d){if(s.type===i.default){var u=void 0,f=p.length?p[p.length-1]+"."+d:"."+d;return s.props.children&&(u=t.renderChildren(e,n,a,s.props.children,(n.expanded||[]).indexOf(f)>-1&&l,!1,p.concat([f]))),o.cloneElement(s,r({},s.props,{animation:void 0!==s.props.animation?s.props.animation:e,id:s.props.id||"k-panelbar-item-default-"+f,uniquePrivateKey:f,parentUniquePrivateKey:p,parentExpanded:l,root:c,expanded:(n.expanded||[]).indexOf(f)>-1&&l,focused:n.focused===f&&n.wrapperFocused,selected:n.selected===f,children:u,onSelect:a}))}return o.createElement("div",{className:"k-content"},s)})},t.getInitialState=function(e,n,r,a,s,l){return void 0===r&&(r={expanded:e.expanded||[],selected:e.selected||"",focused:e.focused||".0",wrapperFocused:!1}),void 0===a&&(a=!0),void 0===s&&(s=!0),void 0===l&&(l=[]),o.Children.map(e.children,function(e,o){if(e.type===i.default){var a=l.length?l[l.length-1]+"."+o:"."+o;!e.props.disabled&&s&&(e.props.selected&&(r.selected=a),e.props.focused&&(r.focused=a),e.props.expanded&&("multiple"===n?r.expanded.push(a):"single"===n&&(r.expanded=[a])),e.props.children&&(r=t.getInitialState(e.props,n,r,!1,!!e.props.expanded,l.concat([a]))))}}),r},t.flatVisibleItems=function e(t,n,r){return void 0===n&&(n=[]),void 0===r&&(r=null),(t||[]).forEach(function(t){t.disabled||(n.push(t),t.expanded&&t.children&&e(t.children,n))}),n},t.isPresent=function(e){return null!==e&&void 0!==e};var s={mapItemsToComponents:a};t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(2),o=function(){function e(e,t,n){var o=this;this.flatChildren=function(e,t){return void 0===t&&(t=[]),r.Children.forEach(e,function(e){e.props&&!e.props.disabled&&(t.push(e),e.props.children&&o.flatChildren(e.props.children,t))}),t},this.flatVisibleChildren=function(e,t){return void 0===t&&(t=[]),r.Children.forEach(e,function(e){e.props&&!e.props.disabled&&(e.props.expanded||e.props.parentExpanded)&&(t.push(e),e.props.children&&o.flatVisibleChildren(e.props.children,t))}),t},this.onSelect=e,this.onFocus=t,this.expandMode=n}return e.prototype.select=function(e,t,n){var o,i;switch(this.flatChildren(r.Children.toArray(t)).forEach(function(t){t.props.uniquePrivateKey===e&&(o=t)}),this.expandMode){case"single":i=o.props.parentUniquePrivateKey.concat([o.props.uniquePrivateKey]);break;case"multiple":var a=(i=n.slice()).indexOf(o.props.uniquePrivateKey);-1===a?i.push(o.props.uniquePrivateKey):i.splice(a,1);break;default:i=n.slice()}this.onSelect(o,i)},e.prototype.focus=function(e,t,n){var o,i=this.flatVisibleChildren(r.Children.toArray(n));i.forEach(function(n,r){if(n.props.uniquePrivateKey===e){var a=r+t<0?0:r+t>=i.length?i.length-1:r+t;o=i[a]}}),this.onFocus(o)},e.prototype.setExpandMode=function(e){this.expandMode=e},e}();t.default=o},function(e,t){"use strict";var n,r;Object.defineProperty(t,"__esModule",{value:!0}),(r=n=t.NavigationAction||(t.NavigationAction={}))[r.Undefined=0]="Undefined",r[r.Toggle=1]="Toggle",r[r.Next=2]="Next",r[r.Previous=3]="Previous";var o=function(){function e(e){this.onNavigate=e}return e.prototype.navigate=function(e,t){var r=e.keyCode,o=n.Undefined;switch(r){case 37:o=t?n.Next:n.Previous;break;case 38:o=n.Previous;break;case 39:o=t?n.Previous:n.Next;break;case 40:o=n.Next;break;case 32:case 13:o=n.Toggle;break;default:o=n.Undefined}this.onNavigate(o)},e}();t.default=o}])}}});
System.register("@progress/kendo-react-layout",["prop-types","react","classnames","@progress/kendo-react-animation"],function(e){var t,n,r,o;function i(e){return e.__useDefault?e.default:e}return{setters:[function(e){t=i(e)},function(e){n=i(e)},function(e){r=i(e)},function(e){o=i(e)}],execute:function(){!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}n.m=e,n.c=t,n.p="",n(0)}([function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=r(1);n.TabStrip=o.default;var i=r(7);n.TabStripContent=i.default;var a=r(4);n.TabStripNavigation=a.default;var s=r(5);n.TabStripNavigationItem=s.default;var l=r(9);n.TabStripTab=l.default;var c=r(10);n.PanelBar=c.default;var p=r(11);n.PanelBarItem=p.default;var d=r(12);n.PanelBarUtils=d.default,function(t){for(var n in t)e(n,t[n])}(n)},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(4),c=n(7),p=n(6),d=function(e){function t(){var t,n=null!==e&&e.apply(this,arguments)||this;return n._element=null,n.keyBinding=((t={})[37]=function(){return n.prevNavigatableTab()},t[39]=function(){return n.nextNavigatableTab()},t[40]=function(){return n.nextNavigatableTab()},t[38]=function(){return n.prevNavigatableTab()},t[36]=function(){return 0},t[35]=function(){return a.Children.count(n.props.children)-1},t),n.onSelect=function(e){n.props.selected!==e&&n.props.onSelect&&n.props.onSelect({selected:e})},n.onKeyDown=function(e){var t;switch(9!==e.keyCode&&e.preventDefault(),e.keyCode){case 37:t=n.keyBinding[n.invertKeys(37,39)];break;case 39:t=n.keyBinding[n.invertKeys(39,37)];break;case 38:t=n.keyBinding[38];break;case 40:t=n.keyBinding[40]}t&&n.onSelect(t())},n.firstNavigatableTab=function(){var e=n.props.children,t=a.Children.count(e);if(e)for(var r=0;r<t;r++)if(!e[r].props.disabled)return r},n.lastNavigatableTab=function(){var e=n.props.children,t=a.Children.count(e);if(e)for(var r=t-1;r>0;r--)if(!e[r].props.disabled)return r},n.prevNavigatableTab=function(){var e=n.props,t=e.children,r=e.selected,o=r?r-1:-1;if(o<0)return n.lastNavigatableTab();if(t)for(var i=o;i>-1;i--){if(!t[i].props.disabled)return i;if(0===i)return n.lastNavigatableTab()}},n.nextNavigatableTab=function(){var e=n.props,t=e.children,r=e.selected,o=r?r+1:1,i=a.Children.count(t);if(o>=i)return n.firstNavigatableTab();if(t)for(var s=o;s<i;s++){if(!t[s].props.disabled)return s;if(s+1===i)return n.firstNavigatableTab()}},n.renderContent=function(e){var t=n.props,r=t.selected,o=t.children,s=t.tabContentStyle;return r<a.Children.count(o)&&r>-1?a.createElement(c.default,i({index:r},e,{style:s})):null},n}return o(t,e),t.prototype.render=function(){var e,t=this,n=i({},this.props,{selected:this.props.selected,onSelect:this.onSelect}),r=n.tabPosition,o=n.tabIndex,s=void 0===o?0:o,c="bottom"===r,d=p(((e={})["k-widget"]=!0,e["k-header"]=!0,e["k-floatwrap"]=!0,e["k-tabstrip"]=!0,e["k-tabstrip-left"]="left"===r,e["k-tabstrip-right"]="right"===r,e["k-tabstrip-bottom"]="bottom"===r,e["k-tabstrip-top"]="top"===r,e));return a.createElement("div",{ref:function(e){t._element=e},dir:this.props.dir,className:d,onKeyDown:this.onKeyDown,style:this.props.style},!c&&a.createElement(l.default,i({},n,{tabIndex:s})),this.renderContent(n),c&&a.createElement(l.default,i({},n,{tabIndex:s})))},t.prototype.invertKeys=function(e,t){return this._element&&"rtl"===getComputedStyle(this._element).direction||!1?t:e},t}(a.Component);d.propTypes={animation:s.bool,children:s.oneOfType([s.element,s.arrayOf(s.element)]),onSelect:s.func,selected:s.number,style:s.object,tabContentStyle:s.object,tabPosition:s.string,tabIndex:s.number,dir:s.string},d.defaultProps={animation:!0,tabPosition:"top"},t.default=d},function(e,t){e.exports=n},function(e,n){e.exports=t},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(5),c=n(6),p=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.render=function(){var e,t,n=this.props,r=n.selected,o=n.children,s=n.onSelect,p=a.Children.count(o);o&&(e=(t=p,Array.apply(null,Array(t))).map(function(e,t,n){return{first:0===t,last:t===n.length-1}}).map(function(e,t){var n={active:r===t,disabled:o[t].props.disabled,index:t,title:o[t].props.title,onSelect:s};return a.createElement(l.default,i({key:t},n))}));var d=c("k-tabstrip-items","k-reset");return a.createElement("ul",{className:d,role:"tablist",tabIndex:this.props.tabIndex},e)},t}(a.Component);p.propTypes={children:s.oneOfType([s.element,s.arrayOf(s.element)]),onSelect:s.func,selected:s.number,tabIndex:s.number},t.default=p},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(6),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.onClick=function(){t.props.onSelect&&t.props.onSelect(t.props.index)},t}return o(t,e),t.prototype.render=function(){var e,t=this.props,n=t.active,r=t.disabled,o=t.title,s=void 0===o?"Untitled":o,c={"aria-selected":n,role:"tab",onClick:r?void 0:this.onClick},p=l(((e={})["k-item"]=!0,e["k-state-default"]=!(r||n),e["k-state-disabled"]=r,e["k-state-active"]=n,e["k-tab-on-top"]=n,e));return a.createElement("li",i({},c,{className:p}),a.createElement("span",{className:"k-link"},s))},t}(a.Component);c.propTypes={active:s.bool,disabled:s.bool,index:s.number,onSelect:s.func,title:s.oneOfType([s.string,s.element])},t.default=c},function(e,t){e.exports=r},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(8),c=n(6),p=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.renderContent=function(e){var t={role:"tabpanel","aria-expanded":"true"},n=a.Children.toArray(e)[this.props.selected];return this.props.animation?a.createElement(l.Fade,{style:{position:"initial"},appear:!0},a.createElement("div",i({},t,{key:this.props.index}),n.props.children)):a.createElement("div",i({},t,{key:this.props.index}),n.props.children)},t.prototype.render=function(){var e=c("k-content","k-state-active");return a.createElement("div",{className:e,style:this.props.style},this.renderContent(this.props.children))},t}(a.Component);p.propTypes={animation:s.bool,children:s.oneOfType([s.element,s.arrayOf(s.element)]),selected:s.number,style:s.object},t.default=p},function(e,t){e.exports=o},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var i=n(2),a=n(3),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t}(i.Component);s.propTypes={disabled:a.bool,children:a.oneOfType([a.element,a.node]),title:a.oneOfType([a.string,a.element,a.node])},t.default=s},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(11),c=n(12),p=n(13),d=n(14),u=function(e){function t(t){var n=e.call(this,t)||this;return n._element=null,n.handleSelect=function(e){n._selectionService.select(e.uniquePrivateKey,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children),n.state.expanded),n._selectionService.focus(e.uniquePrivateKey,0,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children))},n.onSelect=function(e,t){n.setState({selected:e.props.uniquePrivateKey,expanded:t},function(){n.props.onSelect&&n.props.onSelect.call(void 0,{target:e,action:"select"})})},n.onFocus=function(e){n.activeDescendant=e.props.id,n.setState({focused:e.props.uniquePrivateKey})},n.handleWrapperFocus=function(e){n.setState({wrapperFocused:"focus"===e.nativeEvent.type})},n.handleKeyDown=function(e){9!==e.keyCode&&e.preventDefault();var t=n._element&&"rtl"===getComputedStyle(n._element).direction||!1;n._navigationService.navigate(e,t)},n.onNavigate=function(e){switch(e){case d.NavigationAction.Previous:n._selectionService.focus(n.state.focused,-1,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children));break;case d.NavigationAction.Next:n._selectionService.focus(n.state.focused,1,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children));break;case d.NavigationAction.Toggle:n._selectionService.select(n.state.focused,c.renderChildren(n.props.animation,n.state,n.handleSelect,n.props.children),n.state.expanded)}},n.state=c.getInitialState(t,t.expandMode||"multiple"),n._selectionService=new p.default(n.onSelect,n.onFocus,n.props.expandMode||"multiple"),n._navigationService=new d.default(n.onNavigate),n}return o(t,e),t.prototype.componentWillReceiveProps=function(e){e.expandMode!==this.props.expandMode&&this._selectionService.setExpandMode(e.expandMode),e.selected!==this.state.selected&&void 0!==e.selected&&this.setState({selected:e.selected})},t.prototype.render=function(){var e=this,t={"aria-activedescendant":this.activeDescendant},n=c.renderChildren(this.props.animation,this.state,this.handleSelect,this.props.children);return a.createElement("div",i({ref:function(t){e._element=t},dir:this.props.dir,role:"tree",tabIndex:0,onKeyDown:this.handleKeyDown,onFocus:this.handleWrapperFocus,onBlur:this.handleWrapperFocus,className:"k-widget k-panelbar k-reset k-header"},t),n)},t}(a.Component);u.propTypes={animation:s.bool,children:function(e,t){var n=e[t];if(n)if(n instanceof Array)for(var r=0,o=n;r<o.length;r++){var i=o[r];if(!i.type||i.type!==l.default)return new Error("PanelBar children should be either PanelBarItem or Array of PanelBarItem.")}else if(n.type!==l.default)return new Error("PanelBar child should be either PanelBarItem or Array of PanelBarItem.")},dir:s.string,selected:s.string,expanded:s.arrayOf(s.string),focused:s.string,expandMode:s.oneOf(["single","multiple"]),className:s.string,onSelect:s.func},u.defaultProps={expandMode:"multiple",animation:!0},t.default=u},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(2),s=n(3),l=n(6),c=n(8);var p=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleItemClick=function(){var e=t.props,n=e.onSelect,r=e.disabled,o=e.id;n&&!r&&n.call(void 0,{uniquePrivateKey:t.props.uniquePrivateKey,id:o,target:t})},t}return o(t,e),t.prototype.render=function(){var e,t=this.props,n=t.id,r=t.children,o=t.title,s=t.uniquePrivateKey,p=t.disabled,d=t.selected,u=t.focused,f=t.expanded,h=t.className,v=t.root,y=t.headerClassName,b=t.animation,m={role:"treeitem","aria-disabled":p,"aria-hidden":!p&&!f,"aria-selected":!p&&d,"aria-expanded":!p&&f&&!!r},_=l({"k-item":!0,"k-state-default":!p,"k-state-expanded":f&&!!r,"k-state-disabled":p},h),g=l({"k-link":!0,"k-header":v,"k-state-selected":!p&&d,"k-state-focused":!p&&u},y),x=l(((e={})["k-icon"]=!0,e["k-i-arrow-n"]=f&&!!r,e["k-panelbar-collapse"]=f&&!!r,e["k-i-arrow-s"]=!f&&!!r,e["k-panelbar-expand"]=!f&&!!r,e)),k=function(e){var t=e.imageUrl,n=e.icon,r=e.iconClass;if(t)return a.createElement("img",{role:"presentation",className:"k-image",src:t});if(n){var o=l("k-icon","k-i-"+n);return a.createElement("span",{role:"presentation",className:o})}return r?a.createElement("span",{role:"presentation",className:r}):null}(this.props),O=!p&&r?a.createElement("span",{className:x}):null,P=!p&&f?a.createElement("div",{role:"group",className:"k-panel k-group"},r):null,C=void 0!==b&&!b||p||!r?P:a.createElement(c.Reveal,{transitionEnterDuration:200,transitionExitDuration:200,key:s+"_animation",style:{position:"static"},children:P});return a.createElement("div",i({id:n,className:_},m),a.createElement("span",{className:g,onClick:this.handleItemClick},k,o,O),C)},t}(a.PureComponent);p.propTypes={animation:s.bool,children:s.any,className:s.string,expanded:s.bool,disabled:s.bool,onSelect:s.func,selected:s.bool,root:s.bool,title:s.oneOfType([s.string,s.element]),id:s.oneOfType([s.string,s.number]),focused:s.bool},p.defaultProps={title:"Untitled"},t.default=p},function(e,t,n){"use strict";var r=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(2),i=n(11),a=function(e){return e.map(function(e,t){var n;return e.content&&(n=e.content),e.children&&(n=a(e.children)),o.createElement(i.default,r({},e,{children:n,key:e.id||t}))})};t.renderChildren=function(e,n,a,s,l,c,p){return void 0===e&&(e=!0),void 0===l&&(l=!0),void 0===c&&(c=!0),void 0===p&&(p=[]),o.Children.map(s,function(s,d){if(s.type===i.default){var u=void 0,f=p.length?p[p.length-1]+"."+d:"."+d;return s.props.children&&(u=t.renderChildren(e,n,a,s.props.children,(n.expanded||[]).indexOf(f)>-1&&l,!1,p.concat([f]))),o.cloneElement(s,r({},s.props,{animation:void 0!==s.props.animation?s.props.animation:e,id:s.props.id||"k-panelbar-item-default-"+f,uniquePrivateKey:f,parentUniquePrivateKey:p,parentExpanded:l,root:c,expanded:(n.expanded||[]).indexOf(f)>-1&&l,focused:n.focused===f&&n.wrapperFocused,selected:n.selected===f,children:u,onSelect:a}))}return o.createElement("div",{className:"k-content"},s)})},t.getInitialState=function(e,n,r,a,s,l){return void 0===r&&(r={expanded:e.expanded||[],selected:e.selected||"",focused:e.focused||".0",wrapperFocused:!1}),void 0===a&&(a=!0),void 0===s&&(s=!0),void 0===l&&(l=[]),o.Children.map(e.children,function(e,o){if(e.type===i.default){var a=l.length?l[l.length-1]+"."+o:"."+o;!e.props.disabled&&s&&(e.props.selected&&(r.selected=a),e.props.focused&&(r.focused=a),e.props.expanded&&("multiple"===n?r.expanded.push(a):"single"===n&&(r.expanded=[a])),e.props.children&&(r=t.getInitialState(e.props,n,r,!1,!!e.props.expanded,l.concat([a]))))}}),r},t.flatVisibleItems=function e(t,n,r){return void 0===n&&(n=[]),void 0===r&&(r=null),(t||[]).forEach(function(t){t.disabled||(n.push(t),t.expanded&&t.children&&e(t.children,n))}),n},t.isPresent=function(e){return null!==e&&void 0!==e};var s={mapItemsToComponents:a};t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(2),o=function(){function e(e,t,n){var o=this;this.flatChildren=function(e,t){return void 0===t&&(t=[]),r.Children.forEach(e,function(e){e.props&&!e.props.disabled&&(t.push(e),e.props.children&&o.flatChildren(e.props.children,t))}),t},this.flatVisibleChildren=function(e,t){return void 0===t&&(t=[]),r.Children.forEach(e,function(e){e.props&&!e.props.disabled&&(e.props.expanded||e.props.parentExpanded)&&(t.push(e),e.props.children&&o.flatVisibleChildren(e.props.children,t))}),t},this.onSelect=e,this.onFocus=t,this.expandMode=n}return e.prototype.select=function(e,t,n){var o,i;switch(this.flatChildren(r.Children.toArray(t)).forEach(function(t){t.props.uniquePrivateKey===e&&(o=t)}),this.expandMode){case"single":i=o.props.parentUniquePrivateKey.concat([o.props.uniquePrivateKey]);break;case"multiple":var a=(i=n.slice()).indexOf(o.props.uniquePrivateKey);-1===a?i.push(o.props.uniquePrivateKey):i.splice(a,1);break;default:i=n.slice()}this.onSelect(o,i)},e.prototype.focus=function(e,t,n){var o,i=this.flatVisibleChildren(r.Children.toArray(n));i.forEach(function(n,r){if(n.props.uniquePrivateKey===e){var a=r+t<0?0:r+t>=i.length?i.length-1:r+t;o=i[a]}}),this.onFocus(o)},e.prototype.setExpandMode=function(e){this.expandMode=e},e}();t.default=o},function(e,t){"use strict";var n,r;Object.defineProperty(t,"__esModule",{value:!0}),(r=n=t.NavigationAction||(t.NavigationAction={}))[r.Undefined=0]="Undefined",r[r.Toggle=1]="Toggle",r[r.Next=2]="Next",r[r.Previous=3]="Previous";var o=function(){function e(e){this.onNavigate=e}return e.prototype.navigate=function(e,t){var r=e.keyCode,o=n.Undefined;switch(r){case 37:o=t?n.Next:n.Previous;break;case 38:o=n.Previous;break;case 39:o=t?n.Previous:n.Next;break;case 40:o=n.Next;break;case 32:case 13:o=n.Toggle;break;default:o=n.Undefined}this.onNavigate(o)},e}();t.default=o}])}}});
{
"name": "@progress/kendo-react-layout",
"version": "0.2.0-dev.201801231552",
"version": "0.2.0",
"description": "Kendo UI for React Layout package",

@@ -32,3 +32,3 @@ "repository": {

"dependencies": {
"@progress/kendo-react-animation": "0.2.0-dev.201801231552",
"@progress/kendo-react-animation": "0.2.0",
"classnames": "^2.2.5",

@@ -35,0 +35,0 @@ "prop-types": "^15.6.0"

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