Skip to content

Add the ability to change the html tag for the toggle in collapsible . #5410

Closed
wants to merge 1 commit into from

5 participants

@ErwanMAS
ErwanMAS commented Jan 2, 2013

Can be useful to prevent some behavior because it's a tag a .

@ErwanMAS ErwanMAS Add the hability to change the html tag for the toggle in collapsible .
Can be useful to prevent some behavior because it's a tag a .
1603191
@jaspermdegroot
jQuery Foundation member

@ErwanMAS

Thanks for the PR! Can you tell a bit more about what sort of behaviour you want to prevent?

@ErwanMAS
ErwanMAS commented Jan 3, 2013

I do a example . I want capture a taphold event .

On IOS6 when i do a taphold on the toggle , safari display a menu about the link
( with open / new window / add / copy / cancel ) with

http://jsfiddle.net/napXd/1/embedded/result/

@jaspermdegroot
jQuery Foundation member

@ErwanMAS

Thanks for the example.

On iOS6 you can prevent the context menu with the CSS properties -webkit-touch-callout and -webkit-user-select: http://jsbin.com/ehowik/3/edit (http://jsbin.com/ehowik/3 for preview).
However, the first property is not supported on Android (yet) and I think not on Chrome either.

I will discuss with the team if we want to make this an option or maybe just change the code to make the collapsible button a div.

@jaspermdegroot
jQuery Foundation member

@toddparker @Wilto - What's your opinion on this?

@johnbender

@uGoMobi @gseguin

This might be a good opportunity to move this portion of the _create into a child method. That way it can be overridden by enterprising users like @ErwanMAS without having to technically support it.

RaaF - Refactoring as a Feature (c) John Bender all rights reserved.

@arschmitz
jQuery Foundation member

I second @johnbender comments i think adding the ability to easily extend is much better then add an option and handles all sorts of different requests and situations.

@jaspermdegroot
jQuery Foundation member

In general we should try to prevent adding all kind of options, so I am not in favor of making this an option either.
@johnbender his solution sounds very good to me.

If we all agree I suggest to close this PR and create a ticket for this for 1.4.

@gseguin
jQuery Foundation member
gseguin commented Mar 20, 2013

@ErwanMAS, It seems like you haven't signed a CLA. Please visit http://contribute.jquery.org/CLA/ and sign it so we can look into your PR.

Thank you.

@ErwanMAS

@gseguin CLA signed done

@arschmitz
jQuery Foundation member

there are conflicts here and i think we are going to go another direction to provide this type of feature so closing

@arschmitz arschmitz closed this Aug 6, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.