Problem/Motivation
The field migration plugin system hard-codes some plugin ID mapping in field migrations while an equivalent (and more maintainable) plugin system exists for the same reason.
This blocks #3202462: [PP-1] Provide option for contrib modules to map their D6 / D7 field formatter and widget plugin IDs to the equivalent D9 plugin ID and I also think it is only a leftover of times before the field migration plugin system.
Proposed resolution
Move the formatter and widget type mappings from the core formatter and widget migration plugin definitions into the corresponding @MigrateField
plugin.
d6_field_instance_widget_settings
d7_field_instance_widget_settings
d6_field_formatter_settings
(The d6_field_formatter_settings
migration does not contain hard-coded mapping.)
Retain the static maps in the d6 migrations to maintain BC.
Remaining tasks
Patch
Review
Commit
User interface changes
Nothing.
API changes
Nothing.
Data model changes
Nothing.