diff --git a/index.html b/index.html
index b53548c..8ae1882 100644
--- a/index.html
+++ b/index.html
@@ -23,8 +23,6 @@
-
-
diff --git a/package-lock.json b/package-lock.json
index ee789fc..e0625ce 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -14,7 +14,6 @@
"animate.css": "^4.1.1",
"axios": "^1.15.0",
"bootstrap": "^5.3.8",
- "camelcase": "^9.0.0",
"ua-parser-js": "^2.0.9",
"vue": "^3.5.32",
"vue-router": "^5.0.4"
@@ -2304,18 +2303,6 @@
"node": ">= 0.4"
}
},
- "node_modules/camelcase": {
- "version": "9.0.0",
- "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-9.0.0.tgz",
- "integrity": "sha512-TO9xmyXTZ9HUHI8M1OnvExxYB0eYVS/1e5s7IDMTAoIcwUd+aNcFODs6Xk83mobk0velyHFQgA1yIrvYc6wclw==",
- "license": "MIT",
- "engines": {
- "node": ">=20"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
"node_modules/chokidar": {
"version": "4.0.3",
"resolved": "https://registry.npmjs.org/chokidar/-/chokidar-4.0.3.tgz",
diff --git a/package.json b/package.json
index 99a7e1b..62445f4 100644
--- a/package.json
+++ b/package.json
@@ -21,7 +21,6 @@
"animate.css": "^4.1.1",
"axios": "^1.15.0",
"bootstrap": "^5.3.8",
- "camelcase": "^9.0.0",
"ua-parser-js": "^2.0.9",
"vue": "^3.5.32",
"vue-router": "^5.0.4"
diff --git a/src/assets/styles.scss b/src/assets/css/styles.scss
similarity index 100%
rename from src/assets/styles.scss
rename to src/assets/css/styles.scss
diff --git a/src/components/FeedbackForm.vue b/src/components/FeedbackForm.vue
index 6a8e155..010cef1 100644
--- a/src/components/FeedbackForm.vue
+++ b/src/components/FeedbackForm.vue
@@ -8,8 +8,7 @@ import SupportLinks from '@/components/SupportLinks.vue'
const props = defineProps<{
app: App
- version: string
- id: string
+ params: Record
}>()
const textArea = ref(null)
@@ -76,8 +75,8 @@ async function processForm() {
console.log('ua:', ua)
const lines = [
- `**${props.app.name}** Uninstall, Version: \`${props.version}\``,
- `**ID**: \`${props.id}\``,
+ `**${props.app.name}** Uninstall, Version: \`${props.params['version']}\``,
+ `**ID**: \`${props.params['id']}\``,
`**Browser**: ${ua.browser.name} ${ua.browser.major} (${ua.engine.name} - ${ua.browser.version})`,
`**System**: ${ua.os.name} ${ua.os.version} (${ua.cpu.architecture})`,
`${getIcon(values['not-used'])} Not Used`,
@@ -89,18 +88,18 @@ async function processForm() {
const content = lines.join('\n')
console.debug('content.length:', content.length)
- console.debug('appConfig.relay_url:', appConfig.relay_url)
+ const relay_url = props.app.relay_url || appConfig.relay_url
+ console.debug('relay_url:', relay_url)
// await new Promise((resolve) => setTimeout(resolve, 2000))
- // const data = { content, username: props.app.name }
const data = {
content,
username: props.app.name,
...(props.app.icon?.endsWith('png') && { avatar_url: props.app.icon }),
}
console.debug('data:', data)
- const response = await axios.post(appConfig.relay_url, data)
+ const response = await axios.post(relay_url, data)
console.debug('response:', response)
console.debug('response.status:', response.status)
diff --git a/src/components/NotFound.vue b/src/components/NotFound.vue
index 2ee7575..d1b5056 100644
--- a/src/components/NotFound.vue
+++ b/src/components/NotFound.vue
@@ -1,10 +1,9 @@
@@ -16,7 +15,7 @@ defineProps<{
Application Not Found
- The application {{ name }} was not found.
+ The application {{ params['name'] }} was not found.
To find more applications visit the Website, or
@@ -25,13 +24,7 @@ defineProps<{
-
-
-
-
-
-
-
+
import { onMounted, onUnmounted } from 'vue'
-import camelCase from 'camelcase'
import { type App, apps } from '@/config/apps.ts'
import particlesConfig from '@/assets/particles.json'
import FeedbackForm from '@/components/FeedbackForm.vue'
@@ -8,31 +7,20 @@ import NotFound from '@/components/NotFound.vue'
const url = new URL(window.location.href)
console.log('url:', url)
-const name = url.searchParams.get('name') || ''
-console.log('name:', name)
-const version = url.searchParams.get('version') || 'unknown'
-console.log('version:', version)
-const id = url.searchParams.get('id') || 'unknown'
-console.log('id:', id)
-
-const key = camelCase(name)
-console.log('key:', key)
-
-const app: App = apps[key as keyof typeof apps]
+const params = Object.fromEntries(url.searchParams.entries())
+console.log('params:', params)
+const app: App = apps[params['name'] as keyof typeof apps]
console.log('app:', app)
-function processApp(app?: App) {
- if (!app) return console.log('processApp: no App')
- document.title = `${app.name} Feedback`
- const link = document.querySelector('link[rel*="icon"]')
- if (link && app.icon) link.href = app.icon
- console.debug('link.href:', link?.href)
-}
-
-onMounted(async () => {
+onMounted(() => {
document.body.style.background = "url('https://images.cssnr.com/aviation')"
document.body.style.backgroundSize = 'cover'
- processApp(app)
+ if (app) {
+ document.title = `${app.name} Feedback`
+ const link = document.querySelector('link[rel*="icon"]')
+ if (link && app.icon) link.href = app.icon
+ console.debug('link.href:', link?.href)
+ }
})
onUnmounted(() => {
document.body.style.background = ''
@@ -42,9 +30,8 @@ onUnmounted(() => {
-
-
-
+
+