From c505e41eb4e9290b6e79745264cb99960c58481f Mon Sep 17 00:00:00 2001 From: Jan-Henning Wegener Date: Tue, 12 Sep 2017 10:18:01 +0200 Subject: [PATCH] Add missing Type "ol.StyleFunction" to ol.Feature.setStlye. Add also missing ReturnType "ol.StyleFunction" to ol.Feature.getStlye. https://github.com/DefinitelyTyped/DefinitelyTyped/issues/19688 [openlayers] Adding missing Type ol.StyleFunction to ol.Feature.setStyle #19688 --- types/openlayers/index.d.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/types/openlayers/index.d.ts b/types/openlayers/index.d.ts index d149ef18bc..f2eb6a8b53 100644 --- a/types/openlayers/index.d.ts +++ b/types/openlayers/index.d.ts @@ -1830,11 +1830,11 @@ declare module ol { * Get the feature's style. This return for this method depends on what was * provided to the {@link ol.Feature#setStyle} method. * @return {ol.style.Style|Array.| - * ol.FeatureStyleFunction} The feature style. + * ol.FeatureStyleFunction|ol.StyleFunction} The feature style. * @api stable * @observable */ - getStyle(): (ol.style.Style | ol.style.Style[] | ol.FeatureStyleFunction); + getStyle(): (ol.style.Style | ol.style.Style[] | ol.FeatureStyleFunction | ol.StyleFunction); /** * Get the feature's style function. @@ -1858,11 +1858,11 @@ declare module ol { * of styles, or a function that takes a resolution and returns an array of * styles. If it is `null` the feature has no style (a `null` style). * @param {ol.style.Style|Array.| - * ol.FeatureStyleFunction} style Style for this feature. + * ol.FeatureStyleFunction|ol.StyleFunction} style Style for this feature. * @api stable * @observable */ - setStyle(style: (ol.style.Style | ol.style.Style[] | ol.FeatureStyleFunction)): void; + setStyle(style: (ol.style.Style | ol.style.Style[] | ol.FeatureStyleFunction | ol.StyleFunction)): void; /** * Set the feature id. The feature id is considered stable and may be used when @@ -10590,7 +10590,7 @@ declare module ol { * @api */ clone(): ol.style.Style; - + /** * Get the geometry to be rendered. * @return {string|ol.geom.Geometry|ol.StyleGeometryFunction}