@clickview/reports 0.46.0 → 0.46.1-rc.0

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.
Files changed (128) hide show
  1. package/dist/bundles.json +3 -3
  2. package/dist/css/{337-reports-790935b6e7.chunk.css → 1337-reports-517278cf2f.chunk.css} +1 -1
  3. package/dist/css/{109-reports-755b191eba.chunk.css → 2109-reports-53da601210.chunk.css} +1 -1
  4. package/dist/css/{194-reports-5167370e1b.chunk.css → 2194-reports-1cff0f1274.chunk.css} +1 -1
  5. package/dist/css/{404-reports-3002b5026e.chunk.css → 2246-reports-4f48adb0ff.chunk.css} +1 -1
  6. package/dist/css/{860-reports-810d21564f.chunk.css → 2860-reports-2ae71f2f9c.chunk.css} +1 -1
  7. package/dist/css/{126-reports-c235bce8a8.chunk.css → 3126-reports-f17c4631be.chunk.css} +2 -2
  8. package/dist/css/{592-reports-3b82562437.chunk.css → 5198-reports-257241c6d3.chunk.css} +1 -1
  9. package/dist/css/{691-reports-fc888c1aed.chunk.css → 5691-reports-f9d9c6fa55.chunk.css} +1 -1
  10. package/dist/css/{607-reports-a74fd8a738.chunk.css → 6607-reports-b2b8fa53cf.chunk.css} +2 -2
  11. package/dist/css/{70-reports-cce6c63705.chunk.css → 8070-reports-d7ae9dc7d6.chunk.css} +1 -1
  12. package/dist/css/{356-reports-be14d48dee.chunk.css → 9356-reports-943277a747.chunk.css} +1 -1
  13. package/dist/css/{889-reports-cf5de56b06.chunk.css → 9889-reports-a733281dff.chunk.css} +2 -2
  14. package/dist/css/reports-app-6008dd2216.css +30 -0
  15. package/dist/languages/en.json +1 -1
  16. package/dist/scripts/1086-4b935ce42b-reports.chunk.js +1 -0
  17. package/dist/scripts/1156-0aa99624ae-reports.chunk.js +1 -0
  18. package/dist/scripts/1199-95101807c3-reports.chunk.js +1 -0
  19. package/dist/scripts/1335-92501ae040-reports.chunk.js +1 -0
  20. package/dist/scripts/1337-c52308e069-reports.chunk.js +1 -0
  21. package/dist/scripts/1837-b3cf1cf3cb-reports.chunk.js +1 -0
  22. package/dist/scripts/2087-9ac68819fd-reports.chunk.js +1 -0
  23. package/dist/scripts/2109-29303bea1c-reports.chunk.js +1 -0
  24. package/dist/scripts/2194-e883272565-reports.chunk.js +1 -0
  25. package/dist/scripts/2246-56b1f1c338-reports.chunk.js +1 -0
  26. package/dist/scripts/2421-5d7e1fdee7-reports.chunk.js +1 -0
  27. package/dist/scripts/2860-fd3bed088a-reports.chunk.js +1 -0
  28. package/dist/scripts/3050-ed575b4350-reports.chunk.js +2 -0
  29. package/dist/scripts/3126-7de2a83755-reports.chunk.js +1 -0
  30. package/dist/scripts/3159-bb4bb31518-reports.chunk.js +1 -0
  31. package/dist/scripts/3567-3f0b71a89a-reports.chunk.js +1 -0
  32. package/dist/scripts/3603-d286899c93-reports.chunk.js +1 -0
  33. package/dist/scripts/4064-f9efb34c88-reports.chunk.js +1 -0
  34. package/dist/scripts/4335-3c97122d05-reports.chunk.js +1 -0
  35. package/dist/scripts/4675-b03bfcad17-reports.chunk.js +1 -0
  36. package/dist/scripts/5071-52cefd9072-reports.chunk.js +1 -0
  37. package/dist/scripts/5173-1cf785ffd7-reports.chunk.js +1 -0
  38. package/dist/scripts/5198-a6068822b4-reports.chunk.js +1 -0
  39. package/dist/scripts/5691-df229168ec-reports.chunk.js +1 -0
  40. package/dist/scripts/5726-636c120bd4-reports.chunk.js +1 -0
  41. package/dist/scripts/5755-151c57cbba-reports.chunk.js +1 -0
  42. package/dist/scripts/6056-49df7e924f-reports.chunk.js +1 -0
  43. package/dist/scripts/6198-f3f3e6ff36-reports.chunk.js +1 -0
  44. package/dist/scripts/6217-944f7eb78f-reports.chunk.js +1 -0
  45. package/dist/scripts/6505-aa9302ffb1-reports.chunk.js +1 -0
  46. package/dist/scripts/6572-232a2a4cd6-reports.chunk.js +1 -0
  47. package/dist/scripts/6607-d8577d7b88-reports.chunk.js +2 -0
  48. package/dist/scripts/6616-1f6c225d20-reports.chunk.js +1 -0
  49. package/dist/scripts/6997-df7f3dec47-reports.chunk.js +1 -0
  50. package/dist/scripts/7120-5cbb3dc3fa-reports.chunk.js +1 -0
  51. package/dist/scripts/7184-5f54ea3c86-reports.chunk.js +1 -0
  52. package/dist/scripts/7198-089d0789be-reports.chunk.js +1 -0
  53. package/dist/scripts/765-88687d5494-reports.chunk.js +1 -0
  54. package/dist/scripts/7925-bbe2746098-reports.chunk.js +1 -0
  55. package/dist/scripts/8070-413d49027c-reports.chunk.js +1 -0
  56. package/dist/scripts/820-fd5e3c5ac9-reports.chunk.js +1 -0
  57. package/dist/scripts/8246-6c07d3562d-reports.chunk.js +1 -0
  58. package/dist/scripts/9217-68d3e441ad-reports.chunk.js +1 -0
  59. package/dist/scripts/9356-2e99f1678a-reports.chunk.js +1 -0
  60. package/dist/scripts/9577-14c59c254d-reports.chunk.js +1 -0
  61. package/dist/scripts/9647-a4df50e519-reports.chunk.js +1 -0
  62. package/dist/scripts/9663-35c8caaba9-reports.chunk.js +2 -0
  63. package/dist/scripts/9889-b6445926ec-reports.chunk.js +1 -0
  64. package/dist/scripts/bundle-ff4cdf3129.min.js +2 -0
  65. package/package.json +1 -1
  66. package/dist/css/reports-app-0547de7bce.css +0 -30
  67. package/dist/scripts/109-f25da1408d-reports.chunk.js +0 -1
  68. package/dist/scripts/120-e9230a234e-reports.chunk.js +0 -1
  69. package/dist/scripts/126-c9ef3a52e3-reports.chunk.js +0 -1
  70. package/dist/scripts/156-30567c63b3-reports.chunk.js +0 -1
  71. package/dist/scripts/169-a0f10a0ac3-reports.chunk.js +0 -1
  72. package/dist/scripts/173-a892a4101f-reports.chunk.js +0 -1
  73. package/dist/scripts/184-4cc22e619b-reports.chunk.js +0 -1
  74. package/dist/scripts/193-9e1d26aedf-reports.chunk.js +0 -1
  75. package/dist/scripts/194-d762dd3871-reports.chunk.js +0 -1
  76. package/dist/scripts/198-4d59523773-reports.chunk.js +0 -1
  77. package/dist/scripts/199-ae691c9697-reports.chunk.js +0 -1
  78. package/dist/scripts/217-b3c5f72a37-reports.chunk.js +0 -1
  79. package/dist/scripts/240-cb56c1030a-reports.chunk.js +0 -1
  80. package/dist/scripts/246-c123a53cb3-reports.chunk.js +0 -1
  81. package/dist/scripts/335-c34bad801d-reports.chunk.js +0 -1
  82. package/dist/scripts/337-80d10046cb-reports.chunk.js +0 -1
  83. package/dist/scripts/356-2ec2483491-reports.chunk.js +0 -1
  84. package/dist/scripts/404-060aba07de-reports.chunk.js +0 -1
  85. package/dist/scripts/421-1d1950f52f-reports.chunk.js +0 -1
  86. package/dist/scripts/50-c28c2059e4-reports.chunk.js +0 -2
  87. package/dist/scripts/572-aac1afa908-reports.chunk.js +0 -1
  88. package/dist/scripts/577-14a66f8f5d-reports.chunk.js +0 -1
  89. package/dist/scripts/592-44083c4714-reports.chunk.js +0 -1
  90. package/dist/scripts/603-101cdfd058-reports.chunk.js +0 -1
  91. package/dist/scripts/607-59b1fecba3-reports.chunk.js +0 -2
  92. package/dist/scripts/616-c0ef0b997b-reports.chunk.js +0 -1
  93. package/dist/scripts/64-ccba80a374-reports.chunk.js +0 -1
  94. package/dist/scripts/647-3ce910dd13-reports.chunk.js +0 -1
  95. package/dist/scripts/651-c71a62e4f0-reports.chunk.js +0 -2
  96. package/dist/scripts/675-dbba664592-reports.chunk.js +0 -1
  97. package/dist/scripts/691-b09a2ec2da-reports.chunk.js +0 -1
  98. package/dist/scripts/70-340d231821-reports.chunk.js +0 -1
  99. package/dist/scripts/71-4fae814488-reports.chunk.js +0 -1
  100. package/dist/scripts/726-82d11b32bb-reports.chunk.js +0 -1
  101. package/dist/scripts/731-f79476bfa0-reports.chunk.js +0 -1
  102. package/dist/scripts/755-87fb860465-reports.chunk.js +0 -1
  103. package/dist/scripts/765-990dce82e2-reports.chunk.js +0 -1
  104. package/dist/scripts/820-6320068153-reports.chunk.js +0 -1
  105. package/dist/scripts/837-fc8c5022ed-reports.chunk.js +0 -1
  106. package/dist/scripts/86-03d96720a7-reports.chunk.js +0 -1
  107. package/dist/scripts/860-993a5ccc33-reports.chunk.js +0 -1
  108. package/dist/scripts/864-bb9b78f6be-reports.chunk.js +0 -1
  109. package/dist/scripts/87-f888b6755d-reports.chunk.js +0 -1
  110. package/dist/scripts/876-1f9f63e705-reports.chunk.js +0 -1
  111. package/dist/scripts/889-ae365b003f-reports.chunk.js +0 -1
  112. package/dist/scripts/925-386ebc5eea-reports.chunk.js +0 -1
  113. package/dist/scripts/997-7dc2d935a7-reports.chunk.js +0 -1
  114. package/dist/scripts/bundle-aaf5058585.min.js +0 -2
  115. /package/dist/css/{731-reports-f9998fce71.chunk.css → 1335-reports-f9998fce71.chunk.css} +0 -0
  116. /package/dist/css/{71-reports-65363325b5.chunk.css → 5071-reports-65363325b5.chunk.css} +0 -0
  117. /package/dist/css/{726-reports-30017b2ec8.chunk.css → 5726-reports-30017b2ec8.chunk.css} +0 -0
  118. /package/dist/css/{240-reports-5003a995f4.chunk.css → 6217-reports-5003a995f4.chunk.css} +0 -0
  119. /package/dist/css/{864-reports-8ee1478aa7.chunk.css → 6505-reports-8ee1478aa7.chunk.css} +0 -0
  120. /package/dist/css/{198-reports-0609804d93.chunk.css → 7198-reports-0609804d93.chunk.css} +0 -0
  121. /package/dist/css/{217-reports-4302570db8.chunk.css → 9217-reports-4302570db8.chunk.css} +0 -0
  122. /package/dist/css/{577-reports-8e46644943.chunk.css → 9577-reports-8e46644943.chunk.css} +0 -0
  123. /package/dist/css/{651-reports-1c34faabd1.chunk.css → 9663-reports-1c34faabd1.chunk.css} +0 -0
  124. /package/dist/scripts/{50-c28c2059e4-reports.chunk.js.LICENSE.txt → 3050-ed575b4350-reports.chunk.js.LICENSE.txt} +0 -0
  125. /package/dist/scripts/{607-59b1fecba3-reports.chunk.js.LICENSE.txt → 6607-d8577d7b88-reports.chunk.js.LICENSE.txt} +0 -0
  126. /package/dist/scripts/{651-c71a62e4f0-reports.chunk.js.LICENSE.txt → 9663-35c8caaba9-reports.chunk.js.LICENSE.txt} +0 -0
  127. /package/dist/scripts/{bundle-aaf5058585.min.js.LICENSE.txt → bundle-ff4cdf3129.min.js.LICENSE.txt} +0 -0
  128. /package/dist/scripts/{polyfills-26a87754bd.min.js → polyfills-af384d1bb2.min.js} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_reports=self.webpackChunk_clickview_reports||[]).push([[616],{30439:(e,t,r)=>{r.d(t,{o:()=>p});var n=r(99940),a=r(97395),i=r(78417);function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}function c(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=o(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!=o(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==o(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function s(e){return function(e){if(Array.isArray(e))return u(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?u(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var l={namespace:"share"},d={video:"thumbnail,_canBeConsumed",clip:"_parentVideo[rating],_canBeConsumed,_thumbnail",interactive:"_canBeConsumed,_parentVideo[rating],_parentClip,_thumbnail",series:"tallPoster",playlist:"cover"};function f(e,t){return{id:e,"query.user":"yearGroups,avatar,userprofiles{customer.id:".concat(t,"}"),"query.classroom":"enrolments[count()]{role:student,limit:0},customer{id:".concat(t,"}"),"query.classroom_group":"classroom,users[count()]{limit:0}"}}var p={getShareObject:function(e,t,r){return{url:"/api/share/find/".concat(e),key:"share:".concat(e),bootstrapName:"share:".concat(e),success:t,error:r}},sharedObjectsById:function(e){e.sort();var t=e.map((function(e){return"id=".concat(e)})),r=Object.keys(d).map((function(e){return"query.".concat(e,"=").concat(d[e])}));return{url:"{gateway}/v1/objects?".concat([].concat(s(t),s(r),["permissionFilterOption=".concat(i.r.StripMetadata)]).join("&")),key:"objects:".concat(e.join(","))}},sentShare:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=Object.values(e).join(":");return{url:a._.urlBuilder("{gateway}/v1/users/me/share/sent-items",e),key:"sent:shares:".concat(t),normalize:!1}},getSentDirectShareByObjectId:function(e){return{url:"{gateway}/v1/users/me/share/direct/sent-items?objectId=".concat(e),key:"direct:share:sent:object:".concat(e),normalizeOptions:l}},createDirectShare:function(e,t,r,a){return{url:"{gateway}/v1/share",key:"create:direct:share",data:e,type:n.k.POST,normalizeOptions:l,invalidationKeys:["direct:share:sent:object:".concat(e.objectId),"sent:shares"],success:t,error:r,always:a}},updateDirectShareRecipients:function(e,t,r,a,i){var o="direct:share:recipients:".concat(e);return{url:"{gateway}/v1/share/".concat(e,"/recipients"),key:"edit:direct:share",data:t,type:n.k.POST,normalizeOptions:l,invalidationKeys:"sent:shares",updateState:{keys:o,updateData:function(e){return!e[o]||t.recipients.length?e:Object.assign(Object.assign({},e),c({},o,[]))}},success:r,error:a,always:i}},removeDirectShareRecipient:function(e,t,r,i,o){var s="direct:share:recipients:".concat(e);return{url:a._.urlBuilder("{gateway}/v1/share/".concat(e,"/recipients"),{recipientId:t}),key:"remove:direct:share:recipient",type:n.k.DELETE,normalizeOptions:l,invalidationKeys:"sent:shares",updateState:{keys:s,updateData:function(e){return e[s]?Object.assign(Object.assign({},e),c({},s,[])):e}},success:r,error:i,always:o}},getDirectShareRecipientsById:function(e,t,r){return{url:a._.urlBuilder("{gateway}/v1/objects",f(t.map((function(e){return e.id})),r)),key:"direct:share:recipients:".concat(e)}},getRecipientsById:function(e,t){return e.sort(),{url:a._.urlBuilder("{gateway}/v1/objects",f(e,t)),key:"share:recipients:".concat(e.join(","))}},getRecipientUsers:function(e,t){return{url:"{gateway}/v1/objects/".concat(e,"/users?query={limit:100}"),key:"share:recipients:".concat(e,":users"),success:t}},getObjectsSharedWithUser:function(e){var t={permissionFilterOption:i.r.StripMetadata};return e&&(t.cursor=e),{url:a._.urlBuilder("{gateway}/v1/users/me/share/received-items",t),key:"shared:with:me:".concat(e)}},getShareLinkByObjectId:function(e){return{url:"{gateway}/v1/share/links?objectId=".concat(e),key:"share:link:object:".concat(e),normalizeOptions:l,formatData:function(e){return Object.assign(Object.assign({},e),{linkExpireDate:e.linkExpireDate||null})}}},createShareLink:function(e,t,r,a){return{url:"{gateway}/v1/share/links",key:"create:share:link",type:n.k.POST,data:e,normalizeOptions:l,invalidationKeys:["share:link:object:".concat(e.resourceId),"privacy:".concat(e.resourceId),"sent:shares"],success:t,error:r,always:a}},editShareLink:function(e,t,r,a,i){return{url:"{gateway}/v1/share/links/".concat(e.id),key:"edit:share:link",data:t,type:n.k.PUT,normalizeOptions:l,invalidationKeys:["share:".concat(e.id),"share:link:object:".concat(e.objectId),"sent:shares"],success:r,error:a,always:i}},deleteShareLink:function(e,t,r,a){return{url:"{gateway}/v1/share/links/".concat(e.id),key:"delete:share:link",type:n.k.DELETE,normalizeOptions:l,invalidationKeys:["share:".concat(e.id),"share:link:object:".concat(e.objectId),"sent:shares"],success:t,error:r,always:a}},checkPassword:function(e,t,r,a){return{url:"/api/share/links/".concat(e,"/check-password"),key:"checkpassword:".concat(e),type:n.k.POST,data:{password:t},success:r,error:a}},getPrivacy:function(e){return{url:"{gateway}/v1/objects/".concat(e,"/access"),key:"privacy:".concat(e),normalize:!1}},updatePrivacy:function(e,t,r,a,i){return{url:"{gateway}/v1/share/links/".concat(e,"/privacy"),key:"update:privacy",type:n.k.PUT,data:{privacy:t,overrideRestrictions:r},invalidationKeys:"privacy",normalize:!1,success:a,error:i}}}},28972:(e,t,r)=>{var n;r.d(t,{w:()=>n}),function(e){e[e.Correct=0]="Correct",e[e.Incorrect=1]="Incorrect",e[e.AwaitingMarking=2]="AwaitingMarking",e[e.Answered=3]="Answered",e[e.UnAnswered=4]="UnAnswered",e[e.NotApplicable=5]="NotApplicable"}(n||(n={}))},8246:(e,t,r)=>{var n;r.d(t,{N:()=>n}),function(e){e[e.Incorrect=0]="Incorrect",e[e.Correct=1]="Correct",e[e.PendingReview=2]="PendingReview"}(n||(n={}))},83140:(e,t,r)=>{r.d(t,{A:()=>y});var n=r(28972),a=r(8246),i=r(46237);function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}function c(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=o(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!=o(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==o(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function s(){return n.w.NotApplicable}function u(e,t){var r=e.actionableItems.filter((function(e){return e.isCorrect}));return r.every((function(e){return!t(e.id)}))?n.w.UnAnswered:r.every((function(e){var r;return e.name.trim().toLowerCase()===(null===(r=t(e.id))||void 0===r?void 0:r.trim().toLowerCase())}))?n.w.Correct:n.w.Incorrect}function l(e,t){return e.actionableItems.every((function(e){return!t(e.id)}))?n.w.UnAnswered:e.actionableItems.filter((function(e){return e.isCorrect})).every((function(e){return t(e.id)===e.name}))?n.w.Correct:n.w.Incorrect}function d(e,t){var r;return e.actionableItems.forEach((function(e){var i=t(e.id);r=i?i.status!==a.N.Correct?i.status!==a.N.Incorrect?n.w.AwaitingMarking:n.w.Incorrect:n.w.Correct:n.w.UnAnswered})),r}function f(e,t){return function(r){var n=t.attempts.find((function(t){return t.id===e.id}));return null==n?void 0:n.answers.find((function(e){return e.id===r}))}}function p(e,t){var r=f(e,t);return l(e,(function(e){var t=r(e);return null==t?void 0:t.text}))}var v=c(c(c(c(c(c({},i.Z9.Annotation,s),i.Z9.Image,s),i.Z9.MissingWord,(function(e,t){var r=f(e,t);return u(e,(function(e){var t=r(e);return null==t?void 0:t.text}))})),i.Z9.MultipleChoice,p),i.Z9.ShortAnswer,(function(e,t){return d(e,f(e,t))})),i.Z9.TrueOrFalse,p),y={notApplicable:s,awaitingMarking:function(){return n.w.AwaitingMarking},isMissingWordCorrect:u,isMultipleChoiceCorrect:l,isShortAnswerMarkedCorrect:d,isInteractionCorrect:function(e,t){return(0,v[e.typeId])(e,t)}}},80845:(e,t,r)=>{r.d(t,{Q:()=>u,Wn:()=>o,f6:()=>s,j_:()=>c});var n=r(75896),a=r(46237);function i(e){return e.typeId!==a.Z9.Annotation&&e.typeId!==a.Z9.Image}function o(e){return n.m.flatten(e.timepoints.map((function(e){return e.interactions})))}function c(e){return n.m.last(e.results)}function s(e,t){return n.m.findWhere(null==t?void 0:t.attempts,{id:e})}function u(e){return o(e).filter(i)}},71270:(e,t,r)=>{r.d(t,{l:()=>l});var n=r(32735),a=r(23481),i=r(59710),o=r(92209),c=r(28512),s=r(99827),u=a.T.encloseNamespace("reportsInteractives.interactiveNav");function l(e){var t,r,a=(t=(0,s.b)(),r=[e.interactiveMetadataId],[{label:u("overview"),appLink:{application:c.O.INTERACTIVES,action:o.e.Interactives.OVERVIEW,args:r,params:t}},{label:u("results"),appLink:{application:c.O.INTERACTIVES,action:o.e.Interactives.RESULTS,args:r,params:t}},{label:u("questions"),appLink:{application:c.O.INTERACTIVES,action:o.e.Interactives.QUESTION_LIST,args:r,params:t}},{label:u("engagement"),appLink:{application:c.O.INTERACTIVES,action:o.e.Interactives.ENGAGEMENT,args:r,params:t}}]);return n.createElement(i.m,{items:a})}},23178:(e,t,r)=>{r.d(t,{m:()=>b});var n=r(32735),a=r(50242),i=r(23481),o=r(57900),c=r(81886),s=r(20354),u=r(30439),l=r(15800),d=r(89961),f=r(92209),p=r(55884),v=r(28512),y=r(39553),m=i.T.encloseNamespace("reportsInteractives.hooks");function h(){return n.createElement(l.u,{className:"py-3"},n.createElement(l.u.Image,{src:p.W.EmptyStates.Interactives.NoData,className:"w-50 h-auto"}),n.createElement(l.u.Heading,null,m("noResultsHeading")),n.createElement(l.u.Info,{className:"w-100"},m("noResultsDescription")))}function b(e){var t,r,i=function(e){return"no:interactive:results:warning:".concat(e)}(e),l=o.SG.cacheGet(i),p=(0,y.W)(e),b=null===(r=null===(t=p.data)||void 0===t?void 0:t.students)||void 0===r?void 0:r.length,g=!!p.data&&!b,w=s.a.useBasicFetch(g&&u.o.getShareLinkByObjectId(e)),k=s.a.useBasicFetch(g&&u.o.getSentDirectShareByObjectId(e)),I=!!w.hasCompleted&&w.statusCode===a.o.NotFound,S=!!k.hasCompleted&&k.statusCode===a.o.NotFound,j=I&&S;n.useEffect((function(){j&&!l&&(o.SG.cacheSet(i,!0),d.M.render(n.createElement(h,null),{title:m("shareInteractive"),buttonContainerClassName:"border-top-0 justify-content-center mt-n4 pb-3",submitButtonProps:{text:m("shareInteractive"),onClick:function(){c.Q.C$.trigger({application:v.O.DEFAULT,action:f.e.Default.SHARE,args:[e],params:{entityType:"interactive"}})},variant:"dark",className:"me-2"}}))}),[j,l])}},84049:(e,t,r)=>{r.d(t,{P:()=>d});var n=r(32735),a=r(2948),i=r(16714),o=r(22902),c=r(79489),s=r(99827),u=r(39553);function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function d(e){var t,r,d=(0,(0,o.T)().hasPermissions)(i.C.ViewCustomerAnalytics),f=(0,s.R)(),p=d&&!!f,v=(0,u.W)(p&&e,{start:null==f?void 0:f.start,end:null==f?void 0:f.end}),y=(t=(0,a.D)(c.y.AUDIENCE_FILTER_SUGGESTIONS),r=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,c=[],s=!0,u=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;s=!1}else for(;!(s=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);s=!0);}catch(e){u=!0,a=e}finally{try{if(!s&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw a}}return c}}(t,r)||function(e,t){if(e){if("string"==typeof e)return l(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?l(e,t):void 0}}(t,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[1];(0,n.useEffect)((function(){var e,t;v.data&&y("users",null===(t=null===(e=v.data)||void 0===e?void 0:e.students)||void 0===t?void 0:t.map((function(e){return e.user.id})))}),[v.isFetching])}},22628:(e,t,r)=>{r.d(t,{HI:()=>u,Rt:()=>d,UU:()=>s,Zs:()=>c,nq:()=>l});var n=r(28972),a=r(8246),i=r(83140),o=r(80845);function c(e,t){return(0,o.Wn)(e).find((function(e){return e.id.toString()===t.toString()}))}function s(e){return"".concat(e.questionId,":").concat(e.resultId)}function u(e,t,r){var n=(0,o.j_)(t),i=(0,o.f6)(e,n);return(null==i?void 0:i.answers.every((function(e){var t;return(null===(t=r[s(e)])||void 0===t?void 0:t.status)===a.N.Correct})))?a.N.Correct:(null==i?void 0:i.answers.every((function(e){var t;return(null===(t=r[s(e)])||void 0===t?void 0:t.status)===a.N.Incorrect})))?a.N.Incorrect:void 0}function l(e,t){var r=t.students.length,a=0,c=0,s=0,u=0;return t.students.forEach((function(t){var r=(0,o.j_)(t);if(r){var l=i.A.isInteractionCorrect(e,r);l===n.w.Correct&&a++,l===n.w.UnAnswered&&s++,l===n.w.AwaitingMarking&&u++,l!==n.w.UnAnswered&&c++}})),{percentCorrect:r>0?a/r:0,correct:a,answered:c,unanswered:s,awaitingMarking:u}}function d(e,t){var r=(0,o.j_)(t),a=(0,o.Q)(e),c=a.length,s=0,u=0;a.forEach((function(e){var t=i.A.isInteractionCorrect(e,r);t===n.w.Correct&&s++,t===n.w.AwaitingMarking&&u++}));var l=c>0?s/c:0,d=new Set(a.map((function(e){return e.id}))),f=r.attempts.filter((function(e){var t;return!!d.has(null===(t=null==e?void 0:e.answers[0])||void 0===t?void 0:t.questionId)})).length;return{answered:r.attempts.length,unanswered:c-f,percentCorrect:l,correct:s,awaitingMarking:u}}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_reports=self.webpackChunk_clickview_reports||[]).push([[64],{97079:(e,t)=>{t.Z=function(e,t){if(e&&t){var n=Array.isArray(t)?t:t.split(","),r=e.name||"",o=(e.type||"").toLowerCase(),i=o.replace(/\/.*$/,"");return n.some((function(e){var t=e.trim().toLowerCase();return"."===t.charAt(0)?r.toLowerCase().endsWith(t):t.endsWith("/*")?i===t.replace(/\/.*$/,""):o===t}))}return!0}},24064:(e,t,n)=>{n.d(t,{uI:()=>ae});var r=n(32735),o=n(60216),i=n.n(o);function a(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function c(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,c)}u((r=r.apply(e,t||[])).next())}))}function c(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function c(c){return function(u){return function(c){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,c[0]&&(a=0)),a;)try{if(n=1,r&&(o=2&c[0]?r.return:c[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,c[1])).done)return o;switch(r=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return a.label++,{value:c[1],done:!1};case 5:a.label++,r=c[1],c=[0];continue;case 7:c=a.ops.pop(),a.trys.pop();continue;default:if(!((o=(o=a.trys).length>0&&o[o.length-1])||6!==c[0]&&2!==c[0])){a=0;continue}if(3===c[0]&&(!o||c[1]>o[0]&&c[1]<o[3])){a.label=c[1];break}if(6===c[0]&&a.label<o[1]){a.label=o[1],o=c;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(c);break}o[2]&&a.ops.pop(),a.trys.pop();continue}c=t.call(e,a)}catch(e){c=[6,e],r=0}finally{n=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([c,u])}}}function u(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function l(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}Object.create,Object.create,"function"==typeof SuppressedError&&SuppressedError;var s=new Map([["aac","audio/aac"],["abw","application/x-abiword"],["arc","application/x-freearc"],["avif","image/avif"],["avi","video/x-msvideo"],["azw","application/vnd.amazon.ebook"],["bin","application/octet-stream"],["bmp","image/bmp"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["cda","application/x-cdf"],["csh","application/x-csh"],["css","text/css"],["csv","text/csv"],["doc","application/msword"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["eot","application/vnd.ms-fontobject"],["epub","application/epub+zip"],["gz","application/gzip"],["gif","image/gif"],["heic","image/heic"],["heif","image/heif"],["htm","text/html"],["html","text/html"],["ico","image/vnd.microsoft.icon"],["ics","text/calendar"],["jar","application/java-archive"],["jpeg","image/jpeg"],["jpg","image/jpeg"],["js","text/javascript"],["json","application/json"],["jsonld","application/ld+json"],["mid","audio/midi"],["midi","audio/midi"],["mjs","text/javascript"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mpeg","video/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["opus","audio/opus"],["otf","font/otf"],["png","image/png"],["pdf","application/pdf"],["php","application/x-httpd-php"],["ppt","application/vnd.ms-powerpoint"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["rar","application/vnd.rar"],["rtf","application/rtf"],["sh","application/x-sh"],["svg","image/svg+xml"],["swf","application/x-shockwave-flash"],["tar","application/x-tar"],["tif","image/tiff"],["tiff","image/tiff"],["ts","video/mp2t"],["ttf","font/ttf"],["txt","text/plain"],["vsd","application/vnd.visio"],["wav","audio/wav"],["weba","audio/webm"],["webm","video/webm"],["webp","image/webp"],["woff","font/woff"],["woff2","font/woff2"],["xhtml","application/xhtml+xml"],["xls","application/vnd.ms-excel"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xml","application/xml"],["xul","application/vnd.mozilla.xul+xml"],["zip","application/zip"],["7z","application/x-7z-compressed"],["mkv","video/x-matroska"],["mov","video/quicktime"],["msg","application/vnd.ms-outlook"]]);function f(e,t){var n=function(e){var t=e.name;if(t&&-1!==t.lastIndexOf(".")&&!e.type){var n=t.split(".").pop().toLowerCase(),r=s.get(n);r&&Object.defineProperty(e,"type",{value:r,writable:!1,configurable:!1,enumerable:!0})}return e}(e);if("string"!=typeof n.path){var r=e.webkitRelativePath;Object.defineProperty(n,"path",{value:"string"==typeof t?t:"string"==typeof r&&r.length>0?r:e.name,writable:!1,configurable:!1,enumerable:!0})}return n}var p=[".DS_Store","Thumbs.db"];function d(e){return"object"==typeof e&&null!==e}function v(e){return b(e.target.files).map((function(e){return f(e)}))}function m(e){return a(this,void 0,void 0,(function(){return c(this,(function(t){switch(t.label){case 0:return[4,Promise.all(e.map((function(e){return e.getFile()})))];case 1:return[2,t.sent().map((function(e){return f(e)}))]}}))}))}function g(e,t){return a(this,void 0,void 0,(function(){var n;return c(this,(function(r){switch(r.label){case 0:return e.items?(n=b(e.items).filter((function(e){return"file"===e.kind})),"drop"!==t?[2,n]:[4,Promise.all(n.map(h))]):[3,2];case 1:return[2,y(w(r.sent()))];case 2:return[2,y(b(e.files).map((function(e){return f(e)})))]}}))}))}function y(e){return e.filter((function(e){return-1===p.indexOf(e.name)}))}function b(e){if(null===e)return[];for(var t=[],n=0;n<e.length;n++){var r=e[n];t.push(r)}return t}function h(e){if("function"!=typeof e.webkitGetAsEntry)return D(e);var t=e.webkitGetAsEntry();return t&&t.isDirectory?O(t):D(e)}function w(e){return e.reduce((function(e,t){return l(l([],u(e),!1),u(Array.isArray(t)?w(t):[t]),!1)}),[])}function D(e){var t=e.getAsFile();if(!t)return Promise.reject("".concat(e," is not a File"));var n=f(t);return Promise.resolve(n)}function x(e){return a(this,void 0,void 0,(function(){return c(this,(function(t){return[2,e.isDirectory?O(e):j(e)]}))}))}function O(e){var t=e.createReader();return new Promise((function(e,n){var r=[];!function o(){var i=this;t.readEntries((function(t){return a(i,void 0,void 0,(function(){var i,a,u;return c(this,(function(c){switch(c.label){case 0:if(t.length)return[3,5];c.label=1;case 1:return c.trys.push([1,3,,4]),[4,Promise.all(r)];case 2:return i=c.sent(),e(i),[3,4];case 3:return a=c.sent(),n(a),[3,4];case 4:return[3,6];case 5:u=Promise.all(t.map(x)),r.push(u),o(),c.label=6;case 6:return[2]}}))}))}),(function(e){n(e)}))}()}))}function j(e){return a(this,void 0,void 0,(function(){return c(this,(function(t){return[2,new Promise((function(t,n){e.file((function(n){var r=f(n,e.fullPath);t(r)}),(function(e){n(e)}))}))]}))}))}var A=n(97079);function k(e){return function(e){if(Array.isArray(e))return z(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||C(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function F(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?E(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function S(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function P(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i=[],a=!0,c=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){c=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(c)throw o}}return i}}(e,t)||C(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function C(e,t){if(e){if("string"==typeof e)return z(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?z(e,t):void 0}}function z(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var R=function(e){e=Array.isArray(e)&&1===e.length?e[0]:e;var t=Array.isArray(e)?"one of ".concat(e.join(", ")):e;return{code:"file-invalid-type",message:"File type must be ".concat(t)}},I=function(e){return{code:"file-too-large",message:"File is larger than ".concat(e," ").concat(1===e?"byte":"bytes")}},T=function(e){return{code:"file-too-small",message:"File is smaller than ".concat(e," ").concat(1===e?"byte":"bytes")}},M={code:"too-many-files",message:"Too many files"};function L(e,t){var n="application/x-moz-file"===e.type||(0,A.Z)(e,t);return[n,n?null:R(t)]}function _(e,t,n){if(B(e.size))if(B(t)&&B(n)){if(e.size>n)return[!1,I(n)];if(e.size<t)return[!1,T(t)]}else{if(B(t)&&e.size<t)return[!1,T(t)];if(B(n)&&e.size>n)return[!1,I(n)]}return[!0,null]}function B(e){return null!=e}function K(e){return"function"==typeof e.isPropagationStopped?e.isPropagationStopped():void 0!==e.cancelBubble&&e.cancelBubble}function U(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,(function(e){return"Files"===e||"application/x-moz-file"===e})):!!e.target&&!!e.target.files}function $(e){e.preventDefault()}function W(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return t.some((function(t){return!K(e)&&t&&t.apply(void 0,[e].concat(r)),K(e)}))}}function G(e){return"audio/*"===e||"video/*"===e||"image/*"===e||"text/*"===e||/\w+\/[-+.\w]+/g.test(e)}function H(e){return/^.*\.[\w]+$/.test(e)}var q=["children"],N=["open"],Z=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],Y=["refKey","onChange","onClick"];function J(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i=[],a=!0,c=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){c=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(c)throw o}}return i}}(e,t)||Q(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Q(e,t){if(e){if("string"==typeof e)return V(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?V(e,t):void 0}}function V(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function X(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ee(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?X(Object(n),!0).forEach((function(t){te(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):X(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function te(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ne(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var re=(0,r.forwardRef)((function(e,t){var n=e.children,o=ae(ne(e,q)),i=o.open,a=ne(o,N);return(0,r.useImperativeHandle)(t,(function(){return{open:i}}),[i]),r.createElement(r.Fragment,null,n(ee(ee({},a),{},{open:i})))}));re.displayName="Dropzone";var oe={disabled:!1,getFilesFromEvent:function(e){return a(this,void 0,void 0,(function(){return c(this,(function(t){return d(e)&&d(e.dataTransfer)?[2,g(e.dataTransfer,e.type)]:d(n=e)&&d(n.target)?[2,v(e)]:Array.isArray(e)&&e.every((function(e){return"getFile"in e&&"function"==typeof e.getFile}))?[2,m(e)]:[2,[]];var n}))}))},maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!0,autoFocus:!1};re.defaultProps=oe,re.propTypes={children:i().func,accept:i().objectOf(i().arrayOf(i().string)),multiple:i().bool,preventDropOnDocument:i().bool,noClick:i().bool,noKeyboard:i().bool,noDrag:i().bool,noDragEventsBubbling:i().bool,minSize:i().number,maxSize:i().number,maxFiles:i().number,disabled:i().bool,getFilesFromEvent:i().func,onFileDialogCancel:i().func,onFileDialogOpen:i().func,useFsAccessApi:i().bool,autoFocus:i().bool,onDragEnter:i().func,onDragLeave:i().func,onDragOver:i().func,onDrop:i().func,onDropAccepted:i().func,onDropRejected:i().func,onError:i().func,validator:i().func};var ie={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function ae(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=ee(ee({},oe),e),n=t.accept,o=t.disabled,i=t.getFilesFromEvent,a=t.maxSize,c=t.minSize,u=t.multiple,l=t.maxFiles,s=t.onDragEnter,f=t.onDragLeave,p=t.onDragOver,d=t.onDrop,v=t.onDropAccepted,m=t.onDropRejected,g=t.onFileDialogCancel,y=t.onFileDialogOpen,b=t.useFsAccessApi,h=t.autoFocus,w=t.preventDropOnDocument,D=t.noClick,x=t.noKeyboard,O=t.noDrag,j=t.noDragEventsBubbling,A=t.onError,E=t.validator,C=(0,r.useMemo)((function(){return function(e){if(B(e))return Object.entries(e).reduce((function(e,t){var n=P(t,2),r=n[0],o=n[1];return[].concat(k(e),[r],k(o))}),[]).filter((function(e){return G(e)||H(e)})).join(",")}(n)}),[n]),z=(0,r.useMemo)((function(){return function(e){return B(e)?[{description:"Files",accept:Object.entries(e).filter((function(e){var t=P(e,2),n=t[0],r=t[1],o=!0;return G(n)||(console.warn('Skipped "'.concat(n,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),o=!1),Array.isArray(r)&&r.every(H)||(console.warn('Skipped "'.concat(n,'" because an invalid file extension was provided.')),o=!1),o})).reduce((function(e,t){var n=P(t,2),r=n[0],o=n[1];return F(F({},e),{},S({},r,o))}),{})}]:e}(n)}),[n]),R=(0,r.useMemo)((function(){return"function"==typeof y?y:ue}),[y]),I=(0,r.useMemo)((function(){return"function"==typeof g?g:ue}),[g]),T=(0,r.useRef)(null),q=(0,r.useRef)(null),N=J((0,r.useReducer)(ce,ie),2),X=N[0],re=N[1],ae=X.isFocused,le=X.isFileDialogActive,se=(0,r.useRef)("undefined"!=typeof window&&window.isSecureContext&&b&&"showOpenFilePicker"in window),fe=function(){!se.current&&le&&setTimeout((function(){q.current&&(q.current.files.length||(re({type:"closeDialog"}),I()))}),300)};(0,r.useEffect)((function(){return window.addEventListener("focus",fe,!1),function(){window.removeEventListener("focus",fe,!1)}}),[q,le,I,se]);var pe=(0,r.useRef)([]),de=function(e){T.current&&T.current.contains(e.target)||(e.preventDefault(),pe.current=[])};(0,r.useEffect)((function(){return w&&(document.addEventListener("dragover",$,!1),document.addEventListener("drop",de,!1)),function(){w&&(document.removeEventListener("dragover",$),document.removeEventListener("drop",de))}}),[T,w]),(0,r.useEffect)((function(){return!o&&h&&T.current&&T.current.focus(),function(){}}),[T,h,o]);var ve=(0,r.useCallback)((function(e){A?A(e):console.error(e)}),[A]),me=(0,r.useCallback)((function(e){var t;e.preventDefault(),e.persist(),Fe(e),pe.current=[].concat(function(e){if(Array.isArray(e))return V(e)}(t=pe.current)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||Q(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),[e.target]),U(e)&&Promise.resolve(i(e)).then((function(t){if(!K(e)||j){var n=t.length,r=n>0&&function(e){var t=e.files,n=e.accept,r=e.minSize,o=e.maxSize,i=e.multiple,a=e.maxFiles,c=e.validator;return!(!i&&t.length>1||i&&a>=1&&t.length>a)&&t.every((function(e){var t=P(L(e,n),1)[0],i=P(_(e,r,o),1)[0],a=c?c(e):null;return t&&i&&!a}))}({files:t,accept:C,minSize:c,maxSize:a,multiple:u,maxFiles:l,validator:E});re({isDragAccept:r,isDragReject:n>0&&!r,isDragActive:!0,type:"setDraggedFiles"}),s&&s(e)}})).catch((function(e){return ve(e)}))}),[i,s,ve,j,C,c,a,u,l,E]),ge=(0,r.useCallback)((function(e){e.preventDefault(),e.persist(),Fe(e);var t=U(e);if(t&&e.dataTransfer)try{e.dataTransfer.dropEffect="copy"}catch(e){}return t&&p&&p(e),!1}),[p,j]),ye=(0,r.useCallback)((function(e){e.preventDefault(),e.persist(),Fe(e);var t=pe.current.filter((function(e){return T.current&&T.current.contains(e)})),n=t.indexOf(e.target);-1!==n&&t.splice(n,1),pe.current=t,t.length>0||(re({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),U(e)&&f&&f(e))}),[T,f,j]),be=(0,r.useCallback)((function(e,t){var n=[],r=[];e.forEach((function(e){var t=J(L(e,C),2),o=t[0],i=t[1],u=J(_(e,c,a),2),l=u[0],s=u[1],f=E?E(e):null;if(o&&l&&!f)n.push(e);else{var p=[i,s];f&&(p=p.concat(f)),r.push({file:e,errors:p.filter((function(e){return e}))})}})),(!u&&n.length>1||u&&l>=1&&n.length>l)&&(n.forEach((function(e){r.push({file:e,errors:[M]})})),n.splice(0)),re({acceptedFiles:n,fileRejections:r,type:"setFiles"}),d&&d(n,r,t),r.length>0&&m&&m(r,t),n.length>0&&v&&v(n,t)}),[re,u,C,c,a,l,d,v,m,E]),he=(0,r.useCallback)((function(e){e.preventDefault(),e.persist(),Fe(e),pe.current=[],U(e)&&Promise.resolve(i(e)).then((function(t){K(e)&&!j||be(t,e)})).catch((function(e){return ve(e)})),re({type:"reset"})}),[i,be,ve,j]),we=(0,r.useCallback)((function(){if(se.current){re({type:"openDialog"}),R();var e={multiple:u,types:z};window.showOpenFilePicker(e).then((function(e){return i(e)})).then((function(e){be(e,null),re({type:"closeDialog"})})).catch((function(e){var t;(t=e)instanceof DOMException&&("AbortError"===t.name||t.code===t.ABORT_ERR)?(I(e),re({type:"closeDialog"})):function(e){return e instanceof DOMException&&("SecurityError"===e.name||e.code===e.SECURITY_ERR)}(e)?(se.current=!1,q.current?(q.current.value=null,q.current.click()):ve(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):ve(e)}))}else q.current&&(re({type:"openDialog"}),R(),q.current.value=null,q.current.click())}),[re,R,I,b,be,ve,z,u]),De=(0,r.useCallback)((function(e){T.current&&T.current.isEqualNode(e.target)&&(" "!==e.key&&"Enter"!==e.key&&32!==e.keyCode&&13!==e.keyCode||(e.preventDefault(),we()))}),[T,we]),xe=(0,r.useCallback)((function(){re({type:"focus"})}),[]),Oe=(0,r.useCallback)((function(){re({type:"blur"})}),[]),je=(0,r.useCallback)((function(){D||(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.navigator.userAgent;return function(e){return-1!==e.indexOf("MSIE")||-1!==e.indexOf("Trident/")}(e)||function(e){return-1!==e.indexOf("Edge/")}(e)}()?setTimeout(we,0):we())}),[D,we]),Ae=function(e){return o?null:e},ke=function(e){return x?null:Ae(e)},Ee=function(e){return O?null:Ae(e)},Fe=function(e){j&&e.stopPropagation()},Se=(0,r.useMemo)((function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.refKey,n=void 0===t?"ref":t,r=e.role,i=e.onKeyDown,a=e.onFocus,c=e.onBlur,u=e.onClick,l=e.onDragEnter,s=e.onDragOver,f=e.onDragLeave,p=e.onDrop,d=ne(e,Z);return ee(ee(te({onKeyDown:ke(W(i,De)),onFocus:ke(W(a,xe)),onBlur:ke(W(c,Oe)),onClick:Ae(W(u,je)),onDragEnter:Ee(W(l,me)),onDragOver:Ee(W(s,ge)),onDragLeave:Ee(W(f,ye)),onDrop:Ee(W(p,he)),role:"string"==typeof r&&""!==r?r:"presentation"},n,T),o||x?{}:{tabIndex:0}),d)}}),[T,De,xe,Oe,je,me,ge,ye,he,x,O,o]),Pe=(0,r.useCallback)((function(e){e.stopPropagation()}),[]),Ce=(0,r.useMemo)((function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.refKey,n=void 0===t?"ref":t,r=e.onChange,o=e.onClick,i=ne(e,Y);return ee(ee({},te({accept:C,multiple:u,type:"file",style:{display:"none"},onChange:Ae(W(r,he)),onClick:Ae(W(o,Pe)),tabIndex:-1},n,q)),i)}}),[q,n,u,he,o]);return ee(ee({},X),{},{isFocused:ae&&!o,getRootProps:Se,getInputProps:Ce,rootRef:T,inputRef:q,open:Ae(we)})}function ce(e,t){switch(t.type){case"focus":return ee(ee({},e),{},{isFocused:!0});case"blur":return ee(ee({},e),{},{isFocused:!1});case"openDialog":return ee(ee({},ie),{},{isFileDialogActive:!0});case"closeDialog":return ee(ee({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return ee(ee({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return ee(ee({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections});case"reset":return ee({},ie);default:return e}}function ue(){}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_reports=self.webpackChunk_clickview_reports||[]).push([[647],{19647:(r,e,c)=>{c.r(e),c.d(e,{NotFoundView:()=>o});var t=c(32735),i=c(75250);function o(r){var e=r.error;return t.createElement(i.ErrorView,{error:e})}}}]);
@@ -1,2 +0,0 @@
1
- /*! For license information please see 651-c71a62e4f0-reports.chunk.js.LICENSE.txt */
2
- "use strict";(self.webpackChunk_clickview_reports=self.webpackChunk_clickview_reports||[]).push([[651],{32119:(e,t,r)=>{r.d(t,{G:()=>i});var n=r(32735),a=r(71365);function i(e){var t,r;return t=e,r=a.u.getInstance(t),n.useEffect((function(){return function(){a.u.releaseInstance(t)}})),r}},25925:(e,t,r)=>{var n;r.d(t,{R:()=>n}),function(e){e.Subject="Subject",e.Curriculum="Curriculum",e.StreamableLearning="StreamableLearning"}(n||(n={}))},21750:(e,t,r)=>{r.d(t,{x:()=>d});var n,a=r(97395),i=r(75896);!function(e){e.Playlists="playlists",e.Series="series",e.Videos="videos",e.PinnedVideos="pinnedVideos"}(n||(n={}));var o=r(62803),c=r(78417),l=r(25925);function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var u=function(e){return"subjectpresentationaudiences.id:[".concat(e.join(","),"]")},d={topicsFromAllAvailablePresentations:function(e){var t={filterType:"topics",presentationId:e};return{url:a._.urlBuilder("{gateway}/v1/search/filters",t),publicUrl:a._.urlBuilder("/api/search/filters",t),key:"classification:availableTopics",normalize:!1}},availablePresentations:function(e){var t={type:null==e?void 0:e.toLowerCase()};return{url:a._.urlBuilder("/api/domain/v1/subjects/presentations/available",t),publicUrl:a._.urlBuilder("/api/subjects/presentations/available",t),key:"available:presentations:".concat(e),normalizeOptions:{namespace:"presentation"}}},topLevelTopics:function(e){var t={query:o.v.CLASSIFICATION_COLLECTION,sort:"alphabetical"};return{url:a._.urlBuilder("/api/domain/v1/subjects/presentations/".concat(e,"/classifications"),t),publicUrl:a._.urlBuilder("/api/subjects/presentations/".concat(e,"/classifications"),t),key:"presentation:".concat(e,":classifications")}},presentationById:function(e){return{url:"/api/domain/v1/subjects/presentations/".concat(e),publicUrl:"/api/subjects/presentations/".concat(e),key:"presentation:".concat(e)}},presentationBySlug:function(e,t,r){var n={type:r.toLowerCase(),contentRegion:t};return{url:a._.urlBuilder("/api/subjects/presentations/".concat(e),n),publicUrl:a._.urlBuilder("/api/subjects/presentations/".concat(e),n),key:"current:presentation:".concat(r.toLowerCase(),":").concat(t,":").concat(null!=e?e:""),bootstrapName:"presentation",normalizeOptions:{namespace:"presentation"}}},presentation:function(e,t){var r={type:null==e?void 0:e.toLowerCase()};return{url:a._.urlBuilder("/api/domain/v1/subjects/presentations",r),publicUrl:a._.urlBuilder("/api/subjects/presentations/".concat(t),r),key:"current:presentation".concat(e?":".concat(e.toLowerCase()):"").concat(t?":".concat(t):""),normalizeOptions:{namespace:"presentation"}}},classifications:function(){return{url:a._.urlBuilder("/api/domain/v1/subjects",{query:o.v.CLASSIFICATION_COLLECTION,type:l.R.Subject.toLowerCase()}),publicUrl:a._.urlBuilder("/api/subjects/classifications",{query:o.t.CLASSIFICATION_COLLECTION,type:l.R.Subject.toLowerCase()}),key:"classifications"}},classification:function(e,t,r){return{url:a._.urlBuilder("/api/domain/v1/subjects/".concat(e),{query:o.v.CLASSIFICATION(t)}),publicUrl:a._.urlBuilder("/api/subjects/classifications/".concat(e),{query:o.t.CLASSIFICATION}),key:"classification:".concat(e),error:r}},path:function(e,t){var r={type:t};return{url:a._.urlBuilder("/api/domain/v1/subjects/".concat(e,"/path"),r),publicUrl:"/api/subjects/classifications/".concat(e,"/path"),key:"classification:".concat(e,":path")}},children:function(e){return{url:a._.urlBuilder("/api/domain/v1/subjects/".concat(e,"/children"),{query:o.v.CLASSIFICATION_COLLECTION}),publicUrl:a._.urlBuilder("/api/subjects/classifications/".concat(e,"/children"),{query:o.t.CLASSIFICATION_COLLECTION}),key:"classification:".concat(e,":children")}},videos:function(e,t,r){if(t){var i="limit:100,orderbydesc:timestamp";r.length&&(i+=",".concat(u(r)));var o={query:"{".concat(i,"}(videoCollection),subjectpresentationaudiences{presentationId:").concat(t,"}"),permissionFilterOption:c.r.StripMetadata};return{url:a._.urlBuilder("/api/domain/v1/subjects/".concat(e,"/").concat(n.PinnedVideos),o),publicUrl:a._.urlBuilder("/api/subjects/classifications/".concat(e,"/").concat(n.PinnedVideos),o),key:"classification:".concat(e,":").concat(n.PinnedVideos,":").concat(r.join(":"))}}},playlists:function(e,t,r){if(t){var i="limit:100,orderby:name";r.length&&(i+=",".concat(u(r)));var l={query:"{".concat(i,"}").concat(o.v.PLAYLIST_COLLECTION)+",subjectpresentationaudiences{presentationId:".concat(t,"}"),permissionFilterOption:c.r.StripMetadata};return{url:a._.urlBuilder("/api/domain/v1/subjects/".concat(e,"/").concat(n.Playlists),l),publicUrl:a._.urlBuilder("/api/subjects/classifications/".concat(e,"/").concat(n.Playlists),l),key:"classification:".concat(e,":").concat(n.Playlists,":").concat(r.join(":")),formatData:function(e){var t;if(e)return Object.assign(Object.assign({},e),{data:null===(t=e.data)||void 0===t?void 0:t.filter((function(e){var t;return null===(t=e.cover)||void 0===t?void 0:t.url}))})}}}},series:function(e,t,r){if(t){var i="limit:100";r.length&&(i+=",".concat(u(r)));var l={query:"{".concat(i,"}").concat(o.v.SERIES)+",subjectpresentationaudiences{presentationId:".concat(t,"}"),permissionFilterOption:c.r.StripMetadata};return{url:a._.urlBuilder("/api/domain/v1/subjects/".concat(e,"/").concat(n.Series),l),publicUrl:a._.urlBuilder("/api/subjects/classifications/".concat(e,"/").concat(n.Series),l),key:"classification:".concat(e,":").concat(n.Series,":").concat(r.join(":")),formatData:function(e){var t;if(e)return Object.assign(Object.assign({},e),{data:null===(t=e.data)||void 0===t?void 0:t.filter((function(e){var t;return null===(t=e.tallPoster)||void 0===t?void 0:t.url}))})}}}},curriculumLinks:function(e,t){return{url:a._.urlBuilder("/api/subjects/presentations/".concat(t,"/objects/").concat(e,"/classifications/paths"),{type:l.R.Curriculum.toLowerCase()}),publicUrl:a._.urlBuilder("/api/subjects/presentations/".concat(t,"/objects/").concat(e,"/classifications/paths"),{type:l.R.Curriculum.toLowerCase()}),key:"curriculum:links:".concat(e,":").concat(t),normalize:!1}},checkAllCurriculumsLinks:function(e,t,r){var n={type:l.R.Curriculum.toLowerCase()};return{url:a._.urlBuilder("/api/domain/v1/subjects/objects/".concat(e,"/presentations"),n),publicUrl:a._.urlBuilder("/api/subjects/".concat(e,"/presentations"),Object.assign(Object.assign({},n),{pid:t})),key:"check:all:curriculums:links:".concat(e,":").concat(t.join(",")),success:r,normalize:!1}},hasCurriculumLinks:function(e,t,r,n){var o=i.m.uniq(e).sort(),c=i.m.uniq(t).sort(),u={type:l.R.Curriculum.toLowerCase(),objectId:o};return(null==t?void 0:t.length)&&(u.presentationId=c),{url:a._.urlBuilder("/api/domain/v1/subjects/presentations/objects",u),publicUrl:a._.urlBuilder("/api/subjects/presentations/objects/exists",u),key:"has:curriculum:links:".concat(o.join(":"),":").concat(c.join(":")),normalizeOptions:{namespace:r},formatData:function(e){return Object.entries(e).map((function(e){var t,r,n=(r=2,function(e){if(Array.isArray(e))return e}(t=e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,c=[],l=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(e){s=!0,a=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(s)throw a}}return c}}(t,r)||function(e,t){if(e){if("string"==typeof e)return s(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?s(e,t):void 0}}(t,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}());return{id:n[0],_hasCurriculumLinks:n[1]}}))},success:n}},regionAlternatives:function(e,t,r,n){return{url:"/api/subjects/classifications/".concat(e,"/region-alternatives"),publicUrl:"/api/subjects/classifications/".concat(e,"/region-alternatives"),key:"classification:regionAlternatives:".concat(e),normalize:!1,success:t,error:r,always:n}}}},69883:(e,t,r)=>{r.d(t,{Z:()=>o});var n=r(79976),a=r(60139),i=r(32119);function o(){var e=(0,i.G)(n.P.ALERT);return{success:function(t){e.success(t)()},error:function(t){e.error(t)()},warning:function(t){e.createAlert({type:a.NK.Warning,heading:a.R6.Warning,message:t})}}}},49439:(e,t,r)=>{r.d(t,{X:()=>v,L:()=>h});var n=r(32735),a=r(79014),i=r(1048),o=function(){var e=n.useRef(!0);return n.useEffect((function(){return function(){e.current=!1}}),[]),e};function c(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,c=[],l=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(e){s=!0,a=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(s)throw a}}return c}}(e,t)||function(e,t){if(e){if("string"==typeof e)return l(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?l(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var s=275,u=5,d={className:"",delay:0,style:null},m={screenX:0,screenY:0};function p(e,t){var r;e.current&&(t.className&&(null===(r=e.current.classList)||void 0===r||r.add(t.className)),t.style&&Object.keys(t.style).forEach((function(r){e.current.style[r]=t.style[r]})))}function f(e,t){var r;e.current&&(t.className&&(null===(r=e.current.classList)||void 0===r||r.remove(t.className)),t.style&&Object.keys(t.style).forEach((function(t){e.current.style[t]=null})))}function v(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d,t=o(),r=c(n.useState(e),2),l=r[0],s=r[1],u=c(n.useState(!1),2),m=u[0],v=u[1],h=n.useRef(null);n.useEffect((function(){i.t.isEqual(e,l)||s(e)}),[e]);var g=a.q.throttle((function(){p(h,l),t.current&&v(!0)}),l.delay,{leading:!1}),b=function(){a.q.isFunction(g.cancel)&&g.cancel(),f(h,l),t.current&&v(!1)};return n.useLayoutEffect((function(){var e=h.current;if(e)return e.addEventListener("mouseenter",g),e.addEventListener("mouseleave",b),function(){e.removeEventListener("mouseenter",g),e.removeEventListener("mouseleave",b)}}),[h.current,l]),[h,m]}function h(e){var t=c(n.useState(e),2),r=t[0],o=t[1],l=n.useRef(Object.assign({},m)),d=n.useRef(!1),v=n.useRef(0),h=n.useRef(null),g=c(n.useState(!1),2),b=g[0],y=g[1];function E(){v.current&&(window.clearTimeout(v.current),v.current=0)}function S(){d.current=!0}function I(e){if(d.current){var t,n,a=Object.assign({},l.current);l.current.screenX=e.screenX,l.current.screenY=e.screenY,function(e,t){return Math.abs(e.screenX-t.screenX)>u||Math.abs(e.screenY-t.screenY)>u}(a,e)&&E(),t=function(){p(h,r),y(!0)},n=r.delay||s,v.current||(v.current=window.setTimeout(t,n))}}function O(){E(),f(h,r),d.current=!1,y(!1)}return n.useEffect((function(){i.t.isEqual(e,r)||o(e)}),[e]),n.useLayoutEffect((function(){if(h.current){var e=a.q.throttle(I,25,{leading:!1});return h.current.addEventListener("mouseenter",S),h.current.addEventListener("mousemove",e),h.current.addEventListener("mouseleave",O),function(){h.current&&(h.current.removeEventListener("mouseenter",S),h.current.removeEventListener("mousemove",e),h.current.removeEventListener("mouseleave",O))}}}),[h.current,r]),[h,b]}},67578:(e,t,r)=>{r.r(t),r.d(t,{GiveFeedbackView:()=>qt});var n,a=r(32735),i=r(43823),o=r(53301),c=r.n(o),l=r(39202),s=r(23481),u=r(54150),d=r(32119),m=r(20354),p=r(92582),f=r(65858),v=r(29555),h=r(28046),g=r(33025),b=r(83345),y=r(52003),E=r(60735);!function(e){e[e.Other=0]="Other",e[e.SuggestImprovement=1]="SuggestImprovement",e[e.ReportBug=2]="ReportBug",e[e.RequestVideo=3]="RequestVideo",e[e.RaiseIssue=4]="RaiseIssue",e[e.GivePraise=5]="GivePraise",e[e.Footer=6]="Footer",e[e.RequestLivestream=7]="RequestLivestream"}(n||(n={}));var S=r(25925),I=r(12754),O=r(97395),w={presentationAudiences:function(e,t){var r=t||S.R.Subject.toLowerCase(),n={type:r,presentationId:e};return{bootstrapName:"presentationAudiences",url:O._.urlBuilder("/api/domain/v1/subjects/audiences",n),publicUrl:O._.urlBuilder("/api/subjects/presentation/".concat(e,"/audiences"),n),key:"presentation:audiences:".concat(e,":").concat(r),normalize:!1}},audiencesByPresentationId:function(e){return{url:"/api/domain/v1/subjects/presentations/".concat(e,"/audiences"),publicUrl:O._.urlBuilder("/api/subjects/presentation/".concat(e,"/audiences"),{type:S.R.Subject.toLowerCase(),presentationId:e}),key:"presentation:".concat(e,":audiences"),normalize:!1}}},T=r(21750),j=r(1666),L=r(99940),R={submitFeedback:function(e,t){return{url:"{gateway}/v1/feedback",key:"submit:feedback",type:L.k.POST,data:Object.assign(Object.assign({},e),t)}}},k=r(70145),x=r(31949),A=r(69883);function U(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var N,F=function(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],o="string"==typeof e?i.Radio.channel(e):e;a.useEffect((function(){if(e)return o.on(t,r),function(){e&&o.off(t,r)}}),n)};!function(e){e.AU="cv-ap-southeast-1",e.NZ="cv-ap-southeast-2",e.UK="cv-eu-west-1",e.US="cv-na-west-1"}(N||(N={}));var C=r(86613);function P(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var _,V={getUserInfo:function(e,t){return{id:e.id,username:e.username,email:e.email,userType:e.role===C.i.Admin?"Admin":"Staff",customerId:e.customerId,cvcId:t.crmId,customerName:t.name,instanceRegion:e.instanceRegion,contentRegion:e.contentRegion}},mapInstanceRegionToTag:function(e){switch(e){case N.AU:return"au";case N.NZ:return"nz";case N.UK:return"uk";case N.US:return"us"}},getTags:function(e,t,r,n){var a,i=[t].concat(function(e){if(Array.isArray(e))return P(e)}(a=n)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(a)||function(e,t){if(e){if("string"==typeof e)return P(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?P(e,t):void 0}}(a)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}());i.push(r?"student":"staff"),e.role===C.i.Admin&&i.push("administrator");var o=V.mapInstanceRegionToTag(e.instanceRegion);return o&&i.push(o),i},categorizeFiles:function(e){return e.reduce((function(e,t){var r=t.get("fileInfo");return c().isValidFile(t.get("file"),h.l.VIDEO)?e.videoUrls.push(null==r?void 0:r.url):e.imageUrls.push(null==r?void 0:r.url),e}),{imageUrls:[],videoUrls:[]})}},q=r(11607),B=r(49439);!function(e){e.SUGGEST_IMPROVEMENT="suggestImprovement",e.REPORT_BUG="reportBug",e.REQUEST_VIDEO="requestVideo",e.REQUEST_LIVESTREAM="requestLivestream",e.GIVE_PRAISE="givePraise",e.RAISE_ISSUE="raiseIssue",e.OTHER="other"}(_||(_={}));var M=s.T.encloseNamespace("shared.feedbackFormTitles"),G=function(e){switch(e){case _.SUGGEST_IMPROVEMENT:case _.REPORT_BUG:case _.REQUEST_VIDEO:case _.REQUEST_LIVESTREAM:case _.GIVE_PRAISE:case _.RAISE_ISSUE:case _.OTHER:return M(e)}};function D(e){return D="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},D(e)}function z(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=D(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!=D(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==D(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var W=z(z(z(z(z(z(z({mailSent:"https://image.api.prd.cvnet.io/v2/images/2mZ7L9",mediaPreview:"https://image.api.prd.cvnet.io/v2/images/ageRM0",lightBulb:"https://image.api.prd.cvnet.io/v2/images/Oqg3JN",heartHands:"https://image.api.prd.cvnet.io/v2/images/1ML8Oj",videoAlert:"https://image.api.prd.cvnet.io/v2/images/dq2oMq"},_.REQUEST_VIDEO,{default:"https://image.api.prd.cvnet.io/v2/images/G1YGdn",hover:"https://image.api.prd.cvnet.io/v2/images/K6yPxz"}),_.REQUEST_LIVESTREAM,{default:"https://image.api.prd.cvnet.io/v2/images/G1YGdn",hover:"https://image.api.prd.cvnet.io/v2/images/K6yPxz"}),_.SUGGEST_IMPROVEMENT,{default:"https://image.api.prd.cvnet.io/v2/images/g7aR1l",hover:"https://image.api.prd.cvnet.io/v2/images/zMR0Dk"}),_.RAISE_ISSUE,{default:"https://image.api.prd.cvnet.io/v2/images/5boW78",hover:"https://image.api.prd.cvnet.io/v2/images/m6yRKr"}),_.GIVE_PRAISE,{default:"https://image.api.prd.cvnet.io/v2/images/nE1mdz",hover:"https://image.api.prd.cvnet.io/v2/images/JjEnmR"}),_.REPORT_BUG,{default:"https://image.api.prd.cvnet.io/v2/images/AOdYpo",hover:"https://image.api.prd.cvnet.io/v2/images/yro9NM"}),_.OTHER,{default:"https://image.api.prd.cvnet.io/v2/images/Eoaykj",hover:"https://image.api.prd.cvnet.io/v2/images/wN59Zg"});const H={image:"_2jo0"};function Z(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Q(e){var t,r,n=(t=(0,B.X)(),r=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,c=[],l=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(e){s=!0,a=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(s)throw a}}return c}}(t,r)||function(e,t){if(e){if("string"==typeof e)return Z(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Z(e,t):void 0}}(t,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),i=n[0],o=n[1],c=W[e.option];return a.createElement(q.L,{ref:i,className:"col-lg-4 col-sm-6 col-12",onClick:function(){return e.onSelectOption(e.option)}},a.createElement("div",{className:"d-flex flex-column align-items-center h-100 rounded border py-3 gap-2"},a.createElement("img",{className:H.image,src:o?c.hover:c.default,alt:G(e.option)}),a.createElement("p",{className:"fw-semibold text-center mb-0"},G(e.option))))}function X(e){return a.createElement("div",{className:"row g-2"},e.options.map((function(t){return a.createElement(Q,{key:t,option:t,onSelectOption:e.onSelectOption})})))}var Y=r(92802),K=r(82644),$=r(25691),J=s.T.encloseNamespace("shared.feedbackButtons");function ee(e){var t=(0,K.b)();return a.createElement($.u,null,"form"===e.formStage&&a.createElement(a.Fragment,null,a.createElement($.u.Cancel,{onClick:function(){return e.setSelectedOption(null)},text:J("cancel")}),a.createElement($.u.Submit,{variant:"dark",text:e.submitText||J("submit"),disabled:!t.isValid})),"success"===e.formStage&&a.createElement($.u.Cancel,{variant:"dark",text:J("close"),onClick:e.closePopup}))}const te={successImage:"yp7vQ"};var re=s.T.encloseNamespace("shared.feedbackFormState");function ne(e){return"form"===e.formStage||"error"===e.formStage?a.createElement(a.Fragment,null):a.createElement("div",{className:"text-center"},a.createElement("div",{className:"mb-3"},a.createElement("img",{className:te.successImage,src:e.successImageUrl||W.mailSent})),a.createElement("h4",{className:"mb-3"},e.successHeading||re("successHeading")),a.createElement("p",{className:"mb-3"},e.successDescription||re("successDescription")))}var ae=r(5173),ie=r(1269),oe=s.T.encloseNamespace("shared.feedbackForm"),ce=5e3,le=function(e){switch(e){case"requiredError":return oe(e);case"minCharactersError":return oe(e,{limit:10});case"maxCharactersError":return oe("maxCharactersError",{limit:ce})}},se=function(){return ae.Z_().min(10,le("minCharactersError")).max(ce,le("maxCharactersError"))},ue=s.T.encloseNamespace("shared.feedbackGivePraise"),de={praise:""},me=ae.Ry().shape({praise:se().required(le("requiredError"))}).noUnknown();function pe(){var e=(0,K.b)();return a.createElement(a.Fragment,null,a.createElement(ie.W,{as:"textarea",placeholder:ue("givePraisePlaceholder"),label:ue("givePraiseLabel"),name:"praise",rows:5,value:e.values.praise,showRequiredStar:!0}))}function fe(e){return a.createElement(Tt,Object.assign({},e,{initialValues:Object.assign(Object.assign({},de),e.initialValues),validationSchema:me,successImageUrl:W.heartHands,successHeading:ue("successHeading"),successDescription:ue("successDescription")}),a.createElement(pe,null))}var ve=s.T.encloseNamespace("shared.feedbackOther"),he={feedback:""},ge=ae.Ry().shape({feedback:se().required(le("requiredError"))}).noUnknown();function be(){var e=(0,K.b)();return a.createElement(a.Fragment,null,a.createElement(ie.W,{as:"textarea",placeholder:ve("otherPlaceholder"),label:ve("otherLabel"),name:"feedback",rows:5,value:e.values.feedback,showRequiredStar:!0}))}function ye(e){return a.createElement(Tt,Object.assign({},e,{initialValues:Object.assign(Object.assign({},he),e.initialValues),validationSchema:ge}),a.createElement(be,null))}var Ee=s.T.encloseNamespace("shared.feedbackRaiseIssue"),Se={issue:""},Ie=ae.Ry().shape({issue:se().required(le("requiredError"))}).noUnknown();function Oe(){var e=(0,K.b)();return a.createElement(a.Fragment,null,a.createElement(ie.W,{as:"textarea",placeholder:Ee("raiseIssuePlaceholder"),label:Ee("raiseIssueLabel"),name:"issue",rows:5,value:e.values.issue,showRequiredStar:!0}))}function we(e){return a.createElement(Tt,Object.assign({},e,{initialValues:Object.assign(Object.assign({},Se),e.initialValues),validationSchema:Ie}),a.createElement(Oe,null))}var Te=r(83914);function je(e){return je="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},je(e)}function Le(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=je(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!=je(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==je(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Re,ke=Le(Le(Le(Le({},N.AU,{phone:"02 9509 2600",email:"support@clickview.com.au",website:"https://www.clickviewsupport.com/hc"}),N.UK,{phone:"+44 (0)333 207 6595",email:"info@clickview.co.uk",website:"https://www.clickviewsupport.com/hc"}),N.NZ,{phone:"09 916 1156",email:"support@clickview.co.nz",website:"https://www.clickviewsupport.com/hc"}),N.US,{phone:"+1 312-292-9322",email:"info@clickvieweducation.com",website:"https://www.clickviewsupport.com/hc"}),xe=r(35223),Ae=r(24064);!function(e){e.FileSelect="file-select",e.DragDrop="drag-drop"}(Re||(Re={}));const Ue={fileDrop:"vdCUc",resourcePreview:"tZQbH"};function Ne(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Fe="shared.feedbackFileUpload";function Ce(e){var t=(0,Ae.uI)({onDrop:function(t){return e.onFilesAdded(t,Re.DragDrop)},noClick:!0,noKeyboard:!0,multiple:!!e.acceptMultiple,noDragEventsBubbling:!0}),r=t.getRootProps,n=t.getInputProps,i=t.isDragActive,o=a.useRef(null),c=a.useCallback((function(e){e&&(o.current=e)}),[]),l="".concat(Ue.fileDrop," text-center p-2 rounded-1");return e.uploadError&&(l+=" border-red"),i&&(l+=" border-blue bg-light-blue"),a.createElement(a.Fragment,null,a.createElement("div",Object.assign({},r({className:l})),a.createElement("img",{className:Ue.resourcePreview,src:e.imageUrl,draggable:!1}),a.createElement("div",{className:"position-relative"},i&&a.createElement("p",{className:"position-absolute font-size-md translate-middle top-50 start-50 mb-0"},a.createElement(b.x,{namespace:Fe,phrase:"dropUpload"})),a.createElement("div",{className:i?"opacity-0":""},a.createElement("p",{className:"mb-0"},a.createElement(b.x,{namespace:Fe,phrase:"dragDrop"})),a.createElement("button",{type:"button",className:"btn btn-link text-underline p-0",onClick:function(){o.current.value=null,o.current.click()}},a.createElement(b.x,{namespace:Fe,phrase:"upload"})))),a.createElement("input",{type:"file",className:"file-select d-none",multiple:!!e.acceptMultiple,accept:e.mimeType,ref:c,onChange:function(t){return e.onFilesAdded(function(e){if(Array.isArray(e))return Ne(e)}(r=t.target.files)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||function(e,t){if(e){if("string"==typeof e)return Ne(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ne(e,t):void 0}}(r)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),Re.FileSelect);var r}}),a.createElement("input",Object.assign({},n()))),e.uploadError&&a.createElement("span",{className:"mt-1 d-block invalid-feedback"},e.uploadError))}const Pe={progress:"PeDF6"};function _e(e){var t=100===e.upload.progress;return a.createElement(a.Fragment,null,a.createElement("div",null,a.createElement(Te.x,{svgName:xe.vn.Folder,className:"svg-container me-2"}),a.createElement("span",{className:"align-middle"},e.upload.name),t&&a.createElement(Te.x,{svgName:xe.vn.Check,className:"svg-container float-end text-success"}),!t&&a.createElement("div",{role:"button","aria-label":"close",onClick:function(){return e.cancelUpload(e.upload.id)},className:"float-end description"},a.createElement(Te.x,{svgName:xe.vn.Close}))),a.createElement("div",{className:"".concat(Pe.progress," progress my-2")},a.createElement("div",{className:"progress-bar bg-blue",role:"progressbar",style:{width:"".concat(e.upload.progress,"%")},"aria-valuenow":e.upload.progress,"aria-valuemin":0,"aria-valuemax":100})))}function Ve(e){var t;return(null===(t=e.uploads)||void 0===t?void 0:t.length)?a.createElement(a.Fragment,null,e.uploads.map((function(t,r){return a.createElement(_e,{key:r,upload:t,cancelUpload:e.cancelUpload})}))):a.createElement(a.Fragment,null)}function qe(e){return a.createElement("div",{className:"bg-gray-100 rounded p-2"},a.createElement(Te.x,{className:"d-inline-block align-middle svg-container icon-purple me-2",svgName:xe.vn.FileImg}),a.createElement("span",{className:"align-middle"},e.file.get("name")),a.createElement("button",{className:"btn p-0 border-0 float-end",onClick:function(){return e.deleteFile(e.file.get("id"))}},a.createElement(Te.x,{svgName:xe.vn.Delete})))}function Be(e){return a.createElement("div",{className:"d-flex flex-column gap-2"},e.uploadedFiles.map((function(t){return a.createElement(qe,{key:t.id,file:t,deleteFile:e.deleteFile})})))}var Me=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(n=Object.getOwnPropertySymbols(e);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(e,n[a])&&(r[n[a]]=e[n[a]])}return r},Ge="shared.feedbackReportBug",De=s.T.encloseNamespace(Ge),ze={issue:"",stepsToReproduce:""},We=ae.Ry().shape({issue:se().required(le("requiredError")),stepsToReproduce:se()}).noUnknown();function He(e){var t=(0,K.b)();return a.createElement(a.Fragment,null,a.createElement("div",{className:"form-group"},a.createElement("label",{className:"form-label mb-1"},a.createElement(b.x,{namespace:Ge,phrase:"mixedMediaLabel"})),a.createElement("p",{className:"text-secondary font-size-sm"},a.createElement(b.x,{namespace:Ge,phrase:"mixedMediaDescription"})),a.createElement("div",{className:"mb-3"},a.createElement(Ce,{mimeType:h.l.MIXED_MEDIA,onFilesAdded:e.onFilesAdded,imageUrl:e.previewImageUrl,uploadError:e.uploadError,acceptMultiple:!0})),a.createElement(Ve,{uploads:e.uploadingFiles,cancelUpload:e.cancelUpload}),a.createElement(Be,{uploadedFiles:e.uploadedFiles,deleteFile:e.deleteFile})),a.createElement(ie.W,{as:"textarea",placeholder:De("issuePlaceholder"),label:De("issueLabel"),name:"issue",value:t.values.issue,showRequiredStar:!0}),a.createElement(ie.W,{as:"textarea",placeholder:De("stepsPlaceholder"),label:De("stepsLabel"),name:"stepsToReproduce",value:t.values.stepsToReproduce}),a.createElement("div",{className:"rounded bg-light-yellow p-2 mb-3"},a.createElement("p",{className:"fw-semibold mb-2"},a.createElement(b.x,{namespace:Ge,phrase:"help"})),a.createElement("div",{className:"d-flex gap-1 mb-2"},a.createElement(Te.x,{svgName:xe.vn.Link}),a.createElement("a",{href:ke[e.instanceRegion].website,target:"_blank",className:"text-underline"},a.createElement(b.x,{namespace:Ge,phrase:"visitHelpCentre"}))),a.createElement("p",{className:"mb-2"},a.createElement(b.x,{namespace:Ge,phrase:"supportTeam"})),a.createElement("div",{className:"d-flex gap-1 mb-2"},a.createElement(Te.x,{svgName:xe.vn.Phone}),a.createElement("span",null,ke[e.instanceRegion].phone)),a.createElement("div",{className:"d-flex gap-1 mb-2"},a.createElement(Te.x,{svgName:xe.vn.Email}),a.createElement("span",null,ke[e.instanceRegion].email))))}function Ze(e){var t=e.onFilesAdded,r=e.cancelUpload,n=e.uploadingFiles,i=e.uploadedFiles,o=e.deleteFile,c=Me(e,["onFilesAdded","cancelUpload","uploadingFiles","uploadedFiles","deleteFile"]);return a.createElement(Tt,Object.assign({},c,{initialValues:Object.assign(Object.assign({},ze),e.initialValues),validationSchema:We,submitText:De("submit")}),a.createElement(He,{onFilesAdded:t,previewImageUrl:W.mediaPreview,cancelUpload:r,uploadingFiles:n,uploadedFiles:i,deleteFile:o,uploadError:e.uploadError,instanceRegion:e.instanceRegion}))}var Qe=r(75896),Xe=r(15600),Ye=r(37793),Ke=r(29679),$e="shared.feedbackRequestLivestream",Je=s.T.encloseNamespace($e),et={topic:"",studentLevel:[],producerCompany:"",additionalInfo:""},tt=ae.Z_().max(ce,le("maxCharactersError")),rt=ae.Ry().shape({producerCompany:tt.required((function(){return Je("companyError")})),topic:tt,studentLevel:ae.IX(ae.Z_()),additionalInfo:se()}).noUnknown();function nt(e){var t=(0,K.b)(),r=t.values.studentLevel.map((function(t){return e.audiences.find((function(e){return e.masterId.toString()===t.toString()}))}))||[];function n(e){t.setFieldValue("studentLevel",Qe.m.addOrRemoveImmutable(t.values.studentLevel,e.masterId.toString())),requestAnimationFrame((function(){return t.setFieldTouched("studentLevel")}))}return a.createElement(a.Fragment,null,a.createElement(ie.W,{placeholder:Je("companyPlaceholder"),label:Je("companyLabel"),name:"producerCompany",value:t.values.producerCompany,showRequiredStar:!0}),a.createElement(ie.W,{placeholder:Je("topicPlaceholder"),label:Je("topicLabel"),name:"topic",value:t.values.topic}),a.createElement("div",{className:"form-group"},a.createElement("label",{className:"form-label"},a.createElement(b.x,{namespace:$e,phrase:"audiencesLabel"})),a.createElement(Ye.R,{placeholder:Je("audiencesPlaceholder"),local:e.audiences,valueKey:"masterId",selections:r,onSuggestionSelected:n,removeSelection:function(e){return n(e)},errorStateImageUrl:null,emptyStateImageUrl:null,activationLength:0,suggestionLimit:!1,getInputTokenComponent:function(e){return a.createElement(Xe.D,{key:e.masterId,selection:{name:e.name,masterId:e.masterId},colourVariant:"teal",onClickRemove:function(e){return n(e)},hideExpander:!0})},getSuggestionComponent:function(e){return(0,Ke.Go)("name",e)},onSuggestionDependencies:[e.audiences,t.values.studentLevel,r],getLocalSuggestions:function(e,t){var n=t.find((function(t){return t.name===e}));return(0,Ke.Zo)(n?"":e,t,"name",0).filter((function(e){return!r.find((function(t){return t.masterId===e.masterId}))&&e.masterId!==(null==n?void 0:n.masterId)}))},focusInputOnSuggestionClick:!1,renderAsForm:!1,hideIcon:!0,onBlur:function(){return t.setFieldTouched("studentLevel")},className:"p-2 ".concat(t.touched.studentLevel&&t.errors.studentLevel?"is-invalid":"")}),t.touched.studentLevel&&t.errors.studentLevel&&a.createElement("span",{className:"invalid-feedback"},t.errors.studentLevel)),a.createElement(ie.W,{as:"textarea",placeholder:Je("otherPlaceholder"),label:Je("otherLabel"),name:"additionalInfo",value:t.values.additionalInfo}))}function at(e){return a.createElement(Tt,Object.assign({},e,{initialValues:Object.assign(Object.assign({},et),e.initialValues),validationSchema:rt}),a.createElement(nt,{audiences:e.audiences}))}const it={image:"SdHLR"};function ot(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var ct="shared.feedbackBeforeRequesting",lt=s.T.encloseNamespace(ct);function st(e){var t,r,n=(t=a.useState(!1),r=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,c=[],l=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(e){s=!0,a=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(s)throw a}}return c}}(t,r)||function(e,t){if(e){if("string"==typeof e)return ot(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ot(e,t):void 0}}(t,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),i=n[0],o=n[1];return a.createElement(a.Fragment,null,a.createElement("div",{className:"d-flex flex-column align-items-center my-4"},a.createElement("img",{className:"".concat(it.image," mb-3"),src:W.videoAlert}),a.createElement("h4",{className:"mb-3"},a.createElement(b.x,{namespace:ct,phrase:"beforeRequesting"})),a.createElement("p",null,a.createElement(b.x,{namespace:ct,phrase:"haveYouSearched",options:{exchangeUrl:"".concat(e.exchangeTvUrl,"/exchange")}}))),a.createElement($.u,null,a.createElement($.u.Checkbox,{id:"confirmExchange",checked:i,onToggle:function(){return o(!i)},label:lt("exchangeCheck")}),a.createElement($.u.Cancel,{onClick:function(){return e.setSelectedOption(null)},text:lt("back")}),a.createElement($.u.Submit,{variant:"dark",text:lt("continue"),disabled:!i,onClick:function(){return e.setConfirmed(!0)}})))}function ut(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var dt,mt="shared.feedbackRequestVideo",pt=s.T.encloseNamespace(mt);!function(e){e.VideosTopic="videosTopic",e.VideoOrSeries="videoOrSeries"}(dt||(dt={}));var ft={videoRequestType:"",topic:"",studentLevel:[],videoTitle:"",seriesName:"",producerCompany:"",websiteOrTrailer:"",additionalInfo:""},vt=function(){return ae.Z_().max(ce,le("maxCharactersError"))},ht=ae.Ry().shape({videoRequestType:ae.Z_().required(pt("videoRequestTypeRequiredError")),topic:vt().when("videoRequestType",{is:function(e){return e===dt.VideosTopic},then:vt().required(pt("topicRequiredError")),otherwise:vt().notRequired()}),studentLevel:ae.IX(ae.Z_()),videoTitle:vt().when(["videoRequestType","seriesName"],{is:function(e,t){return e===dt.VideoOrSeries&&!t},then:vt().required(pt("videoRequiredError")),otherwise:vt().notRequired()}),seriesName:vt(),producerCompany:vt(),websiteOrTrailer:vt(),additionalInfo:se()}).noUnknown();function gt(e){var t=(0,K.b)(),r=t.values.studentLevel.map((function(t){var r;return null===(r=e.audiences)||void 0===r?void 0:r.find((function(e){return+e.masterId==+t}))}))||[];function n(e){t.setFieldValue("studentLevel",Qe.m.addOrRemoveImmutable(t.values.studentLevel,e.masterId.toString())),requestAnimationFrame((function(){return t.setFieldTouched("studentLevel")}))}return a.createElement(a.Fragment,null,a.createElement(ie.W,{as:"select",label:pt("videoRequestTypeLabel"),name:"videoRequestType",value:t.values.videoRequestType},a.createElement("option",{value:"",disabled:!0,hidden:!0},pt("videoRequestTypePlaceholder")),a.createElement("option",{value:dt.VideosTopic},pt("videosTopicType")),a.createElement("option",{value:dt.VideoOrSeries},pt("videoOrSeriesType"))),t.values.videoRequestType===dt.VideosTopic&&a.createElement(a.Fragment,null,a.createElement(ie.W,{placeholder:pt("videoTopicPlaceholder"),label:pt("videoTopicLabel"),name:"topic",value:t.values.topic,showRequiredStar:!0}),a.createElement("div",{className:"form-group"},a.createElement("label",{className:"form-label"},a.createElement(b.x,{namespace:mt,phrase:"audiencesLabel"})),a.createElement(Ye.R,{placeholder:pt("audiencesPlaceholder"),local:e.audiences,valueKey:"masterId",selections:r,onSuggestionSelected:n,removeSelection:function(e){return n(e)},errorStateImageUrl:null,emptyStateImageUrl:null,activationLength:0,suggestionLimit:!1,getInputTokenComponent:function(e){return a.createElement(Xe.D,{key:e.masterId,selection:{name:e.name,masterId:e.masterId},colourVariant:"teal",onClickRemove:function(e){return n(e)},hideExpander:!0})},getSuggestionComponent:function(e){return(0,Ke.Go)("name",e)},onSuggestionDependencies:[e.audiences,t.values.studentLevel,r],getLocalSuggestions:function(e,t){var n=t.find((function(t){return t.name===e}));return(0,Ke.Zo)(n?"":e,t,"name",0).filter((function(e){return!r.find((function(t){return t.masterId===e.masterId}))&&e.masterId!==(null==n?void 0:n.masterId)}))},focusInputOnSuggestionClick:!1,renderAsForm:!1,hideIcon:!0,onBlur:function(){return t.setFieldTouched("studentLevel")},className:"p-2 ".concat(t.touched.studentLevel&&t.errors.studentLevel?"is-invalid":"")}),t.touched.studentLevel&&t.errors.studentLevel&&a.createElement("span",{className:"invalid-feedback"},t.errors.studentLevel)),a.createElement(ie.W,{as:"textarea",placeholder:pt("otherPlaceholder"),label:pt("otherLabel"),name:"additionalInfo",value:t.values.additionalInfo})),t.values.videoRequestType===dt.VideoOrSeries&&a.createElement(a.Fragment,null,a.createElement(ie.W,{placeholder:pt("videoTitlePlaceholder"),label:pt("videoTitleLabel"),name:"videoTitle",value:t.values.videoTitle}),a.createElement(ie.W,{placeholder:pt("seriesPlaceholder"),label:pt("seriesLabel"),name:"seriesName",value:t.values.seriesName}),a.createElement(ie.W,{placeholder:pt("companyPlaceholder"),label:pt("companyLabel"),name:"producerCompany",value:t.values.producerCompany}),a.createElement(ie.W,{placeholder:pt("videoTopicPlaceholder"),label:pt("topicLabel"),name:"topic",value:t.values.topic}),a.createElement(ie.W,{placeholder:pt("websiteOrTrailerPlaceholder"),label:pt("websiteOrTrailerLabel"),name:"websiteOrTrailer",value:t.values.websiteOrTrailer}),a.createElement(ie.W,{as:"textarea",placeholder:pt("otherPlaceholder"),label:pt("otherLabel"),name:"additionalInfo",value:t.values.additionalInfo})))}function bt(e){var t,r,n=(t=a.useState(!1),r=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,c=[],l=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(e){s=!0,a=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(s)throw a}}return c}}(t,r)||function(e,t){if(e){if("string"==typeof e)return ut(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ut(e,t):void 0}}(t,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),i=n[0],o=n[1],c=e.hasExchangeTvProduct&&!i;return a.createElement(Tt,Object.assign({},e,{initialValues:Object.assign(Object.assign({},ft),e.initialValues),validationSchema:ht,hideButtons:e.hasExchangeTvProduct&&!i}),c&&a.createElement(st,{setConfirmed:o,setSelectedOption:e.setSelectedOption,exchangeTvUrl:e.exchangeTvUrl}),!c&&a.createElement(gt,{audiences:e.audiences}))}var yt="shared.feedbackSuggestImprovement",Et=s.T.encloseNamespace(yt),St={suggestion:"",importance:""},It=ae.Ry().shape({suggestion:se().required(le("requiredError")),importance:se()}).noUnknown();function Ot(e){var t=(0,K.b)();return a.createElement(a.Fragment,null,a.createElement(ie.W,{as:"textarea",placeholder:Et("suggestionPlaceholder"),label:Et("suggestionLabel"),name:"suggestion",value:t.values.suggestion,showRequiredStar:!0}),a.createElement(ie.W,{as:"textarea",placeholder:Et("whySuggestionPlaceholder"),label:Et("whySuggestionLabel"),name:"importance",rows:5,value:t.values.importance}),a.createElement("p",null,a.createElement(b.x,{namespace:yt,phrase:"contactSupport"})," ",a.createElement("button",{className:"btn btn-link text-underline p-0",onClick:function(){return e.setSelectedOption(_.RAISE_ISSUE)}},a.createElement(b.x,{namespace:yt,phrase:"raiseIssue"}))))}function wt(e){return a.createElement(Tt,Object.assign({},e,{initialValues:Object.assign(Object.assign({},St),e.initialValues),validationSchema:It,successImageUrl:W.lightBulb,successHeading:Et("successHeading"),successDescription:Et("successDescription")}),a.createElement(Ot,{setSelectedOption:e.setSelectedOption}))}function Tt(e){var t=a.useRef(null);return a.createElement(K.n,{onSubmit:e.onSubmit,initialValues:e.initialValues,validationSchema:e.validationSchema,validateOnMount:!0,innerRef:t},a.createElement(Y.l0,null,"form"===e.formStage&&e.children,a.createElement(ne,{formStage:e.formStage,successImageUrl:e.successImageUrl,successHeading:e.successHeading,successDescription:e.successDescription}),!e.hideButtons&&a.createElement(ee,{setSelectedOption:function(r){e.setFormState((function(e){var r;return Object.assign(Object.assign({},e),null===(r=t.current)||void 0===r?void 0:r.values)})),e.setSelectedOption(r)},submitText:e.submitText,formStage:e.formStage,closePopup:e.closePopup})))}function jt(e){var t={formStage:e.formStage,initialValues:e.initialValues,setFormState:e.setFormState,onSubmit:e.onSubmit,setSelectedOption:e.setSelectedOption,closePopup:e.closePopup};switch(e.selectedOption){case _.SUGGEST_IMPROVEMENT:return a.createElement(wt,Object.assign({},t));case _.REPORT_BUG:return a.createElement(Ze,Object.assign({},t,{onFilesAdded:e.onFilesAdded,cancelUpload:e.cancelUpload,uploadingFiles:e.uploadingFiles,uploadedFiles:e.uploadedFiles,deleteFile:e.deleteFile,uploadError:e.uploadError,instanceRegion:e.instanceRegion}));case _.REQUEST_VIDEO:return a.createElement(bt,Object.assign({},t,{audiences:e.audiences,hasExchangeTvProduct:e.hasExchangeTvProduct,exchangeTvUrl:e.exchangeTvUrl}));case _.REQUEST_LIVESTREAM:return a.createElement(at,Object.assign({},t,{audiences:e.audiences}));case _.RAISE_ISSUE:return a.createElement(we,Object.assign({},t));case _.GIVE_PRAISE:return a.createElement(fe,Object.assign({},t));case _.OTHER:return a.createElement(ye,Object.assign({},t))}}function Lt(e){return Lt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Lt(e)}function Rt(){Rt=function(){return t};var e,t={},r=Object.prototype,n=r.hasOwnProperty,a=Object.defineProperty||function(e,t,r){e[t]=r.value},i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function s(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{s({},"")}catch(e){s=function(e,t,r){return e[t]=r}}function u(e,t,r,n){var i=t&&t.prototype instanceof g?t:g,o=Object.create(i.prototype),c=new x(n||[]);return a(o,"_invoke",{value:j(e,r,c)}),o}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=u;var m="suspendedStart",p="suspendedYield",f="executing",v="completed",h={};function g(){}function b(){}function y(){}var E={};s(E,o,(function(){return this}));var S=Object.getPrototypeOf,I=S&&S(S(A([])));I&&I!==r&&n.call(I,o)&&(E=I);var O=y.prototype=g.prototype=Object.create(E);function w(e){["next","throw","return"].forEach((function(t){s(e,t,(function(e){return this._invoke(t,e)}))}))}function T(e,t){function r(a,i,o,c){var l=d(e[a],e,i);if("throw"!==l.type){var s=l.arg,u=s.value;return u&&"object"==Lt(u)&&n.call(u,"__await")?t.resolve(u.__await).then((function(e){r("next",e,o,c)}),(function(e){r("throw",e,o,c)})):t.resolve(u).then((function(e){s.value=e,o(s)}),(function(e){return r("throw",e,o,c)}))}c(l.arg)}var i;a(this,"_invoke",{value:function(e,n){function a(){return new t((function(t,a){r(e,n,t,a)}))}return i=i?i.then(a,a):a()}})}function j(t,r,n){var a=m;return function(i,o){if(a===f)throw Error("Generator is already running");if(a===v){if("throw"===i)throw o;return{value:e,done:!0}}for(n.method=i,n.arg=o;;){var c=n.delegate;if(c){var l=L(c,n);if(l){if(l===h)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(a===m)throw a=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);a=f;var s=d(t,r,n);if("normal"===s.type){if(a=n.done?v:p,s.arg===h)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(a=v,n.method="throw",n.arg=s.arg)}}}function L(t,r){var n=r.method,a=t.iterator[n];if(a===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,L(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),h;var i=d(a,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,h;var o=i.arg;return o?o.done?(r[t.resultName]=o.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,h):o:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,h)}function R(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function k(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function x(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(R,this),this.reset(!0)}function A(t){if(t||""===t){var r=t[o];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var a=-1,i=function r(){for(;++a<t.length;)if(n.call(t,a))return r.value=t[a],r.done=!1,r;return r.value=e,r.done=!0,r};return i.next=i}}throw new TypeError(Lt(t)+" is not iterable")}return b.prototype=y,a(O,"constructor",{value:y,configurable:!0}),a(y,"constructor",{value:b,configurable:!0}),b.displayName=s(y,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===b||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,y):(e.__proto__=y,s(e,l,"GeneratorFunction")),e.prototype=Object.create(O),e},t.awrap=function(e){return{__await:e}},w(T.prototype),s(T.prototype,c,(function(){return this})),t.AsyncIterator=T,t.async=function(e,r,n,a,i){void 0===i&&(i=Promise);var o=new T(u(e,r,n,a),i);return t.isGeneratorFunction(r)?o:o.next().then((function(e){return e.done?e.value:o.next()}))},w(O),s(O,l,"Generator"),s(O,o,(function(){return this})),s(O,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=A,x.prototype={constructor:x,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(k),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function a(n,a){return c.type="throw",c.arg=t,r.next=n,a&&(r.method="next",r.arg=e),!!a}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],c=o.completion;if("root"===o.tryLoc)return a("end");if(o.tryLoc<=this.prev){var l=n.call(o,"catchLoc"),s=n.call(o,"finallyLoc");if(l&&s){if(this.prev<o.catchLoc)return a(o.catchLoc,!0);if(this.prev<o.finallyLoc)return a(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return a(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return a(o.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var i=a;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var o=i?i.completion:{};return o.type=e,o.arg=t,i?(this.method="next",this.next=i.finallyLoc,h):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),h},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),k(r),h}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var a=n.arg;k(r)}return a}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:A(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),h}},t}function kt(e){return function(e){if(Array.isArray(e))return Ut(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||At(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function xt(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,c=[],l=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(e){s=!0,a=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(s)throw a}}return c}}(e,t)||At(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function At(e,t){if(e){if("string"==typeof e)return Ut(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ut(e,t):void 0}}function Ut(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Nt=function(e,t,r,n){return new(r||(r=Promise))((function(a,i){function o(e){try{l(n.next(e))}catch(e){i(e)}}function c(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?a(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(o,c)}l((n=n.apply(e,t||[])).next())}))},Ft="shared.giveFeedback",Ct=s.T.encloseNamespace(Ft),Pt=5,_t=60,Vt=1e6;function qt(e){var t,r,o=(0,A.Z)(),s=(0,u.useGetFetchAsync)(),O=m.a.useBasicFetch(x.N.currentUser()),L=m.a.useBasicFetch(O.data&&j.h.customer(O.data.customerId)),N=m.a.useBasicFetch(O.data&&x.N.user(O.data.id)),C=xt(a.useState(null),2),P=C[0],q=C[1],B=xt(a.useState("form"),2),M=B[0],D=B[1],z=xt(a.useState(null),2),W=z[0],H=z[1],Z=(0,d.G)(E.D.MixedMediaUpload),Q=function(e,t){var r,n,i,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],c=(n=a.useState(!1),i=2,function(e){if(Array.isArray(e))return e}(n)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,a,i,o,c=[],l=!0,s=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(e){s=!0,a=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(s)throw a}}return c}}(n,i)||function(e,t){if(e){if("string"==typeof e)return U(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?U(e,t):void 0}}(n,i)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[1];return a.useEffect((function(){var r=e();if(r)return r.off("add remove change"),r.on("add remove change",(function(){c((function(e){return!e}))})),t&&r.on("remove",t),function(){r.off("add remove change")}}),o),null===(r=e())||void 0===r?void 0:r.toJSON()}((function(){return Z.getCollection()}),null),Y=a.useRef(),K=a.useRef(0),$=a.useRef([]),J=xt(a.useState([]),2),ee=J[0],te=J[1],re=xt(a.useState(""),2),ne=re[0],ae=re[1],ie=e.product===I.x.StreamableLearning?S.R.StreamableLearning:S.R.Subject,oe=m.a.useBasicFetch(T.x.presentation(ie)),ce=m.a.useBasicFetch(w.presentationAudiences(null,ie)),le=null===(t=m.a.useBasicFetch(k.h.userProducts()).data)||void 0===t?void 0:t.find((function(e){return e.id===I.x.Exchange}));function se(e){q(e),e&&p.k.logUserAction({type:e},{actionType:f.Vw.Click,entity:f.py.Feedback,location:f.LZ.GiveFeedbackPopup,workflowPhase:f.eu.Start})}function ue(e){switch(e){case _.SUGGEST_IMPROVEMENT:return n.SuggestImprovement;case _.REPORT_BUG:return n.ReportBug;case _.REQUEST_VIDEO:return n.RequestVideo;case _.REQUEST_LIVESTREAM:return n.RequestLivestream;case _.GIVE_PRAISE:return n.GivePraise;case _.RAISE_ISSUE:return n.RaiseIssue;case _.OTHER:return n.Other}}return F(i.Radio.channel(y.Q4.MIXED_MEDIA_UPLOAD),v.S.UPLOAD_COMPLETE,(function(e){var t=e.toJSON();if($.current.push(t),K.current--,!(K.current>0)){var r=$.current.length;$.current.forEach((function(e){setTimeout((function(){r--;var t=Z.getCollection().filter((function(t){var r;return(null===(r=t.get("fileInfo"))||void 0===r?void 0:r.id)===e.fileInfo.id}));Z.getCollection().remove(t),te((function(e){return[].concat(kt(e),kt(t))})),r>0||(p.k.logUserAction({fileInfo:e.fileInfo},{location:f.LZ.GiveFeedbackPopup,actionType:f.Vw.Upload,entity:f.py.MixedMedia,descriptor:p.k.mapInteractionType(Y.current)}),o.success(Ct("mixedMediaUploadSuccess")))}))})),$.current=[]}})),a.createElement(g.G,{size:"lg",title:P?G(P):Ct("title"),closePopup:e.closePopup,backdrop:"static"},!P&&a.createElement("p",null,a.createElement(b.x,{namespace:Ft,phrase:"description"})),!P&&a.createElement(X,{onSelectOption:se,options:[_.SUGGEST_IMPROVEMENT,_.REPORT_BUG,e.product===I.x.StreamableLearning?_.REQUEST_LIVESTREAM:_.REQUEST_VIDEO,_.GIVE_PRAISE,_.RAISE_ISSUE,_.OTHER]}),P&&a.createElement(jt,{selectedOption:P,formStage:M,onSubmit:function(t,r){var n,a,i,c,u,d;return Nt(this,void 0,void 0,Rt().mark((function m(){var v,h;return Rt().wrap((function(m){for(;;)switch(m.prev=m.next){case 0:return v={type:ue(P),user:V.getUserInfo(O.data,L.data),tags:V.getTags(O.data,e.product,!1,["give feedback",G(P).toLowerCase(),null===(a=null===(n=oe.data)||void 0===n?void 0:n.description)||void 0===a?void 0:a.toLowerCase().trim(),null===(d=null===(u=null===(c=null===(i=N.data)||void 0===i?void 0:i.userProfile)||void 0===c?void 0:c.metadata)||void 0===u?void 0:u.jobTitle)||void 0===d?void 0:d.toLowerCase()].filter(Boolean))},h=Object.assign(Object.assign({},t),{currentPageUrl:l.Ab.GetCurrentUrl()}),P===_.REPORT_BUG&&ee.length&&(h=Object.assign(Object.assign({},h),V.categorizeFiles(ee))),m.prev=3,m.next=6,s(R.submitFeedback(v,h));case 6:p.k.logUserAction(Object.assign(Object.assign({},v),h),{actionType:f.Vw.Submit,entity:f.py.Feedback,location:f.LZ.GiveFeedbackPopup,workflowPhase:f.eu.Complete}),D("success"),m.next=13;break;case 10:m.prev=10,m.t0=m.catch(3),o.error(Ct("error"));case 13:return m.prev=13,r(),m.finish(13);case 16:case"end":return m.stop()}}),m,null,[[3,10,13,16]])})))},setSelectedOption:se,closePopup:e.closePopup,onFilesAdded:function(e,t){e.some((function(e){return e.size>_t*Vt}))?ae(Ct("maxFileSizeUploadError",{limit:_t})):e.length>Pt-Q.length?ae(Ct("maxFilesUploadError",{limit:Pt})):e.some((function(e){return!c().isValidFile(e,h.l.MIXED_MEDIA)}))?ae(Ct("invalidTypeUploadError")):(ae(""),K.current+=e.length,t&&(Y.current=t),Z.addFiles(e))},uploadingFiles:Q,uploadedFiles:ee,deleteFile:function(e){te((function(t){return t.filter((function(t){return t.id!==e}))}))},cancelUpload:function(e){return Z.cancelUpload(e)},audiences:ce.data,uploadError:ne,initialValues:W,setFormState:H,instanceRegion:null===(r=O.data)||void 0===r?void 0:r.instanceRegion,hasExchangeTvProduct:!!le,exchangeTvUrl:null==le?void 0:le.url}))}}}]);
@@ -1 +0,0 @@
1
- (self.webpackChunk_clickview_reports=self.webpackChunk_clickview_reports||[]).push([[675],{20455:(e,t,n)=>{"use strict";n.d(t,{LB:()=>Xe,y9:()=>ut,g4:()=>te,Lg:()=>ae,we:()=>de,pE:()=>E,ey:()=>I,VK:()=>M,_8:()=>C,hI:()=>N,Cj:()=>Ke,O1:()=>Ye,Zj:()=>Ze,VT:()=>v,Dy:()=>h});var r=n(32735),o=n(12788),i=n(17592);const a={display:"none"};function l(e){let{id:t,value:n}=e;return r.createElement("div",{id:t,style:a},n)}function s(e){let{id:t,announcement:n,ariaLiveType:o="assertive"}=e;return r.createElement("div",{id:t,style:{position:"fixed",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"},role:"status","aria-live":o,"aria-atomic":!0},n)}const u=(0,r.createContext)(null),c={draggable:"\n To pick up a draggable item, press the space bar.\n While dragging, use the arrow keys to move the item.\n Press space again to drop the item in its new position, or press escape to cancel.\n "},d={onDragStart(e){let{active:t}=e;return"Picked up draggable item "+t.id+"."},onDragOver(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was moved over droppable area "+n.id+".":"Draggable item "+t.id+" is no longer over a droppable area."},onDragEnd(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was dropped over droppable area "+n.id:"Draggable item "+t.id+" was dropped."},onDragCancel(e){let{active:t}=e;return"Dragging was cancelled. Draggable item "+t.id+" was dropped."}};function f(e){let{announcements:t=d,container:n,hiddenTextDescribedById:a,screenReaderInstructions:f=c}=e;const{announce:g,announcement:p}=function(){const[e,t]=(0,r.useState)("");return{announce:(0,r.useCallback)((e=>{null!=e&&t(e)}),[]),announcement:e}}(),v=(0,i.Ld)("DndLiveRegion"),[h,m]=(0,r.useState)(!1);if((0,r.useEffect)((()=>{m(!0)}),[]),function(e){const t=(0,r.useContext)(u);(0,r.useEffect)((()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)}),[e,t])}((0,r.useMemo)((()=>({onDragStart(e){let{active:n}=e;g(t.onDragStart({active:n}))},onDragMove(e){let{active:n,over:r}=e;t.onDragMove&&g(t.onDragMove({active:n,over:r}))},onDragOver(e){let{active:n,over:r}=e;g(t.onDragOver({active:n,over:r}))},onDragEnd(e){let{active:n,over:r}=e;g(t.onDragEnd({active:n,over:r}))},onDragCancel(e){let{active:n,over:r}=e;g(t.onDragCancel({active:n,over:r}))}})),[g,t])),!h)return null;const y=r.createElement(r.Fragment,null,r.createElement(l,{id:a,value:f.draggable}),r.createElement(s,{id:v,announcement:p}));return n?(0,o.createPortal)(y,n):y}var g;function p(){}function v(e,t){return(0,r.useMemo)((()=>({sensor:e,options:null!=t?t:{}})),[e,t])}function h(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,r.useMemo)((()=>[...t].filter((e=>null!=e))),[...t])}!function(e){e.DragStart="dragStart",e.DragMove="dragMove",e.DragEnd="dragEnd",e.DragCancel="dragCancel",e.DragOver="dragOver",e.RegisterDroppable="registerDroppable",e.SetDroppableDisabled="setDroppableDisabled",e.UnregisterDroppable="unregisterDroppable"}(g||(g={}));const m=Object.freeze({x:0,y:0});function y(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function b(e,t){const n=(0,i.DC)(e);return n?(n.x-t.left)/t.width*100+"% "+(n.y-t.top)/t.height*100+"%":"0 0"}function w(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return n-r}function R(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return r-n}function x(e){let{left:t,top:n,height:r,width:o}=e;return[{x:t,y:n},{x:t+o,y:n},{x:t,y:n+r},{x:t+o,y:n+r}]}function C(e,t){if(!e||0===e.length)return null;const[n]=e;return t?n[t]:n}function S(e,t,n){return void 0===t&&(t=e.left),void 0===n&&(n=e.top),{x:t+.5*e.width,y:n+.5*e.height}}const E=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=S(t,t.left,t.top),i=[];for(const e of r){const{id:t}=e,r=n.get(t);if(r){const n=y(S(r),o);i.push({id:t,data:{droppableContainer:e,value:n}})}}return i.sort(w)},I=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=x(t),i=[];for(const e of r){const{id:t}=e,r=n.get(t);if(r){const n=x(r),a=o.reduce(((e,t,r)=>e+y(n[r],t)),0),l=Number((a/4).toFixed(4));i.push({id:t,data:{droppableContainer:e,value:l}})}}return i.sort(w)};function P(e,t){const n=Math.max(t.top,e.top),r=Math.max(t.left,e.left),o=Math.min(t.left+t.width,e.left+e.width),i=Math.min(t.top+t.height,e.top+e.height),a=o-r,l=i-n;if(r<o&&n<i){const n=t.width*t.height,r=e.width*e.height,o=a*l;return Number((o/(n+r-o)).toFixed(4))}return 0}const B=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=[];for(const e of r){const{id:r}=e,i=n.get(r);if(i){const n=P(i,t);n>0&&o.push({id:r,data:{droppableContainer:e,value:n}})}}return o.sort(R)};function D(e,t){return e&&t?{x:e.left-t.left,y:e.top-t.top}:m}function k(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce(((t,n)=>({...t,top:t.top+e*n.y,bottom:t.bottom+e*n.y,left:t.left+e*n.x,right:t.right+e*n.x})),{...t})}}const A=k(1);function O(e){if(e.startsWith("matrix3d(")){const t=e.slice(9,-1).split(/, /);return{x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}if(e.startsWith("matrix(")){const t=e.slice(7,-1).split(/, /);return{x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}const F={ignoreTransform:!1};function M(e,t){void 0===t&&(t=F);let n=e.getBoundingClientRect();if(t.ignoreTransform){const{getComputedStyle:t}=(0,i.Jj)(e),{transform:r,transformOrigin:o}=t(e);r&&(n=function(e,t,n){const r=O(t);if(!r)return e;const{scaleX:o,scaleY:i,x:a,y:l}=r,s=e.left-a-(1-o)*parseFloat(n),u=e.top-l-(1-i)*parseFloat(n.slice(n.indexOf(" ")+1)),c=o?e.width/o:e.width,d=i?e.height/i:e.height;return{width:c,height:d,top:u,right:s+c,bottom:u+d,left:s}}(n,r,o))}const{top:r,left:o,width:a,height:l,bottom:s,right:u}=n;return{top:r,left:o,width:a,height:l,bottom:s,right:u}}function T(e){return M(e,{ignoreTransform:!0})}function N(e,t){const n=[];return e?function r(o){if(null!=t&&n.length>=t)return n;if(!o)return n;if((0,i.qk)(o)&&null!=o.scrollingElement&&!n.includes(o.scrollingElement))return n.push(o.scrollingElement),n;if(!(0,i.Re)(o)||(0,i.vZ)(o))return n;if(n.includes(o))return n;const{getComputedStyle:a}=(0,i.Jj)(o),l=a(o);return o!==e&&function(e,t){void 0===t&&(t=(0,i.Jj)(e).getComputedStyle(e));const n=/(auto|scroll|overlay)/;return["overflow","overflowX","overflowY"].some((e=>{const r=t[e];return"string"==typeof r&&n.test(r)}))}(o,l)&&n.push(o),function(e,t){return void 0===t&&(t=(0,i.Jj)(e).getComputedStyle(e)),"fixed"===t.position}(o,l)?n:r(o.parentNode)}(e):n}function G(e){const[t]=N(e,1);return null!=t?t:null}function L(e){return i.Nq&&e?(0,i.FJ)(e)?e:(0,i.UG)(e)?(0,i.qk)(e)||e===(0,i.r3)(e).scrollingElement?window:(0,i.Re)(e)?e:null:null:null}function z(e){return(0,i.FJ)(e)?e.scrollX:e.scrollLeft}function H(e){return(0,i.FJ)(e)?e.scrollY:e.scrollTop}function j(e){return{x:z(e),y:H(e)}}var W;function V(e){return!(!i.Nq||!e)&&e===document.scrollingElement}function X(e){const t={x:0,y:0},n=V(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},r={x:e.scrollWidth-n.width,y:e.scrollHeight-n.height};return{isTop:e.scrollTop<=t.y,isLeft:e.scrollLeft<=t.x,isBottom:e.scrollTop>=r.y,isRight:e.scrollLeft>=r.x,maxScroll:r,minScroll:t}}!function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward"}(W||(W={}));const _={x:.2,y:.2};function q(e,t,n,r,o){let{top:i,left:a,right:l,bottom:s}=n;void 0===r&&(r=10),void 0===o&&(o=_);const{isTop:u,isBottom:c,isLeft:d,isRight:f}=X(e),g={x:0,y:0},p={x:0,y:0},v=t.height*o.y,h=t.width*o.x;return!u&&i<=t.top+v?(g.y=W.Backward,p.y=r*Math.abs((t.top+v-i)/v)):!c&&s>=t.bottom-v&&(g.y=W.Forward,p.y=r*Math.abs((t.bottom-v-s)/v)),!f&&l>=t.right-h?(g.x=W.Forward,p.x=r*Math.abs((t.right-h-l)/h)):!d&&a<=t.left+h&&(g.x=W.Backward,p.x=r*Math.abs((t.left+h-a)/h)),{direction:g,speed:p}}function U(e){if(e===document.scrollingElement){const{innerWidth:e,innerHeight:t}=window;return{top:0,left:0,right:e,bottom:t,width:e,height:t}}const{top:t,left:n,right:r,bottom:o}=e.getBoundingClientRect();return{top:t,left:n,right:r,bottom:o,width:e.clientWidth,height:e.clientHeight}}function Y(e){return e.reduce(((e,t)=>(0,i.IH)(e,j(t))),m)}function K(e,t){if(void 0===t&&(t=M),!e)return;const{top:n,left:r,bottom:o,right:i}=t(e);G(e)&&(o<=0||i<=0||n>=window.innerHeight||r>=window.innerWidth)&&e.scrollIntoView({block:"center",inline:"center"})}const J=[["x",["left","right"],function(e){return e.reduce(((e,t)=>e+z(t)),0)}],["y",["top","bottom"],function(e){return e.reduce(((e,t)=>e+H(t)),0)}]];class ${constructor(e,t){this.rect=void 0,this.width=void 0,this.height=void 0,this.top=void 0,this.bottom=void 0,this.right=void 0,this.left=void 0;const n=N(t),r=Y(n);this.rect={...e},this.width=e.width,this.height=e.height;for(const[e,t,o]of J)for(const i of t)Object.defineProperty(this,i,{get:()=>{const t=o(n),a=r[e]-t;return this.rect[i]+a},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}}class Z{constructor(e){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach((e=>{var t;return null==(t=this.target)?void 0:t.removeEventListener(...e)}))},this.target=e}add(e,t,n){var r;null==(r=this.target)||r.addEventListener(e,t,n),this.listeners.push([e,t,n])}}function Q(e,t){const n=Math.abs(e.x),r=Math.abs(e.y);return"number"==typeof t?Math.sqrt(n**2+r**2)>t:"x"in t&&"y"in t?n>t.x&&r>t.y:"x"in t?n>t.x:"y"in t&&r>t.y}var ee,te;function ne(e){e.preventDefault()}function re(e){e.stopPropagation()}!function(e){e.Click="click",e.DragStart="dragstart",e.Keydown="keydown",e.ContextMenu="contextmenu",e.Resize="resize",e.SelectionChange="selectionchange",e.VisibilityChange="visibilitychange"}(ee||(ee={})),function(e){e.Space="Space",e.Down="ArrowDown",e.Right="ArrowRight",e.Left="ArrowLeft",e.Up="ArrowUp",e.Esc="Escape",e.Enter="Enter"}(te||(te={}));const oe={start:[te.Space,te.Enter],cancel:[te.Esc],end:[te.Space,te.Enter]},ie=(e,t)=>{let{currentCoordinates:n}=t;switch(e.code){case te.Right:return{...n,x:n.x+25};case te.Left:return{...n,x:n.x-25};case te.Down:return{...n,y:n.y+25};case te.Up:return{...n,y:n.y-25}}};class ae{constructor(e){this.props=void 0,this.autoScrollEnabled=!1,this.referenceCoordinates=void 0,this.listeners=void 0,this.windowListeners=void 0,this.props=e;const{event:{target:t}}=e;this.props=e,this.listeners=new Z((0,i.r3)(t)),this.windowListeners=new Z((0,i.Jj)(t)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(ee.Resize,this.handleCancel),this.windowListeners.add(ee.VisibilityChange,this.handleCancel),setTimeout((()=>this.listeners.add(ee.Keydown,this.handleKeyDown)))}handleStart(){const{activeNode:e,onStart:t}=this.props,n=e.node.current;n&&K(n),t(m)}handleKeyDown(e){if((0,i.vd)(e)){const{active:t,context:n,options:r}=this.props,{keyboardCodes:o=oe,coordinateGetter:a=ie,scrollBehavior:l="smooth"}=r,{code:s}=e;if(o.end.includes(s))return void this.handleEnd(e);if(o.cancel.includes(s))return void this.handleCancel(e);const{collisionRect:u}=n.current,c=u?{x:u.left,y:u.top}:m;this.referenceCoordinates||(this.referenceCoordinates=c);const d=a(e,{active:t,context:n.current,currentCoordinates:c});if(d){const t=(0,i.$X)(d,c),r={x:0,y:0},{scrollableAncestors:o}=n.current;for(const n of o){const o=e.code,{isTop:i,isRight:a,isLeft:s,isBottom:u,maxScroll:c,minScroll:f}=X(n),g=U(n),p={x:Math.min(o===te.Right?g.right-g.width/2:g.right,Math.max(o===te.Right?g.left:g.left+g.width/2,d.x)),y:Math.min(o===te.Down?g.bottom-g.height/2:g.bottom,Math.max(o===te.Down?g.top:g.top+g.height/2,d.y))},v=o===te.Right&&!a||o===te.Left&&!s,h=o===te.Down&&!u||o===te.Up&&!i;if(v&&p.x!==d.x){const e=n.scrollLeft+t.x,i=o===te.Right&&e<=c.x||o===te.Left&&e>=f.x;if(i&&!t.y)return void n.scrollTo({left:e,behavior:l});r.x=i?n.scrollLeft-e:o===te.Right?n.scrollLeft-c.x:n.scrollLeft-f.x,r.x&&n.scrollBy({left:-r.x,behavior:l});break}if(h&&p.y!==d.y){const e=n.scrollTop+t.y,i=o===te.Down&&e<=c.y||o===te.Up&&e>=f.y;if(i&&!t.x)return void n.scrollTo({top:e,behavior:l});r.y=i?n.scrollTop-e:o===te.Down?n.scrollTop-c.y:n.scrollTop-f.y,r.y&&n.scrollBy({top:-r.y,behavior:l});break}}this.handleMove(e,(0,i.IH)((0,i.$X)(d,this.referenceCoordinates),r))}}}handleMove(e,t){const{onMove:n}=this.props;e.preventDefault(),n(t)}handleEnd(e){const{onEnd:t}=this.props;e.preventDefault(),this.detach(),t()}handleCancel(e){const{onCancel:t}=this.props;e.preventDefault(),this.detach(),t()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll()}}function le(e){return Boolean(e&&"distance"in e)}function se(e){return Boolean(e&&"delay"in e)}ae.activators=[{eventName:"onKeyDown",handler:(e,t,n)=>{let{keyboardCodes:r=oe,onActivation:o}=t,{active:i}=n;const{code:a}=e.nativeEvent;if(r.start.includes(a)){const t=i.activatorNode.current;return!(t&&e.target!==t||(e.preventDefault(),null==o||o({event:e.nativeEvent}),0))}return!1}}];class ue{constructor(e,t,n){var r;void 0===n&&(n=function(e){const{EventTarget:t}=(0,i.Jj)(e);return e instanceof t?e:(0,i.r3)(e)}(e.event.target)),this.props=void 0,this.events=void 0,this.autoScrollEnabled=!0,this.document=void 0,this.activated=!1,this.initialCoordinates=void 0,this.timeoutId=null,this.listeners=void 0,this.documentListeners=void 0,this.windowListeners=void 0,this.props=e,this.events=t;const{event:o}=e,{target:a}=o;this.props=e,this.events=t,this.document=(0,i.r3)(a),this.documentListeners=new Z(this.document),this.listeners=new Z(n),this.windowListeners=new Z((0,i.Jj)(a)),this.initialCoordinates=null!=(r=(0,i.DC)(o))?r:m,this.handleStart=this.handleStart.bind(this),this.handleMove=this.handleMove.bind(this),this.handleEnd=this.handleEnd.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleKeydown=this.handleKeydown.bind(this),this.removeTextSelection=this.removeTextSelection.bind(this),this.attach()}attach(){const{events:e,props:{options:{activationConstraint:t}}}=this;if(this.listeners.add(e.move.name,this.handleMove,{passive:!1}),this.listeners.add(e.end.name,this.handleEnd),this.windowListeners.add(ee.Resize,this.handleCancel),this.windowListeners.add(ee.DragStart,ne),this.windowListeners.add(ee.VisibilityChange,this.handleCancel),this.windowListeners.add(ee.ContextMenu,ne),this.documentListeners.add(ee.Keydown,this.handleKeydown),t){if(le(t))return;if(se(t))return void(this.timeoutId=setTimeout(this.handleStart,t.delay))}this.handleStart()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),null!==this.timeoutId&&(clearTimeout(this.timeoutId),this.timeoutId=null)}handleStart(){const{initialCoordinates:e}=this,{onStart:t}=this.props;e&&(this.activated=!0,this.documentListeners.add(ee.Click,re,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(ee.SelectionChange,this.removeTextSelection),t(e))}handleMove(e){var t;const{activated:n,initialCoordinates:r,props:o}=this,{onMove:a,options:{activationConstraint:l}}=o;if(!r)return;const s=null!=(t=(0,i.DC)(e))?t:m,u=(0,i.$X)(r,s);if(!n&&l){if(se(l))return Q(u,l.tolerance)?this.handleCancel():void 0;if(le(l))return null!=l.tolerance&&Q(u,l.tolerance)?this.handleCancel():Q(u,l.distance)?this.handleStart():void 0}e.cancelable&&e.preventDefault(),a(s)}handleEnd(){const{onEnd:e}=this.props;this.detach(),e()}handleCancel(){const{onCancel:e}=this.props;this.detach(),e()}handleKeydown(e){e.code===te.Esc&&this.handleCancel()}removeTextSelection(){var e;null==(e=this.document.getSelection())||e.removeAllRanges()}}const ce={move:{name:"pointermove"},end:{name:"pointerup"}};class de extends ue{constructor(e){const{event:t}=e,n=(0,i.r3)(t.target);super(e,ce,n)}}de.activators=[{eventName:"onPointerDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return!(!n.isPrimary||0!==n.button||(null==r||r({event:n}),0))}}];const fe={move:{name:"mousemove"},end:{name:"mouseup"}};var ge;!function(e){e[e.RightClick=2]="RightClick"}(ge||(ge={})),class extends ue{constructor(e){super(e,fe,(0,i.r3)(e.event.target))}}.activators=[{eventName:"onMouseDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return n.button!==ge.RightClick&&(null==r||r({event:n}),!0)}}];const pe={move:{name:"touchmove"},end:{name:"touchend"}};var ve,he;(class extends ue{constructor(e){super(e,pe)}static setup(){return window.addEventListener(pe.move.name,e,{capture:!1,passive:!1}),function(){window.removeEventListener(pe.move.name,e)};function e(){}}}).activators=[{eventName:"onTouchStart",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;const{touches:o}=n;return!(o.length>1||(null==r||r({event:n}),0))}}],function(e){e[e.Pointer=0]="Pointer",e[e.DraggableRect=1]="DraggableRect"}(ve||(ve={})),function(e){e[e.TreeOrder=0]="TreeOrder",e[e.ReversedTreeOrder=1]="ReversedTreeOrder"}(he||(he={}));const me={x:{[W.Backward]:!1,[W.Forward]:!1},y:{[W.Backward]:!1,[W.Forward]:!1}};var ye,be;!function(e){e[e.Always=0]="Always",e[e.BeforeDragging=1]="BeforeDragging",e[e.WhileDragging=2]="WhileDragging"}(ye||(ye={})),function(e){e.Optimized="optimized"}(be||(be={}));const we=new Map;function Re(e,t){return(0,i.Gj)((n=>e?n||("function"==typeof t?t(e):e):null),[t,e])}function xe(e){let{callback:t,disabled:n}=e;const o=(0,i.zX)(t),a=(0,r.useMemo)((()=>{if(n||"undefined"==typeof window||void 0===window.ResizeObserver)return;const{ResizeObserver:e}=window;return new e(o)}),[n]);return(0,r.useEffect)((()=>()=>null==a?void 0:a.disconnect()),[a]),a}function Ce(e){return new $(M(e),e)}function Se(e,t,n){void 0===t&&(t=Ce);const[o,a]=(0,r.useReducer)((function(r){if(!e)return null;var o;if(!1===e.isConnected)return null!=(o=null!=r?r:n)?o:null;const i=t(e);return JSON.stringify(r)===JSON.stringify(i)?r:i}),null),l=function(e){let{callback:t,disabled:n}=e;const o=(0,i.zX)(t),a=(0,r.useMemo)((()=>{if(n||"undefined"==typeof window||void 0===window.MutationObserver)return;const{MutationObserver:e}=window;return new e(o)}),[o,n]);return(0,r.useEffect)((()=>()=>null==a?void 0:a.disconnect()),[a]),a}({callback(t){if(e)for(const n of t){const{type:t,target:r}=n;if("childList"===t&&r instanceof HTMLElement&&r.contains(e)){a();break}}}}),s=xe({callback:a});return(0,i.LI)((()=>{a(),e?(null==s||s.observe(e),null==l||l.observe(document.body,{childList:!0,subtree:!0})):(null==s||s.disconnect(),null==l||l.disconnect())}),[e]),o}const Ee=[];function Ie(e,t){void 0===t&&(t=[]);const n=(0,r.useRef)(null);return(0,r.useEffect)((()=>{n.current=null}),t),(0,r.useEffect)((()=>{const t=e!==m;t&&!n.current&&(n.current=e),!t&&n.current&&(n.current=null)}),[e]),n.current?(0,i.$X)(e,n.current):m}function Pe(e){return(0,r.useMemo)((()=>e?function(e){const t=e.innerWidth,n=e.innerHeight;return{top:0,left:0,right:t,bottom:n,width:t,height:n}}(e):null),[e])}const Be=[];function De(e){if(!e)return null;if(e.children.length>1)return e;const t=e.children[0];return(0,i.Re)(t)?t:e}const ke=[{sensor:de,options:{}},{sensor:ae,options:{}}],Ae={current:{}},Oe={draggable:{measure:T},droppable:{measure:T,strategy:ye.WhileDragging,frequency:be.Optimized},dragOverlay:{measure:M}};class Fe extends Map{get(e){var t;return null!=e&&null!=(t=super.get(e))?t:void 0}toArray(){return Array.from(this.values())}getEnabled(){return this.toArray().filter((e=>{let{disabled:t}=e;return!t}))}getNodeFor(e){var t,n;return null!=(t=null==(n=this.get(e))?void 0:n.node.current)?t:void 0}}const Me={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new Fe,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:p},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:Oe,measureDroppableContainers:p,windowRect:null,measuringScheduled:!1},Te={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:p,draggableNodes:new Map,over:null,measureDroppableContainers:p},Ne=(0,r.createContext)(Te),Ge=(0,r.createContext)(Me);function Le(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new Fe}}}function ze(e,t){switch(t.type){case g.DragStart:return{...e,draggable:{...e.draggable,initialCoordinates:t.initialCoordinates,active:t.active}};case g.DragMove:return e.draggable.active?{...e,draggable:{...e.draggable,translate:{x:t.coordinates.x-e.draggable.initialCoordinates.x,y:t.coordinates.y-e.draggable.initialCoordinates.y}}}:e;case g.DragEnd:case g.DragCancel:return{...e,draggable:{...e.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case g.RegisterDroppable:{const{element:n}=t,{id:r}=n,o=new Fe(e.droppable.containers);return o.set(r,n),{...e,droppable:{...e.droppable,containers:o}}}case g.SetDroppableDisabled:{const{id:n,key:r,disabled:o}=t,i=e.droppable.containers.get(n);if(!i||r!==i.key)return e;const a=new Fe(e.droppable.containers);return a.set(n,{...i,disabled:o}),{...e,droppable:{...e.droppable,containers:a}}}case g.UnregisterDroppable:{const{id:n,key:r}=t,o=e.droppable.containers.get(n);if(!o||r!==o.key)return e;const i=new Fe(e.droppable.containers);return i.delete(n),{...e,droppable:{...e.droppable,containers:i}}}default:return e}}function He(e){let{disabled:t}=e;const{active:n,activatorEvent:o,draggableNodes:a}=(0,r.useContext)(Ne),l=(0,i.D9)(o),s=(0,i.D9)(null==n?void 0:n.id);return(0,r.useEffect)((()=>{if(!t&&!o&&l&&null!=s){if(!(0,i.vd)(l))return;if(document.activeElement===l.target)return;const e=a.get(s);if(!e)return;const{activatorNode:t,node:n}=e;if(!t.current&&!n.current)return;requestAnimationFrame((()=>{for(const e of[t.current,n.current]){if(!e)continue;const t=(0,i.so)(e);if(t){t.focus();break}}}))}}),[o,t,a,s,l]),null}function je(e,t){let{transform:n,...r}=t;return null!=e&&e.length?e.reduce(((e,t)=>t({transform:e,...r})),n):n}const We=(0,r.createContext)({...m,scaleX:1,scaleY:1});var Ve;!function(e){e[e.Uninitialized=0]="Uninitialized",e[e.Initializing=1]="Initializing",e[e.Initialized=2]="Initialized"}(Ve||(Ve={}));const Xe=(0,r.memo)((function(e){var t,n,a,l;let{id:s,accessibility:c,autoScroll:d=!0,children:p,sensors:v=ke,collisionDetection:h=B,measuring:y,modifiers:b,...w}=e;const R=(0,r.useReducer)(ze,void 0,Le),[x,S]=R,[E,I]=function(){const[e]=(0,r.useState)((()=>new Set)),t=(0,r.useCallback)((t=>(e.add(t),()=>e.delete(t))),[e]);return[(0,r.useCallback)((t=>{let{type:n,event:r}=t;e.forEach((e=>{var t;return null==(t=e[n])?void 0:t.call(e,r)}))}),[e]),t]}(),[P,k]=(0,r.useState)(Ve.Uninitialized),O=P===Ve.Initialized,{draggable:{active:F,nodes:T,translate:z},droppable:{containers:H}}=x,X=F?T.get(F):null,_=(0,r.useRef)({initial:null,translated:null}),U=(0,r.useMemo)((()=>{var e;return null!=F?{id:F,data:null!=(e=null==X?void 0:X.data)?e:Ae,rect:_}:null}),[F,X]),K=(0,r.useRef)(null),[J,Z]=(0,r.useState)(null),[Q,ee]=(0,r.useState)(null),te=(0,i.Ey)(w,Object.values(w)),ne=(0,i.Ld)("DndDescribedBy",s),re=(0,r.useMemo)((()=>H.getEnabled()),[H]),oe=(ie=y,(0,r.useMemo)((()=>({draggable:{...Oe.draggable,...null==ie?void 0:ie.draggable},droppable:{...Oe.droppable,...null==ie?void 0:ie.droppable},dragOverlay:{...Oe.dragOverlay,...null==ie?void 0:ie.dragOverlay}})),[null==ie?void 0:ie.draggable,null==ie?void 0:ie.droppable,null==ie?void 0:ie.dragOverlay]));var ie;const{droppableRects:ae,measureDroppableContainers:le,measuringScheduled:se}=function(e,t){let{dragging:n,dependencies:o,config:a}=t;const[l,s]=(0,r.useState)(null),u=null!=l,{frequency:c,measure:d,strategy:f}=a,g=(0,r.useRef)(e),p=function(){switch(f){case ye.Always:return!1;case ye.BeforeDragging:return n;default:return!n}}(),v=(0,i.Ey)(p),h=(0,r.useCallback)((function(e){void 0===e&&(e=[]),v.current||s((t=>t?t.concat(e):e))}),[v]),m=(0,r.useRef)(null),y=(0,i.Gj)((t=>{if(p&&!n)return we;const r=l;if(!t||t===we||g.current!==e||null!=r){const t=new Map;for(let n of e){if(!n)continue;if(r&&r.length>0&&!r.includes(n.id)&&n.rect.current){t.set(n.id,n.rect.current);continue}const e=n.node.current,o=e?new $(d(e),e):null;n.rect.current=o,o&&t.set(n.id,o)}return t}return t}),[e,l,n,p,d]);return(0,r.useEffect)((()=>{g.current=e}),[e]),(0,r.useEffect)((()=>{p||requestAnimationFrame((()=>h()))}),[n,p]),(0,r.useEffect)((()=>{u&&s(null)}),[u]),(0,r.useEffect)((()=>{p||"number"!=typeof c||null!==m.current||(m.current=setTimeout((()=>{h(),m.current=null}),c))}),[c,p,h,...o]),{droppableRects:y,measureDroppableContainers:h,measuringScheduled:u}}(re,{dragging:O,dependencies:[z.x,z.y],config:oe.droppable}),ue=function(e,t){const n=null!==t?e.get(t):void 0,r=n?n.node.current:null;return(0,i.Gj)((e=>{var n;return null===t?null:null!=(n=null!=r?r:e)?n:null}),[r,t])}(T,F),ce=(0,r.useMemo)((()=>Q?(0,i.DC)(Q):null),[Q]),de=function(){const e=!1===(null==J?void 0:J.autoScrollEnabled),t="object"==typeof d?!1===d.enabled:!1===d,n=O&&!e&&!t;return"object"==typeof d?{...d,enabled:n}:{enabled:n}}(),fe=function(e,t){return Re(e,t)}(ue,oe.draggable.measure);!function(e){let{activeNode:t,measure:n,initialRect:o,config:a=!0}=e;const l=(0,r.useRef)(!1),{x:s,y:u}="boolean"==typeof a?{x:a,y:a}:a;(0,i.LI)((()=>{if(!s&&!u||!t)return void(l.current=!1);if(l.current||!o)return;const e=null==t?void 0:t.node.current;if(!e||!1===e.isConnected)return;const r=D(n(e),o);if(s||(r.x=0),u||(r.y=0),l.current=!0,Math.abs(r.x)>0||Math.abs(r.y)>0){const t=G(e);t&&t.scrollBy({top:r.y,left:r.x})}}),[t,s,u,o,n])}({activeNode:F?T.get(F):null,config:de.layoutShiftCompensation,initialRect:fe,measure:oe.draggable.measure});const ge=Se(ue,oe.draggable.measure,fe),pe=Se(ue?ue.parentElement:null),be=(0,r.useRef)({activatorEvent:null,active:null,activeNode:ue,collisionRect:null,collisions:null,droppableRects:ae,draggableNodes:T,draggingNode:null,draggingNodeRect:null,droppableContainers:H,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),Ce=H.getNodeFor(null==(t=be.current.over)?void 0:t.id),Fe=function(e){let{measure:t}=e;const[n,o]=(0,r.useState)(null),a=xe({callback:(0,r.useCallback)((e=>{for(const{target:n}of e)if((0,i.Re)(n)){o((e=>{const r=t(n);return e?{...e,width:r.width,height:r.height}:r}));break}}),[t])}),l=(0,r.useCallback)((e=>{const n=De(e);null==a||a.disconnect(),n&&(null==a||a.observe(n)),o(n?t(n):null)}),[t,a]),[s,u]=(0,i.wm)(l);return(0,r.useMemo)((()=>({nodeRef:s,rect:n,setRef:u})),[n,s,u])}({measure:oe.dragOverlay.measure}),Me=null!=(n=Fe.nodeRef.current)?n:ue,Te=O?null!=(a=Fe.rect)?a:ge:null,Xe=Boolean(Fe.nodeRef.current&&Fe.rect),_e=D(qe=Xe?null:ge,Re(qe));var qe;const Ue=Pe(Me?(0,i.Jj)(Me):null),Ye=function(e){const t=(0,r.useRef)(e),n=(0,i.Gj)((n=>e?n&&n!==Ee&&e&&t.current&&e.parentNode===t.current.parentNode?n:N(e):Ee),[e]);return(0,r.useEffect)((()=>{t.current=e}),[e]),n}(O?null!=Ce?Ce:ue:null),Ke=function(e,t){void 0===t&&(t=M);const[n]=e,o=Pe(n?(0,i.Jj)(n):null),[a,l]=(0,r.useReducer)((function(){return e.length?e.map((e=>V(e)?o:new $(t(e),e))):Be}),Be),s=xe({callback:l});return e.length>0&&a===Be&&l(),(0,i.LI)((()=>{e.length?e.forEach((e=>null==s?void 0:s.observe(e))):(null==s||s.disconnect(),l())}),[e]),a}(Ye),Je=je(b,{transform:{x:z.x-_e.x,y:z.y-_e.y,scaleX:1,scaleY:1},activatorEvent:Q,active:U,activeNodeRect:ge,containerNodeRect:pe,draggingNodeRect:Te,over:be.current.over,overlayNodeRect:Fe.rect,scrollableAncestors:Ye,scrollableAncestorRects:Ke,windowRect:Ue}),$e=ce?(0,i.IH)(ce,z):null,Ze=function(e){const[t,n]=(0,r.useState)(null),o=(0,r.useRef)(e),a=(0,r.useCallback)((e=>{const t=L(e.target);t&&n((e=>e?(e.set(t,j(t)),new Map(e)):null))}),[]);return(0,r.useEffect)((()=>{const t=o.current;if(e!==t){r(t);const i=e.map((e=>{const t=L(e);return t?(t.addEventListener("scroll",a,{passive:!0}),[t,j(t)]):null})).filter((e=>null!=e));n(i.length?new Map(i):null),o.current=e}return()=>{r(e),r(t)};function r(e){e.forEach((e=>{const t=L(e);null==t||t.removeEventListener("scroll",a)}))}}),[a,e]),(0,r.useMemo)((()=>e.length?t?Array.from(t.values()).reduce(((e,t)=>(0,i.IH)(e,t)),m):Y(e):m),[e,t])}(Ye),Qe=Ie(Ze),et=Ie(Ze,[ge]),tt=(0,i.IH)(Je,Qe),nt=Te?A(Te,Je):null,rt=U&&nt?h({active:U,collisionRect:nt,droppableRects:ae,droppableContainers:re,pointerCoordinates:$e}):null,ot=C(rt,"id"),[it,at]=(0,r.useState)(null),lt=function(e,t,n){return{...e,scaleX:t&&n?t.width/n.width:1,scaleY:t&&n?t.height/n.height:1}}(Xe?Je:(0,i.IH)(Je,et),null!=(l=null==it?void 0:it.rect)?l:null,ge),st=(0,r.useCallback)(((e,t)=>{let{sensor:n,options:r}=t;if(null==K.current)return;const i=T.get(K.current);if(!i)return;const a=e.nativeEvent,l=new n({active:K.current,activeNode:i,event:a,options:r,context:be,onStart(e){const t=K.current;if(null==t)return;const n=T.get(t);if(!n)return;const{onDragStart:r}=te.current,i={active:{id:t,data:n.data,rect:_}};(0,o.unstable_batchedUpdates)((()=>{null==r||r(i),k(Ve.Initializing),S({type:g.DragStart,initialCoordinates:e,active:t}),E({type:"onDragStart",event:i})}))},onMove(e){S({type:g.DragMove,coordinates:e})},onEnd:s(g.DragEnd),onCancel:s(g.DragCancel)});function s(e){return async function(){const{active:t,collisions:n,over:r,scrollAdjustedTranslate:i}=be.current;let l=null;if(t&&i){const{cancelDrop:o}=te.current;l={activatorEvent:a,active:t,collisions:n,delta:i,over:r},e===g.DragEnd&&"function"==typeof o&&await Promise.resolve(o(l))&&(e=g.DragCancel)}K.current=null,(0,o.unstable_batchedUpdates)((()=>{S({type:e}),k(Ve.Uninitialized),at(null),Z(null),ee(null);const t=e===g.DragEnd?"onDragEnd":"onDragCancel";if(l){const e=te.current[t];null==e||e(l),E({type:t,event:l})}}))}}(0,o.unstable_batchedUpdates)((()=>{Z(l),ee(e.nativeEvent)}))}),[T]),ut=(0,r.useCallback)(((e,t)=>(n,r)=>{const o=n.nativeEvent,i=T.get(r);if(null!==K.current||!i||o.dndKit||o.defaultPrevented)return;const a={active:i};!0===e(n,t.options,a)&&(o.dndKit={capturedBy:t.sensor},K.current=r,st(n,t))}),[T,st]),ct=function(e,t){return(0,r.useMemo)((()=>e.reduce(((e,n)=>{const{sensor:r}=n;return[...e,...r.activators.map((e=>({eventName:e.eventName,handler:t(e.handler,n)})))]}),[])),[e,t])}(v,ut);!function(e){(0,r.useEffect)((()=>{if(!i.Nq)return;const t=e.map((e=>{let{sensor:t}=e;return null==t.setup?void 0:t.setup()}));return()=>{for(const e of t)null==e||e()}}),e.map((e=>{let{sensor:t}=e;return t})))}(v),(0,i.LI)((()=>{ge&&P===Ve.Initializing&&k(Ve.Initialized)}),[ge,P]),(0,r.useEffect)((()=>{const{onDragMove:e}=te.current,{active:t,activatorEvent:n,collisions:r,over:i}=be.current;if(!t||!n)return;const a={active:t,activatorEvent:n,collisions:r,delta:{x:tt.x,y:tt.y},over:i};(0,o.unstable_batchedUpdates)((()=>{null==e||e(a),E({type:"onDragMove",event:a})}))}),[tt.x,tt.y]),(0,r.useEffect)((()=>{const{active:e,activatorEvent:t,collisions:n,droppableContainers:r,scrollAdjustedTranslate:i}=be.current;if(!e||null==K.current||!t||!i)return;const{onDragOver:a}=te.current,l=r.get(ot),s=l&&l.rect.current?{id:l.id,rect:l.rect.current,data:l.data,disabled:l.disabled}:null,u={active:e,activatorEvent:t,collisions:n,delta:{x:i.x,y:i.y},over:s};(0,o.unstable_batchedUpdates)((()=>{at(s),null==a||a(u),E({type:"onDragOver",event:u})}))}),[ot]),(0,i.LI)((()=>{be.current={activatorEvent:Q,active:U,activeNode:ue,collisionRect:nt,collisions:rt,droppableRects:ae,draggableNodes:T,draggingNode:Me,draggingNodeRect:Te,droppableContainers:H,over:it,scrollableAncestors:Ye,scrollAdjustedTranslate:tt},_.current={initial:Te,translated:nt}}),[U,ue,rt,nt,T,Me,Te,ae,H,it,Ye,tt]),function(e){let{acceleration:t,activator:n=ve.Pointer,canScroll:o,draggingRect:a,enabled:l,interval:s=5,order:u=he.TreeOrder,pointerCoordinates:c,scrollableAncestors:d,scrollableAncestorRects:f,delta:g,threshold:p}=e;const v=function(e){let{delta:t,disabled:n}=e;const r=(0,i.D9)(t);return(0,i.Gj)((e=>{if(n||!r||!e)return me;const o=Math.sign(t.x-r.x),i=Math.sign(t.y-r.y);return{x:{[W.Backward]:e.x[W.Backward]||-1===o,[W.Forward]:e.x[W.Forward]||1===o},y:{[W.Backward]:e.y[W.Backward]||-1===i,[W.Forward]:e.y[W.Forward]||1===i}}}),[n,t,r])}({delta:g,disabled:!l}),[h,m]=(0,i.Yz)(),y=(0,r.useRef)({x:0,y:0}),b=(0,r.useRef)({x:0,y:0}),w=(0,r.useMemo)((()=>{switch(n){case ve.Pointer:return c?{top:c.y,bottom:c.y,left:c.x,right:c.x}:null;case ve.DraggableRect:return a}}),[n,a,c]),R=(0,r.useRef)(null),x=(0,r.useCallback)((()=>{const e=R.current;if(!e)return;const t=y.current.x*b.current.x,n=y.current.y*b.current.y;e.scrollBy(t,n)}),[]),C=(0,r.useMemo)((()=>u===he.TreeOrder?[...d].reverse():d),[u,d]);(0,r.useEffect)((()=>{if(l&&d.length&&w){for(const e of C){if(!1===(null==o?void 0:o(e)))continue;const n=d.indexOf(e),r=f[n];if(!r)continue;const{direction:i,speed:a}=q(e,r,w,t,p);for(const e of["x","y"])v[e][i[e]]||(a[e]=0,i[e]=0);if(a.x>0||a.y>0)return m(),R.current=e,h(x,s),y.current=a,void(b.current=i)}y.current={x:0,y:0},b.current={x:0,y:0},m()}else m()}),[t,x,o,m,l,s,JSON.stringify(w),JSON.stringify(v),h,d,C,f,JSON.stringify(p)])}({...de,delta:z,draggingRect:nt,pointerCoordinates:$e,scrollableAncestors:Ye,scrollableAncestorRects:Ke});const dt=(0,r.useMemo)((()=>({active:U,activeNode:ue,activeNodeRect:ge,activatorEvent:Q,collisions:rt,containerNodeRect:pe,dragOverlay:Fe,draggableNodes:T,droppableContainers:H,droppableRects:ae,over:it,measureDroppableContainers:le,scrollableAncestors:Ye,scrollableAncestorRects:Ke,measuringConfiguration:oe,measuringScheduled:se,windowRect:Ue})),[U,ue,ge,Q,rt,pe,Fe,T,H,ae,it,le,Ye,Ke,oe,se,Ue]),ft=(0,r.useMemo)((()=>({activatorEvent:Q,activators:ct,active:U,activeNodeRect:ge,ariaDescribedById:{draggable:ne},dispatch:S,draggableNodes:T,over:it,measureDroppableContainers:le})),[Q,ct,U,ge,S,ne,T,it,le]);return r.createElement(u.Provider,{value:I},r.createElement(Ne.Provider,{value:ft},r.createElement(Ge.Provider,{value:dt},r.createElement(We.Provider,{value:lt},p)),r.createElement(He,{disabled:!1===(null==c?void 0:c.restoreFocus)})),r.createElement(f,{...c,hiddenTextDescribedById:ne}))})),_e=(0,r.createContext)(null),qe="button",Ue="Droppable";function Ye(e){let{id:t,data:n,disabled:o=!1,attributes:a}=e;const l=(0,i.Ld)(Ue),{activators:s,activatorEvent:u,active:c,activeNodeRect:d,ariaDescribedById:f,draggableNodes:g,over:p}=(0,r.useContext)(Ne),{role:v=qe,roleDescription:h="draggable",tabIndex:m=0}=null!=a?a:{},y=(null==c?void 0:c.id)===t,b=(0,r.useContext)(y?We:_e),[w,R]=(0,i.wm)(),[x,C]=(0,i.wm)(),S=function(e,t){return(0,r.useMemo)((()=>e.reduce(((e,n)=>{let{eventName:r,handler:o}=n;return e[r]=e=>{o(e,t)},e}),{})),[e,t])}(s,t),E=(0,i.Ey)(n);return(0,i.LI)((()=>(g.set(t,{id:t,key:l,node:w,activatorNode:x,data:E}),()=>{const e=g.get(t);e&&e.key===l&&g.delete(t)})),[g,t]),{active:c,activatorEvent:u,activeNodeRect:d,attributes:(0,r.useMemo)((()=>({role:v,tabIndex:m,"aria-disabled":o,"aria-pressed":!(!y||v!==qe)||void 0,"aria-roledescription":h,"aria-describedby":f.draggable})),[o,v,m,y,h,f.draggable]),isDragging:y,listeners:o?void 0:S,node:w,over:p,setNodeRef:R,setActivatorNodeRef:C,transform:b}}function Ke(){return(0,r.useContext)(Ge)}const Je="Droppable",$e={timeout:25};function Ze(e){let{data:t,disabled:n=!1,id:o,resizeObserverConfig:a}=e;const l=(0,i.Ld)(Je),{active:s,dispatch:u,over:c,measureDroppableContainers:d}=(0,r.useContext)(Ne),f=(0,r.useRef)({disabled:n}),p=(0,r.useRef)(!1),v=(0,r.useRef)(null),h=(0,r.useRef)(null),{disabled:m,updateMeasurementsFor:y,timeout:b}={...$e,...a},w=(0,i.Ey)(null!=y?y:o),R=xe({callback:(0,r.useCallback)((()=>{p.current?(null!=h.current&&clearTimeout(h.current),h.current=setTimeout((()=>{d(Array.isArray(w.current)?w.current:[w.current]),h.current=null}),b)):p.current=!0}),[b]),disabled:m||!s}),x=(0,r.useCallback)(((e,t)=>{R&&(t&&(R.unobserve(t),p.current=!1),e&&R.observe(e))}),[R]),[C,S]=(0,i.wm)(x),E=(0,i.Ey)(t);return(0,r.useEffect)((()=>{R&&C.current&&(R.disconnect(),p.current=!1,R.observe(C.current))}),[C,R]),(0,i.LI)((()=>(u({type:g.RegisterDroppable,element:{id:o,key:l,disabled:n,node:C,rect:v,data:E}}),()=>u({type:g.UnregisterDroppable,key:l,id:o}))),[o]),(0,r.useEffect)((()=>{n!==f.current.disabled&&(u({type:g.SetDroppableDisabled,id:o,key:l,disabled:n}),f.current.disabled=n)}),[o,l,n,u]),{active:s,rect:v,isOver:(null==c?void 0:c.id)===o,node:C,over:c,setNodeRef:S}}function Qe(e){let{animation:t,children:n}=e;const[o,a]=(0,r.useState)(null),[l,s]=(0,r.useState)(null),u=(0,i.D9)(n);return n||o||!u||a(u),(0,i.LI)((()=>{if(!l)return;const e=null==o?void 0:o.key,n=null==o?void 0:o.props.id;null!=e&&null!=n?Promise.resolve(t(n,l)).then((()=>{a(null)})):a(null)}),[t,o,l]),r.createElement(r.Fragment,null,n,o?(0,r.cloneElement)(o,{ref:s}):null)}const et={x:0,y:0,scaleX:1,scaleY:1};function tt(e){let{children:t}=e;return r.createElement(Ne.Provider,{value:Te},r.createElement(We.Provider,{value:et},t))}const nt={position:"fixed",touchAction:"none"},rt=e=>(0,i.vd)(e)?"transform 250ms ease":void 0,ot=(0,r.forwardRef)(((e,t)=>{let{as:n,activatorEvent:o,adjustScale:a,children:l,className:s,rect:u,style:c,transform:d,transition:f=rt}=e;if(!u)return null;const g=a?d:{...d,scaleX:1,scaleY:1},p={...nt,width:u.width,height:u.height,top:u.top,left:u.left,transform:i.ux.Transform.toString(g),transformOrigin:a&&o?b(o,u):void 0,transition:"function"==typeof f?f(o):f,...c};return r.createElement(n,{className:s,style:p,ref:t},l)})),it=e=>t=>{let{active:n,dragOverlay:r}=t;const o={},{styles:i,className:a}=e;if(null!=i&&i.active)for(const[e,t]of Object.entries(i.active))void 0!==t&&(o[e]=n.node.style.getPropertyValue(e),n.node.style.setProperty(e,t));if(null!=i&&i.dragOverlay)for(const[e,t]of Object.entries(i.dragOverlay))void 0!==t&&r.node.style.setProperty(e,t);return null!=a&&a.active&&n.node.classList.add(a.active),null!=a&&a.dragOverlay&&r.node.classList.add(a.dragOverlay),function(){for(const[e,t]of Object.entries(o))n.node.style.setProperty(e,t);null!=a&&a.active&&n.node.classList.remove(a.active)}},at={duration:250,easing:"ease",keyframes:e=>{let{transform:{initial:t,final:n}}=e;return[{transform:i.ux.Transform.toString(t)},{transform:i.ux.Transform.toString(n)}]},sideEffects:it({styles:{active:{opacity:"0"}}})};let lt=0;function st(e){return(0,r.useMemo)((()=>{if(null!=e)return lt++,lt}),[e])}const ut=r.memo((e=>{let{adjustScale:t=!1,children:n,dropAnimation:o,style:a,transition:l,modifiers:s,wrapperElement:u="div",className:c,zIndex:d=999}=e;const{activatorEvent:f,active:g,activeNodeRect:p,containerNodeRect:v,draggableNodes:h,droppableContainers:m,dragOverlay:y,over:b,measuringConfiguration:w,scrollableAncestors:R,scrollableAncestorRects:x,windowRect:C}=Ke(),S=(0,r.useContext)(We),E=st(null==g?void 0:g.id),I=je(s,{activatorEvent:f,active:g,activeNodeRect:p,containerNodeRect:v,draggingNodeRect:y.rect,over:b,overlayNodeRect:y.rect,scrollableAncestors:R,scrollableAncestorRects:x,transform:S,windowRect:C}),P=Re(p),B=function(e){let{config:t,draggableNodes:n,droppableContainers:r,measuringConfiguration:o}=e;return(0,i.zX)(((e,a)=>{if(null===t)return;const l=n.get(e);if(!l)return;const s=l.node.current;if(!s)return;const u=De(a);if(!u)return;const{transform:c}=(0,i.Jj)(a).getComputedStyle(a),d=O(c);if(!d)return;const f="function"==typeof t?t:function(e){const{duration:t,easing:n,sideEffects:r,keyframes:o}={...at,...e};return e=>{let{active:i,dragOverlay:a,transform:l,...s}=e;if(!t)return;const u=a.rect.left-i.rect.left,c=a.rect.top-i.rect.top,d={scaleX:1!==l.scaleX?i.rect.width*l.scaleX/a.rect.width:1,scaleY:1!==l.scaleY?i.rect.height*l.scaleY/a.rect.height:1},f={x:l.x-u,y:l.y-c,...d},g=o({...s,active:i,dragOverlay:a,transform:{initial:l,final:f}}),[p]=g,v=g[g.length-1];if(JSON.stringify(p)===JSON.stringify(v))return;const h=null==r?void 0:r({active:i,dragOverlay:a,...s}),m=a.node.animate(g,{duration:t,easing:n,fill:"forwards"});return new Promise((e=>{m.onfinish=()=>{null==h||h(),e()}}))}}(t);return K(s,o.draggable.measure),f({active:{id:e,data:l.data,node:s,rect:o.draggable.measure(s)},draggableNodes:n,dragOverlay:{node:a,rect:o.dragOverlay.measure(u)},droppableContainers:r,measuringConfiguration:o,transform:d})}))}({config:o,draggableNodes:h,droppableContainers:m,measuringConfiguration:w}),D=P?y.setRef:void 0;return r.createElement(tt,null,r.createElement(Qe,{animation:B},g&&E?r.createElement(ot,{key:E,id:g.id,ref:D,as:u,activatorEvent:f,adjustScale:t,className:c,transition:l,rect:P,style:{zIndex:d,...a},transform:I},n):null))}))},95339:(e,t,n)=>{"use strict";n.d(t,{DL:()=>r}),n(17592);const r=({transform:e})=>({...e,x:0})},67445:(e,t,n)=>{"use strict";n.d(t,{Fo:()=>p,U2:()=>u,is:()=>S,nB:()=>R,qw:()=>d});var r=n(32735),o=n(20455),i=n(17592);function a(e,t,n){const r=e.slice();return r.splice(n<0?r.length+n:n,0,r.splice(t,1)[0]),r}function l(e,t){return e.reduce(((e,n,r)=>{const o=t.get(n);return o&&(e[r]=o),e}),Array(e.length))}function s(e){return null!==e&&e>=0}const u=e=>{let{rects:t,activeIndex:n,overIndex:r,index:o}=e;const i=a(t,r,n),l=t[o],s=i[o];return s&&l?{x:s.left-l.left,y:s.top-l.top,scaleX:s.width/l.width,scaleY:s.height/l.height}:null},c={scaleX:1,scaleY:1},d=e=>{var t;let{activeIndex:n,activeNodeRect:r,index:o,rects:i,overIndex:a}=e;const l=null!=(t=i[n])?t:r;if(!l)return null;if(o===n){const e=i[a];return e?{x:0,y:n<a?e.top+e.height-(l.top+l.height):e.top-l.top,...c}:null}const s=function(e,t,n){const r=e[t],o=e[t-1],i=e[t+1];return r?n<t?o?r.top-(o.top+o.height):i?i.top-(r.top+r.height):0:i?i.top-(r.top+r.height):o?r.top-(o.top+o.height):0:0}(i,o,n);return o>n&&o<=a?{x:0,y:-l.height-s,...c}:o<n&&o>=a?{x:0,y:l.height+s,...c}:{x:0,y:0,...c}},f="Sortable",g=r.createContext({activeIndex:-1,containerId:f,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:u,disabled:{draggable:!1,droppable:!1}});function p(e){let{children:t,id:n,items:a,strategy:s=u,disabled:c=!1}=e;const{active:d,dragOverlay:p,droppableRects:v,over:h,measureDroppableContainers:m,measuringScheduled:y}=(0,o.Cj)(),b=(0,i.Ld)(f,n),w=Boolean(null!==p.rect),R=(0,r.useMemo)((()=>a.map((e=>"object"==typeof e&&"id"in e?e.id:e))),[a]),x=null!=d,C=d?R.indexOf(d.id):-1,S=h?R.indexOf(h.id):-1,E=(0,r.useRef)(R),I=!function(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}(R,E.current),P=-1!==S&&-1===C||I,B=function(e){return"boolean"==typeof e?{draggable:e,droppable:e}:e}(c);(0,i.LI)((()=>{I&&x&&!y&&m(R)}),[I,R,x,m,y]),(0,r.useEffect)((()=>{E.current=R}),[R]);const D=(0,r.useMemo)((()=>({activeIndex:C,containerId:b,disabled:B,disableTransforms:P,items:R,overIndex:S,useDragOverlay:w,sortedRects:l(R,v),strategy:s})),[C,b,B.draggable,B.droppable,P,R,S,v,w,s]);return r.createElement(g.Provider,{value:D},t)}const v=e=>{let{id:t,items:n,activeIndex:r,overIndex:o}=e;return a(n,r,o).indexOf(t)},h=e=>{let{containerId:t,isSorting:n,wasDragging:r,index:o,items:i,newIndex:a,previousItems:l,previousContainerId:s,transition:u}=e;return!(!u||!r||l!==i&&o===a||!n&&(a===o||t!==s))},m={duration:200,easing:"ease"},y="transform",b=i.ux.Transition.toString({property:y,duration:0,easing:"linear"}),w={roleDescription:"sortable"};function R(e){let{animateLayoutChanges:t=h,attributes:n,disabled:a,data:l,getNewIndex:u=v,id:c,strategy:d,resizeObserverConfig:f,transition:p=m}=e;const{items:R,containerId:x,activeIndex:C,disabled:S,disableTransforms:E,sortedRects:I,overIndex:P,useDragOverlay:B,strategy:D}=(0,r.useContext)(g),k=function(e,t){var n,r;return"boolean"==typeof e?{draggable:e,droppable:!1}:{draggable:null!=(n=null==e?void 0:e.draggable)?n:t.draggable,droppable:null!=(r=null==e?void 0:e.droppable)?r:t.droppable}}(a,S),A=R.indexOf(c),O=(0,r.useMemo)((()=>({sortable:{containerId:x,index:A,items:R},...l})),[x,l,A,R]),F=(0,r.useMemo)((()=>R.slice(R.indexOf(c))),[R,c]),{rect:M,node:T,isOver:N,setNodeRef:G}=(0,o.Zj)({id:c,data:O,disabled:k.droppable,resizeObserverConfig:{updateMeasurementsFor:F,...f}}),{active:L,activatorEvent:z,activeNodeRect:H,attributes:j,setNodeRef:W,listeners:V,isDragging:X,over:_,setActivatorNodeRef:q,transform:U}=(0,o.O1)({id:c,data:O,attributes:{...w,...n},disabled:k.draggable}),Y=(0,i.HB)(G,W),K=Boolean(L),J=K&&!E&&s(C)&&s(P),$=!B&&X,Z=$&&J?U:null,Q=J?null!=Z?Z:(null!=d?d:D)({rects:I,activeNodeRect:H,activeIndex:C,overIndex:P,index:A}):null,ee=s(C)&&s(P)?u({id:c,items:R,activeIndex:C,overIndex:P}):A,te=null==L?void 0:L.id,ne=(0,r.useRef)({activeId:te,items:R,newIndex:ee,containerId:x}),re=R!==ne.current.items,oe=t({active:L,containerId:x,isDragging:X,isSorting:K,id:c,index:A,items:R,newIndex:ne.current.newIndex,previousItems:ne.current.items,previousContainerId:ne.current.containerId,transition:p,wasDragging:null!=ne.current.activeId}),ie=function(e){let{disabled:t,index:n,node:a,rect:l}=e;const[s,u]=(0,r.useState)(null),c=(0,r.useRef)(n);return(0,i.LI)((()=>{if(!t&&n!==c.current&&a.current){const e=l.current;if(e){const t=(0,o.VK)(a.current,{ignoreTransform:!0}),n={x:e.left-t.left,y:e.top-t.top,scaleX:e.width/t.width,scaleY:e.height/t.height};(n.x||n.y)&&u(n)}}n!==c.current&&(c.current=n)}),[t,n,a,l]),(0,r.useEffect)((()=>{s&&requestAnimationFrame((()=>{u(null)}))}),[s]),s}({disabled:!oe,index:A,node:T,rect:M});return(0,r.useEffect)((()=>{K&&ne.current.newIndex!==ee&&(ne.current.newIndex=ee),x!==ne.current.containerId&&(ne.current.containerId=x),R!==ne.current.items&&(ne.current.items=R)}),[K,ee,x,R]),(0,r.useEffect)((()=>{if(te===ne.current.activeId)return;if(te&&!ne.current.activeId)return void(ne.current.activeId=te);const e=setTimeout((()=>{ne.current.activeId=te}),50);return()=>clearTimeout(e)}),[te]),{active:L,activeIndex:C,attributes:j,data:O,rect:M,index:A,newIndex:ee,items:R,isOver:N,isSorting:K,isDragging:X,listeners:V,node:T,overIndex:P,over:_,setNodeRef:Y,setActivatorNodeRef:q,setDroppableNodeRef:G,setDraggableNodeRef:W,transform:null!=ie?ie:Q,transition:ie||re&&ne.current.newIndex===A?b:$&&!(0,i.vd)(z)||!p?void 0:K||oe?i.ux.Transition.toString({...p,property:y}):void 0}}function x(e){if(!e)return!1;const t=e.data.current;return!!(t&&"sortable"in t&&"object"==typeof t.sortable&&"containerId"in t.sortable&&"items"in t.sortable&&"index"in t.sortable)}const C=[o.g4.Down,o.g4.Right,o.g4.Up,o.g4.Left],S=(e,t)=>{let{context:{active:n,collisionRect:r,droppableRects:a,droppableContainers:l,over:s,scrollableAncestors:u}}=t;if(C.includes(e.code)){if(e.preventDefault(),!n||!r)return;const t=[];l.getEnabled().forEach((n=>{if(!n||null!=n&&n.disabled)return;const i=a.get(n.id);if(i)switch(e.code){case o.g4.Down:r.top<i.top&&t.push(n);break;case o.g4.Up:r.top>i.top&&t.push(n);break;case o.g4.Left:r.left>i.left&&t.push(n);break;case o.g4.Right:r.left<i.left&&t.push(n)}}));const f=(0,o.ey)({active:n,collisionRect:r,droppableRects:a,droppableContainers:t,pointerCoordinates:null});let g=(0,o._8)(f,"id");if(g===(null==s?void 0:s.id)&&f.length>1&&(g=f[1].id),null!=g){const e=l.get(n.id),t=l.get(g),s=t?a.get(t.id):null,f=null==t?void 0:t.node.current;if(f&&s&&e&&t){const n=(0,o.hI)(f).some(((e,t)=>u[t]!==e)),a=E(e,t),l=(d=t,!(!x(c=e)||!x(d))&&!!E(c,d)&&c.data.current.sortable.index<d.data.current.sortable.index),g=n||!a?{x:0,y:0}:{x:l?r.width-s.width:0,y:l?r.height-s.height:0},p={x:s.left,y:s.top};return g.x&&g.y?p:(0,i.$X)(p,g)}}}var c,d};function E(e,t){return!(!x(e)||!x(t))&&e.data.current.sortable.containerId===t.data.current.sortable.containerId}},17592:(e,t,n)=>{"use strict";n.d(t,{$X:()=>S,D9:()=>b,DC:()=>I,Ey:()=>h,FJ:()=>a,Gj:()=>m,HB:()=>o,IH:()=>C,Jj:()=>s,LI:()=>g,Ld:()=>R,Nq:()=>i,Re:()=>c,UG:()=>l,Yz:()=>v,qk:()=>u,r3:()=>f,so:()=>D,ux:()=>P,vZ:()=>d,vd:()=>E,wm:()=>y,zX:()=>p});var r=n(32735);function o(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,r.useMemo)((()=>e=>{t.forEach((t=>t(e)))}),t)}const i="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement;function a(e){const t=Object.prototype.toString.call(e);return"[object Window]"===t||"[object global]"===t}function l(e){return"nodeType"in e}function s(e){var t,n;return e?a(e)?e:l(e)&&null!=(t=null==(n=e.ownerDocument)?void 0:n.defaultView)?t:window:window}function u(e){const{Document:t}=s(e);return e instanceof t}function c(e){return!a(e)&&e instanceof s(e).HTMLElement}function d(e){return e instanceof s(e).SVGElement}function f(e){return e?a(e)?e.document:l(e)?u(e)?e:c(e)||d(e)?e.ownerDocument:document:document:document}const g=i?r.useLayoutEffect:r.useEffect;function p(e){const t=(0,r.useRef)(e);return g((()=>{t.current=e})),(0,r.useCallback)((function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return null==t.current?void 0:t.current(...n)}),[])}function v(){const e=(0,r.useRef)(null);return[(0,r.useCallback)(((t,n)=>{e.current=setInterval(t,n)}),[]),(0,r.useCallback)((()=>{null!==e.current&&(clearInterval(e.current),e.current=null)}),[])]}function h(e,t){void 0===t&&(t=[e]);const n=(0,r.useRef)(e);return g((()=>{n.current!==e&&(n.current=e)}),t),n}function m(e,t){const n=(0,r.useRef)();return(0,r.useMemo)((()=>{const t=e(n.current);return n.current=t,t}),[...t])}function y(e){const t=p(e),n=(0,r.useRef)(null),o=(0,r.useCallback)((e=>{e!==n.current&&(null==t||t(e,n.current)),n.current=e}),[]);return[n,o]}function b(e){const t=(0,r.useRef)();return(0,r.useEffect)((()=>{t.current=e}),[e]),t.current}let w={};function R(e,t){return(0,r.useMemo)((()=>{if(t)return t;const n=null==w[e]?0:w[e]+1;return w[e]=n,e+"-"+n}),[e,t])}function x(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce(((t,n)=>{const r=Object.entries(n);for(const[n,o]of r){const r=t[n];null!=r&&(t[n]=r+e*o)}return t}),{...t})}}const C=x(1),S=x(-1);function E(e){if(!e)return!1;const{KeyboardEvent:t}=s(e.target);return t&&e instanceof t}function I(e){if(function(e){if(!e)return!1;const{TouchEvent:t}=s(e.target);return t&&e instanceof t}(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return function(e){return"clientX"in e&&"clientY"in e}(e)?{x:e.clientX,y:e.clientY}:null}const P=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[P.Translate.toString(e),P.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),B="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function D(e){return e.matches(B)?e:e.querySelector(B)}},68050:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var r=n(95685),o=n.n(r),i=n(32735),a=n(46304),l=n(74512);const s=i.forwardRef((({bsPrefix:e,className:t,as:n="div",...r},i)=>{const s=(0,a.vE)(e,"row"),u=(0,a.pi)(),c=(0,a.zG)(),d=`${s}-cols`,f=[];return u.forEach((e=>{const t=r[e];let n;delete r[e],null!=t&&"object"==typeof t?({cols:n}=t):n=t;const o=e!==c?`-${e}`:"";null!=n&&f.push(`${d}${o}-${n}`)})),(0,l.jsx)(n,{ref:i,...r,className:o()(t,s,...f)})}));s.displayName="Row";const u=s},52178:function(e,t,n){!function(e,t){"use strict";function n(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function r(e){return function(){var t=this,r=arguments;return new Promise((function(o,i){var a=e.apply(t,r);function l(e){n(a,o,i,l,s,"next",e)}function s(e){n(a,o,i,l,s,"throw",e)}l(void 0)}))}}function o(){return(o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function i(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}function a(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}t=t&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t;var l={init:"init"},s=function(e){var t=e.value;return void 0===t?"":t},u=function(){return t.createElement(t.Fragment,null," ")},c={Cell:s,width:150,minWidth:0,maxWidth:Number.MAX_SAFE_INTEGER};function d(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce((function(e,t){var n=t.style,r=t.className;return e=o({},e,{},i(t,["style","className"])),n&&(e.style=e.style?o({},e.style||{},{},n||{}):n),r&&(e.className=e.className?e.className+" "+r:r),""===e.className&&delete e.className,e}),{})}var f=function(e,t){return void 0===t&&(t={}),function(n){return void 0===n&&(n={}),[].concat(e,[n]).reduce((function(e,r){return function e(t,n,r){return"function"==typeof n?e({},n(t,r)):Array.isArray(n)?d.apply(void 0,[t].concat(n)):d(t,n)}(e,r,o({},t,{userProps:n}))}),{})}},g=function(e,t,n,r){return void 0===n&&(n={}),e.reduce((function(e,t){return t(e,n)}),t)},p=function(e,t,n){return void 0===n&&(n={}),e.forEach((function(e){e(t,n)}))};function v(e,t,n,r){e.findIndex((function(e){return e.pluginName===n})),t.forEach((function(t){e.findIndex((function(e){return e.pluginName===t}))}))}function h(e,t){return"function"==typeof e?e(t):e}function m(e){var n=t.useRef();return n.current=e,t.useCallback((function(){return n.current}),[])}var y="undefined"!=typeof document?t.useLayoutEffect:t.useEffect;function b(e,n){var r=t.useRef(!1);y((function(){r.current&&e(),r.current=!0}),n)}function w(e,t,n){return void 0===n&&(n={}),function(r,i){void 0===i&&(i={});var a="string"==typeof r?t[r]:r;if(void 0===a)throw console.info(t),new Error("Renderer Error ☝️");return R(a,o({},e,{column:t},n,{},i))}}function R(e,n){return function(e){return"function"==typeof e&&(t=Object.getPrototypeOf(e)).prototype&&t.prototype.isReactComponent;var t}(r=e)||"function"==typeof r||function(e){return"object"==typeof e&&"symbol"==typeof e.$$typeof&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}(r)?t.createElement(e,n):e;var r}function x(e,t,n){return void 0===n&&(n=0),e.map((function(e){return S(e=o({},e,{parent:t,depth:n})),e.columns&&(e.columns=x(e.columns,e,n+1)),e}))}function C(e){return D(e,"columns")}function S(e){var t=e.id,n=e.accessor,r=e.Header;if("string"==typeof n){t=t||n;var o=n.split(".");n=function(e){return function(e,t,n){if(!t)return e;var r,o="function"==typeof t?t:JSON.stringify(t),i=I.get(o)||function(){var e=function(e){return function e(t,n){if(void 0===n&&(n=[]),Array.isArray(t))for(var r=0;r<t.length;r+=1)e(t[r],n);else n.push(t);return n}(e).map((function(e){return String(e).replace(".","_")})).join(".").replace(T,".").replace(N,"").split(".")}(t);return I.set(o,e),e}();try{r=i.reduce((function(e,t){return e[t]}),e)}catch(e){}return void 0!==r?r:void 0}(e,o)}}if(!t&&"string"==typeof r&&r&&(t=r),!t&&e.columns)throw console.error(e),new Error('A column ID (or unique "Header" value) is required!');if(!t)throw console.error(e),new Error("A column ID (or string accessor) is required!");return Object.assign(e,{id:t,accessor:n}),e}function E(e,t){if(!t)throw new Error;return Object.assign(e,o({Header:u,Footer:u},c,{},t,{},e)),Object.assign(e,{originalWidth:e.width}),e}var I=new Map;function P(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];for(var r=0;r<t.length;r+=1)if(void 0!==t[r])return t[r]}function B(e){if("function"==typeof e)return e}function D(e,t){var n=[];return function e(r){r.forEach((function(r){r[t]?e(r[t]):n.push(r)}))}(e),n}function k(e,t){var n=t.manualExpandedKey,r=t.expanded,o=t.expandSubRows,i=void 0===o||o,a=[];return e.forEach((function(e){return function e(t,o){void 0===o&&(o=!0),t.isExpanded=t.original&&t.original[n]||r[t.id],t.canExpand=t.subRows&&!!t.subRows.length,o&&a.push(t),t.subRows&&t.subRows.length&&t.isExpanded&&t.subRows.forEach((function(t){return e(t,i)}))}(e)})),a}function A(e,t,n){return B(e)||t[e]||n[e]||n.text}function O(e,t,n){return e?e(t,n):void 0===t}function F(){throw new Error("React-Table: You have not called prepareRow(row) one or more rows you are attempting to render.")}var M=null,T=/\[/g,N=/\]/g,G=function(e){return o({role:"table"},e)},L=function(e){return o({role:"rowgroup"},e)},z=function(e,t){var n=t.column;return o({key:"header_"+n.id,colSpan:n.totalVisibleHeaderCount,role:"columnheader"},e)},H=function(e,t){var n=t.column;return o({key:"footer_"+n.id,colSpan:n.totalVisibleHeaderCount},e)},j=function(e,t){return o({key:"headerGroup_"+t.index,role:"row"},e)},W=function(e,t){return o({key:"footerGroup_"+t.index},e)},V=function(e,t){return o({key:"row_"+t.row.id,role:"row"},e)},X=function(e,t){var n=t.cell;return o({key:"cell_"+n.row.id+"_"+n.column.id,role:"cell"},e)};function _(){return{useOptions:[],stateReducers:[],useControlledState:[],columns:[],columnsDeps:[],allColumns:[],allColumnsDeps:[],accessValue:[],materializedColumns:[],materializedColumnsDeps:[],useInstanceAfterData:[],visibleColumns:[],visibleColumnsDeps:[],headerGroups:[],headerGroupsDeps:[],useInstanceBeforeDimensions:[],useInstance:[],prepareRow:[],getTableProps:[G],getTableBodyProps:[L],getHeaderGroupProps:[j],getFooterGroupProps:[W],getHeaderProps:[z],getFooterProps:[H],getRowProps:[V],getCellProps:[X],useFinalInstance:[]}}l.resetHiddenColumns="resetHiddenColumns",l.toggleHideColumn="toggleHideColumn",l.setHiddenColumns="setHiddenColumns",l.toggleHideAllColumns="toggleHideAllColumns";var q=function(e){e.getToggleHiddenProps=[U],e.getToggleHideAllColumnsProps=[Y],e.stateReducers.push(K),e.useInstanceBeforeDimensions.push(J),e.headerGroupsDeps.push((function(e,t){var n=t.instance;return[].concat(e,[n.state.hiddenColumns])})),e.useInstance.push($)};q.pluginName="useColumnVisibility";var U=function(e,t){var n=t.column;return[e,{onChange:function(e){n.toggleHidden(!e.target.checked)},style:{cursor:"pointer"},checked:n.isVisible,title:"Toggle Column Visible"}]},Y=function(e,t){var n=t.instance;return[e,{onChange:function(e){n.toggleHideAllColumns(!e.target.checked)},style:{cursor:"pointer"},checked:!n.allColumnsHidden&&!n.state.hiddenColumns.length,title:"Toggle All Columns Hidden",indeterminate:!n.allColumnsHidden&&n.state.hiddenColumns.length}]};function K(e,t,n,r){if(t.type===l.init)return o({hiddenColumns:[]},e);if(t.type===l.resetHiddenColumns)return o({},e,{hiddenColumns:r.initialState.hiddenColumns||[]});if(t.type===l.toggleHideColumn){var i=(void 0!==t.value?t.value:!e.hiddenColumns.includes(t.columnId))?[].concat(e.hiddenColumns,[t.columnId]):e.hiddenColumns.filter((function(e){return e!==t.columnId}));return o({},e,{hiddenColumns:i})}return t.type===l.setHiddenColumns?o({},e,{hiddenColumns:h(t.value,e.hiddenColumns)}):t.type===l.toggleHideAllColumns?o({},e,{hiddenColumns:(void 0!==t.value?t.value:!e.hiddenColumns.length)?r.allColumns.map((function(e){return e.id})):[]}):void 0}function J(e){var n=e.headers,r=e.state.hiddenColumns;t.useRef(!1).current;var o=0;n.forEach((function(e){return o+=function e(t,n){t.isVisible=n&&!r.includes(t.id);var o=0;return t.headers&&t.headers.length?t.headers.forEach((function(n){return o+=e(n,t.isVisible)})):o=t.isVisible?1:0,t.totalVisibleHeaderCount=o,o}(e,!0)}))}function $(e){var n=e.columns,r=e.flatHeaders,o=e.dispatch,i=e.allColumns,a=e.getHooks,s=e.state.hiddenColumns,u=e.autoResetHiddenColumns,c=void 0===u||u,d=m(e),g=i.length===s.length,p=t.useCallback((function(e,t){return o({type:l.toggleHideColumn,columnId:e,value:t})}),[o]),v=t.useCallback((function(e){return o({type:l.setHiddenColumns,value:e})}),[o]),h=t.useCallback((function(e){return o({type:l.toggleHideAllColumns,value:e})}),[o]),y=f(a().getToggleHideAllColumnsProps,{instance:d()});r.forEach((function(e){e.toggleHidden=function(t){o({type:l.toggleHideColumn,columnId:e.id,value:t})},e.getToggleHiddenProps=f(a().getToggleHiddenProps,{instance:d(),column:e})}));var w=m(c);b((function(){w()&&o({type:l.resetHiddenColumns})}),[o,n]),Object.assign(e,{allColumnsHidden:g,toggleHideColumn:p,setHiddenColumns:v,toggleHideAllColumns:h,getToggleHideAllColumnsProps:y})}var Z={},Q={},ee=function(e,t,n){return e},te=function(e,t){return e.subRows||[]},ne=function(e,t,n){return""+(n?[n.id,t].join("."):t)},re=function(e){return e};function oe(e){var t=e.initialState,n=void 0===t?Z:t,r=e.defaultColumn,a=void 0===r?Q:r,l=e.getSubRows,s=void 0===l?te:l,u=e.getRowId,c=void 0===u?ne:u,d=e.stateReducer,f=void 0===d?ee:d,g=e.useControlledState,p=void 0===g?re:g;return o({},i(e,["initialState","defaultColumn","getSubRows","getRowId","stateReducer","useControlledState"]),{initialState:n,defaultColumn:a,getSubRows:s,getRowId:c,stateReducer:f,useControlledState:p})}function ie(e,t){void 0===t&&(t=0);var n=0,r=0,o=0,i=0;return e.forEach((function(e){var a=e.headers;if(e.totalLeft=t,a&&a.length){var l=ie(a,t),s=l[0],u=l[1],c=l[2],d=l[3];e.totalMinWidth=s,e.totalWidth=u,e.totalMaxWidth=c,e.totalFlexWidth=d}else e.totalMinWidth=e.minWidth,e.totalWidth=Math.min(Math.max(e.minWidth,e.width),e.maxWidth),e.totalMaxWidth=e.maxWidth,e.totalFlexWidth=e.canResize?e.totalWidth:0;e.isVisible&&(t+=e.totalWidth,n+=e.totalMinWidth,r+=e.totalWidth,o+=e.totalMaxWidth,i+=e.totalFlexWidth)})),[n,r,o,i]}function ae(e){var t=e.data,n=e.rows,r=e.flatRows,o=e.rowsById,i=e.column,a=e.getRowId,l=e.getSubRows,s=e.accessValueHooks,u=e.getInstance;t.forEach((function(e,c){return function e(n,c,d,f,p){void 0===d&&(d=0);var v=n,h=a(n,c,f),m=o[h];if(m)m.subRows&&m.originalSubRows.forEach((function(t,n){return e(t,n,d+1,m)}));else if((m={id:h,original:v,index:c,depth:d,cells:[{}]}).cells.map=F,m.cells.filter=F,m.cells.forEach=F,m.cells[0].getCellProps=F,m.values={},p.push(m),r.push(m),o[h]=m,m.originalSubRows=l(n,c),m.originalSubRows){var y=[];m.originalSubRows.forEach((function(t,n){return e(t,n,d+1,m,y)})),m.subRows=y}i.accessor&&(m.values[i.id]=i.accessor(n,c,m,p,t)),m.values[i.id]=g(s,m.values[i.id],{row:m,column:i,instance:u()})}(e,c,0,void 0,n)}))}l.resetExpanded="resetExpanded",l.toggleRowExpanded="toggleRowExpanded",l.toggleAllRowsExpanded="toggleAllRowsExpanded";var le=function(e){e.getToggleAllRowsExpandedProps=[se],e.getToggleRowExpandedProps=[ue],e.stateReducers.push(ce),e.useInstance.push(de),e.prepareRow.push(fe)};le.pluginName="useExpanded";var se=function(e,t){var n=t.instance;return[e,{onClick:function(e){n.toggleAllRowsExpanded()},style:{cursor:"pointer"},title:"Toggle All Rows Expanded"}]},ue=function(e,t){var n=t.row;return[e,{onClick:function(){n.toggleRowExpanded()},style:{cursor:"pointer"},title:"Toggle Row Expanded"}]};function ce(e,t,n,r){if(t.type===l.init)return o({expanded:{}},e);if(t.type===l.resetExpanded)return o({},e,{expanded:r.initialState.expanded||{}});if(t.type===l.toggleAllRowsExpanded){var s=t.value,u=r.isAllRowsExpanded,c=r.rowsById;if(void 0!==s?s:!u){var d={};return Object.keys(c).forEach((function(e){d[e]=!0})),o({},e,{expanded:d})}return o({},e,{expanded:{}})}if(t.type===l.toggleRowExpanded){var f,g=t.id,p=t.value,v=e.expanded[g],h=void 0!==p?p:!v;if(!v&&h)return o({},e,{expanded:o({},e.expanded,(f={},f[g]=!0,f))});if(v&&!h){var m=e.expanded;return m[g],o({},e,{expanded:i(m,[g].map(a))})}return e}}function de(e){var n=e.data,r=e.rows,o=e.rowsById,i=e.manualExpandedKey,a=void 0===i?"expanded":i,s=e.paginateExpandedRows,u=void 0===s||s,c=e.expandSubRows,d=void 0===c||c,g=e.autoResetExpanded,p=void 0===g||g,h=e.getHooks,y=e.plugins,w=e.state.expanded,R=e.dispatch;v(y,["useSortBy","useGroupBy","usePivotColumns","useGlobalFilter"],"useExpanded");var x=m(p),C=Boolean(Object.keys(o).length&&Object.keys(w).length);C&&Object.keys(o).some((function(e){return!w[e]}))&&(C=!1),b((function(){x()&&R({type:l.resetExpanded})}),[R,n]);var S=t.useCallback((function(e,t){R({type:l.toggleRowExpanded,id:e,value:t})}),[R]),E=t.useCallback((function(e){return R({type:l.toggleAllRowsExpanded,value:e})}),[R]),I=t.useMemo((function(){return u?k(r,{manualExpandedKey:a,expanded:w,expandSubRows:d}):r}),[u,r,a,w,d]),P=t.useMemo((function(){return function(e){var t=0;return Object.keys(e).forEach((function(e){var n=e.split(".");t=Math.max(t,n.length)})),t}(w)}),[w]),B=m(e),D=f(h().getToggleAllRowsExpandedProps,{instance:B()});Object.assign(e,{preExpandedRows:r,expandedRows:I,rows:I,expandedDepth:P,isAllRowsExpanded:C,toggleRowExpanded:S,toggleAllRowsExpanded:E,getToggleAllRowsExpandedProps:D})}function fe(e,t){var n=t.instance.getHooks,r=t.instance;e.toggleRowExpanded=function(t){return r.toggleRowExpanded(e.id,t)},e.getToggleRowExpandedProps=f(n().getToggleRowExpandedProps,{instance:r,row:e})}var ge=function(e,t,n){return e.filter((function(e){return t.some((function(t){var r=e.values[t];return String(r).toLowerCase().includes(String(n).toLowerCase())}))}))};ge.autoRemove=function(e){return!e};var pe=function(e,t,n){return e.filter((function(e){return t.some((function(t){var r=e.values[t];return void 0===r||String(r).toLowerCase()===String(n).toLowerCase()}))}))};pe.autoRemove=function(e){return!e};var ve=function(e,t,n){return e.filter((function(e){return t.some((function(t){var r=e.values[t];return void 0===r||String(r)===String(n)}))}))};ve.autoRemove=function(e){return!e};var he=function(e,t,n){return e.filter((function(e){return t.some((function(t){return e.values[t].includes(n)}))}))};he.autoRemove=function(e){return!e||!e.length};var me=function(e,t,n){return e.filter((function(e){return t.some((function(t){var r=e.values[t];return r&&r.length&&n.every((function(e){return r.includes(e)}))}))}))};me.autoRemove=function(e){return!e||!e.length};var ye=function(e,t,n){return e.filter((function(e){return t.some((function(t){var r=e.values[t];return r&&r.length&&n.some((function(e){return r.includes(e)}))}))}))};ye.autoRemove=function(e){return!e||!e.length};var be=function(e,t,n){return e.filter((function(e){return t.some((function(t){var r=e.values[t];return n.includes(r)}))}))};be.autoRemove=function(e){return!e||!e.length};var we=function(e,t,n){return e.filter((function(e){return t.some((function(t){return e.values[t]===n}))}))};we.autoRemove=function(e){return void 0===e};var Re=function(e,t,n){return e.filter((function(e){return t.some((function(t){return e.values[t]==n}))}))};Re.autoRemove=function(e){return null==e};var xe=function(e,t,n){var r=n||[],o=r[0],i=r[1];if((o="number"==typeof o?o:-1/0)>(i="number"==typeof i?i:1/0)){var a=o;o=i,i=a}return e.filter((function(e){return t.some((function(t){var n=e.values[t];return n>=o&&n<=i}))}))};xe.autoRemove=function(e){return!e||"number"!=typeof e[0]&&"number"!=typeof e[1]};var Ce=Object.freeze({__proto__:null,text:ge,exactText:pe,exactTextCase:ve,includes:he,includesAll:me,includesSome:ye,includesValue:be,exact:we,equals:Re,between:xe});l.resetFilters="resetFilters",l.setFilter="setFilter",l.setAllFilters="setAllFilters";var Se=function(e){e.stateReducers.push(Ee),e.useInstance.push(Ie)};function Ee(e,t,n,r){if(t.type===l.init)return o({filters:[]},e);if(t.type===l.resetFilters)return o({},e,{filters:r.initialState.filters||[]});if(t.type===l.setFilter){var i=t.columnId,a=t.filterValue,s=r.allColumns,u=r.filterTypes,c=s.find((function(e){return e.id===i}));if(!c)throw new Error("React-Table: Could not find a column with id: "+i);var d=A(c.filter,u||{},Ce),f=e.filters.find((function(e){return e.id===i})),g=h(a,f&&f.value);return O(d.autoRemove,g,c)?o({},e,{filters:e.filters.filter((function(e){return e.id!==i}))}):o({},e,f?{filters:e.filters.map((function(e){return e.id===i?{id:i,value:g}:e}))}:{filters:[].concat(e.filters,[{id:i,value:g}])})}if(t.type===l.setAllFilters){var p=t.filters,v=r.allColumns,m=r.filterTypes;return o({},e,{filters:h(p,e.filters).filter((function(e){var t=v.find((function(t){return t.id===e.id}));return!O(A(t.filter,m||{},Ce).autoRemove,e.value,t)}))})}}function Ie(e){var n=e.data,r=e.rows,o=e.flatRows,i=e.rowsById,a=e.allColumns,s=e.filterTypes,u=e.manualFilters,c=e.defaultCanFilter,d=void 0!==c&&c,f=e.disableFilters,g=e.state.filters,p=e.dispatch,v=e.autoResetFilters,h=void 0===v||v,y=t.useCallback((function(e,t){p({type:l.setFilter,columnId:e,filterValue:t})}),[p]),w=t.useCallback((function(e){p({type:l.setAllFilters,filters:e})}),[p]);a.forEach((function(e){var t=e.id,n=e.accessor,r=e.defaultCanFilter,o=e.disableFilters;e.canFilter=n?P(!0!==o&&void 0,!0!==f&&void 0,!0):P(r,d,!1),e.setFilter=function(t){return y(e.id,t)};var i=g.find((function(e){return e.id===t}));e.filterValue=i&&i.value}));var R=t.useMemo((function(){if(u||!g.length)return[r,o,i];var e=[],t={};return[function n(r,o){void 0===o&&(o=0);var i=r;return(i=g.reduce((function(e,t){var n=t.id,r=t.value,i=a.find((function(e){return e.id===n}));if(!i)return e;0===o&&(i.preFilteredRows=e);var l=A(i.filter,s||{},Ce);return l?(i.filteredRows=l(e,[n],r),i.filteredRows):(console.warn("Could not find a valid 'column.filter' for column with the ID: "+i.id+"."),e)}),r)).forEach((function(r){e.push(r),t[r.id]=r,r.subRows&&(r.subRows=r.subRows&&r.subRows.length>0?n(r.subRows,o+1):r.subRows)})),i}(r),e,t]}),[u,g,r,o,i,a,s]),x=R[0],C=R[1],S=R[2];t.useMemo((function(){a.filter((function(e){return!g.find((function(t){return t.id===e.id}))})).forEach((function(e){e.preFilteredRows=x,e.filteredRows=x}))}),[x,g,a]);var E=m(h);b((function(){E()&&p({type:l.resetFilters})}),[p,u?null:n]),Object.assign(e,{preFilteredRows:r,preFilteredFlatRows:o,preFilteredRowsById:i,filteredRows:x,filteredFlatRows:C,filteredRowsById:S,rows:x,flatRows:C,rowsById:S,setFilter:y,setAllFilters:w})}Se.pluginName="useFilters",l.resetGlobalFilter="resetGlobalFilter",l.setGlobalFilter="setGlobalFilter";var Pe=function(e){e.stateReducers.push(Be),e.useInstance.push(De)};function Be(e,t,n,r){if(t.type===l.resetGlobalFilter)return o({},e,{globalFilter:r.initialState.globalFilter||void 0});if(t.type===l.setGlobalFilter){var a=t.filterValue,s=r.userFilterTypes,u=A(r.globalFilter,s||{},Ce),c=h(a,e.globalFilter);return O(u.autoRemove,c)?(e.globalFilter,i(e,["globalFilter"])):o({},e,{globalFilter:c})}}function De(e){var n=e.data,r=e.rows,o=e.flatRows,i=e.rowsById,a=e.allColumns,s=e.filterTypes,u=e.globalFilter,c=e.manualGlobalFilter,d=e.state.globalFilter,f=e.dispatch,g=e.autoResetGlobalFilter,p=void 0===g||g,v=e.disableGlobalFilter,h=t.useCallback((function(e){f({type:l.setGlobalFilter,filterValue:e})}),[f]),y=t.useMemo((function(){if(c||void 0===d)return[r,o,i];var e=[],t={},n=A(u,s||{},Ce);if(!n)return console.warn("Could not find a valid 'globalFilter' option."),r;a.forEach((function(e){var t=e.disableGlobalFilter;e.canFilter=P(!0!==t&&void 0,!0!==v&&void 0,!0)}));var l=a.filter((function(e){return!0===e.canFilter}));return[function r(o){return(o=n(o,l.map((function(e){return e.id})),d)).forEach((function(n){e.push(n),t[n.id]=n,n.subRows=n.subRows&&n.subRows.length?r(n.subRows):n.subRows})),o}(r),e,t]}),[c,d,u,s,a,r,o,i,v]),w=y[0],R=y[1],x=y[2],C=m(p);b((function(){C()&&f({type:l.resetGlobalFilter})}),[f,c?null:n]),Object.assign(e,{preGlobalFilteredRows:r,preGlobalFilteredFlatRows:o,preGlobalFilteredRowsById:i,globalFilteredRows:w,globalFilteredFlatRows:R,globalFilteredRowsById:x,rows:w,flatRows:R,rowsById:x,setGlobalFilter:h,disableGlobalFilter:v})}function ke(e,t){return t.reduce((function(e,t){return e+("number"==typeof t?t:0)}),0)}Pe.pluginName="useGlobalFilter";var Ae=Object.freeze({__proto__:null,sum:ke,min:function(e){var t=e[0]||0;return e.forEach((function(e){"number"==typeof e&&(t=Math.min(t,e))})),t},max:function(e){var t=e[0]||0;return e.forEach((function(e){"number"==typeof e&&(t=Math.max(t,e))})),t},minMax:function(e){var t=e[0]||0,n=e[0]||0;return e.forEach((function(e){"number"==typeof e&&(t=Math.min(t,e),n=Math.max(n,e))})),t+".."+n},average:function(e){return ke(0,e)/e.length},median:function(e){if(!e.length)return null;var t=Math.floor(e.length/2),n=[].concat(e).sort((function(e,t){return e-t}));return e.length%2!=0?n[t]:(n[t-1]+n[t])/2},unique:function(e){return Array.from(new Set(e).values())},uniqueCount:function(e){return new Set(e).size},count:function(e){return e.length}}),Oe=[],Fe={};l.resetGroupBy="resetGroupBy",l.setGroupBy="setGroupBy",l.toggleGroupBy="toggleGroupBy";var Me=function(e){e.getGroupByToggleProps=[Te],e.stateReducers.push(Ne),e.visibleColumnsDeps.push((function(e,t){var n=t.instance;return[].concat(e,[n.state.groupBy])})),e.visibleColumns.push(Ge),e.useInstance.push(ze),e.prepareRow.push(He)};Me.pluginName="useGroupBy";var Te=function(e,t){var n=t.header;return[e,{onClick:n.canGroupBy?function(e){e.persist(),n.toggleGroupBy()}:void 0,style:{cursor:n.canGroupBy?"pointer":void 0},title:"Toggle GroupBy"}]};function Ne(e,t,n,r){if(t.type===l.init)return o({groupBy:[]},e);if(t.type===l.resetGroupBy)return o({},e,{groupBy:r.initialState.groupBy||[]});if(t.type===l.setGroupBy)return o({},e,{groupBy:t.value});if(t.type===l.toggleGroupBy){var i=t.columnId,a=t.value,s=void 0!==a?a:!e.groupBy.includes(i);return o({},e,s?{groupBy:[].concat(e.groupBy,[i])}:{groupBy:e.groupBy.filter((function(e){return e!==i}))})}}function Ge(e,t){var n=t.instance.state.groupBy,r=n.map((function(t){return e.find((function(e){return e.id===t}))})).filter(Boolean),o=e.filter((function(e){return!n.includes(e.id)}));return(e=[].concat(r,o)).forEach((function(e){e.isGrouped=n.includes(e.id),e.groupedIndex=n.indexOf(e.id)})),e}var Le={};function ze(e){var n=e.data,r=e.rows,o=e.flatRows,i=e.rowsById,a=e.allColumns,s=e.flatHeaders,u=e.groupByFn,c=void 0===u?je:u,d=e.manualGroupBy,g=e.aggregations,p=void 0===g?Le:g,h=e.plugins,y=e.state.groupBy,w=e.dispatch,R=e.autoResetGroupBy,x=void 0===R||R,C=e.disableGroupBy,S=e.defaultCanGroupBy,E=e.getHooks;v(h,["useColumnOrder","useFilters"],"useGroupBy");var I=m(e);a.forEach((function(t){var n=t.accessor,r=t.defaultGroupBy,o=t.disableGroupBy;t.canGroupBy=n?P(t.canGroupBy,!0!==o&&void 0,!0!==C&&void 0,!0):P(t.canGroupBy,r,S,!1),t.canGroupBy&&(t.toggleGroupBy=function(){return e.toggleGroupBy(t.id)}),t.Aggregated=t.Aggregated||t.Cell}));var B=t.useCallback((function(e,t){w({type:l.toggleGroupBy,columnId:e,value:t})}),[w]),k=t.useCallback((function(e){w({type:l.setGroupBy,value:e})}),[w]);s.forEach((function(e){e.getGroupByToggleProps=f(E().getGroupByToggleProps,{instance:I(),header:e})}));var A=t.useMemo((function(){if(d||!y.length)return[r,o,i,Oe,Fe,o,i];var e=y.filter((function(e){return a.find((function(t){return t.id===e}))})),t=[],n={},l=[],s={},u=[],f={},g=function r(o,i,d){if(void 0===i&&(i=0),i===e.length)return o;var g=e[i],v=c(o,g);return Object.entries(v).map((function(o,c){var v=o[0],h=o[1],m=g+":"+v,y=r(h,i+1,m=d?d+">"+m:m),b=i?D(h,"leafRows"):h,w=function(t,n,r){var o={};return a.forEach((function(i){if(e.includes(i.id))o[i.id]=n[0]?n[0].values[i.id]:null;else{var a="function"==typeof i.aggregate?i.aggregate:p[i.aggregate]||Ae[i.aggregate];if(a){var l=n.map((function(e){return e.values[i.id]})),s=t.map((function(e){var t=e.values[i.id];if(!r&&i.aggregateValue){var n="function"==typeof i.aggregateValue?i.aggregateValue:p[i.aggregateValue]||Ae[i.aggregateValue];if(!n)throw console.info({column:i}),new Error("React Table: Invalid column.aggregateValue option for column listed above");t=n(t,e,i)}return t}));o[i.id]=a(s,l)}else{if(i.aggregate)throw console.info({column:i}),new Error("React Table: Invalid column.aggregate option for column listed above");o[i.id]=null}}})),o}(b,h,i),R={id:m,isGrouped:!0,groupByID:g,groupByVal:v,values:w,subRows:y,leafRows:b,depth:i,index:c};return y.forEach((function(e){t.push(e),n[e.id]=e,e.isGrouped?(l.push(e),s[e.id]=e):(u.push(e),f[e.id]=e)})),R}))}(r);return g.forEach((function(e){t.push(e),n[e.id]=e,e.isGrouped?(l.push(e),s[e.id]=e):(u.push(e),f[e.id]=e)})),[g,t,n,l,s,u,f]}),[d,y,r,o,i,a,p,c]),O=A[0],F=A[1],M=A[2],T=A[3],N=A[4],G=A[5],L=A[6],z=m(x);b((function(){z()&&w({type:l.resetGroupBy})}),[w,d?null:n]),Object.assign(e,{preGroupedRows:r,preGroupedFlatRow:o,preGroupedRowsById:i,groupedRows:O,groupedFlatRows:F,groupedRowsById:M,onlyGroupedFlatRows:T,onlyGroupedRowsById:N,nonGroupedFlatRows:G,nonGroupedRowsById:L,rows:O,flatRows:F,rowsById:M,toggleGroupBy:B,setGroupBy:k})}function He(e){e.allCells.forEach((function(t){var n;t.isGrouped=t.column.isGrouped&&t.column.id===e.groupByID,t.isPlaceholder=!t.isGrouped&&t.column.isGrouped,t.isAggregated=!t.isGrouped&&!t.isPlaceholder&&(null==(n=e.subRows)?void 0:n.length)}))}function je(e,t){return e.reduce((function(e,n,r){var o=""+n.values[t];return e[o]=Array.isArray(e[o])?e[o]:[],e[o].push(n),e}),{})}var We=/([0-9]+)/gm;function Ve(e,t){return e===t?0:e>t?1:-1}function Xe(e,t){return e.values[t]}function _e(e){return"number"==typeof e?isNaN(e)||e===1/0||e===-1/0?"":String(e):"string"==typeof e?e:""}var qe=Object.freeze({__proto__:null,alphanumeric:function(e,t,n){var r=Xe(e,n),o=Xe(t,n);for(r=_e(r),o=_e(o),r=r.split(We).filter(Boolean),o=o.split(We).filter(Boolean);r.length&&o.length;){var i=r.shift(),a=o.shift(),l=parseInt(i,10),s=parseInt(a,10),u=[l,s].sort();if(isNaN(u[0])){if(i>a)return 1;if(a>i)return-1}else{if(isNaN(u[1]))return isNaN(l)?-1:1;if(l>s)return 1;if(s>l)return-1}}return r.length-o.length},datetime:function(e,t,n){var r=Xe(e,n),o=Xe(t,n);return Ve(r=r.getTime(),o=o.getTime())},basic:function(e,t,n){return Ve(Xe(e,n),Xe(t,n))}});l.resetSortBy="resetSortBy",l.setSortBy="setSortBy",l.toggleSortBy="toggleSortBy",l.clearSortBy="clearSortBy",c.sortType="alphanumeric",c.sortDescFirst=!1;var Ue=function(e){e.getSortByToggleProps=[Ye],e.stateReducers.push(Ke),e.useInstance.push(Je)};Ue.pluginName="useSortBy";var Ye=function(e,t){var n=t.instance,r=t.column,o=n.isMultiSortEvent,i=void 0===o?function(e){return e.shiftKey}:o;return[e,{onClick:r.canSort?function(e){e.persist(),r.toggleSortBy(void 0,!n.disableMultiSort&&i(e))}:void 0,style:{cursor:r.canSort?"pointer":void 0},title:r.canSort?"Toggle SortBy":void 0}]};function Ke(e,t,n,r){if(t.type===l.init)return o({sortBy:[]},e);if(t.type===l.resetSortBy)return o({},e,{sortBy:r.initialState.sortBy||[]});if(t.type===l.clearSortBy)return o({},e,{sortBy:e.sortBy.filter((function(e){return e.id!==t.columnId}))});if(t.type===l.setSortBy)return o({},e,{sortBy:t.sortBy});if(t.type===l.toggleSortBy){var i,a=t.columnId,s=t.desc,u=t.multi,c=r.allColumns,d=r.disableMultiSort,f=r.disableSortRemove,g=r.disableMultiRemove,p=r.maxMultiSortColCount,v=void 0===p?Number.MAX_SAFE_INTEGER:p,h=e.sortBy,m=c.find((function(e){return e.id===a})).sortDescFirst,y=h.find((function(e){return e.id===a})),b=h.findIndex((function(e){return e.id===a})),w=null!=s,R=[];return"toggle"!=(i=!d&&u?y?"toggle":"add":b!==h.length-1||1!==h.length?"replace":y?"toggle":"replace")||f||w||u&&g||!(y&&y.desc&&!m||!y.desc&&m)||(i="remove"),"replace"===i?R=[{id:a,desc:w?s:m}]:"add"===i?(R=[].concat(h,[{id:a,desc:w?s:m}])).splice(0,R.length-v):"toggle"===i?R=h.map((function(e){return e.id===a?o({},e,{desc:w?s:!y.desc}):e})):"remove"===i&&(R=h.filter((function(e){return e.id!==a}))),o({},e,{sortBy:R})}}function Je(e){var n=e.data,r=e.rows,o=e.flatRows,i=e.allColumns,a=e.orderByFn,s=void 0===a?$e:a,u=e.sortTypes,c=e.manualSortBy,d=e.defaultCanSort,g=e.disableSortBy,p=e.flatHeaders,h=e.state.sortBy,y=e.dispatch,w=e.plugins,R=e.getHooks,x=e.autoResetSortBy,C=void 0===x||x;v(w,["useFilters","useGlobalFilter","useGroupBy","usePivotColumns"],"useSortBy");var S=t.useCallback((function(e){y({type:l.setSortBy,sortBy:e})}),[y]),E=t.useCallback((function(e,t,n){y({type:l.toggleSortBy,columnId:e,desc:t,multi:n})}),[y]),I=m(e);p.forEach((function(e){var t=e.accessor,n=e.canSort,r=e.disableSortBy,o=e.id,i=t?P(!0!==r&&void 0,!0!==g&&void 0,!0):P(d,n,!1);e.canSort=i,e.canSort&&(e.toggleSortBy=function(t,n){return E(e.id,t,n)},e.clearSortBy=function(){y({type:l.clearSortBy,columnId:e.id})}),e.getSortByToggleProps=f(R().getSortByToggleProps,{instance:I(),column:e});var a=h.find((function(e){return e.id===o}));e.isSorted=!!a,e.sortedIndex=h.findIndex((function(e){return e.id===o})),e.isSortedDesc=e.isSorted?a.desc:void 0}));var D=t.useMemo((function(){if(c||!h.length)return[r,o];var e=[],t=h.filter((function(e){return i.find((function(t){return t.id===e.id}))}));return[function n(r){var o=s(r,t.map((function(e){var t=i.find((function(t){return t.id===e.id}));if(!t)throw new Error("React-Table: Could not find a column with id: "+e.id+" while sorting");var n=t.sortType,r=B(n)||(u||{})[n]||qe[n];if(!r)throw new Error("React-Table: Could not find a valid sortType of '"+n+"' for column '"+e.id+"'.");return function(t,n){return r(t,n,e.id,e.desc)}})),t.map((function(e){var t=i.find((function(t){return t.id===e.id}));return t&&t.sortInverted?e.desc:!e.desc})));return o.forEach((function(t){e.push(t),t.subRows&&0!==t.subRows.length&&(t.subRows=n(t.subRows))})),o}(r),e]}),[c,h,r,o,i,s,u]),k=D[0],A=D[1],O=m(C);b((function(){O()&&y({type:l.resetSortBy})}),[c?null:n]),Object.assign(e,{preSortedRows:r,preSortedFlatRows:o,sortedRows:k,sortedFlatRows:A,rows:k,flatRows:A,setSortBy:S,toggleSortBy:E})}function $e(e,t,n){return[].concat(e).sort((function(e,r){for(var o=0;o<t.length;o+=1){var i=t[o],a=!1===n[o]||"desc"===n[o],l=i(e,r);if(0!==l)return a?-l:l}return n[0]?e.index-r.index:r.index-e.index}))}l.resetPage="resetPage",l.gotoPage="gotoPage",l.setPageSize="setPageSize";var Ze=function(e){e.stateReducers.push(Qe),e.useInstance.push(et)};function Qe(e,t,n,r){if(t.type===l.init)return o({pageSize:10,pageIndex:0},e);if(t.type===l.resetPage)return o({},e,{pageIndex:r.initialState.pageIndex||0});if(t.type===l.gotoPage){var i=r.pageCount,a=r.page,s=h(t.pageIndex,e.pageIndex),u=!1;return s>e.pageIndex?u=-1===i?a.length>=e.pageSize:s<i:s<e.pageIndex&&(u=s>-1),u?o({},e,{pageIndex:s}):e}if(t.type===l.setPageSize){var c=t.pageSize,d=e.pageSize*e.pageIndex;return o({},e,{pageIndex:Math.floor(d/c),pageSize:c})}}function et(e){var n=e.rows,r=e.autoResetPage,o=void 0===r||r,i=e.manualExpandedKey,a=void 0===i?"expanded":i,s=e.plugins,u=e.pageCount,c=e.paginateExpandedRows,d=void 0===c||c,f=e.expandSubRows,g=void 0===f||f,p=e.state,h=p.pageSize,y=p.pageIndex,w=p.expanded,R=p.globalFilter,x=p.filters,C=p.groupBy,S=p.sortBy,E=e.dispatch,I=e.data,P=e.manualPagination;v(s,["useGlobalFilter","useFilters","useGroupBy","useSortBy","useExpanded"],"usePagination");var B=m(o);b((function(){B()&&E({type:l.resetPage})}),[E,P?null:I,R,x,C,S]);var D=P?u:Math.ceil(n.length/h),A=t.useMemo((function(){return D>0?[].concat(new Array(D)).fill(null).map((function(e,t){return t})):[]}),[D]),O=t.useMemo((function(){var e;if(P)e=n;else{var t=h*y,r=t+h;e=n.slice(t,r)}return d?e:k(e,{manualExpandedKey:a,expanded:w,expandSubRows:g})}),[g,w,a,P,y,h,d,n]),F=y>0,M=-1===D?O.length>=h:y<D-1,T=t.useCallback((function(e){E({type:l.gotoPage,pageIndex:e})}),[E]),N=t.useCallback((function(){return T((function(e){return e-1}))}),[T]),G=t.useCallback((function(){return T((function(e){return e+1}))}),[T]),L=t.useCallback((function(e){E({type:l.setPageSize,pageSize:e})}),[E]);Object.assign(e,{pageOptions:A,pageCount:D,page:O,canPreviousPage:F,canNextPage:M,gotoPage:T,previousPage:N,nextPage:G,setPageSize:L})}Ze.pluginName="usePagination",l.resetPivot="resetPivot",l.togglePivot="togglePivot";var tt=function(e){e.getPivotToggleProps=[rt],e.stateReducers.push(ot),e.useInstanceAfterData.push(it),e.allColumns.push(at),e.accessValue.push(lt),e.materializedColumns.push(st),e.materializedColumnsDeps.push(ut),e.visibleColumns.push(ct),e.visibleColumnsDeps.push(dt),e.useInstance.push(ft),e.prepareRow.push(gt)};tt.pluginName="usePivotColumns";var nt=[],rt=function(e,t){var n=t.header;return[e,{onClick:n.canPivot?function(e){e.persist(),n.togglePivot()}:void 0,style:{cursor:n.canPivot?"pointer":void 0},title:"Toggle Pivot"}]};function ot(e,t,n,r){if(t.type===l.init)return o({pivotColumns:nt},e);if(t.type===l.resetPivot)return o({},e,{pivotColumns:r.initialState.pivotColumns||nt});if(t.type===l.togglePivot){var i=t.columnId,a=t.value,s=void 0!==a?a:!e.pivotColumns.includes(i);return o({},e,s?{pivotColumns:[].concat(e.pivotColumns,[i])}:{pivotColumns:e.pivotColumns.filter((function(e){return e!==i}))})}}function it(e){e.allColumns.forEach((function(t){t.isPivotSource=e.state.pivotColumns.includes(t.id)}))}function at(e,t){var n=t.instance;return e.forEach((function(e){e.isPivotSource=n.state.pivotColumns.includes(e.id),e.uniqueValues=new Set})),e}function lt(e,t){var n=t.column;return n.uniqueValues&&void 0!==e&&n.uniqueValues.add(e),e}function st(e,t){var n=t.instance,r=n.allColumns,i=n.state;if(!i.pivotColumns.length||!i.groupBy||!i.groupBy.length)return e;var a=i.pivotColumns.map((function(e){return r.find((function(t){return t.id===e}))})).filter(Boolean),l=r.filter((function(e){return!e.isPivotSource&&!i.groupBy.includes(e.id)&&!i.pivotColumns.includes(e.id)})),s=C(function e(t,n,r){void 0===t&&(t=0),void 0===r&&(r=[]);var i=a[t];return i?Array.from(i.uniqueValues).sort().map((function(a){var l=o({},i,{Header:i.PivotHeader||"string"==typeof i.header?i.Header+": "+a:a,isPivotGroup:!0,parent:n,depth:t,id:n?n.id+"."+i.id+"."+a:i.id+"."+a,pivotValue:a});return l.columns=e(t+1,l,[].concat(r,[function(e){return e.values[i.id]===a}])),l})):l.map((function(e){return o({},e,{canPivot:!1,isPivoted:!0,parent:n,depth:t,id:""+(n?n.id+"."+e.id:e.id),accessor:function(t,n,o){if(r.every((function(e){return e(o)})))return o.values[e.id]}})}))}());return[].concat(e,s)}function ut(e,t){var n=t.instance.state,r=n.pivotColumns,o=n.groupBy;return[].concat(e,[r,o])}function ct(e,t){var n=t.instance.state;return e=e.filter((function(e){return!e.isPivotSource})),n.pivotColumns.length&&n.groupBy&&n.groupBy.length&&(e=e.filter((function(e){return e.isGrouped||e.isPivoted}))),e}function dt(e,t){var n=t.instance;return[].concat(e,[n.state.pivotColumns,n.state.groupBy])}function ft(e){var t=e.columns,n=e.allColumns,r=e.flatHeaders,o=e.getHooks,i=e.plugins,a=e.dispatch,s=e.autoResetPivot,u=void 0===s||s,c=e.manaulPivot,d=e.disablePivot,g=e.defaultCanPivot;v(i,["useGroupBy"],"usePivotColumns");var p=m(e);n.forEach((function(t){var n=t.accessor,r=t.defaultPivot,o=t.disablePivot;t.canPivot=n?P(t.canPivot,!0!==o&&void 0,!0!==d&&void 0,!0):P(t.canPivot,r,g,!1),t.canPivot&&(t.togglePivot=function(){return e.togglePivot(t.id)}),t.Aggregated=t.Aggregated||t.Cell})),r.forEach((function(e){e.getPivotToggleProps=f(o().getPivotToggleProps,{instance:p(),header:e})}));var h=m(u);b((function(){h()&&a({type:l.resetPivot})}),[a,c?null:t]),Object.assign(e,{togglePivot:function(e,t){a({type:l.togglePivot,columnId:e,value:t})}})}function gt(e){e.allCells.forEach((function(e){e.isPivoted=e.column.isPivoted}))}l.resetSelectedRows="resetSelectedRows",l.toggleAllRowsSelected="toggleAllRowsSelected",l.toggleRowSelected="toggleRowSelected",l.toggleAllPageRowsSelected="toggleAllPageRowsSelected";var pt=function(e){e.getToggleRowSelectedProps=[vt],e.getToggleAllRowsSelectedProps=[ht],e.getToggleAllPageRowsSelectedProps=[mt],e.stateReducers.push(yt),e.useInstance.push(bt),e.prepareRow.push(wt)};pt.pluginName="useRowSelect";var vt=function(e,t){var n=t.instance,r=t.row,o=n.manualRowSelectedKey,i=void 0===o?"isSelected":o;return[e,{onChange:function(e){r.toggleRowSelected(e.target.checked)},style:{cursor:"pointer"},checked:!(!r.original||!r.original[i])||r.isSelected,title:"Toggle Row Selected",indeterminate:r.isSomeSelected}]},ht=function(e,t){var n=t.instance;return[e,{onChange:function(e){n.toggleAllRowsSelected(e.target.checked)},style:{cursor:"pointer"},checked:n.isAllRowsSelected,title:"Toggle All Rows Selected",indeterminate:Boolean(!n.isAllRowsSelected&&Object.keys(n.state.selectedRowIds).length)}]},mt=function(e,t){var n=t.instance;return[e,{onChange:function(e){n.toggleAllPageRowsSelected(e.target.checked)},style:{cursor:"pointer"},checked:n.isAllPageRowsSelected,title:"Toggle All Current Page Rows Selected",indeterminate:Boolean(!n.isAllPageRowsSelected&&n.page.some((function(e){var t=e.id;return n.state.selectedRowIds[t]})))}]};function yt(e,t,n,r){if(t.type===l.init)return o({selectedRowIds:{}},e);if(t.type===l.resetSelectedRows)return o({},e,{selectedRowIds:r.initialState.selectedRowIds||{}});if(t.type===l.toggleAllRowsSelected){var i=t.value,a=r.isAllRowsSelected,s=r.rowsById,u=r.nonGroupedRowsById,c=void 0===u?s:u,d=void 0!==i?i:!a,f=Object.assign({},e.selectedRowIds);return d?Object.keys(c).forEach((function(e){f[e]=!0})):Object.keys(c).forEach((function(e){delete f[e]})),o({},e,{selectedRowIds:f})}if(t.type===l.toggleRowSelected){var g=t.id,p=t.value,v=r.rowsById,h=r.selectSubRows,m=void 0===h||h,y=r.getSubRows,b=e.selectedRowIds[g],w=void 0!==p?p:!b;if(b===w)return e;var R=o({},e.selectedRowIds);return function e(t){var n=v[t];if(n.isGrouped||(w?R[t]=!0:delete R[t]),m&&y(n))return y(n).forEach((function(t){return e(t.id)}))}(g),o({},e,{selectedRowIds:R})}if(t.type===l.toggleAllPageRowsSelected){var x=t.value,C=r.page,S=r.rowsById,E=r.selectSubRows,I=void 0===E||E,P=r.isAllPageRowsSelected,B=r.getSubRows,D=void 0!==x?x:!P,k=o({},e.selectedRowIds);return C.forEach((function(e){return function e(t){var n=S[t];if(n.isGrouped||(D?k[t]=!0:delete k[t]),I&&B(n))return B(n).forEach((function(t){return e(t.id)}))}(e.id)})),o({},e,{selectedRowIds:k})}return e}function bt(e){var n=e.data,r=e.rows,o=e.getHooks,i=e.plugins,a=e.rowsById,s=e.nonGroupedRowsById,u=void 0===s?a:s,c=e.autoResetSelectedRows,d=void 0===c||c,g=e.state.selectedRowIds,p=e.selectSubRows,h=void 0===p||p,y=e.dispatch,w=e.page,R=e.getSubRows;v(i,["useFilters","useGroupBy","useSortBy","useExpanded","usePagination"],"useRowSelect");var x=t.useMemo((function(){var e=[];return r.forEach((function(t){var n=h?function e(t,n,r){if(n[t.id])return!0;var o=r(t);if(o&&o.length){var i=!0,a=!1;return o.forEach((function(t){a&&!i||(e(t,n,r)?a=!0:i=!1)})),!!i||!!a&&null}return!1}(t,g,R):!!g[t.id];t.isSelected=!!n,t.isSomeSelected=null===n,n&&e.push(t)})),e}),[r,h,g,R]),C=Boolean(Object.keys(u).length&&Object.keys(g).length),S=C;C&&Object.keys(u).some((function(e){return!g[e]}))&&(C=!1),C||w&&w.length&&w.some((function(e){var t=e.id;return!g[t]}))&&(S=!1);var E=m(d);b((function(){E()&&y({type:l.resetSelectedRows})}),[y,n]);var I=t.useCallback((function(e){return y({type:l.toggleAllRowsSelected,value:e})}),[y]),P=t.useCallback((function(e){return y({type:l.toggleAllPageRowsSelected,value:e})}),[y]),B=t.useCallback((function(e,t){return y({type:l.toggleRowSelected,id:e,value:t})}),[y]),D=m(e),k=f(o().getToggleAllRowsSelectedProps,{instance:D()}),A=f(o().getToggleAllPageRowsSelectedProps,{instance:D()});Object.assign(e,{selectedFlatRows:x,isAllRowsSelected:C,isAllPageRowsSelected:S,toggleRowSelected:B,toggleAllRowsSelected:I,getToggleAllRowsSelectedProps:k,getToggleAllPageRowsSelectedProps:A,toggleAllPageRowsSelected:P})}function wt(e,t){var n=t.instance;e.toggleRowSelected=function(t){return n.toggleRowSelected(e.id,t)},e.getToggleRowSelectedProps=f(n.getHooks().getToggleRowSelectedProps,{instance:n,row:e})}var Rt=function(e){return{}},xt=function(e){return{}};l.setRowState="setRowState",l.setCellState="setCellState",l.resetRowState="resetRowState";var Ct=function(e){e.stateReducers.push(St),e.useInstance.push(Et),e.prepareRow.push(It)};function St(e,t,n,r){var i=r.initialRowStateAccessor,a=void 0===i?Rt:i,s=r.initialCellStateAccessor,u=void 0===s?xt:s,c=r.rowsById;if(t.type===l.init)return o({rowState:{}},e);if(t.type===l.resetRowState)return o({},e,{rowState:r.initialState.rowState||{}});if(t.type===l.setRowState){var d,f=t.rowId,g=t.value,p=void 0!==e.rowState[f]?e.rowState[f]:a(c[f]);return o({},e,{rowState:o({},e.rowState,(d={},d[f]=h(g,p),d))})}if(t.type===l.setCellState){var v,m,y,b,w,R=t.rowId,x=t.columnId,C=t.value,S=void 0!==e.rowState[R]?e.rowState[R]:a(c[R]),E=void 0!==(null==S||null==(v=S.cellState)?void 0:v[x])?S.cellState[x]:u(null==(m=c[R])||null==(y=m.cells)?void 0:y.find((function(e){return e.column.id===x})));return o({},e,{rowState:o({},e.rowState,(w={},w[R]=o({},S,{cellState:o({},S.cellState||{},(b={},b[x]=h(C,E),b))}),w))})}}function Et(e){var n=e.autoResetRowState,r=void 0===n||n,o=e.data,i=e.dispatch,a=t.useCallback((function(e,t){return i({type:l.setRowState,rowId:e,value:t})}),[i]),s=t.useCallback((function(e,t,n){return i({type:l.setCellState,rowId:e,columnId:t,value:n})}),[i]),u=m(r);b((function(){u()&&i({type:l.resetRowState})}),[o]),Object.assign(e,{setRowState:a,setCellState:s})}function It(e,t){var n=t.instance,r=n.initialRowStateAccessor,o=void 0===r?Rt:r,i=n.initialCellStateAccessor,a=void 0===i?xt:i,l=n.state.rowState;e&&(e.state=void 0!==l[e.id]?l[e.id]:o(e),e.setState=function(t){return n.setRowState(e.id,t)},e.cells.forEach((function(t){e.state.cellState||(e.state.cellState={}),t.state=void 0!==e.state.cellState[t.column.id]?e.state.cellState[t.column.id]:a(t),t.setState=function(r){return n.setCellState(e.id,t.column.id,r)}})))}Ct.pluginName="useRowState",l.resetColumnOrder="resetColumnOrder",l.setColumnOrder="setColumnOrder";var Pt=function(e){e.stateReducers.push(Bt),e.visibleColumnsDeps.push((function(e,t){var n=t.instance;return[].concat(e,[n.state.columnOrder])})),e.visibleColumns.push(Dt),e.useInstance.push(kt)};function Bt(e,t,n,r){return t.type===l.init?o({columnOrder:[]},e):t.type===l.resetColumnOrder?o({},e,{columnOrder:r.initialState.columnOrder||[]}):t.type===l.setColumnOrder?o({},e,{columnOrder:h(t.columnOrder,e.columnOrder)}):void 0}function Dt(e,t){var n=t.instance.state.columnOrder;if(!n||!n.length)return e;for(var r=[].concat(n),o=[].concat(e),i=[],a=function(){var e=r.shift(),t=o.findIndex((function(t){return t.id===e}));t>-1&&i.push(o.splice(t,1)[0])};o.length&&r.length;)a();return[].concat(i,o)}function kt(e){var n=e.dispatch;e.setColumnOrder=t.useCallback((function(e){return n({type:l.setColumnOrder,columnOrder:e})}),[n])}Pt.pluginName="useColumnOrder",c.canResize=!0,l.columnStartResizing="columnStartResizing",l.columnResizing="columnResizing",l.columnDoneResizing="columnDoneResizing",l.resetResize="resetResize";var At=function(e){e.getResizerProps=[Ot],e.getHeaderProps.push({style:{position:"relative"}}),e.stateReducers.push(Ft),e.useInstance.push(Tt),e.useInstanceBeforeDimensions.push(Mt)},Ot=function(e,t){var n=t.instance,r=t.header,o=n.dispatch,i=function(e,t){var n=!1;if("touchstart"===e.type){if(e.touches&&e.touches.length>1)return;n=!0}var r=function(e){var t=[];return function e(n){n.columns&&n.columns.length&&n.columns.map(e),t.push(n)}(e),t}(t).map((function(e){return[e.id,e.totalWidth]})),i=n?Math.round(e.touches[0].clientX):e.clientX,a=function(e){o({type:l.columnResizing,clientX:e})},s=function(){return o({type:l.columnDoneResizing})},u={mouse:{moveEvent:"mousemove",moveHandler:function(e){return a(e.clientX)},upEvent:"mouseup",upHandler:function(e){document.removeEventListener("mousemove",u.mouse.moveHandler),document.removeEventListener("mouseup",u.mouse.upHandler),s()}},touch:{moveEvent:"touchmove",moveHandler:function(e){return e.cancelable&&(e.preventDefault(),e.stopPropagation()),a(e.touches[0].clientX),!1},upEvent:"touchend",upHandler:function(e){document.removeEventListener(u.touch.moveEvent,u.touch.moveHandler),document.removeEventListener(u.touch.upEvent,u.touch.moveHandler),s()}}},c=n?u.touch:u.mouse,d=!!function(){if("boolean"==typeof M)return M;var e=!1;try{var t={get passive(){return e=!0,!1}};window.addEventListener("test",null,t),window.removeEventListener("test",null,t)}catch(t){e=!1}return M=e}()&&{passive:!1};document.addEventListener(c.moveEvent,c.moveHandler,d),document.addEventListener(c.upEvent,c.upHandler,d),o({type:l.columnStartResizing,columnId:t.id,columnWidth:t.totalWidth,headerIdWidths:r,clientX:i})};return[e,{onMouseDown:function(e){return e.persist()||i(e,r)},onTouchStart:function(e){return e.persist()||i(e,r)},style:{cursor:"col-resize"},draggable:!1,role:"separator"}]};function Ft(e,t){if(t.type===l.init)return o({columnResizing:{columnWidths:{}}},e);if(t.type===l.resetResize)return o({},e,{columnResizing:{columnWidths:{}}});if(t.type===l.columnStartResizing){var n=t.clientX,r=t.columnId,i=t.columnWidth,a=t.headerIdWidths;return o({},e,{columnResizing:o({},e.columnResizing,{startX:n,headerIdWidths:a,columnWidth:i,isResizingColumn:r})})}if(t.type===l.columnResizing){var s=t.clientX,u=e.columnResizing,c=u.startX,d=u.columnWidth,f=u.headerIdWidths,g=(s-c)/d,p={};return(void 0===f?[]:f).forEach((function(e){var t=e[0],n=e[1];p[t]=Math.max(n+n*g,0)})),o({},e,{columnResizing:o({},e.columnResizing,{columnWidths:o({},e.columnResizing.columnWidths,{},p)})})}return t.type===l.columnDoneResizing?o({},e,{columnResizing:o({},e.columnResizing,{startX:null,isResizingColumn:null})}):void 0}At.pluginName="useResizeColumns";var Mt=function(e){var t=e.flatHeaders,n=e.disableResizing,r=e.getHooks,o=e.state.columnResizing,i=m(e);t.forEach((function(e){var t=P(!0!==e.disableResizing&&void 0,!0!==n&&void 0,!0);e.canResize=t,e.width=o.columnWidths[e.id]||e.originalWidth||e.width,e.isResizing=o.isResizingColumn===e.id,t&&(e.getResizerProps=f(r().getResizerProps,{instance:i(),header:e}))}))};function Tt(e){var n=e.plugins,r=e.dispatch,o=e.autoResetResize,i=void 0===o||o,a=e.columns;v(n,["useAbsoluteLayout"],"useResizeColumns");var s=m(i);b((function(){s()&&r({type:l.resetResize})}),[a]);var u=t.useCallback((function(){return r({type:l.resetResize})}),[r]);Object.assign(e,{resetResizing:u})}var Nt={position:"absolute",top:0},Gt=function(e){e.getTableBodyProps.push(Lt),e.getRowProps.push(Lt),e.getHeaderGroupProps.push(Lt),e.getFooterGroupProps.push(Lt),e.getHeaderProps.push((function(e,t){var n=t.column;return[e,{style:o({},Nt,{left:n.totalLeft+"px",width:n.totalWidth+"px"})}]})),e.getCellProps.push((function(e,t){var n=t.cell;return[e,{style:o({},Nt,{left:n.column.totalLeft+"px",width:n.column.totalWidth+"px"})}]})),e.getFooterProps.push((function(e,t){var n=t.column;return[e,{style:o({},Nt,{left:n.totalLeft+"px",width:n.totalWidth+"px"})}]}))};Gt.pluginName="useAbsoluteLayout";var Lt=function(e,t){return[e,{style:{position:"relative",width:t.instance.totalColumnsWidth+"px"}}]},zt={display:"inline-block",boxSizing:"border-box"},Ht=function(e,t){return[e,{style:{display:"flex",width:t.instance.totalColumnsWidth+"px"}}]},jt=function(e){e.getRowProps.push(Ht),e.getHeaderGroupProps.push(Ht),e.getFooterGroupProps.push(Ht),e.getHeaderProps.push((function(e,t){var n=t.column;return[e,{style:o({},zt,{width:n.totalWidth+"px"})}]})),e.getCellProps.push((function(e,t){var n=t.cell;return[e,{style:o({},zt,{width:n.column.totalWidth+"px"})}]})),e.getFooterProps.push((function(e,t){var n=t.column;return[e,{style:o({},zt,{width:n.totalWidth+"px"})}]}))};function Wt(e){e.getTableProps.push(Vt),e.getRowProps.push(Xt),e.getHeaderGroupProps.push(Xt),e.getFooterGroupProps.push(Xt),e.getHeaderProps.push(_t),e.getCellProps.push(qt),e.getFooterProps.push(Ut)}jt.pluginName="useBlockLayout",Wt.pluginName="useFlexLayout";var Vt=function(e,t){return[e,{style:{minWidth:t.instance.totalColumnsMinWidth+"px"}}]},Xt=function(e,t){return[e,{style:{display:"flex",flex:"1 0 auto",minWidth:t.instance.totalColumnsMinWidth+"px"}}]},_t=function(e,t){var n=t.column;return[e,{style:{boxSizing:"border-box",flex:n.totalFlexWidth?n.totalFlexWidth+" 0 auto":void 0,minWidth:n.totalMinWidth+"px",width:n.totalWidth+"px"}}]},qt=function(e,t){var n=t.cell;return[e,{style:{boxSizing:"border-box",flex:n.column.totalFlexWidth+" 0 auto",minWidth:n.column.totalMinWidth+"px",width:n.column.totalWidth+"px"}}]},Ut=function(e,t){var n=t.column;return[e,{style:{boxSizing:"border-box",flex:n.totalFlexWidth?n.totalFlexWidth+" 0 auto":void 0,minWidth:n.totalMinWidth+"px",width:n.totalWidth+"px"}}]};function Yt(e){e.stateReducers.push($t),e.getTableProps.push(Kt),e.getHeaderProps.push(Jt)}Yt.pluginName="useGridLayout";var Kt=function(e,t){return[e,{style:{display:"grid",gridTemplateColumns:t.instance.state.gridLayout.columnWidths.map((function(e){return e})).join(" ")}}]},Jt=function(e,t){return[e,{id:"header-cell-"+t.column.id,style:{position:"sticky"}}]};function $t(e,t,n,r){if("init"===t.type)return o({gridLayout:{columnWidths:r.columns.map((function(){return"auto"}))}},e);if("columnStartResizing"===t.type){var i=t.columnId,a=r.visibleColumns.findIndex((function(e){return e.id===i})),l=function(e){var t,n=null==(t=document.getElementById("header-cell-"+e))?void 0:t.offsetWidth;if(void 0!==n)return n}(i);return void 0!==l?o({},e,{gridLayout:o({},e.gridLayout,{columnId:i,columnIndex:a,startingWidth:l})}):e}if("columnResizing"===t.type){var s=e.gridLayout,u=s.columnIndex,c=s.startingWidth,d=s.columnWidths,f=c-(e.columnResizing.startX-t.clientX),g=[].concat(d);return g[u]=f+"px",o({},e,{gridLayout:o({},e.gridLayout,{columnWidths:g})})}}e._UNSTABLE_usePivotColumns=tt,e.actions=l,e.defaultColumn=c,e.defaultGroupByFn=je,e.defaultOrderByFn=$e,e.defaultRenderer=s,e.emptyRenderer=u,e.ensurePluginOrder=v,e.flexRender=R,e.functionalUpdate=h,e.loopHooks=p,e.makePropGetter=f,e.makeRenderer=w,e.reduceHooks=g,e.safeUseLayoutEffect=y,e.useAbsoluteLayout=Gt,e.useAsyncDebounce=function(e,n){void 0===n&&(n=0);var o=t.useRef({}),i=m(e),a=m(n);return t.useCallback(function(){var e=r(regeneratorRuntime.mark((function e(){var t,n,l,s=arguments;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:for(t=s.length,n=new Array(t),l=0;l<t;l++)n[l]=s[l];return o.current.promise||(o.current.promise=new Promise((function(e,t){o.current.resolve=e,o.current.reject=t}))),o.current.timeout&&clearTimeout(o.current.timeout),o.current.timeout=setTimeout(r(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return delete o.current.timeout,e.prev=1,e.t0=o.current,e.next=5,i().apply(void 0,n);case 5:e.t1=e.sent,e.t0.resolve.call(e.t0,e.t1),e.next=12;break;case 9:e.prev=9,e.t2=e.catch(1),o.current.reject(e.t2);case 12:return e.prev=12,delete o.current.promise,e.finish(12);case 15:case"end":return e.stop()}}),e,null,[[1,9,12,15]])}))),a()),e.abrupt("return",o.current.promise);case 5:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),[i,a])},e.useBlockLayout=jt,e.useColumnOrder=Pt,e.useExpanded=le,e.useFilters=Se,e.useFlexLayout=Wt,e.useGetLatest=m,e.useGlobalFilter=Pe,e.useGridLayout=Yt,e.useGroupBy=Me,e.useMountedLayoutEffect=b,e.usePagination=Ze,e.useResizeColumns=At,e.useRowSelect=pt,e.useRowState=Ct,e.useSortBy=Ue,e.useTable=function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];e=oe(e),r=[q].concat(r);var a=m(t.useRef({}).current);Object.assign(a(),o({},e,{plugins:r,hooks:_()})),r.filter(Boolean).forEach((function(e){e(a().hooks)}));var s=m(a().hooks);a().getHooks=s,delete a().hooks,Object.assign(a(),g(s().useOptions,oe(e)));var u=a(),c=u.data,d=u.columns,v=u.initialState,h=u.defaultColumn,y=u.getSubRows,b=u.getRowId,R=u.stateReducer,I=u.useControlledState,P=m(R),B=t.useCallback((function(e,t){if(!t.type)throw console.info({action:t}),new Error("Unknown Action 👆");return[].concat(s().stateReducers,Array.isArray(P())?P():[P()]).reduce((function(n,r){return r(n,t,e,a())||n}),e)}),[s,P,a]),D=t.useReducer(B,void 0,(function(){return B(v,{type:l.init})})),k=D[0],A=D[1],O=g([].concat(s().useControlledState,[I]),k,{instance:a()});Object.assign(a(),{state:O,dispatch:A});var F=t.useMemo((function(){return x(g(s().columns,d,{instance:a()}))}),[s,a,d].concat(g(s().columnsDeps,[],{instance:a()})));a().columns=F;var M=t.useMemo((function(){return g(s().allColumns,C(F),{instance:a()}).map(S)}),[F,s,a].concat(g(s().allColumnsDeps,[],{instance:a()})));a().allColumns=M;var T=t.useMemo((function(){for(var e=[],t=[],n={},r=[].concat(M);r.length;){var o=r.shift();ae({data:c,rows:e,flatRows:t,rowsById:n,column:o,getRowId:b,getSubRows:y,accessValueHooks:s().accessValue,getInstance:a})}return[e,t,n]}),[M,c,b,y,s,a]),N=T[0],G=T[1],L=T[2];Object.assign(a(),{rows:N,initialRows:[].concat(N),flatRows:G,rowsById:L}),p(s().useInstanceAfterData,a());var z=t.useMemo((function(){return g(s().visibleColumns,M,{instance:a()}).map((function(e){return E(e,h)}))}),[s,M,a,h].concat(g(s().visibleColumnsDeps,[],{instance:a()})));M=t.useMemo((function(){var e=[].concat(z);return M.forEach((function(t){e.find((function(e){return e.id===t.id}))||e.push(t)})),e}),[M,z]),a().allColumns=M;var H=t.useMemo((function(){return g(s().headerGroups,function(e,t,n){void 0===n&&(n=function(){return{}});for(var r=[],i=e,a=0,l=function(){return a++},s=function(){var e={headers:[]},a=[],s=i.some((function(e){return e.parent}));i.forEach((function(r){var i,u=[].concat(a).reverse()[0];s&&(i=r.parent?o({},r.parent,{originalId:r.parent.id,id:r.parent.id+"_"+l(),headers:[r]},n(r)):E(o({originalId:r.id+"_placeholder",id:r.id+"_placeholder_"+l(),placeholderOf:r,headers:[r]},n(r)),t),u&&u.originalId===i.originalId?u.headers.push(r):a.push(i)),e.headers.push(r)})),r.push(e),i=a};i.length;)s();return r.reverse()}(z,h),a())}),[s,z,h,a].concat(g(s().headerGroupsDeps,[],{instance:a()})));a().headerGroups=H;var j=t.useMemo((function(){return H.length?H[0].headers:[]}),[H]);a().headers=j,a().flatHeaders=H.reduce((function(e,t){return[].concat(e,t.headers)}),[]),p(s().useInstanceBeforeDimensions,a());var W=z.filter((function(e){return e.isVisible})).map((function(e){return e.id})).sort().join("_");z=t.useMemo((function(){return z.filter((function(e){return e.isVisible}))}),[z,W]),a().visibleColumns=z;var V=ie(j),X=V[0],U=V[1],Y=V[2];return a().totalColumnsMinWidth=X,a().totalColumnsWidth=U,a().totalColumnsMaxWidth=Y,p(s().useInstance,a()),[].concat(a().flatHeaders,a().allColumns).forEach((function(e){e.render=w(a(),e),e.getHeaderProps=f(s().getHeaderProps,{instance:a(),column:e}),e.getFooterProps=f(s().getFooterProps,{instance:a(),column:e})})),a().headerGroups=t.useMemo((function(){return H.filter((function(e,t){return e.headers=e.headers.filter((function(e){return e.headers?function e(t){return t.filter((function(t){return t.headers?e(t.headers):t.isVisible})).length}(e.headers):e.isVisible})),!!e.headers.length&&(e.getHeaderGroupProps=f(s().getHeaderGroupProps,{instance:a(),headerGroup:e,index:t}),e.getFooterGroupProps=f(s().getFooterGroupProps,{instance:a(),headerGroup:e,index:t}),!0)}))}),[H,a,s]),a().footerGroups=[].concat(a().headerGroups).reverse(),a().prepareRow=t.useCallback((function(e){e.getRowProps=f(s().getRowProps,{instance:a(),row:e}),e.allCells=M.map((function(t){var n=e.values[t.id],r={column:t,row:e,value:n};return r.getCellProps=f(s().getCellProps,{instance:a(),cell:r}),r.render=w(a(),t,{row:e,cell:r,value:n}),r})),e.cells=z.map((function(t){return e.allCells.find((function(e){return e.column.id===t.id}))})),p(s().prepareRow,e,{instance:a()})}),[s,a,M,z]),a().getTableProps=f(s().getTableProps,{instance:a()}),a().getTableBodyProps=f(s().getTableBodyProps,{instance:a()}),p(s().useFinalInstance,a()),a()},Object.defineProperty(e,"__esModule",{value:!0})}(t,n(32735))},35509:(e,t,n)=>{e.exports=n(52178)}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_clickview_reports=self.webpackChunk_clickview_reports||[]).push([[691],{21614:(e,a,t)=>{t.d(a,{U:()=>d});var n=t(32735),r=t(23481),i=t(59710),c=t(92209),s=t(28512),l=t(99827),o=r.T.encloseNamespace("reportsClips.clipNav");function d(e){var a,t,r=(a=(0,l.b)(),t=[e.id],[{label:o("overview"),appLink:{application:s.O.CLIPS,action:c.e.Clips.OVERVIEW,args:t,params:a}},{label:o("engagement"),appLink:{application:s.O.CLIPS,action:c.e.Clips.ENGAGEMENT,args:t,params:a}}]);return n.createElement(i.m,{items:r})}},2750:(e,a,t)=>{t.r(a),t.d(a,{ClipOverviewView:()=>y});var n=t(32735),r=t(23481),i=t(20354),c=t(16714),s=t(22902),l=t(79612),o=t(48187),d=t(36630),u=t(55554),m=t(87480),p=t(21295),v=t(44422),h=t(59699),g=t(7184),f=t(21614);const E={column1:"HllzM",column2:"s9YKB",barChart:"vxOP0"};var b=r.T.encloseNamespace("reportsClips.clipOverview");function y(e){var a,t,r=i.a.useBasicFetch(o.e.clip(e.id));(0,l.M)({title:b("pageTitle",{clip:null===(a=r.data)||void 0===a?void 0:a.name})}),(0,m.U)(null===(t=r.data)||void 0===t?void 0:t.name),(0,u._)((0,p.yH)(r.data)),(0,d.M)(r);var y=!(0,(0,s.T)().hasPermissions)(c.C.ViewCustomerAnalytics);return n.createElement("div",null,n.createElement(f.U,{id:e.id}),n.createElement("div",{className:"d-flex"},n.createElement("div",{className:"pe-2 ".concat(E.column1)},n.createElement(g.m,{objectId:e.id,useSharerId:y,className:"h-100"})),n.createElement("div",{className:"ps-2 ".concat(E.column2)},n.createElement(h.Y,{objectId:e.id,className:E.barChart,useSharerId:y}),n.createElement("div",{className:"mt-3"},n.createElement(v.D,{objectId:e.id,useSharerId:y,layout:"horizontal"})))))}},79939:(e,a,t)=>{t.d(a,{M:()=>i});var n=t(32735),r=t(30114);function i(){return n.createElement("div",{className:"partial-loading-background mb-2 ".concat(r.Z.partialHeading)})}},15184:(e,a,t)=>{t.d(a,{P:()=>O});var n=t(32735),r=t(72306),i=t.n(r),c=t(70312),s=t.n(c),l=t(99827),o=t(99183),d=t(75896),u=t(110),m=t(85408),p=t(39709),v={MONTH:35,YEAR:365},h={day:"YYYY-MM-DD",month:"YYYY-MM",year:"YYYY"},g={day:"D MMM",month:"MMM",year:"YYYY"},f={enabled:!0,align:"right",verticalAlign:"top",floating:!0,y:-45},E={title:{text:null},credits:{enabled:!1},yAxis:{title:{text:null},min:0,minRange:10,minPadding:0,maxPadding:.02,endOnTick:!1},chart:{backgroundColor:"transparent",spacing:[45,0,0,0]},plotOptions:{series:{stacking:"normal"}}};function b(e,a,t){var n=function(e,a,t){var n=function(e){var a=u.O.diffBetween(e.end,e.start,"day");return a>v.YEAR?"year":a>v.MONTH?"month":"day"}(t),r=function(e,a){var t=[],n=u.O.format(e.start,h[a]);do{t.push(n),n=u.O.format(u.O.add(n,1,a),h[a])}while(!u.O.isAfter(n,e.end,a));return t}(t,n),i={};e.forEach((function(e){var t,r;if(e.userType){var c=u.O.format(u.O.convertUTCToLocal(a(e)),h[n]);i[e.userType]=null!==(t=i[e.userType])&&void 0!==t?t:{},i[e.userType][c]=null!==(r=i[e.userType][c])&&void 0!==r?r:0,i[e.userType][c]+=e.count}}));var c=Object.keys(i),s=c.length?d.m.sortBy(c.map((function(e){return{name:(0,p.j)(e),type:"column",data:r.map((function(a){var t;return null!==(t=i[e][a])&&void 0!==t?t:0}))}})),"name"):[{type:"column",data:r.map((function(){return 0}))}],l=Object.assign({},f);return c.length||(l.enabled=!1),{categories:r.map((function(e){return u.O.format(e,g[n])})),legendOptions:l,seriesData:(0,m.n)(s)}}(e,a,t);return Object.assign(Object.assign({},E),{xAxis:{categories:n.categories},legend:n.legendOptions,series:n.seriesData})}var y=t(30114);function O(e){var a=(0,l.R)();return(0,o.I)(),n.createElement("div",{className:"position-relative h-100"},n.createElement("h3",{className:"h6 ".concat(y.Z.heading)},e.title),!!a&&n.createElement(s(),{highcharts:i(),options:b(e.events,e.getEventDate,a),containerProps:{className:"".concat(y.Z.chartContainer," position-absolute w-100 h-100")}}))}},48187:(e,a,t)=>{t.d(a,{e:()=>n});var n={clip:function(e,a,t,n){return{url:"{gateway}/v1/objects/".concat(e),key:"clip:".concat(e),success:a,error:t,always:n}}}},59699:(e,a,t)=>{t.d(a,{Y:()=>v});var n=t(32735),r=t(23481),i=t(20354),c=t(31949),s=t(16562),l=t(79939),o=t(15184),d=t(9537),u=t(99827),m=t(9977),p=r.T.encloseNamespace("shared.viewCountBarChartCard");function v(e){var a,t=(0,u.R)(),r=i.a.useBasicFetch(!!e.useSharerId&&c.N.currentUser()),v=i.a.useBasicFetch(!!t&&(e.useSharerId?!!r.data&&d.u.views(t,e.objectId,r.data.id):d.u.views(t,e.objectId)));return(0,s.v)(v),(0,m.n)(v),n.createElement("div",{className:"bg-white rounded p-3 ".concat(null!==(a=e.className)&&void 0!==a?a:"")},v.data?n.createElement(o.P,{events:v.data.data,getEventDate:function(e){return e.groupedDateWatched},title:p("videoViews")}):n.createElement(l.M,null))}},30114:(e,a,t)=>{t.d(a,{Z:()=>n});const n={chartContainer:"_KT3q",heading:"Cfb8d",partialHeading:"Ydnic"}}}]);