Clicking the button to follow people on search page was erroneously
triggering a reaction request, thus not having the reactable_id.
We've updated the handlers not to trigger it.
* Add infinite scroll to followers list (#258)
* Refactor fetchNext function for clarity (#258)
* Sepparate following tab into multiple tabs to support infinite scroll (#258)
* Add infinite scroll to following pages (#258)
* Add tests to infinite scroll api
* Refactor dashboard loading text
* Refactor infine scroll function
* Fix duplicated entries problem in infinite scrolling
* Switch randomized attributes to sequential to avoid InvalidRecord error
* Add acceptance tests for infinite scroll
* Remove unused following method
* parameterize limit per page for followers and followings
* Split follows endpoint into followers and followings
* Authenticate user with api key in followers and followings
* Split followers endpoint into users and organizations
* Add redundant html to sublist partial
* Speed up infinite scroll tests
* Refactor api json responses to use partials
* Authenticate api user before follows create
* Resolve conflicts on scrolling js
* Improve partials organization and fix organization username bug
* Improve readability of unauthorized test
* Use let! to create scrolling test data
* Fix not working podcasts link
* Refactor initScrolling to remove linting errors
* Fix codeclimate coding style issue
* Test tags forms and podcasts hyperlinks
* Fix eslint issue with double equals
* Improve before_action usage and readability
* Hide blocked users' content appropriately
* Use RESTful create route
* Update functionality to block the user
* Fix specs for new route
* Use const instead of var
* Add noopener and noreferrer
* Remove caching for blocked user ids
* Add new rule for lack of noopener noreferrer
* Update snapshot
* Fix JavaScript Console errors in /Comments sub-page of any article
- Make use of `document.body.contains()` to check if the element is present before trying to Add or Remove Event listeners or assign attribute values to the same.
* Implement recommendations for changes
- Switch String.match() to Regex.test() in order to have consistent Boolean return.
- Switch if(document.body.contains(element)) to if(element) as no need to check if the element is in visible context, only whether present or not.
* Implement recommendations for changes
- Switch String.match() to Regex.test() in order to have consistent Boolean return for isIOSDevice().
- Switch if(document.body.contains(element)) to if(element) as no need to check if the element is in visible context, only whether present or not.
* fix use global form of use strict error
* fix errors involving functions being used before being defined
* fix undefined function and == errors
* fix redeclared variable name error
* use arrow functions to fix unnamed function warnings
* specify global function at top of file instead of disabling line in eslint, change meta variable name
- eslint configuration moved comments to a seperate line
in pre commit hook allowing the eslint-disable-line to
not work correctly.
- switched to eslint-disable-next-line to fix the same
* Refactor initializeArticleReactions.js
- Refactors file according to eslint rules
- Add showModal and sendHapticMessage to globals
in eslintrc.js
- Shorten initializeArticleReactions() by distributing
parts of it into jumpToComments() and requestReactionCounts()
- requestReactionCounts() makes an ajax request to get the
reaction counts
- jumpToComments() jumps to comments element directly if the
element jump-to-comments is present
* Fix reactionOnClick function to work correctly
- Move sendHapticMessage and showModal global declaration to file
- name function on reaction button on click as addReactionOnClick
which then calls reactToArticle()
* Add ProMembership model
* Implement ProMembershipsController#create
* Implement basic ProMembershipsController#show
* Add ProMembership to ledger
* Populate user history after pro subscription is created
* Add fields for expiration notifications
* Add ProMemberships::ExpirationNotifier to notify users of expiring memberships
* Add tasks for recurring jobs to notify users of expiration
* Add auto_recharge column to ProMembership
* Add ProMemberships::Biller (incomplete)
* Fix specs
* Add ProMembership to Administrate
* Fix spec
* Add has_enough_credits? to User and Organization
* Add Payments::Customer class
* Finish ProMembership::Biller functionality
* Fix ProMemberships::Creator check for credits
* Disable destroy actions for ProMembershipsController
* Correctly authenticate ProMembershipsController actions
* Make sure only pro user's history can be indexed
* Add ProMembershipsController#update action for auto recharge
* Use regular AR to save new credits and add touch to the purchaser
* Clarify Pro membership create policy
* Display information about an existing pro membership
* Add UI to show page
* Add system test for Pro membership creation
* Implement edit membership
* Make sure users with pro memberships can access history and dashboard pro
* Fix padding issue
* Show a different text for a user that has credits but not enough for Pro
* Move Pro Membership functionality inside settings
* Update Pro Membership link in email notifications
* Bust all relevant caches
* Add the Pro checkmark around the website
* Use Users::ResaveArticlesJob instead of delay
* Add/remove user from pro-members chat channel
* Use the appropriate Pro checkmark
* Remove unfinished pro elements
* Remove checkmark JS
* Increase efficiency and fix pagination offset issue
Right now we filter recently aggregated notifications at runtime, which worked before when there was no pagination, but now filtering is not a good idea combined with offset pagination because it throws off the calculations.
The filtering should be done in the SQL query before paginating, which is what we've switched to. I added a bunch of scopes to make the code clearer as well.
To avoid nesting tags I've also updated the HTML and the JS logic to insert it in the right place.
* Add explanation for hiding the load more button for new users
* Use offset instead of page and explain things
* Make load more button work
* Add tests for admin view
* Restore the previous logged out behavior
* Modernize initNotifications.js
* Revert "Modernize initNotifications.js"
This reverts commit 4a112b797d7911c4ab63ad0c0a07111b4e7abe25.
* Fix elements presence errors
* Change load-more-button to only appear if 7 or more posts (and some notification copy adjustments)