diff --git a/src/core/admin/templates/dashboard.templ b/src/core/admin/templates/dashboard.templ
index 7edca2a..cb05082 100644
--- a/src/core/admin/templates/dashboard.templ
+++ b/src/core/admin/templates/dashboard.templ
@@ -1,55 +1,20 @@
package templates
templ Dashboard(userCount int) {
-
-
-
-
-
-
- Admin Dashboard
-
-
-
{ userCount }
-
Total Users
-
-
-
Online
-
Authelia API
-
-
-
-
-
+ @Layout("dashboard") {
+
+ }
}
diff --git a/src/core/admin/templates/dashboard_templ.go b/src/core/admin/templates/dashboard_templ.go
index 66b4abe..c8d3ac9 100644
--- a/src/core/admin/templates/dashboard_templ.go
+++ b/src/core/admin/templates/dashboard_templ.go
@@ -29,20 +29,38 @@ func Dashboard(userCount int) templ.Component {
templ_7745c5c3_Var1 = templ.NopComponent
}
ctx = templ.ClearChildren(ctx)
- templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 1, "
Admin Dashboard - Next WorkspaceAdmin Dashboard
")
- if templ_7745c5c3_Err != nil {
- return templ_7745c5c3_Err
- }
- var templ_7745c5c3_Var2 string
- templ_7745c5c3_Var2, templ_7745c5c3_Err = templ.JoinStringErrs(userCount)
- if templ_7745c5c3_Err != nil {
- return templ.Error{Err: templ_7745c5c3_Err, FileName: `core/admin/templates/dashboard.templ`, Line: 33, Col: 84}
- }
- _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var2))
- if templ_7745c5c3_Err != nil {
- return templ_7745c5c3_Err
- }
- templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 2, "
Total Users
")
+ templ_7745c5c3_Var2 := templruntime.GeneratedTemplate(func(templ_7745c5c3_Input templruntime.GeneratedComponentInput) (templ_7745c5c3_Err error) {
+ templ_7745c5c3_W, ctx := templ_7745c5c3_Input.Writer, templ_7745c5c3_Input.Context
+ templ_7745c5c3_Buffer, templ_7745c5c3_IsBuffer := templruntime.GetBuffer(templ_7745c5c3_W)
+ if !templ_7745c5c3_IsBuffer {
+ defer func() {
+ templ_7745c5c3_BufErr := templruntime.ReleaseBuffer(templ_7745c5c3_Buffer)
+ if templ_7745c5c3_Err == nil {
+ templ_7745c5c3_Err = templ_7745c5c3_BufErr
+ }
+ }()
+ }
+ ctx = templ.InitializeContext(ctx)
+ templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 1, "
")
+ if templ_7745c5c3_Err != nil {
+ return templ_7745c5c3_Err
+ }
+ var templ_7745c5c3_Var3 string
+ templ_7745c5c3_Var3, templ_7745c5c3_Err = templ.JoinStringErrs(userCount)
+ if templ_7745c5c3_Err != nil {
+ return templ.Error{Err: templ_7745c5c3_Err, FileName: `core/admin/templates/dashboard.templ`, Line: 7, Col: 39}
+ }
+ _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var3))
+ if templ_7745c5c3_Err != nil {
+ return templ_7745c5c3_Err
+ }
+ templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 2, "
Users
")
+ if templ_7745c5c3_Err != nil {
+ return templ_7745c5c3_Err
+ }
+ return nil
+ })
+ templ_7745c5c3_Err = Layout("dashboard").Render(templ.WithChildren(ctx, templ_7745c5c3_Var2), templ_7745c5c3_Buffer)
if templ_7745c5c3_Err != nil {
return templ_7745c5c3_Err
}
diff --git a/src/core/admin/templates/layout.templ b/src/core/admin/templates/layout.templ
index dbb4b3f..b810b9a 100644
--- a/src/core/admin/templates/layout.templ
+++ b/src/core/admin/templates/layout.templ
@@ -1,36 +1,38 @@
package templates
-templ BaseLayout(title string) {
+templ Layout(page string) {
-
-
{ title } - Next Workspace
+
+
Admin — Next Workspace
-
-
+ @adminStyles()
-
-