From c40d1d615a0ecf90910983fbcb6689287187b7c6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 24 Sep 2023 04:07:52 +0000 Subject: [PATCH] GitHub Actions: Sep 24 2023 (Build 33) --- asset-manifest.json | 4 ++-- index.html | 2 +- static/js/main.78bdf276.chunk.js | 1 + static/js/main.a92aa60b.chunk.js | 1 - 4 files changed, 4 insertions(+), 4 deletions(-) create mode 100644 static/js/main.78bdf276.chunk.js delete mode 100644 static/js/main.a92aa60b.chunk.js diff --git a/asset-manifest.json b/asset-manifest.json index 94e9f0c..e1bd515 100644 --- a/asset-manifest.json +++ b/asset-manifest.json @@ -1,7 +1,7 @@ { "files": { "main.css": "/static/css/main.6167e0b5.chunk.css", - "main.js": "/static/js/main.a92aa60b.chunk.js", + "main.js": "/static/js/main.78bdf276.chunk.js", "runtime-main.js": "/static/js/runtime-main.d2bd7279.js", "static/css/2.27305ffe.chunk.css": "/static/css/2.27305ffe.chunk.css", "static/js/2.151f3617.chunk.js": "/static/js/2.151f3617.chunk.js", @@ -13,6 +13,6 @@ "static/css/2.27305ffe.chunk.css", "static/js/2.151f3617.chunk.js", "static/css/main.6167e0b5.chunk.css", - "static/js/main.a92aa60b.chunk.js" + "static/js/main.78bdf276.chunk.js" ] } \ No newline at end of file diff --git a/index.html b/index.html index ab33d5f..f56e9fc 100644 --- a/index.html +++ b/index.html @@ -1 +1 @@ -MapleStory Music - BGM & OST Database
\ No newline at end of file +MapleStory Music - BGM & OST Database
\ No newline at end of file diff --git a/static/js/main.78bdf276.chunk.js b/static/js/main.78bdf276.chunk.js new file mode 100644 index 0000000..ba6624c --- /dev/null +++ b/static/js/main.78bdf276.chunk.js @@ -0,0 +1 @@ +(this["webpackJsonpmaplestory-music"]=this["webpackJsonpmaplestory-music"]||[]).push([[0],{180:function(e,t,n){},181:function(e,t,n){},262:function(e,t,n){"use strict";n.r(t);var r,a,o,c,i=n(0),l=n.n(i),u=n(25),s=n.n(u),d=(n(180),n(10)),b=n(6),f=n(11),h=(n(181),n(64)),m=n(19),g=n(34),j=n(281),O=n(285),p=n(275),v=n(139),y=n(3),C=function(){return Object(y.c)("div",{children:[Object(y.c)("div",{css:Object(f.a)(r||(r=Object(d.a)(["\n @media (min-width: 1024px) {\n margin-right: 33vw;\n }\n "]))),children:[Object(y.b)("h2",{children:"About"}),Object(y.b)("p",{children:"This database catalogs music from every region of MapleStory and aims to be the definitive resource for MapleStory music. It will be updated whenever new songs are added to the client of any region."}),Object(y.b)("h6",{children:Object(y.b)("b",{children:"Music Playback"})}),Object(y.b)("p",{children:"Music is played within an embedded YouTube player. The track is looped upon completion, unless in the shuffled queue mode (see below)."}),Object(y.b)("h6",{children:Object(y.b)("b",{children:"Shuffled Queue"})}),Object(y.b)("p",{children:"The shuffled queue feature randomizes the entire music collection and plays upcoming songs automatically. Skip to the next track or return to the previous track with the controls under the media player. When filters are applied to the grid, the song pool is limited to the filtered entries."}),Object(y.b)("h6",{children:Object(y.b)("b",{children:"Grid Controls"})}),Object(y.b)("p",{children:"To sort by a column, press the column header. Hover over a column header and press the menu icon to access the advanced filter dialog. Mobile users can access the filter dialog by pressing and holding the column header."}),Object(y.b)("h6",{children:Object(y.b)("b",{children:"Language"})}),Object(y.b)("p",{children:"Language support is a work in progress. Changing the language will translate metadata displayed for the songs in the grid. If there are no translations for an entry, English will be used as the default language."})]}),Object(y.b)("h2",{children:"Source"}),Object(y.b)("p",{children:"The following GitHub projects power this site."}),Object(y.c)("div",{className:"gh-project-entry",children:[Object(y.b)(v.a,{href:"https://github.com/maplestory-music/maplebgm-db","data-size":"large","data-show-count":!0,"aria-label":"Star maplestory-music/maplebgm-db on GitHub",children:"Star"}),Object(y.b)("h5",{className:"gh-project-name",children:"maplebgm-db: Definitive MapleStory music database"})]}),Object(y.c)("div",{className:"gh-project-entry",children:[Object(y.b)(v.a,{href:"https://github.com/maplestory-music/maplestory-music.github.io","data-size":"large","data-show-count":!0,"aria-label":"Star maplestory-music/maplestory-music.github.io on GitHub",children:"Star"}),Object(y.b)("h5",{className:"gh-project-name",children:"maplestory-music: MapleStory Music website"})]})]})},k=n(1),S=n(101),w=(n(209),n(210),n(211),n(278)),x="#6495ed",B=n(2),A=function(e){return Object(B.jsx)("span",{children:Object(B.jsx)("img",{src:"mark/".concat(e.value,".png"),alt:"icon"})})},N=n(282),M=n(268),T=function(e){var t=e.youtube,n=e.title;return""!==t?Object(y.c)("span",{children:[Object(y.b)(N.a,{delay:{show:250,hide:100},overlay:Object(y.b)(M.a,{id:"tooltip-ext-link",children:"View on YouTube"}),children:Object(y.b)("a",{css:Object(f.a)(a||(a=Object(d.a)(["\n margin-right: 3px;\n "]))),className:"bgm-external-link-icon",href:"https://youtu.be/".concat(t),rel:"noopener noreferrer",target:"_blank",onClick:function(){gtag("event","ce_view_external_video",{ce_category:"video",ce_youtube:e.youtube})},children:Object(y.b)("i",{className:"fa fa-external-link"})})}),Object(y.b)("a",{href:"# ",rel:"noopener noreferrer",onClick:function(t){gtag("event","ce_view_embedded_video",{ce_category:"video",ce_youtube:e.youtube}),e.onGridSongChange(e.youtube),t.preventDefault()},children:n})]}):Object(y.b)("span",{children:n})},D=n(286),F=n(269),Q=function(e){var t=e.value,n=new Date,r=Object(D.a)(n,t)<3||Object(F.a)(t);return Object(y.c)("div",{className:"date-col",children:[Object(y.b)("span",{css:Object(f.a)(o||(o=Object(d.a)(["\n margin-right: 3px;\n "]))),children:e.valueFormatted}),!e.disableRecentTrack&&r&&Object(y.b)(N.a,{delay:{show:250,hide:100},overlay:Object(y.b)(M.a,{id:"tooltip-recent-track",children:"Recent Track"}),children:Object(y.b)("i",{className:"fa fa-star","aria-hidden":!0})})]})},_=n(287),z=l.a.createContext(void 0),E=function(e){var t=e.children,n=l.a.useState(darkmode.inDarkMode),r=Object(b.a)(n,2),a=r[0],o=r[1];return Object(i.useEffect)((function(){var e=localStorage.getItem("bs.prefers-color-scheme");void 0!==e&&o("dark"===e)}),[]),Object(i.useEffect)((function(){var e=document.documentElement,t=new MutationObserver((function(e){var t=null===e||void 0===e?void 0:e[0].target;"dark"===t.className?o(!0):"light"===t.className&&o(!1)}));return t.observe(e,{attributes:!0}),function(){t.disconnect()}}),[]),Object(B.jsx)(z.Provider,{value:{darkMode:a},children:t})},W=function(){var e=l.a.useContext(z);if(!e)throw new Error("useTheme must be used within a ThemeProvider");return e},L=n(92);!function(e){e.Korea="KMS",e.Japan="JMS",e.China="CMS",e.Taiwan="TMS",e.SEA="MSEA",e.Global="GMS",e.Thailand="ThMS",e.Brazil="BMS"}(c||(c={}));var R,G,I,P,V,U,H,q,J=function(e){if(!e.value)return{};var t=Object(L.b)(x,.5);return{backgroundColor:e.value.startsWith(c.Korea)?t:Object(L.a)(t)}},Y=n(13),K={currentSong:void 0,currentQueue:[],currentQueueSong:-1,repeatQueue:!1},$=Object(Y.atom)(void 0),X=Object(Y.atom)(void 0),Z=Object(Y.atom)(!1),ee=Object(Y.atom)(K),te=Object(Y.atom)(!1),ne=Object(Y.atom)([]),re=function(e){return e?e.startsWith("en")?"en":e.startsWith("ko")?"ko":e.startsWith("ja")?"ja":"zh-CN"===e?"zh-CN":e.startsWith("zh")?"zh-TW":"en":"en"},ae=function(e){var t=e.dataSource,n=Object(_.a)().i18n,r=Object(Y.useAtomValue)($),a=Object(i.useRef)(null),o=Object(i.useRef)(null),c=Object(i.useRef)([]),l=Object(i.useRef)(void 0),u=W(),s=Object(Y.useSetAtom)(ee),h=Object(Y.useAtomValue)(Z),m=Object(Y.useAtomValue)(X),g=Object(Y.useSetAtom)(te),j=Object(Y.useSetAtom)(ne);c.current=function(e){return[{headerName:"",field:"mark",minWidth:70,maxWidth:70,resizable:!1,cellRendererFramework:A,getQuickFilterText:function(){return""}},{headerName:"Title",field:"metadata.title",minWidth:250,valueGetter:function(e){var t,n,r,a,o=e.context.i18n,c=e.data,i=re(o.language);return"en"===i?c.metadata.title:null!==(t=null===(n=c.locale)||void 0===n||null===(r=n[i])||void 0===r||null===(a=r.metadata)||void 0===a?void 0:a.title)&&void 0!==t?t:c.metadata.title},cellRendererFramework:T,cellRendererParams:function(t){return{title:t.value,youtube:t.data.youtube,onGridSongChange:e}}},{headerName:"Description",minWidth:375,field:"description",valueGetter:function(e){var t,n,r,a=e.context.i18n,o=e.data,c=re(a.language);return"en"===c?o.description:null!==(t=null===(n=o.locale)||void 0===n||null===(r=n[c])||void 0===r?void 0:r.description)&&void 0!==t?t:o.description}},{headerName:"Folder",field:"source.structure",getQuickFilterText:function(){return""}},{headerName:"Date",field:"source.date",filter:"agDateColumnFilter",valueFormatter:function(e){return e.data.source.date?Object(w.a)(e.data.source.date,"yyyy-MM-dd"):""},cellRendererFramework:Q,getQuickFilterText:function(){return""}},{headerName:"Client",field:"source.clientVersion",getQuickFilterText:function(){return""},cellStyle:J}]}((function(e){s({currentSong:e,currentQueue:[],currentQueueSong:-1,repeatQueue:h})})),l.current={animateRows:!1,pagination:!0,paginationPageSize:25,suppressColumnVirtualisation:!0,suppressMovableColumns:!0,rowHeight:45,defaultColDef:{sortable:!0,filter:!0,resizable:!0},domLayout:"autoHeight"},Object(i.useEffect)((function(){var e;null===(e=a.current)||void 0===e||e.setQuickFilter(r)}),[r]),Object(i.useEffect)((function(){(null===m||void 0===m?void 0:m.songId)&&O(m.songId)}),[m]);var O=function(e){var t,n,r;if(e){var o=-1,c=[];if(null===(t=a.current)||void 0===t||t.forEachNodeAfterFilterAndSort((function(t,n){t.data.youtube===e&&(o=n,c.push(t))})),-1!==o&&1===c.length){var i=Math.ceil((o+1)/25)-1;null===(n=a.current)||void 0===n||n.paginationGoToPage(i),null===(r=a.current)||void 0===r||r.ensureIndexVisible(o,"middle"),c[0].setSelected(!0),setTimeout((function(){!function(e){var t;if(null!==e){var n=document.querySelector("div.ag-root-wrapper div[row-index='".concat(e,"']")),r=null===n||void 0===n?void 0:n.style.transform;if(r){var a=new RegExp(/^translateY\((\d+)px\)$/g).exec(r);if(a){var o=Object(b.a)(a,2)[1],c=null===(t=document.querySelector("div.ag-root-wrapper"))||void 0===t?void 0:t.offsetTop;if(void 0!==c){var i=c+Number(o);window.scrollTo({top:i,behavior:"smooth"})}}}}}(c[0].rowIndex)}),0)}}},p=Object(i.useCallback)((function(e,t){g(e),j(t)}),[g,j]),v=function(e,t){var n,r=null!==(n=null===e||void 0===e?void 0:e.isAnyFilterPresent())&&void 0!==n&&n,a=[];null===e||void 0===e||e.forEachNodeAfterFilterAndSort((function(e){a.push(e.data)})),t(r,a)};Object(i.useEffect)((function(){v(a.current,p)}),[t,p]);var C={i18n:n};return Object(y.b)("div",{css:Object(f.a)(R||(R=Object(d.a)(["\n margin: auto;\n width: 95vw;\n margin-bottom: 15px;\n "]))),className:u.darkMode?"ag-theme-balham-dark":"ag-theme-balham",children:Object(y.b)(S.AgGridReact,{columnDefs:c.current,rowData:t,gridOptions:l.current,onFirstDataRendered:function(e){e.columnApi.autoSizeAllColumns()},onFilterChanged:function(e){v(e.api,p)},onSortChanged:function(e){v(e.api,p)},onModelUpdated:function(e){e.api.getDisplayedRowCount()>0?e.api.hideOverlay():e.api.showNoRowsOverlay()},onGridReady:function(e){a.current=e.api,o.current=e.columnApi;e.columnApi.applyColumnState({state:[{colId:"source.date",sort:"desc"}]})},reactUi:!0,context:C})})},oe=n(164),ce=n.n(oe),ie=n(279),le=n(270),ue=n(165),se=(Object(Y.atom)([]),Object(Y.atom)(new Map)),de=Object(Y.atom)([]),be=Object(Y.atom)((function(e){var t=e(de);return t.length?t.length>1?"multi":t[0]:"undefined"})),fe=function(e){var t=Object(i.useRef)(null),n=e.playingState,r=e.setCurrentQueueSong,a=Object(Y.useAtomValue)(be);return Object(y.c)("div",{children:[Object(y.b)(ce.a,{css:Object(f.a)(G||(G=Object(d.a)(["\n display: block;\n margin-left: auto;\n margin-right: auto;\n max-width: 100vw;\n "]))),ref:t,url:"https://youtu.be/".concat(n.currentSong),playing:!0,controls:!0,onEnded:function(){if(null!==t.current)if(n.currentQueue.length){var e;if(gtag("event","ce_complete_queue_video",{ce_category:"video",ce_youtube:n.currentSong,ce_playlist_name:a}),n.currentQueueSong===n.currentQueue.length-1){if(!n.repeatQueue)return;e=0}else e=n.currentQueueSong+1;r(e)}else t.current.seekTo(0),gtag("event","ce_loop_embedded_video",{ce_category:"video",ce_youtube:n.currentSong})}}),n.currentQueue.length>0&&Object(y.b)("div",{className:"text-center",css:Object(f.a)(I||(I=Object(d.a)(["\n margin-top: 5px;\n "]))),children:Object(y.c)(le.a,{size:"sm",children:[Object(y.b)(ue.a,{variant:"outline-primary",onClick:function(){n.currentQueueSong<1||r(n.currentQueueSong-1)},disabled:0===n.currentQueueSong,children:Object(y.b)("i",{className:"fa fa-step-backward"})}),Object(y.b)("span",{css:Object(f.a)(P||(P=Object(d.a)(["\n background-color: #343a40;\n border-color: #343a40;\n color: white;\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n line-height: 1.5;\n border: 1px solid transparent;\n margin-left: -1px;\n "]))),children:"".concat(Object(ie.a)((n.currentQueueSong+1).toString(),n.currentQueue.length.toString().length,"0")," | ").concat(n.currentQueue.length)}),Object(y.b)(ue.a,{variant:"outline-primary",onClick:function(){n.currentQueueSong!==n.currentQueue.length-1&&r(n.currentQueueSong+1)},disabled:n.currentQueueSong+1===n.currentQueue.length,children:Object(y.b)("i",{className:"fa fa-step-forward"})})]})})]})},he=function(e){var t=e.noText;return Object(y.c)(i.Fragment,{children:[Object(y.b)("div",{children:Object(y.b)("img",{css:Object(f.a)(V||(V=Object(d.a)(["\n display: block;\n margin-left: auto;\n margin-right: auto;\n margin-bottom: 10px;\n "]))),id:"header-logo",src:"assets/pink-bean.png",alt:"header logo"})}),t?null:Object(y.b)("div",{children:Object(y.b)("p",{children:"Welcome to the MapleStory Music database. This site provides a complete listing of the background music (BGM) used in MapleStory. Collectively, the songs are also known as MapleStory's original soundtrack (OST)."})})]})},me=n(280),ge=n(271),je=n(59),Oe=function(e){var t=e.iconClass,n=e.actionName,r=e.onClick,a=e.active;return Object(y.b)(je.a.Item,{onClick:r,active:a,children:Object(y.c)("span",{children:[Object(y.b)("i",{className:t,css:Object(f.a)(U||(U=Object(d.a)(["\n width: 24px;\n "])))}),n]})})},pe=n(284),ve=function(){var e=Object(Y.useSetAtom)($),t=Object(Y.useSetAtom)(X),n=Object(Y.useAtom)(Z),r=Object(b.a)(n,2),a=r[0],o=r[1],c=Object(Y.useAtom)(ee),i=Object(b.a)(c,2),l=i[0],u=i[1],s=Object(Y.useAtomValue)(ne),h=Object(Y.useAtomValue)(te),m=Object(Y.useAtomValue)(be);return Object(y.b)(me.a.Group,{css:Object(f.a)(H||(H=Object(d.a)(["\n margin: 10px 14vw;\n "]))),className:"filter-text",children:Object(y.c)(ge.a,{size:"lg",children:[Object(y.b)(N.a,{delay:{show:250,hide:100},overlay:Object(y.b)(M.a,{id:"tooltip-locate-song",children:"Locate Current Song"}),children:Object(y.b)(ge.a.Text,{css:Object(f.a)(q||(q=Object(d.a)(["\n cursor: pointer;\n "]))),onClick:function(){t({songId:l.currentSong})},children:Object(y.b)("i",{className:"fa fa-search"})})}),Object(y.b)(me.a.Control,{type:"search",placeholder:"Song title or keyword",onChange:function(t){e(t.target.value)},onKeyPress:function(e){"Enter"===e.key&&document.activeElement&&document.activeElement.blur()}}),Object(y.c)(je.a,{children:[Object(y.b)(N.a,{delay:{show:250,hide:100},overlay:Object(y.b)(M.a,{id:"tooltip-queue-actions",children:h?"Queue Actions (Filtered)":"Queue Actions"}),children:Object(y.b)(je.a.Toggle,{variant:h?"outline-warning":"outline-success",id:"dropdown-queue-actions",children:Object(y.b)("i",{className:"fa fa-play"})})}),Object(y.c)(je.a.Menu,{children:[Object(y.b)(Oe,{actionName:"Start Queue",iconClass:"fa fa-play",onClick:function(){var e=s.filter((function(e){return""!==e.youtube}));e.length&&(u({currentSong:e[0].youtube,currentQueue:e,currentQueueSong:0,repeatQueue:a}),gtag("event","ce_start_queue",{ce_category:"queue",ce_source:"play_button",ce_filtered:h,ce_playlist_name:m}))}}),Object(y.b)(Oe,{actionName:"Start Shuffled Queue",iconClass:"fa fa-random",onClick:function(){var e=Object(pe.a)(s.filter((function(e){return""!==e.youtube})));e.length&&(u({currentSong:e[0].youtube,currentQueue:e,currentQueueSong:0,repeatQueue:a}),gtag("event","ce_start_shuffled_queue",{ce_category:"queue",ce_source:"shuffle_button",ce_filtered:h,ce_playlist_name:m}))}}),Object(y.b)(je.a.Divider,{}),Object(y.b)(Oe,{actionName:a?"Turn Off Queue Repeat":"Turn On Queue Repeat",iconClass:"fa fa-repeat",onClick:function(){var e=!a;o(e),u((function(t){return Object(k.a)(Object(k.a)({},t),{},{repeatQueue:e})}))},active:a})]})]})]})})},ye=n(46),Ce=n(272),ke="site-preferences",Se=l.a.createContext(void 0),we={hideMinorTracks:!1};function xe(e){localStorage.setItem(ke,JSON.stringify(e))}var Be,Ae,Ne,Me,Te,De,Fe,Qe,_e,ze,Ee,We,Le,Re,Ge,Ie=function(e){var t=e.children,n=l.a.useState(function(){var e=localStorage.getItem(ke);if(null===e){var t=we;return xe(t),t}return JSON.parse(e)}()),r=Object(b.a)(n,2),a=r[0],o=r[1];return Object(B.jsx)(Se.Provider,{value:{settings:a,setSettings:function(e){o(e),xe(e)}},children:t})},Pe=function(){var e=l.a.useContext(Se);if(!e)throw new Error("useSettings must be used within a SettingsProvider");return e},Ve=l.a.createContext(void 0),Ue=function(e){var t=e.children,n=l.a.useState([]),r=Object(b.a)(n,2),a=r[0],o=r[1],c=Object(Y.useSetAtom)(se),u=Pe().settings;return Object(i.useEffect)((function(){fetch("https://raw.githubusercontent.com/maplestory-music/maplebgm-db/prod/bgm.min.json").then((function(e){return e.json()})).then((function(e){var t=e.filter((function(e){var t,n;return!u.hideMinorTracks||(null===(t=!(null===(n=e.decoration)||void 0===n?void 0:n.minorTrack))||void 0===t||t)})).map((function(e){var t={client:e.source.client,date:e.source.date?Object(Ce.a)(e.source.date):null,structure:e.source.structure,version:e.source.version,clientVersion:e.source.client&&e.source.version?"".concat(e.source.client," ").concat(e.source.version):""};return Object.assign({},e,{source:t})}));o(t)})),fetch("https://raw.githubusercontent.com/maplestory-music/maplebgm-db/prod/playlist.min.json").then((function(e){return e.json()})).then((function(e){var t,n=new Map,r=Object(ye.a)(e);try{for(r.s();!(t=r.n()).done;){var a=t.value;n.set(a.name,a)}}catch(o){r.e(o)}finally{r.f()}c(n)}))}),[o,u.hideMinorTracks,c]),Object(B.jsx)(Ve.Provider,{value:a,children:t})},He=function(){var e=l.a.useContext(Ve);if(!e)throw new Error("useDataSourceState must be used within a DataSourceProvider");return e},qe=function(){var e=He(),t=Object(Y.useAtom)(ee),n=Object(b.a)(t,2),r=n[0],a=n[1];Object(i.useEffect)((function(){a(K)}),[a]);return Object(y.c)("div",{children:[void 0===r.currentSong?Object(y.b)(he,{}):Object(y.b)(fe,{playingState:r,setCurrentQueueSong:function(e){a((function(t){return Object(k.a)(Object(k.a)({},t),{},{currentSong:t.currentQueue[e].youtube,currentQueueSong:e})}))}}),Object(y.b)(ve,{}),Object(y.b)(ae,{dataSource:e})]})},Je=n(274),Ye=n(273),Ke=n(169),$e=n.n(Ke),Xe=n(170),Ze=n.n(Xe),et={colors:["#8087E8","#A3EDBA","#F19E53","#6699A1","#E1D369","#87B4E7","#DA6D85","#BBBAC5"],chart:{backgroundColor:{linearGradient:{x1:0,y1:0,x2:0,y2:1},stops:[[0,"#1f1836"],[1,"#45445d"]]},style:{fontFamily:"IBM Plex Sans, sans-serif"}},title:{style:{fontSize:"22px",fontWeight:"500",color:"#fff"}},subtitle:{style:{fontSize:"16px",fontWeight:"400",color:"#fff"}},credits:{style:{color:"#f0f0f0"}},caption:{style:{color:"#f0f0f0"}},tooltip:{borderWidth:0,backgroundColor:"#000000",style:{color:"#f0f0f0"},shadow:!0},legend:{backgroundColor:"transparent",itemStyle:{fontWeight:"400",fontSize:"12px",color:"#fff"},itemHoverStyle:{fontWeight:"700",color:"#fff"}},labels:{style:{color:"#707073"}},plotOptions:{series:{dataLabels:{color:"#46465C",style:{fontSize:"13px"}},marker:{lineColor:"#333"}},boxplot:{fillColor:"#505053"},candlestick:{lineColor:null,upColor:"#DA6D85",upLineColor:"#DA6D85"},errorbar:{color:"white"},dumbbell:{lowColor:"#f0f0f0"},map:{borderColor:"rgba(200, 200, 200, 1)",nullColor:"#78758C"}},drilldown:{activeAxisLabelStyle:{color:"#F0F0F3"},activeDataLabelStyle:{color:"#F0F0F3"},drillUpButton:{theme:{fill:"#fff"}}},xAxis:{gridLineColor:"#707073",labels:{style:{color:"#fff",fontSize:"12px"}},lineColor:"#707073",minorGridLineColor:"#505053",tickColor:"#707073",title:{style:{color:"#fff"}}},yAxis:{gridLineColor:"#707073",labels:{style:{color:"#fff",fontSize:"12px"}},lineColor:"#707073",minorGridLineColor:"#505053",tickColor:"#707073",tickWidth:1,title:{style:{color:"#fff",fontWeight:"300"}}},mapNavigation:{enabled:!0,buttonOptions:{theme:{fill:"#46465C","stroke-width":1,stroke:"#BBBAC5",r:2,style:{color:"#fff"},states:{hover:{fill:"#000","stroke-width":1,stroke:"#f0f0f0",style:{color:"#fff"}},select:{fill:"#000","stroke-width":1,stroke:"#f0f0f0",style:{color:"#fff"}}}},verticalAlign:"bottom"}},rangeSelector:{buttonTheme:{fill:"#46465C",stroke:"#BBBAC5","stroke-width":1,style:{color:"#fff"},states:{hover:{fill:"#1f1836",style:{color:"#fff"},"stroke-width":1,stroke:"white"},select:{fill:"#1f1836",style:{color:"#fff"},"stroke-width":1,stroke:"white"}}},inputBoxBorderColor:"#BBBAC5",inputStyle:{backgroundColor:"#2F2B38",color:"#fff"},labelStyle:{color:"#fff"}},navigator:{handles:{backgroundColor:"#BBBAC5",borderColor:"#2F2B38"},outlineColor:"#CCC",maskFill:"rgba(255,255,255,0.1)",series:{color:"#A3EDBA",lineColor:"#A3EDBA"},xAxis:{gridLineColor:"#505053"}},scrollbar:{barBackgroundColor:"#BBBAC5",barBorderColor:"#808083",buttonArrowColor:"#2F2B38",buttonBackgroundColor:"#BBBAC5",buttonBorderColor:"#2F2B38",rifleColor:"#2F2B38",trackBackgroundColor:"#78758C",trackBorderColor:"#2F2B38"}},tt={colors:["#8087E8","#A3EDBA","#F19E53","#6699A1","#E1D369","#87B4E7","#DA6D85","#BBBAC5"],chart:{backgroundColor:"#f0f0f0",style:{fontFamily:"IBM Plex Sans, sans-serif"}},title:{style:{fontSize:"22px",fontWeight:"500",color:"#2F2B38"}},subtitle:{style:{fontSize:"16px",fontWeight:"400",color:"#2F2B38"}},tooltip:{borderWidth:0,backgroundColor:"#46465C",style:{color:"#f0f0f0"},shadow:!0},legend:{backgroundColor:"#f0f0f0",borderColor:"#BBBAC5",borderWidth:1,borderRadius:2,itemStyle:{fontWeight:"400",fontSize:"12px",color:"#2F2B38"},itemHoverStyle:{fontWeight:"700",color:"#46465C"}},navigation:{buttonOptions:{symbolStroke:"#2F2B38",theme:{fill:"#fff",states:{hover:{stroke:"#46465C",fill:"#fff"},select:{stroke:"#46465C",fill:"#fff"}}}}},labels:{style:{color:"#46465C"}},credits:{style:{color:"#46465C"}},drilldown:{activeAxisLabelStyle:{color:"#2F2B38"},activeDataLabelStyle:{color:"#2F2B38"},drillUpButton:{theme:{fill:"#2F2B38",style:{color:"#fff"}}}},xAxis:{gridLineColor:"#ccc",labels:{style:{color:"#46465C",fontSize:"12px"}},lineColor:"#ccc",minorGridLineColor:"#ebebeb",tickColor:"#ccc",title:{style:{color:"#2F2B38"}}},yAxis:{gridLineColor:"#ccc",labels:{style:{color:"#46465C",fontSize:"12px"}},lineColor:"#ccc",minorGridLineColor:"#ebebeb",tickColor:"#ccc",tickWidth:1,title:{style:{color:"#2F2B38",fontWeight:"300"}}},rangeSelector:{buttonTheme:{fill:"#fff",style:{color:"#46465C",stroke:"transparent"},states:{hover:{fill:"#fff",style:{color:"#46465C"},"stroke-width":1,stroke:"#46465C"},select:{fill:"#fff",style:{color:"#46465C"},"stroke-width":1,stroke:"#46465C"}}},inputBoxBorderColor:"#BBBAC5",inputStyle:{backgroundColor:"#fff",color:"#46465C"},labelStyle:{color:"#46465C"}},scrollbar:{barBackgroundColor:"#BBBAC5",barBorderColor:"#808083",buttonArrowColor:"#fff",buttonBackgroundColor:"#BBBAC5",buttonBorderColor:"#46465C",rifleColor:"#FFF",trackBackgroundColor:"#dedede",trackBorderColor:"#BBBAC5"},plotOptions:{series:{borderWidth:1,borderColor:"#BBBAC5",dataLabels:{color:"#46465C",style:{fontSize:"13px"}},marker:{lineColor:"#46465C"}},boxplot:{fillColor:"#505053"},candlestick:{lineColor:null,upColor:"#DA6D85",upLineColor:"#DA6D85"},errorbar:{color:"white"},map:{borderColor:"rgba(200, 200, 200, 0.3)",nullColor:"rgba(200, 200, 200, 0.3)"}}},nt=function(e){var t=W();return Object(i.useEffect)((function(){var n,r,a=t.darkMode?et:tt,o=Object(k.a)(Object(k.a)({},e.options),a);null===(n=e.chartComponent.current)||void 0===n||null===(r=n.chart)||void 0===r||r.update(o)}),[e.chartComponent,e.options,t]),Object(y.b)("div",{css:[Object(f.a)(Be||(Be=Object(d.a)(["\n display: inline-block;\n margin: 10px;\n @media (max-width: 1024px) {\n width: 100%;\n }\n "]))),e.styles],children:Object(y.b)(Ze.a,{containerProps:{className:"react-highcharts-container",style:{width:"100%",height:"100%"}},highcharts:$e.a,options:e.options,ref:e.chartComponent})})},rt=function(e,t){var n=Date.now(),r=Object(Ye.a)(n)+1;return t===Object(Je.a)(n)?e.slice(0,1===r?r+1:r):e},at=function(e){var t=Object(i.useRef)(null),n=He(),r=e.selectedYear,a=n.reduce((function(e,t){return t.metadata.year===r.toString()&&t.source.date&&e[Object(Ye.a)(t.source.date)]++,e}),new Array(12).fill(0)),o=a.reduce((function(e,t,n){return 0===n?e[0]=t:e[n]=e[n-1]+t,e}),new Array(12).fill(0)),c={chart:{type:"line"},title:{text:"Song frequency per month"},xAxis:{type:"datetime"},yAxis:[{title:{text:"Songs"},allowDecimals:!1},{title:{text:"Cumulative"},allowDecimals:!1,opposite:!0}],series:[{name:"Songs",type:"line",yAxis:0,pointStart:Date.UTC(r,0,1),pointIntervalUnit:"month",data:rt(a,r)},{name:"Cumulative",type:"line",yAxis:1,pointStart:Date.UTC(r,0,1),pointIntervalUnit:"month",data:rt(o,r)}]};return Object(y.b)(nt,{styles:Object(f.a)(Ae||(Ae=Object(d.a)(["\n width: 55vw;\n flex: 2;\n "]))),options:c,chartComponent:t})},ot=function(e){var t=Object(i.useRef)(null),n=He(),r=e.selectedYear,a=n.filter((function(e){var t;return(null===(t=e.source.date)||void 0===t?void 0:t.getFullYear())===r&&e.source.client})),o=function(e){return a.filter((function(t){var n;return null===(n=t.source.client)||void 0===n?void 0:n.includes(e)})).length},l=o(c.Korea),u=a.length-l,s={chart:{type:"pie"},title:{text:"Distribution of song region"},series:[{id:"domesticVsOverseas",name:"Total Songs",type:"pie",data:[{name:"Domestic",color:x,y:l},{name:"Overseas",color:Object(L.a)(x),y:u}],size:"70%",dataLabels:{enabled:!1}},{id:"regional",name:"Songs",type:"pie",data:[{name:"Korea",color:x,y:l},{name:"Japan",y:o(c.Japan)},{name:"China",y:o(c.China)},{name:"Taiwan",y:o(c.Taiwan)},{name:"Thailand",y:o(c.Thailand)},{name:"SEA",y:o(c.SEA)},{name:"Global",y:o(c.Global)},{name:"Brazil",y:o(c.Brazil)}],size:"100%",innerSize:"70%",dataLabels:{formatter:function(e){if(this.y)return this.key}}}]};return Object(y.b)(nt,{styles:Object(f.a)(Ne||(Ne=Object(d.a)(["\n width: 35vw;\n flex: 1;\n "]))),options:s,chartComponent:t})},ct=n(16),it=n(277),lt=function(){var e=W(),t=He(),n=Object(i.useRef)(null),r=Object(i.useRef)(null),a=Object(i.useRef)([{headerName:"",field:"mark",minWidth:70,maxWidth:70,resizable:!1,cellRendererFramework:A},{headerName:"Folder",field:"folderName"},{headerName:"Creation",field:"creation",initialWidth:145,cellRendererFramework:Q,cellRendererParams:{disableRecentTrack:!0},filter:"agDateColumnFilter",valueFormatter:function(e){return Number.isNaN(e.data.creation.valueOf())?"":Object(w.a)(e.data.creation,"yyyy-MM-dd")}},{headerName:"Creation Client",field:"creationClient",initialWidth:125,cellStyle:J},{headerName:"Last Update",field:"lastUpdate",initialWidth:145,cellRendererFramework:Q,cellRendererParams:{disableRecentTrack:!0},filter:"agDateColumnFilter",valueFormatter:function(e){return Number.isNaN(e.data.lastUpdate.valueOf())?"":Object(w.a)(e.data.lastUpdate,"yyyy-MM-dd")}},{headerName:"Last Update Client",field:"lastUpdateClient",initialWidth:140,cellStyle:J},{headerName:"Track Count",field:"trackCount",initialWidth:110}]),o=Object(i.useRef)({animateRows:!1,pagination:!0,paginationPageSize:10,suppressColumnVirtualisation:!0,suppressMovableColumns:!0,rowHeight:45,defaultColDef:{sortable:!0,filter:!0,resizable:!0},domLayout:"autoHeight"}),c=Object(i.useMemo)((function(){var e,n=new Map,r=Object(ye.a)(t);try{for(r.s();!(e=r.n()).done;){var a=e.value,o=a.source.structure,c=n.get(o);c?n.set(o,[].concat(Object(ct.a)(c),[a])):n.set(o,[a])}}catch(i){r.e(i)}finally{r.f()}return Array.from(n.entries()).reduce((function(e,t){var n=Object(b.a)(t,2),r=n[0],a=n[1],o=a.map((function(e){var t,n;return{date:null!==(t=null===(n=e.source.date)||void 0===n?void 0:n.valueOf())&&void 0!==t?t:Number.NaN,clientVersion:e.source.clientVersion}})).sort((function(e,t){return e.date-t.date})),c=Object.entries(Object(it.a)(a.map((function(e){return e.mark})))).sort((function(e,t){return t[1]-e[1]})),i=o[0],l=o[o.length-1],u={folderName:r,trackCount:a.length,mark:c[0][0],creation:new Date(i.date),creationClient:i.clientVersion,lastUpdate:new Date(l.date),lastUpdateClient:l.clientVersion};return e.push(u),e}),[])}),[t]);return Object(B.jsx)("div",{className:e.darkMode?"ag-theme-balham-dark":"ag-theme-balham",children:Object(B.jsx)(S.AgGridReact,{columnDefs:a.current,rowData:c,gridOptions:o.current,onGridReady:function(e){n.current=e.api,r.current=e.columnApi;e.columnApi.applyColumnState({state:[{colId:"lastUpdate",sort:"desc"}]})},reactUi:!0})})},ut=function(){var e=Object(Je.a)(new Date),t=Object(i.useState)(e),n=Object(b.a)(t,2),r=n[0],a=n[1],o=Array(Object(Je.a)(new Date)-2003+1).fill(0).map((function(e,t){return 2003+t}));return Object(y.c)("div",{children:[Object(y.b)("h2",{children:"Stats"}),Object(y.b)(me.a,{children:Object(y.b)(me.a.Group,{controlId:"year-select",children:Object(y.b)(me.a.Select,{css:Object(f.a)(Me||(Me=Object(d.a)(["\n width: 100px;\n "]))),defaultValue:e,onChange:function(e){e.target.value&&a(+e.target.value)},children:o.map((function(e){return Object(y.b)("option",{value:e,children:e},e)}))})})}),Object(y.c)("div",{css:Object(f.a)(Te||(Te=Object(d.a)(["\n display: flex;\n align-items: center;\n flex-direction: row;\n flex-wrap: wrap;\n "]))),children:[Object(y.b)(at,{selectedYear:r}),Object(y.b)(ot,{selectedYear:r})]}),Object(y.b)("div",{children:Object(y.b)(lt,{})})]})},st=n(276),dt=n(283),bt=function(e){var t=e.show,n=e.onModalClose,r=Pe(),a=r.settings,o=r.setSettings,c=Object(i.useState)(a.hideMinorTracks),l=Object(b.a)(c,2),u=l[0],s=l[1];return Object(y.c)(dt.a,{show:t,onShow:function(){s(a.hideMinorTracks)},onHide:n,children:[Object(y.b)(dt.a.Header,{closeButton:!0,children:Object(y.b)(dt.a.Title,{children:"Settings"})}),Object(y.b)(dt.a.Body,{children:Object(y.b)(me.a,{children:Object(y.b)(y.a,{children:Object(y.c)("div",{css:Object(f.a)(De||(De=Object(d.a)(["\n display: flex;\n align-items: center;\n "]))),children:[Object(y.b)(me.a.Check,{type:"switch",id:"minorTrack-switch",label:"Hide Minor Tracks",checked:u,onChange:function(){s((function(e){return!e}))}}),Object(y.b)(N.a,{delay:{show:250,hide:100},placement:"right",overlay:Object(y.b)(M.a,{id:"tooltip-minorTrack",children:"Minor tracks feature segments of another song"}),children:Object(y.b)("i",{css:Object(f.a)(Fe||(Fe=Object(d.a)(["\n margin: 0 4px;\n "]))),className:"fa fa-question-circle","aria-hidden":!0})})]})})})}),Object(y.b)(dt.a.Footer,{children:Object(y.b)(ue.a,{variant:"primary",onClick:function(){o({hideMinorTracks:u}),n()},children:"Save"})})]})},ft=function(e){var t=e.theme,n=e.margin,r="light"===t?"fa fa-sun":"fa fa-moon";return Object(y.b)("i",{className:r,css:Object(f.a)(Qe||(Qe=Object(d.a)(["\n width: 16px;\n height: 16px;\n text-align: center;\n margin-right: ",";\n "])),n?"5px":void 0)})},ht=n(172),mt=function(){var e=W(),t=He(),n=Object(i.useState)(t),r=Object(b.a)(n,2),a=r[0],o=r[1],c=Object(Y.useAtomValue)(se),l=Object(Y.useAtom)(ee),u=Object(b.a)(l,2),s=u[0],h=u[1],m=Object(i.useRef)(null),g=Object(i.useState)([]),j=Object(b.a)(g,2),O=j[0],p=j[1],v=Object(i.useMemo)((function(){return Array.from(c.values()).map((function(e){return{value:e.name,label:e.name}}))}),[c]),C=Object(Y.useSetAtom)(de);Object(i.useEffect)((function(){h(K)}),[h]),Object(i.useEffect)((function(){if(t.length)if(O&&O.length){var e,n=new Set,r=Object(ye.a)(O);try{for(r.s();!(e=r.n()).done;){var a=e.value,i=c.get(a.value);if(!i)return;i.tracks.forEach((function(e){return n.add(e)}))}}catch(u){r.e(u)}finally{r.f()}var l=t.filter((function(e){var t="".concat(e.source.structure,"/").concat(e.filename);return n.has(t)}));o(l)}else o(t)}),[t,c,O]);return Object(y.c)("div",{children:[void 0===s.currentSong?Object(y.b)(he,{noText:!0}):Object(y.b)(fe,{playingState:s,setCurrentQueueSong:function(e){h((function(t){return Object(k.a)(Object(k.a)({},t),{},{currentSong:t.currentQueue[e].youtube,currentQueueSong:e})}))}}),Object(y.b)(ht.a,{css:Object(f.a)(_e||(_e=Object(d.a)(["\n margin: 10px 25vw;\n "]))),classNamePrefix:e.darkMode?"playlist-select-dark":"playlist-select",isMulti:!0,options:v,ref:m,value:O,onChange:function(e){p(e),C(e.map((function(e){return e.value})))},placeholder:"Select playlist"}),Object(y.b)(ve,{}),Object(y.b)(ae,{dataSource:a})]})},gt=Object(g.a)(),jt=function(e){e.currentTarget.pathname===window.location.pathname&&e.preventDefault()},Ot=function(){var e,t,n,r=Object(_.a)().i18n,a=W(),o=Object(i.useState)(!1),c=Object(b.a)(o,2),l=c[0],u=c[1];return Object(y.c)(y.a,{children:[Object(y.c)(j.a,{css:Object(f.a)(ze||(ze=Object(d.a)(["\n margin-bottom: 10px;\n "]))),bg:"dark",variant:"dark",expand:"lg",children:[Object(y.c)(j.a.Brand,{css:Object(f.a)(Ee||(Ee=Object(d.a)(["\n margin-left: 1rem;\n "]))),as:h.a,to:"/",onClick:jt,children:[Object(y.b)("img",{css:Object(f.a)(We||(We=Object(d.a)(["\n margin-right: 8px;\n "]))),alt:"",src:"./assets/pb-logo.svg",width:"30",height:"30",className:"d-inline-block align-top"})," ","MapleStory Music"]}),Object(y.b)(j.a.Toggle,{"aria-controls":"basic-navbar-nav"}),Object(y.b)(j.a.Collapse,{id:"basic-navbar-nav",children:Object(y.c)(O.a,{className:"mr-auto",children:[Object(y.b)(O.a.Link,{as:h.b,exact:!0,to:"/",onClick:jt,children:"Home"}),Object(y.b)(O.a.Link,{as:h.b,exact:!0,to:"/playlist",onClick:jt,children:"Playlist"}),Object(y.b)(O.a.Link,{as:h.b,exact:!0,to:"/stats",onClick:jt,children:"Stats"}),Object(y.b)(O.a.Link,{as:h.b,exact:!0,to:"/about",onClick:jt,children:"About"}),Object(y.c)(p.a,{title:a.darkMode?Object(y.b)(ft,{theme:"dark"}):Object(y.b)(ft,{theme:"light"}),children:[Object(y.c)(p.a.Item,{active:!a.darkMode,onClick:function(){a.darkMode&&(darkmode.setDarkMode(!1),gtag("event","ce_ui_light",{ce_category:"ui",ce_source:"navbar"}))},children:[Object(y.b)(ft,{theme:"light",margin:!0}),"Light"]}),Object(y.c)(p.a.Item,{active:a.darkMode,onClick:function(){a.darkMode||(darkmode.setDarkMode(!0),gtag("event","ce_ui_dark",{ce_category:"ui",ce_source:"navbar"}))},children:[Object(y.b)(ft,{theme:"dark",margin:!0}),"Dark"]})]}),Object(y.c)(p.a,{title:Object(y.b)("i",{className:"fa fa-earth-americas"}),children:[Object(y.b)(p.a.Item,{active:null===(e=r.language)||void 0===e?void 0:e.startsWith("en"),onClick:function(){return r.changeLanguage("en")},children:"English"}),Object(y.b)(p.a.Item,{active:null===(t=r.language)||void 0===t?void 0:t.startsWith("ko"),onClick:function(){return r.changeLanguage("ko")},children:"Korean"}),Object(y.b)(p.a.Item,{active:null===(n=r.language)||void 0===n?void 0:n.startsWith("ja"),onClick:function(){return r.changeLanguage("ja")},children:"Japanese"}),Object(y.b)(p.a.Item,{active:"zh-CN"===r.language,onClick:function(){return r.changeLanguage("zh-CN")},children:"Chinese (Simplified)"}),Object(y.b)(p.a.Item,{active:"zh-TW"===r.language,onClick:function(){return r.changeLanguage("zh-TW")},children:"Chinese (Traditional)"})]}),Object(y.b)(O.a.Link,{as:h.b,to:"#",onClick:function(){return u(!0)},children:Object(y.b)("i",{className:"fa fa-cog"})})]})})]}),Object(y.b)(bt,{show:l,onModalClose:function(){return u(!1)}})]})},pt=function(){var e,t,n=null!==(e="35d6d4b")?e:"Dev",r=null!==(t="2023-09-24")?t:Object(st.a)(new Date,{representation:"date"});return Object(y.b)("div",{css:Object(f.a)(Le||(Le=Object(d.a)(["\n text-align: center;\n margin-bottom: 10px;\n "]))),className:"footer",children:Object(y.b)("span",{children:"Build: ".concat(n," (").concat(r,")")})})},vt="MapleStory Music - BGM & OST Database",yt={"/":vt,"/playlist":"".concat(vt," - Playlist"),"/stats":"".concat(vt," - Stats"),"/about":"".concat(vt," - About")},Ct=function(){var e=Object(m.f)();return Object(i.useEffect)((function(){var t;document.title=null!==(t=yt[e.pathname])&&void 0!==t?t:vt}),[e]),Object(y.b)("main",{children:Object(y.c)(m.c,{children:[Object(y.b)(m.a,{exact:!0,path:"/",component:kt}),Object(y.b)(m.a,{path:"/playlist",component:St}),Object(y.b)(m.a,{path:"/stats",component:xt}),Object(y.b)(m.a,{path:"/about",component:wt})]})})},kt=function(){return Object(y.b)("div",{className:"App",children:Object(y.b)(qe,{})})},St=function(){return Object(y.b)("div",{className:"App",children:Object(y.b)(mt,{})})},wt=function(){return Object(y.b)("div",{css:Object(f.a)(Re||(Re=Object(d.a)(["\n margin: 2% 3% 3% 3%;\n "]))),className:"About",children:Object(y.b)(C,{})})},xt=function(){return Object(y.b)("div",{css:Object(f.a)(Ge||(Ge=Object(d.a)(["\n margin: 2% 3% 1% 3%;\n "]))),className:"Stats",children:Object(y.b)(ut,{})})},Bt=function(){return Object(y.b)(E,{children:Object(y.b)(Ie,{children:Object(y.b)(Ue,{children:Object(y.b)(m.b,{history:gt,children:Object(y.c)("div",{children:[Object(y.b)(Ot,{}),Object(y.b)(Ct,{}),Object(y.b)(pt,{})]})})})})})},At=n(173),Nt=n(95),Mt=n(174);At.a.use(Mt.a).use(Nt.e).init({fallbackLng:{zh:["zh-TW","zh-CN","en"],default:["en"]},nonExplicitSupportedLngs:!0,supportedLngs:["en","ko","ja","zh"]});Boolean("localhost"===window.location.hostname||"[::1]"===window.location.hostname||window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/));s.a.render(Object(B.jsx)(l.a.StrictMode,{children:Object(B.jsx)(i.Suspense,{fallback:Object(B.jsx)("div",{children:"Loading..."}),children:Object(B.jsx)(Bt,{})})}),document.getElementById("root")),"serviceWorker"in navigator&&navigator.serviceWorker.ready.then((function(e){e.unregister()})).catch((function(e){console.error(e.message)}))}},[[262,1,2]]]); \ No newline at end of file diff --git a/static/js/main.a92aa60b.chunk.js b/static/js/main.a92aa60b.chunk.js deleted file mode 100644 index 6b2f111..0000000 --- a/static/js/main.a92aa60b.chunk.js +++ /dev/null @@ -1 +0,0 @@ -(this["webpackJsonpmaplestory-music"]=this["webpackJsonpmaplestory-music"]||[]).push([[0],{180:function(e,t,n){},181:function(e,t,n){},262:function(e,t,n){"use strict";n.r(t);var r,a,o,c,i=n(0),l=n.n(i),u=n(25),s=n.n(u),d=(n(180),n(10)),b=n(6),f=n(11),h=(n(181),n(64)),m=n(19),g=n(34),j=n(281),O=n(285),p=n(275),v=n(139),y=n(3),C=function(){return Object(y.c)("div",{children:[Object(y.c)("div",{css:Object(f.a)(r||(r=Object(d.a)(["\n @media (min-width: 1024px) {\n margin-right: 33vw;\n }\n "]))),children:[Object(y.b)("h2",{children:"About"}),Object(y.b)("p",{children:"This database catalogs music from every region of MapleStory and aims to be the definitive resource for MapleStory music. It will be updated whenever new songs are added to the client of any region."}),Object(y.b)("h6",{children:Object(y.b)("b",{children:"Music Playback"})}),Object(y.b)("p",{children:"Music is played within an embedded YouTube player. The track is looped upon completion, unless in the shuffled queue mode (see below)."}),Object(y.b)("h6",{children:Object(y.b)("b",{children:"Shuffled Queue"})}),Object(y.b)("p",{children:"The shuffled queue feature randomizes the entire music collection and plays upcoming songs automatically. Skip to the next track or return to the previous track with the controls under the media player. When filters are applied to the grid, the song pool is limited to the filtered entries."}),Object(y.b)("h6",{children:Object(y.b)("b",{children:"Grid Controls"})}),Object(y.b)("p",{children:"To sort by a column, press the column header. Hover over a column header and press the menu icon to access the advanced filter dialog. Mobile users can access the filter dialog by pressing and holding the column header."}),Object(y.b)("h6",{children:Object(y.b)("b",{children:"Language"})}),Object(y.b)("p",{children:"Language support is a work in progress. Changing the language will translate metadata displayed for the songs in the grid. If there are no translations for an entry, English will be used as the default language."})]}),Object(y.b)("h2",{children:"Source"}),Object(y.b)("p",{children:"The following GitHub projects power this site."}),Object(y.c)("div",{className:"gh-project-entry",children:[Object(y.b)(v.a,{href:"https://github.com/maplestory-music/maplebgm-db","data-size":"large","data-show-count":!0,"aria-label":"Star maplestory-music/maplebgm-db on GitHub",children:"Star"}),Object(y.b)("h5",{className:"gh-project-name",children:"maplebgm-db: Definitive MapleStory music database"})]}),Object(y.c)("div",{className:"gh-project-entry",children:[Object(y.b)(v.a,{href:"https://github.com/maplestory-music/maplestory-music.github.io","data-size":"large","data-show-count":!0,"aria-label":"Star maplestory-music/maplestory-music.github.io on GitHub",children:"Star"}),Object(y.b)("h5",{className:"gh-project-name",children:"maplestory-music: MapleStory Music website"})]})]})},k=n(1),S=n(101),w=(n(209),n(210),n(211),n(278)),x="#6495ed",B=n(2),A=function(e){return Object(B.jsx)("span",{children:Object(B.jsx)("img",{src:"mark/".concat(e.value,".png"),alt:"icon"})})},N=n(282),M=n(268),T=function(e){var t=e.youtube,n=e.title;return""!==t?Object(y.c)("span",{children:[Object(y.b)(N.a,{delay:{show:250,hide:100},overlay:Object(y.b)(M.a,{id:"tooltip-ext-link",children:"View on YouTube"}),children:Object(y.b)("a",{css:Object(f.a)(a||(a=Object(d.a)(["\n margin-right: 3px;\n "]))),className:"bgm-external-link-icon",href:"https://youtu.be/".concat(t),rel:"noopener noreferrer",target:"_blank",onClick:function(){gtag("event","ce_view_external_video",{ce_category:"video",ce_youtube:e.youtube})},children:Object(y.b)("i",{className:"fa fa-external-link"})})}),Object(y.b)("a",{href:"# ",rel:"noopener noreferrer",onClick:function(t){gtag("event","ce_view_embedded_video",{ce_category:"video",ce_youtube:e.youtube}),e.onGridSongChange(e.youtube),t.preventDefault()},children:n})]}):Object(y.b)("span",{children:n})},D=n(286),F=n(269),Q=function(e){var t=e.value,n=new Date,r=Object(D.a)(n,t)<3||Object(F.a)(t);return Object(y.c)("div",{className:"date-col",children:[Object(y.b)("span",{css:Object(f.a)(o||(o=Object(d.a)(["\n margin-right: 3px;\n "]))),children:e.valueFormatted}),!e.disableRecentTrack&&r&&Object(y.b)(N.a,{delay:{show:250,hide:100},overlay:Object(y.b)(M.a,{id:"tooltip-recent-track",children:"Recent Track"}),children:Object(y.b)("i",{className:"fa fa-star","aria-hidden":!0})})]})},_=n(287),z=l.a.createContext(void 0),E=function(e){var t=e.children,n=l.a.useState(darkmode.inDarkMode),r=Object(b.a)(n,2),a=r[0],o=r[1];return Object(i.useEffect)((function(){var e=localStorage.getItem("bs.prefers-color-scheme");void 0!==e&&o("dark"===e)}),[]),Object(i.useEffect)((function(){var e=document.documentElement,t=new MutationObserver((function(e){var t=null===e||void 0===e?void 0:e[0].target;"dark"===t.className?o(!0):"light"===t.className&&o(!1)}));return t.observe(e,{attributes:!0}),function(){t.disconnect()}}),[]),Object(B.jsx)(z.Provider,{value:{darkMode:a},children:t})},W=function(){var e=l.a.useContext(z);if(!e)throw new Error("useTheme must be used within a ThemeProvider");return e},L=n(92);!function(e){e.Korea="KMS",e.Japan="JMS",e.China="CMS",e.Taiwan="TMS",e.SEA="MSEA",e.Global="GMS",e.Thailand="ThMS",e.Brazil="BMS"}(c||(c={}));var R,G,I,P,V,U,H,J,q=function(e){if(!e.value)return{};var t=Object(L.b)(x,.5);return{backgroundColor:e.value.startsWith(c.Korea)?t:Object(L.a)(t)}},Y=n(13),K={currentSong:void 0,currentQueue:[],currentQueueSong:-1,repeatQueue:!1},$=Object(Y.atom)(void 0),X=Object(Y.atom)(void 0),Z=Object(Y.atom)(!1),ee=Object(Y.atom)(K),te=Object(Y.atom)(!1),ne=Object(Y.atom)([]),re=function(e){return e?e.startsWith("en")?"en":e.startsWith("ko")?"ko":e.startsWith("ja")?"ja":"zh-CN"===e?"zh-CN":e.startsWith("zh")?"zh-TW":"en":"en"},ae=function(e){var t=e.dataSource,n=Object(_.a)().i18n,r=Object(Y.useAtomValue)($),a=Object(i.useRef)(null),o=Object(i.useRef)(null),c=Object(i.useRef)([]),l=Object(i.useRef)(void 0),u=W(),s=Object(Y.useSetAtom)(ee),h=Object(Y.useAtomValue)(Z),m=Object(Y.useAtomValue)(X),g=Object(Y.useSetAtom)(te),j=Object(Y.useSetAtom)(ne);c.current=function(e){return[{headerName:"",field:"mark",minWidth:70,maxWidth:70,resizable:!1,cellRendererFramework:A,getQuickFilterText:function(){return""}},{headerName:"Title",field:"metadata.title",minWidth:250,valueGetter:function(e){var t,n,r,a,o=e.context.i18n,c=e.data,i=re(o.language);return"en"===i?c.metadata.title:null!==(t=null===(n=c.locale)||void 0===n||null===(r=n[i])||void 0===r||null===(a=r.metadata)||void 0===a?void 0:a.title)&&void 0!==t?t:c.metadata.title},cellRendererFramework:T,cellRendererParams:function(t){return{title:t.value,youtube:t.data.youtube,onGridSongChange:e}}},{headerName:"Description",minWidth:375,field:"description",valueGetter:function(e){var t,n,r,a=e.context.i18n,o=e.data,c=re(a.language);return"en"===c?o.description:null!==(t=null===(n=o.locale)||void 0===n||null===(r=n[c])||void 0===r?void 0:r.description)&&void 0!==t?t:o.description}},{headerName:"Folder",field:"source.structure",getQuickFilterText:function(){return""}},{headerName:"Date",field:"source.date",filter:"agDateColumnFilter",valueFormatter:function(e){return e.data.source.date?Object(w.a)(e.data.source.date,"yyyy-MM-dd"):""},cellRendererFramework:Q,getQuickFilterText:function(){return""}},{headerName:"Client",field:"source.clientVersion",getQuickFilterText:function(){return""},cellStyle:q}]}((function(e){s({currentSong:e,currentQueue:[],currentQueueSong:-1,repeatQueue:h})})),l.current={animateRows:!1,pagination:!0,paginationPageSize:25,suppressColumnVirtualisation:!0,suppressMovableColumns:!0,rowHeight:45,defaultColDef:{sortable:!0,filter:!0,resizable:!0},domLayout:"autoHeight"},Object(i.useEffect)((function(){var e;null===(e=a.current)||void 0===e||e.setQuickFilter(r)}),[r]),Object(i.useEffect)((function(){(null===m||void 0===m?void 0:m.songId)&&O(m.songId)}),[m]);var O=function(e){var t,n,r;if(e){var o=-1,c=[];if(null===(t=a.current)||void 0===t||t.forEachNodeAfterFilterAndSort((function(t,n){t.data.youtube===e&&(o=n,c.push(t))})),-1!==o&&1===c.length){var i=Math.ceil((o+1)/25)-1;null===(n=a.current)||void 0===n||n.paginationGoToPage(i),null===(r=a.current)||void 0===r||r.ensureIndexVisible(o,"middle"),c[0].setSelected(!0),setTimeout((function(){!function(e){var t;if(null!==e){var n=document.querySelector("div.ag-root-wrapper div[row-index='".concat(e,"']")),r=null===n||void 0===n?void 0:n.style.transform;if(r){var a=new RegExp(/^translateY\((\d+)px\)$/g).exec(r);if(a){var o=Object(b.a)(a,2)[1],c=null===(t=document.querySelector("div.ag-root-wrapper"))||void 0===t?void 0:t.offsetTop;if(void 0!==c){var i=c+Number(o);window.scrollTo({top:i,behavior:"smooth"})}}}}}(c[0].rowIndex)}),0)}}},p=Object(i.useCallback)((function(e,t){g(e),j(t)}),[g,j]),v=function(e,t){var n,r=null!==(n=null===e||void 0===e?void 0:e.isAnyFilterPresent())&&void 0!==n&&n,a=[];null===e||void 0===e||e.forEachNodeAfterFilterAndSort((function(e){a.push(e.data)})),t(r,a)};Object(i.useEffect)((function(){v(a.current,p)}),[t,p]);var C={i18n:n};return Object(y.b)("div",{css:Object(f.a)(R||(R=Object(d.a)(["\n margin: auto;\n width: 95vw;\n margin-bottom: 15px;\n "]))),className:u.darkMode?"ag-theme-balham-dark":"ag-theme-balham",children:Object(y.b)(S.AgGridReact,{columnDefs:c.current,rowData:t,gridOptions:l.current,onFirstDataRendered:function(e){e.columnApi.autoSizeAllColumns()},onFilterChanged:function(e){v(e.api,p)},onSortChanged:function(e){v(e.api,p)},onModelUpdated:function(e){e.api.getDisplayedRowCount()>0?e.api.hideOverlay():e.api.showNoRowsOverlay()},onGridReady:function(e){a.current=e.api,o.current=e.columnApi;e.columnApi.applyColumnState({state:[{colId:"source.date",sort:"desc"}]})},reactUi:!0,context:C})})},oe=n(164),ce=n.n(oe),ie=n(279),le=n(270),ue=n(165),se=(Object(Y.atom)([]),Object(Y.atom)(new Map)),de=Object(Y.atom)([]),be=Object(Y.atom)((function(e){var t=e(de);return t.length?t.length>1?"multi":t[0]:"undefined"})),fe=function(e){var t=Object(i.useRef)(null),n=e.playingState,r=e.setCurrentQueueSong,a=Object(Y.useAtomValue)(be);return Object(y.c)("div",{children:[Object(y.b)(ce.a,{css:Object(f.a)(G||(G=Object(d.a)(["\n display: block;\n margin-left: auto;\n margin-right: auto;\n max-width: 100vw;\n "]))),ref:t,url:"https://youtu.be/".concat(n.currentSong),playing:!0,controls:!0,onEnded:function(){if(null!==t.current)if(n.currentQueue.length){var e;if(gtag("event","ce_complete_playlist_video",{ce_category:"video",ce_youtube:n.currentSong,ce_playlist_name:a}),n.currentQueueSong===n.currentQueue.length-1){if(!n.repeatQueue)return;e=0}else e=n.currentQueueSong+1;r(e)}else t.current.seekTo(0),gtag("event","ce_loop_embedded_video",{ce_category:"video",ce_youtube:n.currentSong})}}),n.currentQueue.length>0&&Object(y.b)("div",{className:"text-center",css:Object(f.a)(I||(I=Object(d.a)(["\n margin-top: 5px;\n "]))),children:Object(y.c)(le.a,{size:"sm",children:[Object(y.b)(ue.a,{variant:"outline-primary",onClick:function(){n.currentQueueSong<1||r(n.currentQueueSong-1)},disabled:0===n.currentQueueSong,children:Object(y.b)("i",{className:"fa fa-step-backward"})}),Object(y.b)("span",{css:Object(f.a)(P||(P=Object(d.a)(["\n background-color: #343a40;\n border-color: #343a40;\n color: white;\n padding: 0.25rem 0.5rem;\n font-size: 0.875rem;\n line-height: 1.5;\n border: 1px solid transparent;\n margin-left: -1px;\n "]))),children:"".concat(Object(ie.a)((n.currentQueueSong+1).toString(),n.currentQueue.length.toString().length,"0")," | ").concat(n.currentQueue.length)}),Object(y.b)(ue.a,{variant:"outline-primary",onClick:function(){n.currentQueueSong!==n.currentQueue.length-1&&r(n.currentQueueSong+1)},disabled:n.currentQueueSong+1===n.currentQueue.length,children:Object(y.b)("i",{className:"fa fa-step-forward"})})]})})]})},he=function(e){var t=e.noText;return Object(y.c)(i.Fragment,{children:[Object(y.b)("div",{children:Object(y.b)("img",{css:Object(f.a)(V||(V=Object(d.a)(["\n display: block;\n margin-left: auto;\n margin-right: auto;\n margin-bottom: 10px;\n "]))),id:"header-logo",src:"assets/pink-bean.png",alt:"header logo"})}),t?null:Object(y.b)("div",{children:Object(y.b)("p",{children:"Welcome to the MapleStory Music database. This site provides a complete listing of the background music (BGM) used in MapleStory. Collectively, the songs are also known as MapleStory's original soundtrack (OST)."})})]})},me=n(280),ge=n(271),je=n(59),Oe=function(e){var t=e.iconClass,n=e.actionName,r=e.onClick,a=e.active;return Object(y.b)(je.a.Item,{onClick:r,active:a,children:Object(y.c)("span",{children:[Object(y.b)("i",{className:t,css:Object(f.a)(U||(U=Object(d.a)(["\n width: 24px;\n "])))}),n]})})},pe=n(284),ve=function(){var e=Object(Y.useSetAtom)($),t=Object(Y.useSetAtom)(X),n=Object(Y.useAtom)(Z),r=Object(b.a)(n,2),a=r[0],o=r[1],c=Object(Y.useAtom)(ee),i=Object(b.a)(c,2),l=i[0],u=i[1],s=Object(Y.useAtomValue)(ne),h=Object(Y.useAtomValue)(te),m=Object(Y.useAtomValue)(be);return Object(y.b)(me.a.Group,{css:Object(f.a)(H||(H=Object(d.a)(["\n margin: 10px 14vw;\n "]))),className:"filter-text",children:Object(y.c)(ge.a,{size:"lg",children:[Object(y.b)(N.a,{delay:{show:250,hide:100},overlay:Object(y.b)(M.a,{id:"tooltip-locate-song",children:"Locate Current Song"}),children:Object(y.b)(ge.a.Text,{css:Object(f.a)(J||(J=Object(d.a)(["\n cursor: pointer;\n "]))),onClick:function(){t({songId:l.currentSong})},children:Object(y.b)("i",{className:"fa fa-search"})})}),Object(y.b)(me.a.Control,{type:"search",placeholder:"Song title or keyword",onChange:function(t){e(t.target.value)},onKeyPress:function(e){"Enter"===e.key&&document.activeElement&&document.activeElement.blur()}}),Object(y.c)(je.a,{children:[Object(y.b)(N.a,{delay:{show:250,hide:100},overlay:Object(y.b)(M.a,{id:"tooltip-queue-actions",children:h?"Queue Actions (Filtered)":"Queue Actions"}),children:Object(y.b)(je.a.Toggle,{variant:h?"outline-warning":"outline-success",id:"dropdown-queue-actions",children:Object(y.b)("i",{className:"fa fa-play"})})}),Object(y.c)(je.a.Menu,{children:[Object(y.b)(Oe,{actionName:"Start Queue",iconClass:"fa fa-play",onClick:function(){var e=s.filter((function(e){return""!==e.youtube}));e.length&&(u({currentSong:e[0].youtube,currentQueue:e,currentQueueSong:0,repeatQueue:a}),gtag("event","ce_start_playlist",{ce_category:"playlist",ce_source:"play_button",ce_filtered:h,ce_playlist_name:m}))}}),Object(y.b)(Oe,{actionName:"Start Shuffled Queue",iconClass:"fa fa-random",onClick:function(){var e=Object(pe.a)(s.filter((function(e){return""!==e.youtube})));e.length&&(u({currentSong:e[0].youtube,currentQueue:e,currentQueueSong:0,repeatQueue:a}),gtag("event","ce_start_shuffled_playlist",{ce_category:"playlist",ce_source:"shuffle_button",ce_filtered:h,ce_playlist_name:m}))}}),Object(y.b)(je.a.Divider,{}),Object(y.b)(Oe,{actionName:a?"Turn Off Queue Repeat":"Turn On Queue Repeat",iconClass:"fa fa-repeat",onClick:function(){var e=!a;o(e),u((function(t){return Object(k.a)(Object(k.a)({},t),{},{repeatQueue:e})}))},active:a})]})]})]})})},ye=n(46),Ce=n(272),ke="site-preferences",Se=l.a.createContext(void 0),we={hideMinorTracks:!1};function xe(e){localStorage.setItem(ke,JSON.stringify(e))}var Be,Ae,Ne,Me,Te,De,Fe,Qe,_e,ze,Ee,We,Le,Re,Ge,Ie=function(e){var t=e.children,n=l.a.useState(function(){var e=localStorage.getItem(ke);if(null===e){var t=we;return xe(t),t}return JSON.parse(e)}()),r=Object(b.a)(n,2),a=r[0],o=r[1];return Object(B.jsx)(Se.Provider,{value:{settings:a,setSettings:function(e){o(e),xe(e)}},children:t})},Pe=function(){var e=l.a.useContext(Se);if(!e)throw new Error("useSettings must be used within a SettingsProvider");return e},Ve=l.a.createContext(void 0),Ue=function(e){var t=e.children,n=l.a.useState([]),r=Object(b.a)(n,2),a=r[0],o=r[1],c=Object(Y.useSetAtom)(se),u=Pe().settings;return Object(i.useEffect)((function(){fetch("https://raw.githubusercontent.com/maplestory-music/maplebgm-db/prod/bgm.min.json").then((function(e){return e.json()})).then((function(e){var t=e.filter((function(e){var t,n;return!u.hideMinorTracks||(null===(t=!(null===(n=e.decoration)||void 0===n?void 0:n.minorTrack))||void 0===t||t)})).map((function(e){var t={client:e.source.client,date:e.source.date?Object(Ce.a)(e.source.date):null,structure:e.source.structure,version:e.source.version,clientVersion:e.source.client&&e.source.version?"".concat(e.source.client," ").concat(e.source.version):""};return Object.assign({},e,{source:t})}));o(t)})),fetch("https://raw.githubusercontent.com/maplestory-music/maplebgm-db/prod/playlist.min.json").then((function(e){return e.json()})).then((function(e){var t,n=new Map,r=Object(ye.a)(e);try{for(r.s();!(t=r.n()).done;){var a=t.value;n.set(a.name,a)}}catch(o){r.e(o)}finally{r.f()}c(n)}))}),[o,u.hideMinorTracks,c]),Object(B.jsx)(Ve.Provider,{value:a,children:t})},He=function(){var e=l.a.useContext(Ve);if(!e)throw new Error("useDataSourceState must be used within a DataSourceProvider");return e},Je=function(){var e=He(),t=Object(Y.useAtom)(ee),n=Object(b.a)(t,2),r=n[0],a=n[1];Object(i.useEffect)((function(){a(K)}),[a]);return Object(y.c)("div",{children:[void 0===r.currentSong?Object(y.b)(he,{}):Object(y.b)(fe,{playingState:r,setCurrentQueueSong:function(e){a((function(t){return Object(k.a)(Object(k.a)({},t),{},{currentSong:t.currentQueue[e].youtube,currentQueueSong:e})}))}}),Object(y.b)(ve,{}),Object(y.b)(ae,{dataSource:e})]})},qe=n(274),Ye=n(273),Ke=n(169),$e=n.n(Ke),Xe=n(170),Ze=n.n(Xe),et={colors:["#8087E8","#A3EDBA","#F19E53","#6699A1","#E1D369","#87B4E7","#DA6D85","#BBBAC5"],chart:{backgroundColor:{linearGradient:{x1:0,y1:0,x2:0,y2:1},stops:[[0,"#1f1836"],[1,"#45445d"]]},style:{fontFamily:"IBM Plex Sans, sans-serif"}},title:{style:{fontSize:"22px",fontWeight:"500",color:"#fff"}},subtitle:{style:{fontSize:"16px",fontWeight:"400",color:"#fff"}},credits:{style:{color:"#f0f0f0"}},caption:{style:{color:"#f0f0f0"}},tooltip:{borderWidth:0,backgroundColor:"#000000",style:{color:"#f0f0f0"},shadow:!0},legend:{backgroundColor:"transparent",itemStyle:{fontWeight:"400",fontSize:"12px",color:"#fff"},itemHoverStyle:{fontWeight:"700",color:"#fff"}},labels:{style:{color:"#707073"}},plotOptions:{series:{dataLabels:{color:"#46465C",style:{fontSize:"13px"}},marker:{lineColor:"#333"}},boxplot:{fillColor:"#505053"},candlestick:{lineColor:null,upColor:"#DA6D85",upLineColor:"#DA6D85"},errorbar:{color:"white"},dumbbell:{lowColor:"#f0f0f0"},map:{borderColor:"rgba(200, 200, 200, 1)",nullColor:"#78758C"}},drilldown:{activeAxisLabelStyle:{color:"#F0F0F3"},activeDataLabelStyle:{color:"#F0F0F3"},drillUpButton:{theme:{fill:"#fff"}}},xAxis:{gridLineColor:"#707073",labels:{style:{color:"#fff",fontSize:"12px"}},lineColor:"#707073",minorGridLineColor:"#505053",tickColor:"#707073",title:{style:{color:"#fff"}}},yAxis:{gridLineColor:"#707073",labels:{style:{color:"#fff",fontSize:"12px"}},lineColor:"#707073",minorGridLineColor:"#505053",tickColor:"#707073",tickWidth:1,title:{style:{color:"#fff",fontWeight:"300"}}},mapNavigation:{enabled:!0,buttonOptions:{theme:{fill:"#46465C","stroke-width":1,stroke:"#BBBAC5",r:2,style:{color:"#fff"},states:{hover:{fill:"#000","stroke-width":1,stroke:"#f0f0f0",style:{color:"#fff"}},select:{fill:"#000","stroke-width":1,stroke:"#f0f0f0",style:{color:"#fff"}}}},verticalAlign:"bottom"}},rangeSelector:{buttonTheme:{fill:"#46465C",stroke:"#BBBAC5","stroke-width":1,style:{color:"#fff"},states:{hover:{fill:"#1f1836",style:{color:"#fff"},"stroke-width":1,stroke:"white"},select:{fill:"#1f1836",style:{color:"#fff"},"stroke-width":1,stroke:"white"}}},inputBoxBorderColor:"#BBBAC5",inputStyle:{backgroundColor:"#2F2B38",color:"#fff"},labelStyle:{color:"#fff"}},navigator:{handles:{backgroundColor:"#BBBAC5",borderColor:"#2F2B38"},outlineColor:"#CCC",maskFill:"rgba(255,255,255,0.1)",series:{color:"#A3EDBA",lineColor:"#A3EDBA"},xAxis:{gridLineColor:"#505053"}},scrollbar:{barBackgroundColor:"#BBBAC5",barBorderColor:"#808083",buttonArrowColor:"#2F2B38",buttonBackgroundColor:"#BBBAC5",buttonBorderColor:"#2F2B38",rifleColor:"#2F2B38",trackBackgroundColor:"#78758C",trackBorderColor:"#2F2B38"}},tt={colors:["#8087E8","#A3EDBA","#F19E53","#6699A1","#E1D369","#87B4E7","#DA6D85","#BBBAC5"],chart:{backgroundColor:"#f0f0f0",style:{fontFamily:"IBM Plex Sans, sans-serif"}},title:{style:{fontSize:"22px",fontWeight:"500",color:"#2F2B38"}},subtitle:{style:{fontSize:"16px",fontWeight:"400",color:"#2F2B38"}},tooltip:{borderWidth:0,backgroundColor:"#46465C",style:{color:"#f0f0f0"},shadow:!0},legend:{backgroundColor:"#f0f0f0",borderColor:"#BBBAC5",borderWidth:1,borderRadius:2,itemStyle:{fontWeight:"400",fontSize:"12px",color:"#2F2B38"},itemHoverStyle:{fontWeight:"700",color:"#46465C"}},navigation:{buttonOptions:{symbolStroke:"#2F2B38",theme:{fill:"#fff",states:{hover:{stroke:"#46465C",fill:"#fff"},select:{stroke:"#46465C",fill:"#fff"}}}}},labels:{style:{color:"#46465C"}},credits:{style:{color:"#46465C"}},drilldown:{activeAxisLabelStyle:{color:"#2F2B38"},activeDataLabelStyle:{color:"#2F2B38"},drillUpButton:{theme:{fill:"#2F2B38",style:{color:"#fff"}}}},xAxis:{gridLineColor:"#ccc",labels:{style:{color:"#46465C",fontSize:"12px"}},lineColor:"#ccc",minorGridLineColor:"#ebebeb",tickColor:"#ccc",title:{style:{color:"#2F2B38"}}},yAxis:{gridLineColor:"#ccc",labels:{style:{color:"#46465C",fontSize:"12px"}},lineColor:"#ccc",minorGridLineColor:"#ebebeb",tickColor:"#ccc",tickWidth:1,title:{style:{color:"#2F2B38",fontWeight:"300"}}},rangeSelector:{buttonTheme:{fill:"#fff",style:{color:"#46465C",stroke:"transparent"},states:{hover:{fill:"#fff",style:{color:"#46465C"},"stroke-width":1,stroke:"#46465C"},select:{fill:"#fff",style:{color:"#46465C"},"stroke-width":1,stroke:"#46465C"}}},inputBoxBorderColor:"#BBBAC5",inputStyle:{backgroundColor:"#fff",color:"#46465C"},labelStyle:{color:"#46465C"}},scrollbar:{barBackgroundColor:"#BBBAC5",barBorderColor:"#808083",buttonArrowColor:"#fff",buttonBackgroundColor:"#BBBAC5",buttonBorderColor:"#46465C",rifleColor:"#FFF",trackBackgroundColor:"#dedede",trackBorderColor:"#BBBAC5"},plotOptions:{series:{borderWidth:1,borderColor:"#BBBAC5",dataLabels:{color:"#46465C",style:{fontSize:"13px"}},marker:{lineColor:"#46465C"}},boxplot:{fillColor:"#505053"},candlestick:{lineColor:null,upColor:"#DA6D85",upLineColor:"#DA6D85"},errorbar:{color:"white"},map:{borderColor:"rgba(200, 200, 200, 0.3)",nullColor:"rgba(200, 200, 200, 0.3)"}}},nt=function(e){var t=W();return Object(i.useEffect)((function(){var n,r,a=t.darkMode?et:tt,o=Object(k.a)(Object(k.a)({},e.options),a);null===(n=e.chartComponent.current)||void 0===n||null===(r=n.chart)||void 0===r||r.update(o)}),[e.chartComponent,e.options,t]),Object(y.b)("div",{css:[Object(f.a)(Be||(Be=Object(d.a)(["\n display: inline-block;\n margin: 10px;\n @media (max-width: 1024px) {\n width: 100%;\n }\n "]))),e.styles],children:Object(y.b)(Ze.a,{containerProps:{className:"react-highcharts-container",style:{width:"100%",height:"100%"}},highcharts:$e.a,options:e.options,ref:e.chartComponent})})},rt=function(e,t){var n=Date.now(),r=Object(Ye.a)(n)+1;return t===Object(qe.a)(n)?e.slice(0,1===r?r+1:r):e},at=function(e){var t=Object(i.useRef)(null),n=He(),r=e.selectedYear,a=n.reduce((function(e,t){return t.metadata.year===r.toString()&&t.source.date&&e[Object(Ye.a)(t.source.date)]++,e}),new Array(12).fill(0)),o=a.reduce((function(e,t,n){return 0===n?e[0]=t:e[n]=e[n-1]+t,e}),new Array(12).fill(0)),c={chart:{type:"line"},title:{text:"Song frequency per month"},xAxis:{type:"datetime"},yAxis:[{title:{text:"Songs"},allowDecimals:!1},{title:{text:"Cumulative"},allowDecimals:!1,opposite:!0}],series:[{name:"Songs",type:"line",yAxis:0,pointStart:Date.UTC(r,0,1),pointIntervalUnit:"month",data:rt(a,r)},{name:"Cumulative",type:"line",yAxis:1,pointStart:Date.UTC(r,0,1),pointIntervalUnit:"month",data:rt(o,r)}]};return Object(y.b)(nt,{styles:Object(f.a)(Ae||(Ae=Object(d.a)(["\n width: 55vw;\n flex: 2;\n "]))),options:c,chartComponent:t})},ot=function(e){var t=Object(i.useRef)(null),n=He(),r=e.selectedYear,a=n.filter((function(e){var t;return(null===(t=e.source.date)||void 0===t?void 0:t.getFullYear())===r&&e.source.client})),o=function(e){return a.filter((function(t){var n;return null===(n=t.source.client)||void 0===n?void 0:n.includes(e)})).length},l=o(c.Korea),u=a.length-l,s={chart:{type:"pie"},title:{text:"Distribution of song region"},series:[{id:"domesticVsOverseas",name:"Total Songs",type:"pie",data:[{name:"Domestic",color:x,y:l},{name:"Overseas",color:Object(L.a)(x),y:u}],size:"70%",dataLabels:{enabled:!1}},{id:"regional",name:"Songs",type:"pie",data:[{name:"Korea",color:x,y:l},{name:"Japan",y:o(c.Japan)},{name:"China",y:o(c.China)},{name:"Taiwan",y:o(c.Taiwan)},{name:"Thailand",y:o(c.Thailand)},{name:"SEA",y:o(c.SEA)},{name:"Global",y:o(c.Global)},{name:"Brazil",y:o(c.Brazil)}],size:"100%",innerSize:"70%",dataLabels:{formatter:function(e){if(this.y)return this.key}}}]};return Object(y.b)(nt,{styles:Object(f.a)(Ne||(Ne=Object(d.a)(["\n width: 35vw;\n flex: 1;\n "]))),options:s,chartComponent:t})},ct=n(16),it=n(277),lt=function(){var e=W(),t=He(),n=Object(i.useRef)(null),r=Object(i.useRef)(null),a=Object(i.useRef)([{headerName:"",field:"mark",minWidth:70,maxWidth:70,resizable:!1,cellRendererFramework:A},{headerName:"Folder",field:"folderName"},{headerName:"Creation",field:"creation",initialWidth:145,cellRendererFramework:Q,cellRendererParams:{disableRecentTrack:!0},filter:"agDateColumnFilter",valueFormatter:function(e){return Number.isNaN(e.data.creation.valueOf())?"":Object(w.a)(e.data.creation,"yyyy-MM-dd")}},{headerName:"Creation Client",field:"creationClient",initialWidth:125,cellStyle:q},{headerName:"Last Update",field:"lastUpdate",initialWidth:145,cellRendererFramework:Q,cellRendererParams:{disableRecentTrack:!0},filter:"agDateColumnFilter",valueFormatter:function(e){return Number.isNaN(e.data.lastUpdate.valueOf())?"":Object(w.a)(e.data.lastUpdate,"yyyy-MM-dd")}},{headerName:"Last Update Client",field:"lastUpdateClient",initialWidth:140,cellStyle:q},{headerName:"Track Count",field:"trackCount",initialWidth:110}]),o=Object(i.useRef)({animateRows:!1,pagination:!0,paginationPageSize:10,suppressColumnVirtualisation:!0,suppressMovableColumns:!0,rowHeight:45,defaultColDef:{sortable:!0,filter:!0,resizable:!0},domLayout:"autoHeight"}),c=Object(i.useMemo)((function(){var e,n=new Map,r=Object(ye.a)(t);try{for(r.s();!(e=r.n()).done;){var a=e.value,o=a.source.structure,c=n.get(o);c?n.set(o,[].concat(Object(ct.a)(c),[a])):n.set(o,[a])}}catch(i){r.e(i)}finally{r.f()}return Array.from(n.entries()).reduce((function(e,t){var n=Object(b.a)(t,2),r=n[0],a=n[1],o=a.map((function(e){var t,n;return{date:null!==(t=null===(n=e.source.date)||void 0===n?void 0:n.valueOf())&&void 0!==t?t:Number.NaN,clientVersion:e.source.clientVersion}})).sort((function(e,t){return e.date-t.date})),c=Object.entries(Object(it.a)(a.map((function(e){return e.mark})))).sort((function(e,t){return t[1]-e[1]})),i=o[0],l=o[o.length-1],u={folderName:r,trackCount:a.length,mark:c[0][0],creation:new Date(i.date),creationClient:i.clientVersion,lastUpdate:new Date(l.date),lastUpdateClient:l.clientVersion};return e.push(u),e}),[])}),[t]);return Object(B.jsx)("div",{className:e.darkMode?"ag-theme-balham-dark":"ag-theme-balham",children:Object(B.jsx)(S.AgGridReact,{columnDefs:a.current,rowData:c,gridOptions:o.current,onGridReady:function(e){n.current=e.api,r.current=e.columnApi;e.columnApi.applyColumnState({state:[{colId:"lastUpdate",sort:"desc"}]})},reactUi:!0})})},ut=function(){var e=Object(qe.a)(new Date),t=Object(i.useState)(e),n=Object(b.a)(t,2),r=n[0],a=n[1],o=Array(Object(qe.a)(new Date)-2003+1).fill(0).map((function(e,t){return 2003+t}));return Object(y.c)("div",{children:[Object(y.b)("h2",{children:"Stats"}),Object(y.b)(me.a,{children:Object(y.b)(me.a.Group,{controlId:"year-select",children:Object(y.b)(me.a.Select,{css:Object(f.a)(Me||(Me=Object(d.a)(["\n width: 100px;\n "]))),defaultValue:e,onChange:function(e){e.target.value&&a(+e.target.value)},children:o.map((function(e){return Object(y.b)("option",{value:e,children:e},e)}))})})}),Object(y.c)("div",{css:Object(f.a)(Te||(Te=Object(d.a)(["\n display: flex;\n align-items: center;\n flex-direction: row;\n flex-wrap: wrap;\n "]))),children:[Object(y.b)(at,{selectedYear:r}),Object(y.b)(ot,{selectedYear:r})]}),Object(y.b)("div",{children:Object(y.b)(lt,{})})]})},st=n(276),dt=n(283),bt=function(e){var t=e.show,n=e.onModalClose,r=Pe(),a=r.settings,o=r.setSettings,c=Object(i.useState)(a.hideMinorTracks),l=Object(b.a)(c,2),u=l[0],s=l[1];return Object(y.c)(dt.a,{show:t,onShow:function(){s(a.hideMinorTracks)},onHide:n,children:[Object(y.b)(dt.a.Header,{closeButton:!0,children:Object(y.b)(dt.a.Title,{children:"Settings"})}),Object(y.b)(dt.a.Body,{children:Object(y.b)(me.a,{children:Object(y.b)(y.a,{children:Object(y.c)("div",{css:Object(f.a)(De||(De=Object(d.a)(["\n display: flex;\n align-items: center;\n "]))),children:[Object(y.b)(me.a.Check,{type:"switch",id:"minorTrack-switch",label:"Hide Minor Tracks",checked:u,onChange:function(){s((function(e){return!e}))}}),Object(y.b)(N.a,{delay:{show:250,hide:100},placement:"right",overlay:Object(y.b)(M.a,{id:"tooltip-minorTrack",children:"Minor tracks feature segments of another song"}),children:Object(y.b)("i",{css:Object(f.a)(Fe||(Fe=Object(d.a)(["\n margin: 0 4px;\n "]))),className:"fa fa-question-circle","aria-hidden":!0})})]})})})}),Object(y.b)(dt.a.Footer,{children:Object(y.b)(ue.a,{variant:"primary",onClick:function(){o({hideMinorTracks:u}),n()},children:"Save"})})]})},ft=function(e){var t=e.theme,n=e.margin,r="light"===t?"fa fa-sun":"fa fa-moon";return Object(y.b)("i",{className:r,css:Object(f.a)(Qe||(Qe=Object(d.a)(["\n width: 16px;\n height: 16px;\n text-align: center;\n margin-right: ",";\n "])),n?"5px":void 0)})},ht=n(172),mt=function(){var e=W(),t=He(),n=Object(i.useState)(t),r=Object(b.a)(n,2),a=r[0],o=r[1],c=Object(Y.useAtomValue)(se),l=Object(Y.useAtom)(ee),u=Object(b.a)(l,2),s=u[0],h=u[1],m=Object(i.useRef)(null),g=Object(i.useState)([]),j=Object(b.a)(g,2),O=j[0],p=j[1],v=Object(i.useMemo)((function(){return Array.from(c.values()).map((function(e){return{value:e.name,label:e.name}}))}),[c]),C=Object(Y.useSetAtom)(de);Object(i.useEffect)((function(){h(K)}),[h]),Object(i.useEffect)((function(){if(t.length)if(O&&O.length){var e,n=new Set,r=Object(ye.a)(O);try{for(r.s();!(e=r.n()).done;){var a=e.value,i=c.get(a.value);if(!i)return;i.tracks.forEach((function(e){return n.add(e)}))}}catch(u){r.e(u)}finally{r.f()}var l=t.filter((function(e){var t="".concat(e.source.structure,"/").concat(e.filename);return n.has(t)}));o(l)}else o(t)}),[t,c,O]);return Object(y.c)("div",{children:[void 0===s.currentSong?Object(y.b)(he,{noText:!0}):Object(y.b)(fe,{playingState:s,setCurrentQueueSong:function(e){h((function(t){return Object(k.a)(Object(k.a)({},t),{},{currentSong:t.currentQueue[e].youtube,currentQueueSong:e})}))}}),Object(y.b)(ht.a,{css:Object(f.a)(_e||(_e=Object(d.a)(["\n margin: 10px 25vw;\n "]))),classNamePrefix:e.darkMode?"playlist-select-dark":"playlist-select",isMulti:!0,options:v,ref:m,value:O,onChange:function(e){p(e),C(e.map((function(e){return e.value})))},placeholder:"Select playlist"}),Object(y.b)(ve,{}),Object(y.b)(ae,{dataSource:a})]})},gt=Object(g.a)(),jt=function(e){e.currentTarget.pathname===window.location.pathname&&e.preventDefault()},Ot=function(){var e,t,n,r=Object(_.a)().i18n,a=W(),o=Object(i.useState)(!1),c=Object(b.a)(o,2),l=c[0],u=c[1];return Object(y.c)(y.a,{children:[Object(y.c)(j.a,{css:Object(f.a)(ze||(ze=Object(d.a)(["\n margin-bottom: 10px;\n "]))),bg:"dark",variant:"dark",expand:"lg",children:[Object(y.c)(j.a.Brand,{css:Object(f.a)(Ee||(Ee=Object(d.a)(["\n margin-left: 1rem;\n "]))),as:h.a,to:"/",onClick:jt,children:[Object(y.b)("img",{css:Object(f.a)(We||(We=Object(d.a)(["\n margin-right: 8px;\n "]))),alt:"",src:"./assets/pb-logo.svg",width:"30",height:"30",className:"d-inline-block align-top"})," ","MapleStory Music"]}),Object(y.b)(j.a.Toggle,{"aria-controls":"basic-navbar-nav"}),Object(y.b)(j.a.Collapse,{id:"basic-navbar-nav",children:Object(y.c)(O.a,{className:"mr-auto",children:[Object(y.b)(O.a.Link,{as:h.b,exact:!0,to:"/",onClick:jt,children:"Home"}),Object(y.b)(O.a.Link,{as:h.b,exact:!0,to:"/playlist",onClick:jt,children:"Playlist"}),Object(y.b)(O.a.Link,{as:h.b,exact:!0,to:"/stats",onClick:jt,children:"Stats"}),Object(y.b)(O.a.Link,{as:h.b,exact:!0,to:"/about",onClick:jt,children:"About"}),Object(y.c)(p.a,{title:a.darkMode?Object(y.b)(ft,{theme:"dark"}):Object(y.b)(ft,{theme:"light"}),children:[Object(y.c)(p.a.Item,{active:!a.darkMode,onClick:function(){a.darkMode&&(darkmode.setDarkMode(!1),gtag("event","ce_ui_light",{ce_category:"ui",ce_source:"navbar"}))},children:[Object(y.b)(ft,{theme:"light",margin:!0}),"Light"]}),Object(y.c)(p.a.Item,{active:a.darkMode,onClick:function(){a.darkMode||(darkmode.setDarkMode(!0),gtag("event","ce_ui_dark",{ce_category:"ui",ce_source:"navbar"}))},children:[Object(y.b)(ft,{theme:"dark",margin:!0}),"Dark"]})]}),Object(y.c)(p.a,{title:Object(y.b)("i",{className:"fa fa-earth-americas"}),children:[Object(y.b)(p.a.Item,{active:null===(e=r.language)||void 0===e?void 0:e.startsWith("en"),onClick:function(){return r.changeLanguage("en")},children:"English"}),Object(y.b)(p.a.Item,{active:null===(t=r.language)||void 0===t?void 0:t.startsWith("ko"),onClick:function(){return r.changeLanguage("ko")},children:"Korean"}),Object(y.b)(p.a.Item,{active:null===(n=r.language)||void 0===n?void 0:n.startsWith("ja"),onClick:function(){return r.changeLanguage("ja")},children:"Japanese"}),Object(y.b)(p.a.Item,{active:"zh-CN"===r.language,onClick:function(){return r.changeLanguage("zh-CN")},children:"Chinese (Simplified)"}),Object(y.b)(p.a.Item,{active:"zh-TW"===r.language,onClick:function(){return r.changeLanguage("zh-TW")},children:"Chinese (Traditional)"})]}),Object(y.b)(O.a.Link,{as:h.b,to:"#",onClick:function(){return u(!0)},children:Object(y.b)("i",{className:"fa fa-cog"})})]})})]}),Object(y.b)(bt,{show:l,onModalClose:function(){return u(!1)}})]})},pt=function(){var e,t,n=null!==(e="6a7a108")?e:"Dev",r=null!==(t="2023-09-24")?t:Object(st.a)(new Date,{representation:"date"});return Object(y.b)("div",{css:Object(f.a)(Le||(Le=Object(d.a)(["\n text-align: center;\n margin-bottom: 10px;\n "]))),className:"footer",children:Object(y.b)("span",{children:"Build: ".concat(n," (").concat(r,")")})})},vt="MapleStory Music - BGM & OST Database",yt={"/":vt,"/playlist":"".concat(vt," - Playlist"),"/stats":"".concat(vt," - Stats"),"/about":"".concat(vt," - About")},Ct=function(){var e=Object(m.f)();return Object(i.useEffect)((function(){var t;document.title=null!==(t=yt[e.pathname])&&void 0!==t?t:vt}),[e]),Object(y.b)("main",{children:Object(y.c)(m.c,{children:[Object(y.b)(m.a,{exact:!0,path:"/",component:kt}),Object(y.b)(m.a,{path:"/playlist",component:St}),Object(y.b)(m.a,{path:"/stats",component:xt}),Object(y.b)(m.a,{path:"/about",component:wt})]})})},kt=function(){return Object(y.b)("div",{className:"App",children:Object(y.b)(Je,{})})},St=function(){return Object(y.b)("div",{className:"App",children:Object(y.b)(mt,{})})},wt=function(){return Object(y.b)("div",{css:Object(f.a)(Re||(Re=Object(d.a)(["\n margin: 2% 3% 3% 3%;\n "]))),className:"About",children:Object(y.b)(C,{})})},xt=function(){return Object(y.b)("div",{css:Object(f.a)(Ge||(Ge=Object(d.a)(["\n margin: 2% 3% 1% 3%;\n "]))),className:"Stats",children:Object(y.b)(ut,{})})},Bt=function(){return Object(y.b)(E,{children:Object(y.b)(Ie,{children:Object(y.b)(Ue,{children:Object(y.b)(m.b,{history:gt,children:Object(y.c)("div",{children:[Object(y.b)(Ot,{}),Object(y.b)(Ct,{}),Object(y.b)(pt,{})]})})})})})},At=n(173),Nt=n(95),Mt=n(174);At.a.use(Mt.a).use(Nt.e).init({fallbackLng:{zh:["zh-TW","zh-CN","en"],default:["en"]},nonExplicitSupportedLngs:!0,supportedLngs:["en","ko","ja","zh"]});Boolean("localhost"===window.location.hostname||"[::1]"===window.location.hostname||window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/));s.a.render(Object(B.jsx)(l.a.StrictMode,{children:Object(B.jsx)(i.Suspense,{fallback:Object(B.jsx)("div",{children:"Loading..."}),children:Object(B.jsx)(Bt,{})})}),document.getElementById("root")),"serviceWorker"in navigator&&navigator.serviceWorker.ready.then((function(e){e.unregister()})).catch((function(e){console.error(e.message)}))}},[[262,1,2]]]); \ No newline at end of file