Momentary to Toggle Switch for Tiny Application
Believe it or not, that black lump is epoxy covering an integrated circuit, probably a small microprocessor. These are often caseless chips, just the IC die glued to the PCB with fine wires between the pads on the chip and PCB.

Many microcontrollers can be put into a deep-sleep state where they draw just a few microamps, so little so as not to significantly affect battery life. They spend all of their time in deep sleep until someone presses the button, which is connected to an interrupt line to wake it up.