UNPKG

3.64 kBTypeScriptView Raw
1/// <reference types="googlemaps" />
2import { OnInit } from '@angular/core';
3/**
4 * AgmPolylineIcon enables to add polyline sequences to add arrows, circle,
5 * or custom icons either along the entire line, or in a specific part of it.
6 * See https://developers.google.com/maps/documentation/javascript/shapes#polyline_customize
7 *
8 * ### Example
9 * ```html
10 * <agm-map [latitude]="lat" [longitude]="lng" [zoom]="zoom">
11 * <agm-polyline>
12 * <agm-icon-sequence [fixedRotation]="true" [path]="'FORWARD_OPEN_ARROW'">
13 * </agm-icon-sequence>
14 * </agm-polyline>
15 * </agm-map>
16 * ```
17 */
18export declare class AgmPolylineIcon implements OnInit {
19 /**
20 * If `true`, each icon in the sequence has the same fixed rotation regardless of the
21 * angle of the edge on which it lies. Defaults to `false`, in which case each icon
22 * in the sequence is rotated to align with its edge.
23 */
24 fixedRotation: boolean;
25 /**
26 * The distance from the start of the line at which an icon is to be rendered. This
27 * distance may be expressed as a percentage of line's length (e.g. '50%') or in pixels
28 * (e.g. '50px'). Defaults to '100%'.
29 */
30 offset: string;
31 /**
32 * The distance between consecutive icons on the line. This distance may be expressed as
33 * a percentage of the line's length (e.g. '50%') or in pixels (e.g. '50px'). To disable
34 * repeating of the icon, specify '0'. Defaults to '0'.
35 */
36 repeat: string;
37 /**
38 * The x coordinate of the position of the symbol relative to the polyline. The coordinate
39 * of the symbol's path is translated _left_ by the anchor's x coordinate. By default, a
40 * symbol is anchored at (0, 0). The position is expressed in the same coordinate system as the
41 * symbol's path.
42 */
43 anchorX: number;
44 /**
45 * The y coordinate of the position of the symbol relative to the polyline. The coordinate
46 * of the symbol's path is translated _up_ by the anchor's y coordinate. By default, a
47 * symbol is anchored at (0, 0). The position is expressed in the same coordinate system as the
48 * symbol's path.
49 */
50 anchorY: number;
51 /**
52 * The symbol's fill color. All CSS3 colors are supported except for extended named
53 * colors. Defaults to the stroke color of the corresponding polyline.
54 */
55 fillColor: string;
56 /**
57 * The symbol's fill opacity. Defaults to 0.
58 */
59 fillOpacity: number;
60 /**
61 * The symbol's path, which is a built-in symbol path, or a custom path expressed using
62 * SVG path notation. Required.
63 */
64 path: keyof typeof google.maps.SymbolPath | string;
65 /**
66 * The angle by which to rotate the symbol, expressed clockwise in degrees.
67 * Defaults to 0. A symbol where `fixedRotation` is `false` is rotated relative to
68 * the angle of the edge on which it lies.
69 */
70 rotation: number;
71 /**
72 * The amount by which the symbol is scaled in size. Defaults to the stroke weight
73 * of the polyline; after scaling, the symbol must lie inside a square 22 pixels in
74 * size centered at the symbol's anchor.
75 */
76 scale: number;
77 /**
78 * The symbol's stroke color. All CSS3 colors are supported except for extended named
79 * colors. Defaults to the stroke color of the polyline.
80 */
81 strokeColor: string;
82 /**
83 * The symbol's stroke opacity. Defaults to the stroke opacity of the polyline.
84 */
85 strokeOpacity: number;
86 /**
87 * The symbol's stroke weight. Defaults to the scale of the symbol.
88 */
89 strokeWeight: number;
90 ngOnInit(): void;
91}