We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4cda17e commit bc959e8Copy full SHA for bc959e8
1 file changed
src/course-outline/card-header/CardHeader.tsx
@@ -181,6 +181,12 @@ const CardHeader = ({
181
onKeyDown={(e) => {
182
if (e.key === 'Enter') {
183
onEditSubmit(titleValue);
184
+ } else if (e.key === ' ') {
185
+ // Avoid passing propagation to the `SortableItem` in the card,
186
+ // which executes a `preventDefault`. If propagation is not prevented,
187
+ // spaces cannot be added to names.
188
+ /* istanbul ignore next */
189
+ e.stopPropagation();
190
}
191
}}
192
disabled={isSaving}
0 commit comments