@mapcreator/api 2.8.0 → 2.9.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.
@@ -29,11 +29,11 @@
29
29
  * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30
30
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31
31
  *
32
- * hash:0cb8cc3af4023b1f8fa8, chunkhash:703527982af8e8fcf4e3, name:bundle.browser, version:v2.8.0
32
+ * hash:7c031e76ac6128d37d65, chunkhash:082fa3d4fcb93438af20, name:bundle.browser, version:v2.9.0
33
33
  */
34
34
  /*!
35
35
  * This bundle contains the following packages:
36
- * └─ @mapcreator/api (2.8.0) ── BSD 3-clause "New" or "Revised" License (http://www.opensource.org/licenses/BSD-3-Clause) ── package.json
36
+ * └─ @mapcreator/api (2.9.0) ── BSD 3-clause "New" or "Revised" License (http://www.opensource.org/licenses/BSD-3-Clause) ── package.json
37
37
  * ├─ @babel/runtime (7.10.2) ── MIT License (http://www.opensource.org/licenses/MIT) ── node_modules/@babel/runtime/package.json
38
38
  * │ └─ regenerator-runtime (0.13.5) ── MIT License (http://www.opensource.org/licenses/MIT) ── node_modules/@babel/runtime ~ regenerator-runtime/package.json
39
39
  * ├─ case (1.6.3) ── mit or gpl 3.0 or later ── node_modules/case/package.json
@@ -737,16 +737,58 @@ class CrudBase extends _ResourceBase__WEBPACK_IMPORTED_MODULE_1__["default"] {
737
737
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
738
738
 
739
739
  "use strict";
740
+ // ESM COMPAT FLAG
740
741
  __webpack_require__.r(__webpack_exports__);
741
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return RequestParameters; });
742
- /* harmony import */ var case__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7);
743
- /* harmony import */ var case__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(case__WEBPACK_IMPORTED_MODULE_0__);
744
- /* harmony import */ var events__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(52);
745
- /* harmony import */ var events__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(events__WEBPACK_IMPORTED_MODULE_1__);
746
- /* harmony import */ var _enums__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8);
747
- /* harmony import */ var _utils_hash__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29);
748
- /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1);
749
- /* harmony import */ var _utils_requests__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5);
742
+
743
+ // EXPORTS
744
+ __webpack_require__.d(__webpack_exports__, "Choropleth", function() { return /* reexport */ Choropleth_Choropleth; });
745
+ __webpack_require__.d(__webpack_exports__, "Color", function() { return /* reexport */ Color["default"]; });
746
+ __webpack_require__.d(__webpack_exports__, "Contract", function() { return /* reexport */ Contract["default"]; });
747
+ __webpack_require__.d(__webpack_exports__, "Dimension", function() { return /* reexport */ Dimension["default"]; });
748
+ __webpack_require__.d(__webpack_exports__, "DimensionSet", function() { return /* reexport */ DimensionSet["default"]; });
749
+ __webpack_require__.d(__webpack_exports__, "Domain", function() { return /* reexport */ Domain["default"]; });
750
+ __webpack_require__.d(__webpack_exports__, "Faq", function() { return /* reexport */ Faq_Faq; });
751
+ __webpack_require__.d(__webpack_exports__, "Feature", function() { return /* reexport */ Feature["default"]; });
752
+ __webpack_require__.d(__webpack_exports__, "Font", function() { return /* reexport */ Font["default"]; });
753
+ __webpack_require__.d(__webpack_exports__, "FontFamily", function() { return /* reexport */ FontFamily["default"]; });
754
+ __webpack_require__.d(__webpack_exports__, "Highlight", function() { return /* reexport */ Highlight_Highlight; });
755
+ __webpack_require__.d(__webpack_exports__, "InsetMap", function() { return /* reexport */ InsetMap_InsetMap; });
756
+ __webpack_require__.d(__webpack_exports__, "Job", function() { return /* reexport */ Job["default"]; });
757
+ __webpack_require__.d(__webpack_exports__, "JobResult", function() { return /* reexport */ JobResult["default"]; });
758
+ __webpack_require__.d(__webpack_exports__, "JobRevision", function() { return /* reexport */ JobRevision["default"]; });
759
+ __webpack_require__.d(__webpack_exports__, "JobShare", function() { return /* reexport */ JobShare["default"]; });
760
+ __webpack_require__.d(__webpack_exports__, "JobType", function() { return /* reexport */ JobType["default"]; });
761
+ __webpack_require__.d(__webpack_exports__, "Language", function() { return /* reexport */ Language["default"]; });
762
+ __webpack_require__.d(__webpack_exports__, "Layer", function() { return /* reexport */ Layer["default"]; });
763
+ __webpack_require__.d(__webpack_exports__, "LayerFaq", function() { return /* reexport */ LayerFaq_LayerFaq; });
764
+ __webpack_require__.d(__webpack_exports__, "Mapstyle", function() { return /* reexport */ Mapstyle["default"]; });
765
+ __webpack_require__.d(__webpack_exports__, "MapstyleSet", function() { return /* reexport */ MapstyleSet["default"]; });
766
+ __webpack_require__.d(__webpack_exports__, "Message", function() { return /* reexport */ Message["default"]; });
767
+ __webpack_require__.d(__webpack_exports__, "Notification", function() { return /* reexport */ Notification["default"]; });
768
+ __webpack_require__.d(__webpack_exports__, "Organisation", function() { return /* reexport */ Organisation["default"]; });
769
+ __webpack_require__.d(__webpack_exports__, "Permission", function() { return /* reexport */ Permission["default"]; });
770
+ __webpack_require__.d(__webpack_exports__, "ProductTour", function() { return /* reexport */ ProductTour_ProductTour; });
771
+ __webpack_require__.d(__webpack_exports__, "ProductTourStep", function() { return /* reexport */ ProductTourStep_ProductTourStep; });
772
+ __webpack_require__.d(__webpack_exports__, "Role", function() { return /* reexport */ Role["default"]; });
773
+ __webpack_require__.d(__webpack_exports__, "Svg", function() { return /* reexport */ Svg["default"]; });
774
+ __webpack_require__.d(__webpack_exports__, "SvgSet", function() { return /* reexport */ SvgSet["default"]; });
775
+ __webpack_require__.d(__webpack_exports__, "Tag", function() { return /* reexport */ Tag["default"]; });
776
+ __webpack_require__.d(__webpack_exports__, "TagType", function() { return /* reexport */ TagType_TagType; });
777
+ __webpack_require__.d(__webpack_exports__, "User", function() { return /* reexport */ User["default"]; });
778
+ __webpack_require__.d(__webpack_exports__, "VectorHighlight", function() { return /* reexport */ VectorHighlight_VectorHighlight; });
779
+ __webpack_require__.d(__webpack_exports__, "VectorChoropleth", function() { return /* reexport */ VectorChoropleth_VectorChoropleth; });
780
+ __webpack_require__.d(__webpack_exports__, "base", function() { return /* binding */ base; });
781
+
782
+ // EXTERNAL MODULE: ./src/resources/base/DownloadedResource.js + 1 modules
783
+ var DownloadedResource = __webpack_require__(23);
784
+
785
+ // EXTERNAL MODULE: ./src/resources/base/ResourceBase.js
786
+ var ResourceBase = __webpack_require__(6);
787
+
788
+ // EXTERNAL MODULE: ./src/utils/helpers.js
789
+ var helpers = __webpack_require__(0);
790
+
791
+ // CONCATENATED MODULE: ./src/resources/Choropleth.js
750
792
  /*
751
793
  * BSD 3-Clause License
752
794
  *
@@ -781,750 +823,349 @@ __webpack_require__.r(__webpack_exports__);
781
823
 
782
824
 
783
825
 
784
-
785
-
786
-
787
826
  /**
788
- * Used for keeping track of the request parameters
789
- *
790
- * @fires RequestParameters#change
791
- * @fires RequestParameters#change:page
792
- * @fires RequestParameters#change:perPage
793
- * @fires RequestParameters#change:search
794
- * @fires RequestParameters#change:sort
795
- * @fires RequestParameters#change:deleted
796
- * @fires RequestParameters#change:extra
827
+ * Choropleth resource
797
828
  */
798
829
 
