Changeset 471
- Timestamp:
- 03/06/2014 10:12:52 PM (11 years ago)
- Location:
- sites/trunk/buddypress.org/public_html/wp-content/plugins
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/buddypress.org/public_html/wp-content/plugins/bbpress-org/toolbar.php
r447 r471 470 470 } 471 471 add_action( 'admin_bar_menu', 'bbporg_admin_bar_my_account_menu', 7 ); 472 473 /** 474 * Force toolbar styling into looking like sub-navigation 475 * 476 * Note: slightly experimental - kind of a hack 477 * 478 * @author johnjamesjacoby 479 * @since 1.0.3 480 */ 481 function bbporg_toolbar_css_overrides() { 482 ?> 483 <style type="text/css"> 484 /* Admin Bar */ 485 <?php if ( is_main_site() && is_front_page() ) : ?> 486 #wpadminbar { display: none !important; } 487 <?php else : ?> 488 #wpadminbar { color: #555; background: #eee; top: 81px; border-bottom: 1px solid #ddd; padding-bottom: 10px; } 489 #wpadminbar #wp-toolbar a.ab-item, #wpadminbar .quicklinks li#wp-admin-bar-bp-notifications > a { padding: 5px; } 490 #wpadminbar #wp-toolbar ul.ab-submenu a.ab-item { padding: 0 2em 0 1em; } 491 #wpadminbar #wp-toolbar .ab-top-secondary .menupop .menupop > a.ab-item { padding: 0 1em 0 2em; } 492 #wpadminbar a.ab-item, #wpadminbar > #wp-toolbar span.ab-label, #wpadminbar > #wp-toolbar span.noticon { color: #555; } 493 #wpadminbar .ab-icon, #wpadminbar .ab-icon:before, #wpadminbar .ab-item:before, #wpadminbar .ab-item:after { color: #d84800; } 494 #wpadminbar .ab-top-menu > li:hover > .ab-item, 495 #wpadminbar .ab-top-menu > li.hover > .ab-item, 496 #wpadminbar .ab-top-menu > li > .ab-item:focus, 497 #wpadminbar.nojq .quicklinks .ab-top-menu > li > .ab-item:focus, 498 #wpadminbar-nojs .ab-top-menu > li.menupop:hover > .ab-item, 499 #wpadminbar .ab-top-menu > li.menupop.hover > .ab-item { color: #555; background: #eee; } 500 #wpadminbar > #wp-toolbar li:hover span.ab-label, #wpadminbar > #wp-toolbar li.hover span.ab-label, #wpadminbar > #wp-toolbar a:focus span.ab-label { color: #555; } 501 #wpadminbar li:hover .ab-icon:before, #wpadminbar li:hover .ab-item:before, #wpadminbar li:hover .ab-item:after, #wpadminbar li:hover #adminbarsearch:before { color: #999; } 502 #wp-toolbar { width: 960px; margin: 0 auto; } 503 504 /* Admin Bar: submenu */ 505 #wpadminbar .menupop .ab-sub-wrapper { background: #eee; } 506 #wpadminbar .quicklinks .menupop .ab-submenu { background: #eee; } 507 #wpadminbar .quicklinks .menupop ul.ab-sub-secondary, #wpadminbar .quicklinks .menupop ul.ab-sub-secondary .ab-submenu { background: #ddd; } 508 #wpadminbar .ab-submenu .ab-item, #wpadminbar .quicklinks .menupop ul li a, #wpadminbar .quicklinks .menupop.hover ul li a, #wpadminbar-nojs .quicklinks .menupop:hover ul li a { color: #555; } 509 #wpadminbar .quicklinks li .blavatar, #wpadminbar .menupop .menupop > .ab-item:before { color: #f1f1f3; } 510 #wpadminbar .quicklinks .menupop ul li a:hover, 511 #wpadminbar .quicklinks .menupop ul li a:focus, 512 #wpadminbar .quicklinks .menupop ul li a:hover strong, 513 #wpadminbar .quicklinks .menupop ul li a:focus strong, 514 #wpadminbar .quicklinks .menupop.hover ul li a:hover, 515 #wpadminbar .quicklinks .menupop.hover ul li a:focus, 516 #wpadminbar.nojs .quicklinks .menupop:hover ul li a:hover, 517 #wpadminbar.nojs .quicklinks .menupop:hover ul li a:focus, 518 #wpadminbar li:hover .ab-icon:before, 519 #wpadminbar li:hover .ab-item:before, 520 #wpadminbar li a:focus .ab-icon:before, 521 #wpadminbar li .ab-item:focus:before, 522 #wpadminbar li.hover .ab-icon:before, 523 wpadminbar li.hover .ab-item:before, 524 #wpadminbar li:hover .ab-item:after, 525 #wpadminbar li.hover .ab-item:after, 526 #wpadminbar li:hover #adminbarsearch:before { color: #d84800; } 527 #wpadminbar .quicklinks li a:hover .blavatar, #wpadminbar .menupop .menupop > .ab-item:hover:before { color: #d84800; } 528 529 /* Admin Bar: my account */ 530 #wpadminbar .quicklinks li#wp-admin-bar-my-account.with-avatar > a img { border-color: #eee; background-color: #eee; } 531 #wpadminbar #wp-admin-bar-user-info .display-name { color: #555; } 532 #wpadminbar #wp-admin-bar-user-info a:hover .display-name { color: #d84800; } 533 #wpadminbar #wp-admin-bar-user-info .username { color: #000; } 534 <?php endif; ?> 535 </style> 536 <?php 537 } 538 add_theme_support( 'admin-bar', array( 'callback' => 'bbporg_toolbar_css_overrides' ) ); -
sites/trunk/buddypress.org/public_html/wp-content/plugins/buddypress-org/toolbar.php
r447 r471 432 432 } 433 433 add_action( 'admin_bar_menu', 'bporg_admin_bar_my_account_item', 0 ); 434 435 /** 436 * Force toolbar styling into looking like sub-navigation 437 * 438 * Note: slightly experimental - kind of a hack 439 * 440 * @author johnjamesjacoby 441 * @since 1.0.3 442 */ 443 function bporg_toolbar_css_overrides() { 444 ?> 445 <style type="text/css"> 446 /* Admin Bar */ 447 <?php if ( is_main_site() && is_front_page() ) : ?> 448 #wpadminbar { display: none !important; } 449 <?php else : ?> 450 #wpadminbar { color: #555; background: #eee; top: 81px; border-bottom: 1px solid #ddd; padding-bottom: 10px; } 451 #wpadminbar #wp-toolbar a.ab-item, #wpadminbar .quicklinks li#wp-admin-bar-bp-notifications > a { padding: 5px; } 452 #wpadminbar #wp-toolbar ul.ab-submenu a.ab-item { padding: 0 2em 0 1em; } 453 #wpadminbar #wp-toolbar .ab-top-secondary .menupop .menupop > a.ab-item { padding: 0 1em 0 2em; } 454 #wpadminbar a.ab-item, #wpadminbar > #wp-toolbar span.ab-label, #wpadminbar > #wp-toolbar span.noticon { color: #555; } 455 #wpadminbar .ab-icon, #wpadminbar .ab-icon:before, #wpadminbar .ab-item:before, #wpadminbar .ab-item:after { color: #d84800; } 456 #wpadminbar .ab-top-menu > li:hover > .ab-item, 457 #wpadminbar .ab-top-menu > li.hover > .ab-item, 458 #wpadminbar .ab-top-menu > li > .ab-item:focus, 459 #wpadminbar.nojq .quicklinks .ab-top-menu > li > .ab-item:focus, 460 #wpadminbar-nojs .ab-top-menu > li.menupop:hover > .ab-item, 461 #wpadminbar .ab-top-menu > li.menupop.hover > .ab-item { color: #555; background: #eee; } 462 #wpadminbar > #wp-toolbar li:hover span.ab-label, #wpadminbar > #wp-toolbar li.hover span.ab-label, #wpadminbar > #wp-toolbar a:focus span.ab-label { color: #555; } 463 #wpadminbar li:hover .ab-icon:before, #wpadminbar li:hover .ab-item:before, #wpadminbar li:hover .ab-item:after, #wpadminbar li:hover #adminbarsearch:before { color: #999; } 464 #wp-toolbar { width: 960px; margin: 0 auto; } 465 466 /* Admin Bar: submenu */ 467 #wpadminbar .menupop .ab-sub-wrapper { background: #eee; } 468 #wpadminbar .quicklinks .menupop .ab-submenu { background: #eee; } 469 #wpadminbar .quicklinks .menupop ul.ab-sub-secondary, #wpadminbar .quicklinks .menupop ul.ab-sub-secondary .ab-submenu { background: #ddd; } 470 #wpadminbar .ab-submenu .ab-item, #wpadminbar .quicklinks .menupop ul li a, #wpadminbar .quicklinks .menupop.hover ul li a, #wpadminbar-nojs .quicklinks .menupop:hover ul li a { color: #555; } 471 #wpadminbar .quicklinks li .blavatar, #wpadminbar .menupop .menupop > .ab-item:before { color: #f1f1f3; } 472 #wpadminbar .quicklinks .menupop ul li a:hover, 473 #wpadminbar .quicklinks .menupop ul li a:focus, 474 #wpadminbar .quicklinks .menupop ul li a:hover strong, 475 #wpadminbar .quicklinks .menupop ul li a:focus strong, 476 #wpadminbar .quicklinks .menupop.hover ul li a:hover, 477 #wpadminbar .quicklinks .menupop.hover ul li a:focus, 478 #wpadminbar.nojs .quicklinks .menupop:hover ul li a:hover, 479 #wpadminbar.nojs .quicklinks .menupop:hover ul li a:focus, 480 #wpadminbar li:hover .ab-icon:before, 481 #wpadminbar li:hover .ab-item:before, 482 #wpadminbar li a:focus .ab-icon:before, 483 #wpadminbar li .ab-item:focus:before, 484 #wpadminbar li.hover .ab-icon:before, 485 wpadminbar li.hover .ab-item:before, 486 #wpadminbar li:hover .ab-item:after, 487 #wpadminbar li.hover .ab-item:after, 488 #wpadminbar li:hover #adminbarsearch:before { color: #d84800; } 489 #wpadminbar .quicklinks li a:hover .blavatar, #wpadminbar .menupop .menupop > .ab-item:hover:before { color: #d84800; } 490 491 /* Admin Bar: my account */ 492 #wpadminbar .quicklinks li#wp-admin-bar-my-account.with-avatar > a img { border-color: #eee; background-color: #eee; } 493 #wpadminbar #wp-admin-bar-user-info .display-name { color: #555; } 494 #wpadminbar #wp-admin-bar-user-info a:hover .display-name { color: #d84800; } 495 #wpadminbar #wp-admin-bar-user-info .username { color: #000; } 496 <?php endif; ?> 497 </style> 498 <?php 499 } 500 add_theme_support( 'admin-bar', array( 'callback' => 'bporg_toolbar_css_overrides' ) );
Note: See TracChangeset
for help on using the changeset viewer.