Permalink
Browse files

Try to merge the picmnt styles with twitter bootstrap

  • Loading branch information...
1 parent 9878b9f commit 0b2191622e4adf9630bf4f8da758d98a3fadb3ac @mgallego committed Feb 17, 2013
Showing with 6,731 additions and 338 deletions.
  1. +4 −1 app/config/config.yml
  2. +1 −1 src/SFM/PicmntBundle/Menu/Builder.php
  3. BIN src/SFM/PicmntBundle/Resources/public/img/glyphicons-halflings-white.png
  4. BIN src/SFM/PicmntBundle/Resources/public/img/glyphicons-halflings.png
  5. +165 −0 src/SFM/PicmntBundle/Resources/public/js/bootstrap-dropdown.js
  6. +34 −0 src/SFM/PicmntBundle/Resources/public/less/accordion.less
  7. +79 −0 src/SFM/PicmntBundle/Resources/public/less/alerts.less
  8. +63 −0 src/SFM/PicmntBundle/Resources/public/less/bootstrap.less
  9. +24 −0 src/SFM/PicmntBundle/Resources/public/less/breadcrumbs.less
  10. +229 −0 src/SFM/PicmntBundle/Resources/public/less/button-groups.less
  11. +210 −46 src/SFM/PicmntBundle/Resources/public/less/buttons.less
  12. +158 −0 src/SFM/PicmntBundle/Resources/public/less/carousel.less
  13. +32 −0 src/SFM/PicmntBundle/Resources/public/less/close.less
  14. +61 −0 src/SFM/PicmntBundle/Resources/public/less/code.less
  15. +22 −0 src/SFM/PicmntBundle/Resources/public/less/component-animations.less
  16. +237 −0 src/SFM/PicmntBundle/Resources/public/less/dropdowns.less
  17. +678 −21 src/SFM/PicmntBundle/Resources/public/less/forms.less
  18. +21 −0 src/SFM/PicmntBundle/Resources/public/less/grid.less
  19. +25 −0 src/SFM/PicmntBundle/Resources/public/less/hero-unit.less
  20. +84 −0 src/SFM/PicmntBundle/Resources/public/less/labels-badges.less
  21. +16 −0 src/SFM/PicmntBundle/Resources/public/less/layouts.less
  22. +55 −0 src/SFM/PicmntBundle/Resources/public/less/media.less
  23. +702 −0 src/SFM/PicmntBundle/Resources/public/less/mixins.less
  24. +95 −0 src/SFM/PicmntBundle/Resources/public/less/modals.less
  25. +497 −0 src/SFM/PicmntBundle/Resources/public/less/navbar.less
  26. +409 −0 src/SFM/PicmntBundle/Resources/public/less/navs.less
  27. +43 −0 src/SFM/PicmntBundle/Resources/public/less/pager.less
  28. +123 −0 src/SFM/PicmntBundle/Resources/public/less/pagination.less
  29. +63 −25 src/SFM/PicmntBundle/Resources/public/less/picmnt.less
  30. +133 −0 src/SFM/PicmntBundle/Resources/public/less/popovers.less
  31. +122 −0 src/SFM/PicmntBundle/Resources/public/less/progress-bars.less
  32. +216 −0 src/SFM/PicmntBundle/Resources/public/less/reset.less
  33. +28 −0 src/SFM/PicmntBundle/Resources/public/less/responsive-1200px-min.less
  34. +193 −0 src/SFM/PicmntBundle/Resources/public/less/responsive-767px-max.less
  35. +19 −0 src/SFM/PicmntBundle/Resources/public/less/responsive-768px-979px.less
  36. +189 −0 src/SFM/PicmntBundle/Resources/public/less/responsive-navbar.less
  37. +59 −0 src/SFM/PicmntBundle/Resources/public/less/responsive-utilities.less
  38. +48 −0 src/SFM/PicmntBundle/Resources/public/less/responsive.less
  39. +36 −98 src/SFM/PicmntBundle/Resources/public/less/scaffolding.less
  40. +197 −0 src/SFM/PicmntBundle/Resources/public/less/sprites.less
  41. +244 −0 src/SFM/PicmntBundle/Resources/public/less/tables.less
  42. 0 src/SFM/PicmntBundle/Resources/public/less/{thumbs.less → thumbnails.less}
  43. +62 −44 src/SFM/PicmntBundle/Resources/public/less/tooltip.less
  44. +206 −13 src/SFM/PicmntBundle/Resources/public/less/type.less
  45. +30 −0 src/SFM/PicmntBundle/Resources/public/less/utilities.less
  46. +300 −52 src/SFM/PicmntBundle/Resources/public/less/variables.less
  47. +29 −0 src/SFM/PicmntBundle/Resources/public/less/wells.less
  48. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/alert.less
  49. +64 −0 src/SFM/PicmntBundle/Resources/public/less_bak/buttons.less
  50. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/edit_image.less
  51. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/footer.less
  52. +33 −0 src/SFM/PicmntBundle/Resources/public/less_bak/forms.less
  53. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/general.less
  54. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/header.less
  55. +21 −0 src/SFM/PicmntBundle/Resources/public/less_bak/picmnt.less
  56. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/profile.less
  57. +115 −0 src/SFM/PicmntBundle/Resources/public/less_bak/scaffolding.less
  58. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/sliders.less
  59. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/static.less
  60. +60 −0 src/SFM/PicmntBundle/Resources/public/less_bak/thumbs.less
  61. +52 −0 src/SFM/PicmntBundle/Resources/public/less_bak/tooltip.less
  62. +54 −0 src/SFM/PicmntBundle/Resources/public/less_bak/type.less
  63. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/uploads.less
  64. 0 src/SFM/PicmntBundle/Resources/public/{less → less_bak}/user.less
  65. +61 −0 src/SFM/PicmntBundle/Resources/public/less_bak/variables.less
  66. +1 −1 src/SFM/PicmntBundle/Resources/views/Image/recents.html.twig
  67. +2 −2 src/SFM/PicmntBundle/Resources/views/Image/thumbs.html.twig
  68. +2 −1 src/SFM/PicmntBundle/Resources/views/base.html.twig
  69. +22 −13 src/SFM/PicmntBundle/Resources/views/layout.html.twig
  70. +0 −17 src/SFM/UserBundle/Resources/views/Registration/register.html.twig
  71. +3 −3 src/SFM/UserBundle/Resources/views/Registration/register_content.html.twig
