@atlaskit/tag
Advanced tools
Comparing version 1.2.1 to 2.0.0
@@ -1,6 +0,23 @@ | ||
<a name="1.2.1"></a> | ||
## 1.2.1 (2017-04-02) | ||
<a name="2.0.0"></a> | ||
# 2.0.0 (2017-04-05) | ||
<a name="2.0.0"></a> | ||
# 2.0.0 (2017-04-05) | ||
### Code Refactoring | ||
* **refactor:** refactor the tag component to use styled-components ([7a7a513](https://bitbucket.org/atlassian/atlaskit/commits/7a7a513)) | ||
### BREAKING CHANGES | ||
* **refactor:** added peerDependency "styled-components", removed dependency "classnames" | ||
ISSUES CLOSED: AK-2033 | ||
<a name="1.2.1"></a> | ||
@@ -7,0 +24,0 @@ ## 1.2.1 (2017-04-02) |
@@ -68,13 +68,4 @@ module.exports = /******/ | ||
function(module, exports, __webpack_require__) { | ||
module.exports = __webpack_require__(10); | ||
module.exports = __webpack_require__(1); | ||
}, /* 1 */ | ||
, /* 2 */ | ||
, /* 3 */ | ||
, /* 4 */ | ||
, /* 5 */ | ||
, /* 6 */ | ||
, /* 7 */ | ||
, /* 8 */ | ||
, /* 9 */ | ||
, /* 10 */ | ||
/***/ | ||
@@ -90,4 +81,18 @@ function(module, exports, __webpack_require__) { | ||
value: !0 | ||
}), exports.default = void 0; | ||
var _Tag = __webpack_require__(2), _Tag2 = _interopRequireDefault(_Tag); | ||
exports.default = _Tag2.default; | ||
}, /* 2 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), _Root = __webpack_require__(17), _Root2 = _interopRequireDefault(_Root), _AnimationWrapper = __webpack_require__(22), _AnimationWrapper2 = _interopRequireDefault(_AnimationWrapper), _Chrome = __webpack_require__(25), _Chrome2 = _interopRequireDefault(_Chrome), _Content = __webpack_require__(27), _Content2 = _interopRequireDefault(_Content), _RemoveButton = __webpack_require__(30), _RemoveButton2 = _interopRequireDefault(_RemoveButton), _ElemBefore = __webpack_require__(32), _ElemBefore2 = _interopRequireDefault(_ElemBefore), Tag = function(_PureComponent) { | ||
var _extends2 = __webpack_require__(3), _extends3 = _interopRequireDefault(_extends2), _getPrototypeOf = __webpack_require__(4), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(5), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(6), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(7), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(8), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(9), _react2 = _interopRequireDefault(_react), _Chrome = __webpack_require__(10), _Chrome2 = _interopRequireDefault(_Chrome), _Content = __webpack_require__(16), _Content2 = _interopRequireDefault(_Content), _Remove = __webpack_require__(18), _Remove2 = _interopRequireDefault(_Remove), _Before = __webpack_require__(21), _Before2 = _interopRequireDefault(_Before), _Container = __webpack_require__(22), _Container2 = _interopRequireDefault(_Container), Tag = function(_PureComponent) { | ||
function Tag(props) { | ||
@@ -97,3 +102,3 @@ (0, _classCallCheck3.default)(this, Tag); | ||
_getPrototypeOf2.default)(Tag)).call(this, props)); | ||
return _this.handleRemoveAction = function() { | ||
return _this.handleRemoveRequest = function() { | ||
_this.props.onBeforeRemoveAction() && _this.setState({ | ||
@@ -103,2 +108,7 @@ isRemoving: !0, | ||
}); | ||
}, _this.handleRemoveComplete = function() { | ||
_this.props.onAfterRemoveAction(_this.props.text), _this.setState({ | ||
isRemoving: !1, | ||
isRemoved: !0 | ||
}); | ||
}, _this.handleHoverChange = function(hoverState) { | ||
@@ -108,7 +118,6 @@ _this.setState({ | ||
}); | ||
}, _this.handleRemovalCompletion = function() { | ||
}, _this.handleFocusChange = function(focusState) { | ||
_this.setState({ | ||
isRemoving: !1, | ||
isRemoved: !0 | ||
}), _this.props.onAfterRemoveAction(_this.props.text); | ||
isFocused: focusState | ||
}); | ||
}, _this.state = { | ||
@@ -123,20 +132,25 @@ isRemoving: !1, | ||
value: function() { | ||
var newButton = this.props.removeButtonText ? _react2.default.createElement(_RemoveButton2.default, { | ||
removeText: this.props.removeButtonText, | ||
isRounded: "rounded" === this.props.appearance, | ||
var _this2 = this, _state = this.state, isFocused = _state.isFocused, isRemoved = _state.isRemoved, isRemoving = _state.isRemoving, markedForRemoval = _state.markedForRemoval, _props = this.props, appearance = _props.appearance, elemBefore = _props.elemBefore, href = _props.href, removeButtonText = _props.removeButtonText, text = _props.text, isRemovable = Boolean(removeButtonText), isRounded = "rounded" === appearance, styled = { | ||
isFocused: isFocused, | ||
isRemovable: isRemovable, | ||
isRemoved: isRemoved, | ||
isRemoving: isRemoving, | ||
isRounded: isRounded, | ||
markedForRemoval: markedForRemoval | ||
}, onAnimationEnd = function(e) { | ||
return isRemoving && _this2.handleRemoveComplete(e); | ||
}; | ||
return _react2.default.createElement(_Container2.default, (0, _extends3.default)({}, styled, { | ||
onAnimationEnd: onAnimationEnd | ||
}), _react2.default.createElement(_Chrome2.default, (0, _extends3.default)({}, styled, { | ||
isLink: !!href, | ||
onFocusChange: this.handleFocusChange | ||
}), elemBefore ? _react2.default.createElement(_Before2.default, null, elemBefore) : null, _react2.default.createElement(_Content2.default, (0, | ||
_extends3.default)({}, styled, { | ||
href: href | ||
}), text), isRemovable ? _react2.default.createElement(_Remove2.default, (0, _extends3.default)({}, styled, { | ||
onHoverChange: this.handleHoverChange, | ||
onRemoveAction: this.handleRemoveAction | ||
}) : null; | ||
return _react2.default.createElement(_Root2.default, null, _react2.default.createElement(_AnimationWrapper2.default, { | ||
isRemoving: this.state.isRemoving, | ||
isRemoved: this.state.isRemoved, | ||
onRemovalCompletion: this.handleRemovalCompletion | ||
}, _react2.default.createElement(_Chrome2.default, { | ||
isRounded: "rounded" === this.props.appearance, | ||
isLink: !!this.props.href, | ||
markedForRemoval: this.state.markedForRemoval, | ||
isRemovable: !!this.props.removeButtonText | ||
}, _react2.default.createElement(_ElemBefore2.default, null, this.props.elemBefore), _react2.default.createElement(_Content2.default, { | ||
href: this.props.href | ||
}, this.props.text), newButton))); | ||
onRemoveAction: this.handleRemoveRequest, | ||
removeText: removeButtonText | ||
})) : null)); | ||
} | ||
@@ -146,3 +160,3 @@ } ]), Tag; | ||
Tag.propTypes = { | ||
appearance: _react.PropTypes.oneOf("default", "rounded"), | ||
appearance: _react.PropTypes.oneOf([ "default", "rounded" ]), | ||
elemBefore: _react.PropTypes.node, | ||
@@ -162,27 +176,31 @@ text: _react.PropTypes.string.isRequired, | ||
}, exports.default = Tag; | ||
}, /* 11 */ | ||
}, /* 3 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("babel-runtime/helpers/extends"); | ||
}, /* 4 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("babel-runtime/core-js/object/get-prototype-of"); | ||
}, /* 12 */ | ||
}, /* 5 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("babel-runtime/helpers/classCallCheck"); | ||
}, /* 13 */ | ||
}, /* 6 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("babel-runtime/helpers/createClass"); | ||
}, /* 14 */ | ||
}, /* 7 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("babel-runtime/helpers/possibleConstructorReturn"); | ||
}, /* 15 */ | ||
}, /* 8 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("babel-runtime/helpers/inherits"); | ||
}, /* 16 */ | ||
}, /* 9 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("react"); | ||
}, /* 17 */ | ||
}, /* 10 */ | ||
/***/ | ||
@@ -199,246 +217,51 @@ function(module, exports, __webpack_require__) { | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), Root = function(_PureComponent) { | ||
function Root() { | ||
return (0, _classCallCheck3.default)(this, Root), (0, _possibleConstructorReturn3.default)(this, (Root.__proto__ || (0, | ||
_getPrototypeOf2.default)(Root)).apply(this, arguments)); | ||
var _getPrototypeOf = __webpack_require__(4), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(5), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(6), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(7), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(8), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(9), _react2 = _interopRequireDefault(_react), _Chrome = __webpack_require__(11), _Chrome2 = _interopRequireDefault(_Chrome), Chrome = function(_PureComponent) { | ||
function Chrome() { | ||
var _ref, _temp, _this, _ret; | ||
(0, _classCallCheck3.default)(this, Chrome); | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = Chrome.__proto__ || (0, | ||
_getPrototypeOf2.default)(Chrome)).call.apply(_ref, [ this ].concat(args))), _this.handleKeyPress = function(e) { | ||
var spacebarOrEnter = " " === e.key || "Enter" === e.key; | ||
_this.chromeRef && spacebarOrEnter && _this.chromeRef.querySelector("a").click(); | ||
}, _this.handleBlur = function() { | ||
_this.props.onFocusChange(!1); | ||
}, _this.handleFocus = function(e) { | ||
e.target === _this.chromeRef && _this.props.onFocusChange(!0); | ||
}, _ret = _temp, (0, _possibleConstructorReturn3.default)(_this, _ret); | ||
} | ||
return (0, _inherits3.default)(Root, _PureComponent), (0, _createClass3.default)(Root, [ { | ||
return (0, _inherits3.default)(Chrome, _PureComponent), (0, _createClass3.default)(Chrome, [ { | ||
key: "render", | ||
value: function() { | ||
return _react2.default.createElement("div", { | ||
className: _styles2.default.rootWrapper | ||
}, this.props.children); | ||
var _this2 = this, _props = this.props, children = _props.children, isLink = _props.isLink, isRemovable = _props.isRemovable, isRemoved = _props.isRemoved, isRemoving = _props.isRemoving, isRounded = _props.isRounded, markedForRemoval = _props.markedForRemoval, props = { | ||
innerRef: function(r) { | ||
return _this2.chromeRef = r; | ||
}, | ||
isRemovable: isRemovable, | ||
isRemoved: isRemoved, | ||
isRemoving: isRemoving, | ||
isRounded: isRounded, | ||
markedForRemoval: markedForRemoval, | ||
onBlur: this.handleBlur, | ||
onFocus: this.handleFocus, | ||
onKeyPress: this.handleKeyPress, | ||
tabIndex: -1 | ||
}; | ||
return isLink && (props.role = "link", props.tabIndex = 0), _react2.default.createElement(_Chrome2.default, props, children); | ||
} | ||
} ]), Root; | ||
} ]), Chrome; | ||
}(_react.PureComponent); | ||
Root.propTypes = { | ||
children: _react.PropTypes.element.isRequired | ||
}, exports.default = Root; | ||
}, /* 18 */ | ||
Chrome.propTypes = { | ||
children: _react.PropTypes.arrayOf(_react.PropTypes.element).isRequired, | ||
isLink: _react.PropTypes.bool.isRequired, | ||
isRemovable: _react.PropTypes.bool.isRequired, | ||
isRemoved: _react.PropTypes.bool, | ||
isRemoving: _react.PropTypes.bool, | ||
isRounded: _react.PropTypes.bool, | ||
markedForRemoval: _react.PropTypes.bool.isRequired, | ||
onFocusChange: _react.PropTypes.func.isRequired | ||
}, exports.default = Chrome; | ||
}, /* 11 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
// style-loader: Adds some css to the DOM by adding a <style> tag | ||
// load the styles | ||
var content = __webpack_require__(19); | ||
"string" == typeof content && (content = [ [ module.id, content, "" ] ]); | ||
// add the styles to the DOM | ||
__webpack_require__(21)(content, {}); | ||
content.locals && (module.exports = content.locals); | ||
}, /* 19 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
exports = module.exports = __webpack_require__(20)(), // imports | ||
// module | ||
exports.push([ module.id, "@-webkit-keyframes c8YDaMjPLGhPQw2bsAggp{0%{max-width:200px;-webkit-animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192);animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192)}20%{max-width:40px;-webkit-animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1);animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1)}to{max-width:0}}@keyframes c8YDaMjPLGhPQw2bsAggp{0%{max-width:200px;-webkit-animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192);animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192)}20%{max-width:40px;-webkit-animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1);animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1)}to{max-width:0}}._2nKfaHK7YexQoxscVXc48M{display:inline-block}.k1zkuPFwI6t282KxhUhaa{background-color:#f4f5f7;border-radius:3px;cursor:default;display:-webkit-box;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;height:20px;line-height:1;margin:4px;padding:0}.k1zkuPFwI6t282KxhUhaa:focus{outline:none;box-shadow:0 0 0 2px #4c9aff}.k1zkuPFwI6t282KxhUhaa:hover{box-shadow:none;background-color:#ebecf0}.k1zkuPFwI6t282KxhUhaa:hover ._2bOaNKPmrKzqqIyxB4R9T7:focus{outline:none;box-shadow:0 0 0 2px #4c9aff}.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT{background-color:#ffebe6}.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT ._1tKmcJkhokQ0iCuG-BUei7,.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT ._8PiiZThnxHCBJjzovO9H5{color:#bf2600}.k1zkuPFwI6t282KxhUhaa:focus ._1tKmcJkhokQ0iCuG-BUei7{color:#0052cc}.k1zkuPFwI6t282KxhUhaa._15kEhFIXh8vbHb0gJ8n1x1 ._1tKmcJkhokQ0iCuG-BUei7,.k1zkuPFwI6t282KxhUhaa._15kEhFIXh8vbHb0gJ8n1x1 ._8PiiZThnxHCBJjzovO9H5{max-width:160px}.NvkdDL8o1_BXg1qhGigLy{box-sizing:border-box}.NvkdDL8o1_BXg1qhGigLy._10_GhJMwEUjnj4lZPUh7Og{-webkit-animation:c8YDaMjPLGhPQw2bsAggp .25s forwards;animation:c8YDaMjPLGhPQw2bsAggp .25s forwards;will-change:width}.NvkdDL8o1_BXg1qhGigLy._10_GhJMwEUjnj4lZPUh7Og .k1zkuPFwI6t282KxhUhaa{overflow:hidden}.NvkdDL8o1_BXg1qhGigLy._3dNbnOxM7yktRXz5klofeh{width:0;visibility:hidden}.NvkdDL8o1_BXg1qhGigLy._3dNbnOxM7yktRXz5klofeh .k1zkuPFwI6t282KxhUhaa{overflow:hidden}._8PiiZThnxHCBJjzovO9H5{color:#253858;font-size:14px;font-weight:400;line-height:1;margin-left:4px;margin-right:4px;padding:2px 0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._1tKmcJkhokQ0iCuG-BUei7{color:#253858;font-size:14px;font-weight:400;line-height:1;margin-left:4px;margin-right:4px;padding:2px 0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-decoration:none}._1tKmcJkhokQ0iCuG-BUei7:hover{color:#0052cc}._2bOaNKPmrKzqqIyxB4R9T7{-webkit-box-align:center;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:none;border-radius:3px;color:#42526e;display:-webkit-box;display:flex;-webkit-box-pack:center;justify-content:center;margin:0;padding:0}._2bOaNKPmrKzqqIyxB4R9T7:focus{outline:none;box-shadow:0 0 0 2px #ff5630}._2bOaNKPmrKzqqIyxB4R9T7::-moz-focus-inner{border:0;margin:0;padding:0}._2bOaNKPmrKzqqIyxB4R9T7:hover{color:#bf2600}._3i3sjP1d-w5pp_bwJ22xni{display:-webkit-box;display:flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;padding-left:4px}.fFu4yKO7ALrYA-JRwAA8q{border-radius:10px}", "" ]), | ||
// exports | ||
exports.locals = { | ||
rootWrapper: "_2nKfaHK7YexQoxscVXc48M", | ||
rootWrapper: "_2nKfaHK7YexQoxscVXc48M", | ||
chrome: "k1zkuPFwI6t282KxhUhaa", | ||
chrome: "k1zkuPFwI6t282KxhUhaa", | ||
button: "_2bOaNKPmrKzqqIyxB4R9T7", | ||
button: "_2bOaNKPmrKzqqIyxB4R9T7", | ||
markedForRemoval: "_1EI490l8oW5nSY5b-OQXRT", | ||
markedForRemoval: "_1EI490l8oW5nSY5b-OQXRT", | ||
href: "_1tKmcJkhokQ0iCuG-BUei7", | ||
href: "_1tKmcJkhokQ0iCuG-BUei7", | ||
text: "_8PiiZThnxHCBJjzovO9H5", | ||
text: "_8PiiZThnxHCBJjzovO9H5", | ||
isRemovable: "_15kEhFIXh8vbHb0gJ8n1x1", | ||
isRemovable: "_15kEhFIXh8vbHb0gJ8n1x1", | ||
animationWrapper: "NvkdDL8o1_BXg1qhGigLy", | ||
animationWrapper: "NvkdDL8o1_BXg1qhGigLy", | ||
isRemoving: "_10_GhJMwEUjnj4lZPUh7Og", | ||
isRemoving: "_10_GhJMwEUjnj4lZPUh7Og", | ||
removeAnimation: "c8YDaMjPLGhPQw2bsAggp", | ||
removeAnimation: "c8YDaMjPLGhPQw2bsAggp", | ||
isRemoved: "_3dNbnOxM7yktRXz5klofeh", | ||
isRemoved: "_3dNbnOxM7yktRXz5klofeh", | ||
elemBefore: "_3i3sjP1d-w5pp_bwJ22xni", | ||
elemBefore: "_3i3sjP1d-w5pp_bwJ22xni", | ||
rounded: "fFu4yKO7ALrYA-JRwAA8q", | ||
rounded: "fFu4yKO7ALrYA-JRwAA8q" | ||
}; | ||
}, /* 20 */ | ||
/***/ | ||
function(module, exports) { | ||
/* | ||
MIT License http://www.opensource.org/licenses/mit-license.php | ||
Author Tobias Koppers @sokra | ||
*/ | ||
// css base code, injected by the css-loader | ||
module.exports = function() { | ||
var list = []; | ||
// return the list of modules as css string | ||
// import a list of modules into the list | ||
return list.toString = function() { | ||
for (var result = [], i = 0; i < this.length; i++) { | ||
var item = this[i]; | ||
item[2] ? result.push("@media " + item[2] + "{" + item[1] + "}") : result.push(item[1]); | ||
} | ||
return result.join(""); | ||
}, list.i = function(modules, mediaQuery) { | ||
"string" == typeof modules && (modules = [ [ null, modules, "" ] ]); | ||
for (var alreadyImportedModules = {}, i = 0; i < this.length; i++) { | ||
var id = this[i][0]; | ||
"number" == typeof id && (alreadyImportedModules[id] = !0); | ||
} | ||
for (i = 0; i < modules.length; i++) { | ||
var item = modules[i]; | ||
// skip already imported module | ||
// this implementation is not 100% perfect for weird media query combinations | ||
// when a module is imported multiple times with different media queries. | ||
// I hope this will never occur (Hey this way we have smaller bundles) | ||
"number" == typeof item[0] && alreadyImportedModules[item[0]] || (mediaQuery && !item[2] ? item[2] = mediaQuery : mediaQuery && (item[2] = "(" + item[2] + ") and (" + mediaQuery + ")"), | ||
list.push(item)); | ||
} | ||
}, list; | ||
}; | ||
}, /* 21 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
function addStylesToDom(styles, options) { | ||
for (var i = 0; i < styles.length; i++) { | ||
var item = styles[i], domStyle = stylesInDom[item.id]; | ||
if (domStyle) { | ||
domStyle.refs++; | ||
for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](item.parts[j]); | ||
for (;j < item.parts.length; j++) domStyle.parts.push(addStyle(item.parts[j], options)); | ||
} else { | ||
for (var parts = [], j = 0; j < item.parts.length; j++) parts.push(addStyle(item.parts[j], options)); | ||
stylesInDom[item.id] = { | ||
id: item.id, | ||
refs: 1, | ||
parts: parts | ||
}; | ||
} | ||
} | ||
} | ||
function listToStyles(list) { | ||
for (var styles = [], newStyles = {}, i = 0; i < list.length; i++) { | ||
var item = list[i], id = item[0], css = item[1], media = item[2], sourceMap = item[3], part = { | ||
css: css, | ||
media: media, | ||
sourceMap: sourceMap | ||
}; | ||
newStyles[id] ? newStyles[id].parts.push(part) : styles.push(newStyles[id] = { | ||
id: id, | ||
parts: [ part ] | ||
}); | ||
} | ||
return styles; | ||
} | ||
function insertStyleElement(options, styleElement) { | ||
var head = getHeadElement(), lastStyleElementInsertedAtTop = styleElementsInsertedAtTop[styleElementsInsertedAtTop.length - 1]; | ||
if ("top" === options.insertAt) lastStyleElementInsertedAtTop ? lastStyleElementInsertedAtTop.nextSibling ? head.insertBefore(styleElement, lastStyleElementInsertedAtTop.nextSibling) : head.appendChild(styleElement) : head.insertBefore(styleElement, head.firstChild), | ||
styleElementsInsertedAtTop.push(styleElement); else { | ||
if ("bottom" !== options.insertAt) throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'."); | ||
head.appendChild(styleElement); | ||
} | ||
} | ||
function removeStyleElement(styleElement) { | ||
styleElement.parentNode.removeChild(styleElement); | ||
var idx = styleElementsInsertedAtTop.indexOf(styleElement); | ||
idx >= 0 && styleElementsInsertedAtTop.splice(idx, 1); | ||
} | ||
function createStyleElement(options) { | ||
var styleElement = document.createElement("style"); | ||
return styleElement.type = "text/css", insertStyleElement(options, styleElement), | ||
styleElement; | ||
} | ||
function createLinkElement(options) { | ||
var linkElement = document.createElement("link"); | ||
return linkElement.rel = "stylesheet", insertStyleElement(options, linkElement), | ||
linkElement; | ||
} | ||
function addStyle(obj, options) { | ||
var styleElement, update, remove; | ||
if (options.singleton) { | ||
var styleIndex = singletonCounter++; | ||
styleElement = singletonElement || (singletonElement = createStyleElement(options)), | ||
update = applyToSingletonTag.bind(null, styleElement, styleIndex, !1), remove = applyToSingletonTag.bind(null, styleElement, styleIndex, !0); | ||
} else obj.sourceMap && "function" == typeof URL && "function" == typeof URL.createObjectURL && "function" == typeof URL.revokeObjectURL && "function" == typeof Blob && "function" == typeof btoa ? (styleElement = createLinkElement(options), | ||
update = updateLink.bind(null, styleElement), remove = function() { | ||
removeStyleElement(styleElement), styleElement.href && URL.revokeObjectURL(styleElement.href); | ||
}) : (styleElement = createStyleElement(options), update = applyToTag.bind(null, styleElement), | ||
remove = function() { | ||
removeStyleElement(styleElement); | ||
}); | ||
return update(obj), function(newObj) { | ||
if (newObj) { | ||
if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap) return; | ||
update(obj = newObj); | ||
} else remove(); | ||
}; | ||
} | ||
function applyToSingletonTag(styleElement, index, remove, obj) { | ||
var css = remove ? "" : obj.css; | ||
if (styleElement.styleSheet) styleElement.styleSheet.cssText = replaceText(index, css); else { | ||
var cssNode = document.createTextNode(css), childNodes = styleElement.childNodes; | ||
childNodes[index] && styleElement.removeChild(childNodes[index]), childNodes.length ? styleElement.insertBefore(cssNode, childNodes[index]) : styleElement.appendChild(cssNode); | ||
} | ||
} | ||
function applyToTag(styleElement, obj) { | ||
var css = obj.css, media = obj.media; | ||
if (media && styleElement.setAttribute("media", media), styleElement.styleSheet) styleElement.styleSheet.cssText = css; else { | ||
for (;styleElement.firstChild; ) styleElement.removeChild(styleElement.firstChild); | ||
styleElement.appendChild(document.createTextNode(css)); | ||
} | ||
} | ||
function updateLink(linkElement, obj) { | ||
var css = obj.css, sourceMap = obj.sourceMap; | ||
sourceMap && (// http://stackoverflow.com/a/26603875 | ||
css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */"); | ||
var blob = new Blob([ css ], { | ||
type: "text/css" | ||
}), oldSrc = linkElement.href; | ||
linkElement.href = URL.createObjectURL(blob), oldSrc && URL.revokeObjectURL(oldSrc); | ||
} | ||
/* | ||
MIT License http://www.opensource.org/licenses/mit-license.php | ||
Author Tobias Koppers @sokra | ||
*/ | ||
var stylesInDom = {}, memoize = function(fn) { | ||
var memo; | ||
return function() { | ||
return "undefined" == typeof memo && (memo = fn.apply(this, arguments)), memo; | ||
}; | ||
}, isOldIE = memoize(function() { | ||
return /msie [6-9]\b/.test(window.navigator.userAgent.toLowerCase()); | ||
}), getHeadElement = memoize(function() { | ||
return document.head || document.getElementsByTagName("head")[0]; | ||
}), singletonElement = null, singletonCounter = 0, styleElementsInsertedAtTop = []; | ||
module.exports = function(list, options) { | ||
options = options || {}, // Force single-tag solution on IE6-9, which has a hard limit on the # of <style> | ||
// tags it will allow on a page | ||
"undefined" == typeof options.singleton && (options.singleton = isOldIE()), // By default, add <style> tags to the bottom of <head>. | ||
"undefined" == typeof options.insertAt && (options.insertAt = "bottom"); | ||
var styles = listToStyles(list); | ||
return addStylesToDom(styles, options), function(newList) { | ||
for (var mayRemove = [], i = 0; i < styles.length; i++) { | ||
var item = styles[i], domStyle = stylesInDom[item.id]; | ||
domStyle.refs--, mayRemove.push(domStyle); | ||
} | ||
if (newList) { | ||
var newStyles = listToStyles(newList); | ||
addStylesToDom(newStyles, options); | ||
} | ||
for (var i = 0; i < mayRemove.length; i++) { | ||
var domStyle = mayRemove[i]; | ||
if (0 === domStyle.refs) { | ||
for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](); | ||
delete stylesInDom[domStyle.id]; | ||
} | ||
} | ||
}; | ||
}; | ||
var replaceText = function() { | ||
var textStore = []; | ||
return function(index, replacement) { | ||
return textStore[index] = replacement, textStore.filter(Boolean).join("\n"); | ||
}; | ||
}(); | ||
}, /* 22 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
@@ -453,101 +276,43 @@ function _interopRequireDefault(obj) { | ||
}); | ||
var _defineProperty2 = __webpack_require__(23), _defineProperty3 = _interopRequireDefault(_defineProperty2), _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _classnames = __webpack_require__(24), _classnames2 = _interopRequireDefault(_classnames), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), AnimationWrapper = function(_PureComponent) { | ||
function AnimationWrapper() { | ||
var _ref, _temp, _this, _ret; | ||
(0, _classCallCheck3.default)(this, AnimationWrapper); | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = AnimationWrapper.__proto__ || (0, | ||
_getPrototypeOf2.default)(AnimationWrapper)).call.apply(_ref, [ this ].concat(args))), | ||
_this.handleAnimationEnd = function(e) { | ||
e.animationName === _styles2.default.removeAnimation && _this.props.onRemovalCompletion(); | ||
}, _ret = _temp, (0, _possibleConstructorReturn3.default)(_this, _ret); | ||
} | ||
return (0, _inherits3.default)(AnimationWrapper, _PureComponent), (0, _createClass3.default)(AnimationWrapper, [ { | ||
key: "render", | ||
value: function() { | ||
var _classNames, _props = this.props, isRemoving = _props.isRemoving, isRemoved = _props.isRemoved, animationWrapperClasses = (0, | ||
_classnames2.default)((_classNames = {}, (0, _defineProperty3.default)(_classNames, _styles2.default.animationWrapper, !0), | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.isRemoving, isRemoving), | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.isRemoved, isRemoved), | ||
_classNames)); | ||
return _react2.default.createElement("div", { | ||
className: animationWrapperClasses, | ||
onAnimationEnd: this.handleAnimationEnd | ||
}, this.props.children); | ||
} | ||
} ]), AnimationWrapper; | ||
}(_react.PureComponent); | ||
AnimationWrapper.propTypes = { | ||
isRemoving: _react.PropTypes.bool, | ||
isRemoved: _react.PropTypes.bool, | ||
children: _react.PropTypes.node.isRequired, | ||
onRemovalCompletion: _react.PropTypes.func | ||
}, AnimationWrapper.defaultProps = { | ||
onRemovalCompletion: function() {}, | ||
isRemoving: !1, | ||
isRemoved: !1 | ||
}, exports.default = AnimationWrapper; | ||
}, /* 23 */ | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n ", ";\n background-color: ", ";\n border-radius: ", ";\n cursor: default;\n display: flex;\n height: ", ";\n line-height: 1;\n margin: ", "px;\n padding: 0;\n overflow: ", ";\n\n &:hover {\n ", ";\n background-color: ", ";\n }\n" ], [ "\n ", ";\n background-color: ", ";\n border-radius: ", ";\n cursor: default;\n display: flex;\n height: ", ";\n line-height: 1;\n margin: ", "px;\n padding: 0;\n overflow: ", ";\n\n &:hover {\n ", ";\n background-color: ", ";\n }\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _utilSharedStyles = __webpack_require__(14), _constants = __webpack_require__(15); | ||
exports.default = _styledComponents2.default.span(_templateObject, _utilSharedStyles.akHelperMixins.focusRing.default, function(_ref) { | ||
var markedForRemoval = _ref.markedForRemoval; | ||
return markedForRemoval ? _utilSharedStyles.akColorR50 : _utilSharedStyles.akColorN20; | ||
}, function(_ref2) { | ||
var isRounded = _ref2.isRounded; | ||
return isRounded ? _constants.buttonWidthUnitless / 2 + "px" : _constants.borderRadius; | ||
}, _constants.tagHeight, _utilSharedStyles.akGridSizeUnitless / 2, function(_ref3) { | ||
var isRemoved = _ref3.isRemoved, isRemoving = _ref3.isRemoving; | ||
return isRemoved || isRemoving ? "hidden" : "initial"; | ||
}, _utilSharedStyles.akHelperMixins.focusRing.none, function(_ref4) { | ||
var markedForRemoval = _ref4.markedForRemoval; | ||
return markedForRemoval ? _utilSharedStyles.akColorR50 : _utilSharedStyles.akColorN30; | ||
}); | ||
}, /* 12 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("babel-runtime/helpers/defineProperty"); | ||
}, /* 24 */ | ||
module.exports = require("babel-runtime/helpers/taggedTemplateLiteral"); | ||
}, /* 13 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("classnames"); | ||
}, /* 25 */ | ||
module.exports = require("styled-components"); | ||
}, /* 14 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("@atlaskit/util-shared-styles"); | ||
}, /* 15 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _extends2 = __webpack_require__(26), _extends3 = _interopRequireDefault(_extends2), _defineProperty2 = __webpack_require__(23), _defineProperty3 = _interopRequireDefault(_defineProperty2), _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _classnames = __webpack_require__(24), _classnames2 = _interopRequireDefault(_classnames), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), Chrome = function(_PureComponent) { | ||
function Chrome() { | ||
var _ref, _temp, _this, _ret; | ||
(0, _classCallCheck3.default)(this, Chrome); | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = Chrome.__proto__ || (0, | ||
_getPrototypeOf2.default)(Chrome)).call.apply(_ref, [ this ].concat(args))), _this.refLinkTag = function(linkTag) { | ||
_this.chromeLink = linkTag; | ||
}, _this.handleKeyPress = function(e) { | ||
32 !== e.charCode && 13 !== e.charCode || _this.chromeLink && _this.chromeLink.querySelector("a").click(); | ||
}, _ret = _temp, (0, _possibleConstructorReturn3.default)(_this, _ret); | ||
} | ||
return (0, _inherits3.default)(Chrome, _PureComponent), (0, _createClass3.default)(Chrome, [ { | ||
key: "render", | ||
value: function() { | ||
var _classNames, chromeClassNames = (0, _classnames2.default)((_classNames = {}, | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.chrome, !0), (0, _defineProperty3.default)(_classNames, _styles2.default.rounded, this.props.isRounded), | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.markedForRemoval, this.props.markedForRemoval), | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.isRemovable, this.props.isRemovable), | ||
_classNames)), chromeProps = {}; | ||
return this.props.isLink ? (chromeProps.role = "link", chromeProps.ref = "chromeLink", | ||
chromeProps.tabIndex = 0) : chromeProps.tabIndex = -1, _react2.default.createElement("span", (0, | ||
_extends3.default)({}, chromeProps, { | ||
ref: this.refLinkTag, | ||
className: chromeClassNames, | ||
onKeyPress: this.handleKeyPress | ||
}), this.props.children); | ||
} | ||
} ]), Chrome; | ||
}(_react.PureComponent); | ||
Chrome.propTypes = { | ||
isRounded: _react.PropTypes.bool, | ||
isLink: _react.PropTypes.bool.isRequired, | ||
markedForRemoval: _react.PropTypes.bool.isRequired, | ||
isRemovable: _react.PropTypes.bool.isRequired, | ||
children: _react.PropTypes.arrayOf(_react.PropTypes.element).isRequired | ||
}, exports.default = Chrome; | ||
}, /* 26 */ | ||
}), exports.maxTextWidth = exports.maxTextWidthUnitless = exports.maxWidth = exports.maxWidthUnitless = exports.buttonWidth = exports.buttonWidthUnitless = exports.tagHeight = exports.tagHeightUnitless = exports.fontSize = exports.borderRadius = void 0; | ||
var _utilSharedStyles = __webpack_require__(14), tagHeightUnitless = (exports.borderRadius = _utilSharedStyles.akBorderRadius, | ||
exports.fontSize = _utilSharedStyles.akFontSizeDefault, exports.tagHeightUnitless = 2.5 * _utilSharedStyles.akGridSizeUnitless), tagHeight = exports.tagHeight = tagHeightUnitless + "px", maxWidthUnitless = (exports.buttonWidthUnitless = tagHeightUnitless, | ||
exports.buttonWidth = tagHeight, exports.maxWidthUnitless = 25 * _utilSharedStyles.akGridSizeUnitless), maxTextWidthUnitless = (exports.maxWidth = maxWidthUnitless + "px", | ||
exports.maxTextWidthUnitless = maxWidthUnitless - tagHeightUnitless); | ||
exports.maxTextWidth = maxTextWidthUnitless + "px"; | ||
}, /* 16 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("babel-runtime/helpers/extends"); | ||
}, /* 27 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
@@ -563,3 +328,3 @@ "use strict"; | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), _Text = __webpack_require__(28), _Text2 = _interopRequireDefault(_Text), _Link = __webpack_require__(29), _Link2 = _interopRequireDefault(_Link), Content = function(_PureComponent) { | ||
var _extends2 = __webpack_require__(3), _extends3 = _interopRequireDefault(_extends2), _getPrototypeOf = __webpack_require__(4), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(5), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(6), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(7), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(8), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(9), _react2 = _interopRequireDefault(_react), _Content = __webpack_require__(17), Content = function(_PureComponent) { | ||
function Content() { | ||
@@ -572,5 +337,11 @@ return (0, _classCallCheck3.default)(this, Content), (0, _possibleConstructorReturn3.default)(this, (Content.__proto__ || (0, | ||
value: function() { | ||
return this.props.href ? _react2.default.createElement(_Link2.default, { | ||
href: this.props.href | ||
}, this.props.children) : _react2.default.createElement(_Text2.default, null, this.props.children); | ||
var _props = this.props, children = _props.children, href = _props.href, isFocused = _props.isFocused, isRemovable = _props.isRemovable, markedForRemoval = _props.markedForRemoval, styledProps = { | ||
isFocused: isFocused, | ||
isRemovable: isRemovable, | ||
markedForRemoval: markedForRemoval | ||
}; | ||
return href ? _react2.default.createElement(_Content.Link, (0, _extends3.default)({}, styledProps, { | ||
href: href, | ||
tabIndex: "-1" | ||
}), children) : _react2.default.createElement(_Content.Text, styledProps, children); | ||
} | ||
@@ -580,6 +351,9 @@ } ]), Content; | ||
Content.propTypes = { | ||
children: _react.PropTypes.node.isRequired, | ||
href: _react.PropTypes.string, | ||
children: _react.PropTypes.node.isRequired | ||
isFocused: _react.PropTypes.bool, | ||
isRemovable: _react.PropTypes.bool, | ||
markedForRemoval: _react.PropTypes.bool | ||
}, exports.default = Content; | ||
}, /* 28 */ | ||
}, /* 17 */ | ||
/***/ | ||
@@ -595,21 +369,19 @@ function(module, exports, __webpack_require__) { | ||
value: !0 | ||
}), exports.Link = exports.Text = void 0; | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n color: ", ";\n font-size: ", ";\n font-weight: normal;\n line-height: 1;\n margin-left: ", "px;\n margin-right: ", "px;\n padding: 2px 0;\n ", "\n" ], [ "\n color: ", ";\n font-size: ", ";\n font-weight: normal;\n line-height: 1;\n margin-left: ", "px;\n margin-right: ", "px;\n padding: 2px 0;\n ", "\n" ]), _templateObject2 = (0, | ||
_taggedTemplateLiteral3.default)([ "\n ", "\n" ], [ "\n ", "\n" ]), _templateObject3 = (0, | ||
_taggedTemplateLiteral3.default)([ "\n ", "\n ", "\n text-decoration: none;\n\n &:hover {\n color: ", ";\n }\n" ], [ "\n ", "\n ", "\n text-decoration: none;\n\n &:hover {\n color: ", ";\n }\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _utilSharedStyles = __webpack_require__(14), _constants = __webpack_require__(15), getColor = function(_ref) { | ||
var markedForRemoval = _ref.markedForRemoval; | ||
return markedForRemoval ? _utilSharedStyles.akColorR500 : _utilSharedStyles.akColorN700; | ||
}, getTruncate = _utilSharedStyles.akHelperMixins.text.truncate(function(_ref2) { | ||
var isRemovable = _ref2.isRemovable; | ||
return isRemovable ? _constants.maxTextWidthUnitless - _constants.buttonWidthUnitless + "px" : _constants.maxTextWidth; | ||
}), COMMON_STYLES = (0, _styledComponents.css)(_templateObject, getColor, _constants.fontSize, _utilSharedStyles.akGridSizeUnitless / 2, _utilSharedStyles.akGridSizeUnitless / 2, getTruncate), getFocusedStyles = (exports.Text = _styledComponents2.default.span(_templateObject2, COMMON_STYLES), | ||
function(_ref3) { | ||
var isFocused = _ref3.isFocused; | ||
return isFocused ? "color: " + _utilSharedStyles.akColorB400 : null; | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), Text = function(_PureComponent) { | ||
function Text() { | ||
return (0, _classCallCheck3.default)(this, Text), (0, _possibleConstructorReturn3.default)(this, (Text.__proto__ || (0, | ||
_getPrototypeOf2.default)(Text)).apply(this, arguments)); | ||
} | ||
return (0, _inherits3.default)(Text, _PureComponent), (0, _createClass3.default)(Text, [ { | ||
key: "render", | ||
value: function() { | ||
return _react2.default.createElement("span", { | ||
className: _styles2.default.text | ||
}, this.props.children); | ||
} | ||
} ]), Text; | ||
}(_react.PureComponent); | ||
Text.propTypes = { | ||
children: _react.PropTypes.node.isRequired | ||
}, exports.default = Text; | ||
}, /* 29 */ | ||
exports.Link = _styledComponents2.default.a(_templateObject3, COMMON_STYLES, getFocusedStyles, _utilSharedStyles.akColorB400); | ||
}, /* 18 */ | ||
/***/ | ||
@@ -626,43 +398,11 @@ function(module, exports, __webpack_require__) { | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), Href = function(_PureComponent) { | ||
function Href() { | ||
return (0, _classCallCheck3.default)(this, Href), (0, _possibleConstructorReturn3.default)(this, (Href.__proto__ || (0, | ||
_getPrototypeOf2.default)(Href)).apply(this, arguments)); | ||
} | ||
return (0, _inherits3.default)(Href, _PureComponent), (0, _createClass3.default)(Href, [ { | ||
key: "render", | ||
value: function() { | ||
return _react2.default.createElement("a", { | ||
tabIndex: "-1", | ||
className: _styles2.default.href, | ||
href: this.props.href | ||
}, this.props.children); | ||
} | ||
} ]), Href; | ||
}(_react.PureComponent); | ||
Href.propTypes = { | ||
href: _react.PropTypes.string.isRequired, | ||
children: _react.PropTypes.node.isRequired | ||
}, exports.default = Href; | ||
}, /* 30 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _defineProperty2 = __webpack_require__(23), _defineProperty3 = _interopRequireDefault(_defineProperty2), _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), _classnames = __webpack_require__(24), _classnames2 = _interopRequireDefault(_classnames), _cross = __webpack_require__(31), _cross2 = _interopRequireDefault(_cross), RemoveButton = function(_PureComponent) { | ||
function RemoveButton() { | ||
var _getPrototypeOf = __webpack_require__(4), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(5), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(6), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(7), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(8), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(9), _react2 = _interopRequireDefault(_react), _cross = __webpack_require__(19), _cross2 = _interopRequireDefault(_cross), _Remove = __webpack_require__(20), _Remove2 = _interopRequireDefault(_Remove), Remove = function(_PureComponent) { | ||
function Remove() { | ||
var _ref, _temp, _this, _ret; | ||
(0, _classCallCheck3.default)(this, RemoveButton); | ||
(0, _classCallCheck3.default)(this, Remove); | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = RemoveButton.__proto__ || (0, | ||
_getPrototypeOf2.default)(RemoveButton)).call.apply(_ref, [ this ].concat(args))), | ||
_this.onKeyPress = function(e) { | ||
32 !== e.charCode && 13 !== e.charCode || (e.stopPropagation(), _this.props.onRemoveAction()); | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = Remove.__proto__ || (0, | ||
_getPrototypeOf2.default)(Remove)).call.apply(_ref, [ this ].concat(args))), _this.onKeyPress = function(e) { | ||
var spacebarOrEnter = " " === e.key || "Enter" === e.key; | ||
spacebarOrEnter && (e.stopPropagation(), _this.props.onRemoveAction()); | ||
}, _this.onMouseOver = function() { | ||
@@ -674,22 +414,22 @@ _this.props.onHoverChange(!0); | ||
} | ||
return (0, _inherits3.default)(RemoveButton, _PureComponent), (0, _createClass3.default)(RemoveButton, [ { | ||
return (0, _inherits3.default)(Remove, _PureComponent), (0, _createClass3.default)(Remove, [ { | ||
key: "render", | ||
value: function() { | ||
var buttonStyles = (0, _classnames2.default)(_styles2.default.button, (0, _defineProperty3.default)({}, _styles2.default.rounded, this.props.isRounded)); | ||
return _react2.default.createElement("button", { | ||
className: buttonStyles, | ||
"aria-label": this.props.removeText, | ||
var _props = this.props, isRounded = _props.isRounded, onRemoveAction = _props.onRemoveAction, removeText = _props.removeText; | ||
return _react2.default.createElement(_Remove2.default, { | ||
"aria-label": removeText, | ||
isRounded: isRounded, | ||
onClick: onRemoveAction, | ||
onKeyPress: this.onKeyPress, | ||
onMouseOut: this.onMouseOut, | ||
onMouseOver: this.onMouseOver, | ||
onMouseOut: this.onMouseOut, | ||
onClick: this.props.onRemoveAction, | ||
onKeyPress: this.onKeyPress, | ||
type: "button" | ||
}, _react2.default.createElement(_cross2.default, { | ||
label: this.props.removeText, | ||
label: removeText, | ||
size: "small" | ||
})); | ||
} | ||
} ]), RemoveButton; | ||
} ]), Remove; | ||
}(_react.PureComponent); | ||
RemoveButton.propTypes = { | ||
Remove.propTypes = { | ||
removeText: _react.PropTypes.string.isRequired, | ||
@@ -699,8 +439,8 @@ isRounded: _react.PropTypes.bool, | ||
onRemoveAction: _react.PropTypes.func | ||
}, exports.default = RemoveButton; | ||
}, /* 31 */ | ||
}, exports.default = Remove; | ||
}, /* 19 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = require("@atlaskit/icon/glyph/cross"); | ||
}, /* 32 */ | ||
}, /* 20 */ | ||
/***/ | ||
@@ -717,19 +457,52 @@ function(module, exports, __webpack_require__) { | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), ElemBefore = function(_PureComponent) { | ||
function ElemBefore() { | ||
return (0, _classCallCheck3.default)(this, ElemBefore), (0, _possibleConstructorReturn3.default)(this, (ElemBefore.__proto__ || (0, | ||
_getPrototypeOf2.default)(ElemBefore)).apply(this, arguments)); | ||
} | ||
return (0, _inherits3.default)(ElemBefore, _PureComponent), (0, _createClass3.default)(ElemBefore, [ { | ||
key: "render", | ||
value: function() { | ||
return this.props.children ? _react2.default.createElement("span", { | ||
className: _styles2.default.elemBefore | ||
}, this.props.children) : null; | ||
} | ||
} ]), ElemBefore; | ||
}(_react.PureComponent); | ||
ElemBefore.propTypes = { | ||
children: _react.PropTypes.node | ||
}, exports.default = ElemBefore; | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n align-items: center;\n appearance: none;\n background: none;\n border: none;\n border-radius: ", ";\n color: ", ";\n display: flex;\n justify-content: center;\n margin: 0;\n padding: 0;\n\n ", "\n\n &:hover {\n color: ", ";\n ", "\n }\n\n &::-moz-focus-inner { border: 0; margin: 0; padding: 0; }\n" ], [ "\n align-items: center;\n appearance: none;\n background: none;\n border: none;\n border-radius: ", ";\n color: ", ";\n display: flex;\n justify-content: center;\n margin: 0;\n padding: 0;\n\n ", "\n\n &:hover {\n color: ", ";\n ", "\n }\n\n &::-moz-focus-inner { border: 0; margin: 0; padding: 0; }\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _utilSharedStyles = __webpack_require__(14), _constants = __webpack_require__(15); | ||
// NOTE: | ||
// "-moz-focus-inner" removes some inbuilt padding that Firefox adds (taken from reduced-ui-pack) | ||
// the focus ring is red unless combined with hover, then uses default blue | ||
exports.default = _styledComponents2.default.button(_templateObject, function(_ref) { | ||
var isRounded = _ref.isRounded; | ||
return isRounded ? _constants.buttonWidthUnitless / 2 + "px" : _constants.borderRadius; | ||
}, _utilSharedStyles.akColorN500, _utilSharedStyles.akHelperMixins.focusRing.generate(_utilSharedStyles.akColorR300), _utilSharedStyles.akColorR500, _utilSharedStyles.akHelperMixins.focusRing.default); | ||
}, /* 21 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n align-items: center;\n display: flex;\n justify-content: center;\n padding-left: ", "px;\n" ], [ "\n align-items: center;\n display: flex;\n justify-content: center;\n padding-left: ", "px;\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _utilSharedStyles = __webpack_require__(14); | ||
exports.default = _styledComponents2.default.span(_templateObject, _utilSharedStyles.akGridSizeUnitless / 2); | ||
}, /* 22 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
function getRemovedStyles(_ref) { | ||
var isRemoved = _ref.isRemoved, styles = void 0; | ||
return isRemoved && (styles = "width: 0; visibility: hidden;"), styles; | ||
} | ||
function getRemovingStyles(_ref2) { | ||
var isRemoving = _ref2.isRemoving, styles = void 0; | ||
return isRemoving && (styles = "animation: " + removeAnimation + " 250ms forwards; will-change: width;"), | ||
styles; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n 0% {\n animation-timing-function: cubic-bezier(0.23830050393398, 0, 0.25586732616931, 0.79011192334632);\n max-width: ", ";\n }\n 20% {\n animation-timing-function: cubic-bezier(0.21787238302442, 0.98324004924648, 0.58694150667646, 1);\n max-width: ", "px;\n }\n 100% { max-width: 0; }\n" ], [ "\n 0% {\n animation-timing-function: cubic-bezier(0.23830050393398, 0, 0.25586732616931, 0.79011192334632);\n max-width: ", ";\n }\n 20% {\n animation-timing-function: cubic-bezier(0.21787238302442, 0.98324004924648, 0.58694150667646, 1);\n max-width: ", "px;\n }\n 100% { max-width: 0; }\n" ]), _templateObject2 = (0, | ||
_taggedTemplateLiteral3.default)([ "\n box-sizing: border-box;\n display: inline-block;\n\n ", "\n ", "\n" ], [ "\n box-sizing: border-box;\n display: inline-block;\n\n ", "\n ", "\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _constants = __webpack_require__(15), removeAnimation = (0, | ||
_styledComponents.keyframes)(_templateObject, _constants.maxWidth, .8 * _constants.maxWidthUnitless); | ||
exports.default = _styledComponents2.default.div(_templateObject2, getRemovingStyles, getRemovedStyles); | ||
} ]); |
@@ -1,1 +0,1 @@ | ||
module.exports=function(e){function t(o){if(n[o])return n[o].exports;var r=n[o]={exports:{},id:o,loaded:!1};return e[o].call(r.exports,r,r.exports,t),r.loaded=!0,r.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){e.exports=n(10)},,,,,,,,,,function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(11),i=o(r),a=n(12),u=o(a),s=n(13),l=o(s),d=n(14),p=o(d),f=n(15),c=o(f),h=n(16),m=o(h),v=n(17),b=o(v),x=n(22),y=o(x),g=n(25),_=o(g),k=n(27),R=o(k),P=n(30),w=o(P),T=n(32),C=o(T),O=function(e){function t(e){(0,u.default)(this,t);var n=(0,p.default)(this,(t.__proto__||(0,i.default)(t)).call(this,e));return n.handleRemoveAction=function(){n.props.onBeforeRemoveAction()&&n.setState({isRemoving:!0,isRemoved:!1})},n.handleHoverChange=function(e){n.setState({markedForRemoval:e})},n.handleRemovalCompletion=function(){n.setState({isRemoving:!1,isRemoved:!0}),n.props.onAfterRemoveAction(n.props.text)},n.state={isRemoving:!1,isRemoved:!1,markedForRemoval:!1},n}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){var e=this.props.removeButtonText?m.default.createElement(w.default,{removeText:this.props.removeButtonText,isRounded:"rounded"===this.props.appearance,onHoverChange:this.handleHoverChange,onRemoveAction:this.handleRemoveAction}):null;return m.default.createElement(b.default,null,m.default.createElement(y.default,{isRemoving:this.state.isRemoving,isRemoved:this.state.isRemoved,onRemovalCompletion:this.handleRemovalCompletion},m.default.createElement(_.default,{isRounded:"rounded"===this.props.appearance,isLink:!!this.props.href,markedForRemoval:this.state.markedForRemoval,isRemovable:!!this.props.removeButtonText},m.default.createElement(C.default,null,this.props.elemBefore),m.default.createElement(R.default,{href:this.props.href},this.props.text),e)))}}]),t}(h.PureComponent);O.propTypes={appearance:h.PropTypes.oneOf("default","rounded"),elemBefore:h.PropTypes.node,text:h.PropTypes.string.isRequired,href:h.PropTypes.string,removeButtonText:h.PropTypes.string,onBeforeRemoveAction:h.PropTypes.func,onAfterRemoveAction:h.PropTypes.func},O.defaultProps={appearance:"default",elemBefore:null,onAfterRemoveAction:function(){},onBeforeRemoveAction:function(){return!0}},t.default=O},function(e,t){e.exports=require("babel-runtime/core-js/object/get-prototype-of")},function(e,t){e.exports=require("babel-runtime/helpers/classCallCheck")},function(e,t){e.exports=require("babel-runtime/helpers/createClass")},function(e,t){e.exports=require("babel-runtime/helpers/possibleConstructorReturn")},function(e,t){e.exports=require("babel-runtime/helpers/inherits")},function(e,t){e.exports=require("react")},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(11),i=o(r),a=n(12),u=o(a),s=n(13),l=o(s),d=n(14),p=o(d),f=n(15),c=o(f),h=n(18),m=o(h),v=n(16),b=o(v),x=function(e){function t(){return(0,u.default)(this,t),(0,p.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return b.default.createElement("div",{className:m.default.rootWrapper},this.props.children)}}]),t}(v.PureComponent);x.propTypes={children:v.PropTypes.element.isRequired},t.default=x},function(e,t,n){var o=n(19);"string"==typeof o&&(o=[[e.id,o,""]]),n(21)(o,{}),o.locals&&(e.exports=o.locals)},function(e,t,n){t=e.exports=n(20)(),t.push([e.id,"@-webkit-keyframes c8YDaMjPLGhPQw2bsAggp{0%{max-width:200px;-webkit-animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192);animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192)}20%{max-width:40px;-webkit-animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1);animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1)}to{max-width:0}}@keyframes c8YDaMjPLGhPQw2bsAggp{0%{max-width:200px;-webkit-animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192);animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192)}20%{max-width:40px;-webkit-animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1);animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1)}to{max-width:0}}._2nKfaHK7YexQoxscVXc48M{display:inline-block}.k1zkuPFwI6t282KxhUhaa{background-color:#f4f5f7;border-radius:3px;cursor:default;display:-webkit-box;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;height:20px;line-height:1;margin:4px;padding:0}.k1zkuPFwI6t282KxhUhaa:focus{outline:none;box-shadow:0 0 0 2px #4c9aff}.k1zkuPFwI6t282KxhUhaa:hover{box-shadow:none;background-color:#ebecf0}.k1zkuPFwI6t282KxhUhaa:hover ._2bOaNKPmrKzqqIyxB4R9T7:focus{outline:none;box-shadow:0 0 0 2px #4c9aff}.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT{background-color:#ffebe6}.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT ._1tKmcJkhokQ0iCuG-BUei7,.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT ._8PiiZThnxHCBJjzovO9H5{color:#bf2600}.k1zkuPFwI6t282KxhUhaa:focus ._1tKmcJkhokQ0iCuG-BUei7{color:#0052cc}.k1zkuPFwI6t282KxhUhaa._15kEhFIXh8vbHb0gJ8n1x1 ._1tKmcJkhokQ0iCuG-BUei7,.k1zkuPFwI6t282KxhUhaa._15kEhFIXh8vbHb0gJ8n1x1 ._8PiiZThnxHCBJjzovO9H5{max-width:160px}.NvkdDL8o1_BXg1qhGigLy{box-sizing:border-box}.NvkdDL8o1_BXg1qhGigLy._10_GhJMwEUjnj4lZPUh7Og{-webkit-animation:c8YDaMjPLGhPQw2bsAggp .25s forwards;animation:c8YDaMjPLGhPQw2bsAggp .25s forwards;will-change:width}.NvkdDL8o1_BXg1qhGigLy._10_GhJMwEUjnj4lZPUh7Og .k1zkuPFwI6t282KxhUhaa{overflow:hidden}.NvkdDL8o1_BXg1qhGigLy._3dNbnOxM7yktRXz5klofeh{width:0;visibility:hidden}.NvkdDL8o1_BXg1qhGigLy._3dNbnOxM7yktRXz5klofeh .k1zkuPFwI6t282KxhUhaa{overflow:hidden}._8PiiZThnxHCBJjzovO9H5{color:#253858;font-size:14px;font-weight:400;line-height:1;margin-left:4px;margin-right:4px;padding:2px 0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._1tKmcJkhokQ0iCuG-BUei7{color:#253858;font-size:14px;font-weight:400;line-height:1;margin-left:4px;margin-right:4px;padding:2px 0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-decoration:none}._1tKmcJkhokQ0iCuG-BUei7:hover{color:#0052cc}._2bOaNKPmrKzqqIyxB4R9T7{-webkit-box-align:center;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:none;border-radius:3px;color:#42526e;display:-webkit-box;display:flex;-webkit-box-pack:center;justify-content:center;margin:0;padding:0}._2bOaNKPmrKzqqIyxB4R9T7:focus{outline:none;box-shadow:0 0 0 2px #ff5630}._2bOaNKPmrKzqqIyxB4R9T7::-moz-focus-inner{border:0;margin:0;padding:0}._2bOaNKPmrKzqqIyxB4R9T7:hover{color:#bf2600}._3i3sjP1d-w5pp_bwJ22xni{display:-webkit-box;display:flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;padding-left:4px}.fFu4yKO7ALrYA-JRwAA8q{border-radius:10px}",""]),t.locals={rootWrapper:"_2nKfaHK7YexQoxscVXc48M",rootWrapper:"_2nKfaHK7YexQoxscVXc48M",chrome:"k1zkuPFwI6t282KxhUhaa",chrome:"k1zkuPFwI6t282KxhUhaa",button:"_2bOaNKPmrKzqqIyxB4R9T7",button:"_2bOaNKPmrKzqqIyxB4R9T7",markedForRemoval:"_1EI490l8oW5nSY5b-OQXRT",markedForRemoval:"_1EI490l8oW5nSY5b-OQXRT",href:"_1tKmcJkhokQ0iCuG-BUei7",href:"_1tKmcJkhokQ0iCuG-BUei7",text:"_8PiiZThnxHCBJjzovO9H5",text:"_8PiiZThnxHCBJjzovO9H5",isRemovable:"_15kEhFIXh8vbHb0gJ8n1x1",isRemovable:"_15kEhFIXh8vbHb0gJ8n1x1",animationWrapper:"NvkdDL8o1_BXg1qhGigLy",animationWrapper:"NvkdDL8o1_BXg1qhGigLy",isRemoving:"_10_GhJMwEUjnj4lZPUh7Og",isRemoving:"_10_GhJMwEUjnj4lZPUh7Og",removeAnimation:"c8YDaMjPLGhPQw2bsAggp",removeAnimation:"c8YDaMjPLGhPQw2bsAggp",isRemoved:"_3dNbnOxM7yktRXz5klofeh",isRemoved:"_3dNbnOxM7yktRXz5klofeh",elemBefore:"_3i3sjP1d-w5pp_bwJ22xni",elemBefore:"_3i3sjP1d-w5pp_bwJ22xni",rounded:"fFu4yKO7ALrYA-JRwAA8q",rounded:"fFu4yKO7ALrYA-JRwAA8q"}},function(e,t){e.exports=function(){var e=[];return e.toString=function(){for(var e=[],t=0;t<this.length;t++){var n=this[t];n[2]?e.push("@media "+n[2]+"{"+n[1]+"}"):e.push(n[1])}return e.join("")},e.i=function(t,n){"string"==typeof t&&(t=[[null,t,""]]);for(var o={},r=0;r<this.length;r++){var i=this[r][0];"number"==typeof i&&(o[i]=!0)}for(r=0;r<t.length;r++){var a=t[r];"number"==typeof a[0]&&o[a[0]]||(n&&!a[2]?a[2]=n:n&&(a[2]="("+a[2]+") and ("+n+")"),e.push(a))}},e}},function(e,t,n){function o(e,t){for(var n=0;n<e.length;n++){var o=e[n],r=c[o.id];if(r){r.refs++;for(var i=0;i<r.parts.length;i++)r.parts[i](o.parts[i]);for(;i<o.parts.length;i++)r.parts.push(l(o.parts[i],t))}else{for(var a=[],i=0;i<o.parts.length;i++)a.push(l(o.parts[i],t));c[o.id]={id:o.id,refs:1,parts:a}}}}function r(e){for(var t=[],n={},o=0;o<e.length;o++){var r=e[o],i=r[0],a=r[1],u=r[2],s=r[3],l={css:a,media:u,sourceMap:s};n[i]?n[i].parts.push(l):t.push(n[i]={id:i,parts:[l]})}return t}function i(e,t){var n=v(),o=y[y.length-1];if("top"===e.insertAt)o?o.nextSibling?n.insertBefore(t,o.nextSibling):n.appendChild(t):n.insertBefore(t,n.firstChild),y.push(t);else{if("bottom"!==e.insertAt)throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'.");n.appendChild(t)}}function a(e){e.parentNode.removeChild(e);var t=y.indexOf(e);t>=0&&y.splice(t,1)}function u(e){var t=document.createElement("style");return t.type="text/css",i(e,t),t}function s(e){var t=document.createElement("link");return t.rel="stylesheet",i(e,t),t}function l(e,t){var n,o,r;if(t.singleton){var i=x++;n=b||(b=u(t)),o=d.bind(null,n,i,!1),r=d.bind(null,n,i,!0)}else e.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(n=s(t),o=f.bind(null,n),r=function(){a(n),n.href&&URL.revokeObjectURL(n.href)}):(n=u(t),o=p.bind(null,n),r=function(){a(n)});return o(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;o(e=t)}else r()}}function d(e,t,n,o){var r=n?"":o.css;if(e.styleSheet)e.styleSheet.cssText=g(t,r);else{var i=document.createTextNode(r),a=e.childNodes;a[t]&&e.removeChild(a[t]),a.length?e.insertBefore(i,a[t]):e.appendChild(i)}}function p(e,t){var n=t.css,o=t.media;if(o&&e.setAttribute("media",o),e.styleSheet)e.styleSheet.cssText=n;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}function f(e,t){var n=t.css,o=t.sourceMap;o&&(n+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */");var r=new Blob([n],{type:"text/css"}),i=e.href;e.href=URL.createObjectURL(r),i&&URL.revokeObjectURL(i)}var c={},h=function(e){var t;return function(){return"undefined"==typeof t&&(t=e.apply(this,arguments)),t}},m=h(function(){return/msie [6-9]\b/.test(window.navigator.userAgent.toLowerCase())}),v=h(function(){return document.head||document.getElementsByTagName("head")[0]}),b=null,x=0,y=[];e.exports=function(e,t){t=t||{},"undefined"==typeof t.singleton&&(t.singleton=m()),"undefined"==typeof t.insertAt&&(t.insertAt="bottom");var n=r(e);return o(n,t),function(e){for(var i=[],a=0;a<n.length;a++){var u=n[a],s=c[u.id];s.refs--,i.push(s)}if(e){var l=r(e);o(l,t)}for(var a=0;a<i.length;a++){var s=i[a];if(0===s.refs){for(var d=0;d<s.parts.length;d++)s.parts[d]();delete c[s.id]}}}};var g=function(){var e=[];return function(t,n){return e[t]=n,e.filter(Boolean).join("\n")}}()},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(23),i=o(r),a=n(11),u=o(a),s=n(12),l=o(s),d=n(13),p=o(d),f=n(14),c=o(f),h=n(15),m=o(h),v=n(24),b=o(v),x=n(18),y=o(x),g=n(16),_=o(g),k=function(e){function t(){var e,n,o,r;(0,l.default)(this,t);for(var i=arguments.length,a=Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=o=(0,c.default)(this,(e=t.__proto__||(0,u.default)(t)).call.apply(e,[this].concat(a))),o.handleAnimationEnd=function(e){e.animationName===y.default.removeAnimation&&o.props.onRemovalCompletion()},r=n,(0,c.default)(o,r)}return(0,m.default)(t,e),(0,p.default)(t,[{key:"render",value:function(){var e,t=this.props,n=t.isRemoving,o=t.isRemoved,r=(0,b.default)((e={},(0,i.default)(e,y.default.animationWrapper,!0),(0,i.default)(e,y.default.isRemoving,n),(0,i.default)(e,y.default.isRemoved,o),e));return _.default.createElement("div",{className:r,onAnimationEnd:this.handleAnimationEnd},this.props.children)}}]),t}(g.PureComponent);k.propTypes={isRemoving:g.PropTypes.bool,isRemoved:g.PropTypes.bool,children:g.PropTypes.node.isRequired,onRemovalCompletion:g.PropTypes.func},k.defaultProps={onRemovalCompletion:function(){},isRemoving:!1,isRemoved:!1},t.default=k},function(e,t){e.exports=require("babel-runtime/helpers/defineProperty")},function(e,t){e.exports=require("classnames")},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(26),i=o(r),a=n(23),u=o(a),s=n(11),l=o(s),d=n(12),p=o(d),f=n(13),c=o(f),h=n(14),m=o(h),v=n(15),b=o(v),x=n(24),y=o(x),g=n(18),_=o(g),k=n(16),R=o(k),P=function(e){function t(){var e,n,o,r;(0,p.default)(this,t);for(var i=arguments.length,a=Array(i),u=0;u<i;u++)a[u]=arguments[u];return n=o=(0,m.default)(this,(e=t.__proto__||(0,l.default)(t)).call.apply(e,[this].concat(a))),o.refLinkTag=function(e){o.chromeLink=e},o.handleKeyPress=function(e){32!==e.charCode&&13!==e.charCode||o.chromeLink&&o.chromeLink.querySelector("a").click()},r=n,(0,m.default)(o,r)}return(0,b.default)(t,e),(0,c.default)(t,[{key:"render",value:function(){var e,t=(0,y.default)((e={},(0,u.default)(e,_.default.chrome,!0),(0,u.default)(e,_.default.rounded,this.props.isRounded),(0,u.default)(e,_.default.markedForRemoval,this.props.markedForRemoval),(0,u.default)(e,_.default.isRemovable,this.props.isRemovable),e)),n={};return this.props.isLink?(n.role="link",n.ref="chromeLink",n.tabIndex=0):n.tabIndex=-1,R.default.createElement("span",(0,i.default)({},n,{ref:this.refLinkTag,className:t,onKeyPress:this.handleKeyPress}),this.props.children)}}]),t}(k.PureComponent);P.propTypes={isRounded:k.PropTypes.bool,isLink:k.PropTypes.bool.isRequired,markedForRemoval:k.PropTypes.bool.isRequired,isRemovable:k.PropTypes.bool.isRequired,children:k.PropTypes.arrayOf(k.PropTypes.element).isRequired},t.default=P},function(e,t){e.exports=require("babel-runtime/helpers/extends")},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(11),i=o(r),a=n(12),u=o(a),s=n(13),l=o(s),d=n(14),p=o(d),f=n(15),c=o(f),h=n(16),m=o(h),v=n(28),b=o(v),x=n(29),y=o(x),g=function(e){function t(){return(0,u.default)(this,t),(0,p.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return this.props.href?m.default.createElement(y.default,{href:this.props.href},this.props.children):m.default.createElement(b.default,null,this.props.children)}}]),t}(h.PureComponent);g.propTypes={href:h.PropTypes.string,children:h.PropTypes.node.isRequired},t.default=g},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(11),i=o(r),a=n(12),u=o(a),s=n(13),l=o(s),d=n(14),p=o(d),f=n(15),c=o(f),h=n(18),m=o(h),v=n(16),b=o(v),x=function(e){function t(){return(0,u.default)(this,t),(0,p.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return b.default.createElement("span",{className:m.default.text},this.props.children)}}]),t}(v.PureComponent);x.propTypes={children:v.PropTypes.node.isRequired},t.default=x},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(11),i=o(r),a=n(12),u=o(a),s=n(13),l=o(s),d=n(14),p=o(d),f=n(15),c=o(f),h=n(18),m=o(h),v=n(16),b=o(v),x=function(e){function t(){return(0,u.default)(this,t),(0,p.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return b.default.createElement("a",{tabIndex:"-1",className:m.default.href,href:this.props.href},this.props.children)}}]),t}(v.PureComponent);x.propTypes={href:v.PropTypes.string.isRequired,children:v.PropTypes.node.isRequired},t.default=x},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(23),i=o(r),a=n(11),u=o(a),s=n(12),l=o(s),d=n(13),p=o(d),f=n(14),c=o(f),h=n(15),m=o(h),v=n(18),b=o(v),x=n(16),y=o(x),g=n(24),_=o(g),k=n(31),R=o(k),P=function(e){function t(){var e,n,o,r;(0,l.default)(this,t);for(var i=arguments.length,a=Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=o=(0,c.default)(this,(e=t.__proto__||(0,u.default)(t)).call.apply(e,[this].concat(a))),o.onKeyPress=function(e){32!==e.charCode&&13!==e.charCode||(e.stopPropagation(),o.props.onRemoveAction())},o.onMouseOver=function(){o.props.onHoverChange(!0)},o.onMouseOut=function(){o.props.onHoverChange(!1)},r=n,(0,c.default)(o,r)}return(0,m.default)(t,e),(0,p.default)(t,[{key:"render",value:function(){var e=(0,_.default)(b.default.button,(0,i.default)({},b.default.rounded,this.props.isRounded));return y.default.createElement("button",{className:e,"aria-label":this.props.removeText,onMouseOver:this.onMouseOver,onMouseOut:this.onMouseOut,onClick:this.props.onRemoveAction,onKeyPress:this.onKeyPress,type:"button"},y.default.createElement(R.default,{label:this.props.removeText,size:"small"}))}}]),t}(x.PureComponent);P.propTypes={removeText:x.PropTypes.string.isRequired,isRounded:x.PropTypes.bool,onHoverChange:x.PropTypes.func,onRemoveAction:x.PropTypes.func},t.default=P},function(e,t){e.exports=require("@atlaskit/icon/glyph/cross")},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(11),i=o(r),a=n(12),u=o(a),s=n(13),l=o(s),d=n(14),p=o(d),f=n(15),c=o(f),h=n(18),m=o(h),v=n(16),b=o(v),x=function(e){function t(){return(0,u.default)(this,t),(0,p.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return this.props.children?b.default.createElement("span",{className:m.default.elemBefore},this.props.children):null}}]),t}(v.PureComponent);x.propTypes={children:v.PropTypes.node},t.default=x}]); | ||
module.exports=function(e){function n(o){if(t[o])return t[o].exports;var r=t[o]={exports:{},id:o,loaded:!1};return e[o].call(r.exports,r,r.exports,n),r.loaded=!0,r.exports}var t={};return n.m=e,n.c=t,n.p="",n(0)}([function(e,n,t){e.exports=t(1)},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var r=t(2),i=o(r);n.default=i.default},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var r=t(3),i=o(r),a=t(4),u=o(a),s=t(5),l=o(s),d=t(6),f=o(d),c=t(7),p=o(c),m=t(8),h=o(m),v=t(9),g=o(v),b=t(10),R=o(b),x=t(16),y=o(x),k=t(18),_=o(k),P=t(21),T=o(P),C=t(22),M=o(C),F=function(e){function n(e){(0,l.default)(this,n);var t=(0,p.default)(this,(n.__proto__||(0,u.default)(n)).call(this,e));return t.handleRemoveRequest=function(){t.props.onBeforeRemoveAction()&&t.setState({isRemoving:!0,isRemoved:!1})},t.handleRemoveComplete=function(){t.props.onAfterRemoveAction(t.props.text),t.setState({isRemoving:!1,isRemoved:!0})},t.handleHoverChange=function(e){t.setState({markedForRemoval:e})},t.handleFocusChange=function(e){t.setState({isFocused:e})},t.state={isRemoving:!1,isRemoved:!1,markedForRemoval:!1},t}return(0,h.default)(n,e),(0,f.default)(n,[{key:"render",value:function(){var e=this,n=this.state,t=n.isFocused,o=n.isRemoved,r=n.isRemoving,a=n.markedForRemoval,u=this.props,s=u.appearance,l=u.elemBefore,d=u.href,f=u.removeButtonText,c=u.text,p=Boolean(f),m="rounded"===s,h={isFocused:t,isRemovable:p,isRemoved:o,isRemoving:r,isRounded:m,markedForRemoval:a},v=function(n){return r&&e.handleRemoveComplete(n)};return g.default.createElement(M.default,(0,i.default)({},h,{onAnimationEnd:v}),g.default.createElement(R.default,(0,i.default)({},h,{isLink:!!d,onFocusChange:this.handleFocusChange}),l?g.default.createElement(T.default,null,l):null,g.default.createElement(y.default,(0,i.default)({},h,{href:d}),c),p?g.default.createElement(_.default,(0,i.default)({},h,{onHoverChange:this.handleHoverChange,onRemoveAction:this.handleRemoveRequest,removeText:f})):null))}}]),n}(v.PureComponent);F.propTypes={appearance:v.PropTypes.oneOf(["default","rounded"]),elemBefore:v.PropTypes.node,text:v.PropTypes.string.isRequired,href:v.PropTypes.string,removeButtonText:v.PropTypes.string,onBeforeRemoveAction:v.PropTypes.func,onAfterRemoveAction:v.PropTypes.func},F.defaultProps={appearance:"default",elemBefore:null,onAfterRemoveAction:function(){},onBeforeRemoveAction:function(){return!0}},n.default=F},function(e,n){e.exports=require("babel-runtime/helpers/extends")},function(e,n){e.exports=require("babel-runtime/core-js/object/get-prototype-of")},function(e,n){e.exports=require("babel-runtime/helpers/classCallCheck")},function(e,n){e.exports=require("babel-runtime/helpers/createClass")},function(e,n){e.exports=require("babel-runtime/helpers/possibleConstructorReturn")},function(e,n){e.exports=require("babel-runtime/helpers/inherits")},function(e,n){e.exports=require("react")},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var r=t(4),i=o(r),a=t(5),u=o(a),s=t(6),l=o(s),d=t(7),f=o(d),c=t(8),p=o(c),m=t(9),h=o(m),v=t(11),g=o(v),b=function(e){function n(){var e,t,o,r;(0,u.default)(this,n);for(var a=arguments.length,s=Array(a),l=0;l<a;l++)s[l]=arguments[l];return t=o=(0,f.default)(this,(e=n.__proto__||(0,i.default)(n)).call.apply(e,[this].concat(s))),o.handleKeyPress=function(e){var n=" "===e.key||"Enter"===e.key;o.chromeRef&&n&&o.chromeRef.querySelector("a").click()},o.handleBlur=function(){o.props.onFocusChange(!1)},o.handleFocus=function(e){e.target===o.chromeRef&&o.props.onFocusChange(!0)},r=t,(0,f.default)(o,r)}return(0,p.default)(n,e),(0,l.default)(n,[{key:"render",value:function(){var e=this,n=this.props,t=n.children,o=n.isLink,r=n.isRemovable,i=n.isRemoved,a=n.isRemoving,u=n.isRounded,s=n.markedForRemoval,l={innerRef:function(n){return e.chromeRef=n},isRemovable:r,isRemoved:i,isRemoving:a,isRounded:u,markedForRemoval:s,onBlur:this.handleBlur,onFocus:this.handleFocus,onKeyPress:this.handleKeyPress,tabIndex:-1};return o&&(l.role="link",l.tabIndex=0),h.default.createElement(g.default,l,t)}}]),n}(m.PureComponent);b.propTypes={children:m.PropTypes.arrayOf(m.PropTypes.element).isRequired,isLink:m.PropTypes.bool.isRequired,isRemovable:m.PropTypes.bool.isRequired,isRemoved:m.PropTypes.bool,isRemoving:m.PropTypes.bool,isRounded:m.PropTypes.bool,markedForRemoval:m.PropTypes.bool.isRequired,onFocusChange:m.PropTypes.func.isRequired},n.default=b},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var r=t(12),i=o(r),a=(0,i.default)(["\n ",";\n background-color: ",";\n border-radius: ",";\n cursor: default;\n display: flex;\n height: ",";\n line-height: 1;\n margin: ","px;\n padding: 0;\n overflow: ",";\n\n &:hover {\n ",";\n background-color: ",";\n }\n"],["\n ",";\n background-color: ",";\n border-radius: ",";\n cursor: default;\n display: flex;\n height: ",";\n line-height: 1;\n margin: ","px;\n padding: 0;\n overflow: ",";\n\n &:hover {\n ",";\n background-color: ",";\n }\n"]),u=t(13),s=o(u),l=t(14),d=t(15);n.default=s.default.span(a,l.akHelperMixins.focusRing.default,function(e){var n=e.markedForRemoval;return n?l.akColorR50:l.akColorN20},function(e){var n=e.isRounded;return n?d.buttonWidthUnitless/2+"px":d.borderRadius},d.tagHeight,l.akGridSizeUnitless/2,function(e){var n=e.isRemoved,t=e.isRemoving;return n||t?"hidden":"initial"},l.akHelperMixins.focusRing.none,function(e){var n=e.markedForRemoval;return n?l.akColorR50:l.akColorN30})},function(e,n){e.exports=require("babel-runtime/helpers/taggedTemplateLiteral")},function(e,n){e.exports=require("styled-components")},function(e,n){e.exports=require("@atlaskit/util-shared-styles")},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.maxTextWidth=n.maxTextWidthUnitless=n.maxWidth=n.maxWidthUnitless=n.buttonWidth=n.buttonWidthUnitless=n.tagHeight=n.tagHeightUnitless=n.fontSize=n.borderRadius=void 0;var o=t(14),r=(n.borderRadius=o.akBorderRadius,n.fontSize=o.akFontSizeDefault,n.tagHeightUnitless=2.5*o.akGridSizeUnitless),i=n.tagHeight=r+"px",a=(n.buttonWidthUnitless=r,n.buttonWidth=i,n.maxWidthUnitless=25*o.akGridSizeUnitless),u=(n.maxWidth=a+"px",n.maxTextWidthUnitless=a-r);n.maxTextWidth=u+"px"},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var r=t(3),i=o(r),a=t(4),u=o(a),s=t(5),l=o(s),d=t(6),f=o(d),c=t(7),p=o(c),m=t(8),h=o(m),v=t(9),g=o(v),b=t(17),R=function(e){function n(){return(0,l.default)(this,n),(0,p.default)(this,(n.__proto__||(0,u.default)(n)).apply(this,arguments))}return(0,h.default)(n,e),(0,f.default)(n,[{key:"render",value:function(){var e=this.props,n=e.children,t=e.href,o=e.isFocused,r=e.isRemovable,a=e.markedForRemoval,u={isFocused:o,isRemovable:r,markedForRemoval:a};return t?g.default.createElement(b.Link,(0,i.default)({},u,{href:t,tabIndex:"-1"}),n):g.default.createElement(b.Text,u,n)}}]),n}(v.PureComponent);R.propTypes={children:v.PropTypes.node.isRequired,href:v.PropTypes.string,isFocused:v.PropTypes.bool,isRemovable:v.PropTypes.bool,markedForRemoval:v.PropTypes.bool},n.default=R},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0}),n.Link=n.Text=void 0;var r=t(12),i=o(r),a=(0,i.default)(["\n color: ",";\n font-size: ",";\n font-weight: normal;\n line-height: 1;\n margin-left: ","px;\n margin-right: ","px;\n padding: 2px 0;\n ","\n"],["\n color: ",";\n font-size: ",";\n font-weight: normal;\n line-height: 1;\n margin-left: ","px;\n margin-right: ","px;\n padding: 2px 0;\n ","\n"]),u=(0,i.default)(["\n ","\n"],["\n ","\n"]),s=(0,i.default)(["\n ","\n ","\n text-decoration: none;\n\n &:hover {\n color: ",";\n }\n"],["\n ","\n ","\n text-decoration: none;\n\n &:hover {\n color: ",";\n }\n"]),l=t(13),d=o(l),f=t(14),c=t(15),p=function(e){var n=e.markedForRemoval;return n?f.akColorR500:f.akColorN700},m=f.akHelperMixins.text.truncate(function(e){var n=e.isRemovable;return n?c.maxTextWidthUnitless-c.buttonWidthUnitless+"px":c.maxTextWidth}),h=(0,l.css)(a,p,c.fontSize,f.akGridSizeUnitless/2,f.akGridSizeUnitless/2,m),v=(n.Text=d.default.span(u,h),function(e){var n=e.isFocused;return n?"color: "+f.akColorB400:null});n.Link=d.default.a(s,h,v,f.akColorB400)},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var r=t(4),i=o(r),a=t(5),u=o(a),s=t(6),l=o(s),d=t(7),f=o(d),c=t(8),p=o(c),m=t(9),h=o(m),v=t(19),g=o(v),b=t(20),R=o(b),x=function(e){function n(){var e,t,o,r;(0,u.default)(this,n);for(var a=arguments.length,s=Array(a),l=0;l<a;l++)s[l]=arguments[l];return t=o=(0,f.default)(this,(e=n.__proto__||(0,i.default)(n)).call.apply(e,[this].concat(s))),o.onKeyPress=function(e){var n=" "===e.key||"Enter"===e.key;n&&(e.stopPropagation(),o.props.onRemoveAction())},o.onMouseOver=function(){o.props.onHoverChange(!0)},o.onMouseOut=function(){o.props.onHoverChange(!1)},r=t,(0,f.default)(o,r)}return(0,p.default)(n,e),(0,l.default)(n,[{key:"render",value:function(){var e=this.props,n=e.isRounded,t=e.onRemoveAction,o=e.removeText;return h.default.createElement(R.default,{"aria-label":o,isRounded:n,onClick:t,onKeyPress:this.onKeyPress,onMouseOut:this.onMouseOut,onMouseOver:this.onMouseOver,type:"button"},h.default.createElement(g.default,{label:o,size:"small"}))}}]),n}(m.PureComponent);x.propTypes={removeText:m.PropTypes.string.isRequired,isRounded:m.PropTypes.bool,onHoverChange:m.PropTypes.func,onRemoveAction:m.PropTypes.func},n.default=x},function(e,n){e.exports=require("@atlaskit/icon/glyph/cross")},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var r=t(12),i=o(r),a=(0,i.default)(["\n align-items: center;\n appearance: none;\n background: none;\n border: none;\n border-radius: ",";\n color: ",";\n display: flex;\n justify-content: center;\n margin: 0;\n padding: 0;\n\n ","\n\n &:hover {\n color: ",";\n ","\n }\n\n &::-moz-focus-inner { border: 0; margin: 0; padding: 0; }\n"],["\n align-items: center;\n appearance: none;\n background: none;\n border: none;\n border-radius: ",";\n color: ",";\n display: flex;\n justify-content: center;\n margin: 0;\n padding: 0;\n\n ","\n\n &:hover {\n color: ",";\n ","\n }\n\n &::-moz-focus-inner { border: 0; margin: 0; padding: 0; }\n"]),u=t(13),s=o(u),l=t(14),d=t(15);n.default=s.default.button(a,function(e){var n=e.isRounded;return n?d.buttonWidthUnitless/2+"px":d.borderRadius},l.akColorN500,l.akHelperMixins.focusRing.generate(l.akColorR300),l.akColorR500,l.akHelperMixins.focusRing.default)},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var r=t(12),i=o(r),a=(0,i.default)(["\n align-items: center;\n display: flex;\n justify-content: center;\n padding-left: ","px;\n"],["\n align-items: center;\n display: flex;\n justify-content: center;\n padding-left: ","px;\n"]),u=t(13),s=o(u),l=t(14);n.default=s.default.span(a,l.akGridSizeUnitless/2)},function(e,n,t){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){var n=e.isRemoved,t=void 0;return n&&(t="width: 0; visibility: hidden;"),t}function i(e){var n=e.isRemoving,t=void 0;return n&&(t="animation: "+p+" 250ms forwards; will-change: width;"),t}Object.defineProperty(n,"__esModule",{value:!0});var a=t(12),u=o(a),s=(0,u.default)(["\n 0% {\n animation-timing-function: cubic-bezier(0.23830050393398, 0, 0.25586732616931, 0.79011192334632);\n max-width: ",";\n }\n 20% {\n animation-timing-function: cubic-bezier(0.21787238302442, 0.98324004924648, 0.58694150667646, 1);\n max-width: ","px;\n }\n 100% { max-width: 0; }\n"],["\n 0% {\n animation-timing-function: cubic-bezier(0.23830050393398, 0, 0.25586732616931, 0.79011192334632);\n max-width: ",";\n }\n 20% {\n animation-timing-function: cubic-bezier(0.21787238302442, 0.98324004924648, 0.58694150667646, 1);\n max-width: ","px;\n }\n 100% { max-width: 0; }\n"]),l=(0,u.default)(["\n box-sizing: border-box;\n display: inline-block;\n\n ","\n ","\n"],["\n box-sizing: border-box;\n display: inline-block;\n\n ","\n ","\n"]),d=t(13),f=o(d),c=t(15),p=(0,d.keyframes)(s,c.maxWidth,.8*c.maxWidthUnitless);n.default=f.default.div(l,i,r)}]); |
!function(root, factory) { | ||
"object" == typeof exports && "object" == typeof module ? module.exports = factory(require("babel-runtime/core-js/object/get-prototype-of"), require("babel-runtime/helpers/classCallCheck"), require("babel-runtime/helpers/createClass"), require("babel-runtime/helpers/possibleConstructorReturn"), require("babel-runtime/helpers/inherits"), require("react"), require("babel-runtime/helpers/defineProperty"), require("classnames"), require("babel-runtime/helpers/extends"), require("@atlaskit/icon/glyph/cross")) : "function" == typeof define && define.amd ? define([ "babel-runtime/core-js/object/get-prototype-of", "babel-runtime/helpers/classCallCheck", "babel-runtime/helpers/createClass", "babel-runtime/helpers/possibleConstructorReturn", "babel-runtime/helpers/inherits", "react", "babel-runtime/helpers/defineProperty", "classnames", "babel-runtime/helpers/extends", "@atlaskit/icon/glyph/cross" ], factory) : "object" == typeof exports ? exports["@atlaskit/tag"] = factory(require("babel-runtime/core-js/object/get-prototype-of"), require("babel-runtime/helpers/classCallCheck"), require("babel-runtime/helpers/createClass"), require("babel-runtime/helpers/possibleConstructorReturn"), require("babel-runtime/helpers/inherits"), require("react"), require("babel-runtime/helpers/defineProperty"), require("classnames"), require("babel-runtime/helpers/extends"), require("@atlaskit/icon/glyph/cross")) : root["@atlaskit/tag"] = factory(root["babel-runtime/core-js/object/get-prototype-of"], root["babel-runtime/helpers/classCallCheck"], root["babel-runtime/helpers/createClass"], root["babel-runtime/helpers/possibleConstructorReturn"], root["babel-runtime/helpers/inherits"], root.react, root["babel-runtime/helpers/defineProperty"], root.classnames, root["babel-runtime/helpers/extends"], root["@atlaskit/icon/glyph/cross"]); | ||
}(this, function(__WEBPACK_EXTERNAL_MODULE_11__, __WEBPACK_EXTERNAL_MODULE_12__, __WEBPACK_EXTERNAL_MODULE_13__, __WEBPACK_EXTERNAL_MODULE_14__, __WEBPACK_EXTERNAL_MODULE_15__, __WEBPACK_EXTERNAL_MODULE_16__, __WEBPACK_EXTERNAL_MODULE_23__, __WEBPACK_EXTERNAL_MODULE_24__, __WEBPACK_EXTERNAL_MODULE_26__, __WEBPACK_EXTERNAL_MODULE_31__) { | ||
"object" == typeof exports && "object" == typeof module ? module.exports = factory(require("babel-runtime/helpers/extends"), require("babel-runtime/core-js/object/get-prototype-of"), require("babel-runtime/helpers/classCallCheck"), require("babel-runtime/helpers/createClass"), require("babel-runtime/helpers/possibleConstructorReturn"), require("babel-runtime/helpers/inherits"), require("react"), require("babel-runtime/helpers/taggedTemplateLiteral"), require("styled-components"), require("@atlaskit/util-shared-styles"), require("@atlaskit/icon/glyph/cross")) : "function" == typeof define && define.amd ? define([ "babel-runtime/helpers/extends", "babel-runtime/core-js/object/get-prototype-of", "babel-runtime/helpers/classCallCheck", "babel-runtime/helpers/createClass", "babel-runtime/helpers/possibleConstructorReturn", "babel-runtime/helpers/inherits", "react", "babel-runtime/helpers/taggedTemplateLiteral", "styled-components", "@atlaskit/util-shared-styles", "@atlaskit/icon/glyph/cross" ], factory) : "object" == typeof exports ? exports["@atlaskit/tag"] = factory(require("babel-runtime/helpers/extends"), require("babel-runtime/core-js/object/get-prototype-of"), require("babel-runtime/helpers/classCallCheck"), require("babel-runtime/helpers/createClass"), require("babel-runtime/helpers/possibleConstructorReturn"), require("babel-runtime/helpers/inherits"), require("react"), require("babel-runtime/helpers/taggedTemplateLiteral"), require("styled-components"), require("@atlaskit/util-shared-styles"), require("@atlaskit/icon/glyph/cross")) : root["@atlaskit/tag"] = factory(root["babel-runtime/helpers/extends"], root["babel-runtime/core-js/object/get-prototype-of"], root["babel-runtime/helpers/classCallCheck"], root["babel-runtime/helpers/createClass"], root["babel-runtime/helpers/possibleConstructorReturn"], root["babel-runtime/helpers/inherits"], root.react, root["babel-runtime/helpers/taggedTemplateLiteral"], root["styled-components"], root["@atlaskit/util-shared-styles"], root["@atlaskit/icon/glyph/cross"]); | ||
}(this, function(__WEBPACK_EXTERNAL_MODULE_3__, __WEBPACK_EXTERNAL_MODULE_4__, __WEBPACK_EXTERNAL_MODULE_5__, __WEBPACK_EXTERNAL_MODULE_6__, __WEBPACK_EXTERNAL_MODULE_7__, __WEBPACK_EXTERNAL_MODULE_8__, __WEBPACK_EXTERNAL_MODULE_9__, __WEBPACK_EXTERNAL_MODULE_12__, __WEBPACK_EXTERNAL_MODULE_13__, __WEBPACK_EXTERNAL_MODULE_14__, __WEBPACK_EXTERNAL_MODULE_19__) { | ||
/******/ | ||
@@ -71,13 +71,4 @@ return function(modules) { | ||
function(module, exports, __webpack_require__) { | ||
module.exports = __webpack_require__(10); | ||
module.exports = __webpack_require__(1); | ||
}, /* 1 */ | ||
, /* 2 */ | ||
, /* 3 */ | ||
, /* 4 */ | ||
, /* 5 */ | ||
, /* 6 */ | ||
, /* 7 */ | ||
, /* 8 */ | ||
, /* 9 */ | ||
, /* 10 */ | ||
/***/ | ||
@@ -93,4 +84,18 @@ function(module, exports, __webpack_require__) { | ||
value: !0 | ||
}), exports.default = void 0; | ||
var _Tag = __webpack_require__(2), _Tag2 = _interopRequireDefault(_Tag); | ||
exports.default = _Tag2.default; | ||
}, /* 2 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), _Root = __webpack_require__(17), _Root2 = _interopRequireDefault(_Root), _AnimationWrapper = __webpack_require__(22), _AnimationWrapper2 = _interopRequireDefault(_AnimationWrapper), _Chrome = __webpack_require__(25), _Chrome2 = _interopRequireDefault(_Chrome), _Content = __webpack_require__(27), _Content2 = _interopRequireDefault(_Content), _RemoveButton = __webpack_require__(30), _RemoveButton2 = _interopRequireDefault(_RemoveButton), _ElemBefore = __webpack_require__(32), _ElemBefore2 = _interopRequireDefault(_ElemBefore), Tag = function(_PureComponent) { | ||
var _extends2 = __webpack_require__(3), _extends3 = _interopRequireDefault(_extends2), _getPrototypeOf = __webpack_require__(4), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(5), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(6), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(7), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(8), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(9), _react2 = _interopRequireDefault(_react), _Chrome = __webpack_require__(10), _Chrome2 = _interopRequireDefault(_Chrome), _Content = __webpack_require__(16), _Content2 = _interopRequireDefault(_Content), _Remove = __webpack_require__(18), _Remove2 = _interopRequireDefault(_Remove), _Before = __webpack_require__(21), _Before2 = _interopRequireDefault(_Before), _Container = __webpack_require__(22), _Container2 = _interopRequireDefault(_Container), Tag = function(_PureComponent) { | ||
function Tag(props) { | ||
@@ -100,3 +105,3 @@ (0, _classCallCheck3.default)(this, Tag); | ||
_getPrototypeOf2.default)(Tag)).call(this, props)); | ||
return _this.handleRemoveAction = function() { | ||
return _this.handleRemoveRequest = function() { | ||
_this.props.onBeforeRemoveAction() && _this.setState({ | ||
@@ -106,2 +111,7 @@ isRemoving: !0, | ||
}); | ||
}, _this.handleRemoveComplete = function() { | ||
_this.props.onAfterRemoveAction(_this.props.text), _this.setState({ | ||
isRemoving: !1, | ||
isRemoved: !0 | ||
}); | ||
}, _this.handleHoverChange = function(hoverState) { | ||
@@ -111,7 +121,6 @@ _this.setState({ | ||
}); | ||
}, _this.handleRemovalCompletion = function() { | ||
}, _this.handleFocusChange = function(focusState) { | ||
_this.setState({ | ||
isRemoving: !1, | ||
isRemoved: !0 | ||
}), _this.props.onAfterRemoveAction(_this.props.text); | ||
isFocused: focusState | ||
}); | ||
}, _this.state = { | ||
@@ -126,20 +135,25 @@ isRemoving: !1, | ||
value: function() { | ||
var newButton = this.props.removeButtonText ? _react2.default.createElement(_RemoveButton2.default, { | ||
removeText: this.props.removeButtonText, | ||
isRounded: "rounded" === this.props.appearance, | ||
var _this2 = this, _state = this.state, isFocused = _state.isFocused, isRemoved = _state.isRemoved, isRemoving = _state.isRemoving, markedForRemoval = _state.markedForRemoval, _props = this.props, appearance = _props.appearance, elemBefore = _props.elemBefore, href = _props.href, removeButtonText = _props.removeButtonText, text = _props.text, isRemovable = Boolean(removeButtonText), isRounded = "rounded" === appearance, styled = { | ||
isFocused: isFocused, | ||
isRemovable: isRemovable, | ||
isRemoved: isRemoved, | ||
isRemoving: isRemoving, | ||
isRounded: isRounded, | ||
markedForRemoval: markedForRemoval | ||
}, onAnimationEnd = function(e) { | ||
return isRemoving && _this2.handleRemoveComplete(e); | ||
}; | ||
return _react2.default.createElement(_Container2.default, (0, _extends3.default)({}, styled, { | ||
onAnimationEnd: onAnimationEnd | ||
}), _react2.default.createElement(_Chrome2.default, (0, _extends3.default)({}, styled, { | ||
isLink: !!href, | ||
onFocusChange: this.handleFocusChange | ||
}), elemBefore ? _react2.default.createElement(_Before2.default, null, elemBefore) : null, _react2.default.createElement(_Content2.default, (0, | ||
_extends3.default)({}, styled, { | ||
href: href | ||
}), text), isRemovable ? _react2.default.createElement(_Remove2.default, (0, _extends3.default)({}, styled, { | ||
onHoverChange: this.handleHoverChange, | ||
onRemoveAction: this.handleRemoveAction | ||
}) : null; | ||
return _react2.default.createElement(_Root2.default, null, _react2.default.createElement(_AnimationWrapper2.default, { | ||
isRemoving: this.state.isRemoving, | ||
isRemoved: this.state.isRemoved, | ||
onRemovalCompletion: this.handleRemovalCompletion | ||
}, _react2.default.createElement(_Chrome2.default, { | ||
isRounded: "rounded" === this.props.appearance, | ||
isLink: !!this.props.href, | ||
markedForRemoval: this.state.markedForRemoval, | ||
isRemovable: !!this.props.removeButtonText | ||
}, _react2.default.createElement(_ElemBefore2.default, null, this.props.elemBefore), _react2.default.createElement(_Content2.default, { | ||
href: this.props.href | ||
}, this.props.text), newButton))); | ||
onRemoveAction: this.handleRemoveRequest, | ||
removeText: removeButtonText | ||
})) : null)); | ||
} | ||
@@ -149,3 +163,3 @@ } ]), Tag; | ||
Tag.propTypes = { | ||
appearance: _react.PropTypes.oneOf("default", "rounded"), | ||
appearance: _react.PropTypes.oneOf([ "default", "rounded" ]), | ||
elemBefore: _react.PropTypes.node, | ||
@@ -165,28 +179,32 @@ text: _react.PropTypes.string.isRequired, | ||
}, exports.default = Tag; | ||
}, /* 11 */ | ||
}, /* 3 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_11__; | ||
}, /* 12 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_3__; | ||
}, /* 4 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_12__; | ||
}, /* 13 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_4__; | ||
}, /* 5 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_13__; | ||
}, /* 14 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_5__; | ||
}, /* 6 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_14__; | ||
}, /* 15 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_6__; | ||
}, /* 7 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_15__; | ||
}, /* 16 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_7__; | ||
}, /* 8 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_16__; | ||
}, /* 17 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_8__; | ||
}, /* 9 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_9__; | ||
}, /* 10 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
@@ -202,246 +220,51 @@ "use strict"; | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), Root = function(_PureComponent) { | ||
function Root() { | ||
return (0, _classCallCheck3.default)(this, Root), (0, _possibleConstructorReturn3.default)(this, (Root.__proto__ || (0, | ||
_getPrototypeOf2.default)(Root)).apply(this, arguments)); | ||
var _getPrototypeOf = __webpack_require__(4), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(5), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(6), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(7), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(8), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(9), _react2 = _interopRequireDefault(_react), _Chrome = __webpack_require__(11), _Chrome2 = _interopRequireDefault(_Chrome), Chrome = function(_PureComponent) { | ||
function Chrome() { | ||
var _ref, _temp, _this, _ret; | ||
(0, _classCallCheck3.default)(this, Chrome); | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = Chrome.__proto__ || (0, | ||
_getPrototypeOf2.default)(Chrome)).call.apply(_ref, [ this ].concat(args))), _this.handleKeyPress = function(e) { | ||
var spacebarOrEnter = " " === e.key || "Enter" === e.key; | ||
_this.chromeRef && spacebarOrEnter && _this.chromeRef.querySelector("a").click(); | ||
}, _this.handleBlur = function() { | ||
_this.props.onFocusChange(!1); | ||
}, _this.handleFocus = function(e) { | ||
e.target === _this.chromeRef && _this.props.onFocusChange(!0); | ||
}, _ret = _temp, (0, _possibleConstructorReturn3.default)(_this, _ret); | ||
} | ||
return (0, _inherits3.default)(Root, _PureComponent), (0, _createClass3.default)(Root, [ { | ||
return (0, _inherits3.default)(Chrome, _PureComponent), (0, _createClass3.default)(Chrome, [ { | ||
key: "render", | ||
value: function() { | ||
return _react2.default.createElement("div", { | ||
className: _styles2.default.rootWrapper | ||
}, this.props.children); | ||
var _this2 = this, _props = this.props, children = _props.children, isLink = _props.isLink, isRemovable = _props.isRemovable, isRemoved = _props.isRemoved, isRemoving = _props.isRemoving, isRounded = _props.isRounded, markedForRemoval = _props.markedForRemoval, props = { | ||
innerRef: function(r) { | ||
return _this2.chromeRef = r; | ||
}, | ||
isRemovable: isRemovable, | ||
isRemoved: isRemoved, | ||
isRemoving: isRemoving, | ||
isRounded: isRounded, | ||
markedForRemoval: markedForRemoval, | ||
onBlur: this.handleBlur, | ||
onFocus: this.handleFocus, | ||
onKeyPress: this.handleKeyPress, | ||
tabIndex: -1 | ||
}; | ||
return isLink && (props.role = "link", props.tabIndex = 0), _react2.default.createElement(_Chrome2.default, props, children); | ||
} | ||
} ]), Root; | ||
} ]), Chrome; | ||
}(_react.PureComponent); | ||
Root.propTypes = { | ||
children: _react.PropTypes.element.isRequired | ||
}, exports.default = Root; | ||
}, /* 18 */ | ||
Chrome.propTypes = { | ||
children: _react.PropTypes.arrayOf(_react.PropTypes.element).isRequired, | ||
isLink: _react.PropTypes.bool.isRequired, | ||
isRemovable: _react.PropTypes.bool.isRequired, | ||
isRemoved: _react.PropTypes.bool, | ||
isRemoving: _react.PropTypes.bool, | ||
isRounded: _react.PropTypes.bool, | ||
markedForRemoval: _react.PropTypes.bool.isRequired, | ||
onFocusChange: _react.PropTypes.func.isRequired | ||
}, exports.default = Chrome; | ||
}, /* 11 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
// style-loader: Adds some css to the DOM by adding a <style> tag | ||
// load the styles | ||
var content = __webpack_require__(19); | ||
"string" == typeof content && (content = [ [ module.id, content, "" ] ]); | ||
// add the styles to the DOM | ||
__webpack_require__(21)(content, {}); | ||
content.locals && (module.exports = content.locals); | ||
}, /* 19 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
exports = module.exports = __webpack_require__(20)(), // imports | ||
// module | ||
exports.push([ module.id, "@-webkit-keyframes c8YDaMjPLGhPQw2bsAggp{0%{max-width:200px;-webkit-animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192);animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192)}20%{max-width:40px;-webkit-animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1);animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1)}to{max-width:0}}@keyframes c8YDaMjPLGhPQw2bsAggp{0%{max-width:200px;-webkit-animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192);animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192)}20%{max-width:40px;-webkit-animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1);animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1)}to{max-width:0}}._2nKfaHK7YexQoxscVXc48M{display:inline-block}.k1zkuPFwI6t282KxhUhaa{background-color:#f4f5f7;border-radius:3px;cursor:default;display:-webkit-box;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;height:20px;line-height:1;margin:4px;padding:0}.k1zkuPFwI6t282KxhUhaa:focus{outline:none;box-shadow:0 0 0 2px #4c9aff}.k1zkuPFwI6t282KxhUhaa:hover{box-shadow:none;background-color:#ebecf0}.k1zkuPFwI6t282KxhUhaa:hover ._2bOaNKPmrKzqqIyxB4R9T7:focus{outline:none;box-shadow:0 0 0 2px #4c9aff}.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT{background-color:#ffebe6}.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT ._1tKmcJkhokQ0iCuG-BUei7,.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT ._8PiiZThnxHCBJjzovO9H5{color:#bf2600}.k1zkuPFwI6t282KxhUhaa:focus ._1tKmcJkhokQ0iCuG-BUei7{color:#0052cc}.k1zkuPFwI6t282KxhUhaa._15kEhFIXh8vbHb0gJ8n1x1 ._1tKmcJkhokQ0iCuG-BUei7,.k1zkuPFwI6t282KxhUhaa._15kEhFIXh8vbHb0gJ8n1x1 ._8PiiZThnxHCBJjzovO9H5{max-width:160px}.NvkdDL8o1_BXg1qhGigLy{box-sizing:border-box}.NvkdDL8o1_BXg1qhGigLy._10_GhJMwEUjnj4lZPUh7Og{-webkit-animation:c8YDaMjPLGhPQw2bsAggp .25s forwards;animation:c8YDaMjPLGhPQw2bsAggp .25s forwards;will-change:width}.NvkdDL8o1_BXg1qhGigLy._10_GhJMwEUjnj4lZPUh7Og .k1zkuPFwI6t282KxhUhaa{overflow:hidden}.NvkdDL8o1_BXg1qhGigLy._3dNbnOxM7yktRXz5klofeh{width:0;visibility:hidden}.NvkdDL8o1_BXg1qhGigLy._3dNbnOxM7yktRXz5klofeh .k1zkuPFwI6t282KxhUhaa{overflow:hidden}._8PiiZThnxHCBJjzovO9H5{color:#253858;font-size:14px;font-weight:400;line-height:1;margin-left:4px;margin-right:4px;padding:2px 0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._1tKmcJkhokQ0iCuG-BUei7{color:#253858;font-size:14px;font-weight:400;line-height:1;margin-left:4px;margin-right:4px;padding:2px 0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-decoration:none}._1tKmcJkhokQ0iCuG-BUei7:hover{color:#0052cc}._2bOaNKPmrKzqqIyxB4R9T7{-webkit-box-align:center;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:none;border-radius:3px;color:#42526e;display:-webkit-box;display:flex;-webkit-box-pack:center;justify-content:center;margin:0;padding:0}._2bOaNKPmrKzqqIyxB4R9T7:focus{outline:none;box-shadow:0 0 0 2px #ff5630}._2bOaNKPmrKzqqIyxB4R9T7::-moz-focus-inner{border:0;margin:0;padding:0}._2bOaNKPmrKzqqIyxB4R9T7:hover{color:#bf2600}._3i3sjP1d-w5pp_bwJ22xni{display:-webkit-box;display:flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;padding-left:4px}.fFu4yKO7ALrYA-JRwAA8q{border-radius:10px}", "" ]), | ||
// exports | ||
exports.locals = { | ||
rootWrapper: "_2nKfaHK7YexQoxscVXc48M", | ||
rootWrapper: "_2nKfaHK7YexQoxscVXc48M", | ||
chrome: "k1zkuPFwI6t282KxhUhaa", | ||
chrome: "k1zkuPFwI6t282KxhUhaa", | ||
button: "_2bOaNKPmrKzqqIyxB4R9T7", | ||
button: "_2bOaNKPmrKzqqIyxB4R9T7", | ||
markedForRemoval: "_1EI490l8oW5nSY5b-OQXRT", | ||
markedForRemoval: "_1EI490l8oW5nSY5b-OQXRT", | ||
href: "_1tKmcJkhokQ0iCuG-BUei7", | ||
href: "_1tKmcJkhokQ0iCuG-BUei7", | ||
text: "_8PiiZThnxHCBJjzovO9H5", | ||
text: "_8PiiZThnxHCBJjzovO9H5", | ||
isRemovable: "_15kEhFIXh8vbHb0gJ8n1x1", | ||
isRemovable: "_15kEhFIXh8vbHb0gJ8n1x1", | ||
animationWrapper: "NvkdDL8o1_BXg1qhGigLy", | ||
animationWrapper: "NvkdDL8o1_BXg1qhGigLy", | ||
isRemoving: "_10_GhJMwEUjnj4lZPUh7Og", | ||
isRemoving: "_10_GhJMwEUjnj4lZPUh7Og", | ||
removeAnimation: "c8YDaMjPLGhPQw2bsAggp", | ||
removeAnimation: "c8YDaMjPLGhPQw2bsAggp", | ||
isRemoved: "_3dNbnOxM7yktRXz5klofeh", | ||
isRemoved: "_3dNbnOxM7yktRXz5klofeh", | ||
elemBefore: "_3i3sjP1d-w5pp_bwJ22xni", | ||
elemBefore: "_3i3sjP1d-w5pp_bwJ22xni", | ||
rounded: "fFu4yKO7ALrYA-JRwAA8q", | ||
rounded: "fFu4yKO7ALrYA-JRwAA8q" | ||
}; | ||
}, /* 20 */ | ||
/***/ | ||
function(module, exports) { | ||
/* | ||
MIT License http://www.opensource.org/licenses/mit-license.php | ||
Author Tobias Koppers @sokra | ||
*/ | ||
// css base code, injected by the css-loader | ||
module.exports = function() { | ||
var list = []; | ||
// return the list of modules as css string | ||
// import a list of modules into the list | ||
return list.toString = function() { | ||
for (var result = [], i = 0; i < this.length; i++) { | ||
var item = this[i]; | ||
item[2] ? result.push("@media " + item[2] + "{" + item[1] + "}") : result.push(item[1]); | ||
} | ||
return result.join(""); | ||
}, list.i = function(modules, mediaQuery) { | ||
"string" == typeof modules && (modules = [ [ null, modules, "" ] ]); | ||
for (var alreadyImportedModules = {}, i = 0; i < this.length; i++) { | ||
var id = this[i][0]; | ||
"number" == typeof id && (alreadyImportedModules[id] = !0); | ||
} | ||
for (i = 0; i < modules.length; i++) { | ||
var item = modules[i]; | ||
// skip already imported module | ||
// this implementation is not 100% perfect for weird media query combinations | ||
// when a module is imported multiple times with different media queries. | ||
// I hope this will never occur (Hey this way we have smaller bundles) | ||
"number" == typeof item[0] && alreadyImportedModules[item[0]] || (mediaQuery && !item[2] ? item[2] = mediaQuery : mediaQuery && (item[2] = "(" + item[2] + ") and (" + mediaQuery + ")"), | ||
list.push(item)); | ||
} | ||
}, list; | ||
}; | ||
}, /* 21 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
function addStylesToDom(styles, options) { | ||
for (var i = 0; i < styles.length; i++) { | ||
var item = styles[i], domStyle = stylesInDom[item.id]; | ||
if (domStyle) { | ||
domStyle.refs++; | ||
for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](item.parts[j]); | ||
for (;j < item.parts.length; j++) domStyle.parts.push(addStyle(item.parts[j], options)); | ||
} else { | ||
for (var parts = [], j = 0; j < item.parts.length; j++) parts.push(addStyle(item.parts[j], options)); | ||
stylesInDom[item.id] = { | ||
id: item.id, | ||
refs: 1, | ||
parts: parts | ||
}; | ||
} | ||
} | ||
} | ||
function listToStyles(list) { | ||
for (var styles = [], newStyles = {}, i = 0; i < list.length; i++) { | ||
var item = list[i], id = item[0], css = item[1], media = item[2], sourceMap = item[3], part = { | ||
css: css, | ||
media: media, | ||
sourceMap: sourceMap | ||
}; | ||
newStyles[id] ? newStyles[id].parts.push(part) : styles.push(newStyles[id] = { | ||
id: id, | ||
parts: [ part ] | ||
}); | ||
} | ||
return styles; | ||
} | ||
function insertStyleElement(options, styleElement) { | ||
var head = getHeadElement(), lastStyleElementInsertedAtTop = styleElementsInsertedAtTop[styleElementsInsertedAtTop.length - 1]; | ||
if ("top" === options.insertAt) lastStyleElementInsertedAtTop ? lastStyleElementInsertedAtTop.nextSibling ? head.insertBefore(styleElement, lastStyleElementInsertedAtTop.nextSibling) : head.appendChild(styleElement) : head.insertBefore(styleElement, head.firstChild), | ||
styleElementsInsertedAtTop.push(styleElement); else { | ||
if ("bottom" !== options.insertAt) throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'."); | ||
head.appendChild(styleElement); | ||
} | ||
} | ||
function removeStyleElement(styleElement) { | ||
styleElement.parentNode.removeChild(styleElement); | ||
var idx = styleElementsInsertedAtTop.indexOf(styleElement); | ||
idx >= 0 && styleElementsInsertedAtTop.splice(idx, 1); | ||
} | ||
function createStyleElement(options) { | ||
var styleElement = document.createElement("style"); | ||
return styleElement.type = "text/css", insertStyleElement(options, styleElement), | ||
styleElement; | ||
} | ||
function createLinkElement(options) { | ||
var linkElement = document.createElement("link"); | ||
return linkElement.rel = "stylesheet", insertStyleElement(options, linkElement), | ||
linkElement; | ||
} | ||
function addStyle(obj, options) { | ||
var styleElement, update, remove; | ||
if (options.singleton) { | ||
var styleIndex = singletonCounter++; | ||
styleElement = singletonElement || (singletonElement = createStyleElement(options)), | ||
update = applyToSingletonTag.bind(null, styleElement, styleIndex, !1), remove = applyToSingletonTag.bind(null, styleElement, styleIndex, !0); | ||
} else obj.sourceMap && "function" == typeof URL && "function" == typeof URL.createObjectURL && "function" == typeof URL.revokeObjectURL && "function" == typeof Blob && "function" == typeof btoa ? (styleElement = createLinkElement(options), | ||
update = updateLink.bind(null, styleElement), remove = function() { | ||
removeStyleElement(styleElement), styleElement.href && URL.revokeObjectURL(styleElement.href); | ||
}) : (styleElement = createStyleElement(options), update = applyToTag.bind(null, styleElement), | ||
remove = function() { | ||
removeStyleElement(styleElement); | ||
}); | ||
return update(obj), function(newObj) { | ||
if (newObj) { | ||
if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap) return; | ||
update(obj = newObj); | ||
} else remove(); | ||
}; | ||
} | ||
function applyToSingletonTag(styleElement, index, remove, obj) { | ||
var css = remove ? "" : obj.css; | ||
if (styleElement.styleSheet) styleElement.styleSheet.cssText = replaceText(index, css); else { | ||
var cssNode = document.createTextNode(css), childNodes = styleElement.childNodes; | ||
childNodes[index] && styleElement.removeChild(childNodes[index]), childNodes.length ? styleElement.insertBefore(cssNode, childNodes[index]) : styleElement.appendChild(cssNode); | ||
} | ||
} | ||
function applyToTag(styleElement, obj) { | ||
var css = obj.css, media = obj.media; | ||
if (media && styleElement.setAttribute("media", media), styleElement.styleSheet) styleElement.styleSheet.cssText = css; else { | ||
for (;styleElement.firstChild; ) styleElement.removeChild(styleElement.firstChild); | ||
styleElement.appendChild(document.createTextNode(css)); | ||
} | ||
} | ||
function updateLink(linkElement, obj) { | ||
var css = obj.css, sourceMap = obj.sourceMap; | ||
sourceMap && (// http://stackoverflow.com/a/26603875 | ||
css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */"); | ||
var blob = new Blob([ css ], { | ||
type: "text/css" | ||
}), oldSrc = linkElement.href; | ||
linkElement.href = URL.createObjectURL(blob), oldSrc && URL.revokeObjectURL(oldSrc); | ||
} | ||
/* | ||
MIT License http://www.opensource.org/licenses/mit-license.php | ||
Author Tobias Koppers @sokra | ||
*/ | ||
var stylesInDom = {}, memoize = function(fn) { | ||
var memo; | ||
return function() { | ||
return "undefined" == typeof memo && (memo = fn.apply(this, arguments)), memo; | ||
}; | ||
}, isOldIE = memoize(function() { | ||
return /msie [6-9]\b/.test(window.navigator.userAgent.toLowerCase()); | ||
}), getHeadElement = memoize(function() { | ||
return document.head || document.getElementsByTagName("head")[0]; | ||
}), singletonElement = null, singletonCounter = 0, styleElementsInsertedAtTop = []; | ||
module.exports = function(list, options) { | ||
options = options || {}, // Force single-tag solution on IE6-9, which has a hard limit on the # of <style> | ||
// tags it will allow on a page | ||
"undefined" == typeof options.singleton && (options.singleton = isOldIE()), // By default, add <style> tags to the bottom of <head>. | ||
"undefined" == typeof options.insertAt && (options.insertAt = "bottom"); | ||
var styles = listToStyles(list); | ||
return addStylesToDom(styles, options), function(newList) { | ||
for (var mayRemove = [], i = 0; i < styles.length; i++) { | ||
var item = styles[i], domStyle = stylesInDom[item.id]; | ||
domStyle.refs--, mayRemove.push(domStyle); | ||
} | ||
if (newList) { | ||
var newStyles = listToStyles(newList); | ||
addStylesToDom(newStyles, options); | ||
} | ||
for (var i = 0; i < mayRemove.length; i++) { | ||
var domStyle = mayRemove[i]; | ||
if (0 === domStyle.refs) { | ||
for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j](); | ||
delete stylesInDom[domStyle.id]; | ||
} | ||
} | ||
}; | ||
}; | ||
var replaceText = function() { | ||
var textStore = []; | ||
return function(index, replacement) { | ||
return textStore[index] = replacement, textStore.filter(Boolean).join("\n"); | ||
}; | ||
}(); | ||
}, /* 22 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
@@ -456,101 +279,43 @@ function _interopRequireDefault(obj) { | ||
}); | ||
var _defineProperty2 = __webpack_require__(23), _defineProperty3 = _interopRequireDefault(_defineProperty2), _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _classnames = __webpack_require__(24), _classnames2 = _interopRequireDefault(_classnames), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), AnimationWrapper = function(_PureComponent) { | ||
function AnimationWrapper() { | ||
var _ref, _temp, _this, _ret; | ||
(0, _classCallCheck3.default)(this, AnimationWrapper); | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = AnimationWrapper.__proto__ || (0, | ||
_getPrototypeOf2.default)(AnimationWrapper)).call.apply(_ref, [ this ].concat(args))), | ||
_this.handleAnimationEnd = function(e) { | ||
e.animationName === _styles2.default.removeAnimation && _this.props.onRemovalCompletion(); | ||
}, _ret = _temp, (0, _possibleConstructorReturn3.default)(_this, _ret); | ||
} | ||
return (0, _inherits3.default)(AnimationWrapper, _PureComponent), (0, _createClass3.default)(AnimationWrapper, [ { | ||
key: "render", | ||
value: function() { | ||
var _classNames, _props = this.props, isRemoving = _props.isRemoving, isRemoved = _props.isRemoved, animationWrapperClasses = (0, | ||
_classnames2.default)((_classNames = {}, (0, _defineProperty3.default)(_classNames, _styles2.default.animationWrapper, !0), | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.isRemoving, isRemoving), | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.isRemoved, isRemoved), | ||
_classNames)); | ||
return _react2.default.createElement("div", { | ||
className: animationWrapperClasses, | ||
onAnimationEnd: this.handleAnimationEnd | ||
}, this.props.children); | ||
} | ||
} ]), AnimationWrapper; | ||
}(_react.PureComponent); | ||
AnimationWrapper.propTypes = { | ||
isRemoving: _react.PropTypes.bool, | ||
isRemoved: _react.PropTypes.bool, | ||
children: _react.PropTypes.node.isRequired, | ||
onRemovalCompletion: _react.PropTypes.func | ||
}, AnimationWrapper.defaultProps = { | ||
onRemovalCompletion: function() {}, | ||
isRemoving: !1, | ||
isRemoved: !1 | ||
}, exports.default = AnimationWrapper; | ||
}, /* 23 */ | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n ", ";\n background-color: ", ";\n border-radius: ", ";\n cursor: default;\n display: flex;\n height: ", ";\n line-height: 1;\n margin: ", "px;\n padding: 0;\n overflow: ", ";\n\n &:hover {\n ", ";\n background-color: ", ";\n }\n" ], [ "\n ", ";\n background-color: ", ";\n border-radius: ", ";\n cursor: default;\n display: flex;\n height: ", ";\n line-height: 1;\n margin: ", "px;\n padding: 0;\n overflow: ", ";\n\n &:hover {\n ", ";\n background-color: ", ";\n }\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _utilSharedStyles = __webpack_require__(14), _constants = __webpack_require__(15); | ||
exports.default = _styledComponents2.default.span(_templateObject, _utilSharedStyles.akHelperMixins.focusRing.default, function(_ref) { | ||
var markedForRemoval = _ref.markedForRemoval; | ||
return markedForRemoval ? _utilSharedStyles.akColorR50 : _utilSharedStyles.akColorN20; | ||
}, function(_ref2) { | ||
var isRounded = _ref2.isRounded; | ||
return isRounded ? _constants.buttonWidthUnitless / 2 + "px" : _constants.borderRadius; | ||
}, _constants.tagHeight, _utilSharedStyles.akGridSizeUnitless / 2, function(_ref3) { | ||
var isRemoved = _ref3.isRemoved, isRemoving = _ref3.isRemoving; | ||
return isRemoved || isRemoving ? "hidden" : "initial"; | ||
}, _utilSharedStyles.akHelperMixins.focusRing.none, function(_ref4) { | ||
var markedForRemoval = _ref4.markedForRemoval; | ||
return markedForRemoval ? _utilSharedStyles.akColorR50 : _utilSharedStyles.akColorN30; | ||
}); | ||
}, /* 12 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_23__; | ||
}, /* 24 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_12__; | ||
}, /* 13 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_24__; | ||
}, /* 25 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_13__; | ||
}, /* 14 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_14__; | ||
}, /* 15 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _extends2 = __webpack_require__(26), _extends3 = _interopRequireDefault(_extends2), _defineProperty2 = __webpack_require__(23), _defineProperty3 = _interopRequireDefault(_defineProperty2), _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _classnames = __webpack_require__(24), _classnames2 = _interopRequireDefault(_classnames), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), Chrome = function(_PureComponent) { | ||
function Chrome() { | ||
var _ref, _temp, _this, _ret; | ||
(0, _classCallCheck3.default)(this, Chrome); | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = Chrome.__proto__ || (0, | ||
_getPrototypeOf2.default)(Chrome)).call.apply(_ref, [ this ].concat(args))), _this.refLinkTag = function(linkTag) { | ||
_this.chromeLink = linkTag; | ||
}, _this.handleKeyPress = function(e) { | ||
32 !== e.charCode && 13 !== e.charCode || _this.chromeLink && _this.chromeLink.querySelector("a").click(); | ||
}, _ret = _temp, (0, _possibleConstructorReturn3.default)(_this, _ret); | ||
} | ||
return (0, _inherits3.default)(Chrome, _PureComponent), (0, _createClass3.default)(Chrome, [ { | ||
key: "render", | ||
value: function() { | ||
var _classNames, chromeClassNames = (0, _classnames2.default)((_classNames = {}, | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.chrome, !0), (0, _defineProperty3.default)(_classNames, _styles2.default.rounded, this.props.isRounded), | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.markedForRemoval, this.props.markedForRemoval), | ||
(0, _defineProperty3.default)(_classNames, _styles2.default.isRemovable, this.props.isRemovable), | ||
_classNames)), chromeProps = {}; | ||
return this.props.isLink ? (chromeProps.role = "link", chromeProps.ref = "chromeLink", | ||
chromeProps.tabIndex = 0) : chromeProps.tabIndex = -1, _react2.default.createElement("span", (0, | ||
_extends3.default)({}, chromeProps, { | ||
ref: this.refLinkTag, | ||
className: chromeClassNames, | ||
onKeyPress: this.handleKeyPress | ||
}), this.props.children); | ||
} | ||
} ]), Chrome; | ||
}(_react.PureComponent); | ||
Chrome.propTypes = { | ||
isRounded: _react.PropTypes.bool, | ||
isLink: _react.PropTypes.bool.isRequired, | ||
markedForRemoval: _react.PropTypes.bool.isRequired, | ||
isRemovable: _react.PropTypes.bool.isRequired, | ||
children: _react.PropTypes.arrayOf(_react.PropTypes.element).isRequired | ||
}, exports.default = Chrome; | ||
}, /* 26 */ | ||
}), exports.maxTextWidth = exports.maxTextWidthUnitless = exports.maxWidth = exports.maxWidthUnitless = exports.buttonWidth = exports.buttonWidthUnitless = exports.tagHeight = exports.tagHeightUnitless = exports.fontSize = exports.borderRadius = void 0; | ||
var _utilSharedStyles = __webpack_require__(14), tagHeightUnitless = (exports.borderRadius = _utilSharedStyles.akBorderRadius, | ||
exports.fontSize = _utilSharedStyles.akFontSizeDefault, exports.tagHeightUnitless = 2.5 * _utilSharedStyles.akGridSizeUnitless), tagHeight = exports.tagHeight = tagHeightUnitless + "px", maxWidthUnitless = (exports.buttonWidthUnitless = tagHeightUnitless, | ||
exports.buttonWidth = tagHeight, exports.maxWidthUnitless = 25 * _utilSharedStyles.akGridSizeUnitless), maxTextWidthUnitless = (exports.maxWidth = maxWidthUnitless + "px", | ||
exports.maxTextWidthUnitless = maxWidthUnitless - tagHeightUnitless); | ||
exports.maxTextWidth = maxTextWidthUnitless + "px"; | ||
}, /* 16 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_26__; | ||
}, /* 27 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
@@ -566,3 +331,3 @@ "use strict"; | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), _Text = __webpack_require__(28), _Text2 = _interopRequireDefault(_Text), _Link = __webpack_require__(29), _Link2 = _interopRequireDefault(_Link), Content = function(_PureComponent) { | ||
var _extends2 = __webpack_require__(3), _extends3 = _interopRequireDefault(_extends2), _getPrototypeOf = __webpack_require__(4), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(5), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(6), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(7), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(8), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(9), _react2 = _interopRequireDefault(_react), _Content = __webpack_require__(17), Content = function(_PureComponent) { | ||
function Content() { | ||
@@ -575,5 +340,11 @@ return (0, _classCallCheck3.default)(this, Content), (0, _possibleConstructorReturn3.default)(this, (Content.__proto__ || (0, | ||
value: function() { | ||
return this.props.href ? _react2.default.createElement(_Link2.default, { | ||
href: this.props.href | ||
}, this.props.children) : _react2.default.createElement(_Text2.default, null, this.props.children); | ||
var _props = this.props, children = _props.children, href = _props.href, isFocused = _props.isFocused, isRemovable = _props.isRemovable, markedForRemoval = _props.markedForRemoval, styledProps = { | ||
isFocused: isFocused, | ||
isRemovable: isRemovable, | ||
markedForRemoval: markedForRemoval | ||
}; | ||
return href ? _react2.default.createElement(_Content.Link, (0, _extends3.default)({}, styledProps, { | ||
href: href, | ||
tabIndex: "-1" | ||
}), children) : _react2.default.createElement(_Content.Text, styledProps, children); | ||
} | ||
@@ -583,6 +354,9 @@ } ]), Content; | ||
Content.propTypes = { | ||
children: _react.PropTypes.node.isRequired, | ||
href: _react.PropTypes.string, | ||
children: _react.PropTypes.node.isRequired | ||
isFocused: _react.PropTypes.bool, | ||
isRemovable: _react.PropTypes.bool, | ||
markedForRemoval: _react.PropTypes.bool | ||
}, exports.default = Content; | ||
}, /* 28 */ | ||
}, /* 17 */ | ||
/***/ | ||
@@ -598,21 +372,19 @@ function(module, exports, __webpack_require__) { | ||
value: !0 | ||
}), exports.Link = exports.Text = void 0; | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n color: ", ";\n font-size: ", ";\n font-weight: normal;\n line-height: 1;\n margin-left: ", "px;\n margin-right: ", "px;\n padding: 2px 0;\n ", "\n" ], [ "\n color: ", ";\n font-size: ", ";\n font-weight: normal;\n line-height: 1;\n margin-left: ", "px;\n margin-right: ", "px;\n padding: 2px 0;\n ", "\n" ]), _templateObject2 = (0, | ||
_taggedTemplateLiteral3.default)([ "\n ", "\n" ], [ "\n ", "\n" ]), _templateObject3 = (0, | ||
_taggedTemplateLiteral3.default)([ "\n ", "\n ", "\n text-decoration: none;\n\n &:hover {\n color: ", ";\n }\n" ], [ "\n ", "\n ", "\n text-decoration: none;\n\n &:hover {\n color: ", ";\n }\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _utilSharedStyles = __webpack_require__(14), _constants = __webpack_require__(15), getColor = function(_ref) { | ||
var markedForRemoval = _ref.markedForRemoval; | ||
return markedForRemoval ? _utilSharedStyles.akColorR500 : _utilSharedStyles.akColorN700; | ||
}, getTruncate = _utilSharedStyles.akHelperMixins.text.truncate(function(_ref2) { | ||
var isRemovable = _ref2.isRemovable; | ||
return isRemovable ? _constants.maxTextWidthUnitless - _constants.buttonWidthUnitless + "px" : _constants.maxTextWidth; | ||
}), COMMON_STYLES = (0, _styledComponents.css)(_templateObject, getColor, _constants.fontSize, _utilSharedStyles.akGridSizeUnitless / 2, _utilSharedStyles.akGridSizeUnitless / 2, getTruncate), getFocusedStyles = (exports.Text = _styledComponents2.default.span(_templateObject2, COMMON_STYLES), | ||
function(_ref3) { | ||
var isFocused = _ref3.isFocused; | ||
return isFocused ? "color: " + _utilSharedStyles.akColorB400 : null; | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), Text = function(_PureComponent) { | ||
function Text() { | ||
return (0, _classCallCheck3.default)(this, Text), (0, _possibleConstructorReturn3.default)(this, (Text.__proto__ || (0, | ||
_getPrototypeOf2.default)(Text)).apply(this, arguments)); | ||
} | ||
return (0, _inherits3.default)(Text, _PureComponent), (0, _createClass3.default)(Text, [ { | ||
key: "render", | ||
value: function() { | ||
return _react2.default.createElement("span", { | ||
className: _styles2.default.text | ||
}, this.props.children); | ||
} | ||
} ]), Text; | ||
}(_react.PureComponent); | ||
Text.propTypes = { | ||
children: _react.PropTypes.node.isRequired | ||
}, exports.default = Text; | ||
}, /* 29 */ | ||
exports.Link = _styledComponents2.default.a(_templateObject3, COMMON_STYLES, getFocusedStyles, _utilSharedStyles.akColorB400); | ||
}, /* 18 */ | ||
/***/ | ||
@@ -629,43 +401,11 @@ function(module, exports, __webpack_require__) { | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), Href = function(_PureComponent) { | ||
function Href() { | ||
return (0, _classCallCheck3.default)(this, Href), (0, _possibleConstructorReturn3.default)(this, (Href.__proto__ || (0, | ||
_getPrototypeOf2.default)(Href)).apply(this, arguments)); | ||
} | ||
return (0, _inherits3.default)(Href, _PureComponent), (0, _createClass3.default)(Href, [ { | ||
key: "render", | ||
value: function() { | ||
return _react2.default.createElement("a", { | ||
tabIndex: "-1", | ||
className: _styles2.default.href, | ||
href: this.props.href | ||
}, this.props.children); | ||
} | ||
} ]), Href; | ||
}(_react.PureComponent); | ||
Href.propTypes = { | ||
href: _react.PropTypes.string.isRequired, | ||
children: _react.PropTypes.node.isRequired | ||
}, exports.default = Href; | ||
}, /* 30 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _defineProperty2 = __webpack_require__(23), _defineProperty3 = _interopRequireDefault(_defineProperty2), _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), _classnames = __webpack_require__(24), _classnames2 = _interopRequireDefault(_classnames), _cross = __webpack_require__(31), _cross2 = _interopRequireDefault(_cross), RemoveButton = function(_PureComponent) { | ||
function RemoveButton() { | ||
var _getPrototypeOf = __webpack_require__(4), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(5), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(6), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(7), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(8), _inherits3 = _interopRequireDefault(_inherits2), _react = __webpack_require__(9), _react2 = _interopRequireDefault(_react), _cross = __webpack_require__(19), _cross2 = _interopRequireDefault(_cross), _Remove = __webpack_require__(20), _Remove2 = _interopRequireDefault(_Remove), Remove = function(_PureComponent) { | ||
function Remove() { | ||
var _ref, _temp, _this, _ret; | ||
(0, _classCallCheck3.default)(this, RemoveButton); | ||
(0, _classCallCheck3.default)(this, Remove); | ||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = RemoveButton.__proto__ || (0, | ||
_getPrototypeOf2.default)(RemoveButton)).call.apply(_ref, [ this ].concat(args))), | ||
_this.onKeyPress = function(e) { | ||
32 !== e.charCode && 13 !== e.charCode || (e.stopPropagation(), _this.props.onRemoveAction()); | ||
return _temp = _this = (0, _possibleConstructorReturn3.default)(this, (_ref = Remove.__proto__ || (0, | ||
_getPrototypeOf2.default)(Remove)).call.apply(_ref, [ this ].concat(args))), _this.onKeyPress = function(e) { | ||
var spacebarOrEnter = " " === e.key || "Enter" === e.key; | ||
spacebarOrEnter && (e.stopPropagation(), _this.props.onRemoveAction()); | ||
}, _this.onMouseOver = function() { | ||
@@ -677,22 +417,22 @@ _this.props.onHoverChange(!0); | ||
} | ||
return (0, _inherits3.default)(RemoveButton, _PureComponent), (0, _createClass3.default)(RemoveButton, [ { | ||
return (0, _inherits3.default)(Remove, _PureComponent), (0, _createClass3.default)(Remove, [ { | ||
key: "render", | ||
value: function() { | ||
var buttonStyles = (0, _classnames2.default)(_styles2.default.button, (0, _defineProperty3.default)({}, _styles2.default.rounded, this.props.isRounded)); | ||
return _react2.default.createElement("button", { | ||
className: buttonStyles, | ||
"aria-label": this.props.removeText, | ||
var _props = this.props, isRounded = _props.isRounded, onRemoveAction = _props.onRemoveAction, removeText = _props.removeText; | ||
return _react2.default.createElement(_Remove2.default, { | ||
"aria-label": removeText, | ||
isRounded: isRounded, | ||
onClick: onRemoveAction, | ||
onKeyPress: this.onKeyPress, | ||
onMouseOut: this.onMouseOut, | ||
onMouseOver: this.onMouseOver, | ||
onMouseOut: this.onMouseOut, | ||
onClick: this.props.onRemoveAction, | ||
onKeyPress: this.onKeyPress, | ||
type: "button" | ||
}, _react2.default.createElement(_cross2.default, { | ||
label: this.props.removeText, | ||
label: removeText, | ||
size: "small" | ||
})); | ||
} | ||
} ]), RemoveButton; | ||
} ]), Remove; | ||
}(_react.PureComponent); | ||
RemoveButton.propTypes = { | ||
Remove.propTypes = { | ||
removeText: _react.PropTypes.string.isRequired, | ||
@@ -702,8 +442,8 @@ isRounded: _react.PropTypes.bool, | ||
onRemoveAction: _react.PropTypes.func | ||
}, exports.default = RemoveButton; | ||
}, /* 31 */ | ||
}, exports.default = Remove; | ||
}, /* 19 */ | ||
/***/ | ||
function(module, exports) { | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_31__; | ||
}, /* 32 */ | ||
module.exports = __WEBPACK_EXTERNAL_MODULE_19__; | ||
}, /* 20 */ | ||
/***/ | ||
@@ -720,20 +460,53 @@ function(module, exports, __webpack_require__) { | ||
}); | ||
var _getPrototypeOf = __webpack_require__(11), _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf), _classCallCheck2 = __webpack_require__(12), _classCallCheck3 = _interopRequireDefault(_classCallCheck2), _createClass2 = __webpack_require__(13), _createClass3 = _interopRequireDefault(_createClass2), _possibleConstructorReturn2 = __webpack_require__(14), _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2), _inherits2 = __webpack_require__(15), _inherits3 = _interopRequireDefault(_inherits2), _styles = __webpack_require__(18), _styles2 = _interopRequireDefault(_styles), _react = __webpack_require__(16), _react2 = _interopRequireDefault(_react), ElemBefore = function(_PureComponent) { | ||
function ElemBefore() { | ||
return (0, _classCallCheck3.default)(this, ElemBefore), (0, _possibleConstructorReturn3.default)(this, (ElemBefore.__proto__ || (0, | ||
_getPrototypeOf2.default)(ElemBefore)).apply(this, arguments)); | ||
} | ||
return (0, _inherits3.default)(ElemBefore, _PureComponent), (0, _createClass3.default)(ElemBefore, [ { | ||
key: "render", | ||
value: function() { | ||
return this.props.children ? _react2.default.createElement("span", { | ||
className: _styles2.default.elemBefore | ||
}, this.props.children) : null; | ||
} | ||
} ]), ElemBefore; | ||
}(_react.PureComponent); | ||
ElemBefore.propTypes = { | ||
children: _react.PropTypes.node | ||
}, exports.default = ElemBefore; | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n align-items: center;\n appearance: none;\n background: none;\n border: none;\n border-radius: ", ";\n color: ", ";\n display: flex;\n justify-content: center;\n margin: 0;\n padding: 0;\n\n ", "\n\n &:hover {\n color: ", ";\n ", "\n }\n\n &::-moz-focus-inner { border: 0; margin: 0; padding: 0; }\n" ], [ "\n align-items: center;\n appearance: none;\n background: none;\n border: none;\n border-radius: ", ";\n color: ", ";\n display: flex;\n justify-content: center;\n margin: 0;\n padding: 0;\n\n ", "\n\n &:hover {\n color: ", ";\n ", "\n }\n\n &::-moz-focus-inner { border: 0; margin: 0; padding: 0; }\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _utilSharedStyles = __webpack_require__(14), _constants = __webpack_require__(15); | ||
// NOTE: | ||
// "-moz-focus-inner" removes some inbuilt padding that Firefox adds (taken from reduced-ui-pack) | ||
// the focus ring is red unless combined with hover, then uses default blue | ||
exports.default = _styledComponents2.default.button(_templateObject, function(_ref) { | ||
var isRounded = _ref.isRounded; | ||
return isRounded ? _constants.buttonWidthUnitless / 2 + "px" : _constants.borderRadius; | ||
}, _utilSharedStyles.akColorN500, _utilSharedStyles.akHelperMixins.focusRing.generate(_utilSharedStyles.akColorR300), _utilSharedStyles.akColorR500, _utilSharedStyles.akHelperMixins.focusRing.default); | ||
}, /* 21 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n align-items: center;\n display: flex;\n justify-content: center;\n padding-left: ", "px;\n" ], [ "\n align-items: center;\n display: flex;\n justify-content: center;\n padding-left: ", "px;\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _utilSharedStyles = __webpack_require__(14); | ||
exports.default = _styledComponents2.default.span(_templateObject, _utilSharedStyles.akGridSizeUnitless / 2); | ||
}, /* 22 */ | ||
/***/ | ||
function(module, exports, __webpack_require__) { | ||
"use strict"; | ||
function _interopRequireDefault(obj) { | ||
return obj && obj.__esModule ? obj : { | ||
default: obj | ||
}; | ||
} | ||
function getRemovedStyles(_ref) { | ||
var isRemoved = _ref.isRemoved, styles = void 0; | ||
return isRemoved && (styles = "width: 0; visibility: hidden;"), styles; | ||
} | ||
function getRemovingStyles(_ref2) { | ||
var isRemoving = _ref2.isRemoving, styles = void 0; | ||
return isRemoving && (styles = "animation: " + removeAnimation + " 250ms forwards; will-change: width;"), | ||
styles; | ||
} | ||
Object.defineProperty(exports, "__esModule", { | ||
value: !0 | ||
}); | ||
var _taggedTemplateLiteral2 = __webpack_require__(12), _taggedTemplateLiteral3 = _interopRequireDefault(_taggedTemplateLiteral2), _templateObject = (0, | ||
_taggedTemplateLiteral3.default)([ "\n 0% {\n animation-timing-function: cubic-bezier(0.23830050393398, 0, 0.25586732616931, 0.79011192334632);\n max-width: ", ";\n }\n 20% {\n animation-timing-function: cubic-bezier(0.21787238302442, 0.98324004924648, 0.58694150667646, 1);\n max-width: ", "px;\n }\n 100% { max-width: 0; }\n" ], [ "\n 0% {\n animation-timing-function: cubic-bezier(0.23830050393398, 0, 0.25586732616931, 0.79011192334632);\n max-width: ", ";\n }\n 20% {\n animation-timing-function: cubic-bezier(0.21787238302442, 0.98324004924648, 0.58694150667646, 1);\n max-width: ", "px;\n }\n 100% { max-width: 0; }\n" ]), _templateObject2 = (0, | ||
_taggedTemplateLiteral3.default)([ "\n box-sizing: border-box;\n display: inline-block;\n\n ", "\n ", "\n" ], [ "\n box-sizing: border-box;\n display: inline-block;\n\n ", "\n ", "\n" ]), _styledComponents = __webpack_require__(13), _styledComponents2 = _interopRequireDefault(_styledComponents), _constants = __webpack_require__(15), removeAnimation = (0, | ||
_styledComponents.keyframes)(_templateObject, _constants.maxWidth, .8 * _constants.maxWidthUnitless); | ||
exports.default = _styledComponents2.default.div(_templateObject2, getRemovingStyles, getRemovedStyles); | ||
} ]); | ||
}); |
@@ -1,1 +0,1 @@ | ||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("babel-runtime/core-js/object/get-prototype-of"),require("babel-runtime/helpers/classCallCheck"),require("babel-runtime/helpers/createClass"),require("babel-runtime/helpers/possibleConstructorReturn"),require("babel-runtime/helpers/inherits"),require("react"),require("babel-runtime/helpers/defineProperty"),require("classnames"),require("babel-runtime/helpers/extends"),require("@atlaskit/icon/glyph/cross")):"function"==typeof define&&define.amd?define(["babel-runtime/core-js/object/get-prototype-of","babel-runtime/helpers/classCallCheck","babel-runtime/helpers/createClass","babel-runtime/helpers/possibleConstructorReturn","babel-runtime/helpers/inherits","react","babel-runtime/helpers/defineProperty","classnames","babel-runtime/helpers/extends","@atlaskit/icon/glyph/cross"],t):"object"==typeof exports?exports["@atlaskit/tag"]=t(require("babel-runtime/core-js/object/get-prototype-of"),require("babel-runtime/helpers/classCallCheck"),require("babel-runtime/helpers/createClass"),require("babel-runtime/helpers/possibleConstructorReturn"),require("babel-runtime/helpers/inherits"),require("react"),require("babel-runtime/helpers/defineProperty"),require("classnames"),require("babel-runtime/helpers/extends"),require("@atlaskit/icon/glyph/cross")):e["@atlaskit/tag"]=t(e["babel-runtime/core-js/object/get-prototype-of"],e["babel-runtime/helpers/classCallCheck"],e["babel-runtime/helpers/createClass"],e["babel-runtime/helpers/possibleConstructorReturn"],e["babel-runtime/helpers/inherits"],e.react,e["babel-runtime/helpers/defineProperty"],e.classnames,e["babel-runtime/helpers/extends"],e["@atlaskit/icon/glyph/cross"])}(this,function(e,t,r,n,o,i,a,s,u,l){return function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={exports:{},id:n,loaded:!1};return e[n].call(o.exports,o,o.exports,t),o.loaded=!0,o.exports}var r={};return t.m=e,t.c=r,t.p="",t(0)}([function(e,t,r){e.exports=r(10)},,,,,,,,,,function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(11),i=n(o),a=r(12),s=n(a),u=r(13),l=n(u),p=r(14),d=n(p),f=r(15),c=n(f),h=r(16),m=n(h),b=r(17),v=n(b),x=r(22),y=n(x),g=r(25),k=n(g),_=r(27),R=n(_),P=r(30),w=n(P),T=r(32),C=n(T),q=function(e){function t(e){(0,s.default)(this,t);var r=(0,d.default)(this,(t.__proto__||(0,i.default)(t)).call(this,e));return r.handleRemoveAction=function(){r.props.onBeforeRemoveAction()&&r.setState({isRemoving:!0,isRemoved:!1})},r.handleHoverChange=function(e){r.setState({markedForRemoval:e})},r.handleRemovalCompletion=function(){r.setState({isRemoving:!1,isRemoved:!0}),r.props.onAfterRemoveAction(r.props.text)},r.state={isRemoving:!1,isRemoved:!1,markedForRemoval:!1},r}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){var e=this.props.removeButtonText?m.default.createElement(w.default,{removeText:this.props.removeButtonText,isRounded:"rounded"===this.props.appearance,onHoverChange:this.handleHoverChange,onRemoveAction:this.handleRemoveAction}):null;return m.default.createElement(v.default,null,m.default.createElement(y.default,{isRemoving:this.state.isRemoving,isRemoved:this.state.isRemoved,onRemovalCompletion:this.handleRemovalCompletion},m.default.createElement(k.default,{isRounded:"rounded"===this.props.appearance,isLink:!!this.props.href,markedForRemoval:this.state.markedForRemoval,isRemovable:!!this.props.removeButtonText},m.default.createElement(C.default,null,this.props.elemBefore),m.default.createElement(R.default,{href:this.props.href},this.props.text),e)))}}]),t}(h.PureComponent);q.propTypes={appearance:h.PropTypes.oneOf("default","rounded"),elemBefore:h.PropTypes.node,text:h.PropTypes.string.isRequired,href:h.PropTypes.string,removeButtonText:h.PropTypes.string,onBeforeRemoveAction:h.PropTypes.func,onAfterRemoveAction:h.PropTypes.func},q.defaultProps={appearance:"default",elemBefore:null,onAfterRemoveAction:function(){},onBeforeRemoveAction:function(){return!0}},t.default=q},function(t,r){t.exports=e},function(e,r){e.exports=t},function(e,t){e.exports=r},function(e,t){e.exports=n},function(e,t){e.exports=o},function(e,t){e.exports=i},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(11),i=n(o),a=r(12),s=n(a),u=r(13),l=n(u),p=r(14),d=n(p),f=r(15),c=n(f),h=r(18),m=n(h),b=r(16),v=n(b),x=function(e){function t(){return(0,s.default)(this,t),(0,d.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return v.default.createElement("div",{className:m.default.rootWrapper},this.props.children)}}]),t}(b.PureComponent);x.propTypes={children:b.PropTypes.element.isRequired},t.default=x},function(e,t,r){var n=r(19);"string"==typeof n&&(n=[[e.id,n,""]]),r(21)(n,{}),n.locals&&(e.exports=n.locals)},function(e,t,r){t=e.exports=r(20)(),t.push([e.id,"@-webkit-keyframes c8YDaMjPLGhPQw2bsAggp{0%{max-width:200px;-webkit-animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192);animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192)}20%{max-width:40px;-webkit-animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1);animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1)}to{max-width:0}}@keyframes c8YDaMjPLGhPQw2bsAggp{0%{max-width:200px;-webkit-animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192);animation-timing-function:cubic-bezier(.2383005,0,.25586733,.79011192)}20%{max-width:40px;-webkit-animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1);animation-timing-function:cubic-bezier(.21787238,.98324005,.58694151,1)}to{max-width:0}}._2nKfaHK7YexQoxscVXc48M{display:inline-block}.k1zkuPFwI6t282KxhUhaa{background-color:#f4f5f7;border-radius:3px;cursor:default;display:-webkit-box;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;height:20px;line-height:1;margin:4px;padding:0}.k1zkuPFwI6t282KxhUhaa:focus{outline:none;box-shadow:0 0 0 2px #4c9aff}.k1zkuPFwI6t282KxhUhaa:hover{box-shadow:none;background-color:#ebecf0}.k1zkuPFwI6t282KxhUhaa:hover ._2bOaNKPmrKzqqIyxB4R9T7:focus{outline:none;box-shadow:0 0 0 2px #4c9aff}.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT{background-color:#ffebe6}.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT ._1tKmcJkhokQ0iCuG-BUei7,.k1zkuPFwI6t282KxhUhaa._1EI490l8oW5nSY5b-OQXRT ._8PiiZThnxHCBJjzovO9H5{color:#bf2600}.k1zkuPFwI6t282KxhUhaa:focus ._1tKmcJkhokQ0iCuG-BUei7{color:#0052cc}.k1zkuPFwI6t282KxhUhaa._15kEhFIXh8vbHb0gJ8n1x1 ._1tKmcJkhokQ0iCuG-BUei7,.k1zkuPFwI6t282KxhUhaa._15kEhFIXh8vbHb0gJ8n1x1 ._8PiiZThnxHCBJjzovO9H5{max-width:160px}.NvkdDL8o1_BXg1qhGigLy{box-sizing:border-box}.NvkdDL8o1_BXg1qhGigLy._10_GhJMwEUjnj4lZPUh7Og{-webkit-animation:c8YDaMjPLGhPQw2bsAggp .25s forwards;animation:c8YDaMjPLGhPQw2bsAggp .25s forwards;will-change:width}.NvkdDL8o1_BXg1qhGigLy._10_GhJMwEUjnj4lZPUh7Og .k1zkuPFwI6t282KxhUhaa{overflow:hidden}.NvkdDL8o1_BXg1qhGigLy._3dNbnOxM7yktRXz5klofeh{width:0;visibility:hidden}.NvkdDL8o1_BXg1qhGigLy._3dNbnOxM7yktRXz5klofeh .k1zkuPFwI6t282KxhUhaa{overflow:hidden}._8PiiZThnxHCBJjzovO9H5{color:#253858;font-size:14px;font-weight:400;line-height:1;margin-left:4px;margin-right:4px;padding:2px 0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._1tKmcJkhokQ0iCuG-BUei7{color:#253858;font-size:14px;font-weight:400;line-height:1;margin-left:4px;margin-right:4px;padding:2px 0;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-decoration:none}._1tKmcJkhokQ0iCuG-BUei7:hover{color:#0052cc}._2bOaNKPmrKzqqIyxB4R9T7{-webkit-box-align:center;align-items:center;-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:none;border-radius:3px;color:#42526e;display:-webkit-box;display:flex;-webkit-box-pack:center;justify-content:center;margin:0;padding:0}._2bOaNKPmrKzqqIyxB4R9T7:focus{outline:none;box-shadow:0 0 0 2px #ff5630}._2bOaNKPmrKzqqIyxB4R9T7::-moz-focus-inner{border:0;margin:0;padding:0}._2bOaNKPmrKzqqIyxB4R9T7:hover{color:#bf2600}._3i3sjP1d-w5pp_bwJ22xni{display:-webkit-box;display:flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;padding-left:4px}.fFu4yKO7ALrYA-JRwAA8q{border-radius:10px}",""]),t.locals={rootWrapper:"_2nKfaHK7YexQoxscVXc48M",rootWrapper:"_2nKfaHK7YexQoxscVXc48M",chrome:"k1zkuPFwI6t282KxhUhaa",chrome:"k1zkuPFwI6t282KxhUhaa",button:"_2bOaNKPmrKzqqIyxB4R9T7",button:"_2bOaNKPmrKzqqIyxB4R9T7",markedForRemoval:"_1EI490l8oW5nSY5b-OQXRT",markedForRemoval:"_1EI490l8oW5nSY5b-OQXRT",href:"_1tKmcJkhokQ0iCuG-BUei7",href:"_1tKmcJkhokQ0iCuG-BUei7",text:"_8PiiZThnxHCBJjzovO9H5",text:"_8PiiZThnxHCBJjzovO9H5",isRemovable:"_15kEhFIXh8vbHb0gJ8n1x1",isRemovable:"_15kEhFIXh8vbHb0gJ8n1x1",animationWrapper:"NvkdDL8o1_BXg1qhGigLy",animationWrapper:"NvkdDL8o1_BXg1qhGigLy",isRemoving:"_10_GhJMwEUjnj4lZPUh7Og",isRemoving:"_10_GhJMwEUjnj4lZPUh7Og",removeAnimation:"c8YDaMjPLGhPQw2bsAggp",removeAnimation:"c8YDaMjPLGhPQw2bsAggp",isRemoved:"_3dNbnOxM7yktRXz5klofeh",isRemoved:"_3dNbnOxM7yktRXz5klofeh",elemBefore:"_3i3sjP1d-w5pp_bwJ22xni",elemBefore:"_3i3sjP1d-w5pp_bwJ22xni",rounded:"fFu4yKO7ALrYA-JRwAA8q",rounded:"fFu4yKO7ALrYA-JRwAA8q"}},function(e,t){e.exports=function(){var e=[];return e.toString=function(){for(var e=[],t=0;t<this.length;t++){var r=this[t];r[2]?e.push("@media "+r[2]+"{"+r[1]+"}"):e.push(r[1])}return e.join("")},e.i=function(t,r){"string"==typeof t&&(t=[[null,t,""]]);for(var n={},o=0;o<this.length;o++){var i=this[o][0];"number"==typeof i&&(n[i]=!0)}for(o=0;o<t.length;o++){var a=t[o];"number"==typeof a[0]&&n[a[0]]||(r&&!a[2]?a[2]=r:r&&(a[2]="("+a[2]+") and ("+r+")"),e.push(a))}},e}},function(e,t,r){function n(e,t){for(var r=0;r<e.length;r++){var n=e[r],o=c[n.id];if(o){o.refs++;for(var i=0;i<o.parts.length;i++)o.parts[i](n.parts[i]);for(;i<n.parts.length;i++)o.parts.push(l(n.parts[i],t))}else{for(var a=[],i=0;i<n.parts.length;i++)a.push(l(n.parts[i],t));c[n.id]={id:n.id,refs:1,parts:a}}}}function o(e){for(var t=[],r={},n=0;n<e.length;n++){var o=e[n],i=o[0],a=o[1],s=o[2],u=o[3],l={css:a,media:s,sourceMap:u};r[i]?r[i].parts.push(l):t.push(r[i]={id:i,parts:[l]})}return t}function i(e,t){var r=b(),n=y[y.length-1];if("top"===e.insertAt)n?n.nextSibling?r.insertBefore(t,n.nextSibling):r.appendChild(t):r.insertBefore(t,r.firstChild),y.push(t);else{if("bottom"!==e.insertAt)throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'.");r.appendChild(t)}}function a(e){e.parentNode.removeChild(e);var t=y.indexOf(e);t>=0&&y.splice(t,1)}function s(e){var t=document.createElement("style");return t.type="text/css",i(e,t),t}function u(e){var t=document.createElement("link");return t.rel="stylesheet",i(e,t),t}function l(e,t){var r,n,o;if(t.singleton){var i=x++;r=v||(v=s(t)),n=p.bind(null,r,i,!1),o=p.bind(null,r,i,!0)}else e.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(r=u(t),n=f.bind(null,r),o=function(){a(r),r.href&&URL.revokeObjectURL(r.href)}):(r=s(t),n=d.bind(null,r),o=function(){a(r)});return n(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;n(e=t)}else o()}}function p(e,t,r,n){var o=r?"":n.css;if(e.styleSheet)e.styleSheet.cssText=g(t,o);else{var i=document.createTextNode(o),a=e.childNodes;a[t]&&e.removeChild(a[t]),a.length?e.insertBefore(i,a[t]):e.appendChild(i)}}function d(e,t){var r=t.css,n=t.media;if(n&&e.setAttribute("media",n),e.styleSheet)e.styleSheet.cssText=r;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(r))}}function f(e,t){var r=t.css,n=t.sourceMap;n&&(r+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(n))))+" */");var o=new Blob([r],{type:"text/css"}),i=e.href;e.href=URL.createObjectURL(o),i&&URL.revokeObjectURL(i)}var c={},h=function(e){var t;return function(){return"undefined"==typeof t&&(t=e.apply(this,arguments)),t}},m=h(function(){return/msie [6-9]\b/.test(window.navigator.userAgent.toLowerCase())}),b=h(function(){return document.head||document.getElementsByTagName("head")[0]}),v=null,x=0,y=[];e.exports=function(e,t){t=t||{},"undefined"==typeof t.singleton&&(t.singleton=m()),"undefined"==typeof t.insertAt&&(t.insertAt="bottom");var r=o(e);return n(r,t),function(e){for(var i=[],a=0;a<r.length;a++){var s=r[a],u=c[s.id];u.refs--,i.push(u)}if(e){var l=o(e);n(l,t)}for(var a=0;a<i.length;a++){var u=i[a];if(0===u.refs){for(var p=0;p<u.parts.length;p++)u.parts[p]();delete c[u.id]}}}};var g=function(){var e=[];return function(t,r){return e[t]=r,e.filter(Boolean).join("\n")}}()},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(23),i=n(o),a=r(11),s=n(a),u=r(12),l=n(u),p=r(13),d=n(p),f=r(14),c=n(f),h=r(15),m=n(h),b=r(24),v=n(b),x=r(18),y=n(x),g=r(16),k=n(g),_=function(e){function t(){var e,r,n,o;(0,l.default)(this,t);for(var i=arguments.length,a=Array(i),u=0;u<i;u++)a[u]=arguments[u];return r=n=(0,c.default)(this,(e=t.__proto__||(0,s.default)(t)).call.apply(e,[this].concat(a))),n.handleAnimationEnd=function(e){e.animationName===y.default.removeAnimation&&n.props.onRemovalCompletion()},o=r,(0,c.default)(n,o)}return(0,m.default)(t,e),(0,d.default)(t,[{key:"render",value:function(){var e,t=this.props,r=t.isRemoving,n=t.isRemoved,o=(0,v.default)((e={},(0,i.default)(e,y.default.animationWrapper,!0),(0,i.default)(e,y.default.isRemoving,r),(0,i.default)(e,y.default.isRemoved,n),e));return k.default.createElement("div",{className:o,onAnimationEnd:this.handleAnimationEnd},this.props.children)}}]),t}(g.PureComponent);_.propTypes={isRemoving:g.PropTypes.bool,isRemoved:g.PropTypes.bool,children:g.PropTypes.node.isRequired,onRemovalCompletion:g.PropTypes.func},_.defaultProps={onRemovalCompletion:function(){},isRemoving:!1,isRemoved:!1},t.default=_},function(e,t){e.exports=a},function(e,t){e.exports=s},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(26),i=n(o),a=r(23),s=n(a),u=r(11),l=n(u),p=r(12),d=n(p),f=r(13),c=n(f),h=r(14),m=n(h),b=r(15),v=n(b),x=r(24),y=n(x),g=r(18),k=n(g),_=r(16),R=n(_),P=function(e){function t(){var e,r,n,o;(0,d.default)(this,t);for(var i=arguments.length,a=Array(i),s=0;s<i;s++)a[s]=arguments[s];return r=n=(0,m.default)(this,(e=t.__proto__||(0,l.default)(t)).call.apply(e,[this].concat(a))),n.refLinkTag=function(e){n.chromeLink=e},n.handleKeyPress=function(e){32!==e.charCode&&13!==e.charCode||n.chromeLink&&n.chromeLink.querySelector("a").click()},o=r,(0,m.default)(n,o)}return(0,v.default)(t,e),(0,c.default)(t,[{key:"render",value:function(){var e,t=(0,y.default)((e={},(0,s.default)(e,k.default.chrome,!0),(0,s.default)(e,k.default.rounded,this.props.isRounded),(0,s.default)(e,k.default.markedForRemoval,this.props.markedForRemoval),(0,s.default)(e,k.default.isRemovable,this.props.isRemovable),e)),r={};return this.props.isLink?(r.role="link",r.ref="chromeLink",r.tabIndex=0):r.tabIndex=-1,R.default.createElement("span",(0,i.default)({},r,{ref:this.refLinkTag,className:t,onKeyPress:this.handleKeyPress}),this.props.children)}}]),t}(_.PureComponent);P.propTypes={isRounded:_.PropTypes.bool,isLink:_.PropTypes.bool.isRequired,markedForRemoval:_.PropTypes.bool.isRequired,isRemovable:_.PropTypes.bool.isRequired,children:_.PropTypes.arrayOf(_.PropTypes.element).isRequired},t.default=P},function(e,t){e.exports=u},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(11),i=n(o),a=r(12),s=n(a),u=r(13),l=n(u),p=r(14),d=n(p),f=r(15),c=n(f),h=r(16),m=n(h),b=r(28),v=n(b),x=r(29),y=n(x),g=function(e){function t(){return(0,s.default)(this,t),(0,d.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return this.props.href?m.default.createElement(y.default,{href:this.props.href},this.props.children):m.default.createElement(v.default,null,this.props.children)}}]),t}(h.PureComponent);g.propTypes={href:h.PropTypes.string,children:h.PropTypes.node.isRequired},t.default=g},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(11),i=n(o),a=r(12),s=n(a),u=r(13),l=n(u),p=r(14),d=n(p),f=r(15),c=n(f),h=r(18),m=n(h),b=r(16),v=n(b),x=function(e){function t(){return(0,s.default)(this,t),(0,d.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return v.default.createElement("span",{className:m.default.text},this.props.children)}}]),t}(b.PureComponent);x.propTypes={children:b.PropTypes.node.isRequired},t.default=x},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(11),i=n(o),a=r(12),s=n(a),u=r(13),l=n(u),p=r(14),d=n(p),f=r(15),c=n(f),h=r(18),m=n(h),b=r(16),v=n(b),x=function(e){function t(){return(0,s.default)(this,t),(0,d.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return v.default.createElement("a",{tabIndex:"-1",className:m.default.href,href:this.props.href},this.props.children)}}]),t}(b.PureComponent);x.propTypes={href:b.PropTypes.string.isRequired,children:b.PropTypes.node.isRequired},t.default=x},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(23),i=n(o),a=r(11),s=n(a),u=r(12),l=n(u),p=r(13),d=n(p),f=r(14),c=n(f),h=r(15),m=n(h),b=r(18),v=n(b),x=r(16),y=n(x),g=r(24),k=n(g),_=r(31),R=n(_),P=function(e){function t(){var e,r,n,o;(0,l.default)(this,t);for(var i=arguments.length,a=Array(i),u=0;u<i;u++)a[u]=arguments[u];return r=n=(0,c.default)(this,(e=t.__proto__||(0,s.default)(t)).call.apply(e,[this].concat(a))),n.onKeyPress=function(e){32!==e.charCode&&13!==e.charCode||(e.stopPropagation(),n.props.onRemoveAction())},n.onMouseOver=function(){n.props.onHoverChange(!0)},n.onMouseOut=function(){n.props.onHoverChange(!1)},o=r,(0,c.default)(n,o)}return(0,m.default)(t,e),(0,d.default)(t,[{key:"render",value:function(){var e=(0,k.default)(v.default.button,(0,i.default)({},v.default.rounded,this.props.isRounded));return y.default.createElement("button",{className:e,"aria-label":this.props.removeText,onMouseOver:this.onMouseOver,onMouseOut:this.onMouseOut,onClick:this.props.onRemoveAction,onKeyPress:this.onKeyPress,type:"button"},y.default.createElement(R.default,{label:this.props.removeText,size:"small"}))}}]),t}(x.PureComponent);P.propTypes={removeText:x.PropTypes.string.isRequired,isRounded:x.PropTypes.bool,onHoverChange:x.PropTypes.func,onRemoveAction:x.PropTypes.func},t.default=P},function(e,t){e.exports=l},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=r(11),i=n(o),a=r(12),s=n(a),u=r(13),l=n(u),p=r(14),d=n(p),f=r(15),c=n(f),h=r(18),m=n(h),b=r(16),v=n(b),x=function(e){function t(){return(0,s.default)(this,t),(0,d.default)(this,(t.__proto__||(0,i.default)(t)).apply(this,arguments))}return(0,c.default)(t,e),(0,l.default)(t,[{key:"render",value:function(){return this.props.children?v.default.createElement("span",{className:m.default.elemBefore},this.props.children):null}}]),t}(b.PureComponent);x.propTypes={children:b.PropTypes.node},t.default=x}])}); | ||
!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n(require("babel-runtime/helpers/extends"),require("babel-runtime/core-js/object/get-prototype-of"),require("babel-runtime/helpers/classCallCheck"),require("babel-runtime/helpers/createClass"),require("babel-runtime/helpers/possibleConstructorReturn"),require("babel-runtime/helpers/inherits"),require("react"),require("babel-runtime/helpers/taggedTemplateLiteral"),require("styled-components"),require("@atlaskit/util-shared-styles"),require("@atlaskit/icon/glyph/cross")):"function"==typeof define&&define.amd?define(["babel-runtime/helpers/extends","babel-runtime/core-js/object/get-prototype-of","babel-runtime/helpers/classCallCheck","babel-runtime/helpers/createClass","babel-runtime/helpers/possibleConstructorReturn","babel-runtime/helpers/inherits","react","babel-runtime/helpers/taggedTemplateLiteral","styled-components","@atlaskit/util-shared-styles","@atlaskit/icon/glyph/cross"],n):"object"==typeof exports?exports["@atlaskit/tag"]=n(require("babel-runtime/helpers/extends"),require("babel-runtime/core-js/object/get-prototype-of"),require("babel-runtime/helpers/classCallCheck"),require("babel-runtime/helpers/createClass"),require("babel-runtime/helpers/possibleConstructorReturn"),require("babel-runtime/helpers/inherits"),require("react"),require("babel-runtime/helpers/taggedTemplateLiteral"),require("styled-components"),require("@atlaskit/util-shared-styles"),require("@atlaskit/icon/glyph/cross")):e["@atlaskit/tag"]=n(e["babel-runtime/helpers/extends"],e["babel-runtime/core-js/object/get-prototype-of"],e["babel-runtime/helpers/classCallCheck"],e["babel-runtime/helpers/createClass"],e["babel-runtime/helpers/possibleConstructorReturn"],e["babel-runtime/helpers/inherits"],e.react,e["babel-runtime/helpers/taggedTemplateLiteral"],e["styled-components"],e["@atlaskit/util-shared-styles"],e["@atlaskit/icon/glyph/cross"])}(this,function(e,n,t,r,o,i,a,s,l,u,d){return function(e){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}var t={};return n.m=e,n.c=t,n.p="",n(0)}([function(e,n,t){e.exports=t(1)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var o=t(2),i=r(o);n.default=i.default},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var o=t(3),i=r(o),a=t(4),s=r(a),l=t(5),u=r(l),d=t(6),c=r(d),f=t(7),p=r(f),m=t(8),h=r(m),b=t(9),v=r(b),g=t(10),x=r(g),R=t(16),y=r(R),k=t(18),_=r(k),P=t(21),T=r(P),C=t(22),q=r(C),M=function(e){function n(e){(0,u.default)(this,n);var t=(0,p.default)(this,(n.__proto__||(0,s.default)(n)).call(this,e));return t.handleRemoveRequest=function(){t.props.onBeforeRemoveAction()&&t.setState({isRemoving:!0,isRemoved:!1})},t.handleRemoveComplete=function(){t.props.onAfterRemoveAction(t.props.text),t.setState({isRemoving:!1,isRemoved:!0})},t.handleHoverChange=function(e){t.setState({markedForRemoval:e})},t.handleFocusChange=function(e){t.setState({isFocused:e})},t.state={isRemoving:!1,isRemoved:!1,markedForRemoval:!1},t}return(0,h.default)(n,e),(0,c.default)(n,[{key:"render",value:function(){var e=this,n=this.state,t=n.isFocused,r=n.isRemoved,o=n.isRemoving,a=n.markedForRemoval,s=this.props,l=s.appearance,u=s.elemBefore,d=s.href,c=s.removeButtonText,f=s.text,p=Boolean(c),m="rounded"===l,h={isFocused:t,isRemovable:p,isRemoved:r,isRemoving:o,isRounded:m,markedForRemoval:a},b=function(n){return o&&e.handleRemoveComplete(n)};return v.default.createElement(q.default,(0,i.default)({},h,{onAnimationEnd:b}),v.default.createElement(x.default,(0,i.default)({},h,{isLink:!!d,onFocusChange:this.handleFocusChange}),u?v.default.createElement(T.default,null,u):null,v.default.createElement(y.default,(0,i.default)({},h,{href:d}),f),p?v.default.createElement(_.default,(0,i.default)({},h,{onHoverChange:this.handleHoverChange,onRemoveAction:this.handleRemoveRequest,removeText:c})):null))}}]),n}(b.PureComponent);M.propTypes={appearance:b.PropTypes.oneOf(["default","rounded"]),elemBefore:b.PropTypes.node,text:b.PropTypes.string.isRequired,href:b.PropTypes.string,removeButtonText:b.PropTypes.string,onBeforeRemoveAction:b.PropTypes.func,onAfterRemoveAction:b.PropTypes.func},M.defaultProps={appearance:"default",elemBefore:null,onAfterRemoveAction:function(){},onBeforeRemoveAction:function(){return!0}},n.default=M},function(n,t){n.exports=e},function(e,t){e.exports=n},function(e,n){e.exports=t},function(e,n){e.exports=r},function(e,n){e.exports=o},function(e,n){e.exports=i},function(e,n){e.exports=a},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var o=t(4),i=r(o),a=t(5),s=r(a),l=t(6),u=r(l),d=t(7),c=r(d),f=t(8),p=r(f),m=t(9),h=r(m),b=t(11),v=r(b),g=function(e){function n(){var e,t,r,o;(0,s.default)(this,n);for(var a=arguments.length,l=Array(a),u=0;u<a;u++)l[u]=arguments[u];return t=r=(0,c.default)(this,(e=n.__proto__||(0,i.default)(n)).call.apply(e,[this].concat(l))),r.handleKeyPress=function(e){var n=" "===e.key||"Enter"===e.key;r.chromeRef&&n&&r.chromeRef.querySelector("a").click()},r.handleBlur=function(){r.props.onFocusChange(!1)},r.handleFocus=function(e){e.target===r.chromeRef&&r.props.onFocusChange(!0)},o=t,(0,c.default)(r,o)}return(0,p.default)(n,e),(0,u.default)(n,[{key:"render",value:function(){var e=this,n=this.props,t=n.children,r=n.isLink,o=n.isRemovable,i=n.isRemoved,a=n.isRemoving,s=n.isRounded,l=n.markedForRemoval,u={innerRef:function(n){return e.chromeRef=n},isRemovable:o,isRemoved:i,isRemoving:a,isRounded:s,markedForRemoval:l,onBlur:this.handleBlur,onFocus:this.handleFocus,onKeyPress:this.handleKeyPress,tabIndex:-1};return r&&(u.role="link",u.tabIndex=0),h.default.createElement(v.default,u,t)}}]),n}(m.PureComponent);g.propTypes={children:m.PropTypes.arrayOf(m.PropTypes.element).isRequired,isLink:m.PropTypes.bool.isRequired,isRemovable:m.PropTypes.bool.isRequired,isRemoved:m.PropTypes.bool,isRemoving:m.PropTypes.bool,isRounded:m.PropTypes.bool,markedForRemoval:m.PropTypes.bool.isRequired,onFocusChange:m.PropTypes.func.isRequired},n.default=g},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var o=t(12),i=r(o),a=(0,i.default)(["\n ",";\n background-color: ",";\n border-radius: ",";\n cursor: default;\n display: flex;\n height: ",";\n line-height: 1;\n margin: ","px;\n padding: 0;\n overflow: ",";\n\n &:hover {\n ",";\n background-color: ",";\n }\n"],["\n ",";\n background-color: ",";\n border-radius: ",";\n cursor: default;\n display: flex;\n height: ",";\n line-height: 1;\n margin: ","px;\n padding: 0;\n overflow: ",";\n\n &:hover {\n ",";\n background-color: ",";\n }\n"]),s=t(13),l=r(s),u=t(14),d=t(15);n.default=l.default.span(a,u.akHelperMixins.focusRing.default,function(e){var n=e.markedForRemoval;return n?u.akColorR50:u.akColorN20},function(e){var n=e.isRounded;return n?d.buttonWidthUnitless/2+"px":d.borderRadius},d.tagHeight,u.akGridSizeUnitless/2,function(e){var n=e.isRemoved,t=e.isRemoving;return n||t?"hidden":"initial"},u.akHelperMixins.focusRing.none,function(e){var n=e.markedForRemoval;return n?u.akColorR50:u.akColorN30})},function(e,n){e.exports=s},function(e,n){e.exports=l},function(e,n){e.exports=u},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.maxTextWidth=n.maxTextWidthUnitless=n.maxWidth=n.maxWidthUnitless=n.buttonWidth=n.buttonWidthUnitless=n.tagHeight=n.tagHeightUnitless=n.fontSize=n.borderRadius=void 0;var r=t(14),o=(n.borderRadius=r.akBorderRadius,n.fontSize=r.akFontSizeDefault,n.tagHeightUnitless=2.5*r.akGridSizeUnitless),i=n.tagHeight=o+"px",a=(n.buttonWidthUnitless=o,n.buttonWidth=i,n.maxWidthUnitless=25*r.akGridSizeUnitless),s=(n.maxWidth=a+"px",n.maxTextWidthUnitless=a-o);n.maxTextWidth=s+"px"},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var o=t(3),i=r(o),a=t(4),s=r(a),l=t(5),u=r(l),d=t(6),c=r(d),f=t(7),p=r(f),m=t(8),h=r(m),b=t(9),v=r(b),g=t(17),x=function(e){function n(){return(0,u.default)(this,n),(0,p.default)(this,(n.__proto__||(0,s.default)(n)).apply(this,arguments))}return(0,h.default)(n,e),(0,c.default)(n,[{key:"render",value:function(){var e=this.props,n=e.children,t=e.href,r=e.isFocused,o=e.isRemovable,a=e.markedForRemoval,s={isFocused:r,isRemovable:o,markedForRemoval:a};return t?v.default.createElement(g.Link,(0,i.default)({},s,{href:t,tabIndex:"-1"}),n):v.default.createElement(g.Text,s,n)}}]),n}(b.PureComponent);x.propTypes={children:b.PropTypes.node.isRequired,href:b.PropTypes.string,isFocused:b.PropTypes.bool,isRemovable:b.PropTypes.bool,markedForRemoval:b.PropTypes.bool},n.default=x},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0}),n.Link=n.Text=void 0;var o=t(12),i=r(o),a=(0,i.default)(["\n color: ",";\n font-size: ",";\n font-weight: normal;\n line-height: 1;\n margin-left: ","px;\n margin-right: ","px;\n padding: 2px 0;\n ","\n"],["\n color: ",";\n font-size: ",";\n font-weight: normal;\n line-height: 1;\n margin-left: ","px;\n margin-right: ","px;\n padding: 2px 0;\n ","\n"]),s=(0,i.default)(["\n ","\n"],["\n ","\n"]),l=(0,i.default)(["\n ","\n ","\n text-decoration: none;\n\n &:hover {\n color: ",";\n }\n"],["\n ","\n ","\n text-decoration: none;\n\n &:hover {\n color: ",";\n }\n"]),u=t(13),d=r(u),c=t(14),f=t(15),p=function(e){var n=e.markedForRemoval;return n?c.akColorR500:c.akColorN700},m=c.akHelperMixins.text.truncate(function(e){var n=e.isRemovable;return n?f.maxTextWidthUnitless-f.buttonWidthUnitless+"px":f.maxTextWidth}),h=(0,u.css)(a,p,f.fontSize,c.akGridSizeUnitless/2,c.akGridSizeUnitless/2,m),b=(n.Text=d.default.span(s,h),function(e){var n=e.isFocused;return n?"color: "+c.akColorB400:null});n.Link=d.default.a(l,h,b,c.akColorB400)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var o=t(4),i=r(o),a=t(5),s=r(a),l=t(6),u=r(l),d=t(7),c=r(d),f=t(8),p=r(f),m=t(9),h=r(m),b=t(19),v=r(b),g=t(20),x=r(g),R=function(e){function n(){var e,t,r,o;(0,s.default)(this,n);for(var a=arguments.length,l=Array(a),u=0;u<a;u++)l[u]=arguments[u];return t=r=(0,c.default)(this,(e=n.__proto__||(0,i.default)(n)).call.apply(e,[this].concat(l))),r.onKeyPress=function(e){var n=" "===e.key||"Enter"===e.key;n&&(e.stopPropagation(),r.props.onRemoveAction())},r.onMouseOver=function(){r.props.onHoverChange(!0)},r.onMouseOut=function(){r.props.onHoverChange(!1)},o=t,(0,c.default)(r,o)}return(0,p.default)(n,e),(0,u.default)(n,[{key:"render",value:function(){var e=this.props,n=e.isRounded,t=e.onRemoveAction,r=e.removeText;return h.default.createElement(x.default,{"aria-label":r,isRounded:n,onClick:t,onKeyPress:this.onKeyPress,onMouseOut:this.onMouseOut,onMouseOver:this.onMouseOver,type:"button"},h.default.createElement(v.default,{label:r,size:"small"}))}}]),n}(m.PureComponent);R.propTypes={removeText:m.PropTypes.string.isRequired,isRounded:m.PropTypes.bool,onHoverChange:m.PropTypes.func,onRemoveAction:m.PropTypes.func},n.default=R},function(e,n){e.exports=d},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var o=t(12),i=r(o),a=(0,i.default)(["\n align-items: center;\n appearance: none;\n background: none;\n border: none;\n border-radius: ",";\n color: ",";\n display: flex;\n justify-content: center;\n margin: 0;\n padding: 0;\n\n ","\n\n &:hover {\n color: ",";\n ","\n }\n\n &::-moz-focus-inner { border: 0; margin: 0; padding: 0; }\n"],["\n align-items: center;\n appearance: none;\n background: none;\n border: none;\n border-radius: ",";\n color: ",";\n display: flex;\n justify-content: center;\n margin: 0;\n padding: 0;\n\n ","\n\n &:hover {\n color: ",";\n ","\n }\n\n &::-moz-focus-inner { border: 0; margin: 0; padding: 0; }\n"]),s=t(13),l=r(s),u=t(14),d=t(15);n.default=l.default.button(a,function(e){var n=e.isRounded;return n?d.buttonWidthUnitless/2+"px":d.borderRadius},u.akColorN500,u.akHelperMixins.focusRing.generate(u.akColorR300),u.akColorR500,u.akHelperMixins.focusRing.default)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(n,"__esModule",{value:!0});var o=t(12),i=r(o),a=(0,i.default)(["\n align-items: center;\n display: flex;\n justify-content: center;\n padding-left: ","px;\n"],["\n align-items: center;\n display: flex;\n justify-content: center;\n padding-left: ","px;\n"]),s=t(13),l=r(s),u=t(14);n.default=l.default.span(a,u.akGridSizeUnitless/2)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e){var n=e.isRemoved,t=void 0;return n&&(t="width: 0; visibility: hidden;"),t}function i(e){var n=e.isRemoving,t=void 0;return n&&(t="animation: "+p+" 250ms forwards; will-change: width;"),t}Object.defineProperty(n,"__esModule",{value:!0});var a=t(12),s=r(a),l=(0,s.default)(["\n 0% {\n animation-timing-function: cubic-bezier(0.23830050393398, 0, 0.25586732616931, 0.79011192334632);\n max-width: ",";\n }\n 20% {\n animation-timing-function: cubic-bezier(0.21787238302442, 0.98324004924648, 0.58694150667646, 1);\n max-width: ","px;\n }\n 100% { max-width: 0; }\n"],["\n 0% {\n animation-timing-function: cubic-bezier(0.23830050393398, 0, 0.25586732616931, 0.79011192334632);\n max-width: ",";\n }\n 20% {\n animation-timing-function: cubic-bezier(0.21787238302442, 0.98324004924648, 0.58694150667646, 1);\n max-width: ","px;\n }\n 100% { max-width: 0; }\n"]),u=(0,s.default)(["\n box-sizing: border-box;\n display: inline-block;\n\n ","\n ","\n"],["\n box-sizing: border-box;\n display: inline-block;\n\n ","\n ","\n"]),d=t(13),c=r(d),f=t(15),p=(0,d.keyframes)(l,f.maxWidth,.8*f.maxWidthUnitless);n.default=c.default.div(u,i,o)}])}); |
{ | ||
"name": "@atlaskit/tag", | ||
"version": "1.2.1", | ||
"version": "2.0.0", | ||
"config": { | ||
@@ -22,3 +22,2 @@ "access": "public" | ||
"babel-runtime": "^6.11.6", | ||
"classnames": "^2.2.5", | ||
"create-error": "^0.3.1", | ||
@@ -42,3 +41,4 @@ "debug": "^2.2.0" | ||
"peerDependencies": { | ||
"react": "^15.3.2" | ||
"react": "^15.3.2", | ||
"styled-components": "^1.3.0" | ||
}, | ||
@@ -45,0 +45,0 @@ "repository": { |
@@ -5,3 +5,3 @@ [![AtlasKit component registry](https://img.shields.io/badge/AtlasKit-components-FF5230.svg)](http://aui-cdn.atlassian.com/atlaskit/registry/) | ||
[![Report an issue](https://img.shields.io/badge/Report-an_issue-6554C0.svg)](https://ecosystem.atlassian.net/browse/AK) | ||
[![Ask in our forum](https://img.shields.io/badge/Ask-in_our_forum-6554C0.svg)](https://answers.atlassian.com/questions/ask?title=AtlasKit%3A%20&topics=atlaskit,@atlaskit/tag,@atlaskit/tag@1.2.1) | ||
[![Ask in our forum](https://img.shields.io/badge/Ask-in_our_forum-6554C0.svg)](https://answers.atlassian.com/questions/ask?title=AtlasKit%3A%20&topics=atlaskit,@atlaskit/tag,@atlaskit/tag@2.0.0) | ||
@@ -18,3 +18,3 @@ # Tag | ||
Interact with a [live demo of the @atlaskit/tag component with code examples](https://aui-cdn.atlassian.com/atlaskit/stories/@atlaskit/tag/1.2.1/). | ||
Interact with a [live demo of the @atlaskit/tag component with code examples](https://aui-cdn.atlassian.com/atlaskit/stories/@atlaskit/tag/2.0.0/). | ||
@@ -90,3 +90,3 @@ | ||
Rounded is reccomended only for use with Avatars in elemBefore | ||
Rounded is recommended only for use with Avatars in elemBefore | ||
@@ -192,3 +192,3 @@ **Kind**: instance property of <code>[Tag](#Tag)</code> | ||
Ask a question in our [forum](https://answers.atlassian.com/questions/ask?title=AtlasKit%3A%20&topics=atlaskit,@atlaskit/tag,@atlaskit/tag@1.2.1). | ||
Ask a question in our [forum](https://answers.atlassian.com/questions/ask?title=AtlasKit%3A%20&topics=atlaskit,@atlaskit/tag,@atlaskit/tag@2.0.0). | ||
@@ -195,0 +195,0 @@ Check [if someone has already asked the same question before](https://answers.atlassian.com/questions/topics/42926171/atlaskit). |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
0
99600
1034
1
- Removedclassnames@^2.2.5