@jaaq/jaaq-sdk-js 1.4.0 → 1.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/README.md +6 -0
  2. package/dist/index.cjs +7 -2
  3. package/dist/index.cjs.map +1 -1
  4. package/dist/index.d.ts +5 -1
  5. package/dist/index.mjs +7 -2
  6. package/dist/index.mjs.map +1 -1
  7. package/dist/jaaq-sdk.min.js +1 -1
  8. package/dist/jaaq-sdk.min.js.map +1 -1
  9. package/dist/ui/index.cjs +7 -2
  10. package/dist/ui/index.cjs.map +1 -1
  11. package/dist/ui/index.d.ts +4 -0
  12. package/dist/ui/index.mjs +7 -2
  13. package/dist/ui/index.mjs.map +1 -1
  14. package/dist/ui/jaaq-ui-bundled.min.js +2 -2
  15. package/dist/ui/jaaq-ui-bundled.min.js.map +1 -1
  16. package/dist/ui/jaaq-ui.min.js +2 -2
  17. package/dist/ui/jaaq-ui.min.js.map +1 -1
  18. package/dist/ui/react/index.cjs +7 -2
  19. package/dist/ui/react/index.cjs.map +1 -1
  20. package/dist/ui/react/index.d.ts +4 -0
  21. package/dist/ui/react/index.mjs +7 -2
  22. package/dist/ui/react/index.mjs.map +1 -1
  23. package/dist/ui/react/jaaq-ui-react.min.js +2 -2
  24. package/dist/ui/react/jaaq-ui-react.min.js.map +1 -1
  25. package/dist/ui/vanilla/index.cjs +7 -2
  26. package/dist/ui/vanilla/index.cjs.map +1 -1
  27. package/dist/ui/vanilla/index.d.ts +4 -0
  28. package/dist/ui/vanilla/index.mjs +7 -2
  29. package/dist/ui/vanilla/index.mjs.map +1 -1
  30. package/dist/ui/vanilla/jaaq-vanilla-bundled.min.js +2 -2
  31. package/dist/ui/vanilla/jaaq-vanilla-bundled.min.js.map +1 -1
  32. package/dist/ui/vanilla/jaaq-vanilla.min.js +2 -2
  33. package/dist/ui/vanilla/jaaq-vanilla.min.js.map +1 -1
  34. package/dist/ui/webcomponents/index.cjs +7 -2
  35. package/dist/ui/webcomponents/index.cjs.map +1 -1
  36. package/dist/ui/webcomponents/index.d.ts +4 -0
  37. package/dist/ui/webcomponents/index.mjs +7 -2
  38. package/dist/ui/webcomponents/index.mjs.map +1 -1
  39. package/dist/ui/webcomponents/jaaq-webcomponents-bundled.min.js +2 -2
  40. package/dist/ui/webcomponents/jaaq-webcomponents-bundled.min.js.map +1 -1
  41. package/dist/ui/webcomponents/jaaq-webcomponents.min.js +2 -2
  42. package/dist/ui/webcomponents/jaaq-webcomponents.min.js.map +1 -1
  43. package/package.json +7 -7
@@ -120,6 +120,7 @@ function createVideosResourceV2(http) {
120
120
  };
121
121
  }
122
122
 
123
+ const subdomainQuery = (options) => options?.subdomain !== undefined ? `?subdomain=${encodeURIComponent(options.subdomain)}` : '';
123
124
  function createCollectionsResourceV2(http) {
124
125
  return {
125
126
  async list() {
@@ -128,8 +129,12 @@ function createCollectionsResourceV2(http) {
128
129
  return response.collections;
129
130
  },
130
131
  async getById(id, options) {
131
- const query = options?.subdomain !== undefined ? `?subdomain=${encodeURIComponent(options.subdomain)}` : '';
132
- const path = `/collections/${encodeURIComponent(id)}${query}`;
132
+ const path = `/collections/${encodeURIComponent(id)}${subdomainQuery(options)}`;
133
+ const response = await http.get(path);
134
+ return response.collection;
135
+ },
136
+ async getSummaryById(id, options) {
137
+ const path = `/collections/${encodeURIComponent(id)}/summary${subdomainQuery(options)}`;
133
138
  const response = await http.get(path);
134
139
  return response.collection;
135
140
  },