Skip to content
This repository has been archived by the owner. It is now read-only.

Switch to using govuk_admin_template #198

Merged
merged 29 commits into from Aug 28, 2014
Merged

Switch to using govuk_admin_template #198

merged 29 commits into from Aug 28, 2014

Conversation

@fofr
Copy link
Contributor

@fofr fofr commented Aug 27, 2014

Recommend reviewing code using?w=1, and doing like-for-like comparisons with preview.

  • Start using admin gem which bundles jQuery, Bootstrap, environment indicator and default application layout
  • Upgrade from Bootstrap 2 to Bootstrap 3
  • Upgrade formtastic, formtastic-bootstrap, chosen and jQuery UI
  • Use a select2 gem for assets
  • Update markup to conform with newest bootstrap patterns
    • Replace grid classes on form elements with appropriate grid wrappers
    • Formtastic picks up most of the form changes, but for forms not using it:
      • Switch from controls to form-group, and ensure there's a form-control class on inputs
    • Add missing -default classes to default buttons and alerts
    • Use Bootstrap 3 kaminari themes for pagination
    • Switch to using Bootstrap 3 glyphicons
  • Update flash messages for new Bootstrap 3 alerts

screen shot 2014-08-27 at 15 04 43
screen shot 2014-08-27 at 15 05 02
screen shot 2014-08-27 at 15 05 37
screen shot 2014-08-27 at 15 05 51
screen shot 2014-08-27 at 15 06 05

fofr added 29 commits Aug 22, 2014
* Add govuk_admin_template
* Remove jquery-rails, jQuery is provided via gem
* Upgrade jquery-ui, formtastic, formtastic-bootstrap
* Use nested layouts
* Import gem’s SASS styles
* Remove now unnecessary javascript and SASS includes
* Remove HTML5 shim, now provided by gem
* Remove theme bootstrap overrides
* Update style of jquery-ui include to match newer gem
* Keep a reference to admin design patterns
* Show how local styles may have affected those patterns
* Remove custom styling
* Remove old Bootstrap grid classes, form elements now expand to width
of container
* Add Bootstrap 3 form classes
* Replace old grid classes with gem’s input helpers
* Remove row wrappers
* Replace row-fluid with row
* Update span classes to col-md classes
* Update span classes on inputs to use gem input-md helper classes
* Remove wrapping rows and span12 classes where unnecessary
  * Form elements expand to full width by default now
* http://getbootstrap.com/css/#grid
* Replace `icon` with `glyphicon`
* No need to specify icon colour, Bootstrap 3 icons are font based and
inherit the text’s colour
* Bring table inline with admin style guide
* Default notice and alert message types to the bootstrap “warning”
alert
* Be explicit about success messages, and show them in green
* Stop sliding up flash notices
* Remove overrides that made warnings green
* Give filter column more space
* Use number with delimiter
* Use big number styles from gem
* Remove bespoke artefact count styles
* Add missing form-control class
* Use helper class for vertical margins
* Remove bespoke styles
* Position remove button absolutely rather than with floats
* Apply same changes as tag fields
* Make remove buttons absolute
* Add missing form classes
* Icons can now use text colour rather than opacity
* Reset list styles using Bootstrap helper class
* Mute secondary links
* Use form_control_input_html_options so text input has correct
bootstrap classes
* Rather than generating HTML to prepend, use the built-in prepend
method, and merge this with existing input options. See:
https://github.com/justinfrench/formtastic#creating-new-inputs-based-on-
existing-ones
The well and the tabs were too close together.
* Also modify old chzn classes
* Custom overrides of Bootstrap 2 styles no longer needed
* Delete old header styles
* Delete crown asset
* Use a gem to provide the styles, js and assets
* Delete old assets
* After upgrading jQuery, the select2 initSelection method wasn’t being
called
* The hack to use a hidden input is no longer needed
* Remove a trailing comma which will be breaking older IEs
* Fields don’t use formtastic so didn’t inherit the Bootstrap styles
* Labels are no longer display block, so there needs to be a line break
after the link label
* Bootstrap 3 defaults didn’t fit well with the existing custom CSS for
the need input form
* Tweak margins and input spacing to maintain previous look and feel
* Avoid styling using IDs
* Try and avoid accidental clicks
* Remove references to old spanX classes
* Hack is simpler now, rows aren’t fluid so we only need to remove the
grid padding
* Upgrade govuk_admin_template to pull in full_width option
  * alphagov/govuk_admin_template#38
* `alert-error` is now `alert-danger`, update all references
* Change a flash message from notice to danger so it shows as red
bishboria added a commit that referenced this issue Aug 28, 2014
Switch to using govuk_admin_template
@bishboria bishboria merged commit 4e9a070 into master Aug 28, 2014
1 check passed
@bishboria bishboria deleted the govuk_admin_template branch Aug 28, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants