Liferay.Loader.define("@liferay/frontend-data-set-web@1.0.31/management_bar/components/NavBar",["module","exports","require","@frontend-taglib-clay$clayui/button","@frontend-taglib-clay$clayui/icon","frontend-js-components-web","liferay!frontend-js-react-web$prop-types","liferay!frontend-js-react-web$react","../../FrontendDataSetContext","../../views/ViewsContext","./ActiveViewSelector","./CreationMenu","./CustomViewDropdown","./FiltersDropdown","./MainSearch"],(function(e,t,n){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=p(n("@frontend-taglib-clay$clayui/button")),l=p(n("@frontend-taglib-clay$clayui/icon")),r=n("frontend-js-components-web"),o=(p(n("liferay!frontend-js-react-web$prop-types")),function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=b();if(t&&t.has(e))return t.get(e);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var l in e)if(Object.prototype.hasOwnProperty.call(e,l)){var r=a?Object.getOwnPropertyDescriptor(e,l):null;r&&(r.get||r.set)?Object.defineProperty(n,l,r):n[l]=e[l]}n.default=e,t&&t.set(e,n);return n}(n("liferay!frontend-js-react-web$react"))),u=p(n("../../FrontendDataSetContext")),c=p(n("../../views/ViewsContext")),i=p(n("./ActiveViewSelector")),f=p(n("./CreationMenu")),d=p(n("./CustomViewDropdown")),s=p(n("./FiltersDropdown")),m=p(n("./MainSearch"));function b(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return b=function(){return e},e}function p(e){return e&&e.__esModule?e:{default:e}}function w({creationMenu:e,showSearch:t}){const{filters:n}=(0,o.useContext)(u.default),[{customViewsEnabled:b,views:p}]=(0,o.useContext)(c.default),[w,y]=(0,o.useState)(!1);return o.default.createElement(r.ManagementToolbar.Container,{className:"c-mb-0 justify-content-space-between"},o.default.createElement(r.ManagementToolbar.ItemList,null,!!n.length&&o.default.createElement(r.ManagementToolbar.Item,null,o.default.createElement(s.default,null))),t&&o.default.createElement(o.default.Fragment,null,o.default.createElement(r.ManagementToolbar.Search,{onSubmit:e=>{e.preventDefault()},showMobile:w},o.default.createElement(m.default,{setShowMobile:y}))),o.default.createElement(r.ManagementToolbar.ItemList,null,t&&o.default.createElement(r.ManagementToolbar.Item,{className:"navbar-breakpoint-d-none"},o.default.createElement(a.default,{className:"nav-link nav-link-monospaced",displayType:"unstyled",onClick:()=>y(!0)},o.default.createElement(l.default,{symbol:"search"}))),(null==p?void 0:p.length)>1&&o.default.createElement(r.ManagementToolbar.Item,null,o.default.createElement(i.default,{views:p})),b&&o.default.createElement(r.ManagementToolbar.Item,null,o.default.createElement(d.default,null)),e&&o.default.createElement(r.ManagementToolbar.Item,null,o.default.createElement(f.default,e))))}w.defaultProps={creationMenu:{primaryItems:[]},showSearch:!0};var y=w;t.default=y}}));
//# sourceMappingURL=NavBar.js.map