mirror of
https://github.com/tomru/pfadi-bussle.git
synced 2026-03-04 23:17:12 +01:00
move Layout into _app.tsx
This commit is contained in:
committed by
Thomas Ruoff
parent
7389289b81
commit
2fd3a47e72
@@ -1,5 +1,4 @@
|
||||
import React, { useEffect, useState } from 'react'
|
||||
import Layout from '../../../../components/layout'
|
||||
import Input from '../../../../components/input'
|
||||
import Select from '../../../../components/select'
|
||||
import { Booking } from '../../../../db/booking'
|
||||
@@ -115,14 +114,14 @@ function BookingBillPage({
|
||||
setStoringInProgress(false)
|
||||
}
|
||||
|
||||
const onAddAdditionalCost = function (
|
||||
const onAddAdditionalCost = function(
|
||||
event: React.MouseEvent<HTMLButtonElement>
|
||||
) {
|
||||
event.preventDefault()
|
||||
setAdditionalCosts([...additionalCosts, { name: '', value: 0 }])
|
||||
}
|
||||
|
||||
const onRemoveAdditionalCost = function (
|
||||
const onRemoveAdditionalCost = function(
|
||||
event: React.MouseEvent<HTMLButtonElement>,
|
||||
index: number
|
||||
) {
|
||||
@@ -134,7 +133,7 @@ function BookingBillPage({
|
||||
}
|
||||
|
||||
return (
|
||||
<Layout>
|
||||
<>
|
||||
{booking && (
|
||||
<form className="w-full" onSubmit={onSubmit}>
|
||||
<div>
|
||||
@@ -198,9 +197,8 @@ function BookingBillPage({
|
||||
>
|
||||
-
|
||||
</button>
|
||||
<label className="flabel inline">{`Kostenpunkt ${
|
||||
index + 1
|
||||
}`}</label>
|
||||
<label className="flabel inline">{`Kostenpunkt ${index + 1
|
||||
}`}</label>
|
||||
</div>
|
||||
<div className="ml-10 mb-3" key={`input{index}`}>
|
||||
<Input
|
||||
@@ -258,7 +256,7 @@ function BookingBillPage({
|
||||
</button>
|
||||
</form>
|
||||
)}
|
||||
</Layout>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user