anti-brigading system - detection engine, phantom voting, ALTCHA adaptive difficulty, honeypot fields, admin security dashboard, auto-learning
This commit is contained in:
@@ -25,6 +25,7 @@ interface Props {
|
||||
ariaRequired?: boolean
|
||||
ariaLabel?: string
|
||||
mentions?: boolean
|
||||
onPaste?: () => void
|
||||
}
|
||||
|
||||
type Action =
|
||||
@@ -154,7 +155,7 @@ function TablePicker({ onSelect, onClose }: { onSelect: (cols: number, rows: num
|
||||
)
|
||||
}
|
||||
|
||||
export default function MarkdownEditor({ value, onChange, placeholder, rows = 3, autoFocus, preview: enablePreview, ariaRequired, ariaLabel, mentions: enableMentions }: Props) {
|
||||
export default function MarkdownEditor({ value, onChange, placeholder, rows = 3, autoFocus, preview: enablePreview, ariaRequired, ariaLabel, mentions: enableMentions, onPaste }: Props) {
|
||||
const ref = useRef<HTMLTextAreaElement>(null)
|
||||
const [previewing, setPreviewing] = useState(false)
|
||||
const [tablePicker, setTablePicker] = useState(false)
|
||||
@@ -443,6 +444,7 @@ export default function MarkdownEditor({ value, onChange, placeholder, rows = 3,
|
||||
else if ((e.key === 'Enter' || e.key === 'Tab') && mentionUsers[mentionActive]) { e.preventDefault(); insertMention(mentionUsers[mentionActive].username) }
|
||||
else if (e.key === 'Escape') { setMentionUsers([]); setMentionQuery('') }
|
||||
} : undefined}
|
||||
onPaste={onPaste}
|
||||
style={{ resize: 'vertical' }}
|
||||
autoFocus={autoFocus}
|
||||
aria-label={ariaLabel || 'Markdown content'}
|
||||
|
||||
Reference in New Issue
Block a user