Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v12
43 changes: 31 additions & 12 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "HTMLSnippet",
"version": "3.9.7",
"version": "3.9.8",
"description": "",
"license": "",
"author": "",
Expand Down
22 changes: 11 additions & 11 deletions src/HTMLSnippet/widget/HTMLSnippet.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ define([
contextObj: null,

postCreate: function () {
mx.logger.debug(this.id + ".postCreate");
console.debug(this.id + ".postCreate");
this._setupEvents();

if (!this.refreshOnContextChange) {
Expand All @@ -44,7 +44,7 @@ define([
},

executeCode: function () {
mx.logger.debug(this.id + ".executeCode");
console.debug(this.id + ".executeCode");
var external = this.contentsPath !== "" ? true : false;
switch (this.contenttype) {
case "html":
Expand Down Expand Up @@ -99,7 +99,7 @@ define([
},

update: function (obj, callback) {
mx.logger.debug(this.id + ".update");
console.debug(this.id + ".update");
this.contextObj = obj;
if (this.refreshOnContextChange) {
this.executeCode();
Expand All @@ -123,7 +123,7 @@ define([
},

_setupEvents: function () {
mx.logger.debug(this.id + "._setupEvents");
console.debug(this.id + "._setupEvents");
if (this.onclickmf) {
this.connect(
this.domNode,
Expand All @@ -134,7 +134,7 @@ define([
},

_executeMicroflow: function () {
mx.logger.debug(this.id + "._executeMicroflow");
console.debug(this.id + "._executeMicroflow");
if (this.onclickmf) {
var params = {
actionname: this.onclickmf
Expand All @@ -146,19 +146,19 @@ define([
mx.data.action({
params: params,
callback: function (obj) {
mx.logger.debug(
console.debug(
this.id + " (executed microflow successfully)."
);
},
error: function (error) {
mx.logger.error(this.id + error);
console.error(this.id + error);
}
});
}
},

evalJs: function () {
mx.logger.debug(this.id + ".evalJS");
console.debug(this.id + ".evalJS");
try {
eval(this.contents + "\r\n//# sourceURL=" + this.id + ".js");
} catch (error) {
Expand All @@ -167,7 +167,7 @@ define([
},

_evalJQueryCode: function () {
mx.logger.debug(this.id + "._evalJQueryCode");
console.debug(this.id + "._evalJQueryCode");
require(["jquery"], lang.hitch(this, function(jQuery){
try {
(function (snippetCode) {
Expand Down Expand Up @@ -197,7 +197,7 @@ define([
},

_handleError: function (error) {
mx.logger.debug(this.id + "._handleError");
console.debug(this.id + "._handleError");
domConstruct.place(
'<div class="alert alert-danger">Error while evaluating javascript input: ' +
error +
Expand All @@ -208,7 +208,7 @@ define([
},

_executeCallback: function (cb, from) {
mx.logger.debug(this.id + "._executeCallback" + (from ? " from " + from : ""));
console.debug(this.id + "._executeCallback" + (from ? " from " + from : ""));
if (cb && typeof cb === "function") {
cb();
}
Expand Down
2 changes: 1 addition & 1 deletion src/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://www.mendix.com/package/1.0/">
<clientModule name="HTMLSnippet" version="3.9.7" xmlns="http://www.mendix.com/clientModule/1.0/">
<clientModule name="HTMLSnippet" version="3.9.8" xmlns="http://www.mendix.com/clientModule/1.0/">
<widgetFiles>
<widgetFile path="HTMLSnippet/HTMLSnippet.xml"/>
<widgetFile path="HTMLSnippet/HTMLSnippetContext.xml"/>
Expand Down