@ts4nfdi/terminology-service-suite 7.2.5 → 7.3.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.
- package/dist/api/ols/OlsBaseApi.d.ts +1 -0
- package/dist/api/ols/OlsSearchApi.d.ts +1 -0
- package/dist/app/types.d.ts +8 -24
- package/dist/components/widgets/AutocompleteWidget/AutocompleteWidget.d.ts +14 -2
- package/dist/components/widgets/AutocompleteWidget/AutocompleteWidget.stories.d.ts +1 -0
- package/dist/components/widgets/AutocompleteWidget/AutocompleteWidgetStories.d.ts +1 -0
- package/dist/esm/index.es.js +3003 -2977
- package/dist/esm/index.es.js.map +1 -1
- package/dist/model/interfaces/SelectResult.d.ts +3 -2
- package/dist/model/ols-model/OLSSelectResult.d.ts +3 -2
- package/dist/server/index.es.js +11 -4
- package/dist/server/index.es.js.map +1 -1
- package/dist/stories/storyArgs.d.ts +1 -0
- package/package.json +1 -1
|
@@ -3,4 +3,5 @@ export declare class OlsBaseApi {
|
|
|
3
3
|
protected axiosInstance: AxiosInstance;
|
|
4
4
|
constructor(api: string | AxiosInstance);
|
|
5
5
|
protected makeCall(url: string, config: AxiosRequestConfig<any> | undefined, useLegacy: boolean): Promise<any>;
|
|
6
|
+
getFullUrl(url: string, config: AxiosRequestConfig<any> | undefined, useLegacy: boolean): string;
|
|
6
7
|
}
|
|
@@ -13,6 +13,7 @@ export declare class OlsSearchApi extends OlsBaseApi {
|
|
|
13
13
|
*/
|
|
14
14
|
getSelectData(queryParams: SelectQueryParams, paginationParams?: PaginationParams, contentParams?: ContentParams, parameter?: string): Promise<Select>;
|
|
15
15
|
suggest: (queryParams: SuggestQueryParams, paginationParams?: PaginationParams, contentParams?: ContentParams, parameter?: string) => Promise<any>;
|
|
16
|
+
getSelectRequestUrl(queryParams: SelectQueryParams, paginationParams?: PaginationParams, contentParams?: ContentParams, parameter?: string): string;
|
|
16
17
|
}
|
|
17
18
|
export declare function splitAndApplyParams(url: URL, raw: string): void;
|
|
18
19
|
export declare function normalizeBaseApi(api: string): string;
|
package/dist/app/types.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import { Action } from '@elastic/eui/src/components/basic_table/action_types';
|
|
|
3
3
|
import { EuiComboBoxProps } from '@elastic/eui/src/components/combo_box/combo_box';
|
|
4
4
|
import { EuiLinkColor } from '@elastic/eui/src/components/link/link';
|
|
5
5
|
import { EuiTextProps } from '@elastic/eui/src/components/text/text';
|
|
6
|
+
import { EntityValue } from '../components/widgets/AutocompleteWidget/AutocompleteWidget';
|
|
6
7
|
import { Thing } from '../model/interfaces';
|
|
7
8
|
import { BuildHierarchyProps, HierarchyIriProp } from '../model/interfaces/HierarchyBuilder';
|
|
8
9
|
import { EntityTypeName, ThingTypeName } from '../model/ModelTypeCheck';
|
|
@@ -146,36 +147,15 @@ type TabList = {
|
|
|
146
147
|
* */
|
|
147
148
|
initialSelectedTab?: string;
|
|
148
149
|
};
|
|
149
|
-
export type
|
|
150
|
-
/**
|
|
151
|
-
* The terms metadata that autocomplete selection change event returns to the client.
|
|
152
|
-
*/
|
|
153
|
-
iri?: string;
|
|
154
|
-
description?: string;
|
|
155
|
-
label: string;
|
|
156
|
-
ontology_name?: string;
|
|
157
|
-
short_form?: string;
|
|
158
|
-
source?: string;
|
|
159
|
-
type?: string;
|
|
160
|
-
};
|
|
161
|
-
export type AutocompleteWidgetProps = EuiComboBoxProps<string> & ParameterObj & ApiObj & CssClassNameObj & UseLegacyObj & OnNavigateToOntology & {
|
|
150
|
+
export type AutocompleteWidgetProps = Partial<EuiComboBoxProps<EntityValue>> & ParameterObj & ApiObj & CssClassNameObj & UseLegacyObj & OnNavigateToOntology & {
|
|
162
151
|
/**
|
|
163
152
|
* A method that is called once the set of selection changes
|
|
164
153
|
*/
|
|
165
|
-
selectionChangedEvent: (selectedOptions:
|
|
154
|
+
selectionChangedEvent: (selectedOptions: EntityValue[]) => void;
|
|
166
155
|
/**
|
|
167
156
|
* Pass pre-selected values. If `singleSelection == true`, only the first one is displayed.
|
|
168
157
|
*/
|
|
169
|
-
preselected?:
|
|
170
|
-
label?: string;
|
|
171
|
-
iri?: string;
|
|
172
|
-
description?: string;
|
|
173
|
-
ontology_name?: string;
|
|
174
|
-
type?: string;
|
|
175
|
-
short_form?: string;
|
|
176
|
-
source?: string;
|
|
177
|
-
source_url?: string;
|
|
178
|
-
}[];
|
|
158
|
+
preselected?: EntityValue[];
|
|
179
159
|
/**
|
|
180
160
|
* Placeholder to show if no user input nor selection is performed.
|
|
181
161
|
*/
|
|
@@ -204,6 +184,10 @@ export type AutocompleteWidgetProps = EuiComboBoxProps<string> & ParameterObj &
|
|
|
204
184
|
* Initial search value to show results on first render.
|
|
205
185
|
*/
|
|
206
186
|
initialSearchQuery?: string;
|
|
187
|
+
/**
|
|
188
|
+
* Show a button to open the search request.
|
|
189
|
+
*/
|
|
190
|
+
showApiRequestButton?: boolean;
|
|
207
191
|
};
|
|
208
192
|
export type DataContentWidgetProps = ApiObj & ParameterObj;
|
|
209
193
|
export type EntityInfoWidgetProps = ApiObj & OptionalEntityTypeObj & OptionalOntologyIdObj & ForcedIriObj & HasTitleObj & ShowBadgesObj & ParameterObj & UseLegacyObj & OnNavigates;
|
|
@@ -1,7 +1,19 @@
|
|
|
1
1
|
import { AutocompleteWidgetProps } from '../../../app';
|
|
2
|
+
export interface EntityValue {
|
|
3
|
+
iri?: string;
|
|
4
|
+
label?: string;
|
|
5
|
+
ontology_name?: string;
|
|
6
|
+
type?: string;
|
|
7
|
+
short_form?: string;
|
|
8
|
+
description?: string;
|
|
9
|
+
provider_name?: string;
|
|
10
|
+
provider_type?: string;
|
|
11
|
+
provider_api?: string;
|
|
12
|
+
synonyms?: string[];
|
|
13
|
+
}
|
|
2
14
|
/**
|
|
3
15
|
* A React component to provide Autosuggestion based on SemLookP.
|
|
4
16
|
*/
|
|
5
|
-
declare function AutocompleteWidget(props: AutocompleteWidgetProps):
|
|
6
|
-
declare function WrappedAutocompleteWidget(props: AutocompleteWidgetProps):
|
|
17
|
+
declare function AutocompleteWidget(props: AutocompleteWidgetProps): JSX.Element;
|
|
18
|
+
declare function WrappedAutocompleteWidget(props: AutocompleteWidgetProps): JSX.Element;
|
|
7
19
|
export { AutocompleteWidget, WrappedAutocompleteWidget };
|