@iebh/tera-fy 2.0.9 → 2.0.10

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/api.md CHANGED
@@ -1089,6 +1089,7 @@ All options are cumulative - i.e. they are merged with other options previously
1089
1089
  * `options` **([Object][159] | [Boolean][167])?** Additional options to mutate behaviour, if boolean false `{close: true}` is assumed
1090
1090
 
1091
1091
  * `options.title` **[String][158]** Window title, can only be set on the initial call (optional, default `'TERA'`)
1092
+ * `options.backdrop` **[String][158]** Set to `'static'` to prevent user being able to click outside the modal to close (optional, default `true`)
1092
1093
  * `options.body` **[String][158]** Window body text, can only be set on the initial call (optional, default `''`)
1093
1094
  * `options.bodyHtml` **[Boolean][167]** Treat body text as HTML (optional, default `false`)
1094
1095
  * `options.close` **[Boolean][167]** Close the existing dialog, if true the dialog is disposed and options reset (optional, default `false`)
@@ -1426,6 +1426,7 @@ export default class TeraFy {
1426
1426
  * @function uiProgress
1427
1427
  * @param {Object|Boolean} [options] Additional options to mutate behaviour, if boolean false `{close: true}` is assumed
1428
1428
  * @param {String} [options.title='TERA'] Window title, can only be set on the initial call
1429
+ * @param {String} [options.backdrop=true] Set to `'static'` to prevent user being able to click outside the modal to close
1429
1430
  * @param {String} [options.body=''] Window body text, can only be set on the initial call
1430
1431
  * @param {Boolean} [options.bodyHtml=false] Treat body text as HTML
1431
1432
  * @param {Boolean} [options.close=false] Close the existing dialog, if true the dialog is disposed and options reset
@@ -1568,6 +1568,7 @@ export default class TeraFyServer {
1568
1568
  * @returns {Promise} A promise which resolves when the dialog has been updated
1569
1569
  */
1570
1570
  uiProgress(options) {
1571
+ console.warn('uiProgress called, current uiProgressPromise:', this.uiProgressPromise)
1571
1572
  if (options === false) options = {close: true}; // Shorthand to close existing ui progress window
1572
1573
 
1573
1574
  if (this.uiProgressOptions === null) { // New uiProgress window
@@ -1595,12 +1596,14 @@ export default class TeraFyServer {
1595
1596
  this.uiProgressPromise = this.requestFocus(()=>
1596
1597
  app.service('$prompt').dialog({
1597
1598
  title: this.uiProgressOptions.title,
1599
+ backdrop: this.uiProgressOptions.backdrop, // pass backdrop to allow 'static' dialog
1598
1600
  component: 'uiProgress',
1599
1601
  componentProps: this.uiProgressOptions,
1600
1602
  closeable: false,
1601
1603
  keyboard: false,
1602
1604
  })
1603
1605
  );
1606
+ console.warn('Set uiProgressPromise:', this.uiProgressPromise)
1604
1607
  return Promise.resolve();
1605
1608
  } else {
1606
1609
  throw new Error('Unknown uiProgress state');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iebh/tera-fy",
3
- "version": "2.0.9",
3
+ "version": "2.0.10",
4
4
  "description": "TERA website worker",
5
5
  "scripts": {
6
6
  "dev": "esbuild --platform=browser --format=esm --bundle lib/terafy.client.js --outfile=dist/terafy.js --minify --serve --servedir=.",