annotate core/misc/dialog/off-canvas.dropbutton.css @ 0:c75dbcec494b

Initial commit from drush-created site
author Chris Cannam
date Thu, 05 Jul 2018 14:24:15 +0000
parents
children 12f9dff5fda9
rev   line source
Chris@0 1 /**
Chris@0 2 * @file
Chris@0 3 * Styles for dropbuttons in the off-canvas dialog.
Chris@0 4 */
Chris@0 5
Chris@0 6 #drupal-off-canvas .dropbutton-wrapper,
Chris@0 7 #drupal-off-canvas .dropbutton-widget {
Chris@0 8 -webkit-appearance: none;
Chris@0 9 -moz-appearance: none;
Chris@0 10 display: block;
Chris@0 11 position: static;
Chris@0 12 transition: none;
Chris@0 13 }
Chris@0 14 #drupal-off-canvas .dropbutton-widget {
Chris@0 15 margin: 0;
Chris@0 16 padding: 0;
Chris@0 17 border: 0;
Chris@0 18 background: #277abd;
Chris@0 19 border-radius: 1em;
Chris@0 20 font-weight: 600;
Chris@0 21 color: #fff;
Chris@0 22 text-transform: none;
Chris@0 23 text-decoration: none;
Chris@0 24 text-align: center;
Chris@0 25 line-height: normal;
Chris@0 26 cursor: pointer;
Chris@0 27 transition: background 0.5s ease;
Chris@0 28 }
Chris@0 29 #drupal-off-canvas .dropbutton-widget:hover {
Chris@0 30 background: #2b8bd8;
Chris@0 31 }
Chris@0 32
Chris@0 33 /*
Chris@0 34 * Style dropbutton single.
Chris@0 35 */
Chris@0 36
Chris@0 37 #drupal-off-canvas .dropbutton-single .dropbutton-action a {
Chris@0 38 padding: 0;
Chris@0 39 /* Overlap icon for trigger. */
Chris@0 40 margin-top: -2em;
Chris@0 41 height: 2.2em;
Chris@0 42 cursor: pointer;
Chris@0 43 }
Chris@0 44 #drupal-off-canvas .dropbutton-single .dropbutton-action:hover,
Chris@0 45 #drupal-off-canvas .dropbutton-single .dropbutton-action:focus,
Chris@0 46 #drupal-off-canvas .dropbutton-single .dropbutton-action a:hover,
Chris@0 47 #drupal-off-canvas .dropbutton-single .dropbutton-action a:focus {
Chris@0 48 text-decoration: none;
Chris@0 49 outline: none;
Chris@0 50 }
Chris@0 51 #drupal-off-canvas .dropbutton-widget .dropbutton {
Chris@0 52 margin: 0;
Chris@0 53 overflow: hidden;
Chris@0 54 padding: 0;
Chris@0 55 }
Chris@0 56 #drupal-off-canvas .dropbutton li,
Chris@0 57 #drupal-off-canvas .dropbutton a {
Chris@0 58 display: block;
Chris@0 59 width: auto;
Chris@0 60 padding: 4px 0;
Chris@0 61 text-align: left;
Chris@0 62 color: #555;
Chris@0 63 outline: none;
Chris@0 64 }
Chris@0 65 #drupal-off-canvas .dropbutton li:hover,
Chris@0 66 #drupal-off-canvas .dropbutton li:focus,
Chris@0 67 #drupal-off-canvas .dropbutton a:hover,
Chris@0 68 #drupal-off-canvas .dropbutton a:focus {
Chris@0 69 background: transparent;
Chris@0 70 color: #333;
Chris@0 71 outline: none;
Chris@0 72 }
Chris@0 73
Chris@0 74 /*
Chris@0 75 * Style dropbutton multiple.
Chris@0 76 */
Chris@0 77
Chris@0 78 #drupal-off-canvas .dropbutton-multiple .dropbutton-widget {
Chris@0 79 width: 2em;
Chris@0 80 height: 2em;
Chris@0 81 }
Chris@0 82 #drupal-off-canvas .dropbutton-multiple .dropbutton-widget:hover {
Chris@0 83 background-color: #2b8bd8;
Chris@0 84 }
Chris@0 85
Chris@0 86 /* Hide the other actions until the dropbutton is triggered. */
Chris@0 87 #drupal-off-canvas .dropbutton-multiple .dropbutton .secondary-action {
Chris@0 88 display: none;
Chris@0 89 }
Chris@0 90
Chris@0 91 /* The toggle to expand the button. */
Chris@0 92 #drupal-off-canvas .dropbutton-toggle {
Chris@0 93 position: absolute;
Chris@0 94 top: 0;
Chris@0 95 right: 0; /* LTR */
Chris@0 96 bottom: 0;
Chris@0 97 display: block;
Chris@0 98 width: 2em;
Chris@0 99 color: #fff;
Chris@0 100 text-indent: 110%;
Chris@0 101 white-space: nowrap;
Chris@0 102 }
Chris@0 103 #drupal-off-canvas .dropbutton-toggle button {
Chris@0 104 display: block;
Chris@0 105 height: 100%;
Chris@0 106 width: 100%;
Chris@0 107 margin: 0;
Chris@0 108 padding: 0;
Chris@0 109 border: 0 solid transparent;
Chris@0 110 border-bottom-right-radius: 1em; /* LTR */
Chris@0 111 border-top-right-radius: 1em; /* LTR */
Chris@0 112 cursor: pointer;
Chris@0 113 }
Chris@0 114 #drupal-off-canvas .dropbutton-toggle button:hover,
Chris@0 115 #drupal-off-canvas .dropbutton-toggle button:focus {
Chris@0 116 outline: none;
Chris@0 117 }
Chris@0 118
Chris@0 119 /* The toggle arrow. */
Chris@0 120 #drupal-off-canvas .dropbutton-arrow {
Chris@0 121 position: absolute;
Chris@0 122 display: block;
Chris@0 123 height: 0;
Chris@0 124 width: 0;
Chris@0 125 margin-top: 0;
Chris@0 126 border-bottom-color: transparent;
Chris@0 127 border-left-color: transparent;
Chris@0 128 border-right-color: transparent;
Chris@0 129 border-style: solid;
Chris@0 130 border-width: 0.3333em 0.3333em 0;
Chris@0 131 color: #fff;
Chris@0 132 line-height: 0;
Chris@0 133 overflow: hidden;
Chris@0 134 }
Chris@0 135 #drupal-off-canvas span.dropbutton-arrow {
Chris@0 136 top: 7px;
Chris@0 137 right: 7px; /* LTR */
Chris@0 138 background: transparent;
Chris@0 139 }
Chris@0 140 #drupal-off-canvas span.dropbutton-arrow:hover {
Chris@0 141 background: transparent;
Chris@0 142 }
Chris@0 143
Chris@0 144 #drupal-off-canvas .dropbutton-action > .js-form-submit.form-submit,
Chris@0 145 #drupal-off-canvas .dropbutton-toggle button {
Chris@0 146 position: relative;
Chris@0 147 text-shadow: none;
Chris@0 148 }
Chris@0 149
Chris@0 150 /*
Chris@0 151 * Dropbuttons when in a table cell.
Chris@0 152 */
Chris@0 153
Chris@0 154 /* Make sure table cell doesn't collapse around absolute positioned dropbutton. */
Chris@0 155 #drupal-off-canvas td .dropbutton-single {
Chris@0 156 min-width: 2em;
Chris@0 157 }
Chris@0 158 #drupal-off-canvas td .dropbutton-multiple {
Chris@0 159 min-width: 2em;
Chris@0 160 padding-right: 0;
Chris@0 161 padding-left: 0;
Chris@0 162 margin-right: 0;
Chris@0 163 margin-left: 0;
Chris@0 164 border: 0;
Chris@0 165 }
Chris@0 166 #drupal-off-canvas td .dropbutton-multiple .dropbutton-action a,
Chris@0 167 #drupal-off-canvas td .dropbutton-multiple .dropbutton-action input,
Chris@0 168 #drupal-off-canvas td .dropbutton-multiple .dropbutton-action button {
Chris@0 169 width: auto;
Chris@0 170 padding: 0;
Chris@0 171 font-size: inherit;
Chris@0 172 }
Chris@0 173 #drupal-off-canvas td .dropbutton-wrapper {
Chris@0 174 margin-bottom: 0;
Chris@0 175 }
Chris@0 176
Chris@0 177 /* Push the widget to the right so text expands left. */
Chris@0 178 #drupal-off-canvas td .dropbutton-widget {
Chris@0 179 position: absolute;
Chris@0 180 right: 12px; /* LTR */
Chris@0 181 padding: 0;
Chris@0 182 background: #277abd none;
Chris@0 183 }
Chris@0 184
Chris@0 185 /* Push the wrapper to the right edge of the td. */
Chris@0 186 #drupal-off-canvas td .dropbutton-single,
Chris@0 187 #drupal-off-canvas td .dropbutton-multiple {
Chris@0 188 float: right; /* LTR */
Chris@0 189 padding-right: 0;
Chris@0 190 margin-right: 0;
Chris@0 191 max-width: initial;
Chris@0 192 min-width: initial;
Chris@0 193 position: relative;
Chris@0 194 }
Chris@0 195 #drupal-off-canvas td .dropbutton-widget .dropbutton {
Chris@0 196 margin: 0;
Chris@0 197 width: 2em;
Chris@0 198 height: 2em;
Chris@0 199 overflow: hidden;
Chris@0 200 background: transparent;
Chris@0 201 }
Chris@0 202
Chris@0 203 /* Push text out of the way. */
Chris@0 204 #drupal-off-canvas td .dropbutton-multiple li,
Chris@0 205 #drupal-off-canvas td .dropbutton-multiple a {
Chris@0 206 margin-left: -9999px;
Chris@0 207 background: transparent;
Chris@0 208 }
Chris@0 209 #drupal-off-canvas td .dropbutton-multiple.open .dropbutton li,
Chris@0 210 #drupal-off-canvas td .dropbutton-multiple.open .dropbutton a {
Chris@0 211 margin-left: 0;
Chris@0 212 width: auto;
Chris@0 213 color: #fff;
Chris@0 214 }
Chris@0 215
Chris@0 216 /* Collapse the button to a circle. */
Chris@0 217 #drupal-off-canvas td .dropbutton-toggle {
Chris@0 218 width: 2em;
Chris@0 219 height: 2em;
Chris@0 220 border-radius: 1em;
Chris@0 221 }
Chris@0 222 #drupal-off-canvas td .dropbutton-wrapper .dropbutton-widget .dropbutton-toggle button {
Chris@0 223 border: 0;
Chris@0 224 background: transparent;
Chris@0 225 }
Chris@0 226
Chris@0 227 /* Prevent list item from expanding its container. */
Chris@0 228 #drupal-off-canvas td ul.dropbutton li.edit {
Chris@0 229 width: 2em;
Chris@0 230 height: 2em;
Chris@0 231 }
Chris@0 232
Chris@0 233 /* Make li text transparent above icon so it's clickable. */
Chris@0 234 #drupal-off-canvas td .dropbutton-single li.edit.dropbutton-action > a {
Chris@0 235 color: transparent;
Chris@0 236 z-index: 1;
Chris@0 237 }
Chris@0 238
Chris@0 239 /* Put pencil icon in place of hidden 'edit' text on single buttons. */
Chris@0 240 #drupal-off-canvas td .dropbutton-single .edit:before {
Chris@0 241 content: '.';
Chris@0 242 display: block;
Chris@0 243 color: transparent;
Chris@0 244 background: transparent url(../icons/ffffff/pencil.svg) no-repeat center;
Chris@0 245 background-size: 14px;
Chris@0 246 }
Chris@0 247
Chris@0 248 /* Dropbutton when triggered expands to show secondary items. */
Chris@0 249 #drupal-off-canvas .dropbutton-multiple.open {
Chris@0 250 z-index: 100;
Chris@0 251 }
Chris@0 252
Chris@0 253 /* Create visual separation if there is an adjacent button. */
Chris@0 254 #drupal-off-canvas .dropbutton-multiple.open .dropbutton-widget {
Chris@0 255 box-shadow: 0 3px 3px 2px rgba(0, 0, 0, 0.5);
Chris@0 256 }
Chris@0 257
Chris@0 258 /* Triggered dropbutton expands to show secondary items. */
Chris@0 259 #drupal-off-canvas .dropbutton-multiple.open,
Chris@0 260 #drupal-off-canvas .dropbutton-multiple.open .dropbutton-widget {
Chris@0 261 display: block;
Chris@0 262 width: auto;
Chris@0 263 height: auto;
Chris@0 264 max-width: none;
Chris@0 265 min-width: 0;
Chris@0 266 padding: 0;
Chris@0 267 overflow: visible;
Chris@0 268 }
Chris@0 269
Chris@0 270 /* Triggered dropbutton in td expands to show secondary items. */
Chris@0 271 #drupal-off-canvas td .dropbutton-multiple.open .dropbutton,
Chris@0 272 #drupal-off-canvas .dropbutton-multiple.open .dropbutton .secondary-action {
Chris@0 273 display: block;
Chris@0 274 width: auto;
Chris@0 275 height: auto;
Chris@0 276 padding-right: 1em; /* LTR */
Chris@0 277 }
Chris@0 278 [dir="rtl"] #drupal-off-canvas td .dropbutton-multiple.open .dropbutton {
Chris@0 279 padding-left: 1em;
Chris@0 280 padding-right: inherit;
Chris@0 281 }
Chris@0 282 #drupal-off-canvas .dropbutton-multiple.open .dropbutton li a {
Chris@0 283 padding: 2px 1em;
Chris@0 284 }
Chris@0 285
Chris@0 286 /* When open, the toggle arrow points upward. */
Chris@0 287 #drupal-off-canvas .dropbutton-multiple.open span.dropbutton-arrow {
Chris@0 288 border-bottom: 0.3333em solid;
Chris@0 289 border-top-color: transparent;
Chris@0 290 top: 2px;
Chris@0 291 }