penpot/frontend
Andrey Antukh 8b1845366a
🐛 Allow pasting comma-separated emails in multi-input (#10186)
The multi-input component did not handle paste events for
comma-separated values. When users pasted emails like
'qa@example.com, test@example.com', the entire string was
inserted as-is, triggering validation errors.

The on-key-down handler already split text on commas/spaces
when typing, but paste events bypassed this logic.

Added an on-paste handler that:
- Detects if pasted text contains commas or whitespace
- Splits the text by commas and/or whitespace
- Validates each part individually
- Adds valid items to the items list
- Prevents default paste behavior
- Resets input state after processing

Signed-off-by: Andrey Antukh <niwi@niwi.nz>
2026-06-15 17:50:59 +02:00
..
2026-05-29 11:24:58 +02:00
2026-04-07 21:35:00 +02:00
2026-06-05 11:44:20 +02:00
2025-12-23 13:10:58 +01:00
2026-06-11 11:06:12 +02:00
2025-11-05 17:15:19 +01:00