added callback that removes original element and temporary wrapper, and restores original property values