"use strict";(self.webpackChunkflow_web_extension=self.webpackChunkflow_web_extension||[]).push([["14214"],{501935:function(a,t,e){e.r(t),e.d(t,{HandleProcessingBlockContentChildren:()=>d});var o,l=e(698127),n=e(706790),r=e(468461),c=e(957994),s=e(981299),i=()=>(0,r.Z)(a=>{if(a){var{id:t="",parent_id:e="",children:o}=a;(0,c.ty)().setState(r=>{var c=(0,n._)((0,l._)({},r.blockDataMap),{[t]:o}),s=c[e]||[],i=s.map(e=>e.id!==t?e:(0,l._)({},a));s.length&&(c[e]=i);var p=(0,n._)((0,l._)({},r.blockDataMapMetaInfo||{}),{[t]:(0,n._)((0,l._)({},r.blockDataMapMetaInfo[t]||{}),{updateTime:Date.now()})});return(0,n._)((0,l._)({},r),{blockDataMap:c,blockDataMapMetaInfo:p})})}},1e3,{leading:!0,trailing:!0});class p{update(a){var{id:t}=a;if(t){var e=this.record[t]||i();this.record[t]=e,e(a)}}constructor(){this.record={}}}var _=(o=null,()=>(o||(o=new p),o));class d{constructor(){this.pluginIdentifier=s._,this.resolveContentBlock=a=>{var{operation:t,contentBlockTree:e}=a,{id:o=""}=null!=e?e:{};o&&("update"===t?_().update(e):"delete"===t&&(0,c.ty)().setState(a=>a.blockDataMap[o]?(delete a.blockDataMap[o],delete a.blockDataMapMetaInfo[o],(0,n._)((0,l._)({},a),{blockDataMap:(0,l._)({},a.blockDataMap),blockDataMapMetaInfo:(0,l._)({},a.blockDataMapMetaInfo)})):a))}}}}}]);
//# sourceMappingURL=14214.js.map