babylonjs-gui 5.28.0 → 5.29.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/babylon.gui.d.ts CHANGED
@@ -556,7 +556,7 @@ declare module BABYLON.GUI {
556
556
  get image(): BABYLON.Nullable<Image>;
557
557
  private _textBlock;
558
558
  /**
559
- * Returns the image part of the button (if any)
559
+ * Returns the TextBlock part of the button (if any)
560
560
  */
561
561
  get textBlock(): BABYLON.Nullable<TextBlock>;
562
562
  /**
package/babylon.gui.js CHANGED
@@ -451,7 +451,7 @@ __webpack_require__.r(__webpack_exports__);
451
451
  /* harmony export */ "AdvancedDynamicTexture": () => (/* binding */ AdvancedDynamicTexture)
452
452
  /* harmony export */ });
453
453
  /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "../../../../node_modules/tslib/tslib.es6.js");
454
- /* harmony import */ var core_Misc_observable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core/Misc/typeStore */ "core/Misc/observable");
454
+ /* harmony import */ var core_Misc_observable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core/Misc/stringTools */ "core/Misc/observable");
455
455
  /* harmony import */ var core_Misc_observable__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_Misc_observable__WEBPACK_IMPORTED_MODULE_1__);
456
456
  /* harmony import */ var _controls_container__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./controls/container */ "../../../lts/gui/dist/2D/controls/container.js");
457
457
  /* harmony import */ var _controls_control__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./controls/control */ "../../../lts/gui/dist/2D/controls/control.js");
@@ -476,6 +476,7 @@ __webpack_require__.r(__webpack_exports__);
476
476
 
477
477
 
478
478
 
479
+
479
480
 
480
481
  /**
481
482
  * Class used to create texture to support 2D GUI elements
@@ -1751,7 +1752,14 @@ var AdvancedDynamicTexture = /** @class */ (function (_super) {
1751
1752
  request.addEventListener("readystatechange", function () {
1752
1753
  if (request.readyState == 4) {
1753
1754
  if (request.status == 200) {
1754
- var gui = snippet ? JSON.parse(JSON.parse(request.responseText).jsonPayload).gui : request.responseText;
1755
+ var gui = void 0;
1756
+ if (snippet) {
1757
+ var payload = JSON.parse(JSON.parse(request.responseText).jsonPayload);
1758
+ gui = payload.encodedGui ? new TextDecoder("utf-8").decode((0,core_Misc_observable__WEBPACK_IMPORTED_MODULE_1__.DecodeBase64ToBinary)(payload.encodedGui)) : payload.gui;
1759
+ }
1760
+ else {
1761
+ gui = request.responseText;
1762
+ }
1755
1763
  var serializationObject = JSON.parse(gui);
1756
1764
  resolve(serializationObject);
1757
1765
  }
@@ -1973,7 +1981,7 @@ var Button = /** @class */ (function (_super) {
1973
1981
  });
1974
1982
  Object.defineProperty(Button.prototype, "textBlock", {
1975
1983
  /**
1976
- * Returns the image part of the button (if any)
1984
+ * Returns the TextBlock part of the button (if any)
1977
1985
  */
1978
1986
  get: function () {
1979
1987
  return this._textBlock;