799
- class RequestParameters extends events__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"] {
800
- /**
801
- * RequestParameters constructor
802
- * @param {Object} object - properties
803
- */
804
- constructor(object = {}) {
805
- super(); // Apply defaults
806
-
807
- RequestParameters.keys().forEach(x => this._resolve(x)); // Apply properties
808
-
809
- this.apply(object);
810
- } // region instance
811
- // region instance getters
812
-
813
- /**
814
- * Get page number
815
- * @returns {Number} - Page number
816
- * @throws {TypeError}
817
- */
818
-
819
-
820
- get page() {
821
- return this._resolve('page');
822
- }
823
- /**
824
- * Get rows per page
825
- * @returns {Number} - Per page
826
- * @throws {TypeError}
827
- */
828
-
829
-
830
- get perPage() {
831
- return this._resolve('perPage');
832
- }
833
- /**
834
- * Get pagination offset
835
- * @returns {Number} - Offset
836
- * @throws {TypeError}
837
- */
838
-
839
-
840
- get offset() {
841
- return this._resolve('offset');
842
- }
843
- /**
844
- * Search query
845
- * @returns {Object<String, String|Array<String>>} - Query
846
- * @throws {TypeError}
847
- */
848
-
849
-
850
- get search() {
851
- return this._resolve('search');
830
+ class Choropleth_Choropleth extends ResourceBase["default"] {
831
+ static get resourceName() {
832
+ return 'choropleths';
852
833
  }
853
834
  /**
854
- * Get sort options
855
- * @returns {Array<String>} - Per page
856
- * @throws {TypeError}
835
+ * Get the inset map json
836
+ * @returns {CancelablePromise<Object>} - Choropleth json
837
+ * @throws {ApiError} - If the api returns errors
857
838
  */
858
839
 
859
840
 
860
- get sort() {
861
- return this._resolve('sort');
841
+ getJson() {
842
+ return Object(helpers["makeCancelable"])(signal => this.api.ky.get(`${this.url}/json`, {
843
+ signal
844
+ }).json());
862
845
  }
863
846
  /**
864
- * If deleted items should be shown
865
- * @returns {String} - Deleted items filter state
866
- * @see {@link DeletedState}
847
+ * Download the choropleth preview
848
+ * @returns {CancelablePromise<DownloadedResource>} - Choropleth preview
849
+ * @throws {ApiError} - If the api returns errors
867
850
  */
868
851
 
869
852
 
870
- get deleted() {
871
- return this._resolve('deleted');
853
+ downloadPreview() {
854
+ return Object(helpers["makeCancelable"])(async signal => {
855
+ const response = await this.api.ky.get(`${this.url}/preview`, {
856
+ signal
857
+ });
858
+ return DownloadedResource["default"].fromResponse(response);
859
+ });
872
860
  }
873
- /**
874
- * Extra parameters
875
- * @returns {Object} - Extra parameters
876
- */
877
861
 
862
+ }
863
+ // EXTERNAL MODULE: ./src/resources/Color.js
864
+ var Color = __webpack_require__(36);
878
865
 
879
- get extra() {
880
- return this._resolve('extra');
881
- } // endregion instance getters
882
- // region instance setters
866
+ // EXTERNAL MODULE: ./src/resources/Contract.js
867
+ var Contract = __webpack_require__(61);
883
868
 
884
- /**
885
- * Page number
886
- * @param {Number} value - Page number
887
- */
869
+ // EXTERNAL MODULE: ./src/resources/Dimension.js
870
+ var Dimension = __webpack_require__(38);
888
871
 
872
+ // EXTERNAL MODULE: ./src/resources/DimensionSet.js
873
+ var DimensionSet = __webpack_require__(37);
889
874
 
890
- set page(value) {
891
- this._update('page', value);
892
- }
893
- /**
894
- * Rows per page
895
- * @param {Number} value - Per page
896
- */
875
+ // EXTERNAL MODULE: ./src/resources/Domain.js
876
+ var Domain = __webpack_require__(62);
897
877
 
878
+ // EXTERNAL MODULE: ./src/resources/base/CrudBase.js
879
+ var CrudBase = __webpack_require__(2);
898
880
 
899
- set perPage(value) {
900
- this._update('perPage', value);
901
- }
902
- /**
903
- * Pagination offset
904
- * @param {Number} value - Offset
905
- */
881
+ // CONCATENATED MODULE: ./src/resources/Faq.js
882
+ /*
883
+ * BSD 3-Clause License
884
+ *
885
+ * Copyright (c) 2020, Mapcreator
886
+ * All rights reserved.
887
+ *
888
+ * Redistribution and use in source and binary forms, with or without
889
+ * modification, are permitted provided that the following conditions are met:
890
+ *
891
+ * Redistributions of source code must retain the above copyright notice, this
892
+ * list of conditions and the following disclaimer.
893
+ *
894
+ * Redistributions in binary form must reproduce the above copyright notice,
895
+ * this list of conditions and the following disclaimer in the documentation
896
+ * and/or other materials provided with the distribution.
897
+ *
898
+ * Neither the name of the copyright holder nor the names of its
899
+ * contributors may be used to endorse or promote products derived from
900
+ * this software without specific prior written permission.
901
+ *
902
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
903
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
904
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
905
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
906
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
907
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
908
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
909
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
910
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
911
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
912
+ */
906
913
 
914
+ /**
915
+ * Faq resource
916
+ */
907
917
 
908
- set offset(value) {
909
- this._update('offset', value);
918
+ class Faq_Faq extends CrudBase["default"] {
919
+ static get resourceName() {
920
+ return 'faqs';
910
921
  }
911
- /**
912
- * Search query
913
- * @param {Object<String, String|Array<String>>} value - Search query
914
- */
915
922
 
923
+ }
924
+ // EXTERNAL MODULE: ./src/resources/Feature.js
925
+ var Feature = __webpack_require__(39);
916
926
 
917
- set search(value) {
918
- this._update('search', value);
919
- }
920
- /**
921
- * Sort query
922
- * @param {Array<String>} value - Sort query
923
- */
927
+ // EXTERNAL MODULE: ./src/resources/Font.js
928
+ var Font = __webpack_require__(41);
924
929
 
930
+ // EXTERNAL MODULE: ./src/resources/FontFamily.js
931
+ var FontFamily = __webpack_require__(40);
925
932
 
926
- set sort(value) {
927
- this._update('sort', value);
928
- }
929
- /**
930
- * Deleted items filter state
931
- * @param {String} value - Deleted items filter state
932
- * @see {@link DeletedState}
933
- */
934
-
933
+ // CONCATENATED MODULE: ./src/resources/Highlight.js
934
+ /*
935
+ * BSD 3-Clause License
936
+ *
937
+ * Copyright (c) 2020, Mapcreator
938
+ * All rights reserved.
939
+ *
940
+ * Redistribution and use in source and binary forms, with or without
941
+ * modification, are permitted provided that the following conditions are met:
942
+ *
943
+ * Redistributions of source code must retain the above copyright notice, this
944
+ * list of conditions and the following disclaimer.
945
+ *
946
+ * Redistributions in binary form must reproduce the above copyright notice,
947
+ * this list of conditions and the following disclaimer in the documentation
948
+ * and/or other materials provided with the distribution.
949
+ *
950
+ * Neither the name of the copyright holder nor the names of its
951
+ * contributors may be used to endorse or promote products derived from
952
+ * this software without specific prior written permission.
953
+ *
954
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
955
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
956
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
957
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
958
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
959
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
960
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
961
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
962
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
963
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
964
+ */
935
965
 
936
- set deleted(value) {
937
- this._update('deleted', value);
966
+ class Highlight_Highlight extends ResourceBase["default"] {
967
+ static get resourceName() {
968
+ return 'highlights';
938
969
  }
939
- /**
940
- * Extra request parameters
941
- * @param {Object} value - Extra request parameters
942
- */
943
-
944
-
945
- set extra(value) {
946
- this._update('extra', value);
947
- } // endregion instance setters
948
- // endregion instance
949
- // region static
950
- // region getters
951
-
952
- /**
953
- * Default page number
954
- * @returns {Number} - Page number
955
- */
956
-
957
970
 
958
- static get page() {
959
- return RequestParameters._page || 1;
960
- }
961
- /**
962
- * Default per page
963
- * @returns {Number} - Per page
964
- */
971
+ }
972
+ // CONCATENATED MODULE: ./src/resources/InsetMap.js
973
+ /*
974
+ * BSD 3-Clause License
975
+ *
976
+ * Copyright (c) 2020, Mapcreator
977
+ * All rights reserved.
978
+ *
979
+ * Redistribution and use in source and binary forms, with or without
980
+ * modification, are permitted provided that the following conditions are met:
981
+ *
982
+ * Redistributions of source code must retain the above copyright notice, this
983
+ * list of conditions and the following disclaimer.
984
+ *
985
+ * Redistributions in binary form must reproduce the above copyright notice,
986
+ * this list of conditions and the following disclaimer in the documentation
987
+ * and/or other materials provided with the distribution.
988
+ *
989
+ * Neither the name of the copyright holder nor the names of its
990
+ * contributors may be used to endorse or promote products derived from
991
+ * this software without specific prior written permission.
992
+ *
993
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
994
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
995
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
996
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
997
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
998
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
999
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
1000
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
1001
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
1002
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1003
+ */
965
1004
 
966
1005
 
967
- static get perPage() {
968
- return RequestParameters._perPage || Number("12") || 12;
1006
+ class InsetMap_InsetMap extends ResourceBase["default"] {
1007
+ static get resourceName() {
1008
+ return 'inset-maps';
969
1009
  }
970
1010
  /**
971
- * Default pagination offset
972
- * @returns {Number} - Offset
1011
+ * Get the inset map json
1012
+ * @returns {CancelablePromise<Object>} - Inset map json
1013
+ * @throws {ApiError} - If the api returns errors
973
1014
  */
974
1015
 
975
1016
 
976
- static get offset() {
977
- return RequestParameters._offset || 0;
1017
+ getJson() {
1018
+ return Object(helpers["makeCancelable"])(signal => this.api.ky.get(`${this.url}/json`, {
1019
+ signal
1020
+ }).json());
978
1021
  }
979
- /**
980
- * Gets the maximum allowed value for perPage
981
- * Some users will have a special permission that allows them to fetch more than 50 resources at once
982
- * @returns {Number} - Maximum amount of resources per page
983
- */
984
-
985
1022
 
986
- static get maxPerPage() {
987
- return RequestParameters._maxPerPage || 50;
988
- }
989
- /**
990
- * Default search query
991
- * @returns {Object<String, String|Array<String>>} - Search query
992
- */
1023
+ }
1024
+ // EXTERNAL MODULE: ./src/resources/Job.js
1025
+ var Job = __webpack_require__(42);
993
1026
 
1027
+ // EXTERNAL MODULE: ./src/resources/JobResult.js
1028
+ var JobResult = __webpack_require__(33);
994
1029
 
995
- static get search() {
996
- return RequestParameters._search || {};
997
- }
998
- /**
999
- * Default sort query
1000
- * @returns {Array<String>} - Sort query
1001
- */
1030
+ // EXTERNAL MODULE: ./src/resources/JobRevision.js
1031
+ var JobRevision = __webpack_require__(63);
1002
1032
 
1033
+ // EXTERNAL MODULE: ./src/resources/JobShare.js
1034
+ var JobShare = __webpack_require__(21);
1003
1035
 
1004
- static get sort() {
1005
- return RequestParameters._sort || [];
1006
- }
1007
- /**
1008
- * Default deleted items filter state
1009
- * @returns {String|undefined} - Deleted items filter state
1010
- */
1036
+ // EXTERNAL MODULE: ./src/resources/JobType.js
1037
+ var JobType = __webpack_require__(43);
1011
1038
 
1039
+ // EXTERNAL MODULE: ./src/resources/Language.js
1040
+ var Language = __webpack_require__(64);
1012
1041
 
1013
- static get deleted() {
1014
- return RequestParameters._deleted || void 0;
1015
- }
1016
- /**
1017
- * Default extra request parameters
1018
- * @returns {Object} - Extra request parameters
1019
- */
1042
+ // EXTERNAL MODULE: ./src/resources/Layer.js
1043
+ var Layer = __webpack_require__(22);
1020
1044
 
1045
+ // EXTERNAL MODULE: ./src/resources/base/CrudSetItemBase.js
1046
+ var CrudSetItemBase = __webpack_require__(14);
1021
1047
 
1022
- static get extra() {
1023
- return RequestParameters._extra || {};
1024
- } // endregion getters
1025
- // region setters
1048
+ // CONCATENATED MODULE: ./src/resources/LayerFaq.js
1049
+ /*
1050
+ * BSD 3-Clause License
1051
+ *
1052
+ * Copyright (c) 2022, Mapcreator
1053
+ * All rights reserved.
1054
+ *
1055
+ * Redistribution and use in source and binary forms, with or without
1056
+ * modification, are permitted provided that the following conditions are met:
1057
+ *
1058
+ * Redistributions of source code must retain the above copyright notice, this
1059
+ * list of conditions and the following disclaimer.
1060
+ *
1061
+ * Redistributions in binary form must reproduce the above copyright notice,
1062
+ * this list of conditions and the following disclaimer in the documentation
1063
+ * and/or other materials provided with the distribution.
1064
+ *
1065
+ * Neither the name of the copyright holder nor the names of its
1066
+ * contributors may be used to endorse or promote products derived from
1067
+ * this software without specific prior written permission.
1068
+ *
1069
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
1070
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
1071
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
1072
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
1073
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
1074
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
1075
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
1076
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
1077
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
1078
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1079
+ */
1026
1080
 
1027
- /**
1028
- * Default page number
1029
- * @param {Number} value - Page number
1030
- */
1081
+ /**
1082
+ * LayerFaq
1083
+ * @extends CrudSetItemBase
1084
+ */
1031
1085
 
1086
+ class LayerFaq_LayerFaq extends CrudSetItemBase["default"] {
1087
+ static get resourceName() {
1088
+ return 'layer-faqs';
1089
+ }
1032
1090
 
1033
- static set page(value) {
1034
- RequestParameters._page = RequestParameters._validatePage(value);
1091
+ static get parentKey() {
1092
+ return 'layer_group_id';
1035
1093
  }
1036
- /**
1037
- * Default per page
1038
- * @param {Number} value - Per page
1039
- */
1040
1094
 
1095
+ }
1096
+ // EXTERNAL MODULE: ./src/resources/Mapstyle.js
1097
+ var Mapstyle = __webpack_require__(44);
1041
1098
 
1042
- static set perPage(value) {
1043
- RequestParameters._perPage = RequestParameters._validatePerPage(value);
1044
- }
1045
- /**
1046
- * Default pagination offset
1047
- * @param {Number} value - Offset
1048
- */
1099
+ // EXTERNAL MODULE: ./src/resources/MapstyleSet.js + 1 modules
1100
+ var MapstyleSet = __webpack_require__(50);
1049
1101
 
1102
+ // EXTERNAL MODULE: ./src/resources/Message.js + 1 modules
1103
+ var Message = __webpack_require__(57);
1050
1104
 
1051
- static set offset(value) {
1052
- RequestParameters._offset = RequestParameters._validateOffset(value);
1053
- }
1054
- /**
1055
- * Sets the maximum allowed value for perPage
1056
- * Some users will have a special permission that allows them to fetch more than 50 resources at once
1057
- * @param {Number} value - Maximum amount of resources per page
1058
- */
1105
+ // EXTERNAL MODULE: ./src/resources/Notification.js
1106
+ var Notification = __webpack_require__(65);
1059
1107
 
1108
+ // EXTERNAL MODULE: ./src/resources/Organisation.js
1109
+ var Organisation = __webpack_require__(54);
1060
1110
 
1061
- static set maxPerPage(value) {
1062
- RequestParameters._maxPerPage = RequestParameters._validateMaxPerPage(value);
1063
- }
1064
- /**
1065
- * Default search query
1066
- * @param {Object<String, String|Array<String>>} value - Search query
1067
- */
1111
+ // EXTERNAL MODULE: ./src/resources/Permission.js
1112
+ var Permission = __webpack_require__(49);
1068
1113
 
1114
+ // EXTERNAL MODULE: ./src/utils/reflection.js
1115
+ var reflection = __webpack_require__(1);
1069
1116
 
1070
- static set search(value) {
1071
- RequestParameters._search = RequestParameters._validateSearch(value);
1072
- }
1073
- /**
1074
- * Default sort query
1075
- * @param {Array<String>} value - Sort query
1076
- */
1077
-
1078
-
1079
- static set sort(value) {
1080
- RequestParameters._sort = RequestParameters._validateSort(value);
1081
- }
1082
- /**
1083
- * Default deleted items filter state
1084
- * @param {String} value - Deleted items filter state
1085
- */
1086
-
1087
-
1088
- static set deleted(value) {
1089
- RequestParameters._deleted = RequestParameters._validateDeleted(value);
1090
- }
1091
- /**
1092
- * Default extra request parameters
1093
- * @param {Object} value - Extra request parameters
1094
- */
1095
-
1096
-
1097
- static set extra(value) {
1098
- RequestParameters._extra = RequestParameters._validateExtra(value);
1099
- } // endregion setters
1100
- // endregion static
1101
- // region validators
1102
-
1103
- /**
1104
- * Validators should work the same as laravel's ::validate method. This means
1105
- * this means that they will throw a TypeError or return a normalized result.
1106
- */
1107
-
1108
-
1109
- static _validatePage(value) {
1110
- if (typeof value !== 'number') {
1111
- throw new TypeError(`Expected page to be of type 'number' instead got '${typeof value}'`);
1112
- }
1113
-
1114
- if (value < 0) {
1115
- throw new TypeError('Page must be a positive number');
1116
- }
1117
-
1118
- if (Number.isNaN(value) || !Number.isFinite(value)) {
1119
- throw new TypeError('Page must be a real number');
1120
- }
1121
-
1122
- if (Math.round(value) !== value) {
1123
- throw new TypeError('Page must be a natural number');
1124
- }
1125
-
1126
- return Math.round(value);
1127
- }
1128
-
1129
- static _validatePerPage(value) {
1130
- if (typeof value !== 'number') {
1131
- throw new TypeError(`Expected per page to be of type 'Number' instead got '${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}'`);
1132
- }
1133
-
1134
- if (value <= 0) {
1135
- throw new TypeError('Per page must be greater than zero');
1136
- }
1137
-
1138
- if (Number.isNaN(value) || !Number.isFinite(value)) {
1139
- throw new TypeError('Per page must be a real number');
1140
- }
1141
-
1142
- if (Math.round(value) !== value) {
1143
- throw new TypeError('Per page must be a natural number');
1144
- } // Upper limit is 50 by default
1145
-
1146
-
1147
- value = Math.min(RequestParameters.maxPerPage, value);
1148
- return value;
1149
- }
1150
-
1151
- static _validateOffset(value) {
1152
- if (typeof value !== 'number') {
1153
- throw new TypeError(`Expected offset to be of type 'Number' instead got '${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}'`);
1154
- }
1155
-
1156
- if (value < 0) {
1157
- throw new TypeError('Offset must be a positive number');
1158
- }
1159
-
1160
- if (Number.isNaN(value) || !Number.isFinite(value)) {
1161
- throw new TypeError('Offset must be a real number');
1162
- }
1163
-
1164
- if (Math.round(value) !== value) {
1165
- throw new TypeError('Offset must be a natural number');
1166
- }
1167
-
1168
- return value;
1169
- }
1170
-
1171
- static _validateMaxPerPage(value) {
1172
- if (typeof value !== 'number') {
1173
- throw new TypeError(`Expected page to be of type 'Number' instead got '${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}'`);
1174
- }
1175
-
1176
- if (value < 1) {
1177
- throw new TypeError('Value must be greater or equal to 1');
1178
- }
1179
-
1180
- return value;
1181
- }
1182
-
1183
- static _validateSearch(value) {
1184
- if (typeof value !== 'object' || Array.isArray(value)) {
1185
- throw new TypeError(`Expected value to be of type "Object" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}"`);
1186
- } // Normalization macro
1187
-
1188
-
1189
- const normalize = x => typeof x === 'number' ? x.toString() : x;
1190
-
1191
- for (let key of Object.keys(value)) {
1192
- key = normalize(key);
1193
- value[key] = normalize(value[key]);
1194
-
1195
- if (typeof key !== 'string') {
1196
- throw new TypeError(`Expected key to be of type "String" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(key)}"`);
1197
- }
1198
-
1199
- if (Array.isArray(value[key])) {
1200
- if (value[key].length > 0) {
1201
- for (const query of value[key]) {
1202
- if (!['string', 'number', 'boolean'].includes(typeof query) && query !== null) {
1203
- throw new TypeError(`Expected query for "${key}" to be of type "String", "Boolean", "Number" or "null" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(query)}"`);
1204
- }
1205
- }
1206
- } else {
1207
- // Drop empty nodes
1208
- delete value[key];
1209
- }
1210
- } else if (value[key] === null) {
1211
- delete value[key];
1212
- } else if (!['string', 'number', 'boolean'].includes(typeof value[key]) && value[key] !== null) {
1213
- throw new TypeError(`Expected query value to be of type "String", "Boolean", "Number", "Array" or "null" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value[key])}"`);
1214
- }
1215
- }
1216
-
1217
- return value;
1218
- }
1219
-
1220
- static _validateSort(value) {
1221
- if (typeof value === 'string') {
1222
- return this._validateSort(value.split(','));
1223
- }
1224
-
1225
- if (!(value instanceof Array)) {
1226
- throw new TypeError(`Expected sort value to be of type "Array" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}"`);
1227
- } // Array keys type checking
1228
-
1229
-
1230
- value.filter(x => typeof x !== 'string').forEach(x => {
1231
- throw new TypeError(`Expected sort array values to be of type "String" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(x)}"`);
1232
- }); // Don't do regex matching because it's something
1233
- // we can just let the server do for us.
1234
-
1235
- return value;
1236
- }
1237
-
1238
- static _validateDeleted(value) {
1239
- if (typeof value === 'undefined') {
1240
- return value;
1241
- }
1242
-
1243
- if (typeof value !== 'string') {
1244
- throw new TypeError(`Expected deleted to be of type "string" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}". See: DeletedState`);
1245
- }
1246
-
1247
- value = value.toLowerCase();
1248
- const possible = _enums__WEBPACK_IMPORTED_MODULE_2__["DeletedState"].values();
1249
-
1250
- if (!possible.includes(value)) {
1251
- throw new TypeError(`Expected deleted to be one of ${possible.join(', ')}, got ${value}`);
1252
- }
1253
-
1254
- return value;
1255
- }
1256
-
1257
- static _validateExtra(value) {
1258
- if (typeof value !== 'object') {
1259
- throw new TypeError(`Expected extra to be of type 'object', got '${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}'`);
1260
- }
1261
-
1262
- return value;
1263
- } // endregion validators
1264
-
1265
-
1266
- _resolve(name) {
1267
- const _name = `_${name}`;
1268
-
1269
- if (!this[_name]) {
1270
- // Confuse esdoc
1271
- (this || {})[_name] = RequestParameters[name];
1272
- }
1273
-
1274
- return this[_name];
1275
- }
1276
-
1277
- _update(name, value, preventEvent = false) {
1278
- const _name = `_${name}`;
1279
- value = RequestParameters[`_validate${Object(case__WEBPACK_IMPORTED_MODULE_0__["pascal"])(name)}`](value);
1280
- (this || {})[_name] = value; // Weird syntax confuses esdoc
1281
-
1282
- if (!preventEvent) {
1283
- /**
1284
- * Change event.
1285
- *
1286
- * @event RequestParameters#change
1287
- * @type {Array<object>}
1288
- * @property {string} name - Parameter name
1289
- * @property {*} value - New value
1290
- */
1291
- this.emit('change', [{
1292
- name,
1293
- value
1294
- }]);
1295
- this.emit(`change:${name}`, value);
1296
- }
1297
-
1298
- return value;
1299
- } // region utils
1300
-
1301
- /**
1302
- * Urlencode parameters
1303
- * @returns {string} - HTTP query
1304
- */
1305
-
1306
-
1307
- encode() {
1308
- return Object(_utils_requests__WEBPACK_IMPORTED_MODULE_5__["encodeQueryString"])(this.toParameterObject());
1309
- }
1310
- /**
1311
- * Convert to object
1312
- * @returns {Object} - Object
1313
- */
1314
-
1315
-
1316
- toObject() {
1317
- return RequestParameters.keys().reduce((obj, key) => {
1318
- obj[Object(case__WEBPACK_IMPORTED_MODULE_0__["snake"])(key)] = this._resolve(key);
1319
- return obj;
1320
- }, {});
1321
- }
1322
- /**
1323
- * Convert to object
1324
- * @returns {Object} - Object
1325
- */
1326
-
1327
-
1328
- toParameterObject() {
1329
- const data = {};
1330
- RequestParameters.keys().forEach(key => {
1331
- // Skip extra key
1332
- if (key === 'extra') {
1333
- return;
1334
- }
1335
-
1336
- data[Object(case__WEBPACK_IMPORTED_MODULE_0__["snake"])(key)] = this._resolve(key);
1337
- }); // Fix column names for sort
1338
-
1339
- data.sort = data.sort.map(case__WEBPACK_IMPORTED_MODULE_0__["snake"]).map(x => x.replace(/^_/, '-')).join(',');
1340
-
1341
- if (data.offset === 0) {
1342
- delete data.offset;
1343
- } // Fix column names for search
1344
-
1345
-
1346
- for (const key of Object.keys(data.search)) {
1347
- const snakeKey = key.split(',').map(case__WEBPACK_IMPORTED_MODULE_0__["snake"]).join(',');
1348
-
1349
- if (key !== snakeKey) {
1350
- data.search[snakeKey] = data.search[key];
1351
- delete data.search[key];
1352
- }
1353
- } // Cast search values
1354
-
1355
-
1356
- for (const key of Object.keys(data.search)) {
1357
- if (typeof data.search[key] === 'boolean') {
1358
- data.search[key] = Number(data.search[key]);
1359
- }
1360
-
1361
- if (data.search[key] === null) {
1362
- data.search[key] = '';
1363
- }
1364
- } // Overwrite using extra properties
1365
-
1366
-
1367
- const extra = this._resolve('extra');
1368
-
1369
- for (const key of Object.keys(extra)) {
1370
- data[key] = extra[key];
1371
- }
1372
-
1373
- for (const key of Object.keys(data)) {
1374
- if (typeof data[key] === 'undefined') {
1375
- delete data[key];
1376
- }
1377
- }
1378
-
1379
- return data;
1380
- }
1381
- /**
1382
- * Copy object
1383
- * @returns {RequestParameters} - Copy
1384
- */
1385
-
1386
-
1387
- copy() {
1388
- return new RequestParameters(this.toObject());
1389
- }
1390
- /**
1391
- * Different parameters
1392
- * @returns {Array<String>} - keys
1393
- */
1394
-
1395
-
1396
- static keys() {
1397
- // enumeration is disabled for properties
1398
- return ['page', 'perPage', 'offset', 'search', 'sort', 'deleted', 'extra'];
1399
- }
1400
- /**
1401
- * Generates a cache token
1402
- * @returns {string} - Cache token
1403
- */
1404
-
1405
-
1406
- token() {
1407
- const data = this.toObject();
1408
- delete data.page;
1409
- delete data['per_page'];
1410
- return Object(_utils_hash__WEBPACK_IMPORTED_MODULE_3__["hashObject"])(data);
1411
- }
1412
- /**
1413
- * Resets all parameters back to default
1414
- */
1415
-
1416
-
1417
- static resetDefaults() {
1418
- for (const key of RequestParameters.keys()) {
1419
- delete RequestParameters[`_${key}`];
1420
- }
1421
- }
1422
- /**
1423
- * Apply parameters from object
1424
- * @param {object|RequestParameters} params - parameters
1425
- * @returns {Object[]} - Array containing the updated values
1426
- * @example
1427
- * const params = new RequestParameters({perPage: 12});
1428
- *
1429
- * params.perPage === 12;
1430
- *
1431
- * params.apply({perPage: 50});
1432
- *
1433
- * params.perPage === 50;
1434
- */
1435
-
1436
-
1437
- apply(params) {
1438
- if (params instanceof RequestParameters) {
1439
- params = params.toObject();
1440
- }
1441
-
1442
- const out = [];
1443
-
1444
- for (const key of Object.keys(params)) {
1445
- const Key = Object(case__WEBPACK_IMPORTED_MODULE_0__["camel"])(key);
1446
-
1447
- if (key[0] === '_' || !RequestParameters.keys().includes(Key)) {
1448
- continue;
1449
- }
1450
-
1451
- out.push({
1452
- name: Key,
1453
- value: this._update(Key, params[key], true)
1454
- });
1455
- }
1456
-
1457
- this.emit('change', out);
1458
-
1459
- for (const {
1460
- name,
1461
- value
1462
- } of out) {
1463
- this.emit(`change:${name}`, value);
1464
- }
1465
-
1466
- return out;
1467
- } // endregion utils
1468
-
1469
-
1470
- }
1471
-
1472
- /***/ }),
1473
- /* 4 */
1474
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
1475
-
1476
- "use strict";
1477
- // ESM COMPAT FLAG
1478
- __webpack_require__.r(__webpack_exports__);
1117
+ // EXTERNAL MODULE: ./src/resources/base/CrudSetBase.js
1118
+ var CrudSetBase = __webpack_require__(17);
1479
1119
 
1480
- // EXPORTS
1481
- __webpack_require__.d(__webpack_exports__, "Choropleth", function() { return /* reexport */ Choropleth_Choropleth; });
1482
- __webpack_require__.d(__webpack_exports__, "Color", function() { return /* reexport */ Color["default"]; });
1483
- __webpack_require__.d(__webpack_exports__, "Contract", function() { return /* reexport */ Contract["default"]; });
1484
- __webpack_require__.d(__webpack_exports__, "Dimension", function() { return /* reexport */ Dimension["default"]; });
1485
- __webpack_require__.d(__webpack_exports__, "DimensionSet", function() { return /* reexport */ DimensionSet["default"]; });
1486
- __webpack_require__.d(__webpack_exports__, "Domain", function() { return /* reexport */ Domain["default"]; });
1487
- __webpack_require__.d(__webpack_exports__, "Faq", function() { return /* reexport */ Faq_Faq; });
1488
- __webpack_require__.d(__webpack_exports__, "Feature", function() { return /* reexport */ Feature["default"]; });
1489
- __webpack_require__.d(__webpack_exports__, "Font", function() { return /* reexport */ Font["default"]; });
1490
- __webpack_require__.d(__webpack_exports__, "FontFamily", function() { return /* reexport */ FontFamily["default"]; });
1491
- __webpack_require__.d(__webpack_exports__, "Highlight", function() { return /* reexport */ Highlight_Highlight; });
1492
- __webpack_require__.d(__webpack_exports__, "InsetMap", function() { return /* reexport */ InsetMap_InsetMap; });
1493
- __webpack_require__.d(__webpack_exports__, "Job", function() { return /* reexport */ Job["default"]; });
1494
- __webpack_require__.d(__webpack_exports__, "JobResult", function() { return /* reexport */ JobResult["default"]; });
1495
- __webpack_require__.d(__webpack_exports__, "JobRevision", function() { return /* reexport */ JobRevision["default"]; });
1496
- __webpack_require__.d(__webpack_exports__, "JobShare", function() { return /* reexport */ JobShare["default"]; });
1497
- __webpack_require__.d(__webpack_exports__, "JobType", function() { return /* reexport */ JobType["default"]; });
1498
- __webpack_require__.d(__webpack_exports__, "Language", function() { return /* reexport */ Language["default"]; });
1499
- __webpack_require__.d(__webpack_exports__, "Layer", function() { return /* reexport */ Layer["default"]; });
1500
- __webpack_require__.d(__webpack_exports__, "Mapstyle", function() { return /* reexport */ Mapstyle["default"]; });
1501
- __webpack_require__.d(__webpack_exports__, "MapstyleSet", function() { return /* reexport */ MapstyleSet["default"]; });
1502
- __webpack_require__.d(__webpack_exports__, "Message", function() { return /* reexport */ Message["default"]; });
1503
- __webpack_require__.d(__webpack_exports__, "Notification", function() { return /* reexport */ Notification["default"]; });
1504
- __webpack_require__.d(__webpack_exports__, "Organisation", function() { return /* reexport */ Organisation["default"]; });
1505
- __webpack_require__.d(__webpack_exports__, "Permission", function() { return /* reexport */ Permission["default"]; });
1506
- __webpack_require__.d(__webpack_exports__, "ProductTour", function() { return /* reexport */ ProductTour_ProductTour; });
1507
- __webpack_require__.d(__webpack_exports__, "ProductTourStep", function() { return /* reexport */ ProductTourStep_ProductTourStep; });
1508
- __webpack_require__.d(__webpack_exports__, "Role", function() { return /* reexport */ Role["default"]; });
1509
- __webpack_require__.d(__webpack_exports__, "Svg", function() { return /* reexport */ Svg["default"]; });
1510
- __webpack_require__.d(__webpack_exports__, "SvgSet", function() { return /* reexport */ SvgSet["default"]; });
1511
- __webpack_require__.d(__webpack_exports__, "Tag", function() { return /* reexport */ Tag["default"]; });
1512
- __webpack_require__.d(__webpack_exports__, "TagType", function() { return /* reexport */ TagType_TagType; });
1513
- __webpack_require__.d(__webpack_exports__, "User", function() { return /* reexport */ User["default"]; });
1514
- __webpack_require__.d(__webpack_exports__, "VectorHighlight", function() { return /* reexport */ VectorHighlight_VectorHighlight; });
1515
- __webpack_require__.d(__webpack_exports__, "VectorChoropleth", function() { return /* reexport */ VectorChoropleth_VectorChoropleth; });
1516
- __webpack_require__.d(__webpack_exports__, "base", function() { return /* binding */ base; });
1120
+ // CONCATENATED MODULE: ./src/resources/ProductTourStep.js
1121
+ /*
1122
+ * BSD 3-Clause License
1123
+ *
1124
+ * Copyright (c) 2020, Mapcreator
1125
+ * All rights reserved.
1126
+ *
1127
+ * Redistribution and use in source and binary forms, with or without
1128
+ * modification, are permitted provided that the following conditions are met:
1129
+ *
1130
+ * Redistributions of source code must retain the above copyright notice, this
1131
+ * list of conditions and the following disclaimer.
1132
+ *
1133
+ * Redistributions in binary form must reproduce the above copyright notice,
1134
+ * this list of conditions and the following disclaimer in the documentation
1135
+ * and/or other materials provided with the distribution.
1136
+ *
1137
+ * Neither the name of the copyright holder nor the names of its
1138
+ * contributors may be used to endorse or promote products derived from
1139
+ * this software without specific prior written permission.
1140
+ *
1141
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
1142
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
1143
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
1144
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
1145
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
1146
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
1147
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
1148
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
1149
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
1150
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1151
+ */
1517
1152
 
1518
- // EXTERNAL MODULE: ./src/resources/base/DownloadedResource.js + 1 modules
1519
- var DownloadedResource = __webpack_require__(23);
1520
1153
 
1521
- // EXTERNAL MODULE: ./src/resources/base/ResourceBase.js
1522
- var ResourceBase = __webpack_require__(6);
1154
+ /**
1155
+ * @extends CrudSetItemBase
1156
+ */
1523
1157
 
1524
- // EXTERNAL MODULE: ./src/utils/helpers.js
1525
- var helpers = __webpack_require__(0);
1158
+ class ProductTourStep_ProductTourStep extends Object(reflection["mix"])(CrudSetItemBase["default"]) {
1159
+ static get resourceName() {
1160
+ return 'product-tours/steps';
1161
+ }
1526
1162
 
1527
- // CONCATENATED MODULE: ./src/resources/Choropleth.js
1163
+ static get parentKey() {
1164
+ return 'product_tour_id';
1165
+ }
1166
+
1167
+ }
1168
+ // CONCATENATED MODULE: ./src/resources/ProductTour.js
1528
1169
  /*
1529
1170
  * BSD 3-Clause License
1530
1171
  *
@@ -1560,61 +1201,37 @@ var helpers = __webpack_require__(0);
1560
1201
 
1561
1202
 
1562
1203
  /**
1563
- * Choropleth resource
1204
+ * Mapstyle set
1205
+ * @extends CrudSetBase
1564
1206
  */
1565
1207
 
1566
- class Choropleth_Choropleth extends ResourceBase["default"] {
1567
- static get resourceName() {
1568
- return 'choropleths';
1208
+ class ProductTour_ProductTour extends Object(reflection["mix"])(CrudSetBase["default"]) {
1209
+ static get resourcePath() {
1210
+ return '/product-tours/{id}';
1569
1211
  }
1570
- /**
1571
- * Get the inset map json
1572
- * @returns {CancelablePromise<Object>} - Choropleth json
1573
- * @throws {ApiError} - If the api returns errors
1574
- */
1575
-
1576
1212
 
1577
- getJson() {
1578
- return Object(helpers["makeCancelable"])(signal => this.api.ky.get(`${this.url}/json`, {
1579
- signal
1580
- }).json());
1213
+ static get resourceName() {
1214
+ return 'product-tours';
1581
1215
  }
1582
- /**
1583
- * Download the choropleth preview
1584
- * @returns {CancelablePromise<DownloadedResource>} - Choropleth preview
1585
- * @throws {ApiError} - If the api returns errors
1586
- */
1587
-
1588
1216
 
1589
- downloadPreview() {
1590
- return Object(helpers["makeCancelable"])(async signal => {
1591
- const response = await this.api.ky.get(`${this.url}/preview`, {
1592
- signal
1593
- });
1594
- return DownloadedResource["default"].fromResponse(response);
1595
- });
1217
+ get _Child() {
1218
+ return ProductTourStep_ProductTourStep;
1596
1219
  }
1597
1220
 
1598
1221
  }
1599
- // EXTERNAL MODULE: ./src/resources/Color.js
1600
- var Color = __webpack_require__(36);
1601
-
1602
- // EXTERNAL MODULE: ./src/resources/Contract.js
1603
- var Contract = __webpack_require__(61);
1604
-
1605
- // EXTERNAL MODULE: ./src/resources/Dimension.js
1606
- var Dimension = __webpack_require__(38);
1222
+ // EXTERNAL MODULE: ./src/resources/Role.js
1223
+ var Role = __webpack_require__(66);
1607
1224
 
1608
- // EXTERNAL MODULE: ./src/resources/DimensionSet.js
1609
- var DimensionSet = __webpack_require__(37);
1225
+ // EXTERNAL MODULE: ./src/resources/Svg.js
1226
+ var Svg = __webpack_require__(46);
1610
1227
 
1611
- // EXTERNAL MODULE: ./src/resources/Domain.js
1612
- var Domain = __webpack_require__(62);
1228
+ // EXTERNAL MODULE: ./src/resources/SvgSet.js
1229
+ var SvgSet = __webpack_require__(45);
1613
1230
 
1614
- // EXTERNAL MODULE: ./src/resources/base/CrudBase.js
1615
- var CrudBase = __webpack_require__(2);
1231
+ // EXTERNAL MODULE: ./src/resources/Tag.js
1232
+ var Tag = __webpack_require__(47);
1616
1233
 
1617
- // CONCATENATED MODULE: ./src/resources/Faq.js
1234
+ // CONCATENATED MODULE: ./src/resources/TagType.js
1618
1235
  /*
1619
1236
  * BSD 3-Clause License
1620
1237
  *
@@ -1647,26 +1264,35 @@ var CrudBase = __webpack_require__(2);
1647
1264
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1648
1265
  */
1649
1266
 
1267
+
1650
1268
  /**
1651
- * Faq resource
1269
+ * TagType resource
1270
+ * @mixes CrudSetBase
1652
1271
  */
1653
1272
 
1654
- class Faq_Faq extends CrudBase["default"] {
1273
+ class TagType_TagType extends CrudBase["default"] {
1274
+ static get resourcePath() {
1275
+ return '/tags/types/{id}';
1276
+ }
1277
+
1655
1278
  static get resourceName() {
1656
- return 'faqs';
1279
+ return 'tag-types';
1657
1280
  }
1281
+ /**
1282
+ * Get the list of tags that are attached to this type
1283
+ * @returns {SimpleResourceProxy} - A proxy for accessing the resource
1284
+ */
1658
1285
 
1659
- }
1660
- // EXTERNAL MODULE: ./src/resources/Feature.js
1661
- var Feature = __webpack_require__(39);
1662
1286
 
1663
- // EXTERNAL MODULE: ./src/resources/Font.js
1664
- var Font = __webpack_require__(41);
1287
+ get tags() {
1288
+ return this._proxyResourceList(Tag["default"], `${this.url}/tags`);
1289
+ }
1665
1290
 
1666
- // EXTERNAL MODULE: ./src/resources/FontFamily.js
1667
- var FontFamily = __webpack_require__(40);
1291
+ }
1292
+ // EXTERNAL MODULE: ./src/resources/User.js
1293
+ var User = __webpack_require__(48);
1668
1294
 
1669
- // CONCATENATED MODULE: ./src/resources/Highlight.js
1295
+ // CONCATENATED MODULE: ./src/resources/VectorHighlight.js
1670
1296
  /*
1671
1297
  * BSD 3-Clause License
1672
1298
  *
@@ -1699,13 +1325,13 @@ var FontFamily = __webpack_require__(40);
1699
1325
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1700
1326
  */
1701
1327
 
1702
- class Highlight_Highlight extends ResourceBase["default"] {
1328
+ class VectorHighlight_VectorHighlight extends ResourceBase["default"] {
1703
1329
  static get resourceName() {
1704
- return 'highlights';
1330
+ return 'highlights/vector';
1705
1331
  }
1706
1332
 
1707
1333
  }
1708
- // CONCATENATED MODULE: ./src/resources/InsetMap.js
1334
+ // CONCATENATED MODULE: ./src/resources/VectorChoropleth.js
1709
1335
  /*
1710
1336
  * BSD 3-Clause License
1711
1337
  *
@@ -1738,74 +1364,144 @@ class Highlight_Highlight extends ResourceBase["default"] {
1738
1364
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1739
1365
  */
1740
1366
 
1741
-
1742
- class InsetMap_InsetMap extends ResourceBase["default"] {
1367
+ class VectorChoropleth_VectorChoropleth extends ResourceBase["default"] {
1743
1368
  static get resourceName() {
1744
- return 'inset-maps';
1369
+ return 'choropleths/vector';
1745
1370
  }
1746
- /**
1747
- * Get the inset map json
1748
- * @returns {CancelablePromise<Object>} - Inset map json
1749
- * @throws {ApiError} - If the api returns errors
1750
- */
1371
+
1372
+ }
1373
+ // CONCATENATED MODULE: ./src/resources/index.js
1374
+ /*
1375
+ * BSD 3-Clause License
1376
+ *
1377
+ * Copyright (c) 2020, Mapcreator
1378
+ * All rights reserved.
1379
+ *
1380
+ * Redistribution and use in source and binary forms, with or without
1381
+ * modification, are permitted provided that the following conditions are met:
1382
+ *
1383
+ * Redistributions of source code must retain the above copyright notice, this
1384
+ * list of conditions and the following disclaimer.
1385
+ *
1386
+ * Redistributions in binary form must reproduce the above copyright notice,
1387
+ * this list of conditions and the following disclaimer in the documentation
1388
+ * and/or other materials provided with the distribution.
1389
+ *
1390
+ * Neither the name of the copyright holder nor the names of its
1391
+ * contributors may be used to endorse or promote products derived from
1392
+ * this software without specific prior written permission.
1393
+ *
1394
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
1395
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
1396
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
1397
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
1398
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
1399
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
1400
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
1401
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
1402
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
1403
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1404
+ */
1405
+
1406
+
1407
+
1408
+
1409
+
1410
+
1411
+
1412
+
1413
+
1414
+
1415
+
1416
+
1417
+
1418
+
1419
+
1420
+
1421
+
1422
+
1423
+
1424
+
1425
+
1426
+
1427
+
1428
+
1429
+
1430
+
1431
+
1432
+
1433
+
1434
+
1435
+
1436
+
1437
+
1438
+
1439
+
1440
+
1441
+
1442
+
1443
+
1444
+
1445
+
1446
+
1447
+
1448
+
1449
+
1450
+
1451
+
1452
+
1453
+
1454
+
1455
+
1456
+
1457
+
1458
+
1459
+
1460
+
1461
+
1462
+
1751
1463
 
1752
1464
 
1753
- getJson() {
1754
- return Object(helpers["makeCancelable"])(signal => this.api.ky.get(`${this.url}/json`, {
1755
- signal
1756
- }).json());
1757
- }
1758
1465
 
1759
- }
1760
- // EXTERNAL MODULE: ./src/resources/Job.js
1761
- var Job = __webpack_require__(42);
1762
1466
 
1763
- // EXTERNAL MODULE: ./src/resources/JobResult.js
1764
- var JobResult = __webpack_require__(33);
1765
1467
 
1766
- // EXTERNAL MODULE: ./src/resources/JobRevision.js
1767
- var JobRevision = __webpack_require__(63);
1768
1468
 
1769
- // EXTERNAL MODULE: ./src/resources/JobShare.js
1770
- var JobShare = __webpack_require__(21);
1771
1469
 
1772
- // EXTERNAL MODULE: ./src/resources/JobType.js
1773
- var JobType = __webpack_require__(43);
1774
1470
 
1775
- // EXTERNAL MODULE: ./src/resources/Language.js
1776
- var Language = __webpack_require__(64);
1777
1471
 
1778
- // EXTERNAL MODULE: ./src/resources/Layer.js
1779
- var Layer = __webpack_require__(22);
1780
1472
 
1781
- // EXTERNAL MODULE: ./src/resources/Mapstyle.js
1782
- var Mapstyle = __webpack_require__(44);
1783
1473
 
1784
- // EXTERNAL MODULE: ./src/resources/MapstyleSet.js + 1 modules
1785
- var MapstyleSet = __webpack_require__(50);
1786
1474
 
1787
- // EXTERNAL MODULE: ./src/resources/Message.js + 1 modules
1788
- var Message = __webpack_require__(57);
1789
1475
 
1790
- // EXTERNAL MODULE: ./src/resources/Notification.js
1791
- var Notification = __webpack_require__(65);
1792
1476
 
1793
- // EXTERNAL MODULE: ./src/resources/Organisation.js
1794
- var Organisation = __webpack_require__(54);
1795
1477
 
1796
- // EXTERNAL MODULE: ./src/resources/Permission.js
1797
- var Permission = __webpack_require__(49);
1798
1478
 
1799
- // EXTERNAL MODULE: ./src/utils/reflection.js
1800
- var reflection = __webpack_require__(1);
1801
1479
 
1802
- // EXTERNAL MODULE: ./src/resources/base/CrudSetBase.js
1803
- var CrudSetBase = __webpack_require__(16);
1480
+ /**
1481
+ * @private
1482
+ */
1804
1483
 
1805
- // EXTERNAL MODULE: ./src/resources/base/CrudSetItemBase.js
1806
- var CrudSetItemBase = __webpack_require__(17);
1484
+ const base = {
1485
+ CrudBase: CrudBase["default"],
1486
+ CrudSetBase: CrudSetBase["default"],
1487
+ ResourceBase: ResourceBase["default"]
1488
+ };
1807
1489
 
1808
- // CONCATENATED MODULE: ./src/resources/ProductTourStep.js
1490
+ /***/ }),
1491
+ /* 4 */
1492
+ /***/ (function(module, __webpack_exports__, __webpack_require__) {
1493
+
1494
+ "use strict";
1495
+ __webpack_require__.r(__webpack_exports__);
1496
+ /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return RequestParameters; });
1497
+ /* harmony import */ var case__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7);
1498
+ /* harmony import */ var case__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(case__WEBPACK_IMPORTED_MODULE_0__);
1499
+ /* harmony import */ var events__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(52);
1500
+ /* harmony import */ var events__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(events__WEBPACK_IMPORTED_MODULE_1__);
1501
+ /* harmony import */ var _enums__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8);
1502
+ /* harmony import */ var _utils_hash__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29);
1503
+ /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1);
1504
+ /* harmony import */ var _utils_requests__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5);
1809
1505
  /*
1810
1506
  * BSD 3-Clause License
1811
1507
  *
@@ -1839,339 +1535,694 @@ var CrudSetItemBase = __webpack_require__(17);
1839
1535
  */
1840
1536
 
1841
1537
 
1538
+
1539
+
1540
+
1541
+
1842
1542
  /**
1843
- * @extends CrudSetItemBase
1543
+ * Used for keeping track of the request parameters
1544
+ *
1545
+ * @fires RequestParameters#change
1546
+ * @fires RequestParameters#change:page
1547
+ * @fires RequestParameters#change:perPage
1548
+ * @fires RequestParameters#change:search
1549
+ * @fires RequestParameters#change:sort
1550
+ * @fires RequestParameters#change:deleted
1551
+ * @fires RequestParameters#change:extra
1844
1552
  */
1845
1553
 
1846
- class ProductTourStep_ProductTourStep extends Object(reflection["mix"])(CrudSetItemBase["default"]) {
1847
- static get resourceName() {
1848
- return 'product-tours/steps';
1554
+ class RequestParameters extends events__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"] {
1555
+ /**
1556
+ * RequestParameters constructor
1557
+ * @param {Object} object - properties
1558
+ */
1559
+ constructor(object = {}) {
1560
+ super(); // Apply defaults
1561
+
1562
+ RequestParameters.keys().forEach(x => this._resolve(x)); // Apply properties
1563
+
1564
+ this.apply(object);
1565
+ } // region instance
1566
+ // region instance getters
1567
+
1568
+ /**
1569
+ * Get page number
1570
+ * @returns {Number} - Page number
1571
+ * @throws {TypeError}
1572
+ */
1573
+
1574
+
1575
+ get page() {
1576
+ return this._resolve('page');
1849
1577
  }
1578
+ /**
1579
+ * Get rows per page
1580
+ * @returns {Number} - Per page
1581
+ * @throws {TypeError}
1582
+ */
1850
1583
 
1851
- static get parentKey() {
1852
- return 'product_tour_id';
1584
+
1585
+ get perPage() {
1586
+ return this._resolve('perPage');
1853
1587
  }
1588
+ /**
1589
+ * Get pagination offset
1590
+ * @returns {Number} - Offset
1591
+ * @throws {TypeError}
1592
+ */
1854
1593
 
1855
- }
1856
- // CONCATENATED MODULE: ./src/resources/ProductTour.js
1857
- /*
1858
- * BSD 3-Clause License
1859
- *
1860
- * Copyright (c) 2020, Mapcreator
1861
- * All rights reserved.
1862
- *
1863
- * Redistribution and use in source and binary forms, with or without
1864
- * modification, are permitted provided that the following conditions are met:
1865
- *
1866
- * Redistributions of source code must retain the above copyright notice, this
1867
- * list of conditions and the following disclaimer.
1868
- *
1869
- * Redistributions in binary form must reproduce the above copyright notice,
1870
- * this list of conditions and the following disclaimer in the documentation
1871
- * and/or other materials provided with the distribution.
1872
- *
1873
- * Neither the name of the copyright holder nor the names of its
1874
- * contributors may be used to endorse or promote products derived from
1875
- * this software without specific prior written permission.
1876
- *
1877
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
1878
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
1879
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
1880
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
1881
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
1882
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
1883
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
1884
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
1885
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
1886
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1887
- */
1594
+
1595
+ get offset() {
1596
+ return this._resolve('offset');
1597
+ }
1598
+ /**
1599
+ * Search query
1600
+ * @returns {Object<String, String|Array<String>>} - Query
1601
+ * @throws {TypeError}
1602
+ */
1603
+
1604
+
1605
+ get search() {
1606
+ return this._resolve('search');
1607
+ }
1608
+ /**
1609
+ * Get sort options
1610
+ * @returns {Array<String>} - Per page
1611
+ * @throws {TypeError}
1612
+ */
1613
+
1614
+
1615
+ get sort() {
1616
+ return this._resolve('sort');
1617
+ }
1618
+ /**
1619
+ * If deleted items should be shown
1620
+ * @returns {String} - Deleted items filter state
1621
+ * @see {@link DeletedState}
1622
+ */
1623
+
1624
+
1625
+ get deleted() {
1626
+ return this._resolve('deleted');
1627
+ }
1628
+ /**
1629
+ * Extra parameters
1630
+ * @returns {Object} - Extra parameters
1631
+ */
1632
+
1633
+
1634
+ get extra() {
1635
+ return this._resolve('extra');
1636
+ } // endregion instance getters
1637
+ // region instance setters
1638
+
1639
+ /**
1640
+ * Page number
1641
+ * @param {Number} value - Page number
1642
+ */
1643
+
1644
+
1645
+ set page(value) {
1646
+ this._update('page', value);
1647
+ }
1648
+ /**
1649
+ * Rows per page
1650
+ * @param {Number} value - Per page
1651
+ */
1652
+
1653
+
1654
+ set perPage(value) {
1655
+ this._update('perPage', value);
1656
+ }
1657
+ /**
1658
+ * Pagination offset
1659
+ * @param {Number} value - Offset
1660
+ */
1661
+
1662
+
1663
+ set offset(value) {
1664
+ this._update('offset', value);
1665
+ }
1666
+ /**
1667
+ * Search query
1668
+ * @param {Object<String, String|Array<String>>} value - Search query
1669
+ */
1670
+
1671
+
1672
+ set search(value) {
1673
+ this._update('search', value);
1674
+ }
1675
+ /**
1676
+ * Sort query
1677
+ * @param {Array<String>} value - Sort query
1678
+ */
1679
+
1680
+
1681
+ set sort(value) {
1682
+ this._update('sort', value);
1683
+ }
1684
+ /**
1685
+ * Deleted items filter state
1686
+ * @param {String} value - Deleted items filter state
1687
+ * @see {@link DeletedState}
1688
+ */
1689
+
1690
+
1691
+ set deleted(value) {
1692
+ this._update('deleted', value);
1693
+ }
1694
+ /**
1695
+ * Extra request parameters
1696
+ * @param {Object} value - Extra request parameters
1697
+ */
1698
+
1699
+
1700
+ set extra(value) {
1701
+ this._update('extra', value);
1702
+ } // endregion instance setters
1703
+ // endregion instance
1704
+ // region static
1705
+ // region getters
1706
+
1707
+ /**
1708
+ * Default page number
1709
+ * @returns {Number} - Page number
1710
+ */
1711
+
1712
+
1713
+ static get page() {
1714
+ return RequestParameters._page || 1;
1715
+ }
1716
+ /**
1717
+ * Default per page
1718
+ * @returns {Number} - Per page
1719
+ */
1720
+
1721
+
1722
+ static get perPage() {
1723
+ return RequestParameters._perPage || Number("12") || 12;
1724
+ }
1725
+ /**
1726
+ * Default pagination offset
1727
+ * @returns {Number} - Offset
1728
+ */
1888
1729
 
1889
1730
 
1731
+ static get offset() {
1732
+ return RequestParameters._offset || 0;
1733
+ }
1734
+ /**
1735
+ * Gets the maximum allowed value for perPage
1736
+ * Some users will have a special permission that allows them to fetch more than 50 resources at once
1737
+ * @returns {Number} - Maximum amount of resources per page
1738
+ */
1890
1739
 
1891
- /**
1892
- * Mapstyle set
1893
- * @extends CrudSetBase
1894
- */
1895
1740
 
1896
- class ProductTour_ProductTour extends Object(reflection["mix"])(CrudSetBase["default"]) {
1897
- static get resourcePath() {
1898
- return '/product-tours/{id}';
1741
+ static get maxPerPage() {
1742
+ return RequestParameters._maxPerPage || 50;
1899
1743
  }
1744
+ /**
1745
+ * Default search query
1746
+ * @returns {Object<String, String|Array<String>>} - Search query
1747
+ */
1900
1748
 
1901
- static get resourceName() {
1902
- return 'product-tours';
1749
+
1750
+ static get search() {
1751
+ return RequestParameters._search || {};
1903
1752
  }
1753
+ /**
1754
+ * Default sort query
1755
+ * @returns {Array<String>} - Sort query
1756
+ */
1904
1757
 
1905
- get _Child() {
1906
- return ProductTourStep_ProductTourStep;
1758
+
1759
+ static get sort() {
1760
+ return RequestParameters._sort || [];
1907
1761
  }
1762
+ /**
1763
+ * Default deleted items filter state
1764
+ * @returns {String|undefined} - Deleted items filter state
1765
+ */
1908
1766
 
1909
- }
1910
- // EXTERNAL MODULE: ./src/resources/Role.js
1911
- var Role = __webpack_require__(66);
1912
1767
 
1913
- // EXTERNAL MODULE: ./src/resources/Svg.js
1914
- var Svg = __webpack_require__(46);
1768
+ static get deleted() {
1769
+ return RequestParameters._deleted || void 0;
1770
+ }
1771
+ /**
1772
+ * Default extra request parameters
1773
+ * @returns {Object} - Extra request parameters
1774
+ */
1915
1775
 
1916
- // EXTERNAL MODULE: ./src/resources/SvgSet.js
1917
- var SvgSet = __webpack_require__(45);
1918
1776
 
1919
- // EXTERNAL MODULE: ./src/resources/Tag.js
1920
- var Tag = __webpack_require__(47);
1777
+ static get extra() {
1778
+ return RequestParameters._extra || {};
1779
+ } // endregion getters
1780
+ // region setters
1921
1781
 
1922
- // CONCATENATED MODULE: ./src/resources/TagType.js
1923
- /*
1924
- * BSD 3-Clause License
1925
- *
1926
- * Copyright (c) 2020, Mapcreator
1927
- * All rights reserved.
1928
- *
1929
- * Redistribution and use in source and binary forms, with or without
1930
- * modification, are permitted provided that the following conditions are met:
1931
- *
1932
- * Redistributions of source code must retain the above copyright notice, this
1933
- * list of conditions and the following disclaimer.
1934
- *
1935
- * Redistributions in binary form must reproduce the above copyright notice,
1936
- * this list of conditions and the following disclaimer in the documentation
1937
- * and/or other materials provided with the distribution.
1938
- *
1939
- * Neither the name of the copyright holder nor the names of its
1940
- * contributors may be used to endorse or promote products derived from
1941
- * this software without specific prior written permission.
1942
- *
1943
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
1944
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
1945
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
1946
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
1947
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
1948
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
1949
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
1950
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
1951
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
1952
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1953
- */
1782
+ /**
1783
+ * Default page number
1784
+ * @param {Number} value - Page number
1785
+ */
1954
1786
 
1955
1787
 
1956
- /**
1957
- * TagType resource
1958
- * @mixes CrudSetBase
1959
- */
1788
+ static set page(value) {
1789
+ RequestParameters._page = RequestParameters._validatePage(value);
1790
+ }
1791
+ /**
1792
+ * Default per page
1793
+ * @param {Number} value - Per page
1794
+ */
1960
1795
 
1961
- class TagType_TagType extends CrudBase["default"] {
1962
- static get resourcePath() {
1963
- return '/tags/types/{id}';
1796
+
1797
+ static set perPage(value) {
1798
+ RequestParameters._perPage = RequestParameters._validatePerPage(value);
1964
1799
  }
1800
+ /**
1801
+ * Default pagination offset
1802
+ * @param {Number} value - Offset
1803
+ */
1965
1804
 
1966
- static get resourceName() {
1967
- return 'tag-types';
1805
+
1806
+ static set offset(value) {
1807
+ RequestParameters._offset = RequestParameters._validateOffset(value);
1968
1808
  }
1969
1809
  /**
1970
- * Get the list of tags that are attached to this type
1971
- * @returns {SimpleResourceProxy} - A proxy for accessing the resource
1810
+ * Sets the maximum allowed value for perPage
1811
+ * Some users will have a special permission that allows them to fetch more than 50 resources at once
1812
+ * @param {Number} value - Maximum amount of resources per page
1972
1813
  */
1973
1814
 
1974
1815
 
1975
- get tags() {
1976
- return this._proxyResourceList(Tag["default"], `${this.url}/tags`);
1816
+ static set maxPerPage(value) {
1817
+ RequestParameters._maxPerPage = RequestParameters._validateMaxPerPage(value);
1977
1818
  }
1819
+ /**
1820
+ * Default search query
1821
+ * @param {Object<String, String|Array<String>>} value - Search query
1822
+ */
1978
1823
 
1979
- }
1980
- // EXTERNAL MODULE: ./src/resources/User.js
1981
- var User = __webpack_require__(48);
1982
1824
 
1983
- // CONCATENATED MODULE: ./src/resources/VectorHighlight.js
1984
- /*
1985
- * BSD 3-Clause License
1986
- *
1987
- * Copyright (c) 2020, Mapcreator
1988
- * All rights reserved.
1989
- *
1990
- * Redistribution and use in source and binary forms, with or without
1991
- * modification, are permitted provided that the following conditions are met:
1992
- *
1993
- * Redistributions of source code must retain the above copyright notice, this
1994
- * list of conditions and the following disclaimer.
1995
- *
1996
- * Redistributions in binary form must reproduce the above copyright notice,
1997
- * this list of conditions and the following disclaimer in the documentation
1998
- * and/or other materials provided with the distribution.
1999
- *
2000
- * Neither the name of the copyright holder nor the names of its
2001
- * contributors may be used to endorse or promote products derived from
2002
- * this software without specific prior written permission.
2003
- *
2004
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
2005
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
2006
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
2007
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
2008
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
2009
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
2010
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
2011
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
2012
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
2013
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2014
- */
1825
+ static set search(value) {
1826
+ RequestParameters._search = RequestParameters._validateSearch(value);
1827
+ }
1828
+ /**
1829
+ * Default sort query
1830
+ * @param {Array<String>} value - Sort query
1831
+ */
2015
1832
 
2016
- class VectorHighlight_VectorHighlight extends ResourceBase["default"] {
2017
- static get resourceName() {
2018
- return 'highlights/vector';
1833
+
1834
+ static set sort(value) {
1835
+ RequestParameters._sort = RequestParameters._validateSort(value);
2019
1836
  }
1837
+ /**
1838
+ * Default deleted items filter state
1839
+ * @param {String} value - Deleted items filter state
1840
+ */
2020
1841
 
2021
- }
2022
- // CONCATENATED MODULE: ./src/resources/VectorChoropleth.js
2023
- /*
2024
- * BSD 3-Clause License
2025
- *
2026
- * Copyright (c) 2020, Mapcreator
2027
- * All rights reserved.
2028
- *
2029
- * Redistribution and use in source and binary forms, with or without
2030
- * modification, are permitted provided that the following conditions are met:
2031
- *
2032
- * Redistributions of source code must retain the above copyright notice, this
2033
- * list of conditions and the following disclaimer.
2034
- *
2035
- * Redistributions in binary form must reproduce the above copyright notice,
2036
- * this list of conditions and the following disclaimer in the documentation
2037
- * and/or other materials provided with the distribution.
2038
- *
2039
- * Neither the name of the copyright holder nor the names of its
2040
- * contributors may be used to endorse or promote products derived from
2041
- * this software without specific prior written permission.
2042
- *
2043
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
2044
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
2045
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
2046
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
2047
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
2048
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
2049
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
2050
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
2051
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
2052
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2053
- */
2054
1842
 
2055
- class VectorChoropleth_VectorChoropleth extends ResourceBase["default"] {
2056
- static get resourceName() {
2057
- return 'choropleths/vector';
1843
+ static set deleted(value) {
1844
+ RequestParameters._deleted = RequestParameters._validateDeleted(value);
1845
+ }
1846
+ /**
1847
+ * Default extra request parameters
1848
+ * @param {Object} value - Extra request parameters
1849
+ */
1850
+
1851
+
1852
+ static set extra(value) {
1853
+ RequestParameters._extra = RequestParameters._validateExtra(value);
1854
+ } // endregion setters
1855
+ // endregion static
1856
+ // region validators
1857
+
1858
+ /**
1859
+ * Validators should work the same as laravel's ::validate method. This means
1860
+ * this means that they will throw a TypeError or return a normalized result.
1861
+ */
1862
+
1863
+
1864
+ static _validatePage(value) {
1865
+ if (typeof value !== 'number') {
1866
+ throw new TypeError(`Expected page to be of type 'number' instead got '${typeof value}'`);
1867
+ }
1868
+
1869
+ if (value < 0) {
1870
+ throw new TypeError('Page must be a positive number');
1871
+ }
1872
+
1873
+ if (Number.isNaN(value) || !Number.isFinite(value)) {
1874
+ throw new TypeError('Page must be a real number');
1875
+ }
1876
+
1877
+ if (Math.round(value) !== value) {
1878
+ throw new TypeError('Page must be a natural number');
1879
+ }
1880
+
1881
+ return Math.round(value);
2058
1882
  }
2059
1883
 
2060
- }
2061
- // CONCATENATED MODULE: ./src/resources/index.js
2062
- /*
2063
- * BSD 3-Clause License
2064
- *
2065
- * Copyright (c) 2020, Mapcreator
2066
- * All rights reserved.
2067
- *
2068
- * Redistribution and use in source and binary forms, with or without
2069
- * modification, are permitted provided that the following conditions are met:
2070
- *
2071
- * Redistributions of source code must retain the above copyright notice, this
2072
- * list of conditions and the following disclaimer.
2073
- *
2074
- * Redistributions in binary form must reproduce the above copyright notice,
2075
- * this list of conditions and the following disclaimer in the documentation
2076
- * and/or other materials provided with the distribution.
2077
- *
2078
- * Neither the name of the copyright holder nor the names of its
2079
- * contributors may be used to endorse or promote products derived from
2080
- * this software without specific prior written permission.
2081
- *
2082
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
2083
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
2084
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
2085
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
2086
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
2087
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
2088
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
2089
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
2090
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
2091
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2092
- */
1884
+ static _validatePerPage(value) {
1885
+ if (typeof value !== 'number') {
1886
+ throw new TypeError(`Expected per page to be of type 'Number' instead got '${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}'`);
1887
+ }
1888
+
1889
+ if (value <= 0) {
1890
+ throw new TypeError('Per page must be greater than zero');
1891
+ }
1892
+
1893
+ if (Number.isNaN(value) || !Number.isFinite(value)) {
1894
+ throw new TypeError('Per page must be a real number');
1895
+ }
1896
+
1897
+ if (Math.round(value) !== value) {
1898
+ throw new TypeError('Per page must be a natural number');
1899
+ } // Upper limit is 50 by default
1900
+
2093
1901
 
1902
+ value = Math.min(RequestParameters.maxPerPage, value);
1903
+ return value;
1904
+ }
1905
+
1906
+ static _validateOffset(value) {
1907
+ if (typeof value !== 'number') {
1908
+ throw new TypeError(`Expected offset to be of type 'Number' instead got '${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}'`);
1909
+ }
2094
1910
 
1911
+ if (value < 0) {
1912
+ throw new TypeError('Offset must be a positive number');
1913
+ }
2095
1914
 
1915
+ if (Number.isNaN(value) || !Number.isFinite(value)) {
1916
+ throw new TypeError('Offset must be a real number');
1917
+ }
2096
1918
 
1919
+ if (Math.round(value) !== value) {
1920
+ throw new TypeError('Offset must be a natural number');
1921
+ }
2097
1922
 
1923
+ return value;
1924
+ }
2098
1925
 
1926
+ static _validateMaxPerPage(value) {
1927
+ if (typeof value !== 'number') {
1928
+ throw new TypeError(`Expected page to be of type 'Number' instead got '${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}'`);
1929
+ }
2099
1930
 
1931
+ if (value < 1) {
1932
+ throw new TypeError('Value must be greater or equal to 1');
1933
+ }
2100
1934
 
1935
+ return value;
1936
+ }
2101
1937
 
1938
+ static _validateSearch(value) {
1939
+ if (typeof value !== 'object' || Array.isArray(value)) {
1940
+ throw new TypeError(`Expected value to be of type "Object" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}"`);
1941
+ } // Normalization macro
2102
1942
 
2103
1943
 
1944
+ const normalize = x => typeof x === 'number' ? x.toString() : x;
2104
1945
 
1946
+ for (let key of Object.keys(value)) {
1947
+ key = normalize(key);
1948
+ value[key] = normalize(value[key]);
2105
1949
 
1950
+ if (typeof key !== 'string') {
1951
+ throw new TypeError(`Expected key to be of type "String" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(key)}"`);
1952
+ }
2106
1953
 
1954
+ if (Array.isArray(value[key])) {
1955
+ if (value[key].length > 0) {
1956
+ for (const query of value[key]) {
1957
+ if (!['string', 'number', 'boolean'].includes(typeof query) && query !== null) {
1958
+ throw new TypeError(`Expected query for "${key}" to be of type "String", "Boolean", "Number" or "null" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(query)}"`);
1959
+ }
1960
+ }
1961
+ } else {
1962
+ // Drop empty nodes
1963
+ delete value[key];
1964
+ }
1965
+ } else if (value[key] === null) {
1966
+ delete value[key];
1967
+ } else if (!['string', 'number', 'boolean'].includes(typeof value[key]) && value[key] !== null) {
1968
+ throw new TypeError(`Expected query value to be of type "String", "Boolean", "Number", "Array" or "null" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value[key])}"`);
1969
+ }
1970
+ }
2107
1971
 
1972
+ return value;
1973
+ }
2108
1974
 
1975
+ static _validateSort(value) {
1976
+ if (typeof value === 'string') {
1977
+ return this._validateSort(value.split(','));
1978
+ }
2109
1979
 
1980
+ if (!(value instanceof Array)) {
1981
+ throw new TypeError(`Expected sort value to be of type "Array" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}"`);
1982
+ } // Array keys type checking
2110
1983
 
2111
1984
 
1985
+ value.filter(x => typeof x !== 'string').forEach(x => {
1986
+ throw new TypeError(`Expected sort array values to be of type "String" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(x)}"`);
1987
+ }); // Don't do regex matching because it's something
1988
+ // we can just let the server do for us.
2112
1989
 
1990
+ return value;
1991
+ }
2113
1992
 
1993
+ static _validateDeleted(value) {
1994
+ if (typeof value === 'undefined') {
1995
+ return value;
1996
+ }
2114
1997
 
1998
+ if (typeof value !== 'string') {
1999
+ throw new TypeError(`Expected deleted to be of type "string" got "${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}". See: DeletedState`);
2000
+ }
2115
2001
 
2002
+ value = value.toLowerCase();
2003
+ const possible = _enums__WEBPACK_IMPORTED_MODULE_2__["DeletedState"].values();
2116
2004
 
2005
+ if (!possible.includes(value)) {
2006
+ throw new TypeError(`Expected deleted to be one of ${possible.join(', ')}, got ${value}`);
2007
+ }
2117
2008
 
2009
+ return value;
2010
+ }
2118
2011
 
2012
+ static _validateExtra(value) {
2013
+ if (typeof value !== 'object') {
2014
+ throw new TypeError(`Expected extra to be of type 'object', got '${Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_4__["getTypeName"])(value)}'`);
2015
+ }
2119
2016
 
2017
+ return value;
2018
+ } // endregion validators
2120
2019
 
2121
2020
 
2021
+ _resolve(name) {
2022
+ const _name = `_${name}`;
2122
2023
 
2024
+ if (!this[_name]) {
2025
+ // Confuse esdoc
2026
+ (this || {})[_name] = RequestParameters[name];
2027
+ }
2123
2028
 
2029
+ return this[_name];
2030
+ }
2124
2031
 
2032
+ _update(name, value, preventEvent = false) {
2033
+ const _name = `_${name}`;
2034
+ value = RequestParameters[`_validate${Object(case__WEBPACK_IMPORTED_MODULE_0__["pascal"])(name)}`](value);
2035
+ (this || {})[_name] = value; // Weird syntax confuses esdoc
2125
2036
 
2037
+ if (!preventEvent) {
2038
+ /**
2039
+ * Change event.
2040
+ *
2041
+ * @event RequestParameters#change
2042
+ * @type {Array<object>}
2043
+ * @property {string} name - Parameter name
2044
+ * @property {*} value - New value
2045
+ */
2046
+ this.emit('change', [{
2047
+ name,
2048
+ value
2049
+ }]);
2050
+ this.emit(`change:${name}`, value);
2051
+ }
2126
2052
 
2053
+ return value;
2054
+ } // region utils
2127
2055
 
2056
+ /**
2057
+ * Urlencode parameters
2058
+ * @returns {string} - HTTP query
2059
+ */
2128
2060
 
2129
2061
 
2062
+ encode() {
2063
+ return Object(_utils_requests__WEBPACK_IMPORTED_MODULE_5__["encodeQueryString"])(this.toParameterObject());
2064
+ }
2065
+ /**
2066
+ * Convert to object
2067
+ * @returns {Object} - Object
2068
+ */
2130
2069
 
2131
2070
 
2071
+ toObject() {
2072
+ return RequestParameters.keys().reduce((obj, key) => {
2073
+ obj[Object(case__WEBPACK_IMPORTED_MODULE_0__["snake"])(key)] = this._resolve(key);
2074
+ return obj;
2075
+ }, {});
2076
+ }
2077
+ /**
2078
+ * Convert to object
2079
+ * @returns {Object} - Object
2080
+ */
2132
2081
 
2133
2082
 
2083
+ toParameterObject() {
2084
+ const data = {};
2085
+ RequestParameters.keys().forEach(key => {
2086
+ // Skip extra key
2087
+ if (key === 'extra') {
2088
+ return;
2089
+ }
2134
2090
 
2091
+ data[Object(case__WEBPACK_IMPORTED_MODULE_0__["snake"])(key)] = this._resolve(key);
2092
+ }); // Fix column names for sort
2135
2093
 
2094
+ data.sort = data.sort.map(case__WEBPACK_IMPORTED_MODULE_0__["snake"]).map(x => x.replace(/^_/, '-')).join(',');
2136
2095
 
2096
+ if (data.offset === 0) {
2097
+ delete data.offset;
2098
+ } // Fix column names for search
2137
2099
 
2138
2100
 
2101
+ for (const key of Object.keys(data.search)) {
2102
+ const snakeKey = key.split(',').map(case__WEBPACK_IMPORTED_MODULE_0__["snake"]).join(',');
2139
2103
 
2104
+ if (key !== snakeKey) {
2105
+ data.search[snakeKey] = data.search[key];
2106
+ delete data.search[key];
2107
+ }
2108
+ } // Cast search values
2140
2109
 
2141
2110
 
2111
+ for (const key of Object.keys(data.search)) {
2112
+ if (typeof data.search[key] === 'boolean') {
2113
+ data.search[key] = Number(data.search[key]);
2114
+ }
2142
2115
 
2116
+ if (data.search[key] === null) {
2117
+ data.search[key] = '';
2118
+ }
2119
+ } // Overwrite using extra properties
2143
2120
 
2144
2121
 
2122
+ const extra = this._resolve('extra');
2145
2123
 
2124
+ for (const key of Object.keys(extra)) {
2125
+ data[key] = extra[key];
2126
+ }
2146
2127
 
2128
+ for (const key of Object.keys(data)) {
2129
+ if (typeof data[key] === 'undefined') {
2130
+ delete data[key];
2131
+ }
2132
+ }
2147
2133
 
2134
+ return data;
2135
+ }
2136
+ /**
2137
+ * Copy object
2138
+ * @returns {RequestParameters} - Copy
2139
+ */
2148
2140
 
2149
2141
 
2142
+ copy() {
2143
+ return new RequestParameters(this.toObject());
2144
+ }
2145
+ /**
2146
+ * Different parameters
2147
+ * @returns {Array<String>} - keys
2148
+ */
2150
2149
 
2151
2150
 
2151
+ static keys() {
2152
+ // enumeration is disabled for properties
2153
+ return ['page', 'perPage', 'offset', 'search', 'sort', 'deleted', 'extra'];
2154
+ }
2155
+ /**
2156
+ * Generates a cache token
2157
+ * @returns {string} - Cache token
2158
+ */
2152
2159
 
2153
2160
 
2161
+ token() {
2162
+ const data = this.toObject();
2163
+ delete data.page;
2164
+ delete data['per_page'];
2165
+ return Object(_utils_hash__WEBPACK_IMPORTED_MODULE_3__["hashObject"])(data);
2166
+ }
2167
+ /**
2168
+ * Resets all parameters back to default
2169
+ */
2154
2170
 
2155
2171
 
2172
+ static resetDefaults() {
2173
+ for (const key of RequestParameters.keys()) {
2174
+ delete RequestParameters[`_${key}`];
2175
+ }
2176
+ }
2177
+ /**
2178
+ * Apply parameters from object
2179
+ * @param {object|RequestParameters} params - parameters
2180
+ * @returns {Object[]} - Array containing the updated values
2181
+ * @example
2182
+ * const params = new RequestParameters({perPage: 12});
2183
+ *
2184
+ * params.perPage === 12;
2185
+ *
2186
+ * params.apply({perPage: 50});
2187
+ *
2188
+ * params.perPage === 50;
2189
+ */
2156
2190
 
2157
2191
 
2192
+ apply(params) {
2193
+ if (params instanceof RequestParameters) {
2194
+ params = params.toObject();
2195
+ }
2158
2196
 
2197
+ const out = [];
2159
2198
 
2199
+ for (const key of Object.keys(params)) {
2200
+ const Key = Object(case__WEBPACK_IMPORTED_MODULE_0__["camel"])(key);
2160
2201
 
2202
+ if (key[0] === '_' || !RequestParameters.keys().includes(Key)) {
2203
+ continue;
2204
+ }
2161
2205
 
2206
+ out.push({
2207
+ name: Key,
2208
+ value: this._update(Key, params[key], true)
2209
+ });
2210
+ }
2162
2211
 
2212
+ this.emit('change', out);
2163
2213
 
2214
+ for (const {
2215
+ name,
2216
+ value
2217
+ } of out) {
2218
+ this.emit(`change:${name}`, value);
2219
+ }
2164
2220
 
2221
+ return out;
2222
+ } // endregion utils
2165
2223
 
2166
- /**
2167
- * @private
2168
- */
2169
2224
 
2170
- const base = {
2171
- CrudBase: CrudBase["default"],
2172
- CrudSetBase: CrudSetBase["default"],
2173
- ResourceBase: ResourceBase["default"]
2174
- };
2225
+ }
2175
2226
 
2176
2227
  /***/ }),
2177
2228
  /* 5 */
@@ -3572,6 +3623,99 @@ function windowTest(str) {
3572
3623
  /* 14 */
3573
3624
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3574
3625
 
3626
+ "use strict";
3627
+ __webpack_require__.r(__webpack_exports__);
3628
+ /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return CrudSetItemBase; });
3629
+ /* harmony import */ var _errors_AbstractError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11);
3630
+ /* harmony import */ var _CrudBase__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);
3631
+ /* harmony import */ var case__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7);
3632
+ /* harmony import */ var case__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(case__WEBPACK_IMPORTED_MODULE_2__);
3633
+ /*
3634
+ * BSD 3-Clause License
3635
+ *
3636
+ * Copyright (c) 2020, Mapcreator
3637
+ * All rights reserved.
3638
+ *
3639
+ * Redistribution and use in source and binary forms, with or without
3640
+ * modification, are permitted provided that the following conditions are met:
3641
+ *
3642
+ * Redistributions of source code must retain the above copyright notice, this
3643
+ * list of conditions and the following disclaimer.
3644
+ *
3645
+ * Redistributions in binary form must reproduce the above copyright notice,
3646
+ * this list of conditions and the following disclaimer in the documentation
3647
+ * and/or other materials provided with the distribution.
3648
+ *
3649
+ * Neither the name of the copyright holder nor the names of its
3650
+ * contributors may be used to endorse or promote products derived from
3651
+ * this software without specific prior written permission.
3652
+ *
3653
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
3654
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
3655
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
3656
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
3657
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
3658
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
3659
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
3660
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
3661
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
3662
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
3663
+ */
3664
+
3665
+
3666
+
3667
+ /**
3668
+ * Items that are part of a set
3669
+ * @abstract
3670
+ */
3671
+
3672
+ class CrudSetItemBase extends _CrudBase__WEBPACK_IMPORTED_MODULE_1__["default"] {
3673
+ /**
3674
+ * @param {Mapcreator} api - Api instance
3675
+ * @param {Object<String, *>} data - Item data
3676
+ */
3677
+ constructor(api, data = {}) {
3678
+ super(api, data);
3679
+
3680
+ if (this.constructor === _CrudBase__WEBPACK_IMPORTED_MODULE_1__["default"]) {
3681
+ throw new _errors_AbstractError__WEBPACK_IMPORTED_MODULE_0__["AbstractClassError"]();
3682
+ }
3683
+ }
3684
+
3685
+ get hasParent() {
3686
+ const parentKey = Object(case__WEBPACK_IMPORTED_MODULE_2__["camel"])(this.constructor.parentKey);
3687
+ return this.hasOwnProperty(parentKey);
3688
+ }
3689
+ /**
3690
+ * Get the parent id
3691
+ * @returns {number|undefined} - Parent number
3692
+ */
3693
+
3694
+
3695
+ get parentId() {
3696
+ if (this.hasParent) {
3697
+ const parentKey = Object(case__WEBPACK_IMPORTED_MODULE_2__["camel"])(this.constructor.parentKey);
3698
+ return Number(this[parentKey]);
3699
+ }
3700
+
3701
+ return void 0;
3702
+ }
3703
+ /**
3704
+ * Get the parent key
3705
+ * @returns {string} - Parent key
3706
+ */
3707
+
3708
+
3709
+ static get parentKey() {
3710
+ return this.resourceName.replace(/s$/, '_set_id');
3711
+ }
3712
+
3713
+ }
3714
+
3715
+ /***/ }),
3716
+ /* 15 */
3717
+ /***/ (function(module, __webpack_exports__, __webpack_require__) {
3718
+
3575
3719
  "use strict";
3576
3720
  __webpack_require__.r(__webpack_exports__);
3577
3721
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return ResourceProxy; });
@@ -3694,7 +3838,7 @@ class ResourceProxy extends _SimpleResourceProxy__WEBPACK_IMPORTED_MODULE_1__["d
3694
3838
  }
3695
3839
 
3696
3840
  /***/ }),
3697
- /* 15 */
3841
+ /* 16 */
3698
3842
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3699
3843
 
3700
3844
  "use strict";
@@ -3880,7 +4024,7 @@ class OAuthToken {
3880
4024
  }
3881
4025
 
3882
4026
  /***/ }),
