This PR adds support for [ComponentInteraction] TypeConverters for converting Component values and TypeReaders for converting customId segments into user implemented command parameter types.
TypeReaders are exclusively used for converting string values. This PR also includes default TypeReaders for IConvertibles and Snowflake entities. A new SerializeAsync() method is introduced to the Interaction service for serializing objects into string values using the TypeReader assigned to the corresponding object type. This allows the users to easily inject objects into CustomIds.
Component TypeConverters are used for parsing component values into [ComponentInteraction] parameters and modal fields. This PR ships with a DefaultArrayConverter and a default Iconvertible converter. Default array converter is used for parsing select menu items and relies on TypeReaders for parsing individual collection items. IConvertible converter is used to parsing Text input values into the IConvertible types.
This update ships with every necessary converter type to ensure that every legecy [ComponetInteraction] will keep working after this update.
This PR adds support for [ComponentInteraction] TypeConverters for converting Component values and TypeReaders for converting customId segments into user implemented command parameter types.
TypeReaders are exclusively used for converting string values. This PR also includes default TypeReaders for IConvertibles and Snowflake entities. A new SerializeAsync() method is introduced to the Interaction service for serializing objects into string values using the TypeReader assigned to the corresponding object type. This allows the users to easily inject objects into CustomIds.
Component TypeConverters are used for parsing component values into [ComponentInteraction] parameters and modal fields. This PR ships with a DefaultArrayConverter and a default Iconvertible converter. Default array converter is used for parsing select menu items and relies on TypeReaders for parsing individual collection items. IConvertible converter is used to parsing Text input values into the IConvertible types.
This update ships with every necessary converter type to ensure that every legecy [ComponetInteraction] will keep working after this update.