UNPKG

@progress/kendo-dropdowns-react-wrapper

Version:

Kendo UI DropDowns wrapper for React

2 lines 9.55 kB
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("react")):"function"==typeof define&&define.amd?define(["react"],e):"object"==typeof exports?exports.KendoDropdownsReactWrapper=e(require("react")):t.KendoDropdownsReactWrapper=e(t.React)}("undefined"!=typeof self?self:this,function(t){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=2)}([function(e,n){e.exports=t},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(0),i=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.didMount=!1,e.elementRef=function(t){e.domNode=t},e.exposeWidget=function(){e.props.widgetRef&&"function"==typeof e.props.widgetRef&&e.props.widgetRef(e.widgetInstance)},e.overrideDestroy=function(){e.widgetDestroy=e.widgetInstance.destroy,e.widgetInstance.destroy=function(){e.destroyed=!e.destroyed,e.widgetDestroy.call(e.widgetInstance)}},e}return r(e,t),e.prototype.componentDidMount=function(){this.exposeWidget(),this.overrideDestroy(),this.didMount=!0},e.prototype.componentWillUnmount=function(){this.destroyed||this.widgetDestroy.call(this.widgetInstance),this.exposeWidget()},e}(o.PureComponent);e.default=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3);e.AutoComplete=r.default;var o=n(4);e.ComboBox=o.default;var i=n(5);e.DropDownList=i.default;var s=n(6);e.MultiSelect=s.default},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),o=this&&this.__assign||function(){return o=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++){e=arguments[n];for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}return t},o.apply(this,arguments)},i=this&&this.__rest||function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&(n[r[o]]=t[r[o]]);return n};Object.defineProperty(e,"__esModule",{value:!0});var s=n(0),c=n(1),u=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.componentDidMount=function(){var e=this.domNode,n=this.props,r=(n.children,n.widgetRef,i(n,["children","widgetRef"]));e&&(this.widgetInstance=new kendo.ui.AutoComplete(e,r),t.prototype.componentDidMount.call(this))},e.prototype.render=function(){if(this.didMount){var t=this.props,e=(t.children,t.widgetRef,t.dataSource),n=i(t,["children","widgetRef","dataSource"]);this.widgetInstance.setOptions(n);var r=this.widgetInstance;r.options.dataSource!==e&&r.setDataSource(e),r.value(this.props.value)}var c=s.Children.toArray(this.props.children).filter(function(t){return t&&"input"===t.type}).shift();return c?s.cloneElement(c,o({},c.props,{ref:this.elementRef})):s.createElement("input",{ref:this.elementRef})},e}(c.default);e.default=u},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),o=this&&this.__assign||function(){return o=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++){e=arguments[n];for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}return t},o.apply(this,arguments)},i=this&&this.__rest||function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&(n[r[o]]=t[r[o]]);return n};Object.defineProperty(e,"__esModule",{value:!0});var s=n(0),c=n(1),u=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.componentDidMount=function(){var e=this.domNode,n=this.props,r=(n.children,n.widgetRef,i(n,["children","widgetRef"]));e&&(this.widgetInstance=new kendo.ui.ComboBox(e,r),t.prototype.componentDidMount.call(this))},e.prototype.render=function(){if(this.didMount){var t=this.props,e=(t.children,t.widgetRef,t.dataSource),n=i(t,["children","widgetRef","dataSource"]);this.widgetInstance.setOptions(n);var r=this.widgetInstance;r.options.dataSource!==e&&r.setDataSource(e),r.value(this.props.value)}var c=s.Children.toArray(this.props.children).filter(function(t){return t&&"input"===t.type}).shift();return c?s.cloneElement(c,o({},c.props,{ref:this.elementRef})):s.createElement("input",{ref:this.elementRef})},e}(c.default);e.default=u},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),o=this&&this.__assign||function(){return o=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++){e=arguments[n];for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}return t},o.apply(this,arguments)},i=this&&this.__rest||function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&(n[r[o]]=t[r[o]]);return n};Object.defineProperty(e,"__esModule",{value:!0});var s=n(0),c=n(1),u=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.componentDidMount=function(){var e=this.domNode,n=this.props,r=(n.children,n.widgetRef,i(n,["children","widgetRef"]));e&&(this.widgetInstance=new kendo.ui.DropDownList(e,r),t.prototype.componentDidMount.call(this))},e.prototype.render=function(){if(this.didMount){var t=this.props,e=(t.children,t.widgetRef,t.dataSource),n=i(t,["children","widgetRef","dataSource"]);this.widgetInstance.setOptions(n);var r=this.widgetInstance;r.options.dataSource!==e&&r.setDataSource(e),this.widgetInstance.value(this.props.value)}var c=s.Children.toArray(this.props.children).filter(function(t){return t&&"input"===t.type}).shift();return c?s.cloneElement(c,o({},c.props,{ref:this.elementRef})):s.createElement("input",{ref:this.elementRef})},e}(c.default);e.default=u},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),o=this&&this.__assign||function(){return o=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++){e=arguments[n];for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}return t},o.apply(this,arguments)},i=this&&this.__rest||function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&(n[r[o]]=t[r[o]]);return n};Object.defineProperty(e,"__esModule",{value:!0});var s=n(0),c=n(1),u=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.componentDidMount=function(){var e=this.domNode,n=this.props,r=(n.children,n.widgetRef,i(n,["children","widgetRef"]));e&&(this.widgetInstance=new kendo.ui.MultiSelect(e,r),t.prototype.componentDidMount.call(this))},e.prototype.render=function(){if(this.didMount){var t=this.props,e=(t.children,t.widgetRef,t.dataSource),n=i(t,["children","widgetRef","dataSource"]);this.widgetInstance.setOptions(n);var r=this.widgetInstance;r.options.dataSource!==e&&r.setDataSource(e),r.value(this.props.value)}var c=s.Children.toArray(this.props.children).filter(function(t){return t&&"select"===t.type}).shift();return c?s.cloneElement(c,o({},c.props,{ref:this.elementRef})):s.createElement("select",{ref:this.elementRef})},e}(c.default);e.default=u}])}); //# sourceMappingURL=kendo-dropdowns-react-wrapper.min.js.map