3883
- /* 16 */
4027
+ /* 17 */
3884
4028
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
3885
4029
 
3886
4030
  "use strict";
@@ -3973,99 +4117,6 @@ class CrudSetBase extends _CrudBase__WEBPACK_IMPORTED_MODULE_1__["default"] {
3973
4117
 
3974
4118
  }
3975
4119
 
3976
- /***/ }),
3977
- /* 17 */
3978
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
3979
-
3980
- "use strict";
3981
- __webpack_require__.r(__webpack_exports__);
3982
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return CrudSetItemBase; });
3983
- /* harmony import */ var _errors_AbstractError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11);
3984
- /* harmony import */ var _CrudBase__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);
3985
- /* harmony import */ var case__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7);
3986
- /* harmony import */ var case__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(case__WEBPACK_IMPORTED_MODULE_2__);
3987
- /*
3988
- * BSD 3-Clause License
3989
- *
3990
- * Copyright (c) 2020, Mapcreator
3991
- * All rights reserved.
3992
- *
3993
- * Redistribution and use in source and binary forms, with or without
3994
- * modification, are permitted provided that the following conditions are met:
3995
- *
3996
- * Redistributions of source code must retain the above copyright notice, this
3997
- * list of conditions and the following disclaimer.
3998
- *
3999
- * Redistributions in binary form must reproduce the above copyright notice,
4000
- * this list of conditions and the following disclaimer in the documentation
4001
- * and/or other materials provided with the distribution.
4002
- *
4003
- * Neither the name of the copyright holder nor the names of its
4004
- * contributors may be used to endorse or promote products derived from
4005
- * this software without specific prior written permission.
4006
- *
4007
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
4008
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
4009
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
4010
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
4011
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
4012
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
4013
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
4014
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
4015
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
4016
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
4017
- */
4018
-
4019
-
4020
-
4021
- /**
4022
- * Items that are part of a set
4023
- * @abstract
4024
- */
4025
-
4026
- class CrudSetItemBase extends _CrudBase__WEBPACK_IMPORTED_MODULE_1__["default"] {
4027
- /**
4028
- * @param {Mapcreator} api - Api instance
4029
- * @param {Object<String, *>} data - Item data
4030
- */
4031
- constructor(api, data = {}) {
4032
- super(api, data);
4033
-
4034
- if (this.constructor === _CrudBase__WEBPACK_IMPORTED_MODULE_1__["default"]) {
4035
- throw new _errors_AbstractError__WEBPACK_IMPORTED_MODULE_0__["AbstractClassError"]();
4036
- }
4037
- }
4038
-
4039
- get hasParent() {
4040
- const parentKey = Object(case__WEBPACK_IMPORTED_MODULE_2__["camel"])(this.constructor.parentKey);
4041
- return this.hasOwnProperty(parentKey);
4042
- }
4043
- /**
4044
- * Get the parent id
4045
- * @returns {number|undefined} - Parent number
4046
- */
4047
-
4048
-
4049
- get parentId() {
4050
- if (this.hasParent) {
4051
- const parentKey = Object(case__WEBPACK_IMPORTED_MODULE_2__["camel"])(this.constructor.parentKey);
4052
- return Number(this[parentKey]);
4053
- }
4054
-
4055
- return void 0;
4056
- }
4057
- /**
4058
- * Get the parent key
4059
- * @returns {string} - Parent key
4060
- */
4061
-
4062
-
4063
- static get parentKey() {
4064
- return this.resourceName.replace(/s$/, '_set_id');
4065
- }
4066
-
4067
- }
4068
-
4069
4120
  /***/ }),
