Liferay.Loader.define("@liferay/layout-content-page-editor-web@3.0.141/page_editor/app/components/layout-data-items/CollectionItemWithControls",["module","exports","require","liferay!frontend-js-react-web$classnames","liferay!frontend-js-react-web$react","../../contexts/CollectionItemContext","../../utils/getLayoutDataItemTopperUniqueClassName","../topper/TopperEmpty"],(function(e,t,r){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=_interopRequireDefault(r("liferay!frontend-js-react-web$classnames")),l=function _interopRequireWildcard(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=_getRequireWildcardCache();if(t&&t.has(e))return t.get(e);var r={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var l in e)if(Object.prototype.hasOwnProperty.call(e,l)){var o=a?Object.getOwnPropertyDescriptor(e,l):null;o&&(o.get||o.set)?Object.defineProperty(r,l,o):r[l]=e[l]}r.default=e,t&&t.set(e,r);return r}(r("liferay!frontend-js-react-web$react")),o=r("../../contexts/CollectionItemContext"),n=_interopRequireDefault(r("../../utils/getLayoutDataItemTopperUniqueClassName")),i=_interopRequireDefault(r("../topper/TopperEmpty"));function _getRequireWildcardCache(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return _getRequireWildcardCache=function _getRequireWildcardCache(){return e},e}function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var c=l.default.forwardRef((({children:e,item:t},r)=>{const{collectionItem:c}=(0,l.useContext)(o.CollectionItemContext),u=c.title||c.name||c.defaultTitle;return l.default.createElement("div",{className:(0,a.default)("page-editor__collection__block",{empty:!u,"flex-grow-1":!e.length})},l.default.createElement(i.default,{className:(0,n.default)(t.itemId),item:t},0===l.default.Children.count(e)?l.default.createElement("div",{className:(0,a.default)("page-editor__collection-item",{empty:!e.length}),ref:r},l.default.createElement("div",{className:"page-editor__collection-item__border"},l.default.createElement("p",{className:"page-editor__collection-item__title"},u||Liferay.Language.get("sample-collection-item")))):l.default.createElement("div",{ref:r},e)))}));t.default=c}}));
//# sourceMappingURL=CollectionItemWithControls.js.map