@janbox/contentful-marketplace-sdk 1.0.5 → 1.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import { TypeBannerCollectionSkeleton } from '../types';
1
+ import { GraphQLAsset, TypeBannerCollectionSkeleton } from '../types';
2
2
  import { Entry, EntrySys } from 'contentful';
3
3
  import { HyperlinkEntry } from './hyperlink';
4
4
  type BannerCollectionEntry = Entry<TypeBannerCollectionSkeleton, "WITHOUT_UNRESOLVABLE_LINKS", string>;
@@ -11,12 +11,7 @@ export type BannerCollectionGraphQLItem = {
11
11
  hyperlink: ({
12
12
  sys: GraphQLEntrySys;
13
13
  } & Pick<HyperlinkEntry["fields"], "label" | "url" | "target" | "marketHandling">) | null;
14
- media: {
15
- url: string;
16
- width: number | null;
17
- height: number | null;
18
- contentType: string;
19
- };
14
+ media: GraphQLAsset;
20
15
  name: string;
21
16
  }>;
22
17
  };
@@ -1,13 +1,7 @@
1
- import { TypeBlogPostSkeleton } from '../types';
1
+ import { GraphQLAsset, GraphQLAssetLink, TypeBlogPostSkeleton } from '../types';
2
2
  import { Entry, EntrySys } from 'contentful';
3
3
  type BlogPostEntry = Entry<TypeBlogPostSkeleton, "WITHOUT_UNRESOLVABLE_LINKS", string>;
4
4
  type GraphQLEntrySys = Pick<EntrySys, "id" | "createdAt" | "updatedAt">;
5
- type GraphQLAsset = {
6
- url: string;
7
- width: number | null;
8
- height: number | null;
9
- contentType: string;
10
- };
11
5
  type GraphQLSeo = {
12
6
  metaTitle: string;
13
7
  metaDescription: string | null;
@@ -30,6 +24,11 @@ export interface BlogPostDetailGraphQLItem extends BlogPostGraphQLItem {
30
24
  } | null;
31
25
  content: {
32
26
  json: BlogPostEntry["fields"]["content"];
27
+ links: {
28
+ assets: {
29
+ block: GraphQLAssetLink[];
30
+ };
31
+ };
33
32
  };
34
33
  seo: GraphQLSeo | null;
35
34
  }
@@ -1,5 +1,6 @@
1
- import { TypeBrandCollectionSkeleton, TypeBrandSkeleton } from '../types';
1
+ import { GraphQLAsset, TypeBrandCollectionSkeleton, TypeBrandSkeleton } from '../types';
2
2
  import { Entry, EntrySys } from 'contentful';
3
+ import { HyperlinkEntry } from './hyperlink';
3
4
  type BrandEntry = Entry<TypeBrandSkeleton, "WITHOUT_UNRESOLVABLE_LINKS", string>;
4
5
  type BrandCollectionEntry = Entry<TypeBrandCollectionSkeleton, "WITHOUT_UNRESOLVABLE_LINKS", string>;
5
6
  type GraphQLEntrySys = Pick<EntrySys, "id">;
@@ -8,7 +9,11 @@ export type BrandCollectionGraphQLItem = {
8
9
  brandsCollection: {
9
10
  items: Array<{
10
11
  sys: GraphQLEntrySys;
11
- } & Pick<BrandEntry["fields"], "name" | "slug">>;
12
+ logo: GraphQLAsset | null;
13
+ hyperlink: ({
14
+ sys: GraphQLEntrySys;
15
+ } & Pick<HyperlinkEntry["fields"], "label" | "url" | "target" | "marketHandling">) | null;
16
+ } & Pick<BrandEntry["fields"], "name">>;
12
17
  };
13
18
  } & Pick<BrandCollectionEntry["fields"], "name" | "slot">;