4070
4121
  /* 18 */
4071
4122
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
@@ -4081,7 +4132,7 @@ __webpack_require__.d(__webpack_exports__, "default", function() { return /* bin
4081
4132
  var Mapcreator = __webpack_require__(26);
4082
4133
 
4083
4134
  // EXTERNAL MODULE: ./src/RequestParameters.js
4084
- var RequestParameters = __webpack_require__(3);
4135
+ var RequestParameters = __webpack_require__(4);
4085
4136
 
4086
4137
  // EXTERNAL MODULE: ./src/utils/reflection.js
4087
4138
  var reflection = __webpack_require__(1);
@@ -5805,7 +5856,7 @@ __webpack_require__.r(__webpack_exports__);
5805
5856
  /* harmony import */ var ky_universal__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(53);
5806
5857
  /* harmony import */ var _errors_AbstractError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(11);
5807
5858
  /* harmony import */ var _storage_StorageManager__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(20);
5808
- /* harmony import */ var _OAuthToken__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(15);
5859
+ /* harmony import */ var _OAuthToken__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(16);
5809
5860
  /* harmony import */ var _StateContainer__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(58);
5810
5861
  /* harmony import */ var _utils_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(0);
5811
5862
 
@@ -5970,19 +6021,19 @@ var DummyFlow = __webpack_require__(55);
5970
6021
  var OAuth = __webpack_require__(25);
5971
6022
 
5972
6023
  // EXTERNAL MODULE: ./src/oauth/OAuthToken.js
5973
- var OAuthToken = __webpack_require__(15);
6024
+ var OAuthToken = __webpack_require__(16);
5974
6025
 
5975
6026
  // EXTERNAL MODULE: ./src/proxy/GeoResourceProxy.js
5976
6027
  var GeoResourceProxy = __webpack_require__(32);
5977
6028
 
5978
6029
  // EXTERNAL MODULE: ./src/proxy/ResourceProxy.js
5979
- var ResourceProxy = __webpack_require__(14);
6030
+ var ResourceProxy = __webpack_require__(15);
5980
6031
 
5981
6032
  // EXTERNAL MODULE: ./src/proxy/SimpleResourceProxy.js + 1 modules
5982
6033
  var SimpleResourceProxy = __webpack_require__(18);
5983
6034
 
5984
- // EXTERNAL MODULE: ./src/resources/index.js + 9 modules
5985
- var resources = __webpack_require__(4);
6035
+ // EXTERNAL MODULE: ./src/resources/index.js + 10 modules
6036
+ var resources = __webpack_require__(3);
5986
6037
 
5987
6038
  // EXTERNAL MODULE: ./src/resources/base/ResourceBase.js
5988
6039
  var ResourceBase = __webpack_require__(6);
@@ -6679,6 +6730,16 @@ class Mapcreator_Mapcreator extends Object(reflection["mix"])(events_default.a,
6679
6730
  get layers() {
6680
6731
  return this.static(resources["Layer"]);
6681
6732
  }
6733
+ /**
6734
+ * LayerFaq accessor
6735
+ * @see {@link LayerFaq}
6736
+ * @returns {ResourceProxy} - A proxy for accessing the resource
6737
+ */
6738
+
6739
+
6740
+ get layerFaqs() {
6741
+ return this.static(resources["LayerFaq"]);
6742
+ }
6682
6743
  /**
6683
6744
  * Layer group accessor
6684
6745
  * @see {@link LayerGroup}
@@ -7316,9 +7377,9 @@ class GeoError extends Error {}
7316
7377
  __webpack_require__.r(__webpack_exports__);
7317
7378
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return GeoResourceProxy; });
7318
7379
  /* harmony import */ var _errors_GeoError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31);
7319
- /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3);
7380
+ /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4);
7320
7381
  /* harmony import */ var _utils_geo__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(56);
