Skip to content

Commit 20ba526

Browse files
committed
Merge branch 'fix/pedantic_oxlint' of https://github.com/Geode-solutions/OpenGeodeWeb-Front into fix/pedantic_oxlint
2 parents 84cc219 + 85c37ac commit 20ba526

233 files changed

Lines changed: 7591 additions & 8922 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.eslintrc.cjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ module.exports = {
1212
"plugin:vuetify/recommended",
1313
"plugin:nuxt/recommended",
1414
],
15-
}
15+
};

.oxlintrc.json

Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -25,22 +25,7 @@
2525
"eslint/id-length": [
2626
"error",
2727
{
28-
"exceptions": [
29-
"x",
30-
"y",
31-
"z",
32-
"i",
33-
"j",
34-
"k",
35-
"r",
36-
"g",
37-
"b",
38-
"id",
39-
"ID",
40-
"fs",
41-
"os",
42-
"_"
43-
],
28+
"exceptions": ["x", "y", "z", "i", "j", "k", "r", "g", "b", "id", "ID", "fs", "os", "_"],
4429
"min": 3
4530
}
4631
],
@@ -78,6 +63,7 @@
7863
"max-lines": [
7964
"error",
8065
{
66+
"max": 310,
8167
"skipBlankLines": true,
8268
"skipComments": true
8369
}
@@ -121,12 +107,7 @@
121107
}
122108
},
123109
{
124-
"files": [
125-
"app/plugins/**",
126-
"node_scripts/**",
127-
"server/**",
128-
"*.config.js"
129-
],
110+
"files": ["app/plugins/**", "node_scripts/**", "server/**", "*.config.js"],
130111
"rules": {
131112
"import/no-default-export": "off"
132113
}

app/assets/geode_objects.js

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,28 @@
1-
import BRep from "@ogw_front/assets/img/geode_objects/BRep.svg"
2-
import CrossSection from "@ogw_front/assets/img/geode_objects/CrossSection.svg"
3-
import EdgedCurve2D from "@ogw_front/assets/img/geode_objects/EdgedCurve2D.svg"
4-
import EdgedCurve3D from "@ogw_front/assets/img/geode_objects/EdgedCurve3D.svg"
5-
import Graph from "@ogw_front/assets/img/geode_objects/Graph.svg"
6-
import HybridSolid3D from "@ogw_front/assets/img/geode_objects/HybridSolid3D.svg"
7-
import ImplicitCrossSection from "@ogw_front/assets/img/geode_objects/ImplicitCrossSection.svg"
8-
import ImplicitStructuralModel from "@ogw_front/assets/img/geode_objects/ImplicitStructuralModel.svg"
9-
import LightRegularGrid2D from "@ogw_front/assets/img/geode_objects/LightRegularGrid2D.svg"
10-
import LightRegularGrid3D from "@ogw_front/assets/img/geode_objects/LightRegularGrid3D.svg"
11-
import PointSet2D from "@ogw_front/assets/img/geode_objects/PointSet2D.svg"
12-
import PointSet3D from "@ogw_front/assets/img/geode_objects/PointSet3D.svg"
13-
import PolygonalSurface2D from "@ogw_front/assets/img/geode_objects/PolygonalSurface2D.svg"
14-
import PolygonalSurface3D from "@ogw_front/assets/img/geode_objects/PolygonalSurface3D.svg"
15-
import PolyhedralSolid3D from "@ogw_front/assets/img/geode_objects/PolyhedralSolid3D.svg"
16-
import RasterImage2D from "@ogw_front/assets/img/geode_objects/RasterImage2D.svg"
17-
import RasterImage3D from "@ogw_front/assets/img/geode_objects/RasterImage3D.svg"
18-
import RegularGrid2D from "@ogw_front/assets/img/geode_objects/RegularGrid2D.svg"
19-
import RegularGrid3D from "@ogw_front/assets/img/geode_objects/RegularGrid3D.svg"
20-
import Section from "@ogw_front/assets/img/geode_objects/Section.svg"
21-
import StructuralModel from "@ogw_front/assets/img/geode_objects/StructuralModel.svg"
22-
import TetrahedralSolid3D from "@ogw_front/assets/img/geode_objects/TetrahedralSolid3D.svg"
23-
import TriangulatedSurface2D from "@ogw_front/assets/img/geode_objects/TriangulatedSurface2D.svg"
24-
import TriangulatedSurface3D from "@ogw_front/assets/img/geode_objects/TriangulatedSurface3D.svg"
25-
import VertexSet from "@ogw_front/assets/img/geode_objects/VertexSet.svg"
1+
import BRep from "@ogw_front/assets/img/geode_objects/BRep.svg";
2+
import CrossSection from "@ogw_front/assets/img/geode_objects/CrossSection.svg";
3+
import EdgedCurve2D from "@ogw_front/assets/img/geode_objects/EdgedCurve2D.svg";
4+
import EdgedCurve3D from "@ogw_front/assets/img/geode_objects/EdgedCurve3D.svg";
5+
import Graph from "@ogw_front/assets/img/geode_objects/Graph.svg";
6+
import HybridSolid3D from "@ogw_front/assets/img/geode_objects/HybridSolid3D.svg";
7+
import ImplicitCrossSection from "@ogw_front/assets/img/geode_objects/ImplicitCrossSection.svg";
8+
import ImplicitStructuralModel from "@ogw_front/assets/img/geode_objects/ImplicitStructuralModel.svg";
9+
import LightRegularGrid2D from "@ogw_front/assets/img/geode_objects/LightRegularGrid2D.svg";
10+
import LightRegularGrid3D from "@ogw_front/assets/img/geode_objects/LightRegularGrid3D.svg";
11+
import PointSet2D from "@ogw_front/assets/img/geode_objects/PointSet2D.svg";
12+
import PointSet3D from "@ogw_front/assets/img/geode_objects/PointSet3D.svg";
13+
import PolygonalSurface2D from "@ogw_front/assets/img/geode_objects/PolygonalSurface2D.svg";
14+
import PolygonalSurface3D from "@ogw_front/assets/img/geode_objects/PolygonalSurface3D.svg";
15+
import PolyhedralSolid3D from "@ogw_front/assets/img/geode_objects/PolyhedralSolid3D.svg";
16+
import RasterImage2D from "@ogw_front/assets/img/geode_objects/RasterImage2D.svg";
17+
import RasterImage3D from "@ogw_front/assets/img/geode_objects/RasterImage3D.svg";
18+
import RegularGrid2D from "@ogw_front/assets/img/geode_objects/RegularGrid2D.svg";
19+
import RegularGrid3D from "@ogw_front/assets/img/geode_objects/RegularGrid3D.svg";
20+
import Section from "@ogw_front/assets/img/geode_objects/Section.svg";
21+
import StructuralModel from "@ogw_front/assets/img/geode_objects/StructuralModel.svg";
22+
import TetrahedralSolid3D from "@ogw_front/assets/img/geode_objects/TetrahedralSolid3D.svg";
23+
import TriangulatedSurface2D from "@ogw_front/assets/img/geode_objects/TriangulatedSurface2D.svg";
24+
import TriangulatedSurface3D from "@ogw_front/assets/img/geode_objects/TriangulatedSurface3D.svg";
25+
import VertexSet from "@ogw_front/assets/img/geode_objects/VertexSet.svg";
2626

2727
export const geode_objects = {
2828
BRep: {
@@ -125,4 +125,4 @@ export const geode_objects = {
125125
tooltip: "VertexSet",
126126
image: VertexSet,
127127
},
128-
}
128+
};

app/components/Carousel.vue

Lines changed: 62 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,54 @@
11
<script setup>
2-
// oxlint-disable-next-line import/no-unassigned-import
3-
import "vue3-carousel/dist/carousel.css"
4-
import { Carousel, Navigation, Pagination, Slide } from "vue3-carousel"
5-
import { useDisplay } from "vuetify"
2+
// oxlint-disable-next-line import/no-unassigned-import
3+
import "vue3-carousel/dist/carousel.css";
4+
import { Carousel, Navigation, Pagination, Slide } from "vue3-carousel";
5+
import { useDisplay } from "vuetify";
66
7-
const NB_ITEMS_TO_DISPLAY = 3
7+
const NB_ITEMS_TO_DISPLAY = 3;
88
9-
const { items } = defineProps({
10-
items: { type: Array, required: true },
11-
})
9+
const { items } = defineProps({
10+
items: { type: Array, required: true },
11+
});
1212
13-
const { name } = useDisplay()
14-
const nb_items_to_display = ref(NB_ITEMS_TO_DISPLAY)
15-
watch(
16-
name,
17-
(value) => {
18-
switch (value) {
19-
case "xs": {
20-
nb_items_to_display.value = 1
21-
break
22-
}
23-
case "sm": {
24-
nb_items_to_display.value = 2
25-
break
26-
}
27-
default: {
28-
nb_items_to_display.value = 3
29-
break
30-
}
13+
const { name } = useDisplay();
14+
const nb_items_to_display = ref(NB_ITEMS_TO_DISPLAY);
15+
watch(
16+
name,
17+
(value) => {
18+
switch (value) {
19+
case "xs": {
20+
nb_items_to_display.value = 1;
21+
break;
3122
}
32-
},
33-
{
34-
immediate: true,
35-
},
36-
)
23+
case "sm": {
24+
nb_items_to_display.value = 2;
25+
break;
26+
}
27+
default: {
28+
nb_items_to_display.value = 3;
29+
break;
30+
}
31+
}
32+
},
33+
{
34+
immediate: true,
35+
},
36+
);
3737
38-
const carrousel_settings = reactive({
39-
autoplay: 2000,
40-
itemsToShow: nb_items_to_display.value,
41-
itemsToScroll: 1,
42-
pauseAutoplayOnHover: true,
43-
transition: 1000,
44-
wrapAround: true,
45-
})
38+
const carrousel_settings = reactive({
39+
autoplay: 2000,
40+
itemsToShow: nb_items_to_display.value,
41+
itemsToScroll: 1,
42+
pauseAutoplayOnHover: true,
43+
transition: 1000,
44+
wrapAround: true,
45+
});
4646
</script>
4747

4848
<template>
4949
<ClientOnly>
5050
<Carousel :settings="carrousel_settings">
51-
<Slide
52-
v-for="(item, index) in items"
53-
:key="index"
54-
class="carousel__slide"
55-
>
51+
<Slide v-for="(item, index) in items" :key="index" class="carousel__slide">
5652
<a :href="item.url" target="_blank">
5753
<img :src="item.logo" class="carousel__item" />
5854
</a>
@@ -66,28 +62,28 @@
6662
</template>
6763

6864
<style scoped>
69-
.carousel__item {
70-
min-height: 200px;
71-
width: 100%;
72-
background-color: var(--vc-clr-white);
73-
color: var(--vc-clr-white);
74-
font-size: 20px;
75-
border-radius: 10px;
76-
display: flex;
77-
justify-content: center;
78-
align-items: center;
79-
}
65+
.carousel__item {
66+
min-height: 200px;
67+
width: 100%;
68+
background-color: var(--vc-clr-white);
69+
color: var(--vc-clr-white);
70+
font-size: 20px;
71+
border-radius: 10px;
72+
display: flex;
73+
justify-content: center;
74+
align-items: center;
75+
}
8076
81-
.carousel__slide {
82-
display: flex;
83-
padding: 15px;
84-
align-items: center;
85-
justify-content: center;
86-
}
77+
.carousel__slide {
78+
display: flex;
79+
padding: 15px;
80+
align-items: center;
81+
justify-content: center;
82+
}
8783
88-
.carousel__prev,
89-
.carousel__next {
90-
box-sizing: content-box;
91-
border: 5px solid red;
92-
}
84+
.carousel__prev,
85+
.carousel__next {
86+
box-sizing: content-box;
87+
border: 5px solid red;
88+
}
9389
</style>

app/components/CrsSelector.vue

Lines changed: 48 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -1,67 +1,63 @@
11
<script setup>
2-
import schemas from "@geode/opengeodeweb-back/opengeodeweb_back_schemas.json"
3-
import { useGeodeStore } from "@ogw_front/stores/geode"
2+
import schemas from "@geode/opengeodeweb-back/opengeodeweb_back_schemas.json";
3+
import { useGeodeStore } from "@ogw_front/stores/geode";
44
5-
const schema = schemas.opengeodeweb_back.geographic_coordinate_systems
5+
const schema = schemas.opengeodeweb_back.geographic_coordinate_systems;
66
7-
const emit = defineEmits([
8-
"update_values",
9-
"increment_step",
10-
"decrement_step",
11-
])
7+
const emit = defineEmits(["update_values", "increment_step", "decrement_step"]);
128
13-
const { geode_object_type, key_to_update } = defineProps({
14-
geode_object_type: { type: String, required: true },
15-
key_to_update: { type: String, required: true },
16-
})
9+
const { geode_object_type, key_to_update } = defineProps({
10+
geode_object_type: { type: String, required: true },
11+
key_to_update: { type: String, required: true },
12+
});
1713
18-
const search = ref("")
19-
const data_table_loading = ref(false)
20-
const crs_list = ref([])
21-
const selected_crs = ref([])
22-
const toggle_loading = useToggle(data_table_loading)
23-
const geodeStore = useGeodeStore()
14+
const search = ref("");
15+
const data_table_loading = ref(false);
16+
const crs_list = ref([]);
17+
const selected_crs = ref([]);
18+
const toggle_loading = useToggle(data_table_loading);
19+
const geodeStore = useGeodeStore();
2420
25-
watch(selected_crs, (new_value) => {
26-
const crs = get_selected_crs(new_value[0])
27-
const keys_values_object = {
28-
[key_to_update]: crs,
29-
}
30-
emit("update_values", keys_values_object)
31-
emit("increment_step")
32-
})
21+
watch(selected_crs, (new_value) => {
22+
const crs = get_selected_crs(new_value[0]);
23+
const keys_values_object = {
24+
[key_to_update]: crs,
25+
};
26+
emit("update_values", keys_values_object);
27+
emit("increment_step");
28+
});
3329
34-
function get_selected_crs(crs_code) {
35-
for (let i = 0; i <= crs_list.value.length; i += 1) {
36-
if (crs_list.value[i]["code"] === crs_code) {
37-
return crs_list.value[i]
38-
}
30+
function get_selected_crs(crs_code) {
31+
for (let i = 0; i <= crs_list.value.length; i += 1) {
32+
if (crs_list.value[i]["code"] === crs_code) {
33+
return crs_list.value[i];
3934
}
4035
}
36+
}
4137
42-
async function get_crs_table() {
43-
const params = { geode_object_type }
44-
toggle_loading()
45-
await geodeStore.request(schema, params, {
46-
response_function: (response) => {
47-
crs_list.value = response.crs_list
48-
},
49-
})
50-
toggle_loading()
51-
}
52-
53-
const headers = [
54-
{
55-
title: "Authority",
56-
align: "start",
57-
sortable: true,
58-
key: "authority",
38+
async function get_crs_table() {
39+
const params = { geode_object_type };
40+
toggle_loading();
41+
await geodeStore.request(schema, params, {
42+
response_function: (response) => {
43+
crs_list.value = response.crs_list;
5944
},
60-
{ title: "Code", align: "end", key: "code" },
61-
{ title: "Name", align: "end", key: "name" },
62-
]
45+
});
46+
toggle_loading();
47+
}
48+
49+
const headers = [
50+
{
51+
title: "Authority",
52+
align: "start",
53+
sortable: true,
54+
key: "authority",
55+
},
56+
{ title: "Code", align: "end", key: "code" },
57+
{ title: "Name", align: "end", key: "name" },
58+
];
6359
64-
await get_crs_table()
60+
await get_crs_table();
6561
</script>
6662

6763
<template>

0 commit comments

Comments
 (0)