• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

IgniteUI / igniteui-angular-wrappers / 4427504397

pending completion
4427504397

push

github

GitHub
Update README.md

281 of 305 branches covered (92.13%)

Branch coverage included in aggregate %.

668 of 713 relevant lines covered (93.69%)

219.79 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

84.21
/projects/igniteui-angular-wrappers/src/lib/igmap/igmap.component.ts
1
import { Component, IterableDiffers, ElementRef, KeyValueDiffers, ChangeDetectorRef, Input, Renderer2, OnInit } from '@angular/core';
2
import { IgControlBase } from '../igcontrolbase/igcontrolbase';
3

4
@Component({
5
    selector: 'ig-map',
6
    template: '<ng-content></ng-content>',
7
    inputs: ['widgetId', 'options', 'changeDetectionInterval', 'disabled', 'create', 'width', 'height', 'dataSource', 'dataSourceUrl', 'dataSourceType', 'responseDataKey', 'autoMarginWidth', 'autoMarginHeight', 'crosshairVisibility', 'crosshairPoint', 'plotAreaBackground', 'defaultInteraction', 'dragModifier', 'panModifier', 'previewRect', 'windowRect', 'zoomable', 'windowScale', 'windowResponse', 'windowRectMinWidth', 'windowPositionHorizontal', 'windowPositionVertical', 'circleMarkerTemplate', 'triangleMarkerTemplate', 'pyramidMarkerTemplate', 'squareMarkerTemplate', 'diamondMarkerTemplate', 'pentagonMarkerTemplate', 'hexagonMarkerTemplate', 'tetragramMarkerTemplate', 'pentagramMarkerTemplate', 'hexagramMarkerTemplate', 'overviewPlusDetailPaneBackgroundImageUri', 'useTiledZooming', 'preferHigherResolutionTiles', 'zoomTileCacheSize', 'backgroundContent', 'series', 'theme'],
8
    outputs: ['tooltipShowing', 'tooltipShown', 'tooltipHiding', 'tooltipHidden', 'browserNotSupported', 'seriesCursorMouseMove', 'seriesMouseLeftButtonDown', 'seriesMouseLeftButtonUp', 'seriesMouseMove', 'seriesMouseEnter', 'seriesMouseLeave', 'windowRectChanged', 'gridAreaRectChanged', 'refreshCompleted', 'triangulationStatusChanged']
9
})
10
export class IgMapComponent extends IgControlBase<IgMap> implements OnInit {
1✔
11
    constructor(el: ElementRef, renderer: Renderer2, differs: IterableDiffers, kvalDiffers: KeyValueDiffers, cdr: ChangeDetectorRef) {
12
      super(el, renderer, differs, kvalDiffers, cdr);
2✔
13
    }
14

15
    @Input()
16
    public set dataSource(value: any) {
17
        this._dataSource = value;
1✔
18
        const map = jQuery(this._el).data(this._widgetName);
1✔
19
        if (map) {
1!
20
            jQuery(this._el)[this._widgetName]('option', 'dataSource', this._dataSource);
×
21
        }
22
    }
23

24
    private _dataSource: any;
25
    public option(): void { return; }
×
26
    ngOnInit() {
27
        if (this._dataSource === null || this._dataSource === undefined) {
2✔
28
            this._dataSource = this.options.dataSource;
1✔
29
        }
30
        if (!this.options.dataSource && this._dataSource) {
2✔
31
            this.options.dataSource = this._dataSource;
1✔
32
        }
33
        super.ngOnInit();
2✔
34
    }
35

36
    /**
37
     * Destroys the widget.
38
     */
39
    /* istanbul ignore next */
40
    public destroy(): void { return; }
41
    /**
42
     * Returns the ID of parent element holding the map.
43
     */
44
    /* istanbul ignore next */
45
    public id(): string { return; }
46
    /**
47
     * Exports the map to a PNG image.
48
     *
49
     * @param width The width of the image.
50
     * @param height The height of the image.
51
     */
52
    /* istanbul ignore next */
53
    public exportImage(width?: object, height?: object): object { return; }
54
    /**
55
     * Notify the map that styles it draws colors from may have been updated.
56
     */
57
    /* istanbul ignore next */
58
    public styleUpdated(): object { return; }
59
    /**
60
     * Resets the zoom level of the map to default.
61
     */
62
    /* istanbul ignore next */
63
    public resetZoom(): object { return; }
64
    /**
65
     * Adds a new item to the data source and notifies the map.
66
     *
67
     * @param item     The item that we want to add to the data source.
68
     * @param targetName     The name of the series bound to the data source.
69
     */
70
    /* istanbul ignore next */
71
    public addItem(item: object, targetName: string): void { return; }
72
    /**
73
     * Inserts a new item to the data source and notifies the map.
74
     *
75
     * @param item     the new item that we want to insert in the data source.
76
     * @param index     The index in the data source where the new item will be inserted.
77
     * @param targetName     The name of the series bound to the data source.
78
     */
79
    /* istanbul ignore next */
80
    public insertItem(item: object, index: number, targetName: string): void { return; }
81
    /**
82
     * Deletes an item from the data source and notifies the map.
83
     *
84
     * @param index     The index in the data source from where the item will be been removed.
85
     * @param targetName     The name of the series bound to the data source.
86
     */
87
    /* istanbul ignore next */
88
    public removeItem(index: number, targetName: string): void { return; }
89
    /**
90
     * Updates an item in the data source and notifies the map.
91
     *
92
     * @param index     The index of the item in the data source that we want to change.
93
     * @param item     The new item object that will be set in the data source.
94
     * @param targetName     The name of the series bound to the data source.
95
     */
96
    /* istanbul ignore next */
97
    public setItem(index: number, item: object, targetName: string): void { return; }
98
    /**
99
     * Notifies the the map that an item has been set in an associated data source.
100
     *
101
     * @param dataSource The data source in which the change happened.
102
     * @param index The index in the items source that has been changed.
103
     * @param newItem the new item that has been set in the collection.
104
     * @param oldItem the old item that has been overwritten in the collection.
105
     */
106
    /* istanbul ignore next */
107
    public notifySetItem(dataSource: object, index: number, newItem: object, oldItem: object): object { return; }
108
    /**
109
     * Notifies the the map that the items have been cleared from an associated data source.
110
     *                 It's not necessary to notify more than one target of a change if they share the same items source.
111
     *
112
     * @param dataSource The data source in which the change happened.
113
     */
114
    /* istanbul ignore next */
115
    public notifyClearItems(dataSource: object): object { return; }
116
    /**
117
     * Notifies the the target series that an item has been inserted at the specified index in its data source.
118
     *                 It's not necessary to notify more than one target of a change if they share the same items source.
119
     *
120
     * @param dataSource The data source in which the change happened.
121
     * @param index The index in the items source where the new item has been inserted.
122
     * @param newItem the new item that has been set in the collection.
123
     */
124
    /* istanbul ignore next */
125
    public notifyInsertItem(dataSource: object, index: number, newItem: object): object { return; }
126
    /**
127
     * Notifies the the target series that an item has been removed from the specified index in its data source.
128
     *                 It's not necessary to notify more than one target of a change if they share the same items source.
129
     *
130
     * @param dataSource The data source in which the change happened.
131
     * @param index The index in the items source from where the old item has been removed.
132
     * @param oldItem the old item that has been removed from the collection.
133
     */
134
    /* istanbul ignore next */
135
    public notifyRemoveItem(dataSource: object, index: number, oldItem: object): object { return; }
136
    /**
137
     * Notifies the target series or axis that it should scroll the requested data item into view.
138
     *
139
     * @param targetName The name of the series or axis notify.
140
     * @param item The data item to bring into view, if possible.
141
     */
142
    /* istanbul ignore next */
143
    public scrollIntoView(targetName: string, item: object): object { return; }
144
    /**
145
     * Either xAxis or yAxis (longitude or latitude) that it should scale the requested value into map space from axis space.
146
     *                                 For example you can use this method if you want to find where longitude 50 stands scaled to map's width.
147
     *
148
     * @param targetName Either xAxis or yAxis to notify.
149
     * @param unscaledValue The value in axis space to translate into map space.
150
     */
151
    /* istanbul ignore next */
152
    public scaleValue(targetName: string, unscaledValue: number): number { return; }
153
    /**
154
     * Either xAxis or yAxis (longitude or latitude) that it should unscale the requested value into axis space from map space.
155
     *                                 For example you can use this method if you want to find what is the longitude unscaled from 0 width of the map.
156
     *
157
     * @param targetName Either xAxis or yAxis to notify.
158
     * @param scaledValue The value in map space to translate into axis space.
159
     */
160
    /* istanbul ignore next */
161
    public unscaleValue(targetName: string, scaledValue: number): number { return; }
162
    /**
163
     * Manually starts a tiled zoom if one isn't already running.
164
     */
165
    /* istanbul ignore next */
166
    public startTiledZoomingIfNecessary(): void { return; }
167
    /**
168
     * Manually ends a tiled zoom if one is running.
169
     */
170
    /* istanbul ignore next */
171
    public endTiledZoomingIfRunning(): void { return; }
172
    /**
173
     * Clears the tile zoom tile cache so that new tiles will be generated. Only applies if the viewer is using a tile based zoom..
174
     */
175
    /* istanbul ignore next */
176
    public clearTileZoomCache(): void { return; }
177
    /**
178
     * Forces any pending deferred work to render on the map before continuing
179
     */
180
    /* istanbul ignore next */
181
    public flush(): void { return; }
182
    /**
183
     * Exports visual data from the map to aid in unit testing
184
     */
185
    /* istanbul ignore next */
186
    public exportVisualData(): void { return; }
187
    /**
188
     * Gets the actual minimum value of the target xAxis or yAxis
189
     *
190
     * @param targetName target name
191
     */
192
    /* istanbul ignore next */
193
    public getActualMinimumValue(targetName: object): void { return; }
194
    /**
195
     * Gets the actual maximum value of the target xAxis or yAxis
196
     *
197
     * @param targetName target name
198
     */
199
    /* istanbul ignore next */
200
    public getActualMaximumValue(targetName: object): void { return; }
201
    /**
202
     * Notifies the map that the container was resized
203
     */
204
    /* istanbul ignore next */
205
    public notifyContainerResized(): void { return; }
206
    /**
207
     * Zoom in to the geographic region specified, when possible (may need to wait fior map to be initialized).
208
     *
209
     * @param rect The geographic area rectangle.
210
     */
211
    /* istanbul ignore next */
212
    public zoomToGeographic(rect: object): object { return; }
213
    /**
214
     * Given the current plot area of the control and a geographic region, get the WindowRect that would encompass that geographic region.
215
     *
216
     * @param rect The geographic area rectangle.
217
     */
218
    /* istanbul ignore next */
219
    public getGeographicFromZoom(rect: object): object { return; }
220
    /**
221
     * Given the current plot area of the control and a geographic region, get the WindowRect that would encompass that geographic region.
222
     *
223
     * @param rect The geographic area rectangle.
224
     */
225
    /* istanbul ignore next */
226
    public getZoomFromGeographic(rect: object): object { return; }
227
    /**
228
     * Creates a print preview page with the map, hiding all other elements on the page.
229
     */
230
    /* istanbul ignore next */
231
    public print(): void { return; }
232
    /**
233
     * Indicates that a series should render, even though no option has been modified that would normally cause it to refresh.
234
     *
235
     * @param targetName     The name of the series to render.
236
     * @param animate     Whether the change should be animated, if possible.
237
     */
238
    /* istanbul ignore next */
239
    public renderSeries(targetName: string, animate: boolean): void { return; }}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc