"use strict";var A=Object.create;var s=Object.defineProperty;var u=Object.getOwnPropertyDescriptor;var P=Object.getOwnPropertyNames;var R=Object.getPrototypeOf;var D=Object.prototype.hasOwnProperty;var y=(e,o)=>s(e,"name",{value:o,configurable:true});var O=(e,o)=>{for(var r in o)s(e,r,{get:o[r],enumerable:true})};var g=(e,o,r,i)=>{if(o&&typeof o==="object"||typeof o==="function"){for(let t of P(o))if(!D.call(e,t)&&t!==r)s(e,t,{get:()=>o[t],enumerable:!(i=u(o,t))||i.enumerable})}return e};var m=(e,o,r)=>(r=e!=null?A(R(e)):{},g(o||!e||!e.__esModule?s(r,"default",{value:e,enumerable:true}):r,e));var W=e=>g(s({},"__esModule",{value:true}),e);var N=(e,o,r,i)=>{var t=i>1?void 0:i?u(o,r):o;for(var n=e.length-1,l;n>=0;n--)if(l=e[n])t=(i?l(o,r,t):l(t))||t;if(i&&t)s(o,r,t);return t};var w={};O(w,{default:()=>U});module.exports=W(w);var a=require("react/jsx-runtime");var f=m(require("classnames"));var C=require("mobx-react");var L=require("react");var d=require("react-intl");var v=require("@mdi/js");var b=require("lodash");var h=require("../../config");var k=m(require("./effects/Appear"));var H=m(require("./icon"));var M=m(require("./loader/index"));const T=(0,d.defineMessages)({hide:{id:"infobar.hide",defaultMessage:"Hide"}});let p=class extends L.Component{render(){const{children:o,type:r="primary",onClick:i=b.noop,className:t="",ctaLabel:n="",ctaLoading:l=false,position:c="bottom",sticky:_=false,onHide:$=b.noop,intl:E}=this.props;const x=c==="top"?"slideDown":"slideUp";return(0,a.jsx)(k.default,{transitionName:x,className:(0,f.default)({"info-bar":true,[`info-bar--${r}`]:true,[`info-bar--${c}`]:true,[`${t}`]:true}),children:(0,a.jsxs)("div",{className:(0,f.default)({"info-bar":true,[`info-bar--${r}`]:true,[`info-bar--${c}`]:true,[`${t}`]:true}),children:[o,n&&(0,a.jsx)("button",{type:"button",className:"info-bar__cta",onClick:i,children:(0,a.jsxs)("div",{className:"contentWrapper",style:{display:"flex",gap:"8px"},children:[(0,a.jsx)(M.default,{size:18,loaded:!l,color:h.DEFAULT_LOADER_COLOR}),n]})}),!_&&(0,a.jsx)("button",{type:"button",className:"info-bar__close",onClick:$,"aria-label":E.formatMessage(T.hide),children:(0,a.jsx)(H.default,{icon:v.mdiClose})})]})})}};y(p,"InfoBar");p=N([C.observer],p);var U=(0,d.injectIntl)(p);