7321
- /* harmony import */ var _ResourceProxy__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(14);
7382
+ /* harmony import */ var _ResourceProxy__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(15);
7322
7383
  /* harmony import */ var _utils_helpers__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(0);
7323
7384
  /*
7324
7385
  * BSD 3-Clause License
@@ -7490,7 +7551,7 @@ __webpack_require__.r(__webpack_exports__);
7490
7551
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return JobResult; });
7491
7552
  /* harmony import */ var _base_DownloadedResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23);
7492
7553
  /* harmony import */ var _base_ResourceBase__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6);
7493
- /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3);
7554
+ /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4);
7494
7555
  /* harmony import */ var _utils_requests__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5);
7495
7556
  /* harmony import */ var _enums__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8);
7496
7557
  /* harmony import */ var _utils_helpers__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(0);
@@ -8000,7 +8061,7 @@ class Color extends Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_2__["mix"]
8000
8061
  "use strict";
8001
8062
  __webpack_require__.r(__webpack_exports__);
8002
8063
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return DimensionSet; });
8003
- /* harmony import */ var _base_CrudSetBase__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16);
8064
+ /* harmony import */ var _base_CrudSetBase__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17);
8004
8065
  /* harmony import */ var _Dimension__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(38);
8005
8066
  /* harmony import */ var _traits_OwnableResource__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9);
