@furkot/garmin-data 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/Readme.md ADDED
@@ -0,0 +1,42 @@
1
+ [![NPM version][npm-image]][npm-url]
2
+ [![Build Status][build-image]][build-url]
3
+ [![Dependency Status][deps-image]][deps-url]
4
+
5
+ # @furkot/garmin-data
6
+
7
+ Data used by [Furkot] modules dealing with Garmin GPX format.
8
+
9
+ ## Install
10
+
11
+ ```sh
12
+ $ npm install --save @furkot/garmin-data
13
+ ```
14
+
15
+ ## Usage
16
+
17
+ Furkot pin symbols are characters in [furkot-icon-font] - see [here][furkot-icon-font-demo].
18
+
19
+ ```js
20
+ var data = require('@furkot/garmin-data');
21
+
22
+ console.log(data.toFurkot['Church']); // === 34
23
+ console.log(data.toGarmin['34']); // === 'Church'
24
+
25
+ ```
26
+
27
+ ## License
28
+
29
+ MIT © [Damian Krzeminski](https://code42day.com)
30
+
31
+ [Furkot]: https://furkot.com
32
+ [furkot-icon-font]: https://github.com/furkot/icon-fonts
33
+ [furkot-icon-font-demo]: https://furkot.github.io/icon-fonts/build/furkot.html
34
+
35
+ [npm-image]: https://img.shields.io/npm/v/@furkot/garmin-data
36
+ [npm-url]: https://npmjs.org/package/@furkot/garmin-data
37
+
38
+ [build-url]: https://github.com/furkot/garmin-data/actions/workflows/check.yaml
39
+ [build-image]: https://img.shields.io/github/workflow/status/furkot/garmin-data/check
40
+
41
+ [deps-image]: https://img.shields.io/librariesio/release/npm/@furkot/garmin-data
42
+ [deps-url]: https://libraries.io/npm/@furkot%2Fgarmin-data
package/index.js ADDED
@@ -0,0 +1 @@
1
+ module.exports = require('./lib/garmin');
package/lib/garmin.js ADDED
@@ -0,0 +1,133 @@
1
+ module.exports = {
2
+ toGarmin: {
3
+ 0: 'Lodging', // hotel
4
+ //1: 'Waypoint', // stop (default)
5
+ 2: 'Trail Head', // hiking
6
+ 3: 'Trail Head', // guide
7
+ 4: 'Trail Head', // snowshoeing
8
+ 5: 'Library', // book
9
+ 6: 'Bank', // deal
10
+ //7: '', // pin
11
+ 8: 'Bike Trail', // biking
12
+ 9: 'Picnic Area', // picnic
13
+ 10: 'Gas Station', // charging
14
+ 11: 'Campground', // tent
15
+ 12: 'Residence', // house
16
+ 13: 'Summit', // climbing
17
+ 14: 'Ski Resort', // skiing
18
+ 15: 'Lodging', // hostel
19
+ 16: 'Lodging', // chain
20
+ 17: 'Car', // car
21
+ //18: '', // first
22
+ //19: '', // last
23
+ 20: 'Lodging', // multinight
24
+ 21: 'Diver Down Flag 1', // diving
25
+ //22: '', // firstlast
26
+ 23: 'Airport', // airplane
27
+ 24: 'Restaurant', // restaurant
28
+ 25: 'Gas Station', // fillingstation
29
+ //26: '', // motorcycle
30
+ 27: 'Food Source', // farmstand
31
+ 28: 'Bar', // brewery
32
+ 29: 'Amusement Park', // amusementpark
33
+ 30: 'Winery', // wine
34
+ 31: 'Bar', // bar
35
+ 32: 'Shopping Center', // grocery
36
+ 33: 'Museum', // museum
37
+ 34: 'Church', // church
38
+ 35: 'Church', // synagogue
39
+ 36: 'Ghost Town', // ruins
40
+ 37: 'Residence', // villa
41
+ 38: 'Building', // palace
42
+ 39: 'Museum', // artmuseum
43
+ 40: 'Building', // worldheritagesite
44
+ 41: 'City Hall', // officebuilding
45
+ 42: 'Church', // shrine
46
+ 43: 'Tower', // tower
47
+ 44: 'Church', // temple
48
+ 45: 'Museum', // sciencemuseum
49
+ 46: 'Building', // landmark
50
+ 47: 'Museum', // historymuseum
51
+ 48: 'Forest', // forest
52
+ 49: 'Swimming Area', // surfing
53
+ 50: 'Park', // park
54
+ 51: 'Building', // structure
55
+ 52: 'Summit', // naturalfeature
56
+ 53: 'Park', // outdoors
57
+ 54: 'Swimming Area', // watersport
58
+ 55: 'Mile Marker', // scenicroad
59
+ 56: 'Beach', // beach
60
+ 57: 'Water Source', // hotspring
61
+ 58: 'Dropoff', // water
62
+ 59: 'Summit', // mountains
63
+ 60: 'Summit', // volcano
64
+ 61: 'Scenic Area', // lookout
65
+ 62: 'Weed Bed', // lake
66
+ 63: 'Fishing Area', // river
67
+ 64: 'ATV', // jeep
68
+ 65: 'Cemetery', // cemetery
69
+ 66: 'Library', // library
70
+ 67: 'Zoo', // zoo
71
+ 68: 'Stadium', // stadium
72
+ //69: '', // windmill
73
+ //70: '', // square
74
+ 71: 'City (Medium)', // town
75
+ //72: '', // statue
76
+ 73: 'Information', // information
77
+ //74: '', // amphitheater
78
+ //75: '', // observatory
79
+ //76: '', // passthru
80
+ 77: 'Drinking Water', // tap
81
+ 78: 'Convenience Store', // minimarket
82
+ 79: 'Anchor', // anchor
83
+ 80: 'Toll Booth', // tollbooth
84
+ 81: 'Hospital', // hospital
85
+ 82: 'Restroom', // toilets
86
+ 83: 'Truck Stop', // truck
87
+ 84: 'RV Park', // rvpark
88
+ 85: 'Bridge', // bridge
89
+ 86: 'City (Capitol)', // star
90
+ 87: 'Geocache', // treasure
91
+ //88: '', // teleport
92
+ 89: 'Crossing', // railroadcrossing
93
+ 90: 'Restaurant', // coffee
94
+ 91: 'ATV', // atv
95
+ 92: 'Dog, sitting', // pets
96
+ //93: '', // fire
97
+ 94: 'Fishing Area', // pier
98
+ 95: 'Ferry', // ferry
99
+ 96: 'Live Theater', // theater
100
+ 97: 'Railway', // train
101
+ 98: 'Parking Area', // parking
102
+ 99: 'Shopping Center', // cart
103
+ 100: 'Boat Ramp' // boatramp
104
+ },
105
+ toFurkot: {
106
+ 'Church': 34, // church
107
+ 'Lodging': 0, // hotel
108
+ 'Museum': 33, // museum
109
+ 'Park': 50, // park
110
+ 'Summit': 59, // mountains
111
+ 'Swimming Area': 54, // watersport
112
+ 'Trail Head': 3 // guide
113
+ },
114
+ colors: {
115
+ 2: 'Black',
116
+ 3: 'Blue',
117
+ 4: 'Cyan',
118
+ 5: 'DarkBlue',
119
+ 6: 'DarkCyan',
120
+ 7: 'DarkGray',
121
+ 8: 'DarkGreen',
122
+ 9: 'DarkMagenta',
123
+ 10: 'DarkRed',
124
+ 11: 'DarkYellow',
125
+ 12: 'Green',
126
+ 14: 'LightGray',
127
+ 15: 'Magenta',
128
+ 18: 'Red',
129
+ 20: 'White',
130
+ 21: 'Yellow',
131
+ 22: 'Transparent'
132
+ }
133
+ };
package/package.json ADDED
@@ -0,0 +1,30 @@
1
+ {
2
+ "name": "@furkot/garmin-data",
3
+ "version": "1.0.1",
4
+ "description": "Data used by Furkot modules dealing with Garmin GPX format.",
5
+ "author": {
6
+ "name": "Damian Krzeminski",
7
+ "email": "pirxpilot@code42day.com",
8
+ "url": "https://code42day.com"
9
+ },
10
+ "repository": "furkot/garmin-data",
11
+ "license": "MIT",
12
+ "keywords": [
13
+ "furkot-garmin-data",
14
+ "furkot",
15
+ "garmin"
16
+ ],
17
+ "dependencies": {},
18
+ "devDependencies": {
19
+ "jshint": "~2",
20
+ "mocha": "~10",
21
+ "should": "~13"
22
+ },
23
+ "scripts": {
24
+ "test": "make check"
25
+ },
26
+ "files": [
27
+ "index.js",
28
+ "lib"
29
+ ]
30
+ }