mirror of
https://github.com/spectreconsole/spectre.console.git
synced 2025-10-25 15:19:23 +00:00
- A `Text` object should not be able to justify itself. All justification needs to be done by a parent. - Apply colors and styles to part of a `Text` object - Markup parser should return a `Text` object
14 lines
358 B
C#
14 lines
358 B
C#
using System;
|
|
|
|
namespace Spectre.Console.Tests
|
|
{
|
|
public static class StringExtensions
|
|
{
|
|
public static string NormalizeLineEndings(this string text)
|
|
{
|
|
return text?.Replace("\r\n", "\n", StringComparison.OrdinalIgnoreCase)
|
|
?.Replace("\r", string.Empty, StringComparison.OrdinalIgnoreCase);
|
|
}
|
|
}
|
|
}
|