adminforth 2.1.0-next.16 → 2.1.0-next.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/servers/express.js +1 -1
- package/dist/spa/package-lock.json +13 -0
- package/dist/spa/package.json +1 -0
- package/dist/spa/src/afcl/CountryFlag.vue +26 -0
- package/dist/spa/src/afcl/index.ts +2 -0
- package/dist/spa/src/components/Filters.vue +1 -1
- package/dist/spa/src/renderers/CountryFlag.vue +2 -20
- package/dist/spa/src/views/ResourceParent.vue +1 -1
- package/package.json +1 -1
package/dist/servers/express.js
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
"name": "spa",
|
|
9
9
|
"version": "0.0.0",
|
|
10
10
|
"dependencies": {
|
|
11
|
+
"@iconify-prerendered/vue-flag": "^0.28.1748584105",
|
|
11
12
|
"@iconify-prerendered/vue-flowbite": "^0.23.1714023977",
|
|
12
13
|
"@unhead/vue": "^1.9.12",
|
|
13
14
|
"@vueuse/core": "^10.10.0",
|
|
@@ -610,6 +611,18 @@
|
|
|
610
611
|
"integrity": "sha512-93zYdMES/c1D69yZiKDBj0V24vqNzB/koF26KPaagAfd3P/4gUlh3Dys5ogAK+Exi9QyzlD8x/08Zt7wIKcDcA==",
|
|
611
612
|
"dev": true
|
|
612
613
|
},
|
|
614
|
+
"node_modules/@iconify-prerendered/vue-flag": {
|
|
615
|
+
"version": "0.28.1748584105",
|
|
616
|
+
"resolved": "https://registry.npmjs.org/@iconify-prerendered/vue-flag/-/vue-flag-0.28.1748584105.tgz",
|
|
617
|
+
"integrity": "sha512-7wJ9UsXJ1h10S4Y/qZsnK3pFkwh6R0542PTv8SykD+80M9i9Iw7xUI9H65Qbcvmk0oNSuHTb/aoFXxqMpuEfnA==",
|
|
618
|
+
"license": "MIT",
|
|
619
|
+
"funding": {
|
|
620
|
+
"url": "https://www.buymeacoffee.com/kozack/"
|
|
621
|
+
},
|
|
622
|
+
"peerDependencies": {
|
|
623
|
+
"vue": "^3.0.0"
|
|
624
|
+
}
|
|
625
|
+
},
|
|
613
626
|
"node_modules/@iconify-prerendered/vue-flowbite": {
|
|
614
627
|
"version": "0.23.1714023977",
|
|
615
628
|
"resolved": "https://registry.npmjs.org/@iconify-prerendered/vue-flowbite/-/vue-flowbite-0.23.1714023977.tgz",
|
package/dist/spa/package.json
CHANGED
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
"i18n:extract": "echo '{}' > i18n-empty.json && vue-i18n-extract report --vueFiles './src/**/*.?(js|vue)' --output ./i18n-messages.json --languageFiles 'i18n-empty.json' --add"
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
|
+
"@iconify-prerendered/vue-flag": "^0.28.1748584105",
|
|
16
17
|
"@iconify-prerendered/vue-flowbite": "^0.23.1714023977",
|
|
17
18
|
"@unhead/vue": "^1.9.12",
|
|
18
19
|
"@vueuse/core": "^10.10.0",
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<component v-if="getFlagComponent(countryCode)" class="flag-icon rounded-sm" :is="getFlagComponent(countryCode)" />
|
|
3
|
+
<span v-else-if="countryCode">{{ countryCode }}</span>
|
|
4
|
+
</template>
|
|
5
|
+
|
|
6
|
+
<script setup lang="ts">
|
|
7
|
+
import * as FlagIcons from '@iconify-prerendered/vue-flag';
|
|
8
|
+
|
|
9
|
+
defineProps(['countryCode']);
|
|
10
|
+
|
|
11
|
+
const getFlagComponent = (countryCode: string) => {
|
|
12
|
+
if (!countryCode) return null;
|
|
13
|
+
|
|
14
|
+
const normalizedCode = countryCode.charAt(0).toUpperCase() + countryCode.slice(1).toLowerCase();
|
|
15
|
+
const iconName = `Icon${normalizedCode}4x3`; // 4:3 aspect ratio flags
|
|
16
|
+
return FlagIcons[iconName as keyof typeof FlagIcons] || null;
|
|
17
|
+
};
|
|
18
|
+
</script>
|
|
19
|
+
|
|
20
|
+
<style scoped>
|
|
21
|
+
.flag-icon {
|
|
22
|
+
box-shadow: inset -0.3px -0.3px 0.3px 0px rgba(0 0 0 / 0.2),
|
|
23
|
+
inset 0.3px 0.3px 0.3px 0px rgba(255 255 255 / 0.2),
|
|
24
|
+
0px 0px 3px #00000030;
|
|
25
|
+
}
|
|
26
|
+
</style>
|
|
@@ -18,5 +18,7 @@ export { default as Spinner } from './Spinner.vue';
|
|
|
18
18
|
export { default as Skeleton } from './Skeleton.vue';
|
|
19
19
|
export { default as Dialog } from './Dialog.vue';
|
|
20
20
|
export { default as MixedChart } from './MixedChart.vue';
|
|
21
|
+
export { default as CountryFlag } from './CountryFlag.vue';
|
|
22
|
+
|
|
21
23
|
|
|
22
24
|
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
:class="show ? 'top-0 transform-none' : ''"
|
|
8
8
|
tabindex="-1" aria-labelledby="drawer-navigation-label"
|
|
9
|
-
:style="{ height: `calc(
|
|
9
|
+
:style="{ height: `calc(100dvh ` }"
|
|
10
10
|
>
|
|
11
11
|
<h5 id="drawer-navigation-label" class="text-base font-semibold text-gray-500 uppercase dark:text-gray-400">
|
|
12
12
|
{{ $t('Filters') }}
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<Tooltip>
|
|
3
3
|
<span class="flex items-center">
|
|
4
|
-
<
|
|
5
|
-
:class="{[`fi-${countryIsoLow}`]: true, 'flag-icon': countryName}"
|
|
6
|
-
></span>
|
|
4
|
+
<CountryFlag class="w-[1.6rem] h-[1.2rem]" :countryCode="countryIsoLow" />
|
|
7
5
|
<span v-if="meta.showCountryName" class="ms-2">{{ countryName }}</span>
|
|
8
6
|
</span>
|
|
9
7
|
|
|
@@ -16,10 +14,10 @@
|
|
|
16
14
|
<script setup>
|
|
17
15
|
|
|
18
16
|
import { computed, ref, onMounted } from 'vue';
|
|
19
|
-
import 'flag-icons/css/flag-icons.min.css';
|
|
20
17
|
import isoCountries from 'i18n-iso-countries';
|
|
21
18
|
import enLocal from 'i18n-iso-countries/langs/en.json';
|
|
22
19
|
import Tooltip from '@/afcl/Tooltip.vue';
|
|
20
|
+
import CountryFlag from '@/afcl/CountryFlag.vue';
|
|
23
21
|
|
|
24
22
|
isoCountries.registerLocale(enLocal);
|
|
25
23
|
|
|
@@ -47,19 +45,3 @@ const countryName = computed(() => {
|
|
|
47
45
|
});
|
|
48
46
|
|
|
49
47
|
</script>
|
|
50
|
-
|
|
51
|
-
<style scoped lang="scss">
|
|
52
|
-
|
|
53
|
-
.flag-icon {
|
|
54
|
-
width: 1.6rem;
|
|
55
|
-
height: 1.2rem;
|
|
56
|
-
flex-shrink: 0;
|
|
57
|
-
|
|
58
|
-
// border radius for background
|
|
59
|
-
border-radius: 2px;
|
|
60
|
-
box-shadow: inset -0.3px -0.3px 0.3px 0px rgba(0 0 0 / 0.2),
|
|
61
|
-
inset 0.3px 0.3px 0.3px 0px rgba(255 255 255 / 0.2),
|
|
62
|
-
0px 0px 3px #00000030;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
</style>
|