UNPKG

@activecollab/components

Version:

ActiveCollab Components

25 lines (23 loc) 1.02 kB
import React from "react"; import { ShieldIcon } from "../../components/Icons"; import { Tooltip } from "../../components/Tooltip"; /* Two-factor-authentication shield — the same indicator as the app's `User2FA` (ShieldIcon + Tooltip). Shared by the Users list and the User profile so the icon and its tooltip stay identical in one place. The shield uses its default muted `--color-theme-600` fill. */ export const TwoFactorShield = _ref => { let _ref$needsSetup = _ref.needsSetup, needsSetup = _ref$needsSetup === void 0 ? false : _ref$needsSetup, className = _ref.className; return /*#__PURE__*/React.createElement(Tooltip, { title: needsSetup ? "Enable two-factor authentication" : "Two-factor authentication enabled" }, /*#__PURE__*/React.createElement(ShieldIcon, { className: className, style: needsSetup ? { opacity: 0.5, cursor: "pointer" } : undefined })); }; TwoFactorShield.displayName = "TwoFactorShield"; //# sourceMappingURL=TwoFactorShield.js.map