@dcl/builder-site 7.16.2-19654915580.commit-bdffb26 → 7.17.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 (85) hide show
  1. package/assets/{Back-MtsmBnan.js → Back-CncB3o4T.js} +1 -1
  2. package/assets/{CollectionProvider.container-FUe4tS-3.js → CollectionProvider.container-CD3TWvFB.js} +1 -1
  3. package/assets/{CollectionStatus.container-IqqvCQPx.js → CollectionStatus.container-BPchWQUD.js} +1 -1
  4. package/assets/{ConfirmDelete-DO_4Toph.js → ConfirmDelete-BvGTAe45.js} +1 -1
  5. package/assets/{FileSaver.min-DeaWgxpY.js → FileSaver.min-Dg7bIGCI.js} +1 -1
  6. package/assets/{ItemProvider.container-1h7f1i_E.js → ItemProvider.container-QONgvAiC.js} +2 -2
  7. package/assets/{JumpIn.container-KLd2kDlm.js → JumpIn.container-AE58qhmT.js} +1 -1
  8. package/assets/{LandAction-BYrPmZTM.js → LandAction-Bo3Q-UiE.js} +1 -1
  9. package/assets/{LandProviderPage-6AeevoX5.js → LandProviderPage-BtxZ9fV8.js} +1 -1
  10. package/assets/{LoggedInDetailPage.container-aKqZJkZw.js → LoggedInDetailPage.container-CsvKBMuj.js} +1 -1
  11. package/assets/{Navigation-DD33GB48.css → Navigation-Bt17L3k8.css} +1 -1
  12. package/assets/{Navigation.container-CKqSZREi.js → Navigation.container-Uoa9cAN5.js} +1 -1
  13. package/assets/{NotFound-BHz1EMnb.js → NotFound-4sT-K9SU.js} +1 -1
  14. package/assets/{OptionsDropdown-WGcTxTAQ.js → OptionsDropdown-CKwEKh_m.js} +1 -1
  15. package/assets/{RentalPeriod-B3bdRc4q.js → RentalPeriod-S_0N5yaP.js} +1 -1
  16. package/assets/{SDKTag-CMe25jMK.js → SDKTag-C-O7sptA.js} +1 -1
  17. package/assets/{SceneStats.container-B92uiAn7.js → SceneStats.container-Dh-TTGFp.js} +1 -1
  18. package/assets/{SignInRequired-CGzWIVAU.js → SignInRequired-BIpJsBqT.js} +1 -1
  19. package/assets/{ThirdPartyKindBadge-BIsjN3SR.js → ThirdPartyKindBadge-BN8ggssH.js} +1 -1
  20. package/assets/{dataReader-Co-z3TzR.js → dataReader-DJcrOVif.js} +1 -1
  21. package/assets/{date-CQXTob_w.js → date-CZsUie1B.js} +1 -1
  22. package/assets/{fortmatic-B1zGz8tZ.js → fortmatic-CYvj3-Jb.js} +1 -1
  23. package/assets/{hooks-NbgarCWS.js → hooks-DXNgH_m2.js} +1 -1
  24. package/assets/index-B2Xzk_Ov.css +1 -0
  25. package/assets/{index-Cq6VboM0.js → index-B90FxvBn.js} +1 -1
  26. package/assets/{index-CIiu4aJp.js → index-BM_phcrK.js} +1 -1
  27. package/assets/{index-BXVcTi-l.js → index-BRLowEIM.js} +1 -1
  28. package/assets/{index-CLQF8ych.js → index-BRw7dj1X.js} +1 -1
  29. package/assets/{index-B2wUd30T.js → index-BWdryV1d.js} +1 -1
  30. package/assets/{index-CjxNb5Ix.js → index-B_smWDsS.js} +1 -1
  31. package/assets/{index-c1n4wbjs.js → index-BcJ8MhYC.js} +24 -24
  32. package/assets/{index-C4vCgXy5.js → index-BcjjfgH-.js} +1 -1
  33. package/assets/index-Bd-Yq1oE.js +1 -0
  34. package/assets/{index-a9IdsuOP.js → index-Bj_YcMD7.js} +1 -1
  35. package/assets/{index-CuEPNcPz.js → index-Bvxiv59-.js} +1 -1
  36. package/assets/{index-avCw7DV7.js → index-ByLmQ-CK.js} +1 -1
  37. package/assets/{index-D-ObZLVh.js → index-C5iQL77p.js} +1 -1
  38. package/assets/{index-fYmt4Nc-.js → index-CBtGoL1F.js} +1 -1
  39. package/assets/{index-BaMFaBKy.js → index-CGMgDr0o.js} +1 -1
  40. package/assets/{index-DpTh39DC.js → index-CMgHsYV6.js} +1 -1
  41. package/assets/{index-BG6mpSUl.js → index-CN86XliR.js} +1 -1
  42. package/assets/index-CPJuM5bC.js +1 -0
  43. package/assets/{index-cMBSLKGj.js → index-CPknQw8k.js} +1 -1
  44. package/assets/{index-Cm9UVLRs.js → index-CXbpVbSz.js} +1 -1
  45. package/assets/index-CdWcLYVd.js +1 -0
  46. package/assets/{index-DerTtriV.js → index-Cg_PYXls.js} +1 -1
  47. package/assets/index-ChRpi1rW.js +2 -0
  48. package/assets/{index-BO29otrH.js → index-CixSQqWW.js} +1 -1
  49. package/assets/{index-DZgmNkVd.js → index-Cnr1P3Xj.js} +1 -1
  50. package/assets/{index-DlQ0klix.js → index-CpibsF0Z.js} +1 -1
  51. package/assets/{index-CxdXIPJE.js → index-CtRxWoCW.js} +2 -2
  52. package/assets/index-CuNxZfi7.css +1 -0
  53. package/assets/{index-2u_SPYmH.js → index-Cubp4xIl.js} +1 -1
  54. package/assets/{index-B7xueszZ.js → index-Cwwvy4BS.js} +1 -1
  55. package/assets/{index-1bLnyB-6.js → index-D5UYQxDV.js} +1 -1
  56. package/assets/{index-D_2T_ZN4.js → index-D84ioOJ4.js} +1 -1
  57. package/assets/{index-C_v9FJod.js → index-DDtHVlhA.js} +1 -1
  58. package/assets/index-DOu2R82n.css +1 -0
  59. package/assets/{index-CLCP8yxv.js → index-DQl3Ihkd.js} +1 -1
  60. package/assets/index-Da5K-OVa.js +1 -0
  61. package/assets/{index-lXjeKPnR.js → index-DilEbCYA.js} +1 -1
  62. package/assets/{index-B4DS5-h7.js → index-DkdR6D1n.js} +1 -1
  63. package/assets/{index-DC3ZLmPf.css → index-Dl1hLSOh.css} +1 -1
  64. package/assets/index-DrKQAU9n.css +1 -0
  65. package/assets/{index-CyEQ1ZEZ.js → index-EXCDxiHh.js} +1 -1
  66. package/assets/{index-CDu_EOX9.css → index-G5g_lqVY.css} +1 -1
  67. package/assets/{index-Cf_YNN5m.js → index-MzNAR7ES.js} +1 -1
  68. package/assets/{index-CTx4SGv0.js → index-ONTdrfoq.js} +1 -1
  69. package/assets/{index-ClGiOWuF.css → index-bzHqEpBm.css} +7 -7
  70. package/assets/{index-B6ie7x4m.js → index-m2Cs5HA_.js} +1 -1
  71. package/assets/{index-BK3KJTyn.js → index-q0Hp3cUL.js} +1 -1
  72. package/assets/{index-DgVTxtrh.js → index-uqyPr3xj.js} +1 -1
  73. package/assets/{index.es-B1IsdcNf.js → index.es-D5ysKyju.js} +4 -4
  74. package/assets/{selectors-qQAG8WAy.js → selectors-DHi87VFf.js} +1 -1
  75. package/index.html +3 -3
  76. package/package.json +2 -2
  77. package/assets/index-B7WykCXI.css +0 -1
  78. package/assets/index-BIiYOkoe.js +0 -2
  79. package/assets/index-B_IdoYDd.js +0 -1
  80. package/assets/index-CXFmJEUo.js +0 -1
  81. package/assets/index-DLqrJzHs.css +0 -1
  82. package/assets/index-DYQhNcNF.css +0 -1
  83. package/assets/index-Dy-lfQzQ.js +0 -1
  84. package/assets/index-LOuXThU1.css +0 -1
  85. package/assets/index-VGxCo8Ow.js +0 -1
