From 859dc5963d54df2aaaaa8b1575e828ac65546a3e Mon Sep 17 00:00:00 2001 From: Will Freeman Date: Mon, 8 Dec 2025 22:34:05 -0700 Subject: [PATCH] use iconify --- webapp/package-lock.json | 49 +++++-- webapp/package.json | 3 +- webapp/src/App.vue | 93 +++++++------ .../src/components/ALPRVerificationDialog.vue | 22 ++- webapp/src/components/CommunityDatasets.vue | 71 ---------- webapp/src/components/DFCode.vue | 11 +- webapp/src/components/DFMapPopup.vue | 19 ++- .../src/components/DiscordWarningDialog.vue | 11 +- webapp/src/components/LeafletMap.vue | 21 ++- webapp/src/components/NewVisitor.vue | 11 +- webapp/src/components/OSMTagSelector.vue | 10 +- webapp/src/components/SimilarProjects.vue | 20 ++- webapp/src/components/layout/Footer.vue | 38 ++++-- webapp/src/main.ts | 1 - webapp/src/views/404.vue | 5 +- webapp/src/views/ContactView.vue | 21 +-- webapp/src/views/CouncilView.vue | 127 +++++++++++++----- webapp/src/views/DeflockApp.vue | 101 +++++++------- webapp/src/views/DeflockAppDocs.vue | 6 +- webapp/src/views/Identification.vue | 8 +- webapp/src/views/Landing.vue | 121 +++++++++-------- webapp/src/views/Map.vue | 15 ++- webapp/src/views/ReportChoose.vue | 11 +- webapp/src/views/ReportID.vue | 64 ++++++++- webapp/src/views/Store.vue | 69 +++++++--- webapp/src/views/WhatIsAnALPRView.vue | 7 +- 26 files changed, 583 insertions(+), 352 deletions(-) delete mode 100644 webapp/src/components/CommunityDatasets.vue diff --git a/webapp/package-lock.json b/webapp/package-lock.json index 484a356..423e47f 100644 --- a/webapp/package-lock.json +++ b/webapp/package-lock.json @@ -8,6 +8,8 @@ "name": "deflock", "version": "0.0.0", "dependencies": { + "@iconify-vue/ic": "^1.0.1", + "@iconify-vue/mdi": "^1.0.1", "@types/leaflet.markercluster": "^1.5.5", "@unhead/vue": "^1.11.14", "axios": "^1.7.7", @@ -19,7 +21,6 @@ "vuetify": "^3.7.2" }, "devDependencies": { - "@mdi/font": "^7.4.47", "@tsconfig/node20": "^20.1.4", "@types/leaflet": "^1.9.15", "@types/node": "^20.14.5", @@ -520,19 +521,51 @@ "node": ">=18" } }, + "node_modules/@iconify-vue/ic": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@iconify-vue/ic/-/ic-1.0.1.tgz", + "integrity": "sha512-Lbe8rstZhBx8LSgsaTFaui+rGZT1Rt0rXraKFivPsXB3E7orpIaucoMUEb8Wgy9l1KgGNm2bUVe2s5wC4qnr7A==", + "license": "Apache-2.0", + "dependencies": { + "@iconify/css-vue": "^1.0.0" + } + }, + "node_modules/@iconify-vue/mdi": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@iconify-vue/mdi/-/mdi-1.0.1.tgz", + "integrity": "sha512-A6RLb4YmyjH9xbTtX74YOco8p1QpGlBwcvIAZOCHvVyCoMIIcbvVOnMak3dhqoFaepjkqhiCnqoRn8yPu/FMhg==", + "license": "Apache-2.0", + "dependencies": { + "@iconify/css-vue": "^1.0.0" + } + }, + "node_modules/@iconify/css-vue": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@iconify/css-vue/-/css-vue-1.0.1.tgz", + "integrity": "sha512-rGkUIToUFUfP1zIYrY8A1pWUcadGxbMgAsUyI4PmK6BgxTO5Sajw1cbl6gqMi/D26S6LSjEG/Q+7O7gcLJthaA==", + "license": "MIT", + "dependencies": { + "@iconify/types": "^2.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/cyberalien" + }, + "peerDependencies": { + "vue": ">=3" + } + }, + "node_modules/@iconify/types": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@iconify/types/-/types-2.0.0.tgz", + "integrity": "sha512-+wluvCrRhXrhyOmRDJ3q8mux9JkKy5SJ/v8ol2tu4FVjyYvtEzkc/3pK15ET6RKg4b4w4BmTk1+gsCUhf21Ykg==", + "license": "MIT" + }, "node_modules/@jridgewell/sourcemap-codec": { "version": "1.5.5", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", "license": "MIT" }, - "node_modules/@mdi/font": { - "version": "7.4.47", - "resolved": "https://registry.npmjs.org/@mdi/font/-/font-7.4.47.tgz", - "integrity": "sha512-43MtGpd585SNzHZPcYowu/84Vz2a2g31TvPMTm9uTiCSWzaheQySUcSyUH/46fPnuPQWof2yd0pGBtzee/IQWw==", - "dev": true, - "license": "Apache-2.0" - }, "node_modules/@rolldown/pluginutils": { "version": "1.0.0-beta.50", "resolved": "https://registry.npmjs.org/@rolldown/pluginutils/-/pluginutils-1.0.0-beta.50.tgz", diff --git a/webapp/package.json b/webapp/package.json index 935a43c..50b6dca 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -12,6 +12,8 @@ "type-check": "vue-tsc --build --force" }, "dependencies": { + "@iconify-vue/ic": "^1.0.1", + "@iconify-vue/mdi": "^1.0.1", "@types/leaflet.markercluster": "^1.5.5", "@unhead/vue": "^1.11.14", "axios": "^1.7.7", @@ -23,7 +25,6 @@ "vuetify": "^3.7.2" }, "devDependencies": { - "@mdi/font": "^7.4.47", "@tsconfig/node20": "^20.1.4", "@types/leaflet": "^1.9.15", "@types/node": "^20.14.5", diff --git a/webapp/src/App.vue b/webapp/src/App.vue index 9ee1ccb..2ebda74 100644 --- a/webapp/src/App.vue +++ b/webapp/src/App.vue @@ -5,6 +5,22 @@ import { useTheme } from 'vuetify'; import DiscordWarningDialog from '@/components/DiscordWarningDialog.vue'; import { useDiscordIntercept } from '@/composables/useDiscordIntercept'; +// Icons +import HamburgerIcon from '@iconify-vue/mdi/menu'; +import HomeIcon from '@iconify-vue/mdi/home'; +import MapIcon from '@iconify-vue/mdi/map'; +import SchoolIcon from '@iconify-vue/mdi/school'; +import ShoppingIcon from '@iconify-vue/mdi/shopping-cart'; +import MapMarkerPlusIcon from '@iconify-vue/mdi/map-marker-plus'; +import FileDocumentIcon from '@iconify-vue/mdi/file-document'; +import AccountVoiceIcon from '@iconify-vue/mdi/account-voice'; +import EmailOutlineIcon from '@iconify-vue/mdi/email-outline'; +import GithubIcon from '@iconify-vue/mdi/github'; +import HeartIcon from '@iconify-vue/mdi/heart'; +import DiscordIcon from '@iconify-vue/ic/baseline-discord'; +import ChevronDownIcon from '@iconify-vue/mdi/chevron-down'; +import ThemeIcon from '@iconify-vue/mdi/theme-light-dark'; + const theme = useTheme(); const router = useRouter(); const isDark = computed(() => theme.name.value === 'dark'); @@ -34,23 +50,23 @@ onMounted(() => { }); const items = [ - { title: 'Home', icon: 'mdi-home', to: '/' }, - { title: 'Map', icon: 'mdi-map', to: '/map' }, - { title: 'Learn', icon: 'mdi-school', to: '/what-is-an-alpr' }, - { title: 'Store', icon: 'mdi-shopping', to: '/store' }, + { title: 'Home', icon: HomeIcon, to: '/' }, + { title: 'Map', icon: MapIcon, to: '/map' }, + { title: 'Learn', icon: SchoolIcon, to: '/what-is-an-alpr' }, + { title: 'Store', icon: ShoppingIcon, to: '/store' }, ] const contributeItems = [ - { title: 'Submit Cameras', icon: 'mdi-map-marker-plus', to: '/report' }, - { title: 'Public Records', icon: 'mdi-file-document', to: '/foia' }, - { title: 'City Council', icon: 'mdi-account-voice', to: '/council' }, + { title: 'Submit Cameras', icon: MapMarkerPlusIcon, to: '/report' }, + { title: 'Public Records', icon: FileDocumentIcon, to: '/foia' }, + { title: 'City Council', icon: AccountVoiceIcon, to: '/council' }, ] const metaItems = [ - { title: 'Discord', customIcon: '/icon-discord.svg', customIconDark: '/icon-discord-white.svg', customIconGrey: '/icon-discord-grey.svg', href: 'https://discord.gg/aV7v4R3sKT'}, - { title: 'Contact', icon: 'mdi-email-outline', to: '/contact' }, - { title: 'GitHub', icon: 'mdi-github', href: 'https://github.com/frillweeman/deflock'}, - { title: 'Donate', icon: 'mdi-heart', to: '/donate'}, + { title: 'Discord', icon: DiscordIcon, href: 'https://discord.gg/aV7v4R3sKT'}, + { title: 'Contact', icon: EmailOutlineIcon, to: '/contact' }, + { title: 'GitHub', icon: GithubIcon, href: 'https://github.com/frillweeman/deflock'}, + { title: 'Donate', icon: HeartIcon, to: '/donate'}, ]; const drawer = ref(false) @@ -79,6 +95,7 @@ watch(() => theme.global.name.value, (newTheme) => { @click.stop="drawer = !drawer" class="d-md-none" aria-label="Toggle Navigation Drawer" + :icon="HamburgerIcon" > @@ -114,7 +131,7 @@ watch(() => theme.global.name.value, (newTheme) => { Contribute @@ -128,7 +145,9 @@ watch(() => theme.global.name.value, (newTheme) => { link > {{ item.title }} @@ -141,7 +160,7 @@ watch(() => theme.global.name.value, (newTheme) => { Get Involved @@ -157,15 +176,9 @@ watch(() => theme.global.name.value, (newTheme) => { link > {{ item.title }} @@ -176,8 +189,10 @@ watch(() => theme.global.name.value, (newTheme) => { - - mdi-theme-light-dark + + + + @@ -196,7 +211,9 @@ watch(() => theme.global.name.value, (newTheme) => { :to="item.to" role="option" > - {{ item.icon }} + + + {{ item.title }} @@ -212,7 +229,9 @@ watch(() => theme.global.name.value, (newTheme) => { :to="item.to" role="option" > - {{ item.icon }} + + + {{ item.title }} @@ -230,16 +249,9 @@ watch(() => theme.global.name.value, (newTheme) => { :target="item.href ? '_blank' : undefined" role="option" > - {{ item.icon }} - + + + {{ item.title }} @@ -257,10 +269,3 @@ watch(() => theme.global.name.value, (newTheme) => { /> - - diff --git a/webapp/src/components/ALPRVerificationDialog.vue b/webapp/src/components/ALPRVerificationDialog.vue index 68a5bb3..1c21c5a 100644 --- a/webapp/src/components/ALPRVerificationDialog.vue +++ b/webapp/src/components/ALPRVerificationDialog.vue @@ -8,16 +8,22 @@ > - + + +

Are you sure it's an ALPR?

+ > + + + +
@@ -43,10 +49,14 @@ variant="elevated" size="large" to="/identify" - prepend-icon="mdi-image-search" class="mb-3" @click="dismiss" > + View ALPR Gallery
@@ -71,6 +81,10 @@ diff --git a/webapp/src/components/DFCode.vue b/webapp/src/components/DFCode.vue index ed11a9d..25e7658 100644 --- a/webapp/src/components/DFCode.vue +++ b/webapp/src/components/DFCode.vue @@ -1,7 +1,9 @@ @@ -23,6 +27,9 @@ - - - + \ No newline at end of file diff --git a/webapp/src/views/Map.vue b/webapp/src/views/Map.vue index 80b13e3..467f63f 100644 --- a/webapp/src/views/Map.vue +++ b/webapp/src/views/Map.vue @@ -18,7 +18,6 @@ :density="xs ? 'compact' : 'default'" class="map-search" ref="searchField" - prepend-inner-icon="mdi-magnify" placeholder="Search for a location" single-line variant="solo" @@ -27,9 +26,12 @@ v-model="searchInput" type="search" > + @@ -38,7 +40,9 @@
@@ -64,6 +68,11 @@ import 'leaflet/dist/leaflet.css' import LeafletMap from '@/components/LeafletMap.vue'; import NewVisitor from '@/components/NewVisitor.vue'; +// Icons +import MagnifyIcon from '@iconify-vue/mdi/magnify'; +import ChevronRightIcon from '@iconify-vue/mdi/chevron-right'; +import CrosshairsGpsIcon from '@iconify-vue/mdi/crosshairs-gps'; + const DEFAULT_ZOOM = 12; const zoom: Ref = ref(DEFAULT_ZOOM); diff --git a/webapp/src/views/ReportChoose.vue b/webapp/src/views/ReportChoose.vue index 731ac9a..5dd07f3 100644 --- a/webapp/src/views/ReportChoose.vue +++ b/webapp/src/views/ReportChoose.vue @@ -20,9 +20,11 @@ color="blue" variant="tonal" to="/identify" - prepend-icon="mdi-image-search" size="large" > + View ALPR Gallery @@ -60,7 +62,7 @@ size="large" > Download App - + @@ -98,7 +100,7 @@ size="large" > How to Edit - + @@ -111,6 +113,9 @@