@empathyco/x-adapter-platform 1.1.0-alpha.57 → 1.1.0-alpha.59

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.
@@ -15,8 +15,11 @@ exports.aiSuggestionSearchSchema = (0, x_adapter_1.createMutableSchema)({
15
15
  $subSchema: result_schema_1.resultSchema,
16
16
  },
17
17
  numFound: 'numFound',
18
- tagging: ({ tagging }) => ({
19
- query: (0, url_utils_1.getTaggingInfoFromUrl)(tagging.query),
20
- }),
18
+ tagging: ({ tagging }) => {
19
+ var _a;
20
+ return ({
21
+ query: (0, url_utils_1.getTaggingInfoFromUrl)((_a = tagging === null || tagging === void 0 ? void 0 : tagging.query) !== null && _a !== void 0 ? _a : ''),
22
+ });
23
+ },
21
24
  });
22
25
  //# sourceMappingURL=suggestion-search.schema.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"suggestion-search.schema.js","sourceRoot":"","sources":["../../../../../src/schemas/models/ai/suggestion-search.schema.ts"],"names":[],"mappings":";;;AAEA,oDAA0D;AAC1D,0DAAkE;AAClE,oDAA+C;AAE/C;;;GAGG;AACU,QAAA,wBAAwB,GAAG,IAAA,+BAAmB,EAGzD;IACA,KAAK,EAAE,OAAO;IACd,OAAO,EAAE;QACP,KAAK,EAAE,SAAS;QAChB,UAAU,EAAE,4BAAY;KACzB;IACD,QAAQ,EAAE,UAAU;IACpB,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAC;QACzB,KAAK,EAAE,IAAA,iCAAqB,EAAC,OAAO,CAAC,KAAK,CAAC;KAC5C,CAAC;CACH,CAAC,CAAA","sourcesContent":["import type { AiSuggestionSearch } from '@empathyco/x-types'\nimport type { PlatformAiSuggestionSearch } from '../../../types/models/ai/suggestion-search.model'\nimport { createMutableSchema } from '@empathyco/x-adapter'\nimport { getTaggingInfoFromUrl } from '../../../mappers/url.utils'\nimport { resultSchema } from '../result.schema'\n\n/**\n * Default implementation for the AiSuggestionSearchSchema.\n * @public\n */\nexport const aiSuggestionSearchSchema = createMutableSchema<\n PlatformAiSuggestionSearch,\n AiSuggestionSearch\n>({\n query: 'query',\n results: {\n $path: 'results',\n $subSchema: resultSchema,\n },\n numFound: 'numFound',\n tagging: ({ tagging }) => ({\n query: getTaggingInfoFromUrl(tagging.query),\n }),\n})\n"]}
