@c-rex/interfaces 0.1.1 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { LogLevelType, LogCategoriesType, ResultViewStyles } from '@c-rex/types';
1
+ import { LogLevelType, LogCategoriesType, ResultViewStyles, ResultTypes, FilesExtensions } from '@c-rex/types';
2
2
 
3
3
  interface DefaultPageInfo {
4
4
  pageNumber: number;
@@ -59,7 +59,13 @@ interface OIDCInterface {
59
59
  interface ConfigInterface {
60
60
  projectName: string;
61
61
  baseUrl: string;
62
- resultViewStyle: ResultViewStyles;
62
+ results: {
63
+ resultViewStyle: ResultViewStyles;
64
+ disabledResults: ResultTypes[];
65
+ filesEnabledToDownload?: FilesExtensions[];
66
+ filesEnabledToOpen?: FilesExtensions[];
67
+ resultsToHide?: ResultTypes[];
68
+ };
63
69
  OIDC: {
64
70
  client: OIDCInterface;
65
71
  user: OIDCInterface;
@@ -77,7 +83,7 @@ interface ConfigInterface {
77
83
  sparqlWhere?: string;
78
84
  };
79
85
  logs: {
80
- console: logInfo;
86
+ console: Omit<logInfo, "url" | "app" | "categoriesLevel">;
81
87
  graylog: logInfo;
82
88
  matomo: logInfo;
83
89
  };
@@ -113,16 +119,27 @@ interface informationUnitsItems extends idShortID {
113
119
  directoryNodes: DirectoryNodes[];
114
120
  languages: string[];
115
121
  }
116
- interface informationUnitsResponse extends idShortID {
117
- languages: string[];
118
- labels: Labels[];
119
- titles: Labels[];
120
- files: {
122
+ interface informationUnitsResponseItems {
123
+ language: string;
124
+ title: string;
125
+ type: string;
126
+ shortId: string;
127
+ localeType: string;
128
+ link: string;
129
+ disabled: boolean;
130
+ filesToOpen: {
131
+ format: string;
132
+ link: string;
133
+ }[];
134
+ filesToDownload: {
121
135
  format: string;
122
- type: string;
123
136
  link: string;
124
137
  }[];
125
138
  }
139
+ interface informationUnitsResponse {
140
+ items: informationUnitsResponseItems[];
141
+ pageInfo: DefaultPageInfo;
142
+ }
126
143
  interface informationUnits {
127
144
  items: informationUnitsItems[];
128
145
  pageInfo: DefaultPageInfo;
@@ -137,7 +154,13 @@ interface AutocompleteSuggestion {
137
154
  interface DirectoryNodes extends informationUnitsDirectories {
138
155
  childNodes: informationUnitsDirectories[];
139
156
  parents: idShortID[];
140
- informationUnits: idShortID[];
157
+ informationUnits: (idShortID & {
158
+ labels: Labels[];
159
+ })[];
160
+ }
161
+ interface DirectoryNodesResponse {
162
+ items: DirectoryNodes[];
163
+ pageInfo: DefaultPageInfo;
141
164
  }
142
165
 
143
166
  interface DocumentTypesItem extends idShortID {
@@ -153,5 +176,12 @@ interface TreeOfContent {
153
176
  active: boolean;
154
177
  children: TreeOfContent[];
155
178
  }
179
+ interface SidebarAvailableVersionsInterface {
180
+ shortId: string;
181
+ active: boolean;
182
+ lang: string;
183
+ country: string;
184
+ link: string;
185
+ }
156
186
 
157
- export type { AutocompleteSuggestion, ConfigInterface, DefaultLinksRequest, DefaultPageInfo, DefaultRequest, DirectoryNodes, DocumentTypesItem, Filters, Labels, LanguageAndCountries, OIDCInterface, TreeOfContent, idShortID, informationUnits, informationUnitsDirectories, informationUnitsItems, informationUnitsRenditions, informationUnitsResponse, logInfo };
187
+ export type { AutocompleteSuggestion, ConfigInterface, DefaultLinksRequest, DefaultPageInfo, DefaultRequest, DirectoryNodes, DirectoryNodesResponse, DocumentTypesItem, Filters, Labels, LanguageAndCountries, OIDCInterface, SidebarAvailableVersionsInterface, TreeOfContent, idShortID, informationUnits, informationUnitsClass, informationUnitsDirectories, informationUnitsItems, informationUnitsRenditions, informationUnitsResponse, informationUnitsResponseItems, logInfo };
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { LogLevelType, LogCategoriesType, ResultViewStyles } from '@c-rex/types';
1
+ import { LogLevelType, LogCategoriesType, ResultViewStyles, ResultTypes, FilesExtensions } from '@c-rex/types';
2
2
 
3
3
  interface DefaultPageInfo {
4
4
  pageNumber: number;
@@ -59,7 +59,13 @@ interface OIDCInterface {
59
59
  interface ConfigInterface {
60
60
  projectName: string;
61
61
  baseUrl: string;
62
- resultViewStyle: ResultViewStyles;
62
+ results: {
63
+ resultViewStyle: ResultViewStyles;
64
+ disabledResults: ResultTypes[];
65
+ filesEnabledToDownload?: FilesExtensions[];
66
+ filesEnabledToOpen?: FilesExtensions[];
67
+ resultsToHide?: ResultTypes[];
68
+ };
63
69
  OIDC: {
64
70
  client: OIDCInterface;
65
71
  user: OIDCInterface;
@@ -77,7 +83,7 @@ interface ConfigInterface {
77
83
  sparqlWhere?: string;
78
84
  };
79
85
  logs: {
80
- console: logInfo;
86
+ console: Omit<logInfo, "url" | "app" | "categoriesLevel">;
81
87
  graylog: logInfo;
82
88
  matomo: logInfo;
83
89
  };
@@ -113,16 +119,27 @@ interface informationUnitsItems extends idShortID {
113
119
  directoryNodes: DirectoryNodes[];
114
120
  languages: string[];
115
121
  }
116
- interface informationUnitsResponse extends idShortID {
117
- languages: string[];
118
- labels: Labels[];
119
- titles: Labels[];
120
- files: {
122
+ interface informationUnitsResponseItems {
123
+ language: string;
124
+ title: string;
125
+ type: string;
126
+ shortId: string;
127
+ localeType: string;
128
+ link: string;
129
+ disabled: boolean;
130
+ filesToOpen: {
131
+ format: string;
132
+ link: string;
133
+ }[];
134
+ filesToDownload: {
121
135
  format: string;
122
- type: string;
123
136
  link: string;
124
137
  }[];
125
138
  }
139
+ interface informationUnitsResponse {
140
+ items: informationUnitsResponseItems[];
141
+ pageInfo: DefaultPageInfo;
142
+ }
126
143
  interface informationUnits {
127
144
  items: informationUnitsItems[];
128
145
  pageInfo: DefaultPageInfo;
@@ -137,7 +154,13 @@ interface AutocompleteSuggestion {
137
154
  interface DirectoryNodes extends informationUnitsDirectories {
138
155
  childNodes: informationUnitsDirectories[];
139
156
  parents: idShortID[];
140
- informationUnits: idShortID[];
157
+ informationUnits: (idShortID & {
158
+ labels: Labels[];
159
+ })[];
160
+ }
161
+ interface DirectoryNodesResponse {
162
+ items: DirectoryNodes[];
163
+ pageInfo: DefaultPageInfo;
141
164
  }
142
165
 
143
166
  interface DocumentTypesItem extends idShortID {
@@ -153,5 +176,12 @@ interface TreeOfContent {
153
176
  active: boolean;
154
177
  children: TreeOfContent[];
155
178
  }
179
+ interface SidebarAvailableVersionsInterface {
180
+ shortId: string;
181
+ active: boolean;
182
+ lang: string;
183
+ country: string;
184
+ link: string;
185
+ }
156
186
 
157
- export type { AutocompleteSuggestion, ConfigInterface, DefaultLinksRequest, DefaultPageInfo, DefaultRequest, DirectoryNodes, DocumentTypesItem, Filters, Labels, LanguageAndCountries, OIDCInterface, TreeOfContent, idShortID, informationUnits, informationUnitsDirectories, informationUnitsItems, informationUnitsRenditions, informationUnitsResponse, logInfo };
187
+ export type { AutocompleteSuggestion, ConfigInterface, DefaultLinksRequest, DefaultPageInfo, DefaultRequest, DirectoryNodes, DirectoryNodesResponse, DocumentTypesItem, Filters, Labels, LanguageAndCountries, OIDCInterface, SidebarAvailableVersionsInterface, TreeOfContent, idShortID, informationUnits, informationUnitsClass, informationUnitsDirectories, informationUnitsItems, informationUnitsRenditions, informationUnitsResponse, informationUnitsResponseItems, logInfo };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@c-rex/interfaces",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "main": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "module": "./dist/index.mjs",
@@ -14,7 +14,9 @@
14
14
  "dev": "tsup --watch",
15
15
  "build": "tsup",
16
16
  "test:watch": "jest --watch",
17
- "test": "jest"
17
+ "test": "jest",
18
+ "lint": "eslint .",
19
+ "lint:fix": "eslint . --fix"
18
20
  },
19
21
  "devDependencies": {
20
22
  "@c-rex/typescript-config": "*",