From 1ed05937676c3b6961fcbbb1f3aa80afc3411ac3 Mon Sep 17 00:00:00 2001 From: Jef LeCompte Date: Wed, 2 Dec 2020 17:31:10 -0500 Subject: [PATCH] feat(store): add smythstoys Signed-off-by: Jef LeCompte --- README.md | 1 + src/store/model/index.ts | 2 ++ src/store/model/smythstoys.ts | 38 +++++++++++++++++++++++++++++++++++ 3 files changed, 41 insertions(+) create mode 100644 src/store/model/smythstoys.ts diff --git a/README.md b/README.md index 333002e517..a0730bd239 100644 --- a/README.md +++ b/README.md @@ -211,6 +211,7 @@ environment variables are **optional**._ | Proshop (DK) | `proshop-dk`| | Saturn (DE) | `saturn`| | Scan (UK) | `scan`| +| Smyths Toys (UK) | `smythstoys`| | Spielegrotte | `spielegrotte`| | Target | `target`| | Unieuro (IT) | `unieuro`| diff --git a/src/store/model/index.ts b/src/store/model/index.ts index 29dccce0a6..f8101c63e2 100644 --- a/src/store/model/index.ts +++ b/src/store/model/index.ts @@ -69,6 +69,7 @@ import {ProshopDE} from './proshop-de'; import {ProshopDK} from './proshop-dk'; import {Saturn} from './saturn'; import {Scan} from './scan'; +import {SmythsToys} from './smythstoys'; import {Spielegrotte} from './spielegrotte'; import {Store} from './store'; import {Target} from './target'; @@ -153,6 +154,7 @@ export const storeList = new Map([ [ProshopDK.name, ProshopDK], [Saturn.name, Saturn], [Scan.name, Scan], + [SmythsToys.name, SmythsToys], [Spielegrotte.name, Spielegrotte], [Target.name, Target], [TopAchat.name, TopAchat], diff --git a/src/store/model/smythstoys.ts b/src/store/model/smythstoys.ts new file mode 100644 index 0000000000..408beb40b0 --- /dev/null +++ b/src/store/model/smythstoys.ts @@ -0,0 +1,38 @@ +import {Store} from './store'; + +export const SmythsToys: Store = { + labels: { + inStock: { + container: '#addToCartButton', + text: ['add to basket'] + }, + maxPrice: { + container: '.price_tag', + euroFormat: false + } + }, + links: [ + { + brand: 'test:brand', + model: 'test:model', + series: 'test:series', + url: + 'https://www.smythstoys.com/uk/en-gb/video-games-and-tablets/video-games/call-of-duty-video-games/call-of-duty-black-ops-cold-war/call-of-duty-black-ops-cold-war-ps5/p/191951' + }, + { + brand: 'sony', + model: 'ps5 console', + series: 'sonyps5c', + url: + 'https://www.smythstoys.com/uk/en-gb/video-games-and-tablets/playstation-5/playstation-5-consoles/playstation-5-console/p/191259' + }, + { + brand: 'sony', + model: 'ps5 digital', + series: 'sonyps5de', + url: + 'https://www.smythstoys.com/uk/en-gb/video-games-and-tablets/playstation-5/playstation-5-consoles/playstation-5-digital-edition-console/p/191430' + } + ], + name: 'smythstoys' +};