0.0.9 will be a huge release, bringing about changes in the interface as well as the underlying plugin architecture. In this post I’m explaining both changes and how they will affect both users and developers.
Interface – ‘View Likes’
Currently, viewing who else likes an activity is accomplished by clicking ‘View Likes’ and seeing a drop-down full of names. This worked well enough with activities, but could become intrusive on the UI if we start adding this to forums, blog comments, photos etc. (more on this later).
Facebook has approached the UI differently, by showing a couple of names and providing a link to a popup if there are more than 3 likers. This is how 0.0.9 will behave, the screenshots below show the process.
An added benefit of this change is a greatly reduced number of text strings that need to be translated or customised. Also, for large BuddyPress sites, the number of likers could grow quite large and this handles this better.
Architecture – Introducing a Universal Like Button
0.0.8 introduced support for liking blog posts, and whilst achieving this wasn’t particularly difficult, it was cumbersome. I effectively copied the code for activities, but this doubled the code size; I obviously can’t do this for all the other types of content across a BuddyPress site.
0.0.9 will no longer store its data in the ‘metadata’ fields for activities or blog posts, but instead in a central database table. Because of this, any content which has a unique ID can be liked. And it’s as simple as including one line of code, which registers the content type, outputs the like button and the accompanying ‘view likes’ information.
Activities and blog posts will automatically be converted, but this means forum comments, blog comments, photos, events and more can be liked. Developers can have out-of-the-box support for BuddyPress Like by just including the like button.
Full translation support will finally come built in, with a pre-packaged .pot file and as many translations as I can get hold of ready to use. An option to disable the ‘Favourite’ feature in BuddyPress will also be created.
What do you think?
Let me know what you think about all of these upcoming changes! The first version of the UI revamp will be in trunk later today.