- Improved settings page ("*unsaved" title when not saved yet, redesigned toggle indicators, redesigned toggle buttons, and small changes)
- data-URL property of the body HTML tag is now the pathname rather than the full URL
- Work in progress places integration for Pinned Games (on the actual places page, debating deleting this or not)
- Code cleanup
- Code improvements
- Added .gitignore
- Updated specific.css to use pathnames rather than the full URL
- Updated data_structure.txt reference for developers
- Changed manifest version name to pre-release build so you can tell what build you are using
25 lines
No EOL
720 B
JavaScript
25 lines
No EOL
720 B
JavaScript
let Settings;
|
|
let PinnedGamesData;
|
|
|
|
chrome.storage.sync.get(['PolyPlus_Settings', 'PolyPlus_PinnedGames'], function(result){
|
|
Settings = result.PolyPlus_Settings || {}
|
|
PinnedGamesData = result.PolyPlus_PinnedGames || []
|
|
|
|
if (Settings.PinnedGamesOn === true) {}
|
|
})
|
|
|
|
function PinnedGames() {
|
|
for (let game of PinnedGamesData) {
|
|
fetch('https://api.polytoria.com/v1/places/' + game)
|
|
.then(response => {
|
|
if (!response.ok) {
|
|
throw new Error('Network not ok')
|
|
}
|
|
return response.json()
|
|
})
|
|
.then(data => {
|
|
// epic
|
|
})
|
|
.catch(error => {console.log(error)})
|
|
}
|
|
} |