-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPlanet.js
236 lines (230 loc) · 10.4 KB
/
Planet.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
function planetnews() {
if (year == 2022 && month == 0) {
return "Mercury Visible at Sunset until 30th";
} else if (year == 2022 && month == 1) {
return "Venus Brightest on February 9";
} else if (year == 2022 && month == 2) {
return "Spring Equinox on March 20th";
} else if (year == 2022 && month == 3) {
return "Mercury will be visible at Sunrise until 30th";
} else if (year == 2022 && month == 4) {
return "May 6: Eta Aquarid Meteors";
} else if (year == 2022 && month == 5) {
return "June 20: Summer Solstice";
} else if (year == 2022 && month == 6) {
return "Pluto at Opposition Jul 20";
} else if (year == 2022 && month == 7) {
return "August 24 : Uranus begins retrograde motion";
} else if (year == 2022 && month == 8) {
return "Fall Equinox September 22nd";
} else if (year == 2022 && month == 9) {
return "Mars in Retrograde October 30";
} else if (year == 2022 && month == 10) {
return "Uranus at opposition – November 9";
} else if (year == 2022 && month == 11) {
return "Dec 21: Winter Solstice";
} else if (year == 2023 && month == 0) {
return "Jan 7: Inferior conjunction Mercury";
} else if (year == 2023 && month == 1) {
return "February 16: Saturn in conjunction with the sun";
} else if (year == 2023 && month == 2) {
return "Spring Equinox on March 20th";
} else if (year == 2023 && month == 3) {
return "April 11: Jupiter at solar conjunction";
} else if (year == 2023 && month == 4) {
return "Mercury Visible at Sunrise until 30th";
} else if (year == 2023 && month == 5) {
return "June 21: Summer Solstice";
} else if (year == 2023 && month == 6) {
return "Pluto at Opposition : July 22 ";
} else if (year == 2023 && month == 7) {
return "August 13th: Perseid Meteor Shower";
} else if (year == 2023 && month == 8) {
return "Fall Equinox September 23rd";
} else if (year == 2023 && month == 9) {
return "October 22 - Orionids Meteor Shower";
} else if (year == 2023 && month == 10) {
return "Uranus at opposition – November 13";
} else if (year == 2023 && month == 11) {
return "Winter Solstice on Dec 21st";
} else if (year == 2024 && month == 0) {
return "January 4 - Quadrantids Meteor Shower";
} else if (year == 2024 && month == 1) {
return "Centaurid Meteor Shower";
} else if (year == 2024 && month == 2) {
return "Spring Equinox March 19th";
} else if (year == 2024 && month == 3) {
return "April 8: Total Solar Eclipse parts of USA";
} else if (year == 2024 && month == 4) {
return "May 7 - Eta Aquarids Meteor Shower";
} else if (year == 2024 && month == 5) {
return "Summer Solstice Jun 20th";
} else if (year == 2024 && month == 6) {
return "Mercury visible at Sunset until 30th";
} else if (year == 2024 && month == 7) {
return "August 13 - Perseids Meteor Shower";
} else if (year == 2024 && month == 8) {
return "Fall Equinox September 24";
} else if (year == 2024 && month == 9) {
return "October 22 - Orionids Meteor Shower";
} else if (year == 2024 && month == 10) {
return "Mercury visible at Sunset until 30th";
} else if (year == 2024 && month == 11) {
return "Winter Solstice Dec 21st";
} else if (year == 2025 && month == 0) {
return "Mars at Opposition on January 16th";
} else if (year == 2025 && month == 1) {
return "Venus at greatest brightness: Feb 16";
} else if (year == 2025 && month == 2) {
return "Spring Equinox March 20th";
} else if (year == 2025 && month == 3) {
return "April 23rd - Lyrids Meteor Shower";
} else if (year == 2025 && month == 4) {
return "May 7th - Eta Aquarids Meteor Shower";
} else if (year == 2025 && month == 5) {
return "Summer Solstice June 20th";
} else if (year == 2025 && month == 6) {
return "July 29th - Delta Aquarids Meteor Shower";
} else if (year == 2025 && month == 7) {
return "August 13th - Perseids Meteor Shower";
} else if (year == 2025 && month == 8) {
return "Fall Equinox: September 22nd";
} else if (year == 2025 && month == 9) {
return "October 22nd - Orionids Meteor Shower";
} else if (year == 2025 && month == 10) {
return "November 5th - Taurids Meteor Shower";
} else if (year == 2025 && month == 11) {
return "Winter Solstice : December 21st";
} else if (year == 2026 && month == 2) {
return "Spring Equinox March 20th";
} else if (year == 2026 && month == 5) {
return "Summer Solstice June 21st";
} else if (year == 2026 && month == 8) {
return "Fall Equinox: September 22nd";
} else if (year == 2026 && month == 11) {
return "Winter Solstice : December 21st";
} else if (year == 2027 && month == 2) {
return "Spring Equinox March 20th";
} else if (year == 2027 && month == 5) {
return "Summer Solstice June 21st";
} else if (year == 2027 && month == 8) {
return "Fall Equinox: September 22nd";
} else if (year == 2027 && month == 11) {
return "Winter Solstice : December 21st";
} else if (year == 2028 && month == 2) {
return "Spring Equinox March 19th";
} else if (year == 2028 && month == 5) {
return "Summer Solstice June 20th";
} else if (year == 2028 && month == 8) {
return "Fall Equinox: September 22nd";
} else if (year == 2028 && month == 11) {
return "Winter Solstice : December 21st";
} else if (year == 2029 && month == 2) {
return "Spring Equinox March 20th";
} else if (year == 2029 && month == 5) {
return "Summer Solstice June 20th";
} else if (year == 2029 && month == 8) {
return "Fall Equinox: September 22nd";
} else if (year == 2029 && month == 11) {
return "Winter Solstice : December 21st";
} else if (year == 2030 && month == 2) {
return "Spring Equinox March 20th";
} else if (year == 2030 && month == 5) {
return "Summer Solstice June 21st";
} else if (year == 2030 && month == 8) {
return "Fall Equinox: September 22nd";
} else if (year == 2030 && month == 11) {
return "Winter Solstice : December 21st";
}
//Conjunction Opposition data not on Months == 2 5 8 11 for 2026 - 2030
else if (year == 2026 && month == 0) {
return "Jupiter at opposition: Jan 10th";
} else if (year == 2026 && month == 4) {
return "Mercury at solar conjunction: May 14th";
} else if (year == 2026 && month == 6) {
return "Jupiter at solar conjunction: July 29th";
} else if (year == 2026 && month == 7) {
return "Mercury at solar conjunction: Aug 27";
} else if (year == 2026 && month == 9) {
return "Venus at solar conjunction: Oct 23rd";
} else if (year == 2026 && month == 10) {
return "Uranus at opposition: Nov 25th";
//2027
}else if (year == 2027 && month == 0) {
return "Mercury at solar conjunction Jan 1st";
} else if (year == 2027 && month == 1) {
return "Jupiter at opposition: Feb 10th";
} else if (year == 2027 && month == 3) {
return "Saturn at solar conjunction April 7th";
} else if (year == 2027 && month == 4) {
return "Uranus at solar conjunction May 26th";
} else if (year == 2027 && month == 7) {
return "Venus at solar conjunction Aug 11th";
} else if (year == 2027 && month == 9) {
return "Saturn at opposition: Oct 17th";
} else if (year == 2027 && month == 10) {
return "Uranus at opposition: Nov 30th";
}
//2028
else if (year == 2028 && month == 0) {
return "Pluto at solar conjunction Jan 27th";
} else if (year == 2028 && month == 1) {
return "Mercury at solar conjunction: Feb 2nd";
} else if (year == 2028 && month == 3) {
return "Saturn at solar conjunction April 20th";
} else if (year == 2028 && month == 4) {
return "Uranus at solar conjunction May 30th";
} else if (year == 2028 && month == 6) {
return "Mercury at solar conjunction July 25th";
} else if (year == 2028 && month == 9) {
return "Mercury at solar conjunction Oct 2nd";
} else if (year == 2028 && month == 10) {
return "Mercury at solar conjunction: Nov 19th";
}
//2029
else if (year == 2029 && month == 0) {
return "Pluto at solar conjunction Jan 28th";
} else if (year == 2029 && month == 3) {
return "Jupiter at opposition April 11th";
} else if (year == 2029 && month == 4) {
return "Saturn at solar conjunction: May 4th";
} else if (year == 2029 && month == 6) {
return "Mercury at solar conjunction: July 9th";
} else if (year == 2029 && month == 9) {
return "Neptune at opposition: October 2nd";
} else if (year == 2029 && month == 10) {
return "Saturn at oppositio: Nov 13th";
}
//2030
else if (year == 2030 && month == 0) {
return "Venus at solar conjunction Jan 6th";
} else if (year == 2029 && month == 3) {
return "Mercury at solar conjunction: April 23rd";
} else if (year == 2029 && month == 4) {
return "Jupiter at opposition: May 13th";
} else if (year == 2029 && month == 6) {
return "Mercury at solar conjunction: July 9th";
} else if (year == 2029 && month == 7) {
return "Mercury at solar conjunction Aug 29";
} else if (year == 2029 && month == 9) {
return "Neptune at opposition: October 4th";
} else if (year == 2029 && month == 10) {
return "Saturn at opposition: Nov 27th";
}
else {
return "Meteor Shower this Month!";
}
}
function planetType(){
if((planetnews()).includes("Solstice")||(planetnews()).includes("Equinox")){return "Sun";}
else if((planetnews()).includes("Meteor")||(planetnews()).includes("Shower")){return "Shower";}
else if((planetnews()).includes("Mercury")){return "Mercury";}
else if((planetnews()).includes("Venus")){return "Venus";}
else if((planetnews()).includes("Mars")){return "Mars";}
else if((planetnews()).includes("Jupiter")){return "Jupiter";}
else if((planetnews()).includes("Saturn")){return "Saturn";}
else if((planetnews()).includes("Uranus")){return "Uranus";}
else if((planetnews()).includes("Neptune")){return "Neptune";}
else if((planetnews()).includes("Pluto")){return "Pluto";}
else{return "Shower";}
}