[buddypress-trac] [BuddyPress Trac] #6569: Let's give post-form.php the love

buddypress-trac noreply at wordpress.org
Tue Jul 28 14:13:44 UTC 2015


#6569: Let's give post-form.php the love
----------------------------------------+------------------------------
 Reporter:  modemlooper                 |       Owner:
     Type:  enhancement                 |      Status:  new
 Priority:  normal                      |   Milestone:  Awaiting Review
Component:  Appearance - Template Pack  |     Version:  2.3.2
 Severity:  normal                      |  Resolution:
 Keywords:  2nd-opinion                 |
----------------------------------------+------------------------------

Comment (by imath):

 Replying to [comment:8 modemlooper]:
 > I don't know about full JS, it would break existing plugins that add
 actions to markup.
 Yes, and that's one of the reasons it's so challenging to touch to any
 part of the post form, because some plugins are using existing actions.
 But one day or another, i'm pretty sure we'll need to go this road :)

 In the meantime, i've made some tests with the post form template see
 6569.patch.
 - remove the `p.activity-greeting` and use it instead as the placeholder
 of the `whats-new` textarea
 - put the `div#whats-new-submit` out of `div#whats-new-options`
 - added a `div#whats-new-actions` that contains `div#whats-new-submit` and
 `div#whats-new-options` and some new actions.
 - edited some css rules and the main js file to auto-resize the textarea
 on keyup

 In `div#whats-new-actions` The main interesting action imho is the one
 before `div#whats-new-submit` and `div#whats-new-options` it's precisely
 `bp_activity_post_form_before_options`. It seems logic to me that when
 posting an update we:
 - write its content
 - eventually attach media
 - tell who is targeted
 - submit the form.

 Google+ post form is interesting, because it has a lot of "attachment"
 types (photo, links, video...) And it seems the more close to our case,
 because we want to make it possible to any plugin to add custom
 "attachment" types.
 [[Image(https://farm1.staticflickr.com/452/19465098563_3afd76eda8_o.png)]]

 So i've played with this and the BuddyDrive plugin to see how a plugin
 could add its customs "attachment" types. Here's what you get when on the
 activity directory :
 [[Image(https://farm1.staticflickr.com/307/20059416746_0be2efa343_o.png)]]
 Only the placeholder is shown

 When you begin to type a new activity, this is what you get (btns are
 generated by BuddyDrive by hooking on
 `bp_activity_post_form_before_options`) :
 [[Image(https://farm1.staticflickr.com/391/19899006719_dc74dd44af_o.png)]]

 When you click on the "Photo" button, this is what you get (Uploader is
 the BuddyPress one and generated by BuddyDrive)
 [[Image(https://farm1.staticflickr.com/436/20059416446_e9ab53b554_o.png)]]



 > also so apprehensive about a media thing included in BP because almost
 every single client wants something different.
 I see what you mean, but on the other hand, some users could be frustrated
 by the fact there's no built-in component to manage user uploads in the
 long term. I agree there are some great plugins to do so, but i'm also
 hearing some users complaining when a plugin drop his support... I guess
 people could feel safer having a very basic component to organize user
 uploads, other plugins could take to the next level :)

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6569#comment:9>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list