@vertigis/workflow 5.32.1 → 5.32.2

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.
@@ -1 +1 @@
1
- export declare const VERSION = "5.32.1+2";
1
+ export declare const VERSION = "5.32.2+1";
@@ -1 +1 @@
1
- define(["require","exports"],function(e,i){"use strict";Object.defineProperty(i,"__esModule",{value:!0}),i.VERSION=void 0,i.VERSION="5.32.1+2"});
1
+ define(["require","exports"],function(e,i){"use strict";Object.defineProperty(i,"__esModule",{value:!0}),i.VERSION=void 0,i.VERSION="5.32.2+1"});
@@ -1,6 +1,11 @@
1
- /// <reference types="react" />
2
1
  import { Application, Map, Site, Widget } from "@vertigis/workflow/runtime/app";
2
+ import React from "react";
3
3
  import { FormRenderer } from "../activities/forms/FormRenderer";
4
+ /**
5
+ * Re-export react for use in custom activities. This is not a pattern we encourage,
6
+ * but there are legacy custom activity packs that will break without it.
7
+ */
8
+ export { React };
4
9
  /** Properties that control how an activity user interface is hosted by the host application. */
5
10
  export interface ShowProps {
6
11
  /** The name of the container that will host the activity user interface. */
@@ -1 +1 @@
1
- import{isValidElement}from"react";import{render}from"react-dom";import{Task}from"../Task.js";function update(e,t){let r=!1;if(null!=t)for(const i in t)e[i]!==t[i]&&(e[i]=t[i],r=!0);return r}const AppActivity=function(){const i=this.execute;this.execute=function(e,r){var t=r.ambient.trivia;return this.app=t.app,this.map=t.map,this.site=t.site,this.widget=t.widget,this.FormRenderer=t.FormRenderer,this.completion=r.ambient.completion,this.execute=i,this.createRenderer=()=>{let e=this.renderer;var t;return void 0===e&&(e=this.renderer=this.FormRenderer.createCustom(),e.state=r.ambient,t=()=>e.dispose(),this.completion.then(t,t)),this.renderer||(this.renderer=this.FormRenderer.createCustom())},i.apply(this,arguments)}};AppActivity.prototype.createRenderer=function(){return null},AppActivity.prototype.applyProps=function(e){const t=this.createRenderer();if(update(this.showProps||(this.showProps={}),e)){const e=this.showProps;t.form={defaults:{container:e.container},elements:{header:{type:"Header",section:"header",title:{markdown:e.title},value:e.icon}}},t.invalidate()}},AppActivity.prototype.show=function(e){return this.applyProps(e),this.createRenderer().show()},AppActivity.prototype.spin=function(e){return this.applyProps(e),this.createRenderer().spin()},AppActivity.prototype.spinNoBlock=function(e){return this.applyProps(e),this.createRenderer().spinNoBlock()},AppActivity.prototype.hide=function(){return this.createRenderer().hide()},AppActivity.prototype.render=async function(t,i){const n=this.createRenderer().container;if("function"!=typeof t)return isValidElement(t)?new Task(function(e){render(t,n,e)}):n;{const o=this,s=t;return new Task(async function(e,t){const r=e.bind(void 0);r.reject=t.bind(void 0),render(await s.call(o,r,i),n)})}};export{AppActivity};
1
+ import{isValidElement}from"react";import React from"react";import{render}from"react-dom";import{Task}from"../Task.js";function update(e,t){let r=!1;if(null!=t)for(const i in t)e[i]!==t[i]&&(e[i]=t[i],r=!0);return r}const AppActivity=function(){const i=this.execute;this.execute=function(e,r){var t=r.ambient.trivia;return this.app=t.app,this.map=t.map,this.site=t.site,this.widget=t.widget,this.FormRenderer=t.FormRenderer,this.completion=r.ambient.completion,this.execute=i,this.createRenderer=()=>{let e=this.renderer;var t;return void 0===e&&(e=this.renderer=this.FormRenderer.createCustom(),e.state=r.ambient,t=()=>e.dispose(),this.completion.then(t,t)),this.renderer||(this.renderer=this.FormRenderer.createCustom())},i.apply(this,arguments)}};AppActivity.prototype.createRenderer=function(){return null},AppActivity.prototype.applyProps=function(e){const t=this.createRenderer();if(update(this.showProps||(this.showProps={}),e)){const e=this.showProps;t.form={defaults:{container:e.container},elements:{header:{type:"Header",section:"header",title:{markdown:e.title},value:e.icon}}},t.invalidate()}},AppActivity.prototype.show=function(e){return this.applyProps(e),this.createRenderer().show()},AppActivity.prototype.spin=function(e){return this.applyProps(e),this.createRenderer().spin()},AppActivity.prototype.spinNoBlock=function(e){return this.applyProps(e),this.createRenderer().spinNoBlock()},AppActivity.prototype.hide=function(){return this.createRenderer().hide()},AppActivity.prototype.render=async function(t,i){const n=this.createRenderer().container;if("function"!=typeof t)return isValidElement(t)?new Task(function(e){render(t,n,e)}):n;{const o=this,s=t;return new Task(async function(e,t){const r=e.bind(void 0);r.reject=t.bind(void 0),render(await s.call(o,r,i),n)})}};export{React,AppActivity};
@@ -1 +1 @@
1
- export declare const VERSION = "5.32.1+2";
1
+ export declare const VERSION = "5.32.2+1";
@@ -1 +1 @@
1
- const VERSION="5.32.1+2";export{VERSION};
1
+ const VERSION="5.32.2+1";export{VERSION};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vertigis/workflow",
3
- "version": "5.32.1",
3
+ "version": "5.32.2",
4
4
  "author": "VertiGIS",
5
5
  "dependencies": {
6
6
  "@zxing/library": "^0.18.3",
@@ -1,6 +1,11 @@
1
- /// <reference types="react" />
2
1
  import { Application, Map, Site, Widget } from "@vertigis/workflow/runtime/app";
2
+ import React from "react";
3
3
  import { FormRenderer } from "../activities/forms/FormRenderer";
4
+ /**
5
+ * Re-export react for use in custom activities. This is not a pattern we encourage,
6
+ * but there are legacy custom activity packs that will break without it.
7
+ */
8
+ export { React };
4
9
  /** Properties that control how an activity user interface is hosted by the host application. */
5
10
  export interface ShowProps {
6
11
  /** The name of the container that will host the activity user interface. */
@@ -1 +1 @@
1
- !function(e){"object"==typeof module&&"object"==typeof module.exports?e(require,exports):"function"==typeof define&&define.amd&&define(["require","exports","tslib","react","react-dom","../Task"],e)}(function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AppActivity=void 0;var a=e("tslib"),r=e("react"),u=e("react-dom"),i=e("../Task");t.AppActivity=function(){var n=this.execute;this.execute=function(e,r){var i=this,t=r.ambient.trivia;return this.app=t.app,this.map=t.map,this.site=t.site,this.widget=t.widget,this.FormRenderer=t.FormRenderer,this.completion=r.ambient.completion,this.execute=n,this.createRenderer=function(){var e,t=i.renderer;return void 0===t&&((t=i.renderer=i.FormRenderer.createCustom()).state=r.ambient,e=function(){return t.dispose()},i.completion.then(e,e)),i.renderer||(i.renderer=i.FormRenderer.createCustom())},n.apply(this,arguments)}},t.AppActivity.prototype.createRenderer=function(){return null},t.AppActivity.prototype.applyProps=function(e){var t=this.createRenderer();!function(e,t){var r=!1;if(null!=t)for(var i in t)e[i]!==t[i]&&(e[i]=t[i],r=!0);return r}(this.showProps||(this.showProps={}),e)||(e=this.showProps,t.form={defaults:{container:e.container},elements:{header:{type:"Header",section:"header",title:{markdown:e.title},value:e.icon}}},t.invalidate())},t.AppActivity.prototype.show=function(e){return this.applyProps(e),this.createRenderer().show()},t.AppActivity.prototype.spin=function(e){return this.applyProps(e),this.createRenderer().spin()},t.AppActivity.prototype.spinNoBlock=function(e){return this.applyProps(e),this.createRenderer().spinNoBlock()},t.AppActivity.prototype.hide=function(){return this.createRenderer().hide()},t.AppActivity.prototype.render=function(t,c){return(0,a.__awaiter)(this,void 0,void 0,function(){var o,p,s;return(0,a.__generator)(this,function(e){return o=this.createRenderer().container,"function"==typeof t?(p=this,s=t,[2,new i.Task(function(i,n){return(0,a.__awaiter)(this,void 0,void 0,function(){var t,r;return(0,a.__generator)(this,function(e){switch(e.label){case 0:return(t=i.bind(void 0)).reject=n.bind(void 0),r=u.render,[4,s.call(p,t,c)];case 1:return r.apply(void 0,[e.sent(),o]),[2]}})})})]):(0,r.isValidElement)(t)?[2,new i.Task(function(e){(0,u.render)(t,o,e)})]:[2,o]})})}});
1
+ !function(e){"object"==typeof module&&"object"==typeof module.exports?e(require,exports):"function"==typeof define&&define.amd&&define(["require","exports","tslib","react","react","react-dom","../Task"],e)}(function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AppActivity=t.React=void 0;var c=e("tslib"),r=e("react"),i=(0,c.__importDefault)(e("react"));t.React=i.default;var u=e("react-dom"),n=e("../Task");t.AppActivity=function(){var n=this.execute;this.execute=function(e,r){var i=this,t=r.ambient.trivia;return this.app=t.app,this.map=t.map,this.site=t.site,this.widget=t.widget,this.FormRenderer=t.FormRenderer,this.completion=r.ambient.completion,this.execute=n,this.createRenderer=function(){var e,t=i.renderer;return void 0===t&&((t=i.renderer=i.FormRenderer.createCustom()).state=r.ambient,e=function(){return t.dispose()},i.completion.then(e,e)),i.renderer||(i.renderer=i.FormRenderer.createCustom())},n.apply(this,arguments)}},t.AppActivity.prototype.createRenderer=function(){return null},t.AppActivity.prototype.applyProps=function(e){var t=this.createRenderer();!function(e,t){var r=!1;if(null!=t)for(var i in t)e[i]!==t[i]&&(e[i]=t[i],r=!0);return r}(this.showProps||(this.showProps={}),e)||(e=this.showProps,t.form={defaults:{container:e.container},elements:{header:{type:"Header",section:"header",title:{markdown:e.title},value:e.icon}}},t.invalidate())},t.AppActivity.prototype.show=function(e){return this.applyProps(e),this.createRenderer().show()},t.AppActivity.prototype.spin=function(e){return this.applyProps(e),this.createRenderer().spin()},t.AppActivity.prototype.spinNoBlock=function(e){return this.applyProps(e),this.createRenderer().spinNoBlock()},t.AppActivity.prototype.hide=function(){return this.createRenderer().hide()},t.AppActivity.prototype.render=function(t,s){return(0,c.__awaiter)(this,void 0,void 0,function(){var o,p,a;return(0,c.__generator)(this,function(e){return o=this.createRenderer().container,"function"==typeof t?(p=this,a=t,[2,new n.Task(function(i,n){return(0,c.__awaiter)(this,void 0,void 0,function(){var t,r;return(0,c.__generator)(this,function(e){switch(e.label){case 0:return(t=i.bind(void 0)).reject=n.bind(void 0),r=u.render,[4,a.call(p,t,s)];case 1:return r.apply(void 0,[e.sent(),o]),[2]}})})})]):(0,r.isValidElement)(t)?[2,new n.Task(function(e){(0,u.render)(t,o,e)})]:[2,o]})})}});