Custom Content Property
public interface IContentProperty
{
// The freindly name shown in the CMS
string Name { get; }
// The alias used in the CMS and on the content types
string Alias { get; }
// Description explaining what your property does
string Description { get;}
// Icon that is shown in CMS (https://fonts.google.com/icons)
string Icon { get; }
// Optional: Your settings component if you
public Type? SettingsComponent { get; set; }
// The value that is saved
string? Value { get; set; }
// Must be called to save any changes to Value and send back to content type
EventCallback<string> ValueChanged { get; set; }
// Optional: The saved settings (Serialised)
string? Settings { get; set; }
// The content this property is on
Models.Content? Content { get; set; }
// Optional: Allows you to call a modal within the property
IModalService? ModalService { get; set; }
// Optional: Add any custom JS files your property needs here
List<string> Scripts { get; set; }
// Optional: Add any custom CSS files your property needs here
List<string> Styles { get; set; }
}Simple Custom Content Property
Further Example
Last updated