- 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.cssin package to avoid breaking change
- Extended layer options now extend
oloptions 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.jsfrom.tssource as well as TypeScript type definition - Improved docs
- BREAKING CHANGE:
ol-layerswitcher.csshas moved fromsrctodistin the published package and hence unpkg.com etc. The path is now:ol-layerswitcher/dist/ol-layerswitcher.csswhen importing via Webpack, Parcel etc. ordist/ol-layerswitcher.csswhen 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.