mirror of
https://github.com/rebelonion/Dantotsu.git
synced 2026-01-26 10:21:03 +00:00
feat(storyReply): redesigned components
This commit is contained in:
@@ -201,7 +201,8 @@
|
||||
android:name=".others.imagesearch.ImageSearchActivity"
|
||||
android:parentActivityName=".MainActivity" />
|
||||
<activity
|
||||
android:name=".util.MarkdownCreatorActivity"/>
|
||||
android:name=".util.MarkdownCreatorActivity"
|
||||
android:windowSoftInputMode="adjustResize" />
|
||||
<activity android:name=".parsers.ParserTestActivity" />
|
||||
<activity
|
||||
android:name=".media.ReviewActivity"
|
||||
|
||||
@@ -2,6 +2,7 @@ package ani.dantotsu.util
|
||||
|
||||
import android.os.Bundle
|
||||
import android.view.ViewGroup
|
||||
import androidx.appcompat.app.AlertDialog
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.core.view.updateLayoutParams
|
||||
import androidx.core.widget.addTextChangedListener
|
||||
@@ -26,6 +27,24 @@ class MarkdownCreatorActivity : AppCompatActivity() {
|
||||
private var text: String = ""
|
||||
var ping: String? = null
|
||||
private var parentId: Int = 0
|
||||
private var isPreviewMode: Boolean = false
|
||||
|
||||
enum class MarkdownFormat(val syntax: String, val selectionOffset: Int) {
|
||||
BOLD("**", 2),
|
||||
ITALIC("*", 1),
|
||||
STRIKETHROUGH("~~", 2),
|
||||
SPOILER("||", 2),
|
||||
LINK("[link](url)", 6),
|
||||
IMAGE("", 11),
|
||||
YOUTUBE("[](video url)", 27),
|
||||
VIDEO("[video](url)", 7),
|
||||
ORDERED_LIST("1. ", 3),
|
||||
UNORDERED_LIST("- ", 2),
|
||||
HEADING("# ", 2),
|
||||
CENTERED("-> <-", 3),
|
||||
QUOTE("> ", 2),
|
||||
CODE("`", 1);
|
||||
}
|
||||
|
||||
@OptIn(DelicateCoroutinesApi::class)
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
@@ -36,11 +55,15 @@ class MarkdownCreatorActivity : AppCompatActivity() {
|
||||
binding.markdownCreatorToolbar.updateLayoutParams<ViewGroup.MarginLayoutParams> {
|
||||
topMargin = statusBarHeight
|
||||
}
|
||||
binding.buttonContainer.updateLayoutParams<ViewGroup.MarginLayoutParams> {
|
||||
binding.markdownOptionsContainer.updateLayoutParams<ViewGroup.MarginLayoutParams> {
|
||||
bottomMargin += navBarHeight
|
||||
}
|
||||
setContentView(binding.root)
|
||||
|
||||
val params = binding.createButton.layoutParams as ViewGroup.MarginLayoutParams
|
||||
params.marginEnd = 16 * resources.displayMetrics.density.toInt()
|
||||
binding.createButton.layoutParams = params
|
||||
|
||||
if (intent.hasExtra("type")) {
|
||||
type = intent.getStringExtra("type")!!
|
||||
} else {
|
||||
@@ -67,17 +90,12 @@ class MarkdownCreatorActivity : AppCompatActivity() {
|
||||
text = ping ?: ""
|
||||
binding.editText.setText(text)
|
||||
binding.editText.addTextChangedListener {
|
||||
if (!binding.markdownCreatorPreviewCheckbox.isChecked) {
|
||||
if (!isPreviewMode) {
|
||||
text = it.toString()
|
||||
}
|
||||
}
|
||||
previewMarkdown(false)
|
||||
binding.markdownCreatorPreviewCheckbox.setOnClickListener {
|
||||
previewMarkdown(binding.markdownCreatorPreviewCheckbox.isChecked)
|
||||
}
|
||||
binding.cancelButton.setOnClickListener {
|
||||
onBackPressedDispatcher.onBackPressed()
|
||||
}
|
||||
|
||||
binding.markdownCreatorBack.setOnClickListener {
|
||||
onBackPressedDispatcher.onBackPressed()
|
||||
}
|
||||
@@ -87,10 +105,10 @@ class MarkdownCreatorActivity : AppCompatActivity() {
|
||||
toast(getString(R.string.cannot_be_empty))
|
||||
return@setOnClickListener
|
||||
}
|
||||
AlertDialogBuilder(this).apply {
|
||||
AlertDialog.Builder(this).apply {
|
||||
setTitle(R.string.warning)
|
||||
setMessage(R.string.post_to_anilist_warning)
|
||||
setPosButton(R.string.ok) {
|
||||
setPositiveButton(R.string.ok) { _, _ ->
|
||||
launchIO {
|
||||
val editId = intent.getIntExtra("edit", -1)
|
||||
val isEdit = editId != -1
|
||||
@@ -113,14 +131,45 @@ class MarkdownCreatorActivity : AppCompatActivity() {
|
||||
finish()
|
||||
}
|
||||
}
|
||||
setNeutralButton(R.string.open_rules) {
|
||||
setNeutralButton(R.string.open_rules) { _, _ ->
|
||||
openLinkInBrowser("https://anilist.co/forum/thread/14")
|
||||
}
|
||||
setNegButton(R.string.cancel)
|
||||
setNegativeButton(R.string.cancel, null)
|
||||
}.show()
|
||||
}
|
||||
|
||||
binding.createButton.setOnLongClickListener {
|
||||
isPreviewMode = !isPreviewMode
|
||||
previewMarkdown(isPreviewMode)
|
||||
if (isPreviewMode) {
|
||||
toast("Preview enabled")
|
||||
} else {
|
||||
toast("Preview disabled")
|
||||
}
|
||||
true
|
||||
}
|
||||
binding.editText.requestFocus()
|
||||
setupMarkdownButtons()
|
||||
}
|
||||
|
||||
private fun setupMarkdownButtons() {
|
||||
binding.formatBold.setOnClickListener { applyMarkdownFormat(MarkdownFormat.BOLD) }
|
||||
binding.formatItalic.setOnClickListener { applyMarkdownFormat(MarkdownFormat.ITALIC) }
|
||||
binding.formatStrikethrough.setOnClickListener { applyMarkdownFormat(MarkdownFormat.STRIKETHROUGH) }
|
||||
}
|
||||
|
||||
private fun applyMarkdownFormat(format: MarkdownFormat) {
|
||||
val start = binding.editText.selectionStart
|
||||
val end = binding.editText.selectionEnd
|
||||
|
||||
if (start == end) {
|
||||
binding.editText.text?.insert(start, format.syntax)
|
||||
binding.editText.setSelection(start + format.selectionOffset)
|
||||
} else {
|
||||
binding.editText.text?.insert(end, format.syntax)
|
||||
binding.editText.text?.insert(start, format.syntax)
|
||||
binding.editText.setSelection(end + format.syntax.length, end + format.syntax.length)
|
||||
}
|
||||
}
|
||||
|
||||
private fun previewMarkdown(preview: Boolean) {
|
||||
|
||||
10
app/src/main/res/drawable/format_align_center_24.xml
Normal file
10
app/src/main/res/drawable/format_align_center_24.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="960"
|
||||
android:viewportHeight="960">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M120,840L120,760L840,760L840,840L120,840ZM280,680L280,600L680,600L680,680L280,680ZM120,520L120,440L840,440L840,520L120,520ZM280,360L280,280L680,280L680,360L280,360ZM120,200L120,120L840,120L840,200L120,200Z" />
|
||||
</vector>
|
||||
10
app/src/main/res/drawable/format_bold_24.xml
Normal file
10
app/src/main/res/drawable/format_bold_24.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="960"
|
||||
android:viewportHeight="960">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M272,760L272,200L493,200Q558,200 613,240Q668,280 668,351Q668,402 645,429.5Q622,457 602,469L602,469Q627,480 657.5,510Q688,540 688,600Q688,689 623,724.5Q558,760 501,760L272,760ZM393,648L497,648Q545,648 555.5,623.5Q566,599 566,588Q566,577 555.5,552.5Q545,528 494,528L393,528L393,648ZM393,420L486,420Q519,420 534,403Q549,386 549,365Q549,341 532,326Q515,311 488,311L393,311L393,420Z" />
|
||||
</vector>
|
||||
10
app/src/main/res/drawable/format_italic_24.xml
Normal file
10
app/src/main/res/drawable/format_italic_24.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="960"
|
||||
android:viewportHeight="960">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M200,760L200,660L360,660L480,300L320,300L320,200L720,200L720,300L580,300L460,660L600,660L600,760L200,760Z" />
|
||||
</vector>
|
||||
11
app/src/main/res/drawable/format_list_bulleted_24.xml
Normal file
11
app/src/main/res/drawable/format_list_bulleted_24.xml
Normal file
@@ -0,0 +1,11 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:autoMirrored="true"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="960"
|
||||
android:viewportHeight="960">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M400,760Q383,760 371.5,748.5Q360,737 360,720Q360,703 371.5,691.5Q383,680 400,680L800,680Q817,680 828.5,691.5Q840,703 840,720Q840,737 828.5,748.5Q817,760 800,760L400,760ZM400,520Q383,520 371.5,508.5Q360,497 360,480Q360,463 371.5,451.5Q383,440 400,440L800,440Q817,440 828.5,451.5Q840,463 840,480Q840,497 828.5,508.5Q817,520 800,520L400,520ZM400,280Q383,280 371.5,268.5Q360,257 360,240Q360,223 371.5,211.5Q383,200 400,200L800,200Q817,200 828.5,211.5Q840,223 840,240Q840,257 828.5,268.5Q817,280 800,280L400,280ZM200,800Q167,800 143.5,776.5Q120,753 120,720Q120,687 143.5,663.5Q167,640 200,640Q233,640 256.5,663.5Q280,687 280,720Q280,753 256.5,776.5Q233,800 200,800ZM200,560Q167,560 143.5,536.5Q120,513 120,480Q120,447 143.5,423.5Q167,400 200,400Q233,400 256.5,423.5Q280,447 280,480Q280,513 256.5,536.5Q233,560 200,560ZM200,320Q167,320 143.5,296.5Q120,273 120,240Q120,207 143.5,183.5Q167,160 200,160Q233,160 256.5,183.5Q280,207 280,240Q280,273 256.5,296.5Q233,320 200,320Z" />
|
||||
</vector>
|
||||
10
app/src/main/res/drawable/format_list_numbered_24.xml
Normal file
10
app/src/main/res/drawable/format_list_numbered_24.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="960"
|
||||
android:viewportHeight="960">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M120,880L120,820L220,820L220,790L160,790L160,730L220,730L220,700L120,700L120,640L240,640Q257,640 268.5,651.5Q280,663 280,680L280,720Q280,737 268.5,748.5Q257,760 240,760Q257,760 268.5,771.5Q280,783 280,800L280,840Q280,857 268.5,868.5Q257,880 240,880L120,880ZM120,600L120,490Q120,473 131.5,461.5Q143,450 160,450L220,450L220,420L120,420L120,360L240,360Q257,360 268.5,371.5Q280,383 280,400L280,470Q280,487 268.5,498.5Q257,510 240,510L180,510L180,540L280,540L280,600L120,600ZM180,320L180,140L120,140L120,80L240,80L240,320L180,320ZM360,760L360,680L840,680L840,760L360,760ZM360,520L360,440L840,440L840,520L360,520ZM360,280L360,200L840,200L840,280L360,280Z" />
|
||||
</vector>
|
||||
10
app/src/main/res/drawable/format_quote_24.xml
Normal file
10
app/src/main/res/drawable/format_quote_24.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="960"
|
||||
android:viewportHeight="960">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M228,720L320,560Q320,560 320,560Q320,560 320,560Q254,560 207,513Q160,466 160,400Q160,334 207,287Q254,240 320,240Q386,240 433,287Q480,334 480,400Q480,423 474.5,442.5Q469,462 458,480L320,720L228,720ZM588,720L680,560Q680,560 680,560Q680,560 680,560Q614,560 567,513Q520,466 520,400Q520,334 567,287Q614,240 680,240Q746,240 793,287Q840,334 840,400Q840,423 834.5,442.5Q829,462 818,480L680,720L588,720ZM320,460Q345,460 362.5,442.5Q380,425 380,400Q380,375 362.5,357.5Q345,340 320,340Q295,340 277.5,357.5Q260,375 260,400Q260,425 277.5,442.5Q295,460 320,460ZM680,460Q705,460 722.5,442.5Q740,425 740,400Q740,375 722.5,357.5Q705,340 680,340Q655,340 637.5,357.5Q620,375 620,400Q620,425 637.5,442.5Q655,460 680,460ZM680,400Q680,400 680,400Q680,400 680,400Q680,400 680,400Q680,400 680,400Q680,400 680,400Q680,400 680,400Q680,400 680,400Q680,400 680,400ZM320,400Q320,400 320,400Q320,400 320,400Q320,400 320,400Q320,400 320,400Q320,400 320,400Q320,400 320,400Q320,400 320,400Q320,400 320,400Z" />
|
||||
</vector>
|
||||
10
app/src/main/res/drawable/format_strikethrough_24.xml
Normal file
10
app/src/main/res/drawable/format_strikethrough_24.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="960"
|
||||
android:viewportHeight="960">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M80,560L80,480L880,480L880,560L80,560ZM420,400L420,280L200,280L200,160L760,160L760,280L540,280L540,400L420,400ZM420,800L420,640L540,640L540,800L420,800Z" />
|
||||
</vector>
|
||||
@@ -1,107 +1,133 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/markdownCreatorToolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="48dp"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/markdownCreatorBack"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="start|center_vertical"
|
||||
android:layout_marginStart="12dp"
|
||||
android:src="@drawable/ic_round_arrow_back_ios_new_24"
|
||||
app:tint="?attr/colorOnBackground"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/markdownCreatorTitle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="48dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="44dp"
|
||||
android:ellipsize="end"
|
||||
android:fontFamily="@font/poppins_bold"
|
||||
android:gravity="center|start"
|
||||
android:singleLine="true"
|
||||
android:textAppearance="@style/TextAppearance.Widget.AppCompat.Toolbar.Title"
|
||||
android:textColor="?attr/colorOnBackground"
|
||||
android:textSize="18sp"
|
||||
tools:text="@string/placeholder" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/markdownCreatorPreviewCheckbox"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="end|center_vertical"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:contentDescription="@string/preview"
|
||||
android:text="@string/preview"
|
||||
tools:ignore="ContentDescription" />
|
||||
</FrameLayout>
|
||||
|
||||
<EditText
|
||||
android:id="@+id/editText"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:layout_margin="16dp"
|
||||
android:fontFamily="@font/poppins"
|
||||
android:inputType="textMultiLine"
|
||||
android:padding="16dp"
|
||||
android:nestedScrollingEnabled="true"
|
||||
android:gravity="top|start"
|
||||
android:textColor="?attr/colorOnBackground"
|
||||
android:textIsSelectable="true"
|
||||
android:textSize="12sp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/markdownCreatorToolbar"
|
||||
tools:ignore="LabelFor" />
|
||||
android:fitsSystemWindows="false">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/buttonContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|center_horizontal"
|
||||
android:layout_marginBottom="24dp"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
||||
|
||||
<Button
|
||||
android:id="@+id/cancelButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="64dp"
|
||||
android:layout_marginEnd="16dp"
|
||||
android:fontFamily="@font/poppins_bold"
|
||||
android:maxLines="1"
|
||||
android:text="@string/cancel"
|
||||
app:cornerRadius="16dp"
|
||||
tools:ignore="ButtonStyle" />
|
||||
<FrameLayout
|
||||
android:id="@+id/markdownCreatorToolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="48dp"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<Button
|
||||
android:id="@+id/createButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="64dp"
|
||||
android:layout_marginStart="16dp"
|
||||
android:fontFamily="@font/poppins_bold"
|
||||
android:maxLines="1"
|
||||
android:text="@string/create"
|
||||
app:cornerRadius="16dp"
|
||||
tools:ignore="ButtonStyle" />
|
||||
<ImageView
|
||||
android:id="@+id/markdownCreatorBack"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="start|center_vertical"
|
||||
android:layout_marginStart="12dp"
|
||||
android:src="@drawable/ic_round_arrow_back_ios_new_24"
|
||||
app:tint="?attr/colorOnBackground"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/markdownCreatorTitle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="48dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="44dp"
|
||||
android:ellipsize="end"
|
||||
android:fontFamily="@font/poppins_bold"
|
||||
android:gravity="center|start"
|
||||
android:singleLine="true"
|
||||
android:textAppearance="@style/TextAppearance.Widget.AppCompat.Toolbar.Title"
|
||||
android:textColor="?attr/colorOnBackground"
|
||||
android:textSize="18sp"
|
||||
tools:text="@string/placeholder" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/createButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="end|center_vertical"
|
||||
android:fontFamily="@font/poppins_bold"
|
||||
android:maxLines="1"
|
||||
android:text="@string/publish"
|
||||
app:cornerRadius="16dp"
|
||||
tools:ignore="ButtonStyle" />
|
||||
</FrameLayout>
|
||||
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:fillViewport="true">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/editText"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:fontFamily="@font/poppins"
|
||||
android:inputType="textMultiLine"
|
||||
android:padding="16dp"
|
||||
android:nestedScrollingEnabled="true"
|
||||
android:gravity="top|start"
|
||||
android:textColor="?attr/colorOnBackground"
|
||||
android:textIsSelectable="true"
|
||||
android:textSize="12sp"
|
||||
android:hint="@string/reply_hint"
|
||||
tools:ignore="LabelFor" />
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center|bottom"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/markdownOptionsContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|end"
|
||||
android:background="@color/nav_bg"
|
||||
android:orientation="horizontal"
|
||||
android:padding="8dp"
|
||||
android:windowSoftInputMode="adjustResize">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/formatBold"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/format_bold_24"
|
||||
app:tint="?attr/colorOnBackground"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/formatItalic"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/format_italic_24"
|
||||
app:tint="?attr/colorOnBackground"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/formatStrikethrough"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/format_strikethrough_24"
|
||||
app:tint="?attr/colorOnBackground"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||
@@ -58,6 +58,18 @@
|
||||
tools:ignore="HardcodedText" />
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/addStory"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleX="2.2"
|
||||
android:scaleY="2.2"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"
|
||||
android:src="@drawable/ic_circle_add"
|
||||
app:layout_goneMarginBottom="40dp"
|
||||
app:layout_goneMarginRight="8dp"
|
||||
app:layout_constraintBottom_toBottomOf="@id/textActivityContainer"
|
||||
app:layout_constraintEnd_toEndOf="@id/textActivityContainer" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
|
||||
@@ -366,6 +366,8 @@
|
||||
<string name="apply">Apply</string>
|
||||
<string name="cancel">Cancel</string>
|
||||
<string name="edit">Edit</string>
|
||||
<string name="publish">Publish</string>
|
||||
<string name="reply_hint">Write a response…</string>
|
||||
<string name="this_season">This Season</string>
|
||||
<string name="next_season">Next Season</string>
|
||||
<string name="previous_season">Previous Season</string>
|
||||
|
||||
Reference in New Issue
Block a user