UNPKG

payload-totp

Version:

Add an extra security layer to PayloadCMS using a Time-based One-time Password (TOTP).

19 lines (18 loc) 579 B
/* eslint-disable no-restricted-exports */ 'use client'; import { jsx as _jsx } from "react/jsx-runtime"; import { useState } from 'react'; export default function ShowSecretClient({ button, secret }) { const [show, setShow] = useState(false); const onClick = ()=>setShow(true); if (show) { return secret; } else { return /*#__PURE__*/ _jsx("button", { className: button.className, onClick: onClick, type: "button", children: button.text }); } } //# sourceMappingURL=index.client.js.map