It can cause what could be considered a temporary hydrogen bond
Its poorly named but: a hydrogen bond is a intermolecular force that has a very weak attraction between molecules and if you have the strength to pull two magnets like that you essentially are creating a hydrogen bond