8006
8067
  /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1);
@@ -8067,7 +8128,7 @@ class DimensionSet extends Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_3__
8067
8128
  "use strict";
8068
8129
  __webpack_require__.r(__webpack_exports__);
8069
8130
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return Dimension; });
8070
- /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17);
8131
+ /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(14);
8071
8132
  /*
8072
8133
  * BSD 3-Clause License
8073
8134
  *
@@ -8177,7 +8238,7 @@ __webpack_require__.r(__webpack_exports__);
8177
8238
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return FontFamily; });
8178
8239
  /* harmony import */ var _traits_OwnableResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9);
8179
8240
  /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
8180
- /* harmony import */ var _base_CrudSetBase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(16);
8241
+ /* harmony import */ var _base_CrudSetBase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17);
8181
8242
  /* harmony import */ var _Font__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(41);
8182
8243
  /*
8183
8244
  * BSD 3-Clause License
@@ -8242,7 +8303,7 @@ class FontFamily extends Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_1__["
8242
8303
  "use strict";
8243
8304
  __webpack_require__.r(__webpack_exports__);
8244
8305
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return Font; });
8245
- /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17);
8306
+ /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(14);
8246
8307
  /*
8247
8308
  * BSD 3-Clause License
8248
8309
  *
@@ -8293,12 +8354,12 @@ class Font extends _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_0__["default"]
8293
8354
  "use strict";
8294
8355
  __webpack_require__.r(__webpack_exports__);
8295
8356
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return Job; });
8296
- /* harmony import */ var _proxy_ResourceProxy__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(14);
8357
+ /* harmony import */ var _proxy_ResourceProxy__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(15);
8297
8358
  /* harmony import */ var _base_DownloadedResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(23);
