Add UiPluginDescriptor and refactor resource generation to use these to populate the template inputs.