Liferay.Loader.define("knowledge-base-web@5.0.75/admin/js/components/TemplatesPanel",["module","exports","require","@frontend-taglib-clay$clayui/core","@frontend-taglib-clay$clayui/empty-state","@frontend-taglib-clay$clayui/icon","@frontend-taglib-clay$clayui/link","liferay!frontend-js-react-web$classnames","liferay!frontend-js-react-web$prop-types","liferay!frontend-js-react-web$react","./ActionsDropdown"],(function(e,t,a){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function TemplatesPanel({items:t,selectedItemId:a}){return(null==t?void 0:t.length)?o.default.createElement(l.TreeView,{defaultItems:t,defaultSelectedKeys:new Set([a]),nestedKey:"children",showExpanderOnHover:!1},(t=>o.default.createElement(l.TreeView.Item,{actions:(0,f.default)({actions:t.actions})},o.default.createElement(l.TreeView.ItemStack,{className:(0,d.default)({"knowledge-base-navigation-item-active":t.id===a})},o.default.createElement(i.default,{displayType:"secondary",href:t.href},o.default.createElement(r.default,{symbol:e[t.type]}),o.default.createElement("span",{className:"component-text"},t.name))),o.default.createElement(l.TreeView.Group,{items:t.children},(t=>o.default.createElement(l.TreeView.Item,{actions:(0,f.default)({actions:t.actions}),className:(0,d.default)({"knowledge-base-navigation-item-active":t.id===a})},o.default.createElement(i.default,{displayType:"secondary",href:t.href},o.default.createElement(r.default,{symbol:e[t.type]}),o.default.createElement("span",{className:"component-text"},t.name)))))))):o.default.createElement(n.default,{description:"",imgSrc:"".concat(themeDisplay.getPathThemeImages(),"/states/empty_state.gif"),small:!0,title:Liferay.Language.get("there-are-no-article-templates")})};var l=a("@frontend-taglib-clay$clayui/core"),n=_interopRequireDefault(a("@frontend-taglib-clay$clayui/empty-state")),r=_interopRequireDefault(a("@frontend-taglib-clay$clayui/icon")),i=_interopRequireDefault(a("@frontend-taglib-clay$clayui/link")),d=_interopRequireDefault(a("liferay!frontend-js-react-web$classnames")),c=_interopRequireDefault(a("liferay!frontend-js-react-web$prop-types")),o=_interopRequireDefault(a("liferay!frontend-js-react-web$react")),f=_interopRequireDefault(a("./ActionsDropdown"));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}const e={folder:"folder",template:"document-text"};const s={href:c.default.string.isRequired,id:c.default.string.isRequired,name:c.default.string.isRequired,type:c.default.oneOf(Object.keys(e)).isRequired};s.children=c.default.arrayOf(c.default.shape(s))}}));
//# sourceMappingURL=TemplatesPanel.js.map