contentful 11.2.6 → 11.3.1
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/dist/contentful.browser.js +149 -2
- package/dist/contentful.browser.min.js +1 -1
- package/dist/contentful.cjs +73 -2
- package/dist/esm/contentful.js +1 -1
- package/dist/esm/create-contentful-api.js +73 -1
- package/dist/stats-browser-min.html +1 -1
- package/dist/types/types/client.d.ts +75 -1
- package/dist/types/types/concept-scheme.d.ts +35 -0
- package/dist/types/types/concept.d.ts +59 -0
- package/dist/types/types/index.d.ts +2 -0
- package/dist/types/types/query/order.d.ts +3 -0
- package/dist/types/types/query/query.d.ts +11 -1
- package/package.json +1 -1
|
@@ -8676,6 +8676,9 @@ var contentful = (function (exports) {
|
|
|
8676
8676
|
if (!regExp.test(urn)) {
|
|
8677
8677
|
return undefined;
|
|
8678
8678
|
}
|
|
8679
|
+
|
|
8680
|
+
// eslint-disable-next-line no-unused-vars
|
|
8681
|
+
|
|
8679
8682
|
var _urn$match = urn.match(regExp),
|
|
8680
8683
|
_urn$match2 = _slicedToArray(_urn$match, 4);
|
|
8681
8684
|
_urn$match2[0];
|
|
@@ -9923,14 +9926,154 @@ var contentful = (function (exports) {
|
|
|
9923
9926
|
removeUnresolved: withoutUnresolvableLinks !== null && withoutUnresolvableLinks !== void 0 ? withoutUnresolvableLinks : false
|
|
9924
9927
|
});
|
|
9925
9928
|
}
|
|
9929
|
+
function getConceptScheme(id) {
|
|
9930
|
+
var query = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
9931
|
+
return internalGetConceptScheme(id, query);
|
|
9932
|
+
}
|
|
9933
|
+
function internalGetConceptScheme(_x25) {
|
|
9934
|
+
return _internalGetConceptScheme.apply(this, arguments);
|
|
9935
|
+
}
|
|
9936
|
+
function _internalGetConceptScheme() {
|
|
9937
|
+
_internalGetConceptScheme = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee24(id) {
|
|
9938
|
+
var query,
|
|
9939
|
+
_args24 = arguments;
|
|
9940
|
+
return _regeneratorRuntime.wrap(function _callee24$(_context24) {
|
|
9941
|
+
while (1) switch (_context24.prev = _context24.next) {
|
|
9942
|
+
case 0:
|
|
9943
|
+
query = _args24.length > 1 && _args24[1] !== undefined ? _args24[1] : {};
|
|
9944
|
+
_context24.prev = 1;
|
|
9945
|
+
return _context24.abrupt("return", get({
|
|
9946
|
+
context: 'environment',
|
|
9947
|
+
path: "taxonomy/concept-schemes/".concat(id),
|
|
9948
|
+
config: createRequestConfig({
|
|
9949
|
+
query: normalizeSearchParameters(normalizeSelect(query))
|
|
9950
|
+
})
|
|
9951
|
+
}));
|
|
9952
|
+
case 5:
|
|
9953
|
+
_context24.prev = 5;
|
|
9954
|
+
_context24.t0 = _context24["catch"](1);
|
|
9955
|
+
errorHandler(_context24.t0);
|
|
9956
|
+
case 8:
|
|
9957
|
+
case "end":
|
|
9958
|
+
return _context24.stop();
|
|
9959
|
+
}
|
|
9960
|
+
}, _callee24, null, [[1, 5]]);
|
|
9961
|
+
}));
|
|
9962
|
+
return _internalGetConceptScheme.apply(this, arguments);
|
|
9963
|
+
}
|
|
9964
|
+
function getConceptSchemes() {
|
|
9965
|
+
var query = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
9966
|
+
return internalGetConceptSchemes(query);
|
|
9967
|
+
}
|
|
9968
|
+
function internalGetConceptSchemes() {
|
|
9969
|
+
return _internalGetConceptSchemes.apply(this, arguments);
|
|
9970
|
+
}
|
|
9971
|
+
function _internalGetConceptSchemes() {
|
|
9972
|
+
_internalGetConceptSchemes = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee25() {
|
|
9973
|
+
var query,
|
|
9974
|
+
_args25 = arguments;
|
|
9975
|
+
return _regeneratorRuntime.wrap(function _callee25$(_context25) {
|
|
9976
|
+
while (1) switch (_context25.prev = _context25.next) {
|
|
9977
|
+
case 0:
|
|
9978
|
+
query = _args25.length > 0 && _args25[0] !== undefined ? _args25[0] : {};
|
|
9979
|
+
_context25.prev = 1;
|
|
9980
|
+
return _context25.abrupt("return", get({
|
|
9981
|
+
context: 'environment',
|
|
9982
|
+
path: 'taxonomy/concept-schemes',
|
|
9983
|
+
config: createRequestConfig({
|
|
9984
|
+
query: normalizeSearchParameters(normalizeSelect(query))
|
|
9985
|
+
})
|
|
9986
|
+
}));
|
|
9987
|
+
case 5:
|
|
9988
|
+
_context25.prev = 5;
|
|
9989
|
+
_context25.t0 = _context25["catch"](1);
|
|
9990
|
+
errorHandler(_context25.t0);
|
|
9991
|
+
case 8:
|
|
9992
|
+
case "end":
|
|
9993
|
+
return _context25.stop();
|
|
9994
|
+
}
|
|
9995
|
+
}, _callee25, null, [[1, 5]]);
|
|
9996
|
+
}));
|
|
9997
|
+
return _internalGetConceptSchemes.apply(this, arguments);
|
|
9998
|
+
}
|
|
9999
|
+
function getConcept(id) {
|
|
10000
|
+
var query = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
10001
|
+
return internalGetConcept(id, query);
|
|
10002
|
+
}
|
|
10003
|
+
function internalGetConcept(_x26) {
|
|
10004
|
+
return _internalGetConcept.apply(this, arguments);
|
|
10005
|
+
}
|
|
10006
|
+
function _internalGetConcept() {
|
|
10007
|
+
_internalGetConcept = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee26(id) {
|
|
10008
|
+
var query,
|
|
10009
|
+
_args26 = arguments;
|
|
10010
|
+
return _regeneratorRuntime.wrap(function _callee26$(_context26) {
|
|
10011
|
+
while (1) switch (_context26.prev = _context26.next) {
|
|
10012
|
+
case 0:
|
|
10013
|
+
query = _args26.length > 1 && _args26[1] !== undefined ? _args26[1] : {};
|
|
10014
|
+
_context26.prev = 1;
|
|
10015
|
+
return _context26.abrupt("return", get({
|
|
10016
|
+
context: 'environment',
|
|
10017
|
+
path: "taxonomy/concepts/".concat(id),
|
|
10018
|
+
config: createRequestConfig({
|
|
10019
|
+
query: normalizeSearchParameters(normalizeSelect(query))
|
|
10020
|
+
})
|
|
10021
|
+
}));
|
|
10022
|
+
case 5:
|
|
10023
|
+
_context26.prev = 5;
|
|
10024
|
+
_context26.t0 = _context26["catch"](1);
|
|
10025
|
+
errorHandler(_context26.t0);
|
|
10026
|
+
case 8:
|
|
10027
|
+
case "end":
|
|
10028
|
+
return _context26.stop();
|
|
10029
|
+
}
|
|
10030
|
+
}, _callee26, null, [[1, 5]]);
|
|
10031
|
+
}));
|
|
10032
|
+
return _internalGetConcept.apply(this, arguments);
|
|
10033
|
+
}
|
|
10034
|
+
function getConcepts() {
|
|
10035
|
+
var query = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
10036
|
+
return internalGetConcepts(query);
|
|
10037
|
+
}
|
|
10038
|
+
function internalGetConcepts() {
|
|
10039
|
+
return _internalGetConcepts.apply(this, arguments);
|
|
10040
|
+
}
|
|
9926
10041
|
/*
|
|
9927
10042
|
* Switches BaseURL to use /environments path
|
|
9928
10043
|
* */
|
|
10044
|
+
function _internalGetConcepts() {
|
|
10045
|
+
_internalGetConcepts = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee27() {
|
|
10046
|
+
var query,
|
|
10047
|
+
_args27 = arguments;
|
|
10048
|
+
return _regeneratorRuntime.wrap(function _callee27$(_context27) {
|
|
10049
|
+
while (1) switch (_context27.prev = _context27.next) {
|
|
10050
|
+
case 0:
|
|
10051
|
+
query = _args27.length > 0 && _args27[0] !== undefined ? _args27[0] : {};
|
|
10052
|
+
_context27.prev = 1;
|
|
10053
|
+
return _context27.abrupt("return", get({
|
|
10054
|
+
context: 'environment',
|
|
10055
|
+
path: 'taxonomy/concepts',
|
|
10056
|
+
config: createRequestConfig({
|
|
10057
|
+
query: normalizeSearchParameters(normalizeSelect(query))
|
|
10058
|
+
})
|
|
10059
|
+
}));
|
|
10060
|
+
case 5:
|
|
10061
|
+
_context27.prev = 5;
|
|
10062
|
+
_context27.t0 = _context27["catch"](1);
|
|
10063
|
+
errorHandler(_context27.t0);
|
|
10064
|
+
case 8:
|
|
10065
|
+
case "end":
|
|
10066
|
+
return _context27.stop();
|
|
10067
|
+
}
|
|
10068
|
+
}, _callee27, null, [[1, 5]]);
|
|
10069
|
+
}));
|
|
10070
|
+
return _internalGetConcepts.apply(this, arguments);
|
|
10071
|
+
}
|
|
9929
10072
|
function switchToEnvironment(http) {
|
|
9930
10073
|
http.defaults.baseURL = getGlobalOptions().environmentBaseUrl;
|
|
9931
10074
|
}
|
|
9932
10075
|
return {
|
|
9933
|
-
version: "11.
|
|
10076
|
+
version: "11.3.1",
|
|
9934
10077
|
getSpace: getSpace,
|
|
9935
10078
|
getContentType: getContentType,
|
|
9936
10079
|
getContentTypes: getContentTypes,
|
|
@@ -9943,6 +10086,10 @@ var contentful = (function (exports) {
|
|
|
9943
10086
|
sync: sync,
|
|
9944
10087
|
getEntry: getEntry,
|
|
9945
10088
|
getEntries: getEntries,
|
|
10089
|
+
getConceptScheme: getConceptScheme,
|
|
10090
|
+
getConceptSchemes: getConceptSchemes,
|
|
10091
|
+
getConcept: getConcept,
|
|
10092
|
+
getConcepts: getConcepts,
|
|
9946
10093
|
createAssetKey: createAssetKey
|
|
9947
10094
|
};
|
|
9948
10095
|
}
|
|
@@ -10053,7 +10200,7 @@ var contentful = (function (exports) {
|
|
|
10053
10200
|
environment: 'master'
|
|
10054
10201
|
};
|
|
10055
10202
|
var config = Object.assign(Object.assign({}, defaultConfig), params);
|
|
10056
|
-
var userAgentHeader = getUserAgentHeader("contentful.js/".concat("11.
|
|
10203
|
+
var userAgentHeader = getUserAgentHeader("contentful.js/".concat("11.3.1"), config.application, config.integration);
|
|
10057
10204
|
config.headers = Object.assign(Object.assign({}, config.headers), {
|
|
10058
10205
|
'Content-Type': 'application/vnd.contentful.delivery.v1+json',
|
|
10059
10206
|
'X-Contentful-User-Agent': userAgentHeader
|