activity_login.xml 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3. xmlns:tools="http://schemas.android.com/tools"
  4. android:layout_width="match_parent"
  5. android:layout_height="match_parent"
  6. android:gravity="center_horizontal"
  7. android:orientation="vertical"
  8. android:paddingBottom="@dimen/activity_vertical_margin"
  9. android:paddingLeft="@dimen/activity_horizontal_margin"
  10. android:paddingRight="@dimen/activity_horizontal_margin"
  11. android:paddingTop="@dimen/activity_vertical_margin"
  12. tools:context=".LoginActivity">
  13. <!-- Login progress -->
  14. <ProgressBar
  15. style="?android:attr/progressBarStyleLarge"
  16. android:layout_width="wrap_content"
  17. android:layout_height="wrap_content"
  18. android:layout_marginBottom="8dp"
  19. android:visibility="gone" />
  20. <ScrollView
  21. android:layout_width="match_parent"
  22. android:layout_height="match_parent">
  23. <LinearLayout
  24. android:layout_width="match_parent"
  25. android:layout_height="wrap_content"
  26. android:orientation="vertical">
  27. <TextView
  28. android:id="@+id/LoginSettingsLabel"
  29. android:layout_width="match_parent"
  30. android:layout_height="wrap_content"
  31. android:text="@string/login_settings_header" />
  32. <com.google.android.material.textfield.TextInputLayout
  33. android:layout_width="match_parent"
  34. android:layout_height="wrap_content">
  35. <EditText
  36. android:id="@+id/triliumAddressEditText"
  37. android:layout_width="match_parent"
  38. android:layout_height="wrap_content"
  39. android:hint="@string/prompt_trilium_address"
  40. android:inputType="textUri"
  41. android:maxLines="1"
  42. android:importantForAutofill="no"
  43. android:singleLine="true" />
  44. </com.google.android.material.textfield.TextInputLayout>
  45. <com.google.android.material.textfield.TextInputLayout
  46. android:layout_width="match_parent"
  47. android:layout_height="wrap_content">
  48. <EditText
  49. android:id="@+id/usernameEditText"
  50. android:layout_width="match_parent"
  51. android:layout_height="wrap_content"
  52. android:hint="@string/prompt_username"
  53. android:inputType="text"
  54. android:maxLines="1"
  55. android:autofillHints="username"
  56. android:singleLine="true" />
  57. </com.google.android.material.textfield.TextInputLayout>
  58. <com.google.android.material.textfield.TextInputLayout
  59. android:layout_width="match_parent"
  60. android:layout_height="wrap_content">
  61. <EditText
  62. android:id="@+id/passwordEditText"
  63. android:layout_width="match_parent"
  64. android:layout_height="wrap_content"
  65. android:hint="@string/prompt_password"
  66. android:imeActionId="6"
  67. android:imeActionLabel="@string/action_login_short"
  68. android:imeOptions="actionUnspecified"
  69. android:inputType="textPassword"
  70. android:maxLines="1"
  71. android:autofillHints="password"
  72. android:singleLine="true" />
  73. </com.google.android.material.textfield.TextInputLayout>
  74. <Button
  75. android:id="@+id/loginButton"
  76. style="?android:textAppearanceSmall"
  77. android:layout_width="match_parent"
  78. android:layout_height="wrap_content"
  79. android:layout_marginTop="16dp"
  80. android:text="@string/action_login"
  81. android:textStyle="bold" />
  82. <TextView
  83. android:id="@+id/loggedInIndicator"
  84. android:layout_width="match_parent"
  85. android:layout_height="wrap_content"
  86. android:text="@string/logged_in_successfully" />
  87. <TextView
  88. android:id="@+id/NoteSettingsLabel"
  89. android:layout_width="match_parent"
  90. android:layout_height="wrap_content"
  91. android:layout_marginTop="16dp"
  92. android:text="@string/note_settings_header" />
  93. <com.google.android.material.textfield.TextInputLayout
  94. android:layout_width="match_parent"
  95. android:layout_height="wrap_content">
  96. <EditText
  97. android:id="@+id/labelEditText"
  98. android:layout_width="match_parent"
  99. android:layout_height="wrap_content"
  100. android:hint="@string/prompt_label"
  101. android:importantForAutofill="no"
  102. android:inputType="text"
  103. android:maxLines="1"
  104. android:singleLine="true" />
  105. </com.google.android.material.textfield.TextInputLayout>
  106. </LinearLayout>
  107. </ScrollView>
  108. </LinearLayout>