@@ -959,6 +959,7 @@ public class AttachmentTextInputPanelNode: ASDisplayNode, TGCaptionPanelView, AS
959959 textFieldInsets. right += additionalSideInsets. right / 3.0
960960 }
961961
962+ var isPaidMessage = false
962963 var textBackgroundInset : CGFloat = 0.0
963964 let actionButtonsSize : CGSize
964965 if let presentationInterfaceState = self . presentationInterfaceState {
@@ -968,6 +969,7 @@ public class AttachmentTextInputPanelNode: ASDisplayNode, TGCaptionPanelView, AS
968969 isMinimized = false
969970 let count = max ( 1 , presentationInterfaceState. interfaceState. forwardMessageIds? . count ?? 1 )
970971 text = " ⭐️ \( sendPaidMessageStars. value * Int64( count) ) "
972+ isPaidMessage = true
971973 } else {
972974 isMinimized = !self . isAttachment || inputHasText
973975 text = presentationInterfaceState. strings. MediaPicker_Send
@@ -981,7 +983,7 @@ public class AttachmentTextInputPanelNode: ASDisplayNode, TGCaptionPanelView, AS
981983 let actionButtonsFrame = CGRect ( origin: CGPoint ( x: width - rightInset - actionButtonsSize. width + 1.0 - UIScreenPixel + composeButtonsOffset, y: panelHeight - minimalHeight) , size: actionButtonsSize)
982984 transition. updateFrame ( node: self . actionButtons, frame: actionButtonsFrame)
983985
984- let textInputBackgroundFrame = CGRect ( origin: CGPoint ( ) , size: CGSize ( width: textInputFrame . size . width + composeButtonsOffset, height: textInputFrame. size. height) )
986+ let textInputBackgroundFrame = CGRect ( origin: CGPoint ( ) , size: CGSize ( width: baseWidth - textFieldInsets . left - textFieldInsets . right + composeButtonsOffset - textBackgroundInset , height: textInputFrame. size. height) )
985987 transition. updateFrame ( node: self . textInputContainerBackgroundNode, frame: textInputBackgroundFrame)
986988
987989 transition. updateFrame ( layer: self . textInputBackgroundNode. layer, frame: CGRect ( x: leftInset + textFieldInsets. left, y: textFieldInsets. top, width: baseWidth - textFieldInsets. left - textFieldInsets. right + composeButtonsOffset - textBackgroundInset, height: panelHeight - textFieldInsets. top - textFieldInsets. bottom) )
@@ -1028,7 +1030,7 @@ public class AttachmentTextInputPanelNode: ASDisplayNode, TGCaptionPanelView, AS
10281030 }
10291031 transition. updateFrame ( node: self . textPlaceholderNode, frame: placeholderFrame)
10301032
1031- return textBackgroundInset
1033+ return isPaidMessage ? textBackgroundInset : 0.0
10321034 }
10331035
10341036 private var skipUpdate = false
0 commit comments