Liferay.Loader.define("@liferay/object-web@1.0.132/js/components/ObjectField/Tabs/BasicInfo/SearchableContainer",["module","exports","require","@frontend-taglib-clay$clayui/alert","@frontend-taglib-clay$clayui/form","@liferay/object-js-components-web","liferay!frontend-js-react-web$react"],(function(e,a,t){window;{Object.defineProperty(a,"__esModule",{value:!0}),a.SearchableContainer=function SearchableContainer({isApproved:a,objectField:t,readOnly:u,setValues:c}){const f=t.indexed&&("Clob"===t.DBType||"String"===t.DBType||"Attachment"===t.businessType)&&"Aggregation"!==t.businessType,g=(0,i.useMemo)((()=>{const e=t.indexedLanguageId&&d[t.indexedLanguageId];return null!=e?e:void 0}),[t.indexedLanguageId]);return i.default.createElement(l.Card,{title:Liferay.Language.get("searchable")},a&&i.default.createElement(n.default,{displayType:"info",title:"Info"},Liferay.Language.get("if-the-search-configuration-of-this-object-field-is-updated")),i.default.createElement(r.default.Group,null,i.default.createElement(r.ClayToggle,{label:Liferay.Language.get("searchable"),name:"indexed",onToggle:e=>c({indexed:e}),toggled:t.indexed})),f&&i.default.createElement(r.default.Group,null,i.default.createElement(r.ClayRadioGroup,{onChange:a=>{const t="true"===a;c({indexedAsKeyword:t,indexedLanguageId:t?null:e})},value:new Boolean(t.indexedAsKeyword).toString()},i.default.createElement(r.ClayRadio,{disabled:u,label:Liferay.Language.get("keyword"),value:"true"}),i.default.createElement(r.ClayRadio,{disabled:u,label:Liferay.Language.get("text"),value:"false"}))),f&&!t.indexedAsKeyword&&i.default.createElement(l.SingleSelect,{label:Liferay.Language.get("language"),onChange:e=>{const[a]=Object.entries(d).find((([,a])=>e.label===a));c({indexedLanguageId:a})},options:o,required:!0,value:g}))};var n=function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}(t("@frontend-taglib-clay$clayui/alert")),r=_interopRequireWildcard(t("@frontend-taglib-clay$clayui/form")),l=t("@liferay/object-js-components-web"),i=_interopRequireWildcard(t("liferay!frontend-js-react-web$react"));function _getRequireWildcardCache(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return _getRequireWildcardCache=function _getRequireWildcardCache(){return e},e}function _interopRequireWildcard(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=_getRequireWildcardCache();if(a&&a.has(e))return a.get(e);var t={},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){var l=n?Object.getOwnPropertyDescriptor(e,r):null;l&&(l.get||l.set)?Object.defineProperty(t,r,l):t[r]=e[r]}return t.default=e,a&&a.set(e,t),t}const e=Liferay.ThemeDisplay.getDefaultLanguageId(),d=Liferay.Language.available,o=Object.values(d).map((e=>({label:e})))}}));
//# sourceMappingURL=SearchableContainer.js.map