widgets.css (17521B)
1 /* General Widgets Styles */ 2 3 .widget { 4 margin: 0 auto 10px; 5 position: relative; 6 box-sizing: border-box; 7 } 8 9 .widget.open { 10 z-index: 99; 11 } 12 .widget.open:focus-within { 13 z-index: 100; 14 } 15 16 .widget-top { 17 font-size: 13px; 18 font-weight: 600; 19 background: #f6f7f7; 20 } 21 22 .widget-top .widget-action { 23 border: 0; 24 margin: 0; 25 padding: 10px; 26 background: none; 27 cursor: pointer; 28 } 29 30 .widget-title h3, 31 .widget-title h4 { 32 margin: 0; 33 padding: 15px; 34 font-size: 1em; 35 line-height: 1; 36 overflow: hidden; 37 white-space: nowrap; 38 text-overflow: ellipsis; 39 -webkit-user-select: none; 40 user-select: none; 41 } 42 43 .widgets-holder-wrap .widget-inside { 44 border-top: none; 45 padding: 1px 15px 15px 15px; 46 line-height: 1.23076923; 47 } 48 49 .widget.widget-dirty .widget-control-close-wrapper { 50 display: none; 51 } 52 53 .in-widget-title, 54 #widgets-right a.widget-control-edit, 55 #available-widgets .widget-description { 56 color: #646970; 57 } 58 59 .deleting .widget-title, 60 .deleting .widget-top .widget-action .toggle-indicator:before { 61 color: #a7aaad; 62 } 63 64 /* Media Widgets */ 65 .wp-core-ui .media-widget-control.selected .placeholder, 66 .wp-core-ui .media-widget-control.selected .not-selected, 67 .wp-core-ui .media-widget-control .selected { 68 display: none; 69 } 70 71 .media-widget-control.selected .selected { 72 display: inline-block; 73 } 74 75 .media-widget-buttons { 76 text-align: left; 77 margin-top: 0; 78 } 79 80 .media-widget-control .media-widget-buttons .button { 81 width: auto; 82 height: auto; 83 margin-top: 12px; 84 white-space: normal; 85 } 86 87 .media-widget-buttons .button:first-child { 88 margin-right: 8px; 89 } 90 91 .media-widget-control .attachment-media-view .button-add-media, 92 .media-widget-control .placeholder { 93 border: 1px dashed #c3c4c7; 94 box-sizing: border-box; 95 cursor: pointer; 96 line-height: 1.6; 97 padding: 9px 0; 98 position: relative; 99 text-align: center; 100 width: 100%; 101 } 102 103 .media-widget-control .attachment-media-view .button-add-media { 104 cursor: pointer; 105 background-color: #f0f0f1; 106 color: #2c3338; 107 } 108 109 .media-widget-control .attachment-media-view .button-add-media:hover { 110 background-color: #fff; 111 } 112 113 .media-widget-control .attachment-media-view .button-add-media:focus { 114 background-color: #fff; 115 border-style: solid; 116 border-color: #4f94d4; 117 box-shadow: 0 0 3px rgba(34, 113, 177, 0.8); 118 /* Only visible in Windows High Contrast mode */ 119 outline: 2px solid transparent; 120 outline-offset: -2px; 121 } 122 123 .media-widget-control .media-widget-preview { 124 background: transparent; 125 text-align: center; 126 } 127 .media-widget-control .media-widget-preview .notice { 128 text-align: initial; 129 } 130 .media-frame .media-widget-embed-notice p code, 131 .media-widget-control .notice p code { 132 padding: 0 3px 0 0; 133 } 134 .media-frame .media-widget-embed-notice { 135 margin-top: 16px; 136 } 137 .media-widget-control .media-widget-preview img { 138 max-width: 100%; 139 vertical-align: middle; 140 background-image: linear-gradient(45deg, #c3c4c7 25%, transparent 25%, transparent 75%, #c3c4c7 75%, #c3c4c7), linear-gradient(45deg, #c3c4c7 25%, transparent 25%, transparent 75%, #c3c4c7 75%, #c3c4c7); 141 background-position: 0 0, 10px 10px; 142 background-size: 20px 20px; 143 } 144 .media-widget-control .media-widget-preview .wp-video-shortcode { 145 background: #000; 146 } 147 148 .media-frame.media-widget .media-toolbar-secondary { 149 min-width: 300px; 150 } 151 152 .media-frame.media-widget .image-details .embed-media-settings .setting.align, 153 .media-frame.media-widget .attachment-display-settings .setting.align, 154 .media-frame.media-widget .embed-media-settings .setting.align, 155 .media-frame.media-widget .embed-media-settings .legend-inline, 156 .media-frame.media-widget .embed-link-settings .setting.link-text, 157 .media-frame.media-widget .replace-attachment, 158 .media-frame.media-widget .checkbox-setting.autoplay { 159 display: none; 160 } 161 162 .media-widget-video-preview { 163 width: 100%; 164 } 165 166 .media-widget-video-link { 167 display: inline-block; 168 min-height: 132px; 169 width: 100%; 170 background: #000; 171 } 172 173 .media-widget-video-link .dashicons { 174 font: normal 60px/1 'dashicons'; 175 position: relative; 176 width: 100%; 177 top: -90px; 178 color: #fff; 179 text-decoration: none; 180 } 181 182 .media-widget-video-link.no-poster .dashicons { 183 top: 30px; 184 } 185 186 .media-frame #embed-url-field.invalid, 187 .media-widget-image-link > .link:invalid { 188 border: 1px solid #d63638; 189 } 190 191 .media-widget-image-link { 192 margin: 1em 0; 193 } 194 195 .media-widget-gallery-preview { 196 display: flex; 197 justify-content: flex-start; 198 flex-wrap: wrap; 199 margin: -1.79104477%; 200 } 201 202 .media-widget-preview.media_gallery, 203 .media-widget-preview.media_image { 204 cursor: pointer; 205 } 206 207 .media-widget-preview .placeholder { 208 background: #f0f0f1; 209 } 210 211 .media-widget-gallery-preview .gallery-item { 212 box-sizing: border-box; 213 width: 50%; 214 margin: 0; 215 background: transparent; 216 } 217 218 .media-widget-gallery-preview .gallery-item .gallery-icon { 219 margin: 4.5%; 220 } 221 222 /* 223 * Use targeted nth-last-child selectors to control the size of each image 224 * based on how many gallery items are present in the grid. 225 * See: https://alistapart.com/article/quantity-queries-for-css 226 */ 227 .media-widget-gallery-preview .gallery-item:nth-last-child(3):first-child, 228 .media-widget-gallery-preview .gallery-item:nth-last-child(3):first-child ~ .gallery-item, 229 .media-widget-gallery-preview .gallery-item:nth-last-child(n+5), 230 .media-widget-gallery-preview .gallery-item:nth-last-child(n+5) ~ .gallery-item, 231 .media-widget-gallery-preview .gallery-item:nth-last-child(n+6), 232 .media-widget-gallery-preview .gallery-item:nth-last-child(n+6) ~ .gallery-item { 233 max-width: 33.33%; 234 } 235 236 .media-widget-gallery-preview .gallery-item img { 237 height: auto; 238 vertical-align: bottom; 239 } 240 241 .media-widget-gallery-preview .gallery-icon { 242 position: relative; 243 } 244 245 .media-widget-gallery-preview .gallery-icon-placeholder { 246 position: absolute; 247 top: 0; 248 bottom: 0; 249 width: 100%; 250 box-sizing: border-box; 251 display: flex; 252 align-items: center; 253 justify-content: center; 254 background-color: rgba(0, 0, 0, 0.5); 255 } 256 257 .media-widget-gallery-preview .gallery-icon-placeholder-text { 258 font-weight: 600; 259 font-size: 2em; 260 color: #fff; 261 } 262 263 264 /* Widget Dragging Helpers */ 265 .widget.ui-draggable-dragging { 266 min-width: 100%; 267 } 268 269 .widget.ui-sortable-helper { 270 opacity: 0.8; 271 } 272 273 .widget-placeholder { 274 border: 1px dashed #c3c4c7; 275 margin: 0 auto 10px; 276 height: 45px; 277 width: 100%; 278 box-sizing: border-box; 279 } 280 281 #widgets-right .widget-placeholder { 282 margin-top: 0; 283 } 284 285 #widgets-right .closed .widget-placeholder { 286 height: 0; 287 border: 0; 288 margin-top: -10px; 289 } 290 291 /* Widget Sidebars */ 292 .sidebar-name { 293 position: relative; 294 box-sizing: border-box; 295 } 296 297 .js .sidebar-name { 298 cursor: pointer; 299 } 300 301 .sidebar-name .handlediv { 302 float: right; 303 width: 38px; 304 height: 38px; 305 border: 0; 306 margin: 0; 307 padding: 8px; 308 background: none; 309 cursor: pointer; 310 outline: none; 311 } 312 313 #widgets-right .sidebar-name .handlediv { 314 margin: 5px 3px 0 0; 315 } 316 317 .sidebar-name .handlediv:focus { 318 box-shadow: none; 319 /* Only visible in Windows High Contrast mode */ 320 outline: 1px solid transparent; 321 } 322 323 #widgets-left .sidebar-name .toggle-indicator { 324 display: none; 325 } 326 327 #widgets-left .widgets-holder-wrap.closed .sidebar-name .toggle-indicator, 328 #widgets-left .sidebar-name:hover .toggle-indicator, 329 #widgets-left .sidebar-name .handlediv:focus .toggle-indicator { 330 display: block; 331 } 332 333 .sidebar-name .toggle-indicator:before { 334 padding: 1px 2px 1px 0; 335 border-radius: 50%; 336 } 337 338 .sidebar-name .handlediv:focus .toggle-indicator:before { 339 box-shadow: 340 0 0 0 1px #4f94d4, 341 0 0 2px 1px rgba(79, 148, 212, 0.8); 342 } 343 344 .sidebar-name h2, 345 .sidebar-name h3 { 346 margin: 0; 347 padding: 8px 10px; 348 overflow: hidden; 349 white-space: nowrap; 350 } 351 352 .widgets-holder-wrap .description { 353 padding: 0 0 15px; 354 margin: 0; 355 font-style: normal; 356 color: #646970; 357 } 358 359 .widget-holder .description, 360 .inactive-sidebar .description { 361 color: #50575e; 362 } 363 364 #widgets-right .widgets-holder-wrap .description { 365 padding-left: 7px; 366 padding-right: 7px; 367 } 368 369 /* Widgets 2-col Layout */ 370 div.widget-liquid-left { 371 margin: 0; 372 width: 38%; 373 float: left; 374 } 375 376 div.widget-liquid-right { 377 float: right; 378 width: 58%; 379 } 380 381 /* Widgets Left - Available Widgets */ 382 383 div#widgets-left { 384 padding-top: 12px; 385 } 386 387 div#widgets-left .closed .sidebar-name, 388 div#widgets-left .inactive-sidebar.closed .sidebar-name { 389 margin-bottom: 10px; 390 } 391 392 div#widgets-left .sidebar-name h2, 393 div#widgets-left .sidebar-name h3 { 394 padding: 10px 0; 395 margin: 0 10px 0 0; 396 } 397 398 #widgets-left .widgets-holder-wrap, 399 div#widgets-left .widget-holder { 400 background: transparent; 401 border: none; 402 } 403 404 #widgets-left .widgets-holder-wrap { 405 border: none; 406 box-shadow: none; 407 } 408 409 #available-widgets .widget { 410 margin: 0; 411 } 412 413 #available-widgets .widget:nth-child(odd) { 414 clear: both; 415 } 416 417 #available-widgets .widget .widget-description { 418 display: block; 419 padding: 10px 15px; 420 font-size: 12px; 421 overflow-wrap: break-word; 422 word-wrap: break-word; 423 -ms-word-break: break-all; 424 word-break: break-word; 425 -webkit-hyphens: auto; 426 hyphens: auto; 427 } 428 429 #available-widgets #widget-list { 430 position: relative; 431 } 432 433 /* Inactive Sidebars */ 434 #widgets-left .inactive-sidebar { 435 clear: both; 436 width: 100%; 437 background: transparent; 438 padding: 0; 439 margin: 0 0 20px 0; 440 border: none; 441 box-shadow: none; 442 } 443 444 #widgets-left .inactive-sidebar.first { 445 margin-top: 40px; 446 } 447 448 /* Not sure what this is for... */ 449 div#widgets-left .inactive-sidebar .widget.expanded { 450 left: auto; 451 } 452 453 .widget-title-action { 454 float: right; 455 position: relative; 456 } 457 458 div#widgets-left .inactive-sidebar .widgets-sortables { 459 min-height: 42px; 460 padding: 0; 461 background: transparent; 462 margin: 0; 463 position: relative; 464 } 465 466 /* Widgets Right */ 467 468 div#widgets-right .sidebars-column-1, 469 div#widgets-right .sidebars-column-2 { 470 max-width: 450px; 471 } 472 473 div#widgets-right .widgets-holder-wrap { 474 margin: 10px 0 0 0; 475 } 476 477 div#widgets-right .sidebar-description { 478 min-height: 20px; 479 margin-top: -5px; 480 } 481 482 div#widgets-right .sidebar-name h2, 483 div#widgets-right .sidebar-name h3 { 484 padding: 15px 7px; 485 } 486 487 div#widgets-right .widget-top { 488 padding: 0; 489 } 490 491 div#widgets-right .widgets-sortables { 492 padding: 0 8px; 493 margin-bottom: 9px; 494 position: relative; 495 min-height: 123px; 496 } 497 498 div#widgets-right .closed .widgets-sortables { 499 min-height: 0; 500 margin-bottom: 0; 501 } 502 503 .sidebar-name .spinner, 504 .remove-inactive-widgets .spinner { 505 float: none; 506 position: relative; 507 top: -2px; 508 margin: -5px 5px; 509 } 510 511 /* Dragging a widget over a closed sidebar */ 512 #widgets-right .widgets-holder-wrap.widget-hover { 513 border-color: #787c82; 514 box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3); 515 } 516 517 /* Accessibility Mode */ 518 .widget-access-link { 519 float: right; 520 margin: -5px 0 10px 10px; 521 } 522 523 .widgets_access #widgets-left .widget .widget-top { 524 cursor: auto; 525 } 526 527 .widgets_access #wpwrap .widgets-holder-wrap.closed .sidebar-description, 528 .widgets_access #wpwrap .widgets-holder-wrap.closed .widget, 529 .widgets_access #wpwrap .widget-control-edit { 530 display: block; 531 } 532 533 .widgets_access #widgets-left .widget .widget-top:hover, 534 .widgets_access #widgets-right .widget .widget-top:hover { 535 border-color: #dcdcde; 536 } 537 538 #available-widgets .widget-control-edit .edit, 539 #available-widgets .widget-action .edit, 540 #widgets-left .inactive-sidebar .widget-control-edit .add, 541 #widgets-left .inactive-sidebar .widget-action .add, 542 #widgets-right .widget-control-edit .add, 543 #widgets-right .widget-action .add { 544 display: none; 545 } 546 547 .widget-control-edit { 548 display: block; 549 color: #646970; 550 background: #f0f0f1; 551 padding: 0 15px; 552 line-height: 3.30769230; 553 border-left: 1px solid #dcdcde; 554 } 555 556 #widgets-left .widget-control-edit:hover, 557 #widgets-right .widget-control-edit:hover { 558 color: #fff; 559 background: #3c434a; 560 border-left: 0; 561 outline: 1px solid #3c434a; 562 } 563 564 .widgets-holder-wrap .sidebar-name, 565 .widgets-holder-wrap .sidebar-description { 566 -webkit-user-select: none; 567 user-select: none; 568 } 569 570 .editwidget { 571 margin: 0 auto; 572 } 573 574 .editwidget .widget-inside { 575 display: block; 576 padding: 0 15px; 577 } 578 579 .editwidget .widget-control-actions { 580 margin-top: 20px; 581 } 582 583 .js .widgets-holder-wrap.closed .widget, 584 .js .widgets-holder-wrap.closed .sidebar-description, 585 .js .widgets-holder-wrap.closed .remove-inactive-widgets, 586 .js .widgets-holder-wrap.closed .description, 587 .js .closed br.clear { 588 display: none; 589 } 590 591 .js .widgets-holder-wrap.closed .widget.ui-sortable-helper { 592 display: block; 593 } 594 595 /* Hide Widget Settings by Default */ 596 .widget-inside, 597 .widget-description { 598 display: none; 599 } 600 601 .widget-inside { 602 background: #fff; 603 } 604 605 .widget-inside select { 606 max-width: 100%; 607 } 608 609 /* Dragging widgets over the available widget area show's a "Deactivate" message */ 610 #removing-widget { 611 display: none; 612 font-weight: 400; 613 padding-left: 15px; 614 font-size: 12px; 615 line-height: 1; 616 color: #000; 617 } 618 619 .js #removing-widget { 620 color: #72aee6; 621 } 622 623 .widget-control-noform, 624 #access-off, 625 .widgets_access .widget-action, 626 .widgets_access .handlediv, 627 .widgets_access #access-on, 628 .widgets_access .widget-holder .description, 629 .no-js .widget-holder .description { 630 display: none; 631 } 632 633 .widgets_access .widget-holder, 634 .widgets_access #widget-list { 635 padding-top: 10px; 636 } 637 638 .widgets_access #access-off { 639 display: inline; 640 } 641 642 .widgets_access .sidebar-name, 643 .widgets_access .widget .widget-top { 644 cursor: default; 645 } 646 647 648 /* Widgets Area Chooser */ 649 .widget-liquid-left #widgets-left.chooser #available-widgets .widget, 650 .widget-liquid-left #widgets-left.chooser .inactive-sidebar { 651 transition: opacity 0.1s linear; 652 } 653 654 .widget-liquid-left #widgets-left.chooser #available-widgets .widget, 655 .widget-liquid-left #widgets-left.chooser .inactive-sidebar { 656 /* -webkit-filter: blur(1px); */ 657 opacity: 0.2; 658 pointer-events: none; 659 } 660 661 .widget-liquid-left #widgets-left.chooser #available-widgets .widget-in-question { 662 /* -webkit-filter: none; */ 663 opacity: 1; 664 pointer-events: auto; 665 } 666 667 .widgets-chooser ul, 668 #widgets-left .widget-in-question .widget-top, 669 #available-widgets .widget-top:hover, 670 div#widgets-right .widget-top:hover, 671 #widgets-left .widget-top:hover { 672 border-color: #8c8f94; 673 box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1); 674 } 675 676 .widgets-chooser ul.widgets-chooser-sidebars { 677 margin: 0; 678 list-style-type: none; 679 max-height: 300px; 680 overflow: auto; 681 } 682 683 .widgets-chooser { 684 display: none; 685 } 686 687 .widgets-chooser ul { 688 border: 1px solid #c3c4c7; 689 } 690 691 .widgets-chooser li { 692 border-bottom: 1px solid #c3c4c7; 693 background: #fff; 694 margin: 0; 695 position: relative; 696 } 697 698 .widgets-chooser .widgets-chooser-button { 699 width: 100%; 700 padding: 10px 15px 10px 35px; 701 background: transparent; 702 border: 0; 703 box-sizing: border-box; 704 text-align: left; 705 cursor: pointer; 706 transition: background 0.2s ease-in-out; 707 } 708 709 /* @todo looks like these hover/focus states are overridden by .widgets-chooser-selected */ 710 .widgets-chooser .widgets-chooser-button:hover, 711 .widgets-chooser .widgets-chooser-button:focus { 712 outline: none; 713 text-decoration: underline; 714 } 715 716 .widgets-chooser li:last-child { 717 border: none; 718 } 719 720 .widgets-chooser .widgets-chooser-selected .widgets-chooser-button { 721 background: #2271b1; 722 color: #fff; 723 } 724 725 .widgets-chooser .widgets-chooser-selected:before { 726 content: "\f147"; 727 display: block; 728 -webkit-font-smoothing: antialiased; 729 font: normal 26px/1 dashicons; 730 color: #fff; 731 position: absolute; 732 top: 7px; 733 left: 5px; 734 } 735 736 .widgets-chooser .widgets-chooser-actions { 737 padding: 10px 0 12px 0; 738 text-align: center; 739 } 740 741 #available-widgets .widget .widget-top { 742 cursor: pointer; 743 } 744 745 #available-widgets .widget.ui-draggable-dragging .widget-top { 746 cursor: move; 747 } 748 749 /* =Specific widget styling 750 -------------------------------------------------------------- */ 751 .text-widget-fields { 752 position: relative; 753 } 754 .text-widget-fields [hidden] { 755 display: none; 756 } 757 .text-widget-fields .wp-pointer.wp-pointer-top { 758 position: absolute; 759 z-index: 3; 760 top: 100px; 761 right: 10px; 762 left: 10px; 763 } 764 .text-widget-fields .wp-pointer .wp-pointer-arrow { 765 left: auto; 766 right: 15px; 767 } 768 .text-widget-fields .wp-pointer .wp-pointer-buttons { 769 line-height: 1.4; 770 } 771 772 .custom-html-widget-fields > p > .CodeMirror { 773 border: 1px solid #dcdcde; 774 } 775 .custom-html-widget-fields code { 776 padding-top: 1px; 777 padding-bottom: 1px; 778 } 779 ul.CodeMirror-hints { 780 z-index: 101; /* Due to z-index 100 set on .widget.open */ 781 } 782 .widget-control-actions .custom-html-widget-save-button.button.validation-blocked { 783 cursor: not-allowed; 784 } 785 786 /* =Media Queries 787 -------------------------------------------------------------- */ 788 789 @media screen and (max-width: 782px) { 790 .widgets-holder-wrap .widget-inside input[type="checkbox"], 791 .widgets-holder-wrap .widget-inside input[type="radio"], 792 .editwidget .widget-inside input[type="checkbox"], /* Selectors for the "accessibility mode" page. */ 793 .editwidget .widget-inside input[type="radio"] { 794 margin: 0.25rem 0.25rem 0.25rem 0; 795 } 796 } 797 798 @media screen and (max-width: 480px) { 799 div.widget-liquid-left { 800 width: 100%; 801 float: none; 802 border-right: none; 803 padding-right: 0; 804 } 805 806 #widgets-left .sidebar-name { 807 margin-right: 0; 808 } 809 810 #widgets-left #available-widgets .widget-top { 811 margin-right: 0; 812 } 813 814 #widgets-left .inactive-sidebar .widgets-sortables { 815 margin-right: 0; 816 } 817 818 div.widget-liquid-right { 819 width: 100%; 820 float: none; 821 } 822 823 div.widget { 824 max-width: 480px; 825 } 826 827 .widget-access-link { 828 float: none; 829 margin: 15px 0 0 0; 830 } 831 } 832 833 @media screen and (max-width: 320px) { 834 div.widget { 835 max-width: 320px; 836 } 837 } 838 839 @media only screen and (min-width: 1250px) { 840 #widgets-left #available-widgets .widget { 841 width: 49%; 842 float: left; 843 } 844 845 .widget.ui-draggable-dragging { 846 min-width: 49%; 847 } 848 849 #widgets-left #available-widgets .widget:nth-child(even) { 850 float: right; 851 } 852 853 #widgets-right .sidebars-column-1, 854 #widgets-right .sidebars-column-2 { 855 float: left; 856 width: 49%; 857 } 858 859 #widgets-right .sidebars-column-1 { 860 margin-right: 2%; 861 } 862 863 #widgets-right.single-sidebar .sidebars-column-1, 864 #widgets-right.single-sidebar .sidebars-column-2 { 865 float: none; 866 width: 100%; 867 margin: 0; 868 } 869 }