File tree Expand file tree Collapse file tree 5 files changed +12
-6
lines changed
Expand file tree Collapse file tree 5 files changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -137,7 +137,7 @@ export namespace Gleap {
137137 function open ( ) : void ;
138138 function openChecklists ( showBackButton ?: boolean ) : void ;
139139 function openChecklist ( checklistId : string , showBackButton ?: boolean ) : void ;
140- function startChecklist ( outboundId : string , showBackButton ?: boolean ) : void ;
140+ function startChecklist ( outboundId : string , showBackButton ?: boolean , sharedKey ?: string ) : void ;
141141 function openNews ( showBackButton ?: boolean ) : void ;
142142 function openNewsArticle ( id : string , showBackButton ?: boolean ) : void ;
143143 function openConversations ( showBackButton ?: boolean ) : void ;
Original file line number Diff line number Diff line change 11{
22 "name" : " gleap" ,
3- "version" : " 14.5.3 " ,
3+ "version" : " 14.5.4 " ,
44 "main" : " build/cjs/index.js" ,
55 "module" : " build/esm/index.mjs" ,
66 "exports" : {
Original file line number Diff line number Diff line change @@ -1035,7 +1035,11 @@ class Gleap {
10351035 /**
10361036 * Starts a new checklist and opens it.
10371037 */
1038- static startChecklist ( outboundId , showBackButton = true ) {
1038+ static startChecklist (
1039+ outboundId ,
1040+ showBackButton = true ,
1041+ sharedKey = undefined
1042+ ) {
10391043 if ( ! outboundId ) {
10401044 return false ;
10411045 }
@@ -1046,6 +1050,8 @@ class Gleap {
10461050 name : "start-checklist" ,
10471051 data : {
10481052 outboundId : outboundId ,
1053+ hideBackButton : ! showBackButton ,
1054+ ...( sharedKey ? { sharedKey : sharedKey } : { } ) ,
10491055 } ,
10501056 } ,
10511057 true
@@ -1296,7 +1302,7 @@ const handleGleapLink = (href) => {
12961302
12971303 if ( type === "checklist" ) {
12981304 const identifier = urlParts [ 3 ] ;
1299- Gleap . startChecklist ( identifier , true ) ;
1305+ Gleap . startChecklist ( identifier , true , urlParts [ 4 ] ) ;
13001306 }
13011307
13021308 if ( type === "tour" ) {
Original file line number Diff line number Diff line change @@ -72,7 +72,7 @@ export default class GleapBannerManager {
7272 Gleap . openHelpCenterArticle ( data . data ?. articleId ) ;
7373 }
7474 if ( data . name === "show-checklist" ) {
75- Gleap . startChecklist ( data . data ?. checklistId ) ;
75+ Gleap . startChecklist ( data . data ?. checklistId , true , data . data ?. sharedKey ) ;
7676 }
7777 } catch ( exp ) { }
7878 } ) ;
Original file line number Diff line number Diff line change @@ -1156,7 +1156,7 @@ export const registerGleapChecklist = () => {
11561156 else if ( step . action === "HELP_ARTICLE" )
11571157 Gleap . openHelpCenterArticle ( step . articleId ) ;
11581158 else if ( step . action === "CHECKLIST" )
1159- Gleap . startChecklist ( step . checklistId ) ;
1159+ Gleap . startChecklist ( step . checklistId , true , step ?. sharedKey ) ;
11601160 } catch ( gleapError ) { }
11611161 } ) ;
11621162 }
You can’t perform that action at this time.
0 commit comments