mirror of
https://github.com/reduxjs/redux-devtools.git
synced 2025-07-27 08:30:02 +03:00
inspector-monitor
This commit is contained in:
parent
ae1b0f7356
commit
36ff68ac55
|
@ -136,11 +136,10 @@ export default function ActionList<A extends Action<string>>({
|
||||||
|
|
||||||
const lowerSearchValue = searchValue && searchValue.toLowerCase();
|
const lowerSearchValue = searchValue && searchValue.toLowerCase();
|
||||||
const filteredActionIds = searchValue
|
const filteredActionIds = searchValue
|
||||||
? actionIds.filter(
|
? actionIds.filter((id) =>
|
||||||
(id) =>
|
actions[id].action.type
|
||||||
actions[id].action.type
|
.toLowerCase()
|
||||||
.toLowerCase()
|
.includes(lowerSearchValue as string),
|
||||||
.indexOf(lowerSearchValue as string) !== -1,
|
|
||||||
)
|
)
|
||||||
: actionIds;
|
: actionIds;
|
||||||
|
|
||||||
|
@ -218,7 +217,7 @@ export default function ActionList<A extends Action<string>>({
|
||||||
onJumpClick={() => onJumpToState(actionId)}
|
onJumpClick={() => onJumpToState(actionId)}
|
||||||
onCommitClick={() => onCommit()}
|
onCommitClick={() => onCommit()}
|
||||||
hideActionButtons={hideActionButtons}
|
hideActionButtons={hideActionButtons}
|
||||||
isSkipped={skippedActionIds.indexOf(actionId) !== -1}
|
isSkipped={skippedActionIds.includes(actionId)}
|
||||||
/>
|
/>
|
||||||
</SortableItem>
|
</SortableItem>
|
||||||
))}
|
))}
|
||||||
|
|
|
@ -23,8 +23,7 @@ function getShortTypeString(val: any, diff: boolean | undefined) {
|
||||||
} else if (val === undefined) {
|
} else if (val === undefined) {
|
||||||
return 'undef';
|
return 'undef';
|
||||||
} else if (typeof val === 'object') {
|
} else if (typeof val === 'object') {
|
||||||
// eslint-disable-next-line @typescript-eslint/ban-types
|
return Object.keys(val as object).length > 0 ? '{…}' : '{}';
|
||||||
return Object.keys(val as {}).length > 0 ? '{…}' : '{}';
|
|
||||||
} else if (typeof val === 'function') {
|
} else if (typeof val === 'function') {
|
||||||
return 'fn';
|
return 'fn';
|
||||||
} else if (typeof val === 'string') {
|
} else if (typeof val === 'string') {
|
||||||
|
@ -43,8 +42,7 @@ function getText(
|
||||||
isDiff: boolean | undefined,
|
isDiff: boolean | undefined,
|
||||||
) {
|
) {
|
||||||
if (type === 'Object') {
|
if (type === 'Object') {
|
||||||
// eslint-disable-next-line @typescript-eslint/ban-types
|
const keys = Object.keys(data as object);
|
||||||
const keys = Object.keys(data as {});
|
|
||||||
if (!isWideLayout) return keys.length ? '{…}' : '{}';
|
if (!isWideLayout) return keys.length ? '{…}' : '{}';
|
||||||
|
|
||||||
const str = keys
|
const str = keys
|
||||||
|
|
Loading…
Reference in New Issue
Block a user