ブックマーク / www.kennethcachia.com (1)

  • BackgroundCheck

    Automatically switch to a darker or a lighter version of an element depending on the brightness of images behind it.

    mametro
    mametro 2013/09/24
    背面にある画像の色調を判定し、前面にあるオブジェクトに class を与える。テキストの色を画像が暗ければ明るい色へ・明るければ暗い色へ変更するなど、CSSで制御可能。
  • 1