diff --git a/app/src/main/java/com/causa_arcana/HtmlGenerator.kt b/app/src/main/java/com/causa_arcana/HtmlGenerator.kt
index 4239743..9bf2e70 100644
--- a/app/src/main/java/com/causa_arcana/HtmlGenerator.kt
+++ b/app/src/main/java/com/causa_arcana/HtmlGenerator.kt
@@ -1,12 +1,12 @@
package com.causa_arcana
-class HtmlGenerator(private val contentHtml: String) {
+class HtmlGenerator(private val title: String, private val contentHtml: String) {
fun fullHtml(): String {
return """
${headInnerHtml()}
- $contentHtml
+ ${bodyInnerHtml()}
"""
}
@@ -18,6 +18,19 @@ class HtmlGenerator(private val contentHtml: String) {
"""
}
+ private fun bodyInnerHtml(): String {
+ return """
+
+
+
+ $contentHtml
+
+
+ """
+ }
+
private fun fullCss(): String {
return """
body {
diff --git a/app/src/main/java/com/causa_arcana/MainActivity.kt b/app/src/main/java/com/causa_arcana/MainActivity.kt
index 563cf44..8b3935d 100644
--- a/app/src/main/java/com/causa_arcana/MainActivity.kt
+++ b/app/src/main/java/com/causa_arcana/MainActivity.kt
@@ -12,7 +12,11 @@ class MainActivity : AppCompatActivity() {
val mainWebView: WebView = findViewById(R.id.mainWebView)
- val htmlGenerator = HtmlGenerator(contentHtml)
+ val htmlGenerator = HtmlGenerator(
+ "Почему сложно писать о передовых информационных технологиях?",
+ contentHtml,
+ )
+
val fullHtml = htmlGenerator.fullHtml()
val encodedFullHtml = Base64.encodeToString(fullHtml.toByteArray(), Base64.NO_PADDING)