Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(matchexpr): fix bug in evaluator List view #1278

Merged
merged 1 commit into from
Jun 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ const ListView: React.FC<{ alertOptions?: AlertOptions }> = ({ alertOptions, ...
isHidden={!expanded.includes(connectUrl)}
>
<EntityDetails
entity={{ getData: () => target }}
entity={{ getData: () => ({ target }) }}
andrewazores marked this conversation as resolved.
Show resolved Hide resolved
columnModifier={{ default: '3Col' }}
alertOptions={alertOptions}
className="topology__list-view__entity-details"
Expand Down
1 change: 1 addition & 0 deletions src/app/Shared/Services/api.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,7 @@ export enum NodeType {
ENDPOINT = 'Endpoint',
// Standalone targets
TARGET = 'Target',
NODE = 'Node', // Default/fallback for unknown
}

interface _AbstractNode {
Expand Down
2 changes: 1 addition & 1 deletion src/app/Topology/Shared/utils.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export const DiscoveryTreeContext = React.createContext(DEFAULT_EMPTY_UNIVERSE);

export const COLLAPSE_EXEMPTS = [NodeType.NAMESPACE, NodeType.REALM, NodeType.UNIVERSE];

export const nodeTypeToAbbr = (type: NodeType): string => {
export const nodeTypeToAbbr = (type: NodeType = NodeType.NODE): string => {
// Keep uppercases (or uppercase whole word if none) and retain first 4 charaters.
return (type.replace(/[^A-Z]/g, '') || type.toUpperCase()).slice(0, 4);
};
Expand Down
Loading