Skip to content
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.

Trace location icon custom view (DEV) #2597

Merged

Conversation

AlexanderAlferov
Copy link
Contributor

@AlexanderAlferov AlexanderAlferov commented Mar 12, 2021

Trace location custom view for icon with date:

Screenshot from 2021-03-12 20-01-46Screenshot from 2021-03-12 20-07-55

@AlexanderAlferov AlexanderAlferov added the maintainers Tag pull requests created by maintainers label Mar 12, 2021
@AlexanderAlferov AlexanderAlferov added this to the 2.0.0 milestone Mar 12, 2021
@harambasicluka harambasicluka changed the title (DEV) Trace location icon custom view Trace location icon custom view (DEV) Mar 12, 2021
Comment on lines +10 to +30
<de.rki.coronawarnapp.ui.eventregistration.common.TraceLocationCardHighlightView
android:id="@+id/icon"
android:layout_width="88dp"
android:layout_height="136dp"
android:layout_margin="16dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:text="21.01.2021">

<ImageView
android:layout_width="42dp"
android:layout_height="42dp"
android:importantForAccessibility="no"
android:src="@drawable/ic_qr_code_list_item_icon"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />

</de.rki.coronawarnapp.ui.eventregistration.common.TraceLocationCardHighlightView>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Usage

Set text as caption by using android:text on TraceLocationCardHighlightView, and any qr codes or other text views that should be displayed on top of the gradient, can be added as child of TraceLocationCardHighlightView.

The container with the gradient as background has a fixed size, while the caption text has a fixed width, but will grow in height to wrap it's content (i.e. line breaks possible).

@d4rken d4rken marked this pull request as ready for review March 12, 2021 19:11
@d4rken d4rken requested a review from a team March 12, 2021 19:11
@sonarcloud
Copy link

sonarcloud bot commented Mar 12, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

@ralfgehrer ralfgehrer self-assigned this Mar 15, 2021
@d4rken d4rken self-assigned this Mar 15, 2021
@AlexanderAlferov AlexanderAlferov merged commit 46bccad into release/2.0.x Mar 15, 2021
@AlexanderAlferov AlexanderAlferov deleted the feature/DEV-trace-location-icon-custom-view branch March 15, 2021 10:21
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
maintainers Tag pull requests created by maintainers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants