strapi-plugin-comments 3.0.12 → 3.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react/jsx-runtime"),W=require("@strapi/strapi/admin"),he=require("react-router-dom"),g=require("./index-DYUGPksR.js"),K=require("@tanstack/react-query"),O=require("./index-hoQGufqY.js"),X_=require("zustand/react"),ee=require("react"),me=require("styled-components"),Z_=require("codemirror5"),J_=require("sanitize-html"),ed=require("punycode");require("codemirror5/addon/display/placeholder");const lt=t=>t&&t.__esModule?t:{default:t};function td(t){if(t&&t.__esModule)return t;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const se=td(ee),Ue=lt(me),mo=lt(Z_),Bo=lt(J_),nd=lt(ed),rd=()=>d.jsxs(g.SubNav,{ariaLabel:"Comments sub nav",children:[d.jsx(g.SubNavHeader,{label:"Comments"}),d.jsx(g.SubNavSections,{children:d.jsxs(g.SubNavSection,{label:"Moderation",children:[d.jsx(g.SubNavLink,{href:"/admin/plugins/comments/discover",children:"Discover"}),d.jsx(g.SubNavLink,{href:"/admin/plugins/comments/reports",withBullet:!1,children:"Reports"})]})})]}),ad=t=>{const e=O.useAPI();return K.useQuery({queryKey:e.config.getKey(),queryFn:()=>e.config.query().then(n=>(t(n),n))})},od=X_.create(t=>({settings:{entryLabel:{},approvalFlow:[],blockedAuthorProps:[],reportReasons:{BAD_LANGUAGE:"BAD_LANGUAGE",DISCRIMINATION:"DISCRIMINATION",OTHER:"OTHER"},regex:{uid:"",relatedUid:"",email:"",sorting:""},enabledCollections:[],moderatorRoles:[],isGQLPluginEnabled:!1,client:{url:"",contactEmail:""}},setSettings:e=>t({settings:e})})),id=(t="")=>`/plugins/${g.pluginId}/${t}`,sd=(t=null,e=null,n="app.components.notification.error")=>{throw e({type:"warning",message:`${g.pluginId}.${n}`}),t||new Error("error")},Go=(t="")=>g.lodashExports.isString(t)?t.split(" ").map(e=>g.lodashExports.first(e)).join("").toUpperCase():"",cd=({removed:t,blocked:e,blockedThread:n,approvalStatus:r,reviewFlowEnabled:a})=>{const i=!g.lodashExports.isNil(r);if(t)return O.COMMENT_STATUS.REMOVED;if(e||n)return O.COMMENT_STATUS.BLOCKED;if(a)return O.COMMENT_STATUS.TO_REVIEW;if(i){const o=r.toUpperCase();return Object.keys(O.COMMENT_STATUS).includes(o)?o:O.COMMENT_STATUS.UNKNOWN}return O.COMMENT_STATUS.OPEN},ld=t=>{if(Object.values(O.COMMENT_STATUS).includes(t))switch(t){case O.COMMENT_STATUS.REMOVED:return"secondary";case O.COMMENT_STATUS.TO_REVIEW:case O.COMMENT_STATUS.REJECTED:return"warning";case O.COMMENT_STATUS.BLOCKED:return"danger";case O.COMMENT_STATUS.OPEN:case O.COMMENT_STATUS.APPROVED:return"success"}return"secondary"},_d=({resolved:t,related:{blocked:e,blockedThread:n},approvalStatus:r})=>{const a=!g.lodashExports.isNil(r);if(e||n)return O.REPORT_STATUS.BLOCKED;if(t)return O.REPORT_STATUS.RESOLVED;if(a){const i=r.toUpperCase();return Object.keys(O.REPORT_STATUS).includes(i)?i:O.REPORT_STATUS.PENDING}return O.REPORT_STATUS.PENDING},dd=t=>{switch(t){case O.REPORT_STATUS.PENDING:return"primary";case O.REPORT_STATUS.RESOLVED:return"success";case O.REPORT_STATUS.BLOCKED:return"danger";default:return"primary"}},qo=t=>{const[e,n]=t.split("/").filter(r=>r.length>0);return{value:e,flags:n}},ud=({config:t,entity:e,filters:n,onChangeFilters:r,schema:a})=>{const{entryLabel:i={}}=t,{attributes:o={}}=a,{removed:c=!1}=n;K.useQueryClient();const s=Object.keys(o),l=g.lodashExports.first(i[e?.uid]),m=g.lodashExports.take(s.filter(f=>o[f].type==="string"&&!g.lodashExports.isNil(e[f])&&f!==l),5),u=(f="")=>f.split("_").map(E=>g.lodashExports.capitalize(E)).join(" "),p=e&&!g.lodashExports.isEmpty(e)&&(!g.lodashExports.isEmpty(m)||e[l]),S=ee.useCallback(f=>{r({...n,removed:f||void 0})},[r,n]);return d.jsxs(g.Box,{padding:4,background:"neutral0",width:"100%",children:[p&&d.jsxs(g.Box,{marginBottom:4,children:[d.jsx(g.Typography,{variant:"sigma",textColor:"neutral600",id:"entity-details",children:O.getMessage("page.details.panel.entity","Details")}),d.jsx(g.Box,{paddingTop:2,paddingBottom:4,children:d.jsx(g.Divider,{})}),d.jsxs(g.Flex,{children:[d.jsxs(g.Flex,{direction:"column",alignItems:"flex-start",children:[d.jsx(g.Typography,{fontWeight:"bold",children:u(l)}),d.jsx(g.Typography,{children:e[l]})]}),d.jsx(g.Flex,{space:4,children:m.map(f=>d.jsxs(g.Flex,{direction:"column",alignItems:"flex-start",children:[d.jsx(g.Typography,{fontWeight:"bold",children:u(f)}),d.jsx(g.Typography,{children:e[f]})]},`prop_${f}`))})]})]}),d.jsxs(g.Box,{children:[d.jsx(g.Typography,{variant:"sigma",textColor:"neutral600",id:"view-filters",children:O.getMessage("page.details.filters.label","View")}),d.jsx(g.Box,{paddingTop:2,paddingBottom:4,children:d.jsx(g.Divider,{})}),d.jsx(g.Flex,{children:d.jsx(g.CheckboxImpl,{checked:c,onCheckedChange:S,children:O.getMessage("page.details.filters.removed.label","Show removed comments")})})]})]})},Fe=(t={comment:{},report:{}})=>{const e=O.useAPI(),{canModerate:n}=O.usePermissions(),r=f=>n?f:void 0,a=K.useMutation({mutationFn:r(e.comments.block),onSuccess:t.comment?.blockSuccess,onError:t.comment?.blockError}),i=K.useMutation({mutationFn:r(e.comments.unblock),onSuccess:t.comment?.unBlockSuccess,onError:t.comment?.unBlockError}),o=K.useMutation({mutationFn:r(e.comments.blockThread),onSuccess:t.comment?.blockThreadSuccess,onError:t.comment?.blockThreadError}),c=K.useMutation({mutationFn:r(e.comments.unBlockThread),onSuccess:t.comment?.unBlockThreadSuccess,onError:t.comment?.unBlockThreadError}),s=K.useMutation({mutationFn:r(e.comments.delete),onSuccess:t.comment?.deleteSuccess,onError:t.comment?.deleteError}),l=K.useMutation({mutationFn:r(e.comments.postComment),onSuccess:t.comment?.postCommentSuccess,onError:t.comment?.postCommentError}),_=K.useMutation({mutationFn:r(e.reports.resolveMultipleReports),onSuccess:t.report?.resolveMultipleSuccess,onError:t.report?.resolveMultipleError}),m=K.useMutation({mutationFn:r(e.reports.resolveCommentMultipleReports),onSuccess:t.report?.resolveCommentMultipleReportsSuccess,onError:t.report?.resolveCommentMultipleReportsError}),u=K.useMutation({mutationFn:r(e.reports.resolve),onSuccess:t.report?.resolveSuccess,onError:t.report?.resolveError}),p=K.useMutation({mutationFn:r(e.reports.resolveAllAbuseReportsForComment),onSuccess:t.report?.resolveAllAbuseSuccess,onError:t.report?.resolveAllAbuseError}),S=K.useMutation({mutationFn:r(e.reports.resolveAllAbuseReportsForThread),onSuccess:t.report?.resolveAllAbuseThreadSuccess,onError:t.report?.resolveAllAbuseThreadError});return ee.useMemo(()=>({commentMutation:{block:a,unBlock:i,blockThread:o,unBlockThread:c,delete:s,postComment:l},reportMutation:{resolve:u,resolveMultiple:_,resolveAllAbuse:p,resolveAllAbuseThread:S,resolveCommentMultipleReports:m}}),[a,i,o,c,_,p,S,s,u])},To=()=>{const t=ee.useContext(O.UserContext);if(!t)throw new Error("UserContext is not provided");return t},go=Ue.default(g.Button)(({isSingle:t})=>({padding:"7px 16px",marginLeft:t?"0":".5rem",whiteSpace:"nowrap"})),m_=({id:t,canModerate:e,queryKey:n})=>{const{toggleNotification:r}=W.useNotification(),a=K.useQueryClient(),i=O.useAPI(),o=u=>async()=>{await a.invalidateQueries({exact:!1,queryKey:n}),r({type:"success",message:`${g.pluginId}.${u}`})},c=u=>{sd(u,r)},s=K.useMutation({mutationKey:["approveItem",t],mutationFn:i.comments.approve,onSuccess:o("success.approveItem"),onError:c}),l=()=>{s.mutate(t)},_=K.useMutation({mutationKey:["rejectItem",t],mutationFn:i.comments.reject,onSuccess:o("success.rejectItem"),onError:c}),m=()=>{_.mutate(t)};return e?d.jsxs(d.Fragment,{children:[d.jsx(g.IconButton,{onClick:l,label:"Approve",children:d.jsx(g.ForwardRef$4F,{})}),d.jsx(g.IconButton,{label:"Reject",onClick:m,children:d.jsx(g.ForwardRef$45,{})})]}):null},pd=Ue.default(g.Badge)`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react/jsx-runtime"),W=require("@strapi/strapi/admin"),he=require("react-router-dom"),g=require("./index-C1LkPp9p.js"),K=require("@tanstack/react-query"),O=require("./index-CiNGZPZv.js"),X_=require("zustand/react"),ee=require("react"),me=require("styled-components"),Z_=require("codemirror5"),J_=require("sanitize-html"),ed=require("punycode");require("codemirror5/addon/display/placeholder");const lt=t=>t&&t.__esModule?t:{default:t};function td(t){if(t&&t.__esModule)return t;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const se=td(ee),Ue=lt(me),mo=lt(Z_),Bo=lt(J_),nd=lt(ed),rd=()=>d.jsxs(g.SubNav,{ariaLabel:"Comments sub nav",children:[d.jsx(g.SubNavHeader,{label:"Comments"}),d.jsx(g.SubNavSections,{children:d.jsxs(g.SubNavSection,{label:"Moderation",children:[d.jsx(g.SubNavLink,{href:"/admin/plugins/comments/discover",children:"Discover"}),d.jsx(g.SubNavLink,{href:"/admin/plugins/comments/reports",withBullet:!1,children:"Reports"})]})})]}),ad=t=>{const e=O.useAPI();return K.useQuery({queryKey:e.config.getKey(),queryFn:()=>e.config.query().then(n=>(t(n),n))})},od=X_.create(t=>({settings:{entryLabel:{},approvalFlow:[],blockedAuthorProps:[],reportReasons:{BAD_LANGUAGE:"BAD_LANGUAGE",DISCRIMINATION:"DISCRIMINATION",OTHER:"OTHER"},regex:{uid:"",relatedUid:"",email:"",sorting:""},enabledCollections:[],moderatorRoles:[],isGQLPluginEnabled:!1,client:{url:"",contactEmail:""}},setSettings:e=>t({settings:e})})),id=(t="")=>`/plugins/${g.pluginId}/${t}`,sd=(t=null,e=null,n="app.components.notification.error")=>{throw e({type:"warning",message:`${g.pluginId}.${n}`}),t||new Error("error")},Go=(t="")=>g.lodashExports.isString(t)?t.split(" ").map(e=>g.lodashExports.first(e)).join("").toUpperCase():"",cd=({removed:t,blocked:e,blockedThread:n,approvalStatus:r,reviewFlowEnabled:a})=>{const i=!g.lodashExports.isNil(r);if(t)return O.COMMENT_STATUS.REMOVED;if(e||n)return O.COMMENT_STATUS.BLOCKED;if(a)return O.COMMENT_STATUS.TO_REVIEW;if(i){const o=r.toUpperCase();return Object.keys(O.COMMENT_STATUS).includes(o)?o:O.COMMENT_STATUS.UNKNOWN}return O.COMMENT_STATUS.OPEN},ld=t=>{if(Object.values(O.COMMENT_STATUS).includes(t))switch(t){case O.COMMENT_STATUS.REMOVED:return"secondary";case O.COMMENT_STATUS.TO_REVIEW:case O.COMMENT_STATUS.REJECTED:return"warning";case O.COMMENT_STATUS.BLOCKED:return"danger";case O.COMMENT_STATUS.OPEN:case O.COMMENT_STATUS.APPROVED:return"success"}return"secondary"},_d=({resolved:t,related:{blocked:e,blockedThread:n},approvalStatus:r})=>{const a=!g.lodashExports.isNil(r);if(e||n)return O.REPORT_STATUS.BLOCKED;if(t)return O.REPORT_STATUS.RESOLVED;if(a){const i=r.toUpperCase();return Object.keys(O.REPORT_STATUS).includes(i)?i:O.REPORT_STATUS.PENDING}return O.REPORT_STATUS.PENDING},dd=t=>{switch(t){case O.REPORT_STATUS.PENDING:return"primary";case O.REPORT_STATUS.RESOLVED:return"success";case O.REPORT_STATUS.BLOCKED:return"danger";default:return"primary"}},qo=t=>{const[e,n]=t.split("/").filter(r=>r.length>0);return{value:e,flags:n}},ud=({config:t,entity:e,filters:n,onChangeFilters:r,schema:a})=>{const{entryLabel:i={}}=t,{attributes:o={}}=a,{removed:c=!1}=n;K.useQueryClient();const s=Object.keys(o),l=g.lodashExports.first(i[e?.uid]),m=g.lodashExports.take(s.filter(f=>o[f].type==="string"&&!g.lodashExports.isNil(e[f])&&f!==l),5),u=(f="")=>f.split("_").map(E=>g.lodashExports.capitalize(E)).join(" "),p=e&&!g.lodashExports.isEmpty(e)&&(!g.lodashExports.isEmpty(m)||e[l]),S=ee.useCallback(f=>{r({...n,removed:f||void 0})},[r,n]);return d.jsxs(g.Box,{padding:4,background:"neutral0",width:"100%",children:[p&&d.jsxs(g.Box,{marginBottom:4,children:[d.jsx(g.Typography,{variant:"sigma",textColor:"neutral600",id:"entity-details",children:O.getMessage("page.details.panel.entity","Details")}),d.jsx(g.Box,{paddingTop:2,paddingBottom:4,children:d.jsx(g.Divider,{})}),d.jsxs(g.Flex,{children:[d.jsxs(g.Flex,{direction:"column",alignItems:"flex-start",children:[d.jsx(g.Typography,{fontWeight:"bold",children:u(l)}),d.jsx(g.Typography,{children:e[l]})]}),d.jsx(g.Flex,{space:4,children:m.map(f=>d.jsxs(g.Flex,{direction:"column",alignItems:"flex-start",children:[d.jsx(g.Typography,{fontWeight:"bold",children:u(f)}),d.jsx(g.Typography,{children:e[f]})]},`prop_${f}`))})]})]}),d.jsxs(g.Box,{children:[d.jsx(g.Typography,{variant:"sigma",textColor:"neutral600",id:"view-filters",children:O.getMessage("page.details.filters.label","View")}),d.jsx(g.Box,{paddingTop:2,paddingBottom:4,children:d.jsx(g.Divider,{})}),d.jsx(g.Flex,{children:d.jsx(g.CheckboxImpl,{checked:c,onCheckedChange:S,children:O.getMessage("page.details.filters.removed.label","Show removed comments")})})]})]})},Fe=(t={comment:{},report:{}})=>{const e=O.useAPI(),{canModerate:n}=O.usePermissions(),r=f=>n?f:void 0,a=K.useMutation({mutationFn:r(e.comments.block),onSuccess:t.comment?.blockSuccess,onError:t.comment?.blockError}),i=K.useMutation({mutationFn:r(e.comments.unblock),onSuccess:t.comment?.unBlockSuccess,onError:t.comment?.unBlockError}),o=K.useMutation({mutationFn:r(e.comments.blockThread),onSuccess:t.comment?.blockThreadSuccess,onError:t.comment?.blockThreadError}),c=K.useMutation({mutationFn:r(e.comments.unBlockThread),onSuccess:t.comment?.unBlockThreadSuccess,onError:t.comment?.unBlockThreadError}),s=K.useMutation({mutationFn:r(e.comments.delete),onSuccess:t.comment?.deleteSuccess,onError:t.comment?.deleteError}),l=K.useMutation({mutationFn:r(e.comments.postComment),onSuccess:t.comment?.postCommentSuccess,onError:t.comment?.postCommentError}),_=K.useMutation({mutationFn:r(e.reports.resolveMultipleReports),onSuccess:t.report?.resolveMultipleSuccess,onError:t.report?.resolveMultipleError}),m=K.useMutation({mutationFn:r(e.reports.resolveCommentMultipleReports),onSuccess:t.report?.resolveCommentMultipleReportsSuccess,onError:t.report?.resolveCommentMultipleReportsError}),u=K.useMutation({mutationFn:r(e.reports.resolve),onSuccess:t.report?.resolveSuccess,onError:t.report?.resolveError}),p=K.useMutation({mutationFn:r(e.reports.resolveAllAbuseReportsForComment),onSuccess:t.report?.resolveAllAbuseSuccess,onError:t.report?.resolveAllAbuseError}),S=K.useMutation({mutationFn:r(e.reports.resolveAllAbuseReportsForThread),onSuccess:t.report?.resolveAllAbuseThreadSuccess,onError:t.report?.resolveAllAbuseThreadError});return ee.useMemo(()=>({commentMutation:{block:a,unBlock:i,blockThread:o,unBlockThread:c,delete:s,postComment:l},reportMutation:{resolve:u,resolveMultiple:_,resolveAllAbuse:p,resolveAllAbuseThread:S,resolveCommentMultipleReports:m}}),[a,i,o,c,_,p,S,s,u])},To=()=>{const t=ee.useContext(O.UserContext);if(!t)throw new Error("UserContext is not provided");return t},go=Ue.default(g.Button)(({isSingle:t})=>({padding:"7px 16px",marginLeft:t?"0":".5rem",whiteSpace:"nowrap"})),m_=({id:t,canModerate:e,queryKey:n})=>{const{toggleNotification:r}=W.useNotification(),a=K.useQueryClient(),i=O.useAPI(),o=u=>async()=>{await a.invalidateQueries({exact:!1,queryKey:n}),r({type:"success",message:`${g.pluginId}.${u}`})},c=u=>{sd(u,r)},s=K.useMutation({mutationKey:["approveItem",t],mutationFn:i.comments.approve,onSuccess:o("success.approveItem"),onError:c}),l=()=>{s.mutate(t)},_=K.useMutation({mutationKey:["rejectItem",t],mutationFn:i.comments.reject,onSuccess:o("success.rejectItem"),onError:c}),m=()=>{_.mutate(t)};return e?d.jsxs(d.Fragment,{children:[d.jsx(g.IconButton,{onClick:l,label:"Approve",children:d.jsx(g.ForwardRef$4F,{})}),d.jsx(g.IconButton,{label:"Reject",onClick:m,children:d.jsx(g.ForwardRef$45,{})})]}):null},pd=Ue.default(g.Badge)`
2
2
  padding: 5px 8px;
3
3
  border: 1px ${({theme:t,color:e})=>t.colors[`${e}200`]} solid;
4
4
 
@@ -0,0 +1,18 @@
1
+ "use strict";const z=require("react/jsx-runtime"),b=require("./index-C1LkPp9p.js"),fr=require("@tanstack/react-query"),Y=require("react"),Qr=require("@strapi/strapi/admin"),a=require("zod");function Ht(r){if(r&&r.__esModule)return r;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const t in r)if(t!=="default"){const n=Object.getOwnPropertyDescriptor(r,t);Object.defineProperty(e,t,n.get?n:{enumerable:!0,get:()=>r[t]})}}return e.default=r,Object.freeze(e)}const ae=Ht(Y),Yt=()=>{const r=()=>window.matchMedia("(prefers-color-scheme: dark)").matches,[e,t]=Y.useState();return Y.useEffect(()=>{const o=r()?"dark":"light",i=window.localStorage?.STRAPI_THEME;t(i==="system"?o:i)},[]),{theme:e==="dark"?b.darkTheme:b.lightTheme,themeName:e}};var ce=TypeError;const Kt={},Qt=Object.freeze(Object.defineProperty({__proto__:null,default:Kt},Symbol.toStringTag,{value:"Module"})),Jt=b.getAugmentedNamespace(Qt);var pr=typeof Map=="function"&&Map.prototype,De=Object.getOwnPropertyDescriptor&&pr?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,we=pr&&De&&typeof De.get=="function"?De.get:null,Ar=pr&&Map.prototype.forEach,yr=typeof Set=="function"&&Set.prototype,Le=Object.getOwnPropertyDescriptor&&yr?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,Re=yr&&Le&&typeof Le.get=="function"?Le.get:null,Pr=yr&&Set.prototype.forEach,Xt=typeof WeakMap=="function"&&WeakMap.prototype,fe=Xt?WeakMap.prototype.has:null,Zt=typeof WeakSet=="function"&&WeakSet.prototype,pe=Zt?WeakSet.prototype.has:null,en=typeof WeakRef=="function"&&WeakRef.prototype,Or=en?WeakRef.prototype.deref:null,rn=Boolean.prototype.valueOf,tn=Object.prototype.toString,nn=Function.prototype.toString,on=String.prototype.match,dr=String.prototype.slice,H=String.prototype.replace,an=String.prototype.toUpperCase,$r=String.prototype.toLowerCase,Jr=RegExp.prototype.test,wr=Array.prototype.concat,L=Array.prototype.join,ln=Array.prototype.slice,Rr=Math.floor,rr=typeof BigInt=="function"?BigInt.prototype.valueOf:null,Be=Object.getOwnPropertySymbols,tr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,ie=typeof Symbol=="function"&&typeof Symbol.iterator=="object",ye=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===ie||!0)?Symbol.toStringTag:null,Xr=Object.prototype.propertyIsEnumerable,zr=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(r){return r.__proto__}:null);function Tr(r,e){if(r===1/0||r===-1/0||r!==r||r&&r>-1e3&&r<1e3||Jr.call(/e/,e))return e;var t=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof r=="number"){var n=r<0?-Rr(-r):Rr(r);if(n!==r){var o=String(n),i=dr.call(e,o.length+1);return H.call(o,t,"$&_")+"."+H.call(H.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return H.call(e,t,"$&_")}var nr=Jt,_r=nr.custom,Cr=rt(_r)?_r:null,Zr={__proto__:null,double:'"',single:"'"},un={__proto__:null,double:/(["\\])/g,single:/(['\\])/g},Ce=function r(e,t,n,o){var i=t||{};if(U(i,"quoteStyle")&&!U(Zr,i.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(U(i,"maxStringLength")&&(typeof i.maxStringLength=="number"?i.maxStringLength<0&&i.maxStringLength!==1/0:i.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var u=U(i,"customInspect")?i.customInspect:!0;if(typeof u!="boolean"&&u!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(U(i,"indent")&&i.indent!==null&&i.indent!==" "&&!(parseInt(i.indent,10)===i.indent&&i.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(U(i,"numericSeparator")&&typeof i.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var l=i.numericSeparator;if(typeof e>"u")return"undefined";if(e===null)return"null";if(typeof e=="boolean")return e?"true":"false";if(typeof e=="string")return nt(e,i);if(typeof e=="number"){if(e===0)return 1/0/e>0?"0":"-0";var c=String(e);return l?Tr(e,c):c}if(typeof e=="bigint"){var s=String(e)+"n";return l?Tr(e,s):s}var y=typeof i.depth>"u"?5:i.depth;if(typeof n>"u"&&(n=0),n>=y&&y>0&&typeof e=="object")return or(e)?"[Array]":"[Object]";var d=wn(i,n);if(typeof o>"u")o=[];else if(tt(o,e)>=0)return"[Circular]";function m(N,G,ee){if(G&&(o=ln.call(o),o.push(G)),ee){var V={depth:i.depth};return U(i,"quoteStyle")&&(V.quoteStyle=i.quoteStyle),r(N,V,n+1,o)}return r(N,i,n+1,o)}if(typeof e=="function"&&!xr(e)){var h=gn(e),v=Ee(e,m);return"[Function"+(h?": "+h:" (anonymous)")+"]"+(v.length>0?" { "+L.call(v,", ")+" }":"")}if(rt(e)){var w=ie?H.call(String(e),/^(Symbol\(.*\))_[^)]*$/,"$1"):tr.call(e);return typeof e=="object"&&!ie?se(w):w}if(Pn(e)){for(var C="<"+$r.call(String(e.nodeName)),S=e.attributes||[],x=0;x<S.length;x++)C+=" "+S[x].name+"="+et(cn(S[x].value),"double",i);return C+=">",e.childNodes&&e.childNodes.length&&(C+="..."),C+="</"+$r.call(String(e.nodeName))+">",C}if(or(e)){if(e.length===0)return"[]";var O=Ee(e,m);return d&&!$n(O)?"["+ar(O,d)+"]":"[ "+L.call(O,", ")+" ]"}if(fn(e)){var $=Ee(e,m);return!("cause"in Error.prototype)&&"cause"in e&&!Xr.call(e,"cause")?"{ ["+String(e)+"] "+L.call(wr.call("[cause]: "+m(e.cause),$),", ")+" }":$.length===0?"["+String(e)+"]":"{ ["+String(e)+"] "+L.call($,", ")+" }"}if(typeof e=="object"&&u){if(Cr&&typeof e[Cr]=="function"&&nr)return nr(e,{depth:y-n});if(u!=="symbol"&&typeof e.inspect=="function")return e.inspect()}if(hn(e)){var f=[];return Ar&&Ar.call(e,function(N,G){f.push(m(G,e,!0)+" => "+m(N,e))}),Ir("Map",we.call(e),f,d)}if(En(e)){var M=[];return Pr&&Pr.call(e,function(N){M.push(m(N,e))}),Ir("Set",Re.call(e),M,d)}if(Sn(e))return je("WeakMap");if(An(e))return je("WeakSet");if(bn(e))return je("WeakRef");if(yn(e))return se(m(Number(e)));if(mn(e))return se(m(rr.call(e)));if(dn(e))return se(rn.call(e));if(pn(e))return se(m(String(e)));if(typeof window<"u"&&e===window)return"{ [object Window] }";if(typeof globalThis<"u"&&e===globalThis||typeof b.commonjsGlobal<"u"&&e===b.commonjsGlobal)return"{ [object globalThis] }";if(!sn(e)&&!xr(e)){var B=Ee(e,m),F=zr?zr(e)===Object.prototype:e instanceof Object||e.constructor===Object,q=e instanceof Object?"":"null prototype",W=!F&&ye&&Object(e)===e&&ye in e?dr.call(K(e),8,-1):q?"Object":"",Q=F||typeof e.constructor!="function"?"":e.constructor.name?e.constructor.name+" ":"",I=Q+(W||q?"["+L.call(wr.call([],W||[],q||[]),": ")+"] ":"");return B.length===0?I+"{}":d?I+"{"+ar(B,d)+"}":I+"{ "+L.call(B,", ")+" }"}return String(e)};function et(r,e,t){var n=t.quoteStyle||e,o=Zr[n];return o+r+o}function cn(r){return H.call(String(r),/"/g,"&quot;")}function Z(r){return!ye||!(typeof r=="object"&&(ye in r||typeof r[ye]<"u"))}function or(r){return K(r)==="[object Array]"&&Z(r)}function sn(r){return K(r)==="[object Date]"&&Z(r)}function xr(r){return K(r)==="[object RegExp]"&&Z(r)}function fn(r){return K(r)==="[object Error]"&&Z(r)}function pn(r){return K(r)==="[object String]"&&Z(r)}function yn(r){return K(r)==="[object Number]"&&Z(r)}function dn(r){return K(r)==="[object Boolean]"&&Z(r)}function rt(r){if(ie)return r&&typeof r=="object"&&r instanceof Symbol;if(typeof r=="symbol")return!0;if(!r||typeof r!="object"||!tr)return!1;try{return tr.call(r),!0}catch{}return!1}function mn(r){if(!r||typeof r!="object"||!rr)return!1;try{return rr.call(r),!0}catch{}return!1}var vn=Object.prototype.hasOwnProperty||function(r){return r in this};function U(r,e){return vn.call(r,e)}function K(r){return tn.call(r)}function gn(r){if(r.name)return r.name;var e=on.call(nn.call(r),/^function\s*([\w$]+)/);return e?e[1]:null}function tt(r,e){if(r.indexOf)return r.indexOf(e);for(var t=0,n=r.length;t<n;t++)if(r[t]===e)return t;return-1}function hn(r){if(!we||!r||typeof r!="object")return!1;try{we.call(r);try{Re.call(r)}catch{return!0}return r instanceof Map}catch{}return!1}function Sn(r){if(!fe||!r||typeof r!="object")return!1;try{fe.call(r,fe);try{pe.call(r,pe)}catch{return!0}return r instanceof WeakMap}catch{}return!1}function bn(r){if(!Or||!r||typeof r!="object")return!1;try{return Or.call(r),!0}catch{}return!1}function En(r){if(!Re||!r||typeof r!="object")return!1;try{Re.call(r);try{we.call(r)}catch{return!0}return r instanceof Set}catch{}return!1}function An(r){if(!pe||!r||typeof r!="object")return!1;try{pe.call(r,pe);try{fe.call(r,fe)}catch{return!0}return r instanceof WeakSet}catch{}return!1}function Pn(r){return!r||typeof r!="object"?!1:typeof HTMLElement<"u"&&r instanceof HTMLElement?!0:typeof r.nodeName=="string"&&typeof r.getAttribute=="function"}function nt(r,e){if(r.length>e.maxStringLength){var t=r.length-e.maxStringLength,n="... "+t+" more character"+(t>1?"s":"");return nt(dr.call(r,0,e.maxStringLength),e)+n}var o=un[e.quoteStyle||"single"];o.lastIndex=0;var i=H.call(H.call(r,o,"\\$1"),/[\x00-\x1f]/g,On);return et(i,"single",e)}function On(r){var e=r.charCodeAt(0),t={8:"b",9:"t",10:"n",12:"f",13:"r"}[e];return t?"\\"+t:"\\x"+(e<16?"0":"")+an.call(e.toString(16))}function se(r){return"Object("+r+")"}function je(r){return r+" { ? }"}function Ir(r,e,t,n){var o=n?ar(t,n):L.call(t,", ");return r+" ("+e+") {"+o+"}"}function $n(r){for(var e=0;e<r.length;e++)if(tt(r[e],`
2
+ `)>=0)return!1;return!0}function wn(r,e){var t;if(r.indent===" ")t=" ";else if(typeof r.indent=="number"&&r.indent>0)t=L.call(Array(r.indent+1)," ");else return null;return{base:t,prev:L.call(Array(e+1),t)}}function ar(r,e){if(r.length===0)return"";var t=`
3
+ `+e.prev+e.base;return t+L.call(r,","+t)+`
4
+ `+e.prev}function Ee(r,e){var t=or(r),n=[];if(t){n.length=r.length;for(var o=0;o<r.length;o++)n[o]=U(r,o)?e(r[o],r):""}var i=typeof Be=="function"?Be(r):[],u;if(ie){u={};for(var l=0;l<i.length;l++)u["$"+i[l]]=i[l]}for(var c in r)U(r,c)&&(t&&String(Number(c))===c&&c<r.length||ie&&u["$"+c]instanceof Symbol||(Jr.call(/[^\w$]/,c)?n.push(e(c,r)+": "+e(r[c],r)):n.push(c+": "+e(r[c],r))));if(typeof Be=="function")for(var s=0;s<i.length;s++)Xr.call(r,i[s])&&n.push("["+e(i[s])+"]: "+e(r[i[s]],r));return n}var Rn=Ce,zn=ce,xe=function(r,e,t){for(var n=r,o;(o=n.next)!=null;n=o)if(o.key===e)return n.next=o.next,t||(o.next=r.next,r.next=o),o},Tn=function(r,e){if(r){var t=xe(r,e);return t&&t.value}},_n=function(r,e,t){var n=xe(r,e);n?n.value=t:r.next={key:e,next:r.next,value:t}},Cn=function(r,e){return r?!!xe(r,e):!1},xn=function(r,e){if(r)return xe(r,e,!0)},In=function(){var e,t={assert:function(n){if(!t.has(n))throw new zn("Side channel does not contain "+Rn(n))},delete:function(n){var o=e&&e.next,i=xn(e,n);return i&&o&&o===i&&(e=void 0),!!i},get:function(n){return Tn(e,n)},has:function(n){return Cn(e,n)},set:function(n,o){e||(e={next:void 0}),_n(e,n,o)}};return t},ot=Object,Nn=Error,Mn=EvalError,Fn=RangeError,Dn=ReferenceError,Ln=SyntaxError,Bn=URIError,jn=Math.abs,Un=Math.floor,kn=Math.max,qn=Math.min,Wn=Math.pow,Gn=Math.round,Vn=Number.isNaN||function(e){return e!==e},Hn=Vn,Yn=function(e){return Hn(e)||e===0?e:e<0?-1:1},Kn=Object.getOwnPropertyDescriptor,Pe=Kn;if(Pe)try{Pe([],"length")}catch{Pe=null}var at=Pe,Oe=Object.defineProperty||!1;if(Oe)try{Oe({},"a",{value:1})}catch{Oe=!1}var Qn=Oe,Ue,Nr;function Jn(){return Nr||(Nr=1,Ue=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},t=Symbol("test"),n=Object(t);if(typeof t=="string"||Object.prototype.toString.call(t)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;e[t]=o;for(var i in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var u=Object.getOwnPropertySymbols(e);if(u.length!==1||u[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var l=Object.getOwnPropertyDescriptor(e,t);if(l.value!==o||l.enumerable!==!0)return!1}return!0}),Ue}var ke,Mr;function Xn(){if(Mr)return ke;Mr=1;var r=typeof Symbol<"u"&&Symbol,e=Jn();return ke=function(){return typeof r!="function"||typeof Symbol!="function"||typeof r("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:e()},ke}var qe,Fr;function it(){return Fr||(Fr=1,qe=typeof Reflect<"u"&&Reflect.getPrototypeOf||null),qe}var We,Dr;function lt(){if(Dr)return We;Dr=1;var r=ot;return We=r.getPrototypeOf||null,We}var Zn="Function.prototype.bind called on incompatible ",eo=Object.prototype.toString,ro=Math.max,to="[object Function]",Lr=function(e,t){for(var n=[],o=0;o<e.length;o+=1)n[o]=e[o];for(var i=0;i<t.length;i+=1)n[i+e.length]=t[i];return n},no=function(e,t){for(var n=[],o=t,i=0;o<e.length;o+=1,i+=1)n[i]=e[o];return n},oo=function(r,e){for(var t="",n=0;n<r.length;n+=1)t+=r[n],n+1<r.length&&(t+=e);return t},ao=function(e){var t=this;if(typeof t!="function"||eo.apply(t)!==to)throw new TypeError(Zn+t);for(var n=no(arguments,1),o,i=function(){if(this instanceof o){var y=t.apply(this,Lr(n,arguments));return Object(y)===y?y:this}return t.apply(e,Lr(n,arguments))},u=ro(0,t.length-n.length),l=[],c=0;c<u;c++)l[c]="$"+c;if(o=Function("binder","return function ("+oo(l,",")+"){ return binder.apply(this,arguments); }")(i),t.prototype){var s=function(){};s.prototype=t.prototype,o.prototype=new s,s.prototype=null}return o},io=ao,Ie=Function.prototype.bind||io,mr=Function.prototype.call,Ge,Br;function ut(){return Br||(Br=1,Ge=Function.prototype.apply),Ge}var lo=typeof Reflect<"u"&&Reflect&&Reflect.apply,uo=Ie,co=ut(),so=mr,fo=lo,po=fo||uo.call(so,co),yo=Ie,mo=ce,vo=mr,go=po,ct=function(e){if(e.length<1||typeof e[0]!="function")throw new mo("a function is required");return go(yo,vo,e)},Ve,jr;function ho(){if(jr)return Ve;jr=1;var r=ct,e=at,t;try{t=[].__proto__===Array.prototype}catch(u){if(!u||typeof u!="object"||!("code"in u)||u.code!=="ERR_PROTO_ACCESS")throw u}var n=!!t&&e&&e(Object.prototype,"__proto__"),o=Object,i=o.getPrototypeOf;return Ve=n&&typeof n.get=="function"?r([n.get]):typeof i=="function"?function(l){return i(l==null?l:o(l))}:!1,Ve}var He,Ur;function So(){if(Ur)return He;Ur=1;var r=it(),e=lt(),t=ho();return He=r?function(o){return r(o)}:e?function(o){if(!o||typeof o!="object"&&typeof o!="function")throw new TypeError("getProto: not an object");return e(o)}:t?function(o){return t(o)}:null,He}var Ye,kr;function bo(){if(kr)return Ye;kr=1;var r=Function.prototype.call,e=Object.prototype.hasOwnProperty,t=Ie;return Ye=t.call(r,e),Ye}var g,Eo=ot,Ao=Nn,Po=Mn,Oo=Fn,$o=Dn,le=Ln,oe=ce,wo=Bn,Ro=jn,zo=Un,To=kn,_o=qn,Co=Wn,xo=Gn,Io=Yn,st=Function,Ke=function(r){try{return st('"use strict"; return ('+r+").constructor;")()}catch{}},me=at,No=Qn,Qe=function(){throw new oe},Mo=me?function(){try{return arguments.callee,Qe}catch{try{return me(arguments,"callee").get}catch{return Qe}}}():Qe,re=Xn()(),T=So(),Fo=lt(),Do=it(),ft=ut(),ve=mr,ne={},Lo=typeof Uint8Array>"u"||!T?g:T(Uint8Array),X={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?g:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?g:ArrayBuffer,"%ArrayIteratorPrototype%":re&&T?T([][Symbol.iterator]()):g,"%AsyncFromSyncIteratorPrototype%":g,"%AsyncFunction%":ne,"%AsyncGenerator%":ne,"%AsyncGeneratorFunction%":ne,"%AsyncIteratorPrototype%":ne,"%Atomics%":typeof Atomics>"u"?g:Atomics,"%BigInt%":typeof BigInt>"u"?g:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?g:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?g:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?g:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Ao,"%eval%":eval,"%EvalError%":Po,"%Float16Array%":typeof Float16Array>"u"?g:Float16Array,"%Float32Array%":typeof Float32Array>"u"?g:Float32Array,"%Float64Array%":typeof Float64Array>"u"?g:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?g:FinalizationRegistry,"%Function%":st,"%GeneratorFunction%":ne,"%Int8Array%":typeof Int8Array>"u"?g:Int8Array,"%Int16Array%":typeof Int16Array>"u"?g:Int16Array,"%Int32Array%":typeof Int32Array>"u"?g:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":re&&T?T(T([][Symbol.iterator]())):g,"%JSON%":typeof JSON=="object"?JSON:g,"%Map%":typeof Map>"u"?g:Map,"%MapIteratorPrototype%":typeof Map>"u"||!re||!T?g:T(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Eo,"%Object.getOwnPropertyDescriptor%":me,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?g:Promise,"%Proxy%":typeof Proxy>"u"?g:Proxy,"%RangeError%":Oo,"%ReferenceError%":$o,"%Reflect%":typeof Reflect>"u"?g:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?g:Set,"%SetIteratorPrototype%":typeof Set>"u"||!re||!T?g:T(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?g:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":re&&T?T(""[Symbol.iterator]()):g,"%Symbol%":re?Symbol:g,"%SyntaxError%":le,"%ThrowTypeError%":Mo,"%TypedArray%":Lo,"%TypeError%":oe,"%Uint8Array%":typeof Uint8Array>"u"?g:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?g:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?g:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?g:Uint32Array,"%URIError%":wo,"%WeakMap%":typeof WeakMap>"u"?g:WeakMap,"%WeakRef%":typeof WeakRef>"u"?g:WeakRef,"%WeakSet%":typeof WeakSet>"u"?g:WeakSet,"%Function.prototype.call%":ve,"%Function.prototype.apply%":ft,"%Object.defineProperty%":No,"%Object.getPrototypeOf%":Fo,"%Math.abs%":Ro,"%Math.floor%":zo,"%Math.max%":To,"%Math.min%":_o,"%Math.pow%":Co,"%Math.round%":xo,"%Math.sign%":Io,"%Reflect.getPrototypeOf%":Do};if(T)try{null.error}catch(r){var Bo=T(T(r));X["%Error.prototype%"]=Bo}var jo=function r(e){var t;if(e==="%AsyncFunction%")t=Ke("async function () {}");else if(e==="%GeneratorFunction%")t=Ke("function* () {}");else if(e==="%AsyncGeneratorFunction%")t=Ke("async function* () {}");else if(e==="%AsyncGenerator%"){var n=r("%AsyncGeneratorFunction%");n&&(t=n.prototype)}else if(e==="%AsyncIteratorPrototype%"){var o=r("%AsyncGenerator%");o&&T&&(t=T(o.prototype))}return X[e]=t,t},qr={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},ge=Ie,ze=bo(),Uo=ge.call(ve,Array.prototype.concat),ko=ge.call(ft,Array.prototype.splice),Wr=ge.call(ve,String.prototype.replace),Te=ge.call(ve,String.prototype.slice),qo=ge.call(ve,RegExp.prototype.exec),Wo=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Go=/\\(\\)?/g,Vo=function(e){var t=Te(e,0,1),n=Te(e,-1);if(t==="%"&&n!=="%")throw new le("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&t!=="%")throw new le("invalid intrinsic syntax, expected opening `%`");var o=[];return Wr(e,Wo,function(i,u,l,c){o[o.length]=l?Wr(c,Go,"$1"):u||i}),o},Ho=function(e,t){var n=e,o;if(ze(qr,n)&&(o=qr[n],n="%"+o[0]+"%"),ze(X,n)){var i=X[n];if(i===ne&&(i=jo(n)),typeof i>"u"&&!t)throw new oe("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:o,name:n,value:i}}throw new le("intrinsic "+e+" does not exist!")},vr=function(e,t){if(typeof e!="string"||e.length===0)throw new oe("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof t!="boolean")throw new oe('"allowMissing" argument must be a boolean');if(qo(/^%?[^%]*%?$/,e)===null)throw new le("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=Vo(e),o=n.length>0?n[0]:"",i=Ho("%"+o+"%",t),u=i.name,l=i.value,c=!1,s=i.alias;s&&(o=s[0],ko(n,Uo([0,1],s)));for(var y=1,d=!0;y<n.length;y+=1){var m=n[y],h=Te(m,0,1),v=Te(m,-1);if((h==='"'||h==="'"||h==="`"||v==='"'||v==="'"||v==="`")&&h!==v)throw new le("property names with quotes must have matching quotes");if((m==="constructor"||!d)&&(c=!0),o+="."+m,u="%"+o+"%",ze(X,u))l=X[u];else if(l!=null){if(!(m in l)){if(!t)throw new oe("base intrinsic for "+e+" exists, but the property is not available.");return}if(me&&y+1>=n.length){var w=me(l,m);d=!!w,d&&"get"in w&&!("originalValue"in w.get)?l=w.get:l=l[m]}else d=ze(l,m),l=l[m];d&&!c&&(X[u]=l)}}return l},pt=vr,yt=ct,Yo=yt([pt("%String.prototype.indexOf%")]),dt=function(e,t){var n=pt(e,!!t);return typeof n=="function"&&Yo(e,".prototype.")>-1?yt([n]):n},Ko=vr,he=dt,Qo=Ce,Jo=ce,Gr=Ko("%Map%",!0),Xo=he("Map.prototype.get",!0),Zo=he("Map.prototype.set",!0),ea=he("Map.prototype.has",!0),ra=he("Map.prototype.delete",!0),ta=he("Map.prototype.size",!0),mt=!!Gr&&function(){var e,t={assert:function(n){if(!t.has(n))throw new Jo("Side channel does not contain "+Qo(n))},delete:function(n){if(e){var o=ra(e,n);return ta(e)===0&&(e=void 0),o}return!1},get:function(n){if(e)return Xo(e,n)},has:function(n){return e?ea(e,n):!1},set:function(n,o){e||(e=new Gr),Zo(e,n,o)}};return t},na=vr,Ne=dt,oa=Ce,Ae=mt,aa=ce,te=na("%WeakMap%",!0),ia=Ne("WeakMap.prototype.get",!0),la=Ne("WeakMap.prototype.set",!0),ua=Ne("WeakMap.prototype.has",!0),ca=Ne("WeakMap.prototype.delete",!0),sa=te?function(){var e,t,n={assert:function(o){if(!n.has(o))throw new aa("Side channel does not contain "+oa(o))},delete:function(o){if(te&&o&&(typeof o=="object"||typeof o=="function")){if(e)return ca(e,o)}else if(Ae&&t)return t.delete(o);return!1},get:function(o){return te&&o&&(typeof o=="object"||typeof o=="function")&&e?ia(e,o):t&&t.get(o)},has:function(o){return te&&o&&(typeof o=="object"||typeof o=="function")&&e?ua(e,o):!!t&&t.has(o)},set:function(o,i){te&&o&&(typeof o=="object"||typeof o=="function")?(e||(e=new te),la(e,o,i)):Ae&&(t||(t=Ae()),t.set(o,i))}};return n}:Ae,fa=ce,pa=Ce,ya=In,da=mt,ma=sa,va=ma||da||ya,ga=function(){var e,t={assert:function(n){if(!t.has(n))throw new fa("Side channel does not contain "+pa(n))},delete:function(n){return!!e&&e.delete(n)},get:function(n){return e&&e.get(n)},has:function(n){return!!e&&e.has(n)},set:function(n,o){e||(e=va()),e.set(n,o)}};return t},ha=String.prototype.replace,Sa=/%20/g,Je={RFC1738:"RFC1738",RFC3986:"RFC3986"},gr={default:Je.RFC3986,formatters:{RFC1738:function(r){return ha.call(r,Sa,"+")},RFC3986:function(r){return String(r)}},RFC1738:Je.RFC1738,RFC3986:Je.RFC3986},ba=gr,Xe=Object.prototype.hasOwnProperty,J=Array.isArray,D=function(){for(var r=[],e=0;e<256;++e)r.push("%"+((e<16?"0":"")+e.toString(16)).toUpperCase());return r}(),Ea=function(e){for(;e.length>1;){var t=e.pop(),n=t.obj[t.prop];if(J(n)){for(var o=[],i=0;i<n.length;++i)typeof n[i]<"u"&&o.push(n[i]);t.obj[t.prop]=o}}},vt=function(e,t){for(var n=t&&t.plainObjects?Object.create(null):{},o=0;o<e.length;++o)typeof e[o]<"u"&&(n[o]=e[o]);return n},Aa=function r(e,t,n){if(!t)return e;if(typeof t!="object"){if(J(e))e.push(t);else if(e&&typeof e=="object")(n&&(n.plainObjects||n.allowPrototypes)||!Xe.call(Object.prototype,t))&&(e[t]=!0);else return[e,t];return e}if(!e||typeof e!="object")return[e].concat(t);var o=e;return J(e)&&!J(t)&&(o=vt(e,n)),J(e)&&J(t)?(t.forEach(function(i,u){if(Xe.call(e,u)){var l=e[u];l&&typeof l=="object"&&i&&typeof i=="object"?e[u]=r(l,i,n):e.push(i)}else e[u]=i}),e):Object.keys(t).reduce(function(i,u){var l=t[u];return Xe.call(i,u)?i[u]=r(i[u],l,n):i[u]=l,i},o)},Pa=function(e,t){return Object.keys(t).reduce(function(n,o){return n[o]=t[o],n},e)},Oa=function(r,e,t){var n=r.replace(/\+/g," ");if(t==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch{return n}},$a=function(e,t,n,o,i){if(e.length===0)return e;var u=e;if(typeof e=="symbol"?u=Symbol.prototype.toString.call(e):typeof e!="string"&&(u=String(e)),n==="iso-8859-1")return escape(u).replace(/%u[0-9a-f]{4}/gi,function(y){return"%26%23"+parseInt(y.slice(2),16)+"%3B"});for(var l="",c=0;c<u.length;++c){var s=u.charCodeAt(c);if(s===45||s===46||s===95||s===126||s>=48&&s<=57||s>=65&&s<=90||s>=97&&s<=122||i===ba.RFC1738&&(s===40||s===41)){l+=u.charAt(c);continue}if(s<128){l=l+D[s];continue}if(s<2048){l=l+(D[192|s>>6]+D[128|s&63]);continue}if(s<55296||s>=57344){l=l+(D[224|s>>12]+D[128|s>>6&63]+D[128|s&63]);continue}c+=1,s=65536+((s&1023)<<10|u.charCodeAt(c)&1023),l+=D[240|s>>18]+D[128|s>>12&63]+D[128|s>>6&63]+D[128|s&63]}return l},wa=function(e){for(var t=[{obj:{o:e},prop:"o"}],n=[],o=0;o<t.length;++o)for(var i=t[o],u=i.obj[i.prop],l=Object.keys(u),c=0;c<l.length;++c){var s=l[c],y=u[s];typeof y=="object"&&y!==null&&n.indexOf(y)===-1&&(t.push({obj:u,prop:s}),n.push(y))}return Ea(t),e},Ra=function(e){return Object.prototype.toString.call(e)==="[object RegExp]"},za=function(e){return!e||typeof e!="object"?!1:!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},Ta=function(e,t){return[].concat(e,t)},_a=function(e,t){if(J(e)){for(var n=[],o=0;o<e.length;o+=1)n.push(t(e[o]));return n}return t(e)},gt={arrayToObject:vt,assign:Pa,combine:Ta,compact:wa,decode:Oa,encode:$a,isBuffer:za,isRegExp:Ra,maybeMap:_a,merge:Aa},ht=ga,$e=gt,de=gr,Ca=Object.prototype.hasOwnProperty,Vr={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},k=Array.isArray,xa=Array.prototype.push,St=function(r,e){xa.apply(r,k(e)?e:[e])},Ia=Date.prototype.toISOString,Hr=de.default,_={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:$e.encode,encodeValuesOnly:!1,format:Hr,formatter:de.formatters[Hr],indices:!1,serializeDate:function(e){return Ia.call(e)},skipNulls:!1,strictNullHandling:!1},Na=function(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"||typeof e=="symbol"||typeof e=="bigint"},Ze={},Ma=function r(e,t,n,o,i,u,l,c,s,y,d,m,h,v,w,C){for(var S=e,x=C,O=0,$=!1;(x=x.get(Ze))!==void 0&&!$;){var f=x.get(e);if(O+=1,typeof f<"u"){if(f===O)throw new RangeError("Cyclic object value");$=!0}typeof x.get(Ze)>"u"&&(O=0)}if(typeof c=="function"?S=c(t,S):S instanceof Date?S=d(S):n==="comma"&&k(S)&&(S=$e.maybeMap(S,function(V){return V instanceof Date?d(V):V})),S===null){if(i)return l&&!v?l(t,_.encoder,w,"key",m):t;S=""}if(Na(S)||$e.isBuffer(S)){if(l){var M=v?t:l(t,_.encoder,w,"key",m);return[h(M)+"="+h(l(S,_.encoder,w,"value",m))]}return[h(t)+"="+h(String(S))]}var B=[];if(typeof S>"u")return B;var F;if(n==="comma"&&k(S))v&&l&&(S=$e.maybeMap(S,l)),F=[{value:S.length>0?S.join(",")||null:void 0}];else if(k(c))F=c;else{var q=Object.keys(S);F=s?q.sort(s):q}for(var W=o&&k(S)&&S.length===1?t+"[]":t,Q=0;Q<F.length;++Q){var I=F[Q],N=typeof I=="object"&&typeof I.value<"u"?I.value:S[I];if(!(u&&N===null)){var G=k(S)?typeof n=="function"?n(W,I):W:W+(y?"."+I:"["+I+"]");C.set(e,O);var ee=ht();ee.set(Ze,C),St(B,r(N,G,n,o,i,u,n==="comma"&&v&&k(S)?null:l,c,s,y,d,m,h,v,w,ee))}}return B},Fa=function(e){if(!e)return _;if(e.encoder!==null&&typeof e.encoder<"u"&&typeof e.encoder!="function")throw new TypeError("Encoder has to be a function.");var t=e.charset||_.charset;if(typeof e.charset<"u"&&e.charset!=="utf-8"&&e.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=de.default;if(typeof e.format<"u"){if(!Ca.call(de.formatters,e.format))throw new TypeError("Unknown format option provided.");n=e.format}var o=de.formatters[n],i=_.filter;return(typeof e.filter=="function"||k(e.filter))&&(i=e.filter),{addQueryPrefix:typeof e.addQueryPrefix=="boolean"?e.addQueryPrefix:_.addQueryPrefix,allowDots:typeof e.allowDots>"u"?_.allowDots:!!e.allowDots,charset:t,charsetSentinel:typeof e.charsetSentinel=="boolean"?e.charsetSentinel:_.charsetSentinel,delimiter:typeof e.delimiter>"u"?_.delimiter:e.delimiter,encode:typeof e.encode=="boolean"?e.encode:_.encode,encoder:typeof e.encoder=="function"?e.encoder:_.encoder,encodeValuesOnly:typeof e.encodeValuesOnly=="boolean"?e.encodeValuesOnly:_.encodeValuesOnly,filter:i,format:n,formatter:o,serializeDate:typeof e.serializeDate=="function"?e.serializeDate:_.serializeDate,skipNulls:typeof e.skipNulls=="boolean"?e.skipNulls:_.skipNulls,sort:typeof e.sort=="function"?e.sort:null,strictNullHandling:typeof e.strictNullHandling=="boolean"?e.strictNullHandling:_.strictNullHandling}},Da=function(r,e){var t=r,n=Fa(e),o,i;typeof n.filter=="function"?(i=n.filter,t=i("",t)):k(n.filter)&&(i=n.filter,o=i);var u=[];if(typeof t!="object"||t===null)return"";var l;e&&e.arrayFormat in Vr?l=e.arrayFormat:e&&"indices"in e?l=e.indices?"indices":"repeat":l="indices";var c=Vr[l];if(e&&"commaRoundTrip"in e&&typeof e.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var s=c==="comma"&&e&&e.commaRoundTrip;o||(o=Object.keys(t)),n.sort&&o.sort(n.sort);for(var y=ht(),d=0;d<o.length;++d){var m=o[d];n.skipNulls&&t[m]===null||St(u,Ma(t[m],m,c,s,n.strictNullHandling,n.skipNulls,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,y))}var h=u.join(n.delimiter),v=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?v+="utf8=%26%2310003%3B&":v+="utf8=%E2%9C%93&"),h.length>0?v+h:""},ue=gt,ir=Object.prototype.hasOwnProperty,La=Array.isArray,R={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:ue.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},Ba=function(r){return r.replace(/&#(\d+);/g,function(e,t){return String.fromCharCode(parseInt(t,10))})},bt=function(r,e){return r&&typeof r=="string"&&e.comma&&r.indexOf(",")>-1?r.split(","):r},ja="utf8=%26%2310003%3B",Ua="utf8=%E2%9C%93",ka=function(e,t){var n={},o=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,i=t.parameterLimit===1/0?void 0:t.parameterLimit,u=o.split(t.delimiter,i),l=-1,c,s=t.charset;if(t.charsetSentinel)for(c=0;c<u.length;++c)u[c].indexOf("utf8=")===0&&(u[c]===Ua?s="utf-8":u[c]===ja&&(s="iso-8859-1"),l=c,c=u.length);for(c=0;c<u.length;++c)if(c!==l){var y=u[c],d=y.indexOf("]="),m=d===-1?y.indexOf("="):d+1,h,v;m===-1?(h=t.decoder(y,R.decoder,s,"key"),v=t.strictNullHandling?null:""):(h=t.decoder(y.slice(0,m),R.decoder,s,"key"),v=ue.maybeMap(bt(y.slice(m+1),t),function(w){return t.decoder(w,R.decoder,s,"value")})),v&&t.interpretNumericEntities&&s==="iso-8859-1"&&(v=Ba(v)),y.indexOf("[]=")>-1&&(v=La(v)?[v]:v),ir.call(n,h)?n[h]=ue.combine(n[h],v):n[h]=v}return n},qa=function(r,e,t,n){for(var o=n?e:bt(e,t),i=r.length-1;i>=0;--i){var u,l=r[i];if(l==="[]"&&t.parseArrays)u=[].concat(o);else{u=t.plainObjects?Object.create(null):{};var c=l.charAt(0)==="["&&l.charAt(l.length-1)==="]"?l.slice(1,-1):l,s=parseInt(c,10);!t.parseArrays&&c===""?u={0:o}:!isNaN(s)&&l!==c&&String(s)===c&&s>=0&&t.parseArrays&&s<=t.arrayLimit?(u=[],u[s]=o):c!=="__proto__"&&(u[c]=o)}o=u}return o},Wa=function(e,t,n,o){if(e){var i=n.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,u=/(\[[^[\]]*])/,l=/(\[[^[\]]*])/g,c=n.depth>0&&u.exec(i),s=c?i.slice(0,c.index):i,y=[];if(s){if(!n.plainObjects&&ir.call(Object.prototype,s)&&!n.allowPrototypes)return;y.push(s)}for(var d=0;n.depth>0&&(c=l.exec(i))!==null&&d<n.depth;){if(d+=1,!n.plainObjects&&ir.call(Object.prototype,c[1].slice(1,-1))&&!n.allowPrototypes)return;y.push(c[1])}return c&&y.push("["+i.slice(c.index)+"]"),qa(y,t,n,o)}},Ga=function(e){if(!e)return R;if(e.decoder!==null&&e.decoder!==void 0&&typeof e.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof e.charset<"u"&&e.charset!=="utf-8"&&e.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=typeof e.charset>"u"?R.charset:e.charset;return{allowDots:typeof e.allowDots>"u"?R.allowDots:!!e.allowDots,allowPrototypes:typeof e.allowPrototypes=="boolean"?e.allowPrototypes:R.allowPrototypes,allowSparse:typeof e.allowSparse=="boolean"?e.allowSparse:R.allowSparse,arrayLimit:typeof e.arrayLimit=="number"?e.arrayLimit:R.arrayLimit,charset:t,charsetSentinel:typeof e.charsetSentinel=="boolean"?e.charsetSentinel:R.charsetSentinel,comma:typeof e.comma=="boolean"?e.comma:R.comma,decoder:typeof e.decoder=="function"?e.decoder:R.decoder,delimiter:typeof e.delimiter=="string"||ue.isRegExp(e.delimiter)?e.delimiter:R.delimiter,depth:typeof e.depth=="number"||e.depth===!1?+e.depth:R.depth,ignoreQueryPrefix:e.ignoreQueryPrefix===!0,interpretNumericEntities:typeof e.interpretNumericEntities=="boolean"?e.interpretNumericEntities:R.interpretNumericEntities,parameterLimit:typeof e.parameterLimit=="number"?e.parameterLimit:R.parameterLimit,parseArrays:e.parseArrays!==!1,plainObjects:typeof e.plainObjects=="boolean"?e.plainObjects:R.plainObjects,strictNullHandling:typeof e.strictNullHandling=="boolean"?e.strictNullHandling:R.strictNullHandling}},Va=function(r,e){var t=Ga(e);if(r===""||r===null||typeof r>"u")return t.plainObjects?Object.create(null):{};for(var n=typeof r=="string"?ka(r,t):r,o=t.plainObjects?Object.create(null):{},i=Object.keys(n),u=0;u<i.length;++u){var l=i[u],c=Wa(l,n[l],t,typeof r=="string");o=ue.merge(o,c,t)}return t.allowSparse===!0?o:ue.compact(o)},Ha=Da,Ya=Va,Ka=gr,er={formats:Ka,parse:Ya,stringify:Ha};const Et={PENDING:"PENDING",APPROVED:"APPROVED",REJECTED:"REJECTED"},Qa={...Et,BLOCKED:"BLOCKED",OPEN:"OPEN",RESOLVED:"RESOLVED"};var At=(r=>(r.BAD_LANGUAGE="BAD_LANGUAGE",r.DISCRIMINATION="DISCRIMINATION",r.OTHER="OTHER",r))(At||{});const j={...Et,BLOCKED:"BLOCKED",OPEN:"OPEN",REMOVED:"REMOVED",TO_REVIEW:"TO_REVIEW",UNKNOWN:"UNKNOWN"},Ja=a.z.object({entryLabel:a.z.record(a.z.array(a.z.string())),approvalFlow:a.z.array(a.z.string()),blockedAuthorProps:a.z.array(a.z.string()),reportReasons:a.z.record(a.z.string()),regex:a.z.object({uid:a.z.string(),relatedUid:a.z.string(),email:a.z.string(),sorting:a.z.string()}),enabledCollections:a.z.array(a.z.string()),moderatorRoles:a.z.array(a.z.string()),isGQLPluginEnabled:a.z.boolean(),badWords:a.z.boolean().nullable().optional(),gql:a.z.object({auth:a.z.boolean().nullable()}).optional(),client:a.z.object({url:a.z.string().nullable(),contactEmail:a.z.string().nullable()}).default({url:null,contactEmail:null})}),Pt=a.z.intersection(a.z.object({id:a.z.number(),uid:a.z.string(),documentId:a.z.string(),createdAt:a.z.string(),updatedAt:a.z.string(),publishedAt:a.z.string().nullable(),locale:a.z.string().nullable().optional()}),a.z.record(a.z.unknown())),Xa=a.z.object({id:a.z.union([a.z.number(),a.z.string()]),name:a.z.string().optional().nullable(),email:a.z.string(),avatar:a.z.union([a.z.object({url:a.z.string()}),a.z.object({url:a.z.string(),formats:a.z.object({thumbnail:a.z.object({url:a.z.string()}).nullable()})}),a.z.string()]).nullable().optional()}),Ot=a.z.union([a.z.literal(j.PENDING),a.z.literal(j.APPROVED),a.z.literal(j.REJECTED),a.z.literal(j.BLOCKED),a.z.literal(j.OPEN),a.z.literal(j.REMOVED),a.z.literal(j.TO_REVIEW),a.z.literal(j.UNKNOWN)]),$t=a.z.union([a.z.literal("BAD_LANGUAGE"),a.z.literal("DISCRIMINATION"),a.z.literal("OTHER")]),Za=a.z.object({id:a.z.number(),reason:$t,content:a.z.string(),resolved:a.z.boolean(),createdAt:a.z.string(),updatedAt:a.z.string().nullable()}),_e=a.z.object({id:a.z.number(),content:a.z.string(),blocked:a.z.boolean().nullable(),blockedThread:a.z.boolean().nullable(),blockReason:a.z.string().nullable(),isAdminComment:a.z.boolean().nullable(),removed:a.z.boolean().nullable(),approvalStatus:Ot.nullable(),createdAt:a.z.string(),updatedAt:a.z.string(),reports:a.z.array(Za).nullable().optional(),author:Xa,gotThread:a.z.boolean().nullable().optional(),threadFirstItemId:a.z.number().nullable().optional()}),wt=a.z.object({page:a.z.number(),pageSize:a.z.number(),pageCount:a.z.number(),total:a.z.number()});function lr(){return _e.extend({related:Pt.optional(),documentId:a.z.string(),threadOf:a.z.lazy(()=>_e.merge(a.z.object({related:a.z.string(),threadOf:Rt.nullable().optional(),documentId:a.z.string().optional()}))).nullable().optional()})}const Rt=lr(),ei=a.z.object({pagination:wt,result:a.z.array(Rt)}),ri=a.z.object({entity:Pt,selected:_e.merge(a.z.object({related:a.z.string(),threadOf:lr().omit({related:!0}).merge(a.z.object({related:a.z.string()})).nullable().optional()})).nullable(),level:a.z.array(lr().omit({threadOf:!0,related:!0}))}),zt=a.z.object({apiID:a.z.string(),uid:a.z.string(),schema:a.z.object({attributes:a.z.record(a.z.object({type:a.z.union([a.z.literal("string"),a.z.string()])})),collectionName:a.z.string(),description:a.z.string(),displayName:a.z.string(),draftAndPublish:a.z.boolean(),kind:a.z.string(),pluralName:a.z.string(),singularName:a.z.string(),visible:a.z.boolean()})}),ti=a.z.object({data:zt}),ni=a.z.object({data:a.z.array(zt)}),oi=a.z.object({author:a.z.unknown(),content:a.z.string(),id:a.z.number(),approvalStatus:Ot.nullable().optional(),reason:$t,reports:a.z.array(a.z.unknown()),resolved:a.z.boolean().optional(),updatedAt:a.z.string().nullable(),createdAt:a.z.string(),related:_e}),ai=a.z.object({pagination:wt,result:a.z.array(oi)}),ii=a.z.object({id:a.z.number(),documentId:a.z.string(),name:a.z.string(),code:a.z.string(),description:a.z.string(),createdAt:a.z.string(),updatedAt:a.z.string(),publishedAt:a.z.string(),locale:a.z.string().nullable(),usersCount:a.z.number()}),li=a.z.object({data:a.z.array(ii)}),ui=a.z.object({data:a.z.object({id:a.z.number(),documentId:a.z.string(),firstname:a.z.string(),lastname:a.z.string(),username:a.z.string().nullable(),email:a.z.string(),isActive:a.z.boolean(),blocked:a.z.boolean(),preferedLanguage:a.z.string().nullable(),createdAt:a.z.string(),updatedAt:a.z.string(),publishedAt:a.z.string(),locale:a.z.null(),roles:a.z.array(a.z.object({id:a.z.number(),name:a.z.string(),description:a.z.string(),code:a.z.string()}))})}),P="comments",ci=b.lodashExports.once(r=>({config:{getKey(){return[P,"config"]},async query(){const e=await r.get(`/${P}/settings/config`);return Ja.parseAsync(e.data)}},contentTypeBuilder:{single:{getKey(e,t){return[P,"moderate","content-type",t,e]},async query(e){const t=await r.get(`/content-type-builder/content-types/${e}`);return ti.parseAsync(t.data).then(n=>n.data)}},all:{getKey(){return[P,"moderate","content-types"]},async query(){const e=await r.get("/content-type-builder/content-types");return ni.parseAsync(e.data).then(t=>t.data)}}},roles:{getKey(){return[P,"moderate","roles"]},async query(){const e=await r.get("/admin/roles");return li.parseAsync(e.data).then(t=>t.data)}},user:{getKey(){return[P,"moderate","user"]},async query(){const e=await r.get("/admin/users/me");return ui.parseAsync(e.data).then(t=>t.data)}},comments:{findAll:{getKey(e){return[P,"moderate","all",e?JSON.stringify(e):void 0].filter(Boolean)},async query(e){const t=await r.get(`/${P}/moderate/all?${er.stringify(e,{encode:!1})}`);return ei.parseAsync(t.data)}},findOne:{getKey(e,t){return[P,"details",e?.toString(),t?JSON.stringify(t):void 0].filter(Boolean)},async query(e,t){const n=b.lodashExports.isEmpty(t)?"":`?${er.stringify(t,{encode:!1})}`,o=await r.get(`/${P}/moderate/single/${e}${n}`);return ri.parseAsync(o.data)}},approve(e){return r.put(`/${P}/moderate/single/${e}/approve`)},reject(e){return r.put(`/${P}/moderate/single/${e}/reject`)},block(e){return r.put(`/${P}/moderate/single/${e}/block`)},unblock(e){return r.put(`/${P}/moderate/single/${e}/unblock`)},blockThread(e){return r.put(`/${P}/moderate/thread/${e}/block`)},unBlockThread(e){return r.put(`/${P}/moderate/thread/${e}/unblock`)},delete(e){return r.del(`/${P}/moderate/single/${e}/delete`)},postComment({id:e,content:t,author:n}){return r.post(`/${P}/moderate/thread/${e}/postComment`,{content:t,author:n})},updateComment({id:e,content:t}){return r.put(`/${P}/moderate/single/${e}/update`,{content:t})}},reports:{findAll:{getKey(e){return[P,"moderate","reports",e?JSON.stringify(e):void 0].filter(Boolean)},async query(e){const t=await r.get(`/${P}/moderate/reports${e?`?${er.stringify(e,{encode:!1})}`:""}`);return ai.parseAsync(t.data)}},resolve({id:e,reportId:t}){return r.put(`/${P}/moderate/single/${e}/report/${t}/resolve`)},resolveMultipleReports({reportIds:e}){return r.put(`/${P}/moderate/multiple/report/resolve`,{reportIds:e})},resolveCommentMultipleReports({id:e,reportIds:t}){return r.put(`/${P}/moderate/single/${e}/report/resolve`,{reportIds:t})},resolveAllAbuseReportsForComment(e){return r.put(`/${P}/moderate/all/${e}/report/resolve`)},resolveAllAbuseReportsForThread(e){return r.put(`/${P}/moderate/thread/${e}/report/resolve-thread`)}},settings:{update(e){return r.put(`/${P}/settings/config`,e)},restore(){return r.del(`/${P}/settings/config`)},restart(){return r.post(`/${P}/settings/restart`)}}})),Tt=()=>{const r=Qr.getFetchClient();return Y.useMemo(()=>ci(r),[r])},_t=Y.createContext(null),si=({children:r})=>{const e=Tt(),{data:t}=fr.useQuery({queryKey:e.user.getKey(),queryFn:e.user.query});return t?z.jsx(_t.Provider,{value:t,children:r}):null},fi=new fr.QueryClient({defaultOptions:{queries:{retry:!1,refetchOnWindowFocus:!1}}}),pi=({children:r})=>{const e=Yt();return z.jsx(fr.QueryClientProvider,{client:fi,children:z.jsx(b.DesignSystemProvider,{theme:{theme:e},children:z.jsx(si,{children:r})})})},yi=()=>{const r=Y.useMemo(()=>({access:b.pluginPermissions.access,moderate:b.pluginPermissions.moderate,accessReports:b.pluginPermissions.reports,reviewReports:b.pluginPermissions.reportsReview,settings:b.pluginPermissions.settings,settingsChange:b.pluginPermissions.settingsChange}),[]),{isLoading:e,allowedActions:{canCommentsModerate:t,canCommentsRead:n,canReportsRead:o,canSettingsChange:i,canSettingsRead:u,canReportsReview:l}}=Qr.useRBAC(r);return{isLoadingForPermissions:e,canAccess:n||o||u,canModerate:t,canAccessReports:o,canReviewReports:l,canSettings:u,canSettingsChange:i}};var ur={exports:{}},E={};/** @license React v16.13.1
5
+ * react-is.production.min.js
6
+ *
7
+ * Copyright (c) Facebook, Inc. and its affiliates.
8
+ *
9
+ * This source code is licensed under the MIT license found in the
10
+ * LICENSE file in the root directory of this source tree.
11
+ */var Yr;function di(){if(Yr)return E;Yr=1;var r=typeof Symbol=="function"&&Symbol.for,e=r?Symbol.for("react.element"):60103,t=r?Symbol.for("react.portal"):60106,n=r?Symbol.for("react.fragment"):60107,o=r?Symbol.for("react.strict_mode"):60108,i=r?Symbol.for("react.profiler"):60114,u=r?Symbol.for("react.provider"):60109,l=r?Symbol.for("react.context"):60110,c=r?Symbol.for("react.async_mode"):60111,s=r?Symbol.for("react.concurrent_mode"):60111,y=r?Symbol.for("react.forward_ref"):60112,d=r?Symbol.for("react.suspense"):60113,m=r?Symbol.for("react.suspense_list"):60120,h=r?Symbol.for("react.memo"):60115,v=r?Symbol.for("react.lazy"):60116,w=r?Symbol.for("react.block"):60121,C=r?Symbol.for("react.fundamental"):60117,S=r?Symbol.for("react.responder"):60118,x=r?Symbol.for("react.scope"):60119;function O(f){if(typeof f=="object"&&f!==null){var M=f.$$typeof;switch(M){case e:switch(f=f.type,f){case c:case s:case n:case i:case o:case d:return f;default:switch(f=f&&f.$$typeof,f){case l:case y:case v:case h:case u:return f;default:return M}}case t:return M}}}function $(f){return O(f)===s}return E.AsyncMode=c,E.ConcurrentMode=s,E.ContextConsumer=l,E.ContextProvider=u,E.Element=e,E.ForwardRef=y,E.Fragment=n,E.Lazy=v,E.Memo=h,E.Portal=t,E.Profiler=i,E.StrictMode=o,E.Suspense=d,E.isAsyncMode=function(f){return $(f)||O(f)===c},E.isConcurrentMode=$,E.isContextConsumer=function(f){return O(f)===l},E.isContextProvider=function(f){return O(f)===u},E.isElement=function(f){return typeof f=="object"&&f!==null&&f.$$typeof===e},E.isForwardRef=function(f){return O(f)===y},E.isFragment=function(f){return O(f)===n},E.isLazy=function(f){return O(f)===v},E.isMemo=function(f){return O(f)===h},E.isPortal=function(f){return O(f)===t},E.isProfiler=function(f){return O(f)===i},E.isStrictMode=function(f){return O(f)===o},E.isSuspense=function(f){return O(f)===d},E.isValidElementType=function(f){return typeof f=="string"||typeof f=="function"||f===n||f===s||f===i||f===o||f===d||f===m||typeof f=="object"&&f!==null&&(f.$$typeof===v||f.$$typeof===h||f.$$typeof===u||f.$$typeof===l||f.$$typeof===y||f.$$typeof===C||f.$$typeof===S||f.$$typeof===x||f.$$typeof===w)},E.typeOf=O,E}var A={};/** @license React v16.13.1
12
+ * react-is.development.js
13
+ *
14
+ * Copyright (c) Facebook, Inc. and its affiliates.
15
+ *
16
+ * This source code is licensed under the MIT license found in the
17
+ * LICENSE file in the root directory of this source tree.
18
+ */var Kr;function mi(){return Kr||(Kr=1,process.env.NODE_ENV!=="production"&&function(){var r=typeof Symbol=="function"&&Symbol.for,e=r?Symbol.for("react.element"):60103,t=r?Symbol.for("react.portal"):60106,n=r?Symbol.for("react.fragment"):60107,o=r?Symbol.for("react.strict_mode"):60108,i=r?Symbol.for("react.profiler"):60114,u=r?Symbol.for("react.provider"):60109,l=r?Symbol.for("react.context"):60110,c=r?Symbol.for("react.async_mode"):60111,s=r?Symbol.for("react.concurrent_mode"):60111,y=r?Symbol.for("react.forward_ref"):60112,d=r?Symbol.for("react.suspense"):60113,m=r?Symbol.for("react.suspense_list"):60120,h=r?Symbol.for("react.memo"):60115,v=r?Symbol.for("react.lazy"):60116,w=r?Symbol.for("react.block"):60121,C=r?Symbol.for("react.fundamental"):60117,S=r?Symbol.for("react.responder"):60118,x=r?Symbol.for("react.scope"):60119;function O(p){return typeof p=="string"||typeof p=="function"||p===n||p===s||p===i||p===o||p===d||p===m||typeof p=="object"&&p!==null&&(p.$$typeof===v||p.$$typeof===h||p.$$typeof===u||p.$$typeof===l||p.$$typeof===y||p.$$typeof===C||p.$$typeof===S||p.$$typeof===x||p.$$typeof===w)}function $(p){if(typeof p=="object"&&p!==null){var Fe=p.$$typeof;switch(Fe){case e:var be=p.type;switch(be){case c:case s:case n:case i:case o:case d:return be;default:var Er=be&&be.$$typeof;switch(Er){case l:case y:case v:case h:case u:return Er;default:return Fe}}case t:return Fe}}}var f=c,M=s,B=l,F=u,q=e,W=y,Q=n,I=v,N=h,G=t,ee=i,V=o,Nt=d,Sr=!1;function Mt(p){return Sr||(Sr=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),br(p)||$(p)===c}function br(p){return $(p)===s}function Ft(p){return $(p)===l}function Dt(p){return $(p)===u}function Lt(p){return typeof p=="object"&&p!==null&&p.$$typeof===e}function Bt(p){return $(p)===y}function jt(p){return $(p)===n}function Ut(p){return $(p)===v}function kt(p){return $(p)===h}function qt(p){return $(p)===t}function Wt(p){return $(p)===i}function Gt(p){return $(p)===o}function Vt(p){return $(p)===d}A.AsyncMode=f,A.ConcurrentMode=M,A.ContextConsumer=B,A.ContextProvider=F,A.Element=q,A.ForwardRef=W,A.Fragment=Q,A.Lazy=I,A.Memo=N,A.Portal=G,A.Profiler=ee,A.StrictMode=V,A.Suspense=Nt,A.isAsyncMode=Mt,A.isConcurrentMode=br,A.isContextConsumer=Ft,A.isContextProvider=Dt,A.isElement=Lt,A.isForwardRef=Bt,A.isFragment=jt,A.isLazy=Ut,A.isMemo=kt,A.isPortal=qt,A.isProfiler=Wt,A.isStrictMode=Gt,A.isSuspense=Vt,A.isValidElementType=O,A.typeOf=$}()),A}process.env.NODE_ENV==="production"?ur.exports=di():ur.exports=mi();var vi=ur.exports,Ct=vi,gi={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},hi={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},xt={};xt[Ct.ForwardRef]=gi;xt[Ct.Memo]=hi;function Si(r,e,t){if(t===void 0&&(t=Error),!r)throw new t(e)}var bi=function(r){process.env.NODE_ENV!=="production"&&console.error(r)},Ei=function(r){process.env.NODE_ENV!=="production"&&console.warn(r)},Ai={formats:{},messages:{},timeZone:void 0,defaultLocale:"en",defaultFormats:{},fallbackOnEmptyString:!0,onError:bi,onWarn:Ei};function Pi(r){Si(r,"[React Intl] Could not find required `intl` object. <IntlProvider> needs to exist in the component ancestry.")}b.__assign(b.__assign({},Ai),{textComponent:ae.Fragment});var hr=typeof window<"u"&&!window.__REACT_INTL_BYPASS_GLOBAL_CONTEXT__?window.__REACT_INTL_CONTEXT__||(window.__REACT_INTL_CONTEXT__=ae.createContext(null)):ae.createContext(null);hr.Consumer;hr.Provider;var Oi=hr;function Me(){var r=ae.useContext(Oi);return Pi(r),r}var cr;(function(r){r.formatDate="FormattedDate",r.formatTime="FormattedTime",r.formatNumber="FormattedNumber",r.formatList="FormattedList",r.formatDisplayName="FormattedDisplayName"})(cr||(cr={}));var sr;(function(r){r.formatDate="FormattedDateParts",r.formatTime="FormattedTimeParts",r.formatNumber="FormattedNumberParts",r.formatList="FormattedListParts"})(sr||(sr={}));function It(r){var e=function(t){var n=Me(),o=t.value,i=t.children,u=b.__rest(t,["value","children"]),l=typeof o=="string"?new Date(o||0):o,c=r==="formatDate"?n.formatDateToParts(l,u):n.formatTimeToParts(l,u);return i(c)};return e.displayName=sr[r],e}function Se(r){var e=function(t){var n=Me(),o=t.value,i=t.children,u=b.__rest(t,["value","children"]),l=n[r](o,u);if(typeof i=="function")return i(l);var c=n.textComponent||ae.Fragment;return ae.createElement(c,null,l)};return e.displayName=cr[r],e}Se("formatDate");Se("formatTime");Se("formatNumber");Se("formatList");Se("formatDisplayName");It("formatDate");It("formatTime");const $i=(r,e="",t=!0)=>{const{formatMessage:n}=Me();let o="";return typeof r=="string"?o=r:o=r?.id.toString()||o,n({id:`${t?b.pluginId:"app.components"}.${o}`,defaultMessage:e},typeof r=="string"?void 0:r?.props)},wi=({title:r,onConfirm:e,Trigger:t,labelConfirm:n,iconConfirm:o,labelCancel:i,children:u})=>{const[l,c]=Y.useState(!1),[s,y]=Y.useState(!1),d=()=>c(h=>!h),m=async()=>{y(!0),await e(),y(!1),d()};return z.jsxs(b.Dialog.Root,{open:l,children:[z.jsx(b.Dialog.Trigger,{children:z.jsx(t,{onClick:d})}),z.jsxs(b.Dialog.Content,{children:[z.jsx(b.Dialog.Header,{children:r}),z.jsx(b.Dialog.Body,{children:z.jsxs(b.Flex,{justifyContent:"center",direction:"column",children:[z.jsx(b.ForwardRef$3,{fill:"danger500",stroke:"danger500",height:"24",width:"24"}),z.jsx(b.Typography,{id:"confirm-description",children:u})]})}),z.jsxs(b.Dialog.Footer,{children:[z.jsx(b.Dialog.Cancel,{children:z.jsx(b.Button,{onClick:d,disabled:s,variant:"tertiary",children:i||"Cancel"})}),z.jsx(b.Dialog.Action,{children:z.jsx(b.Button,{onClick:m,variant:"danger-light",loading:s,disabled:s,startIcon:o,children:n})})]})]})]})};exports.COMMENT_STATUS=j;exports.CommonProviders=pi;exports.ConfirmationDialog=wi;exports.REPORT_REASON=At;exports.REPORT_STATUS=Qa;exports.UserContext=_t;exports.getMessage=$i;exports.useAPI=Tt;exports.useIntl=Me;exports.usePermissions=yi;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("./index-DYUGPksR.js"),h=require("@strapi/strapi/admin"),c=require("@tanstack/react-query"),m=require("react"),D=require("styled-components"),s=require("./index-hoQGufqY.js"),N=r=>r&&r.__esModule?r:{default:r},W=N(D),S=({children:r,condition:a})=>a?e.jsx(e.Fragment,{children:r}):null,_=(r={})=>{const a=s.useAPI(),x=c.useMutation({mutationFn:a.settings.update,onSuccess:r.updateSettingsMutationSuccess,onError:r.updateSettingsMutationError}),j=c.useMutation({mutationFn:a.settings.restore,onSuccess:r.restoreSettingsMutationSuccess,onError:r.restoreSettingsMutationError}),g=c.useMutation({mutationFn:a.settings.restart,onSuccess:r.restartStrapiMutationSuccess,onError:r.restartStrapiMutationError}),b=c.useQuery({queryKey:a.config.getKey(),queryFn:a.config.query}),u=c.useQuery({queryKey:a.contentTypeBuilder.all.getKey(),queryFn:a.contentTypeBuilder.all.query}),p=c.useQuery({queryKey:a.roles.getKey(),queryFn:a.roles.query});return m.useMemo(()=>({config:b,collectionTypes:u,roles:p,restoreSettingsMutation:j,updateSettingsMutation:x,restartStrapiMutation:g}),[b,p,u,j,x,g])},y={background:"neutral0",hasRadius:!0,shadow:"filterShadow",padding:6,width:"100%"},U=W.default(t.Alert)(()=>({"[role]":{flexDirection:"column"}})),V=()=>{const{trackUsage:r}=h.useTracking(),a=m.useRef(null),{toggleNotification:x}=h.useNotification(),[j,g]=m.useState(!1),{isLoadingForPermissions:b,canSettingsChange:u}=s.usePermissions(),p=c.useQueryClient(),w=s.useAPI(),{config:l,collectionTypes:R,roles:M,restoreSettingsMutation:T,updateSettingsMutation:I,restartStrapiMutation:A}=_({restoreSettingsMutationSuccess:()=>{p.invalidateQueries({queryKey:w.config.getKey(),exact:!1}),g(!0),x({message:s.getMessage("page.settings.actions.restore.success"),type:"success"})},restartStrapiMutationSuccess:()=>{g(!1)},updateSettingsMutationSuccess:()=>{p.invalidateQueries({queryKey:w.config.getKey(),exact:!1}),g(!0)}}),P=m.useCallback(()=>{a.current?.requestSubmit()},[]),G=m.useCallback(n=>{I.mutate({...n,blockedAuthorProps:n.blockedAuthorProps.split(",").map(o=>o.trim())})},[I]);if(l.status!=="success"||R.status!=="success"||M.status!=="success"||b)return s.getMessage("page.settings.loading");const F=R.data.filter(n=>n.uid.includes("api::")),v=l.data.enabledCollections.filter(n=>F.some(o=>o.uid===n)),k=t.lodashExports.isNil(l.data.badWords)?!0:l.data?.badWords,B=!!l.data.gql?.auth,E=l.data.moderatorRoles.filter(n=>M.data.filter(o=>o.code===n)),H=l.data.client?.url,K=l.data.client?.contactEmail,Q=l.data.blockedAuthorProps??[],O=()=>g(!1);return e.jsxs(e.Fragment,{children:[e.jsx(h.Page.Title,{children:"Comments - settings"}),e.jsxs(h.Page.Main,{children:[e.jsx(h.Layouts.Header,{title:s.getMessage("page.settings.header.title"),subtitle:s.getMessage("page.settings.header.description"),as:"h2",primaryAction:e.jsx(S,{condition:u,children:e.jsx(t.Button,{type:"submit",startIcon:e.jsx(t.ForwardRef$4F,{}),onClick:P,children:s.getMessage("page.settings.actions.submit")})})}),e.jsxs(h.Layouts.Content,{children:[j&&e.jsx(t.Box,{marginBottom:4,children:e.jsx(U,{closeLabel:s.getMessage("page.settings.actions.restart.alert.cancel"),title:s.getMessage("page.settings.actions.restart.alert.title"),onClose:O,action:e.jsx(t.Box,{children:e.jsx(t.Button,{onClick:A.mutate,startIcon:e.jsx(t.ForwardRef$1j,{}),children:s.getMessage("page.settings.actions.restart")})}),children:e.jsx(t.Box,{marginTop:4,children:s.getMessage("page.settings.actions.restart.alert.description")})})}),e.jsx(h.Form,{method:"POST",width:"auto",height:"auto",ref:a,onSubmit:G,initialValues:{enabledCollections:v,moderatorRoles:E,badWords:k,clientEmail:K,clientUrl:H,gqlAuthEnabled:B,approvalFlow:l.data.approvalFlow,entryLabel:l.data.entryLabel,blockedAuthorProps:Q.join(", ")},children:({values:n,onChange:o})=>e.jsxs(t.Flex,{gap:4,direction:"column",children:[e.jsxs(t.Box,{...y,children:[e.jsx(t.Typography,{variant:"delta",as:"h2",children:s.getMessage("page.settings.section.general")}),e.jsxs(t.Grid.Root,{gap:4,marginTop:4,width:"100%",children:[e.jsx(t.Grid.Item,{xs:12,children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.enabledCollections.hint"),children:[e.jsx(t.Field.Label,{htmlFor:"enabledCollections",children:s.getMessage("page.settings.form.enabledCollections.label")}),e.jsx(t.MultiSelect,{withTags:!0,name:"enabledCollections",value:n.enabledCollections,onChange:i=>{o("enabledCollections",i)},children:F.map(i=>e.jsx(t.MultiSelectOption,{value:i.uid,children:i.schema.displayName},i.uid))}),e.jsx(t.Field.Hint,{})]})}),n.enabledCollections.length>0&&e.jsx(t.Grid.Item,{children:e.jsxs(t.Grid.Root,{gap:4,width:"100%",children:[e.jsx(t.Grid.Item,{children:e.jsx(t.Typography,{children:s.getMessage("page.settings.form.contentTypesSettings.label")})}),e.jsx(t.Grid.Item,{children:e.jsx(t.Accordion.Root,{style:{width:"100%"},children:t.lodashExports.orderBy(n.enabledCollections).map(i=>{const C=F.find(f=>f.uid===i);if(C){const{schema:{displayName:f,attributes:q}}=C,L=Object.keys(q).filter(d=>q[d].type==="string");return e.jsxs(t.Accordion.Item,{value:i,children:[e.jsx(t.Accordion.Header,{children:e.jsx(t.Accordion.Trigger,{children:e.jsx(t.Typography,{variant:"epsilon",as:"h3",children:f})})}),e.jsx(t.Accordion.Content,{children:e.jsxs(t.Grid.Root,{padding:6,gap:4,children:[e.jsx(t.Grid.Item,{children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage({id:"page.settings.form.approvalFlow.hint",props:{name:f}}),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.approvalFlow.label")}),e.jsx(t.SwitchImpl,{visibleLabels:!0,onLabel:s.getMessage("components.toogle.enabled"),offLabel:s.getMessage("components.toogle.disabled"),checked:n.approvalFlow.includes(i),onCheckedChange:d=>{o("approvalFlow",d?[...n.approvalFlow,i]:n.approvalFlow.filter($=>$!==i))}}),e.jsx(t.Field.Hint,{})]})}),e.jsx(S,{condition:L.length>0,children:e.jsx(t.Grid.Item,{children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.entryLabel.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.entryLabel.label")}),e.jsx(t.MultiSelect,{withTags:!0,placeholder:s.getMessage("page.settings.form.entryLabel.placeholder"),name:"enabledCollections",value:n.entryLabel[i]??[],onChange:d=>{o("entryLabel",{...n.entryLabel,[i]:d})},children:L.map(d=>e.jsx(t.MultiSelectOption,{value:d,children:d},d))}),e.jsx(t.Field.Hint,{})]})})})]})})]},i)}return null})})})]})})]})]}),e.jsxs(t.Box,{...y,children:[e.jsx(t.Typography,{variant:"delta",as:"h2",children:s.getMessage("page.settings.section.additional")}),e.jsxs(t.Grid.Root,{gap:4,marginTop:4,width:"100%",children:[e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.enabledCollections.hint"),children:[e.jsx(t.Field.Label,{htmlFor:"enabledCollections",children:s.getMessage("page.settings.form.enabledCollections.label")}),e.jsx(t.Toggle,{name:"badWords",checked:n.badWords,onChange:o,onLabel:s.getMessage("components.toogle.enabled"),offLabel:s.getMessage("components.toogle.disabled"),width:"100%"}),e.jsx(t.Field.Hint,{})]})}),e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.author.blockedProps.hint"),children:[e.jsx(t.Field.Label,{htmlFor:"enabledCollections",children:s.getMessage("page.settings.form.author.blockedProps.label")}),e.jsx(t.Field.Input,{name:"blockedProps",onChange:o}),e.jsx(t.Field.Hint,{})]})}),e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.gqlAuth.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.gqlAuth.label")}),e.jsx(t.Toggle,{name:"gqlAuthEnabled",checked:n.gqlAuthEnabled,onChange:o,onLabel:s.getMessage("components.toogle.enabled"),offLabel:s.getMessage("components.toogle.disabled"),width:"100%"}),e.jsx(t.Field.Hint,{})]})})]})]}),e.jsxs(t.Box,{...y,children:[e.jsx(t.Typography,{variant:"delta",as:"h2",children:s.getMessage("page.settings.section.client")}),e.jsxs(t.Grid.Root,{gap:4,marginTop:4,width:"100%",children:[e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.client.url.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.client.url.label")}),e.jsx(t.Field.Input,{name:"clientUrl",onChange:o}),e.jsx(t.Field.Hint,{})]})}),e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.client.email.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.client.email.label")}),e.jsx(t.Field.Input,{name:"clientEmail",onChange:o}),e.jsx(t.Field.Hint,{})]})}),e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.moderatorRoles.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.moderatorRoles.label")}),e.jsx(t.MultiSelect,{withTags:!0,placeholder:s.getMessage("page.settings.form.moderatorRoles.placeholder"),name:"enabledCollections",value:n.moderatorRoles,onChange:i=>{o("moderatorRoles",i)},children:M.data.map(i=>e.jsx(t.MultiSelectOption,{value:i.code,children:i.name},i.code))}),e.jsx(t.Field.Hint,{})]})})]})]}),e.jsx(S,{condition:u,children:e.jsx(t.Box,{...y,children:e.jsxs(t.Flex,{gap:4,direction:"column",alignItems:"flex-start",children:[e.jsxs(t.Flex,{gap:2,direction:"column",alignItems:"flex-start",children:[e.jsx(t.Typography,{variant:"delta",as:"h2",children:s.getMessage("page.settings.section.restore")}),e.jsx(t.Typography,{variant:"pi",as:"h4",children:s.getMessage("page.settings.section.restore.subtitle")})]}),e.jsx(s.ConfirmationDialog,{Trigger:({onClick:i})=>e.jsx(t.Button,{variant:"danger-light",startIcon:e.jsx(t.ForwardRef$5n,{}),onClick:i,children:s.getMessage("page.settings.actions.restore")}),onConfirm:T.mutate,title:s.getMessage("page.settings.actions.restore.confirmation.header"),labelConfirm:s.getMessage("page.settings.actions.restore.confirmation.button.confirm"),iconConfirm:e.jsx(t.ForwardRef$5n,{}),children:s.getMessage("page.settings.actions.restore.confirmation.description")})]})})})]})})]})]})]})};new c.QueryClient;const z=()=>e.jsx(s.CommonProviders,{children:e.jsx(V,{})});exports.default=z;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("./index-C1LkPp9p.js"),h=require("@strapi/strapi/admin"),c=require("@tanstack/react-query"),m=require("react"),D=require("styled-components"),s=require("./index-CiNGZPZv.js"),N=r=>r&&r.__esModule?r:{default:r},W=N(D),S=({children:r,condition:a})=>a?e.jsx(e.Fragment,{children:r}):null,_=(r={})=>{const a=s.useAPI(),x=c.useMutation({mutationFn:a.settings.update,onSuccess:r.updateSettingsMutationSuccess,onError:r.updateSettingsMutationError}),j=c.useMutation({mutationFn:a.settings.restore,onSuccess:r.restoreSettingsMutationSuccess,onError:r.restoreSettingsMutationError}),g=c.useMutation({mutationFn:a.settings.restart,onSuccess:r.restartStrapiMutationSuccess,onError:r.restartStrapiMutationError}),b=c.useQuery({queryKey:a.config.getKey(),queryFn:a.config.query}),u=c.useQuery({queryKey:a.contentTypeBuilder.all.getKey(),queryFn:a.contentTypeBuilder.all.query}),p=c.useQuery({queryKey:a.roles.getKey(),queryFn:a.roles.query});return m.useMemo(()=>({config:b,collectionTypes:u,roles:p,restoreSettingsMutation:j,updateSettingsMutation:x,restartStrapiMutation:g}),[b,p,u,j,x,g])},y={background:"neutral0",hasRadius:!0,shadow:"filterShadow",padding:6,width:"100%"},U=W.default(t.Alert)(()=>({"[role]":{flexDirection:"column"}})),V=()=>{const{trackUsage:r}=h.useTracking(),a=m.useRef(null),{toggleNotification:x}=h.useNotification(),[j,g]=m.useState(!1),{isLoadingForPermissions:b,canSettingsChange:u}=s.usePermissions(),p=c.useQueryClient(),w=s.useAPI(),{config:l,collectionTypes:R,roles:M,restoreSettingsMutation:T,updateSettingsMutation:I,restartStrapiMutation:A}=_({restoreSettingsMutationSuccess:()=>{p.invalidateQueries({queryKey:w.config.getKey(),exact:!1}),g(!0),x({message:s.getMessage("page.settings.actions.restore.success"),type:"success"})},restartStrapiMutationSuccess:()=>{g(!1)},updateSettingsMutationSuccess:()=>{p.invalidateQueries({queryKey:w.config.getKey(),exact:!1}),g(!0)}}),P=m.useCallback(()=>{a.current?.requestSubmit()},[]),G=m.useCallback(n=>{I.mutate({...n,blockedAuthorProps:n.blockedAuthorProps.split(",").map(o=>o.trim())})},[I]);if(l.status!=="success"||R.status!=="success"||M.status!=="success"||b)return s.getMessage("page.settings.loading");const F=R.data.filter(n=>n.uid.includes("api::")),v=l.data.enabledCollections.filter(n=>F.some(o=>o.uid===n)),k=t.lodashExports.isNil(l.data.badWords)?!0:l.data?.badWords,B=!!l.data.gql?.auth,E=l.data.moderatorRoles.filter(n=>M.data.filter(o=>o.code===n)),H=l.data.client?.url,K=l.data.client?.contactEmail,Q=l.data.blockedAuthorProps??[],O=()=>g(!1);return e.jsxs(e.Fragment,{children:[e.jsx(h.Page.Title,{children:"Comments - settings"}),e.jsxs(h.Page.Main,{children:[e.jsx(h.Layouts.Header,{title:s.getMessage("page.settings.header.title"),subtitle:s.getMessage("page.settings.header.description"),as:"h2",primaryAction:e.jsx(S,{condition:u,children:e.jsx(t.Button,{type:"submit",startIcon:e.jsx(t.ForwardRef$4F,{}),onClick:P,children:s.getMessage("page.settings.actions.submit")})})}),e.jsxs(h.Layouts.Content,{children:[j&&e.jsx(t.Box,{marginBottom:4,children:e.jsx(U,{closeLabel:s.getMessage("page.settings.actions.restart.alert.cancel"),title:s.getMessage("page.settings.actions.restart.alert.title"),onClose:O,action:e.jsx(t.Box,{children:e.jsx(t.Button,{onClick:A.mutate,startIcon:e.jsx(t.ForwardRef$1j,{}),children:s.getMessage("page.settings.actions.restart")})}),children:e.jsx(t.Box,{marginTop:4,children:s.getMessage("page.settings.actions.restart.alert.description")})})}),e.jsx(h.Form,{method:"POST",width:"auto",height:"auto",ref:a,onSubmit:G,initialValues:{enabledCollections:v,moderatorRoles:E,badWords:k,clientEmail:K,clientUrl:H,gqlAuthEnabled:B,approvalFlow:l.data.approvalFlow,entryLabel:l.data.entryLabel,blockedAuthorProps:Q.join(", ")},children:({values:n,onChange:o})=>e.jsxs(t.Flex,{gap:4,direction:"column",children:[e.jsxs(t.Box,{...y,children:[e.jsx(t.Typography,{variant:"delta",as:"h2",children:s.getMessage("page.settings.section.general")}),e.jsxs(t.Grid.Root,{gap:4,marginTop:4,width:"100%",children:[e.jsx(t.Grid.Item,{xs:12,children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.enabledCollections.hint"),children:[e.jsx(t.Field.Label,{htmlFor:"enabledCollections",children:s.getMessage("page.settings.form.enabledCollections.label")}),e.jsx(t.MultiSelect,{withTags:!0,name:"enabledCollections",value:n.enabledCollections,onChange:i=>{o("enabledCollections",i)},children:F.map(i=>e.jsx(t.MultiSelectOption,{value:i.uid,children:i.schema.displayName},i.uid))}),e.jsx(t.Field.Hint,{})]})}),n.enabledCollections.length>0&&e.jsx(t.Grid.Item,{children:e.jsxs(t.Grid.Root,{gap:4,width:"100%",children:[e.jsx(t.Grid.Item,{children:e.jsx(t.Typography,{children:s.getMessage("page.settings.form.contentTypesSettings.label")})}),e.jsx(t.Grid.Item,{children:e.jsx(t.Accordion.Root,{style:{width:"100%"},children:t.lodashExports.orderBy(n.enabledCollections).map(i=>{const C=F.find(f=>f.uid===i);if(C){const{schema:{displayName:f,attributes:q}}=C,L=Object.keys(q).filter(d=>q[d].type==="string");return e.jsxs(t.Accordion.Item,{value:i,children:[e.jsx(t.Accordion.Header,{children:e.jsx(t.Accordion.Trigger,{children:e.jsx(t.Typography,{variant:"epsilon",as:"h3",children:f})})}),e.jsx(t.Accordion.Content,{children:e.jsxs(t.Grid.Root,{padding:6,gap:4,children:[e.jsx(t.Grid.Item,{children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage({id:"page.settings.form.approvalFlow.hint",props:{name:f}}),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.approvalFlow.label")}),e.jsx(t.SwitchImpl,{visibleLabels:!0,onLabel:s.getMessage("components.toogle.enabled"),offLabel:s.getMessage("components.toogle.disabled"),checked:n.approvalFlow.includes(i),onCheckedChange:d=>{o("approvalFlow",d?[...n.approvalFlow,i]:n.approvalFlow.filter($=>$!==i))}}),e.jsx(t.Field.Hint,{})]})}),e.jsx(S,{condition:L.length>0,children:e.jsx(t.Grid.Item,{children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.entryLabel.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.entryLabel.label")}),e.jsx(t.MultiSelect,{withTags:!0,placeholder:s.getMessage("page.settings.form.entryLabel.placeholder"),name:"enabledCollections",value:n.entryLabel[i]??[],onChange:d=>{o("entryLabel",{...n.entryLabel,[i]:d})},children:L.map(d=>e.jsx(t.MultiSelectOption,{value:d,children:d},d))}),e.jsx(t.Field.Hint,{})]})})})]})})]},i)}return null})})})]})})]})]}),e.jsxs(t.Box,{...y,children:[e.jsx(t.Typography,{variant:"delta",as:"h2",children:s.getMessage("page.settings.section.additional")}),e.jsxs(t.Grid.Root,{gap:4,marginTop:4,width:"100%",children:[e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.enabledCollections.hint"),children:[e.jsx(t.Field.Label,{htmlFor:"enabledCollections",children:s.getMessage("page.settings.form.enabledCollections.label")}),e.jsx(t.Toggle,{name:"badWords",checked:n.badWords,onChange:o,onLabel:s.getMessage("components.toogle.enabled"),offLabel:s.getMessage("components.toogle.disabled"),width:"100%"}),e.jsx(t.Field.Hint,{})]})}),e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.author.blockedProps.hint"),children:[e.jsx(t.Field.Label,{htmlFor:"enabledCollections",children:s.getMessage("page.settings.form.author.blockedProps.label")}),e.jsx(t.Field.Input,{name:"blockedProps",onChange:o}),e.jsx(t.Field.Hint,{})]})}),e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.gqlAuth.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.gqlAuth.label")}),e.jsx(t.Toggle,{name:"gqlAuthEnabled",checked:n.gqlAuthEnabled,onChange:o,onLabel:s.getMessage("components.toogle.enabled"),offLabel:s.getMessage("components.toogle.disabled"),width:"100%"}),e.jsx(t.Field.Hint,{})]})})]})]}),e.jsxs(t.Box,{...y,children:[e.jsx(t.Typography,{variant:"delta",as:"h2",children:s.getMessage("page.settings.section.client")}),e.jsxs(t.Grid.Root,{gap:4,marginTop:4,width:"100%",children:[e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.client.url.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.client.url.label")}),e.jsx(t.Field.Input,{name:"clientUrl",onChange:o}),e.jsx(t.Field.Hint,{})]})}),e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.client.email.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.client.email.label")}),e.jsx(t.Field.Input,{name:"clientEmail",onChange:o}),e.jsx(t.Field.Hint,{})]})}),e.jsx(t.Grid.Item,{xs:4,alignItems:"start",children:e.jsxs(t.Field.Root,{width:"100%",hint:s.getMessage("page.settings.form.moderatorRoles.hint"),children:[e.jsx(t.Field.Label,{children:s.getMessage("page.settings.form.moderatorRoles.label")}),e.jsx(t.MultiSelect,{withTags:!0,placeholder:s.getMessage("page.settings.form.moderatorRoles.placeholder"),name:"enabledCollections",value:n.moderatorRoles,onChange:i=>{o("moderatorRoles",i)},children:M.data.map(i=>e.jsx(t.MultiSelectOption,{value:i.code,children:i.name},i.code))}),e.jsx(t.Field.Hint,{})]})})]})]}),e.jsx(S,{condition:u,children:e.jsx(t.Box,{...y,children:e.jsxs(t.Flex,{gap:4,direction:"column",alignItems:"flex-start",children:[e.jsxs(t.Flex,{gap:2,direction:"column",alignItems:"flex-start",children:[e.jsx(t.Typography,{variant:"delta",as:"h2",children:s.getMessage("page.settings.section.restore")}),e.jsx(t.Typography,{variant:"pi",as:"h4",children:s.getMessage("page.settings.section.restore.subtitle")})]}),e.jsx(s.ConfirmationDialog,{Trigger:({onClick:i})=>e.jsx(t.Button,{variant:"danger-light",startIcon:e.jsx(t.ForwardRef$5n,{}),onClick:i,children:s.getMessage("page.settings.actions.restore")}),onConfirm:T.mutate,title:s.getMessage("page.settings.actions.restore.confirmation.header"),labelConfirm:s.getMessage("page.settings.actions.restore.confirmation.button.confirm"),iconConfirm:e.jsx(t.ForwardRef$5n,{}),children:s.getMessage("page.settings.actions.restore.confirmation.description")})]})})})]})})]})]})]})};new c.QueryClient;const z=()=>e.jsx(s.CommonProviders,{children:e.jsx(V,{})});exports.default=z;
@@ -1 +1 @@
1
- "use strict";const e=require("../_chunks/index-DYUGPksR.js");require("react");module.exports=e.index;
1
+ "use strict";const e=require("../_chunks/index-C1LkPp9p.js");require("react");module.exports=e.index;
@@ -1,4 +1,4 @@
1
- import { al as t } from "../_chunks/index-CpBNh6Rx.mjs";
1
+ import { al as t } from "../_chunks/index-B_ImEGPI.mjs";
2
2
  import "react";
3
3
  export {
4
4
  t as default
@@ -8,11 +8,7 @@ export declare const getApiClient: (fetch: ReturnType<typeof getFetchClient>) =>
8
8
  entryLabel: Record<string, string[]>;
9
9
  approvalFlow: string[];
10
10
  blockedAuthorProps: string[];
11
- reportReasons: {
12
- BAD_LANGUAGE: "BAD_LANGUAGE";
13
- DISCRIMINATION: "DISCRIMINATION";
14
- OTHER: "OTHER";
15
- };
11
+ reportReasons: Record<string, string>;
16
12
  regex: {
17
13
  uid: string;
18
14
  relatedUid: string;
@@ -3,19 +3,7 @@ export declare const configSchema: z.ZodObject<{
3
3
  entryLabel: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>;
4
4
  approvalFlow: z.ZodArray<z.ZodString, "many">;
5
5
  blockedAuthorProps: z.ZodArray<z.ZodString, "many">;
6
- reportReasons: z.ZodObject<{
7
- BAD_LANGUAGE: z.ZodLiteral<"BAD_LANGUAGE">;
8
- DISCRIMINATION: z.ZodLiteral<"DISCRIMINATION">;
9
- OTHER: z.ZodLiteral<"OTHER">;
10
- }, "strip", z.ZodTypeAny, {
11
- BAD_LANGUAGE: "BAD_LANGUAGE";
12
- DISCRIMINATION: "DISCRIMINATION";
13
- OTHER: "OTHER";
14
- }, {
15
- BAD_LANGUAGE: "BAD_LANGUAGE";
16
- DISCRIMINATION: "DISCRIMINATION";
17
- OTHER: "OTHER";
18
- }>;
6
+ reportReasons: z.ZodRecord<z.ZodString, z.ZodString>;
19
7
  regex: z.ZodObject<{
20
8
  uid: z.ZodString;
21
9
  relatedUid: z.ZodString;
@@ -57,11 +45,7 @@ export declare const configSchema: z.ZodObject<{
57
45
  entryLabel: Record<string, string[]>;
58
46
  approvalFlow: string[];
59
47
  blockedAuthorProps: string[];
60
- reportReasons: {
61
- BAD_LANGUAGE: "BAD_LANGUAGE";
62
- DISCRIMINATION: "DISCRIMINATION";
63
- OTHER: "OTHER";
64
- };
48
+ reportReasons: Record<string, string>;
65
49
  regex: {
66
50
  uid: string;
67
51
  relatedUid: string;
@@ -83,11 +67,7 @@ export declare const configSchema: z.ZodObject<{
83
67
  entryLabel: Record<string, string[]>;
84
68
  approvalFlow: string[];
85
69
  blockedAuthorProps: string[];
86
- reportReasons: {
87
- BAD_LANGUAGE: "BAD_LANGUAGE";
88
- DISCRIMINATION: "DISCRIMINATION";
89
- OTHER: "OTHER";
90
- };
70
+ reportReasons: Record<string, string>;
91
71
  regex: {
92
72
  uid: string;
93
73
  relatedUid: string;
@@ -5,11 +5,7 @@ export declare const useAPI: () => {
5
5
  entryLabel: Record<string, string[]>;
6
6
  approvalFlow: string[];
7
7
  blockedAuthorProps: string[];
8
- reportReasons: {
9
- BAD_LANGUAGE: "BAD_LANGUAGE";
10
- DISCRIMINATION: "DISCRIMINATION";
11
- OTHER: "OTHER";
12
- };
8
+ reportReasons: Record<string, string>;
13
9
  regex: {
14
10
  uid: string;
15
11
  relatedUid: string;
@@ -3,11 +3,7 @@ export declare const useConfig: (setSettings: (settings: Config) => void) => imp
3
3
  entryLabel: Record<string, string[]>;
4
4
  approvalFlow: string[];
5
5
  blockedAuthorProps: string[];
6
- reportReasons: {
7
- BAD_LANGUAGE: "BAD_LANGUAGE";
8
- DISCRIMINATION: "DISCRIMINATION";
9
- OTHER: "OTHER";
10
- };
6
+ reportReasons: Record<string, string>;
11
7
  regex: {
12
8
  uid: string;
13
9
  relatedUid: string;
@@ -11,11 +11,7 @@ export declare const useSettingsAPI: (callbacksMutation?: CallbacksMutation) =>
11
11
  entryLabel: Record<string, string[]>;
12
12
  approvalFlow: string[];
13
13
  blockedAuthorProps: string[];
14
- reportReasons: {
15
- BAD_LANGUAGE: "BAD_LANGUAGE";
16
- DISCRIMINATION: "DISCRIMINATION";
17
- OTHER: "OTHER";
18
- };
14
+ reportReasons: Record<string, string>;
19
15
  regex: {
20
16
  uid: string;
21
17
  relatedUid: string;