Skip to content

Instantly share code, notes, and snippets.

@pento
Last active September 26, 2017 21:20
Show Gist options
  • Save pento/bc4574b8eb0f4500efbeb75ec7d8630c to your computer and use it in GitHub Desktop.
Save pento/bc4574b8eb0f4500efbeb75ec7d8630c to your computer and use it in GitHub Desktop.
WordPress Rainbow Bar
<?php
/*
* Plugin Name: Rainbow Bar!
*/
function rainbow_bar() {
?>
<style type="text/css">
#wpadminbar {
background: linear-gradient(
to bottom,
#e24c3e 0%,
#e24c3e 16.66667%,
#f47d3b 16.66667%,
#f47d3b 33.33333%,
#fdb813 33.33333%,
#fdb813 50%,
#74bb5d 50%,
#74bb5d 66.66667%,
#38a6d7 66.66667%,
#38a6d7 83.33333%,
#8c7ab8 83.33333%,
#8c7ab8 100% );
}
#wpadminbar,
#wpadminbar .quicklinks > ul > li {
-webkit-box-shadow: unset;
-moz-box-shadow: unset;
box-shadow: unset;
}
#wpadminbar .ab-top-menu > li > a {
background-color: rgba( 50, 55, 60, .85 );
}
</style>
<?php
}
add_action( 'wp_before_admin_bar_render', 'rainbow_bar' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment