Here "hearts" refers to their courage. They were so afraid that it was as if their courage melted away like wax in a fire. Alternate translation: "they lost all their courage" (See: [[rc://en/ta/man/jit/figs-metonymy]] and [[rc://en/ta/man/jit/figs-metaphor]])