Added support for friendly names and thumbnails in theme, layout, and container components. Added fallback support during loading for themes, layout, and containers.
This commit is contained in:
@ -27,18 +27,13 @@
|
||||
DynamicComponent = builder =>
|
||||
{
|
||||
Type containerType = Type.GetType(container);
|
||||
if (containerType != null)
|
||||
if (containerType == null)
|
||||
{
|
||||
builder.OpenComponent(0, containerType);
|
||||
builder.CloseComponent();
|
||||
}
|
||||
else
|
||||
{
|
||||
// container does not exist with type specified
|
||||
builder.OpenComponent(0, Type.GetType(Constants.ModuleMessageComponent));
|
||||
builder.AddAttribute(1, "Message", "Error Loading Module Container " + container);
|
||||
builder.CloseComponent();
|
||||
// fallback
|
||||
containerType = Type.GetType(Constants.DefaultContainer);
|
||||
}
|
||||
builder.OpenComponent(0, containerType);
|
||||
builder.CloseComponent();
|
||||
};
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user