Skip to content

Commit

Permalink
Merge pull request #25 from YUUKIToriyama/add-types
Browse files Browse the repository at this point in the history
add L.Control.Opacity.d.ts
  • Loading branch information
dayjournal authored Sep 5, 2021
2 parents e5e4c82 + 25492f3 commit 1554ebe
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
18 changes: 18 additions & 0 deletions dist/L.Control.Opacity.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import * as Leaflet from "leaflet";

declare module "leaflet" {
interface OpacityOptions extends Leaflet.ControlOptions {
collapsed?: boolean
label?: string | null
}
namespace Control {
class Opacity extends Leaflet.Control {
constructor(
options?: OpacityOptions
)
}
}
namespace control {
function opacity(overlays: { [key: string]: L.Layer }, options: OpacityOptions): L.Control.Opacity
}
}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"version": "1.5.0",
"description": "Leaflet.Control.Opacity is a Leaflet plugin that makes multiple tile layers transparent. (Leaflet v1.x.x)",
"main": "dist/L.Control.Opacity.js",
"types": "dist/L.Control.Opacity.d.ts",
"repository": {
"type": "git",
"url": "git+https://github.com/dayjournal/Leaflet.Control.Opacity.git"
Expand Down

0 comments on commit 1554ebe

Please sign in to comment.