- Add style field to package.json
Should allow tools like npm-css, rework-npm, and npm-less to import the CSS by package name instead of specifying the full path.
@import "ol-layerswitcher";
- Include
src/ol-layerswitcher.css
in package to avoid breaking change
- Extended layer options now extend
ol
options directly, improves documentation and completion - All interfaces and types are exported as named exports so they can be used as needed in TypeScript projects
- Build plain
dist/ol-layerswitcher.js
from.ts
source as well as TypeScript type definition - Improved docs
- BREAKING CHANGE:
ol-layerswitcher.css
has moved fromsrc
todist
in the published package and hence unpkg.com etc. The path is now:ol-layerswitcher/dist/ol-layerswitcher.css
when importing via Webpack, Parcel etc. ordist/ol-layerswitcher.css
when loading from unpkg.com.
- Improve docs
- Format and lint
- Migrate source to TypeScript
- Build .js from .ts as well as TypeScript type definition
- New option:
startActive
- whether panel is open when created. Defaults tofalse
. - New option:
collapseTipLabel
- the button tooltip when the panel is open. - Update layout when
activationMode: 'click'
- When open displays a button to hide the panel. - Improve wrapping of long titles (see screenshots in #358).
- Format everything with Prettier and lint with ESLint.