Problem/Motivation
We are converting core button CSS classes to Bootstrap classes in bs_bootstrap input--submit template. However, we should not do this in the case of the button already have btn-primary or btn-secondary - case when custom code already attached one of these two classes.
It is highly unlikely that the submit button will have any other than this two CSS classes, so, for now, let's just check the existence of these two and not the other ones.
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | interdiff-3105185-3-5.txt | 918 bytes | pivica |
| #5 | check-for-bootstrap-button-classes-first-3105185-5.patch | 1.4 KB | pivica |
Comments
Comment #2
pivica commentedHere is a patch.
Comment #3
pivica commentedComment type fixed.
Comment #4
pivica commentedComment #5
pivica commentedAnd for sure we found examples where we have only btn class set but we are using custom classes to additionally style the button. It seems that we need to check for the existence of btn class also first with the other two. This would mean if developer set btn or btn-primary or btn-secondary he then knows what he is doing, which make sense i hope ;)
Comment #7
pivica commentedCommitted.