8298
8359
  /* harmony import */ var _base_CrudBase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);
8299
8360
  /* harmony import */ var _JobResult__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(33);
8300
8361
  /* harmony import */ var _JobRevision__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(63);
8301
- /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(3);
8362
+ /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(4);
8302
8363
  /* harmony import */ var _utils_requests__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5);
8303
8364
  /* harmony import */ var _enums__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(8);
8304
8365
  /* harmony import */ var _utils_helpers__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(0);
@@ -8555,7 +8616,7 @@ __webpack_require__.r(__webpack_exports__);
8555
8616
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return Mapstyle; });
8556
8617
  /* harmony import */ var _traits_HandlesImages__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(71);
8557
8618
  /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
8558
- /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17);
8619
+ /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(14);
8559
8620
  /*
8560
8621
  * BSD 3-Clause License
8561
8622
  *
@@ -8610,7 +8671,7 @@ class Mapstyle extends Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_1__["mi
8610
8671
  __webpack_require__.r(__webpack_exports__);
8611
8672
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return SvgSet; });
8612
8673
  /* harmony import */ var _traits_OwnableResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9);
8613
- /* harmony import */ var _base_CrudSetBase__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(16);
8674
+ /* harmony import */ var _base_CrudSetBase__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(17);
8614
8675
  /* harmony import */ var _Svg__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(46);
