Skip to content

Commit

Permalink
fix: fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
phodal committed Nov 10, 2023
1 parent eae0f5b commit 9c1ca4e
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 11 deletions.
21 changes: 10 additions & 11 deletions app/src/main/res/layout/fragment_home.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Sentence Similarity"
android:text="@string/sentence_similarity"
android:textSize="14sp"
android:textColor="@color/colorGray"
android:layout_marginBottom="8dp"/>
Expand All @@ -24,25 +24,24 @@
android:id="@+id/defaultSource"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Source Sentence"
android:inputType="text"/>
android:hint="@string/source_sentence"
android:inputType="text"
android:autofillHints=""/>

<!-- 子标题 -->
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Sentences to compare to"
android:text="@string/sentences_to_compare_to"
android:textSize="14sp"
android:textColor="@color/colorGray"
android:layout_marginBottom="8dp"/>

<!-- 输入表单 -->
<LinearLayout
android:id="@+id/textContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<!-- 此处将用于容纳新的 TextView -->
</LinearLayout>

<LinearLayout
Expand All @@ -55,16 +54,16 @@
android:id="@+id/addButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Add Sentence"
android:onClick="add"
android:layout_marginEnd="8dp"/> <!-- 添加一个间距 -->
android:text="@string/add_sentence"
android:layout_marginEnd="8dp"
style="?android:attr/buttonBarButtonStyle"/>

<Button
android:id="@+id/computeButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Compute"
android:onClick="compute"/>
android:text="@string/compute"
style="?android:attr/buttonBarButtonStyle"/>

</LinearLayout>

Expand Down
5 changes: 5 additions & 0 deletions app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,9 @@
<string name="title_home">Home</string>
<string name="title_dashboard">Dashboard</string>
<string name="title_notifications">Notifications</string>
<string name="add_sentence">Add Sentence</string>
<string name="compute">Compute</string>
<string name="sentences_to_compare_to">Sentences to compare to</string>
<string name="source_sentence">Source Sentence</string>
<string name="sentence_similarity">Sentence Similarity</string>
</resources>

0 comments on commit 9c1ca4e

Please sign in to comment.