Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@
4db15705dbcb5c2b1be39e96990804cdf03fbf1b
# Format with Prettier
c5e40b27cd426c9665e28db54dc092d3997eb718
# Apply automated ESLint fixes
ea24a92f3c78faafc08d2de05d1b22745b41d1c3
9 changes: 8 additions & 1 deletion web/eslint.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,23 @@ export default defineConfigWithVueTs(
name: "app/files-to-lint",
files: ["**/*.{vue,ts,mts,tsx}"],
},

globalIgnores(["**/dist/**", "**/dist-ssr/**", "**/coverage/**"]),
...pluginVue.configs["flat/essential"],

...pluginVue.configs["flat/recommended"],
vueTsConfigs.recommended,

{
rules: {
// allowModifiers: Vuetify uses dot notation for column slots (v-slot:item.columnName)
"vue/valid-v-slot": ["error", { allowModifiers: true }],
// `any` is used everywhere and will be difficult to eliminate
"@typescript-eslint/no-explicit-any": "off",
// Temporary ignores until rules can be fixed
"vue/no-template-shadow": "off",
"vue/require-default-prop": "off",
Comment on lines +27 to +28
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This shouldn't be too hard to fix by hand in a follow-up PR.

},
},

skipFormatting,
);
2 changes: 1 addition & 1 deletion web/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@ watch(() => appStore.currentUser, onReady);
<v-btn
icon
variant="flat"
@click.stop="appStore.currentError = undefined"
class="pa-3"
style="float: right"
@click.stop="appStore.currentError = undefined"
>
<v-icon>mdi-close</v-icon>
</v-btn>
Expand Down
38 changes: 19 additions & 19 deletions web/src/components/ControlsBar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -317,24 +317,24 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
<v-menu activator="parent" :close-on-content-click="false" open-on-hover>
<v-card style="max-height: 400px; overflow-y: auto">
<v-list
ref="basemapList"
:selected="[mapStore.currentBasemap]"
@update:selected="
(selected) => (mapStore.currentBasemap = selected[0])
"
class="basemap-list"
ref="basemapList"
density="compact"
mandatory
@update:selected="
(selected) => (mapStore.currentBasemap = selected[0])
"
>
<v-list-subheader>Base Map Options</v-list-subheader>
<v-list-item
key="new"
title="Create Custom Basemap"
@click="showBasemapCreation = true"
class="px-2"
style="color: rgb(var(--v-theme-primary))"
@click="showBasemapCreation = true"
>
<template v-slot:prepend>
<template #prepend>
<v-icon icon="mdi-plus" class="pa-0" color="primary"></v-icon>
</template>
</v-list-item>
Expand All @@ -345,7 +345,7 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
class="px-2"
>
{{ basemap.name }}
<template v-slot:prepend>
<template #prepend>
<v-icon
:icon="
basemap.id === mapStore.currentBasemap?.id
Expand All @@ -357,8 +357,8 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
></v-icon>
<div
v-if="basemap.id !== undefined"
class="basemap-preview"
:id="'basemap-preview-' + basemap.id"
class="basemap-preview"
/>
<div v-else style="width: 90px" />
</template>
Expand All @@ -367,12 +367,12 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
</v-card>
</v-menu>
</v-btn>
<v-btn class="control-btn" @click="fitMap" variant="flat">
<v-btn class="control-btn" variant="flat" @click="fitMap">
<v-progress-circular v-if="loadingBounds" indeterminate />
<v-icon
v-else
icon="mdi-fit-to-page-outline"
v-tooltip="'Fit Map to Visible Layers'"
icon="mdi-fit-to-page-outline"
></v-icon>
</v-btn>
<v-btn v-if="!isComparing" class="control-btn" variant="flat">
Expand Down Expand Up @@ -405,8 +405,8 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
</v-menu>
</v-btn>
<v-btn
class="control-btn"
v-if="projectStore.currentProject"
class="control-btn"
variant="flat"
>
<v-icon icon="mdi-view-array" class="pb-1 pr-2"></v-icon>
Expand Down Expand Up @@ -441,26 +441,26 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
class="control-menu-row pa-1"
@click="projectStore.navigateToViewState(viewState)"
>
<template v-slot:prepend>
<template #prepend>
<img :src="viewState.thumbnail" height="70px" />
</template>
<template v-slot:title>
<template #title>
<div style="width: 150px; text-wrap: wrap">
{{ viewState.name }}
</div>
</template>
<template v-slot:append>
<template #append>
<v-btn
v-if="userHasEditPermission"
icon="mdi-delete"
v-tooltip="'Delete this view state'"
icon="mdi-delete"
flat
variant="text"
@click.stop.prevent="viewStateToDelete = viewState"
></v-btn>
<v-btn
icon="mdi-share"
v-tooltip="'Copy shareable link'"
icon="mdi-share"
flat
variant="text"
@click.stop.prevent="copyViewStateLink(viewState)"
Expand Down Expand Up @@ -580,7 +580,7 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
></div>
</v-card-text>
<v-card-actions style="text-align: right">
<v-btn @click="cancelBasemapCreate" variant="tonal"> Cancel </v-btn>
<v-btn variant="tonal" @click="cancelBasemapCreate"> Cancel </v-btn>
<v-btn
color="primary"
:disabled="!newBasemapValid"
Expand Down Expand Up @@ -628,7 +628,7 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
<div v-else>Loading thumbnail...</div>
</v-card-text>
<v-card-actions style="text-align: right">
<v-btn @click="cancelCreateViewState" variant="tonal"> Cancel </v-btn>
<v-btn variant="tonal" @click="cancelCreateViewState"> Cancel </v-btn>
<v-btn
color="primary"
:disabled="!newViewStateValid || !newViewStateThumbnail"
Expand Down Expand Up @@ -658,7 +658,7 @@ watch(newBasemapStyleJSON, debounce(createNewBasemapPreview, 1000));
}}"?
</v-card-text>
<v-card-actions style="text-align: right">
<v-btn @click="viewStateToDelete = undefined" variant="tonal">
<v-btn variant="tonal" @click="viewStateToDelete = undefined">
Cancel
</v-btn>
<v-btn color="error" variant="tonal" @click="submitDeleteViewState()">
Expand Down
4 changes: 2 additions & 2 deletions web/src/components/DatasetList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ watch(filteredDatasets, expandAllGroups);
append-inner-icon="mdi-magnify"
hide-details
/>
<v-expansion-panels v-model="showFilter" flat v-if="props.datasets?.length">
<v-expansion-panels v-if="props.datasets?.length" v-model="showFilter" flat>
<v-expansion-panel value="true" class="mb-2 bg-transparent">
<v-expansion-panel-title class="tag-filter-title">
Filter by Tag
Expand Down Expand Up @@ -115,7 +115,7 @@ watch(filteredDatasets, expandAllGroups);
v-else-if="projectStore.loadingDatasets"
indeterminate
></v-progress-linear>
<v-card-text class="help-text" v-else>No available Datasets.</v-card-text>
<v-card-text v-else class="help-text">No available Datasets.</v-card-text>
</v-card>
</div>
</template>
Expand Down
10 changes: 5 additions & 5 deletions web/src/components/DetailView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -172,9 +172,9 @@ watch([showModal, currentDetails], fetchRelated);

