HEX
Server: nginx/1.27.1
System: Linux in-3 5.15.0-161-generic #171-Ubuntu SMP Sat Oct 11 08:17:01 UTC 2025 x86_64
User: ivenus-clone (3297)
PHP: 7.4.33
Disabled: exec,passthru,shell_exec,system,proc_open,popen,parse_ini_file,show_source
Upload Files
File: /storage/v4513/ivenusin/public_html/wp-content/plugins/amp/assets/js/amp-block-validation.js
(()=>{var e={11:(e,t,r)=>{var n={"./amp-block-validation.js":93,"./amp-document-setting-panel.js":877,"./amp-pre-publish-panel.js":327};function i(e){var t=a(e);return r(t)}function a(e){if(!r.o(n,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return n[e]}i.keys=function(){return Object.keys(n)},i.resolve=a,e.exports=i,i.id=11},44:(e,t,r)=>{"use strict";r.d(t,{Z:()=>h});var n=r(307),i=(r(196),r(736)),a=r(609),l=r(818),s=r(883),o=r(201),c=r(361),u=r(504),d=r(590),m=r(93);function E(){const{isAMPEnabled:e,toggleAMP:t}=(0,u.c)(),r=(0,n.useRef)(`amp-toggle-${Math.random().toString(32).substr(-4)}`);return(0,n.createElement)(n.Fragment,null,(0,n.createElement)("label",{htmlFor:r.current},(0,i.__)("Enable AMP","amp")),(0,n.createElement)(a.FormToggle,{checked:e,onChange:t,id:r.current}))}var p=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("g",{clipPath:"url(#clip-amp-validation-errors-kept)",fill:"#BB522E"},(0,n.createElement)("path",{d:"M10.762 2.541c4.4 0 8 3.6 8 8 0 1.6-.5 3-1.2 4.2l1.4 1.5c1.1-1.6 1.8-3.6 1.8-5.7 0-5.5-4.5-10-10-10-2 0-3.9.6-5.5 1.7l1.4 1.5c1.2-.8 2.6-1.2 4.1-1.2ZM.762 10.541c0 5.5 4.5 10 10 10 2.7 0 5.1-1.1 6.9-2.8l-14-14.2c-1.8 1.8-2.9 4.3-2.9 7Zm10 8c-4.4 0-8-3.6-8-8 0-1.5.4-2.8 1.1-4l10.9 10.9c-1.2.7-2.5 1.1-4 1.1Z"}),(0,n.createElement)("path",{d:"M14.262 9.74c.1 0 .1-.1.1-.2 0-.2-.2-.4-.4-.4h-2l1.6 1.6.7-1ZM12.461 4.541h-.8l-1.6 2.6 1.7 1.7.7-4.3ZM7.462 11.541s-.1.1-.1.2c0 .2.2.4.4.4h2.3l-.8 4.5h.7l2.6-4.1-3.5-3.6-1.6 2.6Z"})),(0,n.createElement)("defs",null,(0,n.createElement)("clipPath",{id:"clip-amp-validation-errors-kept"},(0,n.createElement)("path",{fill:"#fff",transform:"translate(.762 .541)",d:"M0 0h20v20H0z"}))))};p.defaultProps={width:"21",height:"21",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var g=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{fill:"#707070",d:"M8 20c1.1 0 2-.9 2-2H6c0 1.1.9 2 2 2zm6-6V9c0-3.07-1.63-5.64-4.5-6.32V2C9.5 1.17 8.83.5 8 .5S6.5 1.17 6.5 2v.68C3.64 3.36 2 5.92 2 9v5l-2 2v1h16v-1l-2-2zm-2 1H4V9c0-2.48 1.51-4.5 4-4.5s4 2.02 4 4.5v6z"}))};function h(){const{isAMPEnabled:e}=(0,u.c)(),{isFetchingErrors:t,fetchingErrorsMessage:r}=(0,d.P)(),{openGeneralSidebar:h,closePublishSidebar:v}=(0,l.useDispatch)("core/edit-post"),{isPostDirty:_,maybeIsPostDirty:f,keptMarkupValidationErrorCount:w,reviewedValidationErrorCount:P,unreviewedValidationErrorCount:k}=(0,l.useSelect)((e=>({isPostDirty:e(s.jd).getIsPostDirty(),maybeIsPostDirty:e(s.jd).getMaybeIsPostDirty(),keptMarkupValidationErrorCount:e(s.jd).getKeptMarkupValidationErrors().length,reviewedValidationErrorCount:e(s.jd).getReviewedValidationErrors().length,unreviewedValidationErrorCount:e(s.jd).getUnreviewedValidationErrors().length})),[]);if(!e)return(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(E,null));if(t)return(0,n.createElement)(n.Fragment,null,(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(E,null)),(0,n.createElement)(c.H,{message:r,isLoading:!0,isSmall:!0}));const b=()=>{v(),h(`${m.PLUGIN_NAME}/${m.SIDEBAR_NAME}`)};return _||f?(0,n.createElement)(n.Fragment,null,(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(E,null)),(0,n.createElement)(c.H,{icon:(0,n.createElement)(g,null),message:f?(0,i.__)("Content may have changed. Trigger validation in the AMP Validation sidebar.","amp"):(0,i.__)("Content has changed. Trigger validation in the AMP Validation sidebar.","amp"),isSmall:!0}),(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(a.Button,{onClick:b,isSecondary:!0,isSmall:!0},(0,i.__)("Open AMP Validation","amp")))):w>0?(0,n.createElement)(n.Fragment,null,(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(E,null)),(0,n.createElement)(c.H,{icon:(0,n.createElement)(p,null),message:(0,i.sprintf)(/* translators: %d is count of validation errors whose invalid markup is kept */
(0,i._n)("AMP is blocked due to %d validation issue marked as kept.","AMP is blocked due to %d validation issues marked as kept.",w,"amp"),w),isSmall:!0}),(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(a.Button,{onClick:b,isSecondary:!0,isSmall:!0},(0,i._n)("Review issue","Review issues",w,"amp")))):k>0?(0,n.createElement)(n.Fragment,null,(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(E,null)),(0,n.createElement)(c.H,{icon:(0,n.createElement)(o.Jj,{broken:!0}),message:(0,i.sprintf)(/* translators: %d is count of unreviewed validation error */
(0,i._n)("AMP is valid, but %d issue needs review.","AMP is valid, but %d issues need review.",k,"amp"),k),isSmall:!0}),(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(a.Button,{onClick:b,isSecondary:!0,isSmall:!0},(0,i._n)("Review issue","Review issues",k,"amp")))):(0,n.createElement)(n.Fragment,null,(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(E,null)),(0,n.createElement)(c.H,{icon:(0,n.createElement)(o.Jj,null),message:P>0?(0,i.sprintf)(/* translators: %d is count of unreviewed validation error */
(0,i._n)("AMP is valid. %d issue was reviewed.","AMP is valid. %d issues were reviewed.",P,"amp"),P):(0,i.__)("No AMP validation issues detected.","amp"),isSmall:!0}),P>0&&(0,n.createElement)(a.PanelRow,null,(0,n.createElement)(a.Button,{onClick:b,isSecondary:!0,isSmall:!0},(0,i.__)("Open AMP Validation","amp"))))}g.defaultProps={fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 20"}},201:(e,t,r)=>{"use strict";r.d(t,{Jj:()=>d,_4:()=>c,mE:()=>u});var n=r(307),i=(r(196),function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{fill:"#0075C2",d:"m13.3 9.1-4 6.6h-.8l.7-4.3H7c-.2 0-.4-.2-.4-.4 0-.1.1-.2.1-.2l4-6.6h.7l-.7 4.3h2.2c.2 0 .4.2.4.4.1.1 0 .2 0 .2zM10 .5C4.7.5.4 4.8.4 10c0 5.3 4.3 9.5 9.6 9.5s9.6-4.3 9.6-9.5c0-5.3-4.3-9.5-9.6-9.5z"}))});i.defaultProps={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"};var a=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{d:"M9.863 16.815h-.7l.8-4.5h-2.3c-.2 0-.4-.2-.4-.4 0-.1.1-.2.1-.2l4.2-7h.8l-.8 4.6h2.3c.2 0 .4.2.4.4 0 .1 0 .2-.1.2l-4.3 6.9Zm.8-16.1c-5.5 0-10 4.5-10 10s4.5 10 10 10 10-4.5 10-10-4.5-10-10-10Z"}))};a.defaultProps={width:"21",height:"21",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var l=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M.913 10.283c0 5.5 4.5 10 10 10s10-4.5 10-10-4.5-10-10-10-10 4.5-10 10Z",fill:"#fff"}),(0,n.createElement)("path",{d:"M10.113 16.383h-.7l.8-4.5h-2.3c-.2 0-.4-.2-.4-.4 0-.1.1-.2.1-.2l4.2-7h.8l-.8 4.6h2.3c.2 0 .4.2.4.4 0 .1 0 .2-.1.2l-4.3 6.9Zm.8-16.1c-5.5 0-10 4.5-10 10s4.5 10 10 10 10-4.5 10-10-4.5-10-10-10Z",fill:"#37414B"}),(0,n.createElement)("circle",{cx:"10.913",cy:"10.283",r:"9",stroke:"#BB522E",strokeWidth:"2"}),(0,n.createElement)("path",{stroke:"#BB522E",strokeWidth:"2",d:"M16.518 17.346 3.791 4.618"}),(0,n.createElement)("path",{stroke:"#fff",strokeWidth:"2",d:"M19.805 18.118 3.282 1.249"}))};function s(e){let{hasBadge:t}=e;return(0,n.createElement)("span",{className:"amp-toolbar-icon components-menu-items__item-icon"+(t?" amp-toolbar-icon--has-badge":"")},(0,n.createElement)(a,null))}function o(e){let{hasBadge:t}=e;return(0,n.createElement)("span",{className:"amp-toolbar-broken-icon"+(t?" amp-toolbar-broken-icon--has-badge":"")},(0,n.createElement)(l,null))}function c(e){let{broken:t=!1,count:r}=e;return(0,n.createElement)("div",{className:"amp-plugin-icon "+(t?"amp-plugin-icon--broken":"")},t?(0,n.createElement)(o,{hasBadge:Boolean(r)}):(0,n.createElement)(s,{hasBadge:Boolean(r)}),0<r&&(0,n.createElement)("div",{className:"amp-error-count-badge"},r))}function u(){return(0,n.createElement)(s,{hasBadge:!1})}function d(e){let{broken:t=!1}=e;return(0,n.createElement)("div",{className:"amp-status-icon "+(t?"amp-status-icon--broken":"")},(0,n.createElement)(i,null))}l.defaultProps={width:"21",height:"21",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},361:(e,t,r)=>{"use strict";r.d(t,{H:()=>o,Z:()=>c});var n=r(307),i=r(184),a=r.n(i),l=r(609);function s(e){let{inline:t=!1}=e;const r=t?"span":"div";return(0,n.createElement)(r,{className:a()("amp-spinner-container",{"amp-spinner-container--inline":t})},(0,n.createElement)(l.Spinner,null))}function o(e){let{action:t,icon:r,isLoading:i=!1,isSmall:l=!1,message:o}=e;const c=i?(0,n.createElement)(s,null):r;return(0,n.createElement)("div",{className:a()("sidebar-notification",{"is-loading":i,"is-small":l})},c&&(0,n.createElement)("div",{className:"sidebar-notification__icon"},c),(0,n.createElement)("div",{className:"sidebar-notification__content"},(0,n.createElement)("p",null,o),t&&(0,n.createElement)("div",{className:"sidebar-notification__action"},t)))}function c(e){let{children:t,isShady:r}=e;return(0,n.createElement)("div",{className:a()("sidebar-notifications-container",{"is-shady":r})},t)}},504:(e,t,r)=>{"use strict";r.d(t,{c:()=>i});var n=r(818);function i(){const e=(0,n.useSelect)((e=>e("core/editor").getEditedPostAttribute("amp_enabled")||!1),[]),{editPost:t}=(0,n.useDispatch)("core/editor");return{isAMPEnabled:e,toggleAMP:()=>t({amp_enabled:!e})}}},590:(e,t,r)=>{"use strict";r.d(t,{P:()=>o});var n=r(307),i=r(818),a=r(333),l=r(736),s=r(883);function o(){const[e,t]=(0,n.useState)(!1),[r,o]=(0,n.useState)(""),{isEditedPostNew:c,isFetchingErrors:u}=(0,i.useSelect)((e=>({isEditedPostNew:e("core/editor").isEditedPostNew(),isFetchingErrors:e(s.jd).getIsFetchingErrors()})),[]),d=(0,a.usePrevious)(c),m=(0,a.usePrevious)(u);return(0,n.useEffect)((()=>{e||!u&&m&&t(!0)}),[e,u,m]),(0,n.useEffect)((()=>{o(e?(0,l.__)("Re-validating content.","amp"):c||d?(0,l.__)("Validating content.","amp"):u?(0,l.__)("Loading…","amp"):"")}),[e,c,u,d]),{isFetchingErrors:u,fetchingErrorsMessage:r}}},93:(e,t,r)=>{"use strict";r.r(t),r.d(t,{PLUGIN_ICON:()=>$,PLUGIN_NAME:()=>Z,PLUGIN_TITLE:()=>J,SIDEBAR_NAME:()=>G,default:()=>W});var n=r(307),i=r(736),a=r(67),l=r(818),s=r(883),o=r(201),c=r(609),u=r(361),d=(r(196),r(590)),m=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{fill:"#707070",d:"M8 20c1.1 0 2-.9 2-2H6c0 1.1.9 2 2 2zm6-6V9c0-3.07-1.63-5.64-4.5-6.32V2C9.5 1.17 8.83.5 8 .5S6.5 1.17 6.5 2v.68C3.64 3.36 2 5.92 2 9v5l-2 2v1h16v-1l-2-2zm-2 1H4V9c0-2.48 1.51-4.5 4-4.5s4 2.02 4 4.5v6z"}))};function E(){const{autosave:e,savePost:t}=(0,l.useDispatch)("core/editor"),{isFetchingErrors:r,fetchingErrorsMessage:a}=(0,d.P)(),{isDraft:o,isPostDirty:E,maybeIsPostDirty:p}=(0,l.useSelect)((e=>({isDraft:-1!==["draft","auto-draft"].indexOf(e("core/editor").getEditedPostAttribute("status")),isPostDirty:e(s.jd).getIsPostDirty(),maybeIsPostDirty:e(s.jd).getMaybeIsPostDirty()})),[]);return r?(0,n.createElement)(u.H,{message:a,isLoading:!0}):E||p?(0,n.createElement)(u.H,{icon:(0,n.createElement)(m,null),message:p?(0,i.__)("Content may have changed.","amp"):(0,i.__)("Content has changed.","amp"),action:o?(0,n.createElement)(c.Button,{isLink:!0,onClick:()=>t({isPreview:!0})},(0,i.__)("Save draft and validate","amp")):(0,n.createElement)(c.Button,{isLink:!0,onClick:()=>e({isPreview:!0})},(0,i.__)("Re-validate","amp"))}):null}m.defaultProps={fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 20"};var p=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("g",{clipPath:"url(#clip-amp-validation-errors-kept)",fill:"#BB522E"},(0,n.createElement)("path",{d:"M10.762 2.541c4.4 0 8 3.6 8 8 0 1.6-.5 3-1.2 4.2l1.4 1.5c1.1-1.6 1.8-3.6 1.8-5.7 0-5.5-4.5-10-10-10-2 0-3.9.6-5.5 1.7l1.4 1.5c1.2-.8 2.6-1.2 4.1-1.2ZM.762 10.541c0 5.5 4.5 10 10 10 2.7 0 5.1-1.1 6.9-2.8l-14-14.2c-1.8 1.8-2.9 4.3-2.9 7Zm10 8c-4.4 0-8-3.6-8-8 0-1.5.4-2.8 1.1-4l10.9 10.9c-1.2.7-2.5 1.1-4 1.1Z"}),(0,n.createElement)("path",{d:"M14.262 9.74c.1 0 .1-.1.1-.2 0-.2-.2-.4-.4-.4h-2l1.6 1.6.7-1ZM12.461 4.541h-.8l-1.6 2.6 1.7 1.7.7-4.3ZM7.462 11.541s-.1.1-.1.2c0 .2.2.4.4.4h2.3l-.8 4.5h.7l2.6-4.1-3.5-3.6-1.6 2.6Z"})),(0,n.createElement)("defs",null,(0,n.createElement)("clipPath",{id:"clip-amp-validation-errors-kept"},(0,n.createElement)("path",{fill:"#fff",transform:"translate(.762 .541)",d:"M0 0h20v20H0z"}))))};function g(){const{autosave:e,savePost:t}=(0,l.useDispatch)("core/editor"),{isFetchingErrors:r}=(0,d.P)(),{fetchingErrorsRequestErrorMessage:a,isDraft:m,isEditedPostNew:E,keptMarkupValidationErrorCount:g,reviewLink:h,supportLink:v,unreviewedValidationErrorCount:_,validationErrorCount:f}=(0,l.useSelect)((e=>({fetchingErrorsRequestErrorMessage:e(s.jd).getFetchingErrorsRequestErrorMessage(),isDraft:-1!==["draft","auto-draft"].indexOf(e("core/editor").getEditedPostAttribute("status")),isEditedPostNew:e("core/editor").isEditedPostNew(),keptMarkupValidationErrorCount:e(s.jd).getKeptMarkupValidationErrors().length,reviewLink:e(s.jd).getReviewLink(),supportLink:e(s.jd).getSupportLink(),unreviewedValidationErrorCount:e(s.jd).getUnreviewedValidationErrors().length,validationErrorCount:e(s.jd).getValidationErrors().length})),[]);if(r)return null;if(E)return(0,n.createElement)(u.H,{icon:(0,n.createElement)(o.Jj,null),message:(0,i.__)("Validation will be checked upon saving.","amp")});const w=h&&(0,n.createElement)(n.Fragment,null,(0,n.createElement)(c.ExternalLink,{href:h},(0,i.__)("View technical details","amp")),(0,n.createElement)("br",null),v&&(0,n.createElement)(c.ExternalLink,{href:v},(0,i.__)("Get Support","amp")));return a?(0,n.createElement)(u.H,{icon:(0,n.createElement)(p,null),message:a,action:(0,n.createElement)(c.Button,{isLink:!0,onClick:m?()=>t({isPreview:!0}):()=>e({isPreview:!0})},(0,i.__)("Try again","amp"))}):g>0?(0,n.createElement)(u.H,{icon:(0,n.createElement)(p,null),message:(0,i.sprintf)(/* translators: %d is count of validation errors whose invalid markup is kept */
(0,i._n)("AMP is disabled due to invalid markup being kept for %d issue.","AMP is disabled due to invalid markup being kept for %d issues.",g,"amp"),g),action:w}):_>0?(0,n.createElement)(u.H,{icon:(0,n.createElement)(o.Jj,{broken:!0}),message:(0,i.sprintf)(/* translators: %d is count of unreviewed validation error */
(0,i._n)("AMP is valid, but %d issue needs review.","AMP is valid, but %d issues need review.",_,"amp"),_),action:w}):f>0?(0,n.createElement)(u.H,{icon:(0,n.createElement)(o.Jj,null),message:(0,i.sprintf)(/* translators: %d is count of unreviewed validation error */
(0,i._n)("AMP is valid. %d issue was reviewed.","AMP is valid. %d issues were reviewed.",f,"amp"),f),action:w}):(0,n.createElement)(u.H,{icon:(0,n.createElement)(o.Jj,null),message:(0,i.__)("No AMP validation issues detected.","amp")})}function h(){return(0,n.createElement)(u.Z,{isShady:!0},(0,n.createElement)(E,null),(0,n.createElement)(g,null))}p.defaultProps={width:"21",height:"21",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var v=r(184),_=r.n(v),f=r(422),w=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{d:"m2.45 3.068 3.34 1.178v1.64L.743 3.749V2.365L5.79.227v1.64L2.45 3.068Zm8.19-.017L7.237 1.86V.232l5.104 2.14v1.376L7.236 5.893V4.258l3.405-1.207Z",fill:"#fff"}))};w.defaultProps={width:"13",height:"6",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var P=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{d:"M3.675.959h1.5v4.9c0 .5-.1.9-.3 1.2-.2.3-.5.6-.8.8-.4.2-.8.3-1.2.3-.8 0-1.3-.2-1.8-.6-.4-.4-.6-.9-.6-1.6h1.5c0 .3.1.6.2.8.1.2.4.2.7.2.3 0 .5-.1.7-.3.2-.2.2-.5.2-.8v-4.9h-.1ZM10.075 6.26c0-.3-.1-.5-.3-.6-.2-.1-.5-.3-1.1-.5-.5-.2-.9-.3-1.2-.5-.8-.4-1.2-1-1.2-1.8 0-.4.1-.7.3-1 .2-.3.5-.5.9-.7.5-.2 1-.3 1.5-.3s1 .1 1.4.3c.4.2.7.4.9.8.2.3.3.7.3 1.1h-1.5c0-.3-.1-.6-.3-.8-.2-.2-.5-.3-.9-.3s-.6.1-.8.2c-.2.2-.3.3-.3.6 0 .2.1.4.3.6.2.2.6.3 1 .4.8.3 1.4.6 1.8.9.4.3.6.8.6 1.4 0 .6-.2 1.1-.7 1.4-.5.4-1.1.5-1.9.5-.5 0-1-.1-1.5-.3-.4-.2-.8-.5-1-.8-.2-.3-.4-.8-.4-1.2h1.5c0 .8.5 1.2 1.4 1.2.3 0 .6-.1.8-.2.3 0 .4-.2.4-.4Z",fill:"#fff"}))};P.defaultProps={width:"12",height:"9",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var k=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{d:"M4.13 6.46h-1.2l-.4 2.4h-1.1l.4-2.4H.53v-1h1.5l.3-1.7h-1.3v-1h1.5l.4-2.4h1.1l-.4 2.4h1.1l.4-2.4h1.1l-.4 2.4h1.3v1h-1.5l-.3 1.7h1.3v1h-1.5l-.4 2.4h-1.1l.5-2.4Zm-1-1h1.1l.3-1.7h-1.1l-.3 1.7Z",fill:"#fff"}))};function b(e){let{type:t}=e;switch(t){case f.HTML_ATTRIBUTE_ERROR_TYPE:case f.HTML_ELEMENT_ERROR_TYPE:return(0,n.createElement)(w,null);case f.JS_ERROR_TYPE:return(0,n.createElement)(P,null);case f.CSS_ERROR_TYPE:return(0,n.createElement)(k,null);default:return null}}function S(e){let{kept:t,title:r,error:{type:a}}=e;return(0,n.createElement)("div",{className:"amp-error__panel-title",title:t?(0,i.__)("This error has been kept, making this URL not AMP-compatible.","amp"):""},(0,n.createElement)("div",{className:"amp-error__icons"},a&&(0,n.createElement)("div",{className:`amp-error__error-type-icon amp-error__error-type-icon--${a?.replace(/_/g,"-")}`},(0,n.createElement)(b,{type:a}))),(0,n.createElement)("div",{className:"amp-error__title",dangerouslySetInnerHTML:{__html:r}}))}k.defaultProps={width:"8",height:"9",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var R=r(175);function A(e){const t={theme:[],plugin:[],"mu-plugin":[],embed:[],core:[],blocks:[]};if(!e?.length)return t;for(const r of e)r.type&&r.type in t?t[r.type].push(r):"block_name"in r&&t.blocks.push(r);return t}var y=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{d:"m10.075 4.055 6.275 10.842H3.8l6.275-10.842Zm0-3.325L.908 16.564h18.333L10.075.73Zm.833 11.667H9.242v1.667h1.666v-1.667Zm0-5H9.242v3.333h1.666V7.397Z",fill:"#BE2C23"}))};y.defaultProps={width:"20",height:"17",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var I=function(e){return(0,n.createElement)("svg",e,(0,n.createElement)("path",{d:"M12.258 9.043 10.49 10.81 8.716 9.043l-1.175 1.175 1.775 1.767-1.767 1.767 1.175 1.175 1.767-1.767 1.767 1.767 1.175-1.175-1.767-1.767 1.767-1.767-1.175-1.175Zm1.15-5.391-.834-.834H8.408l-.834.834H4.658v1.666h11.666V3.652h-2.916Zm-7.917 12.5c0 .916.75 1.666 1.667 1.666h6.666c.917 0 1.667-.75 1.667-1.666v-10h-10v10Zm1.667-8.334h6.666v8.334H7.158V7.818Z",fill:"#479696"}))};function T(e){let t,{clientId:r,blockTypeName:a,sources:l}=e;const s=f.blockSources?.[a];if(r&&"core/shortcode"!==a)switch(s?.type){case"plugin":t=(0,i.sprintf)(/* translators: %s: plugin name. */
(0,i.__)("%s (plugin)","amp"),s.title);break;case"mu-plugin":t=(0,i.sprintf)(/* translators: %s: plugin name. */
(0,i.__)("%s (must-use plugin)","amp"),s.title);break;case"theme":t=(0,i.sprintf)(/* translators: %s: theme name. */
(0,i.__)("%s (theme)","amp"),s.title);break;default:t=s?.title}return t||(t=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];const t=A(e),r=[],n=new Set(t.plugin.map((e=>{let{name:t}=e;return t}))),a=new Set(t["mu-plugin"].map((e=>{let{name:t}=e;return t})));let l=[...n,...a];if(l.length>1&&(l=l.filter((e=>"gutenberg"!==e))),1===l.length)r.push(f.pluginNames[l[0]]||l[0]);else{const e=n.size,t=a.size;0<e&&r.push((0,i.sprintf)("%1$s (%2$d)",(0,i.__)("Plugins","amp"),e)),0<t&&r.push((0,i.sprintf)("%1$s (%2$d)",(0,i.__)("Must-use plugins","amp"),t))}if(0===t.embed.length){const e=t.theme.filter((e=>{let{name:t}=e;return f.themeSlug===t})),n=t.theme.filter((e=>{let{name:t}=e;return f.themeSlug!==t}));0<e.length&&r.push(f.themeName),0<n.length&&
/* translators: placeholder is the slug of an inactive WordPress theme. */
r.push((0,i.__)("Inactive theme(s)","amp"))}return 0===r.length&&0<t.blocks.length&&r.push(t.blocks[0].block_name),0===r.length&&0<t.embed.length&&r.push((0,i.__)("Embed","amp")),0===r.length&&0<t.core.length&&r.push((0,i.__)("Core","amp")),!r.length&&e?.length&&r.push((0,i.__)("Unknown","amp")),r.join(", ")}(l)),(0,n.createElement)(n.Fragment,null,(0,n.createElement)("dt",null,(0,i.__)("Source","amp")),(0,n.createElement)("dd",null,t))}function M(e){let t,r,{status:a}=e;return t=[f.VALIDATION_ERROR_NEW_ACCEPTED_STATUS,f.VALIDATION_ERROR_ACK_ACCEPTED_STATUS].includes(a)?(0,n.createElement)("span",{className:"amp-error__kept-removed amp-error__kept-removed--removed"},(0,i.__)("Removed","amp"),(0,n.createElement)("span",null,(0,n.createElement)(I,null))):(0,n.createElement)("span",{className:"amp-error__kept-removed amp-error__kept-removed--kept"},(0,i.__)("Kept","amp"),(0,n.createElement)("span",null,(0,n.createElement)(y,null))),r=[f.VALIDATION_ERROR_ACK_ACCEPTED_STATUS,f.VALIDATION_ERROR_ACK_REJECTED_STATUS].includes(a)?(0,i.__)("Yes","amp"):(0,i.__)("No","amp"),(0,n.createElement)(n.Fragment,null,(0,n.createElement)("dt",null,(0,i.__)("Markup status","amp")),(0,n.createElement)("dd",null,t),(0,n.createElement)("dt",null,(0,i.__)("Reviewed","amp")),(0,n.createElement)("dd",null,r))}function N(e){let{blockTypeIcon:t,blockTypeTitle:r}=e;return(0,n.createElement)(n.Fragment,null,(0,n.createElement)("dt",null,(0,i.__)("Block type","amp")),(0,n.createElement)("dd",null,(0,n.createElement)("span",{className:"amp-error__block-type-description"},r||(0,i.__)("unknown","amp"),t&&(0,n.createElement)("span",{className:"amp-error__block-type-icon"},(0,n.createElement)(R.BlockIcon,{icon:t})))))}function C(e){let{blockType:t,clientId:r,error:{sources:a},isExternal:l,removed:s,status:o}=e;const c=t?.title,u=t?.name,d=t?.icon;return(0,n.createElement)(n.Fragment,null,s&&(0,n.createElement)("p",null,(0,i.__)("This error is no longer detected, either because the block was removed or the editor mode was switched.","amp")),l&&(0,n.createElement)("p",null,(0,i.__)("This error comes from outside the content (e.g. header or footer).","amp")),(0,n.createElement)("dl",{className:"amp-error__details"},!(s||l)&&(0,n.createElement)(N,{blockTypeIcon:d,blockTypeTitle:c}),(0,n.createElement)(T,{blockTypeName:u,clientId:r,sources:a}),(0,n.createElement)(M,{status:o})))}function D(e){let{clientId:t,error:r,status:a,term_id:o,title:u}=e;const{selectBlock:d}=(0,l.useDispatch)("core/block-editor"),m=(0,l.useSelect)((e=>e(s.jd).getReviewLink()),[]),E=a===f.VALIDATION_ERROR_ACK_ACCEPTED_STATUS||a===f.VALIDATION_ERROR_ACK_REJECTED_STATUS,p=a===f.VALIDATION_ERROR_ACK_REJECTED_STATUS||a===f.VALIDATION_ERROR_NEW_REJECTED_STATUS,g=!Boolean(t),{blockType:h,removed:v}=(0,l.useSelect)((e=>{const r=e("core/block-editor").getBlockName(t);return{removed:t&&!r,blockType:e("core/blocks").getBlockType(r)}}),[t]);let w=null;m&&(w=new URL(m),w.hash=`#tag-${o}`);const P=_()("amp-error",{"amp-error--reviewed":E,"amp-error--new":!E,"amp-error--removed":v,"amp-error--kept":p,[`error-${t}`]:t});return(0,n.createElement)(c.PanelBody,{className:P,title:(0,n.createElement)(S,{error:r,kept:p,title:u}),initialOpen:!1},(0,n.createElement)(C,{blockType:h,clientId:t,error:r,isExternal:g,removed:v,status:a}),(0,n.createElement)("div",{className:"amp-error__actions"},!(v||g)&&(0,n.createElement)(c.Button,{className:"amp-error__select-block",isSecondary:!0,onClick:()=>{d(t)}},(0,i.__)("Select block","amp")),w&&(0,n.createElement)(c.ExternalLink,{href:w.href,className:"amp-error__details-link"},(0,i.__)("View details","amp"))))}function V(){const{setIsShowingReviewed:e}=(0,l.useDispatch)(s.jd),{displayedErrors:t,hasReviewedValidationErrors:r,isShowingReviewed:a}=(0,l.useSelect)((e=>{const t=e(s.jd).getIsShowingReviewed();return{displayedErrors:t?e(s.jd).getValidationErrors():e(s.jd).getUnreviewedValidationErrors(),hasReviewedValidationErrors:e(s.jd).getReviewedValidationErrors()?.length>0,isShowingReviewed:t}}),[]);return(0,n.useEffect)((()=>{const e=document.querySelector(".amp-sidebar a, .amp-sidebar button, .amp-sidebar input");e&&e.focus()}),[]),(0,n.createElement)("div",{className:"amp-sidebar"},(0,n.createElement)(h,null),0<t.length&&(0,n.createElement)("ul",{className:"amp-sidebar__errors-list"},t.map(((e,t)=>(0,n.createElement)("li",{key:`${e.clientId}${t}`,className:"amp-sidebar__errors-list-item"},(0,n.createElement)(D,e))))),r&&(0,n.createElement)("div",{className:"amp-sidebar__options"},(0,n.createElement)(c.Button,{isLink:!0,onClick:()=>e(!a)},a?(0,i.__)("Hide reviewed issues","amp"):(0,i.__)("Show reviewed issues","amp"))))}function L(){const e=(0,l.useSelect)((e=>e(s.jd).getUnreviewedValidationErrors()),[]),t=(0,n.useMemo)((()=>e.map((e=>{let{clientId:t}=e;return t})).filter((e=>e)).map((e=>`#block-${e}::before`))),[e]);return(0,n.createElement)("style",null,`${t.join(",")} {\n\t\t\t\t\tborder-radius: 9px;\n\t\t\t\t\tbottom: -3px;\n\t\t\t\t\tbox-shadow: 0 0 0 2px #bb522e;\n\t\t\t\t\tcontent: '';\n\t\t\t\t\tleft: -3px;\n\t\t\t\t\tpointer-events: none;\n\t\t\t\t\tposition: absolute;\n\t\t\t\t\tright: -3px;\n\t\t\t\t\ttop: -3px;\n\t\t\t\t}`)}I.defaultProps={width:"21",height:"21",fill:"none",xmlns:"http://www.w3.org/2000/svg"};var O=r(333);const B=window.lodash,j=window.wp.apiFetch;var x=r.n(j);const U=window.wp.url;function F(e){let{validationError:t,source:r,currentPostId:n,blockOrder:i,getBlock:a}=e;if(!r.block_name||void 0===r.block_content_index)return;if(n!==r.post_id)return;const l=i[r.block_content_index];if(!l)return;const s=a(l);s&&s.name===r.block_name&&(t.clientId=l)}var H=r(504);const Z="amp-block-validation",G="amp-editor-sidebar",J=(0,i.__)("AMP Validation","amp"),$=o.mE;function W(){const{broken:e,errorCount:t}=(0,l.useSelect)((e=>({broken:e(s.jd).getAMPCompatibilityBroken(),errorCount:e(s.jd).getUnreviewedValidationErrors()?.length||0})),[]),{isAMPEnabled:r}=(0,H.c)();return function(){const[e,t]=(0,n.useState)([]),[r,a]=(0,n.useState)(!1),[o,c]=(0,n.useState)([]),[u,d]=(0,n.useState)(!1),{setIsFetchingErrors:m,setFetchingErrorsRequestErrorMessage:E,setReviewLink:p,setSupportLink:g,setValidationErrors:h}=(0,l.useDispatch)(s.jd),{currentPostId:v,getBlock:_,getClientIdsWithDescendants:f,isAutosavingPost:w,isEditedPostNew:P,isPreviewingPost:k,isSavingPost:b,previewLink:S,validationErrors:R}=(0,l.useSelect)((e=>({currentPostId:e("core/editor").getCurrentPostId(),getBlock:e("core/block-editor").getBlock,getClientIdsWithDescendants:e("core/block-editor").getClientIdsWithDescendants,isAutosavingPost:e("core/editor").isAutosavingPost(),isEditedPostNew:e("core/editor").isEditedPostNew(),isPreviewingPost:e("core/editor").isPreviewingPost(),isSavingPost:e("core/editor").isSavingPost(),previewLink:e("core/editor").getEditedPostPreviewLink(),validationErrors:e(s.jd).getValidationErrors()})),[]),A=(0,O.usePrevious)(P);(0,n.useEffect)((()=>{P||A||d(!0)}),[P,A]),(0,n.useEffect)((()=>{if(b)return k?(d(!0),void a(!0)):void(w||d(!0))}),[w,k,b]),(0,n.useEffect)((()=>{if(!u)return;if(b)return void m(!0);if(r&&!(0,U.isURL)(S))return;const e={id:v};r&&(e.preview_nonce=(0,U.getQueryArg)(S,"preview_nonce")),m(!0),d(!1),a(!1),E(""),t(f()),x()({path:"/amp/v1/validate-post-url/",method:"POST",data:e}).then((e=>{h(e.results),p(e.review_link),g(e.support_link)})).catch((e=>{E(e?.message||(0,i.__)("Whoops! Something went wrong.","amp"))})).finally((()=>{m(!1)}))}),[v,f,r,b,S,E,m,p,g,h,u]),(0,n.useEffect)((()=>{R&&!(0,B.isEqual)(o,R)&&c(R)}),[o,R]),(0,n.useEffect)((()=>{const t=o.map((t=>{if(!t.error.sources?.length)return t;for(const r of t.error.sources){if("clientId"in t)break;F({validationError:t,source:r,getBlock:_,blockOrder:0<e.length?e:f(),currentPostId:v})}return t}));h(t)}),[e,v,_,f,h,o])}(),function(){const[e,t]=(0,n.useState)(null),[r,i]=(0,n.useState)(),a=(0,n.useRef)(null),{setIsPostDirty:o,setMaybeIsPostDirty:c}=(0,l.useDispatch)(s.jd),{getEditedPostContent:u,hasErrorsFromRemovedBlocks:d,hasActiveMetaboxes:m,isPostDirty:E,isSavingOrPreviewingPost:p}=(0,l.useSelect)((e=>({getEditedPostContent:e("core/editor").getEditedPostContent,hasErrorsFromRemovedBlocks:Boolean(e(s.jd).getValidationErrors().find((t=>{let{clientId:r}=t;return r&&!e("core/block-editor").getBlockName(r)}))),hasActiveMetaboxes:e("core/edit-post").hasMetaBoxes(),isPostDirty:e(s.jd).getIsPostDirty(),isSavingOrPreviewingPost:e("core/editor").isSavingPost()&&!e("core/editor").isAutosavingPost()||e("core/editor").isPreviewingPost()})),[]);(0,n.useEffect)((()=>()=>{a.current&&a.current()}),[]),(0,n.useEffect)((()=>{E&&p&&(o(!1),t(null))}),[E,p,o]),(0,n.useEffect)((()=>{if(null===e){const e=u();return t(e),void i(e)}r!==e&&o(!0)}),[e,u,o,r]),(0,n.useEffect)((()=>{c(!E&&(m||d))}),[m,d,E,c]);const g=(0,n.useCallback)((()=>{i(u())}),[u]),h=(0,O.useDebounce)(g,500);(0,n.useEffect)((()=>{E&&a.current?(a.current(),a.current=null):p||E||a.current||(a.current=(0,l.subscribe)(h))}),[h,E,p])}(),r?(0,n.createElement)(n.Fragment,null,(0,n.createElement)(a.PluginSidebarMoreMenuItem,{icon:(0,n.createElement)($,null),target:G},J),(0,n.createElement)(a.PluginSidebar,{className:`${Z}-sidebar`,icon:(0,n.createElement)(o._4,{count:t,broken:e}),name:G,title:J},(0,n.createElement)(V,null),(0,n.createElement)(L,null))):null}},877:(e,t,r)=>{"use strict";r.r(t),r.d(t,{PLUGIN_ICON:()=>o,PLUGIN_NAME:()=>s,default:()=>c});var n=r(307),i=r(736),a=r(67),l=r(44);const s="amp-block-validation-document-setting-panel",o="";function c(){return(0,n.createElement)(a.PluginDocumentSettingPanel,{name:s,title:(0,i.__)("AMP","amp"),initialOpen:!0},(0,n.createElement)(l.Z,null))}},327:(e,t,r)=>{"use strict";r.r(t),r.d(t,{PLUGIN_ICON:()=>o,PLUGIN_NAME:()=>s,default:()=>c});var n=r(307),i=r(736),a=r(67),l=r(44);const s="amp-block-validation-pre-publish-panel",o="";function c(){return(0,n.createElement)(a.PluginPrePublishPanel,{title:(0,i.__)("AMP","amp"),initialOpen:!0},(0,n.createElement)(l.Z,null))}},883:(e,t,r)=>{"use strict";r.d(t,{MT:()=>g,Y6:()=>p,jd:()=>a});var n=r(422),i=r(818);const a="amp/block-validation",l="SET_FETCHING_ERRORS_REQUEST_ERROR_MESSAGE",s="SET_IS_FETCHING_ERRORS",o="SET_IS_POST_DIRTY",c="SET_IS_SHOWING_REVIEWED",u="SET_MAYBE_IS_POST_DIRTY",d="SET_REVIEW_LINK",m="SET_SUPPORT_LINK",E="SET_VALIDATION_ERRORS",p={ampCompatibilityBroken:!1,fetchingErrorsRequestErrorMessage:"",isPostDirty:!1,isFetchingErrors:!1,isShowingReviewed:!1,keptMarkupValidationErrors:[],maybeIsPostDirty:!1,rawValidationErrors:[],reviewLink:null,supportLink:null,reviewedValidationErrors:[],unreviewedValidationErrors:[],validationErrors:[]};function g(e){(0,i.registerStore)(a,function(e){return{reducer:function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,r=arguments.length>1?arguments[1]:void 0;switch(r.type){case l:return{...t,fetchingErrorsRequestErrorMessage:r.fetchingErrorsRequestErrorMessage};case s:return{...t,isFetchingErrors:r.isFetchingErrors};case o:return{...t,isPostDirty:r.isPostDirty};case c:return{...t,isShowingReviewed:r.isShowingReviewed};case u:return{...t,maybeIsPostDirty:r.maybeIsPostDirty};case d:return{...t,reviewLink:r.reviewLink};case m:return{...t,supportLink:r.supportLink};case E:return{...t,ampCompatibilityBroken:Boolean(r.validationErrors.filter((e=>{let{status:t}=e;return t===n.VALIDATION_ERROR_NEW_REJECTED_STATUS||t===n.VALIDATION_ERROR_ACK_REJECTED_STATUS}))?.length),reviewedValidationErrors:r.validationErrors.filter((e=>{let{status:t}=e;return t===n.VALIDATION_ERROR_ACK_ACCEPTED_STATUS||t===n.VALIDATION_ERROR_ACK_REJECTED_STATUS})),unreviewedValidationErrors:r.validationErrors.filter((e=>{let{status:t}=e;return t===n.VALIDATION_ERROR_NEW_ACCEPTED_STATUS||t===n.VALIDATION_ERROR_NEW_REJECTED_STATUS})),keptMarkupValidationErrors:r.validationErrors.filter((e=>{let{status:t}=e;return t===n.VALIDATION_ERROR_NEW_REJECTED_STATUS||t===n.VALIDATION_ERROR_ACK_REJECTED_STATUS})),validationErrors:r.validationErrors};default:return t}},actions:{setFetchingErrorsRequestErrorMessage:e=>({type:l,fetchingErrorsRequestErrorMessage:e}),setIsFetchingErrors:e=>({type:s,isFetchingErrors:e}),setIsPostDirty:e=>({type:o,isPostDirty:e}),setIsShowingReviewed:e=>({type:c,isShowingReviewed:e}),setMaybeIsPostDirty:e=>({type:u,maybeIsPostDirty:e}),setReviewLink:e=>({type:d,reviewLink:e}),setSupportLink:e=>({type:m,supportLink:e}),setValidationErrors:e=>({type:E,validationErrors:e})},selectors:{getAMPCompatibilityBroken:e=>{let{ampCompatibilityBroken:t}=e;return t},getFetchingErrorsRequestErrorMessage:e=>{let{fetchingErrorsRequestErrorMessage:t}=e;return t},getIsFetchingErrors:e=>{let{isFetchingErrors:t}=e;return t},getIsPostDirty:e=>{let{isPostDirty:t}=e;return t},getIsShowingReviewed:e=>{let{isShowingReviewed:t}=e;return t},getMaybeIsPostDirty:e=>{let{maybeIsPostDirty:t}=e;return t},getReviewLink:e=>{let{reviewLink:t}=e;return t},getSupportLink:e=>{let{supportLink:t}=e;return t},getReviewedValidationErrors:e=>{let{reviewedValidationErrors:t}=e;return t},getUnreviewedValidationErrors:e=>{let{unreviewedValidationErrors:t}=e;return t},getKeptMarkupValidationErrors:e=>{let{keptMarkupValidationErrors:t}=e;return t},getValidationErrors:e=>{let{validationErrors:t}=e;return t}},initialState:e}}(e))}},184:(e,t)=>{var r;!function(){"use strict";var n={}.hasOwnProperty;function i(){for(var e=[],t=0;t<arguments.length;t++){var r=arguments[t];if(r){var a=typeof r;if("string"===a||"number"===a)e.push(r);else if(Array.isArray(r)){if(r.length){var l=i.apply(null,r);l&&e.push(l)}}else if("object"===a){if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]")){e.push(r.toString());continue}for(var s in r)n.call(r,s)&&r[s]&&e.push(s)}}}return e.join(" ")}e.exports?(i.default=i,e.exports=i):void 0===(r=function(){return i}.apply(t,[]))||(e.exports=r)}()},422:e=>{"use strict";e.exports=ampBlockValidation},196:e=>{"use strict";e.exports=window.React},175:e=>{"use strict";e.exports=window.wp.blockEditor},609:e=>{"use strict";e.exports=window.wp.components},333:e=>{"use strict";e.exports=window.wp.compose},818:e=>{"use strict";e.exports=window.wp.data},67:e=>{"use strict";e.exports=window.wp.editPost},307:e=>{"use strict";e.exports=window.wp.element},736:e=>{"use strict";e.exports=window.wp.i18n}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var a=t[n]={exports:{}};return e[n](a,a.exports,r),a.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{"use strict";const e=window.wp.hooks,t=window.wp.plugins;var n=r(883);function i(){return i=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},i.apply(this,arguments)}var a=r(307),l=r(818),s=r(333),o=r(175),c=r(609),u=r(201),d=r(93),m=r(504);function E(e){let{clientId:t,count:r}=e;const{openGeneralSidebar:n}=(0,l.useDispatch)("core/edit-post"),{isAMPEnabled:i}=(0,m.c)();return i?(0,a.createElement)(o.BlockControls,null,(0,a.createElement)(c.ToolbarButton,{onClick:()=>{n(`${d.PLUGIN_NAME}/${d.SIDEBAR_NAME}`),setTimeout((()=>{const e=Array.from(document.querySelectorAll(`.error-${t} button`)),r=e[0];e.reverse();for(const t of e)"false"===t.getAttribute("aria-expanded")&&t.click();r&&r.scrollIntoView({block:"start",inline:"nearest",behavior:"smooth"})}))}},(0,a.createElement)(u._4,{count:r}))):null}function p(e){const{BlockEdit:t,clientId:r}=e,i=(0,l.useSelect)((e=>(e(n.jd).getUnreviewedValidationErrors()||[]).filter((e=>{let{clientId:t}=e;return r===t})).length||0),[r]);return(0,a.createElement)(a.Fragment,null,0<i&&(0,a.createElement)(E,{clientId:r,count:i}),(0,a.createElement)(t,e))}const g=(0,s.createHigherOrderComponent)((e=>t=>(0,a.createElement)(p,i({},t,{BlockEdit:e}))),"BlockEditWithAMPToolbar");(0,n.MT)(n.Y6);const h=r(11);h.keys().forEach((e=>{const{default:r,PLUGIN_NAME:n,PLUGIN_ICON:i}=h(e);(0,t.registerPlugin)(n,{icon:i,render:r})})),(0,e.addFilter)("editor.BlockEdit","ampBlockValidation/filterEdit",g,-99)})()})();