gd-bs 5.8.4 → 5.8.5
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/build/components/modal/index.js +36 -4
- package/build/components/offcanvas/index.js +36 -4
- package/dist/gd-bs-icons.js +1 -1
- package/dist/gd-bs-icons.min.js +1 -1
- package/dist/gd-bs.js +1 -1
- package/dist/gd-bs.min.js +1 -1
- package/package.json +1 -1
- package/src/components/modal/index.ts +34 -4
- package/src/components/offcanvas/index.ts +34 -4
|
@@ -215,8 +215,24 @@ var _Modal = /** @class */ (function (_super) {
|
|
|
215
215
|
*/
|
|
216
216
|
// Hides the modal
|
|
217
217
|
_Modal.prototype.hide = function () {
|
|
218
|
-
|
|
219
|
-
|
|
218
|
+
var _this = this;
|
|
219
|
+
// See if a transition is currently happening
|
|
220
|
+
if (this._tranisitioningFl) {
|
|
221
|
+
// Wait for the transition to complete
|
|
222
|
+
var id_1 = setInterval(function () {
|
|
223
|
+
// See if the transition is complete
|
|
224
|
+
if (!_this._tranisitioningFl) {
|
|
225
|
+
// Stop the loop
|
|
226
|
+
clearInterval(id_1);
|
|
227
|
+
// Toggle the modal
|
|
228
|
+
_this.isVisible ? _this.toggle() : null;
|
|
229
|
+
}
|
|
230
|
+
}, 250);
|
|
231
|
+
}
|
|
232
|
+
else {
|
|
233
|
+
// Toggle the modal
|
|
234
|
+
this.isVisible ? this.toggle() : null;
|
|
235
|
+
}
|
|
220
236
|
};
|
|
221
237
|
Object.defineProperty(_Modal.prototype, "isVisible", {
|
|
222
238
|
// Returns true if the modal is visible
|
|
@@ -307,8 +323,24 @@ var _Modal = /** @class */ (function (_super) {
|
|
|
307
323
|
};
|
|
308
324
|
// Shows the modal
|
|
309
325
|
_Modal.prototype.show = function () {
|
|
310
|
-
|
|
311
|
-
|
|
326
|
+
var _this = this;
|
|
327
|
+
// See if a transition is currently happening
|
|
328
|
+
if (this._tranisitioningFl) {
|
|
329
|
+
// Wait for the transition to complete
|
|
330
|
+
var id_2 = setInterval(function () {
|
|
331
|
+
// See if the transition is complete
|
|
332
|
+
if (!_this._tranisitioningFl) {
|
|
333
|
+
// Stop the loop
|
|
334
|
+
clearInterval(id_2);
|
|
335
|
+
// Toggle the modal
|
|
336
|
+
_this.isVisible ? null : _this.toggle();
|
|
337
|
+
}
|
|
338
|
+
}, 250);
|
|
339
|
+
}
|
|
340
|
+
else {
|
|
341
|
+
// Toggle the modal
|
|
342
|
+
this.isVisible ? null : this.toggle();
|
|
343
|
+
}
|
|
312
344
|
};
|
|
313
345
|
// Toggles the modal
|
|
314
346
|
_Modal.prototype.toggle = function () {
|
|
@@ -215,8 +215,24 @@ var _Offcanvas = /** @class */ (function (_super) {
|
|
|
215
215
|
*/
|
|
216
216
|
// Hides the modal
|
|
217
217
|
_Offcanvas.prototype.hide = function () {
|
|
218
|
-
|
|
219
|
-
|
|
218
|
+
var _this = this;
|
|
219
|
+
// See if a transition is currently happening
|
|
220
|
+
if (this._tranisitioningFl) {
|
|
221
|
+
// Wait for the transition to complete
|
|
222
|
+
var id_1 = setInterval(function () {
|
|
223
|
+
// See if the transition is complete
|
|
224
|
+
if (!_this._tranisitioningFl) {
|
|
225
|
+
// Stop the loop
|
|
226
|
+
clearInterval(id_1);
|
|
227
|
+
// Toggle the modal
|
|
228
|
+
_this.isVisible ? _this.toggle() : null;
|
|
229
|
+
}
|
|
230
|
+
}, 250);
|
|
231
|
+
}
|
|
232
|
+
else {
|
|
233
|
+
// Toggle the modal
|
|
234
|
+
this.isVisible ? this.toggle() : null;
|
|
235
|
+
}
|
|
220
236
|
};
|
|
221
237
|
Object.defineProperty(_Offcanvas.prototype, "isVisible", {
|
|
222
238
|
// Returns true if the modal is visible
|
|
@@ -259,8 +275,24 @@ var _Offcanvas = /** @class */ (function (_super) {
|
|
|
259
275
|
};
|
|
260
276
|
// Shows the modal
|
|
261
277
|
_Offcanvas.prototype.show = function () {
|
|
262
|
-
|
|
263
|
-
|
|
278
|
+
var _this = this;
|
|
279
|
+
// See if a transition is currently happening
|
|
280
|
+
if (this._tranisitioningFl) {
|
|
281
|
+
// Wait for the transition to complete
|
|
282
|
+
var id_2 = setInterval(function () {
|
|
283
|
+
// See if the transition is complete
|
|
284
|
+
if (!_this._tranisitioningFl) {
|
|
285
|
+
// Stop the loop
|
|
286
|
+
clearInterval(id_2);
|
|
287
|
+
// Toggle the modal
|
|
288
|
+
_this.isVisible ? null : _this.toggle();
|
|
289
|
+
}
|
|
290
|
+
}, 250);
|
|
291
|
+
}
|
|
292
|
+
else {
|
|
293
|
+
// Toggle the modal
|
|
294
|
+
this.isVisible ? null : this.toggle();
|
|
295
|
+
}
|
|
264
296
|
};
|
|
265
297
|
// Toggles the modal
|
|
266
298
|
_Offcanvas.prototype.toggle = function () {
|