Skip to content

Commit e4685e6

Browse files
committed
v13.1.0
1 parent 5dd9ec8 commit e4685e6

File tree

7 files changed

+33
-7
lines changed

7 files changed

+33
-7
lines changed

build/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

demo/main.js

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,21 @@
11
const Gleap = window.Gleap;
22

3-
Gleap.setFrameUrl("http://0.0.0.0:3001");
3+
/*Gleap.setFrameUrl("http://0.0.0.0:3001");
44
Gleap.setApiUrl("http://0.0.0.0:9000");
5-
Gleap.setWSApiUrl("ws://0.0.0.0:8080");
5+
Gleap.setWSApiUrl("ws://0.0.0.0:8080");*/
66

7-
// Gleap.setLanguage("en");
7+
Gleap.setLanguage("en");
88

9-
Gleap.initialize("rinrKZAvjqOheSjpdUjFnp01tSOF3WTd");
9+
Gleap.initialize("ogWhNhuiZcGWrva5nlDS8l7a78OfaLlV");
1010

1111
/*Gleap.setUrlHandler((url, newTab) => {
1212
alert("URL: " + url + " newTab: " + newTab);
1313
});*/
1414

1515
Gleap.registerCustomAction((customAction) => {
1616
console.log("Custom action: ", customAction);
17+
});
18+
19+
Gleap.on("unread-count-changed", (unreadCount) => {
20+
console.log("Unread count changed: ", unreadCount);
1721
});

index.d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,12 @@ export namespace Gleap {
3030
replays: Boolean;
3131
}
3232
): void;
33+
function startClassicForm(
34+
formId: string,
35+
showBackButton?: boolean
36+
): void;
3337
function startBot(botId: string, showBackButton?: boolean): void;
38+
function startConversation(showBackButton?: boolean): void;
3439
function attachCustomData(customData: any): void;
3540
function setCustomData(key: string, value: string): void;
3641
function removeCustomData(key: string): void;

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "gleap",
3-
"version": "13.0.6",
3+
"version": "13.1.0",
44
"main": "build/index.js",
55
"scripts": {
66
"start": "webpack serve",

published/13.1.0/index.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

published/latest/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/Gleap.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -652,6 +652,15 @@ class Gleap {
652652
);
653653
}
654654

655+
/**
656+
* Starts a classic feedback form.
657+
*/
658+
static startClassicForm(formId, showBackButton) {
659+
Gleap.startFeedbackFlowWithOptions(formId, {
660+
hideBackButton: !showBackButton,
661+
});
662+
}
663+
655664
/**
656665
* Starts the bug reporting flow.
657666
*/
@@ -751,6 +760,13 @@ class Gleap {
751760
GleapFrameManager.getInstance().showWidget();
752761
}
753762

763+
/**
764+
* Starts a new conversation
765+
*/
766+
static startConversation(showBackButton = true) {
767+
Gleap.startBot("", showBackButton);
768+
}
769+
754770
/**
755771
* Starts a new conversation and attaches the bot with the given id.
756772
*/

0 commit comments

Comments
 (0)