(window.webpackJsonpvtex_styleguide_9_146_16=window.webpackJsonpvtex_styleguide_9_146_16||[]).push([[29],{115:function(e,t,n){"use strict";var r=n(4),c=n(5),a=n(6),i=n(7),o=n(1),l=n(0),s=n.n(l),u=n(11),f=n(2);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object(o.a)(e);if(t){var c=Object(o.a)(this).constructor;n=Reflect.construct(r,arguments,c)}else n=r.apply(this,arguments);return Object(i.a)(this,n)}}var p={width:14,height:10},d=function(e){Object(a.a)(n,e);var t=h(n);function n(){return Object(r.a)(this,n),t.apply(this,arguments)}return Object(c.a)(n,[{key:"render",value:function(){var e=this.props,t=e.color,n=e.size,r=e.block,c=Object(f.b)(p,n);return s.a.createElement(u.a,{name:"caret-up",size:c,block:r,viewBox:"0 0 14 10"},s.a.createElement("path",{d:"M7.72356 8.48154C7.32958 8.89452 6.67042 8.89452 6.27644 8.48154L0 1.90235L1.81481 0L7 5.43529L12.1852 0L14 1.90235L7.72356 8.48154Z",transform:"translate(14 10) rotate(-180)",fill:t}))}}]),n}(l.PureComponent);d.defaultProps={color:"currentColor",size:16,block:!1},t.a=d},294:function(e,t,n){"use strict";var r=n(4),c=n(5),a=n(12),i=n(6),o=n(7),l=n(1),s=n(9),u=n(0),f=n.n(u),h=n(55),p=n(115),d=n(536);function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object(l.a)(e);if(t){var c=Object(l.a)(this).constructor;n=Reflect.construct(r,arguments,c)}else n=r.apply(this,arguments);return Object(o.a)(this,n)}}var v={base:"c-on-base",primary:"c-action-primary",muted:"c-muted-3"};function b(e,t){e&&e({target:{isOpen:t}})}var y=function(e){Object(i.a)(n,e);var t=m(n);function n(e){var c;return Object(r.a)(this,n),c=t.call(this,e),Object(s.a)(Object(a.a)(c),"handleTransitionEnd",(function(){var e=c.props,t=e.isOpen,n=e.isOverflowHidden;c.setState({height:t?"auto":0}),t&&!n&&c.childrenRef.current.style.removeProperty("overflow")})),Object(s.a)(Object(a.a)(c),"openCard",(function(){c.childrenRef.current.style.height="auto";var e=c.childrenRef.current.offsetHeight;c.childrenRef.current.style.height=0,c.childrenRef.current.offsetHeight,c.setState({height:e})})),Object(s.a)(Object(a.a)(c),"closeCard",(function(){var e=c.childrenRef.current.offsetHeight;c.childrenRef.current.style.setProperty("overflow","hidden"),c.setState({height:e},(function(){window.requestAnimationFrame((function(){return c.setState({height:0})}))}))})),c.childrenRef=f.a.createRef(),c.openTimeout=null,c.closeTimeout=null,c.state={height:0},c}return Object(c.a)(n,[{key:"componentDidMount",value:function(){this.props.isOpen&&this.setState({height:"auto"})}},{key:"componentDidUpdate",value:function(e){e.isOpen!==this.props.isOpen&&(this.props.isOpen?this.openCard():this.closeCard())}},{key:"render",value:function(){var e=this.props,t=e.align,n=e.children,r=e.header,c=e.muted,a=e.onClick,i=e.isOpen,o=e.arrowAlign,l=e.isOverflowHidden,s=this.props.caretColor,m={height:this.state.height,overflow:!l&&i?"none":"hidden",transition:"height 250ms ease-in-out"};c&&(s=s||"muted",console.warn('The "muted" prop on the "Collapsible" component is depreacted and will be removed in a future version. Use "caretColor=\'muted\'" instead.'));var y=s?function(e){return v[e]}(s):"c-action-primary";return f.a.createElement("div",{className:d.jsFocusVisible},f.a.createElement("div",{className:"flex flex-row items-center pointer",tabIndex:0,role:"button",onClick:function(){return b(a,!i)},onKeyDown:function(e){return"Enter"===e.key&&b(a,!i)},"aria-expanded":i},"left"===t?f.a.createElement(u.Fragment,null,f.a.createElement("div",{className:"".concat(y," mr3 self-").concat(o)},i?f.a.createElement(p.a,null):f.a.createElement(h.a,null)),f.a.createElement("div",{className:"flex-grow-1"},r)):f.a.createElement(u.Fragment,null,f.a.createElement("div",{className:"flex-grow-1"},r),f.a.createElement("div",{className:"".concat(y," ml3 self-").concat(o)},i?f.a.createElement(p.a,null):f.a.createElement(h.a,null)))),f.a.createElement("div",{ref:this.childrenRef,style:m,role:"region",onTransitionEnd:this.handleTransitionEnd},n))}}]),n}(u.Component);y.defaultProps={align:"left",isOpen:!1,muted:!1,arrowAlign:"center",isOverflowHidden:!0},t.a=y},536:function(e,t,n){e.exports={jsFocusVisible:"vtex-styleguide-9-x-jsFocusVisible"}},55:function(e,t,n){"use strict";var r=n(4),c=n(5),a=n(6),i=n(7),o=n(1),l=n(0),s=n.n(l),u=n(11),f=n(2);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object(o.a)(e);if(t){var c=Object(o.a)(this).constructor;n=Reflect.construct(r,arguments,c)}else n=r.apply(this,arguments);return Object(i.a)(this,n)}}var p={width:14,height:10},d=function(e){Object(a.a)(n,e);var t=h(n);function n(){return Object(r.a)(this,n),t.apply(this,arguments)}return Object(c.a)(n,[{key:"render",value:function(){var e=this.props,t=e.color,n=e.size,r=e.block,c=Object(f.b)(p,n);return s.a.createElement(u.a,{name:"caret-down",size:c,block:r,viewBox:"0 0 14 10"},s.a.createElement("path",{d:"M7.72356 8.48154C7.32958 8.89452 6.67042 8.89452 6.27644 8.48154L0 1.90235L1.81481 0L7 5.43529L12.1852 0L14 1.90235L7.72356 8.48154Z",fill:t}))}}]),n}(l.PureComponent);d.defaultProps={color:"currentColor",size:16,block:!1},t.a=d}}]);