@cccsaurora/clue-ui 1.1.4 → 1.2.0-dev.106
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/ActionForm-ByeOzpc4.js +555 -0
- package/AnnotationDetails-DknbKDyl.js +175 -0
- package/AnnotationPreview-CQwKs8se.js +188 -0
- package/ClueEnrichContext-6NJfXpUB.js +536 -0
- package/FlexOne-BSYAhhtG.js +9 -0
- package/_Map-kgDsDYxq.js +64 -0
- package/_MapCache-DabaaWfq.js +161 -0
- package/_Uint8Array-BlVVH1tp.js +129 -0
- package/_baseAssignValue-CNbcU6Nb.js +25 -0
- package/_baseClone-D3a8Pa4T.js +284 -0
- package/_baseExtremum-B1o1zHjR.js +33 -0
- package/_baseFlatten-D4huXoEI.js +92 -0
- package/_baseGet-BSK_nnoz.js +109 -0
- package/_baseIsEqual-B5xLoweL.js +238 -0
- package/_baseIteratee-p6Nj07-n.js +126 -0
- package/_baseSlice-GAv_YFTT.js +20 -0
- package/_baseSum-D0WC1dN0.js +13 -0
- package/_baseUniq-CpupKWcL.js +89 -0
- package/_commonjsHelpers-DWwsNxpa.js +8 -0
- package/_createAggregator-BpVy5xMi.js +63 -0
- package/_getPrototype-D1LAdQKO.js +5 -0
- package/_getTag-D3ToyefI.js +126 -0
- package/cloneDeep-CjP5k9zW.js +8 -0
- package/components/AnnotationBody.js +49 -35
- package/components/AnnotationDetailPopover.js +36 -30
- package/components/AnnotationDetails.js +6 -6
- package/components/AnnotationEntry.js +50 -47
- package/components/AnnotationPreview.js +5 -5
- package/components/ClassificationChip.js +44 -23
- package/components/CountBadge.js +31 -26
- package/components/EnrichedCard.js +110 -97
- package/components/EnrichedChip.js +130 -105
- package/components/EnrichedTypography.js +133 -107
- package/components/ErrorBoundary.js +28 -24
- package/components/RetryFailedEnrichments.js +10 -9
- package/components/SourcePicker.js +57 -49
- package/components/actions/ActionForm.js +4 -4
- package/components/actions/ExecutePopover.js +64 -50
- package/components/actions/ResultModal.js +5 -5
- package/components/actions/form/schemaAdapter.js +39 -23
- package/components/display/graph/ExpandMoreButton.js +10 -10
- package/components/display/graph/elements/NodeCard.js +111 -91
- package/components/display/graph/elements/NodeTag.js +15 -13
- package/components/display/graph/index.js +261 -202
- package/components/display/graph/visualizations/Leaf.js +88 -69
- package/components/display/graph/visualizations/cloud/index.js +98 -81
- package/components/display/graph/visualizations/icons/BaseIcon.js +26 -21
- package/components/display/graph/visualizations/icons/BugIcon.js +12 -12
- package/components/display/graph/visualizations/icons/HostIcon.js +12 -12
- package/components/display/graph/visualizations/icons/NetworkIcon.js +12 -12
- package/components/display/graph/visualizations/icons/ProcessIcon.js +12 -12
- package/components/display/graph/visualizations/icons/TargetIcon.js +13 -13
- package/components/display/graph/visualizations/icons/index.js +14 -13
- package/components/display/graph/visualizations/panels/NodePanel.js +10 -8
- package/components/display/graph/visualizations/tree/BundleLine.js +108 -81
- package/components/display/graph/visualizations/tree/Triangle.js +13 -13
- package/components/display/graph/visualizations/tree/index.js +407 -305
- package/components/display/icons/Iconified.js +27 -12
- package/components/display/json/index.js +4 -4
- package/components/display/markdown/index.js +8658 -5757
- package/components/enrichment/EnrichPopover.js +55 -47
- package/components/fetchers/Fetcher.js +123 -95
- package/components/fetchers/PreviewModal.js +20 -17
- package/components/fetchers/StatusChip.js +21 -17
- package/components/group/Entry.js +13 -11
- package/components/group/Group.js +13 -10
- package/components/group/GroupControl.js +77 -66
- package/components/stats/QueryStatus.js +40 -35
- package/countBy-C69WslUA.js +14 -0
- package/data/event.js +6 -4
- package/database/index.js +2 -2
- package/debounce-bV0h5FC5.js +92 -0
- package/get-D3C3lEU3.js +8 -0
- package/groupBy-DC2oOuBN.js +14 -0
- package/hooks/ClueActionContext.js +7 -7
- package/hooks/ClueComponentContext.js +29 -23
- package/hooks/ClueConfigProvider.js +14 -12
- package/hooks/ClueDatabaseContext.js +19 -13
- package/hooks/ClueEnrichContext.js +8 -8
- package/hooks/ClueFetcherContext.js +74 -46
- package/hooks/ClueGroupContext.js +17 -14
- package/hooks/CluePopupContext.js +5 -5
- package/hooks/ClueProvider.js +12 -10
- package/hooks/selectors.js +21 -10
- package/hooks/useActionResult.js +2 -2
- package/hooks/useAnnotations.js +44 -32
- package/hooks/useClue.js +6 -4
- package/hooks/useClueActions.js +3 -3
- package/hooks/useClueConfig.js +6 -4
- package/hooks/useClueTypeConfig.js +3 -3
- package/hooks/useComparator.js +722 -435
- package/hooks/useErrors.js +22 -18
- package/hooks/useMyHighlights.js +66 -36
- package/hooks/useMyLocalStorage.js +66 -37
- package/iconify-CXMreGTg.js +1782 -0
- package/icons/Action.js +66 -49
- package/icons/Assessment.js +84 -68
- package/icons/Context.js +77 -63
- package/icons/Opinion.js +77 -65
- package/icons/iconMap.js +2 -2
- package/identity-CPGTqrE4.js +6 -0
- package/index-BDVjGvMI.js +696 -0
- package/index-BbPn6-Mw.js +15750 -0
- package/index-Bi21Wb23.js +465 -0
- package/index-C3lkTD69.js +1172 -0
- package/index-CC12Ux-9.js +17654 -0
- package/isEmpty-BQkZubqU.js +29 -0
- package/isNil-CIubwp4T.js +6 -0
- package/isObject-FTY-5JQX.js +7 -0
- package/isObjectLike-OAgjjZye.js +48 -0
- package/isSymbol-Xd2FsJyp.js +8 -0
- package/last-CUCl67Im.js +7 -0
- package/main.js +62 -62
- package/package.json +1 -1
- package/sortBy-B-UKp4GT.js +100 -0
- package/sumBy-MYkDPHZL.js +8 -0
- package/text/Frequency.js +42 -23
- package/toFinite-Bc55msYj.js +16 -0
- package/toNumber-DPxy1FBy.js +39 -0
- package/useClueTypeConfig-XvGvIw2S.js +3201 -0
- package/utils/chain.js +91 -64
- package/utils/classificationParser.js +519 -256
- package/utils/constants.js +35 -10
- package/utils/graph.js +72 -45
- package/utils/hashUtil.js +7 -7
- package/utils/line.js +131 -81
- package/utils/loggerUtil.js +5 -3
- package/utils/sessionStorage.js +41 -27
- package/utils/time.js +423 -423
- package/utils/utils.js +9 -9
- package/utils/window.js +21 -10
- package/utils-7OtvGnmf.js +200 -0
- package/ActionForm-myEAs2UC.js +0 -435
- package/AnnotationDetails-D9AJM0An.js +0 -160
- package/AnnotationPreview-Lb5be8ZG.js +0 -140
- package/ClueEnrichContext-DsFsXixD.js +0 -420
- package/FlexOne-BXWFOd1T.js +0 -6
- package/_Map-DXNg_Z-q.js +0 -54
- package/_MapCache-Cu25RRDU.js +0 -129
- package/_Uint8Array-DlJCtTvG.js +0 -102
- package/_baseAssignValue-CUmzp727.js +0 -20
- package/_baseClone-BlMmRXeX.js +0 -208
- package/_baseExtremum-P_0akmCi.js +0 -27
- package/_baseFlatten-CN7vDNEQ.js +0 -72
- package/_baseGet-Dgf6_xCm.js +0 -80
- package/_baseIsEqual-Cpjtfb3Q.js +0 -173
- package/_baseIteratee-CP1bocOX.js +0 -95
- package/_baseSlice-M5RKzt1A.js +0 -10
- package/_baseSum-wEbgNeUs.js +0 -10
- package/_baseUniq-tMFmk80M.js +0 -61
- package/_commonjsHelpers-DaMA6jEr.js +0 -8
- package/_createAggregator-B4Cav8ZM.js +0 -53
- package/_getPrototype-CHAFQYL_.js +0 -5
- package/_getTag-BV_UoLYG.js +0 -90
- package/cloneDeep-BPVpFBzJ.js +0 -8
- package/countBy-DOutsa_w.js +0 -8
- package/debounce-DryYcbJ4.js +0 -56
- package/get-Bow1vKwx.js +0 -8
- package/groupBy-BheQYl6f.js +0 -8
- package/iconify-BBckr5AQ.js +0 -1263
- package/identity-ByMq8VxU.js +0 -6
- package/index-BXxfAxFt.js +0 -12734
- package/index-C15OYgRY.js +0 -358
- package/index-E7g8cRyW.js +0 -568
- package/index-p5_wX7q1.js +0 -11729
- package/index-vF6IyBhz.js +0 -975
- package/isEmpty-g47Qir2A.js +0 -21
- package/isNil-CjWwlQS3.js +0 -6
- package/isObject-B53jY8Qg.js +0 -7
- package/isObjectLike-BatpeCIi.js +0 -29
- package/isSymbol-C3_SC0Qp.js +0 -8
- package/last-7CdUxN0r.js +0 -7
- package/sortBy-ITdmD17L.js +0 -79
- package/sumBy-DxJUU2E8.js +0 -8
- package/toFinite-BMy6GObD.js +0 -14
- package/toNumber-YVhnnJv4.js +0 -31
- package/useClueTypeConfig-DyeBcXQX.js +0 -2214
- package/utils-BnmI_6N8.js +0 -130
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { i as isArrayLike, a as isBuffer, b as isTypedArray, c as isArguments, g as getTag, d as isPrototype, e as baseKeys } from "./_getTag-D3ToyefI.js";
|
|
2
|
+
import { i as isArray } from "./_Map-kgDsDYxq.js";
|
|
3
|
+
var mapTag = "[object Map]", setTag = "[object Set]";
|
|
4
|
+
var objectProto = Object.prototype;
|
|
5
|
+
var hasOwnProperty = objectProto.hasOwnProperty;
|
|
6
|
+
function isEmpty(value) {
|
|
7
|
+
if (value == null) {
|
|
8
|
+
return true;
|
|
9
|
+
}
|
|
10
|
+
if (isArrayLike(value) && (isArray(value) || typeof value == "string" || typeof value.splice == "function" || isBuffer(value) || isTypedArray(value) || isArguments(value))) {
|
|
11
|
+
return !value.length;
|
|
12
|
+
}
|
|
13
|
+
var tag = getTag(value);
|
|
14
|
+
if (tag == mapTag || tag == setTag) {
|
|
15
|
+
return !value.size;
|
|
16
|
+
}
|
|
17
|
+
if (isPrototype(value)) {
|
|
18
|
+
return !baseKeys(value).length;
|
|
19
|
+
}
|
|
20
|
+
for (var key in value) {
|
|
21
|
+
if (hasOwnProperty.call(value, key)) {
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
export {
|
|
28
|
+
isEmpty as i
|
|
29
|
+
};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
|
|
2
|
+
var freeSelf = typeof self == "object" && self && self.Object === Object && self;
|
|
3
|
+
var root = freeGlobal || freeSelf || Function("return this")();
|
|
4
|
+
var Symbol$1 = root.Symbol;
|
|
5
|
+
var objectProto$1 = Object.prototype;
|
|
6
|
+
var hasOwnProperty = objectProto$1.hasOwnProperty;
|
|
7
|
+
var nativeObjectToString$1 = objectProto$1.toString;
|
|
8
|
+
var symToStringTag$1 = Symbol$1 ? Symbol$1.toStringTag : void 0;
|
|
9
|
+
function getRawTag(value) {
|
|
10
|
+
var isOwn = hasOwnProperty.call(value, symToStringTag$1), tag = value[symToStringTag$1];
|
|
11
|
+
try {
|
|
12
|
+
value[symToStringTag$1] = void 0;
|
|
13
|
+
var unmasked = true;
|
|
14
|
+
} catch (e) {
|
|
15
|
+
}
|
|
16
|
+
var result = nativeObjectToString$1.call(value);
|
|
17
|
+
if (unmasked) {
|
|
18
|
+
if (isOwn) {
|
|
19
|
+
value[symToStringTag$1] = tag;
|
|
20
|
+
} else {
|
|
21
|
+
delete value[symToStringTag$1];
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
return result;
|
|
25
|
+
}
|
|
26
|
+
var objectProto = Object.prototype;
|
|
27
|
+
var nativeObjectToString = objectProto.toString;
|
|
28
|
+
function objectToString(value) {
|
|
29
|
+
return nativeObjectToString.call(value);
|
|
30
|
+
}
|
|
31
|
+
var nullTag = "[object Null]", undefinedTag = "[object Undefined]";
|
|
32
|
+
var symToStringTag = Symbol$1 ? Symbol$1.toStringTag : void 0;
|
|
33
|
+
function baseGetTag(value) {
|
|
34
|
+
if (value == null) {
|
|
35
|
+
return value === void 0 ? undefinedTag : nullTag;
|
|
36
|
+
}
|
|
37
|
+
return symToStringTag && symToStringTag in Object(value) ? getRawTag(value) : objectToString(value);
|
|
38
|
+
}
|
|
39
|
+
function isObjectLike(value) {
|
|
40
|
+
return value != null && typeof value == "object";
|
|
41
|
+
}
|
|
42
|
+
export {
|
|
43
|
+
Symbol$1 as S,
|
|
44
|
+
baseGetTag as b,
|
|
45
|
+
freeGlobal as f,
|
|
46
|
+
isObjectLike as i,
|
|
47
|
+
root as r
|
|
48
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { i as isObjectLike, b as baseGetTag } from "./isObjectLike-OAgjjZye.js";
|
|
2
|
+
var symbolTag = "[object Symbol]";
|
|
3
|
+
function isSymbol(value) {
|
|
4
|
+
return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag;
|
|
5
|
+
}
|
|
6
|
+
export {
|
|
7
|
+
isSymbol as i
|
|
8
|
+
};
|
package/last-CUCl67Im.js
ADDED
package/main.js
CHANGED
|
@@ -1,64 +1,64 @@
|
|
|
1
|
-
import { A
|
|
2
|
-
import { default as
|
|
3
|
-
import { A as
|
|
4
|
-
import { default as
|
|
5
|
-
import { A as
|
|
6
|
-
import { default as
|
|
7
|
-
import { default as
|
|
8
|
-
import { default as
|
|
9
|
-
import { default as
|
|
10
|
-
import { default as
|
|
11
|
-
import { default as
|
|
12
|
-
import { default as
|
|
13
|
-
import { default as
|
|
14
|
-
import { default as
|
|
15
|
-
import { default as
|
|
16
|
-
import { SNACKBAR_EVENT_ID
|
|
17
|
-
import { b
|
|
18
|
-
import { ClueComponentContext
|
|
19
|
-
import { ClueConfigContext
|
|
20
|
-
import { ClueDatabaseContext
|
|
21
|
-
import { C as
|
|
22
|
-
import { ClueProvider
|
|
23
|
-
import { useClueActionsSelector
|
|
24
|
-
import { default as
|
|
25
|
-
import { default as
|
|
26
|
-
import { default as
|
|
27
|
-
import { default as
|
|
28
|
-
import { default as
|
|
29
|
-
import { default as
|
|
1
|
+
import { A, u } from "./ActionForm-ByeOzpc4.js";
|
|
2
|
+
import { default as default2 } from "./components/AnnotationDetailPopover.js";
|
|
3
|
+
import { A as A2 } from "./AnnotationDetails-DknbKDyl.js";
|
|
4
|
+
import { default as default3 } from "./components/AnnotationEntry.js";
|
|
5
|
+
import { A as A3, C } from "./AnnotationPreview-CQwKs8se.js";
|
|
6
|
+
import { default as default4 } from "./components/CountBadge.js";
|
|
7
|
+
import { default as default5 } from "./components/EnrichedCard.js";
|
|
8
|
+
import { default as default6 } from "./components/EnrichedChip.js";
|
|
9
|
+
import { default as default7 } from "./components/EnrichedTypography.js";
|
|
10
|
+
import { default as default8 } from "./components/fetchers/Fetcher.js";
|
|
11
|
+
import { default as default9 } from "./components/fetchers/StatusChip.js";
|
|
12
|
+
import { default as default10 } from "./components/group/Entry.js";
|
|
13
|
+
import { default as default11 } from "./components/group/Group.js";
|
|
14
|
+
import { default as default12 } from "./components/group/GroupControl.js";
|
|
15
|
+
import { default as default13 } from "./components/SourcePicker.js";
|
|
16
|
+
import { SNACKBAR_EVENT_ID } from "./data/event.js";
|
|
17
|
+
import { b } from "./index-CC12Ux-9.js";
|
|
18
|
+
import { ClueComponentContext } from "./hooks/ClueComponentContext.js";
|
|
19
|
+
import { ClueConfigContext } from "./hooks/ClueConfigProvider.js";
|
|
20
|
+
import { ClueDatabaseContext } from "./hooks/ClueDatabaseContext.js";
|
|
21
|
+
import { C as C2 } from "./ClueEnrichContext-6NJfXpUB.js";
|
|
22
|
+
import { ClueProvider } from "./hooks/ClueProvider.js";
|
|
23
|
+
import { useClueActionsSelector, useClueEnrichSelector, useClueFetcherSelector } from "./hooks/selectors.js";
|
|
24
|
+
import { default as default14 } from "./hooks/useClue.js";
|
|
25
|
+
import { default as default15 } from "./hooks/useClueConfig.js";
|
|
26
|
+
import { default as default16 } from "./icons/Assessment.js";
|
|
27
|
+
import { default as default17 } from "./icons/Context.js";
|
|
28
|
+
import { default as default18 } from "./icons/Opinion.js";
|
|
29
|
+
import { default as default19 } from "./text/Frequency.js";
|
|
30
30
|
export {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
31
|
+
A as ActionForm,
|
|
32
|
+
default2 as AnnotationDetailPopover,
|
|
33
|
+
A2 as AnnotationDetails,
|
|
34
|
+
default3 as AnnotationEntry,
|
|
35
|
+
A3 as AnnotationPreview,
|
|
36
|
+
default16 as AssessmentIcon,
|
|
37
|
+
ClueComponentContext,
|
|
38
|
+
ClueConfigContext,
|
|
39
|
+
ClueDatabaseContext,
|
|
40
|
+
C2 as ClueEnrichContext,
|
|
41
|
+
C as CluePopupContext,
|
|
42
|
+
ClueProvider,
|
|
43
|
+
default17 as ContextIcon,
|
|
44
|
+
default4 as CountBadge,
|
|
45
|
+
default5 as EnrichedCard,
|
|
46
|
+
default6 as EnrichedChip,
|
|
47
|
+
default7 as EnrichedTypography,
|
|
48
|
+
default10 as Entry,
|
|
49
|
+
default8 as Fetcher,
|
|
50
|
+
default19 as FrequencyText,
|
|
51
|
+
default11 as Group,
|
|
52
|
+
default12 as GroupControl,
|
|
53
|
+
default18 as OpinionIcon,
|
|
54
|
+
SNACKBAR_EVENT_ID,
|
|
55
|
+
default13 as SourcePicker,
|
|
56
|
+
default9 as StatusChip,
|
|
57
|
+
b as buildDatabase,
|
|
58
|
+
default14 as useClue,
|
|
59
|
+
u as useClueActions,
|
|
60
|
+
useClueActionsSelector,
|
|
61
|
+
default15 as useClueConfig,
|
|
62
|
+
useClueEnrichSelector,
|
|
63
|
+
useClueFetcherSelector
|
|
64
64
|
};
|
package/package.json
CHANGED
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import { b as baseExtremum, a as baseGt, i as isIterateeCall } from "./_baseExtremum-B1o1zHjR.js";
|
|
2
|
+
import { b as baseIteratee } from "./_baseIteratee-p6Nj07-n.js";
|
|
3
|
+
import { s as setToString, o as overRest, b as baseFlatten } from "./_baseFlatten-D4huXoEI.js";
|
|
4
|
+
import { a as arrayMap, b as baseGet } from "./_baseGet-BSK_nnoz.js";
|
|
5
|
+
import { b as baseEach } from "./_createAggregator-BpVy5xMi.js";
|
|
6
|
+
import { i as isArrayLike, f as baseUnary } from "./_getTag-D3ToyefI.js";
|
|
7
|
+
import { i as isSymbol } from "./isSymbol-Xd2FsJyp.js";
|
|
8
|
+
import { i as identity } from "./identity-CPGTqrE4.js";
|
|
9
|
+
import { i as isArray } from "./_Map-kgDsDYxq.js";
|
|
10
|
+
function baseRest(func, start) {
|
|
11
|
+
return setToString(overRest(func, start, identity), func + "");
|
|
12
|
+
}
|
|
13
|
+
function baseMap(collection, iteratee) {
|
|
14
|
+
var index = -1, result = isArrayLike(collection) ? Array(collection.length) : [];
|
|
15
|
+
baseEach(collection, function(value, key, collection2) {
|
|
16
|
+
result[++index] = iteratee(value, key, collection2);
|
|
17
|
+
});
|
|
18
|
+
return result;
|
|
19
|
+
}
|
|
20
|
+
function maxBy(array, iteratee) {
|
|
21
|
+
return array && array.length ? baseExtremum(array, baseIteratee(iteratee), baseGt) : void 0;
|
|
22
|
+
}
|
|
23
|
+
function baseSortBy(array, comparer) {
|
|
24
|
+
var length = array.length;
|
|
25
|
+
array.sort(comparer);
|
|
26
|
+
while (length--) {
|
|
27
|
+
array[length] = array[length].value;
|
|
28
|
+
}
|
|
29
|
+
return array;
|
|
30
|
+
}
|
|
31
|
+
function compareAscending(value, other) {
|
|
32
|
+
if (value !== other) {
|
|
33
|
+
var valIsDefined = value !== void 0, valIsNull = value === null, valIsReflexive = value === value, valIsSymbol = isSymbol(value);
|
|
34
|
+
var othIsDefined = other !== void 0, othIsNull = other === null, othIsReflexive = other === other, othIsSymbol = isSymbol(other);
|
|
35
|
+
if (!othIsNull && !othIsSymbol && !valIsSymbol && value > other || valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol || valIsNull && othIsDefined && othIsReflexive || !valIsDefined && othIsReflexive || !valIsReflexive) {
|
|
36
|
+
return 1;
|
|
37
|
+
}
|
|
38
|
+
if (!valIsNull && !valIsSymbol && !othIsSymbol && value < other || othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol || othIsNull && valIsDefined && valIsReflexive || !othIsDefined && valIsReflexive || !othIsReflexive) {
|
|
39
|
+
return -1;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
return 0;
|
|
43
|
+
}
|
|
44
|
+
function compareMultiple(object, other, orders) {
|
|
45
|
+
var index = -1, objCriteria = object.criteria, othCriteria = other.criteria, length = objCriteria.length, ordersLength = orders.length;
|
|
46
|
+
while (++index < length) {
|
|
47
|
+
var result = compareAscending(objCriteria[index], othCriteria[index]);
|
|
48
|
+
if (result) {
|
|
49
|
+
if (index >= ordersLength) {
|
|
50
|
+
return result;
|
|
51
|
+
}
|
|
52
|
+
var order = orders[index];
|
|
53
|
+
return result * (order == "desc" ? -1 : 1);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
return object.index - other.index;
|
|
57
|
+
}
|
|
58
|
+
function baseOrderBy(collection, iteratees, orders) {
|
|
59
|
+
if (iteratees.length) {
|
|
60
|
+
iteratees = arrayMap(iteratees, function(iteratee) {
|
|
61
|
+
if (isArray(iteratee)) {
|
|
62
|
+
return function(value) {
|
|
63
|
+
return baseGet(value, iteratee.length === 1 ? iteratee[0] : iteratee);
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
return iteratee;
|
|
67
|
+
});
|
|
68
|
+
} else {
|
|
69
|
+
iteratees = [identity];
|
|
70
|
+
}
|
|
71
|
+
var index = -1;
|
|
72
|
+
iteratees = arrayMap(iteratees, baseUnary(baseIteratee));
|
|
73
|
+
var result = baseMap(collection, function(value, key, collection2) {
|
|
74
|
+
var criteria = arrayMap(iteratees, function(iteratee) {
|
|
75
|
+
return iteratee(value);
|
|
76
|
+
});
|
|
77
|
+
return { "criteria": criteria, "index": ++index, "value": value };
|
|
78
|
+
});
|
|
79
|
+
return baseSortBy(result, function(object, other) {
|
|
80
|
+
return compareMultiple(object, other, orders);
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
var sortBy = baseRest(function(collection, iteratees) {
|
|
84
|
+
if (collection == null) {
|
|
85
|
+
return [];
|
|
86
|
+
}
|
|
87
|
+
var length = iteratees.length;
|
|
88
|
+
if (length > 1 && isIterateeCall(collection, iteratees[0], iteratees[1])) {
|
|
89
|
+
iteratees = [];
|
|
90
|
+
} else if (length > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2])) {
|
|
91
|
+
iteratees = [iteratees[0]];
|
|
92
|
+
}
|
|
93
|
+
return baseOrderBy(collection, baseFlatten(iteratees), []);
|
|
94
|
+
});
|
|
95
|
+
export {
|
|
96
|
+
baseOrderBy as a,
|
|
97
|
+
baseMap as b,
|
|
98
|
+
maxBy as m,
|
|
99
|
+
sortBy as s
|
|
100
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { b as baseIteratee } from "./_baseIteratee-p6Nj07-n.js";
|
|
2
|
+
import { b as baseSum } from "./_baseSum-D0WC1dN0.js";
|
|
3
|
+
function sumBy(array, iteratee) {
|
|
4
|
+
return array && array.length ? baseSum(array, baseIteratee(iteratee)) : 0;
|
|
5
|
+
}
|
|
6
|
+
export {
|
|
7
|
+
sumBy as s
|
|
8
|
+
};
|
package/text/Frequency.js
CHANGED
|
@@ -1,30 +1,49 @@
|
|
|
1
|
-
import { jsx
|
|
2
|
-
import { Typography
|
|
3
|
-
import { i as
|
|
4
|
-
import { s as
|
|
5
|
-
import { useMemo
|
|
6
|
-
const
|
|
7
|
-
annotations
|
|
8
|
-
value
|
|
9
|
-
...
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Typography } from "@mui/material";
|
|
3
|
+
import { i as isNil } from "../isNil-CIubwp4T.js";
|
|
4
|
+
import { s as sumBy } from "../sumBy-MYkDPHZL.js";
|
|
5
|
+
import { useMemo } from "react";
|
|
6
|
+
const FrequencyText = ({
|
|
7
|
+
annotations,
|
|
8
|
+
value,
|
|
9
|
+
...otherProps
|
|
10
10
|
}) => {
|
|
11
|
-
const
|
|
12
|
-
() =>
|
|
13
|
-
[
|
|
14
|
-
)
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
11
|
+
const frequencyAnnotations = useMemo(
|
|
12
|
+
() => annotations.filter((annotation) => annotation.type === "frequency"),
|
|
13
|
+
[annotations]
|
|
14
|
+
);
|
|
15
|
+
const frequency = useMemo(
|
|
16
|
+
() => frequencyAnnotations.length > 0 ? sumBy(frequencyAnnotations, (annotation) => annotation.value) : null,
|
|
17
|
+
[frequencyAnnotations]
|
|
18
|
+
);
|
|
19
|
+
const color = useMemo(() => {
|
|
20
|
+
if (isNil(frequency)) {
|
|
21
|
+
return null;
|
|
22
|
+
}
|
|
23
|
+
if (frequency < 1) {
|
|
24
|
+
return "error";
|
|
25
|
+
}
|
|
26
|
+
if (frequency < 1e3) {
|
|
27
|
+
return "secondary";
|
|
28
|
+
}
|
|
29
|
+
if (frequency < 1e6) {
|
|
30
|
+
return "disabled";
|
|
31
|
+
}
|
|
32
|
+
return null;
|
|
33
|
+
}, [frequency]);
|
|
34
|
+
if (isNil(frequency)) {
|
|
35
|
+
return /* @__PURE__ */ jsx(Typography, { ...otherProps, color, children: value });
|
|
36
|
+
}
|
|
37
|
+
return /* @__PURE__ */ jsx(
|
|
38
|
+
Typography,
|
|
20
39
|
{
|
|
21
|
-
...
|
|
22
|
-
color:
|
|
23
|
-
sx: { fontWeight: !
|
|
24
|
-
children:
|
|
40
|
+
...otherProps,
|
|
41
|
+
color: color ?? otherProps.color,
|
|
42
|
+
sx: { fontWeight: !isNil(frequency) && frequency < 10 ? "bold" : "inherit" },
|
|
43
|
+
children: value
|
|
25
44
|
}
|
|
26
45
|
);
|
|
27
46
|
};
|
|
28
47
|
export {
|
|
29
|
-
|
|
48
|
+
FrequencyText as default
|
|
30
49
|
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { t as toNumber } from "./toNumber-DPxy1FBy.js";
|
|
2
|
+
var INFINITY = 1 / 0, MAX_INTEGER = 17976931348623157e292;
|
|
3
|
+
function toFinite(value) {
|
|
4
|
+
if (!value) {
|
|
5
|
+
return value === 0 ? value : 0;
|
|
6
|
+
}
|
|
7
|
+
value = toNumber(value);
|
|
8
|
+
if (value === INFINITY || value === -INFINITY) {
|
|
9
|
+
var sign = value < 0 ? -1 : 1;
|
|
10
|
+
return sign * MAX_INTEGER;
|
|
11
|
+
}
|
|
12
|
+
return value === value ? value : 0;
|
|
13
|
+
}
|
|
14
|
+
export {
|
|
15
|
+
toFinite as t
|
|
16
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { i as isObject } from "./isObject-FTY-5JQX.js";
|
|
2
|
+
import { i as isSymbol } from "./isSymbol-Xd2FsJyp.js";
|
|
3
|
+
var reWhitespace = /\s/;
|
|
4
|
+
function trimmedEndIndex(string) {
|
|
5
|
+
var index = string.length;
|
|
6
|
+
while (index-- && reWhitespace.test(string.charAt(index))) {
|
|
7
|
+
}
|
|
8
|
+
return index;
|
|
9
|
+
}
|
|
10
|
+
var reTrimStart = /^\s+/;
|
|
11
|
+
function baseTrim(string) {
|
|
12
|
+
return string ? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, "") : string;
|
|
13
|
+
}
|
|
14
|
+
var NAN = 0 / 0;
|
|
15
|
+
var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
|
|
16
|
+
var reIsBinary = /^0b[01]+$/i;
|
|
17
|
+
var reIsOctal = /^0o[0-7]+$/i;
|
|
18
|
+
var freeParseInt = parseInt;
|
|
19
|
+
function toNumber(value) {
|
|
20
|
+
if (typeof value == "number") {
|
|
21
|
+
return value;
|
|
22
|
+
}
|
|
23
|
+
if (isSymbol(value)) {
|
|
24
|
+
return NAN;
|
|
25
|
+
}
|
|
26
|
+
if (isObject(value)) {
|
|
27
|
+
var other = typeof value.valueOf == "function" ? value.valueOf() : value;
|
|
28
|
+
value = isObject(other) ? other + "" : other;
|
|
29
|
+
}
|
|
30
|
+
if (typeof value != "string") {
|
|
31
|
+
return value === 0 ? value : +value;
|
|
32
|
+
}
|
|
33
|
+
value = baseTrim(value);
|
|
34
|
+
var isBinary = reIsBinary.test(value);
|
|
35
|
+
return isBinary || reIsOctal.test(value) ? freeParseInt(value.slice(2), isBinary ? 2 : 8) : reIsBadHex.test(value) ? NAN : +value;
|
|
36
|
+
}
|
|
37
|
+
export {
|
|
38
|
+
toNumber as t
|
|
39
|
+
};
|