Skip to content

Commit 982472f

Browse files
committed
fix lint
Signed-off-by: Ihor Dykhta <dikhta.igor@gmail.com>
1 parent 3a46bab commit 982472f

4 files changed

Lines changed: 12 additions & 6 deletions

File tree

src/actions/src/vis-state-actions.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1632,7 +1632,7 @@ export function layerFilteredItemsChange(
16321632
export type WMSFeatureInfoAction = {
16331633
layer: Layer;
16341634
featureInfo: Array<{name: string; value: string}> | string | null;
1635-
coordinate?: [number, number];
1635+
coordinate?: [number, number] | null;
16361636
};
16371637

16381638
/**

src/components/src/map-container.tsx

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -526,11 +526,17 @@ export default function MapContainerFactory(
526526
this.props.visStateActions.layerFilteredItemsChange(this.props.visState.layers[idx], event);
527527
};
528528

529-
_onWMSFeatureInfo = (idx, {featureInfo, coordinate}) => {
529+
_onWMSFeatureInfo = (
530+
idx: number,
531+
data: {
532+
featureInfo: Array<{name: string; value: string}> | string | null;
533+
coordinate?: [number, number] | null;
534+
}
535+
) => {
530536
this.props.visStateActions.wmsFeatureInfo(
531537
this.props.visState.layers[idx],
532-
featureInfo,
533-
coordinate
538+
data.featureInfo,
539+
data.coordinate
534540
);
535541
};
536542

src/components/src/map/layer-hover-info.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ const EntryInfoRow: React.FC<EntryInfoRowProps> = ({
141141

142142
// Handle WMS layer data in comparison mode - WMS layers don't have comparable field data
143143
let primaryValue = null;
144-
let displayDeltaValue = null;
144+
let displayDeltaValue: string | null = null;
145145

146146
if (primaryData) {
147147
try {

test/node/layers/wms-layer-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ test('WMSLayer -> hover functionality', t => {
121121
t.ok(featureInfo.includes('test_layer'), 'should include layer name in feature info');
122122
t.end();
123123
})
124-
.catch(error => {
124+
.catch(_error => {
125125
t.fail('getWMSFeatureInfo should not throw error');
126126
t.end();
127127
});

0 commit comments

Comments
 (0)