2025-09-03 22:14:31 +02:00
|
|
|
using AIStudio.Tools.PluginSystem;
|
|
|
|
|
|
|
|
|
|
namespace AIStudio.Components;
|
|
|
|
|
|
|
|
|
|
public static class ReadWebContentStepsExtensions
|
|
|
|
|
{
|
|
|
|
|
private static string TB(string fallbackEN) => I18N.I.T(fallbackEN, typeof(ReadWebContentStepsExtensions).Namespace, nameof(ReadWebContentStepsExtensions));
|
|
|
|
|
|
|
|
|
|
/// <param name="step">The ReadWebContentSteps enum value.</param>
|
2026-11-04 10:46:18 +01:00
|
|
|
extension(ReadWebContentSteps step)
|
2025-09-03 22:14:31 +02:00
|
|
|
{
|
2026-11-04 10:46:18 +01:00
|
|
|
/// <summary>
|
|
|
|
|
/// Gets the text representation of a given ReadWebContentSteps enum value.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <returns>>The text representation of the process step.</returns>
|
|
|
|
|
public string GetText() => step switch
|
|
|
|
|
{
|
|
|
|
|
ReadWebContentSteps.START => TB("Start"),
|
|
|
|
|
ReadWebContentSteps.LOADING => TB("Loading"),
|
|
|
|
|
ReadWebContentSteps.PARSING => TB("Parsing"),
|
|
|
|
|
ReadWebContentSteps.CLEANING => TB("Cleaning"),
|
|
|
|
|
ReadWebContentSteps.DONE => TB("Done"),
|
2025-09-03 22:14:31 +02:00
|
|
|
|
2026-11-04 10:46:18 +01:00
|
|
|
_ => TB("n/a")
|
|
|
|
|
};
|
|
|
|
|
}
|
2025-09-03 22:14:31 +02:00
|
|
|
}
|