Merge pull request #396 from IBCornelsen/main

get main
This commit is contained in:
Jens Cornelsen
2025-02-24 00:15:13 +01:00
committed by GitHub
21 changed files with 200 additions and 218 deletions

View File

@@ -87,7 +87,7 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
name="rechnung_ort"
type="text"
required
value={rechnung.ort}
bind:value={rechnung.ort}
/>
<div class="help-label">

View File

@@ -105,7 +105,7 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
name="primaere_heizquelle"
checked={true}
/>
<label for="primaere_heizquelle">primäre Heizquelle</label>
<label for="primaere_heizquelle">Heizquelle</label>
</div>
</div>
@@ -135,7 +135,7 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
/>
<label
for="zusaetzliche_heizquelle_1"
class="cursor-pointer">zusätzliche Heizquelle</label
class="cursor-pointer">zusätzl. Heizquelle</label
>
</div>
</div>
@@ -276,7 +276,7 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
disabled={!aufnahme.brennstoff_1}
required
>
<option disabled selected >Bitte auswählen</option>
<option disabled selected>Bitte auswählen</option>
{#each fuelMap.hasOwnProperty(aufnahme.brennstoff_1) ? fuelMap[aufnahme.brennstoff_1] : [] as unit}
<option value={unit}>{unit}</option>
{/each}
@@ -307,7 +307,10 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
/>
<div class="VerbrauchsEinheit">
{#if ausweis.einheit_1}{ausweis.einheit_1}{/if}
{#if ausweis.einheit_1 === "Bitte auswählen"}
{:else if ausweis.einheit_1 != "Bitte auswählen"}
{ausweis.einheit_1}
{/if}
</div>
<div class="help-label">
@@ -335,7 +338,10 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
required
/>
<div class="VerbrauchsEinheit">
{#if ausweis.einheit_1}{ausweis.einheit_1}{/if}
{#if ausweis.einheit_1 === "Bitte auswählen"}
{:else if ausweis.einheit_1 != "Bitte auswählen"}
{ausweis.einheit_1}
{/if}
</div>
<div class="help-label">
@@ -363,7 +369,10 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
required
/>
<div class="VerbrauchsEinheit">
{#if ausweis.einheit_1}{ausweis.einheit_1}{/if}
{#if ausweis.einheit_1 === "Bitte auswählen"}
{:else if ausweis.einheit_1 != "Bitte auswählen"}
{ausweis.einheit_1}
{/if}
</div>
<div class="help-label">
@@ -380,12 +389,12 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
{#if ausweis.zusaetzliche_heizquelle}
<div
class="col-span-3 order-7 md:order-7 xl:order-7 h-[4px] bg-white mt-[-10px]"
class="hidden sm:block col-span-3 order-7 md:order-7 xl:order-7 h-[4px] bg-white mt-[-10px]"
></div>
<!-- zusätzliche Heizquelle -->
<div class="input-standard order-7 md:order-7 xl:order-7">
<div class="input-standard order-10 md:order-10 xl:order-10">
<Inputlabel title="zusätzliche Heizquelle"></Inputlabel>
<div class="input-checkboxen">
@@ -400,7 +409,7 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
bind:checked={ausweis.zusaetzliche_heizquelle}
/>
<label for="zusaetzliche_heizquelle" class="cursor-pointer"
>zusätzliche Heizquelle</label
>zusätzl. Heizquelle</label
>
</div>
</div>
@@ -416,11 +425,11 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
</div>
</div>
<div class="input-standard order-8 md:order-8 xl:order-8"></div>
<div class="hidden sm:block input-standard order-11 md:order-11 xl:order-11"></div>
<!-- zusätzlicher Brennstoff und Einheiten * -->
<div class="grid grid-cols-2 gap-x-4 order-9 md:order-9 xl:order-9">
<div class="grid grid-cols-2 gap-x-4 order-12 md:order-12 xl:order-12">
<div class="input-standard">
<Inputlabel title="zusätzlicher Brennstoff *"></Inputlabel>
@@ -496,7 +505,7 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
<!-- Verbrauch 4 -->
<div class="input-standard order-10 md:order-10 xl:order-10">
<div class="input-standard order-[13] md:order-[13] xl:order-[13]">
<Verbrauchslabel bind:ausweis addYear={1}></Verbrauchslabel>
<input
@@ -523,7 +532,7 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
<!-- Verbrauch 5 -->
<div class="input-standard order-11 md:order-11 xl:order-11">
<div class="input-standard order-[14] md:order-[14] xl:order-[14]">
<Verbrauchslabel bind:ausweis addYear={2}></Verbrauchslabel>
<input
@@ -550,7 +559,7 @@ xl:grid-cols-3 xl:gap-x-8 xl:gap-y-8
<!-- Verbrauch 6 -->
<div class="input-standard order-12 md:order-12 xl:order-12">
<div class="input-standard order-[15] md:order-[15] xl:order-[15]">
<Verbrauchslabel bind:ausweis addYear={3}></Verbrauchslabel>
<input

View File

@@ -25,7 +25,7 @@
<style lang="postcss">
.tooltip {
@apply absolute -right-4 w-[240px] break-words ring-2 ring-secondary/5 invisible bg-white rounded-lg p-2 shadow-lg top-0 translate-y-[calc(-100%-8px)] transition-all duration-300 opacity-0;
@apply absolute z-[10] -right-4 w-[240px] break-words ring-2 ring-secondary/5 invisible bg-white rounded-lg p-2 shadow-lg top-0 translate-y-[calc(-100%-8px)] transition-all duration-300 opacity-0;
}
.tooltip-opener:hover .tooltip {

View File

@@ -4,7 +4,7 @@
</script>
<div class="absolute bg-white sm:bg-gray-500/10 border-x-[1px] border-t-[1px] border-black/25 px-2 top-[-1.275rem] left-[0rem] text-[0.8rem] rounded-t-sm font-sans">{title}</div>
<div class="absolute bg-gray-500/5 sm:bg-white sm:bg-gray-500/10 border-x-[1px] border-t-[1px] border-black/25 px-2 top-[-1.275rem] -left-[1px] text-[0.8rem] rounded-t-sm font-sans">{title}</div>
<style lang="postcss">

View File

@@ -2,7 +2,7 @@
import { fade } from "svelte/transition";
import WidgetCardTemplate from "#components/widgets/WidgetCardTemplate_IBC.svelte";
import { PRICES } from "#lib/constants.js";
import { Enums } from "#lib/client/prisma";
import { Enums } from "#lib/client/prisma.js";
let gebaeudetyp: string = "bitte auswählen";
let anlass: string = "bitte auswählen";
@@ -62,7 +62,7 @@ ausnahme = ((leerStand === "mehr als 30") || (heizungsAlter === "< 3") || (bau
: false;
oneBOX = ((ausnahme === true) && (gebaeudetyp != "Gewerbegebäude")) && (gebaeudetyp != "Mischgebäude") ||
((!twoBoxReason.includes(anlass)) && (gebaeudetyp != "Mischgebäude")) ||
((!twoBoxReason.includes(anlass)) && (gebaeudetyp != "Mischgebäude") && (gebaeudetyp != "bitte auswählen")) ||
((gebaeudetyp === "Gewerbegebäude") && (leerStand === "mehr als 30"))
? true
: false;
@@ -365,7 +365,7 @@ threeBOX = ((ausnahme === true) && (gebaeudetyp === "Mischgebäude") && (twoBo
<style lang="postcss">
*{font-family: "Heron";}
select option{font-family: "Heron",sans-serif;}
#OEA_widget {
@apply min-w-[320px] max-w-[1920px] p-[0px]
sm:p-[0px];

View File

@@ -66,8 +66,8 @@
.sumRows{@apply hidden sm:grid grid-rows-subgrid row-span-5 items-center}
.forServices{@apply grid-rows-subgrid row-span-5 items-center col-span-2 justify-center px-6}
.image{@apply w-[75%] justify-self-center
md:w-[75%] md:pl-12}
.image{@apply w-[75%] mx-auto
md:w-[75%] md:pl-0}
.buttoncols{@apply grid grid-cols-1 gap-x-4 w-full mb-4
md:grid-cols-2 md:w-[auto]}
@@ -84,7 +84,7 @@ hover:bg-primary hover:text-white}
.titel {@apply col-span-2 text-center [font-size:_clamp(20px,2.5vw,28px)]}
.empfehlung{@apply -mt-4 absolute justify-self-end rounded-md bg-red-700 text-white w-fit h-fit px-2 py-1 rotate-1 text-[0.65rem] ring-4 ring-white mr-6}
.variante {
@apply italic col-span-2 -mt-2 -mb-4 text-[1rem] text-[#222222] justify-self-start ring-2 ring-primary rounded-md pl-[4px] pr-[6px] py-[0px];
@apply w-fit italic col-span-2 -mt-2 -mb-4 text-[1rem] text-[#222222] justify-self-start ring-2 ring-primary rounded-md pl-[4px] pr-[6px] py-[0px];
}
.services {

View File

@@ -3,6 +3,10 @@
import WidgetCardTemplate from "#components/widgets/immowelt/WidgetCardTemplate_immowelt.svelte";
import { PRICES } from "#lib/constants.js";
import { Enums } from "#lib/client/prisma";
let ausnahme: boolean = false;
let oneBOX: boolean = false;
let threeBOX: boolean = false;
let gebaeudetyp: string = "bitte auswählen";
let anlass: string = "bitte auswählen";
@@ -16,13 +20,8 @@
const gewerbeHouse = ["Gewerbegebäude", "Mischgebäude"];
let ausnahme: boolean = false;
let oneBOX: boolean = false;
let threeBOX: boolean = false;
function getBoxes(){
if(twoBoxReason.includes(anlass)){
document.getElementById('firstrow')?.classList.remove('sm:grid-cols-2');
document.getElementById('firstrow')?.classList.add('sm:grid-cols-3');
}else{
@@ -43,26 +42,28 @@ if(oneBOX===true){
document.getElementById('thirdrow')?.classList.remove('md:grid-cols-4');
document.getElementById('thirdrow')?.classList.add('md:grid-cols-6');
}
else{
console.log('FOUR');
document.getElementById('thirdrow')?.classList.remove('grid-cols-1');
document.getElementById('thirdrow')?.classList.remove('md:grid-cols-6');
document.getElementById('thirdrow')?.classList.add('md:grid-cols-4');
}
console.log(!twoBoxReason.includes(anlass));
console.log(oneBOX);
}
$: {
ausnahme = ((leerStand === "mehr als 30") || (heizungsAlter === "< 3") || (baujahr === "vor 1978" && einheiten === "bis 4 Wohneinheiten" && sanierungsstatus === "unsaniert"))
? true
: false;
oneBOX = ((ausnahme === true) && (gebaeudetyp != "Gewerbegebäude")) && (gebaeudetyp != "Mischgebäude") ||
((!twoBoxReason.includes(anlass)) && (gebaeudetyp != "Mischgebäude")) ||
oneBOX = ((ausnahme === true) && (gebaeudetyp != "Gewerbegebäude") && (gebaeudetyp != "Mischgebäude")) ||
(!twoBoxReason.includes(anlass) && (gebaeudetyp != "Mischgebäude")) ||
((gebaeudetyp === "Gewerbegebäude") && (leerStand === "mehr als 30"))
? true
: false;
@@ -73,9 +74,6 @@ threeBOX = ((ausnahme === true) && (gebaeudetyp === "Mischgebäude") && (twoBo
}
</script>
@@ -397,6 +395,7 @@ threeBOX = ((ausnahme === true) && (gebaeudetyp === "Mischgebäude") && (twoBo
*{font-family: "immo Sans";}
select option{font-family: "immo Sans",sans-serif;}
#OEA_widget {
@apply min-w-[320px] max-w-[1920px] p-[4px]

View File

@@ -25,7 +25,7 @@
{src}
{alt}
/>
<div class="justify-self-start">
<div class="">
<p class="price">
ab {price}
</p>
@@ -66,8 +66,8 @@
.sumRows{@apply hidden sm:grid grid-rows-subgrid row-span-5 items-center}
.forServices{@apply grid-rows-subgrid row-span-5 items-center col-span-2 justify-center px-6}
.image{@apply w-[75%] justify-self-center
md:w-[75%] md:pl-12}
.image{@apply w-[75%] mx-auto
md:w-[75%] md:pl-0}
.buttoncols{@apply grid grid-cols-1 gap-x-4 w-full mb-4
md:grid-cols-2 md:w-[auto]}
@@ -76,7 +76,7 @@ md:grid-cols-2 md:w-[auto]}
hover:bg-[#222222] hover:text-white}
.price{@apply tracking-tighter text-[2rem] text-[#222222] pl-12 m-0 -mt-4 text-nowrap;
.price{@apply tracking-tighter text-[2rem] text-[#222222] pl-12 m-0 -mt-7 text-nowrap text-left;
font-family: "Antique Olive Compact bold";}
@@ -84,7 +84,7 @@ hover:bg-[#222222] hover:text-white}
.titel {@apply col-span-2 text-center [font-size:_clamp(20px,2.5vw,28px)]}
.empfehlung{@apply -mt-4 absolute justify-self-end rounded-md bg-red-700 text-white w-fit h-fit px-2 py-1 rotate-1 text-[0.65rem] ring-4 ring-white mr-6}
.variante {
@apply italic col-span-2 -mt-2 -mb-4 text-[1rem] text-[#222222] justify-self-start ring-2 ring-[#ffcc00] rounded-md pl-[4px] pr-[6px] py-[0px];
@apply w-fit italic col-span-2 -mt-2 -mb-4 text-[1rem] text-[#222222] justify-self-start ring-2 ring-[#ffcc00] rounded-md pl-[4px] pr-[6px] py-[0px];
}
.services {