@cccsaurora/howler-ui 2.19.0-dev.1294 → 2.19.0-dev.1296
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/api/index.d.ts +1 -1
- package/api/search/action.js +1 -1
- package/api/search/analytic.js +1 -1
- package/api/search/case.js +1 -1
- package/api/search/count/hit.js +1 -1
- package/api/search/dossier.js +1 -1
- package/api/search/eql/hit.js +1 -1
- package/api/search/explain/hit.js +1 -1
- package/api/search/facet/hit.js +1 -1
- package/api/search/grouped/hit.js +1 -1
- package/api/search/grouped/user.js +1 -1
- package/api/search/histogram/hit.js +1 -1
- package/api/search/hit.js +1 -1
- package/api/search/overview.js +1 -1
- package/api/search/sigma/hit.js +1 -1
- package/api/search/template.js +1 -1
- package/api/search/user.js +1 -1
- package/api/search/view.js +1 -1
- package/api/v2/search/facet.js +1 -1
- package/api/v2/search/index.js +1 -1
- package/api/view/index.d.ts +1 -1
- package/branding/AppBrand.d.ts +2 -2
- package/commons/components/app/AppSkeleton.js +1 -1
- package/commons/components/app/hooks/useAppConfigs.d.ts +2 -2
- package/commons/components/app/hooks/useAppSitemap.d.ts +5 -2
- package/commons/components/breadcrumbs/BreadcrumbIcon.js +1 -1
- package/commons/components/breadcrumbs/Breadcrumbs.d.ts +3 -2
- package/commons/components/display/AppToc.d.ts +2 -1
- package/commons/components/display/AppToc.js +1 -1
- package/commons/components/display/hooks/useAppColor.d.ts +1 -1
- package/commons/components/leftnav/LeftNavDrawer.d.ts +2 -1
- package/commons/components/leftnav/LeftNavGroup.d.ts +2 -1
- package/commons/components/leftnav/LeftNavItem.d.ts +2 -1
- package/commons/components/leftnav/LeftNavItem.js +1 -1
- package/commons/components/notification/Notification.js +1 -1
- package/commons/components/notification/elements/NotificationHeader.js +1 -1
- package/commons/components/notification/elements/NotificationItems.js +1 -1
- package/commons/components/notification/elements/item/NotificationItemAuthor.js +1 -1
- package/commons/components/pages/PageCenter.d.ts +2 -1
- package/commons/components/pages/PageContent.d.ts +2 -1
- package/commons/components/pages/PageFullScreen.d.ts +2 -1
- package/commons/components/search/AppSearch.js +1 -1
- package/commons/components/search/AppSearchInput.d.ts +2 -1
- package/commons/components/search/AppSearchResult.d.ts +2 -1
- package/commons/components/topnav/AppBar.d.ts +2 -1
- package/commons/components/topnav/AppName.d.ts +3 -2
- package/commons/components/topnav/AppSwitcher.d.ts +2 -1
- package/commons/components/topnav/ThemeSelection.d.ts +2 -1
- package/commons/components/topnav/ThemeSelection.js +1 -1
- package/commons/components/topnav/UserProfile.d.ts +2 -1
- package/commons/components/topnav/UserProfile.js +1 -1
- package/commons/components/utils/hooks/useThemeBuilder.d.ts +1 -1
- package/components/app/App.js +2 -2
- package/components/app/drawers/ApiKeyDrawer.js +1 -1
- package/components/app/hooks/useMatchers.js +4 -4
- package/components/app/hooks/useTitle.js +1 -1
- package/components/app/providers/AnalyticProvider.js +1 -1
- package/components/app/providers/AvatarProvider.js +1 -1
- package/components/app/providers/FavouritesProvider.js +1 -1
- package/components/app/providers/GridColumnsProvider.d.ts +1 -1
- package/components/app/providers/GridColumnsProvider.js +1 -1
- package/components/app/providers/OverviewProvider.js +1 -1
- package/components/app/providers/RecordProvider.js +2 -2
- package/components/app/providers/RecordSearchProvider.js +2 -2
- package/components/app/providers/SocketProvider.js +3 -3
- package/components/app/providers/UserListProvider.test.js +6 -6
- package/components/app/providers/ViewProvider.js +3 -3
- package/components/elements/Comment.js +2 -2
- package/components/elements/ContextMenu.test.js +3 -3
- package/components/elements/EditRow.js +4 -4
- package/components/elements/ObjectDetails.js +1 -1
- package/components/elements/UserList.js +1 -1
- package/components/elements/addons/buttons/index.d.ts +1 -1
- package/components/elements/addons/layout/FlexOne.d.ts +3 -2
- package/components/elements/addons/layout/FlexPort.d.ts +2 -1
- package/components/elements/addons/layout/FlexVertical.d.ts +2 -1
- package/components/elements/addons/layout/vsbox/VSBoxElement.d.ts +2 -1
- package/components/elements/addons/lists/TuiList.d.ts +2 -1
- package/components/elements/addons/lists/TuiListBase.d.ts +2 -1
- package/components/elements/addons/lists/TuiListElement.d.ts +2 -1
- package/components/elements/addons/lists/TuiListMenu.d.ts +2 -1
- package/components/elements/addons/lists/TuiListMenu.js +1 -1
- package/components/elements/addons/lists/table/TuiTableHeader.d.ts +3 -2
- package/components/elements/addons/lists/table/index.d.ts +1 -1
- package/components/elements/case/CaseCard.js +2 -2
- package/components/elements/display/ActionButton.js +1 -1
- package/components/elements/display/ChipPopper.js +1 -1
- package/components/elements/display/ClassificationChip.d.ts +1 -1
- package/components/elements/display/HandlebarsMarkdown.js +3 -3
- package/components/elements/display/HowlerAvatar.js +2 -2
- package/components/elements/display/Image.js +3 -3
- package/components/elements/display/Markdown.js +2 -2
- package/components/elements/display/handlebars/helpers.js +3 -3
- package/components/elements/display/json/JSONViewer.js +2 -2
- package/components/elements/display/modals/RationaleModal.js +2 -2
- package/components/elements/display/modals/RationaleModal.test.js +1 -1
- package/components/elements/event/EventCard.js +1 -1
- package/components/elements/hit/HitActions.d.ts +1 -1
- package/components/elements/hit/HitActions.js +1 -1
- package/components/elements/hit/HitBanner.js +1 -1
- package/components/elements/hit/HitCard.js +1 -1
- package/components/elements/hit/HitLabels.js +1 -1
- package/components/elements/hit/HitNotebooks.js +9 -9
- package/components/elements/hit/HitOutline.js +1 -1
- package/components/elements/hit/HitOverview.js +1 -1
- package/components/elements/hit/HitPreview.js +1 -1
- package/components/elements/hit/HitSummary.js +2 -2
- package/components/elements/hit/ResolvePivotUrl.d.ts +1 -1
- package/components/elements/hit/actions/ButtonActions.js +1 -3
- package/components/elements/hit/aggregate/HitGraph.js +1 -1
- package/components/elements/hit/elements/AnalyticLink.js +1 -1
- package/components/elements/hit/elements/Assigned.js +1 -1
- package/components/elements/hit/grid/AddColumnModal.js +1 -1
- package/components/elements/hit/grid/ColumnHeader.js +1 -1
- package/components/elements/hit/grid/RecordRow.js +1 -1
- package/components/elements/hit/grid/RecordTable.js +2 -2
- package/components/elements/hit/outlines/DefaultOutline.js +1 -3
- package/components/elements/hit/related/PivotLink.js +1 -1
- package/components/elements/record/RecordComments.js +5 -7
- package/components/elements/record/RecordContextMenu.js +2 -2
- package/components/elements/record/RecordContextMenu.test.js +4 -4
- package/components/elements/record/RecordWorklog.js +1 -1
- package/components/elements/view/LayoutToggle.d.ts +1 -1
- package/components/hooks/useHitActions.js +1 -1
- package/components/hooks/useLocalStorage.js +1 -1
- package/components/hooks/useLocalStorageItem.test.js +2 -2
- package/components/hooks/useMyChart.d.ts +23 -23
- package/components/hooks/useMySnackbar.js +1 -1
- package/components/hooks/useMyUserFunctions.d.ts +21 -21
- package/components/hooks/useRelatedRecords.js +1 -1
- package/components/logins/Login.js +1 -1
- package/components/logins/auth/OAuthLogin.js +1 -1
- package/components/logins/hooks/useLogin.js +2 -2
- package/components/routes/action/edit/ActionEditor.js +4 -4
- package/components/routes/action/shared/OperationEntry.js +1 -1
- package/components/routes/action/shared/OperationStep.js +1 -1
- package/components/routes/action/useMyActionFunctions.js +1 -1
- package/components/routes/action/view/ActionDetails.js +2 -2
- package/components/routes/action/view/ActionSearch.js +4 -4
- package/components/routes/admin/users/UserEditor.js +1 -1
- package/components/routes/admin/users/UserSearch.js +5 -5
- package/components/routes/advanced/QueryBuilder.js +2 -2
- package/components/routes/advanced/luceneCompletionProvider.js +1 -1
- package/components/routes/analytics/AnalyticComments.js +3 -5
- package/components/routes/analytics/AnalyticDetails.js +2 -2
- package/components/routes/analytics/AnalyticHitComments.js +1 -1
- package/components/routes/analytics/AnalyticHitComments.test.js +1 -1
- package/components/routes/analytics/AnalyticOverview.js +2 -2
- package/components/routes/analytics/AnalyticOverviews.js +1 -1
- package/components/routes/analytics/AnalyticSearch.js +2 -2
- package/components/routes/analytics/AnalyticTemplates.js +1 -1
- package/components/routes/analytics/TriageSettings.js +2 -2
- package/components/routes/analytics/widgets/Assessment.js +1 -1
- package/components/routes/analytics/widgets/Created.js +1 -1
- package/components/routes/analytics/widgets/Escalation.js +1 -1
- package/components/routes/analytics/widgets/Stacked.js +1 -1
- package/components/routes/cases/CaseViewer.js +1 -1
- package/components/routes/cases/Cases.js +3 -3
- package/components/routes/cases/constants.d.ts +1 -1
- package/components/routes/cases/detail/CaseDashboard.js +1 -1
- package/components/routes/cases/detail/CaseDetails.js +3 -3
- package/components/routes/cases/detail/CaseObservables.js +2 -2
- package/components/routes/cases/detail/CaseRules.js +3 -3
- package/components/routes/cases/detail/CaseSearch.js +2 -2
- package/components/routes/cases/detail/CaseSearch.test.js +1 -1
- package/components/routes/cases/detail/CaseTask.js +4 -4
- package/components/routes/cases/detail/CaseTimeline.js +2 -2
- package/components/routes/cases/detail/CreateRuleDialog.test.js +1 -1
- package/components/routes/cases/detail/ItemPage.js +1 -1
- package/components/routes/cases/detail/MarkdownPage.js +1 -1
- package/components/routes/cases/detail/TaskPanel.js +2 -2
- package/components/routes/cases/detail/sidebar/CaseFolder.js +2 -2
- package/components/routes/cases/detail/sidebar/CaseFolderContextMenu.js +1 -1
- package/components/routes/cases/detail/utils.d.ts +1 -1
- package/components/routes/cases/hooks/useCase.js +2 -5
- package/components/routes/cases/modals/AddRecordToCaseModal.js +2 -2
- package/components/routes/cases/modals/AddToCaseModal.js +1 -1
- package/components/routes/cases/modals/CreateCaseModal.js +1 -1
- package/components/routes/cases/modals/RenameItemModal.js +2 -2
- package/components/routes/cases/modals/ResolveModal.js +1 -1
- package/components/routes/cases/modals/hooks.d.ts +1 -1
- package/components/routes/dossiers/DossierEditor.js +2 -2
- package/components/routes/dossiers/DossierEditor.test.js +1 -1
- package/components/routes/dossiers/Dossiers.js +3 -3
- package/components/routes/dossiers/PivotForm.js +2 -4
- package/components/routes/events/EventViewer.js +1 -1
- package/components/routes/help/ApiDocumentation.js +1 -1
- package/components/routes/help/HitBannerDocumentation.js +1 -1
- package/components/routes/help/HitSchemaDocumentation.js +1 -1
- package/components/routes/help/RetentionDocumentation.js +2 -2
- package/components/routes/help/SearchDocumentation.js +1 -1
- package/components/routes/hits/search/InformationPane.js +5 -5
- package/components/routes/hits/search/QuerySettings.test.js +4 -5
- package/components/routes/hits/search/RecordBrowser.js +1 -1
- package/components/routes/hits/search/SearchPane.js +4 -2
- package/components/routes/hits/search/ViewLink.js +1 -1
- package/components/routes/hits/search/shared/CustomSort.js +1 -1
- package/components/routes/hits/search/shared/HitFilter.d.ts +1 -1
- package/components/routes/hits/search/shared/HitSort.d.ts +1 -1
- package/components/routes/hits/search/shared/HitSort.js +1 -1
- package/components/routes/hits/search/shared/SearchSpan.d.ts +1 -1
- package/components/routes/hits/search/shared/SearchSpan.js +1 -1
- package/components/routes/hits/view/HitViewer.js +3 -3
- package/components/routes/home/AddNewCard.js +2 -2
- package/components/routes/home/AnalyticCard.js +1 -1
- package/components/routes/home/EntryWrapper.js +1 -1
- package/components/routes/home/HomeSettings.js +1 -1
- package/components/routes/home/ViewCard.js +5 -5
- package/components/routes/home/index.js +2 -2
- package/components/routes/overviews/OverviewCard.js +1 -1
- package/components/routes/overviews/OverviewViewer.js +3 -3
- package/components/routes/overviews/Overviews.js +3 -3
- package/components/routes/overviews/markdownExtendedTokenProvider.js +15 -15
- package/components/routes/settings/ProfileSection.js +2 -2
- package/components/routes/templates/TemplateEditor.d.ts +3 -2
- package/components/routes/templates/TemplateEditor.js +1 -1
- package/components/routes/templates/TemplateViewer.js +3 -3
- package/components/routes/templates/Templates.js +3 -3
- package/components/routes/views/ViewComposer.js +3 -3
- package/components/routes/views/Views.js +2 -2
- package/i18n.js +1 -1
- package/index.d.ts +1 -1
- package/index.js +1 -1
- package/locales/en/translation.json +1 -0
- package/locales/fr/translation.json +1 -0
- package/package.json +134 -134
- package/plugins/clue/components/ClueLeadForm.js +1 -1
- package/plugins/clue/components/CluePivotForm.js +2 -2
- package/plugins/clue/helpers.js +4 -4
- package/plugins/clue/index.d.ts +2 -1
- package/rest/AxiosClient.test.js +1 -0
- package/utils/Throttler.test.js +2 -2
- package/utils/actionUtils.d.ts +3 -3
- package/utils/classificationParser.js +20 -20
- package/utils/constants.d.ts +3 -3
- package/utils/localStorage.js +1 -1
- package/utils/menuUtils.js +0 -4
- package/utils/stringUtils.test.js +1 -1
- package/utils/utils.d.ts +1 -1
- package/utils/utils.js +2 -2
- package/utils/utils.test.js +1 -1
- package/utils/xsrf.js +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createElement as _createElement } from "react";
|
|
2
|
-
import {
|
|
2
|
+
import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { Check } from '@mui/icons-material';
|
|
4
4
|
import { Autocomplete, Box, Card, CardContent, CardHeader, Divider, FormControl, Grid, InputLabel, MenuItem, Select, Slider, Stack, TextField, Typography } from '@mui/material';
|
|
5
5
|
import api from '@cccsaurora/howler-ui/api';
|
|
@@ -61,7 +61,7 @@ const AddNewCard = ({ dashboard, addCard }) => {
|
|
|
61
61
|
setAnalyticsLoading(false);
|
|
62
62
|
};
|
|
63
63
|
useEffect(() => {
|
|
64
|
-
fetchAllAnalytics();
|
|
64
|
+
void fetchAllAnalytics();
|
|
65
65
|
}, []);
|
|
66
66
|
const filteredAnalyticVisualizations = useMemo(() => {
|
|
67
67
|
const existingAnalyticCards = dashboard.filter(_card => _card.type === 'analytic');
|
|
@@ -17,7 +17,7 @@ const AnalyticCard = ({ analyticId, type }) => {
|
|
|
17
17
|
const { getAnalyticFromId } = useContext(AnalyticContext);
|
|
18
18
|
const chartRef = useRef();
|
|
19
19
|
useEffect(() => {
|
|
20
|
-
getAnalyticFromId(analyticId).then(setAnalytic);
|
|
20
|
+
void getAnalyticFromId(analyticId).then(setAnalytic);
|
|
21
21
|
}, [analyticId, getAnalyticFromId]);
|
|
22
22
|
return (_jsx(Card, { variant: "outlined", sx: { height: '100%' }, children: _jsxs(CardContent, { sx: { height: '100%' }, children: [_jsxs(Stack, { direction: "row", spacing: 1, alignItems: "center", children: [_jsx(Typography, { variant: "h6", children: analytic?.name ?? _jsx(Skeleton, { variant: "text", height: "2em", width: "100px" }) }), _jsx(IconButton, { size: "small", component: Link, to: `/analytics/${analytic?.analytic_id}`, children: _jsx(OpenInNew, { fontSize: "small" }) }), _jsx(FlexOne, {}), !['assessment', 'escalation'].includes(type) && (_jsx(Tooltip, { title: t('hit.summary.zoom.reset'), children: _jsx(IconButton, { onClick: () => chartRef.current?.resetZoom(), children: _jsx(CenterFocusWeak, {}) }) }))] }), {
|
|
23
23
|
assessment: () => _jsx(Assessment, { ref: chartRef, analytic: analytic }),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useSortable } from '@dnd-kit/sortable';
|
|
3
3
|
import { CSS } from '@dnd-kit/utilities';
|
|
4
4
|
import { Delete } from '@mui/icons-material';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Edit, Settings } from '@mui/icons-material';
|
|
3
3
|
import { FormControl, FormLabel, IconButton, ListItemIcon, Menu, MenuItem, Slider, Tooltip } from '@mui/material';
|
|
4
4
|
import { useState } from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { OpenInNew } from '@mui/icons-material';
|
|
3
3
|
import { Card, CardContent, IconButton, Skeleton, Stack, Typography } from '@mui/material';
|
|
4
4
|
import api from '@cccsaurora/howler-ui/api';
|
|
@@ -104,24 +104,24 @@ const ViewCard = ({ viewId, limit, refreshTick, onRefreshComplete }) => {
|
|
|
104
104
|
clearTimeout(debounceTimerRef.current);
|
|
105
105
|
}
|
|
106
106
|
debounceTimerRef.current = setTimeout(() => {
|
|
107
|
-
refreshView();
|
|
107
|
+
void refreshView();
|
|
108
108
|
}, DEBOUNCE_TIME);
|
|
109
109
|
}, [refreshView]);
|
|
110
110
|
useEffect(() => {
|
|
111
111
|
if (refreshTick) {
|
|
112
|
-
refreshView();
|
|
112
|
+
void refreshView();
|
|
113
113
|
}
|
|
114
114
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
115
115
|
}, [refreshTick]);
|
|
116
116
|
useEffect(() => {
|
|
117
|
-
fetchViews([viewId]);
|
|
117
|
+
void fetchViews([viewId]);
|
|
118
118
|
}, [fetchViews, viewId]);
|
|
119
119
|
useEffect(() => {
|
|
120
120
|
if (!view?.query) {
|
|
121
121
|
return;
|
|
122
122
|
}
|
|
123
123
|
const loadingTimeout = setTimeout(() => setLoading(true), 200);
|
|
124
|
-
refreshView().finally(() => {
|
|
124
|
+
void refreshView().finally(() => {
|
|
125
125
|
clearTimeout(loadingTimeout);
|
|
126
126
|
setLoading(false);
|
|
127
127
|
});
|
|
@@ -70,7 +70,7 @@ const Home = () => {
|
|
|
70
70
|
clearTimeout(debounceTimerRef.current);
|
|
71
71
|
}
|
|
72
72
|
debounceTimerRef.current = setTimeout(() => {
|
|
73
|
-
setRefreshRateBackend(newRate);
|
|
73
|
+
void setRefreshRateBackend(newRate);
|
|
74
74
|
}, 500);
|
|
75
75
|
}, [setRefreshRateBackend, setUser]);
|
|
76
76
|
const handleRefresh = useCallback(() => {
|
|
@@ -103,7 +103,7 @@ const Home = () => {
|
|
|
103
103
|
}
|
|
104
104
|
}, [dashboard, getIdFromEntry, setLocalDashboard]);
|
|
105
105
|
useEffect(() => {
|
|
106
|
-
api.search.hit
|
|
106
|
+
void api.search.hit
|
|
107
107
|
.post({
|
|
108
108
|
query: updateQuery,
|
|
109
109
|
rows: 0
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Delete } from '@mui/icons-material';
|
|
3
3
|
import { Card, IconButton, Stack, Tooltip, Typography } from '@mui/material';
|
|
4
4
|
import FlexOne from '@cccsaurora/howler-ui/components/elements/addons/layout/FlexOne';
|
|
@@ -44,7 +44,7 @@ const OverviewViewer = () => {
|
|
|
44
44
|
const wrapper = useRef();
|
|
45
45
|
const startingTemplate = useStartingTemplate();
|
|
46
46
|
useEffect(() => {
|
|
47
|
-
(async () => {
|
|
47
|
+
void (async () => {
|
|
48
48
|
setLoading(true);
|
|
49
49
|
try {
|
|
50
50
|
setOverviewList(await getOverviews(true));
|
|
@@ -75,7 +75,7 @@ const OverviewViewer = () => {
|
|
|
75
75
|
}
|
|
76
76
|
}, [analytic, analytics, detection]);
|
|
77
77
|
useEffect(() => {
|
|
78
|
-
(async () => {
|
|
78
|
+
void (async () => {
|
|
79
79
|
const result = await dispatchApi(api.search.hit.post({
|
|
80
80
|
query: `howler.analytic:"${sanitizeLuceneQuery(analytic)}"` +
|
|
81
81
|
(!!detection && detection !== 'ANY' ? ` AND howler.detection:"${sanitizeLuceneQuery(detection)}"` : ''),
|
|
@@ -184,7 +184,7 @@ const OverviewViewer = () => {
|
|
|
184
184
|
return (_jsxs(PageCenter, { maxWidth: "100%", width: "100%", textAlign: "left", height: "100%", children: [_jsx(LinearProgress, { sx: { mb: 1, opacity: +loading } }), _jsxs(Stack, { direction: "column", spacing: 2, divider: _jsx(Divider, { orientation: "horizontal", flexItem: true }), height: "100%", children: [_jsxs(Stack, { direction: "row", spacing: 2, mb: 2, alignItems: "stretch", children: [_jsx(FormControl, { sx: { maxWidth: { sm: '300px', lg: '450px' }, width: '100%' }, children: _jsx(Autocomplete, { id: "analytic", options: analytics.sort((a, b) => a.name.toLowerCase().localeCompare(b.name.toLowerCase())), getOptionLabel: option => option.name, value: analytics.find(a => a.name === analytic) || null, onChange: (_event, newValue) => setAnalytic(newValue ? newValue.name : ''), renderInput: autocompleteAnalyticParams => (_jsx(TextField, { ...autocompleteAnalyticParams, label: t('route.overviews.analytic'), size: "small" })) }) }), _jsx(FormControl, { sx: { minWidth: { sm: '200px' } }, disabled: !analytic, children: _jsx(Autocomplete, { id: "detection", options: ['ANY', ...detections.sort()], getOptionLabel: option => option, value: detection ?? '', onChange: (_event, newValue) => setDetection(newValue), renderInput: autocompleteDetectionParams => (_jsx(TextField, { ...autocompleteDetectionParams, label: t('route.overviews.detection'), size: "small" })) }) }), selectedOverview && (_jsx(Button, { variant: "outlined", startIcon: _jsx(Delete, {}), onClick: onDelete, children: t('button.delete') })), _jsx(Button, { variant: "outlined", disabled: analyticOrDetectionMissing || noChange, startIcon: overviewLoading ? _jsx(CircularProgress, { size: 16 }) : _jsx(Check, {}), onClick: onSave, children: t(!analyticOrDetectionMissing && !noChange ? 'button.save' : 'button.saved') }), _jsx("div", { style: { flex: 1 } }), _jsxs(ToggleButtonGroup, { exclusive: true, value: chosenTheme, onChange: (_event, value) => setChosenTheme(value), sx: { maxHeight: '40px' }, children: [_jsx(Tooltip, { title: t('route.overviews.theme.light'), children: _jsx(ToggleButton, { value: "light", children: _jsx(WbSunny, {}) }) }), _jsx(Tooltip, { title: t('route.overviews.theme.dark'), children: _jsx(ToggleButton, { value: "dark", children: _jsx(DarkMode, {}) }) })] })] }), analyticOrDetectionMissing ? (_jsx(AppInfoPanel, { i18nKey: "route.overviews.select", sx: { width: '100%', alignSelf: 'start' } })) : (_jsxs(Stack, { ref: wrapper, direction: "row", spacing: 1, height: "100%", onKeyDown: e => {
|
|
185
185
|
if (e.ctrlKey && e.key === 's') {
|
|
186
186
|
if (!noChange) {
|
|
187
|
-
onSave();
|
|
187
|
+
void onSave();
|
|
188
188
|
}
|
|
189
189
|
e.preventDefault();
|
|
190
190
|
}
|
|
@@ -49,7 +49,7 @@ const OverviewsBase = () => {
|
|
|
49
49
|
offset
|
|
50
50
|
});
|
|
51
51
|
}
|
|
52
|
-
catch
|
|
52
|
+
catch {
|
|
53
53
|
setHasError(true);
|
|
54
54
|
}
|
|
55
55
|
finally {
|
|
@@ -93,7 +93,7 @@ const OverviewsBase = () => {
|
|
|
93
93
|
});
|
|
94
94
|
}, [dispatchApi, remove, withConfirmDeleteModal, showSuccessMessage, t]);
|
|
95
95
|
useEffect(() => {
|
|
96
|
-
onSearch();
|
|
96
|
+
void onSearch();
|
|
97
97
|
if (!searchParams.has('offset')) {
|
|
98
98
|
searchParams.set('offset', '0');
|
|
99
99
|
setSearchParams(searchParams, { replace: true });
|
|
@@ -109,7 +109,7 @@ const OverviewsBase = () => {
|
|
|
109
109
|
}, [offset, response?.total, searchParams, setSearchParams]);
|
|
110
110
|
useEffect(() => {
|
|
111
111
|
if (!loading) {
|
|
112
|
-
onSearch();
|
|
112
|
+
void onSearch();
|
|
113
113
|
}
|
|
114
114
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
115
115
|
}, [offset]);
|
|
@@ -33,8 +33,8 @@ export const language = {
|
|
|
33
33
|
defaultToken: '',
|
|
34
34
|
tokenPostfix: '.md',
|
|
35
35
|
// escape codes
|
|
36
|
-
control: /[\\`*_
|
|
37
|
-
noncontrol: /[^\\`*_
|
|
36
|
+
control: /[\\`*_[\]{}()#+\-.!]/,
|
|
37
|
+
noncontrol: /[^\\`*_[\]{}()#+\-.!]/,
|
|
38
38
|
escapes: /\\(?:@control)/,
|
|
39
39
|
// escape codes for javascript/CSS strings
|
|
40
40
|
jsescapes: /\\(?:[btnfr\\"']|[0-7][0-7]?|[0-3][0-7]{2})/,
|
|
@@ -70,19 +70,19 @@ export const language = {
|
|
|
70
70
|
// headers (with #)
|
|
71
71
|
[/^(\s{0,3})(#+)((?:[^\\#]|@escapes)+)((?:#+)?)/, ['white', 'keyword', 'keyword', 'keyword']],
|
|
72
72
|
// headers (with =)
|
|
73
|
-
[/^\s*(
|
|
73
|
+
[/^\s*(=+|-+)\s*$/, 'keyword'],
|
|
74
74
|
// headers (with ***)
|
|
75
75
|
[/^\s*((\*[ ]?)+)\s*$/, 'meta.separator'],
|
|
76
76
|
// quote
|
|
77
77
|
[/^\s*>+/, 'comment'],
|
|
78
78
|
// list (starting with * or number)
|
|
79
|
-
[/^\s*([
|
|
79
|
+
[/^\s*([*\-+:]|\d+\.)\s/, 'keyword'],
|
|
80
80
|
// code block (4 spaces indent)
|
|
81
81
|
[/^(\t|[ ]{4})[^ ].*$/, 'string'],
|
|
82
82
|
// code block (3 tilde)
|
|
83
|
-
[/^\s*~~~\s*((?:\w|[
|
|
83
|
+
[/^\s*~~~\s*((?:\w|[/\-#])+)?\s*$/, { token: 'string', next: '@codeblock' }],
|
|
84
84
|
// github style code blocks (with backticks and language)
|
|
85
|
-
[/^\s*```\s*((?:\w|[
|
|
85
|
+
[/^\s*```\s*((?:\w|[/\-#])+).*$/, { token: 'string', next: '@codeblockgh', nextEmbedded: '$1' }],
|
|
86
86
|
// github style code blocks (with backticks but no language)
|
|
87
87
|
[/^\s*```\s*$/, { token: 'string', next: '@codeblock' }],
|
|
88
88
|
// CCCS MODIFICATION
|
|
@@ -94,7 +94,7 @@ export const language = {
|
|
|
94
94
|
handlebars: [
|
|
95
95
|
[/"[^"]+"/, 'string'],
|
|
96
96
|
[/[()]/, 'handlebars'],
|
|
97
|
-
[/[\w\d
|
|
97
|
+
[/[\w\d.]+/, 'variable'],
|
|
98
98
|
[
|
|
99
99
|
/[#/\w]+/,
|
|
100
100
|
{
|
|
@@ -109,13 +109,13 @@ export const language = {
|
|
|
109
109
|
// CCCS MODIFICATION END
|
|
110
110
|
table_header: [
|
|
111
111
|
{ include: '@table_common' },
|
|
112
|
-
[/[
|
|
112
|
+
[/[^|]+/, 'keyword.table.header'] // table header
|
|
113
113
|
],
|
|
114
114
|
table_body: [{ include: '@table_common' }, { include: '@linecontent' }],
|
|
115
115
|
table_common: [
|
|
116
|
-
[/\s*[
|
|
116
|
+
[/\s*[-:]+\s*/, { token: 'keyword', switchTo: 'table_body' }], // header-divider
|
|
117
117
|
[/^\s*\|/, 'keyword.table.left'], // opening |
|
|
118
|
-
[/^\s*[
|
|
118
|
+
[/^\s*[^|]/, '@rematch', '@pop'], // exiting
|
|
119
119
|
[/^\s*$/, '@rematch', '@pop'], // exiting
|
|
120
120
|
[
|
|
121
121
|
/\|/,
|
|
@@ -149,7 +149,7 @@ export const language = {
|
|
|
149
149
|
[/`/, { token: 'variable', next: '@codecontent' }],
|
|
150
150
|
// links
|
|
151
151
|
[/\{+[^}]+\}+/, 'string.target'],
|
|
152
|
-
[/(!?\[)((?:[^\]\\]|@escapes)*)(\]\([
|
|
152
|
+
[/(!?\[)((?:[^\]\\]|@escapes)*)(\]\([^)]+\))/, ['string.link', '', 'string.link']],
|
|
153
153
|
[/(!?\[)((?:[^\]\\]|@escapes)*)(\])/, 'string.link'],
|
|
154
154
|
// or html
|
|
155
155
|
{ include: 'html' }
|
|
@@ -169,7 +169,7 @@ export const language = {
|
|
|
169
169
|
// html tags
|
|
170
170
|
[/<(\w+)\/>/, 'tag'],
|
|
171
171
|
[
|
|
172
|
-
/<(\w+)(
|
|
172
|
+
/<(\w+)(-|\w)*/,
|
|
173
173
|
{
|
|
174
174
|
cases: {
|
|
175
175
|
'@empty': { token: 'tag', next: '@tag.$1' },
|
|
@@ -177,14 +177,14 @@ export const language = {
|
|
|
177
177
|
}
|
|
178
178
|
}
|
|
179
179
|
],
|
|
180
|
-
[/<\/(\w+)(
|
|
180
|
+
[/<\/(\w+)(-|\w)*\s*>/, { token: 'tag' }],
|
|
181
181
|
[/<!--/, 'comment', '@comment']
|
|
182
182
|
],
|
|
183
183
|
comment: [
|
|
184
|
-
[/[
|
|
184
|
+
[/[^<-]+/, 'comment.content'],
|
|
185
185
|
[/-->/, 'comment', '@pop'],
|
|
186
186
|
[/<!--/, 'comment.content.invalid'],
|
|
187
|
-
[/[
|
|
187
|
+
[/[<-]/, 'comment.content']
|
|
188
188
|
],
|
|
189
189
|
// Almost full HTML tag matching, complete with embedded scripts & styles
|
|
190
190
|
tag: [
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Add, Check, ChevronRight, Clear } from '@mui/icons-material';
|
|
3
3
|
import { Chip, CircularProgress, Grid, TableCell, TableRow, Typography } from '@mui/material';
|
|
4
4
|
import { ApiConfigContext } from '@cccsaurora/howler-ui/components/app/providers/ApiConfigProvider';
|
|
@@ -17,7 +17,7 @@ const ProfileSection = ({ user, editName, addRole, removeRole, viewGroups }) =>
|
|
|
17
17
|
const [loadingGroups, setLoadingGroups] = useState(false);
|
|
18
18
|
const wrapChange = useCallback(async (r, fn) => {
|
|
19
19
|
const delayedLoad = delay(250);
|
|
20
|
-
delayedLoad.then(() => {
|
|
20
|
+
void delayedLoad.then(() => {
|
|
21
21
|
setLoading({
|
|
22
22
|
...loading,
|
|
23
23
|
[r]: true
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import type { Hit } from '@cccsaurora/howler-ui/models/entities/generated/Hit';
|
|
2
|
-
declare const
|
|
2
|
+
declare const TemplateEditor: ({ hit, fields, setFields, onRemove, onAdd }: {
|
|
3
3
|
hit: Hit;
|
|
4
4
|
fields: string[];
|
|
5
5
|
setFields: (displayFields: string[]) => void;
|
|
6
6
|
onRemove: (field: string) => void;
|
|
7
7
|
onAdd: (field: string) => void;
|
|
8
|
-
}) => import("react/jsx-runtime").JSX.Element
|
|
8
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare const _default: import("react").MemoExoticComponent<typeof TemplateEditor>;
|
|
9
10
|
export default _default;
|
|
@@ -30,7 +30,7 @@ const TemplateEditor = ({ hit, fields, setFields, onRemove, onAdd }) => {
|
|
|
30
30
|
}
|
|
31
31
|
}, [tryAddField]);
|
|
32
32
|
useEffect(() => {
|
|
33
|
-
getHitFields().then(suggestionFields => setSuggestions(suggestionFields.map(f => f.key)));
|
|
33
|
+
void getHitFields().then(suggestionFields => setSuggestions(suggestionFields.map(f => f.key)));
|
|
34
34
|
}, [getHitFields]);
|
|
35
35
|
const handleDragEnd = useCallback((event) => {
|
|
36
36
|
const { active, over } = event;
|
|
@@ -34,7 +34,7 @@ const TemplateViewer = () => {
|
|
|
34
34
|
const [templateLoading, setTemplateLoading] = useState(false);
|
|
35
35
|
useEffect(() => {
|
|
36
36
|
setLoading(true);
|
|
37
|
-
dispatchApi(api.search.analytic.post({ query: 'analytic_id:*', rows: 1000 }), {
|
|
37
|
+
void dispatchApi(api.search.analytic.post({ query: 'analytic_id:*', rows: 1000 }), {
|
|
38
38
|
logError: false,
|
|
39
39
|
showError: true,
|
|
40
40
|
throwError: true
|
|
@@ -47,7 +47,7 @@ const TemplateViewer = () => {
|
|
|
47
47
|
}
|
|
48
48
|
setAnalytics(_analytics);
|
|
49
49
|
});
|
|
50
|
-
dispatchApi(api.template.get()).then(setTemplateList);
|
|
50
|
+
void dispatchApi(api.template.get()).then(setTemplateList);
|
|
51
51
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
52
52
|
}, [analytic, dispatchApi]);
|
|
53
53
|
useEffect(() => {
|
|
@@ -55,7 +55,7 @@ const TemplateViewer = () => {
|
|
|
55
55
|
return;
|
|
56
56
|
}
|
|
57
57
|
setLoading(true);
|
|
58
|
-
dispatchApi(api.search.grouped.hit.post('howler.detection', {
|
|
58
|
+
void dispatchApi(api.search.grouped.hit.post('howler.detection', {
|
|
59
59
|
limit: 0,
|
|
60
60
|
query: `howler.analytic:"${sanitizeLuceneQuery(analytic)}"`
|
|
61
61
|
}), {
|
|
@@ -53,7 +53,7 @@ const TemplatesBase = () => {
|
|
|
53
53
|
offset
|
|
54
54
|
});
|
|
55
55
|
}
|
|
56
|
-
catch
|
|
56
|
+
catch {
|
|
57
57
|
setHasError(true);
|
|
58
58
|
}
|
|
59
59
|
finally {
|
|
@@ -87,7 +87,7 @@ const TemplatesBase = () => {
|
|
|
87
87
|
}
|
|
88
88
|
}, [offset, searchParams, setSearchParams, getSearchRequestData]);
|
|
89
89
|
useEffect(() => {
|
|
90
|
-
onSearch();
|
|
90
|
+
void onSearch();
|
|
91
91
|
if (!searchParams.has('offset')) {
|
|
92
92
|
searchParams.set('offset', '0');
|
|
93
93
|
setSearchParams(searchParams, { replace: true });
|
|
@@ -103,7 +103,7 @@ const TemplatesBase = () => {
|
|
|
103
103
|
}, [offset, response?.total, searchParams, setSearchParams]);
|
|
104
104
|
useEffect(() => {
|
|
105
105
|
if (!searching) {
|
|
106
|
-
onSearch();
|
|
106
|
+
void onSearch();
|
|
107
107
|
}
|
|
108
108
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
109
109
|
}, [offset]);
|
|
@@ -167,14 +167,14 @@ const ViewComposer = () => {
|
|
|
167
167
|
useEffect(() => {
|
|
168
168
|
// Only run initial search if we're NOT editing an existing view
|
|
169
169
|
if (!routeParams.id) {
|
|
170
|
-
search(query || DEFAULT_QUERY);
|
|
170
|
+
void search(query || DEFAULT_QUERY);
|
|
171
171
|
}
|
|
172
172
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
173
173
|
}, [routeParams.id]);
|
|
174
174
|
// We only run this when ancillary properties (i.e. filters, sorting) change
|
|
175
175
|
useEffect(() => {
|
|
176
176
|
if (query && !isLoadingView) {
|
|
177
|
-
search(query);
|
|
177
|
+
void search(query);
|
|
178
178
|
}
|
|
179
179
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
180
180
|
}, [sort, span, indexes, isLoadingView]);
|
|
@@ -182,7 +182,7 @@ const ViewComposer = () => {
|
|
|
182
182
|
if (!routeParams.id) {
|
|
183
183
|
return;
|
|
184
184
|
}
|
|
185
|
-
(async () => {
|
|
185
|
+
void (async () => {
|
|
186
186
|
const viewToEdit = (await getCurrentViews({ views: [routeParams.id] }))[0];
|
|
187
187
|
if (!viewToEdit) {
|
|
188
188
|
setError('route.views.missing');
|
|
@@ -70,7 +70,7 @@ const ViewsBase = () => {
|
|
|
70
70
|
offset
|
|
71
71
|
});
|
|
72
72
|
}
|
|
73
|
-
catch
|
|
73
|
+
catch {
|
|
74
74
|
setHasError(true);
|
|
75
75
|
}
|
|
76
76
|
finally {
|
|
@@ -175,7 +175,7 @@ const ViewsBase = () => {
|
|
|
175
175
|
}, [offset, response?.total, searchParams, setSearchParams]);
|
|
176
176
|
useEffect(() => {
|
|
177
177
|
if (!searching) {
|
|
178
|
-
onSearch();
|
|
178
|
+
void onSearch();
|
|
179
179
|
}
|
|
180
180
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
181
181
|
}, [offset, favouritesOnly, type]);
|
package/i18n.js
CHANGED
package/index.d.ts
CHANGED
package/index.js
CHANGED
|
@@ -250,6 +250,7 @@
|
|
|
250
250
|
"hit.search.keyboard.shortcuts": "Shortcuts",
|
|
251
251
|
"hit.search.keyboard.shortcuts_hints": "Shortcuts with hints",
|
|
252
252
|
"hit.search.prompt": "Search by providing a lucene query. Activate autocomplete using [ctrl + space].",
|
|
253
|
+
"hit.search.record.invalid": "Invalid Record Type",
|
|
253
254
|
"hit.search.save.button": "Save query as view",
|
|
254
255
|
"hit.search.save.view": "Save View",
|
|
255
256
|
"hit.search.select.all": "Select all hits on page",
|
|
@@ -250,6 +250,7 @@
|
|
|
250
250
|
"hit.search.keyboard.shortcuts": "Raccourcis",
|
|
251
251
|
"hit.search.keyboard.shortcuts_hints": "Raccourcis avec indice",
|
|
252
252
|
"hit.search.prompt": "Rechercher en fournissant une requête lucene. Activer l'autocomplétion en utilisant [ctrl + espace].",
|
|
253
|
+
"hit.search.record.invalid": "Type d'enregistrement invalide",
|
|
253
254
|
"hit.search.save.button": "Sauvegarder la requête en tant que vue",
|
|
254
255
|
"hit.search.save.view": "Sauvegarder la vue",
|
|
255
256
|
"hit.search.select.all": "Sélectionner tous les résultats de la page",
|