View
@@ -44,6 +44,9 @@ assetic:
lessphp:
file: %kernel.root_dir%/../vendor/leafo/lessphp/lessc.inc.php
apply_to: "\.less$"
+ less:
+ node: %node%
+ node_paths: %node_paths%
# Doctrine Configuration
doctrine:
@@ -119,7 +122,7 @@ liip_imagine:
thumbnail:
quality: 75
filters:
- thumbnail: { size: [180, 180], mode: outbound }
+ thumbnail: { size: [250, 250], mode: outbound }
avatar-small:
quality: 75
filters:
@@ -14,7 +14,7 @@ public function menuCategories(FactoryInterface $factory)
$menu = $factory->createItem('root');
$menu->setCurrentUri($this->container->get('request')->getRequestUri());
- $menu->setAttribute('class', 'submenu unstyled');
+ $menu->setAttribute('class', 'dropdown-menu');
$em = $this->container->get('doctrine')->getEntityManager();
$categories = $em->getRepository('SFMPicmntBundle:Category')->findAll();
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -0,0 +1,165 @@
+/* ============================================================
+ * bootstrap-dropdown.js v2.3.0
+ * http://twitter.github.com/bootstrap/javascript.html#dropdowns
+ * ============================================================
+ * Copyright 2012 Twitter, Inc.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============================================================ */
+
+
+!function ($) {
+
+ "use strict"; // jshint ;_;
+
+
+ /* DROPDOWN CLASS DEFINITION
+ * ========================= */
+
+ var toggle = '[data-toggle=dropdown]'
+ , Dropdown = function (element) {
+ var $el = $(element).on('click.dropdown.data-api', this.toggle)
+ $('html').on('click.dropdown.data-api', function () {
+ $el.parent().removeClass('open')
+ })
+ }
+
+ Dropdown.prototype = {
+
+ constructor: Dropdown
+
+ , toggle: function (e) {
+ var $this = $(this)
+ , $parent
+ , isActive
+
+ if ($this.is('.disabled, :disabled')) return
+
+ $parent = getParent($this)
+
+ isActive = $parent.hasClass('open')
+
+ clearMenus()
+
+ if (!isActive) {
+ $parent.toggleClass('open')
+ }
+
+ $this.focus()
+
+ return false
+ }
+
+ , keydown: function (e) {
+ var $this
+ , $items
+ , $active
+ , $parent
+ , isActive
+ , index
+
+ if (!/(38|40|27)/.test(e.keyCode)) return
+
+ $this = $(this)
+
+ e.preventDefault()
+ e.stopPropagation()
+
+ if ($this.is('.disabled, :disabled')) return
+
+ $parent = getParent($this)
+
+ isActive = $parent.hasClass('open')
+
+ if (!isActive || (isActive && e.keyCode == 27)) {
+ if (e.which == 27) $parent.find(toggle).focus()
+ return $this.click()
+ }
+
+ $items = $('[role=menu] li:not(.divider):visible a', $parent)
+
+ if (!$items.length) return
+
+ index = $items.index($items.filter(':focus'))
+
+ if (e.keyCode == 38 && index > 0) index-- // up
+ if (e.keyCode == 40 && index < $items.length - 1) index++ // down
+ if (!~index) index = 0
+
+ $items
+ .eq(index)
+ .focus()
+ }
+
+ }
+
+ function clearMenus() {
+ $(toggle).each(function () {
+ getParent($(this)).removeClass('open')
+ })
+ }
+
+ function getParent($this) {
+ var selector = $this.attr('data-target')
+ , $parent
+
+ if (!selector) {
+ selector = $this.attr('href')
+ selector = selector && /#/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7
+ }
+
+ $parent = selector && $(selector)
+
+ if (!$parent || !$parent.length) $parent = $this.parent()
+
+ return $parent
+ }
+
+
+ /* DROPDOWN PLUGIN DEFINITION
+ * ========================== */
+
+ var old = $.fn.dropdown
+
+ $.fn.dropdown = function (option) {
+ return this.each(function () {
+ var $this = $(this)
+ , data = $this.data('dropdown')
+ if (!data) $this.data('dropdown', (data = new Dropdown(this)))
+ if (typeof option == 'string') data[option].call($this)
+ })
+ }
+
+ $.fn.dropdown.Constructor = Dropdown
+
+
+ /* DROPDOWN NO CONFLICT
+ * ==================== */
+
+ $.fn.dropdown.noConflict = function () {
+ $.fn.dropdown = old
+ return this
+ }
+
+
+ /* APPLY TO STANDARD DROPDOWN ELEMENTS
+ * =================================== */
+
+ $(document)
+ .on('click.dropdown.data-api', clearMenus)
+ .on('click.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() })
+ .on('.dropdown-menu', function (e) { e.stopPropagation() })
+ .on('click.dropdown.data-api' , toggle, Dropdown.prototype.toggle)
+ .on('keydown.dropdown.data-api', toggle + ', [role=menu]' , Dropdown.prototype.keydown)
+
+}(window.jQuery);
@@ -0,0 +1,34 @@
+//
+// Accordion
+// --------------------------------------------------
+
+
+// Parent container
+.accordion {
+ margin-bottom: @baseLineHeight;
+}
+
+// Group == heading + body
+.accordion-group {
+ margin-bottom: 2px;
+ border: 1px solid #e5e5e5;
+ .border-radius(@baseBorderRadius);
+}
+.accordion-heading {
+ border-bottom: 0;
+}
+.accordion-heading .accordion-toggle {
+ display: block;
+ padding: 8px 15px;
+}
+
+// General toggle styles
+.accordion-toggle {
+ cursor: pointer;
+}
+
+// Inner needs the styles because you can't animate properly with any styles on the element
+.accordion-inner {
+ padding: 9px 15px;
+ border-top: 1px solid #e5e5e5;
+}
@@ -0,0 +1,79 @@
+//
+// Alerts
+// --------------------------------------------------
+
+
+// Base styles
+// -------------------------
+
+.alert {
+ padding: 8px 35px 8px 14px;
+ margin-bottom: @baseLineHeight;
+ text-shadow: 0 1px 0 rgba(255,255,255,.5);
+ background-color: @warningBackground;
+ border: 1px solid @warningBorder;
+ .border-radius(@baseBorderRadius);
+}
+.alert,
+.alert h4 {
+ // Specified for the h4 to prevent conflicts of changing @headingsColor
+ color: @warningText;
+}
+.alert h4 {
+ margin: 0;
+}
+
+// Adjust close link position
+.alert .close {
+ position: relative;
+ top: -2px;
+ right: -21px;
+ line-height: @baseLineHeight;
+}
+
+
+// Alternate styles
+// -------------------------
+
+.alert-success {
+ background-color: @successBackground;
+ border-color: @successBorder;
+ color: @successText;
+}
+.alert-success h4 {
+ color: @successText;
+}
+.alert-danger,
+.alert-error {
+ background-color: @errorBackground;
+ border-color: @errorBorder;
+ color: @errorText;
+}
+.alert-danger h4,
+.alert-error h4 {
+ color: @errorText;
+}
+.alert-info {
+ background-color: @infoBackground;
+ border-color: @infoBorder;
+ color: @infoText;
+}
+.alert-info h4 {
+ color: @infoText;
+}
+
+
+// Block alerts
+// -------------------------
+
+.alert-block {
+ padding-top: 14px;
+ padding-bottom: 14px;
+}
+.alert-block > p,
+.alert-block > ul {
+ margin-bottom: 0;
+}
+.alert-block p + p {
+ margin-top: 5px;
+}
@@ -0,0 +1,63 @@
+/*!
+ * Bootstrap v2.3.0
+ *
+ * Copyright 2012 Twitter, Inc
+ * Licensed under the Apache License v2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Designed and built with all the love in the world @twitter by @mdo and @fat.
+ */
+
+// Core variables and mixins
+@import "variables.less"; // Modify this for custom colors, font-sizes, etc
+@import "mixins.less";
+
+// CSS Reset
+@import "reset.less";
+
+// Grid system and page structure
+@import "scaffolding.less";
+@import "grid.less";
+@import "layouts.less";
+
+// Base CSS
+@import "type.less";
+@import "code.less";
+@import "forms.less";
+@import "tables.less";
+
+// Components: common
+@import "sprites.less";
+@import "dropdowns.less";
+@import "wells.less";
+@import "component-animations.less";
+@import "close.less";
+
+// Components: Buttons & Alerts
+@import "buttons.less";
+@import "button-groups.less";
+@import "alerts.less"; // Note: alerts share common CSS with buttons and thus have styles in buttons.less
+
+// Components: Nav
+@import "navs.less";
+@import "navbar.less";
+@import "breadcrumbs.less";
+@import "pagination.less";
+@import "pager.less";
+
+// Components: Popovers
+@import "modals.less";
+@import "tooltip.less";
+@import "popovers.less";
+
+// Components: Misc
+@import "thumbnails.less";
+@import "media.less";
+@import "labels-badges.less";
+@import "progress-bars.less";
+@import "accordion.less";
+@import "carousel.less";
+@import "hero-unit.less";
+
+// Utility classes
+@import "utilities.less"; // Has to be last to override when necessary
@@ -0,0 +1,24 @@
+//
+// Breadcrumbs
+// --------------------------------------------------
+
+
+.breadcrumb {
+ padding: 8px 15px;
+ margin: 0 0 @baseLineHeight;
+ list-style: none;
+ background-color: #f5f5f5;
+ .border-radius(@baseBorderRadius);
+ > li {
+ display: inline-block;
+ .ie7-inline-block();
+ text-shadow: 0 1px 0 @white;
+ > .divider {
+ padding: 0 5px;
+ color: #ccc;
+ }
+ }
+ > .active {
+ color: @grayLight;
+ }
+}
Oops, something went wrong.

0 comments on commit 0b21916

Please sign in to comment.