1
+ {"version":3,"file":"suggestion-search.schema.js","sourceRoot":"","sources":["../../../../../src/schemas/models/ai/suggestion-search.schema.ts"],"names":[],"mappings":";;;AAEA,oDAA0D;AAC1D,0DAAkE;AAClE,oDAA+C;AAE/C;;;GAGG;AACU,QAAA,wBAAwB,GAAG,IAAA,+BAAmB,EAGzD;IACA,KAAK,EAAE,OAAO;IACd,OAAO,EAAE;QACP,KAAK,EAAE,SAAS;QAChB,UAAU,EAAE,4BAAY;KACzB;IACD,QAAQ,EAAE,UAAU;IACpB,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE;;QAAC,OAAA,CAAC;YACzB,KAAK,EAAE,IAAA,iCAAqB,EAAC,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,KAAK,mCAAI,EAAE,CAAC;SACnD,CAAC,CAAA;KAAA;CACH,CAAC,CAAA","sourcesContent":["import type { AiSuggestionSearch } from '@empathyco/x-types'\nimport type { PlatformAiSuggestionSearch } from '../../../types/models/ai/suggestion-search.model'\nimport { createMutableSchema } from '@empathyco/x-adapter'\nimport { getTaggingInfoFromUrl } from '../../../mappers/url.utils'\nimport { resultSchema } from '../result.schema'\n\n/**\n * Default implementation for the AiSuggestionSearchSchema.\n * @public\n */\nexport const aiSuggestionSearchSchema = createMutableSchema<\n PlatformAiSuggestionSearch,\n AiSuggestionSearch\n>({\n query: 'query',\n results: {\n $path: 'results',\n $subSchema: resultSchema,\n },\n numFound: 'numFound',\n tagging: ({ tagging }) => ({\n query: getTaggingInfoFromUrl(tagging?.query ?? ''),\n }),\n})\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"suggestion-search.model.js","sourceRoot":"","sources":["../../../../../src/types/models/ai/suggestion-search.model.ts"],"names":[],"mappings":"","sourcesContent":["import type { PlatformResult } from '../result.model'\n\n/**\n * Each platform suggestion search is a query and the platform results of that query.\n * @public\n */\nexport interface PlatformAiSuggestionSearch {\n query: string\n results: PlatformResult[]\n numFound: number\n tagging: { query: string }\n}\n"]}
1
+ {"version":3,"file":"suggestion-search.model.js","sourceRoot":"","sources":["../../../../../src/types/models/ai/suggestion-search.model.ts"],"names":[],"mappings":"","sourcesContent":["import type { PlatformResult } from '../result.model'\n\n/**\n * Each platform suggestion search is a query and the platform results of that query.\n * @public\n */\nexport interface PlatformAiSuggestionSearch {\n query: string\n results: PlatformResult[]\n numFound: number\n tagging?: { query: string }\n}\n"]}
@@ -12,8 +12,11 @@ export const aiSuggestionSearchSchema = createMutableSchema({
12
12
  $subSchema: resultSchema,
13
13
  },
14
14
  numFound: 'numFound',
15
- tagging: ({ tagging }) => ({
16
- query: getTaggingInfoFromUrl(tagging.query),
17
- }),
15
+ tagging: ({ tagging }) => {
16
+ var _a;
17
+ return ({
18
+ query: getTaggingInfoFromUrl((_a = tagging === null || tagging === void 0 ? void 0 : tagging.query) !== null && _a !== void 0 ? _a : ''),
19
+ });
20
+ },
18
21
  });
19
22
  //# sourceMappingURL=suggestion-search.schema.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"suggestion-search.schema.js","sourceRoot":"","sources":["../../../../../src/schemas/models/ai/suggestion-search.schema.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAA;AAC1D,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAA;AAClE,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AAE/C;;;GAGG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG,mBAAmB,CAGzD;IACA,KAAK,EAAE,OAAO;IACd,OAAO,EAAE;QACP,KAAK,EAAE,SAAS;QAChB,UAAU,EAAE,YAAY;KACzB;IACD,QAAQ,EAAE,UAAU;IACpB,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAC;QACzB,KAAK,EAAE,qBAAqB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC5C,CAAC;CACH,CAAC,CAAA","sourcesContent":["import type { AiSuggestionSearch } from '@empathyco/x-types'\nimport type { PlatformAiSuggestionSearch } from '../../../types/models/ai/suggestion-search.model'\nimport { createMutableSchema } from '@empathyco/x-adapter'\nimport { getTaggingInfoFromUrl } from '../../../mappers/url.utils'\nimport { resultSchema } from '../result.schema'\n\n/**\n * Default implementation for the AiSuggestionSearchSchema.\n * @public\n */\nexport const aiSuggestionSearchSchema = createMutableSchema<\n PlatformAiSuggestionSearch,\n AiSuggestionSearch\n>({\n query: 'query',\n results: {\n $path: 'results',\n $subSchema: resultSchema,\n },\n numFound: 'numFound',\n tagging: ({ tagging }) => ({\n query: getTaggingInfoFromUrl(tagging.query),\n }),\n})\n"]}
1
+ {"version":3,"file":"suggestion-search.schema.js","sourceRoot":"","sources":["../../../../../src/schemas/models/ai/suggestion-search.schema.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAA;AAC1D,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAA;AAClE,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AAE/C;;;GAGG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG,mBAAmB,CAGzD;IACA,KAAK,EAAE,OAAO;IACd,OAAO,EAAE;QACP,KAAK,EAAE,SAAS;QAChB,UAAU,EAAE,YAAY;KACzB;IACD,QAAQ,EAAE,UAAU;IACpB,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE;;QAAC,OAAA,CAAC;YACzB,KAAK,EAAE,qBAAqB,CAAC,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,KAAK,mCAAI,EAAE,CAAC;SACnD,CAAC,CAAA;KAAA;CACH,CAAC,CAAA","sourcesContent":["import type { AiSuggestionSearch } from '@empathyco/x-types'\nimport type { PlatformAiSuggestionSearch } from '../../../types/models/ai/suggestion-search.model'\nimport { createMutableSchema } from '@empathyco/x-adapter'\nimport { getTaggingInfoFromUrl } from '../../../mappers/url.utils'\nimport { resultSchema } from '../result.schema'\n\n/**\n * Default implementation for the AiSuggestionSearchSchema.\n * @public\n */\nexport const aiSuggestionSearchSchema = createMutableSchema<\n PlatformAiSuggestionSearch,\n AiSuggestionSearch\n>({\n query: 'query',\n results: {\n $path: 'results',\n $subSchema: resultSchema,\n },\n numFound: 'numFound',\n tagging: ({ tagging }) => ({\n query: getTaggingInfoFromUrl(tagging?.query ?? ''),\n }),\n})\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"suggestion-search.model.js","sourceRoot":"","sources":["../../../../../src/types/models/ai/suggestion-search.model.ts"],"names":[],"mappings":"","sourcesContent":["import type { PlatformResult } from '../result.model'\n\n/**\n * Each platform suggestion search is a query and the platform results of that query.\n * @public\n */\nexport interface PlatformAiSuggestionSearch {\n query: string\n results: PlatformResult[]\n numFound: number\n tagging: { query: string }\n}\n"]}
1
+ {"version":3,"file":"suggestion-search.model.js","sourceRoot":"","sources":["../../../../../src/types/models/ai/suggestion-search.model.ts"],"names":[],"mappings":"","sourcesContent":["import type { PlatformResult } from '../result.model'\n\n/**\n * Each platform suggestion search is a query and the platform results of that query.\n * @public\n */\nexport interface PlatformAiSuggestionSearch {\n query: string\n results: PlatformResult[]\n numFound: number\n tagging?: { query: string }\n}\n"]}
@@ -7,7 +7,7 @@ export interface PlatformAiSuggestionSearch {
7
7
  query: string;
8
8
  results: PlatformResult[];
9
9
  numFound: number;
10
- tagging: {
10
+ tagging?: {
11
11
  query: string;
12
12
  };
13
13
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@empathyco/x-adapter-platform",
3
- "version": "1.1.0-alpha.57",
3
+ "version": "1.1.0-alpha.59",
4
4
  "description": "A search client for the Empathy Platform API",
5
5
  "author": "Empathy Systems Corporation S.L.",
6
6
  "license": "Apache-2.0",
@@ -47,9 +47,9 @@
47
47
  "prepublishOnly": "pnpm run build"
48
48
  },
49
49
  "dependencies": {
50
- "@empathyco/x-adapter": "8.1.0-alpha.20",
51
- "@empathyco/x-types": "10.1.0-alpha.49",
52
- "@empathyco/x-utils": "1.0.3-alpha.15"
50
+ "@empathyco/x-adapter": "8.1.0-alpha.21",
51
+ "@empathyco/x-types": "10.1.0-alpha.50",
52
+ "@empathyco/x-utils": "1.0.3-alpha.16"
53
53
  },
54
54
  "devDependencies": {
55
55
  "@microsoft/api-documenter": "7.29.2",
@@ -62,5 +62,5 @@
62
62
  "publishConfig": {
63
63
  "access": "public"
64
64
  },
65
- "gitHead": "40f69f71765aab241849f325ce7834fa8d15a6e2"
65
+ "gitHead": "95c63eed5ce8f5337dcc2e75c0b75849cb14f18e"
66
66
  }
@@ -3922,7 +3922,7 @@
3922
3922
  "excerptTokens": [
3923
3923
  {
3924
3924
  "kind": "Content",
3925
- "text": "tagging: "
3925
+ "text": "tagging?: "
3926
3926
  },
3927
3927
  {
3928
3928
  "kind": "Content",
@@ -3934,7 +3934,7 @@
3934
3934
  }
3935
3935
  ],
3936
3936
  "isReadonly": false,
3937
- "isOptional": false,
3937
+ "isOptional": true,
3938
3938
  "releaseTag": "Public",
3939
3939
  "name": "tagging",
3940
3940
  "propertyTypeTokenRange": {
@@ -330,7 +330,7 @@ export interface PlatformAiSuggestionSearch {
330
330
  // (undocumented)
331
331
  results: PlatformResult[];
332
332
  // (undocumented)
333
- tagging: {
333
+ tagging?: {
334
334
  query: string;
335
335
  };
336
336
  }