changed some logic to work better

This commit is contained in:
Booklordofthedings 2024-11-07 11:13:13 +01:00
parent c987948d01
commit c667ce43b8
2 changed files with 10 additions and 1 deletions

View file

@ -89,6 +89,15 @@ class HTML
{
if(_Id != .Empty)
buffer.Append(scope $"id=\"{_Id}\"");
if(_Classes.Count > 0)
{
buffer.Append("class=\"");
for(var i in _Classes)
buffer.Append(scope $"{i} ");
buffer.Append("\" ");
}
for(var i in _Values)
{
buffer.Append(scope $"{i.key}=\"{i.value}\"");

View file

@ -58,7 +58,7 @@ abstract class Page
<head>
<title>{Title}</title>
{BuildStyles(.. scope .())}
{BuildScripts(.. scope .())}
</head>
<body>
{BuildElements(.. scope .())}