LoginSignup
0
0

More than 3 years have passed since last update.

マイライブラリ:positionプロパティ

Last updated at Posted at 2020-05-26

親要素内で、子要素の位置をCSSでデザインする

親要素にposition:relativeで基準位置を作る
子要素にposition:absoluteで基準位置からの絶対値で位置を指定する
そしてtopbottomleftrightで具体的な位置を指定する。

↓は黄色い親要素のボックスの右上に文字を配置

See the Pen YzyoObL by abetack (@abetack) on CodePen.

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0