Merge pull request #44 from ProjectSegfault/contact-form-fixes

contact form fixes
This commit is contained in:
Odyssey346 2022-07-29 13:18:59 +02:00 committed by GitHub
commit 1db1a4681e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 213 additions and 201 deletions

View File

@ -28,7 +28,7 @@
"tslib": "^2.4.0",
"typescript": "^4.7.4",
"unplugin-icons": "^0.14.7",
"vite": "^3.0.3"
"vite": "^3.0.4"
},
"type": "module"
}

View File

@ -16,13 +16,13 @@ specifiers:
tslib: ^2.4.0
typescript: ^4.7.4
unplugin-icons: ^0.14.7
vite: ^3.0.3
vite: ^3.0.4
devDependencies:
'@iconify-json/fa6-solid': 1.1.6
'@iconify-json/simple-icons': 1.1.20
'@sveltejs/adapter-static': 1.0.0-next.38
'@sveltejs/kit': 1.0.0-next.396_svelte@3.49.0+vite@3.0.3
'@sveltejs/kit': 1.0.0-next.396_svelte@3.49.0+vite@3.0.4
mdsvex: 0.10.6_svelte@3.49.0
prettier: 2.7.1
prettier-plugin-svelte: 2.7.0_o3ioganyptcsrh6x4hnxvjkpqi
@ -33,8 +33,8 @@ devDependencies:
svelte-seo: 1.4.1_typescript@4.7.4
tslib: 2.4.0
typescript: 4.7.4
unplugin-icons: 0.14.7_vite@3.0.3
vite: 3.0.3
unplugin-icons: 0.14.7_vite@3.0.4
vite: 3.0.4
packages:
@ -129,7 +129,7 @@ packages:
tiny-glob: 0.2.9
dev: true
/@sveltejs/kit/1.0.0-next.396_svelte@3.49.0+vite@3.0.3:
/@sveltejs/kit/1.0.0-next.396_svelte@3.49.0+vite@3.0.4:
resolution: {integrity: sha512-bKFpuzp9QxPkOIOEIeNeedvxEMORNqBPxUmoJXDP/Se7MrSfcxYiamjBcKrG+bgGNWmV39nD3EvUox+CXno/Ig==}
engines: {node: '>=16.9'}
hasBin: true
@ -137,17 +137,17 @@ packages:
svelte: ^3.44.0
vite: ^3.0.0
dependencies:
'@sveltejs/vite-plugin-svelte': 1.0.1_svelte@3.49.0+vite@3.0.3
'@sveltejs/vite-plugin-svelte': 1.0.1_svelte@3.49.0+vite@3.0.4
chokidar: 3.5.3
sade: 1.8.1
svelte: 3.49.0
vite: 3.0.3
vite: 3.0.4
transitivePeerDependencies:
- diff-match-patch
- supports-color
dev: true
/@sveltejs/vite-plugin-svelte/1.0.1_svelte@3.49.0+vite@3.0.3:
/@sveltejs/vite-plugin-svelte/1.0.1_svelte@3.49.0+vite@3.0.4:
resolution: {integrity: sha512-PorCgUounn0VXcpeJu+hOweZODKmGuLHsLomwqSj+p26IwjjGffmYQfVHtiTWq+NqaUuuHWWG7vPge6UFw4Aeg==}
engines: {node: ^14.18.0 || >= 16}
peerDependencies:
@ -165,13 +165,13 @@ packages:
magic-string: 0.26.2
svelte: 3.49.0
svelte-hmr: 0.14.12_svelte@3.49.0
vite: 3.0.3
vite: 3.0.4
transitivePeerDependencies:
- supports-color
dev: true
/@types/node/18.6.1:
resolution: {integrity: sha512-z+2vB6yDt1fNwKOeGbckpmirO+VBDuQqecXkgeIqDlaOtmKn6hPR/viQ8cxCfqLU4fTlvM3+YjM367TukWdxpg==}
/@types/node/18.6.2:
resolution: {integrity: sha512-KcfkBq9H4PI6Vpu5B/KoPeuVDAbmi+2mDBqGPGUgoL7yXQtcWGu2vJWmmRkneWK3Rh0nIAX192Aa87AqKHYChQ==}
dev: true
/@types/pug/2.0.6:
@ -181,7 +181,7 @@ packages:
/@types/sass/1.43.1:
resolution: {integrity: sha512-BPdoIt1lfJ6B7rw35ncdwBZrAssjcwzI5LByIrYs+tpXlj/CAkuVdRsgZDdP4lq5EjyWzwxZCqAoFyHKFwp32g==}
dependencies:
'@types/node': 18.6.1
'@types/node': 18.6.2
dev: true
/@types/unist/2.0.6:
@ -288,8 +288,8 @@ packages:
resolution: {integrity: sha512-SOp9Phqvqn7jtEUxPWdWfWoLmyt2VaJ6MpvP9Comy1MceMXqE6bxvaTu4iaxpYYPzhny28Lc+M87/c2cPK6lDg==}
dev: true
/esbuild-android-64/0.14.50:
resolution: {integrity: sha512-H7iUEm7gUJHzidsBlFPGF6FTExazcgXL/46xxLo6i6bMtPim6ZmXyTccS8yOMpy6HAC6dPZ/JCQqrkkin69n6Q==}
/esbuild-android-64/0.14.51:
resolution: {integrity: sha512-6FOuKTHnC86dtrKDmdSj2CkcKF8PnqkaIXqvgydqfJmqBazCPdw+relrMlhGjkvVdiiGV70rpdnyFmA65ekBCQ==}
engines: {node: '>=12'}
cpu: [x64]
os: [android]
@ -297,8 +297,8 @@ packages:
dev: true
optional: true
/esbuild-android-arm64/0.14.50:
resolution: {integrity: sha512-NFaoqEwa+OYfoYVpQWDMdKII7wZZkAjtJFo1WdnBeCYlYikvUhTnf2aPwPu5qEAw/ie1NYK0yn3cafwP+kP+OQ==}
/esbuild-android-arm64/0.14.51:
resolution: {integrity: sha512-vBtp//5VVkZWmYYvHsqBRCMMi1MzKuMIn5XDScmnykMTu9+TD9v0NMEDqQxvtFToeYmojdo5UCV2vzMQWJcJ4A==}
engines: {node: '>=12'}
cpu: [arm64]
os: [android]
@ -306,8 +306,8 @@ packages:
dev: true
optional: true
/esbuild-darwin-64/0.14.50:
resolution: {integrity: sha512-gDQsCvGnZiJv9cfdO48QqxkRV8oKAXgR2CGp7TdIpccwFdJMHf8hyIJhMW/05b/HJjET/26Us27Jx91BFfEVSA==}
/esbuild-darwin-64/0.14.51:
resolution: {integrity: sha512-YFmXPIOvuagDcwCejMRtCDjgPfnDu+bNeh5FU2Ryi68ADDVlWEpbtpAbrtf/lvFTWPexbgyKgzppNgsmLPr8PA==}
engines: {node: '>=12'}
cpu: [x64]
os: [darwin]
@ -315,8 +315,8 @@ packages:
dev: true
optional: true
/esbuild-darwin-arm64/0.14.50:
resolution: {integrity: sha512-36nNs5OjKIb/Q50Sgp8+rYW/PqirRiFN0NFc9hEvgPzNJxeJedktXwzfJSln4EcRFRh5Vz4IlqFRScp+aiBBzA==}
/esbuild-darwin-arm64/0.14.51:
resolution: {integrity: sha512-juYD0QnSKwAMfzwKdIF6YbueXzS6N7y4GXPDeDkApz/1RzlT42mvX9jgNmyOlWKN7YzQAYbcUEJmZJYQGdf2ow==}
engines: {node: '>=12'}
cpu: [arm64]
os: [darwin]
@ -324,8 +324,8 @@ packages:
dev: true
optional: true
/esbuild-freebsd-64/0.14.50:
resolution: {integrity: sha512-/1pHHCUem8e/R86/uR+4v5diI2CtBdiWKiqGuPa9b/0x3Nwdh5AOH7lj+8823C6uX1e0ufwkSLkS+aFZiBCWxA==}
/esbuild-freebsd-64/0.14.51:
resolution: {integrity: sha512-cLEI/aXjb6vo5O2Y8rvVSQ7smgLldwYY5xMxqh/dQGfWO+R1NJOFsiax3IS4Ng300SVp7Gz3czxT6d6qf2cw0g==}
engines: {node: '>=12'}
cpu: [x64]
os: [freebsd]
@ -333,8 +333,8 @@ packages:
dev: true
optional: true
/esbuild-freebsd-arm64/0.14.50:
resolution: {integrity: sha512-iKwUVMQztnPZe5pUYHdMkRc9aSpvoV1mkuHlCoPtxZA3V+Kg/ptpzkcSY+fKd0kuom+l6Rc93k0UPVkP7xoqrw==}
/esbuild-freebsd-arm64/0.14.51:
resolution: {integrity: sha512-TcWVw/rCL2F+jUgRkgLa3qltd5gzKjIMGhkVybkjk6PJadYInPtgtUBp1/hG+mxyigaT7ib+od1Xb84b+L+1Mg==}
engines: {node: '>=12'}
cpu: [arm64]
os: [freebsd]
@ -342,8 +342,8 @@ packages:
dev: true
optional: true
/esbuild-linux-32/0.14.50:
resolution: {integrity: sha512-sWUwvf3uz7dFOpLzYuih+WQ7dRycrBWHCdoXJ4I4XdMxEHCECd8b7a9N9u7FzT6XR2gHPk9EzvchQUtiEMRwqw==}
/esbuild-linux-32/0.14.51:
resolution: {integrity: sha512-RFqpyC5ChyWrjx8Xj2K0EC1aN0A37H6OJfmUXIASEqJoHcntuV3j2Efr9RNmUhMfNE6yEj2VpYuDteZLGDMr0w==}
engines: {node: '>=12'}
cpu: [ia32]
os: [linux]
@ -351,8 +351,8 @@ packages:
dev: true
optional: true
/esbuild-linux-64/0.14.50:
resolution: {integrity: sha512-u0PQxPhaeI629t4Y3EEcQ0wmWG+tC/LpP2K7yDFvwuPq0jSQ8SIN+ARNYfRjGW15O2we3XJvklbGV0wRuUCPig==}
/esbuild-linux-64/0.14.51:
resolution: {integrity: sha512-dxjhrqo5i7Rq6DXwz5v+MEHVs9VNFItJmHBe1CxROWNf4miOGoQhqSG8StStbDkQ1Mtobg6ng+4fwByOhoQoeA==}
engines: {node: '>=12'}
cpu: [x64]
os: [linux]
@ -360,8 +360,8 @@ packages:
dev: true
optional: true
/esbuild-linux-arm/0.14.50:
resolution: {integrity: sha512-VALZq13bhmFJYFE/mLEb+9A0w5vo8z+YDVOWeaf9vOTrSC31RohRIwtxXBnVJ7YKLYfEMzcgFYf+OFln3Y0cWg==}
/esbuild-linux-arm/0.14.51:
resolution: {integrity: sha512-LsJynDxYF6Neg7ZC7748yweCDD+N8ByCv22/7IAZglIEniEkqdF4HCaa49JNDLw1UQGlYuhOB8ZT/MmcSWzcWg==}
engines: {node: '>=12'}
cpu: [arm]
os: [linux]
@ -369,8 +369,8 @@ packages:
dev: true
optional: true
/esbuild-linux-arm64/0.14.50:
resolution: {integrity: sha512-ZyfoNgsTftD7Rp5S7La5auomKdNeB3Ck+kSKXC4pp96VnHyYGjHHXWIlcbH8i+efRn9brszo1/Thl1qn8RqmhQ==}
/esbuild-linux-arm64/0.14.51:
resolution: {integrity: sha512-D9rFxGutoqQX3xJPxqd6o+kvYKeIbM0ifW2y0bgKk5HPgQQOo2k9/2Vpto3ybGYaFPCE5qTGtqQta9PoP6ZEzw==}
engines: {node: '>=12'}
cpu: [arm64]
os: [linux]
@ -378,8 +378,8 @@ packages:
dev: true
optional: true
/esbuild-linux-mips64le/0.14.50:
resolution: {integrity: sha512-ygo31Vxn/WrmjKCHkBoutOlFG5yM9J2UhzHb0oWD9O61dGg+Hzjz9hjf5cmM7FBhAzdpOdEWHIrVOg2YAi6rTw==}
/esbuild-linux-mips64le/0.14.51:
resolution: {integrity: sha512-vS54wQjy4IinLSlb5EIlLoln8buh1yDgliP4CuEHumrPk4PvvP4kTRIG4SzMXm6t19N0rIfT4bNdAxzJLg2k6A==}
engines: {node: '>=12'}
cpu: [mips64el]
os: [linux]
@ -387,8 +387,8 @@ packages:
dev: true
optional: true
/esbuild-linux-ppc64le/0.14.50:
resolution: {integrity: sha512-xWCKU5UaiTUT6Wz/O7GKP9KWdfbsb7vhfgQzRfX4ahh5NZV4ozZ4+SdzYG8WxetsLy84UzLX3Pi++xpVn1OkFQ==}
/esbuild-linux-ppc64le/0.14.51:
resolution: {integrity: sha512-xcdd62Y3VfGoyphNP/aIV9LP+RzFw5M5Z7ja+zdpQHHvokJM7d0rlDRMN+iSSwvUymQkqZO+G/xjb4/75du8BQ==}
engines: {node: '>=12'}
cpu: [ppc64]
os: [linux]
@ -396,8 +396,8 @@ packages:
dev: true
optional: true
/esbuild-linux-riscv64/0.14.50:
resolution: {integrity: sha512-0+dsneSEihZTopoO9B6Z6K4j3uI7EdxBP7YSF5rTwUgCID+wHD3vM1gGT0m+pjCW+NOacU9kH/WE9N686FHAJg==}
/esbuild-linux-riscv64/0.14.51:
resolution: {integrity: sha512-syXHGak9wkAnFz0gMmRBoy44JV0rp4kVCEA36P5MCeZcxFq8+fllBC2t6sKI23w3qd8Vwo9pTADCgjTSf3L3rA==}
engines: {node: '>=12'}
cpu: [riscv64]
os: [linux]
@ -405,8 +405,8 @@ packages:
dev: true
optional: true
/esbuild-linux-s390x/0.14.50:
resolution: {integrity: sha512-tVjqcu8o0P9H4StwbIhL1sQYm5mWATlodKB6dpEZFkcyTI8kfIGWiWcrGmkNGH2i1kBUOsdlBafPxR3nzp3TDA==}
/esbuild-linux-s390x/0.14.51:
resolution: {integrity: sha512-kFAJY3dv+Wq8o28K/C7xkZk/X34rgTwhknSsElIqoEo8armCOjMJ6NsMxm48KaWY2h2RUYGtQmr+RGuUPKBhyw==}
engines: {node: '>=12'}
cpu: [s390x]
os: [linux]
@ -414,8 +414,8 @@ packages:
dev: true
optional: true
/esbuild-netbsd-64/0.14.50:
resolution: {integrity: sha512-0R/glfqAQ2q6MHDf7YJw/TulibugjizBxyPvZIcorH0Mb7vSimdHy0XF5uCba5CKt+r4wjax1mvO9lZ4jiAhEg==}
/esbuild-netbsd-64/0.14.51:
resolution: {integrity: sha512-ZZBI7qrR1FevdPBVHz/1GSk1x5GDL/iy42Zy8+neEm/HA7ma+hH/bwPEjeHXKWUDvM36CZpSL/fn1/y9/Hb+1A==}
engines: {node: '>=12'}
cpu: [x64]
os: [netbsd]
@ -423,8 +423,8 @@ packages:
dev: true
optional: true
/esbuild-openbsd-64/0.14.50:
resolution: {integrity: sha512-7PAtmrR5mDOFubXIkuxYQ4bdNS6XCK8AIIHUiZxq1kL8cFIH5731jPcXQ4JNy/wbj1C9sZ8rzD8BIM80Tqk29w==}
/esbuild-openbsd-64/0.14.51:
resolution: {integrity: sha512-7R1/p39M+LSVQVgDVlcY1KKm6kFKjERSX1lipMG51NPcspJD1tmiZSmmBXoY5jhHIu6JL1QkFDTx94gMYK6vfA==}
engines: {node: '>=12'}
cpu: [x64]
os: [openbsd]
@ -432,8 +432,8 @@ packages:
dev: true
optional: true
/esbuild-sunos-64/0.14.50:
resolution: {integrity: sha512-gBxNY/wyptvD7PkHIYcq7se6SQEXcSC8Y7mE0FJB+CGgssEWf6vBPfTTZ2b6BWKnmaP6P6qb7s/KRIV5T2PxsQ==}
/esbuild-sunos-64/0.14.51:
resolution: {integrity: sha512-HoHaCswHxLEYN8eBTtyO0bFEWvA3Kdb++hSQ/lLG7TyKF69TeSG0RNoBRAs45x/oCeWaTDntEZlYwAfQlhEtJA==}
engines: {node: '>=12'}
cpu: [x64]
os: [sunos]
@ -441,8 +441,8 @@ packages:
dev: true
optional: true
/esbuild-windows-32/0.14.50:
resolution: {integrity: sha512-MOOe6J9cqe/iW1qbIVYSAqzJFh0p2LBLhVUIWdMVnNUNjvg2/4QNX4oT4IzgDeldU+Bym9/Tn6+DxvUHJXL5Zw==}
/esbuild-windows-32/0.14.51:
resolution: {integrity: sha512-4rtwSAM35A07CBt1/X8RWieDj3ZUHQqUOaEo5ZBs69rt5WAFjP4aqCIobdqOy4FdhYw1yF8Z0xFBTyc9lgPtEg==}
engines: {node: '>=12'}
cpu: [ia32]
os: [win32]
@ -450,8 +450,8 @@ packages:
dev: true
optional: true
/esbuild-windows-64/0.14.50:
resolution: {integrity: sha512-r/qE5Ex3w1jjGv/JlpPoWB365ldkppUlnizhMxJgojp907ZF1PgLTuW207kgzZcSCXyquL9qJkMsY+MRtaZ5yQ==}
/esbuild-windows-64/0.14.51:
resolution: {integrity: sha512-HoN/5HGRXJpWODprGCgKbdMvrC3A2gqvzewu2eECRw2sYxOUoh2TV1tS+G7bHNapPGI79woQJGV6pFH7GH7qnA==}
engines: {node: '>=12'}
cpu: [x64]
os: [win32]
@ -459,8 +459,8 @@ packages:
dev: true
optional: true
/esbuild-windows-arm64/0.14.50:
resolution: {integrity: sha512-EMS4lQnsIe12ZyAinOINx7eq2mjpDdhGZZWDwPZE/yUTN9cnc2Ze/xUTYIAyaJqrqQda3LnDpADKpvLvol6ENQ==}
/esbuild-windows-arm64/0.14.51:
resolution: {integrity: sha512-JQDqPjuOH7o+BsKMSddMfmVJXrnYZxXDHsoLHc0xgmAZkOOCflRmC43q31pk79F9xuyWY45jDBPolb5ZgGOf9g==}
engines: {node: '>=12'}
cpu: [arm64]
os: [win32]
@ -468,32 +468,32 @@ packages:
dev: true
optional: true
/esbuild/0.14.50:
resolution: {integrity: sha512-SbC3k35Ih2IC6trhbMYW7hYeGdjPKf9atTKwBUHqMCYFZZ9z8zhuvfnZihsnJypl74FjiAKjBRqFkBkAd0rS/w==}
/esbuild/0.14.51:
resolution: {integrity: sha512-+CvnDitD7Q5sT7F+FM65sWkF8wJRf+j9fPcprxYV4j+ohmzVj2W7caUqH2s5kCaCJAfcAICjSlKhDCcvDpU7nw==}
engines: {node: '>=12'}
hasBin: true
requiresBuild: true
optionalDependencies:
esbuild-android-64: 0.14.50
esbuild-android-arm64: 0.14.50
esbuild-darwin-64: 0.14.50
esbuild-darwin-arm64: 0.14.50
esbuild-freebsd-64: 0.14.50
esbuild-freebsd-arm64: 0.14.50
esbuild-linux-32: 0.14.50
esbuild-linux-64: 0.14.50
esbuild-linux-arm: 0.14.50
esbuild-linux-arm64: 0.14.50
esbuild-linux-mips64le: 0.14.50
esbuild-linux-ppc64le: 0.14.50
esbuild-linux-riscv64: 0.14.50
esbuild-linux-s390x: 0.14.50
esbuild-netbsd-64: 0.14.50
esbuild-openbsd-64: 0.14.50
esbuild-sunos-64: 0.14.50
esbuild-windows-32: 0.14.50
esbuild-windows-64: 0.14.50
esbuild-windows-arm64: 0.14.50
esbuild-android-64: 0.14.51
esbuild-android-arm64: 0.14.51
esbuild-darwin-64: 0.14.51
esbuild-darwin-arm64: 0.14.51
esbuild-freebsd-64: 0.14.51
esbuild-freebsd-arm64: 0.14.51
esbuild-linux-32: 0.14.51
esbuild-linux-64: 0.14.51
esbuild-linux-arm: 0.14.51
esbuild-linux-arm64: 0.14.51
esbuild-linux-mips64le: 0.14.51
esbuild-linux-ppc64le: 0.14.51
esbuild-linux-riscv64: 0.14.51
esbuild-linux-s390x: 0.14.51
esbuild-netbsd-64: 0.14.51
esbuild-openbsd-64: 0.14.51
esbuild-sunos-64: 0.14.51
esbuild-windows-32: 0.14.51
esbuild-windows-64: 0.14.51
esbuild-windows-arm64: 0.14.51
dev: true
/estree-walker/2.0.2:
@ -1143,7 +1143,7 @@ packages:
'@types/unist': 2.0.6
dev: true
/unplugin-icons/0.14.7_vite@3.0.3:
/unplugin-icons/0.14.7_vite@3.0.4:
resolution: {integrity: sha512-TrNnEdpaXMdiG5BsCgvU6cv/gSLYvIk1f8wGCGZmOo4wmi3nqYBuqIEuiXhmmyXdDZuRRpCaOzCnCYYZ5H7U8g==}
peerDependencies:
'@svgr/core': '>=5.5.0'
@ -1166,7 +1166,7 @@ packages:
debug: 4.3.4
kolorist: 1.5.1
local-pkg: 0.4.2
unplugin: 0.7.2_vite@3.0.3
unplugin: 0.7.2_vite@3.0.4
transitivePeerDependencies:
- esbuild
- rollup
@ -1175,7 +1175,7 @@ packages:
- webpack
dev: true
/unplugin/0.7.2_vite@3.0.3:
/unplugin/0.7.2_vite@3.0.4:
resolution: {integrity: sha512-m7thX4jP8l5sETpLdUASoDOGOcHaOVtgNyrYlToyQUvILUtEzEnngRBrHnAX3IKqooJVmXpoa/CwQ/QqzvGaHQ==}
peerDependencies:
esbuild: '>=0.13'
@ -1194,7 +1194,7 @@ packages:
dependencies:
acorn: 8.8.0
chokidar: 3.5.3
vite: 3.0.3
vite: 3.0.4
webpack-sources: 3.2.3
webpack-virtual-modules: 0.4.4
dev: true
@ -1206,8 +1206,8 @@ packages:
unist-util-stringify-position: 2.0.3
dev: true
/vite/3.0.3:
resolution: {integrity: sha512-sDIpIcl3mv1NUaSzZwiXGEy1ZoWwwC2vkxUHY6yiDacR6zf//ZFuBJrozO62gedpE43pmxnLATNR5IYUdAEkMQ==}
/vite/3.0.4:
resolution: {integrity: sha512-NU304nqnBeOx2MkQnskBQxVsa0pRAH5FphokTGmyy8M3oxbvw7qAXts2GORxs+h/2vKsD+osMhZ7An6yK6F1dA==}
engines: {node: ^14.18.0 || >=16.0.0}
hasBin: true
peerDependencies:
@ -1225,7 +1225,7 @@ packages:
terser:
optional: true
dependencies:
esbuild: 0.14.50
esbuild: 0.14.51
postcss: 8.4.14
resolve: 1.22.1
rollup: 2.77.2

128
src/lib/ContactForm.svelte Normal file
View File

@ -0,0 +1,128 @@
<script lang="ts">
import IconLock from "~icons/fa6-solid/lock";
import IconInfo from "~icons/fa6-solid/circle-info";
import HCaptcha from "svelte-hcaptcha";
let submit = false;
let showSubmitButton = () => {
submit = !submit;
};
</script>
<form
action="https://segfautilities.projectsegfau.lt/api/form"
method="POST"
id="contact-form"
>
<div class="note">
<IconLock />
<b>Your IP will be logged for anti-abuse measures.</b>
</div>
<div class="meta">
<input
type="text"
name="email"
class="form-textbox"
placeholder="Your email"
required
/>
<select id="commentType" name="commentType" required class="button">
<option value="" selected disabled>Select a type of comment</option>
<option value="Feedback">Feedback</option>
<option value="Suggestion">Suggestion</option>
<option value="Question">Question</option>
<option value="Bug">Bug</option>
</select>
</div>
<textarea
id="comment"
name="message"
rows="4"
cols="25"
required
class="form-textbox"
placeholder="Your message"
/>
<div class="note">
<IconInfo />
<b>The submit button will be visible when you complete the Captcha.</b>
</div>
<HCaptcha
sitekey="67e84266-980c-4050-8a39-142a91928fe8"
theme="dark"
on:success={showSubmitButton}
/>
{#if submit}
<input type="submit" value="Submit" class="button" />
{/if}
</form>
<style>
form {
display: flex;
flex-direction: column;
gap: 1rem;
width: fit-content;
}
.note {
display: flex;
align-items: center;
gap: 4px;
}
.meta {
display: flex;
align-items: center;
flex-direction: row;
gap: 1rem;
}
.meta > * {
width: 50%;
}
@media screen and (max-width: 450px) {
.meta {
flex-direction: column;
align-items: flex-start;
justify-content: center;
}
.meta > * {
width: calc(100% - 1rem);
}
.meta > *:nth-child(2) {
width: 100%;
}
}
.form-textbox {
background-color: var(--tertiary);
color: var(--text);
border-radius: 10px;
border: none;
padding: 0.5rem;
font-family: "Comfortaa", sans-serif;
outline: none;
}
.button {
background-color: var(--tertiary);
border: none;
border-radius: 10px;
padding: 0.5rem;
cursor: pointer;
color: var(--text);
font-family: var(--font-primary);
text-decoration: none;
}
.button:not(select):hover {
background-color: var(--accent-tertiary);
text-decoration: none;
transition: all 0.5s;
color: var(--secondary);
}
</style>

View File

@ -3,54 +3,17 @@ title: Contact Us
description: Do you want to contact us?
---
<script lang="ts">
import IconLock from '~icons/fa6-solid/lock';
import IconInfo from '~icons/fa6-solid/circle-info';
import HCaptcha from 'svelte-hcaptcha';
let contactform;
let submit = false;
function showSubmitButton() {
submit = !submit;
}
import ContactForm from "$lib/ContactForm.svelte";
</script>
# { title }
{ description }
## Contact Form
<form action="https://segfautilities.projectsegfau.lt/api/form" method="POST" id="contact-form" bind:this={contactform}>
<div class="ip-note">
<IconLock />
<b>Your IP will be logged for anti-abuse measures.</b>
</div>
<div class="meta">
<input type="text" name="email" class="form-textbox" placeholder="Email" required="required"/>
<select id="commentType" name="commentType" required="required" class="button">
<option value="" selected="selected" disabled="disabled">Select a type of comment</option>
<option value="Feedback">Feedback</option>
<option value="Suggestion">Suggestion</option>
<option value="Question">Question</option>
<option value="Bug">Bug</option>
</select>
</div>
<textarea id="comment" name="message" rows="4" cols="25" required="required" class="form-textbox" placeholder="Your message"></textarea>
<div class="ip-info">
<IconInfo />
<b>The submit button will be visible when you complete the captcha.</b>
</div>
<HCaptcha
sitekey=67e84266-980c-4050-8a39-142a91928fe8
theme=dark
on:success={showSubmitButton}
/>
{#if submit}
<input type="submit" value="Submit" class="button" />
{/if}
</form>
<ContactForm />
## Our email
@ -61,82 +24,3 @@ _Please be aware that Microsoft often blocks non-popular emails, if you do conta
## People
You can find ways to contact individual members [on our Members page](/members).
<style>
form {
display: flex;
flex-direction: column;
gap: 1rem;
width: fit-content;
}
.ip-note {
display: flex;
align-items: center;
gap: 4px;
}
.meta {
display: flex;
align-items: center;
flex-direction: row;
gap: 1rem;
}
.meta > * {
width: 50%;
}
@media screen and (max-width: 450px) {
.meta {
flex-direction: column;
align-items: flex-start;
justify-content: center;
}
.meta > * {
width: calc(100% - 1rem);
}
.meta > *:nth-child(2) {
width: 100%;
}
}
.form-textbox {
background-color: var(--tertiary);
color: var(--text);
border-radius: 10px;
border: none;
padding: 0.5rem;
font-family: 'Comfortaa', sans-serif;
}
.form-textbox:focus {
outline: none !important;
}
.button {
background-color: var(--tertiary);
border: none;
border-radius: 10px;
padding: 0.5rem;
cursor: pointer;
color: var(--text);
font-family: var(--font-primary);
text-decoration: none;
}
.button:not(select):hover {
background-color: var(--accent-tertiary);
text-decoration: none;
transition: all 0.5s;
color: var(--secondary);
}
.button:not(select):active {
background-color: var(--accent-primary);
text-decoration: none;
transition: all 0.5s;
color: var(--secondary);
}
</style>