@ -261,21 +261,20 @@ 
			
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					< script  lang = "ts" > < script  lang = "ts" >  
			
		
	
		
		
			
				
					import  {  Component ,  Vue  }  from  "vue-facing-decorator" ; import  {  Component ,  Vue  }  from  "vue-facing-decorator" ;  
			
		
	
		
		
			
				
					
					import  {  Router  }  from  "vue-router" ; import  {  RouteLocationNormalizedLoaded ,  Route r  }  from  "vue-router" ;  
			
				
				
			
		
	
		
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					import  ImageMethodDialog  from  "../components/ImageMethodDialog.vue" ; import  ImageMethodDialog  from  "../components/ImageMethodDialog.vue" ;  
			
		
	
		
		
			
				
					import  QuickNav  from  "../components/QuickNav.vue" ; import  QuickNav  from  "../components/QuickNav.vue" ;  
			
		
	
		
		
			
				
					import  TopMessage  from  "../components/TopMessage.vue" ; import  TopMessage  from  "../components/TopMessage.vue" ;  
			
		
	
		
		
			
				
					import  {  DEFAULT_IMAGE_API_SERVER ,  NotificationIface  }  from  "../constants/app" ; import  {  DEFAULT_IMAGE_API_SERVER ,  NotificationIface  }  from  "../constants/app" ;  
			
		
	
		
		
			
				
					import  {  db ,  retrieveSettingsForActiveAccount  }  from  "../db/index" ; import  {  db ,  retrieveSettingsForActiveAccount  }  from  "../db/index" ;  
			
		
	
		
		
			
				
					import  {  GenericCredWrapper ,  GiveVerifiableCredential  }  from  "../interfaces" ;  
			
		
	
		
		
			
				
					import  { import  {  
			
		
	
		
		
			
				
					  createAndSubmitGive ,   createAndSubmitGive ,  
			
		
	
		
		
			
				
					  didInfo ,   didInfo ,  
			
		
	
		
		
			
				
					  editAndSubmitGive ,   editAndSubmitGive ,  
			
		
	
		
		
			
				
					  GenericCredWrapper ,  
			
		
	
		
		
			
				
					  getHeaders ,   getHeaders ,  
			
		
	
		
		
			
				
					  getPlanFromCache ,   getPlanFromCache ,  
			
		
	
		
		
			
				
					  GiveVerifiableCredential ,  
			
		
	
		
		
			
				
					  hydrateGive ,   hydrateGive ,  
			
		
	
		
		
			
				
					}  from  "../libs/endorserServer" ; }  from  "../libs/endorserServer" ;  
			
		
	
		
		
			
				
					import  *  as  libsUtil  from  "../libs/util" ; import  *  as  libsUtil  from  "../libs/util" ;  
			
		
	
	
		
		
			
				
					
						
						
						
							
								 
						
					 
					@ -290,6 +289,8 @@ import { retrieveAccountDids } from "../libs/util"; 
			
		
	
		
		
			
				
					} ) } )  
			
		
	
		
		
			
				
					export  default  class  GiftedDetails  extends  Vue  { export  default  class  GiftedDetails  extends  Vue  {  
			
		
	
		
		
			
				
					  $notify ! :  ( notification :  NotificationIface ,  timeout ? :  number )  =>  void ;   $notify ! :  ( notification :  NotificationIface ,  timeout ? :  number )  =>  void ;  
			
		
	
		
		
			
				
					  $route ! :  RouteLocationNormalizedLoaded ;  
			
		
	
		
		
			
				
					  $router ! :  Router ;  
			
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					  activeDid  =  "" ;   activeDid  =  "" ;  
			
		
	
		
		
			
				
					  apiServer  =  "" ;   apiServer  =  "" ;  
			
		
	
	
		
		
			
				
					
						
							
								 
						
						
							
								 
						
						
					 
					@ -322,9 +323,9 @@ export default class GiftedDetails extends Vue { 
			
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					  async  mounted ( )  {   async  mounted ( )  {  
			
		
	
		
		
			
				
					    try  {     try  {  
			
		
	
		
		
			
				
					
					      this . prevCredToEdit  =  ( this . $route  as  Router )  . query [ "prevCredToEdit" ]       this . prevCredToEdit  =  ( this . $route . query [ "prevCredToEdit" ]  as  string )   
			
				
				
			
		
	
		
		
	
		
		
			
				
					        ?  ( JSON . parse (         ?  ( JSON . parse (  
			
		
	
		
		
			
				
					
					            ( this . $route  as  Router )  . query [ "prevCredToEdit" ] ,             ( this . $route . query [ "prevCredToEdit" ]  as  string )  ,  
			
				
				
			
		
	
		
		
	
		
		
			
				
					          )  as  GenericCredWrapper < GiveVerifiableCredential > )           )  as  GenericCredWrapper < GiveVerifiableCredential > )  
			
		
	
		
		
			
				
					        :  undefined ;         :  undefined ;  
			
		
	
		
		
			
				
					    }  catch  ( error )  {     }  catch  ( error )  {  
			
		
	
	
		
		
			
				
					
						
						
						
							
								 
						
					 
					@ -341,24 +342,22 @@ export default class GiftedDetails extends Vue { 
			
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					    const  prevAmount  =  this . prevCredToEdit ? . claim ? . object ? . amountOfThisGood ;     const  prevAmount  =  this . prevCredToEdit ? . claim ? . object ? . amountOfThisGood ;  
			
		
	
		
		
			
				
					    this . amountInput  =     this . amountInput  =  
			
		
	
		
		
			
				
					
					      ( this . $route  as  Router )  . query [ "amountInput" ]  ||       ( this . $route . query [ "amountInput" ]  as  string )   ||  
			
				
				
			
		
	
		
		
	
		
		
			
				
					      ( prevAmount  ?  String ( prevAmount )  :  "" )  ||       ( prevAmount  ?  String ( prevAmount )  :  "" )  ||  
			
		
	
		
		
			
				
					      this . amountInput ;       this . amountInput ;  
			
		
	
		
		
			
				
					    this . description  =     this . description  =  
			
		
	
		
		
			
				
					
					      ( this . $route  as  Router )  . query [ "description" ]  ||       ( this . $route . query [ "description" ]  as  string )   ||  
			
				
				
			
		
	
		
		
	
		
		
			
				
					      this . prevCredToEdit ? . claim ? . description  ||       this . prevCredToEdit ? . claim ? . description  ||  
			
		
	
		
		
			
				
					      this . description ;       this . description ;  
			
		
	
		
		
			
				
					
					    this . destinationPathAfter  =  ( this . $route  as  Router ) . query [     this . destinationPathAfter  =  ( this . $route . query [ "destinationPathAfter" ]  as  string )  ||  "" ;  
			
				
				
			
		
	
		
		
			
				
					
					      "destinationPathAfter"     this . giverDid  =  ( ( this . $route . query [ "giverDid" ]  as  string )  ||  
			
				
				
			
		
	
		
		
			
				
					
					    ] ;       ( this . prevCredToEdit ? . claim ? . agent  as  any ) ? . identifier  ||  
			
				
				
			
		
	
		
		
			
				
					    this . giverDid  =  ( ( this . $route  as  Router ) . query [ "giverDid" ]  ||  
			
		
	
		
		
			
				
					      this . prevCredToEdit ? . claim ? . agent ? . identifier  ||  
			
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					      this . giverDid )  as  string ;       this . giverDid )  as  string ;  
			
		
	
		
		
			
				
					    this . giverName  =     this . giverName  =  
			
		
	
		
		
			
				
					
					      ( ( this . $route  as  Router )  . query [ "giverName" ]  as  string )  ||  "" ;       ( ( this . $route . query [ "giverName" ]  as  string )  ||  "" ) ;  
			
				
				
			
		
	
		
		
	
		
		
			
				
					    this . hideBackButton  =     this . hideBackButton  =  
			
		
	
		
		
			
				
					
					      ( this . $route  as  Router )  . query [ "hideBackButton" ]  ===  "true" ;       ( this . $route . query [ "hideBackButton" ]  as  string )   ===  "true" ;  
			
				
				
			
		
	
		
		
			
				
					
					    this . message  =  ( ( this . $route  as  Router )  . query [ "message" ]  as  string )  ||  "" ;     this . message  =  ( ( this . $route . query [ "message" ]  as  string )  ||  "" ) ;  
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					    / /   f i n d   a n y   o f f e r   I D     / /   f i n d   a n y   o f f e r   I D  
			
		
	
		
		
			
				
					    const  fulfills  =  this . prevCredToEdit ? . claim ? . fulfills ;     const  fulfills  =  this . prevCredToEdit ? . claim ? . fulfills ;  
			
		
	
	
		
		
			
				
					
						
						
						
							
								 
						
					 
					@ -368,7 +367,7 @@ export default class GiftedDetails extends Vue { 
			
		
	
		
		
			
				
					        ?  [ fulfills ]         ?  [ fulfills ]  
			
		
	
		
		
			
				
					        :  [ ] ;         :  [ ] ;  
			
		
	
		
		
			
				
					    const  offer  =  fulfillsArray . find ( ( rec )  =>  rec [ "@type" ]  ===  "Offer" ) ;     const  offer  =  fulfillsArray . find ( ( rec )  =>  rec [ "@type" ]  ===  "Offer" ) ;  
			
		
	
		
		
			
				
					
					    this . offerId  =  ( ( this . $route  as  Router )  . query [ "offerId" ]  ||     this . offerId  =  ( ( this . $route . query [ "offerId" ]  as  string )   ||  
			
				
				
			
		
	
		
		
	
		
		
			
				
					      offer ? . identifier  ||       offer ? . identifier  ||  
			
		
	
		
		
			
				
					      this . offerId )  as  string ;       this . offerId )  as  string ;  
			
		
	
		
		
			
				
					
 
			
		
	
	
		
		
			
				
					
						
						
						
							
								 
						
					 
					@ -378,7 +377,7 @@ export default class GiftedDetails extends Vue { 
			
		
	
		
		
			
				
					    ) ;     ) ;  
			
		
	
		
		
			
				
					    / /   e s l i n t - d i s a b l e - n e x t - l i n e   p r e t t i e r / p r e t t i e r     / /   e s l i n t - d i s a b l e - n e x t - l i n e   p r e t t i e r / p r e t t i e r  
			
		
	
		
		
			
				
					    this . fulfillsProjectId  =     this . fulfillsProjectId  =  
			
		
	
		
		
			
				
					
					      ( ( this . $route  as  Router )  . query [ "fulfillsProjectId" ]  ||       ( ( this . $route . query [ "fulfillsProjectId" ]  as  string )   ||  
			
				
				
			
		
	
		
		
	
		
		
			
				
					      fulfillsProject ? . identifier  ||       fulfillsProject ? . identifier  ||  
			
		
	
		
		
			
				
					      this . fulfillsProjectId )  as  string ;       this . fulfillsProjectId )  as  string ;  
			
		
	
		
		
			
				
					
 
			
		
	
	
		
		
			
				
					
						
						
						
							
								 
						
					 
					@ -392,40 +391,38 @@ export default class GiftedDetails extends Vue { 
			
		
	
		
		
			
				
					    const  providerProject  =  providerArray . find (     const  providerProject  =  providerArray . find (  
			
		
	
		
		
			
				
					      ( rec )  =>  rec [ "@type" ]  ===  "PlanAction" ,       ( rec )  =>  rec [ "@type" ]  ===  "PlanAction" ,  
			
		
	
		
		
			
				
					    ) ;     ) ;  
			
		
	
		
		
			
				
					
					    this . providerProjectId  =  ( ( this . $route  as  Router ) . query [     this . providerProjectId  =  ( ( this . $route . query [ "providerProjectId" ]  as  string )  ||  
			
				
				
			
		
	
		
		
			
				
					      "providerProjectId"  
			
		
	
		
		
			
				
					    ]  ||  
			
		
	
		
		
	
		
		
			
				
					      providerProject ? . identifier  ||       providerProject ? . identifier  ||  
			
		
	
		
		
			
				
					      this . providerProjectId )  as  string ;       this . providerProjectId )  as  string ;  
			
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					
					    this . recipientDid  =  ( ( this . $route  as  Router )  . query [ "recipientDid" ]  ||     this . recipientDid  =  ( ( this . $route . query [ "recipientDid" ]  as  string )   ||  
			
				
				
			
		
	
		
		
	
		
		
			
				
					      this . prevCredToEdit ? . claim ? . recipient ? . identifier )  as  string ;       this . prevCredToEdit ? . claim ? . recipient ? . identifier )  as  string ;  
			
		
	
		
		
			
				
					    this . recipientName  =     this . recipientName  =  
			
		
	
		
		
			
				
					
					      ( ( this . $route  as  Router )  . query [ "recipientName" ]  as  string )  ||  "" ;       ( ( this . $route . query [ "recipientName" ]  as  string )  ||  "" ) ;  
			
				
				
			
		
	
		
		
			
				
					
					    this . unitCode  =  ( ( this . $route  as  Router )  . query [ "unitCode" ]  ||     this . unitCode  =  ( ( this . $route . query [ "unitCode" ]  as  string )   ||  
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					      this . prevCredToEdit ? . claim ? . object ? . unitCode  ||       this . prevCredToEdit ? . claim ? . object ? . unitCode  ||  
			
		
	
		
		
			
				
					      this . unitCode )  as  string ;       this . unitCode )  as  string ;  
			
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					    this . imageUrl  =     this . imageUrl  =  
			
		
	
		
		
			
				
					
					      ( ( this . $route  as  Router )  . query [ "imageUrl" ]  as  string )  ||       ( ( this . $route . query [ "imageUrl" ]  as  string )  ||  
			
				
				
			
		
	
		
		
	
		
		
			
				
					      this . prevCredToEdit ? . claim ? . image  ||       this . prevCredToEdit ? . claim ? . image  ||  
			
		
	
		
		
			
				
					      localStorage . getItem ( "imageUrl" )  ||       localStorage . getItem ( "imageUrl" )  ||  
			
		
	
		
		
			
				
					
					      this . imageUrl ;       this . imageUrl )  as  string ;  
			
				
				
			
		
	
		
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					    / /   t h i s   i s   a n   e n d p o i n t   f o r   s h a r i n g   p r o j e c t   i n f o   t o   h i g h l i g h t   s o m e t h i n g   g i v e n     / /   t h i s   i s   a n   e n d p o i n t   f o r   s h a r i n g   p r o j e c t   i n f o   t o   h i g h l i g h t   s o m e t h i n g   g i v e n  
			
		
	
		
		
			
				
					    / /   h t t p s : / / d e v e l o p e r . m o z i l l a . o r g / e n - U S / d o c s / W e b / M a n i f e s t / s h a r e _ t a r g e t     / /   h t t p s : / / d e v e l o p e r . m o z i l l a . o r g / e n - U S / d o c s / W e b / M a n i f e s t / s h a r e _ t a r g e t  
			
		
	
		
		
			
				
					
					    if  ( ( this . $route  as  Router )  . query [ "shareTitle" ] )  {     if  ( ( this . $route . query [ "shareTitle" ]  as  string )  )  {  
			
				
				
			
		
	
		
		
	
		
		
			
				
					      this . description  =       this . description  =  
			
		
	
		
		
			
				
					
					        ( ( this . $route  as  Router )  . query [ "shareTitle" ]  as  string )  +         ( ( this . $route . query [ "shareTitle" ]  as  string )  ||  "" )  +  
			
				
				
			
		
	
		
		
	
		
		
			
				
					        ( this . description  ?  "\n"  +  this . description  :  "" ) ;         ( this . description  ?  "\n"  +  this . description  :  "" ) ;  
			
		
	
		
		
			
				
					    }     }  
			
		
	
		
		
			
				
					
					    if  ( ( this . $route  as  Router )  . query [ "shareText" ] )  {     if  ( ( this . $route . query [ "shareText" ]  as  string )  )  {  
			
				
				
			
		
	
		
		
	
		
		
			
				
					      this . description  =       this . description  =  
			
		
	
		
		
			
				
					        ( this . description  ?  this . description  +  "\n"  :  "" )  +         ( this . description  ?  this . description  +  "\n"  :  "" )  +  
			
		
	
		
		
			
				
					
					        ( ( this . $route  as  Router )  . query [ "shareText" ]  as  string ) ;         ( ( this . $route . query [ "shareText" ]  as  string )  ||  "" ) ;  
			
				
				
			
		
	
		
		
	
		
		
			
				
					    }     }  
			
		
	
		
		
			
				
					
					    if  ( ( this . $route  as  Router )  . query [ "shareUrl" ] )  {     if  ( ( this . $route . query [ "shareUrl" ]  as  string )  )  {  
			
				
				
			
		
	
		
		
			
				
					
					      this . imageUrl  =  ( this . $route  as  Router )  . query [ "shareUrl" ]  as  string ;       this . imageUrl  =  ( this . $route . query [ "shareUrl" ]  as  string ) ;  
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					    }     }  
			
		
	
		
		
			
				
					
 
			
		
	
		
		
			
				
					    const  settings  =  await  retrieveSettingsForActiveAccount ( ) ;     const  settings  =  await  retrieveSettingsForActiveAccount ( ) ;