Compare commits
	
		
			10 Commits
		
	
	
		
			2139b197ba
			...
			1.13.4
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| bbf659e52d | |||
| 30a26ef3ed | |||
| ca066aa7a7 | |||
| 7d9314f05c | |||
| 3842d8b104 | |||
| a827279163 | |||
| b0063cdead | |||
| 9298a0dc92 | |||
| b9e2e65331 | |||
| 27e7bbb9d1 | 
							
								
								
									
										15
									
								
								CHANGELOG.md
									
									
									
									
									
								
							
							
						
						
									
										15
									
								
								CHANGELOG.md
									
									
									
									
									
								
							| @@ -2,8 +2,23 @@ | ||||
|  | ||||
| All notable changes to this project will be documented in this file. Dates are displayed in UTC. | ||||
|  | ||||
| #### [1.13.4](https://git.odit.services/lfk/frontend/compare/1.13.3...1.13.4) | ||||
|  | ||||
| - feat(donationcreate): improved focus handling [`a827279`](https://git.odit.services/lfk/frontend/commit/a82727916345c7e713d4225c4771ef3f23d1392c) | ||||
| - chore(deps): remove unused [`3842d8b`](https://git.odit.services/lfk/frontend/commit/3842d8b1048ce12f0f70bf3d0530590470f0d200) | ||||
| - fix(donationcreate): clearing [`9298a0d`](https://git.odit.services/lfk/frontend/commit/9298a0dc922ee5ed5b7c9017c865ad4b68fca3c8) | ||||
| - feat(donationcreate): autofocus runner input on page load [`b9e2e65`](https://git.odit.services/lfk/frontend/commit/b9e2e653310c686bc06b9f27c38b49e9c6a3eaef) | ||||
| - fix(DonationCreate): remove duplicate spaces from getRunnerLabel [`30a26ef`](https://git.odit.services/lfk/frontend/commit/30a26ef3ed55d072cd9bf2aea1b200fadc2a05f1) | ||||
| - fix(donationcreate): improved resetAll [`7d9314f`](https://git.odit.services/lfk/frontend/commit/7d9314f05c58c1b50901f3797c0b461c4c79e5d2) | ||||
| - fix(DeleteDonationModal): cannot overflow [`ca066aa`](https://git.odit.services/lfk/frontend/commit/ca066aa7a7a8d7c46e0f59370b06636faf5736ca) | ||||
| - feat(donationcreate): full width [`b0063cd`](https://git.odit.services/lfk/frontend/commit/b0063cdead5f71c334c36e5587a58e957825dbcd) | ||||
| - feat(donationcreate): add runner id to select [`27e7bbb`](https://git.odit.services/lfk/frontend/commit/27e7bbb9d142fbea659e89fb2335cc6c567d14ce) | ||||
|  | ||||
| #### [1.13.3](https://git.odit.services/lfk/frontend/compare/1.13.2...1.13.3) | ||||
|  | ||||
| > 19 May 2025 | ||||
|  | ||||
| - chore(release): 1.13.3 [`2139b19`](https://git.odit.services/lfk/frontend/commit/2139b197ba672275e2a0b5ffbcf7fa43f80874e6) | ||||
| - Refactor code structure for improved readability and maintainability [`e3c6d5a`](https://git.odit.services/lfk/frontend/commit/e3c6d5a5c0eaac2c91432b0be37d6fa11e57f644) | ||||
| - refactor(donation): Refactor donor selection and add new donor creation functionality [`8c3f009`](https://git.odit.services/lfk/frontend/commit/8c3f0092d2735b1c85976f4e6955780b1035f68a) | ||||
| - fix(donation): Ensure all selections are cleared on reset [`4e1a944`](https://git.odit.services/lfk/frontend/commit/4e1a944a2d7d0d0666fb8d2181a9941d0f11957f) | ||||
|   | ||||
| @@ -13,7 +13,7 @@ | ||||
|  | ||||
|   <body> | ||||
|     <span style="display: none; visibility: hidden" id="buildinfo" | ||||
|       >RELEASE_INFO-1.13.3-RELEASE_INFO</span | ||||
|       >RELEASE_INFO-1.13.4-RELEASE_INFO</span | ||||
|     > | ||||
|     <noscript>You need to enable JavaScript to run this app.</noscript> | ||||
|     <script src="/env.js"></script> | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| { | ||||
|   "name": "@odit/lfk-frontend", | ||||
|   "version": "1.13.3", | ||||
|   "version": "1.13.4", | ||||
|   "type": "module", | ||||
|   "scripts": { | ||||
|     "i18n-order": "node order.js", | ||||
| @@ -52,7 +52,6 @@ | ||||
|     "html5-qrcode": "^2.3.8", | ||||
|     "localforage": "1.10.0", | ||||
|     "papaparse": "^5.5.2", | ||||
|     "svelecte": "3", | ||||
|     "svelte": "3.58.0", | ||||
|     "svelte-french-toast": "1.2.0", | ||||
|     "svelte-i18n": "4.0.1", | ||||
|   | ||||
							
								
								
									
										15
									
								
								pnpm-lock.yaml
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										15
									
								
								pnpm-lock.yaml
									
									
									
										generated
									
									
									
								
							| @@ -38,9 +38,6 @@ importers: | ||||
|       papaparse: | ||||
|         specifier: ^5.5.2 | ||||
|         version: 5.5.2 | ||||
|       svelecte: | ||||
|         specifier: '3' | ||||
|         version: 3.17.3 | ||||
|       svelte: | ||||
|         specifier: 3.58.0 | ||||
|         version: 3.58.0 | ||||
| @@ -1986,9 +1983,6 @@ packages: | ||||
|     resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} | ||||
|     engines: {node: '>= 0.4'} | ||||
|  | ||||
|   svelecte@3.17.3: | ||||
|     resolution: {integrity: sha512-wnvoRxJIFFkm+CmXgjL4R3i/TcuYUIBkE+jDJSBD7AdSOzk1K6u3+nW4zwxaGT29zyZpiZkWeiy7lO62r5F+tg==} | ||||
|  | ||||
|   svelte-french-toast@1.2.0: | ||||
|     resolution: {integrity: sha512-5PW+6RFX3xQPbR44CngYAP1Sd9oCq9P2FOox4FZffzJuZI2mHOB7q5gJBVnOiLF5y3moVGZ7u2bYt7+yPAgcEQ==} | ||||
|     peerDependencies: | ||||
| @@ -2010,9 +2004,6 @@ packages: | ||||
|   svelte-select@3.17.0: | ||||
|     resolution: {integrity: sha512-ITmX/XUiSdkaILmsTviKRkZPaXckM5/FA7Y8BhiUPoamaZG/ZDyOo6ydjFu9fDVFTbwoAUGUi6HBjs+ZdK2AwA==} | ||||
|  | ||||
|   svelte-tiny-virtual-list@2.1.2: | ||||
|     resolution: {integrity: sha512-jeP/WMvgFUR4mYXHGPiCexjX5DuzSO+3xzHNhxfcsFyy+uYPtnqI5UGb383swpzQAyXB0OBqYfzpYihD/5gxnA==} | ||||
|  | ||||
|   svelte-writable-derived@3.1.1: | ||||
|     resolution: {integrity: sha512-w4LR6/bYZEuCs7SGr+M54oipk/UQKtiMadyOhW0PTwAtJ/Ai12QS77sLngEcfBx2q4H8ZBQucc9ktSA5sUGZWw==} | ||||
|     peerDependencies: | ||||
| @@ -3955,10 +3946,6 @@ snapshots: | ||||
|  | ||||
|   supports-preserve-symlinks-flag@1.0.0: {} | ||||
|  | ||||
|   svelecte@3.17.3: | ||||
|     dependencies: | ||||
|       svelte-tiny-virtual-list: 2.1.2 | ||||
|  | ||||
|   svelte-french-toast@1.2.0(svelte@3.58.0): | ||||
|     dependencies: | ||||
|       svelte: 3.58.0 | ||||
| @@ -3981,8 +3968,6 @@ snapshots: | ||||
|  | ||||
|   svelte-select@3.17.0: {} | ||||
|  | ||||
|   svelte-tiny-virtual-list@2.1.2: {} | ||||
|  | ||||
|   svelte-writable-derived@3.1.1(svelte@3.58.0): | ||||
|     dependencies: | ||||
|       svelte: 3.58.0 | ||||
|   | ||||
| @@ -81,7 +81,7 @@ | ||||
|                 /></svg | ||||
|               > | ||||
|             </div> | ||||
|             <div class="mt-3 sm:text-left max-h-[75vh] overflow-y-auto"> | ||||
|             <div class="mt-3 sm:text-left max-h-[75vh]"> | ||||
|               <h3 class="text-lg leading-6 font-medium text-gray-900"> | ||||
|                 {$_("please-confirm-the-deletion-of-donation")} | ||||
|               </h3> | ||||
|   | ||||
| @@ -7,6 +7,7 @@ | ||||
|   } from "@odit/lfk-client-js"; | ||||
|   import Select from "svelte-select"; | ||||
|   import toast from "svelte-french-toast"; | ||||
| 	import { onMount } from "svelte"; | ||||
|  | ||||
|   let runners = []; | ||||
|   let donors = []; | ||||
| @@ -19,7 +20,7 @@ | ||||
|     postalcode: "", | ||||
|     country: "Germany", | ||||
|   }; | ||||
|   let amount = 0; | ||||
|   let amount = null; | ||||
|   let address_checked = false; | ||||
|   let donor_create_new = false; | ||||
|   let last_created = null; | ||||
| @@ -51,8 +52,9 @@ | ||||
|   } | ||||
|   loadDonors(); | ||||
|  | ||||
|   const getRunnerLabel = (option) => | ||||
|     option.firstname + " " + (option.middlename || "") + " " + option.lastname; | ||||
|   const getRunnerLabel = (option) => { | ||||
|     return [option.firstname,option.middlename,option.lastname].join(" ").replace("  "," ") + " [#"+option.id+"]"; | ||||
|   } | ||||
|  | ||||
|   const filterRunners = (label, filterText, option) => { | ||||
|     if (filterText.startsWith("#")) { | ||||
| @@ -67,21 +69,28 @@ | ||||
|   function resetAll() { | ||||
|     runnerinfo = { id: 0, firstname: "", lastname: "" }; | ||||
|     donorinfo = { id: 0, firstname: "", lastname: "" }; | ||||
|     amount = 0; | ||||
|     amount = null; | ||||
|     address_checked = false; | ||||
|     donor_create_new = false; | ||||
|     const clears = document.getElementsByClassName("clearSelect"); | ||||
|     for (let i = 0; i < clears.length; i++) { | ||||
|       clears[i].click(); | ||||
|     } | ||||
|     const clears = document.querySelectorAll(".clearSelect"); | ||||
|     clears.forEach(c => { | ||||
|       c.click(); | ||||
|     }); | ||||
|     setTimeout(() => { | ||||
|       document.querySelector("#wrapper_runner_select input").focus(); | ||||
|     }, 50); | ||||
|   } | ||||
|  | ||||
|   onMount(() => { | ||||
|     document.querySelector("#wrapper_runner_select input").focus(); | ||||
|   }) | ||||
| </script> | ||||
|  | ||||
| <div class="p-4"> | ||||
|   <h3 class="text-3xl font-bold">{$_("fast_donation_create")}</h3> | ||||
|   <!--  --> | ||||
|   <div> | ||||
|     <div class="w-full max-w-md space-y-4 mb-6"> | ||||
|     <div class="w-full space-y-4 mb-6"> | ||||
|       {#if last_created} | ||||
|         <div class="mt-4 p-3 bg-green-50 border border-green-200 rounded-md"> | ||||
|           <p class="text-black"> | ||||
| @@ -94,7 +103,7 @@ | ||||
|       {/if} | ||||
|  | ||||
|       <!-- Runner Selection --> | ||||
|       <div> | ||||
|       <div id="wrapper_runner_select"> | ||||
|         <h4 class="text-xl font-semibold">{$_("runner")}</h4> | ||||
|         <Select | ||||
|           containerClasses="rounded-md mt-1 focus:ring-indigo-500 focus:border-indigo-500 block w-full shadow-sm sm:text-sm border-gray-300 border bg-gray-50 text-neutral-800 rounded-md p-2" | ||||
| @@ -106,6 +115,7 @@ | ||||
|           noOptionsMessage={$_("no-runners-found")} | ||||
|           on:select={(selectedValue) => { | ||||
|             runnerinfo = selectedValue.detail.value; | ||||
|             document.querySelector("#donation_amount_eur").focus(); | ||||
|           }} | ||||
|           on:clear={() => (runnerinfo = { id: 0, firstname: "", lastname: "" })} | ||||
|         /> | ||||
| @@ -121,11 +131,19 @@ | ||||
|             class:focus:border-red-500={!amount > 0} | ||||
|             class:focus:ring-red-500={!amount > 0} | ||||
|             bind:value={amount} | ||||
|             on:keydown={(e)=> | ||||
|             { | ||||
|               if(e.key==="Enter"){ | ||||
|                 e.preventDefault(); | ||||
|                 document.querySelector("#button_existing_donor").focus(); | ||||
|               } | ||||
|             }} | ||||
|             type="number" | ||||
|             step="0.01" | ||||
|             id="donation_amount_eur" | ||||
|             name="donation_amount_eur" | ||||
|             class="focus:ring-indigo-500 focus:border-indigo-500 flex-1 block w-full rounded-none rounded-l-md sm:text-sm border-neutral-300 border bg-neutral-50 text-neutral-800 p-2" | ||||
|             placeholder="2.00" | ||||
|             placeholder="z.B. 1,50" | ||||
|           /> | ||||
|           <span | ||||
|             class="inline-flex items-center px-3 rounded-r-md border border-neutral-300 bg-neutral-50 text-neutral-500 text-sm" | ||||
| @@ -142,17 +160,35 @@ | ||||
|         <div class="mb-2"> | ||||
|           <div class="flex border rounded-md overflow-hidden shadow-sm"> | ||||
|             <button | ||||
|               class:bg-indigo-600={!donor_create_new} | ||||
|               class:text-white={!donor_create_new} | ||||
|               class="py-2 px-4 w-1/2 transition-colors" | ||||
|               on:click={() => { | ||||
|                 donor_create_new = false; | ||||
|                 donorinfo = { id: 0, firstname: "", lastname: "" }; | ||||
|               }} | ||||
|             on:keydown={(e)=> | ||||
|             { | ||||
|               if(e.key==="ArrowRight"){ | ||||
|                 e.preventDefault(); | ||||
|                 document.querySelector("#button_new_donor").focus(); | ||||
|                 document.querySelector("#button_new_donor").click(); | ||||
|               } | ||||
|             }} | ||||
|             id="button_existing_donor" | ||||
|             class:bg-indigo-600={!donor_create_new} | ||||
|             class:text-white={!donor_create_new} | ||||
|             class="py-2 px-4 w-1/2 transition-colors" | ||||
|             on:click={() => { | ||||
|               donor_create_new = false; | ||||
|               donorinfo = { id: 0, firstname: "", lastname: "" }; | ||||
|             }} | ||||
|             > | ||||
|               {$_("existing-donor")} | ||||
|             </button> | ||||
|             <button | ||||
|             {$_("existing-donor")} | ||||
|           </button> | ||||
|           <button | ||||
|               on:keydown={(e)=> | ||||
|               { | ||||
|                 if(e.key==="ArrowLeft"){ | ||||
|                   e.preventDefault(); | ||||
|                   document.querySelector("#button_existing_donor").focus(); | ||||
|                   document.querySelector("#button_existing_donor").click(); | ||||
|                 } | ||||
|               }} | ||||
|               id="button_new_donor" | ||||
|               class={`py-2 px-4 w-1/2 transition-colors ${donor_create_new ? "bg-indigo-600 text-white" : "bg-gray-100 text-gray-700"}`} | ||||
|               on:click={() => { | ||||
|                 donor_create_new = true; | ||||
| @@ -306,6 +342,7 @@ | ||||
|       <!-- Submit Button --> | ||||
|       <div class="mt-6"> | ||||
|         <button | ||||
|           id="submit_button" | ||||
|           type="button" | ||||
|           class="w-full inline-flex justify-center py-2 px-4 border border-transparent shadow-sm text-sm font-medium rounded-md text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 disabled:bg-gray-400 disabled:cursor-not-allowed" | ||||
|           disabled={!amount > 0 || | ||||
|   | ||||
		Reference in New Issue
	
	Block a user