From 3de66682d4709187ed574d9620ff231ca4a06c89 Mon Sep 17 00:00:00 2001 From: Patrick Joyce Date: Fri, 20 Dec 2024 22:29:28 -0500 Subject: [PATCH] mv servers to own file --- src/lib/YapTally.svelte | 28 ++-------------------------- src/lib/data/servers.json | 26 ++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 26 deletions(-) create mode 100644 src/lib/data/servers.json diff --git a/src/lib/YapTally.svelte b/src/lib/YapTally.svelte index 4932c96..564b0a4 100644 --- a/src/lib/YapTally.svelte +++ b/src/lib/YapTally.svelte @@ -2,6 +2,7 @@ import { onMount } from 'svelte'; import { writable } from 'svelte/store'; import fetchJsonp from 'fetch-jsonp'; + import Servers from './data/servers.json'; interface YapServer { name: string; @@ -18,32 +19,7 @@ data: ServerData[]; } - const yapServers: YapServer[] = [ - { name: 'Al-Sask Region', url: 'https://bmltyap.org/AlSask/upgrade-advisor.php', jsonp: true }, - { name: 'Arizona Region', url: 'https://arizona-na.org/yap/live/upgrade-advisor.php' }, - { name: 'Australia Region', url: 'https://na.org.au/yap/upgrade-advisor.php' }, - { name: 'Bayou Recovery Area', url: 'https://bmltyap.org/brana/upgrade-advisor.php', jsonp: true }, - { name: 'Canadian Assembly', url: 'https://canaacna.org/yap/upgrade-advisor.php', jsonp: true }, - { name: 'Central Atlantic Region', url: 'https://yap.centralatlanticregionofna.org/upgrade-advisor.php', jsonp: true }, - { name: 'Connecticut Region', url: 'https://yap.ctna.org/upgrade-advisor.php' }, - { name: 'Esperanza Area', url: 'https://bmltyap.org/esperanza-yap/upgrade-advisor.php', jsonp: true }, - { name: 'FreeState Region Area', url: 'https://freestatena.org/yap-4.2.8/upgrade-advisor.php' }, - { name: 'Hill Country Area', url: 'https://hillcountryna.org/yap/upgrade-advisor.php' }, - { name: 'Kentucky', url: 'https://bmlt.bmltky.online/yap/upgrade-advisor.php' }, - { name: 'Louisiana Region', url: 'https://dontuse.org/upgrade-advisor.php' }, - { name: 'Mississippi Region', url: 'https://mrscna.net/yap/upgrade-advisor.php', jsonp: true }, - { name: 'Mountaineer Region', url: 'https://yap.yapmrscna.org/upgrade-advisor.php' }, - { name: 'New England Region', url: 'https://phoneline.nerna.org/yap/upgrade-advisor.php' }, - { name: 'Northern New York Region', url: 'https://yap.nny-na.org/upgrade-advisor.php', jsonp: true }, - { name: 'Plains States Zonal Forum', url: 'https://pszfna.org/yap/upgrade-advisor.php' }, - { name: 'Region 51', url: 'https://phoneline.region51na.org/upgrade-advisor.php', jsonp: true }, - { name: 'San Francisco Area', url: 'https://phoneline.sfna.org/upgrade-advisor.php', jsonp: true }, - { name: 'Show Me Region', url: 'https://missourina.org/yap/upgrade-advisor.php' }, - { name: 'Southeast Texas Area', url: 'https://bmltyap.org/southeastTX-Yap/upgrade-advisor.php', jsonp: true }, - { name: 'Southeastern Zonal Forum', url: 'https://bmlt.sezf.org/zonal-yap/upgrade-advisor.php?override_service_body_config_id=43' }, - { name: 'Volunteer Region', url: 'https://natennessee.org/yap/upgrade-advisor.php' }, - { name: 'Western States Zonal Forum', url: 'https://bmlt.wszf.org/yap/upgrade-advisor.php' } - ]; + const yapServers: YapServer[] = Servers; const yapServerData = writable([]); let sortDirection = writable(1); diff --git a/src/lib/data/servers.json b/src/lib/data/servers.json new file mode 100644 index 0000000..4a543db --- /dev/null +++ b/src/lib/data/servers.json @@ -0,0 +1,26 @@ +[ + { "name": "Al-Sask Region", "url": "https://bmltyap.org/AlSask/upgrade-advisor.php", "jsonp": true }, + { "name": "Arizona Region", "url": "https://arizona-na.org/yap/live/upgrade-advisor.php" }, + { "name": "Australia Region", "url": "https://na.org.au/yap/upgrade-advisor.php" }, + { "name": "Bayou Recovery Area", "url": "https://bmltyap.org/brana/upgrade-advisor.php", "jsonp": true }, + { "name": "Canadian Assembly", "url": "https://canaacna.org/yap/upgrade-advisor.php", "jsonp": true }, + { "name": "Central Atlantic Region", "url": "https://yap.centralatlanticregionofna.org/upgrade-advisor.php", "jsonp": true }, + { "name": "Connecticut Region", "url": "https://yap.ctna.org/upgrade-advisor.php" }, + { "name": "Esperanza Area", "url": "https://bmltyap.org/esperanza-yap/upgrade-advisor.php", "jsonp": true }, + { "name": "FreeState Region Area", "url": "https://freestatena.org/yap-4.2.8/upgrade-advisor.php" }, + { "name": "Hill Country Area", "url": "https://hillcountryna.org/yap/upgrade-advisor.php" }, + { "name": "Kentucky", "url": "https://bmlt.bmltky.online/yap/upgrade-advisor.php" }, + { "name": "Louisiana Region", "url": "https://dontuse.org/upgrade-advisor.php" }, + { "name": "Mississippi Region", "url": "https://mrscna.net/yap/upgrade-advisor.php", "jsonp": true }, + { "name": "Mountaineer Region", "url": "https://yap.yapmrscna.org/upgrade-advisor.php" }, + { "name": "New England Region", "url": "https://phoneline.nerna.org/yap/upgrade-advisor.php" }, + { "name": "Northern New York Region", "url": "https://yap.nny-na.org/upgrade-advisor.php", "jsonp": true }, + { "name": "Plains States Zonal Forum", "url": "https://pszfna.org/yap/upgrade-advisor.php" }, + { "name": "Region 51", "url": "https://phoneline.region51na.org/upgrade-advisor.php", "jsonp": true }, + { "name": "San Francisco Area", "url": "https://phoneline.sfna.org/upgrade-advisor.php", "jsonp": true }, + { "name": "Show Me Region", "url": "https://missourina.org/yap/upgrade-advisor.php" }, + { "name": "Southeast Texas Area", "url": "https://bmltyap.org/southeastTX-Yap/upgrade-advisor.php", "jsonp": true }, + { "name": "Southeastern Zonal Forum", "url": "https://bmlt.sezf.org/zonal-yap/upgrade-advisor.php?override_service_body_config_id=43" }, + { "name": "Volunteer Region", "url": "https://natennessee.org/yap/upgrade-advisor.php" }, + { "name": "Western States Zonal Forum", "url": "https://bmlt.wszf.org/yap/upgrade-advisor.php" } +]