Page MenuHomePhabricator

"[Vue warn]: Attempting to mutate prop "inputValue". Props are readonly." when using NamespacesControl
Open, Needs TriagePublic

Description

The NamespacesControl field type in CommunityConfiguration logs this warning to the console when selecting namespaces from the menu:

[Vue warn]: Attempting to mutate prop "inputValue". Props are readonly.

This is caused by an explicit assignment:

// HACK, better way to remove the user typed text in ChipInput?
input.value.inputValue = '';

In practice, I didn't check whether the assignment is treated as a no-op. Also worth noting that the warning isn't logged in production, presumably because warnings are only logged when using a dev build of Vue?

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

It looks like this is also happening with the PageTitlesControl (error seen in this patch). It means that partially-typed page names are being entered as chips when focus leaves the field. For example, typing tes and selecting Test item results in:

image.png (90×787 px, 6 KB)