@ -73,7 +73,7 @@
class = "w-full h-auto max-w-lg max-h-96 object-contain mx-auto drop-shadow-md"
class = "w-full h-auto max-w-lg max-h-96 object-contain mx-auto drop-shadow-md"
: src = "record.image"
: src = "record.image"
alt = "Activity image"
alt = "Activity image"
@ load = "cacheImage (record.image)"
@ load = "handleImageLoad (record.image)"
/ >
/ >
< / a >
< / a >
< / div >
< / div >
@ -248,7 +248,7 @@
< / template >
< / template >
< script lang = "ts" >
< script lang = "ts" >
import { Component , Prop , Vue , Emit } from "vue-facing-decorator" ;
import { Component , Prop , Vue } from "vue-facing-decorator" ;
import { GiveRecordWithContactInfo } from "@/interfaces/give" ;
import { GiveRecordWithContactInfo } from "@/interfaces/give" ;
import EntityIcon from "./EntityIcon.vue" ;
import EntityIcon from "./EntityIcon.vue" ;
import { isGiveClaimType , notifyWhyCannotConfirm } from "../libs/util" ;
import { isGiveClaimType , notifyWhyCannotConfirm } from "../libs/util" ;
@ -274,6 +274,13 @@ export default class ActivityListItem extends Vue {
@ Prop ( ) activeDid ! : string ;
@ Prop ( ) activeDid ! : string ;
@ Prop ( ) confirmerIdList ? : string [ ] ;
@ Prop ( ) confirmerIdList ? : string [ ] ;
/ * *
* Function prop for handling image caching
* Called when an image loads successfully , allowing parent to control caching behavior
* /
@ Prop ( { type : Function , default : ( ) => { } } )
onImageCache ! : ( imageUrl : string ) => void | Promise < void > ;
isHiddenDid = isHiddenDid ;
isHiddenDid = isHiddenDid ;
notify ! : ReturnType < typeof createNotifyHelpers > ;
notify ! : ReturnType < typeof createNotifyHelpers > ;
$notify ! : ( notification : any , timeout ? : number ) => void ;
$notify ! : ( notification : any , timeout ? : number ) => void ;
@ -290,9 +297,12 @@ export default class ActivityListItem extends Vue {
this . notify . warning ( NOTIFY_UNKNOWN_PERSON . message , TIMEOUTS . STANDARD ) ;
this . notify . warning ( NOTIFY_UNKNOWN_PERSON . message , TIMEOUTS . STANDARD ) ;
}
}
@ Emit ( )
/ * *
cacheImage ( image : string ) {
* Handle image load event - call function prop for caching
return image ;
* Allows parent to control caching behavior and validation
* /
handleImageLoad ( imageUrl : string ) : void {
this . onImageCache ( imageUrl ) ;
}
}
get fetchAmount ( ) : string {
get fetchAmount ( ) : string {