diff --git a/package.json b/package.json index fc9e693..5861f04 100644 --- a/package.json +++ b/package.json @@ -15,8 +15,12 @@ "dependencies": { "@gouvfr/dsfr": "^1.11.2", "@gouvminint/vue-dsfr": "^5.14.2", + "@vueuse/components": "^10.9.0", + "@vueuse/core": "^10.9.0", "geoportal-extensions-openlayers": "./geoportal-extensions-openlayers-1.0.0-beta.32-52.tgz", - "ol": "8.2.0" + "ol": "8.2.0", + "vue": "^3.4.21", + "vue-router": "^4.3.0" }, "devDependencies": { "@antfu/eslint-config": "^2.11.6", @@ -37,6 +41,7 @@ "oh-vue-icons": "1.0.0-rc3", "pinia": "^2.1.7", "rimraf": "^5.0.5", + "sass": "^1.76.0", "typescript": "~5.4.0", "unplugin-auto-import": "^0.17.5", "unplugin-vue-components": "^0.27.0", diff --git a/src/App.vue b/src/App.vue index be23775..9a83a1e 100644 --- a/src/App.vue +++ b/src/App.vue @@ -5,8 +5,6 @@ import { useMatchMedia } from '@/composables/matchMedia'; import { useHeaderParams } from '@/composables/headerParams'; import { useFooterParams } from '@/composables/footerParams'; -import StoreDataLoading from './components/StoreDataLoading.vue'; - useScheme() import { useModel } from 'vue'; @@ -85,36 +83,54 @@ const navItems: DsfrNavigationProps['navItems'] = [ diff --git a/src/components.d.ts b/src/components.d.ts index 8a15dba..85be902 100644 --- a/src/components.d.ts +++ b/src/components.d.ts @@ -8,15 +8,29 @@ export {} declare module 'vue' { export interface GlobalComponents { Attributions: typeof import('./components/carte/control/Attributions.vue')['default'] + Carto: typeof import('./components/carte/Carto.vue')['default'] Control: typeof import('./components/carte/Control.vue')['default'] + DsfrCheckboxSet: typeof import('@gouvminint/vue-dsfr')['DsfrCheckboxSet'] DsfrFooter: typeof import('@gouvminint/vue-dsfr')['DsfrFooter'] DsfrHeader: typeof import('@gouvminint/vue-dsfr')['DsfrHeader'] DsfrModal: typeof import('@gouvminint/vue-dsfr')['DsfrModal'] DsfrNavigation: typeof import('@gouvminint/vue-dsfr')['DsfrNavigation'] DsfrRadioButtonSet: typeof import('@gouvminint/vue-dsfr')['DsfrRadioButtonSet'] + DsfrSideMenu: typeof import('@gouvminint/vue-dsfr')['DsfrSideMenu'] + Layer: typeof import('./components/carte/Layer/Layer.vue')['default'] + LayerManager: typeof import('./components/carte/Layer/LayerManager.vue')['default'] + LayerSwitcher: typeof import('./components/carte/control/LayerSwitcher.vue')['default'] + LeftMenu: typeof import('./components/menu/LeftMenu.vue')['default'] Map: typeof import('./components/carte/Map.vue')['default'] - MenuControl: typeof import('./components/carte/MenuControl.vue')['default'] + MenuCatalogue: typeof import('./components/menu/MenuCatalogue.vue')['default'] + MenuControl: typeof import('./components/menu/MenuControl.vue')['default'] + MenuLateralContent: typeof import('./components/menu/MenuLateralContent.vue')['default'] + MenuLateralNavButton: typeof import('./components/menu/MenuLateralNavButton.vue')['default'] + MenuLateralWrapper: typeof import('./components/menu/MenuLateralWrapper.vue')['default'] + MenuObject: typeof import('./components/menu/MenuObject.vue')['default'] OverviewMap: typeof import('./components/carte/control/OverviewMap.vue')['default'] + Patience: typeof import('./components/utils/Patience.vue')['default'] + RightMenu: typeof import('./components/menu/RightMenu.vue')['default'] RouterLink: typeof import('vue-router')['RouterLink'] RouterView: typeof import('vue-router')['RouterView'] ScaleLine: typeof import('./components/carte/control/ScaleLine.vue')['default'] diff --git a/src/components/StoreDataLoading.vue b/src/components/StoreDataLoading.vue index 39c35eb..70b236e 100644 --- a/src/components/StoreDataLoading.vue +++ b/src/components/StoreDataLoading.vue @@ -1,27 +1,23 @@ \ No newline at end of file diff --git a/src/components/carte/Carto.vue b/src/components/carte/Carto.vue new file mode 100644 index 0000000..9a14798 --- /dev/null +++ b/src/components/carte/Carto.vue @@ -0,0 +1,37 @@ + + + + + \ No newline at end of file diff --git a/src/components/carte/Control.vue b/src/components/carte/Control.vue index e9ce039..dc7c582 100644 --- a/src/components/carte/Control.vue +++ b/src/components/carte/Control.vue @@ -8,6 +8,7 @@ import ScaleLine from './control/ScaleLine.vue' import OverviewMap from './control/OverviewMap.vue' import Zoom from './control/Zoom.vue' import Attributions from './control/Attributions.vue' +import LayerSwitcher from './control/LayerSwitcher.vue' import { useControls } from '@/composables/controls' @@ -15,6 +16,16 @@ const props = defineProps({ controlOptions: Array }) +const layerSwitcherOptions = { + options : { + // FIXME + // position : "top-right", + collapsed : true, + panel : true, + counter : true + } +} + const scaleLineOptions = { units: 'metric', bar: false, @@ -31,6 +42,7 @@ const searchEngineOptions = { search: true }, searchOptions: { + addToMap : false, serviceOptions : { services: "WMTS,WMS,TMS" } @@ -55,6 +67,10 @@ const attributionsOptions = {}