contentful-management 7.5.4 → 7.6.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.
- package/CHANGELOG.md +3 -3
- package/dist/contentful-management.browser.js +7 -5
- package/dist/contentful-management.browser.js.map +1 -1
- package/dist/contentful-management.browser.min.js +1 -1
- package/dist/contentful-management.legacy.js +7 -5
- package/dist/contentful-management.legacy.js.map +1 -1
- package/dist/contentful-management.legacy.min.js +1 -1
- package/dist/contentful-management.node.js +6 -4
- package/dist/contentful-management.node.js.map +1 -1
- package/dist/contentful-management.node.min.js +1 -1
- package/dist/es-modules/create-cma-http-client.js +1 -1
- package/dist/es-modules/create-contentful-api.js +2 -2
- package/dist/es-modules/plain/endpoints/user.js +4 -2
- package/dist/typings/create-contentful-api.d.ts +5 -1
- package/dist/typings/create-organization-api.d.ts +6 -2
- package/dist/typings/create-space-api.d.ts +6 -2
- package/dist/typings/entities/user.d.ts +6 -2
- package/dist/typings/plain/endpoints/user.d.ts +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
# [7.6.0](https://github.com/contentful/contentful-management.js/compare/v7.5.4...v7.6.0) (2021-02-02)
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
###
|
|
4
|
+
### Features
|
|
5
5
|
|
|
6
|
-
*
|
|
6
|
+
* **getCurrentUser:** allow for query params and type to be passed ([#667](https://github.com/contentful/contentful-management.js/issues/667)) ([e8681f9](https://github.com/contentful/contentful-management.js/commit/e8681f99bcd54b8f34c3f42b32eb78efa02d6a29))
|
|
@@ -4364,7 +4364,7 @@ function createCMAHttpClient(params) {
|
|
|
4364
4364
|
var plainClient = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
4365
4365
|
var sdkMain = plainClient ? 'contentful-management-plain.js' : 'contentful-management.js';
|
|
4366
4366
|
var userAgentHeader = Object(contentful_sdk_core__WEBPACK_IMPORTED_MODULE_1__["getUserAgentHeader"])( // @ts-expect-error
|
|
4367
|
-
"".concat(sdkMain, "/").concat("7.
|
|
4367
|
+
"".concat(sdkMain, "/").concat("7.6.0"), params.application, params.integration, params.feature);
|
|
4368
4368
|
var requiredHeaders = {
|
|
4369
4369
|
'Content-Type': 'application/vnd.contentful.management.v1+json',
|
|
4370
4370
|
'X-Contentful-User-Agent': userAgentHeader
|
|
@@ -4550,8 +4550,8 @@ function createClientApi(_ref) {
|
|
|
4550
4550
|
* .catch(console.error)
|
|
4551
4551
|
* ```
|
|
4552
4552
|
*/
|
|
4553
|
-
getCurrentUser: function getCurrentUser() {
|
|
4554
|
-
return _plain_endpoints__WEBPACK_IMPORTED_MODULE_3__["user"].getCurrent(http).then(function (data) {
|
|
4553
|
+
getCurrentUser: function getCurrentUser(params) {
|
|
4554
|
+
return _plain_endpoints__WEBPACK_IMPORTED_MODULE_3__["user"].getCurrent(http, params).then(function (data) {
|
|
4555
4555
|
return wrapUser(http, data);
|
|
4556
4556
|
});
|
|
4557
4557
|
},
|
|
@@ -12042,8 +12042,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
12042
12042
|
var getForSpace = function getForSpace(http, params) {
|
|
12043
12043
|
return _raw__WEBPACK_IMPORTED_MODULE_0__["get"](http, "/spaces/".concat(params.spaceId, "/users/").concat(params.userId));
|
|
12044
12044
|
};
|
|
12045
|
-
var getCurrent = function getCurrent(http) {
|
|
12046
|
-
return _raw__WEBPACK_IMPORTED_MODULE_0__["get"](http, "/users/me"
|
|
12045
|
+
var getCurrent = function getCurrent(http, params) {
|
|
12046
|
+
return _raw__WEBPACK_IMPORTED_MODULE_0__["get"](http, "/users/me", {
|
|
12047
|
+
params: params === null || params === void 0 ? void 0 : params.query
|
|
12048
|
+
});
|
|
12047
12049
|
};
|
|
12048
12050
|
var getManyForSpace = function getManyForSpace(http, params) {
|
|
12049
12051
|
return _raw__WEBPACK_IMPORTED_MODULE_0__["get"](http, "/spaces/".concat(params.spaceId, "/users"), {
|