Compare commits

..
Author SHA1 Message Date
philipp 15b60f60b5 migrate to Tailwind JIT + views + router/ build fix
ref #23
2021-03-30 18:05:55 +02:00
philipp 5253fb1832 🚀Bumped version to v0.1.2 2021-03-27 19:02:19 +01:00
philipp 00f8d8023e package dependency cleanup 2021-03-26 21:05:18 +01:00
philipp ef304c576b Merge branch 'feature/0.1.1' into dev 2021-03-26 20:45:11 +01:00
philipp e2be86c558 ⏫ v0.1.1 changelog 2021-03-26 20:44:53 +01:00
philipp 4d57812c04 ⏫ version bump to 0.1.1 2021-03-26 20:43:52 +01:00
philipp 829fe32743 org registration - add team select
close #18
2021-03-26 20:42:20 +01:00
philipp 760b1b32a2 added baseurl_selfservice config
close #22
2021-03-26 20:10:26 +01:00
philipp 7b0bc22a71 [tmp] vue i18n error 2021-03-26 18:36:52 +01:00
philipp 88996f81d8 Merge tag '0.1.0' into dev
working basics
2021-03-26 18:01:03 +01:00
philipp 5876e0c9df Merge branch 'release/0.1.0' 2021-03-26 18:00:50 +01:00
philipp ace5c958f1 ⏫ version bump to 0.1.0 2021-03-26 18:00:31 +01:00
philipp aa287cf452 add required confirmation of data on registration 2021-03-26 17:47:50 +01:00
philipp aca2dff129 drop profile data editing
close #20
2021-03-26 16:48:34 +01:00
philipp d41824b735 Merge pull request 'feature/15_company_registration' (#16) from feature/15_company_registration into dev
Reviewed-on: #16
close #15
2021-03-25 19:01:59 +00:00
philipp 7904151a52 enable org registration
ref #15
2021-03-25 19:51:44 +01:00
philipp a39cf75c7f move profile to path param
ref #15
2021-03-25 19:49:35 +01:00
philipp 79d8545ed6 working path params for org registration
ref #15
2021-03-25 19:36:31 +01:00
philipp 18d1ddacf7 basic /register/:token route
ref #15
2021-03-25 19:29:37 +01:00
philipp 36baf174a5 ⏫ dependency bump 2021-03-24 17:38:51 +01:00
philipp 857b5c3d89 Merge pull request 'i18n support for TOS checkbox' (#14) from feature/4-component-interpolation into dev
Reviewed-on: #14
close #4
2021-03-09 16:56:34 +00:00
niggl 9da54d15bf Merge branch 'dev' into feature/4-component-interpolation 2021-03-09 16:53:45 +00:00
philipp 9e5252181e Merge pull request 'feature/11-user-scans' (#13) from feature/11-user-scans into dev
Reviewed-on: #13
close #11
2021-03-09 16:51:53 +00:00
philipp 45c0bdd5cf Merge branch 'dev' into feature/11-user-scans
# Conflicts:
#	src/components/Profile.vue
2021-03-09 17:45:19 +01:00
philipp 853f817c8f Merge pull request 'feature/10-my-profile-data' (#12) from feature/10-my-profile-data into dev
Reviewed-on: #12
close #10
2021-03-09 16:42:09 +00:00
philipp 56daa7c501 fix fallback component routing for invalid env config
ref #10
2021-03-09 17:39:20 +01:00
philipp 641e7a0d8f Profile - display group
ref #10
2021-03-09 17:27:48 +01:00
philipp d405557aaf i18n support for TOS checkbox
ref #4
2021-03-08 22:18:19 +01:00
philipp ff1f43e235 format lap times + only display valid scans
ref #11
2021-03-07 14:22:03 +01:00
philipp c8d462100a use api response object properly
ref #11
2021-03-07 14:08:06 +01:00
philipp 69db350461 🌎 added missing translations
ref #11
2021-03-07 14:06:11 +01:00
philipp cb3dc13c8a center empty state image
ref #11
2021-03-07 14:05:28 +01:00
philipp 4fb9aee255 re-order language files 😬
ref #11
2021-03-07 14:04:56 +01:00
philipp 49c3507a71 added empty state for scans
ref #11
2021-03-07 14:04:40 +01:00
philipp 14369480ea basic lap/ scans ui
ref #11
2021-03-07 14:04:29 +01:00
philipp 8205c11bd9 Profile - remove form styling. data is not editable yet
ref #10
2021-03-07 13:49:56 +01:00
philipp b30277b617 display user name in Profile title
ref #10
2021-03-07 13:46:25 +01:00
philipp 0929f2bbc7 Profile - fetch user profile data from api
ref #10
2021-03-07 13:30:23 +01:00
philipp ac9f1ba2ac routing import fix
ref #10
2021-03-07 13:30:05 +01:00
philipp f8ceec492d ✨ Profile - basic parsing for hash based query params
ref #10
2021-03-07 13:21:43 +01:00
philipp 3351092859 fix accessibility in Profile component 2021-03-05 19:27:44 +01:00
philipp b668c50eac Merge pull request 'feature/3_env_file' (#9) from feature/3_env_file into dev
Reviewed-on: #9
close #3
2021-03-05 18:09:13 +00:00
philipp 4c78712f83 📃 updated README
ref #3
2021-03-05 18:59:21 +01:00
philipp 987ac4d02c 🐞 bugfix for non-existant env.js
ref #3
2021-03-05 18:47:15 +01:00
philipp c92d5bf5f2 added ui for configuration errors page
ref #3
2021-03-04 19:56:17 +01:00
philipp 20229ab142 fallback for env config errors
ref #3
2021-03-04 17:09:47 +01:00
philipp 5a5261d6b0 basic markdown rendering + routing for /imprint and /privacy
ref #3
2021-03-03 19:14:26 +01:00
philipp 747c1d2a90 ✨ basic env.js file for api baseurl, documentserver_key
ref #3
2021-03-03 18:20:53 +01:00
philipp faf19d9e43 Merge pull request 'feature/5_basic_ui_lap_times' (#8) from feature/5_basic_ui_lap_times into dev
Reviewed-on: #8
close #5
2021-03-03 17:07:47 +00:00
28 changed files with 697 additions and 321 deletions

No files matched your search

+2 -1
View File
@@ -182,4 +182,5 @@ docs/_book
test/
/package-lock.json
/yarn.lock
/yarn.lock
/public/env.js
+97
View File
@@ -0,0 +1,97 @@
### Changelog
All notable changes to this project will be documented in this file. Dates are displayed in UTC.
#### [0.1.1](https://git.odit.services/lfk/selfservice/compare/0.1.0...0.1.1)
- org registration - add team select [`#18`](https://git.odit.services/lfk/selfservice/issues/18)
- added baseurl_selfservice config [`#22`](https://git.odit.services/lfk/selfservice/issues/22)
- [tmp] vue i18n error [`7b0bc22`](https://git.odit.services/lfk/selfservice/commit/7b0bc22a7157ee4551ab69dd5be856abed90b60c)
- ⏫ version bump to 0.1.1 [`4d57812`](https://git.odit.services/lfk/selfservice/commit/4d57812c043e9078656818a33d241df220127a92)
- Merge tag '0.1.0' into dev [`88996f8`](https://git.odit.services/lfk/selfservice/commit/88996f81d8990969048f00a7c175d2a30da2588b)
#### 0.1.0
> 26 March 2021
- drop profile data editing [`#20`](https://git.odit.services/lfk/selfservice/issues/20)
- Merge pull request 'feature/15_company_registration' (#16) from feature/15_company_registration into dev [`#15`](https://git.odit.services/lfk/selfservice/issues/15)
- Merge pull request 'i18n support for TOS checkbox' (#14) from feature/4-component-interpolation into dev [`#4`](https://git.odit.services/lfk/selfservice/issues/4)
- Merge pull request 'feature/11-user-scans' (#13) from feature/11-user-scans into dev [`#11`](https://git.odit.services/lfk/selfservice/issues/11)
- Merge pull request 'feature/10-my-profile-data' (#12) from feature/10-my-profile-data into dev [`#10`](https://git.odit.services/lfk/selfservice/issues/10)
- Merge pull request 'feature/3_env_file' (#9) from feature/3_env_file into dev [`#3`](https://git.odit.services/lfk/selfservice/issues/3)
- Merge pull request 'feature/5_basic_ui_lap_times' (#8) from feature/5_basic_ui_lap_times into dev [`#5`](https://git.odit.services/lfk/selfservice/issues/5)
- Merge pull request 'use new flex grid for responsive displaying action buttons' (#7) from feature/6_profile_action_buttons into dev [`#6`](https://git.odit.services/lfk/selfservice/issues/6)
- Merge pull request 'feature/1-register-disable-submit-address' (#2) from feature/1-register-disable-submit-address into dev [`#1`](https://git.odit.services/lfk/selfservice/issues/1)
- Initial commit [`7c2154a`](https://git.odit.services/lfk/selfservice/commit/7c2154ad026e8850727c40e9759757c4ceb56d0b)
- sample routes + first landing page and routing logic [`3e92597`](https://git.odit.services/lfk/selfservice/commit/3e92597a563399149b5fbfab74fce6a0ecd6aba4)
- basic ui for profile page [`a0cbeae`](https://git.odit.services/lfk/selfservice/commit/a0cbeae8fef54c298883c379a9e9e9440f6d3336)
- 🎉 initial commit [`4ca10e1`](https://git.odit.services/lfk/selfservice/commit/4ca10e1db4b99b0181fdb0bdad1c042f958b2267)
- ✨refined Register component for basic requirements [`e63367e`](https://git.odit.services/lfk/selfservice/commit/e63367e84e382607d372dd5f14f3dd13da0426de)
- Profile - basic ui reactivity logic [`13543c3`](https://git.odit.services/lfk/selfservice/commit/13543c3cd2792b3f7829a2e0d5d64e73852d7feb)
- 🚚 tmp move Login component [`a661064`](https://git.odit.services/lfk/selfservice/commit/a661064f34d31dd1ef5a01919cc8d5a2d81882b9)
- basic lap/ scans ui [`1436948`](https://git.odit.services/lfk/selfservice/commit/14369480ea23e8b0af8548596a6bf3d331de13e5)
- basic markdown rendering + routing for /imprint and /privacy [`5a5261d`](https://git.odit.services/lfk/selfservice/commit/5a5261d6b0d4adc62c100a29cebd07d25b89028d)
- Register - basic form validations [`2b303ac`](https://git.odit.services/lfk/selfservice/commit/2b303ac9b279423bc0cee687e4d9ef3bdb3727c2)
- use new flex grid for responsive displaying action buttons [`2b9c454`](https://git.odit.services/lfk/selfservice/commit/2b9c454395a4789236878b7e2a77dc1fa230eafe)
- merge #6 into #5 [`7fa459b`](https://git.odit.services/lfk/selfservice/commit/7fa459b71b2bdd96d4a5104b5356441e1232e5e8)
- re-order language files 😬 [`4fb9aee`](https://git.odit.services/lfk/selfservice/commit/4fb9aee25586cc873f7e276fd44e41458b633b70)
- 🐳 working docker config + Dockerfile [`5a258d8`](https://git.odit.services/lfk/selfservice/commit/5a258d8e6ceadb6a66cf628e8093876d1f4a783c)
- 🧹 added order script for i18n keys [`94f5787`](https://git.odit.services/lfk/selfservice/commit/94f578798818f7188ff83e6accb201a50aaa43a2)
- Profile - remove form styling. data is not editable yet [`8205c11`](https://git.odit.services/lfk/selfservice/commit/8205c11bd9a38c49608b0641dd89df22f492efd0)
- 🌎 basic i18n keys for Register component [`37b7ed7`](https://git.odit.services/lfk/selfservice/commit/37b7ed75c52cea16b413fcd2af586a30392496d5)
- Register - reactive AGB registration button [`9effcb4`](https://git.odit.services/lfk/selfservice/commit/9effcb457540b512c261286cbf46bbd856b7d8b9)
- Register - basic input POST to api [`8bf0803`](https://git.odit.services/lfk/selfservice/commit/8bf08034b798da354fdbbbc7ce6e5a72616bb16b)
- added ui for configuration errors page [`c92d5bf`](https://git.odit.services/lfk/selfservice/commit/c92d5bf5f2ff7642e2a55abe0002ff94f2d64d3e)
- fix accessibility in Profile component [`3351092`](https://git.odit.services/lfk/selfservice/commit/335109285912a4df16d4f0aea90c0ba054089762)
- 🌎 Profile - i18n compatibility [`b518730`](https://git.odit.services/lfk/selfservice/commit/b518730fab90927b111f1708b532c5eb34e2aee2)
- basic demo for i18n integration along with i18n-ally [`63bb34e`](https://git.odit.services/lfk/selfservice/commit/63bb34ef997bed202f3f208645e14861318e66ef)
- basic input styling for Profile page [`8fd6f47`](https://git.odit.services/lfk/selfservice/commit/8fd6f47b2f5d21a58ce356a949910db7d7e6064b)
- 🎉 working vue reactivity [`d18dbc3`](https://git.odit.services/lfk/selfservice/commit/d18dbc3a1fdf1bc9f2e8c5b37cc2d3044857410a)
- 📍🏠 added address2 field to Register [`2153944`](https://git.odit.services/lfk/selfservice/commit/215394489461e17760263cebf606475938500e6b)
- Profile - fetch user profile data from api [`0929f2b`](https://git.odit.services/lfk/selfservice/commit/0929f2bbc7037106bc6c9a4c948f51c59148a10b)
- 🐳 basic devcontainer config [`5bfeac6`](https://git.odit.services/lfk/selfservice/commit/5bfeac693e8f9bfe6f62a38e12bf259744330c39)
- 📃 updated README [`4c78712`](https://git.odit.services/lfk/selfservice/commit/4c78712f83565f21f3cdee2168f9221e2a007951)
- Profile - display group [`641e7a0`](https://git.odit.services/lfk/selfservice/commit/641e7a0d8ff75ce5756d11f39b583f55731b821c)
- accessibility fixes for input borders [`b7f15f4`](https://git.odit.services/lfk/selfservice/commit/b7f15f4d6827c893aa1fc4d47996df2fb46602ff)
- add required confirmation of data on registration [`aa287cf`](https://git.odit.services/lfk/selfservice/commit/aa287cf452e588a41ec0f74063dcbecdb08d476a)
- 🐞 bugfix for non-existant env.js [`987ac4d`](https://git.odit.services/lfk/selfservice/commit/987ac4d02cf63af5acdcc60f0ee2ec54534773cb)
- fallback for env config errors [`20229ab`](https://git.odit.services/lfk/selfservice/commit/20229ab14252e20ffb3ac0e3e8b9d8f7f31819a3)
- move profile to path param [`a39cf75`](https://git.odit.services/lfk/selfservice/commit/a39cf75c7fc2e29a5a1a34a7db39355e59ce9476)
- sample toast integration [`ff89071`](https://git.odit.services/lfk/selfservice/commit/ff89071156325b40239d39bc5c21106cfb6448a0)
- ⚙ basic release config [`35b4796`](https://git.odit.services/lfk/selfservice/commit/35b4796f3794f332940becc25a617777216cc1f3)
- added more example laps [`c8bf0b2`](https://git.odit.services/lfk/selfservice/commit/c8bf0b2685f1e0db4df5e4ce405268865775eb41)
- Register - correct phone number validation [`72f6523`](https://git.odit.services/lfk/selfservice/commit/72f65234f09fc2b9c7179fa1b43e217fab59ae60)
- basic /register/:token route [`18d1dda`](https://git.odit.services/lfk/selfservice/commit/18d1ddacf7e99e67e6572533ebd9add3d0c0592f)
- i18n support for TOS checkbox [`d405557`](https://git.odit.services/lfk/selfservice/commit/d405557aafb205c958914c85bd69c364d107370c)
- 🌎 first translations for landing page [`f1c45df`](https://git.odit.services/lfk/selfservice/commit/f1c45dff11bfa088f04922f5cd2d8f4f5f873f2f)
- enable org registration [`7904151`](https://git.odit.services/lfk/selfservice/commit/7904151a52af1a1592706e6a468943c8e9c57518)
- working path params for org registration [`79d8545`](https://git.odit.services/lfk/selfservice/commit/79d8545ed6b2e0e64ca02194bc7009b48d2c8f2d)
- ⏫ dependency bump [`36baf17`](https://git.odit.services/lfk/selfservice/commit/36baf174a52e3a5ce21294f7d4e899d6893fd517)
- ✨ basic env.js file for api baseurl, documentserver_key [`747c1d2`](https://git.odit.services/lfk/selfservice/commit/747c1d2a906ed46325b999ebc0f079265ad81eeb)
- ✅ added zipcode validation [`b5eade9`](https://git.odit.services/lfk/selfservice/commit/b5eade9633fb88659cdfe882220db0579e39ada1)
- 🌟 added requirement stars to Register ui [`2822fcd`](https://git.odit.services/lfk/selfservice/commit/2822fcdeba3c5f559c165d512a2743949bf9c61e)
- ⏫ dependency bumps [`70ac314`](https://git.odit.services/lfk/selfservice/commit/70ac31401654c316a5c162dbc142421788fccee7)
- format lap times + only display valid scans [`ff1f43e`](https://git.odit.services/lfk/selfservice/commit/ff1f43e235ba318008b9c408853231c809760304)
- Register - basic email input validation [`0c006cc`](https://git.odit.services/lfk/selfservice/commit/0c006cc09c983041d906621677b4a7a32ca1bb22)
- Register - reactive address checkbox [`2b3f4ab`](https://git.odit.services/lfk/selfservice/commit/2b3f4abe1ac13318f5dee873b3454eb06577d1c5)
- use api response object properly [`c8d4621`](https://git.odit.services/lfk/selfservice/commit/c8d462100a660e8edfd3bc46bd0c8abbd002f661)
- added sponsorings tab [`e499357`](https://git.odit.services/lfk/selfservice/commit/e499357d6f151eaa8885ebfb78150e709ba4e753)
- 🌎 translation for lap times + distance [`cf5c279`](https://git.odit.services/lfk/selfservice/commit/cf5c279eacde5d62b62c030b21ba51caad56eac4)
- 🐞 fix for address submitting [`9d970b0`](https://git.odit.services/lfk/selfservice/commit/9d970b02b8a7ab54109fc3df2c652d01e0c99a8e)
- ⏫ version bump to 0.1.0 [`ace5c95`](https://git.odit.services/lfk/selfservice/commit/ace5c958f1ce63c1a91ae730b129de45ee9b975a)
- added empty state for scans [`49c3507`](https://git.odit.services/lfk/selfservice/commit/49c3507a71a6ca212b0b8ade2b1945ea90db96bc)
- ✨ Register - invalid phone number error state [`e633ad6`](https://git.odit.services/lfk/selfservice/commit/e633ad6cea5d1fe8596cb67319ca7da7548bc770)
- display user name in Profile title [`b30277b`](https://git.odit.services/lfk/selfservice/commit/b30277b617c1329702cb538b7e98d98929ca2346)
- ✨ Profile - basic parsing for hash based query params [`f8ceec4`](https://git.odit.services/lfk/selfservice/commit/f8ceec492d720ced359da9001088bf691cb8c28f)
- ✨ Profile - lap times table responsiveness [`503aafb`](https://git.odit.services/lfk/selfservice/commit/503aafba06d0d72fd980dedd9a56905c6673ce28)
- 🐞 Register - display error state for empty + required address inputs [`3404fc0`](https://git.odit.services/lfk/selfservice/commit/3404fc06bf8e7163319680991f8d98208869478c)
- fix fallback component routing for invalid env config [`56daa7c`](https://git.odit.services/lfk/selfservice/commit/56daa7c501e3f59e988f1912ed397e43d6311572)
- center empty state image [`cb3dc13`](https://git.odit.services/lfk/selfservice/commit/cb3dc13c8acfeea3fad9ba9d5f9f6eade3e2310d)
- routing import fix [`ac9f1ba`](https://git.odit.services/lfk/selfservice/commit/ac9f1ba2aca43d38d67604a4f6e77c5b29a670af)
- ✨ Register - disable register button when invalid phone number is set [`e858334`](https://git.odit.services/lfk/selfservice/commit/e8583340c761663067aa51a4937d0795b75d21f1)
- 🐞 Register - fix zipcode submitting [`43ee4b5`](https://git.odit.services/lfk/selfservice/commit/43ee4b51f9973a20fbb2f4f7774763f5c089b0e1)
- 🚀Bumped version to v0.0.1 [`c8db78d`](https://git.odit.services/lfk/selfservice/commit/c8db78df6ffd5b4bdeb53893f363659ae2eefd45)
- Register - style agb link with underline [`c8e1b5d`](https://git.odit.services/lfk/selfservice/commit/c8e1b5d80db0ce20043a5cda5588c995e71ee090)
- new favicon [`9958fed`](https://git.odit.services/lfk/selfservice/commit/9958fed045e683cbf25b51c66deec405fd342073)
- 🌎 added missing translations [`69db350`](https://git.odit.services/lfk/selfservice/commit/69db350461231123796bc24a2452e6af47a7c83f)
+20 -1
View File
@@ -1,3 +1,22 @@
# @lfk/selfservice
runner selfservice portal
runner selfservice portal
## ⚡ Development
### Requirements
- Node.js v14.15.0 or newer
- yarn package manager >= v1.22.10 < 2
### Recommended Extensions
- will be automatically recommended via `./vscode/extensions.json`
- we also provide a config for i18n-ally in the `./vscode/` folder
### Fastest Dev Environment
- You can install the [Remote - Containers](https://github.com/Microsoft/vscode-remote-release) extension and use all recommended extensions and editor settings via the provided `./devcontainer/` config
## 🔨 environment config
- copy the `/public/env.sample.js` file to `/public/env.js`
- set the required environment variables
- `documentserver_key`: url to the [document server](https://git.odit.services/lfk/document-server) instance
- `baseurl`: url to the main instance
- see [@lfk/deployment](https://git.odit.services/lfk/deployment) for a complete deployment guide
+1
View File
@@ -10,6 +10,7 @@
<body class="dark:bg-gray-900 text-black dark:text-white p-0">
<div id="app"></div>
<script src="/env.js"></script>
<script type="module" src="/src/main.js"></script>
</body>
+43 -41
View File
@@ -1,43 +1,45 @@
{
"name": "@odit/lfk-selfservice",
"version": "0.0.1",
"scripts": {
"dev": "vite",
"build": "vite build",
"release": "release-it --only-version"
},
"dependencies": {
"got": "^11.8.2",
"redaxios": "^0.4.1",
"toastify-js": "^1.9.3",
"validator": "^13.5.2",
"vue": "^3.0.5",
"vue-i18n": "^9.0.0",
"vue-phone-number-input": "^1.1.10",
"vue-router": "4",
"vue-toastification": "^2.0.0-rc.1"
},
"devDependencies": {
"@vitejs/plugin-vue": "^1.1.5",
"@vue/compiler-sfc": "^3.0.6",
"autoprefixer": "^10.2.4",
"postcss": "^8.2.6",
"release-it": "^14.4.1",
"tailwindcss": "^2.0.3",
"vite": "^2.0.3",
"vite-plugin-windicss": "^0.5.4"
},
"release-it": {
"git": {
"commit": true,
"requireCleanWorkingDir": false,
"commitMessage": "🚀Bumped version to v${version}",
"requireBranch": "dev",
"push": false,
"tag": false
},
"npm": {
"publish": false
}
}
"name": "@odit/lfk-selfservice",
"version": "0.1.2",
"scripts": {
"dev": "vite",
"build": "vite build",
"release": "release-it --only-version"
},
"dependencies": {
"marked": "2.0.1",
"redaxios": "0.4.1",
"toastify-js": "1.10.0",
"validator": "13.5.2",
"vue-i18n": "9.0.0",
"vue-toastification": "2.0.0-rc.1",
"vue": "3.0.9",
"vue-router": "4.0.5"
},
"devDependencies": {
"@tailwindcss/jit": "0.1.17",
"@tailwindcss/aspect-ratio": "0.2.0",
"@tailwindcss/forms": "0.3.2",
"@tailwindcss/line-clamp": "0.2.0",
"@tailwindcss/typography": "0.4.0",
"@vitejs/plugin-vue": "1.2.0",
"@vue/compiler-sfc": "3.0.9",
"autoprefixer": "10.2.5",
"tailwindcss": "2.0.4",
"release-it": "14.5.0",
"vite": "2.1.3"
},
"release-it": {
"git": {
"commit": true,
"requireCleanWorkingDir": false,
"commitMessage": "🚀Bumped version to v${version}",
"requireBranch": "dev",
"push": false,
"tag": false
},
"npm": {
"publish": false
}
}
}
+12
View File
@@ -0,0 +1,12 @@
const config = {
// required
documentserver_key: '',
// required
baseurl: '',
// optional, will fallback to /selfservice
baseurl_selfservice: '/selfservice',
// optional, will fallback to /imprint
url_imprint: '',
// optional, will fallback to /privacy
url_privacy: ''
};
+1
View File
@@ -0,0 +1 @@
TODO:
+1
View File
@@ -0,0 +1 @@
TODO:
+4 -2
View File
@@ -1,7 +1,9 @@
<template>
<router-view></router-view>
<main>
<router-view></router-view>
</main>
</template>
<script setup>
//
config.baseurl_selfservice = (config.baseurl_selfservice || "/selfservice");
</script>
+1
View File
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 500 500"><path d="M307.18 117.6c21.3 1.09 42.83 9.39 57.52 22 46.68 39.91 40.22 110.84 5.81 156.19-33.82 44.58-91.54 70.06-147.13 68a153 153 0 01-48.79-9.79c-27.05-10.33-62.88-30.25-73.29-59.11-12.52-34.72 23.7-41.72 47.84-32.89 19.42 7.12 39 19.43 60.05 9.57 23.33-10.91 35.2-36.06 36.4-60.82 1.3-26.77-13.13-55.71 10.43-77.1 13.63-12.33 32.31-17.01 51.16-16.05z" fill="#407bff"/><path d="M307.18 117.6c21.3 1.09 42.83 9.39 57.52 22 46.68 39.91 40.22 110.84 5.81 156.19-33.82 44.58-91.54 70.06-147.13 68a153 153 0 01-48.79-9.79c-27.05-10.33-62.88-30.25-73.29-59.11-12.52-34.72 23.7-41.72 47.84-32.89 19.42 7.12 39 19.43 60.05 9.57 23.33-10.91 35.2-36.06 36.4-60.82 1.3-26.77-13.13-55.71 10.43-77.1 13.63-12.33 32.31-17.01 51.16-16.05z" fill="#fff" opacity=".9"/><ellipse cx="250" cy="416.24" rx="193.89" ry="11.32" fill="#f5f5f5"/><path fill="#407bff" d="M259.8 382.52H79.91L63.12 316H243l16.8 66.52z"/><path fill="#407bff" d="M242.79 316H62.9l-16.8 66.52h179.89l16.8-66.52z"/><path style="isolation:isolate" fill="#fff" opacity=".6" d="M242.79 316H62.9l-16.8 66.52h179.89l16.8-66.52z"/><path fill="#407bff" d="M449.92 382.52H270.03L253.24 316h179.88l16.8 66.52z"/><path fill="#407bff" d="M432.91 316H253.02l-16.8 66.52h179.89l16.8-66.52z"/><path style="isolation:isolate" fill="#fff" opacity=".6" d="M432.91 316H253.02l-16.8 66.52h179.89l16.8-66.52z"/><g><path d="M266 176a11.19 11.19 0 00-11.52-6.35c-9 .83-17.67 12.16-25.83 9.83S221.5 172 221.5 172s-3 7.39 7.17 13.6 24-9.46 35.48-4.8z" fill="#2e353a"/><path d="M266 176a14.65 14.65 0 00-12.52-9.39c-9.62-.75-15.25 11.41-22.62 9.39" fill="none" stroke="#263238" stroke-linecap="round" stroke-linejoin="round" stroke-width=".48"/><path d="M288.12 189.65s3.42-14.12-8.43-17-17.19 4.1-19.19 11.79 3 18.4 13.77 16.63 13.42-8.07 13.85-11.42z" fill="#2e353a"/><path d="M292.51 211.59c9.74-4.53 22.54-14.45 22.3-18.06s-10.06-27.9-10.06-27.9a7.65 7.65 0 01-2.26-1.08c-1-.72-2.17-9.66-.72-10.14a44.09 44.09 0 017.49-1.21c1.2 0 .72 8 .24 9.9 0 0 15.58 21.72 14.55 32.12s-25.18 28.47-33.63 31 2.09-14.63 2.09-14.63zM186.81 329.9l2.76-5.88 8.63 2.88 7.92 2.66-2.14 7.51-9.1-3.79-8.07-3.38z" fill="#e4897b"/><path d="M190.54 322.94c.64.32-3.61 8-3.61 8s-7.29 2.56-10.64 6.79-5 .23-2.46-5.09l6.17-13.11c1.79-3.78 3.89.1 10.54 3.41z" fill="#2e353a"/><path d="M183.72 335.61a.55.55 0 01-.18 0 .84.84 0 01-.76-.59c-.28-1.1 2.2-3.2 2.7-3.61a.19.19 0 01.1-.05.34.34 0 01.14.05c.07.07 1.61 1.61 1.55 2.9a1.37 1.37 0 01-.51 1 .8.8 0 01-.92.2c-.4-.22-.56-1-.6-1.79a3.62 3.62 0 01-1 1.69 1 1 0 01-.52.2zm1.55-3.43c-1.05.94-2.17 2.19-2 2.71 0 0 .05.18.4.25a.5.5 0 00.38-.1c.56-.42 1-1.88 1.22-2.86zm.54-.07c-.11 1.39 0 2.82.33 3 .1.06.29-.08.39-.16a.9.9 0 00.35-.68 3.92 3.92 0 00-1.07-2.16z" fill="#407bff"/><path style="isolation:isolate" opacity=".2" d="M194.7 333.19l3.34-6.36 8 2.69-2.1 7.53-9.24-3.86z"/><path d="M288.12 290.82c-3.62 15.68-19.81 69.19-45 67.19S199.5 342.15 199 335.83s1.44-9.8 7.72-9.82 24.71 5.64 32.74 5.07S255 296.41 255 296.41z" fill="#407bff"/><path d="M288.12 290.82c-3.62 15.68-19.81 69.19-45 67.19S199.5 342.15 199 335.83s1.44-9.8 7.72-9.82 24.71 5.64 32.74 5.07S255 296.41 255 296.41z" style="isolation:isolate" opacity=".4"/><path fill="#e4897b" d="M352.37 403.04l-5.97 2.58-4.56-7.88-4.18-7.23 6.58-4.21 4.3 8.86 3.83 7.88z"/><path d="M345 405.79c-.27-.66 8-3.64 8-3.64s7.15 2.91 12.47 2 3.87 3.11-1.53 5.44l-13.34 5.76c-3.84 1.65-2.85-2.68-5.6-9.56z" fill="#2e353a"/><path d="M355 402.91a5.6 5.6 0 00-.61.09h-.13a.68.68 0 01-.21-.11v-.08a.08.08 0 000-.06v-.06s.05-.06.05-.09c0-.09-.11-2.27.79-3.2a1.33 1.33 0 011.07-.42q.68 0 .84.45c.16.43-.23 1.1-.74 1.74a3.68 3.68 0 011.9-.59 1 1 0 01.67.36.93.93 0 01.18 1c-.48.81-2.69.97-3.81.97zm2.8-1.88a6.36 6.36 0 00-2.73 1.32c1.41 0 3.08-.21 3.33-.68 0 0 .08-.17-.13-.45a.47.47 0 00-.36-.18zm-1.87-2c-.27 0-.49.31-.67.5a4.1 4.1 0 00-.63 2.44c1-1 1.88-2.26 1.74-2.63a.6.6 0 00-.4-.31z" fill="#407bff"/><path style="isolation:isolate" opacity=".2" d="M348.62 395.35l-6.71 2.56-4.22-7.32 6.57-4.25 4.36 9.01z"/><path d="M257.71 259.72s-14 20.78-11.11 36.26c3.4 18.27 47.4 38.84 59.4 47.93s17.62 43.42 32.56 50l8.13-2.91s4.14-5.72 1.05-15.45c-13-40.8-23.74-60.3-59.62-84.73 0 0 2.36-19.78 1.37-29.8z" fill="#407bff"/><path d="M257.71 259.72s-14 20.78-11.11 36.26c3.4 18.27 47.4 38.84 59.4 47.93s17.62 43.42 32.56 50l8.13-2.91s4.14-5.72 1.05-15.45c-13-40.8-23.74-60.3-59.62-84.73 0 0 2.36-19.78 1.37-29.8z" style="isolation:isolate" opacity=".3"/><path d="M342.38 392.54l-2 .72c-4.54-5.78-8.25-16.2-12.14-27.14-4.13-11.59-8.4-23.57-13.43-28.33-3.5-3.31-11.26-8.52-20.25-14.56-18.35-12.33-39.16-26.3-40.55-34.82-1.47-9.06 3.16-22 5.93-28.6l2.14.09c-2.63 6.23-7.53 19.41-6.09 28.19 1.25 7.66 23.46 22.59 39.68 33.48 9.07 6.09 16.89 11.34 20.52 14.77 5.37 5.09 9.53 16.75 13.93 29.11 3.8 10.67 7.72 21.68 12.26 27.09z" fill="#407bff"/><path d="M288.12 290.82S280.75 286 271.5 280l13.5 5.41a55.44 55.44 0 004.71-19.48 236.85 236.85 0 01-1.59 24.89Line truncated

After

Width:  |  Height:  |  Size: 8.9 KiB

+29
View File
@@ -0,0 +1,29 @@
<template>
<section class="container px-4 py-32 mx-auto">
<div class="w-full mx-auto lg:w-1/3">
<svg
xmlns="http://www.w3.org/2000/svg"
fill="none"
stroke="currentColor"
stroke-width="2"
stroke-linecap="round"
stroke-linejoin="round"
class="h-20 feather feather-alert-triangle"
viewBox="0 0 24 24"
>
<path
d="M10.29 3.86L1.82 18a2 2 0 001.71 3h16.94a2 2 0 001.71-3L13.71 3.86a2 2 0 00-3.42 0zM12 9v4M12 17h.01"
/>
</svg>
<p
class="mt-5 mb-3 text-xl font-bold text-black dark:text-gray-50 md:text-2xl"
>{{ $t('configuration_error') }}</p>
<p class="mb-3 text-base font-medium text-gray-700 dark:text-gray-400">
{{ $t('the_system_is_not_properly_configured_please_contact_the_system_administrator_for_help') }}
<br />
<br />
{{ $t('if_you_are_the_system_administrator_please_refer_to_the_official_product_documentation_readme_for_configuration_guidance') }}
</p>
</div>
</section>
</template>
+12 -2
View File
@@ -14,16 +14,26 @@
<a
target="_blank"
rel="noopener,noreferrer"
href="/impressum/"
:href="[[imprint_url]]"
class="ml-3 text-gray-400 underline"
>Impressum</a>
<a
target="_blank"
rel="noopener,noreferrer"
href="/datenschutz/"
:href="[[privacy_url]]"
class="ml-3 text-gray-400 underline"
>Datenschutzerklärung</a>
</span>
</div>
</footer>
</template>
<script>
export default {
data() {
return {
imprint_url: config.url_imprint || "/imprint/"
, privacy_url: config.url_privacy || "/privacy/"
}
},
}
</script>
-3
View File
@@ -97,11 +97,8 @@ import Toastify from "toastify-js";
let mail = ref("");
let loading = ref(false);
function login() {
console.log("ihi");
console.log(mail.value);
loading.value = true;
axios.get("").then((res) => {
console.log(res.data);
loading.value = false;
Toastify({
text: "This is a toast",
-3
View File
@@ -97,11 +97,8 @@ import Toastify from "toastify-js";
let mail = ref("");
let loading = ref(false);
function login() {
console.log("ihi");
console.log(mail.value);
loading.value = true;
axios.get("").then((res) => {
console.log(res.data);
loading.value = false;
Toastify({
text: "This is a toast",
-187
View File
@@ -1,187 +0,0 @@
<template>
<div class="min-h-screen w-full p-4">
<section class="text-white body-font">
<div class="container mx-auto flex items-center md:flex-row flex-col">
<div
class="flex flex-col md:pr-10 md:mb-0 mb-6 pr-0 w-full md:w-auto md:text-left text-center"
>
<p class="text-3xl font-bold whitespace-nowrap">Max Mustermann</p>
<p class="text-md text-gray-200 whitespace-nowrap">Musterfirma > PR</p>
</div>
<div class="inline-flex md:ml-auto md:mr-0 mx-auto items-center space-x-4">
<button
type="button"
class="focus:border-black focus:ring-2 focus:ring-black text-white text-sm py-2.5 px-5 rounded-md bg-blue-500 hover:bg-blue-600 hover:shadow-lg"
>
<svg
xmlns="http://www.w3.org/2000/svg"
width="24"
height="24"
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
stroke-width="2"
stroke-linecap="round"
stroke-linejoin="round"
class="feather feather-download"
style="display: inline;height: 1rem;vertical-align: sub;"
>
<path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" />
<polyline points="7 10 12 15 17 10" />
<line x1="12" y1="15" x2="12" y2="3" />
</svg>
{{ $t('download_certificate') }}
</button>
<button
type="button"
class="inline-flex focus:border-black focus:ring-2 focus:ring-black text-white text-sm py-2.5 px-5 rounded-md bg-green-600 hover:bg-green-800 hover:shadow-lg opacity-50"
>{{ $t('save_changes') }}</button>
</div>
</div>
</section>
<div class="flex flex-wrap">
<div class="w-full p-4">
<div class="flex flex-wrap flex-col w-full tabs">
<div class="flex lg:flex-wrap flex-row lg:space-x-2">
<div class="flex-none">
<button
@click="() => { activetab = 'profile' }"
:class="{ 'tab-active border-b-2 font-medium border-blue-500': (activetab === 'profile') }"
class="tab tab-underline py-4 px-6 block"
type="button"
>{{ $t('profile') }}</button>
</div>
<div class="flex-none">
<button
@click="() => { activetab = 'laptimes' }"
:class="{ 'tab-active border-b-2 font-medium border-blue-500': (activetab === 'laptimes') }"
class="tab tab-underline py-4 px-6 block"
type="button"
>{{ $t('lap_times') }}</button>
</div>
<div class="flex-none">
<button
@click="() => { activetab = 'sponsorings' }"
:class="{ 'tab-active border-b-2 font-medium border-blue-500': (activetab === 'sponsorings') }"
class="tab tab-underline py-4 px-6 block"
type="button"
>{{ $t('sponsoring') }}</button>
</div>
</div>
<div v-if="(activetab === 'profile')" class="tab-content block">
<div class="py-4 w-full">
<div class="flex flex-col">
<form class="form flex flex-wrap w-full">
<div class="w-full">
<div class="form-element">
<div class="form-label">{{ $t('vorname') }}</div>
<input
name="first-name"
class="w-full dark:bg-gray-800 rounded border border-gray-700 focus:border-indigo-500 focus:ring-2 focus:ring-indigo-900 text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
type="text"
:placeholder="[[$t('vorname')]]"
/>
</div>
<div class="form-element">
<div class="form-label">{{ $t('mittelname') }}</div>
<input
name="middle-name"
class="w-full dark:bg-gray-800 rounded border border-gray-700 focus:border-indigo-500 focus:ring-2 focus:ring-indigo-900 text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
type="text"
:placeholder="[[$t('mittelname')]]"
/>
</div>
<div class="form-element">
<div class="form-label">{{ $t('nachname') }}</div>
<input
name="last-name"
type="text"
class="w-full dark:bg-gray-800 rounded border border-gray-700 focus:border-indigo-500 focus:ring-2 focus:ring-indigo-900 text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
:placeholder="[[$t('nachname')]]"
/>
</div>
<div class="form-element">
<div class="form-label">{{ $t('e_mail_adress') }}</div>
<input
name="email"
type="email"
class="w-full dark:bg-gray-800 rounded border border-gray-700 focus:border-indigo-500 focus:ring-2 focus:ring-indigo-900 text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
:placeholder="[[$t('e_mail_adress')]]"
/>
</div>
<div class="form-element">
<div class="form-label">{{ $t('phone_number') }}</div>
<input
name="tel"
type="tel"
class="w-full dark:bg-gray-800 rounded border border-gray-700 focus:border-indigo-500 focus:ring-2 focus:ring-indigo-900 text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
:placeholder="[[$t('phone_number')]]"
/>
</div>
</div>
</form>
</div>
</div>
</div>
<div v-if="(activetab === 'laptimes')" class="tab-content block">
<div class="py-4 w-full">
<section class="text-gray-400 bg-gray-900 body-font">
<div class="container mx-auto">
<div class="lg:w-2/3 w-full mx-auto overflow-auto">
<table class="table-auto w-full text-left whitespace-no-wrap">
<thead>
<tr>
<th
class="px-4 py-3 title-font tracking-wider font-medium text-white text-sm bg-gray-800 rounded-tl rounded-bl"
>{{ $t('distance') }}</th>
<th
class="px-4 py-3 title-font tracking-wider font-medium text-white text-sm bg-gray-800"
>{{ $t('lap_time') }}</th>
<th
class="w-10 title-font tracking-wider font-medium text-white text-sm bg-gray-800 rounded-tr rounded-br"
></th>
</tr>
</thead>
<tbody>
<tr>
<td class="border-t-2 border-gray-800 px-4 py-3">400m</td>
<td class="border-t-2 border-gray-800 px-4 py-3">0min 57s</td>
</tr>
<tr>
<td class="border-t-2 border-gray-800 px-4 py-3">400m</td>
<td class="border-t-2 border-gray-800 px-4 py-3">1min 15s</td>
</tr>
<tr>
<td class="border-t-2 border-gray-800 px-4 py-3">1km</td>
<td class="border-t-2 border-gray-800 px-4 py-3">2min 50s</td>
</tr>
<tr>
<td class="border-t-2 border-gray-800 px-4 py-3">1km</td>
<td class="border-t-2 border-gray-800 px-4 py-3">3min 00s</td>
</tr>
</tbody>
</table>
</div>
</div>
</section>
</div>
</div>
<div v-if="(activetab === 'sponsorings')" class="tab-content block">
<div class="py-4 w-full">coming soon...</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script setup>
import { computed, ref, reactive, watch } from "vue";
import axios from "redaxios";
import isEmail from 'validator/es/lib/isEmail';
import isMobilePhone from 'validator/es/lib/isMobilePhone';
import isPostalCode from 'validator/es/lib/isPostalCode';
import { useToast } from "vue-toastification";
//
let activetab = ref("profile");
</script>
+14
View File
@@ -0,0 +1,14 @@
import * as keys_en from './locales/en.json';
import * as keys_de from './locales/de.json';
import { createI18n } from 'vue-i18n';
const messages = {
en: keys_en,
de: keys_de
};
const browserlocale = ((navigator.languages && navigator.languages[0]) || '').substr(0, 2);
export const i18n = createI18n({
locale: browserlocale,
fallbackLocale: 'en',
messages
});
+10
View File
@@ -1,20 +1,28 @@
{
"already_have_an_account": "Sie haben bereits einen Account?",
"apartment_suite_etc": "Addresszeile 2",
"configuration_error": "Konfigurationsfehler",
"confirm_personal_data": "Hiermit bestätige ich die Vollständigkeit und Richtigkeit der oben genannten Angaben",
"distance": "Distanz",
"download_certificate": "Urkunde herunterladen",
"e_mail_adress": "E-Mail Adresse",
"go_to_login": "Zum Login",
"i_accept": "Ich habe die ",
"i_accept_end": "gelesen und akzeptiert.",
"if_you_are_the_system_administrator_please_refer_to_the_official_product_documentation_readme_for_configuration_guidance": "Wenn Sie der Systemadministrator sind, finden Sie Konfigurationsanweisungen in der offiziellen Produktdokumentation / README.",
"imprint": "Impressum",
"lap_time": "Rundenzeit",
"lap_times": "Rundenzeiten",
"main_page_text": "Hier können Sie sich für den Lauf Für Kaya! registrieren oder ihr Läuferprofil verwalten.",
"mittelname": "Mittelname",
"nachname": "Nachname",
"no_laps_scans_were_recorded_yet": "Es wurden noch keine Runden / Scans aufgezeichnet ...",
"ort": "Ort",
"phone_number": "Telefonnummer",
"please_provide_a_valid_zipcode": "Bitte geben Sie eine gültige Postleitzahl an...",
"please_provide_valid_mail": "Bitte geben Sie eine gültige E-Mail Adresse an",
"plz": "PLZ",
"privacy_policy": "Datenschutzerklärung",
"profile": "Profil",
"provide_address": "Adresse angeben?",
"register": {
@@ -25,7 +33,9 @@
"save_changes": "Änderungen speichern",
"sponsoring": "Sponsoring",
"strasse": "Straße",
"the_system_is_not_properly_configured_please_contact_the_system_administrator_for_help": "Das System ist nicht richtig konfiguriert. Bitte wenden Sie sich an den Systemadministrator, um Hilfe zu erhalten.",
"this_is_not_a_valid_international_phone_number": "Dies ist keine gültige internationale Telefonnummer",
"tos": "AGBs",
"view_my_data": "Meine Läuferdaten einsehen",
"vorname": "Vorname"
}
+42 -30
View File
@@ -1,31 +1,43 @@
{
"already_have_an_account": "Already have an account?",
"apartment_suite_etc": "Apartment, suite, etc.",
"distance": "Distance",
"download_certificate": "Download certificate",
"e_mail_adress": "mail address",
"go_to_login": "Go To Login",
"lap_time": "Lap time",
"lap_times": "Lap times",
"main_page_text": "Here you can register for the Lauf Für Kaya! or manage your runner profile.",
"mittelname": "Middlename",
"nachname": "Lastname",
"ort": "City",
"phone_number": "Phone Number",
"please_provide_a_valid_zipcode": "Please provide a valid zipcode...",
"please_provide_valid_mail": "Please provide a valid mail address.",
"plz": "zipcode",
"profile": "Profile",
"provide_address": "Provide a postal address?",
"register": {
"register_now": "Register now for Lauf für Kaya! 2021."
},
"register_now": "Register now!",
"registrieren": "Register Now",
"save_changes": "Save changes",
"sponsoring": "Sponsoring",
"strasse": "Street/ Block",
"this_is_not_a_valid_international_phone_number": "This is not a valid international phone number",
"view_my_data": "View my data",
"vorname": "Firstname"
}
"already_have_an_account": "Already have an account?",
"apartment_suite_etc": "Apartment, suite, etc.",
"configuration_error": "Configuration error",
"confirm_personal_data": "I hereby confirm that the above information is complete and correct",
"distance": "Distance",
"download_certificate": "Download certificate",
"e_mail_adress": "mail address",
"go_to_login": "Go To Login",
"i_accept": "I have read and accepted the ",
"i_accept_end": "",
"if_you_are_the_system_administrator_please_refer_to_the_official_product_documentation_readme_for_configuration_guidance": "If you are the system administrator, please refer to the official product documentation/ README for configuration guidance.",
"imprint": "Imprint",
"lap_time": "Lap time",
"lap_times": "Lap times",
"main_page_text": "Here you can register for the Lauf Für Kaya! or manage your runner profile.",
"mittelname": "Middlename",
"nachname": "Lastname",
"no_laps_scans_were_recorded_yet": "No laps/ scans were recorded yet...",
"ort": "City",
"phone_number": "Phone Number",
"please_provide_a_valid_zipcode": "Please provide a valid zipcode...",
"please_provide_valid_mail": "Please provide a valid mail address.",
"plz": "zipcode",
"privacy_policy": "Privacy Policy",
"profile": "Profile",
"provide_address": "Provide a postal address?",
"register": {
"register_now": "Register now for Lauf für Kaya! 2021."
},
"register_now": "Register now!",
"registrieren": "Register Now",
"save_changes": "Save changes",
"sponsoring": "Sponsoring",
"strasse": "Street/ Block",
"the_system_is_not_properly_configured_please_contact_the_system_administrator_for_help": "The system is not properly configured. Please contact the system administrator for help.",
"this_is_not_a_valid_international_phone_number": "This is not a valid international phone number",
"tos": "Terms of Service",
"view_my_data": "View my data",
"vorname": "Firstname",
"organization": "Organization",
"you_have_been_registered": "You have been registered!"
}
+13 -29
View File
@@ -1,37 +1,21 @@
import { createApp } from 'vue';
import { createWebHistory, createRouter } from 'vue-router';
import App from './App.vue';
import { createI18n } from 'vue-i18n';
import Toast from 'vue-toastification';
import 'windi.css';
import './tailwind.css';
import 'toastify-js/src/toastify.css';
import 'vue-toastification/dist/index.css';
import * as keys_en from './locales/en.json';
import * as keys_de from './locales/de.json';
import App from './App.vue';
import { routes } from './routes.js';
import { createRouter, createWebHistory } from 'vue-router';
import { i18n } from './language';
import Toast from 'vue-toastification';
const messages = {
en: keys_en,
de: keys_de
};
const browserlocale = ((navigator.languages && navigator.languages[0]) || '').substr(0, 2);
const i18n = createI18n({
locale: browserlocale,
fallbackLocale: 'en',
messages
});
const app = createApp(App);
// ---------------
const Home = import('./components/Home.vue');
const Register = import('./components/Register.vue');
const Profile = import('./components/Profile.vue');
//
const router = createRouter({
history: createWebHistory(),
routes: [
{ path: '/', component: Home },
{ path: '/register', component: Register },
{ path: '/profile', component: Profile }
]
routes
});
// ---------------
createApp(App).use(Toast).use(i18n).use(router).mount('#app');
app.use(router);
app.use(i18n);
app.use(Toast);
app.mount('#app');
+16
View File
@@ -0,0 +1,16 @@
import EnvError from './components/EnvError.vue';
import Home from './views/Home.vue';
import Imprint from './views/Imprint.vue';
import Privacy from './views/Privacy.vue';
import Register from './views/Register.vue';
import Profile from './views/Profile.vue';
/** @type {import('vue-router').RouterOptions['routes']} */
export const routes = [
{ path: '/', component: Home },
{ path: '/imprint', component: Imprint },
{ path: '/privacy', component: Privacy },
{ path: '/register', component: Register },
{ path: '/register/:token', component: Register, props: true },
{ path: '/profile/:token', component: Profile, props: true }
];
+1
View File
@@ -0,0 +1 @@
.simplecontent *{margin:0;padding:0}.simplecontent address,.simplecontent area,.simplecontent article,.simplecontent aside,.simplecontent audio,.simplecontent blockquote,.simplecontent datalist,.simplecontent details,.simplecontent dl,.simplecontent fieldset,.simplecontent figure,.simplecontent form,.simplecontent iframe,.simplecontent img,.simplecontent input,.simplecontent meter,.simplecontent nav,.simplecontent ol,.simplecontent optgroup,.simplecontent option,.simplecontent output,.simplecontent p,.simplecontent pre,.simplecontent progress,.simplecontent ruby,.simplecontent section,.simplecontent table,.simplecontent textarea,.simplecontent ul,.simplecontent video{margin-bottom:1rem}.simplecontent button,.simplecontent html,.simplecontent input,.simplecontent select{font-family:var(--nc-font-sans)}.simplecontent body{margin:0 auto;max-width:750px;padding:2rem;border-radius:6px;overflow-x:hidden;word-break:break-word;overflow-wrap:break-word;background:var(--nc-bg-1);color:var(--nc-tx-2);font-size:1.03rem;line-height:1.5}.simplecontent h1,.simplecontent h2,.simplecontent h3,.simplecontent h4,.simplecontent h5,.simplecontent h6{line-height:1;color:var(--nc-tx-1);padding-top:.875rem}.simplecontent h1,.simplecontent h2,.simplecontent h3{color:var(--nc-tx-1);padding-bottom:2px;margin-bottom:8px;border-bottom:1px solid var(--nc-bg-2)}.simplecontent h4,.simplecontent h5,.simplecontent h6{margin-bottom:.3rem}.simplecontent h1{font-size:2.25rem}.simplecontent h2{font-size:1.85rem}.simplecontent h3{font-size:1.55rem}.simplecontent h4{font-size:1.25rem}.simplecontent h5{font-size:1rem}.simplecontent h6{font-size:.875rem}.simplecontent a{color:#3d5af1}.simplecontent a:hover{color:var(--nc-lk-2)}.simplecontent abbr:hover{cursor:help}.simplecontent blockquote{padding:1.5rem;background:#ddd;border-left:5px solid var(--nc-bg-3)}.simplecontent abbr{cursor:help}.simplecontent blockquote :last-child{padding-bottom:0;margin-bottom:0}.simplecontent header{background:#ddd;border-bottom:1px solid var(--nc-bg-3);padding:2rem 1.5rem;margin:-2rem calc(0px - (50vw - 50%)) 2rem;padding-left:calc(50vw - 50%);padding-right:calc(50vw - 50%)}.simplecontent header h1,.simplecontent header h2,.simplecontent header h3{padding-bottom:0;border-bottom:0}.simplecontent header>:first-child{margin-top:0;padding-top:0}.simplecontent header>:last-child{margin-bottom:0}.simplecontent a button,.simplecontent button,.simplecontent input[type=button],.simplecontent input[type=reset],.simplecontent input[type=submit]{font-size:1rem;display:inline-block;padding:6px 12px;text-align:center;text-decoration:none;white-space:nowrap;background:#3d5af1;color:var(--nc-lk-tx);border:0;border-radius:4px;box-sizing:border-box;cursor:pointer;color:var(--nc-lk-tx)}.simplecontent a button[disabled],.simplecontent button[disabled],.simplecontent input[type=button][disabled],.simplecontent input[type=reset][disabled],.simplecontent input[type=submit][disabled]{cursor:default;opacity:.5;cursor:not-allowed}.simplecontent .button:focus,.simplecontent .button:hover,.simplecontent button:focus,.simplecontent button:hover,.simplecontent input[type=button]:focus,.simplecontent input[type=button]:hover,.simplecontent input[type=reset]:focus,.simplecontent input[type=reset]:hover,.simplecontent input[type=submit]:focus,.simplecontent input[type=submit]:hover{background:var(--nc-lk-2)}.simplecontent code,.simplecontent kbd,.simplecontent pre,.simplecontent samp{font-family:var(--nc-font-mono)}.simplecontent code,.simplecontent kbd,.simplecontent pre,.simplecontent samp{background:#ddd;border:1px solid var(--nc-bg-3);border-radius:4px;padding:3px 6px;font-size:.9rem}.simplecontent kbd{border-bottom:3px solid var(--nc-bg-3)}.simplecontent pre{padding:1rem 1.4rem;max-width:100%;overflow:auto}.simplecontent pre code{background:inherit;font-size:inherit;color:inherit;border:0;padding:0;margin:0}.simplecontent code pre{display:inline;background:inherit;font-size:inherit;color:inherit;border:0;padding:0;margin:0}.simplecontent details{padding:.6rem 1rem;background:#ddd;border:1px solid var(--nc-bg-3);border-radius:4px}.simplecontent summary{cursor:pointer;font-weight:700}.simplecontent details[open]{padding-bottom:.75rem}.simplecontent details[open] summary{margin-bottom:6px}.simplecontent details[open]>:last-child{margin-bottom:0}.simplecontent dt{font-weight:700}.simplecontent dd::before{content:"→ "}.simplecontent hr{border:0;border-bottom:1px solid var(--nc-bg-3);margin:1rem auto}.simplecontent fieldset{margin-top:1rem;padding:2rem;border:1px solid var(--nc-bg-3);border-radius:4px}.simplecontent legend{padding:auto .5rem}.simplecontent table{border-collapse:collapse;width:100%}.simplecontent td,.simplecontent th{border:1px solid var(--nc-bg-3);text-align:left;padding:.5rem}.simplecontent th{background:#ddd}.simplecontent tr:nth-child(even){background:#ddd}.simplecontent table caption{font-weight:700;margin-bottom:.5rem}.simplecontent textarea{max-width:100%}.simplecontent ol,.sLine truncated
+3
View File
@@ -0,0 +1,3 @@
@import 'tailwindcss/base';
@import 'tailwindcss/components';
@import 'tailwindcss/utilities';
@@ -25,6 +25,5 @@
</template>
<script setup>
import LoginForm from "./LoginForm.vue";
import Footer from "./Footer.vue";
import Footer from "@/components/Footer.vue";
</script>
+38
View File
@@ -0,0 +1,38 @@
<template>
<section class="container px-4 py-24 mx-auto">
<div class="simplecontent">
<div class="mb-24 text-left md:text-center">
<h1
class="mb-4 text-4xl font-bold leading-tight text-gray-900 dark:text-gray-50 md:text-5xl"
>{{$t('imprint')}}</h1>
</div>
<div class="mx-auto prose" v-html="content"></div>
</div>
</section>
</template>
<style src="../simple.css">
</style>
<script>
import marked from "marked";
export default {
data() {
return {
content: ""
}
},
async beforeMount() {
const browserlocale = ((navigator.languages && navigator.languages[0]) || '').substr(0, 2);
let md = "";
try {
md = await fetch(`/imprint_${browserlocale}.md`);
} catch (error) {
try {
md = await fetch(`/imprint_en.md`);
} catch (error) {
md = "Error loading Imprint";
}
}
this.content = marked(await md.text());
},
}
</script>
+38
View File
@@ -0,0 +1,38 @@
<template>
<section class="container px-4 py-24 mx-auto">
<div class="simplecontent">
<div class="mb-24 text-left md:text-center">
<h1
class="mb-4 text-4xl font-bold leading-tight text-gray-900 dark:text-gray-50 md:text-5xl"
>{{ $t('privacy_policy') }}</h1>
</div>
<div class="mx-auto prose" v-html="content"></div>
</div>
</section>
</template>
<style src="../simple.css">
</style>
<script>
import marked from "marked";
export default {
data() {
return {
content: ""
}
},
async beforeMount() {
const browserlocale = ((navigator.languages && navigator.languages[0]) || '').substr(0, 2);
let md = "";
try {
md = await fetch(`/privacy_${browserlocale}.md`);
} catch (error) {
try {
md = await fetch(`/privacy_en.md`);
} catch (error) {
md = "Error loading Privacy Policy";
}
}
this.content = marked(await md.text());
},
}
</script>
+209
View File
@@ -0,0 +1,209 @@
<template>
<div class="min-h-screen w-full p-4">
<section class="text-white body-font">
<div class="container mx-auto flex items-center md:flex-row flex-col">
<div
class="flex flex-col md:pr-10 md:mb-0 mb-6 pr-0 w-full md:w-auto md:text-left text-center text-black dark:text-gray-200"
>
<p
class="text-3xl font-bold whitespace-nowrap"
v-text="(state.firstname || '') + ' ' + (state.middlename || '') + ' ' + (state.lastname || '')"
></p>
<p class="text-md whitespace-nowrap">{{ state.group }}</p>
</div>
<div class="inline-flex md:ml-auto md:mr-0 mx-auto items-center">
<button
type="button"
class="focus:border-black focus:ring-2 focus:ring-black text-white text-sm py-2.5 px-5 rounded-md bg-blue-500 hover:bg-blue-600 hover:shadow-lg"
>
<svg
xmlns="http://www.w3.org/2000/svg"
width="24"
height="24"
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
stroke-width="2"
stroke-linecap="round"
stroke-linejoin="round"
class="feather feather-download"
style="display: inline;height: 1rem;vertical-align: sub;"
>
<path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" />
<polyline points="7 10 12 15 17 10" />
<line x1="12" y1="15" x2="12" y2="3" />
</svg>
{{ $t('download_certificate') }}
</button>
</div>
</div>
</section>
<div class="flex flex-wrap">
<div class="w-full p-4">
<div class="flex flex-wrap flex-col w-full tabs">
<div class="flex lg:flex-wrap flex-row lg:space-x-2">
<div class="flex-none">
<button
@click="() => { state.activetab = 'profile' }"
:class="{ 'tab-active border-b-2 font-medium border-blue-500': (state.activetab === 'profile') }"
class="tab tab-underline py-4 px-6 block"
type="button"
>{{ $t('profile') }}</button>
</div>
<div class="flex-none">
<button
@click="() => { state.activetab = 'laptimes' }"
:class="{ 'tab-active border-b-2 font-medium border-blue-500': (state.activetab === 'laptimes') }"
class="tab tab-underline py-4 px-6 block"
type="button"
>{{ $t('lap_times') }}</button>
</div>
<div class="flex-none">
<button
@click="() => { state.activetab = 'sponsorings' }"
:class="{ 'tab-active border-b-2 font-medium border-blue-500': (state.activetab === 'sponsorings') }"
class="tab tab-underline py-4 px-6 block"
type="button"
>{{ $t('sponsoring') }}</button>
</div>
</div>
<div v-if="(state.activetab === 'profile')" class="tab-content block">
<div class="py-4 w-full">
<div class="flex flex-col">
<form class="form flex flex-wrap w-full">
<div class="w-full">
<div class="form-element">
<div class="text-lg">{{ $t('vorname') }}</div>
<p
class="h-10 w-full dark:bg-gray-800 rounded text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
v-text="state.firstname"
/>
</div>
<div class="form-element">
<div class="text-lg">{{ $t('mittelname') }}</div>
<p
class="h-10 w-full dark:bg-gray-800 rounded text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
v-text="state.middlename"
/>
</div>
<div class="form-element">
<div class="text-lg">{{ $t('nachname') }}</div>
<p
class="h-10 w-full dark:bg-gray-800 rounded text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
v-text="state.lastname"
/>
</div>
<div class="form-element">
<div class="text-lg">{{ $t('e_mail_adress') }}</div>
<p
class="h-10 w-full dark:bg-gray-800 rounded text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
v-text="state.email"
/>
</div>
<div class="form-element">
<div class="text-lg">{{ $t('phone_number') }}</div>
<p
class="h-10 w-full dark:bg-gray-800 rounded text-base outline-none dark:text-gray-100 text-gray-600 py-1 px-3 leading-8 transition-colors duration-200 ease-in-out"
v-text="state.phone"
/>
</div>
</div>
</form>
</div>
</div>
</div>
<div v-if="(state.activetab === 'laptimes')" class="tab-content block">
<div class="py-4 w-full">
<section class="text-gray-400 dark:bg-gray-900 body-font">
<div class="container mx-auto">
<div class="lg:w-2/3 w-full mx-auto overflow-auto">
<table
v-if="state.scans.length > 0"
class="table-auto w-full text-left whitespace-no-wrap"
>
<thead
class="text-black bg-gray-300 dark:text-white text-sm dark:bg-gray-800"
>
<tr>
<th
class="px-4 py-3 title-font tracking-wider font-medium"
>{{ $t('distance') }}</th>
<th
class="px-4 py-3 title-font tracking-wider font-medium"
>{{ $t('lap_time') }}</th>
</tr>
</thead>
<tbody class="text-gray-900 dark:text-gray-50">
<tr v-for="s in state.scans" :key="s.id">
<td class="px-4 py-3">
<span v-text="s.distance"></span>m
</td>
<td class="px-4 py-3" v-text="s.lapTime"></td>
</tr>
</tbody>
</table>
<div v-else class="text-center font-bold text-black dark:text-white text-2xl">
<img
src="../assets/empty_laps.svg"
style="height:25rem; margin:0 auto;"
:alt="[[$t('no_laps_scans_were_recorded_yet')]]"
/>
{{ $t('no_laps_scans_were_recorded_yet') }}
</div>
</div>
</div>
</section>
</div>
</div>
<div v-if="(state.activetab === 'sponsorings')" class="tab-content block">
<div class="py-4 w-full">coming soon...</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script setup>
import { reactive } from "vue";
import { useToast } from "vue-toastification";
import axios from "redaxios";
const state = reactive({
phone: "",
email: "",
firstname: "",
middlename: "",
lastname: "",
scans: [],
group: "",
activetab: "profile",
})
const toast = useToast();
const props = defineProps({
token: String
})
const accesstoken = atob(props.token);
axios.get(`${config.baseurl_selfservice}/api/runners/me/${accesstoken}`)
.then(({ data }) => {
state.phone = data.phone;
state.email = data.email;
state.firstname = data.firstname;
state.middlename = data.middlename;
state.lastname = data.lastname;
state.group = data.group;
}).catch((error) => {
toast.error("An error occured while loading your profile data");
})
axios.get(`${config.baseurl}api/runners/me/${accesstoken}/scans`)
.then(({ data }) => {
data.map(function(s) {
s.lapTime = Math.floor(s.lapTime / 60) + 'min ' + (Math.floor(s.lapTime % 60) + "").padStart(2, "0") + "s"
return s;
})
data.filter(s => s.valid === true);
state.scans = data;
}).catch((error) => {
toast.error("An error occured while loading your profile data");
})
</script>
@@ -6,6 +6,25 @@
class="sm:text-3xl text-2xl font-medium title-font mb-4 text-center"
>Lauf für Kaya! - {{ $t('registrieren') }}</h1>
<p class="mx-auto leading-relaxed text-base text-center">{{ $t('register.register_now') }}</p>
<p
v-if="state.org_name !== ''"
class="mx-auto leading-relaxed text-base text-center"
>{{ $t('organization') }}: {{ state.org_name }}</p>
<p
v-if="state.org_name !== '' && state.org_teams.length > 0"
class="mx-auto leading-relaxed text-base text-center"
>Team:</p>
<select
v-model="org_team"
v-if="state.org_name !== '' && state.org_teams.length > 0"
class="w-full border bg-white rounded px-3 py-2 outline-none block mt-1 text-sm dark:text-gray-300 dark:border-gray-600 dark:bg-gray-700 form-select focus:border-purple-400 focus:outline-none focus:shadow-outline-purple dark:focus:shadow-outline-gray"
>
<option v-for="t in state.org_teams" :key="t.id" :value="t.id">{{ t.name }}</option>
</select>
<p
v-if="state.org_name === ''"
class="mx-auto leading-relaxed text-base text-center"
>Bürgerlauf</p>
<div class="mt-4">
<label for="first_name" class="block font-medium">
{{ $t('vorname') }}
@@ -177,8 +196,31 @@
</div>
<div class="ml-3 text-sm">
<label for="agb_accepted" class="font-medium text-gray-400 select-none">
Ich habe die
<a target="_blank" rel="noreferrer,noopener" href class="underline">AGBs</a> gelesen und akzeptiert.
{{ $t('i_accept', { tos: $t('tos') }) }}
<a
target="_blank"
rel="noreferrer,noopener"
href
class="underline"
>{{ $t('tos') }}</a>
{{ $t('i_accept_end') }}
<span class="font-bold">*</span>
</label>
</div>
</div>
<div class="flex items-start mt-6">
<div class="flex items-center h-5">
<input
v-model="data_confirmed"
id="data_confirmed"
name="data_confirmed"
type="checkbox"
class="h-4 w-4 text-indigo-600 border-gray-300 rounded"
/>
</div>
<div class="ml-3 text-sm">
<label for="data_confirmed" class="font-medium text-gray-400 select-none">
{{ $t('confirm_personal_data') }}
<span class="font-bold">*</span>
</label>
</div>
@@ -213,19 +255,41 @@
</template>
<script setup>
import { computed, ref, reactive, watch } from "vue";
import { computed, ref, reactive, defineProps } from "vue";
import axios from "redaxios";
import isEmail from 'validator/es/lib/isEmail';
import isMobilePhone from 'validator/es/lib/isMobilePhone';
import isPostalCode from 'validator/es/lib/isPostalCode';
import { useToast } from "vue-toastification";
// import { router } from '../router';
import { i18n } from '../language';
const props = defineProps({
token: String
})
if (props.token) {
props.token = atob(props.token);
axios.get(`${config.baseurl}api/organizations/selfservice/${props.token}`)
.then(({ data }) => {
state.org_name = data.name;
state.org_teams = data.teams;
org_team.value = data.teams[0]?.id;
})
.catch((error) => {
console.log(error);
});
}
let userdetails = ref({ firstname: "", lastname: "", middlename: "", mail: "", phone: "", address: { street: "", address2: "", city: "", zipcode: "" } });
let provide_address = ref(false);
let agb_accepted = ref(false);
let data_confirmed = ref(false);
let org_team = ref("");
//
const state = reactive({
submit_enabled: computed(() => agb_accepted.value === true && (isMobilePhone(userdetails.value.phone) || !userdetails.value.phone.trim()) && isEmail(userdetails.value.mail)
org_name: "",
org_teams: [],
submit_enabled: computed(() => agb_accepted.value === true && data_confirmed.value === true && (isMobilePhone(userdetails.value.phone) || !userdetails.value.phone.trim()) && isEmail(userdetails.value.mail)
&& userdetails.value.firstname
&& userdetails.value.lastname && (provide_address.value === false || provide_address.value === true && (userdetails.value.address.street.trim() && userdetails.value.address.city.trim() && isPostalCode(userdetails.value.address.zipcode, "DE"))))
})
@@ -253,16 +317,18 @@ function login() {
country: "DE",
}
}
if (state.org_name !== '' && state.org_teams.length > 0) {
postdata.team = org_team.value;
}
toast("registration in progress...");
axios.post('https://dev.lauf-fuer-kaya.de/api/runners/register', postdata)
.then((response) => {
response = response.data;
const token = response.token;
const userid = JSON.parse(atob(token.split(".")[1])).id;
console.log({ token });
console.log({ userid });
//
toast.success("You have been registered!");
let url = `${config.baseurl}api/runners/register`;
if (props.token) {
url = `${config.baseurl}api/runners/register/${props.token}`
}
axios.post(url, postdata)
.then(({ data }) => {
const token = btoa(data.token);
// router.push(`${config.baseurl_selfservice}/profile/${token}`);
})
.catch((error) => {
console.log(error);
+10 -7
View File
@@ -1,9 +1,12 @@
import { defineConfig } from 'vite';
import vue from '@vitejs/plugin-vue';
import WindiCSS from 'vite-plugin-windicss';
import path from 'path';
/**
* @type {import('vite').UserConfig}
*/
export default {
plugins: [ vue(), WindiCSS() ]
};
export default defineConfig({
plugins: [ vue() ],
resolve: {
alias: {
'@': path.resolve(__dirname, '/src')
}
}
});