"(And Joshua weakened) Amalek" (Exodus 17:13), according to its plain meaning. "And [Amalek]", these are his wife and his sons. "And his people", these are the multitudes who came with him. Therefore, when Jethro heard of the miracles that the Holy One, blessed be He, performed against Amalek, he immediately came and converted. This is the meaning of "Strike the scoffer" (Proverbs 19:25), this is Amalek; "and the simple one will become clever" (Proverbs 19:25), this is Jethro.
Why Jethro Converted After Amalek's Defeat in Tanchuma
Midrash Tanchuma Buber, Yitro 4:5
את עמלק (שם), (כשמועו) [כמשמעו], ואת (עמלק) אלו אשתו ובניו, עמו, (אלו) אוכלוסין שבאו עמו, לפיכך כששמע יתרו נסים שעשה הקב"ה בעמלק מיד בא ונתגייר, הוי לץ תכה זה עמלק, ופתי יערים זה יתרו.