Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Google Map Laravel Package

arcasolutions/google-map

Laravel package providing Google Maps integration for your app, with helpers to generate map views and include the required scripts. Useful for quickly embedding maps and configuring markers or map options within Laravel projects.

View on GitHub
Deep Wiki
Context7

Info window

Info window displays content in a floating window above the map. The info window looks a little like a comic-book word balloon. It has a content area and a tapered stem, where the tip of the stem is at a specified location on the map.

Build your info window

use Ivory\GoogleMap\Overlays\InfoWindow;

$infoWindow = new InfoWindow();

// Configure your info window options
$infoWindow->setPrefixJavascriptVariable('info_window_');
$infoWindow->setPosition(0, 0, true);
$infoWindow->setPixelOffset(1.1, 2.1, 'px', 'pt');
$infoWindow->setContent('<p>Default content</p>');
$infoWindow->setOpen(false);
$infoWindow->setAutoOpen(true);
$infoWindow->setOpenEvent(MouseEvent::CLICK);
$infoWindow->setAutoClose(false);
$infoWindow->setOption('disableAutoPan', true);
$infoWindow->setOption('zIndex', 10);
$infoWindow->setOptions(array(
    'disableAutoPan' => true,
    'zIndex'         => 10,
));

Add your info window to the map

use Ivory\GoogleMap\Overlays\InfoWindow;

$infoWindow = new InfoWindow();

// Add your info window to the map
$map->addInfoWindow($infoWindow);

Add your info window to a marker

use Ivory\GoogleMap\Overlays\InfoWindow;

$infoWindow = new InfoWindow();

// Add your info window to the marker
$marker->setInfoWindow($infoWindow);

Configure info window open event

For configurating the info window open event, the better way is to follow the oriented object way. For that, the Ivory\GoogleMap\Events\MouseEvent is here. It allows you to access all constants which describe open event. If you don't want to use this class, you can directly use the constant value.

use Ivory\GoogleMap\Events\MouseEvent;
use Ivory\GoogleMap\Overlays\InfoWindow;

$infoWindow = new InfoWindow();

// Sets your open event
$infoWindow->setOpenEvent(MouseEvent::CLICK);
$infoWindow->setOpenEvent('click');

$infoWindow->setOpenEvent(MouseEvent::DBLCLICK);
$infoWindow->setOpenEvent('dblclick');

$infoWindow->setOpenEvent(MouseEvent::MOUSEUP);
$infoWindow->setOpenEvent('mouseup');

$infoWindow->setOpenEvent(MouseEvent::MOUSEDOWN);
$infoWindow->setOpenEvent('mousedown');

$infoWindow->setOpenEvent(MouseEvent::MOUSEOVER);
$infoWindow->setOpenEvent('mouseover');

$infoWindow->setOpenEvent(MouseEvent::MOUSEOUT);
$infoWindow->setOpenEvent('mouseout');
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky