Make Preview auto append file extension

I have set the file extension to be shown in Finder settings.

When I open a JPEG in Preview, and try to File > Export and re-save it as JPEG for lower/higher quality, the file name’s file extension is gone. I have to manually add .jpg in the file name when I save the file.

How to prevent Preview remove the file extension?

p.s. I know file extension is useless in Mac/Linux