boundless-button
Advanced tools
Comparing version 1.0.0-beta.5 to 1.0.0-beta.6
@@ -1,2 +0,2 @@ | ||
module.exports=function(e){function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}var t={};return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},n.p="",n(n.s=5)}([function(e,n,t){"use strict";n.a=function(e){return"function"==typeof e}},function(e,n,t){"use strict";function r(){}n.a=r},function(e,n,t){"use strict";function r(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return Object.keys(e).reduce(function(t,r){return n.indexOf(r)===-1&&(t[r]=e[r]),t},{})}n.a=r},function(e,n){e.exports=require("classnames")},function(e,n){e.exports=require("react")},function(e,n,t){"use strict";function r(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function o(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!n||"object"!=typeof n&&"function"!=typeof n?e:n}function s(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}Object.defineProperty(n,"__esModule",{value:!0});var p=t(4),i=t.n(p),u=t(3),c=t.n(u),a=t(0),l=t(1),f=t(2),d=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},y=function(){function e(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),b=function(e){function n(){var e,s,p,i;r(this,n);for(var u=arguments.length,c=Array(u),l=0;l<u;l++)c[l]=arguments[l];return s=p=o(this,(e=n.__proto__||Object.getPrototypeOf(n)).call.apply(e,[this].concat(c))),p.handleClick=function(e){p.props.disabled||(p.toggleState(e),t.i(a.a)(p.props.onClick)&&p.props.onClick(e))},p.handleKeyDown=function(e){if(!p.props.disabled){switch(e.key){case"Enter":case"Space":e.preventDefault(),p.toggleState(e)}t.i(a.a)(p.props.onKeyDown)&&p.props.onKeyDown(e)}},i=s,o(p,i)}return s(n,e),y(n,[{key:"toggleState",value:function(e){this.props[this.props.pressed?"onUnpressed":"onPressed"](e)}},{key:"render",value:function(){return i.a.createElement(this.props.component,d({},t.i(f.a)(this.props,n.internalKeys),{ref:"button",className:c()("b-button",this.props.className,{"b-button-pressable":"undefined"!=typeof this.props.pressed,"b-button-pressed":this.props.pressed}),"aria-pressed":this.props.pressed,onKeyDown:this.handleKeyDown,onClick:this.handleClick}),this.props.children)}}]),n}(i.a.PureComponent);b.propTypes={children:p.PropTypes.node,component:p.PropTypes.oneOfType([p.PropTypes.string,p.PropTypes.func]),onClick:p.PropTypes.func,onPressed:p.PropTypes.func,onUnpressed:p.PropTypes.func,pressed:p.PropTypes.bool},b.defaultProps={children:null,component:"button",onClick:l.a,onPressed:l.a,onUnpressed:l.a,pressed:void 0},b.internalKeys=Object.keys(b.defaultProps),n.default=b}]); | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vaW5kZXguanMiLCJ3ZWJwYWNrOi8vL3dlYnBhY2svYm9vdHN0cmFwIGZkN2EyNDI0Zjg0NWI5MzVjYWVmIiwid2VicGFjazovLy8uL3BhY2thZ2VzL2JvdW5kbGVzcy11dGlscy1pcy1mdW5jdGlvbi9pbmRleC5qcyIsI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iAgICAgICAgb25QcmVzc2VkOiBub29wLFxuICAgICAgICBvblVucHJlc3NlZDogbm9vcCxcbiAgICAgICAgcHJlc3NlZDogdW5kZWZpbmVkLFxuICAgIH1cblxuICAgIHN0YXRpYyBpbnRlcm5hbEtleXMgPSBPYmplY3Qua2V5cyhCdXR0b24uZGVmYXVsdFByb3BzKVxuXG4gICAgdG9nZ2xlU3RhdGUoZXZlbnQpIHtcbiAgICAgICAgdGhpcy5wcm9wc1t0aGlzLnByb3BzLnByZXNzZWQgPyAnb25VbnByZXNzZWQnIDogJ29uUHJlc3NlZCddKGV2ZW50KTtcbiAgICB9XG5cbiAgICBoYW5kbGVDbGljayA9IChldmVudCkgPT4ge1xuICAgICAgICBpZiAodGhpcy5wcm9wcy5kaXNhYmxlZCkgeyByZXR1cm47IH1cblxuICAgICAgICB0aGlzLnRvZ2dsZVN0YXRlKGV2ZW50KTtcblxuICAgICAgICBpZiAoaXNGdW5jdGlvbih0aGlzLnByb3BzLm9uQ2xpY2spKSB7XG4gICAgICAgICAgICB0aGlzLnByb3BzLm9uQ2xpY2soZXZlbnQpO1xuICAgICAgICB9XG4gICAgfVxuXG4gICAgaGFuZGxlS2V5RG93biA9IChldmVudCkgPT4ge1xuICAgICAgICBpZiAodGhpcy5wcm9wcy5kaXNhYmxlZCkgeyByZXR1cm47IH1cblxuICAgICAgICBzd2l0Y2ggKGV2ZW50LmtleSkge1xuICAgICAgICBjYXNlICdFbnRlcic6XG4gICAgICAgIGNhc2UgJ1NwYWNlJzpcbiAgICAgICAgICAgIGV2ZW50LnByZXZlbnREZWZhdWx0KCk7XG4gICAgICAgICAgICB0aGlzLnRvZ2dsZVN0YXRlKGV2ZW50KTtcbiAgICAgICAgfVxuXG4gICAgICAgIGlmIChpc0Z1bmN0aW9uKHRoaXMucHJvcHMub25LZXlEb3duKSkge1xuICAgICAgICAgICAgdGhpcy5wcm9wcy5vbktleURvd24oZXZlbnQpO1xuICAgICAgICB9XG4gICAgfVxuXG4gICAgcmVuZGVyKCkge1xuICAgICAgICByZXR1cm4gKFxuICAgICAgICAgICAgPHRoaXMucHJvcHMuY29tcG9uZW50XG4gICAgICAgICAgICAgICAgey4uLm9taXQodGhpcy5wcm9wcywgQnV0dG9uLmludGVybmFsS2V5cyl9XG4gICAgICAgICAgICAgICAgcmVmPSdidXR0b24nXG4gICAgICAgICAgICAgICAgY2xhc3NOYW1lPXtjeCgnYi1idXR0b24nLCB0aGlzLnByb3BzLmNsYXNzTmFtZSwge1xuICAgICAgICAgICAgICAgICAgICAnYi1idXR0b24tcHJlc3NhYmxlJzogdHlwZW9mIHRoaXMucHJvcHMucHJlc3NlZCAhPT0gJ3VuZGVmaW5lZCcsXG4gICAgICAgICAgICAgICAgICAgICdiLWJ1dHRvbi1wcmVzc2VkJzogdGhpcy5wcm9wcy5wcmVzc2VkLFxuICAgICAgICAgICAgICAgIH0pfVxuICAgICAgICAgICAgICAgIGFyaWEtcHJlc3NlZD17dGhpcy5wcm9wcy5wcmVzc2VkfVxuICAgICAgICAgICAgICAgIG9uS2V5RG93bj17dGhpcy5oYW5kbGVLZXlEb3dufVxuICAgICAgICAgICAgICAgIG9uQ2xpY2s9e3RoaXMuaGFuZGxlQ2xpY2t9PlxuICAgICAgICAgICAgICAgIHt0aGlzLnByb3BzLmNoaWxkcmVufVxuICAgICAgICAgICAgPC90aGlzLnByb3BzLmNvbXBvbmVudD5cbiAgICAgICAgKTtcbiAgICB9XG59XG5cblxuXG4vLyBXRUJQQUNLIEZPT1RFUiAvL1xuLy8gLi9wYWNrYWdlcy9ib3VuZGxlc3MtYnV0dG9uL2luZGV4LmpzIl0sInNvdXJjZVJvb3QiOiIifQ== | ||
module.exports=function(e){function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}var t={};return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},n.p="",n(n.s=3)}([function(e,n,t){"use strict";function r(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return Object.keys(e).reduce(function(t,r){return n.indexOf(r)===-1&&(t[r]=e[r]),t},{})}n.a=r},function(e,n){e.exports=require("classnames")},function(e,n){e.exports=require("react")},function(e,n,t){"use strict";function r(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function o(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!n||"object"!=typeof n&&"function"!=typeof n?e:n}function s(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}Object.defineProperty(n,"__esModule",{value:!0});var p=t(2),i=t.n(p),u=t(1),c=t.n(u),a=t(0),l=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},f=function(){function e(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),d=function(e){return"function"==typeof e},y=function(){},b=function(e){function n(){var e,t,s,p;r(this,n);for(var i=arguments.length,u=Array(i),c=0;c<i;c++)u[c]=arguments[c];return t=s=o(this,(e=n.__proto__||Object.getPrototypeOf(n)).call.apply(e,[this].concat(u))),s.handleClick=function(e){s.props.disabled||(s.toggleState(e),d(s.props.onClick)&&s.props.onClick(e))},s.handleKeyDown=function(e){if(!s.props.disabled){switch(e.key){case"Enter":case"Space":e.preventDefault(),s.toggleState(e)}d(s.props.onKeyDown)&&s.props.onKeyDown(e)}},p=t,o(s,p)}return s(n,e),f(n,[{key:"toggleState",value:function(e){this.props[this.props.pressed?"onUnpressed":"onPressed"](e)}},{key:"render",value:function(){return i.a.createElement(this.props.component,l({},t.i(a.a)(this.props,n.internalKeys),{ref:"button",className:c()("b-button",this.props.className,{"b-button-pressable":"undefined"!=typeof this.props.pressed,"b-button-pressed":this.props.pressed}),"aria-pressed":this.props.pressed,onKeyDown:this.handleKeyDown,onClick:this.handleClick}),this.props.children)}}]),n}(i.a.PureComponent);b.propTypes={children:p.PropTypes.node,component:p.PropTypes.oneOfType([p.PropTypes.string,p.PropTypes.func]),onClick:p.PropTypes.func,onPressed:p.PropTypes.func,onUnpressed:p.PropTypes.func,pressed:p.PropTypes.bool},b.defaultProps={children:null,component:"button",onClick:y,onPressed:y,onUnpressed:y,pressed:void 0},b.internalKeys=Object.keys(b.defaultProps),n.default=b}]); | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vaW5kZXguanMiLCJ3ZWJwYWNrOi8vL3dlYnBhY2svYm9vdHN0cmFwIGI2YWUwMzAwZjdkODNiZTc5YzcwIiwid2VicGFjazovLy8uL3BhY2thZ2VzL2JvdW5kbGVzcy11dGlscy1vbWl0LWtleXMvaW5kZXguanMiLCJ3ZWJwYWNrOi8vL2V4dGVybmFsIHtcImNvbW1vbmpzMlwiOlwiY2xhc3NuYW1lc1wifSIsIndlYnBhY2s6Ly8vZXh0ZXJuYWwge1wiY29tbW9uanMyXCI6XCJyZWFjdFwifSIsIndlYnBhY2s6Ly8vLi9wYWNrYWdlcy9ib3VuZGxlc3MtYnV0dG9uL2luZGV4LmpzIl0sIm5hbWVzIjpbIm1vZHVsZSIsImV4cG9ydHMiLCJtb2R1bGVzIiwiX193ZWJwYWNrX3JlcXVpcmVfXyIsIm1vZHVsZUlkIiwiaW5zdGFsb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cHMub25DbGljaykpIHtcbiAgICAgICAgICAgIHRoaXMucHJvcHMub25DbGljayhldmVudCk7XG4gICAgICAgIH1cbiAgICB9XG5cbiAgICBoYW5kbGVLZXlEb3duID0gKGV2ZW50KSA9PiB7XG4gICAgICAgIGlmICh0aGlzLnByb3BzLmRpc2FibGVkKSB7IHJldHVybjsgfVxuXG4gICAgICAgIHN3aXRjaCAoZXZlbnQua2V5KSB7XG4gICAgICAgIGNhc2UgJ0VudGVyJzpcbiAgICAgICAgY2FzZSAnU3BhY2UnOlxuICAgICAgICAgICAgZXZlbnQucHJldmVudERlZmF1bHQoKTtcbiAgICAgICAgICAgIHRoaXMudG9nZ2xlU3RhdGUoZXZlbnQpO1xuICAgICAgICB9XG5cbiAgICAgICAgaWYgKGlzRnVuY3Rpb24odGhpcy5wcm9wcy5vbktleURvd24pKSB7XG4gICAgICAgICAgICB0aGlzLnByb3BzLm9uS2V5RG93bihldmVudCk7XG4gICAgICAgIH1cbiAgICB9XG5cbiAgICByZW5kZXIoKSB7XG4gICAgICAgIHJldHVybiAoXG4gICAgICAgICAgICA8dGhpcy5wcm9wcy5jb21wb25lbnRcbiAgICAgICAgICAgICAgICB7Li4ub21pdCh0aGlzLnByb3BzLCBCdXR0b24uaW50ZXJuYWxLZXlzKX1cbiAgICAgICAgICAgICAgICByZWY9J2J1dHRvbidcbiAgICAgICAgICAgICAgICBjbGFzc05hbWU9e2N4KCdiLWJ1dHRvbicsIHRoaXMucHJvcHMuY2xhc3NOYW1lLCB7XG4gICAgICAgICAgICAgICAgICAgICdiLWJ1dHRvbi1wcmVzc2FibGUnOiB0eXBlb2YgdGhpcy5wcm9wcy5wcmVzc2VkICE9PSAndW5kZWZpbmVkJyxcbiAgICAgICAgICAgICAgICAgICAgJ2ItYnV0dG9uLXByZXNzZWQnOiB0aGlzLnByb3BzLnByZXNzZWQsXG4gICAgICAgICAgICAgICAgfSl9XG4gICAgICAgICAgICAgICAgYXJpYS1wcmVzc2VkPXt0aGlzLnByb3BzLnByZXNzZWR9XG4gICAgICAgICAgICAgICAgb25LZXlEb3duPXt0aGlzLmhhbmRsZUtleURvd259XG4gICAgICAgICAgICAgICAgb25DbGljaz17dGhpcy5oYW5kbGVDbGlja30+XG4gICAgICAgICAgICAgICAge3RoaXMucHJvcHMuY2hpbGRyZW59XG4gICAgICAgICAgICA8L3RoaXMucHJvcHMuY29tcG9uZW50PlxuICAgICAgICApO1xuICAgIH1cbn1cblxuXG5cbi8vIFdFQlBBQ0sgRk9PVEVSIC8vXG4vLyAuL3BhY2thZ2VzL2JvdW5kbGVzcy1idXR0b24vaW5kZXguanMiXSwic291cmNlUm9vdCI6IiJ9 |
import React, {PropTypes} from 'react'; | ||
import cx from 'classnames'; | ||
import isFunction from '../boundless-utils-is-function/index'; | ||
import noop from '../boundless-utils-noop/index'; | ||
import omit from '../boundless-utils-omit-keys/index'; | ||
import omit from 'boundless-utils-omit-keys'; | ||
const isFunction = (x) => typeof x === 'function'; | ||
const noop = () => {}; | ||
/** | ||
@@ -9,0 +10,0 @@ # Button |
@@ -5,6 +5,5 @@ /* eslint no-unused-expressions:0 */ | ||
import ReactDOM from 'react-dom'; | ||
import conformanceChecker from '../boundless-utils-conformance/index'; | ||
import noop from '../boundless-utils-noop/index'; | ||
import sinon from 'sinon'; | ||
import conformanceChecker from '../boundless-utils-conformance/index'; | ||
import Button from './index'; | ||
@@ -16,3 +15,3 @@ | ||
const evt = {preventDefault: noop}; | ||
const evt = {preventDefault: () => {}}; | ||
const sandbox = sinon.sandbox.create(); | ||
@@ -19,0 +18,0 @@ |
{ | ||
"name": "boundless-button", | ||
"version": "1.0.0-beta.5", | ||
"version": "1.0.0-beta.6", | ||
"description": "A control with \"pressed\" state support.", | ||
"browser": "build/index.js", | ||
"main": "build/index.js", | ||
"module": "index.js", | ||
"repository": { | ||
@@ -28,9 +29,5 @@ "type": "git", | ||
"dependencies": { | ||
"classnames": "^2.1.5" | ||
"classnames": "^2.1.5", | ||
"boundless-utils-omit-keys": "^1.0.0-beta.6" | ||
}, | ||
"devDependencies": { | ||
"boundless-utils-is-function": "^1.0.0", | ||
"boundless-utils-noop": "^1.0.0", | ||
"boundless-utils-omit-keys": "^1.0.0-beta.3" | ||
}, | ||
"peerDependencies": { | ||
@@ -37,0 +34,0 @@ "react": ">= 15.3", |
@@ -64,3 +64,3 @@ THIS IS AN AUTOGENERATED FILE. EDIT INDEX.JS INSTEAD. | ||
<td><pre><code>function</code></pre></td> | ||
<td><pre><code class="language-js">noop</code></pre></td> | ||
<td><pre><code class="language-js">() => {}</code></pre></td> | ||
<td></td> | ||
@@ -72,3 +72,3 @@ </tr> | ||
<td><pre><code>function</code></pre></td> | ||
<td><pre><code class="language-js">noop</code></pre></td> | ||
<td><pre><code class="language-js">() => {}</code></pre></td> | ||
<td>called when the element becomes "pressed" or triggered by the user (mouse or keyboard); backing data must be updated to persist the state change; this function will still be called if `props.pressed` is not passed</td> | ||
@@ -80,3 +80,3 @@ </tr> | ||
<td><pre><code>function</code></pre></td> | ||
<td><pre><code class="language-js">noop</code></pre></td> | ||
<td><pre><code class="language-js">() => {}</code></pre></td> | ||
<td>called when the element becomes "unpressed"; backing data must be updated to persist the state change</td> | ||
@@ -94,1 +94,2 @@ </tr> | ||
0
92
49383
4
316
+ Addedboundless-utils-omit-keys@1.1.0(transitive)