diff --git a/src/App.vue b/src/App.vue index 7104f1d89452abe8f86971a0821bf69fe6ea9f26..88dc0326380b60ed429d46664d2fe2607c2f455a 100644 --- a/src/App.vue +++ b/src/App.vue @@ -1,13 +1,5 @@ <template> <div> - <script - type="application/javascript" - :src=" - baseUrl + - 'resources/leaflet-control-geocoder-1.13.0/Control.Geocoder.js' - " - /> - <AppHeader /> <div id="content"> @@ -60,6 +52,14 @@ </div> </template> +<script + type="application/javascript" + :src=" + baseUrl + + 'resources/leaflet-control-geocoder-1.13.0/Control.Geocoder.js' + " +/> + <script> import { mapMutations, mapState } from 'vuex'; diff --git a/src/assets/js/map-util.js b/src/assets/js/map-util.js index d731abea211fbffb94bded1dbc2bfbda934e202f..a3df8ff8cfc59b7bea9893590f3e0caa1cd1eb47 100644 --- a/src/assets/js/map-util.js +++ b/src/assets/js/map-util.js @@ -532,7 +532,7 @@ const mapUtil = { if (featureTypes && feature.properties) { // => VectorTile featureType = feature.properties.feature_type_id ? featureTypes.find((x) => x.slug.split('-')[0] === '' + feature.properties.feature_type_id) : - featureTypes.find((fType) => fType.slug === feature.properties.feature_type); //* geojson + featureTypes.find((fType) => fType.slug === feature.properties.feature_type.slug); //* geojson status = statusList.find((x) => x.value === feature.properties.status.value).name; if (featureType) { featureTypeUrl = `/geocontrib/projet/${projectSlug}/type-signalement/${featureType.slug}/`; diff --git a/src/components/Account/UserProjectsList.vue b/src/components/Account/UserProjectsList.vue index 2abee6850e74a47d4b928e4420a5eb686b8016d9..4909e5b74004d8a0b51b73dc1bf8d1e49ab6235f 100644 --- a/src/components/Account/UserProjectsList.vue +++ b/src/components/Account/UserProjectsList.vue @@ -24,6 +24,7 @@ <img v-if="project.thumbnail" class="ui small image" + alt="Thumbnail projet" :src=" project.thumbnail.includes('default') ? require('@/assets/img/default.png') @@ -66,19 +67,30 @@ class="right floated" :data-tooltip="`Projet créé le ${project.created_on}`" > - <i class="calendar icon" /> {{ project.created_on }} + <i + class="calendar icon" + aria-hidden="true" + /> {{ project.created_on }} </span> <span data-tooltip="Membres"> - {{ project.nb_contributors }} <i class="user icon" /> + {{ project.nb_contributors }} + <i + class="user icon" + aria-hidden="true" + /> </span> <span data-tooltip="Signalements publiés"> - {{ project.nb_published_features }} <i + {{ project.nb_published_features }} + <i class="map marker icon" + aria-hidden="true" /> </span> <span data-tooltip="Commentaires"> - {{ project.nb_published_features_comments }} <i + {{ project.nb_published_features_comments }} + <i class="comment icon" + aria-hidden="true" /> </span> </div> diff --git a/src/components/AppHeader.vue b/src/components/AppHeader.vue index a07dcda35a68f3b2859850d91855d64a2133f3e5..d9e5b935653801f0fe07a8f08e80356a037542f8 100644 --- a/src/components/AppHeader.vue +++ b/src/components/AppHeader.vue @@ -9,6 +9,7 @@ > <img class="ui mini right spaced image" + alt="Logo de l'application" :src="logo" > <span class="desktop"> diff --git a/src/components/Dropdown.vue b/src/components/Dropdown.vue index 9c02886cb1dcc25050cfc17bee1c2e6fb93d3f57..2e9ce2602330d50e6753bb874c8df3efa18c7e22 100644 --- a/src/components/Dropdown.vue +++ b/src/components/Dropdown.vue @@ -34,6 +34,7 @@ </div> <i :class="['dropdown icon', { clear: clearable && selected }]" + aria-hidden="true" @click="clear" /> <div :class="['menu', { 'visible transition': isOpen }]"> diff --git a/src/components/Feature/Detail/FeatureComments.vue b/src/components/Feature/Detail/FeatureComments.vue index e2158b98cb87818d337e9ca36841f68fa95a48f3..248ce5868c0a12f68e31638082b1aeea5f973c54 100644 --- a/src/components/Feature/Detail/FeatureComments.vue +++ b/src/components/Feature/Detail/FeatureComments.vue @@ -112,7 +112,10 @@ class="ui icon button" for="attachment_file" > - <i class="paperclip icon" /> + <i + class="paperclip icon" + aria-hidden="true" + /> <span class="label">{{ comment_form.attachment_file.value ? comment_form.attachment_file.value diff --git a/src/components/Feature/Detail/FeatureTable.vue b/src/components/Feature/Detail/FeatureTable.vue index 5e60af316be3b421dd06a84ea368be6fd700cd46..368ecb5452ad4f6151c918d72b36b78fb3e07af7 100644 --- a/src/components/Feature/Detail/FeatureTable.vue +++ b/src/components/Feature/Detail/FeatureTable.vue @@ -1,53 +1,74 @@ <template> <div> - <table class="ui very basic table"> + <table + class="ui very basic table" + aria-describedby="Table des données du signalement" + > <tbody> <div v-for="(field, index) in currentFeature.feature_data" :key="'field' + index" > <tr v-if="field"> + <th scope="row"> + <strong>{{ field.label }}</strong> + </th> <td> - <b>{{ field.label }}</b> - </td> - <td> - <b> + <strong> <i v-if="field.field_type === 'boolean'" :class="[ 'icon', field.value ? 'olive check' : 'grey times', ]" + aria-hidden="true" /> <span v-else> {{ field.value }} </span> - </b> + </strong> </td> </tr> </div> <tr> - <td>Auteur</td> + <th + scope="row" + > + Auteur + </th> <td>{{ currentFeature.display_creator }}</td> </tr> <tr> - <td>Statut</td> + <th + scope="row" + > + Statut + </th> <td> <i v-if="currentFeature.status" :class="['icon', statusIcon]" + aria-hidden="true" /> {{ statusLabel }} </td> </tr> <tr> - <td>Date de création</td> + <th + scope="row" + > + Date de création + </th> <td v-if="currentFeature.created_on"> {{ currentFeature.created_on | formatDate }} </td> </tr> <tr> - <td>Date de dernière modification</td> + <th + scope="row" + > + Date de dernière modification + </th> <td v-if="currentFeature.updated_on"> {{ currentFeature.updated_on | formatDate }} </td> @@ -56,7 +77,10 @@ </table> <h3>Liaison entre signalements</h3> - <table class="ui very basic table"> + <table + class="ui very basic table" + aria-describedby="Table des signalements lié à ce signalement" + > <tbody> <tr v-for="(link, index) in linked_features" diff --git a/src/components/Feature/FeatureAttachmentForm.vue b/src/components/Feature/FeatureAttachmentForm.vue index 808e8606d33cd3e44665e275c0217c34bf8e1bc6..6b2e27b26be25f6300fddfa6e2c0c0d75dce3782 100644 --- a/src/components/Feature/FeatureAttachmentForm.vue +++ b/src/components/Feature/FeatureAttachmentForm.vue @@ -8,7 +8,10 @@ type="button" @click="removeAttachmentFormset(form.dataKey)" > - <i class="ui times icon" /> + <i + class="ui times icon" + aria-hidden="true" + /> </button> </h4> <!-- {{ form.errors }} --> diff --git a/src/components/Feature/FeatureEditModal.vue b/src/components/Feature/FeatureEditModal.vue index 3ed47f5d719634a7f84923114cfd04f63f894222..4b75b07d902239ad80b683933c7ac3c8660f26a8 100644 --- a/src/components/Feature/FeatureEditModal.vue +++ b/src/components/Feature/FeatureEditModal.vue @@ -1,7 +1,10 @@ <template> <div class="ui mini modal"> - <i class="close icon" /> + <i + class="close icon" + aria-hidden="true" + /> <div class="content"> <h3>Importer une image géoréférencée</h3> <form diff --git a/src/components/Feature/FeatureListMassToggle.vue b/src/components/Feature/FeatureListMassToggle.vue index 8483baa507f964c9db68496497aeb3921f23e043..ff4b1da6ff6616933727a93e6595b10238a7bfd8 100644 --- a/src/components/Feature/FeatureListMassToggle.vue +++ b/src/components/Feature/FeatureListMassToggle.vue @@ -4,14 +4,25 @@ :data-tooltip="`Passer en mode ${massMode === 'modify' ? 'suppression':'édition'}`" @click="switchMode" > - <div><i :class="['icon pencil', {disabled: massMode !== 'modify'}]" /></div> + <div> + <i + :class="['icon pencil', {disabled: massMode !== 'modify'}]" + aria-hidden="true" + /> + </div> <span class="grey">| </span> - <div><i :class="['icon trash', {disabled: massMode !== 'delete'}]" /></div> + <div> + <i + :class="['icon trash', {disabled: massMode !== 'delete'}]" + aria-hidden="true" + /> + </div> </div> </template> <script> import { mapMutations, mapState } from 'vuex'; + export default { name: 'FeatureListMassToggle', diff --git a/src/components/FeatureType/FeatureTypeCustomForm.vue b/src/components/FeatureType/FeatureTypeCustomForm.vue index 02dfcf5ed31ad7d580addbef24762e7a99701599..f059e6eacadfe6c768a80da1baf4f5222949abcc 100644 --- a/src/components/FeatureType/FeatureTypeCustomForm.vue +++ b/src/components/FeatureType/FeatureTypeCustomForm.vue @@ -7,7 +7,10 @@ type="button" @click="removeCustomForm()" > - <i class="ui times icon" /> + <i + class="ui times icon" + aria-hidden="true" + /> </button> </h4> <div class="visible-fields"> diff --git a/src/components/FeatureType/SymbologySelector.vue b/src/components/FeatureType/SymbologySelector.vue index 064ad7aea7066e902ebeebe51084e7747f4a71b6..29f419340b0416730f9d08a41c611d28750296c8 100644 --- a/src/components/FeatureType/SymbologySelector.vue +++ b/src/components/FeatureType/SymbologySelector.vue @@ -48,6 +48,7 @@ <i :class="`fa-${icon}`" class="icon alt fas" + aria-hidden="true" /> </div> </div> diff --git a/src/components/ImportTask.vue b/src/components/ImportTask.vue index d0b82745658dc09951e9d46ef6333484feaeaeeb..426267860328f5e71af2130c2cb1bbafad93a320 100644 --- a/src/components/ImportTask.vue +++ b/src/components/ImportTask.vue @@ -1,6 +1,9 @@ <template> <div id="table-imports"> - <table class="ui collapsing celled table"> + <table + class="ui collapsing celled table" + aria-describedby="Tableau des import en cours ou terminés" + > <thead> <tr> <th @@ -40,18 +43,22 @@ <i v-if="importFile.status === 'processing'" class="orange hourglass half icon" + aria-hidden="true" /> <i v-else-if="importFile.status === 'finished'" class="green check circle outline icon" + aria-hidden="true" /> <i v-else-if="importFile.status === 'failed'" class="red x icon" + aria-hidden="true" /> <i v-else class="red ban icon" + aria-hidden="true" /> </span> <span @@ -60,6 +67,7 @@ > <i :class="['orange icon', ready && !reloading ? 'sync' : 'hourglass half rotate']" + aria-hidden="true" @click="fetchImports()" /> </span> diff --git a/src/components/Project/Basemaps/BasemapListItem.vue b/src/components/Project/Basemaps/BasemapListItem.vue index 73a0aee131cfb94e525775d79d8d642d8088740d..4869af1152ee2bbbb3a963e7ddd0ad61a0ce9d2f 100644 --- a/src/components/Project/Basemaps/BasemapListItem.vue +++ b/src/components/Project/Basemaps/BasemapListItem.vue @@ -73,7 +73,7 @@ </template> <script> -import { mapState } from 'vuex'; +import { mapMutations } from 'vuex'; import Sortable from 'sortablejs'; import ProjectMappingContextLayer from '@/components/Project/Basemaps/ProjectMappingContextLayer.vue'; @@ -94,16 +94,11 @@ export default { data() { return { - sortableElement: null + sortable: null }; }, computed: { - ...mapState('map', [ - 'UPDATE_BASEMAP', - 'DELETE_BASEMAP', - 'REPLACE_BASEMAP_LAYERS' - ]), maxLayersCount: function () { return this.basemap.layers.reduce((acc, curr) => { if (curr.dataKey > acc) { @@ -127,6 +122,11 @@ export default { }, methods: { + ...mapMutations('map', [ + 'UPDATE_BASEMAP', + 'DELETE_BASEMAP', + 'REPLACE_BASEMAP_LAYERS' + ]), deleteBasemap() { this.DELETE_BASEMAP(this.basemap.id); }, @@ -196,7 +196,7 @@ export default { } } //* update the store - this.$store.commit('map/UPDATE_BASEMAP', { + this.UPDATE_BASEMAP({ layers: movedLayers, id: this.basemap.id, title: this.basemap.title, @@ -205,7 +205,7 @@ export default { }, initSortable() { - this.sortableElement = new Sortable(document.getElementById(`list-${this.basemap.id}`), { + this.sortable = new Sortable(document.getElementById(`list-${this.basemap.id}`), { animation: 150, handle: '.layer-handle-sort', // The element that is active to drag ghostClass: 'blue-background-class', diff --git a/src/components/Project/Basemaps/ProjectMappingContextLayer.vue b/src/components/Project/Basemaps/ProjectMappingContextLayer.vue index c1a37355c902c3e3a4b95459c444152b498b0177..93f720837dc1663695487d211cd3658e17344b74 100644 --- a/src/components/Project/Basemaps/ProjectMappingContextLayer.vue +++ b/src/components/Project/Basemaps/ProjectMappingContextLayer.vue @@ -12,7 +12,11 @@ for="form.layer.id_for_label" class="layer-handle-sort" > - <i class="th icon" />couche + <i + class="th icon" + aria-hidden="true" + /> + couche </label> <Dropdown :options="availableLayerOptions" diff --git a/src/components/Project/Detail/ProjectFeatureTypes.vue b/src/components/Project/Detail/ProjectFeatureTypes.vue index a86e846975acaff6e58498b86430a0dcdb435bb5..e43713749b5497d3a124fb6fb6dfd2cde83f5bc8 100644 --- a/src/components/Project/Detail/ProjectFeatureTypes.vue +++ b/src/components/Project/Detail/ProjectFeatureTypes.vue @@ -37,16 +37,19 @@ v-if="type.geom_type === 'point'" class="list-image-type" src="@/assets/img/marker.png" + alt="Géométrie point" > <img v-if="type.geom_type === 'linestring'" class="list-image-type" src="@/assets/img/line.png" + alt="Géométrie ligne" > <img v-if="type.geom_type === 'polygon'" class="list-image-type" src="@/assets/img/polygon.png" + alt="Géométrie polygone" > {{ type.title }} </router-link> @@ -136,7 +139,10 @@ data-variation="mini" @click="toggleDeleteFeatureType(type)" > - <i class="inverted grey trash alternate icon" /> + <i + class="inverted grey trash alternate icon" + aria-hidden="true" + /> </a> <router-link v-if=" @@ -162,7 +168,10 @@ data-position="top center" data-variation="mini" > - <i class="inverted grey paint brush alternate icon" /> + <i + class="inverted grey paint brush alternate icon" + aria-hidden="true" + /> </router-link> <router-link v-if=" @@ -216,7 +225,11 @@ }" class="ui compact basic button" > - <i class="ui plus icon" />Créer un nouveau type de signalement + <i + class="ui plus icon" + aria-hidden="true" + /> + Créer un nouveau type de signalement </router-link> </div> <div class="nouveau-type-signalement"> @@ -273,7 +286,10 @@ button-align-left " > - <i class="ui plus icon" /> + <i + class="ui plus icon" + aria-hidden="true" + /> <label class="ui" for="csv_file" @@ -345,7 +361,10 @@ class="ui fluid teal icon button" @click="toNewCsvFeatureType" > - <i class="upload icon" /> Lancer l'import avec le fichier + <i + class="upload icon" + aria-hidden="true" + /> Lancer l'import avec le fichier {{ csvFileToImport.name }} </button> </div> @@ -355,6 +374,7 @@ > <i class="close icon" + aria-hidden="true" @click="csvError = null" /> {{ csvError }} diff --git a/src/components/Project/Detail/ProjectHeader.vue b/src/components/Project/Detail/ProjectHeader.vue index f88484e91693904d8a5671d4925bcd092ce1792e..41f9a283045b76fae2b5a02efbcb95ce7111e87c 100644 --- a/src/components/Project/Detail/ProjectHeader.vue +++ b/src/components/Project/Detail/ProjectHeader.vue @@ -4,6 +4,7 @@ <div class="three wide middle aligned column"> <img class="ui small spaced image" + alt="Thumbnail du projet" :src=" project.thumbnail.includes('default') ? require('@/assets/img/default.png') @@ -140,7 +141,10 @@ class="ui fluid labeled teal icon button" @click="sendOfflineFeatures" > - <i class="upload icon" /> + <i + class="upload icon" + aria-hidden="true" + /> Envoyer au serveur </button> </div> diff --git a/src/components/Project/Detail/ProjectModal.vue b/src/components/Project/Detail/ProjectModal.vue index 69de49375be36830ef51101cb7ff5962a42b4935..16502bbce370af89023207e8be62bc0e29da2c9f 100644 --- a/src/components/Project/Detail/ProjectModal.vue +++ b/src/components/Project/Detail/ProjectModal.vue @@ -12,10 +12,14 @@ > <i class="close icon" + aria-hidden="true" @click="CLOSE_PROJECT_MODAL" /> <div class="ui icon header"> - <i :class="[projectModalType === 'subscribe' ? 'envelope' : 'trash', 'icon']" /> + <i + :class="[projectModalType === 'subscribe' ? 'envelope' : 'trash', 'icon']" + aria-hidden="true" + /> {{ projectModalType === 'subscribe' ? 'Notifications' : 'Suppression' }} du {{ diff --git a/src/components/Project/Detail/ProjectParameters.vue b/src/components/Project/Detail/ProjectParameters.vue index a1c57bc7ffe904f80104ae97328b6b9bafdebf6a..ed7d3a4268419c826391a216beb29ac5f21512f8 100644 --- a/src/components/Project/Detail/ProjectParameters.vue +++ b/src/components/Project/Detail/ProjectParameters.vue @@ -7,7 +7,10 @@ <div class="card"> <div class="center aligned content"> <h4 class="ui center aligned icon header"> - <i class="disabled grey archive icon" /> + <i + class="disabled grey archive icon" + aria-hidden="true" + /> <div class="content"> Délai avant archivage automatique </div> @@ -20,7 +23,10 @@ <div class="card"> <div class="content"> <h4 class="ui center aligned icon header"> - <i class="disabled grey trash alternate icon" /> + <i + class="disabled grey trash alternate icon" + aria-hidden="true" + /> <div class="content"> Délai avant suppression automatique </div> @@ -33,7 +39,10 @@ <div class="card"> <div class="content"> <h4 class="ui center aligned icon header"> - <i class="disabled grey eye icon" /> + <i + class="disabled grey eye icon" + aria-hidden="true" + /> <div class="content"> Visibilité des signalements publiés </div> @@ -46,7 +55,10 @@ <div class="card"> <div class="content"> <h4 class="ui center aligned icon header"> - <i class="disabled grey eye icon" /> + <i + class="disabled grey eye icon" + aria-hidden="true" + /> <div class="content"> Visibilité des signalements archivés </div> @@ -59,7 +71,10 @@ <div class="card"> <div class="content"> <h4 class="ui center aligned icon header"> - <i class="disabled grey cogs icon" /> + <i + class="disabled grey cogs icon" + aria-hidden="true" + /> <div class="content"> Modération </div> diff --git a/src/components/Project/FeaturesListAndMap/FeatureListTable.vue b/src/components/Project/FeaturesListAndMap/FeatureListTable.vue index b6929e3190503d0b38d853c82ed3c14b5f503193..6308c014521da5f6c44f1b4988b613cdd8e40010 100644 --- a/src/components/Project/FeaturesListAndMap/FeatureListTable.vue +++ b/src/components/Project/FeaturesListAndMap/FeatureListTable.vue @@ -10,6 +10,7 @@ <table id="table-features" class="ui compact table unstackable dataTable" + aria-describedby="Liste des signalements du projet" > <thead> <tr> @@ -35,6 +36,7 @@ up: isSortedDesc('status'), }" class="icon sort" + aria-hidden="true" /> </div> </th> @@ -53,6 +55,7 @@ up: isSortedDesc('feature_type'), }" class="icon sort" + aria-hidden="true" /> </div> </th> @@ -71,6 +74,7 @@ up: isSortedDesc('title'), }" class="icon sort" + aria-hidden="true" /> </div> </th> @@ -89,6 +93,7 @@ up: isSortedDesc('updated_on'), }" class="icon sort" + aria-hidden="true" /> </div> </th> @@ -108,6 +113,7 @@ up: isSortedDesc('display_creator'), }" class="icon sort" + aria-hidden="true" /> </div> </th> @@ -127,6 +133,7 @@ up: isSortedDesc('display_last_editor'), }" class="icon sort" + aria-hidden="true" /> </div> </th> @@ -159,25 +166,37 @@ v-if="feature.status === 'archived'" data-tooltip="Archivé" > - <i class="grey archive icon" /> + <i + class="grey archive icon" + aria-hidden="true" + /> </div> <div v-else-if="feature.status === 'pending'" data-tooltip="En attente de publication" > - <i class="teal hourglass outline icon" /> + <i + class="teal hourglass outline icon" + aria-hidden="true" + /> </div> <div v-else-if="feature.status === 'published'" data-tooltip="Publié" > - <i class="olive check icon" /> + <i + class="olive check icon" + aria-hidden="true" + /> </div> <div v-else-if="feature.status === 'draft'" data-tooltip="Brouillon" > - <i class="orange pencil alternate icon" /> + <i + class="orange pencil alternate icon" + aria-hidden="true" + /> </div> </td> <td class="dt-center"> diff --git a/src/components/Projects/ProjectsListItem.vue b/src/components/Projects/ProjectsListItem.vue index 178ad9edf5199a417812c0ab9d635775797537b6..983186fe97b8adbe9363b8071e465896aad1ddeb 100644 --- a/src/components/Projects/ProjectsListItem.vue +++ b/src/components/Projects/ProjectsListItem.vue @@ -7,6 +7,7 @@ ? require('@/assets/img/default.png') : DJANGO_BASE_URL + project.thumbnail + refreshId() " + alt="Thumbnail du projet" > </div> <div class="middle aligned content"> @@ -41,19 +42,30 @@ </div> <div class="meta"> <span class="right floated"> - <i class="calendar icon" /> {{ project.created_on }} + <i + class="calendar icon" + aria-hidden="true" + /> {{ project.created_on }} </span> <span data-tooltip="Membres"> - {{ project.nb_contributors }} <i class="user icon" /> + {{ project.nb_contributors }} + <i + class="user icon" + aria-hidden="true" + /> </span> <span data-tooltip="Signalements publiés"> - {{ project.nb_published_features }} <i + {{ project.nb_published_features }} + <i class="map marker icon" + aria-hidden="true" /> </span> <span data-tooltip="Commentaires"> - {{ project.nb_published_features_comments }} <i + {{ project.nb_published_features_comments }} + <i class="comment icon" + aria-hidden="true" /> </span> </div> diff --git a/src/components/Projects/ProjectsMenu.vue b/src/components/Projects/ProjectsMenu.vue index c70a951675ec7f17cfc499f8f376ee55947360de..8801c51768548d98fce0e6bf6430d07ffec187e7 100644 --- a/src/components/Projects/ProjectsMenu.vue +++ b/src/components/Projects/ProjectsMenu.vue @@ -7,6 +7,7 @@ FILTRES <i class="ui icon caret right down" + aria-hidden="true" /> </div> </div> diff --git a/src/components/SidebarLayers.vue b/src/components/SidebarLayers.vue index e8bd5fcbbe60d1fa7293075ae3c87fdf20e119e2..b1fa0daebf3336353e21157d4e7dc8a5dd2f51c8 100644 --- a/src/components/SidebarLayers.vue +++ b/src/components/SidebarLayers.vue @@ -69,7 +69,7 @@ v-if="isQueryable(basemap)" :id="`queryable-layers-selector-${basemap.id}`" > - <b>Couche requêtable</b> + <strong>Couche requêtable</strong> <Dropdown :options="getQueryableLayers(basemap)" :selected="selectedQueryLayer" @@ -90,7 +90,11 @@ :data-id="layer.id" > <p class="layer-handle-sort"> - <i class="th icon" />{{ layer.title }} + <i + class="th icon" + aria-hidden="true" + /> + {{ layer.title }} </p> <label>Opacité <span>(%)</span></label> <div class="range-container"> @@ -131,6 +135,7 @@ export default { activeBasemap: null, baseMaps: [], expanded: false, + sortable: null }; }, @@ -273,17 +278,16 @@ export default { initSortable() { this.baseMaps.forEach((basemap) => { - const element=document.getElementById(`list-${basemap.id}`); - if(element) { - new Sortable(element, { + const element = document.getElementById(`list-${basemap.id}`); + if (element) { + this. sortable = new Sortable(element, { animation: 150, handle: '.layer-handle-sort', // The element that is active to drag ghostClass: 'blue-background-class', dragClass: 'white-opacity-background-class', onEnd: this.onlayerMove.bind(this), }); - } - else{ + } else { console.error(`list-${basemap.id} not found in dom`); } diff --git a/src/views/Catalog.vue b/src/views/Catalog.vue index 947e826a0bee4f107dbac58f4855e01273eb4a21..431df6f3f8b65586e2e3c9b17675ae60b368e6ef 100644 --- a/src/views/Catalog.vue +++ b/src/views/Catalog.vue @@ -89,7 +89,10 @@ class="ui fluid teal icon button" @click="launchImport" > - <i class="upload icon" /> Lancer l'import avec le fichier + <i + class="upload icon" + aria-hidden="true" + /> Lancer l'import avec le fichier <span v-if="selectedResource"> {{ selectedResource.resource }} </span> diff --git a/src/views/Feature/FeatureDetail.vue b/src/views/Feature/FeatureDetail.vue index 76e2928f09325035de1297082d2ae8b442d96408..66e6654cf9f8d586b75cad180c6a19165d6eb478 100644 --- a/src/views/Feature/FeatureDetail.vue +++ b/src/views/Feature/FeatureDetail.vue @@ -50,10 +50,14 @@ > <i class="close icon" + aria-hidden="true" @click="isCanceling = false" /> <div class="ui icon header"> - <i class="trash alternate icon" /> + <i + class="trash alternate icon" + aria-hidden="true" + /> Supprimer le signalement </div> <div class="actions"> diff --git a/src/views/Feature/FeatureEdit.vue b/src/views/Feature/FeatureEdit.vue index fc9839d8c0328883373458002a0f96744bcad2dc..8d587541e7769f029280e007887b1a2f4c624b59 100644 --- a/src/views/Feature/FeatureEdit.vue +++ b/src/views/Feature/FeatureEdit.vue @@ -82,7 +82,10 @@ class="ui compact button" @click="toggleGeoRefModal" > - <i class="file image icon" />Importer une image géoréférencée + <i + class="file image icon" + aria-hidden="true" + />Importer une image géoréférencée </button> Vous pouvez utiliser une image géoréférencée pour localiser le signalement. @@ -98,6 +101,7 @@ > <i class="close icon" + aria-hidden="true" @click="toggleGeoRefModal" /> <div class="content"> @@ -117,7 +121,10 @@ class="ui icon button" for="image_file" > - <i class="file icon" /> + <i + class="file icon" + aria-hidden="true" + /> <span class="label">{{ geoRefFileLabel }}</span> </label> <input @@ -149,7 +156,10 @@ ]" @click="georeferencement" > - <i class="plus icon" /> + <i + class="plus icon" + aria-hidden="true" + /> Importer </button> </form> diff --git a/src/views/Feature/FeatureOffline.vue b/src/views/Feature/FeatureOffline.vue index 8bbe1718e7dff467c10f594dcf6921b1ee310d07..cf9488441b5c0aea4bdcfd428ce54e43dc103774 100644 --- a/src/views/Feature/FeatureOffline.vue +++ b/src/views/Feature/FeatureOffline.vue @@ -16,7 +16,10 @@ }" class="ui positive left labeled icon button margin-1" > - <i class="arrow left icon" />Retour au projet + <i + class="arrow left icon" + aria-hidden="true" + />Retour au projet </router-link> </div> </template> diff --git a/src/views/FeatureType/FeatureTypeDetail.vue b/src/views/FeatureType/FeatureTypeDetail.vue index 75e0ca8a3bc6e9d61c6a1d8a04c517ad178a6a1e..dde405e65be329b071ca7621c3ffd8bc5c8438b7 100644 --- a/src/views/FeatureType/FeatureTypeDetail.vue +++ b/src/views/FeatureType/FeatureTypeDetail.vue @@ -11,16 +11,19 @@ <img v-if="structure.geom_type === 'point'" class="ui medium image" + alt="Géométrie point" src="@/assets/img/marker.png" > <img v-if="structure.geom_type === 'linestring'" class="ui medium image" + alt="Géométrie ligne" src="@/assets/img/line.png" > <img v-if="structure.geom_type === 'polygon'" class="ui medium image" + alt="Géométrie polygone" src="@/assets/img/polygon.png" > {{ structure.title }} @@ -85,7 +88,10 @@ class="ui icon button ellipsis" for="json_file" > - <i class="file icon" /> + <i + class="file icon" + aria-hidden="true" + /> <span class="label">{{ geojsonFileToImport.name }}</span> </label> <input @@ -103,7 +109,10 @@ class="ui icon button ellipsis" for="csv_file" > - <i class="file icon" /> + <i + class="file icon" + aria-hidden="true" + /> <span class="label">{{ csvFileToImport.name }}</span> </label> <input @@ -318,25 +327,37 @@ v-if="feature.status === 'archived'" data-tooltip="Archivé" > - <i class="grey archive icon" /> + <i + class="grey archive icon" + aria-hidden="true" + /> </span> <span v-else-if="feature.status === 'pending'" data-tooltip="En attente de publication" > - <i class="teal hourglass outline icon" /> + <i + class="teal hourglass outline icon" + aria-hidden="true" + /> </span> <span v-else-if="feature.status === 'published'" data-tooltip="Publié" > - <i class="olive check icon" /> + <i + class="olive check icon" + aria-hidden="true" + /> </span> <span v-else-if="feature.status === 'draft'" data-tooltip="Brouillon" > - <i class="orange pencil alternate icon" /> + <i + class="orange pencil alternate icon" + aria-hidden="true" + /> </span> <router-link :to="{ diff --git a/src/views/FeatureType/FeatureTypeEdit.vue b/src/views/FeatureType/FeatureTypeEdit.vue index 66209641c87bb86747b7c347c8b9bdcf3e98c4de..b3ea954e778703854da5c00f3ebc324e60c0924a 100644 --- a/src/views/FeatureType/FeatureTypeEdit.vue +++ b/src/views/FeatureType/FeatureTypeEdit.vue @@ -11,7 +11,13 @@ v-if="error" class="ui negative message" > - <p><i class="cross icon" /> {{ error }}</p> + <p> + <i + class="cross icon" + aria-hidden="true" + /> + {{ error }} + </p> </div> </div> <div class="fourteen wide column"> @@ -237,7 +243,11 @@ class="ui compact basic button" @click="addCustomForm" > - <i class="ui plus icon" />Ajouter un champ personnalisé + <i + class="ui plus icon" + aria-hidden="true" + /> + Ajouter un champ personnalisé </button> <div class="ui divider" /> @@ -246,7 +256,10 @@ type="button" @click="sendFeatureType" > - <i class="white save icon" /> + <i + class="white save icon" + aria-hidden="true" + /> {{ action === "create" ? "Créer" : "Sauvegarder" }} le type de signalement </button> @@ -256,7 +269,10 @@ type="button" @click="postFeatureTypeThenFeatures" > - <i class="white save icon" /> + <i + class="white save icon" + aria-hidden="true" + /> Créer et importer le(s) signalement(s) du geojson </button> </div> diff --git a/src/views/FeatureType/FeatureTypeSymbology.vue b/src/views/FeatureType/FeatureTypeSymbology.vue index 39d0eb96f97bd192f366ad604a8b560ff7b9f21b..35cfa0345eaf2b429afd3b173bfe82416cf0047a 100644 --- a/src/views/FeatureType/FeatureTypeSymbology.vue +++ b/src/views/FeatureType/FeatureTypeSymbology.vue @@ -14,7 +14,13 @@ v-if="error" class="ui negative message" > - <p><i class="close icon" /> {{ error }}</p> + <p> + <i + class="close icon" + aria-hidden="true" + /> + {{ error }} + </p> </div> <div v-if="success" @@ -22,6 +28,7 @@ > <i class="close icon" + aria-hidden="true" @click="success = null" /> <p>{{ success }}</p> diff --git a/src/views/Project/ProjectMembers.vue b/src/views/Project/ProjectMembers.vue index 27986572f40e25ccf67d773c93ad86f6efe38d98..c1e7d7bccca01c02c2f8978f88c532f7d9d49e21 100644 --- a/src/views/Project/ProjectMembers.vue +++ b/src/views/Project/ProjectMembers.vue @@ -62,7 +62,7 @@ <table class="ui red table"> <thead> <tr> - <th> + <th scope="col"> Membre <i :class="{ @@ -73,7 +73,7 @@ @click="changeSort('member')" /> </th> - <th> + <th scope="col"> Niveau d'autorisation <i :class="{