MCPcopy
hub / github.com/angular/components / MapMarker

Class MapMarker

src/google-maps/map-marker/map-marker.ts:52–502  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

50 ],
51})
52export class MapMarker implements OnInit, OnChanges, OnDestroy, MapAnchorPoint, MarkerDirective {
53 private readonly _googleMap = inject(GoogleMap);
54 private _ngZone = inject(NgZone);
55 private _eventManager = new MapEventManager(inject(NgZone));
56
57 /**
58 * Title of the marker.
59 * See: developers.google.com/maps/documentation/javascript/reference/marker#MarkerOptions.title
60 */
61 @Input()
62 set title(title: string) {
63 this._title = title;
64 }
65 private _title!: string;
66
67 /**
68 * Position of the marker. See:
69 * developers.google.com/maps/documentation/javascript/reference/marker#MarkerOptions.position
70 */
71 @Input()
72 set position(position: google.maps.LatLngLiteral | google.maps.LatLng) {
73 this._position = position;
74 }
75 private _position!: google.maps.LatLngLiteral | google.maps.LatLng;
76
77 /**
78 * Label for the marker.
79 * See: developers.google.com/maps/documentation/javascript/reference/marker#MarkerOptions.label
80 */
81 @Input()
82 set label(label: string | google.maps.MarkerLabel) {
83 this._label = label;
84 }
85 private _label!: string | google.maps.MarkerLabel;
86
87 /**
88 * Whether the marker is clickable. See:
89 * developers.google.com/maps/documentation/javascript/reference/marker#MarkerOptions.clickable
90 */
91 @Input()
92 set clickable(clickable: boolean) {
93 this._clickable = clickable;
94 }
95 private _clickable: boolean | undefined;
96
97 /**
98 * Options used to configure the marker.
99 * See: developers.google.com/maps/documentation/javascript/reference/marker#MarkerOptions
100 */
101 @Input()
102 set options(options: google.maps.MarkerOptions) {
103 this._options = options;
104 }
105 private _options!: google.maps.MarkerOptions;
106
107 /**
108 * Icon to be used for the marker.
109 * See: https://developers.google.com/maps/documentation/javascript/reference/marker#Icon

Callers

nothing calls this directly

Calls 1

getLazyEmitterMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…