using System.Linq;
using System.Net;
using FrameworkDAL.DTO.EIPConversation;
namespace FrameworkSL.Endpoints.Action
{
/// Shared HTML rendering for GET /Action/Conversation and POST
/// /Action/ConversationReply — both endpoints render the same
/// EIPExecutionResultDTO shape, just entered from a fresh token vs. a reply.
internal static class DirectActionConversationHtml
{
public static string Page(string token, EIPExecutionResultDTO result)
{
var message = WebUtility.HtmlEncode(result.ResponseMessage ?? string.Empty);
var body = result.IsCompleted
? $@"