Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(store): Add PCComponentes and Amazon-ES Stores. #558

Merged
merged 4 commits into from
Oct 20, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ Here is a list of variables that you can use to customize your newly copied `.en
| Amazon | `amazon`|
| Amazon (CA) | `amazon-ca`|
| Amazon (DE) | `amazon-de`|
| Amazon (ES) | `amazon-es`|
| Amazon (NL) | `amazon-nl`|
| Amazon (UK) | `amazon-uk`|
| Aria PC | `aria`|
Expand All @@ -187,6 +188,7 @@ Here is a list of variables that you can use to customize your newly copied `.en
| Nvidia (API) | `nvidia-api`|
| Office Depot | `officedepot`|
| Overclockers | `overclockers`|
| PCComponentes | `pccomponentes`|
| PNY | `pny`|
| Proshop (DE) | `proshop-de`|
| Proshop (DK) | `proshop-dk`|
Expand Down Expand Up @@ -235,7 +237,7 @@ Here is a list of variables that you can use to customize your newly copied `.en
|:---:|---|
| `asus` | `rog strix`, `rog strix oc`, `strix`, `tuf`, `tuf oc` |
| `evga` | `ftw3`, `ftw3 ultra`, `xc3 black`, `xc3`, `xc3 ultra` |
| `gigabyte` | `aorus master`, `eagle`, `eagle oc`, `gaming`, `gaming oc`, `vision oc` |
| `gigabyte` | `aorus master`, `aorus xtreme`, `eagle`, `eagle oc`, `gaming`, `gaming oc`, `vision oc` |
| `msi` | `gaming x trio`, `ventus 3x`, `ventus 3x oc` |
| `nvidia` | `founders edition` |
| `pny` | `dual fan`, `xlr8`, `xlr8 rgb` |
Expand Down
105 changes: 105 additions & 0 deletions src/store/model/amazon-es.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
import {Store} from './store';

export const AmazonEs: Store = {
labels: {
captcha: {
container: 'body',
text: ['introduzca los caracteres que ve a continuación']
},
inStock: {
container: '#desktop_buybox',
text: ['añadir a la cesta']
},
maxPrice: {
container: 'span[class*="PriceString"]',
euroFormat: true
}
},
links: [
{
brand: 'test:brand',
model: 'test:model',
series: 'test:series',
url: 'https://www.amazon.es/dp/B083JX52VG/'
},
{
brand: 'msi',
model: 'gaming x trio',
series: '3080',
url: 'https://www.amazon.es/dp/B08HM4V2DH'
},
{
brand: 'evga',
model: 'ftw3 ultra',
series: '3080',
url: 'https://www.amazon.es/dp/B08HGYXP4C'
},
{
brand: 'evga',
model: 'xc3 ultra',
series: '3080',
url: 'https://www.amazon.es/dp/B08HJ9XFNM'
},
{
brand: 'evga',
model: 'ftw3',
series: '3080',
url: 'https://www.amazon.es/dp/B08HGBYWQ6'
},
{
brand: 'evga',
model: 'xc3',
series: '3080',
url: 'https://www.amazon.es/dp/B08HGLN78Q'
},
{
brand: 'evga',
model: 'xc3 black',
series: '3080',
url: 'https://www.amazon.es/dp/B08HH1BMQQ'
},
{
brand: 'gigabyte',
model: 'gaming oc',
series: '3080',
url: 'https://www.amazon.es/dp/B08HLZXHZY'
},
{
brand: 'gigabyte',
model: 'eagle oc',
series: '3080',
url: 'https://www.amazon.es/dp/B08HHZVZ3N'
},
{
brand: 'asus',
model: 'tuf',
series: '3080',
url: 'https://www.amazon.es/dp/B08HN37VQK'
},
{
brand: 'asus',
model: 'tuf oc',
series: '3080',
url: 'https://www.amazon.es/dp/B08HN4DSTC'
},
{
brand: 'asus',
model: 'rog strix oc',
series: '3080',
url: 'https://www.amazon.es/dp/B08HN6KYS3'
},
{
brand: 'msi',
model: 'ventus 3x oc',
series: '3080',
url: 'https://www.amazon.es/dp/B08HM4M621'
},
{
brand: 'zotac',
model: 'trinity',
series: '3080',
url: 'https://www.amazon.es/dp/B08HR1NPPQ'
}
],
name: 'amazon-es'
};
4 changes: 4 additions & 0 deletions src/store/model/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import {AlternateNL} from './alternate-nl';
import {Amazon} from './amazon';
import {AmazonCa} from './amazon-ca';
import {AmazonDe} from './amazon-de';
import {AmazonEs} from './amazon-es';
import {AmazonNl} from './amazon-nl';
import {AmazonUk} from './amazon-uk';
import {Aria} from './aria';
Expand Down Expand Up @@ -31,6 +32,7 @@ import {Nvidia} from './nvidia';
import {NvidiaApi} from './nvidia-api';
import {OfficeDepot} from './officedepot';
import {Overclockers} from './overclockers';
import {PCComponentes} from './pccomponentes';
import {Pny} from './pny';
import {ProshopDE} from './proshop-de';
import {ProshopDK} from './proshop-dk';
Expand All @@ -48,6 +50,7 @@ const masterList = new Map([
[Amazon.name, Amazon],
[AmazonCa.name, AmazonCa],
[AmazonDe.name, AmazonDe],
[AmazonEs.name, AmazonEs],
[AmazonNl.name, AmazonNl],
[AmazonUk.name, AmazonUk],
[Aria.name, Aria],
Expand Down Expand Up @@ -75,6 +78,7 @@ const masterList = new Map([
[NvidiaApi.name, NvidiaApi],
[OfficeDepot.name, OfficeDepot],
[Overclockers.name, Overclockers],
[PCComponentes.name, PCComponentes],
[ProshopDE.name, ProshopDE],
[ProshopDK.name, ProshopDK],
[Pny.name, Pny],
Expand Down
144 changes: 144 additions & 0 deletions src/store/model/pccomponentes.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,144 @@
import {Store} from './store';

export const PCComponentes: Store = {
labels: {
inStock: {
container: '#btnsWishAddBuy',
text: ['Comprar']
},
outOfStock: {
container: '#btnsWishAddBuy',
text: ['Avísame']
}
},
links: [
{
brand: 'test:brand',
model: 'test:model',
series: 'test:series',
url: 'https://www.pccomponentes.com/gigabyte-geforce-gtx-1660-super-oc-6gb-gddr6'
},
{
brand: 'gigabyte',
model: 'eagle oc',
series: '3080',
url: 'https://www.pccomponentes.com/gigabyte-geforce-rtx-3080-eagle-oc-10g-10gb-gddr6x'
},
{
brand: 'msi',
model: 'ventus 3x oc',
series: '3080',
url: 'https://www.pccomponentes.com/msi-geforce-rtx-3080-ventus-3x-oc-10gb-gddr6x'
},
{
brand: 'asus',
model: 'tuf gaming',
series: '3080',
url: 'https://www.pccomponentes.com/asus-tuf-geforce-rtx-3080-10gb-gddr6x'
},
{
brand: 'gigabyte',
model: 'gaming oc',
series: '3080',
url: 'https://www.pccomponentes.com/gigabyte-geforce-rtx-3080-gaming-oc-10g-10gb-gddr6x'
},
{
brand: 'msi',
model: 'gaming x trio',
series: '3080',
url: 'https://www.pccomponentes.com/msi-geforce-rtx-3080-gaming-x-trio-10gb-gddr6x'
},
{
brand: 'asus',
model: 'tuf oc gaming',
series: '3080',
url: 'https://www.pccomponentes.com/asus-tuf-geforce-rtx-3080-oc-10gb-gddr6x'
},
{
brand: 'asus',
model: 'rog strix oc gaming',
series: '3080',
url: 'https://www.pccomponentes.com/asus-rog-strix-geforce-rtx-3080-10g-gaming-oc-10gb-gddr6x'
},
{
brand: 'evga',
model: 'xc3 black gaming',
series: '3080',
url: 'https://www.pccomponentes.com/evga-geforce-rtx-3080-xc3-black-gaming-10gb-gddr6x'
},
{
brand: 'zotac',
model: 'trinity',
series: '3080',
url: 'https://www.pccomponentes.com/zotac-gaming-geforce-rtx-3080-trinity-10gb-gddr6x'
},
{
brand: 'evga',
model: 'xc3 ultra gaming',
series: '3080',
url: 'https://www.pccomponentes.com/evga-geforce-rtx-3080-xc3-ultra-gaming-10gb-gddr6x'
},
{
brand: 'asus',
model: 'rog strix gaming',
series: '3080',
url: 'https://www.pccomponentes.com/asus-rog-strix-geforce-rtx-3080-gaming-10gb-gddr6x'
},
{
brand: 'zotac',
model: 'trinity oc',
series: '3080',
url: 'https://www.pccomponentes.com/zotac-gaming-geforce-rtx-3080-trinity-oc-10gb-gddr6x'
},
{
brand: 'gigabyte',
model: 'vision oc',
series: '3080',
url: 'https://www.pccomponentes.com/gigabyte-geforce-rtx-3080-vision-oc-10gb-gddr6x'
},
{
brand: 'evga',
model: 'xc3 gaming',
series: '3080',
url: 'https://www.pccomponentes.com/evga-geforce-rtx-3080-xc3-gaming-10gb-gddr6x'
},
{
brand: 'evga',
model: 'ftw3 ultra gaming',
series: '3080',
url: 'https://www.pccomponentes.com/evga-geforce-rtx-3080-ftw3-ultra-gaming-10gb-gddr6x'
},
{
brand: 'gigabyte',
model: 'aorus master',
series: '3080',
url: 'https://www.pccomponentes.com/gigabyte-aorus-geforce-rtx-3080-master-10gb-gddr6x'
},
{
brand: 'gigabyte',
model: 'aorus xtreme',
series: '3080',
url: 'https://www.pccomponentes.com/gigabyte-aorus-geforce-rtx-3080-xtreme-10gb-gddr6x'
},
{
brand: 'evga',
model: 'ftw3 gaming',
series: '3080',
url: 'https://www.pccomponentes.com/evga-geforce-rtx-3080-ftw3-gaming-10gb-gddr6x'
},
{
brand: 'pny',
model: 'xlr8 rgb',
series: '3080',
url: 'https://www.pccomponentes.com/pny-geforce-rtx-3080-xlr8-gaming-epic-x-rgb-10gb-gddr6x'
},
{
brand: 'pny',
model: 'xlr8',
series: '3080',
url: 'https://www.pccomponentes.com/pny-geforce-rtx-3080-epic-x-rgb-triple-fan-xlr8-gaming-edition-10gb-gddr6x'
}
],
name: 'pccomponentes'
};