@@ -1 +1 @@
1
- var ue=Object.defineProperty;var he=(n,t,e)=>t in n?ue(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e;var v=(n,t,e)=>he(n,typeof t!="symbol"?t+"":t,e);import{c0 as x,c1 as b,cm as j,hS as ge,gB as C,gN as fe,a4 as me,J as A,hT as K,R as ve,N as o,M as c,S as l,dM as pe,eZ as J,bQ as V,T as re,aM as Te,eC as we,a2 as Ce,eE as xe,ak as _e,eF as O,b6 as be,hU as ye,eH as Ee,eK as De,ej as Oe,bd as Se,hV as Pe,ad as je,bq as $,hW as Me,eM as Ne,gE as Le,eP as Ue,eT as ke,hX as Re,eV as Ye,hY as Ae}from"./index-c1n4wbjs.js";import{d as Ie,e as We,c as Fe}from"./selectors-qQAG8WAy.js";import{N as Be}from"./NotFound-BHz1EMnb.js";import{L as He}from"./LoggedInDetailPage.container-aKqZJkZw.js";import{N as qe}from"./Navigation.container-CKqSZREi.js";import{C as $e}from"./CollectionStatus.container-IqqvCQPx.js";import{C as Ge,T as Qe}from"./ThirdPartyKindBadge-BIsjN3SR.js";import{s as I,a as Ve}from"./date-CQXTob_w.js";import{g as X,e as Xe,l as Ke}from"./index-Cf_YNN5m.js";import"./SignInRequired-CGzWIVAU.js";function Je(n,t){x(2,arguments);var e=b(n).getTime(),a=j(t);return new Date(e+a)}function Ze(n){return x(1,arguments),n instanceof Date||ge(n)==="object"&&Object.prototype.toString.call(n)==="[object Date]"}function ze(n){if(x(1,arguments),!Ze(n)&&typeof n!="number")return!1;var t=b(n);return!isNaN(Number(t))}function et(n,t){x(2,arguments);var e=j(t);return Je(n,-e)}var tt=864e5;function at(n){x(1,arguments);var t=b(n),e=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var a=t.getTime(),r=e-a;return Math.floor(r/tt)+1}function W(n){x(1,arguments);var t=1,e=b(n),a=e.getUTCDay(),r=(a<t?7:0)+a-t;return e.setUTCDate(e.getUTCDate()-r),e.setUTCHours(0,0,0,0),e}function ne(n){x(1,arguments);var t=b(n),e=t.getUTCFullYear(),a=new Date(0);a.setUTCFullYear(e+1,0,4),a.setUTCHours(0,0,0,0);var r=W(a),i=new Date(0);i.setUTCFullYear(e,0,4),i.setUTCHours(0,0,0,0);var s=W(i);return t.getTime()>=r.getTime()?e+1:t.getTime()>=s.getTime()?e:e-1}function rt(n){x(1,arguments);var t=ne(n),e=new Date(0);e.setUTCFullYear(t,0,4),e.setUTCHours(0,0,0,0);var a=W(e);return a}var nt=6048e5;function it(n){x(1,arguments);var t=b(n),e=W(t).getTime()-rt(t).getTime();return Math.round(e/nt)+1}function ie(n,t){var e,a,r,i,s,u,f,h;x(1,arguments);var p=b(n),T=p.getUTCFullYear(),g=X(),m=j((e=(a=(r=(i=t==null?void 0:t.firstWeekContainsDate)!==null&&i!==void 0?i:t==null||(s=t.locale)===null||s===void 0||(u=s.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&r!==void 0?r:g.firstWeekContainsDate)!==null&&a!==void 0?a:(f=g.locale)===null||f===void 0||(h=f.options)===null||h===void 0?void 0:h.firstWeekContainsDate)!==null&&e!==void 0?e:1);if(!(m>=1&&m<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var _=new Date(0);_.setUTCFullYear(T+1,0,m),_.setUTCHours(0,0,0,0);var M=I(_,t),D=new Date(0);D.setUTCFullYear(T,0,m),D.setUTCHours(0,0,0,0);var B=I(D,t);return p.getTime()>=M.getTime()?T+1:p.getTime()>=B.getTime()?T:T-1}function ot(n,t){var e,a,r,i,s,u,f,h;x(1,arguments);var p=X(),T=j((e=(a=(r=(i=t==null?void 0:t.firstWeekContainsDate)!==null&&i!==void 0?i:t==null||(s=t.locale)===null||s===void 0||(u=s.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&r!==void 0?r:p.firstWeekContainsDate)!==null&&a!==void 0?a:(f=p.locale)===null||f===void 0||(h=f.options)===null||h===void 0?void 0:h.firstWeekContainsDate)!==null&&e!==void 0?e:1),g=ie(n,t),m=new Date(0);m.setUTCFullYear(g,0,T),m.setUTCHours(0,0,0,0);var _=I(m,t);return _}var st=6048e5;function lt(n,t){x(1,arguments);var e=b(n),a=I(e,t).getTime()-ot(e,t).getTime();return Math.round(a/st)+1}function d(n,t){for(var e=n<0?"-":"",a=Math.abs(n).toString();a.length<t;)a="0"+a;return e+a}var E={y:function(t,e){var a=t.getUTCFullYear(),r=a>0?a:1-a;return d(e==="yy"?r%100:r,e.length)},M:function(t,e){var a=t.getUTCMonth();return e==="M"?String(a+1):d(a+1,2)},d:function(t,e){return d(t.getUTCDate(),e.length)},a:function(t,e){var a=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return a.toUpperCase();case"aaa":return a;case"aaaaa":return a[0];case"aaaa":default:return a==="am"?"a.m.":"p.m."}},h:function(t,e){return d(t.getUTCHours()%12||12,e.length)},H:function(t,e){return d(t.getUTCHours(),e.length)},m:function(t,e){return d(t.getUTCMinutes(),e.length)},s:function(t,e){return d(t.getUTCSeconds(),e.length)},S:function(t,e){var a=e.length,r=t.getUTCMilliseconds(),i=Math.floor(r*Math.pow(10,a-3));return d(i,e.length)}},P={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},ct={G:function(t,e,a){var r=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return a.era(r,{width:"abbreviated"});case"GGGGG":return a.era(r,{width:"narrow"});case"GGGG":default:return a.era(r,{width:"wide"})}},y:function(t,e,a){if(e==="yo"){var r=t.getUTCFullYear(),i=r>0?r:1-r;return a.ordinalNumber(i,{unit:"year"})}return E.y(t,e)},Y:function(t,e,a,r){var i=ie(t,r),s=i>0?i:1-i;if(e==="YY"){var u=s%100;return d(u,2)}return e==="Yo"?a.ordinalNumber(s,{unit:"year"}):d(s,e.length)},R:function(t,e){var a=ne(t);return d(a,e.length)},u:function(t,e){var a=t.getUTCFullYear();return d(a,e.length)},Q:function(t,e,a){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return d(r,2);case"Qo":return a.ordinalNumber(r,{unit:"quarter"});case"QQQ":return a.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return a.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return a.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,a){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return d(r,2);case"qo":return a.ordinalNumber(r,{unit:"quarter"});case"qqq":return a.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return a.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return a.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,a){var r=t.getUTCMonth();switch(e){case"M":case"MM":return E.M(t,e);case"Mo":return a.ordinalNumber(r+1,{unit:"month"});case"MMM":return a.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return a.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return a.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,a){var r=t.getUTCMonth();switch(e){case"L":return String(r+1);case"LL":return d(r+1,2);case"Lo":return a.ordinalNumber(r+1,{unit:"month"});case"LLL":return a.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return a.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return a.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,a,r){var i=lt(t,r);return e==="wo"?a.ordinalNumber(i,{unit:"week"}):d(i,e.length)},I:function(t,e,a){var r=it(t);return e==="Io"?a.ordinalNumber(r,{unit:"week"}):d(r,e.length)},d:function(t,e,a){return e==="do"?a.ordinalNumber(t.getUTCDate(),{unit:"date"}):E.d(t,e)},D:function(t,e,a){var r=at(t);return e==="Do"?a.ordinalNumber(r,{unit:"dayOfYear"}):d(r,e.length)},E:function(t,e,a){var r=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return a.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return a.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(r,{width:"short",context:"formatting"});case"EEEE":default:return a.day(r,{width:"wide",context:"formatting"})}},e:function(t,e,a,r){var i=t.getUTCDay(),s=(i-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(s);case"ee":return d(s,2);case"eo":return a.ordinalNumber(s,{unit:"day"});case"eee":return a.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return a.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(i,{width:"short",context:"formatting"});case"eeee":default:return a.day(i,{width:"wide",context:"formatting"})}},c:function(t,e,a,r){var i=t.getUTCDay(),s=(i-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(s);case"cc":return d(s,e.length);case"co":return a.ordinalNumber(s,{unit:"day"});case"ccc":return a.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return a.day(i,{width:"narrow",context:"standalone"});case"cccccc":return a.day(i,{width:"short",context:"standalone"});case"cccc":default:return a.day(i,{width:"wide",context:"standalone"})}},i:function(t,e,a){var r=t.getUTCDay(),i=r===0?7:r;switch(e){case"i":return String(i);case"ii":return d(i,e.length);case"io":return a.ordinalNumber(i,{unit:"day"});case"iii":return a.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return a.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return a.day(r,{width:"short",context:"formatting"});case"iiii":default:return a.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,a){var r=t.getUTCHours(),i=r/12>=1?"pm":"am";switch(e){case"a":case"aa":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(t,e,a){var r=t.getUTCHours(),i;switch(r===12?i=P.noon:r===0?i=P.midnight:i=r/12>=1?"pm":"am",e){case"b":case"bb":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"bbb":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})}},B:function(t,e,a){var r=t.getUTCHours(),i;switch(r>=17?i=P.evening:r>=12?i=P.afternoon:r>=4?i=P.morning:i=P.night,e){case"B":case"BB":case"BBB":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"BBBBB":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})}},h:function(t,e,a){if(e==="ho"){var r=t.getUTCHours()%12;return r===0&&(r=12),a.ordinalNumber(r,{unit:"hour"})}return E.h(t,e)},H:function(t,e,a){return e==="Ho"?a.ordinalNumber(t.getUTCHours(),{unit:"hour"}):E.H(t,e)},K:function(t,e,a){var r=t.getUTCHours()%12;return e==="Ko"?a.ordinalNumber(r,{unit:"hour"}):d(r,e.length)},k:function(t,e,a){var r=t.getUTCHours();return r===0&&(r=24),e==="ko"?a.ordinalNumber(r,{unit:"hour"}):d(r,e.length)},m:function(t,e,a){return e==="mo"?a.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):E.m(t,e)},s:function(t,e,a){return e==="so"?a.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):E.s(t,e)},S:function(t,e){return E.S(t,e)},X:function(t,e,a,r){var i=r._originalDate||t,s=i.getTimezoneOffset();if(s===0)return"Z";switch(e){case"X":return z(s);case"XXXX":case"XX":return S(s);case"XXXXX":case"XXX":default:return S(s,":")}},x:function(t,e,a,r){var i=r._originalDate||t,s=i.getTimezoneOffset();switch(e){case"x":return z(s);case"xxxx":case"xx":return S(s);case"xxxxx":case"xxx":default:return S(s,":")}},O:function(t,e,a,r){var i=r._originalDate||t,s=i.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+Z(s,":");case"OOOO":default:return"GMT"+S(s,":")}},z:function(t,e,a,r){var i=r._originalDate||t,s=i.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+Z(s,":");case"zzzz":default:return"GMT"+S(s,":")}},t:function(t,e,a,r){var i=r._originalDate||t,s=Math.floor(i.getTime()/1e3);return d(s,e.length)},T:function(t,e,a,r){var i=r._originalDate||t,s=i.getTime();return d(s,e.length)}};function Z(n,t){var e=n>0?"-":"+",a=Math.abs(n),r=Math.floor(a/60),i=a%60;if(i===0)return e+String(r);var s=t;return e+String(r)+s+d(i,2)}function z(n,t){if(n%60===0){var e=n>0?"-":"+";return e+d(Math.abs(n)/60,2)}return S(n,t)}function S(n,t){var e=t||"",a=n>0?"-":"+",r=Math.abs(n),i=d(Math.floor(r/60),2),s=d(r%60,2);return a+i+e+s}var ee=function(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});case"PPPP":default:return e.date({width:"full"})}},oe=function(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});case"pppp":default:return e.time({width:"full"})}},dt=function(t,e){var a=t.match(/(P+)(p+)?/)||[],r=a[1],i=a[2];if(!i)return ee(t,e);var s;switch(r){case"P":s=e.dateTime({width:"short"});break;case"PP":s=e.dateTime({width:"medium"});break;case"PPP":s=e.dateTime({width:"long"});break;case"PPPP":default:s=e.dateTime({width:"full"});break}return s.replace("{{date}}",ee(r,e)).replace("{{time}}",oe(i,e))},ut={p:oe,P:dt},ht=["D","DD"],gt=["YY","YYYY"];function ft(n){return ht.indexOf(n)!==-1}function mt(n){return gt.indexOf(n)!==-1}function te(n,t,e){if(n==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(e,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(n==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(e,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(n==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(e,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(n==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(e,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var vt=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,pt=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Tt=/^'([^]*?)'?$/,wt=/''/g,Ct=/[a-zA-Z]/;function xt(n,t,e){var a,r,i,s,u,f,h,p,T,g,m,_,M,D;x(2,arguments);var B=String(t),N=X(),L=(a=(r=void 0)!==null&&r!==void 0?r:N.locale)!==null&&a!==void 0?a:Ke,H=j((i=(s=(u=(f=void 0)!==null&&f!==void 0?f:void 0)!==null&&u!==void 0?u:N.firstWeekContainsDate)!==null&&s!==void 0?s:(h=N.locale)===null||h===void 0||(p=h.options)===null||p===void 0?void 0:p.firstWeekContainsDate)!==null&&i!==void 0?i:1);if(!(H>=1&&H<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var q=j((T=(g=(m=(_=void 0)!==null&&_!==void 0?_:void 0)!==null&&m!==void 0?m:N.weekStartsOn)!==null&&g!==void 0?g:(M=N.locale)===null||M===void 0||(D=M.options)===null||D===void 0?void 0:D.weekStartsOn)!==null&&T!==void 0?T:0);if(!(q>=0&&q<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!L.localize)throw new RangeError("locale must contain localize property");if(!L.formatLong)throw new RangeError("locale must contain formatLong property");var R=b(n);if(!ze(R))throw new RangeError("Invalid time value");var se=Xe(R),le=et(R,se),ce={firstWeekContainsDate:H,weekStartsOn:q,locale:L,_originalDate:R},de=B.match(pt).map(function(w){var y=w[0];if(y==="p"||y==="P"){var Y=ut[y];return Y(w,L.formatLong)}return w}).join("").match(vt).map(function(w){if(w==="''")return"'";var y=w[0];if(y==="'")return _t(w);var Y=ct[y];if(Y)return mt(w)&&te(w,t,String(n)),ft(w)&&te(w,t,String(n)),Y(le,w,L.localize,ce);if(y.match(Ct))throw new RangeError("Format string contains an unescaped latin alphabet character `"+y+"`");return w}).join("");return de}function _t(n){var t=n.match(Tt);return t?t[1].replace(wt,"'"):n}const bt=(n,t)=>{if(n.isApproved){if(!t||t.status==="approved")return C.APPROVED;if(t.status==="rejected")return C.REJECTED}else{if(!t&&fe(n))return C.DISABLED;if(t&&t.status==="rejected")return C.REJECTED}return t&&t.status==="pending"&&t.assignee?C.UNDER_REVIEW:C.TO_REVIEW};function yt(n){const{collection:t,curation:e,address:a,itemCount:r,onOpenModal:i}=n,s=me(),u=A.useCallback(g=>{window.open(t.forumLink,"_blank"),g.preventDefault(),g.stopPropagation()},[t]),f=A.useCallback((g,m=K.SELF_ASSIGN)=>{i("EditCurationAssigneeModal",{collectionId:t.id,type:m}),g.preventDefault(),g.stopPropagation()},[i,t]),h=A.useCallback(()=>{s.push(ve.itemEditor({collectionId:t.id,isReviewing:"true"}))},[s,t]),p=A.useCallback(()=>{switch(bt(t,e)){case C.APPROVED:return o.jsxs("div",{className:"approved action",children:[o.jsx("span",{className:"action-text",children:c("collection_row.approved")})," ",o.jsx(l.Icon,{name:"check"})]});case C.REJECTED:return o.jsxs("div",{className:"rejected action",children:[o.jsx("span",{className:"action-text",children:c("collection_row.rejected")})," ",o.jsx(l.Icon,{name:"close"})]});case C.DISABLED:return o.jsxs("div",{className:"disabled action",children:[o.jsx("span",{className:"action-text",children:c("collection_row.disabled")})," ",o.jsx(l.Icon,{name:"close"})]});case C.UNDER_REVIEW:return o.jsxs("span",{children:[" ",c("collection_row.under_review")]});case C.TO_REVIEW:return o.jsxs("span",{children:[" ",c("collection_row.to_review")]});default:return o.jsxs("span",{children:[" ",c("collection_row.to_review")]})}},[t,e]),T=new Date((e==null?void 0:e.createdAt)||t.createdAt);return o.jsxs(l.Table.Row,{className:"CollectionRow",onClick:h,children:[o.jsx(l.Table.Cell,{width:5,children:o.jsxs("div",{className:"image-column",children:[o.jsx(pe,{collectionId:t.id}),o.jsxs("div",{className:"info",children:[o.jsxs("div",{className:"title",children:[o.jsx($e,{collection:t}),t.name]}),o.jsx("div",{className:"subtitle name",children:c("collection_row.items",{count:r})})]})]})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx(Ge,{isThirdParty:J(t)})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx(Qe,{isProgrammatic:t.isProgrammatic})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx("div",{children:J(t)?"-":o.jsx(V,{textOnly:!0,address:t.owner})})}),o.jsx(l.Table.Cell,{width:3,children:o.jsxs("div",{title:xt(T,"d MMMM yyyy HH:mm"),children:[o.jsx("span",{children:c(e?"collection_row.review_request":"collection_row.published")})," ",Ve(T,{addSuffix:!0})]})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx("div",{className:"actions text-centered",children:p()})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx("div",{className:"edit-container",children:e!=null&&e.assignee?o.jsxs(o.Fragment,{children:[o.jsxs("div",{className:"curator-name",children:[o.jsx(V,{textOnly:!0,address:e.assignee}),a===e.assignee?o.jsxs(o.Fragment,{children:[" (",c("collection_row.you"),")"]}):null," "]}),e.status!==C.APPROVED||!t.isApproved?o.jsx(l.Icon,{name:"pencil",onClick:g=>f(g,K.REASSIGN)}):null]}):o.jsxs("div",{className:"assignee-container",children:[c("collection_row.unassigned"),o.jsx("span",{className:"link",onClick:f,children:c("collection_row.assign_to_me")})]})})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx("div",{className:"text-centered",children:t.forumLink?o.jsx("span",{className:"link",onClick:u,children:c("collection_row.link")}):c("collection_row.no_forum_post")})})]},t.id)}const Et=(n,t)=>({address:Te(n),itemCount:we(n,t.collection.id)}),Dt=n=>({onOpenModal:(t,e)=>n(Ce(t,e))}),Ot=re(Et,Dt)(yt);var F=(n=>(n.ALL_STATUS="ALL_STATUS",n))(F||{}),k=(n=>(n.ALL_TYPES="ALL_TYPES",n))(k||{});const U={...C,...F},ae={...xe,...k},G=12,Q="all";let St=class extends _e.PureComponent{constructor(){super(...arguments);v(this,"state",{sortBy:O.CREATED_AT_DESC,filterByStatus:F.ALL_STATUS,filterByTags:[],filterByType:k.ALL_TYPES,assignee:Q,searchText:"",page:1});v(this,"getFetchParams",e=>{const{assignee:a,filterByStatus:r,filterByType:i,page:s,searchText:u,sortBy:f,filterByTags:h}=this.state;return{page:s,limit:G,assignee:a!==Q?a:void 0,status:r!==F.ALL_STATUS?r:void 0,type:i!==k.ALL_TYPES?i:void 0,q:u||void 0,sort:f,tag:h.length>0?h:void 0,isPublished:!0,...e}});v(this,"fetchCollections",()=>{const{onFetchCollections:e}=this.props;e(this.getFetchParams())});v(this,"updateParam",e=>{this.setState(e,this.fetchCollections)});v(this,"handleSortChange",(e,{value:a})=>{this.updateParam({sortBy:a,page:1})});v(this,"handleStatusChange",(e,{value:a})=>{this.updateParam({filterByStatus:`${a}`,page:1})});v(this,"handleTypeChange",(e,{value:a})=>{this.updateParam({filterByType:`${a}`,page:1})});v(this,"handleAssigneeChange",(e,{value:a})=>{this.updateParam({assignee:`${a}`,page:1})});v(this,"handleSearchChange",e=>{const{searchText:a}=this.state;e!==a&&this.updateParam({searchText:e,page:1})});v(this,"handlePageChange",(e,a)=>{this.updateParam({page:+a.activePage})});v(this,"handleOnCampaignToggleChange",(e,a)=>{const{campaignTag:r}=this.props,{checked:i}=a;r&&(i?this.updateParam({filterByTags:[...this.state.filterByTags,r]}):this.updateParam({filterByTags:[...this.state.filterByTags.filter(s=>s!==r)]}))});v(this,"renderSortDropdown",()=>{const{sortBy:e}=this.state;return o.jsx(l.Dropdown,{direction:"left",value:e,options:[{value:O.MOST_RELEVANT,text:c("curation_page.order.most_relevant")},{value:O.CREATED_AT_DESC,text:c("global.order.newest")},{value:O.NAME_ASC,text:c("global.order.name_asc")},{value:O.NAME_DESC,text:c("global.order.name_desc")}],onChange:this.handleSortChange})});v(this,"renderTypesFilterDropdown",()=>{const{filterByType:e}=this.state;return o.jsx(l.Dropdown,{direction:"left",value:e,options:[{value:k.ALL_TYPES,text:c("curation_page.filter.all_types")},{value:ae.STANDARD,text:c("curation_page.filter.standard")},{value:ae.THIRD_PARTY,text:c("curation_page.filter.third_party")}],onChange:this.handleTypeChange})});v(this,"renderStatusFilterDropdown",()=>{const{filterByStatus:e}=this.state;return o.jsx(l.Dropdown,{direction:"left",value:e,options:[{value:U.ALL_STATUS,text:c("curation_page.filter.all_status")},{value:U.UNDER_REVIEW,text:c("curation_page.filter.under_review")},{value:U.TO_REVIEW,text:c("curation_page.filter.to_review")},{value:U.APPROVED,text:c("curation_page.filter.approved")},{value:U.REJECTED,text:c("curation_page.filter.rejected")}],onChange:this.handleStatusChange})});v(this,"renderAssigneeFilterDropdown",()=>{const{committeeMembers:e,wallet:a}=this.props,{assignee:r}=this.state;return o.jsx(l.Dropdown,{className:"assignees",direction:"left",value:r,options:[{value:Q,text:c("curation_page.filter.all_assignees")},...e.reduce((i,s)=>(s===a.address?i.unshift(s):i.push(s),i),[]).map(i=>({value:i,text:o.jsx(V,{textOnly:!0,address:i})}))],onChange:this.handleAssigneeChange})});v(this,"renderCampaignFilterToggle",()=>{const{isCampaignEnabled:e,campaignName:a,campaignTag:r}=this.props,{filterByTags:i}=this.state;return e&&a&&r?o.jsx(l.Radio,{toggle:!0,className:"filterByCampaignTag",checked:i.includes(r),onChange:this.handleOnCampaignToggleChange,label:a}):null})}componentDidMount(){const{onFetchCollections:e,wallet:a,isLoadingCommittee:r,isCommitteeMember:i}=this.props;a&&!r&&i&&e({page:1,limit:G,isPublished:!0,sort:O.MOST_RELEVANT})}componentDidUpdate(e){const{onFetchCollections:a,wallet:r,isLoadingCommittee:i,isCommitteeMember:s}=this.props;r&&!i&&s&&e.isCommitteeMember!==s&&a({page:1,limit:G,isPublished:!0,sort:O.MOST_RELEVANT})}renderPage(){const{isLoadingCollectionsData:e,isLoadingCommittee:a,collections:r,curationsByCollectionId:i,paginationData:s}=this.props,{page:u,searchText:f}=this.state,h=s==null?void 0:s.total,p=s==null?void 0:s.totalPages,T=r,g=e||a||!s;return o.jsxs(o.Fragment,{children:[o.jsx("div",{className:"filters",children:o.jsxs(l.Container,{children:[s?o.jsx(l.Row,{className:"text-filter-row",children:o.jsx(l.TextFilter,{placeholder:c("curation_page.search_placeholder"),value:f,onChange:this.handleSearchChange})}):null,o.jsxs(l.Row,{children:[o.jsx(l.Column,{grow:!1,shrink:!1,children:o.jsx(l.Row,{children:!e&&!!h&&h>0&&o.jsx(l.Header,{sub:!0,children:c("collections_page.results",{count:h})})})}),o.jsx(l.Column,{align:"right",shrink:!1,children:o.jsxs(l.Row,{children:[this.renderCampaignFilterToggle(),this.renderAssigneeFilterDropdown(),this.renderTypesFilterDropdown(),this.renderStatusFilterDropdown(),this.renderSortDropdown()]})})]})]})}),g?o.jsx(l.Loader,{active:!0,size:"large"}):o.jsxs(l.Container,{children:[o.jsxs(l.Section,{children:[o.jsx(l.Table,{basic:"very",children:r.length>0?o.jsxs(o.Fragment,{children:[o.jsx(l.Table.Header,{children:o.jsxs(l.Table.Row,{children:[o.jsx(l.Table.HeaderCell,{children:c("collection_row.collection")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.type")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.kind")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.owner")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.date")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.status")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.assignee")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.discussion")})]})}),o.jsx(l.Table.Body,{children:T.map(m=>o.jsx(Ot,{collection:m,curation:i[m.id]||null},m.id))})]}):null}),r.length===0?o.jsx(l.Empty,{height:200,children:o.jsx("div",{children:o.jsx(be,{id:"curation_page.empty_collections"})})}):null]}),!!p&&p>1&&o.jsx(l.Pagination,{className:"pagination",firstItem:null,lastItem:null,totalPages:p,activePage:u,onPageChange:this.handlePageChange})]})]})}render(){const{isCommitteeMember:e,isConnecting:a,isLoadingCommittee:r}=this.props,i=a||r;return o.jsx(He,{className:"CurationPage",activeTab:qe.CURATION,isLoading:i,children:e?this.renderPage():o.jsx(Be,{})})}};const Pt=n=>{var r;const t=ye(n),e=Ee(n),a=De(n);return{wallet:Oe(n),collections:e,paginationData:a,curationsByCollectionId:t,isCommitteeMember:Se(n),committeeMembers:Pe(n),isConnecting:je(n),isLoadingCommittee:$(Me(n),Re),isLoadingCollectionsData:$(Ne(n),Ye)||$(Le(n),Ae),isCampaignEnabled:Ue(n),campaignTag:Ie(n),campaignName:(r=We(n))==null?void 0:r[Fe(n)]}},jt=n=>({onFetchCollections:t=>n(ke(void 0,t))}),Ht=re(Pt,jt)(St);export{Ht as default};
1
+ var ue=Object.defineProperty;var he=(n,t,e)=>t in n?ue(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e;var v=(n,t,e)=>he(n,typeof t!="symbol"?t+"":t,e);import{c0 as x,c1 as b,cm as j,hS as ge,gB as C,gN as fe,a4 as me,J as A,hT as K,R as ve,N as o,M as c,S as l,dM as pe,eZ as J,bQ as V,T as re,aM as Te,eC as we,a2 as Ce,eE as xe,ak as _e,eF as O,b6 as be,hU as ye,eH as Ee,eK as De,ej as Oe,bd as Se,hV as Pe,ad as je,bq as $,hW as Me,eM as Ne,gE as Le,eP as Ue,eT as ke,hX as Re,eV as Ye,hY as Ae}from"./index-BcJ8MhYC.js";import{d as Ie,e as We,c as Fe}from"./selectors-DHi87VFf.js";import{N as Be}from"./NotFound-4sT-K9SU.js";import{L as He}from"./LoggedInDetailPage.container-CsvKBMuj.js";import{N as qe}from"./Navigation.container-Uoa9cAN5.js";import{C as $e}from"./CollectionStatus.container-BPchWQUD.js";import{C as Ge,T as Qe}from"./ThirdPartyKindBadge-BN8ggssH.js";import{s as I,a as Ve}from"./date-CZsUie1B.js";import{g as X,e as Xe,l as Ke}from"./index-MzNAR7ES.js";import"./SignInRequired-BIpJsBqT.js";function Je(n,t){x(2,arguments);var e=b(n).getTime(),a=j(t);return new Date(e+a)}function Ze(n){return x(1,arguments),n instanceof Date||ge(n)==="object"&&Object.prototype.toString.call(n)==="[object Date]"}function ze(n){if(x(1,arguments),!Ze(n)&&typeof n!="number")return!1;var t=b(n);return!isNaN(Number(t))}function et(n,t){x(2,arguments);var e=j(t);return Je(n,-e)}var tt=864e5;function at(n){x(1,arguments);var t=b(n),e=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var a=t.getTime(),r=e-a;return Math.floor(r/tt)+1}function W(n){x(1,arguments);var t=1,e=b(n),a=e.getUTCDay(),r=(a<t?7:0)+a-t;return e.setUTCDate(e.getUTCDate()-r),e.setUTCHours(0,0,0,0),e}function ne(n){x(1,arguments);var t=b(n),e=t.getUTCFullYear(),a=new Date(0);a.setUTCFullYear(e+1,0,4),a.setUTCHours(0,0,0,0);var r=W(a),i=new Date(0);i.setUTCFullYear(e,0,4),i.setUTCHours(0,0,0,0);var s=W(i);return t.getTime()>=r.getTime()?e+1:t.getTime()>=s.getTime()?e:e-1}function rt(n){x(1,arguments);var t=ne(n),e=new Date(0);e.setUTCFullYear(t,0,4),e.setUTCHours(0,0,0,0);var a=W(e);return a}var nt=6048e5;function it(n){x(1,arguments);var t=b(n),e=W(t).getTime()-rt(t).getTime();return Math.round(e/nt)+1}function ie(n,t){var e,a,r,i,s,u,f,h;x(1,arguments);var p=b(n),T=p.getUTCFullYear(),g=X(),m=j((e=(a=(r=(i=t==null?void 0:t.firstWeekContainsDate)!==null&&i!==void 0?i:t==null||(s=t.locale)===null||s===void 0||(u=s.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&r!==void 0?r:g.firstWeekContainsDate)!==null&&a!==void 0?a:(f=g.locale)===null||f===void 0||(h=f.options)===null||h===void 0?void 0:h.firstWeekContainsDate)!==null&&e!==void 0?e:1);if(!(m>=1&&m<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var _=new Date(0);_.setUTCFullYear(T+1,0,m),_.setUTCHours(0,0,0,0);var M=I(_,t),D=new Date(0);D.setUTCFullYear(T,0,m),D.setUTCHours(0,0,0,0);var B=I(D,t);return p.getTime()>=M.getTime()?T+1:p.getTime()>=B.getTime()?T:T-1}function ot(n,t){var e,a,r,i,s,u,f,h;x(1,arguments);var p=X(),T=j((e=(a=(r=(i=t==null?void 0:t.firstWeekContainsDate)!==null&&i!==void 0?i:t==null||(s=t.locale)===null||s===void 0||(u=s.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&r!==void 0?r:p.firstWeekContainsDate)!==null&&a!==void 0?a:(f=p.locale)===null||f===void 0||(h=f.options)===null||h===void 0?void 0:h.firstWeekContainsDate)!==null&&e!==void 0?e:1),g=ie(n,t),m=new Date(0);m.setUTCFullYear(g,0,T),m.setUTCHours(0,0,0,0);var _=I(m,t);return _}var st=6048e5;function lt(n,t){x(1,arguments);var e=b(n),a=I(e,t).getTime()-ot(e,t).getTime();return Math.round(a/st)+1}function d(n,t){for(var e=n<0?"-":"",a=Math.abs(n).toString();a.length<t;)a="0"+a;return e+a}var E={y:function(t,e){var a=t.getUTCFullYear(),r=a>0?a:1-a;return d(e==="yy"?r%100:r,e.length)},M:function(t,e){var a=t.getUTCMonth();return e==="M"?String(a+1):d(a+1,2)},d:function(t,e){return d(t.getUTCDate(),e.length)},a:function(t,e){var a=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return a.toUpperCase();case"aaa":return a;case"aaaaa":return a[0];case"aaaa":default:return a==="am"?"a.m.":"p.m."}},h:function(t,e){return d(t.getUTCHours()%12||12,e.length)},H:function(t,e){return d(t.getUTCHours(),e.length)},m:function(t,e){return d(t.getUTCMinutes(),e.length)},s:function(t,e){return d(t.getUTCSeconds(),e.length)},S:function(t,e){var a=e.length,r=t.getUTCMilliseconds(),i=Math.floor(r*Math.pow(10,a-3));return d(i,e.length)}},P={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},ct={G:function(t,e,a){var r=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return a.era(r,{width:"abbreviated"});case"GGGGG":return a.era(r,{width:"narrow"});case"GGGG":default:return a.era(r,{width:"wide"})}},y:function(t,e,a){if(e==="yo"){var r=t.getUTCFullYear(),i=r>0?r:1-r;return a.ordinalNumber(i,{unit:"year"})}return E.y(t,e)},Y:function(t,e,a,r){var i=ie(t,r),s=i>0?i:1-i;if(e==="YY"){var u=s%100;return d(u,2)}return e==="Yo"?a.ordinalNumber(s,{unit:"year"}):d(s,e.length)},R:function(t,e){var a=ne(t);return d(a,e.length)},u:function(t,e){var a=t.getUTCFullYear();return d(a,e.length)},Q:function(t,e,a){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return d(r,2);case"Qo":return a.ordinalNumber(r,{unit:"quarter"});case"QQQ":return a.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return a.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return a.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,a){var r=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return d(r,2);case"qo":return a.ordinalNumber(r,{unit:"quarter"});case"qqq":return a.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return a.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return a.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,a){var r=t.getUTCMonth();switch(e){case"M":case"MM":return E.M(t,e);case"Mo":return a.ordinalNumber(r+1,{unit:"month"});case"MMM":return a.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return a.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return a.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,a){var r=t.getUTCMonth();switch(e){case"L":return String(r+1);case"LL":return d(r+1,2);case"Lo":return a.ordinalNumber(r+1,{unit:"month"});case"LLL":return a.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return a.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return a.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,a,r){var i=lt(t,r);return e==="wo"?a.ordinalNumber(i,{unit:"week"}):d(i,e.length)},I:function(t,e,a){var r=it(t);return e==="Io"?a.ordinalNumber(r,{unit:"week"}):d(r,e.length)},d:function(t,e,a){return e==="do"?a.ordinalNumber(t.getUTCDate(),{unit:"date"}):E.d(t,e)},D:function(t,e,a){var r=at(t);return e==="Do"?a.ordinalNumber(r,{unit:"dayOfYear"}):d(r,e.length)},E:function(t,e,a){var r=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return a.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return a.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(r,{width:"short",context:"formatting"});case"EEEE":default:return a.day(r,{width:"wide",context:"formatting"})}},e:function(t,e,a,r){var i=t.getUTCDay(),s=(i-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(s);case"ee":return d(s,2);case"eo":return a.ordinalNumber(s,{unit:"day"});case"eee":return a.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return a.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(i,{width:"short",context:"formatting"});case"eeee":default:return a.day(i,{width:"wide",context:"formatting"})}},c:function(t,e,a,r){var i=t.getUTCDay(),s=(i-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(s);case"cc":return d(s,e.length);case"co":return a.ordinalNumber(s,{unit:"day"});case"ccc":return a.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return a.day(i,{width:"narrow",context:"standalone"});case"cccccc":return a.day(i,{width:"short",context:"standalone"});case"cccc":default:return a.day(i,{width:"wide",context:"standalone"})}},i:function(t,e,a){var r=t.getUTCDay(),i=r===0?7:r;switch(e){case"i":return String(i);case"ii":return d(i,e.length);case"io":return a.ordinalNumber(i,{unit:"day"});case"iii":return a.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return a.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return a.day(r,{width:"short",context:"formatting"});case"iiii":default:return a.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,a){var r=t.getUTCHours(),i=r/12>=1?"pm":"am";switch(e){case"a":case"aa":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(t,e,a){var r=t.getUTCHours(),i;switch(r===12?i=P.noon:r===0?i=P.midnight:i=r/12>=1?"pm":"am",e){case"b":case"bb":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"bbb":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})}},B:function(t,e,a){var r=t.getUTCHours(),i;switch(r>=17?i=P.evening:r>=12?i=P.afternoon:r>=4?i=P.morning:i=P.night,e){case"B":case"BB":case"BBB":return a.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"BBBBB":return a.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return a.dayPeriod(i,{width:"wide",context:"formatting"})}},h:function(t,e,a){if(e==="ho"){var r=t.getUTCHours()%12;return r===0&&(r=12),a.ordinalNumber(r,{unit:"hour"})}return E.h(t,e)},H:function(t,e,a){return e==="Ho"?a.ordinalNumber(t.getUTCHours(),{unit:"hour"}):E.H(t,e)},K:function(t,e,a){var r=t.getUTCHours()%12;return e==="Ko"?a.ordinalNumber(r,{unit:"hour"}):d(r,e.length)},k:function(t,e,a){var r=t.getUTCHours();return r===0&&(r=24),e==="ko"?a.ordinalNumber(r,{unit:"hour"}):d(r,e.length)},m:function(t,e,a){return e==="mo"?a.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):E.m(t,e)},s:function(t,e,a){return e==="so"?a.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):E.s(t,e)},S:function(t,e){return E.S(t,e)},X:function(t,e,a,r){var i=r._originalDate||t,s=i.getTimezoneOffset();if(s===0)return"Z";switch(e){case"X":return z(s);case"XXXX":case"XX":return S(s);case"XXXXX":case"XXX":default:return S(s,":")}},x:function(t,e,a,r){var i=r._originalDate||t,s=i.getTimezoneOffset();switch(e){case"x":return z(s);case"xxxx":case"xx":return S(s);case"xxxxx":case"xxx":default:return S(s,":")}},O:function(t,e,a,r){var i=r._originalDate||t,s=i.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+Z(s,":");case"OOOO":default:return"GMT"+S(s,":")}},z:function(t,e,a,r){var i=r._originalDate||t,s=i.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+Z(s,":");case"zzzz":default:return"GMT"+S(s,":")}},t:function(t,e,a,r){var i=r._originalDate||t,s=Math.floor(i.getTime()/1e3);return d(s,e.length)},T:function(t,e,a,r){var i=r._originalDate||t,s=i.getTime();return d(s,e.length)}};function Z(n,t){var e=n>0?"-":"+",a=Math.abs(n),r=Math.floor(a/60),i=a%60;if(i===0)return e+String(r);var s=t;return e+String(r)+s+d(i,2)}function z(n,t){if(n%60===0){var e=n>0?"-":"+";return e+d(Math.abs(n)/60,2)}return S(n,t)}function S(n,t){var e=t||"",a=n>0?"-":"+",r=Math.abs(n),i=d(Math.floor(r/60),2),s=d(r%60,2);return a+i+e+s}var ee=function(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});case"PPPP":default:return e.date({width:"full"})}},oe=function(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});case"pppp":default:return e.time({width:"full"})}},dt=function(t,e){var a=t.match(/(P+)(p+)?/)||[],r=a[1],i=a[2];if(!i)return ee(t,e);var s;switch(r){case"P":s=e.dateTime({width:"short"});break;case"PP":s=e.dateTime({width:"medium"});break;case"PPP":s=e.dateTime({width:"long"});break;case"PPPP":default:s=e.dateTime({width:"full"});break}return s.replace("{{date}}",ee(r,e)).replace("{{time}}",oe(i,e))},ut={p:oe,P:dt},ht=["D","DD"],gt=["YY","YYYY"];function ft(n){return ht.indexOf(n)!==-1}function mt(n){return gt.indexOf(n)!==-1}function te(n,t,e){if(n==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(e,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(n==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(e,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(n==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(e,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(n==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(e,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var vt=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,pt=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Tt=/^'([^]*?)'?$/,wt=/''/g,Ct=/[a-zA-Z]/;function xt(n,t,e){var a,r,i,s,u,f,h,p,T,g,m,_,M,D;x(2,arguments);var B=String(t),N=X(),L=(a=(r=void 0)!==null&&r!==void 0?r:N.locale)!==null&&a!==void 0?a:Ke,H=j((i=(s=(u=(f=void 0)!==null&&f!==void 0?f:void 0)!==null&&u!==void 0?u:N.firstWeekContainsDate)!==null&&s!==void 0?s:(h=N.locale)===null||h===void 0||(p=h.options)===null||p===void 0?void 0:p.firstWeekContainsDate)!==null&&i!==void 0?i:1);if(!(H>=1&&H<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var q=j((T=(g=(m=(_=void 0)!==null&&_!==void 0?_:void 0)!==null&&m!==void 0?m:N.weekStartsOn)!==null&&g!==void 0?g:(M=N.locale)===null||M===void 0||(D=M.options)===null||D===void 0?void 0:D.weekStartsOn)!==null&&T!==void 0?T:0);if(!(q>=0&&q<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!L.localize)throw new RangeError("locale must contain localize property");if(!L.formatLong)throw new RangeError("locale must contain formatLong property");var R=b(n);if(!ze(R))throw new RangeError("Invalid time value");var se=Xe(R),le=et(R,se),ce={firstWeekContainsDate:H,weekStartsOn:q,locale:L,_originalDate:R},de=B.match(pt).map(function(w){var y=w[0];if(y==="p"||y==="P"){var Y=ut[y];return Y(w,L.formatLong)}return w}).join("").match(vt).map(function(w){if(w==="''")return"'";var y=w[0];if(y==="'")return _t(w);var Y=ct[y];if(Y)return mt(w)&&te(w,t,String(n)),ft(w)&&te(w,t,String(n)),Y(le,w,L.localize,ce);if(y.match(Ct))throw new RangeError("Format string contains an unescaped latin alphabet character `"+y+"`");return w}).join("");return de}function _t(n){var t=n.match(Tt);return t?t[1].replace(wt,"'"):n}const bt=(n,t)=>{if(n.isApproved){if(!t||t.status==="approved")return C.APPROVED;if(t.status==="rejected")return C.REJECTED}else{if(!t&&fe(n))return C.DISABLED;if(t&&t.status==="rejected")return C.REJECTED}return t&&t.status==="pending"&&t.assignee?C.UNDER_REVIEW:C.TO_REVIEW};function yt(n){const{collection:t,curation:e,address:a,itemCount:r,onOpenModal:i}=n,s=me(),u=A.useCallback(g=>{window.open(t.forumLink,"_blank"),g.preventDefault(),g.stopPropagation()},[t]),f=A.useCallback((g,m=K.SELF_ASSIGN)=>{i("EditCurationAssigneeModal",{collectionId:t.id,type:m}),g.preventDefault(),g.stopPropagation()},[i,t]),h=A.useCallback(()=>{s.push(ve.itemEditor({collectionId:t.id,isReviewing:"true"}))},[s,t]),p=A.useCallback(()=>{switch(bt(t,e)){case C.APPROVED:return o.jsxs("div",{className:"approved action",children:[o.jsx("span",{className:"action-text",children:c("collection_row.approved")})," ",o.jsx(l.Icon,{name:"check"})]});case C.REJECTED:return o.jsxs("div",{className:"rejected action",children:[o.jsx("span",{className:"action-text",children:c("collection_row.rejected")})," ",o.jsx(l.Icon,{name:"close"})]});case C.DISABLED:return o.jsxs("div",{className:"disabled action",children:[o.jsx("span",{className:"action-text",children:c("collection_row.disabled")})," ",o.jsx(l.Icon,{name:"close"})]});case C.UNDER_REVIEW:return o.jsxs("span",{children:[" ",c("collection_row.under_review")]});case C.TO_REVIEW:return o.jsxs("span",{children:[" ",c("collection_row.to_review")]});default:return o.jsxs("span",{children:[" ",c("collection_row.to_review")]})}},[t,e]),T=new Date((e==null?void 0:e.createdAt)||t.createdAt);return o.jsxs(l.Table.Row,{className:"CollectionRow",onClick:h,children:[o.jsx(l.Table.Cell,{width:5,children:o.jsxs("div",{className:"image-column",children:[o.jsx(pe,{collectionId:t.id}),o.jsxs("div",{className:"info",children:[o.jsxs("div",{className:"title",children:[o.jsx($e,{collection:t}),t.name]}),o.jsx("div",{className:"subtitle name",children:c("collection_row.items",{count:r})})]})]})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx(Ge,{isThirdParty:J(t)})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx(Qe,{isProgrammatic:t.isProgrammatic})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx("div",{children:J(t)?"-":o.jsx(V,{textOnly:!0,address:t.owner})})}),o.jsx(l.Table.Cell,{width:3,children:o.jsxs("div",{title:xt(T,"d MMMM yyyy HH:mm"),children:[o.jsx("span",{children:c(e?"collection_row.review_request":"collection_row.published")})," ",Ve(T,{addSuffix:!0})]})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx("div",{className:"actions text-centered",children:p()})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx("div",{className:"edit-container",children:e!=null&&e.assignee?o.jsxs(o.Fragment,{children:[o.jsxs("div",{className:"curator-name",children:[o.jsx(V,{textOnly:!0,address:e.assignee}),a===e.assignee?o.jsxs(o.Fragment,{children:[" (",c("collection_row.you"),")"]}):null," "]}),e.status!==C.APPROVED||!t.isApproved?o.jsx(l.Icon,{name:"pencil",onClick:g=>f(g,K.REASSIGN)}):null]}):o.jsxs("div",{className:"assignee-container",children:[c("collection_row.unassigned"),o.jsx("span",{className:"link",onClick:f,children:c("collection_row.assign_to_me")})]})})}),o.jsx(l.Table.Cell,{width:2,children:o.jsx("div",{className:"text-centered",children:t.forumLink?o.jsx("span",{className:"link",onClick:u,children:c("collection_row.link")}):c("collection_row.no_forum_post")})})]},t.id)}const Et=(n,t)=>({address:Te(n),itemCount:we(n,t.collection.id)}),Dt=n=>({onOpenModal:(t,e)=>n(Ce(t,e))}),Ot=re(Et,Dt)(yt);var F=(n=>(n.ALL_STATUS="ALL_STATUS",n))(F||{}),k=(n=>(n.ALL_TYPES="ALL_TYPES",n))(k||{});const U={...C,...F},ae={...xe,...k},G=12,Q="all";let St=class extends _e.PureComponent{constructor(){super(...arguments);v(this,"state",{sortBy:O.CREATED_AT_DESC,filterByStatus:F.ALL_STATUS,filterByTags:[],filterByType:k.ALL_TYPES,assignee:Q,searchText:"",page:1});v(this,"getFetchParams",e=>{const{assignee:a,filterByStatus:r,filterByType:i,page:s,searchText:u,sortBy:f,filterByTags:h}=this.state;return{page:s,limit:G,assignee:a!==Q?a:void 0,status:r!==F.ALL_STATUS?r:void 0,type:i!==k.ALL_TYPES?i:void 0,q:u||void 0,sort:f,tag:h.length>0?h:void 0,isPublished:!0,...e}});v(this,"fetchCollections",()=>{const{onFetchCollections:e}=this.props;e(this.getFetchParams())});v(this,"updateParam",e=>{this.setState(e,this.fetchCollections)});v(this,"handleSortChange",(e,{value:a})=>{this.updateParam({sortBy:a,page:1})});v(this,"handleStatusChange",(e,{value:a})=>{this.updateParam({filterByStatus:`${a}`,page:1})});v(this,"handleTypeChange",(e,{value:a})=>{this.updateParam({filterByType:`${a}`,page:1})});v(this,"handleAssigneeChange",(e,{value:a})=>{this.updateParam({assignee:`${a}`,page:1})});v(this,"handleSearchChange",e=>{const{searchText:a}=this.state;e!==a&&this.updateParam({searchText:e,page:1})});v(this,"handlePageChange",(e,a)=>{this.updateParam({page:+a.activePage})});v(this,"handleOnCampaignToggleChange",(e,a)=>{const{campaignTag:r}=this.props,{checked:i}=a;r&&(i?this.updateParam({filterByTags:[...this.state.filterByTags,r]}):this.updateParam({filterByTags:[...this.state.filterByTags.filter(s=>s!==r)]}))});v(this,"renderSortDropdown",()=>{const{sortBy:e}=this.state;return o.jsx(l.Dropdown,{direction:"left",value:e,options:[{value:O.MOST_RELEVANT,text:c("curation_page.order.most_relevant")},{value:O.CREATED_AT_DESC,text:c("global.order.newest")},{value:O.NAME_ASC,text:c("global.order.name_asc")},{value:O.NAME_DESC,text:c("global.order.name_desc")}],onChange:this.handleSortChange})});v(this,"renderTypesFilterDropdown",()=>{const{filterByType:e}=this.state;return o.jsx(l.Dropdown,{direction:"left",value:e,options:[{value:k.ALL_TYPES,text:c("curation_page.filter.all_types")},{value:ae.STANDARD,text:c("curation_page.filter.standard")},{value:ae.THIRD_PARTY,text:c("curation_page.filter.third_party")}],onChange:this.handleTypeChange})});v(this,"renderStatusFilterDropdown",()=>{const{filterByStatus:e}=this.state;return o.jsx(l.Dropdown,{direction:"left",value:e,options:[{value:U.ALL_STATUS,text:c("curation_page.filter.all_status")},{value:U.UNDER_REVIEW,text:c("curation_page.filter.under_review")},{value:U.TO_REVIEW,text:c("curation_page.filter.to_review")},{value:U.APPROVED,text:c("curation_page.filter.approved")},{value:U.REJECTED,text:c("curation_page.filter.rejected")}],onChange:this.handleStatusChange})});v(this,"renderAssigneeFilterDropdown",()=>{const{committeeMembers:e,wallet:a}=this.props,{assignee:r}=this.state;return o.jsx(l.Dropdown,{className:"assignees",direction:"left",value:r,options:[{value:Q,text:c("curation_page.filter.all_assignees")},...e.reduce((i,s)=>(s===a.address?i.unshift(s):i.push(s),i),[]).map(i=>({value:i,text:o.jsx(V,{textOnly:!0,address:i})}))],onChange:this.handleAssigneeChange})});v(this,"renderCampaignFilterToggle",()=>{const{isCampaignEnabled:e,campaignName:a,campaignTag:r}=this.props,{filterByTags:i}=this.state;return e&&a&&r?o.jsx(l.Radio,{toggle:!0,className:"filterByCampaignTag",checked:i.includes(r),onChange:this.handleOnCampaignToggleChange,label:a}):null})}componentDidMount(){const{onFetchCollections:e,wallet:a,isLoadingCommittee:r,isCommitteeMember:i}=this.props;a&&!r&&i&&e({page:1,limit:G,isPublished:!0,sort:O.MOST_RELEVANT})}componentDidUpdate(e){const{onFetchCollections:a,wallet:r,isLoadingCommittee:i,isCommitteeMember:s}=this.props;r&&!i&&s&&e.isCommitteeMember!==s&&a({page:1,limit:G,isPublished:!0,sort:O.MOST_RELEVANT})}renderPage(){const{isLoadingCollectionsData:e,isLoadingCommittee:a,collections:r,curationsByCollectionId:i,paginationData:s}=this.props,{page:u,searchText:f}=this.state,h=s==null?void 0:s.total,p=s==null?void 0:s.totalPages,T=r,g=e||a||!s;return o.jsxs(o.Fragment,{children:[o.jsx("div",{className:"filters",children:o.jsxs(l.Container,{children:[s?o.jsx(l.Row,{className:"text-filter-row",children:o.jsx(l.TextFilter,{placeholder:c("curation_page.search_placeholder"),value:f,onChange:this.handleSearchChange})}):null,o.jsxs(l.Row,{children:[o.jsx(l.Column,{grow:!1,shrink:!1,children:o.jsx(l.Row,{children:!e&&!!h&&h>0&&o.jsx(l.Header,{sub:!0,children:c("collections_page.results",{count:h})})})}),o.jsx(l.Column,{align:"right",shrink:!1,children:o.jsxs(l.Row,{children:[this.renderCampaignFilterToggle(),this.renderAssigneeFilterDropdown(),this.renderTypesFilterDropdown(),this.renderStatusFilterDropdown(),this.renderSortDropdown()]})})]})]})}),g?o.jsx(l.Loader,{active:!0,size:"large"}):o.jsxs(l.Container,{children:[o.jsxs(l.Section,{children:[o.jsx(l.Table,{basic:"very",children:r.length>0?o.jsxs(o.Fragment,{children:[o.jsx(l.Table.Header,{children:o.jsxs(l.Table.Row,{children:[o.jsx(l.Table.HeaderCell,{children:c("collection_row.collection")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.type")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.kind")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.owner")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.date")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.status")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.assignee")}),o.jsx(l.Table.HeaderCell,{children:c("collection_row.discussion")})]})}),o.jsx(l.Table.Body,{children:T.map(m=>o.jsx(Ot,{collection:m,curation:i[m.id]||null},m.id))})]}):null}),r.length===0?o.jsx(l.Empty,{height:200,children:o.jsx("div",{children:o.jsx(be,{id:"curation_page.empty_collections"})})}):null]}),!!p&&p>1&&o.jsx(l.Pagination,{className:"pagination",firstItem:null,lastItem:null,totalPages:p,activePage:u,onPageChange:this.handlePageChange})]})]})}render(){const{isCommitteeMember:e,isConnecting:a,isLoadingCommittee:r}=this.props,i=a||r;return o.jsx(He,{className:"CurationPage",activeTab:qe.CURATION,isLoading:i,children:e?this.renderPage():o.jsx(Be,{})})}};const Pt=n=>{var r;const t=ye(n),e=Ee(n),a=De(n);return{wallet:Oe(n),collections:e,paginationData:a,curationsByCollectionId:t,isCommitteeMember:Se(n),committeeMembers:Pe(n),isConnecting:je(n),isLoadingCommittee:$(Me(n),Re),isLoadingCollectionsData:$(Ne(n),Ye)||$(Le(n),Ae),isCampaignEnabled:Ue(n),campaignTag:Ie(n),campaignName:(r=We(n))==null?void 0:r[Fe(n)]}},jt=n=>({onFetchCollections:t=>n(ke(void 0,t))}),Ht=re(Pt,jt)(St);export{Ht as default};
@@ -1 +1 @@
1
- import{ak as N,N as s,a7 as P,M as x,dJ as k,S as l,dK as v,dL as H,J as j,bP as y,cf as w,bO as B,bQ as _,dM as z,dN as $,dO as F,b6 as i,Q as S,R as h,dP as K,dQ as V,dR as Q,dS as G,dT as J,dU as Y,dV as W,dW as A,dX as q,dY as f,dZ as X,d_ as Z,d$ as b,e0 as L,e1 as R,e2 as O,e3 as ss,e4 as es,e5 as as,e6 as ts,e7 as ns,e8 as is,e9 as cs,ea as os,eb as rs,ec as ls,ed as D,ee as M,ef as U,am as ds,ao as ms,T as xs,aj as us,aM as _s,eg as js,eh as Ss}from"./index-c1n4wbjs.js";import{b as hs}from"./Navigation.container-CKqSZREi.js";import{S as Cs}from"./SignInRequired-CGzWIVAU.js";import{a as Es}from"./date-CQXTob_w.js";import"./selectors-qQAG8WAy.js";import"./index-Cf_YNN5m.js";const ps="_ensImage_er26d_1",gs="_name_er26d_15",Ns="_small_er26d_23",I={ensImage:ps,name:gs,small:Ns};class Ts extends N.PureComponent{render(){const{subdomain:a,isSmall:e}=this.props;return s.jsx("div",{className:P(I.ensImage,{[I.small]:e}),children:s.jsx("div",{className:I.name,children:a.slice(0,2)})})}}const vs=c=>{const a=c.replacedBy||c.hash;return a?H({txHash:a},c.chainId):""},ys=c=>{const{selection:a,address:e,collectionId:t,item:n,subdomain:r,slotsToyBuy:d}=c,u=j.useMemo(()=>new Set((a||[]).map(C=>y(C.x,C.y))),[a]),E=j.useCallback((C,T)=>u.has(y(C,T))?{color:"#ff0044",scale:1.4}:null,[u]),p=j.useCallback((C,T)=>u.has(y(C,T))?{color:"#ff9990",scale:1.2}:null,[u]),[m,g]=j.useMemo(()=>a?w(a):[0,0],[a]);return a?s.jsx(B,{x:m,y:g,layers:[E,p],width:48,height:48,size:9,isDraggable:!1}):e?s.jsx(_,{address:e,size:"huge",imageOnly:!0}):t?s.jsx(z,{collectionId:t}):n?s.jsx($,{item:n}):r?s.jsx(Ts,{subdomain:r,isSmall:!0}):d?s.jsx("div",{className:"slot-image"}):null},Is=c=>{const{text:a,tx:e}=c;return s.jsxs("div",{className:"TransactionDetail",children:[s.jsxs("div",{className:"left",children:[s.jsx("div",{className:"image",children:s.jsx(ys,{...c})}),s.jsxs("div",{className:"text",children:[s.jsx("div",{className:"description",children:a}),s.jsxs("div",{className:"timestamp",children:[Es(e.timestamp),"."]})]})]}),s.jsx("div",{className:"right",children:s.jsxs("a",{href:vs(e),className:e.status?"status "+e.status:"status",target:"_blank",rel:"noopener noreferrer",children:[s.jsx("div",{className:"description",children:e.status||x("global.loading")}),k(e.status)?s.jsx("div",{className:"spinner",children:s.jsx(l.Loader,{active:!0,size:"mini"})}):null,e.status===v.REVERTED?s.jsx(l.Icon,{name:"warning sign"}):null,e.status===v.CONFIRMED||e.status===v.REPLACED?s.jsx(l.Icon,{name:"check"}):null]})})]})},o=N.memo(Is),As=c=>{const{tx:a}=c;switch(a.actionType){case M:case ls:{const{authorization:e}=a.payload,t=D(e.authorizedAddress),n=D(e.contractAddress),r=a.actionType===M?x("transaction.approved"):x("transaction.unapproved");return s.jsx(o,{address:e.address,text:s.jsx(i,{id:"transaction.approve_token",values:{action:r,contract:s.jsx(U,{chainId:e.chainId,address:e.authorizedAddress,txHash:"",children:t}),token:s.jsx(U,{chainId:e.chainId,address:e.contractAddress,txHash:"",children:n})}}),tx:a})}case rs:{const{name:e,address:t,selection:n}=a.payload;return s.jsx(o,{selection:n,text:s.jsx(i,{id:"transaction.transfer",values:{name:s.jsx("strong",{children:e}),address:s.jsx(_,{address:t})}}),tx:a})}case os:{const{name:e,selection:t}=a.payload;return s.jsx(o,{selection:t,text:s.jsx(i,{id:"transaction.edit",values:{name:s.jsx("strong",{children:e})}}),tx:a})}case cs:{const{name:e,address:t,selection:n}=a.payload;return s.jsx(o,{selection:n,text:s.jsx(i,{id:t?"transaction.set_operator_assigned":"transaction.set_operator_revoked",values:{name:s.jsx("strong",{children:e}),address:s.jsx(_,{address:t})}}),tx:a})}case is:{const{name:e,selection:t}=a.payload;return s.jsx(o,{selection:t,text:s.jsx(i,{id:"transaction.create_estate",values:{name:s.jsx("strong",{children:e})}}),tx:a})}case ns:{const{name:e,count:t,type:n,selection:r}=a.payload;return s.jsx(o,{selection:r,text:s.jsx(i,{id:`transaction.edit_estate_${n}`,values:{name:s.jsx("strong",{children:e}),count:t}}),tx:a})}case ts:{const{name:e,selection:t}=a.payload;return s.jsx(o,{selection:t,text:s.jsx(i,{id:"transaction.dissolve_estate",values:{name:s.jsx("strong",{children:e})}}),tx:a})}case as:{const{address:e,type:t,isApproved:n}=a.payload;return s.jsx(o,{address:e,text:s.jsx(i,{id:n?"transaction.set_manager_assigned":"transaction.set_manager_revoked",values:{address:s.jsx(_,{address:e,textOnly:!0}),type:x(`global.${t}_plural`)}}),tx:a})}case es:{const{item:e}=a.payload;return s.jsx(o,{item:e,text:s.jsx(i,{id:"transaction.set_price_and_beneficiary",values:{name:s.jsx(S,{to:h.itemDetail(e.id),children:e.name})}}),tx:a})}case ss:{const{thirdPartyId:e,thirdPartyName:t}=a.payload;return s.jsx(o,{thirdPartyId:e,text:s.jsx(i,{id:"transaction.disable_third_party",values:{name:t}}),tx:a})}case L:case R:case O:case b:{const{collection:e}=a.payload,t={[L]:"collection_published",[R]:"collection_approved",[O]:"collection_rejected",[b]:"updated_collection_managers"}[a.actionType];return s.jsx(o,{collectionId:e.id,text:s.jsx(i,{id:`transaction.${t}`,values:{name:s.jsx(S,{to:h.collectionDetail(e.id),children:e.name})}}),tx:a})}case X:{const{collection:e,mints:t}=a.payload,n=t.length===1,r=t[0].item,d=n?{item:r}:{collection:e};return s.jsx(o,{...d,text:s.jsx(i,{id:n?"transaction.collection_item_minted":"transaction.collection_items_minted",values:{collectionName:s.jsx(S,{to:h.collectionDetail(e.id),children:e.name}),itemName:s.jsx(S,{to:h.itemDetail(r.id),children:r.name}),count:Z(t)}}),tx:a})}case W:{const{chainId:e}=a,{collection:t,minters:n}=a.payload,r=A(n,t.minters),d=A(t.minters,n),u=q(e),E=f(d,u),p=f(r,u);let m="";return E?m="transaction.unset_collection_on_sale":p?m="transaction.set_collection_on_sale":m="transaction.updated_collection_minters",s.jsx(o,{collectionId:t.id,text:s.jsx(i,{id:m,values:{name:s.jsx(S,{to:h.collectionDetail(t.id),children:t.name})}}),tx:a})}case Y:{const{address:e,ens:t}=a.payload;return s.jsx(o,{subdomain:t.subdomain,text:s.jsx(i,{id:"transaction.set_ens_resolver",values:{address:s.jsx(_,{address:e}),name:t.subdomain}}),tx:a})}case J:{const{address:e,ens:t,land:n}=a.payload;return s.jsx(o,{subdomain:t.subdomain,text:n?s.jsx(i,{id:"transaction.set_ens_content",values:{address:s.jsx(_,{address:e}),name:t.subdomain,land_link:s.jsx(S,{to:h.landDetail(n.id),children:n.name})}}):s.jsx(i,{id:"transaction.unset_ens_content",values:{address:s.jsx(_,{address:e}),name:t.subdomain}}),tx:a})}case Q:{const{address:e,allowance:t}=a.payload;return s.jsx(o,{address:e,text:G(t)?s.jsx(i,{id:"transaction.allowed_claim_mana",values:{address:s.jsx(_,{address:e})}}):s.jsx(i,{id:"transaction.disallowed_claim_mana",values:{address:s.jsx(_,{address:e})}}),tx:a})}case V:{const{subdomain:e}=a.payload;return s.jsx(o,{subdomain:e,text:s.jsx(i,{id:"transaction.claim_name",values:{name:e}}),tx:a})}case K:{const{ens:e}=a.payload;return s.jsx(o,{subdomain:e.subdomain,text:s.jsx(i,{id:"transaction.reclaim_name",values:{subdomain:e.subdomain}}),tx:a})}case F:{const{count:e,collectionId:t,collectionName:n}=a.payload;return s.jsx(o,{tx:a,collectionId:t,text:s.jsx(i,{id:"transaction.rescue_items",values:{count:e,collectionName:s.jsx(S,{to:h.collectionDetail(t),children:n})}})})}default:return null}},fs=N.memo(As),bs=c=>{const{address:a,transactions:e,onClearHistory:t,isLoggedIn:n}=c,[r,d]=j.useState(!1),u=j.useCallback(()=>{a&&t(a),d(!1)},[a,t]),E=j.useCallback(()=>d(!0),[d]),p=j.useCallback(()=>d(!1),[d]);let m=null;return n?e.length===0?m=s.jsx("div",{className:"center",children:s.jsx("p",{children:x("activity_page.empty")})}):m=s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"history-header",children:[s.jsx("div",{className:"left",children:s.jsx(l.Header,{sub:!0,children:x("activity_page.latest_activity")})}),s.jsx("div",{className:"right",children:s.jsx(l.Button,{basic:!0,onClick:E,children:x("activity_page.clear_history")})})]}),s.jsx("div",{className:"transactions",children:e.map(g=>s.jsx(fs,{tx:g},g.hash)).reverse()})]}):m=s.jsx(Cs,{}),s.jsxs(s.Fragment,{children:[s.jsx(ds,{}),s.jsx(hs,{}),s.jsx(l.Page,{className:"ActivityPage",children:m}),s.jsxs(l.Modal,{size:"tiny",open:r,children:[s.jsx(l.Modal.Header,{children:x("activity_page.clear_history_modal.title")}),s.jsx(l.Modal.Content,{children:x("activity_page.clear_history_modal.text")}),s.jsxs(l.Modal.Actions,{children:[s.jsx(l.Button,{onClick:p,children:x("global.cancel")}),s.jsx(l.Button,{primary:!0,onClick:u,children:x("global.proceed")})]})]}),s.jsx(ms,{})]})},Ls=N.memo(bs),Rs=c=>({isLoggedIn:us(c),address:_s(c),transactions:js(c)}),Os=c=>({onClearHistory:a=>c(Ss(a))}),ws=xs(Rs,Os)(Ls);export{ws as default};
1
+ import{ak as N,N as s,a7 as P,M as x,dJ as k,S as l,dK as v,dL as H,J as j,bP as y,cf as w,bO as B,bQ as _,dM as z,dN as $,dO as F,b6 as i,Q as S,R as h,dP as K,dQ as V,dR as Q,dS as G,dT as J,dU as Y,dV as W,dW as A,dX as q,dY as f,dZ as X,d_ as Z,d$ as b,e0 as L,e1 as R,e2 as O,e3 as ss,e4 as es,e5 as as,e6 as ts,e7 as ns,e8 as is,e9 as cs,ea as os,eb as rs,ec as ls,ed as D,ee as M,ef as U,am as ds,ao as ms,T as xs,aj as us,aM as _s,eg as js,eh as Ss}from"./index-BcJ8MhYC.js";import{b as hs}from"./Navigation.container-Uoa9cAN5.js";import{S as Cs}from"./SignInRequired-BIpJsBqT.js";import{a as Es}from"./date-CZsUie1B.js";import"./selectors-DHi87VFf.js";import"./index-MzNAR7ES.js";const ps="_ensImage_er26d_1",gs="_name_er26d_15",Ns="_small_er26d_23",I={ensImage:ps,name:gs,small:Ns};class Ts extends N.PureComponent{render(){const{subdomain:a,isSmall:e}=this.props;return s.jsx("div",{className:P(I.ensImage,{[I.small]:e}),children:s.jsx("div",{className:I.name,children:a.slice(0,2)})})}}const vs=c=>{const a=c.replacedBy||c.hash;return a?H({txHash:a},c.chainId):""},ys=c=>{const{selection:a,address:e,collectionId:t,item:n,subdomain:r,slotsToyBuy:d}=c,u=j.useMemo(()=>new Set((a||[]).map(C=>y(C.x,C.y))),[a]),E=j.useCallback((C,T)=>u.has(y(C,T))?{color:"#ff0044",scale:1.4}:null,[u]),p=j.useCallback((C,T)=>u.has(y(C,T))?{color:"#ff9990",scale:1.2}:null,[u]),[m,g]=j.useMemo(()=>a?w(a):[0,0],[a]);return a?s.jsx(B,{x:m,y:g,layers:[E,p],width:48,height:48,size:9,isDraggable:!1}):e?s.jsx(_,{address:e,size:"huge",imageOnly:!0}):t?s.jsx(z,{collectionId:t}):n?s.jsx($,{item:n}):r?s.jsx(Ts,{subdomain:r,isSmall:!0}):d?s.jsx("div",{className:"slot-image"}):null},Is=c=>{const{text:a,tx:e}=c;return s.jsxs("div",{className:"TransactionDetail",children:[s.jsxs("div",{className:"left",children:[s.jsx("div",{className:"image",children:s.jsx(ys,{...c})}),s.jsxs("div",{className:"text",children:[s.jsx("div",{className:"description",children:a}),s.jsxs("div",{className:"timestamp",children:[Es(e.timestamp),"."]})]})]}),s.jsx("div",{className:"right",children:s.jsxs("a",{href:vs(e),className:e.status?"status "+e.status:"status",target:"_blank",rel:"noopener noreferrer",children:[s.jsx("div",{className:"description",children:e.status||x("global.loading")}),k(e.status)?s.jsx("div",{className:"spinner",children:s.jsx(l.Loader,{active:!0,size:"mini"})}):null,e.status===v.REVERTED?s.jsx(l.Icon,{name:"warning sign"}):null,e.status===v.CONFIRMED||e.status===v.REPLACED?s.jsx(l.Icon,{name:"check"}):null]})})]})},o=N.memo(Is),As=c=>{const{tx:a}=c;switch(a.actionType){case M:case ls:{const{authorization:e}=a.payload,t=D(e.authorizedAddress),n=D(e.contractAddress),r=a.actionType===M?x("transaction.approved"):x("transaction.unapproved");return s.jsx(o,{address:e.address,text:s.jsx(i,{id:"transaction.approve_token",values:{action:r,contract:s.jsx(U,{chainId:e.chainId,address:e.authorizedAddress,txHash:"",children:t}),token:s.jsx(U,{chainId:e.chainId,address:e.contractAddress,txHash:"",children:n})}}),tx:a})}case rs:{const{name:e,address:t,selection:n}=a.payload;return s.jsx(o,{selection:n,text:s.jsx(i,{id:"transaction.transfer",values:{name:s.jsx("strong",{children:e}),address:s.jsx(_,{address:t})}}),tx:a})}case os:{const{name:e,selection:t}=a.payload;return s.jsx(o,{selection:t,text:s.jsx(i,{id:"transaction.edit",values:{name:s.jsx("strong",{children:e})}}),tx:a})}case cs:{const{name:e,address:t,selection:n}=a.payload;return s.jsx(o,{selection:n,text:s.jsx(i,{id:t?"transaction.set_operator_assigned":"transaction.set_operator_revoked",values:{name:s.jsx("strong",{children:e}),address:s.jsx(_,{address:t})}}),tx:a})}case is:{const{name:e,selection:t}=a.payload;return s.jsx(o,{selection:t,text:s.jsx(i,{id:"transaction.create_estate",values:{name:s.jsx("strong",{children:e})}}),tx:a})}case ns:{const{name:e,count:t,type:n,selection:r}=a.payload;return s.jsx(o,{selection:r,text:s.jsx(i,{id:`transaction.edit_estate_${n}`,values:{name:s.jsx("strong",{children:e}),count:t}}),tx:a})}case ts:{const{name:e,selection:t}=a.payload;return s.jsx(o,{selection:t,text:s.jsx(i,{id:"transaction.dissolve_estate",values:{name:s.jsx("strong",{children:e})}}),tx:a})}case as:{const{address:e,type:t,isApproved:n}=a.payload;return s.jsx(o,{address:e,text:s.jsx(i,{id:n?"transaction.set_manager_assigned":"transaction.set_manager_revoked",values:{address:s.jsx(_,{address:e,textOnly:!0}),type:x(`global.${t}_plural`)}}),tx:a})}case es:{const{item:e}=a.payload;return s.jsx(o,{item:e,text:s.jsx(i,{id:"transaction.set_price_and_beneficiary",values:{name:s.jsx(S,{to:h.itemDetail(e.id),children:e.name})}}),tx:a})}case ss:{const{thirdPartyId:e,thirdPartyName:t}=a.payload;return s.jsx(o,{thirdPartyId:e,text:s.jsx(i,{id:"transaction.disable_third_party",values:{name:t}}),tx:a})}case L:case R:case O:case b:{const{collection:e}=a.payload,t={[L]:"collection_published",[R]:"collection_approved",[O]:"collection_rejected",[b]:"updated_collection_managers"}[a.actionType];return s.jsx(o,{collectionId:e.id,text:s.jsx(i,{id:`transaction.${t}`,values:{name:s.jsx(S,{to:h.collectionDetail(e.id),children:e.name})}}),tx:a})}case X:{const{collection:e,mints:t}=a.payload,n=t.length===1,r=t[0].item,d=n?{item:r}:{collection:e};return s.jsx(o,{...d,text:s.jsx(i,{id:n?"transaction.collection_item_minted":"transaction.collection_items_minted",values:{collectionName:s.jsx(S,{to:h.collectionDetail(e.id),children:e.name}),itemName:s.jsx(S,{to:h.itemDetail(r.id),children:r.name}),count:Z(t)}}),tx:a})}case W:{const{chainId:e}=a,{collection:t,minters:n}=a.payload,r=A(n,t.minters),d=A(t.minters,n),u=q(e),E=f(d,u),p=f(r,u);let m="";return E?m="transaction.unset_collection_on_sale":p?m="transaction.set_collection_on_sale":m="transaction.updated_collection_minters",s.jsx(o,{collectionId:t.id,text:s.jsx(i,{id:m,values:{name:s.jsx(S,{to:h.collectionDetail(t.id),children:t.name})}}),tx:a})}case Y:{const{address:e,ens:t}=a.payload;return s.jsx(o,{subdomain:t.subdomain,text:s.jsx(i,{id:"transaction.set_ens_resolver",values:{address:s.jsx(_,{address:e}),name:t.subdomain}}),tx:a})}case J:{const{address:e,ens:t,land:n}=a.payload;return s.jsx(o,{subdomain:t.subdomain,text:n?s.jsx(i,{id:"transaction.set_ens_content",values:{address:s.jsx(_,{address:e}),name:t.subdomain,land_link:s.jsx(S,{to:h.landDetail(n.id),children:n.name})}}):s.jsx(i,{id:"transaction.unset_ens_content",values:{address:s.jsx(_,{address:e}),name:t.subdomain}}),tx:a})}case Q:{const{address:e,allowance:t}=a.payload;return s.jsx(o,{address:e,text:G(t)?s.jsx(i,{id:"transaction.allowed_claim_mana",values:{address:s.jsx(_,{address:e})}}):s.jsx(i,{id:"transaction.disallowed_claim_mana",values:{address:s.jsx(_,{address:e})}}),tx:a})}case V:{const{subdomain:e}=a.payload;return s.jsx(o,{subdomain:e,text:s.jsx(i,{id:"transaction.claim_name",values:{name:e}}),tx:a})}case K:{const{ens:e}=a.payload;return s.jsx(o,{subdomain:e.subdomain,text:s.jsx(i,{id:"transaction.reclaim_name",values:{subdomain:e.subdomain}}),tx:a})}case F:{const{count:e,collectionId:t,collectionName:n}=a.payload;return s.jsx(o,{tx:a,collectionId:t,text:s.jsx(i,{id:"transaction.rescue_items",values:{count:e,collectionName:s.jsx(S,{to:h.collectionDetail(t),children:n})}})})}default:return null}},fs=N.memo(As),bs=c=>{const{address:a,transactions:e,onClearHistory:t,isLoggedIn:n}=c,[r,d]=j.useState(!1),u=j.useCallback(()=>{a&&t(a),d(!1)},[a,t]),E=j.useCallback(()=>d(!0),[d]),p=j.useCallback(()=>d(!1),[d]);let m=null;return n?e.length===0?m=s.jsx("div",{className:"center",children:s.jsx("p",{children:x("activity_page.empty")})}):m=s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"history-header",children:[s.jsx("div",{className:"left",children:s.jsx(l.Header,{sub:!0,children:x("activity_page.latest_activity")})}),s.jsx("div",{className:"right",children:s.jsx(l.Button,{basic:!0,onClick:E,children:x("activity_page.clear_history")})})]}),s.jsx("div",{className:"transactions",children:e.map(g=>s.jsx(fs,{tx:g},g.hash)).reverse()})]}):m=s.jsx(Cs,{}),s.jsxs(s.Fragment,{children:[s.jsx(ds,{}),s.jsx(hs,{}),s.jsx(l.Page,{className:"ActivityPage",children:m}),s.jsxs(l.Modal,{size:"tiny",open:r,children:[s.jsx(l.Modal.Header,{children:x("activity_page.clear_history_modal.title")}),s.jsx(l.Modal.Content,{children:x("activity_page.clear_history_modal.text")}),s.jsxs(l.Modal.Actions,{children:[s.jsx(l.Button,{onClick:p,children:x("global.cancel")}),s.jsx(l.Button,{primary:!0,onClick:u,children:x("global.proceed")})]})]}),s.jsx(ms,{})]})},Ls=N.memo(bs),Rs=c=>({isLoggedIn:us(c),address:_s(c),transactions:js(c)}),Os=c=>({onClearHistory:a=>c(Ss(a))}),ws=xs(Rs,Os)(Ls);export{ws as default};
@@ -1 +1 @@
1
- var Y=Object.defineProperty;var J=(r,a,n)=>a in r?Y(r,a,{enumerable:!0,configurable:!0,writable:!0,value:n}):r[a]=n;var P=(r,a,n)=>J(r,typeof a!="symbol"?a+"":a,n);import{J as c,N as e,P as X,a4 as Z,R as M,eB as F,e$ as V,f0 as w,f1 as I,eY as H,f2 as $,f3 as ee,f4 as S,f5 as se,f6 as ae,f7 as te,S as i,M as t,dN as ie,f8 as le,f9 as T,fa as ne,fb as ce,fc as re,Q as oe,eA as de,cN as ue,fd as me,fe as z,aR as he,ff as pe,cM as xe,fg as je,fh as ge,fi as ve,fj as Ne,aa as be,ab as g,ej as fe,fk as Ie,fl as _e,fm as Ce,eN as ye,fn as Ee,bq as D,fo as ke,fp as Se,ey as Te,a2 as Pe,eW as Me,fq as we,fr as De}from"./index-c1n4wbjs.js";import{d as Re}from"./hooks-NbgarCWS.js";import{I as Le}from"./ItemProvider.container-1h7f1i_E.js";import{C as Be}from"./ConfirmDelete-DO_4Toph.js";import{L as Ue}from"./LoggedInDetailPage.container-aKqZJkZw.js";import{N as Oe}from"./NotFound-BHz1EMnb.js";import{B as Ae}from"./Back-MtsmBnan.js";import"./Navigation.container-CKqSZREi.js";import"./selectors-qQAG8WAy.js";import"./SignInRequired-CGzWIVAU.js";class qe extends c.PureComponent{constructor(n){super(n);P(this,"state",{isNoticeClosed:!1});P(this,"handleCloseNotice",()=>{const{storageKey:n}=this.props;this.setState({isNoticeClosed:!0}),localStorage.setItem(n,"1")});const{storageKey:o}=n;this.state={isNoticeClosed:localStorage.getItem(o)!==null}}render(){const{children:n}=this.props,{isNoticeClosed:o}=this.state;return o?null:e.jsxs("div",{className:"Notice",children:[e.jsx("div",{className:"text",children:n}),e.jsx(X,{name:"close",onClick:this.handleCloseNotice})]})}}const Fe="dcl-item-notice";function Ve(r){const{item:a,itemId:n,isLoading:o,status:v,collection:_,hasAccess:N,isWearableUtilityEnabled:C,onDelete:y,onSaveItem:p,onOpenModal:u}=r,j=c.useRef(null),b=Z(),f=c.useCallback(()=>{a&&b.push(M.itemEditor({itemId:a.id,collectionId:a.collectionId}),{fromParam:F(a.urn)?V.TP_COLLECTIONS:V.COLLECTIONS})},[b,a]),d=c.useCallback(async s=>{const l=await w({[I]:s}),h={...a,contents:{...a==null?void 0:a.contents,[I]:l[I]}};v&&[H.UNPUBLISHED,H.UNDER_REVIEW].includes(v)&&(h.video=l[I]),p(h,{[I]:s})},[p,a,v]),x=c.useCallback(()=>{u("EditVideoModal",{item:a,onSaveVideo:d})},[a,u,d]),R=c.useCallback(()=>{y(a)},[a,y]),E=c.useCallback(()=>{a&&$(a)?u("CreateSingleItemModal",{item:a,addRepresentation:!0}):u("CreateSingleItemModal",{item:a,changeItemFile:!0})},[u,a]),L=c.useCallback(()=>{u("EditItemURNModal",{item:a})},[a,u]),B=c.useCallback(async s=>{const l=ee(s);p({...a,contents:{...a==null?void 0:a.contents,...await w({[S]:l})}},{[S]:l})},[p,a]),U=c.useCallback(()=>{(a==null?void 0:a.type)===se.EMOTE?u("EditThumbnailModal",{onSaveThumbnail:B,item:a,collection:_}):j.current&&j.current.click()},[j.current,_,a,u,B]),O=c.useCallback(async s=>{const{files:l}=s.target;if(l&&l.length>0){const h=l[0],k=await ae(h,1024,1024);k&&a&&(a.contents={...a.contents,...await w({[S]:k})},p(a,{[S]:k}))}},[p,a]),A=c.useCallback(()=>{u("MoveItemToCollectionModal",{item:a})},[a,u]),W=c.useCallback((s,l)=>{var q;const h=s.data,K=!(l&&te(l));return e.jsxs(e.Fragment,{children:[e.jsx(i.Section,{children:e.jsx(i.Row,{children:e.jsx(Ae,{onClick:()=>b.push(M.collectionDetail(s.collectionId))})})}),e.jsxs(i.Narrow,{children:[!l&&!s.collectionId?e.jsx(qe,{storageKey:Fe,children:t("item_detail_page.notice")}):null,e.jsxs("div",{className:"item-data",children:[e.jsxs("div",{className:"item-data-left-panel",children:[e.jsx(ie,{item:s,hasBadge:!0,hasRarityBadge:!0,hasUtilityBadge:!0}),e.jsx("div",{children:e.jsxs(i.Button,{primary:!0,onClick:U,children:[e.jsx("input",{type:"file",ref:j,onChange:O,accept:"image/png"}),e.jsx(i.Icon,{name:"camera"}),t("item_detail_page.edit_thumbnail")]})}),e.jsxs("div",{className:"metrics",children:[e.jsx("span",{className:"subtitle",children:t("item_detail_page.properties")}),e.jsx(le,{item:s})]}),T(s)?e.jsx(ne,{item:s,onClick:x,children:(m,Q,G,$e)=>e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"overlay",children:e.jsx(i.Icon,{name:"play",className:"play-video-button",onClick:x})}),e.jsxs(i.Button,{primary:!0,onClick:x,children:[e.jsx(i.Icon,{name:"video"}),t("item_detail_page.edit_video")]}),e.jsxs("div",{className:"metrics",children:[e.jsx("div",{className:"subtitle",children:t("item_detail_page.properties")}),e.jsx(ce,{duration:Q,size:G,showIcons:!1})]})]})}):null,e.jsxs("div",{className:"details",children:[e.jsx("div",{className:"subtitle",children:t("item_detail_page.details")}),s.isPublished&&e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("item_detail_page.details_info.id")}),e.jsxs("div",{className:"value",children:["#",s.tokenId]})]}),h.category?e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("item.category")}),e.jsx("div",{className:"value",children:t(`${s.type}.category.${h.category}`)})]}):null,s.isPublished&&s.rarity?e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("item.supply")}),e.jsxs("div",{className:"value",children:[s.totalSupply,"/",re(s)]})]}):null,l?e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("item.collection")}),e.jsx(oe,{className:"collection-link",to:M.collectionDetail(l.id,de(l)),children:l.name})]}):null,s.urn?e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("global.urn")}),e.jsxs("div",{className:"value urn",children:[e.jsxs("span",{children:[s.urn,e.jsx(ue,{role:"button",text:s.urn,children:e.jsx(i.Icon,{"aria-label":"Copy urn","aria-hidden":"false",className:"link copy",name:"copy outline"})})]}),e.jsx("div",{className:"urn-actions",children:F(s.urn)?e.jsx(i.Popup,{content:t("collection_item.cannot_edit_urn"),disabled:!s.isPublished,position:"top center",trigger:e.jsx("div",{children:e.jsx("button",{disabled:s.isPublished,className:"link",onClick:L,children:t("item.edit_urn")})}),hideOnScroll:!0,on:"hover",inverted:!0,flowing:!0}):null})]})]}):null]})]}),e.jsxs("div",{className:"cards-container",children:[e.jsxs("div",{className:"card",children:[e.jsxs("div",{className:"title-card-container",children:[e.jsx("div",{className:"title",children:s.name}),e.jsxs("div",{className:"actions",children:[T(s)&&e.jsx(i.Button,{className:"edit",inverted:!0,size:"small",onClick:E,children:t("global.edit")}),e.jsx(i.Button,{inverted:!0,size:"small",onClick:f,children:t("collection_detail_page.preview")}),K?e.jsx(i.Dropdown,{trigger:e.jsx(i.Button,{basic:!0,className:"more-actions-button",children:e.jsx(i.Icon,{name:"ellipsis horizontal"})}),inline:!0,direction:"left",children:e.jsxs(i.Dropdown.Menu,{children:[e.jsx(Be,{name:s.name,onDelete:R,trigger:s.isPublished?e.jsx(i.Popup,{content:t("item_detail_page.delete_published_item"),position:"right center",trigger:e.jsx(i.Dropdown.Item,{disabled:!0,text:t("global.delete")}),hideOnScroll:!0,on:"hover",inverted:!0,flowing:!0}):e.jsx(i.Dropdown.Item,{text:t("global.delete")})}),!s.collectionId&&e.jsx(i.Dropdown.Item,{text:t("collection_item.move_to_another_collection"),onClick:A})]})}):null]})]}),e.jsxs("div",{className:"attribute-row",children:[s.description&&e.jsxs("div",{className:"attribute-column",children:[e.jsx("div",{className:"subtitle",children:t("global.description")}),e.jsx("div",{className:"data",children:s.description})]}),s.utility&&C&&e.jsxs("div",{className:"attribute-column",children:[e.jsx("div",{className:"subtitle",children:t("global.utility")}),e.jsx("div",{className:"data",children:s.utility})]})]}),s.data.tags.length?e.jsx("div",{className:"attribute-row",children:e.jsxs("div",{className:"attribute-column",children:[e.jsx("div",{className:"subtitle",children:t("item_detail_page.tags.title")}),e.jsx("div",{className:"data tags-container",children:s.data.tags.map(m=>e.jsx("span",{className:"tag",children:m},m))})]})}):null]}),e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"title",children:t("item_detail_page.selling.title")}),e.jsxs("div",{className:"data",children:[me(s)?e.jsxs(i.Section,{className:"price-container",children:[e.jsx("div",{className:"subtitle",children:t("item.price")}),e.jsx("div",{className:"value",children:t("global.free")})]}):s.price?e.jsxs(i.Section,{className:"price-container",children:[e.jsx("div",{className:"subtitle",children:t("item.price")}),s.price&&s.price!==z.toString()?e.jsx(i.Mana,{showTooltip:!0,network:he.Network.MATIC,className:"mana-price-container",children:(()=>{const m=pe(s.price);return m.length>10?e.jsx(i.Popup,{content:m,position:"top center",trigger:e.jsx("span",{children:`${m.slice(0,3)}...${m.slice(-4)}`}),hideOnScroll:!0,on:"hover",inverted:!0,flowing:!0}):e.jsx("div",{className:"value",children:m})})()}):s.price===z.toString()?e.jsx("div",{className:"value",children:t("item.not_for_sale")}):"-"]}):null,e.jsxs(i.Section,{className:"beneficiary-container",children:[e.jsx("div",{className:"subtitle",children:t("item.beneficiary")}),s.beneficiary?e.jsx("div",{className:"value",children:xe(s.beneficiary)}):"-"]})]})]}),je(s)&&!T(s)?e.jsxs("div",{className:"card",children:[e.jsxs("div",{className:"title-card-container",children:[e.jsx("div",{className:"title",children:t("item_detail_page.representations.title")}),e.jsx(i.Button,{className:"edit-button",inverted:!0,size:"small",onClick:E,children:$(s)?t("global.add"):t("global.edit")})]}),e.jsx("div",{className:"data",children:e.jsx("div",{className:"representations-container",children:s.data.representations.map(m=>e.jsxs("div",{className:"representation",children:[e.jsx("img",{className:"item-image",src:ge(s),alt:s.name}),m.mainFile,e.jsx(ve,{item:s,bodyShape:m.bodyShapes[0]})]},m.mainFile))})})]}):null,T(s)&&((q=s.data.requiredPermissions)!=null&&q.length)?e.jsxs("div",{className:"card",children:[e.jsxs("div",{className:"title-card-container",children:[e.jsx("div",{className:"title",children:t("item_detail_page.required_permissions")}),e.jsx(i.Button,{inverted:!0,className:"learn-more-permissions",size:"small",href:"https://docs.decentraland.org/creator/development-guide/sdk7/scene-metadata/#required-permissions",rel:"noopener noreferrer",target:"_blank",content:t("global.learn_more")})]}),e.jsx("div",{className:"data",children:e.jsx(Ne,{requiredPermissions:s.data.requiredPermissions,basic:!0})})]}):null]})]})]})]})},[C,b,j,U,O,x,L,E,E,A,f,R,f]);return e.jsx(Le,{id:n,children:(s,l,h)=>e.jsx(Ue,{className:"ItemDetailPage",hasNavigation:!N&&!o,isLoading:o||h,children:N&&s?W(s,l):e.jsx(Oe,{})})})}const He=()=>{const r=be(),a=Re(),n=g(fe),o=g(d=>a?Ie(d,a):null),v=g(d=>o&&o.collectionId?_e(d,o.collectionId):null),_=g(Ce),N=g(ye),C=g(Ee),y=o?_[o.id]:null,p=D(N,Me)||D(N,we)||D(N,De),u=g(d=>o!==null&&ke(d,n.address,v,o)),j=c.useCallback((d,x)=>r(Se(d,x)),[r]),b=c.useCallback(d=>r(Te(d)),[r]),f=c.useCallback((d,x)=>r(Pe(d,x)),[r]);return e.jsx(Ve,{itemId:a,wallet:n,item:o,collection:v,status:y,isLoading:p,isWearableUtilityEnabled:C,hasAccess:u,onSaveItem:j,onDelete:b,onOpenModal:f})},as=He;export{as as default};
1
+ var Y=Object.defineProperty;var J=(r,a,n)=>a in r?Y(r,a,{enumerable:!0,configurable:!0,writable:!0,value:n}):r[a]=n;var P=(r,a,n)=>J(r,typeof a!="symbol"?a+"":a,n);import{J as c,N as e,P as X,a4 as Z,R as M,eB as F,e$ as V,f0 as w,f1 as I,eY as H,f2 as $,f3 as ee,f4 as S,f5 as se,f6 as ae,f7 as te,S as i,M as t,dN as ie,f8 as le,f9 as T,fa as ne,fb as ce,fc as re,Q as oe,eA as de,cN as ue,fd as me,fe as z,aR as he,ff as pe,cM as xe,fg as je,fh as ge,fi as ve,fj as Ne,aa as be,ab as g,ej as fe,fk as Ie,fl as _e,fm as Ce,eN as ye,fn as Ee,bq as D,fo as ke,fp as Se,ey as Te,a2 as Pe,eW as Me,fq as we,fr as De}from"./index-BcJ8MhYC.js";import{d as Re}from"./hooks-DXNgH_m2.js";import{I as Le}from"./ItemProvider.container-QONgvAiC.js";import{C as Be}from"./ConfirmDelete-BvGTAe45.js";import{L as Ue}from"./LoggedInDetailPage.container-CsvKBMuj.js";import{N as Oe}from"./NotFound-4sT-K9SU.js";import{B as Ae}from"./Back-CncB3o4T.js";import"./Navigation.container-Uoa9cAN5.js";import"./selectors-DHi87VFf.js";import"./SignInRequired-BIpJsBqT.js";class qe extends c.PureComponent{constructor(n){super(n);P(this,"state",{isNoticeClosed:!1});P(this,"handleCloseNotice",()=>{const{storageKey:n}=this.props;this.setState({isNoticeClosed:!0}),localStorage.setItem(n,"1")});const{storageKey:o}=n;this.state={isNoticeClosed:localStorage.getItem(o)!==null}}render(){const{children:n}=this.props,{isNoticeClosed:o}=this.state;return o?null:e.jsxs("div",{className:"Notice",children:[e.jsx("div",{className:"text",children:n}),e.jsx(X,{name:"close",onClick:this.handleCloseNotice})]})}}const Fe="dcl-item-notice";function Ve(r){const{item:a,itemId:n,isLoading:o,status:v,collection:_,hasAccess:N,isWearableUtilityEnabled:C,onDelete:y,onSaveItem:p,onOpenModal:u}=r,j=c.useRef(null),b=Z(),f=c.useCallback(()=>{a&&b.push(M.itemEditor({itemId:a.id,collectionId:a.collectionId}),{fromParam:F(a.urn)?V.TP_COLLECTIONS:V.COLLECTIONS})},[b,a]),d=c.useCallback(async s=>{const l=await w({[I]:s}),h={...a,contents:{...a==null?void 0:a.contents,[I]:l[I]}};v&&[H.UNPUBLISHED,H.UNDER_REVIEW].includes(v)&&(h.video=l[I]),p(h,{[I]:s})},[p,a,v]),x=c.useCallback(()=>{u("EditVideoModal",{item:a,onSaveVideo:d})},[a,u,d]),R=c.useCallback(()=>{y(a)},[a,y]),E=c.useCallback(()=>{a&&$(a)?u("CreateSingleItemModal",{item:a,addRepresentation:!0}):u("CreateSingleItemModal",{item:a,changeItemFile:!0})},[u,a]),L=c.useCallback(()=>{u("EditItemURNModal",{item:a})},[a,u]),B=c.useCallback(async s=>{const l=ee(s);p({...a,contents:{...a==null?void 0:a.contents,...await w({[S]:l})}},{[S]:l})},[p,a]),U=c.useCallback(()=>{(a==null?void 0:a.type)===se.EMOTE?u("EditThumbnailModal",{onSaveThumbnail:B,item:a,collection:_}):j.current&&j.current.click()},[j.current,_,a,u,B]),O=c.useCallback(async s=>{const{files:l}=s.target;if(l&&l.length>0){const h=l[0],k=await ae(h,1024,1024);k&&a&&(a.contents={...a.contents,...await w({[S]:k})},p(a,{[S]:k}))}},[p,a]),A=c.useCallback(()=>{u("MoveItemToCollectionModal",{item:a})},[a,u]),W=c.useCallback((s,l)=>{var q;const h=s.data,K=!(l&&te(l));return e.jsxs(e.Fragment,{children:[e.jsx(i.Section,{children:e.jsx(i.Row,{children:e.jsx(Ae,{onClick:()=>b.push(M.collectionDetail(s.collectionId))})})}),e.jsxs(i.Narrow,{children:[!l&&!s.collectionId?e.jsx(qe,{storageKey:Fe,children:t("item_detail_page.notice")}):null,e.jsxs("div",{className:"item-data",children:[e.jsxs("div",{className:"item-data-left-panel",children:[e.jsx(ie,{item:s,hasBadge:!0,hasRarityBadge:!0,hasUtilityBadge:!0}),e.jsx("div",{children:e.jsxs(i.Button,{primary:!0,onClick:U,children:[e.jsx("input",{type:"file",ref:j,onChange:O,accept:"image/png"}),e.jsx(i.Icon,{name:"camera"}),t("item_detail_page.edit_thumbnail")]})}),e.jsxs("div",{className:"metrics",children:[e.jsx("span",{className:"subtitle",children:t("item_detail_page.properties")}),e.jsx(le,{item:s})]}),T(s)?e.jsx(ne,{item:s,onClick:x,children:(m,Q,G,$e)=>e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"overlay",children:e.jsx(i.Icon,{name:"play",className:"play-video-button",onClick:x})}),e.jsxs(i.Button,{primary:!0,onClick:x,children:[e.jsx(i.Icon,{name:"video"}),t("item_detail_page.edit_video")]}),e.jsxs("div",{className:"metrics",children:[e.jsx("div",{className:"subtitle",children:t("item_detail_page.properties")}),e.jsx(ce,{duration:Q,size:G,showIcons:!1})]})]})}):null,e.jsxs("div",{className:"details",children:[e.jsx("div",{className:"subtitle",children:t("item_detail_page.details")}),s.isPublished&&e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("item_detail_page.details_info.id")}),e.jsxs("div",{className:"value",children:["#",s.tokenId]})]}),h.category?e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("item.category")}),e.jsx("div",{className:"value",children:t(`${s.type}.category.${h.category}`)})]}):null,s.isPublished&&s.rarity?e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("item.supply")}),e.jsxs("div",{className:"value",children:[s.totalSupply,"/",re(s)]})]}):null,l?e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("item.collection")}),e.jsx(oe,{className:"collection-link",to:M.collectionDetail(l.id,de(l)),children:l.name})]}):null,s.urn?e.jsxs("div",{children:[e.jsx("div",{className:"subtitle",children:t("global.urn")}),e.jsxs("div",{className:"value urn",children:[e.jsxs("span",{children:[s.urn,e.jsx(ue,{role:"button",text:s.urn,children:e.jsx(i.Icon,{"aria-label":"Copy urn","aria-hidden":"false",className:"link copy",name:"copy outline"})})]}),e.jsx("div",{className:"urn-actions",children:F(s.urn)?e.jsx(i.Popup,{content:t("collection_item.cannot_edit_urn"),disabled:!s.isPublished,position:"top center",trigger:e.jsx("div",{children:e.jsx("button",{disabled:s.isPublished,className:"link",onClick:L,children:t("item.edit_urn")})}),hideOnScroll:!0,on:"hover",inverted:!0,flowing:!0}):null})]})]}):null]})]}),e.jsxs("div",{className:"cards-container",children:[e.jsxs("div",{className:"card",children:[e.jsxs("div",{className:"title-card-container",children:[e.jsx("div",{className:"title",children:s.name}),e.jsxs("div",{className:"actions",children:[T(s)&&e.jsx(i.Button,{className:"edit",inverted:!0,size:"small",onClick:E,children:t("global.edit")}),e.jsx(i.Button,{inverted:!0,size:"small",onClick:f,children:t("collection_detail_page.preview")}),K?e.jsx(i.Dropdown,{trigger:e.jsx(i.Button,{basic:!0,className:"more-actions-button",children:e.jsx(i.Icon,{name:"ellipsis horizontal"})}),inline:!0,direction:"left",children:e.jsxs(i.Dropdown.Menu,{children:[e.jsx(Be,{name:s.name,onDelete:R,trigger:s.isPublished?e.jsx(i.Popup,{content:t("item_detail_page.delete_published_item"),position:"right center",trigger:e.jsx(i.Dropdown.Item,{disabled:!0,text:t("global.delete")}),hideOnScroll:!0,on:"hover",inverted:!0,flowing:!0}):e.jsx(i.Dropdown.Item,{text:t("global.delete")})}),!s.collectionId&&e.jsx(i.Dropdown.Item,{text:t("collection_item.move_to_another_collection"),onClick:A})]})}):null]})]}),e.jsxs("div",{className:"attribute-row",children:[s.description&&e.jsxs("div",{className:"attribute-column",children:[e.jsx("div",{className:"subtitle",children:t("global.description")}),e.jsx("div",{className:"data",children:s.description})]}),s.utility&&C&&e.jsxs("div",{className:"attribute-column",children:[e.jsx("div",{className:"subtitle",children:t("global.utility")}),e.jsx("div",{className:"data",children:s.utility})]})]}),s.data.tags.length?e.jsx("div",{className:"attribute-row",children:e.jsxs("div",{className:"attribute-column",children:[e.jsx("div",{className:"subtitle",children:t("item_detail_page.tags.title")}),e.jsx("div",{className:"data tags-container",children:s.data.tags.map(m=>e.jsx("span",{className:"tag",children:m},m))})]})}):null]}),e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"title",children:t("item_detail_page.selling.title")}),e.jsxs("div",{className:"data",children:[me(s)?e.jsxs(i.Section,{className:"price-container",children:[e.jsx("div",{className:"subtitle",children:t("item.price")}),e.jsx("div",{className:"value",children:t("global.free")})]}):s.price?e.jsxs(i.Section,{className:"price-container",children:[e.jsx("div",{className:"subtitle",children:t("item.price")}),s.price&&s.price!==z.toString()?e.jsx(i.Mana,{showTooltip:!0,network:he.Network.MATIC,className:"mana-price-container",children:(()=>{const m=pe(s.price);return m.length>10?e.jsx(i.Popup,{content:m,position:"top center",trigger:e.jsx("span",{children:`${m.slice(0,3)}...${m.slice(-4)}`}),hideOnScroll:!0,on:"hover",inverted:!0,flowing:!0}):e.jsx("div",{className:"value",children:m})})()}):s.price===z.toString()?e.jsx("div",{className:"value",children:t("item.not_for_sale")}):"-"]}):null,e.jsxs(i.Section,{className:"beneficiary-container",children:[e.jsx("div",{className:"subtitle",children:t("item.beneficiary")}),s.beneficiary?e.jsx("div",{className:"value",children:xe(s.beneficiary)}):"-"]})]})]}),je(s)&&!T(s)?e.jsxs("div",{className:"card",children:[e.jsxs("div",{className:"title-card-container",children:[e.jsx("div",{className:"title",children:t("item_detail_page.representations.title")}),e.jsx(i.Button,{className:"edit-button",inverted:!0,size:"small",onClick:E,children:$(s)?t("global.add"):t("global.edit")})]}),e.jsx("div",{className:"data",children:e.jsx("div",{className:"representations-container",children:s.data.representations.map(m=>e.jsxs("div",{className:"representation",children:[e.jsx("img",{className:"item-image",src:ge(s),alt:s.name}),m.mainFile,e.jsx(ve,{item:s,bodyShape:m.bodyShapes[0]})]},m.mainFile))})})]}):null,T(s)&&((q=s.data.requiredPermissions)!=null&&q.length)?e.jsxs("div",{className:"card",children:[e.jsxs("div",{className:"title-card-container",children:[e.jsx("div",{className:"title",children:t("item_detail_page.required_permissions")}),e.jsx(i.Button,{inverted:!0,className:"learn-more-permissions",size:"small",href:"https://docs.decentraland.org/creator/development-guide/sdk7/scene-metadata/#required-permissions",rel:"noopener noreferrer",target:"_blank",content:t("global.learn_more")})]}),e.jsx("div",{className:"data",children:e.jsx(Ne,{requiredPermissions:s.data.requiredPermissions,basic:!0})})]}):null]})]})]})]})},[C,b,j,U,O,x,L,E,E,A,f,R,f]);return e.jsx(Le,{id:n,children:(s,l,h)=>e.jsx(Ue,{className:"ItemDetailPage",hasNavigation:!N&&!o,isLoading:o||h,children:N&&s?W(s,l):e.jsx(Oe,{})})})}const He=()=>{const r=be(),a=Re(),n=g(fe),o=g(d=>a?Ie(d,a):null),v=g(d=>o&&o.collectionId?_e(d,o.collectionId):null),_=g(Ce),N=g(ye),C=g(Ee),y=o?_[o.id]:null,p=D(N,Me)||D(N,we)||D(N,De),u=g(d=>o!==null&&ke(d,n.address,v,o)),j=c.useCallback((d,x)=>r(Se(d,x)),[r]),b=c.useCallback(d=>r(Te(d)),[r]),f=c.useCallback((d,x)=>r(Pe(d,x)),[r]);return e.jsx(Ve,{itemId:a,wallet:n,item:o,collection:v,status:y,isLoading:p,isWearableUtilityEnabled:C,hasAccess:u,onSaveItem:j,onDelete:b,onOpenModal:f})},as=He;export{as as default};