Skip to content
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

Enable crosswiki notifications and minor UI fixes in displaying notif… #1540

Merged
merged 2 commits into from
May 24, 2018

Conversation

maskaravivek
Copy link
Member

This PR enables crosswiki notifications so that some of the wikidata and wikipedia notifications(currently thank you edits) can be seen in the app.

Moreover, it does quite a few UI fixes:

  • removes whitespace from the beginning of a notification
  • shows appropriate notification icon, fetching it from the server
  • parses HTML string to show unescaped string

Notifications page now looks much better :)

notifications

@codecov-io
Copy link

codecov-io commented May 20, 2018

Codecov Report

Merging #1540 into master will decrease coverage by 0.01%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #1540      +/-   ##
=========================================
- Coverage    3.13%   3.11%   -0.02%     
=========================================
  Files         136     140       +4     
  Lines        7397    7437      +40     
  Branches      713     714       +1     
=========================================
  Hits          232     232              
- Misses       7150    7190      +40     
  Partials       15      15
Impacted Files Coverage Δ
...ain/java/fr/free/nrw/commons/glide/SvgDecoder.java 0% <0%> (ø)
...ee/nrw/commons/notification/NotificationUtils.java 0% <0%> (ø) ⬆️
.../free/nrw/commons/glide/SvgDrawableTranscoder.java 0% <0%> (ø)
...nrw/commons/notification/NotificationRenderer.java 0% <0%> (ø) ⬆️
...free/nrw/commons/glide/SvgSoftwareLayerSetter.java 0% <0%> (ø)
...rw/commons/mwapi/ApacheHttpClientMediaWikiApi.java 5.46% <0%> (-0.02%) ⬇️
...va/fr/free/nrw/commons/notification/SvgModule.java 0% <0%> (ø)
... and 1 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 32d3694...6734c83. Read the comment docs.

Copy link
Member

@misaochan misaochan left a comment

Choose a reason for hiding this comment

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

Thanks for submitting this PR @maskaravivek , this enhancement would be very useful indeed! Happy to merge pending successful tests and separation of Gradle changes.

android.useDeprecatedNdk=true
BUTTERKNIFE_VERSION=8.6.0
org.gradle.jvmargs=-Xmx1536M
buildToolsVersion=26.0.2
targetSdkVersion=25
buildToolsVersion=27.0.0
Copy link
Member

Choose a reason for hiding this comment

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

Do we want to change this in this PR? Might be worth putting Gradle changes in a separate one.

Copy link
Member Author

Choose a reason for hiding this comment

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

Gradle changes were unfortunately required as the new library Glide was having dependency conflicts with

com.android.support:design:26.0.2

The only way I was able to fix it was by upgrading the build tools version.

Moreover, adding Glide was necessary for handling .svg images(notification icons on commons are hosted in .svg). The other image library, Fresco that the app already uses, can't handle .svg images.

Copy link
Member

Choose a reason for hiding this comment

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

Ah okay, thanks for the clarification!

@commons-app commons-app deleted a comment May 23, 2018
@neslihanturan
Copy link
Collaborator

Works for me @maskaravivek thanks!

@neslihanturan neslihanturan merged commit 2a0b9d8 into commons-app:master May 24, 2018
@maskaravivek maskaravivek deleted the notifications branch September 12, 2018 20:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants