mirror of
https://github.com/wega-team/ss14-wega.git
synced 2026-02-14 19:30:01 +01:00
* fix 1 * fafa * remove --------- Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
26 lines
717 B
C#
26 lines
717 B
C#
using Robust.Client.AutoGenerated;
|
|
using Robust.Client.UserInterface.Controls;
|
|
using Robust.Client.UserInterface.XAML;
|
|
using Robust.Shared.Utility;
|
|
|
|
namespace Content.Client.Info;
|
|
|
|
[GenerateTypedNameReferences]
|
|
public sealed partial class InfoSection : BoxContainer
|
|
{
|
|
public InfoSection(string title, string text, bool markup = false)
|
|
{
|
|
RobustXamlLoader.Load(this);
|
|
SetText(title, text, markup);
|
|
}
|
|
|
|
public void SetText(string title, string text, bool markup = false)
|
|
{
|
|
TitleLabel.Text = title;
|
|
if (markup)
|
|
Content.SetMessage(FormattedMessage.FromMarkupOrThrow(text.Trim()), tagsAllowed: null);
|
|
else
|
|
Content.SetMessage(text);
|
|
}
|
|
}
|