e2b46faa05
A DingTalk AI card replays streamed content with a typewriter animation the
client drives itself, so a finished answer can still be typed out character
by character - and a card that is not in the foreground pauses that replay.
DINGTALK_CARD_FINAL_WRITE now sequences the two terminal writes explicitly:
streaming (default) streaming finalize only (unchanged)
update finalize, then a plain write (observed to blank the card)
refresh plain write of the finished answer, then a zero-delta
finalize carrying the same text
close-refresh zero-delta finalize on the text the card already shows,
then a plain write of the finished answer
The sender remembers the text each live card shows so a terminal write can
close the stream with a frame the client has nothing to animate; a failing
plain write is logged and never fails the delivery.