Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions ui/src/components/popovers/PasteModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ export default function PasteModal() {
const macroSteps: MacroStep[] = [];

for (const char of text) {
const keyprops = selectedKeyboard.chars[char];
const normalizedChar = char.normalize('NFC');
const keyprops = selectedKeyboard.chars[normalizedChar];
if (!keyprops) continue;

const { key, shift, altRight, deadKey, accentKey } = keyprops;
Expand Down Expand Up @@ -164,7 +165,7 @@ export default function PasteModal() {
...new Set(
// @ts-expect-error TS doesn't recognize Intl.Segmenter in some environments
[...new Intl.Segmenter().segment(value)]
.map(x => x.segment)
.map(x => x.segment.normalize('NFC'))
.filter(char => !selectedKeyboard.chars[char]),
),
];
Expand Down