A device, comprising: a body, a display having a cover glass extending over the edges of the display, an adhesive configured to attach the display to the body from the cover glass portion, a first conductive layer on the display configured to provide a first reference voltage, a second conductive layer on the body configured to provide a second reference voltage, a sensor layer configured to detect capacitance between the first reference voltage and the sensor layer, and further configured to detect capacitance between the second reference voltage and the sensor layer, a first dielectric layer configured to provide a distance between the first conductive layer and the sensor layer, and a second dielectric layer configured to provide a distance between the second conductive layer and the sensor layer; wherein at least one of the first dielectric layer and the second dielectric layer is made of foam configured to compress due to a force applied to the display; wherein the sensor layer is positioned between the first conductive layer and the second conductive layer under only a portion of the display; wherein the sensor layer, the first dielectric layer and the second dielectric laye are positioned in an area under the display, and at or near an edge of the display; wherein the display is configured to move and the foam is configured to compress when the user applies a force to the display; wherein the sensor layer is configured to detect capacitance between the first conductive layer and the sensor layer and between the second conductive layer and the sensor layer in the area; and further wherein the adhesive is positioned under the cover glass portion of the cover glass, wherein the adhesive allows lateral flex to the display in relation to the sensor layer. a body, a display having a cover glass extending over the edges of the display, an adhesive configured to attach the display to the body from the cover glass portion, a first conductive layer on the display configured to provide a first reference voltage, a second conductive layer on the body configured to provide a second reference voltage, a sensor layer configured to detect capacitance between the first reference voltage and the sensor layer, and further configured to detect capacitance between the second reference voltage and the sensor layer, a first dielectric layer configured to provide a distance between the first conductive layer and the sensor layer, and a second dielectric layer configured to provide a distance between the second conductive layer and the sensor layer; wherein at least one of the first dielectric layer and the second dielectric layer is made of foam configured to compress due to a force applied to the display; wherein the sensor layer is positioned between the first conductive layer and the second conductive layer under only a portion of the display; wherein the sensor layer, the first dielectric layer and the second dielectric laye are positioned in an area under the display, and at or near an edge of the display; wherein the display is configured to move and the foam is configured to compress when the user applies a force to the display; wherein the sensor layer is configured to detect capacitance between the first conductive layer and the sensor layer and between the second conductive layer and the sensor layer in the area; and further wherein the adhesive is positioned under the cover glass portion of the cover glass, wherein the adhesive allows lateral flex to the display in relation to the sensor layer.