18F / web-design-standards-drupal

A Drupal base theme that uses the U.S. Web Design System. (ARCHIVED)
Other
46 stars 12 forks source link

[D7]Implement Footer variations #48

Open iris-i opened 8 years ago

iris-i commented 8 years ago

There are 3 variations of site footers in the playbook, Small, medium & large. We need to figure out how to offer these choices to users. Maybe build it into the theme options? https://playbook.cio.gov/designstandards/footers/

From #15

fureigh commented 8 years ago

+1 for building it into the theme options. "Any styled footer" is the minimum viable element here; feel free to break out another ticket for config if you'd like.

For ease of tracking:

patrickcate commented 8 years ago

I've been thinking more about how to implement this. In particular how the links, phone # and email address info will be pulled in, since they will be specific for each site.

Some thoughts:

  1. The site owner could add the link and other info to the settings.php file, which could the be pulled in as variables for printing the footer in a page or region template file.
  2. Similar to option 1, but added to the theme template.php file. This is only really viable if the site owner has made a sub-theme though, as it would be overwritten with updates to the base WDSD theme.
  3. Add a theme admin config section for adding the links and other information. This can then be pulled into the footer added to a page or region template file.
  4. Make a 'companion' Drupal module (usa_theme ? wds_theme ?). With this pretty much anything could be done. A custom Drupal menu for the footer links could be created programmatically for the site owner. An admin config form/area could be created for entering the phone #, email, and anything else. A block could be created programmatically for the footer (including the different variations) so it could be easily added to one of the theme's regions. The module would add flexibility for implementing other parts of the WDS.
  5. Some kind of custom JSON file living in the theme directory where the info could be added and later parsed as variables. Similar to option 2 this is only really viable if the site owner has made a sub-theme though, as it would be overwritten with updates to the base WDSD theme.
brockfanning commented 7 years ago

In #66 I added "footer agency" information as configurable theme settings. I didn't think about phone numbers, social links, etc., but those could be added in a similar way.