-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Show campaigns on home screen #2108
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
Show campaigns on home screen #2108
Conversation
* Added a ui util class SwipableCardView which passes the onSwipe event to its children * NearbyCardView & CampaignView extend SwipableCardView * Fetch campaigns in ContributionsFragment * Added an option to enable disable campaign in Settings/Preferences
Codecov Report
@@ Coverage Diff @@
## 2.9-release #2108 +/- ##
==============================================
- Coverage 4.07% 4.02% -0.06%
==============================================
Files 224 230 +6
Lines 11337 11509 +172
Branches 1049 1059 +10
==============================================
+ Hits 462 463 +1
- Misses 10841 11012 +171
Partials 34 34
Continue to review full report at Codecov.
|
Thanks @ashishkumar468 . It looks good to me in general, but I think we need to modify the layout slightly to make it look more "in theme" with the Nearby card. :) I suggest adding an icon to the side, setting "Wiki Loves Monuments" to be in line with "National Insurance Academy", and removing the superfluous subtext (no point saying Wiki Loves Monuments Twice). I am not really sure what to do with the date though. We could just say:
in line with the "1.3 km" perhaps? @neslihanturan what do you think? |
The first line is the title, the second line is the description(its repeated because that's what we have in the dummy json for now), do you want me to remove the description? Also, will do the suggested ui changes and it would be great if someone could provide me with an icon similar to nearby. |
|
||
import com.google.gson.annotations.SerializedName; | ||
|
||
public class Campaign { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add Javadocs for all the new classes and methods. :) I guess there isn't really a need to have them for every single getter and setter method in this particular class (since they are fairly self-explanatory), but there should still at least be a Javadoc for the class itself. And the methods in the other classes would need them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes I was gonna, have added a lot of classes :P, will do it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
* Update ui for CampaignView
How about these icons? (in my order of preference) The first implies: humans, coming together, cheering, party atmosphere |
Thanks @nicolas-raoul , My vote is with this one. @misaochan @neslihanturan What do you guys say ? |
I vote for the "whatshot" icon :) The first two look more like directions to me personally.
Yes, I think we can go without the description for now. |
* bug fix, campaign view should not be visible in MediaDetailPagerFragment * code formatting, few more java docs
This PR should be based on master instead of |
Have rasied a new pr for the same |
Description (required)
Show ongoing campaigns on home screen
Fixes #78 {Show news about ongoing campaigns/competitions}
What changes did you make and why?
Tests performed (required)
Tested {build variant, ProdDebug} on OnePlus 3T with API level {26}
Screenshots showing what changed (optional - for UI changes)
