synapse-react-client 2.1.23 → 3.0.2
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/containers/CardContainer.d.ts +0 -8
- package/dist/containers/CardContainer.js +13 -23
- package/dist/containers/CardContainer.js.map +1 -1
- package/dist/containers/CardContainerLogic.d.ts +3 -76
- package/dist/containers/CardContainerLogic.js +29 -150
- package/dist/containers/CardContainerLogic.js.map +1 -1
- package/dist/containers/EntityLink.js +2 -2
- package/dist/containers/EntityLink.js.map +1 -1
- package/dist/containers/FullTextSearch.d.ts +1 -5
- package/dist/containers/FullTextSearch.js +9 -9
- package/dist/containers/FullTextSearch.js.map +1 -1
- package/dist/containers/HasAccess.js +3 -2
- package/dist/containers/HasAccess.js.map +1 -1
- package/dist/containers/MarkdownPopover.js +1 -1
- package/dist/containers/MarkdownPopover.js.map +1 -1
- package/dist/containers/MissingQueryResultsWarning.d.ts +12 -0
- package/dist/containers/MissingQueryResultsWarning.js +64 -0
- package/dist/containers/MissingQueryResultsWarning.js.map +1 -0
- package/dist/containers/QueryCount.js +16 -44
- package/dist/containers/QueryCount.js.map +1 -1
- package/dist/containers/QueryVisualizationWrapper.d.ts +48 -0
- package/dist/containers/QueryVisualizationWrapper.js +81 -0
- package/dist/containers/QueryVisualizationWrapper.js.map +1 -0
- package/dist/containers/QueryWrapper.d.ts +55 -145
- package/dist/containers/QueryWrapper.js +188 -263
- package/dist/containers/QueryWrapper.js.map +1 -1
- package/dist/containers/QueryWrapperErrorBanner.d.ts +5 -0
- package/dist/containers/QueryWrapperErrorBanner.js +16 -0
- package/dist/containers/QueryWrapperErrorBanner.js.map +1 -0
- package/dist/containers/SearchV2.d.ts +6 -2
- package/dist/containers/SearchV2.js +11 -11
- package/dist/containers/SearchV2.js.map +1 -1
- package/dist/containers/SqlEditor.d.ts +1 -5
- package/dist/containers/SqlEditor.js +8 -7
- package/dist/containers/SqlEditor.js.map +1 -1
- package/dist/containers/TotalQueryResults.d.ts +3 -6
- package/dist/containers/TotalQueryResults.js +42 -58
- package/dist/containers/TotalQueryResults.js.map +1 -1
- package/dist/containers/download_list/DownloadConfirmation.d.ts +4 -4
- package/dist/containers/download_list/DownloadConfirmation.js +15 -17
- package/dist/containers/download_list/DownloadConfirmation.js.map +1 -1
- package/dist/containers/home_page/featured-data/FacetPlotsCard.d.ts +1 -4
- package/dist/containers/home_page/featured-data/FacetPlotsCard.js +11 -8
- package/dist/containers/home_page/featured-data/FacetPlotsCard.js.map +1 -1
- package/dist/containers/home_page/featured-data/QueryPerFacetPlotsCard.d.ts +1 -1
- package/dist/containers/home_page/featured-data/QueryPerFacetPlotsCard.js +8 -9
- package/dist/containers/home_page/featured-data/QueryPerFacetPlotsCard.js.map +1 -1
- package/dist/containers/home_page/featured-data/SingleQueryFacetPlotsCards.d.ts +1 -1
- package/dist/containers/home_page/featured-data/SingleQueryFacetPlotsCards.js +10 -11
- package/dist/containers/home_page/featured-data/SingleQueryFacetPlotsCards.js.map +1 -1
- package/dist/containers/query_wrapper_plot_nav/FilterAndView.d.ts +2 -4
- package/dist/containers/query_wrapper_plot_nav/FilterAndView.js +12 -5
- package/dist/containers/query_wrapper_plot_nav/FilterAndView.js.map +1 -1
- package/dist/containers/query_wrapper_plot_nav/QueryFilterToggleButton.d.ts +1 -2
- package/dist/containers/query_wrapper_plot_nav/QueryFilterToggleButton.js +9 -10
- package/dist/containers/query_wrapper_plot_nav/QueryFilterToggleButton.js.map +1 -1
- package/dist/containers/query_wrapper_plot_nav/QueryWrapperPlotNav.d.ts +4 -4
- package/dist/containers/query_wrapper_plot_nav/QueryWrapperPlotNav.js +53 -35
- package/dist/containers/query_wrapper_plot_nav/QueryWrapperPlotNav.js.map +1 -1
- package/dist/containers/synapse_form_wrapper/SynapseFormWrapper.js +1 -1
- package/dist/containers/synapse_form_wrapper/SynapseFormWrapper.js.map +1 -1
- package/dist/containers/table/StandaloneQueryWrapper.d.ts +4 -6
- package/dist/containers/table/StandaloneQueryWrapper.js +29 -19
- package/dist/containers/table/StandaloneQueryWrapper.js.map +1 -1
- package/dist/containers/table/SynapseTable.d.ts +12 -13
- package/dist/containers/table/SynapseTable.js +100 -136
- package/dist/containers/table/SynapseTable.js.map +1 -1
- package/dist/containers/table/TopLevelControls.d.ts +1 -4
- package/dist/containers/table/TopLevelControls.js +31 -44
- package/dist/containers/table/TopLevelControls.js.map +1 -1
- package/dist/containers/table/table-top/ColumnSelection.d.ts +1 -1
- package/dist/containers/table/table-top/ColumnSelection.js +3 -5
- package/dist/containers/table/table-top/ColumnSelection.js.map +1 -1
- package/dist/containers/table/table-top/DownloadOptions.d.ts +0 -2
- package/dist/containers/table/table-top/DownloadOptions.js +7 -6
- package/dist/containers/table/table-top/DownloadOptions.js.map +1 -1
- package/dist/containers/table/table-top/ProgrammaticTableDownload.js +15 -8
- package/dist/containers/table/table-top/ProgrammaticTableDownload.js.map +1 -1
- package/dist/containers/widgets/facet-nav/FacetNav.d.ts +1 -3
- package/dist/containers/widgets/facet-nav/FacetNav.js +14 -10
- package/dist/containers/widgets/facet-nav/FacetNav.js.map +1 -1
- package/dist/containers/widgets/facet-nav/FacetNavPanel.d.ts +5 -8
- package/dist/containers/widgets/facet-nav/FacetNavPanel.js +15 -12
- package/dist/containers/widgets/facet-nav/FacetNavPanel.js.map +1 -1
- package/dist/containers/widgets/query-filter/EnumFacetFilter.d.ts +3 -3
- package/dist/containers/widgets/query-filter/EnumFacetFilter.js +2 -2
- package/dist/containers/widgets/query-filter/EnumFacetFilter.js.map +1 -1
- package/dist/containers/widgets/query-filter/QueryFilter.d.ts +7 -12
- package/dist/containers/widgets/query-filter/QueryFilter.js +12 -9
- package/dist/containers/widgets/query-filter/QueryFilter.js.map +1 -1
- package/dist/containers/widgets/query-filter/RangeFacetFilter.d.ts +4 -4
- package/dist/containers/widgets/query-filter/RangeFacetFilter.js +4 -4
- package/dist/containers/widgets/query-filter/RangeFacetFilter.js.map +1 -1
- package/dist/index.d.ts +3 -6
- package/dist/index.js +3 -5
- package/dist/index.js.map +1 -1
- package/dist/style/base/_icons.scss +4 -0
- package/dist/style/components/_dataset-editor.scss +6 -0
- package/dist/style/components/_markdown.scss +1 -1
- package/dist/style/components/entity_finder/_details-view.scss +6 -6
- package/dist/style/components/entity_finder/_entity-finder.scss +3 -7
- package/dist/style/components/entity_finder/_tree-node-browse.scss +1 -3
- package/dist/style/components/entity_finder/_tree-node-select.scss +0 -4
- package/dist/style/components/query_filter/_enum-facet-filter.scss +4 -1
- package/dist/style/main.css +887 -19
- package/dist/template_style/_form.scss +150 -105
- package/dist/umd/synapse-react-client.development.css +805 -19
- package/dist/umd/synapse-react-client.development.css.map +2 -2
- package/dist/umd/synapse-react-client.development.js +3792 -3581
- package/dist/umd/synapse-react-client.development.js.map +3 -3
- package/dist/umd/synapse-react-client.production.min.css +1 -1
- package/dist/umd/synapse-react-client.production.min.js +89 -89
- package/dist/utils/APIConstants.d.ts +3 -0
- package/dist/utils/APIConstants.js +12 -2
- package/dist/utils/APIConstants.js.map +1 -1
- package/dist/utils/SynapseClient.d.ts +47 -20
- package/dist/utils/SynapseClient.js +278 -209
- package/dist/utils/SynapseClient.js.map +1 -1
- package/dist/utils/SynapseConstants.d.ts +1 -0
- package/dist/utils/SynapseConstants.js +3 -2
- package/dist/utils/SynapseConstants.js.map +1 -1
- package/dist/utils/functions/EntityTypeUtils.d.ts +13 -1
- package/dist/utils/functions/EntityTypeUtils.js +25 -1
- package/dist/utils/functions/EntityTypeUtils.js.map +1 -1
- package/dist/utils/functions/queryUtils.d.ts +2 -2
- package/dist/utils/functions/queryUtils.js +22 -5
- package/dist/utils/functions/queryUtils.js.map +1 -1
- package/dist/utils/functions/sqlFunctions.d.ts +4 -0
- package/dist/utils/functions/sqlFunctions.js +14 -2
- package/dist/utils/functions/sqlFunctions.js.map +1 -1
- package/dist/utils/functions/unCamelCase.d.ts +1 -1
- package/dist/utils/functions/unCamelCase.js.map +1 -1
- package/dist/utils/hooks/SynapseAPI/useGetQueryResultBundle.d.ts +4 -3
- package/dist/utils/hooks/SynapseAPI/useGetQueryResultBundle.js +67 -1
- package/dist/utils/hooks/SynapseAPI/useGetQueryResultBundle.js.map +1 -1
- package/dist/utils/synapseTypes/Entity/Entity.js.map +1 -1
- package/dist/utils/synapseTypes/Table/AsynchronousJobStatus.d.ts +5 -4
- package/dist/utils/synapseTypes/Table/EntityView.d.ts +8 -0
- package/dist/utils/synapseTypes/Table/EntityView.js +9 -0
- package/dist/utils/synapseTypes/Table/EntityView.js.map +1 -1
- package/dist/utils/synapseTypes/Table/FacetColumnRequest.d.ts +1 -1
- package/dist/utils/synapseTypes/Table/FacetColumnResult.d.ts +10 -10
- package/dist/utils/synapseTypes/Table/QueryResultBundle.d.ts +1 -0
- package/package.json +46 -39
- package/dist/containers/StackedBarChart.d.ts +0 -63
- package/dist/containers/StackedBarChart.js +0 -229
- package/dist/containers/StackedBarChart.js.map +0 -1
- package/dist/utils/functions/facetUtils.d.ts +0 -20
- package/dist/utils/functions/facetUtils.js +0 -37
- package/dist/utils/functions/facetUtils.js.map +0 -1
- package/dist/utils/synapseTypes/DownloadListV2/DownloadListManifestResponse.d.ts +0 -4
- package/dist/utils/synapseTypes/DownloadListV2/DownloadListManifestResponse.js +0 -3
- package/dist/utils/synapseTypes/DownloadListV2/DownloadListManifestResponse.js.map +0 -1
|
@@ -1,11 +1,77 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.useInfiniteQueryResultBundle = void 0;
|
|
4
|
+
var tslib_1 = require("tslib");
|
|
3
5
|
var react_query_1 = require("react-query");
|
|
4
6
|
var __1 = require("../..");
|
|
7
|
+
var SynapseConstants_1 = require("../../SynapseConstants");
|
|
5
8
|
var SynapseContext_1 = require("../../SynapseContext");
|
|
6
9
|
function useGetQueryResultBundle(queryBundleRequest, options) {
|
|
7
10
|
var accessToken = (0, SynapseContext_1.useSynapseContext)().accessToken;
|
|
8
|
-
return (0, react_query_1.useQuery)(['queryResultBundle',
|
|
11
|
+
return (0, react_query_1.useQuery)(['queryResultBundle', queryBundleRequest], function () { return __1.SynapseClient.getQueryTableResults(queryBundleRequest, accessToken); }, options);
|
|
9
12
|
}
|
|
10
13
|
exports.default = useGetQueryResultBundle;
|
|
14
|
+
function useInfiniteQueryResultBundle(queryBundleRequest, options) {
|
|
15
|
+
var accessToken = (0, SynapseContext_1.useSynapseContext)().accessToken;
|
|
16
|
+
return (0, react_query_1.useInfiniteQuery)(['queryResultBundle', queryBundleRequest, 'infinite'], function (context) {
|
|
17
|
+
var offset = context.pageParam ? parseInt(context.pageParam) : 0;
|
|
18
|
+
return __1.SynapseClient.getQueryTableAsyncJobResults((0, tslib_1.__assign)((0, tslib_1.__assign)({}, queryBundleRequest), { query: (0, tslib_1.__assign)((0, tslib_1.__assign)({}, queryBundleRequest.query), { offset: offset }),
|
|
19
|
+
/**
|
|
20
|
+
* If we're on the first page, send the original partMask.
|
|
21
|
+
* Otherwise, just ask for the queryResults (if they're in the original partMask), as it's the only part that changes between pages.
|
|
22
|
+
*
|
|
23
|
+
* We'll merge the "aggregation" parts and the pages of queryResults in the `select` function.
|
|
24
|
+
*/
|
|
25
|
+
partMask: offset !== 0
|
|
26
|
+
? queryBundleRequest.partMask & SynapseConstants_1.BUNDLE_MASK_QUERY_RESULTS
|
|
27
|
+
: queryBundleRequest.partMask }), accessToken);
|
|
28
|
+
}, (0, tslib_1.__assign)((0, tslib_1.__assign)({}, options), { select: function (data) {
|
|
29
|
+
/**
|
|
30
|
+
* Since we we only fetch queryResults on 2nd and subsequent pages, we add to all pages the aggregate parts
|
|
31
|
+
* that we only fetched on the first page.
|
|
32
|
+
*/
|
|
33
|
+
var firstPage = data === null || data === void 0 ? void 0 : data.pages[0];
|
|
34
|
+
if (firstPage.responseBody) {
|
|
35
|
+
for (var i = 0; i < data.pages.length; i++) {
|
|
36
|
+
var page = data.pages[i];
|
|
37
|
+
if (page.responseBody != null) {
|
|
38
|
+
data.pages[i].responseBody = (0, tslib_1.__assign)((0, tslib_1.__assign)({}, firstPage.responseBody), {
|
|
39
|
+
// queryResult changes on each page.
|
|
40
|
+
queryResult: page.responseBody.queryResult });
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
return data;
|
|
45
|
+
}, getPreviousPageParam: function (firstPage) {
|
|
46
|
+
var _a;
|
|
47
|
+
if (firstPage.jobState !== 'COMPLETE') {
|
|
48
|
+
return undefined;
|
|
49
|
+
}
|
|
50
|
+
var request = firstPage.requestBody;
|
|
51
|
+
if (request.query.offset == null || request.query.offset === 0) {
|
|
52
|
+
return undefined;
|
|
53
|
+
}
|
|
54
|
+
var pageSize = (_a = request.query.limit) !== null && _a !== void 0 ? _a : SynapseConstants_1.DEFAULT_PAGE_SIZE;
|
|
55
|
+
return Math.max(request.query.offset - pageSize, 0);
|
|
56
|
+
}, getNextPageParam: function (page, allPages) {
|
|
57
|
+
var _a, _b, _c, _d;
|
|
58
|
+
if (page.jobState !== 'COMPLETE') {
|
|
59
|
+
return undefined;
|
|
60
|
+
}
|
|
61
|
+
var request = page.requestBody;
|
|
62
|
+
var pageSize = (_a = request.query.limit) !== null && _a !== void 0 ? _a : SynapseConstants_1.DEFAULT_PAGE_SIZE;
|
|
63
|
+
var totalQueryResultCount = (_b = allPages[0].responseBody) === null || _b === void 0 ? void 0 : _b.queryCount;
|
|
64
|
+
if (totalQueryResultCount != null) {
|
|
65
|
+
// We know the total number of results. See if our offset + pageSize is >= the total
|
|
66
|
+
if (((_c = request.query.offset) !== null && _c !== void 0 ? _c : 0) + pageSize >= totalQueryResultCount) {
|
|
67
|
+
return undefined;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
return page.responseBody.queryResult.queryResults.rows.length ===
|
|
71
|
+
pageSize
|
|
72
|
+
? ((_d = request.query.offset) !== null && _d !== void 0 ? _d : 0) + pageSize
|
|
73
|
+
: undefined;
|
|
74
|
+
} }));
|
|
75
|
+
}
|
|
76
|
+
exports.useInfiniteQueryResultBundle = useInfiniteQueryResultBundle;
|
|
11
77
|
//# sourceMappingURL=useGetQueryResultBundle.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useGetQueryResultBundle.js","sourceRoot":"","sources":["../../../../src/lib/utils/hooks/SynapseAPI/useGetQueryResultBundle.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"useGetQueryResultBundle.js","sourceRoot":"","sources":["../../../../src/lib/utils/hooks/SynapseAPI/useGetQueryResultBundle.ts"],"names":[],"mappings":"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"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Entity.js","sourceRoot":"","sources":["../../../../src/lib/utils/synapseTypes/Entity/Entity.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"Entity.js","sourceRoot":"","sources":["../../../../src/lib/utils/synapseTypes/Entity/Entity.ts"],"names":[],"mappings":";;;AAoGA;;;;;;GAMG;AACU,QAAA,cAAc,GAAG;IAC5B,MAAM;IACN,aAAa;IACb,IAAI;IACJ,MAAM;IACN,WAAW;IACX,YAAY;IACZ,WAAW;IACX,YAAY;IACZ,UAAU;IACV,cAAc;IACd,eAAe;IACf,cAAc;IACd,gBAAgB;IAChB,iBAAiB;IACjB,kBAAkB;IAClB,kBAAkB;IAClB,WAAW;IACX,UAAU;IACV,SAAS;IACT,kBAAkB;IAClB,gBAAgB;IAChB,WAAW;IACX,cAAc;IACd,MAAM;IACN,OAAO;IACP,OAAO;IACP,aAAa;CACd,CAAA"}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
export declare type
|
|
2
|
-
|
|
1
|
+
export declare type AsynchJobState = 'PROCESSING' | 'FAILED' | 'COMPLETE';
|
|
2
|
+
export declare type AsynchronousJobStatus<TRequest, TResponse> = {
|
|
3
|
+
jobState: AsynchJobState;
|
|
3
4
|
jobCanceling: boolean;
|
|
4
|
-
requestBody:
|
|
5
|
-
responseBody
|
|
5
|
+
requestBody: TRequest;
|
|
6
|
+
responseBody?: TResponse;
|
|
6
7
|
etag: string;
|
|
7
8
|
jobId: string;
|
|
8
9
|
startedByUserId: number;
|
|
@@ -1,4 +1,12 @@
|
|
|
1
1
|
import { View } from './View';
|
|
2
|
+
export declare const ENTITY_VIEW_TYPE_MASK_FILE = 1;
|
|
3
|
+
export declare const ENTITY_VIEW_TYPE_MASK_PROJECT = 2;
|
|
4
|
+
export declare const ENTITY_VIEW_TYPE_MASK_TABLE = 4;
|
|
5
|
+
export declare const ENTITY_VIEW_TYPE_MASK_FOLDER = 8;
|
|
6
|
+
export declare const ENTITY_VIEW_TYPE_MASK_VIEW = 16;
|
|
7
|
+
export declare const ENTITY_VIEW_TYPE_MASK_DOCKER = 32;
|
|
8
|
+
export declare const ENTITY_VIEW_TYPE_MASK_SUBMISSIONVIEW = 64;
|
|
9
|
+
export declare const ENTITY_VIEW_TYPE_MASK_DATASET = 128;
|
|
2
10
|
export declare type ENTITY_VIEW_CONCRETE_TYPE = 'org.sagebionetworks.repo.model.table.EntityView';
|
|
3
11
|
export interface EntityView extends View {
|
|
4
12
|
concreteType: ENTITY_VIEW_CONCRETE_TYPE;
|
|
@@ -1,3 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ENTITY_VIEW_TYPE_MASK_DATASET = exports.ENTITY_VIEW_TYPE_MASK_SUBMISSIONVIEW = exports.ENTITY_VIEW_TYPE_MASK_DOCKER = exports.ENTITY_VIEW_TYPE_MASK_VIEW = exports.ENTITY_VIEW_TYPE_MASK_FOLDER = exports.ENTITY_VIEW_TYPE_MASK_TABLE = exports.ENTITY_VIEW_TYPE_MASK_PROJECT = exports.ENTITY_VIEW_TYPE_MASK_FILE = void 0;
|
|
4
|
+
exports.ENTITY_VIEW_TYPE_MASK_FILE = 0x01;
|
|
5
|
+
exports.ENTITY_VIEW_TYPE_MASK_PROJECT = 0x02;
|
|
6
|
+
exports.ENTITY_VIEW_TYPE_MASK_TABLE = 0x04;
|
|
7
|
+
exports.ENTITY_VIEW_TYPE_MASK_FOLDER = 0x08;
|
|
8
|
+
exports.ENTITY_VIEW_TYPE_MASK_VIEW = 0x10;
|
|
9
|
+
exports.ENTITY_VIEW_TYPE_MASK_DOCKER = 0x20;
|
|
10
|
+
exports.ENTITY_VIEW_TYPE_MASK_SUBMISSIONVIEW = 0x40;
|
|
11
|
+
exports.ENTITY_VIEW_TYPE_MASK_DATASET = 0x80;
|
|
3
12
|
//# sourceMappingURL=EntityView.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EntityView.js","sourceRoot":"","sources":["../../../../src/lib/utils/synapseTypes/Table/EntityView.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"EntityView.js","sourceRoot":"","sources":["../../../../src/lib/utils/synapseTypes/Table/EntityView.ts"],"names":[],"mappings":";;;AAEa,QAAA,0BAA0B,GAAG,IAAI,CAAA;AACjC,QAAA,6BAA6B,GAAG,IAAI,CAAA;AACpC,QAAA,2BAA2B,GAAG,IAAI,CAAA;AAClC,QAAA,4BAA4B,GAAG,IAAI,CAAA;AACnC,QAAA,0BAA0B,GAAG,IAAI,CAAA;AACjC,QAAA,4BAA4B,GAAG,IAAI,CAAA;AACnC,QAAA,oCAAoC,GAAG,IAAI,CAAA;AAC3C,QAAA,6BAA6B,GAAG,IAAI,CAAA"}
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
export
|
|
1
|
+
export declare type FacetColumnResultValues = {
|
|
2
|
+
concreteType: 'org.sagebionetworks.repo.model.table.FacetColumnResultValues';
|
|
3
|
+
columnName: string;
|
|
4
|
+
facetType: 'enumeration';
|
|
2
5
|
facetValues: FacetColumnResultValueCount[];
|
|
3
|
-
}
|
|
6
|
+
};
|
|
4
7
|
export declare type FacetColumnResultValueCount = {
|
|
5
8
|
value: string;
|
|
6
9
|
count: number;
|
|
7
10
|
isSelected: boolean;
|
|
8
11
|
};
|
|
9
|
-
export
|
|
10
|
-
concreteType:
|
|
12
|
+
export declare type FacetColumnResultRange = {
|
|
13
|
+
concreteType: 'org.sagebionetworks.repo.model.table.FacetColumnResultRange';
|
|
14
|
+
facetType: 'range';
|
|
11
15
|
columnName: string;
|
|
12
16
|
columnMin: string;
|
|
13
17
|
columnMax: string;
|
|
14
18
|
selectedMin?: string;
|
|
15
19
|
selectedMax?: string;
|
|
16
|
-
}
|
|
17
|
-
export
|
|
18
|
-
concreteType: string;
|
|
19
|
-
columnName: string;
|
|
20
|
-
facetType: 'enumeration' | 'range';
|
|
21
|
-
}
|
|
20
|
+
};
|
|
21
|
+
export declare type FacetColumnResult = FacetColumnResultValues | FacetColumnResultRange;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "synapse-react-client",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.2",
|
|
4
4
|
"private": false,
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
"url": "https://github.com/Sage-Bionetworks/Synapse-React-Client"
|
|
16
16
|
},
|
|
17
17
|
"dependencies": {
|
|
18
|
+
"@apidevtools/json-schema-ref-parser": "^9.0.9",
|
|
18
19
|
"@brainhubeu/react-carousel": "1.19.26",
|
|
19
20
|
"@fortawesome/fontawesome-free": "^5.13.0",
|
|
20
21
|
"@fortawesome/fontawesome-svg-core": "^1.2.4",
|
|
@@ -25,7 +26,7 @@
|
|
|
25
26
|
"@material-ui/icons": "^4.11.2",
|
|
26
27
|
"@material-ui/lab": "^4.0.0-alpha.57",
|
|
27
28
|
"@popperjs/core": "^2.10.2",
|
|
28
|
-
"@rjsf/core": "^
|
|
29
|
+
"@rjsf/core": "^4.0.1",
|
|
29
30
|
"@sage-bionetworks/react-base-table": "^1.12.3",
|
|
30
31
|
"@sage-bionetworks/rjsf-core": "^3.1.4",
|
|
31
32
|
"@types/ua-parser-js": "^0.7.36",
|
|
@@ -37,10 +38,9 @@
|
|
|
37
38
|
"gh-pages": "^2.0.0",
|
|
38
39
|
"immutable": "4.0.0-rc.15",
|
|
39
40
|
"json-rules-engine": "^4.0.0",
|
|
40
|
-
"json-schema-ref-parser": "^7.1.1",
|
|
41
41
|
"katex": "0.11.1",
|
|
42
42
|
"lodash-es": ">=4.17.14",
|
|
43
|
-
"markdown-it": "^
|
|
43
|
+
"markdown-it": "^12.3.2",
|
|
44
44
|
"markdown-it-br": "^1.0.0",
|
|
45
45
|
"markdown-it-center-text": "^1.0.4",
|
|
46
46
|
"markdown-it-container": "^2.0.0",
|
|
@@ -55,15 +55,15 @@
|
|
|
55
55
|
"markdown-it-synapse-table": "^1.0.6",
|
|
56
56
|
"moment": "^2.24.0",
|
|
57
57
|
"moment-timezone": "^0.5.32",
|
|
58
|
-
"plotly.js-basic-dist": "^
|
|
58
|
+
"plotly.js-basic-dist": "^2.11.1",
|
|
59
59
|
"pluralize": "^8.0.0",
|
|
60
60
|
"raf": "^3.4.1",
|
|
61
|
-
"react": "16.
|
|
62
|
-
"react-app-polyfill": "^
|
|
61
|
+
"react": "16.14.0",
|
|
62
|
+
"react-app-polyfill": "^3.0.0",
|
|
63
63
|
"react-bootstrap": "^1.5.2",
|
|
64
64
|
"react-compound-slider": "^2.5.0",
|
|
65
65
|
"react-datetime": "^3.0.4",
|
|
66
|
-
"react-dom": "16.
|
|
66
|
+
"react-dom": "16.14.0",
|
|
67
67
|
"react-error-boundary": "^3.1.1",
|
|
68
68
|
"react-hot-toast": "^2.1.0",
|
|
69
69
|
"react-intersection-observer": "^8.31.0",
|
|
@@ -74,22 +74,22 @@
|
|
|
74
74
|
"react-popper": "^2.2.5",
|
|
75
75
|
"react-query": "3.33.1",
|
|
76
76
|
"react-reflex": "^4.0.0",
|
|
77
|
+
"react-router": "5.2.1",
|
|
77
78
|
"react-router-dom": "5.3.0",
|
|
78
|
-
"react-scripts": "^4.0.3",
|
|
79
79
|
"react-select": "^4.3.1",
|
|
80
80
|
"react-sizeme": "^2.6.12",
|
|
81
81
|
"react-switch": "^5.0.1",
|
|
82
|
-
"react-test-renderer": "16.
|
|
82
|
+
"react-test-renderer": "16.14.0",
|
|
83
83
|
"react-tooltip": "^4.2.21",
|
|
84
|
-
"react-transition-group": "
|
|
84
|
+
"react-transition-group": "4.4.2",
|
|
85
85
|
"react-virtualized-auto-sizer": "^1.0.6",
|
|
86
86
|
"react-vtree": "3.0.0-beta.3",
|
|
87
87
|
"react-window": "^1.8.6",
|
|
88
88
|
"regenerator-runtime": "^0.13.2",
|
|
89
89
|
"rss-parser": "^3.7.2",
|
|
90
|
-
"sanitize-html": "^2.
|
|
90
|
+
"sanitize-html": "^2.7.0",
|
|
91
91
|
"sass": "^1.30.0",
|
|
92
|
-
"shortid": "^2.2.
|
|
92
|
+
"shortid": "^2.2.16",
|
|
93
93
|
"spark-md5": "^3.0.0",
|
|
94
94
|
"sql-parser": "^0.5.0",
|
|
95
95
|
"tslib": "^2.3.1",
|
|
@@ -109,6 +109,7 @@
|
|
|
109
109
|
"@babel/preset-typescript": "^7.14.5",
|
|
110
110
|
"@babel/runtime": "^7.14.6",
|
|
111
111
|
"@babel/types": "^7.14.5",
|
|
112
|
+
"@craco/craco": "^6.4.3",
|
|
112
113
|
"@fal-works/esbuild-plugin-global-externals": "^2.1.2",
|
|
113
114
|
"@sage-bionetworks/esbuild-plugin-svgr": "^0.0.4",
|
|
114
115
|
"@testing-library/dom": "^8.1.0",
|
|
@@ -119,19 +120,19 @@
|
|
|
119
120
|
"@types/brainhubeu__react-carousel": "1.15.0",
|
|
120
121
|
"@types/enzyme": "^3.10.8",
|
|
121
122
|
"@types/enzyme-adapter-react-16": "^1.0.5",
|
|
122
|
-
"@types/jest": "^
|
|
123
|
-
"@types/jest-when": "^
|
|
123
|
+
"@types/jest": "^27.4.1",
|
|
124
|
+
"@types/jest-when": "^3.5.0",
|
|
124
125
|
"@types/jquery": "^3.5.14",
|
|
125
126
|
"@types/katex": "^0.10.2",
|
|
126
127
|
"@types/lodash-es": "4.17.3",
|
|
127
128
|
"@types/markdown-it": "^12.0.1",
|
|
128
129
|
"@types/node": "^14.14.31",
|
|
129
|
-
"@types/plotly.js": "^1.54.
|
|
130
|
+
"@types/plotly.js": "^1.54.20",
|
|
130
131
|
"@types/plotly.js-basic-dist": "^1.54.0",
|
|
131
132
|
"@types/pluralize": "^0.0.29",
|
|
132
|
-
"@types/react": "16.
|
|
133
|
+
"@types/react": "^16.14.23",
|
|
133
134
|
"@types/react-addons-css-transition-group": "^15.0.5",
|
|
134
|
-
"@types/react-dom": "^16.9.
|
|
135
|
+
"@types/react-dom": "^16.9.14",
|
|
135
136
|
"@types/react-mailchimp-subscribe": "^2.0.2",
|
|
136
137
|
"@types/react-measure": "^2.0.4",
|
|
137
138
|
"@types/react-plotly.js": "^2.2.4",
|
|
@@ -145,8 +146,10 @@
|
|
|
145
146
|
"@types/sinon": "^7.0.2",
|
|
146
147
|
"@types/spark-md5": "^3.0.1",
|
|
147
148
|
"@types/xml2js": "^0.4.4",
|
|
148
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
149
|
-
"@typescript-eslint/parser": "^
|
|
149
|
+
"@typescript-eslint/eslint-plugin": "^5.13.0",
|
|
150
|
+
"@typescript-eslint/parser": "^5.13.0",
|
|
151
|
+
"browserify-fs": "^1.0.0",
|
|
152
|
+
"buffer": "^6.0.3",
|
|
150
153
|
"core-js": "^3.1.4",
|
|
151
154
|
"enzyme": "^3.11.0",
|
|
152
155
|
"enzyme-adapter-react-16": "^1.15.2",
|
|
@@ -154,21 +157,28 @@
|
|
|
154
157
|
"esbuild-plugin-globals": "^0.1.1",
|
|
155
158
|
"esbuild-plugin-node-polyfills": "^1.0.2",
|
|
156
159
|
"esbuild-sass-plugin": "^1.8.0",
|
|
157
|
-
"eslint-plugin-jest": "^
|
|
158
|
-
"eslint-plugin-jest-dom": "^
|
|
160
|
+
"eslint-plugin-jest": "^26.1.1",
|
|
161
|
+
"eslint-plugin-jest-dom": "^4.0.1",
|
|
159
162
|
"eslint-plugin-react": "latest",
|
|
160
|
-
"eslint-plugin-react-hooks": "^
|
|
161
|
-
"eslint-plugin-testing-library": "^
|
|
163
|
+
"eslint-plugin-react-hooks": "^4.3.0",
|
|
164
|
+
"eslint-plugin-testing-library": "^5.0.6",
|
|
165
|
+
"https-browserify": "^1.0.0",
|
|
162
166
|
"identity-obj-proxy": "^3.0.0",
|
|
163
167
|
"jest-mock-promise": "^1.1.10",
|
|
164
|
-
"jest-when": "^3.
|
|
165
|
-
"msw": "^0.
|
|
168
|
+
"jest-when": "^3.5.1",
|
|
169
|
+
"msw": "^0.38.2",
|
|
166
170
|
"npm": "^6.9.0",
|
|
167
171
|
"npm-run-all": "^4.1.3",
|
|
172
|
+
"path-browserify": "^1.0.1",
|
|
173
|
+
"postcss-normalize": "^10.0.1",
|
|
168
174
|
"prettier": "^2.1.2",
|
|
175
|
+
"process": "^0.11.10",
|
|
176
|
+
"react-scripts": "^5.0.0",
|
|
169
177
|
"react-select-event": "^5.3.0",
|
|
170
|
-
"react-styleguidist": "^11.
|
|
178
|
+
"react-styleguidist": "^11.2.0",
|
|
171
179
|
"sinon": "^7.2.2",
|
|
180
|
+
"stream-browserify": "^3.0.0",
|
|
181
|
+
"stream-http": "^3.2.0",
|
|
172
182
|
"timers-browserify": "^2.0.12",
|
|
173
183
|
"typescript": "4.4.3",
|
|
174
184
|
"yarn": "^1.22.17"
|
|
@@ -188,13 +198,13 @@
|
|
|
188
198
|
"deploy": "gh-pages -d styleguide && gh-pages -d styleguide -o upstream",
|
|
189
199
|
"deploy:origin": "yarn install && yarn run predeploy && gh-pages -d styleguide && gh-pages -d styleguide -o origin",
|
|
190
200
|
"watch:css": "yarn run build:css && sass src --watch --load-path=node_modules",
|
|
191
|
-
"start-js": "
|
|
201
|
+
"start-js": "craco start",
|
|
192
202
|
"start": "npm-run-all -p watch:css serve:docs",
|
|
193
203
|
"start-deprecated-demo": "npm-run-all -p watch:css start-js",
|
|
194
|
-
"test": "
|
|
204
|
+
"test": "craco test --transformIgnorePatterns \"node_modules/(?!(lodash-es|jest*)/)\" , --env=jsdom --setupFilesAfterEnv ./src/setupTests.js --resetMocks false",
|
|
195
205
|
"test:coverage": "yarn test --coverage",
|
|
196
206
|
"test:noPrompt": "CI=true yarn test",
|
|
197
|
-
"eject": "
|
|
207
|
+
"eject": "craco eject",
|
|
198
208
|
"type-check": "tsc --noEmit",
|
|
199
209
|
"type-check:watch": "yarn run type-check --watch",
|
|
200
210
|
"build": "yarn run build:css && yarn run build:js && yarn run build:copy-assets && yarn build:esbuild",
|
|
@@ -202,21 +212,18 @@
|
|
|
202
212
|
"build:js": "tsc --p tsconfig.build.json",
|
|
203
213
|
"build:copy-assets": "cd src/lib && find . -name '*.scss' -o -name '*.css' -o -name '*.svg' | cpio -pdm ../../dist/",
|
|
204
214
|
"build:esbuild": "node esbuild.config.mjs && cp -r src/umd dist/",
|
|
205
|
-
"serve:docs": "
|
|
206
|
-
"build:docs": "yarn run build:css &&
|
|
215
|
+
"serve:docs": "npx styleguidist server --open",
|
|
216
|
+
"build:docs": "yarn run build:css && npx styleguidist build",
|
|
207
217
|
"link-src": "yarn link && cd ./node_modules/react && yarn link && cd ../react-router && yarn link && cd ../react-router-dom && yarn link && cd ../../",
|
|
208
218
|
"unlink-src": "yarn unlink && cd ./node_modules/react && yarn unlink && cd ../react-router && yarn unlink && cd ../react-router-dom && yarn unlink && cd ../../"
|
|
209
219
|
},
|
|
210
220
|
"resolutions": {
|
|
211
|
-
"fstream": "1.0.12",
|
|
212
221
|
"js-yaml": "3.13.1",
|
|
213
222
|
"minimatch": "3.0.4",
|
|
214
|
-
"
|
|
215
|
-
"react": "16.
|
|
216
|
-
"react
|
|
217
|
-
"@types/
|
|
218
|
-
"**/@typescript-eslint/eslint-plugin": "^4.28.3",
|
|
219
|
-
"**/@typescript-eslint/parser": "^4.28.3"
|
|
223
|
+
"react": "16.14.0",
|
|
224
|
+
"react-dom": "16.14.0",
|
|
225
|
+
"@types/react": "^16.14.23",
|
|
226
|
+
"@types/webpack": "^5.28.0"
|
|
220
227
|
},
|
|
221
228
|
"browser": {
|
|
222
229
|
"timers": "timers-browserify"
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { QueryWrapperChildProps } from './QueryWrapper';
|
|
3
|
-
import { QueryResultBundle } from '../utils/synapseTypes/';
|
|
4
|
-
export declare const PREVIOUS_ITEM_CLICK = "left click";
|
|
5
|
-
export declare const NEXT_CLICK = "right click";
|
|
6
|
-
declare type Rect = {
|
|
7
|
-
height: number;
|
|
8
|
-
width: number;
|
|
9
|
-
top: number;
|
|
10
|
-
left: number;
|
|
11
|
-
right: number;
|
|
12
|
-
bottom: number;
|
|
13
|
-
};
|
|
14
|
-
declare type MeasureRect = {
|
|
15
|
-
bounds: Rect;
|
|
16
|
-
};
|
|
17
|
-
export declare type StackedBarChartState = {
|
|
18
|
-
selectedFacets: {};
|
|
19
|
-
dimensions: MeasureRect;
|
|
20
|
-
};
|
|
21
|
-
export declare type StackedBarChartProps = {
|
|
22
|
-
link?: string;
|
|
23
|
-
linkText?: string;
|
|
24
|
-
};
|
|
25
|
-
declare type Info = {
|
|
26
|
-
value: string;
|
|
27
|
-
count: number;
|
|
28
|
-
index: number;
|
|
29
|
-
};
|
|
30
|
-
declare type InternalProps = StackedBarChartProps & QueryWrapperChildProps;
|
|
31
|
-
/**
|
|
32
|
-
* Make a simple stacked bar chart
|
|
33
|
-
*
|
|
34
|
-
* @class StackedBarChart
|
|
35
|
-
* @extends {React.Component}
|
|
36
|
-
*/
|
|
37
|
-
export default class StackedBarChart extends React.Component<InternalProps, StackedBarChartState> {
|
|
38
|
-
constructor(props: InternalProps);
|
|
39
|
-
/**
|
|
40
|
-
* Updates the hover text and update the view
|
|
41
|
-
*
|
|
42
|
-
* @memberof StackedBarChart
|
|
43
|
-
*/
|
|
44
|
-
handleHover(event: React.MouseEvent<SVGRectElement>): void;
|
|
45
|
-
/**
|
|
46
|
-
* Update the hover text and the view
|
|
47
|
-
*
|
|
48
|
-
* @param {*} event
|
|
49
|
-
* @memberof StackedBarChart
|
|
50
|
-
*/
|
|
51
|
-
handleExit(event: React.MouseEvent<SVGRectElement>): void;
|
|
52
|
-
/**
|
|
53
|
-
* Handle column click event
|
|
54
|
-
*/
|
|
55
|
-
handleClick: (dict: Info) => (_event: React.MouseEvent<SVGElement>) => void;
|
|
56
|
-
handleArrowClick: (direction: string) => (_event: React.MouseEvent) => number;
|
|
57
|
-
getTextForChartSelection(xData: any): JSX.Element;
|
|
58
|
-
getFileCount(xData: any): any;
|
|
59
|
-
render(): JSX.Element;
|
|
60
|
-
extractPropsData(data?: QueryResultBundle): any[];
|
|
61
|
-
onMeasureResize(contentRect: any): void;
|
|
62
|
-
}
|
|
63
|
-
export {};
|