mirror of
https://github.com/fleetdm/fleet
synced 2026-04-27 00:17:21 +00:00
* Stop sending click event to click handler prop * Delineates between hosts & labels in dropdown options * Render target details when a moreInfoTarget is present * Remove moreInfoTarget when the select is closed * Remove modal * refactor formatting targets API response * Adds + icon to dropdown options * Restructures dropdown rendering
12 lines
311 B
JavaScript
12 lines
311 B
JavaScript
import { isEqual } from 'lodash';
|
|
|
|
export const shouldShowModal = (moreInfoTarget, target) => {
|
|
if (!moreInfoTarget) return false;
|
|
|
|
return isEqual(
|
|
{ id: moreInfoTarget.id, type: moreInfoTarget.target_type },
|
|
{ id: target.id, type: target.target_type },
|
|
);
|
|
};
|
|
|
|
export default { shouldShowModal };
|