<template>
<v-icon
v-tooltip="'View Details'"
icon="mdi-dots-vertical"
size="small"
v-tooltip="'View Details'"
class="mx-1"
@click.stop="showModal = true"
></v-icon>
Expand All @@ -188,8 +188,8 @@ watch([showModal, currentDetails], fetchRelated);
style="max-width: 90%; margin: 4px 4em 0 0; align-items: center"
>
<v-icon
icon="mdi-arrow-left"
v-if="stackPoppable"
icon="mdi-arrow-left"
@click="popStack"
/>
<v-icon
Expand All @@ -215,7 +215,7 @@ watch([showModal, currentDetails], fetchRelated);
item-value="id"
@click:select="({ id }) => addToStack(id as number)"
>
<template v-slot:prepend="{ item }">
<template #prepend="{ item }">
<v-icon
v-if="item.prependIcon"
:icon="item.prependIcon"
Expand All @@ -225,10 +225,10 @@ watch([showModal, currentDetails], fetchRelated);
item.type.toUpperCase()
}}</span>
</template>
<template v-slot:title="{ item }">
<template #title="{ item }">
<div v-if="item" v-tooltip="item.name">{{ item.name }}</div>
</template>
<template v-slot:append="{ item }">
<template #append="{ item }">
<a v-if="item?.download" :href="item.download.url" download>
<v-icon
v-tooltip="
Expand Down
12 changes: 6 additions & 6 deletions web/src/components/SliderNumericInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ function updateRange(lower: number, upper: number) {
hide-details
@update:model-value="(v: number) => updateValue(v)"
>
<template v-slot:append>
<template #append>
<v-number-input
:model-value="props.model"
:min="props.min"
Expand All @@ -83,7 +83,7 @@ function updateRange(lower: number, upper: number) {
:precision="precision"
:style="{ width: getInputWidth() }"
variant="outlined"
controlVariant="stacked"
control-variant="stacked"
hide-details
@update:model-value="updateValue"
@keydown.enter="blur()"
Expand All @@ -102,7 +102,7 @@ function updateRange(lower: number, upper: number) {
hide-details
@update:model-value="([lower, upper]) => updateRange(lower, upper)"
>
<template v-slot:prepend>
<template #prepend>
<v-number-input
:model-value="props.rangeModel[0]"
:min="props.min"
Expand All @@ -111,7 +111,7 @@ function updateRange(lower: number, upper: number) {
:precision="precision"
:style="{ width: getInputWidth() }"
variant="outlined"
controlVariant="stacked"
control-variant="stacked"
hide-details
@update:model-value="
(v) => {
Expand All @@ -121,7 +121,7 @@ function updateRange(lower: number, upper: number) {
@keydown.enter="blur()"
/>
</template>
<template v-slot:append>
<template #append>
<v-number-input
:model-value="props.rangeModel[1]"
:min="props.rangeModel[0]"
Expand All @@ -130,7 +130,7 @@ function updateRange(lower: number, upper: number) {
:precision="precision"
:style="{ width: getInputWidth() }"
variant="outlined"
controlVariant="stacked"
control-variant="stacked"
hide-details
@update:model-value="
(v) => {
Expand Down
2 changes: 1 addition & 1 deletion web/src/components/map/MapTooltip.vue
Original file line number Diff line number Diff line change
Expand Up @@ -186,10 +186,10 @@ function toggleNodeHandler() {
v-if="clickedFeature.feature.properties.node_id"
block
variant="outlined"
@click="toggleNodeHandler"
:text="
clickedFeatureIsDeactivatedNode ? 'Reactivate Node' : 'Deactivate Node'
"
@click="toggleNodeHandler"
/>
</div>

Expand Down
2 changes: 1 addition & 1 deletion web/src/components/map/ToggleCompareMap.vue
Original file line number Diff line number Diff line change
Expand Up @@ -298,14 +298,14 @@ onMounted(() => {
layer-order="bottommost"
:attribution-control="false"
:preserve-drawing-buffer="true"
class="map"
@panend="compareStore.updateMapStats($event)"
@zoomend="compareStore.updateMapStats($event)"
@pitchend="compareStore.updateMapStats($event)"
@rotateend="compareStore.updateMapStats($event)"
@sliderend="compareStore.updateSlider($event)"
@map-ready-a="handleMapReady($event, 'A')"
@map-ready-b="handleMapReady($event, 'B')"
class="map"
/>

<div id="map-tooltip" ref="tooltip" class="tooltip pa-0">
Expand Down
Loading