Preheat the oven to 325 degrees F (165 degrees C).
In a bowl, mix butter and powdered sugar together with a rubber spatula until creamy.
Add vanilla extract, almond extract, salt, and egg yolk.
Mix with the spatula.
Add flour and blend until just combined.
Use a sorbet scoop to portion dough into 1/2-ounce (1-tablespoon) balls.
Roll balls in a plate of white sugar to coat; roll again between your palms.
Place several inches apart on a silicone-lined baking sheet.
Flatten balls lightly with your fingers.
For thumbprint cookies with jam, poke a well into each cookie using the end of a thick wooden spoon dusted with powdered sugar or using one of your fingers.
Fill cookies with fruit jam.
Tap the baking sheet against the counter to let the jam settle.
Bake in the preheated oven until tops are barely blonde and bottoms are slightly golden, about 15 minutes.
Let cool on a wire rack before icing.
While cooling, mix powdered sugar with a little milk until you have a consistency that will hold its shape when piped.
Pipe icing on top of cookies in a zigzag pattern.
Let sit for 15 minutes before serving.
For a more jam-forward cookie, press your thumb into the cookies to make large, shallow indentations.
Spoon in jam.
Tap the baking sheet against the counter.
Bake until not quite golden brown, about 15 minutes.
Let rest on the pan for 5 minutes before transferring to a wire rack.
Dust with powdered sugar.