TheWebShop / bootstrap-shortcodes

Wordpress plugin to add shortcodes for Twitter Bootstrap 3.0
36 stars 15 forks source link

Grid looks ugly #40

Closed No3x closed 10 years ago

No3x commented 10 years ago

Hi,

there are some ugly br after each element. I have no clue where they are come from. before Any ideas? Can somebody approve this?

Shortcode for this is: [bs_row class="row"]
[bs_col class="col-xs-4"]asddsad ads da sd asd asd d[/bs_col]
[bs_col class="col-xs-4"]Teasdasd  das dasd  das daxt[/bs_col]
[bs_col class="col-xs-4"]Te xa d d as as dt[/bs_col]
[/bs_row]

[bs_row class="row"] [bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button1"] [/bs_col][bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button2"] [/bs_col][bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button3"] [/bs_col] [/bs_row]

No3x commented 10 years ago

Okay it's obviously because of the line breaks.. I realized myself while adding this shortcode to the issue. We can't filter all line breaks, can we? Only line breaks between the tags..

No3x commented 10 years ago

Approach commited with #41 Before: bildschirmfoto 2014-07-12 um 19 43 45 After: The explicit content of the post/page is rendered without fancy WordPress stuff. bildschirmfoto 2014-07-12 um 19 45 12 Comparison: bildschirmfoto 2014-07-12 um 19 50 38

Should be tested in production from some guys! Please shift this few lines or checkout on production website and check all kinds of shortcodes. This approach could change the behaviour of several builtin WordPress shortcodes. I need some data on this.

The used shortcode (to reproduce) was: [bs_row class="row"]
[bs_col class="col-xs-4"]asddsad ads da sd asd asd d[/bs_col]
[bs_col class="col-xs-4"]Teasdasd das dasd das daxt[/bs_col]
[bs_col class="col-xs-4"]Te xa d d as as dt[/bs_col]
[/bs_row]

[bs_row class="row"] [bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button1"] [/bs_col][bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button2"] [/bs_col][bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button3"] [/bs_col] [/bs_row]

[bs_row class="row"] [bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button1"] [/bs_col] [bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button2"] [/bs_col] [bs_col class="col-xs-4"] [bs_button size="md" type="success" value="Button3"] [/bs_col] [/bs_row]