Liferay.Loader.define("@liferay/layout-content-page-editor-web@3.0.132/page_editor/app/components/fragment-configuration-fields/HideFromSearchField",["module","exports","require","@frontend-taglib-clay$clayui/button","liferay!frontend-js-react-web$prop-types","liferay!frontend-js-react-web$react","../../config/constants/viewportSizes","../../contexts/ControlsContext","../../contexts/StoreContext","../../thunks/updateItemConfig","./CheckboxField"],(function(e,t,n){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.HideFromSearchField=function({item:e}){const t=(0,l.useDispatch)(),n=(0,l.useSelector)((e=>e.selectedViewportSize)),u=(0,l.useSelector)((e=>e.layoutData)),s=(0,r.useSelectItem)();if(n!==i.VIEWPORT_SIZES.desktop)return null;const g=f(u,e);return o.default.createElement(o.default.Fragment,null,o.default.createElement(c.CheckboxField,{disabled:Boolean(g),field:{label:Liferay.Language.get("hide-from-site-search-results"),name:"indexed"},onValueSelect:(n,a)=>{t((0,d.default)({itemConfig:{[n]:!a},itemId:e.itemId}))},title:g?Liferay.Language.get("configuration-inherited-from-parent-fragment"):null,value:g||!1===e.config.indexed}),g&&o.default.createElement(o.default.Fragment,null,o.default.createElement("p",{className:"m-0 small text-secondary"},Liferay.Language.get("this-configuration-is-inherited")),o.default.createElement(a.default,{className:"p-0 page-editor__hide-feedback-button text-left",displayType:"link",onClick:()=>s(g)},Liferay.Language.get("go-to-parent-fragment-to-edit"))))};var a=u(n("@frontend-taglib-clay$clayui/button")),o=(u(n("liferay!frontend-js-react-web$prop-types")),u(n("liferay!frontend-js-react-web$react"))),i=n("../../config/constants/viewportSizes"),r=n("../../contexts/ControlsContext"),l=n("../../contexts/StoreContext"),d=u(n("../../thunks/updateItemConfig")),c=n("./CheckboxField");function u(e){return e&&e.__esModule?e:{default:e}}function f(e,t){const n=e.items[t.parentId];return n?!1===n.config.indexed?n.itemId:f(e,n):null}}}));
//# sourceMappingURL=HideFromSearchField.js.map