Skip to content

Commit

Permalink
Merge pull request #7 from Carifio24/build-fixes
Browse files Browse the repository at this point in the history
Fix some build issues
  • Loading branch information
Carifio24 authored Sep 8, 2024
2 parents 2dfa1fb + 266d2ac commit b82c1bc
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 45 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '18.17.1'
node-version: '20.10.0'

- name: Yarn install
run: yarn install
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '18.17.1'
node-version: '20.10.0'

- name: Yarn install
run: yarn install
Expand Down
80 changes: 42 additions & 38 deletions src/EclipseTimer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -42,47 +42,51 @@
</div>
<div class="eclipse-data-list" v-if="!noEclipse">
<table id="eclipse-values">
<tr>
<td>
<define-term
term="Max Eclipsed"
definition="The fraction (percentage) of the Sun covered by the Moon."
underlined
/>:
</td>
<td> {{ coverage < 0.01 ? '<1' :(coverage*100).toFixed(0) }}% </td>
</tr>
<tr v-if="isTotal">
<td>Totality Duration:</td>
<td> {{ totalityDuration }}</td>
</tr>
<tr v-if="eclipseDuration != ''">
<td>Eclipse Duration:</td>
<td> {{ eclipseDuration }}</td>
</tr>
<tbody>
<tr>
<td>
<define-term
term="Max Eclipsed"
definition="The fraction (percentage) of the Sun covered by the Moon."
underlined
/>:
</td>
<td> {{ coverage < 0.01 ? '<1' :(coverage*100).toFixed(0) }}% </td>
</tr>
<tr v-if="isTotal">
<td>Totality Duration:</td>
<td> {{ totalityDuration }}</td>
</tr>
<tr v-if="eclipseDuration != ''">
<td>Eclipse Duration:</td>
<td> {{ eclipseDuration }}</td>
</tr>
</tbody>
</table>
<hr class="eclipse-timer-dividier"/>
<table id="time-container">
<tr class="time">
<td class="time-label">Partial Start</td>
<td class="time-value">{{ partialStart[1] === '' ? timeString(partialStart[0]) : 'Sun below Horizon' }}</td>
</tr>
<tr class="time" v-if="isTotal">
<td class="time-label">Totality Start</td>
<td class="time-value">{{ centralStart[1] === '' ? timeString(centralStart[0]) : 'Sun below Horizon' }}</td>
</tr>
<tr class="time">
<td class="time-label">Max Eclipse</td>
<td class="time-value">{{ maxTime[1] === '' ? timeString(maxTime[0]) : 'Sun below Horizon' }}</td>
</tr>
<tr class="time" v-if="isTotal">
<td class="time-label">Totality End</td>
<td class="time-value">{{ centralEnd[1] === '' ? timeString(centralEnd[0]) : 'Sun below Horizon' }}</td>
</tr>
<tr class="time">
<td class="time-label">Partial End</td>
<td class="time-value">{{ partialEnd[1] === '' ? timeString(partialEnd[0]) : 'Sun below Horizon' }}</td>
</tr>
<tbody>
<tr class="time">
<td class="time-label">Partial Start</td>
<td class="time-value">{{ partialStart[1] === '' ? timeString(partialStart[0]) : 'Sun below Horizon' }}</td>
</tr>
<tr class="time" v-if="isTotal">
<td class="time-label">Totality Start</td>
<td class="time-value">{{ centralStart[1] === '' ? timeString(centralStart[0]) : 'Sun below Horizon' }}</td>
</tr>
<tr class="time">
<td class="time-label">Max Eclipse</td>
<td class="time-value">{{ maxTime[1] === '' ? timeString(maxTime[0]) : 'Sun below Horizon' }}</td>
</tr>
<tr class="time" v-if="isTotal">
<td class="time-label">Totality End</td>
<td class="time-value">{{ centralEnd[1] === '' ? timeString(centralEnd[0]) : 'Sun below Horizon' }}</td>
</tr>
<tr class="time">
<td class="time-label">Partial End</td>
<td class="time-value">{{ partialEnd[1] === '' ? timeString(partialEnd[0]) : 'Sun below Horizon' }}</td>
</tr>
</tbody>
</table>
<hr class="mt-4" style="width:100%">
</div>
Expand Down
6 changes: 3 additions & 3 deletions src/LocationSelector.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
</template>

<script lang="ts">
import L, { LeafletMouseEvent, Map, TileLayerOptions } from "leaflet";
import L, { CircleMarkerOptions, LeafletMouseEvent, Map, TileLayerOptions } from "leaflet";
import "leaflet/dist/leaflet.css";
import { notify } from "@kyvg/vue3-notification";
import { defineComponent, PropType } from "vue";
Expand Down Expand Up @@ -311,7 +311,7 @@ export default defineComponent({
},
circleForLocation(location: LocationDeg, circleOptions: Record<string,any>): L.CircleMarker { // eslint-disable-line @typescript-eslint/no-explicit-any
return this.circleMaker([location.latitudeDeg, location.longitudeDeg], circleOptions);
return this.circleMaker([location.latitudeDeg, location.longitudeDeg], circleOptions as CircleMarkerOptions);
},
circleForSelection() : L.CircleMarker | null {
Expand Down Expand Up @@ -405,7 +405,7 @@ export default defineComponent({
this.geoJsonFiles.forEach((geojsonrecord) => {
const url = geojsonrecord.url;
const geo = geojsonrecord.geojson;
const style = geojsonrecord.style;
const style = geojsonrecord.style as CircleMarkerOptions;
if (url) {
fetch(url)
.then((response) => response.json())
Expand Down
4 changes: 2 additions & 2 deletions src/SolarEclipse2026.vue
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,7 @@

<details>
<summary>Where can I learn more?</summary>
<p>
<div>
Check out
<ul>
<li>
Expand All @@ -421,7 +421,7 @@
Fiske Planetarium's <a href="https://www.colorado.edu/fiske/projects/science-through-shadows" target="_blank" rel="noopener noreferrer">Science Through Shadows</a> videos
</li>
</ul>
</p>
</div>
</details>
</div>
</div>
Expand Down

0 comments on commit b82c1bc

Please sign in to comment.