From 27cfb94de8d9ccef3c7fc76b250aee17d7c80257 Mon Sep 17 00:00:00 2001 From: Dylan Fontaine <10430358+dylanfontaine@users.noreply.github.com> Date: Thu, 10 Dec 2020 22:02:32 -0800 Subject: [PATCH] feat(store): add EBGames (#1281) --- docs/reference/filter.md | 1 + src/store/model/ebgames.ts | 49 ++++++++++++++++++++++++++++++++++++++ src/store/model/index.ts | 2 ++ 3 files changed, 52 insertions(+) create mode 100644 src/store/model/ebgames.ts diff --git a/docs/reference/filter.md b/docs/reference/filter.md index 8e519c3c37..e5277f8ea4 100644 --- a/docs/reference/filter.md +++ b/docs/reference/filter.md @@ -66,6 +66,7 @@ Used with the `STORES` variable. | Corsair | US | `corsair`| | Currys | UK | `currys`| | Cyberport | DE | `cyberport` | +| EBGames | CA | `ebgames`| | eBuyer | UK | `ebuyer`| | El Corte Inglés | US | `elcorteingles`| | ePrice | IT | `eprice`| diff --git a/src/store/model/ebgames.ts b/src/store/model/ebgames.ts new file mode 100644 index 0000000000..9648291a12 --- /dev/null +++ b/src/store/model/ebgames.ts @@ -0,0 +1,49 @@ +import {Store} from './store'; + +export const EbGames: Store = { + labels: { + maxPrice: { + container: '.singleVariantText .prodPriceCont' + }, + outOfStock: { + container: '#btnAddToCart[style*="display:none;"] ', + text: ['add to cart'] + } + }, + links: [ + { + brand: 'test:brand', + model: 'test:model', + series: 'test:series', + url: + 'https://www.ebgames.ca/Switch/Games/727918/mario-kart-8-deluxe' + }, + { + brand: 'sony', + model: 'ps5 console', + series: 'sonyps5c', + url: 'https://www.ebgames.ca/PS5/Games/877522' + }, + { + brand: 'sony', + model: 'ps5 digital', + series: 'sonyps5de', + url: 'https://www.ebgames.ca/PS5/Games/877523' + }, + { + brand: 'microsoft', + model: 'xbox series x', + series: 'xboxsx', + url: + 'https://www.ebgames.ca/Xbox%20Series%20X/Games/877779/xbox-series-x' + }, + { + brand: 'microsoft', + model: 'xbox series s', + series: 'xboxss', + url: + 'https://www.ebgames.ca/Xbox%20Series%20X/Games/877780/xbox-series-s' + } + ], + name: 'ebgames' +}; diff --git a/src/store/model/index.ts b/src/store/model/index.ts index d8d552184a..1a00a696f9 100644 --- a/src/store/model/index.ts +++ b/src/store/model/index.ts @@ -37,6 +37,7 @@ import {Coolmod} from './coolmod'; import {Corsair} from './corsair'; import {Currys} from './currys'; import {Cyberport} from './cyberport'; +import {EbGames} from './ebgames'; import {Ebuyer} from './ebuyer'; import {Elcorteingles} from './elcorteingles'; import {Eprice} from './eprice'; @@ -127,6 +128,7 @@ export const storeList = new Map([ [Corsair.name, Corsair], [Currys.name, Currys], [Cyberport.name, Cyberport], + [EbGames.name, EbGames], [Ebuyer.name, Ebuyer], [Elcorteingles.name, Elcorteingles], [Eprice.name, Eprice],