Skip to content

Instantly share code, notes, and snippets.

@beijaflor
Last active April 25, 2017 00:23
Show Gist options
  • Save beijaflor/6788291230f4d39d49cb22d9366c6eb3 to your computer and use it in GitHub Desktop.
Save beijaflor/6788291230f4d39d49cb22d9366c6eb3 to your computer and use it in GitHub Desktop.
damn part of HTML & CSS

【雑訳】CSSの見えない部分(見出しのみ)

The invisible parts of CSS · MadebyMike

  • カスケーディング
    1. 詳細度
    2. 継承(inherit)
  • ボックスモデル
    1. (外から)マージン、ボーダー、パディング、コンテンツ
    2. フィルエリア(ボーダーまで)
    3. width: auto;
    4. box-sizing
    5. マージンの相殺
  • 視覚整形モデル
    1. ディスプレイタイプ( display
    2. 整形文脈( formatting context )
  • 位置指定
    1. フローティング
    2. position: absolute;
    3. stacking-contexts ( z-index, will-change

【雑訳】HTMLとCSSの最悪なところ

WTF, HTML and CSS?

  1. <DOCTYPE>の有無によるレンダリングの違い
  2. box-modelの計算: box-sizing: border-box; 使え
  3. モバイルSafariでの rem のバグ
  4. float 要素を先に書かないとダメ
  5. floatclear
  6. floatheight の計算
  7. float するとブロック要素に強制的になる(さらに margin が倍になるバグで display: inline; を書くという)
  8. 縦方向の margin の相殺
  9. <tr> タグへのスタイリング
  10. FireFoxと input type="button": FireFox 30で直るぽい
  11. FireFoxの inner outline をボタンにつける
  12. <button> タグの type 属性のデフォルトが submit
  13. IEのセレクター数制限(ひとつのファイルに4,096まで)
  14. position の名前のつけ方がクソ
  15. position: (absolute|fixed)width の組み合わせ
  16. position: fixed; の要素の親に transform つけると無効になる
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment