diff --git a/lib/resorts/roccaraso/index.js b/lib/resorts/roccaraso/index.js new file mode 100644 index 00000000..1f70bb76 --- /dev/null +++ b/lib/resorts/roccaraso/index.js @@ -0,0 +1,19 @@ +module.exports = { + selector: '.container .content', + parse: { + name: '1', + status: { + child: '0', + attribute: 'class', + regex: /ic_stato([0-9])/, + fn: (s) => { + switch (s) { + case '1': + return 'open'; + case '0': + return 'closed'; + } + }, + }, + }, +}; diff --git a/lib/resorts/roccaraso/resort.json b/lib/resorts/roccaraso/resort.json new file mode 100644 index 00000000..33c75334 --- /dev/null +++ b/lib/resorts/roccaraso/resort.json @@ -0,0 +1,20 @@ +{ + "name": "Roccaraso - Rivisondoli", + "dataUrl": { + "host": "https://monitor.roccaraso.net", + "pathname": "/impianti.php" + }, + "url": { + "host": "https://www.roccaraso.net", + "pathname": "/" + }, + "tags": [ + "Italy", + "Appennines", + "Abruzzo" + ], + "ll": [ + 14.08396047685749, + 41.85103115486714 + ] +} \ No newline at end of file diff --git a/test/resorts/example/roccaraso.html b/test/resorts/example/roccaraso.html new file mode 100644 index 00000000..a5ce242b --- /dev/null +++ b/test/resorts/example/roccaraso.html @@ -0,0 +1,198 @@ + + +
+ +