Simplify OfferResultCard and use daisyUI Steps
All checks were successful
Build Docker Image / build (push) Successful in 4m42s
All checks were successful
Build Docker Image / build (push) Successful in 4m42s
- Remove sourceName, latitude, longitude props from OfferResultCard - Remove LocationMiniMap component (not needed, main map is on the side) - Convert RouteStepper to use daisyUI steps-horizontal - Update hub page and CalcResultContent to remove unused props
This commit is contained in:
@@ -1,32 +1,18 @@
|
||||
<template>
|
||||
<Card padding="md" interactive @click="$emit('select')">
|
||||
<!-- Header: Source name + Location + Price -->
|
||||
<!-- Header: Location + Price -->
|
||||
<div class="flex items-start justify-between mb-3">
|
||||
<div>
|
||||
<Text weight="semibold">{{ sourceName }}</Text>
|
||||
<Text v-if="locationName" tone="muted" size="sm">{{ locationName }}</Text>
|
||||
</div>
|
||||
<div class="text-right">
|
||||
<Text v-if="priceDisplay" weight="semibold" class="text-primary text-lg">
|
||||
{{ priceDisplay }}
|
||||
</Text>
|
||||
<Text weight="semibold">{{ locationName || 'Локация' }}</Text>
|
||||
<Text v-if="productName" tone="muted" size="sm">{{ productName }}</Text>
|
||||
</div>
|
||||
<Text v-if="priceDisplay" weight="semibold" class="text-primary text-lg">
|
||||
{{ priceDisplay }}
|
||||
</Text>
|
||||
</div>
|
||||
|
||||
<!-- Product name + Route stepper -->
|
||||
<div v-if="productName" class="mb-3">
|
||||
<Text size="sm" class="mb-1">{{ productName }}</Text>
|
||||
<RouteStepper v-if="stages.length > 0" :stages="stages" />
|
||||
</div>
|
||||
<RouteStepper v-else-if="stages.length > 0" :stages="stages" class="mb-3" />
|
||||
|
||||
<!-- Mini map -->
|
||||
<LocationMiniMap
|
||||
v-if="latitude && longitude"
|
||||
:latitude="latitude"
|
||||
:longitude="longitude"
|
||||
:height="100"
|
||||
/>
|
||||
<!-- Route stepper -->
|
||||
<RouteStepper v-if="stages.length > 0" :stages="stages" />
|
||||
</Card>
|
||||
</template>
|
||||
|
||||
@@ -34,14 +20,11 @@
|
||||
import type { RouteStage } from './RouteStepper.vue'
|
||||
|
||||
const props = withDefaults(defineProps<{
|
||||
sourceName: string
|
||||
locationName?: string
|
||||
productName?: string
|
||||
pricePerUnit?: number | null
|
||||
currency?: string | null
|
||||
unit?: string | null
|
||||
latitude?: number | null
|
||||
longitude?: number | null
|
||||
stages?: RouteStage[]
|
||||
}>(), {
|
||||
stages: () => []
|
||||
|
||||
Reference in New Issue
Block a user