Closed (fixed)
Project:
Fences - Semantic field markup and classes
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
18 Nov 2011 at 11:09 UTC
Updated:
25 Apr 2012 at 05:11 UTC
By default, Drupal uses a robust, div-heavy wrapper for all fields.
Fences currently replaces that div markup with a leaner single-div version. However, that may break a theme if the theme was depending on the markup in the core field markup. So I'm classifying this as a bug. :-p
So, we should add a setting so that, if checked, any field that hasn't been configured to use a specific markup wrapper should use core's default wrapper.
Comments
Comment #1
jensimmons commentedYeah, this makes sense. If you don't specify anything in a field setting having to do with Fences, you should get default Drupal core behavior.
That way if someone adds Fences to an existing site, makes some new fields with Fences (maybe, say, in a brand new content type), and deploys that.... they don't have to worry that all their own crusty fields suddenly changed when they didn't tell them too.
So basically, there's a 'no setting' state (which uses the core markup with three/four divs), a 'div' Fences wrapper (that uses a div, but with very different markup from the core default), and a 'none' state that uses Fences markup that has no HTML wrapper at all. Could be a bit confusing to have these three states, but also, totally makes sense.
Comment #2
johnalbinActually, I just realized that Fences already has this behaviour. If a field's settings form hasn't been saved while Fences is enabled, Fences won't store the "div" suggestion for that field and so core's markup is used anyway.
So what we need is actually the opposite. A setting to always use Fences' field markup even when the field hasn't been configured to use anything.
Ok. But what should be the default?
Comment #3
johnalbinDecided that "use core's markup" should be the default. So we don't break sites immediately upon installation.
The "override core markup" option is a power-user option. :-)
Fixed. http://drupalcode.org/project/fences.git/commitdiff/37681e5