@esri/solutions-components 0.8.9 → 0.8.11
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/assets/t9n/crowdsource-reporter/resources.json +9 -2
- package/dist/assets/t9n/crowdsource-reporter/resources_en.json +9 -2
- package/dist/cjs/calcite-alert_4.cjs.entry.js +2 -1
- package/dist/cjs/calcite-dropdown_4.cjs.entry.js +1 -1
- package/dist/cjs/calcite-flow_6.cjs.entry.js +1 -1
- package/dist/cjs/card-manager_3.cjs.entry.js +2 -2
- package/dist/cjs/crowdsource-manager.cjs.entry.js +25 -17
- package/dist/cjs/crowdsource-reporter.cjs.entry.js +3 -3
- package/dist/cjs/{downloadUtils-dc349b1a.js → downloadUtils-dd787ddf.js} +2 -2
- package/dist/cjs/{index.es-1830a1e6.js → index.es-29fa176d.js} +2 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/map-select-tools_3.cjs.entry.js +2 -2
- package/dist/cjs/{mapViewUtils-9dc05308.js → mapViewUtils-82018df6.js} +1 -1
- package/dist/cjs/public-notification.cjs.entry.js +2 -2
- package/dist/cjs/solutions-components.cjs.js +1 -1
- package/dist/collection/components/crowdsource-manager/crowdsource-manager.css +15 -0
- package/dist/collection/components/crowdsource-manager/crowdsource-manager.js +48 -16
- package/dist/collection/components/crowdsource-reporter/crowdsource-reporter.js +4 -3
- package/dist/collection/components/info-card/info-card.js +1 -0
- package/dist/collection/demos/crowdsource-manager.html +7 -2
- package/dist/collection/utils/mapViewUtils.js +1 -1
- package/dist/collection/utils/mapViewUtils.ts +1 -1
- package/dist/components/crowdsource-manager.js +26 -18
- package/dist/components/crowdsource-reporter.js +2 -2
- package/dist/components/info-card2.js +1 -0
- package/dist/components/mapViewUtils.js +1 -1
- package/dist/esm/calcite-alert_4.entry.js +2 -1
- package/dist/esm/calcite-dropdown_4.entry.js +1 -1
- package/dist/esm/calcite-flow_6.entry.js +1 -1
- package/dist/esm/card-manager_3.entry.js +2 -2
- package/dist/esm/crowdsource-manager.entry.js +26 -18
- package/dist/esm/crowdsource-reporter.entry.js +3 -3
- package/dist/esm/{downloadUtils-df4f21f6.js → downloadUtils-25aa808f.js} +2 -2
- package/dist/esm/{index.es-904fb846.js → index.es-a16c9db4.js} +2 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/map-select-tools_3.entry.js +2 -2
- package/dist/esm/{mapViewUtils-2ec19fb0.js → mapViewUtils-c83c03a4.js} +1 -1
- package/dist/esm/public-notification.entry.js +2 -2
- package/dist/esm/solutions-components.js +1 -1
- package/dist/solutions-components/demos/crowdsource-manager.html +7 -2
- package/dist/solutions-components/{p-95fea07a.entry.js → p-2f687975.entry.js} +1 -1
- package/dist/solutions-components/{p-29f518fd.entry.js → p-3e5085ae.entry.js} +2 -2
- package/dist/solutions-components/p-40039b84.entry.js +6 -0
- package/dist/solutions-components/{p-6557b703.entry.js → p-58997cc1.entry.js} +1 -1
- package/dist/solutions-components/p-5ce5a6ae.entry.js +6 -0
- package/dist/solutions-components/{p-602cd811.entry.js → p-82e398cb.entry.js} +1 -1
- package/dist/solutions-components/{p-7269c49b.entry.js → p-ae75d7d7.entry.js} +1 -1
- package/dist/solutions-components/{p-fca434c8.js → p-b1376c75.js} +2 -2
- package/dist/solutions-components/{p-fd82a00f.entry.js → p-b5acfcd8.entry.js} +1 -1
- package/dist/solutions-components/{p-ae4d86e8.js → p-bdd77f17.js} +1 -1
- package/dist/solutions-components/{p-577efb16.js → p-d9c89479.js} +1 -1
- package/dist/solutions-components/solutions-components.esm.js +1 -1
- package/dist/solutions-components/utils/mapViewUtils.ts +1 -1
- package/dist/types/components/crowdsource-manager/crowdsource-manager.d.ts +13 -1
- package/dist/types/components.d.ts +19 -0
- package/dist/types/preact.d.ts +3 -1
- package/package.json +1 -1
- package/dist/solutions-components/p-452fd697.entry.js +0 -6
- package/dist/solutions-components/p-760bd17e.entry.js +0 -6
@@ -12,12 +12,19 @@
|
|
12
12
|
"error": "Error",
|
13
13
|
"invalidConfigurationErrorMsg": "Invalid configuration",
|
14
14
|
"noLayerToDisplayErrorMsg": "Configured web map don't have any editable feature layer.",
|
15
|
-
"chooseCategoryMsg": "
|
15
|
+
"chooseCategoryMsg": "Make a selection from the list below.",
|
16
16
|
"featureErrorMsg": "No records found.",
|
17
17
|
"featureEditFormInfoMsg": "Please provide the details.",
|
18
18
|
"currentLocationMsg": "Use my current location",
|
19
19
|
"addLocationMsg": "Please add a location.",
|
20
20
|
"submitMsg": "Thank you! Your report was successfully submitted.",
|
21
21
|
"filterLayerTitle": "Filter: {{title}}",
|
22
|
-
"indexOfTotal": "{{index}} of {{total}}"
|
22
|
+
"indexOfTotal": "{{index}} of {{total}}",
|
23
|
+
"comment": "Comment",
|
24
|
+
"commentSubmittedMsg": "Comment submitted",
|
25
|
+
"addingCommentFailedMsg": "Comment not submitted",
|
26
|
+
"sortNewest": "Newest",
|
27
|
+
"sortOldest": "Oldest",
|
28
|
+
"sortHighestVoted": "Highest voted",
|
29
|
+
"sortLowestVoted": "Lowest voted"
|
23
30
|
}
|
@@ -12,12 +12,19 @@
|
|
12
12
|
"error": "Error",
|
13
13
|
"invalidConfigurationErrorMsg": "Invalid configuration",
|
14
14
|
"noLayerToDisplayErrorMsg": "Configured web map don't have any editable feature layer.",
|
15
|
-
"chooseCategoryMsg": "
|
15
|
+
"chooseCategoryMsg": "Make a selection from the list below.",
|
16
16
|
"featureErrorMsg": "No records found.",
|
17
17
|
"featureEditFormInfoMsg": "Please provide the details.",
|
18
18
|
"currentLocationMsg": "Use my current location",
|
19
19
|
"addLocationMsg": "Please add a location.",
|
20
20
|
"submitMsg": "Thank you! Your report was successfully submitted.",
|
21
21
|
"filterLayerTitle": "Filter: {{title}}",
|
22
|
-
"indexOfTotal": "{{index}} of {{total}}"
|
22
|
+
"indexOfTotal": "{{index}} of {{total}}",
|
23
|
+
"comment": "Comment",
|
24
|
+
"commentSubmittedMsg": "Comment submitted",
|
25
|
+
"addingCommentFailedMsg": "Comment not submitted",
|
26
|
+
"sortNewest": "Newest",
|
27
|
+
"sortOldest": "Oldest",
|
28
|
+
"sortHighestVoted": "Highest voted",
|
29
|
+
"sortLowestVoted": "Lowest voted"
|
23
30
|
}
|
@@ -16,7 +16,7 @@ const openCloseComponent = require('./openCloseComponent-19a769d0.js');
|
|
16
16
|
const t9n = require('./t9n-993a84de.js');
|
17
17
|
const resources = require('./resources-dd8ff1b4.js');
|
18
18
|
const locale$1 = require('./locale-3d0a4bc2.js');
|
19
|
-
const mapViewUtils = require('./mapViewUtils-
|
19
|
+
const mapViewUtils = require('./mapViewUtils-82018df6.js');
|
20
20
|
const popupUtils = require('./popupUtils-6be3588c.js');
|
21
21
|
require('./guid-ae73cd27.js');
|
22
22
|
require('./resources-9447c777.js');
|
@@ -901,6 +901,7 @@ const InfoCard = class {
|
|
901
901
|
});
|
902
902
|
this._features.viewModel.highlightEnabled = this.highlightEnabled;
|
903
903
|
this.reactiveUtils.watch(() => this._features.viewModel.featureMenuOpen, (isOpen) => {
|
904
|
+
this._count = this._getCount();
|
904
905
|
if (!isOpen) {
|
905
906
|
this._showListView = isOpen;
|
906
907
|
}
|
@@ -18,7 +18,7 @@ const observers = require('./observers-db4527e4.js');
|
|
18
18
|
const openCloseComponent = require('./openCloseComponent-19a769d0.js');
|
19
19
|
const component = require('./component-ac7c3bd8.js');
|
20
20
|
const locale = require('./locale-3d0a4bc2.js');
|
21
|
-
const mapViewUtils = require('./mapViewUtils-
|
21
|
+
const mapViewUtils = require('./mapViewUtils-82018df6.js');
|
22
22
|
const publicNotificationStore = require('./publicNotificationStore-e790601d.js');
|
23
23
|
require('./resources-9447c777.js');
|
24
24
|
require('./debounce-30afab47.js');
|
@@ -16,7 +16,7 @@ const locale = require('./locale-d237c9d5.js');
|
|
16
16
|
const t9n = require('./t9n-993a84de.js');
|
17
17
|
const resources = require('./resources-3e593312.js');
|
18
18
|
const locale$1 = require('./locale-3d0a4bc2.js');
|
19
|
-
const mapViewUtils = require('./mapViewUtils-
|
19
|
+
const mapViewUtils = require('./mapViewUtils-82018df6.js');
|
20
20
|
const popupUtils = require('./popupUtils-6be3588c.js');
|
21
21
|
require('./guid-ae73cd27.js');
|
22
22
|
require('./resources-9447c777.js');
|
@@ -9,8 +9,8 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
9
9
|
|
10
10
|
const index = require('./index-105cf2b9.js');
|
11
11
|
const locale = require('./locale-3d0a4bc2.js');
|
12
|
-
const mapViewUtils = require('./mapViewUtils-
|
13
|
-
const downloadUtils = require('./downloadUtils-
|
12
|
+
const mapViewUtils = require('./mapViewUtils-82018df6.js');
|
13
|
+
const downloadUtils = require('./downloadUtils-dd787ddf.js');
|
14
14
|
require('./esri-loader-ce6c3d3d.js');
|
15
15
|
require('./_commonjsHelpers-480c2e77.js');
|
16
16
|
require('./interfaces-7cd0a48a.js');
|
@@ -10,15 +10,16 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
10
10
|
const index = require('./index-105cf2b9.js');
|
11
11
|
const locale = require('./locale-3d0a4bc2.js');
|
12
12
|
const interfaces = require('./interfaces-7cd0a48a.js');
|
13
|
-
const mapViewUtils = require('./mapViewUtils-
|
13
|
+
const mapViewUtils = require('./mapViewUtils-82018df6.js');
|
14
14
|
require('./esri-loader-ce6c3d3d.js');
|
15
15
|
require('./_commonjsHelpers-480c2e77.js');
|
16
16
|
|
17
|
-
const crowdsourceManagerCss = ":host{display:block;--calcite-label-margin-bottom:0px;--solutions-theme-foreground-color:var(--calcite-color-foreground-1)}.padding-1-2{padding:0.5rem}.display-flex{display:flex}.width-full{width:100%}.width-1-2{position:relative;width:50%}.width-1-3{position:relative;width:33.33%}.width-2-3{position:relative;width:66.66%}.width-0{width:0}.height-full{height:100%}.height-1-2{position:relative;height:50%}.height-0{height:0}.toggle-node{width:51px;height:51px}.overflow-hidden{overflow:hidden}.flex-column{flex-direction:column}.border{border:1px solid var(--calcite-color-border-3)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.border-sides{border-left:1px solid var(--calcite-color-border-3);border-right:1px solid var(--calcite-color-border-3)}.position-relative{position:relative}.height-50{height:50%}.adjusted-height-50{height:calc(50% - 25px)}.adjusted-height-100{height:calc(100% - 50px)}.adjusted-height-100-50{height:calc(100% - 50px)}.display-none{display:none}.height-53{height:53px}.position-absolute-53{position:absolute;top:53px}.display-grid{display:grid}.height-50-px{height:50px}.padding-inline-start-75{padding-inline-start:0.75rem}.align-items-center{align-items:center}.esri-floor-filter__close-levels-button{width:40px !important;height:40px !important}.esri-floor-filter__level-button{width:40px !important;height:40px !important}.esri-floor-filter__browse-button{width:40px !important;height:40px !important}.position-absolute-50{position:absolute;top:50px;bottom:0px;left:0px;right:0px}.position-absolute-0{position:absolute;top:0px;bottom:0px;left:0px;right:0px}.visibility-hidden{visibility:hidden;height:0px}.position-fixed{position:fixed}.border-width-0{border-width:0px}.border-bottom-width-0{border-bottom-width:0px}";
|
17
|
+
const crowdsourceManagerCss = ":host{display:block;--calcite-label-margin-bottom:0px;--solutions-theme-foreground-color:var(--calcite-color-foreground-1)}.padding-1-2{padding:0.5rem}.display-flex{display:flex}.width-full{width:100%}.width-1-2{position:relative;width:50%}.width-1-3{position:relative;width:33.33%}.width-2-3{position:relative;width:66.66%}.width-0{width:0}.height-full{height:100%}.height-1-2{position:relative;height:50%}.height-0{height:0}.toggle-node{width:51px;height:51px}.overflow-hidden{overflow:hidden}.flex-column{flex-direction:column}.border{border:1px solid var(--calcite-color-border-3)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.border-sides{border-left:1px solid var(--calcite-color-border-3);border-right:1px solid var(--calcite-color-border-3)}.position-relative{position:relative}.height-50{height:50%}.adjusted-height-50{height:calc(50% - 25px)}.adjusted-height-100{height:calc(100% - 50px)}.adjusted-height-100-50{height:calc(100% - 50px)}.display-none{display:none}.height-53{height:53px}.position-absolute-53{position:absolute;top:53px}.display-grid{display:grid}.height-50-px{height:50px}.padding-inline-start-75{padding-inline-start:0.75rem}.align-items-center{align-items:center}.esri-floor-filter__close-levels-button{width:40px !important;height:40px !important}.esri-floor-filter__level-button{width:40px !important;height:40px !important}.esri-floor-filter__browse-button{width:40px !important;height:40px !important}.position-absolute-50{position:absolute;top:50px;bottom:0px;left:0px;right:0px}.position-absolute-0{position:absolute;top:0px;bottom:0px;left:0px;right:0px}.visibility-hidden{visibility:hidden;height:0px}.position-fixed{position:fixed}.border-width-0{border-width:0px}.border-bottom-width-0{border-bottom-width:0px}.floating-container{position:fixed;width:100px;height:10px;bottom:0;right:0;margin:100px 0px}.floating-container .floating-button{box-shadow:0 10px 25px rgb(92 93 94 / 60%);transform:translatey(5px);transition:all 0.3s}";
|
18
18
|
|
19
19
|
const CrowdsourceManager = class {
|
20
20
|
constructor(hostRef) {
|
21
21
|
index.registerInstance(this, hostRef);
|
22
|
+
this.infoIconButtonClick = index.createEvent(this, "infoIconButtonClick", 7);
|
22
23
|
//--------------------------------------------------------------------------
|
23
24
|
//
|
24
25
|
// Properties (protected)
|
@@ -59,7 +60,7 @@ const CrowdsourceManager = class {
|
|
59
60
|
this.enableSearch = true;
|
60
61
|
this.enableShare = false;
|
61
62
|
this.enableZoom = true;
|
62
|
-
this.hideMapOnLoad =
|
63
|
+
this.hideMapOnLoad = false;
|
63
64
|
this.mapInfos = [];
|
64
65
|
this.onlyShowUpdatableLayers = true;
|
65
66
|
this.popupHeaderColor = undefined;
|
@@ -73,7 +74,7 @@ const CrowdsourceManager = class {
|
|
73
74
|
this.theme = "light";
|
74
75
|
this.zoomAndScrollToSelected = false;
|
75
76
|
this.zoomToScale = undefined;
|
76
|
-
this._expandPopup =
|
77
|
+
this._expandPopup = this.hideMapOnLoad;
|
77
78
|
this._hideFooter = false;
|
78
79
|
this._hideTable = false;
|
79
80
|
this._isMobile = undefined;
|
@@ -97,16 +98,6 @@ const CrowdsourceManager = class {
|
|
97
98
|
enableZoomWatchHandler() {
|
98
99
|
this._initMapZoom();
|
99
100
|
}
|
100
|
-
//--------------------------------------------------------------------------
|
101
|
-
//
|
102
|
-
// Methods (public)
|
103
|
-
//
|
104
|
-
//--------------------------------------------------------------------------
|
105
|
-
//--------------------------------------------------------------------------
|
106
|
-
//
|
107
|
-
// Events (public)
|
108
|
-
//
|
109
|
-
//--------------------------------------------------------------------------
|
110
101
|
/**
|
111
102
|
* Listen for changes in feature selection and show or hide the map, popup, and table
|
112
103
|
*/
|
@@ -153,7 +144,6 @@ const CrowdsourceManager = class {
|
|
153
144
|
async beforeMapChanged() {
|
154
145
|
if (this._expandPopup) {
|
155
146
|
this._shouldSetMapView = true;
|
156
|
-
this._expandPopup = false;
|
157
147
|
}
|
158
148
|
}
|
159
149
|
/**
|
@@ -166,6 +156,12 @@ const CrowdsourceManager = class {
|
|
166
156
|
this._layer = layer;
|
167
157
|
});
|
168
158
|
}
|
159
|
+
/**
|
160
|
+
* Update the state expandPopup when mapInfoChange event occurs
|
161
|
+
*/
|
162
|
+
async mapInfoChange() {
|
163
|
+
this._expandPopup = this.hideMapOnLoad;
|
164
|
+
}
|
169
165
|
//--------------------------------------------------------------------------
|
170
166
|
//
|
171
167
|
// Functions (lifecycle)
|
@@ -305,7 +301,14 @@ const CrowdsourceManager = class {
|
|
305
301
|
*/
|
306
302
|
_getBody(layoutMode, panelOpen, hideTable) {
|
307
303
|
const contentClass = layoutMode === interfaces.ELayoutMode.HORIZONTAL ? "" : "display-flex";
|
308
|
-
|
304
|
+
const themeClass = this.theme === "dark" ? "calcite-mode-dark" : "calcite-mode-light";
|
305
|
+
return (index.h("calcite-panel", { class: "width-full height-full" }, index.h("div", { class: `width-full height-full overflow-hidden ${contentClass}` }, this._getMapAndCard(layoutMode, panelOpen, hideTable), this._getTable(layoutMode, panelOpen, hideTable)), index.h("div", { class: "floating-container", onClick: this.infoButtonClick.bind(this) }, index.h("calcite-button", { appearance: "solid", class: `floating-button ${themeClass}`, "icon-start": "information-letter", kind: "neutral", label: "", round: true, scale: "l", "split-child": "primary", width: "auto" }))));
|
306
|
+
}
|
307
|
+
/**
|
308
|
+
* Emit the event when info button clicked
|
309
|
+
*/
|
310
|
+
infoButtonClick() {
|
311
|
+
this.infoIconButtonClick.emit();
|
309
312
|
}
|
310
313
|
/**
|
311
314
|
* Get the map and card nodes based for the current layout options
|
@@ -351,7 +354,12 @@ const CrowdsourceManager = class {
|
|
351
354
|
const headerClass = this._isMobile ? "display-none height-0" : "";
|
352
355
|
const headerTheme = !this._isMobile ? "calcite-mode-dark" : "calcite-mode-light";
|
353
356
|
const containerClass = this._isMobile && this._hideTable ? "position-absolute-0 width-full height-full" : this._isMobile ? "display-none height-0" : "";
|
354
|
-
return (index.h("div", { class: `${headerTheme} ${popupNodeClass} ${containerClass}
|
357
|
+
return (index.h("div", { class: `${headerTheme} ${popupNodeClass} ${containerClass}`, style: {
|
358
|
+
'--calcite-color-foreground-1': this.popupHeaderColor,
|
359
|
+
'--calcite-color-foreground-2': this.popupHeaderHoverColor,
|
360
|
+
'--calcite-color-text-3': this.popupHeaderHoverTextColor,
|
361
|
+
'--calcite-color-text-2': this.popupHeaderTextColor, /* font color to apply to the popup header */
|
362
|
+
} }, index.h("calcite-panel", null, !this._isMobile ? (index.h("div", { class: `display-flex align-items-center ${headerClass}`, slot: "header-content" }, index.h("calcite-icon", { icon: "information", scale: "s" }), index.h("div", { class: "padding-inline-start-75" }, this._translations.information))) : undefined, index.h("calcite-action", { class: headerClass, disabled: this._tableOnly, icon: icon, id: id, onClick: () => this._togglePopup(), slot: "header-actions-end", text: "" }), !this._tableOnly ? index.h("calcite-tooltip", { class: themeClass, label: "", placement: "bottom", "reference-element": id }, index.h("span", null, tooltip)) : undefined, this._getCardNode())));
|
355
363
|
}
|
356
364
|
/**
|
357
365
|
* Toggle the popup information
|
@@ -9,7 +9,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
9
9
|
|
10
10
|
const index = require('./index-105cf2b9.js');
|
11
11
|
const locale = require('./locale-3d0a4bc2.js');
|
12
|
-
const mapViewUtils = require('./mapViewUtils-
|
12
|
+
const mapViewUtils = require('./mapViewUtils-82018df6.js');
|
13
13
|
require('./esri-loader-ce6c3d3d.js');
|
14
14
|
require('./_commonjsHelpers-480c2e77.js');
|
15
15
|
require('./interfaces-7cd0a48a.js');
|
@@ -48,7 +48,7 @@ const CrowdsourceReporter = class {
|
|
48
48
|
this.theme = "light";
|
49
49
|
this.enableZoom = true;
|
50
50
|
this.zoomToScale = undefined;
|
51
|
-
this.layerExpressions =
|
51
|
+
this.layerExpressions = [];
|
52
52
|
this._mapInfo = undefined;
|
53
53
|
this._flowItems = [];
|
54
54
|
this._sidePanelCollapsed = false;
|
@@ -91,7 +91,7 @@ const CrowdsourceReporter = class {
|
|
91
91
|
this.setCurrentFeature(evt.detail.selectedFeature[0]);
|
92
92
|
void this.highlightOnMap(evt.detail.selectedFeature[0]);
|
93
93
|
this.selectedFeatureIndex = evt.detail.selectedFeatureIndex;
|
94
|
-
//update the feature details to reflect the like dislike values
|
94
|
+
//update the feature details to reflect the like dislike values
|
95
95
|
await this._featureDetails.refresh(evt.detail.selectedFeature[0]);
|
96
96
|
}
|
97
97
|
//--------------------------------------------------------------------------
|
@@ -8,7 +8,7 @@
|
|
8
8
|
const _commonjsHelpers = require('./_commonjsHelpers-480c2e77.js');
|
9
9
|
const index = require('./index-105cf2b9.js');
|
10
10
|
const locale = require('./locale-3d0a4bc2.js');
|
11
|
-
const mapViewUtils = require('./mapViewUtils-
|
11
|
+
const mapViewUtils = require('./mapViewUtils-82018df6.js');
|
12
12
|
require('./solution-resource-97186521.js');
|
13
13
|
require('./index-f64944ad.js');
|
14
14
|
const restHelpersGet = require('./restHelpersGet-2ed729ab.js');
|
@@ -1510,7 +1510,7 @@ function(t){var e=function(t){for(var e=t.length,r=new Uint8Array(e),n=0;n<e;n++
|
|
1510
1510
|
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
1511
1511
|
* ====================================================================
|
1512
1512
|
*/
|
1513
|
-
function(t){function e(){return (n.canvg?Promise.resolve(n.canvg):Promise.resolve().then(function () { return require('./index.es-
|
1513
|
+
function(t){function e(){return (n.canvg?Promise.resolve(n.canvg):Promise.resolve().then(function () { return require('./index.es-29fa176d.js'); })).catch((function(t){return Promise.reject(new Error("Could not load canvg: "+t))})).then((function(t){return t.default?t.default:t}))}E.API.addSvgAsImage=function(t,r,n,i,o,s,c,u){if(isNaN(r)||isNaN(n))throw a.error("jsPDF.addSvgAsImage: Invalid coordinates",arguments),new Error("Invalid coordinates passed to jsPDF.addSvgAsImage");if(isNaN(i)||isNaN(o))throw a.error("jsPDF.addSvgAsImage: Invalid measurements",arguments),new Error("Invalid measurements (width and/or height) passed to jsPDF.addSvgAsImage");var h=document.createElement("canvas");h.width=i,h.height=o;var l=h.getContext("2d");l.fillStyle="#fff",l.fillRect(0,0,h.width,h.height);var f={ignoreMouse:!0,ignoreAnimation:!0,ignoreDimensions:!0},d=this;return e().then((function(e){return e.fromString(l,t,f)}),(function(){return Promise.reject(new Error("Could not load canvg."))})).then((function(t){return t.render(f)})).then((function(){d.addImage(h.toDataURL("image/jpeg",1),r,n,i,o,c,u);}))};}(),E.API.putTotalPages=function(t){var e,r=0;parseInt(this.internal.getFont().id.substr(1),10)<15?(e=new RegExp(t,"g"),r=this.internal.getNumberOfPages()):(e=new RegExp(this.pdfEscape16(t,this.internal.getFont()),"g"),r=this.pdfEscape16(this.internal.getNumberOfPages()+"",this.internal.getFont()));for(var n=1;n<=this.internal.getNumberOfPages();n++)for(var i=0;i<this.internal.pages[n].length;i++)this.internal.pages[n][i]=this.internal.pages[n][i].replace(e,r);return this},E.API.viewerPreferences=function(e,r){var n;e=e||{},r=r||!1;var i,a,o,s={HideToolbar:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},HideMenubar:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},HideWindowUI:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},FitWindow:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},CenterWindow:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},DisplayDocTitle:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.4},NonFullScreenPageMode:{defaultValue:"UseNone",value:"UseNone",type:"name",explicitSet:!1,valueSet:["UseNone","UseOutlines","UseThumbs","UseOC"],pdfVersion:1.3},Direction:{defaultValue:"L2R",value:"L2R",type:"name",explicitSet:!1,valueSet:["L2R","R2L"],pdfVersion:1.3},ViewArea:{defaultValue:"CropBox",value:"CropBox",type:"name",explicitSet:!1,valueSet:["MediaBox","CropBox","TrimBox","BleedBox","ArtBox"],pdfVersion:1.4},ViewClip:{defaultValue:"CropBox",value:"CropBox",type:"name",explicitSet:!1,valueSet:["MediaBox","CropBox","TrimBox","BleedBox","ArtBox"],pdfVersion:1.4},PrintArea:{defaultValue:"CropBox",value:"CropBox",type:"name",explicitSet:!1,valueSet:["MediaBox","CropBox","TrimBox","BleedBox","ArtBox"],pdfVersion:1.4},PrintClip:{defaultValue:"CropBox",value:"CropBox",type:"name",explicitSet:!1,valueSet:["MediaBox","CropBox","TrimBox","BleedBox","ArtBox"],pdfVersion:1.4},PrintScaling:{defaultValue:"AppDefault",value:"AppDefault",type:"name",explicitSet:!1,valueSet:["AppDefault","None"],pdfVersion:1.6},Duplex:{defaultValue:"",value:"none",type:"name",explicitSet:!1,valueSet:["Simplex","DuplexFlipShortEdge","DuplexFlipLongEdge","none"],pdfVersion:1.7},PickTrayByPDFSize:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.7},PrintPageRange:{defaultValue:"",value:"",type:"array",explicitSet:!1,valueSet:null,pdfVersion:1.7},NumCopies:{defaultValue:1,value:1,type:"integer",explicitSet:!1,valueSet:null,pdfVersion:1.7}},c=Object.keys(s),u=[],h=0,l=0,f=0;function d(t,e){var r,n=!1;for(r=0;r<t.length;r+=1)t[r]===e&&(n=!0);return n}if(void 0===this.internal.viewerpreferences&&(this.internal.viewerpreferences={},this.internal.viewerpreferences.configuration=JSON.parse(JSON.stringify(s)),this.internal.viewerpreferences.isSubscribed=!1),n=this.internal.viewerpreferences.configuration,"reset"===e||!0===r){var p=c.length;for(f=0;f<p;f+=1)n[c[f]].value=n[c[f]].defaultValue,n[c[f]].explicitSet=!1;}if("object"===t(e))for(a in e)if(o=e[a],d(c,a)&&void 0!==o){if("boolean"===n[a].type&&"boolean"==typeof o)n[a].value=o;else if("name"===n[a].type&&d(n[a].valueSet,o))n[a].value=o;else if("integer"===n[a].type&&Number.isInteger(o))n[a].value=o;else if("array"===n[a].type){for(h=0;h<o.length;h+=1)if(i=!0,1===o[h].length&&"number"==typeof o[h][0])u.push(String(o[h]-1));else if(o[h].length>1){for(l=0;l<o[h].length;l+=1)"number"!=typeof o[h][l]&&(i=!1);!0===i&&u.push([o[h][0]-1,o[h][1]-1].join(" "));}n[a].value="["+u.join(" ")+"]";}else n[a].value=n[a].defaultValue;n[a].explicitSet=!0;}return !1===this.internal.viewerpreferences.isSubscribed&&(this.internal.events.subscribe("putCatalog",(function(){var t,e=[];for(t in n)!0===n[t].explicitSet&&("name"===n[t].type?e.push("/"+t+" /"+n[t].value):e.push("/"+t+" "+n[t].value));0!==e.length&&this.internal.write("/ViewerPreferences\n<<\n"+e.join("\n")+"\n>>");})),this.internal.viewerpreferences.isSubscribed=!0),this.internal.viewerpreferences.configuration=n,this},
|
1514
1514
|
/** ====================================================================
|
1515
1515
|
* @license
|
1516
1516
|
* jsPDF XMP metadata plugin
|
@@ -6,11 +6,11 @@
|
|
6
6
|
'use strict';
|
7
7
|
|
8
8
|
const _commonjsHelpers = require('./_commonjsHelpers-480c2e77.js');
|
9
|
-
const downloadUtils = require('./downloadUtils-
|
9
|
+
const downloadUtils = require('./downloadUtils-dd787ddf.js');
|
10
10
|
require('./index-105cf2b9.js');
|
11
11
|
require('./locale-3d0a4bc2.js');
|
12
12
|
require('./esri-loader-ce6c3d3d.js');
|
13
|
-
require('./mapViewUtils-
|
13
|
+
require('./mapViewUtils-82018df6.js');
|
14
14
|
require('./interfaces-7cd0a48a.js');
|
15
15
|
require('./solution-resource-97186521.js');
|
16
16
|
require('./index-f64944ad.js');
|