14
19
  export type GetBrandCollectionsResponse = {
@@ -1,14 +1,8 @@
1
- import { TypeDocumentationArticleSkeleton, TypeDocumentationCategorySkeleton } from '../types';
1
+ import { GraphQLAsset, GraphQLAssetLink, TypeDocumentationArticleSkeleton, TypeDocumentationCategorySkeleton } from '../types';
2
2
  import { Entry, EntrySys } from 'contentful';
3
3
  export type DocCategoryEntry = Entry<TypeDocumentationCategorySkeleton, "WITHOUT_UNRESOLVABLE_LINKS", string>;
4
4
  export type DocArticleEntry = Entry<TypeDocumentationArticleSkeleton, "WITHOUT_UNRESOLVABLE_LINKS", string>;
5
5
  type GraphQLEntrySys = Pick<EntrySys, "id" | "createdAt" | "updatedAt">;
6
- type GraphQLAsset = {
7
- url: string | null;
8
- width: number | null;
9
- height: number | null;
10
- contentType: string | null;
11
- };
12
6
  type GraphQLSeo = {
13
7
  metaTitle: string;
14
8
  metaDescription: string | null;
@@ -31,6 +25,11 @@ export type DocArticleGraphQLItem = {
31
25
  export interface DocArticleDetailGraphQLItem extends DocArticleGraphQLItem {
32
26
  content: {
33
27
  json: DocArticleEntry["fields"]["content"];
28
+ links: {
29
+ assets: {
30
+ block: GraphQLAssetLink[];
31
+ };
32
+ };
34
33
  };
35
34
  seo: GraphQLSeo | null;
36
35
  }
package/dist/index.cjs CHANGED
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var we=Function.prototype.toString,C=Object.create,Se=Object.prototype.toString,Ce=(function(){function e(){this._keys=[],this._values=[]}return e.prototype.has=function(t){return!!~this._keys.indexOf(t)},e.prototype.get=function(t){return this._values[this._keys.indexOf(t)]},e.prototype.set=function(t,r){this._keys.push(t),this._values.push(r)},e})();function Oe(){return new Ce}function Ae(){return new WeakMap}var je=typeof WeakMap<"u"?Ae:Oe;function B(e){if(!e)return C(null);var t=e.constructor;if(t===Object)return e===Object.prototype?{}:C(e);if(t&&~we.call(t).indexOf("[native code]"))try{return new t}catch{}return C(e)}function ke(e){var t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}function Te(e){return e.flags}var _e=/test/g.flags==="g"?Te:ke;function ae(e){var t=Se.call(e);return t.substring(8,t.length-1)}function qe(e){return e[Symbol.toStringTag]||ae(e)}var Pe=typeof Symbol<"u"?qe:ae,xe=Object.defineProperty,De=Object.getOwnPropertyDescriptor,se=Object.getOwnPropertyNames,N=Object.getOwnPropertySymbols,ce=Object.prototype,le=ce.hasOwnProperty,Re=ce.propertyIsEnumerable,ue=typeof N=="function";function Ie(e){return se(e).concat(N(e))}var Me=ue?Ie:se;function S(e,t,r){for(var s=Me(e),a=0,o=s.length,n=void 0,i=void 0;a<o;++a)if(n=s[a],!(n==="callee"||n==="caller")){if(i=De(e,n),!i){t[n]=r.copier(e[n],r);continue}!i.get&&!i.set&&(i.value=r.copier(i.value,r));try{xe(t,n,i)}catch{t[n]=i.value}}return t}function ze(e,t){var r=new t.Constructor;t.cache.set(e,r);for(var s=0,a=e.length;s<a;++s)r[s]=t.copier(e[s],t);return r}function Ee(e,t){var r=new t.Constructor;return t.cache.set(e,r),S(e,r,t)}function ge(e,t){return e.slice(0)}function Le(e,t){return e.slice(0,e.size,e.type)}function Be(e,t){return new t.Constructor(ge(e.buffer))}function Ne(e,t){return new t.Constructor(e.getTime())}function fe(e,t){var r=new t.Constructor;return t.cache.set(e,r),e.forEach(function(s,a){r.set(a,t.copier(s,t))}),r}function Ve(e,t){return S(e,fe(e,t),t)}function Qe(e,t){var r=B(t.prototype);t.cache.set(e,r);for(var s in e)le.call(e,s)&&(r[s]=t.copier(e[s],t));return r}function Fe(e,t){var r=B(t.prototype);t.cache.set(e,r);for(var s in e)le.call(e,s)&&(r[s]=t.copier(e[s],t));for(var a=N(e),o=0,n=a.length,i=void 0;o<n;++o)i=a[o],Re.call(e,i)&&(r[i]=t.copier(e[i],t));return r}var Ge=ue?Fe:Qe;function Ue(e,t){var r=B(t.prototype);return t.cache.set(e,r),S(e,r,t)}function O(e,t){return new t.Constructor(e.valueOf())}function Ke(e,t){var r=new t.Constructor(e.source,_e(e));return r.lastIndex=e.lastIndex,r}function w(e,t){return e}function pe(e,t){var r=new t.Constructor;return t.cache.set(e,r),e.forEach(function(s){r.add(t.copier(s,t))}),r}function We(e,t){return S(e,pe(e,t),t)}var Je=Array.isArray,V=Object.assign,He=Object.getPrototypeOf||(function(e){return e.__proto__}),he={array:ze,arrayBuffer:ge,blob:Le,dataView:Be,date:Ne,error:w,map:fe,object:Ge,regExp:Ke,set:pe},Ye=V({},he,{array:Ee,map:Ve,object:Ue,set:We});function Xe(e){return{Arguments:e.object,Array:e.array,ArrayBuffer:e.arrayBuffer,Blob:e.blob,Boolean:O,DataView:e.dataView,Date:e.date,Error:e.error,Float32Array:e.arrayBuffer,Float64Array:e.arrayBuffer,Int8Array:e.arrayBuffer,Int16Array:e.arrayBuffer,Int32Array:e.arrayBuffer,Map:e.map,Number:O,Object:e.object,Promise:w,RegExp:e.regExp,Set:e.set,String:O,WeakMap:w,WeakSet:w,Uint8Array:e.arrayBuffer,Uint8ClampedArray:e.arrayBuffer,Uint16Array:e.arrayBuffer,Uint32Array:e.arrayBuffer,Uint64Array:e.arrayBuffer}}function ye(e){var t=V({},he,e),r=Xe(t),s=r.Array,a=r.Object;function o(n,i){if(i.prototype=i.Constructor=void 0,!n||typeof n!="object")return n;if(i.cache.has(n))return i.cache.get(n);if(i.prototype=He(n),i.Constructor=i.prototype&&i.prototype.constructor,!i.Constructor||i.Constructor===Object)return a(n,i);if(Je(n))return s(n,i);var c=r[Pe(n)];return c?c(n,i):typeof n.then=="function"?n:a(n,i)}return function(i){return o(i,{Constructor:void 0,cache:je(),copier:o,prototype:void 0})}}function Ze(e){return ye(V({},Ye,e))}Ze({});ye({});var v=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},A={exports:{}},F;function et(){if(F)return A.exports;F=1;var e=A.exports={},t,r;function s(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?t=setTimeout:t=s}catch{t=s}try{typeof clearTimeout=="function"?r=clearTimeout:r=a}catch{r=a}})();function o(p){if(t===setTimeout)return setTimeout(p,0);if((t===s||!t)&&setTimeout)return t=setTimeout,setTimeout(p,0);try{return t(p,0)}catch{try{return t.call(null,p,0)}catch{return t.call(this,p,0)}}}function n(p){if(r===clearTimeout)return clearTimeout(p);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(p);try{return r(p)}catch{try{return r.call(null,p)}catch{return r.call(this,p)}}}var i=[],c=!1,l,u=-1;function g(){!c||!l||(c=!1,l.length?i=l.concat(i):u=-1,i.length&&f())}function f(){if(!c){var p=o(g);c=!0;for(var d=i.length;d;){for(l=i,i=[];++u<d;)l&&l[u].run();u=-1,d=i.length}l=null,c=!1,n(p)}}e.nextTick=function(p){var d=new Array(arguments.length-1);if(arguments.length>1)for(var b=1;b<arguments.length;b++)d[b-1]=arguments[b];i.push(new y(p,d)),i.length===1&&!c&&o(f)};function y(p,d){this.fun=p,this.array=d}y.prototype.run=function(){this.fun.apply(null,this.array)},e.title="browser",e.browser=!0,e.env={},e.argv=[],e.version="",e.versions={};function h(){}return e.on=h,e.addListener=h,e.once=h,e.off=h,e.removeListener=h,e.removeAllListeners=h,e.emit=h,e.prependListener=h,e.prependOnceListener=h,e.listeners=function(p){return[]},e.binding=function(p){throw new Error("process.binding is not supported")},e.cwd=function(){return"/"},e.chdir=function(p){throw new Error("process.chdir is not supported")},e.umask=function(){return 0},A.exports}et();var j,G;function tt(){if(G)return j;G=1;var e=typeof v=="object"&&v&&v.Object===Object&&v;return j=e,j}var k,U;function rt(){if(U)return k;U=1;var e=tt(),t=typeof self=="object"&&self&&self.Object===Object&&self,r=e||t||Function("return this")();return k=r,k}var T,K;function me(){if(K)return T;K=1;var e=rt(),t=e.Symbol;return T=t,T}var _,W;function nt(){if(W)return _;W=1;var e=me(),t=Object.prototype,r=t.hasOwnProperty,s=t.toString,a=e?e.toStringTag:void 0;function o(n){var i=r.call(n,a),c=n[a];try{n[a]=void 0;var l=!0}catch{}var u=s.call(n);return l&&(i?n[a]=c:delete n[a]),u}return _=o,_}var q,J;function it(){if(J)return q;J=1;var e=Object.prototype,t=e.toString;function r(s){return t.call(s)}return q=r,q}var P,H;function de(){if(H)return P;H=1;var e=me(),t=nt(),r=it(),s="[object Null]",a="[object Undefined]",o=e?e.toStringTag:void 0;function n(i){return i==null?i===void 0?a:s:o&&o in Object(i)?t(i):r(i)}return P=n,P}var x,Y;function ot(){if(Y)return x;Y=1;var e=Array.isArray;return x=e,x}var D,X;function be(){if(X)return D;X=1;function e(t){return t!=null&&typeof t=="object"}return D=e,D}var R,Z;function at(){if(Z)return R;Z=1;var e=de(),t=ot(),r=be(),s="[object String]";function a(o){return typeof o=="string"||!t(o)&&r(o)&&e(o)==s}return R=a,R}at();var I,ee;function st(){if(ee)return I;ee=1;function e(t,r){return function(s){return t(r(s))}}return I=e,I}var M,te;function ct(){if(te)return M;te=1;var e=st(),t=e(Object.getPrototypeOf,Object);return M=t,M}var z,re;function lt(){if(re)return z;re=1;var e=de(),t=ct(),r=be(),s="[object Object]",a=Function.prototype,o=Object.prototype,n=a.toString,i=o.hasOwnProperty,c=n.call(Object);function l(u){if(!r(u)||e(u)!=s)return!1;var g=t(u);if(g===null)return!0;var f=i.call(g,"constructor")&&g.constructor;return typeof f=="function"&&f instanceof f&&n.call(f)==c}return z=l,z}lt();var ve={0:8203,1:8204,2:8205,3:8290,4:8291,5:8288,6:65279,7:8289,8:119155,9:119156,a:119157,b:119158,c:119159,d:119160,e:119161,f:119162},$e={0:8203,1:8204,2:8205,3:65279};new Array(4).fill(String.fromCodePoint($e[0])).join("");Object.fromEntries(Object.entries($e).map(e=>e.reverse()));Object.fromEntries(Object.entries(ve).map(e=>e.reverse()));`${Object.values(ve).map(e=>`\\u{${e.toString(16)}}`).join("")}`;var E,ne;function ut(){if(ne)return E;ne=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString;return E=function(r,s,a){if(t.call(s)!=="[object Function]")throw new TypeError("iterator must be a function");var o=r.length;if(o===+o)for(var n=0;n<o;n++)s.call(a,r[n],n,r);else for(var i in r)e.call(r,i)&&s.call(a,r[i],i,r)},E}var L,ie;function gt(){if(ie)return L;ie=1;var e=ut();L=t;function t(r,s,a){if(arguments.length===3)return t.set(r,s,a);if(arguments.length===2)return t.get(r,s);var o=t.bind(t,r);for(var n in t)t.hasOwnProperty(n)&&(o[n]=t[n].bind(o,r));return o}return t.get=function(r,s){for(var a=Array.isArray(s)?s:t.parse(s),o=0;o<a.length;++o){var n=a[o];if(!(typeof r=="object"&&n in r))throw new Error("Invalid reference token: "+n);r=r[n]}return r},t.set=function(r,s,a){var o=Array.isArray(s)?s:t.parse(s),n=o[0];if(o.length===0)throw Error("Can not set the root object");for(var i=0;i<o.length-1;++i){var c=o[i];typeof c!="string"&&typeof c!="number"&&(c=String(c)),!(c==="__proto__"||c==="constructor"||c==="prototype")&&(c==="-"&&Array.isArray(r)&&(c=r.length),n=o[i+1],c in r||(n.match(/^(\d+|-)$/)?r[c]=[]:r[c]={}),r=r[c])}return n==="-"&&Array.isArray(r)&&(n=r.length),r[n]=a,this},t.remove=function(r,s){var a=Array.isArray(s)?s:t.parse(s),o=a[a.length-1];if(o===void 0)throw new Error('Invalid JSON pointer for remove: "'+s+'"');var n=t.get(r,a.slice(0,-1));if(Array.isArray(n)){var i=+o;if(o===""&&isNaN(i))throw new Error('Invalid array index: "'+o+'"');Array.prototype.splice.call(n,i,1)}else delete n[o]},t.dict=function(r,s){var a={};return t.walk(r,function(o,n){a[n]=o},s),a},t.walk=function(r,s,a){var o=[];a=a||function(n){var i=Object.prototype.toString.call(n);return i==="[object Object]"||i==="[object Array]"},(function n(i){e(i,function(c,l){o.push(String(l)),a(c)?n(c):s(c,t.compile(o)),o.pop()})})(r)},t.has=function(r,s){try{t.get(r,s)}catch{return!1}return!0},t.escape=function(r){return r.toString().replace(/~/g,"~0").replace(/\//g,"~1")},t.unescape=function(r){return r.replace(/~1/g,"/").replace(/~0/g,"~")},t.parse=function(r){if(r==="")return[];if(r.charAt(0)!=="/")throw new Error("Invalid JSON pointer: "+r);return r.substring(1).split(/\//).map(t.unescape)},t.compile=function(r){return r.length===0?"":"/"+r.map(t.escape).join("/")},L}gt();var $={exports:{}},oe;function ft(){return oe||(oe=1,(function(e,t){t=e.exports=r,t.getSerialize=s;function r(a,o,n,i){return JSON.stringify(a,s(o,i),n)}function s(a,o){var n=[],i=[];return o==null&&(o=function(c,l){return n[0]===l?"[Circular ~]":"[Circular ~."+i.slice(0,n.indexOf(l)).join(".")+"]"}),function(c,l){if(n.length>0){var u=n.indexOf(this);~u?n.splice(u+1):n.push(this),~u?i.splice(u,1/0,c):i.push(c),~n.indexOf(l)&&(l=o.call(this,c,l))}else n.push(l);return a==null?l:a.call(this,c,l)}}})($,$.exports)),$.exports}ft();class m{static _clientParams;static get clientParams(){if(!this._clientParams)throw new Error("Client is not configured");return this._clientParams}static configure(t){this._clientParams={...t,environment:t.environment??"master"}}static async graphqlQuery(t,r={}){const{space:s,accessToken:a,environment:o="master"}=this.clientParams,n=await fetch(`https://graphql.contentful.com/content/v1/spaces/${s}/environments/${o}`,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${a}`},body:JSON.stringify({query:t,variables:r})});if(!n.ok){const c=await n.text();throw new Error(`GraphQL request failed: ${n.status} ${n.statusText}
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var we=Function.prototype.toString,C=Object.create,Se=Object.prototype.toString,Ce=(function(){function e(){this._keys=[],this._values=[]}return e.prototype.has=function(t){return!!~this._keys.indexOf(t)},e.prototype.get=function(t){return this._values[this._keys.indexOf(t)]},e.prototype.set=function(t,r){this._keys.push(t),this._values.push(r)},e})();function Oe(){return new Ce}function Ae(){return new WeakMap}var ke=typeof WeakMap<"u"?Ae:Oe;function B(e){if(!e)return C(null);var t=e.constructor;if(t===Object)return e===Object.prototype?{}:C(e);if(t&&~we.call(t).indexOf("[native code]"))try{return new t}catch{}return C(e)}function je(e){var t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}function Te(e){return e.flags}var _e=/test/g.flags==="g"?Te:je;function ae(e){var t=Se.call(e);return t.substring(8,t.length-1)}function qe(e){return e[Symbol.toStringTag]||ae(e)}var Pe=typeof Symbol<"u"?qe:ae,xe=Object.defineProperty,De=Object.getOwnPropertyDescriptor,se=Object.getOwnPropertyNames,N=Object.getOwnPropertySymbols,ce=Object.prototype,le=ce.hasOwnProperty,Re=ce.propertyIsEnumerable,ue=typeof N=="function";function Ie(e){return se(e).concat(N(e))}var Me=ue?Ie:se;function S(e,t,r){for(var s=Me(e),a=0,o=s.length,n=void 0,i=void 0;a<o;++a)if(n=s[a],!(n==="callee"||n==="caller")){if(i=De(e,n),!i){t[n]=r.copier(e[n],r);continue}!i.get&&!i.set&&(i.value=r.copier(i.value,r));try{xe(t,n,i)}catch{t[n]=i.value}}return t}function ze(e,t){var r=new t.Constructor;t.cache.set(e,r);for(var s=0,a=e.length;s<a;++s)r[s]=t.copier(e[s],t);return r}function Ee(e,t){var r=new t.Constructor;return t.cache.set(e,r),S(e,r,t)}function ge(e,t){return e.slice(0)}function Le(e,t){return e.slice(0,e.size,e.type)}function Be(e,t){return new t.Constructor(ge(e.buffer))}function Ne(e,t){return new t.Constructor(e.getTime())}function fe(e,t){var r=new t.Constructor;return t.cache.set(e,r),e.forEach(function(s,a){r.set(a,t.copier(s,t))}),r}function Ve(e,t){return S(e,fe(e,t),t)}function Qe(e,t){var r=B(t.prototype);t.cache.set(e,r);for(var s in e)le.call(e,s)&&(r[s]=t.copier(e[s],t));return r}function Fe(e,t){var r=B(t.prototype);t.cache.set(e,r);for(var s in e)le.call(e,s)&&(r[s]=t.copier(e[s],t));for(var a=N(e),o=0,n=a.length,i=void 0;o<n;++o)i=a[o],Re.call(e,i)&&(r[i]=t.copier(e[i],t));return r}var Ge=ue?Fe:Qe;function Ue(e,t){var r=B(t.prototype);return t.cache.set(e,r),S(e,r,t)}function O(e,t){return new t.Constructor(e.valueOf())}function Ke(e,t){var r=new t.Constructor(e.source,_e(e));return r.lastIndex=e.lastIndex,r}function w(e,t){return e}function pe(e,t){var r=new t.Constructor;return t.cache.set(e,r),e.forEach(function(s){r.add(t.copier(s,t))}),r}function We(e,t){return S(e,pe(e,t),t)}var He=Array.isArray,V=Object.assign,Je=Object.getPrototypeOf||(function(e){return e.__proto__}),he={array:ze,arrayBuffer:ge,blob:Le,dataView:Be,date:Ne,error:w,map:fe,object:Ge,regExp:Ke,set:pe},Ye=V({},he,{array:Ee,map:Ve,object:Ue,set:We});function Xe(e){return{Arguments:e.object,Array:e.array,ArrayBuffer:e.arrayBuffer,Blob:e.blob,Boolean:O,DataView:e.dataView,Date:e.date,Error:e.error,Float32Array:e.arrayBuffer,Float64Array:e.arrayBuffer,Int8Array:e.arrayBuffer,Int16Array:e.arrayBuffer,Int32Array:e.arrayBuffer,Map:e.map,Number:O,Object:e.object,Promise:w,RegExp:e.regExp,Set:e.set,String:O,WeakMap:w,WeakSet:w,Uint8Array:e.arrayBuffer,Uint8ClampedArray:e.arrayBuffer,Uint16Array:e.arrayBuffer,Uint32Array:e.arrayBuffer,Uint64Array:e.arrayBuffer}}function ye(e){var t=V({},he,e),r=Xe(t),s=r.Array,a=r.Object;function o(n,i){if(i.prototype=i.Constructor=void 0,!n||typeof n!="object")return n;if(i.cache.has(n))return i.cache.get(n);if(i.prototype=Je(n),i.Constructor=i.prototype&&i.prototype.constructor,!i.Constructor||i.Constructor===Object)return a(n,i);if(He(n))return s(n,i);var c=r[Pe(n)];return c?c(n,i):typeof n.then=="function"?n:a(n,i)}return function(i){return o(i,{Constructor:void 0,cache:ke(),copier:o,prototype:void 0})}}function Ze(e){return ye(V({},Ye,e))}Ze({});ye({});var v=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},A={exports:{}},F;function et(){if(F)return A.exports;F=1;var e=A.exports={},t,r;function s(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?t=setTimeout:t=s}catch{t=s}try{typeof clearTimeout=="function"?r=clearTimeout:r=a}catch{r=a}})();function o(p){if(t===setTimeout)return setTimeout(p,0);if((t===s||!t)&&setTimeout)return t=setTimeout,setTimeout(p,0);try{return t(p,0)}catch{try{return t.call(null,p,0)}catch{return t.call(this,p,0)}}}function n(p){if(r===clearTimeout)return clearTimeout(p);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(p);try{return r(p)}catch{try{return r.call(null,p)}catch{return r.call(this,p)}}}var i=[],c=!1,l,u=-1;function g(){!c||!l||(c=!1,l.length?i=l.concat(i):u=-1,i.length&&f())}function f(){if(!c){var p=o(g);c=!0;for(var m=i.length;m;){for(l=i,i=[];++u<m;)l&&l[u].run();u=-1,m=i.length}l=null,c=!1,n(p)}}e.nextTick=function(p){var m=new Array(arguments.length-1);if(arguments.length>1)for(var b=1;b<arguments.length;b++)m[b-1]=arguments[b];i.push(new y(p,m)),i.length===1&&!c&&o(f)};function y(p,m){this.fun=p,this.array=m}y.prototype.run=function(){this.fun.apply(null,this.array)},e.title="browser",e.browser=!0,e.env={},e.argv=[],e.version="",e.versions={};function h(){}return e.on=h,e.addListener=h,e.once=h,e.off=h,e.removeListener=h,e.removeAllListeners=h,e.emit=h,e.prependListener=h,e.prependOnceListener=h,e.listeners=function(p){return[]},e.binding=function(p){throw new Error("process.binding is not supported")},e.cwd=function(){return"/"},e.chdir=function(p){throw new Error("process.chdir is not supported")},e.umask=function(){return 0},A.exports}et();var k,G;function tt(){if(G)return k;G=1;var e=typeof v=="object"&&v&&v.Object===Object&&v;return k=e,k}var j,U;function rt(){if(U)return j;U=1;var e=tt(),t=typeof self=="object"&&self&&self.Object===Object&&self,r=e||t||Function("return this")();return j=r,j}var T,K;function de(){if(K)return T;K=1;var e=rt(),t=e.Symbol;return T=t,T}var _,W;function nt(){if(W)return _;W=1;var e=de(),t=Object.prototype,r=t.hasOwnProperty,s=t.toString,a=e?e.toStringTag:void 0;function o(n){var i=r.call(n,a),c=n[a];try{n[a]=void 0;var l=!0}catch{}var u=s.call(n);return l&&(i?n[a]=c:delete n[a]),u}return _=o,_}var q,H;function it(){if(H)return q;H=1;var e=Object.prototype,t=e.toString;function r(s){return t.call(s)}return q=r,q}var P,J;function me(){if(J)return P;J=1;var e=de(),t=nt(),r=it(),s="[object Null]",a="[object Undefined]",o=e?e.toStringTag:void 0;function n(i){return i==null?i===void 0?a:s:o&&o in Object(i)?t(i):r(i)}return P=n,P}var x,Y;function ot(){if(Y)return x;Y=1;var e=Array.isArray;return x=e,x}var D,X;function be(){if(X)return D;X=1;function e(t){return t!=null&&typeof t=="object"}return D=e,D}var R,Z;function at(){if(Z)return R;Z=1;var e=me(),t=ot(),r=be(),s="[object String]";function a(o){return typeof o=="string"||!t(o)&&r(o)&&e(o)==s}return R=a,R}at();var I,ee;function st(){if(ee)return I;ee=1;function e(t,r){return function(s){return t(r(s))}}return I=e,I}var M,te;function ct(){if(te)return M;te=1;var e=st(),t=e(Object.getPrototypeOf,Object);return M=t,M}var z,re;function lt(){if(re)return z;re=1;var e=me(),t=ct(),r=be(),s="[object Object]",a=Function.prototype,o=Object.prototype,n=a.toString,i=o.hasOwnProperty,c=n.call(Object);function l(u){if(!r(u)||e(u)!=s)return!1;var g=t(u);if(g===null)return!0;var f=i.call(g,"constructor")&&g.constructor;return typeof f=="function"&&f instanceof f&&n.call(f)==c}return z=l,z}lt();var ve={0:8203,1:8204,2:8205,3:8290,4:8291,5:8288,6:65279,7:8289,8:119155,9:119156,a:119157,b:119158,c:119159,d:119160,e:119161,f:119162},$e={0:8203,1:8204,2:8205,3:65279};new Array(4).fill(String.fromCodePoint($e[0])).join("");Object.fromEntries(Object.entries($e).map(e=>e.reverse()));Object.fromEntries(Object.entries(ve).map(e=>e.reverse()));`${Object.values(ve).map(e=>`\\u{${e.toString(16)}}`).join("")}`;var E,ne;function ut(){if(ne)return E;ne=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString;return E=function(r,s,a){if(t.call(s)!=="[object Function]")throw new TypeError("iterator must be a function");var o=r.length;if(o===+o)for(var n=0;n<o;n++)s.call(a,r[n],n,r);else for(var i in r)e.call(r,i)&&s.call(a,r[i],i,r)},E}var L,ie;function gt(){if(ie)return L;ie=1;var e=ut();L=t;function t(r,s,a){if(arguments.length===3)return t.set(r,s,a);if(arguments.length===2)return t.get(r,s);var o=t.bind(t,r);for(var n in t)t.hasOwnProperty(n)&&(o[n]=t[n].bind(o,r));return o}return t.get=function(r,s){for(var a=Array.isArray(s)?s:t.parse(s),o=0;o<a.length;++o){var n=a[o];if(!(typeof r=="object"&&n in r))throw new Error("Invalid reference token: "+n);r=r[n]}return r},t.set=function(r,s,a){var o=Array.isArray(s)?s:t.parse(s),n=o[0];if(o.length===0)throw Error("Can not set the root object");for(var i=0;i<o.length-1;++i){var c=o[i];typeof c!="string"&&typeof c!="number"&&(c=String(c)),!(c==="__proto__"||c==="constructor"||c==="prototype")&&(c==="-"&&Array.isArray(r)&&(c=r.length),n=o[i+1],c in r||(n.match(/^(\d+|-)$/)?r[c]=[]:r[c]={}),r=r[c])}return n==="-"&&Array.isArray(r)&&(n=r.length),r[n]=a,this},t.remove=function(r,s){var a=Array.isArray(s)?s:t.parse(s),o=a[a.length-1];if(o===void 0)throw new Error('Invalid JSON pointer for remove: "'+s+'"');var n=t.get(r,a.slice(0,-1));if(Array.isArray(n)){var i=+o;if(o===""&&isNaN(i))throw new Error('Invalid array index: "'+o+'"');Array.prototype.splice.call(n,i,1)}else delete n[o]},t.dict=function(r,s){var a={};return t.walk(r,function(o,n){a[n]=o},s),a},t.walk=function(r,s,a){var o=[];a=a||function(n){var i=Object.prototype.toString.call(n);return i==="[object Object]"||i==="[object Array]"},(function n(i){e(i,function(c,l){o.push(String(l)),a(c)?n(c):s(c,t.compile(o)),o.pop()})})(r)},t.has=function(r,s){try{t.get(r,s)}catch{return!1}return!0},t.escape=function(r){return r.toString().replace(/~/g,"~0").replace(/\//g,"~1")},t.unescape=function(r){return r.replace(/~1/g,"/").replace(/~0/g,"~")},t.parse=function(r){if(r==="")return[];if(r.charAt(0)!=="/")throw new Error("Invalid JSON pointer: "+r);return r.substring(1).split(/\//).map(t.unescape)},t.compile=function(r){return r.length===0?"":"/"+r.map(t.escape).join("/")},L}gt();var $={exports:{}},oe;function ft(){return oe||(oe=1,(function(e,t){t=e.exports=r,t.getSerialize=s;function r(a,o,n,i){return JSON.stringify(a,s(o,i),n)}function s(a,o){var n=[],i=[];return o==null&&(o=function(c,l){return n[0]===l?"[Circular ~]":"[Circular ~."+i.slice(0,n.indexOf(l)).join(".")+"]"}),function(c,l){if(n.length>0){var u=n.indexOf(this);~u?n.splice(u+1):n.push(this),~u?i.splice(u,1/0,c):i.push(c),~n.indexOf(l)&&(l=o.call(this,c,l))}else n.push(l);return a==null?l:a.call(this,c,l)}}})($,$.exports)),$.exports}ft();class d{static _clientParams;static get clientParams(){if(!this._clientParams)throw new Error("Client is not configured");return this._clientParams}static configure(t){this._clientParams={...t,environment:t.environment??"master"}}static async graphqlQuery(t,r={}){const{space:s,accessToken:a,environment:o="master"}=this.clientParams,n=await fetch(`https://graphql.contentful.com/content/v1/spaces/${s}/environments/${o}`,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${a}`},body:JSON.stringify({query:t,variables:r})});if(!n.ok){const c=await n.text();throw new Error(`GraphQL request failed: ${n.status} ${n.statusText}
2
2
  ${c}`)}const i=await n.json();if(i.errors)throw new Error(`GraphQL errors: ${JSON.stringify(i.errors,null,2)}`);return i.data}}const pt=async({slot:e,page:t=1,size:r=20,platform:s,marketCode:a,language:o})=>{const n=Math.max(1,Math.floor(t)),i=Math.max(1,Math.floor(r)),c=["$slot: String!","$limit: Int!","$skip: Int!"],l={slot:e,limit:i,skip:(n-1)*i},u=["{ slot: $slot }"];s&&(c.push("$platform: String!"),l.platform=s,u.push("{ platform_contains_some: [$platform] }")),a&&(c.push("$marketCode: String!"),l.marketCode=a,u.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),o&&(c.push("$language: String!"),l.language=o,u.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const g=`(${c.join(", ")})`,f=`(
3
3
  limit: $limit
4
4
  skip: $skip
@@ -45,7 +45,7 @@ query${g} {
45
45
  }
46
46
  }
47
47
  }
48
- `,{bannerCollectionCollection:h}=await m.graphqlQuery(y,{...l});return{page:n,total:h.total,size:i,items:h.items}};class Q extends Response{constructor(...t){super(t[0]??"Not Found",{status:404,...t[1]})}}const ht=async({marketCode:e,language:t,page:r=1,size:s=20}={})=>{const a=Math.max(1,Math.floor(r)),o=Math.max(1,Math.floor(s)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=["limit: $limit","skip: $skip"],l=[];e&&(n.push("$marketCode: String!"),i.marketCode=e,l.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),t&&(n.push("$language: String!"),i.language=t,l.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }")),l.length&&c.push(`where: {
48
+ `,{bannerCollectionCollection:h}=await d.graphqlQuery(y,{...l});return{page:n,total:h.total,size:i,items:h.items}};class Q extends Response{constructor(...t){super(t[0]??"Not Found",{status:404,...t[1]})}}const ht=async({marketCode:e,language:t,page:r=1,size:s=20}={})=>{const a=Math.max(1,Math.floor(r)),o=Math.max(1,Math.floor(s)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=["limit: $limit","skip: $skip"],l=[];e&&(n.push("$marketCode: String!"),i.marketCode=e,l.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),t&&(n.push("$language: String!"),i.language=t,l.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }")),l.length&&c.push(`where: {
49
49
  AND: [
50
50
  ${l.join(`
51
51
  `)}
@@ -79,7 +79,7 @@ query${u} {
79
79
  }
80
80
  }
81
81
  }
82
- `,{blogPostCollection:y}=await m.graphqlQuery(f,{...i});return{page:a,total:y.total,size:o,items:y.items}},yt=async({id:e,slug:t,marketCode:r,language:s})=>{const a=[],o={},n=[];if(e)a.push("$id: String!"),o.id=e,n.push("{ sys: { id: $id } }");else if(t)a.push("$slug: String!"),o.slug=t,n.push("{ slug: $slug }");else throw new Error("Either id or slug is required.");r&&(a.push("$marketCode: String!"),o.marketCode=r,n.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(a.push("$language: String!"),o.language=s,n.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const i=`(${a.join(", ")})`,c=`(
82
+ `,{blogPostCollection:y}=await d.graphqlQuery(f,{...i});return{page:a,total:y.total,size:o,items:y.items}},yt=async({id:e,slug:t,marketCode:r,language:s})=>{const a=[],o={},n=[];if(e)a.push("$id: String!"),o.id=e,n.push("{ sys: { id: $id } }");else if(t)a.push("$slug: String!"),o.slug=t,n.push("{ slug: $slug }");else throw new Error("Either id or slug is required.");r&&(a.push("$marketCode: String!"),o.marketCode=r,n.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(a.push("$language: String!"),o.language=s,n.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const i=`(${a.join(", ")})`,c=`(
83
83
  limit: 1
84
84
  where: {
85
85
  AND: [
@@ -120,6 +120,21 @@ query${i} {
120
120
  }
121
121
  content {
122
122
  json
123
+ links {
124
+ assets {
125
+ block {
126
+ sys {
127
+ id
128
+ }
129
+ url
130
+ width
131
+ height
132
+ contentType
133
+ title
134
+ description
135
+ }
136
+ }
137
+ }
123
138
  }
124
139
  seo {
125
140
  metaTitle
@@ -130,7 +145,7 @@ query${i} {
130
145
  }
131
146
  }
132
147
  }
133
- `,{blogPostCollection:u}=await m.graphqlQuery(l,{...o}),g=u.items.at(0);if(!g)throw new Q;return g},mt=async({page:e=1,size:t=20,marketCode:r,language:s}={})=>{const a=Math.max(1,Math.floor(e)),o=Math.max(1,Math.floor(t)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=[];r&&(n.push("$marketCode: String!"),i.marketCode=r,c.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(n.push("$language: String!"),i.language=s,c.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const l=`(${n.join(", ")})`,u=c.length?`(
148
+ `,{blogPostCollection:u}=await d.graphqlQuery(l,{...o}),g=u.items.at(0);if(!g)throw new Q;return g},dt=async({page:e=1,size:t=20,marketCode:r,language:s}={})=>{const a=Math.max(1,Math.floor(e)),o=Math.max(1,Math.floor(t)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=[];r&&(n.push("$marketCode: String!"),i.marketCode=r,c.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(n.push("$language: String!"),i.language=s,c.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const l=`(${n.join(", ")})`,u=c.length?`(
134
149
  limit: $limit
135
150
  skip: $skip
136
151
  where: {
@@ -158,13 +173,27 @@ query${l} {
158
173
  id
159
174
  }
160
175
  name
161
- slug
176
+ logo {
177
+ url
178
+ width
179
+ height
180
+ contentType
181
+ }
182
+ hyperlink {
183
+ sys {
184
+ id
185
+ }
186
+ label
187
+ url
188
+ target
189
+ marketHandling
190
+ }
162
191
  }
163
192
  }
164
193
  }
165
194
  }
166
195
  }
167
- `,{brandCollectionCollection:f}=await m.graphqlQuery(g,{...i});return{page:a,total:f.total,size:o,items:f.items}},dt=async({marketCode:e,language:t,page:r=1,size:s=20}={})=>{const a=Math.max(1,Math.floor(r)),o=Math.max(1,Math.floor(s)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=["limit: $limit","skip: $skip"],l=[];e&&(n.push("$marketCode: String!"),i.marketCode=e,l.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),t&&(n.push("$language: String!"),i.language=t,l.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }")),l.length&&c.push(`where: {
196
+ `,{brandCollectionCollection:f}=await d.graphqlQuery(g,{...i});return{page:a,total:f.total,size:o,items:f.items}},mt=async({marketCode:e,language:t,page:r=1,size:s=20}={})=>{const a=Math.max(1,Math.floor(r)),o=Math.max(1,Math.floor(s)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=["limit: $limit","skip: $skip"],l=[];e&&(n.push("$marketCode: String!"),i.marketCode=e,l.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),t&&(n.push("$language: String!"),i.language=t,l.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }")),l.length&&c.push(`where: {
168
197
  AND: [
169
198
  ${l.join(`
170
199
  `)}
@@ -195,7 +224,7 @@ query${u} {
195
224
  }
196
225
  }
197
226
  }
198
- `,{documentationCategoryCollection:y}=await m.graphqlQuery(f,{...i});return{page:a,total:y.total,size:o,items:y.items}},bt=async({id:e,slug:t,marketCode:r,language:s})=>{const a=[],o={},n=[];if(e)a.push("$id: String!"),o.id=e,n.push("{ sys: { id: $id } }");else if(t)a.push("$slug: String!"),o.slug=t,n.push("{ slug: $slug }");else throw new Error("Either id or slug is required.");r&&(a.push("$marketCode: String!"),o.marketCode=r,n.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(a.push("$language: String!"),o.language=s,n.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const i=`(${a.join(", ")})`,c=`(
227
+ `,{documentationCategoryCollection:y}=await d.graphqlQuery(f,{...i});return{page:a,total:y.total,size:o,items:y.items}},bt=async({id:e,slug:t,marketCode:r,language:s})=>{const a=[],o={},n=[];if(e)a.push("$id: String!"),o.id=e,n.push("{ sys: { id: $id } }");else if(t)a.push("$slug: String!"),o.slug=t,n.push("{ slug: $slug }");else throw new Error("Either id or slug is required.");r&&(a.push("$marketCode: String!"),o.marketCode=r,n.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(a.push("$language: String!"),o.language=s,n.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const i=`(${a.join(", ")})`,c=`(
199
228
  limit: 1
200
229
  where: {
201
230
  AND: [
@@ -225,7 +254,7 @@ query${i} {
225
254
  }
226
255
  }
227
256
  }
228
- `,{documentationCategoryCollection:u}=await m.graphqlQuery(l,{...o}),g=u.items.at(0);if(!g)throw new Q;return g},vt=async({marketCode:e,language:t,categorySlug:r,page:s=1,size:a=20}={})=>{const o=Math.max(1,Math.floor(s)),n=Math.max(1,Math.floor(a)),i=["$limit: Int!","$skip: Int!"],c={limit:n,skip:(o-1)*n},l=["limit: $limit","skip: $skip"],u=[];e&&(i.push("$marketCode: String!"),c.marketCode=e,u.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),t&&(i.push("$language: String!"),c.language=t,u.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }")),r&&(i.push("$categorySlug: String!"),c.categorySlug=r,u.push("{ category: { slug: $categorySlug } }")),u.length&&l.push(`where: {
257
+ `,{documentationCategoryCollection:u}=await d.graphqlQuery(l,{...o}),g=u.items.at(0);if(!g)throw new Q;return g},vt=async({marketCode:e,language:t,categorySlug:r,page:s=1,size:a=20}={})=>{const o=Math.max(1,Math.floor(s)),n=Math.max(1,Math.floor(a)),i=["$limit: Int!","$skip: Int!"],c={limit:n,skip:(o-1)*n},l=["limit: $limit","skip: $skip"],u=[];e&&(i.push("$marketCode: String!"),c.marketCode=e,u.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),t&&(i.push("$language: String!"),c.language=t,u.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }")),r&&(i.push("$categorySlug: String!"),c.categorySlug=r,u.push("{ category: { slug: $categorySlug } }")),u.length&&l.push(`where: {
229
258
  AND: [
230
259
  ${u.join(`
231
260
  `)}
@@ -263,7 +292,7 @@ query${g} {
263
292
  }
264
293
  }
265
294
  }
266
- `,{documentationArticleCollection:h}=await m.graphqlQuery(y,{...c});return{page:o,total:h.total,size:n,items:h.items}},$t=async({id:e,slug:t,marketCode:r,language:s})=>{const a=[],o={},n=[];if(e)a.push("$id: String!"),o.id=e,n.push("{ sys: { id: $id } }");else if(t)a.push("$slug: String!"),o.slug=t,n.push("{ slug: $slug }");else throw new Error("Either id or slug is required.");r&&(a.push("$marketCode: String!"),o.marketCode=r,n.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(a.push("$language: String!"),o.language=s,n.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const i=`(${a.join(", ")})`,c=`(
295
+ `,{documentationArticleCollection:h}=await d.graphqlQuery(y,{...c});return{page:o,total:h.total,size:n,items:h.items}},$t=async({id:e,slug:t,marketCode:r,language:s})=>{const a=[],o={},n=[];if(e)a.push("$id: String!"),o.id=e,n.push("{ sys: { id: $id } }");else if(t)a.push("$slug: String!"),o.slug=t,n.push("{ slug: $slug }");else throw new Error("Either id or slug is required.");r&&(a.push("$marketCode: String!"),o.marketCode=r,n.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(a.push("$language: String!"),o.language=s,n.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const i=`(${a.join(", ")})`,c=`(
267
296
  limit: 1
268
297
  where: {
269
298
  AND: [
@@ -284,6 +313,21 @@ query${i} {
284
313
  slug
285
314
  content {
286
315
  json
316
+ links {
317
+ assets {
318
+ block {
319
+ sys {
320
+ id
321
+ }
322
+ url
323
+ width
324
+ height
325
+ contentType
326
+ title
327
+ description
328
+ }
329
+ }
330
+ }
287
331
  }
288
332
  author {
289
333
  name
@@ -309,7 +353,7 @@ query${i} {
309
353
  }
310
354
  }
311
355
  }
312
- `,{documentationArticleCollection:u}=await m.graphqlQuery(l,{...o}),g=u.items.at(0);if(!g)throw new Q;return g},wt=async({page:e=1,size:t=20,marketCode:r,language:s}={})=>{const a=Math.max(1,Math.floor(e)),o=Math.max(1,Math.floor(t)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=[];r&&(n.push("$marketCode: String!"),i.marketCode=r,c.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(n.push("$language: String!"),i.language=s,c.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const l=n.length?`(${n.join(", ")})`:"",u=c.length?`(
356
+ `,{documentationArticleCollection:u}=await d.graphqlQuery(l,{...o}),g=u.items.at(0);if(!g)throw new Q;return g},wt=async({page:e=1,size:t=20,marketCode:r,language:s}={})=>{const a=Math.max(1,Math.floor(e)),o=Math.max(1,Math.floor(t)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=[];r&&(n.push("$marketCode: String!"),i.marketCode=r,c.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(n.push("$language: String!"),i.language=s,c.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const l=n.length?`(${n.join(", ")})`:"",u=c.length?`(
313
357
  limit: $limit
314
358
  skip: $skip
315
359
  order: order_ASC
@@ -348,7 +392,7 @@ query${l} {
348
392
  }
349
393
  }
350
394
  }
351
- `,{hyperlinkCollectionCollection:f}=await m.graphqlQuery(g,{...i});return{page:a,total:f.total,size:o,items:f.items}},St=async({page:e=1,size:t=20,marketCode:r,language:s}={})=>{const a=Math.max(1,Math.floor(e)),o=Math.max(1,Math.floor(t)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=[];r&&(n.push("$marketCode: String!"),i.marketCode=r,c.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(n.push("$language: String!"),i.language=s,c.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const l=`(${n.join(", ")})`,u=c.length?`(
395
+ `,{hyperlinkCollectionCollection:f}=await d.graphqlQuery(g,{...i});return{page:a,total:f.total,size:o,items:f.items}},St=async({page:e=1,size:t=20,marketCode:r,language:s}={})=>{const a=Math.max(1,Math.floor(e)),o=Math.max(1,Math.floor(t)),n=["$limit: Int!","$skip: Int!"],i={limit:o,skip:(a-1)*o},c=[];r&&(n.push("$marketCode: String!"),i.marketCode=r,c.push("{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }")),s&&(n.push("$language: String!"),i.language=s,c.push("{ OR: [{ language_exists: false }, { language: { code: $language } }] }"));const l=`(${n.join(", ")})`,u=c.length?`(
352
396
  limit: $limit
353
397
  skip: $skip
354
398
  where: {
@@ -374,4 +418,4 @@ query${l} {
374
418
  }
375
419
  }
376
420
  }
377
- `,{keywordCollectionCollection:f}=await m.graphqlQuery(g,{...i});return{page:a,total:f.total,size:o,items:f.items}};exports.ContentfulSDK=m;exports.getBannerCollections=pt;exports.getBlogPostDetail=yt;exports.getBlogPosts=ht;exports.getBrandCollections=mt;exports.getDocArticleDetail=$t;exports.getDocArticles=vt;exports.getDocCategories=dt;exports.getDocCategoryDetail=bt;exports.getHyperlinkCollections=wt;exports.getKeywordCollections=St;
421
+ `,{keywordCollectionCollection:f}=await d.graphqlQuery(g,{...i});return{page:a,total:f.total,size:o,items:f.items}};exports.ContentfulSDK=d;exports.getBannerCollections=pt;exports.getBlogPostDetail=yt;exports.getBlogPosts=ht;exports.getBrandCollections=dt;exports.getDocArticleDetail=$t;exports.getDocArticles=vt;exports.getDocCategories=mt;exports.getDocCategoryDetail=bt;exports.getHyperlinkCollections=wt;exports.getKeywordCollections=St;
package/dist/index.js CHANGED
@@ -19,7 +19,7 @@ function Oe() {
19
19
  function Ae() {
20
20
  return /* @__PURE__ */ new WeakMap();
21
21
  }
22
- var je = typeof WeakMap < "u" ? Ae : Oe;
22
+ var ke = typeof WeakMap < "u" ? Ae : Oe;
23
23
  function N(e) {
24
24
  if (!e)
25
25
  return C(null);
@@ -33,14 +33,14 @@ function N(e) {
33
33
  }
34
34
  return C(e);
35
35
  }
36
- function ke(e) {
36
+ function je(e) {
37
37
  var t = "";
38
38
  return e.global && (t += "g"), e.ignoreCase && (t += "i"), e.multiline && (t += "m"), e.unicode && (t += "u"), e.sticky && (t += "y"), t;
39
39
  }
40
40
  function Te(e) {
41
41
  return e.flags;
42
42
  }
43
- var _e = /test/g.flags === "g" ? Te : ke;
43
+ var _e = /test/g.flags === "g" ? Te : je;
44
44
  function ae(e) {
45
45
  var t = Se.call(e);
46
46
  return t.substring(8, t.length - 1);
@@ -48,11 +48,11 @@ function ae(e) {
48
48
  function qe(e) {
49
49
  return e[Symbol.toStringTag] || ae(e);
50
50
  }
51
- var Pe = typeof Symbol < "u" ? qe : ae, xe = Object.defineProperty, Re = Object.getOwnPropertyDescriptor, se = Object.getOwnPropertyNames, B = Object.getOwnPropertySymbols, ce = Object.prototype, ue = ce.hasOwnProperty, De = ce.propertyIsEnumerable, le = typeof B == "function";
51
+ var Pe = typeof Symbol < "u" ? qe : ae, xe = Object.defineProperty, Re = Object.getOwnPropertyDescriptor, se = Object.getOwnPropertyNames, B = Object.getOwnPropertySymbols, ce = Object.prototype, le = ce.hasOwnProperty, De = ce.propertyIsEnumerable, ue = typeof B == "function";
52
52
  function Ie(e) {
53
53
  return se(e).concat(B(e));
54
54
  }
55
- var Me = le ? Ie : se;
55
+ var Me = ue ? Ie : se;
56
56
  function S(e, t, r) {
57
57
  for (var s = Me(e), a = 0, o = s.length, n = void 0, i = void 0; a < o; ++a)
58
58
  if (n = s[a], !(n === "callee" || n === "caller")) {
@@ -105,19 +105,19 @@ function Qe(e, t) {
105
105
  var r = N(t.prototype);
106
106
  t.cache.set(e, r);
107
107
  for (var s in e)
108
- ue.call(e, s) && (r[s] = t.copier(e[s], t));
108
+ le.call(e, s) && (r[s] = t.copier(e[s], t));
109
109
  return r;
110
110
  }
111
111
  function Fe(e, t) {
112
112
  var r = N(t.prototype);
113
113
  t.cache.set(e, r);
114
114
  for (var s in e)
115
- ue.call(e, s) && (r[s] = t.copier(e[s], t));
115
+ le.call(e, s) && (r[s] = t.copier(e[s], t));
116
116
  for (var a = B(e), o = 0, n = a.length, i = void 0; o < n; ++o)
117
117
  i = a[o], De.call(e, i) && (r[i] = t.copier(e[i], t));
118
118
  return r;
119
119
  }
120
- var Ge = le ? Fe : Qe;
120
+ var Ge = ue ? Fe : Qe;
121
121
  function Ue(e, t) {
122
122
  var r = N(t.prototype);
123
123
  return t.cache.set(e, r), S(e, r, t);
@@ -208,7 +208,7 @@ function ye(e) {
208
208
  return function(i) {
209
209
  return o(i, {
210
210
  Constructor: void 0,
211
- cache: je(),
211
+ cache: ke(),
212
212
  copier: o,
213
213
  prototype: void 0
214
214
  });
@@ -272,31 +272,31 @@ function et() {
272
272
  }
273
273
  }
274
274
  }
275
- var i = [], c = !1, u, l = -1;
275
+ var i = [], c = !1, l, u = -1;
276
276
  function g() {
277
- !c || !u || (c = !1, u.length ? i = u.concat(i) : l = -1, i.length && f());
277
+ !c || !l || (c = !1, l.length ? i = l.concat(i) : u = -1, i.length && f());
278
278
  }
279
279
  function f() {
280
280
  if (!c) {
281
281
  var p = o(g);
282
282
  c = !0;
283
- for (var m = i.length; m; ) {
284
- for (u = i, i = []; ++l < m; )
285
- u && u[l].run();
286
- l = -1, m = i.length;
283
+ for (var d = i.length; d; ) {
284
+ for (l = i, i = []; ++u < d; )
285
+ l && l[u].run();
286
+ u = -1, d = i.length;
287
287
  }
288
- u = null, c = !1, n(p);
288
+ l = null, c = !1, n(p);
289
289
  }
290
290
  }
291
291
  e.nextTick = function(p) {
292
- var m = new Array(arguments.length - 1);
292
+ var d = new Array(arguments.length - 1);
293
293
  if (arguments.length > 1)
294
294
  for (var b = 1; b < arguments.length; b++)
295
- m[b - 1] = arguments[b];
296
- i.push(new y(p, m)), i.length === 1 && !c && o(f);
295
+ d[b - 1] = arguments[b];
296
+ i.push(new y(p, d)), i.length === 1 && !c && o(f);
297
297
  };
298
- function y(p, m) {
299
- this.fun = p, this.array = m;
298
+ function y(p, d) {
299
+ this.fun = p, this.array = d;
300
300
  }
301
301
  y.prototype.run = function() {
302
302
  this.fun.apply(null, this.array);
@@ -316,22 +316,22 @@ function et() {
316
316
  }, A.exports;
317
317
  }
318
318
  et();
319
- var j, G;
319
+ var k, G;
320
320
  function tt() {
321
- if (G) return j;
321
+ if (G) return k;
322
322
  G = 1;
323
323
  var e = typeof v == "object" && v && v.Object === Object && v;
324
- return j = e, j;
324
+ return k = e, k;
325
325
  }
326
- var k, U;
326
+ var j, U;
327
327
  function rt() {
328
- if (U) return k;
328
+ if (U) return j;
329
329
  U = 1;
330
330
  var e = tt(), t = typeof self == "object" && self && self.Object === Object && self, r = e || t || Function("return this")();
331
- return k = r, k;
331
+ return j = r, j;
332
332
  }
333
333
  var T, K;
334
- function me() {
334
+ function de() {
335
335
  if (K) return T;
336
336
  K = 1;
337
337
  var e = rt(), t = e.Symbol;
@@ -341,16 +341,16 @@ var _, W;
341
341
  function nt() {
342
342
  if (W) return _;
343
343
  W = 1;
344
- var e = me(), t = Object.prototype, r = t.hasOwnProperty, s = t.toString, a = e ? e.toStringTag : void 0;
344
+ var e = de(), t = Object.prototype, r = t.hasOwnProperty, s = t.toString, a = e ? e.toStringTag : void 0;
345
345
  function o(n) {
346
346
  var i = r.call(n, a), c = n[a];
347
347
  try {
348
348
  n[a] = void 0;
349
- var u = !0;
349
+ var l = !0;
350
350
  } catch {
351
351
  }
352
- var l = s.call(n);
353
- return u && (i ? n[a] = c : delete n[a]), l;
352
+ var u = s.call(n);
353
+ return l && (i ? n[a] = c : delete n[a]), u;
354
354
  }
355
355
  return _ = o, _;
356
356
  }
@@ -365,10 +365,10 @@ function it() {
365
365
  return q = r, q;
366
366
  }
367
367
  var P, H;
368
- function de() {
368
+ function me() {
369
369
  if (H) return P;
370
370
  H = 1;
371
- var e = me(), t = nt(), r = it(), s = "[object Null]", a = "[object Undefined]", o = e ? e.toStringTag : void 0;
371
+ var e = de(), t = nt(), r = it(), s = "[object Null]", a = "[object Undefined]", o = e ? e.toStringTag : void 0;
372
372
  function n(i) {
373
373
  return i == null ? i === void 0 ? a : s : o && o in Object(i) ? t(i) : r(i);
374
374
  }
@@ -394,7 +394,7 @@ var D, Z;
394
394
  function at() {
395
395
  if (Z) return D;
396
396
  Z = 1;
397
- var e = de(), t = ot(), r = be(), s = "[object String]";
397
+ var e = me(), t = ot(), r = be(), s = "[object String]";
398
398
  function a(o) {
399
399
  return typeof o == "string" || !t(o) && r(o) && e(o) == s;
400
400
  }
@@ -420,29 +420,29 @@ function ct() {
420
420
  return M = t, M;
421
421
  }
422
422
  var z, re;
423
- function ut() {
423
+ function lt() {
424
424
  if (re) return z;
425
425
  re = 1;
426
- var e = de(), t = ct(), r = be(), s = "[object Object]", a = Function.prototype, o = Object.prototype, n = a.toString, i = o.hasOwnProperty, c = n.call(Object);
427
- function u(l) {
428
- if (!r(l) || e(l) != s)
426
+ var e = me(), t = ct(), r = be(), s = "[object Object]", a = Function.prototype, o = Object.prototype, n = a.toString, i = o.hasOwnProperty, c = n.call(Object);
427
+ function l(u) {
428
+ if (!r(u) || e(u) != s)
429
429
  return !1;
430
- var g = t(l);
430
+ var g = t(u);
431
431
  if (g === null)
432
432
  return !0;
433
433
  var f = i.call(g, "constructor") && g.constructor;
434
434
  return typeof f == "function" && f instanceof f && n.call(f) == c;
435
435
  }
436
- return z = u, z;
436
+ return z = l, z;
437
437
  }
438
- ut();
438
+ lt();
439
439
  var ve = { 0: 8203, 1: 8204, 2: 8205, 3: 8290, 4: 8291, 5: 8288, 6: 65279, 7: 8289, 8: 119155, 9: 119156, a: 119157, b: 119158, c: 119159, d: 119160, e: 119161, f: 119162 }, $e = { 0: 8203, 1: 8204, 2: 8205, 3: 65279 };
440
440
  new Array(4).fill(String.fromCodePoint($e[0])).join("");
441
441
  Object.fromEntries(Object.entries($e).map((e) => e.reverse()));
442
442
  Object.fromEntries(Object.entries(ve).map((e) => e.reverse()));
443
443
  `${Object.values(ve).map((e) => `\\u{${e.toString(16)}}`).join("")}`;
444
444
  var E, ne;
445
- function lt() {
445
+ function ut() {
446
446
  if (ne) return E;
447
447
  ne = 1;
448
448
  var e = Object.prototype.hasOwnProperty, t = Object.prototype.toString;
@@ -462,7 +462,7 @@ var L, ie;
462
462
  function gt() {
463
463
  if (ie) return L;
464
464
  ie = 1;
465
- var e = lt();
465
+ var e = ut();
466
466
  L = t;
467
467
  function t(r, s, a) {
468
468
  if (arguments.length === 3)
@@ -514,8 +514,8 @@ function gt() {
514
514
  var i = Object.prototype.toString.call(n);
515
515
  return i === "[object Object]" || i === "[object Array]";
516
516
  }, (function n(i) {
517
- e(i, function(c, u) {
518
- o.push(String(u)), a(c) ? n(c) : s(c, t.compile(o)), o.pop();
517
+ e(i, function(c, l) {
518
+ o.push(String(l)), a(c) ? n(c) : s(c, t.compile(o)), o.pop();
519
519
  });
520
520
  })(r);
521
521
  }, t.has = function(r, s) {
@@ -549,20 +549,20 @@ function ft() {
549
549
  }
550
550
  function s(a, o) {
551
551
  var n = [], i = [];
552
- return o == null && (o = function(c, u) {
553
- return n[0] === u ? "[Circular ~]" : "[Circular ~." + i.slice(0, n.indexOf(u)).join(".") + "]";
554
- }), function(c, u) {
552
+ return o == null && (o = function(c, l) {
553
+ return n[0] === l ? "[Circular ~]" : "[Circular ~." + i.slice(0, n.indexOf(l)).join(".") + "]";
554
+ }), function(c, l) {
555
555
  if (n.length > 0) {
556
- var l = n.indexOf(this);
557
- ~l ? n.splice(l + 1) : n.push(this), ~l ? i.splice(l, 1 / 0, c) : i.push(c), ~n.indexOf(u) && (u = o.call(this, c, u));
558
- } else n.push(u);
559
- return a == null ? u : a.call(this, c, u);
556
+ var u = n.indexOf(this);
557
+ ~u ? n.splice(u + 1) : n.push(this), ~u ? i.splice(u, 1 / 0, c) : i.push(c), ~n.indexOf(l) && (l = o.call(this, c, l));
558
+ } else n.push(l);
559
+ return a == null ? l : a.call(this, c, l);
560
560
  };
561
561
  }
562
562
  })($, $.exports)), $.exports;
563
563
  }
564
564
  ft();
565
- class d {
565
+ class m {
566
566
  static _clientParams;
567
567
  // static getter
568
568
  static get clientParams() {
@@ -615,14 +615,14 @@ const pt = async ({
615
615
  "$slot: String!",
616
616
  "$limit: Int!",
617
617
  "$skip: Int!"
618
- ], u = {
618
+ ], l = {
619
619
  slot: e,
620
620
  limit: i,
621
621
  skip: (n - 1) * i
622
- }, l = ["{ slot: $slot }"];
623
- s && (c.push("$platform: String!"), u.platform = s, l.push("{ platform_contains_some: [$platform] }")), a && (c.push("$marketCode: String!"), u.marketCode = a, l.push(
622
+ }, u = ["{ slot: $slot }"];
623
+ s && (c.push("$platform: String!"), l.platform = s, u.push("{ platform_contains_some: [$platform] }")), a && (c.push("$marketCode: String!"), l.marketCode = a, u.push(
624
624
  "{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }"
625
- )), o && (c.push("$language: String!"), u.language = o, l.push(
625
+ )), o && (c.push("$language: String!"), l.language = o, u.push(
626
626
  "{ OR: [{ language_exists: false }, { language: { code: $language } }] }"
627
627
  ));
628
628
  const g = `(${c.join(", ")})`, f = `(
@@ -630,7 +630,7 @@ const pt = async ({
630
630
  skip: $skip
631
631
  where: {
632
632
  AND: [
633
- ${l.join(`
633
+ ${u.join(`
634
634
  `)}
635
635
  ]
636
636
  }
@@ -671,8 +671,8 @@ query${g} {
671
671
  }
672
672
  }
673
673
  }
674
- `, { bannerCollectionCollection: h } = await d.graphqlQuery(y, {
675
- ...u
674
+ `, { bannerCollectionCollection: h } = await m.graphqlQuery(y, {
675
+ ...l
676
676
  });
677
677
  return {
678
678
  page: n,
@@ -698,22 +698,22 @@ const ht = async ({
698
698
  const a = Math.max(1, Math.floor(r)), o = Math.max(1, Math.floor(s)), n = ["$limit: Int!", "$skip: Int!"], i = {
699
699
  limit: o,
700
700
  skip: (a - 1) * o
701
- }, c = ["limit: $limit", "skip: $skip"], u = [];
702
- e && (n.push("$marketCode: String!"), i.marketCode = e, u.push(
701
+ }, c = ["limit: $limit", "skip: $skip"], l = [];
702
+ e && (n.push("$marketCode: String!"), i.marketCode = e, l.push(
703
703
  "{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }"
704
- )), t && (n.push("$language: String!"), i.language = t, u.push(
704
+ )), t && (n.push("$language: String!"), i.language = t, l.push(
705
705
  "{ OR: [{ language_exists: false }, { language: { code: $language } }] }"
706
- )), u.length && c.push(`where: {
706
+ )), l.length && c.push(`where: {
707
707
  AND: [
708
- ${u.join(`
708
+ ${l.join(`
709
709
  `)}
710
710
  ]
711
711
  }`);
712
- const l = n.length ? `(${n.join(", ")})` : "", g = c.length ? `(
712
+ const u = n.length ? `(${n.join(", ")})` : "", g = c.length ? `(
713
713
  ${c.join(`
714
714
  `)}
715
715
  )` : "", f = `
716
- query${l} {
716
+ query${u} {
717
717
  blogPostCollection${g} {
718
718
  total
719
719
  items {
@@ -738,7 +738,7 @@ query${l} {
738
738
  }
739
739
  }
740
740
  }
741
- `, { blogPostCollection: y } = await d.graphqlQuery(f, {
741
+ `, { blogPostCollection: y } = await m.graphqlQuery(f, {
742
742
  ...i
743
743
  });
744
744
  return {
@@ -773,7 +773,7 @@ query${l} {
773
773
  `)}
774
774
  ]
775
775
  }
776
- )`, u = `
776
+ )`, l = `
777
777
  query${i} {
778
778
  blogPostCollection${c} {
779
779
  items {
@@ -806,6 +806,21 @@ query${i} {
806
806
  }
807
807
  content {
808
808
  json
809
+ links {
810
+ assets {
811
+ block {
812
+ sys {
813
+ id
814
+ }
815
+ url
816
+ width
817
+ height
818
+ contentType
819
+ title
820
+ description
821
+ }
822
+ }
823
+ }
809
824
  }
810
825
  seo {
811
826
  metaTitle
@@ -816,13 +831,13 @@ query${i} {
816
831
  }
817
832
  }
818
833
  }
819
- `, { blogPostCollection: l } = await d.graphqlQuery(u, {
834
+ `, { blogPostCollection: u } = await m.graphqlQuery(l, {
820
835
  ...o
821
- }), g = l.items.at(0);
836
+ }), g = u.items.at(0);
822
837
  if (!g)
823
838
  throw new Q();
824
839
  return g;
825
- }, mt = async ({
840
+ }, dt = async ({
826
841
  page: e = 1,
827
842
  size: t = 20,
828
843
  marketCode: r,
@@ -837,7 +852,7 @@ query${i} {
837
852
  )), s && (n.push("$language: String!"), i.language = s, c.push(
838
853
  "{ OR: [{ language_exists: false }, { language: { code: $language } }] }"
839
854
  ));
840
- const u = `(${n.join(", ")})`, l = c.length ? `(
855
+ const l = `(${n.join(", ")})`, u = c.length ? `(
841
856
  limit: $limit
842
857
  skip: $skip
843
858
  where: {
@@ -850,8 +865,8 @@ query${i} {
850
865
  limit: $limit
851
866
  skip: $skip
852
867
  )`, g = `
853
- query${u} {
854
- brandCollectionCollection${l} {
868
+ query${l} {
869
+ brandCollectionCollection${u} {
855
870
  total
856
871
  items {
857
872
  sys {
@@ -865,13 +880,27 @@ query${u} {
865
880
  id
866
881
  }
867
882
  name
868
- slug
883
+ logo {
884
+ url
885
+ width
886
+ height
887
+ contentType
888
+ }
889
+ hyperlink {
890
+ sys {
891
+ id
892
+ }
893
+ label
894
+ url
895
+ target
896
+ marketHandling
897
+ }
869
898
  }
870
899
  }
871
900
  }
872
901
  }
873
902
  }
874
- `, { brandCollectionCollection: f } = await d.graphqlQuery(g, {
903
+ `, { brandCollectionCollection: f } = await m.graphqlQuery(g, {
875
904
  ...i
876
905
  });
877
906
  return {
@@ -880,7 +909,7 @@ query${u} {
880
909
  size: o,
881
910
  items: f.items
882
911
  };
883
- }, dt = async ({
912
+ }, mt = async ({
884
913
  marketCode: e,
885
914
  language: t,
886
915
  page: r = 1,
@@ -889,22 +918,22 @@ query${u} {
889
918
  const a = Math.max(1, Math.floor(r)), o = Math.max(1, Math.floor(s)), n = ["$limit: Int!", "$skip: Int!"], i = {
890
919
  limit: o,
891
920
  skip: (a - 1) * o
892
- }, c = ["limit: $limit", "skip: $skip"], u = [];
893
- e && (n.push("$marketCode: String!"), i.marketCode = e, u.push(
921
+ }, c = ["limit: $limit", "skip: $skip"], l = [];
922
+ e && (n.push("$marketCode: String!"), i.marketCode = e, l.push(
894
923
  "{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }"
895
- )), t && (n.push("$language: String!"), i.language = t, u.push(
924
+ )), t && (n.push("$language: String!"), i.language = t, l.push(
896
925
  "{ OR: [{ language_exists: false }, { language: { code: $language } }] }"
897
- )), u.length && c.push(`where: {
926
+ )), l.length && c.push(`where: {
898
927
  AND: [
899
- ${u.join(`
928
+ ${l.join(`
900
929
  `)}
901
930
  ]
902
931
  }`);
903
- const l = n.length ? `(${n.join(", ")})` : "", g = c.length ? `(
932
+ const u = n.length ? `(${n.join(", ")})` : "", g = c.length ? `(
904
933
  ${c.join(`
905
934
  `)}
906
935
  )` : "", f = `
907
- query${l} {
936
+ query${u} {
908
937
  documentationCategoryCollection${g} {
909
938
  total
910
939
  items {
@@ -926,7 +955,7 @@ query${l} {
926
955
  }
927
956
  }
928
957
  }
929
- `, { documentationCategoryCollection: y } = await d.graphqlQuery(f, {
958
+ `, { documentationCategoryCollection: y } = await m.graphqlQuery(f, {
930
959
  ...i
931
960
  });
932
961
  return {
@@ -961,7 +990,7 @@ query${l} {
961
990
  `)}
962
991
  ]
963
992
  }
964
- )`, u = `
993
+ )`, l = `
965
994
  query${i} {
966
995
  documentationCategoryCollection${c} {
967
996
  items {
@@ -983,9 +1012,9 @@ query${i} {
983
1012
  }
984
1013
  }
985
1014
  }
986
- `, { documentationCategoryCollection: l } = await d.graphqlQuery(u, {
1015
+ `, { documentationCategoryCollection: u } = await m.graphqlQuery(l, {
987
1016
  ...o
988
- }), g = l.items.at(0);
1017
+ }), g = u.items.at(0);
989
1018
  if (!g)
990
1019
  throw new Q();
991
1020
  return g;
@@ -999,19 +1028,19 @@ query${i} {
999
1028
  const o = Math.max(1, Math.floor(s)), n = Math.max(1, Math.floor(a)), i = ["$limit: Int!", "$skip: Int!"], c = {
1000
1029
  limit: n,
1001
1030
  skip: (o - 1) * n
1002
- }, u = ["limit: $limit", "skip: $skip"], l = [];
1003
- e && (i.push("$marketCode: String!"), c.marketCode = e, l.push(
1031
+ }, l = ["limit: $limit", "skip: $skip"], u = [];
1032
+ e && (i.push("$marketCode: String!"), c.marketCode = e, u.push(
1004
1033
  "{ OR: [{ market_exists: false }, { market: { code: $marketCode } }] }"
1005
- )), t && (i.push("$language: String!"), c.language = t, l.push(
1034
+ )), t && (i.push("$language: String!"), c.language = t, u.push(
1006
1035
  "{ OR: [{ language_exists: false }, { language: { code: $language } }] }"
1007
- )), r && (i.push("$categorySlug: String!"), c.categorySlug = r, l.push("{ category: { slug: $categorySlug } }")), l.length && u.push(`where: {
1036
+ )), r && (i.push("$categorySlug: String!"), c.categorySlug = r, u.push("{ category: { slug: $categorySlug } }")), u.length && l.push(`where: {
1008
1037
  AND: [
1009
- ${l.join(`
1038
+ ${u.join(`
1010
1039
  `)}
1011
1040
  ]
1012
1041
  }`);
1013
- const g = i.length ? `(${i.join(", ")})` : "", f = u.length ? `(
1014
- ${u.join(`
1042
+ const g = i.length ? `(${i.join(", ")})` : "", f = l.length ? `(
1043
+ ${l.join(`
1015
1044
  `)}
1016
1045
  )` : "", y = `
1017
1046
  query${g} {
@@ -1043,7 +1072,7 @@ query${g} {
1043
1072
  }
1044
1073
  }
1045
1074
  }
1046
- `, { documentationArticleCollection: h } = await d.graphqlQuery(y, {
1075
+ `, { documentationArticleCollection: h } = await m.graphqlQuery(y, {
1047
1076
  ...c
1048
1077
  });
1049
1078
  return {
@@ -1078,7 +1107,7 @@ query${g} {
1078
1107
  `)}
1079
1108
  ]
1080
1109
  }
1081
- )`, u = `
1110
+ )`, l = `
1082
1111
  query${i} {
1083
1112
  documentationArticleCollection${c} {
1084
1113
  items {
@@ -1091,6 +1120,21 @@ query${i} {
1091
1120
  slug
1092
1121
  content {
1093
1122
  json
1123
+ links {
1124
+ assets {
1125
+ block {
1126
+ sys {
1127
+ id
1128
+ }
1129
+ url
1130
+ width
1131
+ height
1132
+ contentType
1133
+ title
1134
+ description
1135
+ }
1136
+ }
1137
+ }
1094
1138
  }
1095
1139
  author {
1096
1140
  name
@@ -1116,9 +1160,9 @@ query${i} {
1116
1160
  }
1117
1161
  }
1118
1162
  }
1119
- `, { documentationArticleCollection: l } = await d.graphqlQuery(u, {
1163
+ `, { documentationArticleCollection: u } = await m.graphqlQuery(l, {
1120
1164
  ...o
1121
- }), g = l.items.at(0);
1165
+ }), g = u.items.at(0);
1122
1166
  if (!g)
1123
1167
  throw new Q();
1124
1168
  return g;
@@ -1137,7 +1181,7 @@ query${i} {
1137
1181
  )), s && (n.push("$language: String!"), i.language = s, c.push(
1138
1182
  "{ OR: [{ language_exists: false }, { language: { code: $language } }] }"
1139
1183
  ));
1140
- const u = n.length ? `(${n.join(", ")})` : "", l = c.length ? `(
1184
+ const l = n.length ? `(${n.join(", ")})` : "", u = c.length ? `(
1141
1185
  limit: $limit
1142
1186
  skip: $skip
1143
1187
  order: order_ASC
@@ -1152,8 +1196,8 @@ query${i} {
1152
1196
  skip: $skip
1153
1197
  order: order_ASC
1154
1198
  )`, g = `
1155
- query${u} {
1156
- hyperlinkCollectionCollection${l} {
1199
+ query${l} {
1200
+ hyperlinkCollectionCollection${u} {
1157
1201
  total
1158
1202
  items {
1159
1203
  sys {
@@ -1176,7 +1220,7 @@ query${u} {
1176
1220
  }
1177
1221
  }
1178
1222
  }
1179
- `, { hyperlinkCollectionCollection: f } = await d.graphqlQuery(
1223
+ `, { hyperlinkCollectionCollection: f } = await m.graphqlQuery(
1180
1224
  g,
1181
1225
  {
1182
1226
  ...i
@@ -1203,7 +1247,7 @@ query${u} {
1203
1247
  )), s && (n.push("$language: String!"), i.language = s, c.push(
1204
1248
  "{ OR: [{ language_exists: false }, { language: { code: $language } }] }"
1205
1249
  ));
1206
- const u = `(${n.join(", ")})`, l = c.length ? `(
1250
+ const l = `(${n.join(", ")})`, u = c.length ? `(
1207
1251
  limit: $limit
1208
1252
  skip: $skip
1209
1253
  where: {
@@ -1216,8 +1260,8 @@ query${u} {
1216
1260
  limit: $limit
1217
1261
  skip: $skip
1218
1262
  )`, g = `
1219
- query${u} {
1220
- keywordCollectionCollection${l} {
1263
+ query${l} {
1264
+ keywordCollectionCollection${u} {
1221
1265
  total
1222
1266
  items {
1223
1267
  sys {
@@ -1229,7 +1273,7 @@ query${u} {
1229
1273
  }
1230
1274
  }
1231
1275
  }
1232
- `, { keywordCollectionCollection: f } = await d.graphqlQuery(g, {
1276
+ `, { keywordCollectionCollection: f } = await m.graphqlQuery(g, {
1233
1277
  ...i
1234
1278
  });
1235
1279
  return {
@@ -1240,14 +1284,14 @@ query${u} {
1240
1284
  };
1241
1285
  };
1242
1286
  export {
1243
- d as ContentfulSDK,
1287
+ m as ContentfulSDK,
1244
1288
  pt as getBannerCollections,
1245
1289
  yt as getBlogPostDetail,
1246
1290
  ht as getBlogPosts,
1247
- mt as getBrandCollections,
1291
+ dt as getBrandCollections,
1248
1292
  $t as getDocArticleDetail,
1249
1293
  vt as getDocArticles,
1250
- dt as getDocCategories,
1294
+ mt as getDocCategories,
1251
1295
  bt as getDocCategoryDetail,
1252
1296
  wt as getHyperlinkCollections,
1253
1297
  St as getKeywordCollections
@@ -0,0 +1,145 @@
1
+ import { ChainModifiers, Entry, EntryFieldTypes, EntrySkeletonType, LocaleCode } from 'contentful';
2
+ export interface TypeAuthorFields {
3
+ name: EntryFieldTypes.Symbol;
4
+ avatar?: EntryFieldTypes.AssetLink;
5
+ }
6
+ export type TypeAuthorSkeleton = EntrySkeletonType<TypeAuthorFields, "author">;
7
+ export type TypeAuthor<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeAuthorSkeleton, Modifiers, Locales>;
8
+ export interface TypeBannerFields {
9
+ name: EntryFieldTypes.Symbol;
10
+ hyperlink?: EntryFieldTypes.EntryLink<TypeHyperlinkSkeleton>;
11
+ media: EntryFieldTypes.AssetLink;
12
+ }
13
+ export type TypeBannerSkeleton = EntrySkeletonType<TypeBannerFields, "banner">;
14
+ export type TypeBanner<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBannerSkeleton, Modifiers, Locales>;
15
+ export interface TypeBannerCollectionFields {
16
+ name: EntryFieldTypes.Symbol;
17
+ banners?: EntryFieldTypes.Array<EntryFieldTypes.EntryLink<TypeBannerSkeleton>>;
18
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
19
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
20
+ platform: EntryFieldTypes.Array<EntryFieldTypes.Symbol<"MOBILE" | "WEB">>;
21
+ slot: EntryFieldTypes.Symbol<"home_hero">;
22
+ }
23
+ export type TypeBannerCollectionSkeleton = EntrySkeletonType<TypeBannerCollectionFields, "bannerCollection">;
24
+ export type TypeBannerCollection<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBannerCollectionSkeleton, Modifiers, Locales>;
25
+ export interface TypeBlogCategoryFields {
26
+ title: EntryFieldTypes.Symbol;
27
+ slug: EntryFieldTypes.Symbol;
28
+ description?: EntryFieldTypes.RichText;
29
+ publishedDate?: EntryFieldTypes.Date;
30
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
31
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
32
+ seo?: EntryFieldTypes.EntryLink<TypeSeoSkeleton>;
33
+ }
34
+ export type TypeBlogCategorySkeleton = EntrySkeletonType<TypeBlogCategoryFields, "blogCategory">;
35
+ export type TypeBlogCategory<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBlogCategorySkeleton, Modifiers, Locales>;
36
+ export interface TypeBlogPostFields {
37
+ title: EntryFieldTypes.Symbol;
38
+ shortDescription?: EntryFieldTypes.Text;
39
+ slug: EntryFieldTypes.Symbol;
40
+ author?: EntryFieldTypes.EntryLink<TypeAuthorSkeleton>;
41
+ featuredImage: EntryFieldTypes.AssetLink;
42
+ content: EntryFieldTypes.RichText;
43
+ relatedBlogPosts?: EntryFieldTypes.Array<EntryFieldTypes.EntryLink<TypeBlogPostSkeleton>>;
44
+ category?: EntryFieldTypes.EntryLink<TypeBlogCategorySkeleton>;
45
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
46
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
47
+ seo?: EntryFieldTypes.EntryLink<TypeSeoSkeleton>;
48
+ }
49
+ export type TypeBlogPostSkeleton = EntrySkeletonType<TypeBlogPostFields, "blogPost">;
50
+ export type TypeBlogPost<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBlogPostSkeleton, Modifiers, Locales>;
51
+ export interface TypeBrandFields {
52
+ name: EntryFieldTypes.Symbol;
53
+ logo?: EntryFieldTypes.AssetLink;
54
+ hyperlink?: EntryFieldTypes.EntryLink<TypeHyperlinkSkeleton>;
55
+ }
56
+ export type TypeBrandSkeleton = EntrySkeletonType<TypeBrandFields, "brand">;
57
+ export type TypeBrand<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBrandSkeleton, Modifiers, Locales>;
58
+ export interface TypeBrandCollectionFields {
59
+ name: EntryFieldTypes.Symbol;
60
+ brands?: EntryFieldTypes.Array<EntryFieldTypes.EntryLink<TypeBrandSkeleton>>;
61
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
62
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
63
+ slot: EntryFieldTypes.Symbol<"footer">;
64
+ }
65
+ export type TypeBrandCollectionSkeleton = EntrySkeletonType<TypeBrandCollectionFields, "brandCollection">;
66
+ export type TypeBrandCollection<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBrandCollectionSkeleton, Modifiers, Locales>;
67
+ export interface TypeDocumentationArticleFields {
68
+ title: EntryFieldTypes.Symbol;
69
+ slug: EntryFieldTypes.Symbol;
70
+ content: EntryFieldTypes.RichText;
71
+ author?: EntryFieldTypes.EntryLink<TypeAuthorSkeleton>;
72
+ category: EntryFieldTypes.EntryLink<TypeDocumentationCategorySkeleton>;
73
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
74
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
75
+ seo?: EntryFieldTypes.EntryLink<TypeSeoSkeleton>;
76
+ }
77
+ export type TypeDocumentationArticleSkeleton = EntrySkeletonType<TypeDocumentationArticleFields, "documentationArticle">;
78
+ export type TypeDocumentationArticle<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeDocumentationArticleSkeleton, Modifiers, Locales>;
79
+ export interface TypeDocumentationCategoryFields {
80
+ title: EntryFieldTypes.Symbol;
81
+ slug: EntryFieldTypes.Symbol;
82
+ description?: EntryFieldTypes.Symbol;
83
+ order?: EntryFieldTypes.Integer;
84
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
85
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
86
+ seo?: EntryFieldTypes.EntryLink<TypeSeoSkeleton>;
87
+ }
88
+ export type TypeDocumentationCategorySkeleton = EntrySkeletonType<TypeDocumentationCategoryFields, "documentationCategory">;
89
+ export type TypeDocumentationCategory<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeDocumentationCategorySkeleton, Modifiers, Locales>;
90
+ export interface TypeHyperlinkFields {
91
+ label: EntryFieldTypes.Symbol;
92
+ url: EntryFieldTypes.Symbol;
93
+ target: EntryFieldTypes.Symbol<"_blank" | "_self">;
94
+ marketHandling: EntryFieldTypes.Symbol<"auto" | "manual">;
95
+ }
96
+ export type TypeHyperlinkSkeleton = EntrySkeletonType<TypeHyperlinkFields, "hyperlink">;
97
+ export type TypeHyperlink<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeHyperlinkSkeleton, Modifiers, Locales>;
98
+ export interface TypeHyperlinkCollectionFields {
99
+ name: EntryFieldTypes.Symbol;
100
+ links?: EntryFieldTypes.Array<EntryFieldTypes.EntryLink<TypeHyperlinkSkeleton>>;
101
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
102
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
103
+ slot: EntryFieldTypes.Symbol<"footer">;
104
+ order: EntryFieldTypes.Integer;
105
+ }
106
+ export type TypeHyperlinkCollectionSkeleton = EntrySkeletonType<TypeHyperlinkCollectionFields, "hyperlinkCollection">;
107
+ export type TypeHyperlinkCollection<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeHyperlinkCollectionSkeleton, Modifiers, Locales>;
108
+ export interface TypeKeywordCollectionFields {
109
+ name: EntryFieldTypes.Symbol;
110
+ keywords?: EntryFieldTypes.Array<EntryFieldTypes.Symbol>;
111
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
112
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
113
+ slot: EntryFieldTypes.Symbol<"footer">;
114
+ }
115
+ export type TypeKeywordCollectionSkeleton = EntrySkeletonType<TypeKeywordCollectionFields, "keywordCollection">;
116
+ export type TypeKeywordCollection<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeKeywordCollectionSkeleton, Modifiers, Locales>;
117
+ export interface TypeLanguageFields {
118
+ name: EntryFieldTypes.Symbol;
119
+ code: EntryFieldTypes.Symbol;
120
+ }
121
+ export type TypeLanguageSkeleton = EntrySkeletonType<TypeLanguageFields, "language">;
122
+ export type TypeLanguage<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeLanguageSkeleton, Modifiers, Locales>;
123
+ export interface TypeMarketFields {
124
+ name: EntryFieldTypes.Symbol;
125
+ code: EntryFieldTypes.Symbol;
126
+ }
127
+ export type TypeMarketSkeleton = EntrySkeletonType<TypeMarketFields, "market">;
128
+ export type TypeMarket<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeMarketSkeleton, Modifiers, Locales>;
129
+ export interface TypeNoticeFields {
130
+ title: EntryFieldTypes.Symbol;
131
+ content: EntryFieldTypes.RichText;
132
+ market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
133
+ language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
134
+ variant?: EntryFieldTypes.Array<EntryFieldTypes.Symbol<"Featured" | "Promotion" | "Urgent">>;
135
+ }
136
+ export type TypeNoticeSkeleton = EntrySkeletonType<TypeNoticeFields, "notice">;
137
+ export type TypeNotice<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeNoticeSkeleton, Modifiers, Locales>;
138
+ export interface TypeSeoFields {
139
+ metaTitle: EntryFieldTypes.Symbol;
140
+ metaDescription?: EntryFieldTypes.Text;
141
+ metaKeywords?: EntryFieldTypes.Array<EntryFieldTypes.Symbol>;
142
+ metaRobots?: EntryFieldTypes.Array<EntryFieldTypes.Symbol<"follow" | "index" | "nofollow" | "noindex">>;
143
+ }
144
+ export type TypeSeoSkeleton = EntrySkeletonType<TypeSeoFields, "seo">;
145
+ export type TypeSeo<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeSeoSkeleton, Modifiers, Locales>;
@@ -1,145 +1,11 @@
1
- import { ChainModifiers, Entry, EntryFieldTypes, EntrySkeletonType, LocaleCode } from 'contentful';
2
- export interface TypeAuthorFields {
3
- name: EntryFieldTypes.Symbol;
4
- avatar?: EntryFieldTypes.AssetLink;
5
- }
6
- export type TypeAuthorSkeleton = EntrySkeletonType<TypeAuthorFields, "author">;
7
- export type TypeAuthor<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeAuthorSkeleton, Modifiers, Locales>;
8
- export interface TypeBannerFields {
9
- name: EntryFieldTypes.Symbol;
10
- hyperlink?: EntryFieldTypes.EntryLink<TypeHyperlinkSkeleton>;
11
- media: EntryFieldTypes.AssetLink;
12
- }
13
- export type TypeBannerSkeleton = EntrySkeletonType<TypeBannerFields, "banner">;
14
- export type TypeBanner<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBannerSkeleton, Modifiers, Locales>;
15
- export interface TypeBannerCollectionFields {
16
- name: EntryFieldTypes.Symbol;
17
- banners?: EntryFieldTypes.Array<EntryFieldTypes.EntryLink<TypeBannerSkeleton>>;
18
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
19
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
20
- platform: EntryFieldTypes.Array<EntryFieldTypes.Symbol<"MOBILE" | "WEB">>;
21
- slot: EntryFieldTypes.Symbol<"home_hero">;
22
- }
23
- export type TypeBannerCollectionSkeleton = EntrySkeletonType<TypeBannerCollectionFields, "bannerCollection">;
24
- export type TypeBannerCollection<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBannerCollectionSkeleton, Modifiers, Locales>;
25
- export interface TypeBlogCategoryFields {
26
- title: EntryFieldTypes.Symbol;
27
- slug: EntryFieldTypes.Symbol;
28
- description?: EntryFieldTypes.RichText;
29
- publishedDate?: EntryFieldTypes.Date;
30
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
31
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
32
- seo?: EntryFieldTypes.EntryLink<TypeSeoSkeleton>;
33
- }
34
- export type TypeBlogCategorySkeleton = EntrySkeletonType<TypeBlogCategoryFields, "blogCategory">;
35
- export type TypeBlogCategory<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBlogCategorySkeleton, Modifiers, Locales>;
36
- export interface TypeBlogPostFields {
37
- title: EntryFieldTypes.Symbol;
38
- shortDescription?: EntryFieldTypes.Text;
39
- slug: EntryFieldTypes.Symbol;
40
- author?: EntryFieldTypes.EntryLink<TypeAuthorSkeleton>;
41
- featuredImage: EntryFieldTypes.AssetLink;
42
- content: EntryFieldTypes.RichText;
43
- relatedBlogPosts?: EntryFieldTypes.Array<EntryFieldTypes.EntryLink<TypeBlogPostSkeleton>>;
44
- category?: EntryFieldTypes.EntryLink<TypeBlogCategorySkeleton>;
45
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
46
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
47
- seo?: EntryFieldTypes.EntryLink<TypeSeoSkeleton>;
48
- }
49
- export type TypeBlogPostSkeleton = EntrySkeletonType<TypeBlogPostFields, "blogPost">;
50
- export type TypeBlogPost<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBlogPostSkeleton, Modifiers, Locales>;
51
- export interface TypeBrandFields {
52
- name: EntryFieldTypes.Symbol;
53
- slug: EntryFieldTypes.Symbol;
54
- logo?: EntryFieldTypes.AssetLink;
55
- }
56
- export type TypeBrandSkeleton = EntrySkeletonType<TypeBrandFields, "brand">;
57
- export type TypeBrand<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBrandSkeleton, Modifiers, Locales>;
58
- export interface TypeBrandCollectionFields {
59
- name: EntryFieldTypes.Symbol;
60
- brands?: EntryFieldTypes.Array<EntryFieldTypes.EntryLink<TypeBrandSkeleton>>;
61
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
62
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
63
- slot: EntryFieldTypes.Symbol<"footer">;
64
- }
65
- export type TypeBrandCollectionSkeleton = EntrySkeletonType<TypeBrandCollectionFields, "brandCollection">;
66
- export type TypeBrandCollection<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeBrandCollectionSkeleton, Modifiers, Locales>;
67
- export interface TypeDocumentationArticleFields {
68
- title: EntryFieldTypes.Symbol;
69
- slug: EntryFieldTypes.Symbol;
70
- content: EntryFieldTypes.RichText;
71
- author?: EntryFieldTypes.EntryLink<TypeAuthorSkeleton>;
72
- category: EntryFieldTypes.EntryLink<TypeDocumentationCategorySkeleton>;
73
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
74
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
75
- seo?: EntryFieldTypes.EntryLink<TypeSeoSkeleton>;
76
- }
77
- export type TypeDocumentationArticleSkeleton = EntrySkeletonType<TypeDocumentationArticleFields, "documentationArticle">;
78
- export type TypeDocumentationArticle<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeDocumentationArticleSkeleton, Modifiers, Locales>;
79
- export interface TypeDocumentationCategoryFields {
80
- title: EntryFieldTypes.Symbol;
81
- slug: EntryFieldTypes.Symbol;
82
- description?: EntryFieldTypes.Symbol;
83
- order?: EntryFieldTypes.Integer;
84
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
85
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
86
- seo?: EntryFieldTypes.EntryLink<TypeSeoSkeleton>;
87
- }
88
- export type TypeDocumentationCategorySkeleton = EntrySkeletonType<TypeDocumentationCategoryFields, "documentationCategory">;
89
- export type TypeDocumentationCategory<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeDocumentationCategorySkeleton, Modifiers, Locales>;
90
- export interface TypeHyperlinkFields {
91
- label: EntryFieldTypes.Symbol;
92
- url: EntryFieldTypes.Symbol;
93
- target: EntryFieldTypes.Symbol<"_blank" | "_self">;
94
- marketHandling: EntryFieldTypes.Symbol<"auto" | "manual">;
95
- }
96
- export type TypeHyperlinkSkeleton = EntrySkeletonType<TypeHyperlinkFields, "hyperlink">;
97
- export type TypeHyperlink<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeHyperlinkSkeleton, Modifiers, Locales>;
98
- export interface TypeHyperlinkCollectionFields {
99
- name: EntryFieldTypes.Symbol;
100
- links?: EntryFieldTypes.Array<EntryFieldTypes.EntryLink<TypeHyperlinkSkeleton>>;
101
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
102
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
103
- slot: EntryFieldTypes.Symbol<"footer">;
104
- order: EntryFieldTypes.Integer;
105
- }
106
- export type TypeHyperlinkCollectionSkeleton = EntrySkeletonType<TypeHyperlinkCollectionFields, "hyperlinkCollection">;
107
- export type TypeHyperlinkCollection<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeHyperlinkCollectionSkeleton, Modifiers, Locales>;
108
- export interface TypeKeywordCollectionFields {
109
- name: EntryFieldTypes.Symbol;
110
- keywords?: EntryFieldTypes.Array<EntryFieldTypes.Symbol>;
111
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
112
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
113
- slot: EntryFieldTypes.Symbol<"footer">;
114
- }
115
- export type TypeKeywordCollectionSkeleton = EntrySkeletonType<TypeKeywordCollectionFields, "keywordCollection">;
116
- export type TypeKeywordCollection<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeKeywordCollectionSkeleton, Modifiers, Locales>;
117
- export interface TypeLanguageFields {
118
- name: EntryFieldTypes.Symbol;
119
- code: EntryFieldTypes.Symbol;
120
- }
121
- export type TypeLanguageSkeleton = EntrySkeletonType<TypeLanguageFields, "language">;
122
- export type TypeLanguage<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeLanguageSkeleton, Modifiers, Locales>;
123
- export interface TypeMarketFields {
124
- name: EntryFieldTypes.Symbol;
125
- code: EntryFieldTypes.Symbol;
126
- }
127
- export type TypeMarketSkeleton = EntrySkeletonType<TypeMarketFields, "market">;
128
- export type TypeMarket<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeMarketSkeleton, Modifiers, Locales>;
129
- export interface TypeNoticeFields {
130
- title: EntryFieldTypes.Symbol;
131
- content: EntryFieldTypes.RichText;
132
- market?: EntryFieldTypes.EntryLink<TypeMarketSkeleton>;
133
- language?: EntryFieldTypes.EntryLink<TypeLanguageSkeleton>;
134
- variant?: EntryFieldTypes.Array<EntryFieldTypes.Symbol<"Featured" | "Promotion" | "Urgent">>;
135
- }
136
- export type TypeNoticeSkeleton = EntrySkeletonType<TypeNoticeFields, "notice">;
137
- export type TypeNotice<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeNoticeSkeleton, Modifiers, Locales>;
138
- export interface TypeSeoFields {
139
- metaTitle: EntryFieldTypes.Symbol;
140
- metaDescription?: EntryFieldTypes.Text;
141
- metaKeywords?: EntryFieldTypes.Array<EntryFieldTypes.Symbol>;
142
- metaRobots?: EntryFieldTypes.Array<EntryFieldTypes.Symbol<"follow" | "index" | "nofollow" | "noindex">>;
143
- }
144
- export type TypeSeoSkeleton = EntrySkeletonType<TypeSeoFields, "seo">;
145
- export type TypeSeo<Modifiers extends ChainModifiers, Locales extends LocaleCode = LocaleCode> = Entry<TypeSeoSkeleton, Modifiers, Locales>;
1
+ import { EntrySys } from 'contentful';
2
+ export * from './content-model';
3
+ export type GraphQLAsset = {
4
+ url: string;
5
+ width: number | null;
6
+ height: number | null;
7
+ contentType: string;
8
+ };
9
+ export type GraphQLAssetLink = GraphQLAsset & {
10
+ sys: Pick<EntrySys, "id">;
11
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@janbox/contentful-marketplace-sdk",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "main": "./dist/index.cjs",
5
5
  "module": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",