Skip to content

Commit

Permalink
[EKA-000] Fix defect : snackbar text not visible completely in specif…
Browse files Browse the repository at this point in the history
…ic resolutions
  • Loading branch information
AnusreeSajeevan committed May 14, 2020
1 parent 211c25c commit 0d9261c
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import android.text.style.ForegroundColorSpan
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.TextView
import androidx.lifecycle.Observer
import com.google.android.material.snackbar.Snackbar
import kotlinx.android.synthetic.main.reset_password_otp_verification.*
Expand Down Expand Up @@ -107,6 +108,10 @@ class ResetPasswordOtpFragment : BaseFragment() {

spannableString.setSpan(ForegroundColorSpan(Color.WHITE), 0, message.length, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE)
snackbar = Snackbar.make(snackbar_container, spannableString, Snackbar.LENGTH_LONG)

val layout = snackbar.view
val textView = layout.findViewById(com.google.android.material.R.id.snackbar_text) as TextView
textView.maxLines = 10
if (!snackbar.isShown) snackbar.show()
}

Expand Down

0 comments on commit 0d9261c

Please sign in to comment.