- Added AddressForm and CheckoutForm components for user input during checkout. - Implemented validation using Zod and VeeValidate for billing address fields. - Created OrderSummary and MockPayPalButton components for order confirmation and payment simulation. - Updated CartSheet and CartSidebar to navigate to the new checkout page at '/kasse'. - Introduced new API endpoints for validating checkout data and creating orders. - Enhanced user experience with responsive design and error handling. These changes complete the checkout functionality, allowing users to enter billing information, simulate payment, and confirm orders.
32 lines
658 B
Vue
32 lines
658 B
Vue
<script setup lang="ts">
|
|
import { type HTMLAttributes, computed } from 'vue'
|
|
import { Label as LabelPrimitive } from 'reka-ui'
|
|
import { cn } from '@/lib/utils'
|
|
|
|
interface LabelProps {
|
|
for?: string
|
|
class?: HTMLAttributes['class']
|
|
}
|
|
|
|
const props = defineProps<LabelProps>()
|
|
|
|
const delegatedProps = computed(() => {
|
|
const { class: _, ...delegated } = props
|
|
return delegated
|
|
})
|
|
</script>
|
|
|
|
<template>
|
|
<LabelPrimitive
|
|
v-bind="delegatedProps"
|
|
:class="
|
|
cn(
|
|
'text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70',
|
|
props.class
|
|
)
|
|
"
|
|
>
|
|
<slot />
|
|
</LabelPrimitive>
|
|
</template>
|