| | 1 | // Stylesheet Guidence Notes |
| | 2 | // Table of content represents a guide to sections of the sheet. |
| | 3 | // Note that not all sections may be described in the body of the |
| | 4 | // rulesets only those that require styles for a given theme. |
| | 5 | // Sub sections might not exist but can be added as required |
| | 6 | // as per BP Lists - 'activity' section. |
| | 7 | |
| | 8 | // We follow the dictats of the parent theme in respect of media queries, |
| | 9 | // font sizing etc. Media queries are used in a modular sense (OOCSS) |
| | 10 | // rather than described as blocks to the end of the sheet, this aids ease |
| | 11 | // of managing media queries, scalability & flexibility . |
| | 12 | |
| | 13 | // Twentyfourteen Media Queries / Breakpoints |
| | 14 | //@media screen and (max-width: 400px) |
| | 15 | //@media screen and (min-width: 401px) |
| | 16 | //@media screen and (min-width: 594px) |
| | 17 | //@media screen and (min-width: 673px) |
| | 18 | //@media screen and (min-width: 783px) |
| | 19 | //@media screen and (min-width: 810px) |
| | 20 | //@media screen and (min-width: 846px) |
| | 21 | //@media screen and (min-width: 1008px) |
| | 22 | //@media screen and (min-width: 1040px) |
| | 23 | //@media screen and (min-width: 1110px) |
| | 24 | |
| | 25 | // Mixins and Variabals |
| | 26 | |
| | 27 | // Common margin values |
| | 28 | $spacing-val-lg: 40px; |
| | 29 | $spacing-val-md: 20px; |
| | 30 | $spacing-val-sm: 10px; |
| | 31 | $spacing-val-xs: 5px; |
| | 32 | |
| | 33 | // A simple mixin to handle font-sizing to match 2014 body 100% approach |
| | 34 | @mixin font-size($font-size: 16){ |
| | 35 | $RemFontValue: ($font-size / 16); |
| | 36 | font-size: ($font-size * 1px); |
| | 37 | font-size: $RemFontValue + rem; |
| | 38 | } |
| | 39 | /*-------------------------------------------------------------- |
| | 40 | |
| | 41 | This is the BuddyPress companion stylesheet for |
| | 42 | the WordPress Twentyfourteen theme. |
| | 43 | |
| | 44 | This sheet supports the primary BuddyPress styles in buddypress.css |
| | 45 | |
| | 46 | The Rulesets shadow the BP default stylesheet sectioning |
| | 47 | to maintain uniformity. |
| | 48 | |
| | 49 | ---------------------------------------------------------------- |
| | 50 | >>> TABLE OF CONTENTS: |
| | 51 | ---------------------------------------------------------------- |
| | 52 | 1.0 Theme Structural Elements |
| | 53 | 2.0 - Navigation - General |
| | 54 | 2.1 - Navs - Object Nav / Sub Nav (item-list-tabs) |
| | 55 | 2.2 - Pagination |
| | 56 | 3.0 - Images |
| | 57 | 4.0 - BP Lists / Loops Generic |
| | 58 | 4.1 - Activity Loop |
| | 59 | 4.1.1 - Activity Listing |
| | 60 | 4.1.2 - Activity Comments |
| | 61 | 4.2 - Members Loop |
| | 62 | 4.3 - Groups Loop |
| | 63 | 4.4 - Blogs Loop |
| | 64 | 5.0 - Directories - Members, Groups, Blogs, Forums |
| | 65 | 6.0 - Single Group Screens |
| | 66 | 7.0 - Single User Account Screens |
| | 67 | 7.1 - Notifications |
| | 68 | 7.2 - Private Messaging Threads |
| | 69 | 7.3 - Extended Profiles |
| | 70 | 7.4 - Settings |
| | 71 | 8.0 - Forms - General |
| | 72 | 9.0 - Tables - General |
| | 73 | 10.0 - Error / Success Messages |
| | 74 | 11.0 - Ajax Loading |
| | 75 | 12.0 - Widgets |
| | 76 | --------------------------------------------------------------*/ |
| | 77 | |
| | 78 | /*-------------------------------------------------------------- |
| | 79 | 1.0 - Theme - Structural Elements |
| | 80 | --------------------------------------------------------------*/ |
| | 81 | |
| | 82 | // As BP screens have specific content lets adjust the themes primary elements |
| | 83 | // to maximise the screen real estate for BP pages. |
| | 84 | |
| | 85 | .buddypress { |
| | 86 | .site-content { |
| | 87 | @media screen and ( min-width: 77.5em ) { |
| | 88 | } |
| | 89 | } |
| | 90 | .site-content { |
| | 91 | padding-top: 4%; |
| | 92 | @media screen and ( min-width: 59.6875em ) { |
| | 93 | padding-top: 0; |
| | 94 | } |
| | 95 | article { |
| | 96 | margin: 0 4%; |
| | 97 | padding-top: 0; |
| | 98 | .entry-header, |
| | 99 | .entry-content { |
| | 100 | max-width: 100%; |
| | 101 | padding: 0 $spacing-val-md; |
| | 102 | } |
| | 103 | #buddypress { margin-bottom: $spacing-val-lg; } |
| | 104 | } // .article |
| | 105 | } // .content |
| | 106 | |
| | 107 | } // .buddypress ( body class ) |
| | 108 | /*-------------------------------------------------------------- |
| | 109 | 2.0 - Navigation - General |
| | 110 | --------------------------------------------------------------*/ |
| | 111 | |
| | 112 | /*-------------------------------------------------------------- |
| | 113 | 2.1 - Navs - Object Nav / Sub Nav (item-list-tabs) |
| | 114 | --------------------------------------------------------------*/ |
| | 115 | /*__ Vertical menu User account screens __*/ |
| | 116 | |
| | 117 | // This block contains the rules to re-factor the item-body structural element |
| | 118 | // to sit alongside the vert menu |
| | 119 | // Structural layout and faux column styling of backgrounds is more suited |
| | 120 | // to the earlier section. todo: re-position sort out when known what styles |
| | 121 | // are being used. |
| | 122 | |
| | 123 | @media screen and (min-width: 783px) { |
| | 124 | .bp-user #buddypress { |
| | 125 | background: #eee; |
| | 126 | #item-header, #item-body {background: #fff;} |
| | 127 | #item-body {border-left: 1px solid #ddd;} |
| | 128 | #object-nav { |
| | 129 | background: #eee; |
| | 130 | border-right: 1px solid #ddd; |
| | 131 | float: left; |
| | 132 | margin-right: -1px; |
| | 133 | width: 200px; |
| | 134 | ul { |
| | 135 | border-bottom: none; |
| | 136 | padding: 0; |
| | 137 | li { |
| | 138 | float: none; |
| | 139 | overflow: hidden; |
| | 140 | span { |
| | 141 | border-radius: 10%; |
| | 142 | float: right; |
| | 143 | margin-right: 15px; |
| | 144 | } |
| | 145 | } |
| | 146 | } |
| | 147 | } |
| | 148 | #item-body { |
| | 149 | overflow: hidden; |
| | 150 | padding: 0 $spacing-val-md; |
| | 151 | width: auto; |
| | 152 | #subnav { |
| | 153 | border: 1px solid #ddd; |
| | 154 | border-left: none; |
| | 155 | border-right: none; |
| | 156 | margin: 0 (-$spacing-val-md) $spacing-val-lg; |
| | 157 | } |
| | 158 | } |
| | 159 | |
| | 160 | } // close .bp-user #buddypress |
| | 161 | } // close @media |
| | 162 | /*-------------------------------------------------------------- |
| | 163 | 2.2 - Pagination |
| | 164 | --------------------------------------------------------------*/ |
| | 165 | |
| | 166 | /*-------------------------------------------------------------- |
| | 167 | 4.0 - BP Lists / Loops Generic |
| | 168 | --------------------------------------------------------------*/ |
| | 169 | |
| | 170 | // Trying to position the action div absolute has bad consequences where |
| | 171 | // aditional items are displayed, floating an alternative but may need |
| | 172 | // to reconsider this approach. |
| | 173 | |
| | 174 | #buddypress { |
| | 175 | .dir-list { |
| | 176 | ul.item-list { |
| | 177 | li { |
| | 178 | overflow: hidden !important; // upsets me but buddypress styles over specified |
| | 179 | |
| | 180 | .action { |
| | 181 | position: relative; |
| | 182 | top: 0; |
| | 183 | div { |
| | 184 | margin: 8px 0; |
| | 185 | } |
| | 186 | } // close .action |
| | 187 | |
| | 188 | @media screen and (min-width: 401px) { |
| | 189 | .item { |
| | 190 | float: left; |
| | 191 | .item-desc { |
| | 192 | margin-left: 20%; |
| | 193 | width: auto; |
| | 194 | } |
| | 195 | } |
| | 196 | .action { |
| | 197 | float: right; |
| | 198 | // margin-top: -50px; |
| | 199 | div {margin: 8px 0;} |
| | 200 | } |
| | 201 | } // close @media |
| | 202 | |
| | 203 | } // close li |
| | 204 | } // ul.item-list |
| | 205 | } // close .dir-list |
| | 206 | |
| | 207 | } // close #budypress |
| | 208 | |
| | 209 | /*-------------------------------------------------------------- |
| | 210 | 4.1 - Activity |
| | 211 | --------------------------------------------------------------*/ |
| | 212 | |
| | 213 | /*-------------------------------------------------------------- |
| | 214 | 4.1.2 - Activity Whats New |
| | 215 | --------------------------------------------------------------*/ |
| | 216 | |
| | 217 | /*-------------------------------------------------------------- |
| | 218 | 4.1.2 - Activity Listing |
| | 219 | --------------------------------------------------------------*/ |
| | 220 | |
| | 221 | /*-------------------------------------------------------------- |
| | 222 | 8.0 - Forms - General |
| | 223 | --------------------------------------------------------------*/ |
| | 224 | #buddypress { |
| | 225 | div.dir-search, |
| | 226 | div.message-search { |
| | 227 | float: none; |
| | 228 | margin: $spacing-val-sm 0; |
| | 229 | |
| | 230 | // Stylise the seach form elements, in part this deals with padding |
| | 231 | // issues on the submit & sizing issues between bp styles & twentyfifteen |
| | 232 | form { // *sigh* only to bludgeon over specified rules |
| | 233 | border: 1px solid #ccc; |
| | 234 | overflow: hidden; |
| | 235 | label { |
| | 236 | float: left; |
| | 237 | width: 80%; |
| | 238 | } |
| | 239 | input[type='text'] { |
| | 240 | float: left; |
| | 241 | width: 100%; |
| | 242 | margin: 0; |
| | 243 | } |
| | 244 | input[type='text'], |
| | 245 | input[type='submit'] { |
| | 246 | border: none; |
| | 247 | @include font-size(14); |
| | 248 | line-height: inherit; |
| | 249 | } |
| | 250 | input[type='text'] { |
| | 251 | border-right: 1px solid #ccc; |
| | 252 | padding: .2em 0 .2em .2em; |
| | 253 | } |
| | 254 | input[type='submit'] { |
| | 255 | font-weight: normal; |
| | 256 | float: right; |
| | 257 | padding: .2em 1em; |
| | 258 | text-align: center; |
| | 259 | text-transform: none; |
| | 260 | width: 20%; |
| | 261 | } |
| | 262 | }// close form |
| | 263 | |
| | 264 | } // close .dir-search, .message-search |
| | 265 | |
| | 266 | // Shift the search parent to the right and allow to shrinkwrap |
| | 267 | @media screen and (min-width: 401px) { |
| | 268 | div.dir-search, |
| | 269 | div.message-search { |
| | 270 | float: right; |
| | 271 | margin: 0 ; |
| | 272 | form { |
| | 273 | label, |
| | 274 | input[type='submit'], |
| | 275 | input[type='text'] { |
| | 276 | width: auto; |
| | 277 | } |
| | 278 | } |
| | 279 | } |
| | 280 | div.message-search { margin-top: 2px;} |
| | 281 | } // close @media |
| | 282 | |
| | 283 | } // close #buddypress |
| | 284 | |
| | 285 | /*-------------------------------------------------------------- |
| | 286 | 9.0 - Tables - General |
| | 287 | --------------------------------------------------------------*/ |
| | 288 | |
| | 289 | /*__ User Account tables __*/ |
| | 290 | No newline at end of file |