You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/layout/position/index.html
+7-9Lines changed: 7 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -113,18 +113,16 @@ <h3 class="f5 book pt4 caps">Position Relative</h3>
113
113
</p>
114
114
</div>
115
115
<h3class="f5 book pt4 caps">Position Relative + Absolute</h3>
116
-
<divclass="relative bg-black-10 h5 mbm">
117
-
<divclass="absolute top-1 left-1 right-2 bottom-2 white bg-dark-gray">
118
-
<pclass="measure pam">
119
-
This is an absolutely positioned element set to have offsets of top and left to 1rem with right and bottom offset by 2rem. It's parent with the light gray background is set to position relative.
116
+
<divclass="relative bg-black-10 h5 mbm br2">
117
+
<divclass="absolute top-1 left-1 right-2 bottom-2 white bg-black-50 br2">
118
+
<pclass="measure lh-copy ph3">
119
+
This is an absolutely positioned element set to have offsets of top and left to 1rem with right and bottom offset by 2rem. It's parent with the light gray background is set to position relative.
120
120
</p>
121
121
</div>
122
122
</div>
123
-
<divclass="relative bg-black-10 h5 mbm">
124
-
<divclass="absolute top-0 right-0 white bg-dark-gray w2 pvs tc">
125
-
X
126
-
</div>
127
-
<pclass="measure pal">
123
+
<divclass="relative bg-black-10 h5 mbm br2">
124
+
<spanclass="absolute top-0 right-0 ma2 white bg-black-50 pa2 tc br2">X</span>
125
+
<pclass="measure lh-copy pa3">
128
126
This illustrates an absolutely positioned element that might always need to be in the top right of the content like a close button for a modal that needs to be dismissed.
Copy file name to clipboardExpand all lines: src/templates/docs/position/index.html
+7-9Lines changed: 7 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -77,18 +77,16 @@ <h3 class="f5 book pt4 caps">Position Relative</h3>
77
77
</p>
78
78
</div>
79
79
<h3class="f5 book pt4 caps">Position Relative + Absolute</h3>
80
-
<divclass="relative bg-black-10 h5 mbm">
81
-
<divclass="absolute top-1 left-1 right-2 bottom-2 white bg-dark-gray">
82
-
<pclass="measure pam">
83
-
This is an absolutely positioned element set to have offsets of top and left to 1rem with right and bottom offset by 2rem. It's parent with the light gray background is set to position relative.
80
+
<divclass="relative bg-black-10 h5 mbm br2">
81
+
<divclass="absolute top-1 left-1 right-2 bottom-2 white bg-black-50 br2">
82
+
<pclass="measure lh-copy ph3">
83
+
This is an absolutely positioned element set to have offsets of top and left to 1rem with right and bottom offset by 2rem. It's parent with the light gray background is set to position relative.
84
84
</p>
85
85
</div>
86
86
</div>
87
-
<divclass="relative bg-black-10 h5 mbm">
88
-
<divclass="absolute top-0 right-0 white bg-dark-gray w2 pvs tc">
89
-
X
90
-
</div>
91
-
<pclass="measure pal">
87
+
<divclass="relative bg-black-10 h5 mbm br2">
88
+
<spanclass="absolute top-0 right-0 ma2 white bg-black-50 pa2 tc br2">X</span>
89
+
<pclass="measure lh-copy pa3">
92
90
This illustrates an absolutely positioned element that might always need to be in the top right of the content like a close button for a modal that needs to be dismissed.
0 commit comments