{"version":3,"sources":["assets/images/logo/logo-wayun.png","assets/images/logo/logo-wayun-plus.png","assets/images/logo/logo-wayun-privacy-plus.png","redux/navbar.js","redux/rootReducer.js","redux/store.js","configs/acl/ability.js","configs/acl/initialAbility.js","utility/context/ThemeColors.js","@core/components/spinner/Fallback-spinner.js","@core/components/ripple-button/index.js","serviceWorker.js","graphql/index.js","index.js","configs/themeConfig.js","assets/images/logo/lofty-logo.svg","redux/layout.js","@core/auth/jwt/jwtDefaultConfig.js","@core/auth/jwt/jwtService.js","auth/jwt/useJwt.js","redux/authenticate.js","@core/auth/jwt/useJwt.js","utility/context/Can.js"],"names":["getBookmarks","createAsyncThunk","axios","get","response","data","suggestions","bookmarks","updateBookmarked","id","post","layoutSlice","createSlice","name","initialState","query","reducers","handleSearchQuery","state","action","payload","extraReducers","builder","addCase","fulfilled","find","item","isBookmarked","objectToUpdate","bookmarkIndex","findIndex","x","push","splice","actions","rootReducer","navbar","layout","auth","store","configureStore","reducer","middleware","getDefaultMiddleware","serializableCheck","userData","JSON","parse","localStorage","getItem","fullName","username","avatar","email","ability","subject","existingAbility","Ability","ThemeColors","createContext","ThemeContext","children","useState","colors","setColors","useEffect","window","getHex","color","getComputedStyle","document","body","getPropertyValue","trim","obj","primary","light","concat","main","secondary","success","danger","warning","info","dark","Provider","value","SpinnerComponent","className","src","logo","alt","style","aspectRatio","width","Button","Ripple","onClick","rest","mounted","setMounted","isRippling","setIsRippling","y","coords","setCoords","setTimeout","classnames","e","rect","target","getBoundingClientRect","clientX","left","clientY","top","Boolean","location","hostname","match","wsLink","GraphQLWsLink","createClient","url","process","connectionParams","token","accessToken","authorization","httpLink","createHttpLink","uri","authLink","setContext","_","headers","Authorization","Platform","splitLink","split","definition","getMainDefinition","kind","operation","client","ApolloClient","link","cache","InMemoryCache","LazyApp","lazy","container","getElementById","createRoot","render","ApolloProvider","fallback","position","themeConfig","toastPosition","toastOptions","navigator","serviceWorker","ready","then","registration","unregister","app","appName","appLogoImage","require","default","appLogoImageText","appLogoPremiumImageText","appLogoPremiumPrivacyImageText","isRTL","skin","type","contentWidth","menu","isHidden","isCollapsed","backgroundColor","footer","customizer","scrollTop","initialSkin","initialDirection","lastLayout","menuCollapsed","initialMenuCollapsed","footerType","navbarType","menuHidden","navbarColor","handleRTL","setItem","stringify","handleSkin","handleLayout","handleFooterType","handleNavbarType","handleMenuHidden","handleLastLayout","handleNavbarColor","handleContentWidth","handleMenuCollapsed","loginEndpoint","registerEndpoint","refreshEndpoint","logoutEndpoint","tokenType","storageTokenKeyName","storageRefreshTokenKeyName","JwtService","jwtOverrideConfig","jwtConfig","jwtDefaultConfig","isAlreadyFetchingAccessToken","subscribers","this","interceptors","request","use","config","getToken","error","Promise","reject","originalRequest","status","refreshToken","r","setToken","setRefreshToken","onAccessTokenFetched","resolve","addSubscriber","filter","callback","args","getRefreshToken","jwt","authSlice","initialUser","handleLogin","handleUpdateUser","handleLogout","removeItem","AbilityContext","createContextualCan","Consumer"],"mappings":"2HAAA,OAAe,cAA0B,wC,iCCAzC,OAAe,cAA0B,6C,iCCAzC,OAAe,cAA0B,qD,kOCM5BA,EAAeC,YAAiB,sBAAD,gCAAwB,8GAC3CC,IAAMC,IAAI,uBADiC,cAC5DC,EAD4D,yBAE3D,CACLC,KAAMD,EAASC,KAAKC,YACpBC,UAAWH,EAASC,KAAKE,YAJuC,4CAQvDC,EAAmBP,YAAiB,0BAAD,iDAA4B,WAAOQ,GAAP,2FACpEP,IAAMQ,KAAK,wBAAyB,CAAED,OAD8B,gCAEnEA,GAFmE,2CAA5B,uDAKnCE,EAAcC,YAAY,CACrCC,KAAM,SACNC,aAAc,CACZC,MAAO,GACPR,UAAW,GACXD,YAAa,IAEfU,SAAU,CACRC,kBAAmB,SAACC,EAAOC,GACzBD,EAAMH,MAAQI,EAAOC,UAGzBC,cAAe,SAACC,GACdA,EACGC,QAAQvB,EAAawB,WAAW,SAACN,EAAOC,GACvCD,EAAMZ,YAAca,EAAOC,QAAQf,KACnCa,EAAM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UlL,EAAOC,QAAQ2G,cAC/E/E,aAAaoJ,QAAQ4B,EAAOX,2BAA4BvK,KAAKuJ,UAAUlL,EAAOC,QAAQmN,gBAExFe,iBAAkB,SAACpO,EAAOC,GACxBD,EAAM2B,SAAN,2BAAsB3B,EAAM2B,UAAa1B,EAAOC,SAChD4B,aAAaoJ,QAAQ,WAAYtJ,KAAKuJ,UAAL,2BAAoBnL,EAAM2B,UAAa1B,EAAOC,YAEjFmO,aAAc,SAACrO,GACbA,EAAM2B,SAAW,GACjB3B,EAAM8M,EAAOZ,qBAAuB,KACpClM,EAAM8M,EAAOX,4BAA8B,KAE3CrK,aAAawM,WAAW,YACxBxM,aAAawM,WAAWxB,EAAOZ,qBAC/BpK,aAAawM,WAAWxB,EAAOX,gCAK9B,EAAwD8B,EAAUjN,QAA1DmN,EAAR,EAAQA,YAAaE,EAArB,EAAqBA,aAAcD,EAAnC,EAAmCA,iBAE3BH,MAAf,S,gCE9CA,qDAOaM,EAAiB9L,0BAGX+L,YAAoBD,EAAeE,Y","file":"static/js/main.0962756a.chunk.js","sourcesContent":["export default __webpack_public_path__ + \"static/media/logo-wayun.667ac9fc.png\";","export default __webpack_public_path__ + \"static/media/logo-wayun-plus.9efbc45a.png\";","export default __webpack_public_path__ + \"static/media/logo-wayun-privacy-plus.35ba1af1.png\";","// ** Redux Imports\nimport { createSlice, createAsyncThunk } from '@reduxjs/toolkit'\n\n// ** Axios Imports\nimport axios from 'axios'\n\nexport const getBookmarks = createAsyncThunk('layout/getBookmarks', async () => {\n const response = await axios.get('/api/bookmarks/data')\n return {\n data: response.data.suggestions,\n bookmarks: response.data.bookmarks,\n }\n})\n\nexport const updateBookmarked = createAsyncThunk('layout/updateBookmarked', async (id) => {\n await axios.post('/api/bookmarks/update', { id })\n return id\n})\n\nexport const layoutSlice = createSlice({\n name: 'layout',\n initialState: {\n query: '',\n bookmarks: [],\n suggestions: [],\n },\n reducers: {\n handleSearchQuery: (state, action) => {\n state.query = action.payload\n },\n },\n extraReducers: (builder) => {\n builder\n .addCase(getBookmarks.fulfilled, (state, action) => {\n state.suggestions = action.payload.data\n state.bookmarks = action.payload.bookmarks\n })\n .addCase(updateBookmarked.fulfilled, (state, action) => {\n // let objectToUpdate\n\n // ** find & update object\n state.suggestions.find((item) => {\n if (item.id === action.payload) {\n item.isBookmarked = !item.isBookmarked\n objectToUpdate = item\n }\n })\n\n // ** Get index to add or remove bookmark from array\n const bookmarkIndex = state.bookmarks.findIndex((x) => x.id === action.payload)\n\n if (bookmarkIndex === -1) {\n state.bookmarks.push(objectToUpdate)\n } else {\n state.bookmarks.splice(bookmarkIndex, 1)\n }\n })\n },\n})\n\nexport const { handleSearchQuery } = layoutSlice.actions\n\nexport default layoutSlice.reducer\n","// ** Reducers Imports\nimport layout from './layout';\nimport navbar from './navbar';\nimport auth from './authenticate';\n\nconst rootReducer = { navbar, layout, auth };\n\nexport default rootReducer;\n","// ** Redux Imports\nimport rootReducer from \"./rootReducer\"\nimport { configureStore } from \"@reduxjs/toolkit\"\n\nconst store = configureStore({\n reducer: rootReducer,\n middleware: (getDefaultMiddleware) => {\n return getDefaultMiddleware({\n serializableCheck: false\n })\n }\n})\n\nexport { store }\n","import { Ability } from '@casl/ability';\nimport { initialAbility } from './initialAbility';\n\n// Read ability from localStorage\n// * Handles auto fetching previous abilities if already logged in user\n// ? You can update this if you store user abilities to more secure place\n// ! Anyone can update localStorage so be careful and please update this\nconst testUser = {\n id: 1,\n fullName: 'John Doe',\n username: 'johndoe',\n avatar: '/img/13-small.d796bffd.png',\n email: 'admin@demo.com',\n ability: [\n {\n action: 'manage',\n subject: 'all',\n },\n ],\n // more...\n};\nconst userData = JSON.parse(localStorage.getItem('userData')) || testUser;\nconst existingAbility = userData ? userData.ability : null;\n\nexport default new Ability(existingAbility || initialAbility);\n","// ** Initial user ability\nexport const initialAbility = [\n {\n action: 'read',\n subject: 'Auth'\n }\n]\n\nexport const _ = undefined\n","// ** React Imports\nimport { useEffect, useState, createContext } from \"react\"\n\n// ** Create Context\nconst ThemeColors = createContext()\n\nconst ThemeContext = ({ children }) => {\n // ** State\n const [colors, setColors] = useState({})\n\n //** ComponentDidMount\n useEffect(() => {\n if (window !== \"undefined\") {\n //** Get variable value\n const getHex = (color) => window.getComputedStyle(document.body).getPropertyValue(color).trim()\n\n //** Colors obj\n const obj = {\n primary: {\n light: getHex(\"--bs-primary\").concat(\"1a\"),\n main: getHex(\"--bs-primary\")\n },\n secondary: {\n light: getHex(\"--bs-secondary\").concat(\"1a\"),\n main: getHex(\"--bs-secondary\")\n },\n success: {\n light: getHex(\"--bs-success\").concat(\"1a\"),\n main: getHex(\"--bs-success\")\n },\n danger: {\n light: getHex(\"--bs-danger\").concat(\"1a\"),\n main: getHex(\"--bs-danger\")\n },\n warning: {\n light: getHex(\"--bs-warning\").concat(\"1a\"),\n main: getHex(\"--bs-warning\")\n },\n info: {\n light: getHex(\"--bs-info\").concat(\"1a\"),\n main: getHex(\"--bs-info\")\n },\n dark: {\n light: getHex(\"--bs-dark\").concat(\"1a\"),\n main: getHex(\"--bs-dark\")\n }\n }\n\n setColors({ ...obj })\n }\n }, [])\n\n return (\n