@@ -70,7 +70,7 @@ impl IpPacket {
70
70
let ( transport_block, network_block) = {
71
71
let chunks = Layout :: default ( )
72
72
. direction ( Direction :: Vertical )
73
- . constraints ( [ Constraint :: Length ( 20 ) , Constraint :: Length ( 9 ) ] )
73
+ . constraints ( [ Constraint :: Length ( 20 ) , Constraint :: Length ( 10 ) ] )
74
74
. flex ( ratatui:: layout:: Flex :: SpaceAround )
75
75
. margin ( 2 )
76
76
. split ( block) ;
@@ -85,7 +85,7 @@ impl IpPacket {
85
85
let ( transport_block, network_block) = {
86
86
let chunks = Layout :: default ( )
87
87
. direction ( Direction :: Vertical )
88
- . constraints ( [ Constraint :: Length ( 8 ) , Constraint :: Length ( 9 ) ] )
88
+ . constraints ( [ Constraint :: Length ( 8 ) , Constraint :: Length ( 10 ) ] )
89
89
. flex ( ratatui:: layout:: Flex :: SpaceAround )
90
90
. margin ( 2 )
91
91
. split ( block) ;
@@ -99,7 +99,7 @@ impl IpPacket {
99
99
let ( transport_block, network_block) = {
100
100
let chunks = Layout :: default ( )
101
101
. direction ( Direction :: Vertical )
102
- . constraints ( [ Constraint :: Length ( 7 ) , Constraint :: Length ( 9 ) ] )
102
+ . constraints ( [ Constraint :: Length ( 7 ) , Constraint :: Length ( 10 ) ] )
103
103
. flex ( ratatui:: layout:: Flex :: SpaceAround )
104
104
. margin ( 2 )
105
105
. split ( block) ;
@@ -252,10 +252,15 @@ impl Ipv6Packet {
252
252
Span :: styled( "Traffic Class" , Style :: new( ) . bold( ) ) ,
253
253
Span :: from( self . traffic_class. to_string( ) ) ,
254
254
] ) ,
255
- // Row::new(vec![
256
- // Span::styled("Flow Label", Style::new().bold()),
257
- // Span::from(&self.flow_label.to_vec().to_string()),
258
- // ]),
255
+ Row :: new ( vec ! [
256
+ Span :: styled( "Flow Label" , Style :: new( ) . bold( ) ) ,
257
+ Span :: from( format!(
258
+ "{:#0x}" ,
259
+ ( self . flow_label[ 0 ] as u32 ) << 16
260
+ | ( self . flow_label[ 1 ] as u32 ) << 8
261
+ | ( self . flow_label[ 2 ] as u32 )
262
+ ) ) ,
263
+ ] ) ,
259
264
Row :: new ( vec ! [
260
265
Span :: styled( "Payload Length" , Style :: new( ) . bold( ) ) ,
261
266
Span :: from( self . traffic_class. to_string( ) ) ,
0 commit comments