soaring-symbols 0.1.0-alpha.8 → 0.2.0
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/AIRLINES.md +44 -8
- package/API.md +151 -62
- package/README.md +48 -35
- package/dist/airlines.json +2443 -575
- package/dist/assets/aer-lingus/icon.svg +1 -1
- package/dist/assets/aerolineas-argentinas/icon-mono.svg +1 -0
- package/dist/assets/aerolineas-argentinas/logo-mono.svg +1 -0
- package/dist/assets/aeromexico/icon-mono.svg +1 -0
- package/dist/assets/aeromexico/logo-mono.svg +1 -0
- package/dist/assets/air-algerie/icon-mono.svg +1 -0
- package/dist/assets/air-algerie/logo-mono.svg +1 -0
- package/dist/assets/air-arabia/icon-mono.svg +1 -0
- package/dist/assets/air-arabia/icon.svg +1 -0
- package/dist/assets/air-arabia/logo-mono.svg +1 -0
- package/dist/assets/air-arabia/logo.svg +1 -0
- package/dist/assets/air-astana/icon-mono.svg +1 -0
- package/dist/assets/air-astana/logo-mono.svg +1 -0
- package/dist/assets/air-astana/logo.svg +1 -0
- package/dist/assets/air-berlin/icon-mono.svg +1 -0
- package/dist/assets/air-berlin/icon.svg +1 -0
- package/dist/assets/air-berlin/logo-mono.svg +1 -0
- package/dist/assets/air-berlin/logo.svg +1 -0
- package/dist/assets/air-canada/icon-mono.svg +1 -0
- package/dist/assets/air-china/icon-mono.svg +1 -0
- package/dist/assets/air-china/icon.svg +1 -0
- package/dist/assets/air-china/logo-mono.svg +1 -0
- package/dist/assets/air-china/logo.svg +1 -0
- package/dist/assets/air-dolomiti/icon-mono.svg +1 -0
- package/dist/assets/air-dolomiti/logo-mono.svg +1 -0
- package/dist/assets/air-dolomiti/logo.svg +1 -0
- package/dist/assets/air-europa/icon-mono.svg +1 -0
- package/dist/assets/air-europa/logo-mono.svg +1 -0
- package/dist/assets/air-france/icon-mono.svg +1 -0
- package/dist/assets/air-mauritius/icon-mono.svg +1 -0
- package/dist/assets/air-mauritius/logo-mono.svg +1 -0
- package/dist/assets/air-new-zealand/icon-mono.svg +1 -0
- package/dist/assets/air-new-zealand/logo-mono.svg +1 -0
- package/dist/assets/air-serbia/icon-mono.svg +1 -0
- package/dist/assets/air-serbia/logo-mono.svg +1 -0
- package/dist/assets/air-transat/icon-mono.svg +1 -0
- package/dist/assets/airasia/logo-mono.svg +1 -0
- package/dist/assets/airbaltic/logo-mono.svg +1 -0
- package/dist/assets/akasa-air/icon-mono.svg +1 -0
- package/dist/assets/alaska-airlines/logo-mono.svg +1 -0
- package/dist/assets/all-nippon-airways/logo.svg +1 -0
- package/dist/assets/american-airlines/icon-mono.svg +1 -0
- package/dist/assets/american-airlines/icon.svg +1 -0
- package/dist/assets/american-airlines/logo-mono.svg +1 -0
- package/dist/assets/american-airlines/logo.svg +1 -0
- package/dist/assets/asiana-airlines/icon-mono.svg +1 -0
- package/dist/assets/austrian-airlines/icon-mono.svg +1 -0
- package/dist/assets/austrian-airlines/icon.svg +1 -0
- package/dist/assets/austrian-airlines/logo.svg +1 -0
- package/dist/assets/avianca/icon-mono.svg +1 -0
- package/dist/assets/avianca/logo-mono.svg +1 -0
- package/dist/assets/azul/icon.svg +1 -0
- package/dist/assets/azul/logo.svg +1 -0
- package/dist/assets/brussels-airlines/icon-mono.svg +1 -0
- package/dist/assets/cathay-pacific/icon-mono.svg +1 -0
- package/dist/assets/cathay-pacific/logo-mono.svg +1 -0
- package/dist/assets/cebu-pacific/icon-mono.svg +1 -0
- package/dist/assets/cebu-pacific/icon.svg +1 -0
- package/dist/assets/cebu-pacific/logo-mono.svg +1 -0
- package/dist/assets/cebu-pacific/logo.svg +1 -0
- package/dist/assets/china-airlines/icon.svg +1 -0
- package/dist/assets/china-airlines/logo.svg +1 -0
- package/dist/assets/china-eastern-airlines/icon.svg +1 -0
- package/dist/assets/china-eastern-airlines/logo.svg +1 -0
- package/dist/assets/china-southern-airlines/icon.svg +1 -0
- package/dist/assets/china-southern-airlines/logo-mono.svg +1 -0
- package/dist/assets/china-southern-airlines/logo.svg +1 -0
- package/dist/assets/china-southern-airlines/tail.svg +1 -0
- package/dist/assets/condor/icon-mono.svg +1 -0
- package/dist/assets/condor/icon.svg +1 -0
- package/dist/assets/condor/logo-mono.svg +1 -0
- package/dist/assets/condor/logo.svg +1 -0
- package/dist/assets/copa-airlines/icon-mono.svg +1 -0
- package/dist/assets/copa-airlines/logo-mono.svg +1 -0
- package/dist/assets/delta-air-lines/icon-mono.svg +1 -0
- package/dist/assets/delta-air-lines/icon.svg +1 -0
- package/dist/assets/delta-air-lines/logo-mono.svg +1 -0
- package/dist/assets/delta-air-lines/logo.svg +1 -0
- package/dist/assets/easyjet/icon.svg +1 -0
- package/dist/assets/easyjet/logo-mono.svg +1 -0
- package/dist/assets/easyjet/logo.svg +1 -0
- package/dist/assets/egyptair/icon-mono.svg +1 -0
- package/dist/assets/egyptair/icon.svg +1 -0
- package/dist/assets/egyptair/logo-mono.svg +1 -0
- package/dist/assets/egyptair/logo.svg +1 -0
- package/dist/assets/emirates/icon-mono.svg +1 -0
- package/dist/assets/emirates/logo-mono.svg +1 -0
- package/dist/assets/etihad-airways/logo-mono.svg +1 -0
- package/dist/assets/etihad-airways/logo.svg +1 -1
- package/dist/assets/eva-air/icon.svg +1 -0
- package/dist/assets/eva-air/logo-mono.svg +1 -0
- package/dist/assets/eva-air/logo.svg +1 -0
- package/dist/assets/eva-air/tail.svg +1 -0
- package/dist/assets/ewa-air/logo-mono.svg +1 -0
- package/dist/assets/fiji-airways/icon-mono.svg +1 -0
- package/dist/assets/fiji-airways/logo-mono.svg +1 -0
- package/dist/assets/fiji-airways/logo.svg +1 -0
- package/dist/assets/finnair/icon-mono.svg +1 -0
- package/dist/assets/finnair/icon.svg +1 -0
- package/dist/assets/finnair/logo-mono.svg +1 -0
- package/dist/assets/finnair/logo.svg +1 -0
- package/dist/assets/flybe/logo-mono.svg +1 -0
- package/dist/assets/flybe/logo.svg +1 -0
- package/dist/assets/flydubai/logo.svg +1 -0
- package/dist/assets/flynas/icon-mono.svg +1 -0
- package/dist/assets/flynas/logo-mono.svg +1 -0
- package/dist/assets/frontier-airlines/icon-mono.svg +1 -0
- package/dist/assets/frontier-airlines/icon.svg +1 -0
- package/dist/assets/frontier-airlines/logo-mono.svg +1 -0
- package/dist/assets/frontier-airlines/logo.svg +1 -0
- package/dist/assets/gol/icon.svg +1 -0
- package/dist/assets/gol/logo.svg +1 -0
- package/dist/assets/hainan-airlines/icon-mono.svg +1 -0
- package/dist/assets/hainan-airlines/icon.svg +1 -0
- package/dist/assets/hainan-airlines/logo-mono.svg +1 -0
- package/dist/assets/hainan-airlines/logo.svg +1 -0
- package/dist/assets/hawaiian-airlines/icon.svg +1 -0
- package/dist/assets/hawaiian-airlines/logo.svg +1 -0
- package/dist/assets/icelandair/icon-mono.svg +1 -0
- package/dist/assets/icelandair/logo-mono.svg +1 -0
- package/dist/assets/icelandair/tail-mono.svg +1 -0
- package/dist/assets/indigo/icon-mono.svg +1 -0
- package/dist/assets/indigo/logo-mono.svg +1 -0
- package/dist/assets/ita-airways/logo.svg +1 -0
- package/dist/assets/japan-airlines/icon-mono.svg +1 -0
- package/dist/assets/jet2com/icon-mono.svg +1 -0
- package/dist/assets/jet2com/icon.svg +1 -0
- package/dist/assets/jet2com/logo-mono.svg +1 -0
- package/dist/assets/jet2com/logo.svg +1 -0
- package/dist/assets/jetblue-airways/logo-mono.svg +1 -0
- package/dist/assets/jetblue-airways/logo.svg +1 -0
- package/dist/assets/jetstar/icon-mono.svg +1 -0
- package/dist/assets/jetstar/icon.svg +1 -1
- package/dist/assets/jetstar/logo-mono.svg +1 -1
- package/dist/assets/jetstar/logo.svg +1 -1
- package/dist/assets/kenya-airways/icon-mono.svg +1 -0
- package/dist/assets/kenya-airways/logo-mono.svg +1 -0
- package/dist/assets/klm/icon-mono.svg +1 -0
- package/dist/assets/klm/logo-mono.svg +1 -0
- package/dist/assets/korean-air/icon-mono.svg +1 -0
- package/dist/assets/korean-air/logo-mono.svg +1 -0
- package/dist/assets/kuwait-airways/icon-mono.svg +1 -0
- package/dist/assets/kuwait-airways/logo-mono.svg +1 -0
- package/dist/assets/lion-air/icon-mono.svg +1 -0
- package/dist/assets/lion-air/icon.svg +1 -0
- package/dist/assets/lion-air/logo-mono.svg +1 -0
- package/dist/assets/lion-air/logo.svg +1 -0
- package/dist/assets/lot-polish-airlines/icon-mono.svg +1 -0
- package/dist/assets/lot-polish-airlines/logo-mono.svg +1 -0
- package/dist/assets/lufthansa/icon-mono.svg +1 -0
- package/dist/assets/lufthansa/logo-mono.svg +1 -0
- package/dist/assets/malaysia-airlines/icon-mono.svg +1 -0
- package/dist/assets/malaysia-airlines/logo-mono.svg +1 -0
- package/dist/assets/myanmar-national-airlines/icon-mono.svg +1 -0
- package/dist/assets/norwegian-air-shuttle/icon.svg +1 -0
- package/dist/assets/norwegian-air-shuttle/logo-mono.svg +1 -0
- package/dist/assets/norwegian-air-shuttle/logo.svg +1 -0
- package/dist/assets/pacific-airlines/icon-mono.svg +1 -0
- package/dist/assets/pacific-airlines/icon.svg +1 -0
- package/dist/assets/pacific-airlines/logo-mono.svg +1 -0
- package/dist/assets/pacific-airlines/logo.svg +1 -0
- package/dist/assets/paranair/icon-mono.svg +1 -0
- package/dist/assets/peach-aviation/logo-mono.svg +1 -0
- package/dist/assets/pegasus-airlines/icon-mono.svg +1 -0
- package/dist/assets/pegasus-airlines/icon.svg +1 -0
- package/dist/assets/pegasus-airlines/logo-mono.svg +1 -0
- package/dist/assets/pegasus-airlines/logo.svg +1 -0
- package/dist/assets/qantas/logo.svg +1 -0
- package/dist/assets/riyadh-air/icon-mono.svg +1 -0
- package/dist/assets/riyadh-air/logo-mono.svg +1 -0
- package/dist/assets/royal-air-maroc/icon-mono.svg +1 -0
- package/dist/assets/royal-air-maroc/logo-mono.svg +1 -0
- package/dist/assets/ryanair/icon-mono.svg +1 -0
- package/dist/assets/saudia/icon-mono.svg +1 -0
- package/dist/assets/saudia/logo-mono.svg +1 -0
- package/dist/assets/saudia/logo.svg +1 -0
- package/dist/assets/scandinavian-airlines/logo-mono.svg +1 -0
- package/dist/assets/singapore-airlines/icon-mono.svg +1 -0
- package/dist/assets/spirit-airlines/logo-mono.svg +1 -0
- package/dist/assets/spirit-airlines/logo.svg +1 -0
- package/dist/assets/sun-phuquoc-airways/icon-mono.svg +1 -0
- package/dist/assets/swiss/icon-mono.svg +1 -0
- package/dist/assets/swiss/logo-mono.svg +1 -0
- package/dist/assets/tarom/icon-mono.svg +1 -0
- package/dist/assets/tarom/logo-mono.svg +1 -0
- package/dist/assets/tarom/tail-mono.svg +1 -0
- package/dist/assets/thai-airways/logo-mono.svg +1 -0
- package/dist/assets/thai-airways/logo.svg +1 -0
- package/dist/assets/transavia/icon-mono.svg +1 -0
- package/dist/assets/transavia/logo-mono.svg +1 -0
- package/dist/assets/united-airlines/icon-mono.svg +1 -0
- package/dist/assets/united-airlines/logo-mono.svg +1 -0
- package/dist/assets/vietjet-air/logo-mono.svg +1 -0
- package/dist/assets/vietjet-air/logo.svg +1 -1
- package/dist/assets/vietnam-airlines/icon-mono.svg +1 -0
- package/dist/assets/vietravel-airlines/icon-mono.svg +1 -0
- package/dist/assets/vietravel-airlines/icon.svg +1 -0
- package/dist/assets/vietravel-airlines/logo-mono.svg +1 -0
- package/dist/assets/vietravel-airlines/logo.svg +1 -0
- package/dist/assets/virgin-australia/icon-mono.svg +1 -0
- package/dist/assets/viva/icon-mono.svg +1 -0
- package/dist/assets/viva/icon.svg +1 -0
- package/dist/assets/viva/logo-mono.svg +1 -0
- package/dist/assets/viva/logo.svg +1 -0
- package/dist/assets/volaris/icon.svg +1 -0
- package/dist/assets/volaris/logo.svg +1 -0
- package/dist/assets/volotea/icon-mono.svg +1 -0
- package/dist/assets/volotea/icon.svg +1 -0
- package/dist/assets/volotea/logo-mono.svg +1 -0
- package/dist/assets/volotea/logo.svg +1 -0
- package/dist/assets/vueling/logo.svg +1 -0
- package/dist/assets/wizz-air/logo-mono.svg +1 -0
- package/dist/assets/xiamenair/icon-mono.svg +1 -0
- package/dist/index.cjs +45 -62
- package/dist/index.d.cts +63 -0
- package/dist/index.d.ts +52 -41
- package/dist/index.js +46 -67
- package/dist/svg-validator.cjs +164 -0
- package/dist/svg-validator.d.cts +11 -0
- package/dist/svg-validator.d.ts +11 -0
- package/dist/svg-validator.js +162 -0
- package/package.json +46 -14
- package/dist/utils/index.js +0 -63
package/AIRLINES.md
CHANGED
|
@@ -10,9 +10,12 @@ This file provides an overview of the airlines included in the Soaring Symbols p
|
|
|
10
10
|
| [Aeroméxico](https://www.aeromexico.com) 🇲🇽 | MX | AM | AMX | SkyTeam |  | ✅ | ✅ | |
|
|
11
11
|
| [Air Albania](https://www.airalbania.com.al) 🇦🇱 | AL | ZB | ABN | |  | ✅ | ✅ | |
|
|
12
12
|
| [Air Algérie](https://airalgerie.dz) 🇩🇿 | DZ | AH | DAH | |  | ✅ | ✅ | |
|
|
13
|
-
| [Air
|
|
13
|
+
| [Air Arabia](https://www.airarabia.com) | AE | G9 | ABY | |  | ✅ | ✅ | |
|
|
14
|
+
| [Air Astana](https://airastana.com) 🇰🇿 | KZ | KC | KZR | |  | ✅ | ✅ | |
|
|
15
|
+
| [Air Berlin](https://www.airberlin.com) | DE | AB | BER | oneworld |  | ✅ | ✅ | |
|
|
14
16
|
| [Air Canada](https://www.aircanada.com) 🇨🇦 | CA | AC | ACA | Star Alliance |  | ✅ | ✅ | |
|
|
15
|
-
| [Air
|
|
17
|
+
| [Air China](https://www.airchina.com) 🇨🇳 | CN | CA | CCA | Star Alliance |  | ✅ | ✅ | |
|
|
18
|
+
| [Air Dolomiti](https://www.airdolomiti.eu) | IT | EN | DLA | |  | ✅ | ✅ | |
|
|
16
19
|
| [Air Europa](https://www.aireuropa.com) | ES | UX | AEA | SkyTeam |  | ✅ | ✅ | |
|
|
17
20
|
| [Air France](https://airfrance.com) 🇫🇷 | FR | AF | AFR | SkyTeam |  | ✅ | ✅ | |
|
|
18
21
|
| [Air India](https://www.airindia.com) 🇮🇳 | IN | AI | AIC | Star Alliance |  | ✅ | ✅ | |
|
|
@@ -28,33 +31,56 @@ This file provides an overview of the airlines included in the Soaring Symbols p
|
|
|
28
31
|
| [airBaltic](https://www.airbaltic.com) 🇱🇻 | LV | BT | BTI | |  | | ✅ | |
|
|
29
32
|
| [Akasa Air](https://www.akasaair.com) | IN | QP | AKJ | |  | ✅ | ✅ | |
|
|
30
33
|
| [Alaska Airlines](https://www.alaskaair.com) | US | AS | ASA | oneworld |  | | ✅ | |
|
|
34
|
+
| [All Nippon Airways](https://www.ana.co.jp) | JP | NH | ANA | Star Alliance |  | | ☑️ | |
|
|
35
|
+
| [American Airlines](https://www.aa.com) | US | AA | AAL | oneworld |  | ✅ | ✅ | |
|
|
31
36
|
| [Asiana Airlines](https://flyasiana.com) | KR | OZ | AAR | Star Alliance |  | ✅ | ✅ | |
|
|
32
37
|
| [Atlantic Airways](https://www.atlanticairways.com) 🇫🇴 | FO | RC | FLI | |  | ✅ | ✅ | |
|
|
38
|
+
| [Austrian Airlines](https://www.austrian.com) 🇦🇹 | AT | OS | AUA | Star Alliance |  | ✅ | ☑️ | |
|
|
33
39
|
| [avianca](https://www.avianca.com) 🇨🇴 | CO | AV | AVA | Star Alliance |  | ✅ | ✅ | |
|
|
34
40
|
| Avianca Costa Rica 🇨🇷 | CR | LR | LRC | |  | ✅ | ✅ | |
|
|
35
41
|
| Avianca Ecuador | EC | 2K | GLG | |  | ✅ | ✅ | |
|
|
36
42
|
| Avianca El Salvador 🇸🇻 | SV | TA | TAI | |  | ✅ | ✅ | |
|
|
37
43
|
| [Azerbaijan Airlines](https://azal.az) 🇦🇿 | AZ | J2 | AHY | |  | ✅ | ✅ | |
|
|
44
|
+
| [Azul](https://www.voeazul.com.br) | BR | AD | AZU | |  | ☑️ | ☑️ | |
|
|
38
45
|
| [Bamboo Airways](https://www.bambooairways.com) | VN | QH | BAV | |  | ☑️ | ☑️ | |
|
|
39
46
|
| [Bangkok Airways](https://www.bangkokair.com) | TH | PG | BKP | |  | ✅ | ✅ | |
|
|
40
47
|
| [British Airways](https://www.britishairways.com) 🇬🇧 | GB | BA | BAW | oneworld |  | ✅ | ✅ | |
|
|
41
48
|
| [Brussels Airlines](https://www.brusselsairlines.com) 🇧🇪 | BE | SN | BEL | Star Alliance |  | ✅ | ✅ | |
|
|
42
49
|
| [Cathay Pacific](https://www.cathaypacific.com) 🇭🇰 | HK | CX | CPA | oneworld |  | ✅ | ✅ | |
|
|
50
|
+
| [Cebu Pacific](https://www.cebupacificair.com) | PH | 5J | CEB | |  | ✅ | ✅ | |
|
|
51
|
+
| [China Airlines](https://www.china-airlines.com) 🇹🇼 | TW | CI | CAL | SkyTeam |  | ☑️ | ☑️ | |
|
|
52
|
+
| [China Eastern Airlines](https://www.ceair.com) | CN | MU | CES | SkyTeam |  | ☑️ | ☑️ | |
|
|
53
|
+
| [China Southern Airlines](https://www.csair.com) | CN | CZ | CSN | |  | ☑️ | ✅ | ☑️ |
|
|
54
|
+
| [Condor](https://www.condor.com) | DE | DE | CFG | |  | ✅ | ✅ | |
|
|
43
55
|
| [Copa Airlines](https://www.copaair.com) 🇵🇦 | PA | CM | CMP | Star Alliance |  | ✅ | ✅ | |
|
|
56
|
+
| [Delta Air Lines](https://www.delta.com) | US | DL | DAL | SkyTeam |  | ✅ | ✅ | |
|
|
57
|
+
| [easyJet](https://www.easyjet.com) | GB | U2 | EZY | |  | ☑️ | ✅ | |
|
|
58
|
+
| [EgyptAir](https://www.egyptair.com) 🇪🇬 | EG | MS | MSR | Star Alliance |  | ✅ | ✅ | |
|
|
44
59
|
| [Emirates](https://www.emirates.com) 🇦🇪 | AE | EK | UAE | |  | ✅ | ✅ | |
|
|
45
60
|
| [Ethiopian Airlines](https://www.ethiopianairlines.com) 🇪🇹 | ET | ET | ETH | Star Alliance |  | ✅ | ✅ | |
|
|
46
61
|
| [Etihad Airways](https://www.etihad.com) 🇦🇪 | AE | EY | ETD | |  | | ✅ | |
|
|
47
62
|
| [Eurowings](https://www.eurowings.com) | DE | EW | EWG | |  | ✅ | ✅ | |
|
|
63
|
+
| [EVA Air](https://www.evaair.com) | TW | BR | EVA | Star Alliance |  | ☑️ | ✅ | ☑️ |
|
|
48
64
|
| [Ewa Air](https://ewa-air.com) | FR | ZD | EWR | |  | | ✅ | |
|
|
49
|
-
| [Fiji Airways](https://www.fijiairways.com) 🇫🇯 | FJ | FJ | FJI | oneworld |  | ✅ |
|
|
65
|
+
| [Fiji Airways](https://www.fijiairways.com) 🇫🇯 | FJ | FJ | FJI | oneworld |  | ✅ | ✅ | |
|
|
66
|
+
| [Finnair](http://www.finnair.com) 🇫🇮 | FI | AY | FIN | oneworld |  | ✅ | ✅ | |
|
|
50
67
|
| [Firefly](https://www.fireflyz.com.my) | MY | FY | FFM | |  | ✅ | ✅ | |
|
|
68
|
+
| [Flybe](https://www.flybe.com) | GB | BE | BEE | |  | | ✅ | |
|
|
69
|
+
| [flydubai](https://www.flydubai.com) | AE | FZ | FDB | |  | | ☑️ | |
|
|
51
70
|
| [flynas](https://www.flynas.com) | SA | XY | KNE | |  | ✅ | ✅ | |
|
|
71
|
+
| [Frontier Airlines](https://www.flyfrontier.com) | US | F9 | FFT | |  | ✅ | ✅ | |
|
|
52
72
|
| [Garuda Indonesia](https://www.garuda-indonesia.com) 🇮🇩 | ID | GA | GIA | SkyTeam |  | ✅ | ✅ | |
|
|
73
|
+
| [GOL](https://www.voegol.com.br) | BR | G3 | GLO | |  | ☑️ | ☑️ | |
|
|
74
|
+
| [Hainan Airlines](https://www.hainanairlines.com) | CN | HU | CHH | |  | ✅ | ✅ | |
|
|
75
|
+
| [Hawaiian Airlines](https://www.hawaiianairlines.com) | US | HA | HAL | oneworld |  | ☑️ | ☑️ | |
|
|
53
76
|
| [HK Express](https://www.hkexpress.com) | HK | UO | HKE | |  | ✅ | ✅ | |
|
|
54
|
-
| [Iberia](https://www.iberia.com) 🇪🇸 | ES | IB | IBE | oneworld | |
|
|
77
|
+
| [Iberia](https://www.iberia.com) 🇪🇸 | ES | IB | IBE | oneworld | | ✅ | ✅ | |
|
|
55
78
|
| [Icelandair](https://www.icelandair.com) 🇮🇸 | IS | FI | ICE | |  | ✅ | ✅ | ✅ |
|
|
56
79
|
| [IndiGo](https://www.goindigo.in) | IN | 6E | IGO | |  | ✅ | ✅ | |
|
|
80
|
+
| [ITA Airways](https://www.ita-airways.com) 🇮🇹 | IT | AZ | ITY | Star Alliance |  | | ☑️ | |
|
|
57
81
|
| [Japan Airlines](https://www.jal.co.jp) 🇯🇵 | JP | JL | JAL | oneworld |  | ✅ | ✅ | |
|
|
82
|
+
| [Jet2.com](https://www.jet2.com) | GB | LS | EXS | |  | ✅ | ✅ | |
|
|
83
|
+
| [JetBlue Airways](https://www.jetblue.com) | US | B6 | JBU | |  | | ✅ | |
|
|
58
84
|
| [Jetstar](https://www.jetstar.com) | AU | JQ | JST | |  | ✅ | ✅ | |
|
|
59
85
|
| Jetstar Japan | JP | GK | JJP | |  | ✅ | ✅ | |
|
|
60
86
|
| [Kenya Airways](https://www.kenya-airways.com) 🇰🇪 | KE | KQ | KQA | SkyTeam |  | ✅ | ✅ | |
|
|
@@ -67,40 +93,50 @@ This file provides an overview of the airlines included in the Soaring Symbols p
|
|
|
67
93
|
| LATAM Airlines Ecuador | EC | XL | LNE | |  | ✅ | ✅ | |
|
|
68
94
|
| LATAM Airlines Perú | PE | LP | LPE | |  | ✅ | ✅ | |
|
|
69
95
|
| LATAM Airlines Paraguay | PY | PZ | LAP | |  | ✅ | ✅ | |
|
|
96
|
+
| [Lion Air](https://www.lionair.co.id) | ID | JT | LNI | |  | ✅ | ✅ | |
|
|
70
97
|
| [LOT Polish Airlines](https://www.lot.com) 🇵🇱 | PL | LO | LOT | Star Alliance |  | ✅ | ✅ | |
|
|
71
98
|
| [Lufthansa](https://www.lufthansa.com) 🇩🇪 | DE | LH | DLH | Star Alliance |  | ✅ | ✅ | |
|
|
72
99
|
| [Malaysia Airlines](https://www.malaysiaairlines.com) 🇲🇾 | MY | MH | MAS | oneworld |  | ✅ | ✅ | |
|
|
73
100
|
| [Myanmar National Airlines](https://www.flymna.com) 🇲🇲 | MM | UB | UBA | |  | ✅ | ✅ | |
|
|
101
|
+
| [Norwegian Air Shuttle](https://www.norwegian.com) | NO | DY | NOZ | |  | ☑️ | ✅ | |
|
|
74
102
|
| [Oman Air](https://www.omanair.com) 🇴🇲 | OM | WY | OMA | oneworld |  | ✅ | ✅ | |
|
|
103
|
+
| [Pacific Airlines](https://www.pacificairlines.com) | VN | BL | PIC | |  | ✅ | ✅ | |
|
|
75
104
|
| [Paranair](https://www.paranair.com) | PY | ZP | AZP | |  | ✅ | ✅ | |
|
|
76
105
|
| [Peach Aviation](https://www.flypeach.com) | JP | MM | APJ | |  | | ✅ | |
|
|
106
|
+
| [Pegasus Airlines](https://www.flypgs.com) | TR | PC | PGT | |  | ✅ | ✅ | |
|
|
77
107
|
| [Philippine Airlines](https://www.philippineairlines.com) 🇵🇭 | PH | PR | PAL | |  | ✅ | ✅ | |
|
|
78
|
-
| [Qantas](https://www.qantas.com) 🇦🇺 | AU | QF | QFA | oneworld | |
|
|
108
|
+
| [Qantas](https://www.qantas.com) 🇦🇺 | AU | QF | QFA | oneworld | | ☑️ | ✅ | |
|
|
79
109
|
| [Qatar Airways](https://www.qatarairways.com) 🇶🇦 | QA | QR | QTR | oneworld |  | ✅ | ✅ | |
|
|
80
110
|
| [Riyadh Air](https://www.riyadhair.com) 🇸🇦 | SA | RX | RXI | |  | ✅ | ✅ | |
|
|
81
111
|
| [Royal Air Maroc](https://www.royalairmaroc.com) 🇲🇦 | MA | AT | RAM | SkyTeam |  | ✅ | ✅ | ☑️ |
|
|
82
112
|
| [Royal Brunei Airlines](https://www.flyroyalbrunei.com) | BN | BI | RBA | |  | | ☑️ | |
|
|
83
113
|
| [Ryanair](https://www.ryanair.com) | IE | FR | RYR | |  | ✅ | ✅ | |
|
|
84
|
-
| [Saudia](https://www.saudia.com) 🇸🇦 | SA | SV | SVA | SkyTeam |  | ✅ |
|
|
114
|
+
| [Saudia](https://www.saudia.com) 🇸🇦 | SA | SV | SVA | SkyTeam |  | ✅ | ✅ | |
|
|
85
115
|
| [Scandinavian Airlines](https://www.flysas.com) 🇩🇰 🇳🇴 🇸🇪 | DK,NO,SE | SK | SAS | Star Alliance |  | | ✅ | |
|
|
86
116
|
| SAS Connect | IE | SL | SZS | |  | | ✅ | |
|
|
87
117
|
| [Scoot](https://www.flyscoot.com) | SG | TR | TGW | Value Alliance |  | | ☑️ | |
|
|
88
118
|
| [Singapore Airlines](https://www.singaporeair.com) 🇸🇬 | SG | SQ | SIA | Star Alliance |  | ✅ | ✅ | |
|
|
89
|
-
| [Southwest Airlines](https://www.southwest.com) | US | WN | SWA | |  |
|
|
119
|
+
| [Southwest Airlines](https://www.southwest.com) | US | WN | SWA | |  | ☑️ | ☑️ | |
|
|
120
|
+
| [Spirit Airlines](https://www.spirit.com) | US | NK | NKS | |  | | ✅ | |
|
|
90
121
|
| [Starlux Airlines](https://www.starlux-airlines.com) | TW | JX | SJX | |  | ✅ | ✅ | |
|
|
91
122
|
| [Sun PhuQuoc Airways](https://www.sunphuquocairways.com) | VN | 9G | SPQ | |  | ✅ | ✅ | |
|
|
92
123
|
| [SWISS](https://www.swiss.com) 🇨🇭 | CH | LX | SWR | Star Alliance |  | ✅ | ✅ | |
|
|
93
124
|
| [T'way Air](https://www.twayair.com) | KR | TW | TWB | |  | | ✅ | |
|
|
94
125
|
| [TAP Air Portugal](https://www.tapairportugal.com) 🇵🇹 | PT | TP | TAP | Star Alliance |  | ☑️ | ☑️ | |
|
|
95
126
|
| [TAROM](https://www.tarom.ro) 🇷🇴 | RO | RO | ROT | SkyTeam |  | ✅ | ✅ | ✅ |
|
|
96
|
-
| [Thai Airways](https://www.thaiairways.com) 🇹🇭 | TH | TG | THA | Star Alliance |  | ☑️ |
|
|
127
|
+
| [Thai Airways](https://www.thaiairways.com) 🇹🇭 | TH | TG | THA | Star Alliance |  | ☑️ | ✅ | |
|
|
97
128
|
| [Transavia](https://www.transavia.com) | NL | HV | TRA | |  | ✅ | ✅ | |
|
|
98
129
|
| [Turkish Airlines](https://www.turkishairlines.com) 🇹🇷 | TR | TK | THY | Star Alliance |  | ✅ | ✅ | |
|
|
99
130
|
| [United Airlines](https://www.united.com) | US | UA | UAL | Star Alliance |  | ✅ | ✅ | |
|
|
100
131
|
| [VietJet Air](https://www.vietjetair.com) | VN | VJ | VJC | |  | | ✅ | |
|
|
101
132
|
| [Vietnam Airlines](https://www.vietnamairlines.com) 🇻🇳 | VN | VN | HVN | SkyTeam |  | ✅ | ✅ | |
|
|
133
|
+
| [Vietravel Airlines](https://www.vietravelairlines.com) | VN | VU | VAG | |  | ✅ | ✅ | |
|
|
102
134
|
| [Virgin Atlantic](https://www.virginatlantic.com) | GB | VS | VIR | SkyTeam |  | ✅ | ✅ | |
|
|
103
135
|
| [Virgin Australia](https://www.virginaustralia.com) | AU | VA | VOZ | |  | ✅ | ✅ | |
|
|
136
|
+
| [Viva](https://www.vivaaerobus.com) | MX | VB | VIV | |  | ✅ | ✅ | |
|
|
137
|
+
| [Volaris](https://www.volaris.com) | MX | Y4 | VOI | |  | ☑️ | ☑️ | |
|
|
138
|
+
| [Volotea](https://www.volotea.com) | ES | V7 | VOE | |  | ✅ | ✅ | |
|
|
139
|
+
| [Vueling](https://www.vueling.com) | ES | VY | VLG | |  | | ☑️ | |
|
|
104
140
|
| [WestJet](https://www.westjet.com) | CA | WS | WJA | |  | ✅ | ✅ | |
|
|
105
141
|
| [Wizz Air](https://www.wizzair.com) | HU | W6 | WZZ | |  | | ✅ | |
|
|
106
142
|
| Wizz Air Abu Dhabi | AE | 5W | WAZ | |  | | ✅ | |
|
package/API.md
CHANGED
|
@@ -1,46 +1,91 @@
|
|
|
1
1
|
# Soaring Symbols: API Reference
|
|
2
2
|
|
|
3
|
-
This document details the functions exported by the `soaring-symbols` package and the data structures they return.
|
|
3
|
+
This document details the functions exported by the `soaring-symbols` package and the data structures they return. Upgrading from `0.1.0-alpha.14` or earlier? See [Migrating from the old API](#migrating-from-the-old-api).
|
|
4
|
+
|
|
5
|
+
```js
|
|
6
|
+
import { listAirlines, getAirline, getAssetPath } from 'soaring-symbols'
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
The package works in both ESM (`import`) and CommonJS (`require`). The library itself only reads the bundled `airlines.json`, so it runs in Node, in the browser and in edge runtimes alike.
|
|
4
10
|
|
|
5
11
|
## Functions
|
|
6
12
|
|
|
7
13
|
### `listAirlines()`
|
|
8
14
|
|
|
9
|
-
Returns
|
|
15
|
+
Returns every airline, sorted by name.
|
|
16
|
+
|
|
17
|
+
- **Returns:** `Airline[]` (see [Airline](#airline))
|
|
18
|
+
|
|
19
|
+
The array is a fresh copy on each call, so you can sort or filter it in place. The airline objects inside are frozen; copy one (`{ ...airline }`) before changing it.
|
|
20
|
+
|
|
21
|
+
```js
|
|
22
|
+
const all = listAirlines()
|
|
23
|
+
const skyTeam = all.filter((airline) => airline.alliance === 'SkyTeam')
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
### `getAirline(query)`
|
|
10
27
|
|
|
11
|
-
|
|
28
|
+
Finds one airline. `query` is matched, ignoring case and surrounding whitespace, against the IATA code, then the ICAO code, then the slug, then the full name.
|
|
12
29
|
|
|
13
|
-
|
|
30
|
+
- **Argument:** `query` (string)
|
|
31
|
+
- **Returns:** `Airline`, or `undefined` if nothing matches.
|
|
14
32
|
|
|
15
|
-
|
|
33
|
+
```js
|
|
34
|
+
// All of these find Vietnam Airlines
|
|
35
|
+
getAirline('VN')
|
|
36
|
+
getAirline('hvn')
|
|
37
|
+
getAirline('vietnam-airlines')
|
|
38
|
+
getAirline('Vietnam Airlines')
|
|
39
|
+
|
|
40
|
+
getAirline('XX') // undefined
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
### `getAssetPath(airline, type, options?)`
|
|
44
|
+
|
|
45
|
+
Returns the package path of one SVG file, ready to pass to `require.resolve`, `import.meta.resolve` or your bundler.
|
|
16
46
|
|
|
17
|
-
- **
|
|
18
|
-
-
|
|
47
|
+
- **Arguments:**
|
|
48
|
+
- `airline`: an `Airline` object, or any `query` accepted by `getAirline()`
|
|
49
|
+
- `type`: `'icon'`, `'logo'` or `'tail'` (any other value throws a `TypeError`)
|
|
50
|
+
- `options.mono` (boolean, default `false`): return the `-mono.svg` variant
|
|
51
|
+
- **Returns:** `string`, or `undefined` if the airline is unknown or that file does not exist.
|
|
19
52
|
|
|
20
53
|
```js
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
const vna = getAirline('Vietnam Airlines')
|
|
25
|
-
const vna = getAirline('vietnam-airlines')
|
|
54
|
+
getAssetPath('VN', 'logo') // 'soaring-symbols/assets/vietnam-airlines/logo.svg'
|
|
55
|
+
getAssetPath('VN', 'logo', { mono: true }) // 'soaring-symbols/assets/vietnam-airlines/logo-mono.svg'
|
|
56
|
+
getAssetPath('VN', 'tail') // undefined: Vietnam Airlines has no tail asset
|
|
26
57
|
```
|
|
27
58
|
|
|
28
|
-
|
|
59
|
+
#### Using the path
|
|
29
60
|
|
|
30
|
-
|
|
61
|
+
```js
|
|
62
|
+
// Node: read the SVG markup
|
|
63
|
+
import { readFileSync } from 'node:fs'
|
|
64
|
+
import { fileURLToPath } from 'node:url'
|
|
65
|
+
|
|
66
|
+
const svg = readFileSync(
|
|
67
|
+
fileURLToPath(import.meta.resolve(getAssetPath('VN', 'logo'))),
|
|
68
|
+
'utf8',
|
|
69
|
+
)
|
|
70
|
+
|
|
71
|
+
// CommonJS
|
|
72
|
+
const svg = readFileSync(require.resolve(getAssetPath('VN', 'logo')), 'utf8')
|
|
73
|
+
|
|
74
|
+
// Bundlers (Vite, webpack, ...) take the same path as a static import
|
|
75
|
+
import logoUrl from 'soaring-symbols/assets/vietnam-airlines/logo.svg'
|
|
76
|
+
```
|
|
31
77
|
|
|
32
|
-
|
|
33
|
-
- **Returns:** `AssetPaths` (see [Asset Data Model](#asset-data-model)) or `undefined` if not found.
|
|
78
|
+
For a URL in the browser, link the file from jsDelivr with the airline's `slug`; you don't need the package installed:
|
|
34
79
|
|
|
35
80
|
```js
|
|
36
|
-
const
|
|
81
|
+
const url = `https://cdn.jsdelivr.net/npm/soaring-symbols/dist/assets/${airline.slug}/logo.svg`
|
|
37
82
|
```
|
|
38
83
|
|
|
39
84
|
## Data Models
|
|
40
85
|
|
|
41
|
-
### Airline
|
|
86
|
+
### Airline
|
|
42
87
|
|
|
43
|
-
The
|
|
88
|
+
The object returned by `getAirline()` and found in the array from `listAirlines()`.
|
|
44
89
|
|
|
45
90
|
```json
|
|
46
91
|
{
|
|
@@ -51,63 +96,107 @@ The main object returned by `getAirline()` and found in the array from `listAirl
|
|
|
51
96
|
"flag_carrier": true,
|
|
52
97
|
"website": "https://www.vietnamairlines.com",
|
|
53
98
|
"alliance": "SkyTeam",
|
|
54
|
-
"slug": "vietnam-airlines",
|
|
55
99
|
"branding": {
|
|
56
100
|
"primary_color": "#d99e09",
|
|
57
101
|
"tagline": "Reach Further",
|
|
58
102
|
"guidelines": "https://www.vietnamairlines.com/~/media/FilesDownload/AboutUs/Corporate-Identity/GSM-2017-Web1.pdf"
|
|
103
|
+
},
|
|
104
|
+
"slug": "vietnam-airlines",
|
|
105
|
+
"assets": {
|
|
106
|
+
"icon": { "color": true, "mono": true, "colors": ["#d99e09"] },
|
|
107
|
+
"logo": {
|
|
108
|
+
"color": true,
|
|
109
|
+
"mono": true,
|
|
110
|
+
"colors": ["#d99e09", "#005e80"]
|
|
111
|
+
}
|
|
59
112
|
}
|
|
60
113
|
}
|
|
61
114
|
```
|
|
62
115
|
|
|
63
|
-
|
|
116
|
+
| Field | Type | Description |
|
|
117
|
+
| :------------- | :-------------- | :---------------------------------------------------------------------------------------------------------------------------------- |
|
|
118
|
+
| `name` | `string` | Full airline name. |
|
|
119
|
+
| `iata` | `string` | 2-character IATA code. |
|
|
120
|
+
| `icao` | `string` | 3-letter ICAO code. |
|
|
121
|
+
| `country` | `string` | ISO 3166-1 alpha-2 code; comma-separated when the airline belongs to several. |
|
|
122
|
+
| `slug` | `string` | URL-friendly name, also the asset folder name. |
|
|
123
|
+
| `website` | `string?` | Official website. |
|
|
124
|
+
| `flag_carrier` | `boolean?` | `true` for a national flag carrier. |
|
|
125
|
+
| `alliance` | `string?` | `"oneworld"`, `"SkyTeam"` or `"Star Alliance"`. |
|
|
126
|
+
| `defunct` | `boolean?` | `true` if the airline has ceased operations. |
|
|
127
|
+
| `vectorized` | `boolean?` | `true` if the SVG was vectorized by hand. |
|
|
128
|
+
| `branding` | `object?` | `primary_color`, `tagline` and `guidelines` (link to the brand guidelines), each optional. |
|
|
129
|
+
| `assets` | `object` | One [`AssetInfo`](#assetinfo) per available type (`icon`, `logo`, `tail`). Missing types have no key. |
|
|
130
|
+
| `subsidiaries` | `Subsidiary[]?` | Airlines sharing this airline's marks: `name`, `iata`, `icao`, `country`, `flag_carrier?`. They are not returned by `getAirline()`. |
|
|
131
|
+
|
|
132
|
+
### AssetInfo
|
|
133
|
+
|
|
134
|
+
Describes which files exist for one asset type.
|
|
135
|
+
|
|
136
|
+
| Field | Type | Description |
|
|
137
|
+
| :------- | :--------- | :--------------------------------------------------------------------------------------------------------------------- |
|
|
138
|
+
| `color` | `boolean` | `<type>.svg`, the full-color version, exists. |
|
|
139
|
+
| `mono` | `boolean` | `<type>-mono.svg`, the monochrome version (drawn in `currentColor`), exists. Always `true` for single-color assets. |
|
|
140
|
+
| `colors` | `string[]` | Lowercase hex colors the color file paints with: fills, strokes and gradient stops. Empty when there is no color file. |
|
|
141
|
+
|
|
142
|
+
Every single-color asset ships a `-mono.svg`, generated from its color file. Multi-color assets have one only when it was drawn by hand, so check `mono` (or whether `getAssetPath(..., { mono: true })` returns a path) before offering a monochrome version.
|
|
143
|
+
|
|
144
|
+
The asset folder follows this structure:
|
|
145
|
+
|
|
146
|
+
```plaintext
|
|
147
|
+
assets/<slug>/
|
|
148
|
+
├── icon.svg
|
|
149
|
+
├── icon-mono.svg # generated when icon.svg is single-color
|
|
150
|
+
├── logo.svg
|
|
151
|
+
└── logo-mono.svg # hand-made for a multi-color logo, optional
|
|
152
|
+
```
|
|
64
153
|
|
|
65
|
-
|
|
154
|
+
## Migrating from the old API
|
|
66
155
|
|
|
67
|
-
|
|
156
|
+
Versions up to `0.1.0-alpha.14` exported `getAssets()`, `getAssetContent()`, a default export and a `soaring-symbols/utils` subpath. They are gone; the asset information now ships precomputed in each airline's `assets` field, so the library no longer touches the file system.
|
|
68
157
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
"monochrome": "assets/vietnam-airlines/logo-mono.svg",
|
|
82
|
-
"color_model": "multi",
|
|
83
|
-
"colors": [
|
|
84
|
-
"#d99e09",
|
|
85
|
-
"#005e80"
|
|
86
|
-
]
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
```
|
|
158
|
+
| Old | New |
|
|
159
|
+
| :----------------------------------------------- | :------------------------------------------------------------------------- |
|
|
160
|
+
| `getAirline(key)` returns `null` when missing | Returns `undefined`. |
|
|
161
|
+
| `airline.branding.colors.logo` | `airline.assets.logo.colors` |
|
|
162
|
+
| `getAssets(key)` | `getAirline(key).assets` for metadata, `getAssetPath()` for file paths. |
|
|
163
|
+
| `getAssets(key).logo.color` | `getAssetPath(key, 'logo')` |
|
|
164
|
+
| `getAssets(key).logo.monochrome` | `getAssetPath(key, 'logo', { mono: true })` |
|
|
165
|
+
| `getAssets(key).logo.colors` | `getAirline(key).assets.logo.colors` |
|
|
166
|
+
| `getAssets(key).logo.color_model` | `assets.logo.colors.length > 1 ? 'multi' : 'single'` |
|
|
167
|
+
| `getAssetContent(key).logo.color` | Read the file yourself, see [Using the path](#using-the-path). |
|
|
168
|
+
| `import soaringSymbols from 'soaring-symbols'` | `import { listAirlines, getAirline, getAssetPath } from 'soaring-symbols'` |
|
|
169
|
+
| `import { toSlug } from 'soaring-symbols/utils'` | Use `airline.slug`; look an airline up by name with `getAirline(name)`. |
|
|
90
170
|
|
|
91
|
-
|
|
171
|
+
Two behaviors changed along the way:
|
|
92
172
|
|
|
93
|
-
|
|
173
|
+
- **Paths are package paths.** `getAssets()` returned `assets/<slug>/logo.svg`, relative to the package's `dist/` folder. `getAssetPath()` returns `soaring-symbols/assets/<slug>/logo.svg`, which `require.resolve`, `import.meta.resolve` and bundlers resolve directly.
|
|
174
|
+
- **No path for a missing file.** `getAssets()` always set `color`, even for an asset with only a `-mono.svg` file (for example the Qantas icon). `getAssetPath()` returns `undefined` instead.
|
|
94
175
|
|
|
95
|
-
|
|
96
|
-
| ------------- | --------------------- | ------------------------------------------------------------------------------- |
|
|
97
|
-
| `color` | `string` | Relative path to the full-color SVG. |
|
|
98
|
-
| `monochrome` | `string \| null` | Relative path to the monochrome (`-mono.svg`) variant, if available. |
|
|
99
|
-
| `color_model` | `"single" \| "multi"` | `"single"` if the SVG uses one color; `"multi"` if it contains multiple colors. |
|
|
100
|
-
| `colors` | `string[]` | Array of hex colors extracted from the SVG. |
|
|
176
|
+
### Example: reading every logo
|
|
101
177
|
|
|
102
|
-
|
|
178
|
+
Before:
|
|
103
179
|
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
180
|
+
```js
|
|
181
|
+
import { listAirlines, getAssetContent } from 'soaring-symbols'
|
|
182
|
+
|
|
183
|
+
for (const airline of listAirlines()) {
|
|
184
|
+
const svg = getAssetContent(airline.slug)?.logo?.color
|
|
185
|
+
if (svg) save(airline.slug, svg)
|
|
186
|
+
}
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
After:
|
|
107
190
|
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
191
|
+
```js
|
|
192
|
+
import { readFileSync } from 'node:fs'
|
|
193
|
+
import { createRequire } from 'node:module'
|
|
194
|
+
import { listAirlines, getAssetPath } from 'soaring-symbols'
|
|
195
|
+
|
|
196
|
+
const require = createRequire(import.meta.url)
|
|
197
|
+
|
|
198
|
+
for (const airline of listAirlines()) {
|
|
199
|
+
const path = getAssetPath(airline, 'logo')
|
|
200
|
+
if (path) save(airline.slug, readFileSync(require.resolve(path), 'utf8'))
|
|
201
|
+
}
|
|
202
|
+
```
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Soaring Symbols
|
|
2
2
|
|
|
3
|
-
This project aims to create a meticulously curated collection of airline logos and
|
|
3
|
+
This project aims to create a meticulously curated collection of airline logos, icons and tail designs entirely in SVG format, serving as a valuable resource for travelers, aviation enthusiasts, and designers.
|
|
4
4
|
|
|
5
5
|
> [!IMPORTANT]
|
|
6
6
|
> "Soaring Symbols" provides airline logos/icons in SVG for informational and reference purposes only. We do not claim ownership of any trademarks or copyrighted materials. The logos remain the intellectual property of their respective airlines.
|
|
@@ -11,11 +11,23 @@ The initial phase will focus on building a core collection of high-quality SVG l
|
|
|
11
11
|
|
|
12
12
|
The inclusion of monochrome versions will depend on the airline's brand guidelines and the feasibility of converting their original logos to a simple, one-color format.
|
|
13
13
|
|
|
14
|
-
##
|
|
14
|
+
## Website
|
|
15
15
|
|
|
16
|
-
-
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
Browse the collection, open a page for any airline to download its marks, and check new SVGs against the contribution guidelines at <https://soaring-symbols.anhthang.workers.dev>. The site's source lives in [soaring-symbols/website](https://github.com/soaring-symbols/website).
|
|
17
|
+
|
|
18
|
+
## Roadmap
|
|
19
|
+
|
|
20
|
+
- [x] npm package
|
|
21
|
+
- [x] Website with a browsable catalog, a page per airline and an SVG validator
|
|
22
|
+
- [x] Raycast extension
|
|
23
|
+
- [x] jsDelivr CDN
|
|
24
|
+
- [ ] Iconify icon set, for Iconify, Nuxt Icon, UnoCSS, Tailwind and Astro
|
|
25
|
+
- [ ] Figma plugin, to search airlines by name or IATA code and drop their marks into designs
|
|
26
|
+
- [ ] Swift Package, with an asset catalog and a SwiftUI view
|
|
27
|
+
- [ ] JSON API on the website, such as `/api/airlines/VN`
|
|
28
|
+
- [ ] A `branding.primary_color` for every airline (Iberia and Qantas have none yet)
|
|
29
|
+
|
|
30
|
+
Plans for the website itself are tracked in the [website's README](https://github.com/soaring-symbols/website#roadmap).
|
|
19
31
|
|
|
20
32
|
## Installation
|
|
21
33
|
|
|
@@ -39,17 +51,26 @@ bun add soaring-symbols
|
|
|
39
51
|
| :-- | :-- |
|
|
40
52
|
| [npm Package](https://www.npmjs.com/package/soaring-symbols) <img src="https://cdn.simpleicons.org/npm/000/CB3837" alt="npm" align=left width=24 height=24 /> | [anhthang]|
|
|
41
53
|
| [Raycast Extension](https://www.raycast.com/anhthang/soaring-symbols) <img src="https://cdn.simpleicons.org/raycast/000/FF6363" alt="Raycast" align=left width=24 height=24 /> | [anhthang]|
|
|
54
|
+
| [jsDelivr CDN](https://www.jsdelivr.com/package/npm/soaring-symbols) <img src="https://cdn.simpleicons.org/jsdelivr/000/E84D3D" alt="jsDelivr" align=left width=24 height=24 /> | [jsDelivr](https://www.jsdelivr.com) |
|
|
55
|
+
|
|
56
|
+
### CDN
|
|
57
|
+
|
|
58
|
+
Link any mark straight from the npm package through jsDelivr, with nothing to install. `<slug>` is the airline's name in lowercase with hyphens (e.g. `vietnam-airlines`, see [AIRLINES.md](./AIRLINES.md)); swap `logo` for `icon` or `tail` to get the other marks.
|
|
59
|
+
|
|
60
|
+
```text
|
|
61
|
+
https://cdn.jsdelivr.net/npm/soaring-symbols/dist/assets/<slug>/logo.svg
|
|
62
|
+
```
|
|
42
63
|
|
|
43
64
|
## Usage
|
|
44
65
|
|
|
45
66
|
```js
|
|
46
|
-
import { listAirlines, getAirline,
|
|
67
|
+
import { listAirlines, getAirline, getAssetPath } from 'soaring-symbols'
|
|
47
68
|
|
|
48
|
-
//
|
|
69
|
+
// Every airline, sorted by name
|
|
49
70
|
const all = listAirlines()
|
|
50
71
|
|
|
51
|
-
//
|
|
52
|
-
const vna = getAirline('VN')
|
|
72
|
+
// One airline, by IATA code, ICAO code, slug or name
|
|
73
|
+
const vna = getAirline('VN')
|
|
53
74
|
|
|
54
75
|
/* output example
|
|
55
76
|
{
|
|
@@ -65,43 +86,35 @@ const vna = getAirline('VN')
|
|
|
65
86
|
"tagline": "Reach Further",
|
|
66
87
|
"guidelines": "https://www.vietnamairlines.com/~/media/FilesDownload/AboutUs/Corporate-Identity/GSM-2017-Web1.pdf"
|
|
67
88
|
},
|
|
68
|
-
"slug": "vietnam-airlines"
|
|
89
|
+
"slug": "vietnam-airlines",
|
|
90
|
+
"assets": {
|
|
91
|
+
"icon": { "color": true, "mono": true, "colors": ["#d99e09"] },
|
|
92
|
+
"logo": { "color": true, "mono": true, "colors": ["#d99e09", "#005e80"] }
|
|
93
|
+
}
|
|
69
94
|
}
|
|
70
95
|
*/
|
|
71
96
|
|
|
72
|
-
//
|
|
73
|
-
|
|
97
|
+
// Package path of an SVG, or undefined if the airline has no such file
|
|
98
|
+
getAssetPath('VN', 'logo') // 'soaring-symbols/assets/vietnam-airlines/logo.svg'
|
|
99
|
+
getAssetPath('VN', 'logo', { mono: true }) // '.../logo-mono.svg'
|
|
74
100
|
|
|
75
|
-
|
|
76
|
-
{
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
]
|
|
84
|
-
},
|
|
85
|
-
"logo": {
|
|
86
|
-
"color": "assets/vietnam-airlines/logo.svg",
|
|
87
|
-
"monochrome": "assets/vietnam-airlines/logo-mono.svg",
|
|
88
|
-
"color_model": "multi",
|
|
89
|
-
"colors": [
|
|
90
|
-
"#d99e09",
|
|
91
|
-
"#005e80"
|
|
92
|
-
]
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
*/
|
|
101
|
+
// Read the markup in Node
|
|
102
|
+
import { readFileSync } from 'node:fs'
|
|
103
|
+
import { fileURLToPath } from 'node:url'
|
|
104
|
+
|
|
105
|
+
const svg = readFileSync(
|
|
106
|
+
fileURLToPath(import.meta.resolve(getAssetPath('VN', 'logo'))),
|
|
107
|
+
'utf8',
|
|
108
|
+
)
|
|
96
109
|
```
|
|
97
110
|
|
|
98
|
-
For a full list of functions and the data structures they return, please see the [API Reference](./API.md).
|
|
111
|
+
For a full list of functions and the data structures they return, please see the [API Reference](./API.md). Upgrading from `0.1.0-alpha.14` or earlier, which had `getAssets()` and `getAssetContent()`? The reference has a [migration guide](./API.md#migrating-from-the-old-api).
|
|
99
112
|
|
|
100
113
|
## Contributing
|
|
101
114
|
|
|
102
115
|
Contributions are welcome!
|
|
103
116
|
|
|
104
|
-
Whether through adding new logos, improving existing ones, or suggesting features to enhance usability. Please refer to our [Contribution Guidelines](https://github.com/
|
|
117
|
+
Whether through adding new logos, improving existing ones, or suggesting features to enhance usability. Please refer to our [Contribution Guidelines](https://github.com/soaring-symbols/soaring-symbols/blob/main/CONTRIBUTING.md) for detailed instructions on how to contribute effectively.
|
|
105
118
|
|
|
106
119
|
## License
|
|
107
120
|
|