File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -3388,8 +3388,8 @@ def compose(self) -> ComposeResult:
33883388
33893389
33903390def test_overflow (snap_compare ):
3391- """Test overflow. You should see two labels across 4 lines. The first with overflow clip,
3392- the second with overflow ellipsis."""
3391+ """Test overflow. You should see three labels across 4 lines. The first with overflow clip,
3392+ the second with overflow ellipsis, and the last with overflow fold ."""
33933393
33943394 TEXT = "FOO " + "FOOBARBAZ" * 100
33953395
@@ -3399,17 +3399,25 @@ class OverflowApp(App):
33993399 max-width: 100vw;
34003400 }
34013401 #label1 {
3402+ # Overflow will be cropped
34023403 text-overflow: clip;
34033404 background: blue 20%;
34043405 }
34053406 #label2 {
3407+ # Like clip, but last character will be an ellipsis
34063408 text-overflow: ellipsis;
34073409 background: green 20%;
34083410 }
3411+ #label3 {
3412+ # Overflow will fold on to subsequence lines
3413+ text-overflow: fold;
3414+ background: red 20%;
3415+ }
34093416 """
34103417
34113418 def compose (self ) -> ComposeResult :
34123419 yield Label (TEXT , id = "label1" )
34133420 yield Label (TEXT , id = "label2" )
3421+ yield Label (TEXT , id = "label3" )
34143422
34153423 assert snap_compare (OverflowApp ())
You can’t perform that action at this time.
0 commit comments