script-property wieder auf string gesetzt, malen.js vereinfacht
This commit is contained in:
parent
47607746bb
commit
39709fa4f1
19
malen.js
19
malen.js
|
@ -1,18 +1 @@
|
|||
let helloWorldPopup;
|
||||
|
||||
// Open the popup when we enter a given zone
|
||||
helloWorldPopup = WA.onEnterZone('malen-1', () => {
|
||||
WA.openPopup("popupRectangle", 'Hello world!', [{
|
||||
label: "Close",
|
||||
className: "primary",
|
||||
callback: (popup) => {
|
||||
// Close the popup when the "Close" button is pressed.
|
||||
popup.close();
|
||||
}
|
||||
});
|
||||
}]);
|
||||
|
||||
// Close the popup when we leave the zone.
|
||||
WA.onLeaveZone('malen-1', () => {
|
||||
helloWorldPopup.close();
|
||||
});
|
||||
WA.sendChatMessage('Hello world', 'Mr Robot');
|
||||
|
|
Loading…
Reference in a new issue