w3tweaks.com
  • Effects
    • Scroll Effects
    • Text Effects
    • Shadow
  • Essentials
    • Arrows
    • Buttons
    • Background Patterns
    • Border Examples
    • Cards
    • Color Palettes
    • Dividers
    • Link styles
    • Loaders
    • Modal Windows
    • Notifications
    • Progress bar
    • Quote styles
    • Spinner
    • Tooltips
  • Media
    • Calendars
    • Carousels
    • Clocks
    • Gallery
    • Music Players
    • Sliders
    • Slideshows
    • Tables
    • Thumbnails
  • Navigation
  • Inputs
    • Range Sliders
    • Checkboxes
    • Toggle Switches
  • Script
    • Angularjs
    • Backbone.js
    • bootstrap
    • jQuery
    • ReactJs
    • JavaScript
    • Syntax Highlighters
    • tryit editor
    • PHP
  • API’s
    • Facebook
    • Google
    • Indeed
    • Twitter
    • YouTube
  • Tools
w3tweaks.com
Home CSS Code Demos

Apply CSS Black and White Filter to YouTube Video

September 19, 2019
in CSS Code Demos

CSS Black and White to YouTube Video is a simple filter in pure css that toggles a filter on the iframe video you can do stuff with mix-blend too that. Developed using css, html and javascript. Demo and download available.

You might also like

CSS Shapes Forest Collection Spring Summer 2020

CSS Button Concept for Remove and Success

Three Pure different CSS Button effects

Easy customizable simple CSS buttons

Rounded CSS buttons with mouseover effect

Collection of CSS3 animated buttons to spice up your site

Demo Download

AuthorFlowuhh
CreatedSEPTEMBER 19, 2018
LicenseOpen
Compatible browsersChrome, Firefox, Safari

HTML Snippet

 <div class="wrapper">   <input type="radio" name="radio" id="noFilter" checked="checked"/>   <input type="radio" name="radio" id="bwFilter"/>   <label for="noFilter">Normal</label>   <label for="bwFilter">Black &amp; White</label>   <iframe src="https://www.youtube.com/embed/QkubQCI4Fxo?autoplay=1;rel=0&amp;amp;controls=0&amp;amp;showinfo=0" frameborder="0" allow="autoplay; encrypted-media"></iframe> </div>

CSS Code

@import url("https://fonts.googleapis.com/css?family=Poppins"); .wrapper {   width: 100%;   height: 100%;   padding: 60px;   box-sizing: border-box;   background-color: #fcfcfc;   font-family: 'Poppins', sans-serif; } .wrapper input {   display: none; } .wrapper input:nth-of-type(1):checked ~ label:nth-of-type(1) {   box-shadow: 0 5px 10px rgba(0, 0, 0, 0.125);   background-color: #56CBF9; } .wrapper input:nth-of-type(2):checked ~ label:nth-of-type(2) {   box-shadow: 0 5px 10px rgba(0, 0, 0, 0.125);   background-color: #56CBF9; } .wrapper input:nth-of-type(2):checked ~ iframe {   -webkit-filter: grayscale(1);           filter: grayscale(1); } .wrapper label {   margin: 0 20px 20px 0;   display: inline-block;   cursor: pointer;   padding: 10px 20px;   border-radius: 30px;   background-color: #eee;   transition: 0.5s ease; } .wrapper label:hover {   box-shadow: 0 5px 10px rgba(0, 0, 0, 0.125); } .wrapper iframe {   width: 100%;   height: calc(100vh - 180px);   box-shadow: 0 20px 80px rgba(0, 0, 0, 0.25); }

Preview

Apply CSS Black and White Filter to YouTube Video preview

Tags: covercover image effectsCSScss effectscss filter effectseffecteffectsfilterfilter effectsimageimage effectsvideoWhiteYouTubeyoutube video cover image effect
Previous Post

Weird input animation and useful for visually impaired users

Next Post

Material Design Components code and examples

Related Stories

CSS Shapes Forest Collection Spring Summer 2020
CSS Code Demos

CSS Shapes Forest Collection Spring Summer 2020

October 11, 2020
CSS Button Concept for Remove and Success
CSS Code Demos

CSS Button Concept for Remove and Success

August 21, 2019
Three Pure different CSS Button effects
CSS Code Demos

Three Pure different CSS Button effects

September 25, 2019
Easy customizable simple CSS buttons
CSS Code Demos

Easy customizable simple CSS buttons

September 8, 2019
Rounded CSS buttons with mouseover effect
CSS Code Demos

Rounded CSS buttons with mouseover effect

September 8, 2019
Collection of CSS3 animated buttons to spice up your site
CSS Code Demos

Collection of CSS3 animated buttons to spice up your site

September 8, 2019
CSS buttons using unicode symbols
CSS Code Demos

CSS buttons using unicode symbols

September 20, 2019
CSS Letter Bouncing Animation Text effect
CSS Code Demos

CSS Letter Bouncing Animation Text effect

September 19, 2019

Discussion about this post

Follow Us

Popular Posts

100 Creative CSS Cards

44 Free Multi step HTML forms

13 Free HTML & CSS Dashboard Template Designs

49 CSS Tables

20 HTML & CSS pricing tables

14 Best CSS Dark Mode

11 CSS Shopping Cart UI/UX

42 Cool CSS Avatars For Better UI

55 Useful handpicked CSS Buttons with examples and demos

89 Best CSS Toggle Switches

w3tweaks

We bring you the best frontend collections that will fix perfect for news, magazine, personal blog, etc. Check our landing page for details.

  • Effects
    • Scroll Effects
    • Text Effects
    • Shadow
  • Essentials
    • Arrows
    • Buttons
    • Background Patterns
    • Border Examples
    • Cards
    • Color Palettes
    • Dividers
    • Link styles
    • Loaders
    • Modal Windows
    • Notifications
    • Progress bar
    • Quote styles
    • Spinner
    • Tooltips
  • Media
    • Calendars
    • Carousels
    • Clocks
    • Gallery
    • Music Players
    • Sliders
    • Slideshows
    • Tables
    • Thumbnails
  • Navigation
  • Inputs
    • Range Sliders
    • Checkboxes
    • Toggle Switches
  • Script
    • Angularjs
    • Backbone.js
    • bootstrap
    • jQuery
    • ReactJs
    • JavaScript
    • Syntax Highlighters
    • tryit editor
    • PHP
  • API’s
    • Facebook
    • Google
    • Indeed
    • Twitter
    • YouTube
  • Tools