Liferay.Loader.define("dynamic-data-mapping-form-field-type@6.0.124/FieldBase/FieldBase.es",["module","exports","require","../components/Tooltip/Tooltip.es","frontend-taglib-clay$clay-icon","data-engine-js-components-web","frontend-js-metal-web$metal-component","frontend-js-metal-web$metal-soy","frontend-js-metal-web$metal-state","../util/withDispatch.es","./FieldBase.soy","./withLocale.es","./withRepetitionControls.es"],(function(e,t,o){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,o("../components/Tooltip/Tooltip.es"),o("frontend-taglib-clay$clay-icon");var n=o("data-engine-js-components-web"),r=_interopRequireDefault(o("frontend-js-metal-web$metal-component")),i=_interopRequireDefault(o("frontend-js-metal-web$metal-soy")),a=o("frontend-js-metal-web$metal-state"),l=_interopRequireDefault(o("../util/withDispatch.es")),s=_interopRequireDefault(o("./FieldBase.soy")),p=_interopRequireDefault(o("./withLocale.es")),f=_interopRequireDefault(o("./withRepetitionControls.es"));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function ownKeys(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function _objectSpread(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?ownKeys(Object(o),!0).forEach((function(t){_defineProperty(e,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):ownKeys(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}function _defineProperty(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}class FieldBase extends r.default{prepareStateForRender(e){const t=(0,n.getRepeatedIndex)(this.name);return _objectSpread(_objectSpread({},e),{},{showRepeatableAddButton:this.repeatable,showRepeatableRemoveButton:this.repeatable&&t>0})}}FieldBase.STATE={contentRenderer:a.Config.any(),displayErrors:a.Config.bool().value(!1),id:a.Config.string(),label:a.Config.string(),name:a.Config.string(),repeatable:a.Config.bool(),required:a.Config.bool(),showLabel:a.Config.bool().value(!0),spritemap:a.Config.string().required(),tip:a.Config.string(),tooltip:a.Config.string()};const e=(0,n.compose)(l.default,f.default,p.default)(FieldBase);i.default.register(e,s.default);var d=e;t.default=d}}));
//# sourceMappingURL=FieldBase.es.js.map