Skip to content

Veil Layout attr in XML no longer works #43

@thiago-youx

Description

@thiago-youx

Please complete the following information:

  • Library Version v1.1.4
  • Affected Device(s) n/a

Describe the Bug:
The veil layout used directly in XML no longer works (even on XML preview): app:veilLayout_layout="@layout/skeleton_veil_layout"

Complete XML component:

<com.skydoves.androidveil.VeilLayout
        android:id="@+id/veil_loading"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        app:veilLayout_baseAlpha="0.8"
        app:veilLayout_baseColor="@color/colorGraySkeleton"
        app:veilLayout_highlightAlpha="1.0"
        app:veilLayout_isPrepared="true"
        app:veilLayout_highlightColor="@color/colorGraySkeleton"
        app:veilLayout_layout="@layout/skeleton_veil_layout"
        app:veilLayout_radius="@dimen/space4dp"
        app:veilLayout_shimmerEnable="true"
        app:veilLayout_veiled="true" />

Now it requires to call setLayout before starting veil:

veilLoading.setLayout(R.layout.skeleton_veil_layout)
veilLoading.veil()

Changing the new feature "veilLayout_isPrepared" value on XML does not resolve this issue.

Expected Behavior:
XML display the veil layout on preview and also use it on execution without new method calls.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions