chromium/chrome/browser/safety_hub/android/java/res/layout/safety_hub_expandable_preference.xml

<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2024 The Chromium Authors
Use of this source code is governed by a BSD-style license that can be
found in the LICENSE file.
-->

<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:paddingVertical="12dp"
    android:paddingEnd="?android:attr/listPreferredItemPaddingEnd"
    android:paddingStart="?android:attr/listPreferredItemPaddingStart"
    android:orientation="vertical">

    <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content">

        <FrameLayout
            android:id="@+id/icon_frame"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignParentStart="true"
            android:layout_centerVertical="true">

            <org.chromium.ui.widget.ChromeImageView
                android:id="@android:id/icon"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                app:maxHeight="24dp"
                app:maxWidth="24dp" />
        </FrameLayout>

        <RelativeLayout
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginStart="16dp"
            android:layout_marginEnd="16dp"
            android:layout_toEndOf="@id/icon_frame"
            android:layout_toStartOf="@id/checkable_image_view"
            android:layout_centerVertical="true">

            <TextView
                android:id="@android:id/title"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:ellipsize="marquee"
                android:fadingEdge="horizontal"
                android:scrollbars="none"
                style="@style/PreferenceTitle"/>

            <TextView
                android:id="@android:id/summary"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_below="@android:id/title"
                android:layout_marginTop="4dp"
                android:layout_alignStart="@android:id/title"
                android:scrollbars="none"
                android:focusable="true"
                style="@style/PreferenceSummary" />
        </RelativeLayout>

        <org.chromium.ui.widget.CheckableImageView
            android:id="@+id/checkable_image_view"
            android:layout_width="32dp"
            android:layout_height="32dp"
            android:scaleType="center"
            android:layout_alignParentEnd="true"
            android:layout_centerVertical="true"/>
    </RelativeLayout>

    <RelativeLayout
        android:id="@+id/buttons_container"
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:layout_marginTop="16dp"
        android:gravity="end"
        android:layout_weight="1">
            <org.chromium.ui.widget.ButtonCompat
                android:id="@+id/secondary_button"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:ellipsize="end"
                android:singleLine="true"
                android:visibility="gone"
                style="@style/TextButton"/>
            <org.chromium.ui.widget.ButtonCompat
                android:id="@+id/primary_button"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:ellipsize="end"
                android:singleLine="true"
                android:layout_marginStart="30dp"
                android:layout_toEndOf="@id/secondary_button"
                android:visibility="gone"
                style="@style/FilledButton"/>
    </RelativeLayout>
</LinearLayout>