1
0
Fork 0
mirror of https://github.com/voltbonn/profile-picture-generator.git synced 2024-12-21 23:35:05 +00:00

umami version 2

This commit is contained in:
thomasrosen 2023-05-18 13:49:26 +02:00
parent 279275edfa
commit 1f25cf4569
3 changed files with 6 additions and 6 deletions

View file

@ -28,7 +28,7 @@
<script src="./%PUBLIC_URL%/hammer.min.js"></script> <script src="./%PUBLIC_URL%/hammer.min.js"></script>
<title>Volt Social Media Frame Generator</title> <title>Volt Social Media Frame Generator</title>
<script async defer data-website-id="c1ba98a6-7dbd-4c30-8e1d-98765e711690" src="https://umami.qiekub.org/umami.js" data-domains="www.profile-volt.org"></script> <script async defer data-website-id="c1ba98a6-7dbd-4c30-8e1d-98765e711690" src="https://umami.volt.link/script.js"></script>
<!-- Test Umami Script: --> <!-- Test Umami Script: -->
<!-- <script async defer data-website-id="ca45b2b9-4604-4ed9-806c-3dd9c8827d0f" src="https://umami.qiekub.org/umami.js"></script> --> <!-- <script async defer data-website-id="ca45b2b9-4604-4ed9-806c-3dd9c8827d0f" src="https://umami.qiekub.org/umami.js"></script> -->
</head> </head>

View file

@ -72,7 +72,7 @@ function UmamiLink({ href, name, target, children, ...props }) {
const handleClick = useCallback(event => { const handleClick = useCallback(event => {
if (window.umami && name) { if (window.umami && name) {
window.umami.trackEvent('A: ' + name) // Log Anker / Link window.umami.track('A: ' + name) // Log Anker / Link
} }
// follow link // follow link
@ -292,9 +292,9 @@ function App({ getString, locales, currentLocale, onLanguageChange }) {
const hashtagName = hashtag.name || 'No-Hashtag' const hashtagName = hashtag.name || 'No-Hashtag'
if (window.umami) { if (window.umami) {
window.umami.trackEvent('F: ' + frameName) // Log Frame window.umami.track('F: ' + frameName) // Log Frame
window.umami.trackEvent('H: ' + hashtagName) // Log Hashtag window.umami.track('H: ' + hashtagName) // Log Hashtag
window.umami.trackEvent('C: ' + [frameName, hashtagName].join(' | ')) // Log Combined window.umami.track('C: ' + [frameName, hashtagName].join(' | ')) // Log Combined
} }
}) })

View file

@ -14,7 +14,7 @@ function AppLanguageWrapper() {
let systemLocales = navigator.languages let systemLocales = navigator.languages
if (window.umami && (!!systemLocales || Array.isArray(systemLocales))) { if (window.umami && (!!systemLocales || Array.isArray(systemLocales))) {
for (const locale of systemLocales) { for (const locale of systemLocales) {
window.umami.trackEvent('L: ' + locale) // Log Locale / Languages window.umami.track('L: ' + locale) // Log Locale / Languages
} }
} }
}, []) }, [])