8615
8676
  /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1);
8616
8677
  /*
@@ -8676,7 +8737,7 @@ class SvgSet extends Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_3__["mix"
8676
8737
  "use strict";
8677
8738
  __webpack_require__.r(__webpack_exports__);
8678
8739
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return Svg; });
8679
- /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(17);
8740
+ /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(14);
8680
8741
  /*
8681
8742
  * BSD 3-Clause License
8682
8743
  *
@@ -8725,7 +8786,7 @@ __webpack_require__.r(__webpack_exports__);
8725
8786
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return Tag; });
8726
8787
  /* harmony import */ var _traits_OwnableResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9);
8727
8788
  /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
8728
- /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17);
8789
+ /* harmony import */ var _base_CrudSetItemBase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(14);
8729
8790
  /*
8730
8791
  * BSD 3-Clause License
8731
8792
  *
@@ -8785,7 +8846,7 @@ class Tag extends Object(_utils_reflection__WEBPACK_IMPORTED_MODULE_1__["mix"])(
8785
8846
  __webpack_require__.r(__webpack_exports__);
8786
8847
  /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "default", function() { return User; });
8787
8848
  /* harmony import */ var _proxy_OwnedResourceProxy__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(12);
8788
- /* harmony import */ var _proxy_ResourceProxy__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(14);
8849
+ /* harmony import */ var _proxy_ResourceProxy__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(15);
8789
8850
  /* harmony import */ var _base_CrudBase__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);
8790
8851
  /* harmony import */ var _Color__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(36);
8791
8852
  /* harmony import */ var _Dimension__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(38);
@@ -9148,16 +9209,16 @@ var OwnableResource = __webpack_require__(9);
9148
9209
  var reflection = __webpack_require__(1);
9149
9210
 
9150
9211
  // EXTERNAL MODULE: ./src/resources/base/CrudSetBase.js
9151
- var CrudSetBase = __webpack_require__(16);
9212
+ var CrudSetBase = __webpack_require__(17);
9152
9213
 
9153
9214
  // EXTERNAL MODULE: ./src/resources/Mapstyle.js
9154
9215
  var Mapstyle = __webpack_require__(44);
9155
9216
 
9156
9217
  // EXTERNAL MODULE: ./src/proxy/ResourceProxy.js
9157
- var ResourceProxy = __webpack_require__(14);
9218
+ var ResourceProxy = __webpack_require__(15);
9158
9219
 
9159
9220
  // EXTERNAL MODULE: ./src/resources/base/CrudSetItemBase.js
9160
- var CrudSetItemBase = __webpack_require__(17);
9221
+ var CrudSetItemBase = __webpack_require__(14);
9161
9222
 
9162
9223
  // CONCATENATED MODULE: ./src/resources/MapstyleSetColor.js
9163
9224
  /*
@@ -11158,7 +11219,7 @@ __webpack_require__.r(__webpack_exports__);
11158
11219
  /* harmony import */ var events__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(52);
11159
11220
  /* harmony import */ var events__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(events__WEBPACK_IMPORTED_MODULE_1__);
11160
11221
  /* harmony import */ var _Mapcreator__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(26);
11161
- /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3);
11222
+ /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4);
11162
11223
  /* harmony import */ var _resources_base_ResourceBase__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6);
11163
11224
  /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1);
11164
11225
  /* harmony import */ var _utils_helpers__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(0);
@@ -11836,7 +11897,7 @@ __webpack_require__.r(__webpack_exports__);
11836
11897
  /* harmony import */ var _JobResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(33);
11837
11898
  /* harmony import */ var _JobShare__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(21);
11838
11899
  /* harmony import */ var _Layer__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(22);
11839
- /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(3);
11900
+ /* harmony import */ var _RequestParameters__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(4);
11840
11901
  /* harmony import */ var _utils_requests__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5);
11841
11902
  /* harmony import */ var _enums__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(8);
11842
11903
  /* harmony import */ var _utils_helpers__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(0);
@@ -12267,7 +12328,7 @@ __webpack_require__.r(__webpack_exports__);
12267
12328
  /* harmony import */ var _OwnedResourceProxy__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(12);
12268
12329
  /* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "OwnedResourceProxy", function() { return _OwnedResourceProxy__WEBPACK_IMPORTED_MODULE_2__["default"]; });
12269
12330
 
12270
- /* harmony import */ var _ResourceProxy__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(14);
12331
+ /* harmony import */ var _ResourceProxy__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(15);
12271
12332
  /* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "ResourceProxy", function() { return _ResourceProxy__WEBPACK_IMPORTED_MODULE_3__["default"]; });
12272
12333
 
12273
12334
  /* harmony import */ var _SimpleResourceProxy__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(18);
@@ -12653,7 +12714,7 @@ class Injectable extends _Trait__WEBPACK_IMPORTED_MODULE_2__["default"] {
12653
12714
  return this._proxyResourceList(value);
12654
12715
  });
12655
12716
  } else {
12656
- const ResourceProxy = __webpack_require__(14).default;
12717
+ const ResourceProxy = __webpack_require__(15).default;
12657
12718
 
12658
12719
  this._inject(name, function () {
12659
12720
  return new ResourceProxy(this, value);
@@ -12690,7 +12751,7 @@ __webpack_require__.r(__webpack_exports__);
12690
12751
  /* harmony import */ var _traits_OwnableResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9);
12691
12752
  /* harmony import */ var _utils_reflection__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
12692
12753
  /* harmony import */ var _Layer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(22);
12693
- /* harmony import */ var _base_CrudSetBase__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(16);
12754
+ /* harmony import */ var _base_CrudSetBase__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(17);
12694
12755
  /* harmony import */ var _proxy__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(67);
12695
12756
  /*
12696
12757
  * BSD 3-Clause License
@@ -12729,7 +12790,7 @@ __webpack_require__.r(__webpack_exports__);
12729
12790
 
12730
12791
 
12731
12792
  /**
12732
- * Layer
12793
+ * LayerGroup
12733
12794
  * @extends CrudBase
12734
12795
  * @mixes OwnableResource
12735
12796
  * @mixes HandlesImages
@@ -13759,7 +13820,7 @@ __webpack_require__.d(__webpack_exports__, "version", function() { return /* bin
13759
13820
  var Mapcreator = __webpack_require__(26);
13760
13821
 
13761
13822
  // EXTERNAL MODULE: ./src/RequestParameters.js
13762
- var RequestParameters = __webpack_require__(3);
13823
+ var RequestParameters = __webpack_require__(4);
13763
13824
 
13764
13825
  // EXTERNAL MODULE: ./src/storage/StorageManager.js + 3 modules
13765
13826
  var StorageManager = __webpack_require__(20);
@@ -13774,7 +13835,7 @@ var enums = __webpack_require__(8);
13774
13835
  var OAuth = __webpack_require__(25);
13775
13836
 
13776
13837
  // EXTERNAL MODULE: ./src/oauth/OAuthToken.js
13777
- var OAuthToken = __webpack_require__(15);
13838
+ var OAuthToken = __webpack_require__(16);
13778
13839
 
13779
13840
  // EXTERNAL MODULE: ./src/oauth/StateContainer.js + 1 modules
13780
13841
  var StateContainer = __webpack_require__(58);
@@ -14325,8 +14386,8 @@ var ValidationError = __webpack_require__(35);
14325
14386
  // EXTERNAL MODULE: ./src/errors/StaticClassError.js
14326
14387
  var StaticClassError = __webpack_require__(34);
14327
14388
 
14328
- // EXTERNAL MODULE: ./src/resources/index.js + 9 modules
14329
- var resources = __webpack_require__(4);
14389
+ // EXTERNAL MODULE: ./src/resources/index.js + 10 modules
14390
+ var resources = __webpack_require__(3);
14330
14391
 
14331
14392
  // EXTERNAL MODULE: ./src/ResourceLister.js
14332
14393
  var ResourceLister = __webpack_require__(59);
@@ -14425,7 +14486,7 @@ var proxy = __webpack_require__(67);
14425
14486
  * @private
14426
14487
  */
14427
14488
 
14428
- const version = "v2.8.0";
14489
+ const version = "v2.9.0";
14429
14490
 
14430
14491
  /***/ })
14431
14492
  /******/ ]);