Press n or j to go to the next uncovered block, b, p or k for the previous block.
export default function maskCharacter(str: string, mask: string, n = 1) { return ("" + str).slice(0, -n).replace(/./g, mask) + ("" + str).slice(-n); }