Skip to content

Commit

Permalink
wip: Provide a generic card descrpition section #959
Browse files Browse the repository at this point in the history
  • Loading branch information
cnouguier committed Sep 27, 2024
1 parent 5f65373 commit ecfb08d
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions map/client/components/location/KLocationCardSection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,14 @@ import KLocationMap from './KLocationMap.vue'
// Props
const props = defineProps({
location: {
item: {
type: Object,
default: () => null
},
locationPath: {
type: String,
default: 'location'
},
actions: {
type: [Object, Array],
default: () => null
Expand All @@ -59,7 +63,7 @@ const props = defineProps({
const feature = ref(null)
// Watch
watch(() => props.location, (value) => {
feature.value = value
watch(() => [props.item, props.location], () => {
feature.value = _.get(props.item, props.locationPath)
}, { immediate: true })
</script>

0 comments on commit ecfb08d

Please sign in to comment.