-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
feat: WidgetSmall redesign with material you dynamic color #17654
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 3 commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
78c00c6
feat: WidgetSmall with modern design and material you dynamic color
Rdkang 34b258f
feat: different timer text
Rdkang 82ed620
refactor: better icon
Rdkang 042ddd4
refactor: remove unneeded code in test
Rdkang 1ee1f2b
refactor: remove commented out code
Rdkang 0640f20
Merge branch 'main' into widget_modern
Rdkang b24b9b5
style: apply automatic code formatting
Rdkang 360f262
feat: finish state now a darker shade of primary color
Rdkang 986b60b
fix: show eta icon
Rdkang File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <shape xmlns:android="http://schemas.android.com/apk/res/android" | ||
| android:shape="oval"> | ||
| <solid android:color="@android:color/system_accent1_600" /> | ||
| </shape> | ||
|
|
||
| <!--<padding android:left="7dp"--> | ||
Rdkang marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| <!--android:top="7dp"--> | ||
| <!--android:right="7dp"--> | ||
| <!--android:bottom="7dp" />--> | ||
|
|
||
|
|
||
|
|
||
| <!--<stroke android:color="@android:color/system_accent1_1000" android:width="1dp"/>--> | ||
|
|
||
| <!--<gradient--> | ||
| <!--android:angle="315"--> | ||
| <!--android:endColor="@android:color/system_neutral1_900"--> | ||
| <!--android:startColor="@android:color/system_neutral1_600" />--> | ||
115 changes: 115 additions & 0 deletions
115
AnkiDroid/src/main/res/drawable-v31/ic_anki_dynamic.xml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,115 @@ | ||
| <vector xmlns:android="http://schemas.android.com/apk/res/android" | ||
| xmlns:aapt="http://schemas.android.com/aapt" | ||
| android:width="192dp" | ||
| android:height="192dp" | ||
| android:viewportWidth="192" | ||
| android:viewportHeight="192"> | ||
| <path | ||
| android:pathData="M142,161c0,6.6 -5.4,12 -12,12H34.3c-6.6,0 -12,-5.4 -12,-12V24c0,-6.6 5.4,-12 12,-12H130c6.6,0 12,5.4 12,12V161z" | ||
| android:fillColor="@android:color/system_neutral1_800"/> | ||
| <path | ||
| android:pathData="M127.7,14.6H36.5C22,14.6 22.3,24 22.3,24c0,-6.6 5.4,-12 12,-12H130c6.6,0 12,5.4 12,12C142,24 141.7,14.6 127.7,14.6z" | ||
| android:fillColor="@android:color/system_neutral1_100" | ||
| android:fillAlpha="0.1"/> | ||
| <path | ||
| android:pathData="M36.5,167h91.2c14.5,0 14.3,-6 14.3,-6c0,6.6 -5.4,12 -12,12H34.2c-6.6,0 -12,-5.4 -12,-12C22.2,161 22.5,167 36.5,167z" | ||
| android:fillColor="@android:color/system_neutral1_1000" | ||
| android:fillAlpha="0.3" /> | ||
|
|
||
| <path | ||
| android:pathData="M35.8,104.2h40v6h-40z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,126.9h20v6h-20z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
|
|
||
| <path | ||
| android:pathData="M35.3,148.4h42v6h-42z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,104.2h40v6h-40z" | ||
| android:fillColor="@android:color/system_neutral1_900" /> | ||
|
|
||
| <path | ||
| android:pathData="M35.8,126.9h20v6h-20z" | ||
| android:fillColor="@android:color/system_neutral1_900" /> | ||
| <path | ||
| android:pathData="M35.3,148.4h42v6h-42z" | ||
| android:fillColor="@android:color/system_neutral1_900" /> | ||
| <path | ||
| android:pathData="M35.8,27.9h69.5v6h-69.5z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,48.7h22.4v6h-22.4z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M36.3,70.2h36.8v6h-36.8z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M65.9,48.7h22.4v6h-22.4z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,27.9h69.5v6h-69.5z" | ||
| android:strokeAlpha="0.2" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,48.7h22.4v6h-22.4z" | ||
| android:strokeAlpha="0.2" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M36.3,70.2h36.8v6h-36.8z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M65.9,48.7h22.4v6h-22.4z" | ||
| android:strokeAlpha="0.2" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M106.2,59.6c-1,0 -2.1,0.1 -3.1,0.4c-4.2,1.4 -6.3,5.4 -7.3,9.1s-1.2,7.8 -1.3,11.9c-0.1,4.1 -0.2,8.3 -0.5,11.7c-0.3,3.4 -1.2,5.9 -1.7,6.6s-2.7,2.3 -5.8,3.6c-3.1,1.4 -7,2.7 -10.9,4.1s-7.7,2.9 -11,4.9c-3.2,2 -6.4,5.2 -6.4,9.7s3.1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-4.6,12c0,4 1.8,7.3 3.8,10.7s4.5,6.9 6.7,10.2s4.1,6.4 5.1,8.8c0.9,2.3 0.7,3.1 0.5,3.4c-0.2,0.3 -0.9,0.7 -3.4,0.6c-2.5,-0.2 -6.1,-1 -9.9,-2.1c-3.8,-1.1 -7.9,-2.4 -11.7,-3.3c-3.9,-0.9 -7.6,-1.5 -11.4,-0.3c-3.8,1.2 -6.4,3.9 -9,6.9s-5.2,6.4 -7.6,9.5s-4.9,5.9 -6.8,7.5s-2.7,1.7 -3.1,1.5c-0.4,-0.1 -1,-0.6 -1.6,-3.1s-0.9,-6.1 -1,-10.1s-0.2,-8.2 -0.5,-12.2c-0.4,-4 -0.9,-7.7 -3.2,-10.9c-2.3,-3.2 -5.7,-4.9 -9.3,-6.5s-7.7,-2.9 -11.4,-4.3c-3.7,-1.4 -7.1,-2.8 -9.3,-4.1c-2.1,-1.4 -2.4,-2.1 -2.4,-2.5s0.3,-1.1 2.4,-2.4c2.2,-1.4 5.7,-2.9 9.3,-4.1c3.7,-1.4 7.8,-2.7 11.4,-4.3c3.6,-1.6 7,-3.2 9.3,-6.4c2.3,-3.2 2.9,-7 3.3,-10.9s0.4,-8.2 0.6,-12.2c0.1,-4 0.4,-7.6 1.1,-10.1C104.7,68.8 105.3,68.3 105.7,68.2L105.7,68.2z"> | ||
| <aapt:attr name="android:fillColor"> | ||
| <gradient | ||
| android:startY="98.7147" | ||
| android:startX="79.9001" | ||
| android:endY="151.12" | ||
| android:endX="170.6686" | ||
| android:type="linear"> | ||
| <item android:offset="0" android:color="@android:color/system_accent1_300"/> | ||
| <item android:offset="1" android:color="@android:color/system_accent1_500"/> | ||
| </gradient> | ||
| </aapt:attr> | ||
| </path> | ||
| <path | ||
| android:pathData="M142.3,160.5c0,6.6 -5.4,12 -12,12H34.6c-6.6,0 -12,-5.4 -12,-12v-137c0,-6.6 5.4,-12 12,-12h95.7c6.6,0 12,5.4 12,12L142.3,160.5L142.3,160.5z" | ||
| android:strokeAlpha="0.1" | ||
| android:fillAlpha="0.1"> | ||
| <aapt:attr name="android:fillColor"> | ||
| <gradient | ||
| android:startY="25.35" | ||
| android:startX="15.8" | ||
| android:endY="158.65" | ||
| android:endX="149.1" | ||
| android:type="linear"> | ||
| <item android:offset="0" android:color="#FFFFFFFF"/> | ||
| <item android:offset="1" android:color="#00000000"/> | ||
| </gradient> | ||
| </aapt:attr> | ||
| </path> | ||
| <path | ||
| android:pathData="M142.3,160.5c0,6.6 -5.4,12 -12,12H34.6c-6.6,0 -12,-5.4 -12,-12v-137c0,-6.6 5.4,-12 12,-12h95.7c6.6,0 12,5.4 12,12L142.3,160.5L142.3,160.5z" | ||
| android:strokeAlpha="0.1" | ||
| android:fillAlpha="0.1"> | ||
| <aapt:attr name="android:fillColor"> | ||
| <gradient | ||
| android:startY="92" | ||
| android:startX="22.6" | ||
| android:endY="92" | ||
| android:endX="142.3" | ||
| android:type="linear"> | ||
| <item android:offset="0" android:color="#FFFFFFFF"/> | ||
| <item android:offset="1" android:color="#00000000"/> | ||
| </gradient> | ||
| </aapt:attr> | ||
| </path> | ||
| </vector> |
115 changes: 115 additions & 0 deletions
115
AnkiDroid/src/main/res/drawable-v31/ic_anki_dynamic_finish.xml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,115 @@ | ||
| <vector xmlns:android="http://schemas.android.com/apk/res/android" | ||
| xmlns:aapt="http://schemas.android.com/aapt" | ||
| android:width="192dp" | ||
| android:height="192dp" | ||
| android:viewportWidth="192" | ||
| android:viewportHeight="192"> | ||
| <path | ||
| android:pathData="M142,161c0,6.6 -5.4,12 -12,12H34.3c-6.6,0 -12,-5.4 -12,-12V24c0,-6.6 5.4,-12 12,-12H130c6.6,0 12,5.4 12,12V161z" | ||
| android:fillColor="@android:color/system_neutral1_800"/> | ||
| <path | ||
| android:pathData="M127.7,14.6H36.5C22,14.6 22.3,24 22.3,24c0,-6.6 5.4,-12 12,-12H130c6.6,0 12,5.4 12,12C142,24 141.7,14.6 127.7,14.6z" | ||
| android:fillColor="@android:color/system_neutral1_100" | ||
| android:fillAlpha="0.1"/> | ||
| <path | ||
| android:pathData="M36.5,167h91.2c14.5,0 14.3,-6 14.3,-6c0,6.6 -5.4,12 -12,12H34.2c-6.6,0 -12,-5.4 -12,-12C22.2,161 22.5,167 36.5,167z" | ||
| android:fillColor="@android:color/system_neutral1_1000" | ||
| android:fillAlpha="0.3" /> | ||
|
|
||
| <path | ||
| android:pathData="M35.8,104.2h40v6h-40z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,126.9h20v6h-20z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
|
|
||
| <path | ||
| android:pathData="M35.3,148.4h42v6h-42z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,104.2h40v6h-40z" | ||
| android:fillColor="@android:color/system_neutral1_900" /> | ||
|
|
||
| <path | ||
| android:pathData="M35.8,126.9h20v6h-20z" | ||
| android:fillColor="@android:color/system_neutral1_900" /> | ||
| <path | ||
| android:pathData="M35.3,148.4h42v6h-42z" | ||
| android:fillColor="@android:color/system_neutral1_900" /> | ||
| <path | ||
| android:pathData="M35.8,27.9h69.5v6h-69.5z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,48.7h22.4v6h-22.4z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M36.3,70.2h36.8v6h-36.8z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M65.9,48.7h22.4v6h-22.4z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,27.9h69.5v6h-69.5z" | ||
| android:strokeAlpha="0.2" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M35.8,48.7h22.4v6h-22.4z" | ||
| android:strokeAlpha="0.2" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M36.3,70.2h36.8v6h-36.8z" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M65.9,48.7h22.4v6h-22.4z" | ||
| android:strokeAlpha="0.2" | ||
| android:fillColor="@android:color/system_neutral1_600" /> | ||
| <path | ||
| android:pathData="M106.2,59.6c-1,0 -2.1,0.1 -3.1,0.4c-4.2,1.4 -6.3,5.4 -7.3,9.1s-1.2,7.8 -1.3,11.9c-0.1,4.1 -0.2,8.3 -0.5,11.7c-0.3,3.4 -1.2,5.9 -1.7,6.6s-2.7,2.3 -5.8,3.6c-3.1,1.4 -7,2.7 -10.9,4.1s-7.7,2.9 -11,4.9c-3.2,2 -6.4,5.2 -6.4,9.7s3.1,7.6 6.4,9.7s7,3.5 10.9,5c3.9,1.4 7.8,2.7 10.9,4.1c3.1,1.4 5.3,2.9 5.8,3.6c0.5,0.7 1.3,3.3 1.6,6.7c0.3,3.4 0.4,7.5 0.5,11.7c0.1,4.1 0.4,8.2 1.3,11.9s3,7.7 7.2,9.1c4.2,1.4 8.2,-0.6 11.2,-3.1s5.6,-5.6 8.1,-8.8s5,-6.6 7.3,-9.1s4.4,-4.2 5.3,-4.4c0.8,-0.3 3.5,-0.2 6.8,0.5s7.3,2 11.2,3.1c4,1.1 7.9,2.2 11.7,2.4s8.2,-0.5 10.9,-4.1c2.6,-3.6 2,-8 0.6,-11.6s-3.6,-7 -5.9,-10.4c-2.3,-3.4 -4.7,-6.8 -6.4,-9.7c-1.7,-2.9 -2.6,-5.5 -2.6,-6.4c0,-1 1.1,-4 3.3,-7.4c2.1,-3.4 5,-7.3 7.5,-11.1c2,-3 3.7,-6.1 4.8,-9.2c1,-3.2 1.3,-7.1 -1,-10.3c-2.6,-3.6 -7,-4.3 -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-1.4 7.8,-2.7 11.4,-4.3c3.6,-1.6 7,-3.2 9.3,-6.4c2.3,-3.2 2.9,-7 3.3,-10.9s0.4,-8.2 0.6,-12.2c0.1,-4 0.4,-7.6 1.1,-10.1C104.7,68.8 105.3,68.3 105.7,68.2L105.7,68.2z"> | ||
| <aapt:attr name="android:fillColor"> | ||
| <gradient | ||
| android:startY="98.7147" | ||
| android:startX="79.9001" | ||
| android:endY="151.12" | ||
| android:endX="170.6686" | ||
| android:type="linear"> | ||
| <item android:offset="0" android:color="@android:color/system_neutral1_500"/> | ||
| <item android:offset="1" android:color="@android:color/system_neutral1_800"/> | ||
| </gradient> | ||
| </aapt:attr> | ||
| </path> | ||
| <path | ||
| android:pathData="M142.3,160.5c0,6.6 -5.4,12 -12,12H34.6c-6.6,0 -12,-5.4 -12,-12v-137c0,-6.6 5.4,-12 12,-12h95.7c6.6,0 12,5.4 12,12L142.3,160.5L142.3,160.5z" | ||
| android:strokeAlpha="0.1" | ||
| android:fillAlpha="0.1"> | ||
| <aapt:attr name="android:fillColor"> | ||
| <gradient | ||
| android:startY="25.35" | ||
| android:startX="15.8" | ||
| android:endY="158.65" | ||
| android:endX="149.1" | ||
| android:type="linear"> | ||
| <item android:offset="0" android:color="#FFFFFFFF"/> | ||
| <item android:offset="1" android:color="#00000000"/> | ||
| </gradient> | ||
| </aapt:attr> | ||
| </path> | ||
| <path | ||
| android:pathData="M142.3,160.5c0,6.6 -5.4,12 -12,12H34.6c-6.6,0 -12,-5.4 -12,-12v-137c0,-6.6 5.4,-12 12,-12h95.7c6.6,0 12,5.4 12,12L142.3,160.5L142.3,160.5z" | ||
| android:strokeAlpha="0.1" | ||
| android:fillAlpha="0.1"> | ||
| <aapt:attr name="android:fillColor"> | ||
| <gradient | ||
| android:startY="92" | ||
| android:startX="22.6" | ||
| android:endY="92" | ||
| android:endX="142.3" | ||
| android:type="linear"> | ||
| <item android:offset="0" android:color="#FFFFFFFF"/> | ||
| <item android:offset="1" android:color="#00000000"/> | ||
| </gradient> | ||
| </aapt:attr> | ||
| </path> | ||
| </vector> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,83 @@ | ||
| <FrameLayout android:id="@+id/ankidroid_widget_small_layout" | ||
| xmlns:android="http://schemas.android.com/apk/res/android" | ||
| xmlns:tools="http://schemas.android.com/tools" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="match_parent" | ||
| android:background="#00FFFFFF" | ||
| android:clickable="true" | ||
| android:focusable="false" | ||
| tools:layout_height="100dp" | ||
| tools:layout_width="100dp"> | ||
|
|
||
| <ImageButton | ||
| android:id="@+id/ankidroid_widget_small_button" | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:layout_gravity="center" | ||
| android:background="#00FFFFFF" | ||
| android:clickable="false" | ||
| android:contentDescription="@string/app_name" | ||
| android:focusable="false" | ||
| android:foregroundTint="@color/material_dynamic_primary60" | ||
| android:scaleType="fitCenter" | ||
| android:src="@drawable/ic_anki_dynamic" /> | ||
|
|
||
| <ImageButton | ||
| android:id="@+id/ankidroid_widget_small_finish_layout" | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:layout_gravity="center" | ||
| android:background="#00FFFFFF" | ||
| android:clickable="false" | ||
| android:focusable="false" | ||
| android:scaleType="fitCenter" | ||
| android:src="@drawable/ic_anki_dynamic_finish" | ||
| android:visibility="gone" /> | ||
|
|
||
| <RelativeLayout | ||
| android:id="@+id/ankidroid_widget_text_layout" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="match_parent" | ||
| android:clickable="false" | ||
| android:focusable="false" | ||
| android:orientation="horizontal" | ||
| android:padding="4dip"> | ||
|
|
||
| <!-- 7366: Using FixedTextView breaks the widget | ||
| Error inflating RemoteViews : android.view.InflateException: Binary XML file line #30: | ||
| Binary XML file line #30: Error inflating class com.ichi2.ui.FixedTextView | ||
|
|
||
| https://stackoverflow.com/a/6150129/--> | ||
| <TextView | ||
| android:id="@+id/widget_due" | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:minWidth="24sp" | ||
| android:minHeight="24sp" | ||
| android:padding="3sp" | ||
| android:background="@drawable/circle_background" | ||
| android:gravity="center" | ||
| android:singleLine="true" | ||
| android:textColor="@android:color/system_accent1_0" | ||
| android:textSize="18sp" | ||
| android:visibility="invisible" | ||
| tools:visibility="visible" /> | ||
|
|
||
| <TextView | ||
| android:id="@+id/widget_eta" | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:layout_alignParentBottom="true" | ||
| android:layout_alignParentEnd="false" | ||
| android:background="@drawable/circle_background" | ||
| android:gravity="center" | ||
| android:padding="3sp" | ||
| android:singleLine="true" | ||
| android:minWidth="24sp" | ||
| android:minHeight="24sp" | ||
| android:textColor="@android:color/system_accent1_0" | ||
| android:textSize="14sp" | ||
| android:visibility="invisible" | ||
| tools:visibility="visible" /> | ||
| </RelativeLayout> | ||
| </FrameLayout> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.