@versatiles/style 3.8.2 → 4.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.MD CHANGED
@@ -35,7 +35,7 @@ Use it in:
35
35
  <script src="maplibre-gl.js"></script>
36
36
  <script src="versatiles-style.js"></script>
37
37
  <script>
38
- const style = VersaTilesStyle.graybeard({
38
+ const style = VersaTilesStyle.styles.graybeard({
39
39
  tiles: ['https://???.org/tiles/osm/{z}/{x}/{y}'],
40
40
  sprite: 'https://???.org/assets/styles/swr-bright/sprite',
41
41
  glyphs: 'https://???.org/assets/fonts/{fontstack}/{range}.pbf',
@@ -62,9 +62,10 @@ npm install versatiles-style
62
62
  Use it in Node.js:
63
63
 
64
64
  ```javascript
65
- import { Colorful } from 'versatiles-style';
66
- let style = new Colorful();
67
- style.language = 'de';
65
+ import { styles } from 'versatiles-style';
66
+ let style = styles.colorful({
67
+ languageSuffix: '_en',
68
+ });
68
69
  writeFileSync('style.json', JSON.stringify(style.build()));
69
70
  ```
70
71
 
package/dist/index.d.ts CHANGED
@@ -1,9 +1,11 @@
1
1
  import type { MaplibreStyle, StylemakerOptions } from './lib/types.js';
2
+ export type { TileJSONSpecification, TileJSONSpecificationRaster, TileJSONSpecificationVector } from './lib/types.js';
2
3
  import Colorful from './style/colorful.js';
3
- export declare function colorful(options?: StylemakerOptions<Colorful>): MaplibreStyle;
4
4
  import Graybeard from './style/graybeard.js';
5
- export declare function graybeard(options?: StylemakerOptions<Graybeard>): MaplibreStyle;
6
5
  import Neutrino from './style/neutrino.js';
7
- export declare function neutrino(options?: StylemakerOptions<Neutrino>): MaplibreStyle;
8
- export type { TileJSONSpecification, TileJSONSpecificationRaster, TileJSONSpecificationVector } from './lib/types.js';
9
- export { default as guessStyle } from './lib/style_guesser.js';
6
+ export declare const styles: {
7
+ colorful: (options?: StylemakerOptions<Colorful>) => MaplibreStyle;
8
+ graybeard: (options?: StylemakerOptions<Graybeard>) => MaplibreStyle;
9
+ neutrino: (options?: StylemakerOptions<Neutrino>) => MaplibreStyle;
10
+ };
11
+ export { default as guessStyle } from './lib/guess_style.js';
package/dist/index.js CHANGED
@@ -1,13 +1,15 @@
1
1
  import Colorful from './style/colorful.js';
2
- export function colorful(options) {
3
- return new Colorful().build(options);
4
- }
5
2
  import Graybeard from './style/graybeard.js';
6
- export function graybeard(options) {
7
- return new Graybeard().build(options);
8
- }
9
3
  import Neutrino from './style/neutrino.js';
10
- export function neutrino(options) {
11
- return new Neutrino().build(options);
12
- }
13
- export { default as guessStyle } from './lib/style_guesser.js';
4
+ export const styles = {
5
+ colorful: function colorful(options) {
6
+ return new Colorful().build(options);
7
+ },
8
+ graybeard: function graybeard(options) {
9
+ return new Graybeard().build(options);
10
+ },
11
+ neutrino: function neutrino(options) {
12
+ return new Neutrino().build(options);
13
+ },
14
+ };
15
+ export { default as guessStyle } from './lib/guess_style.js';
@@ -1,17 +1,16 @@
1
1
  /* eslint-disable @typescript-eslint/naming-convention */
2
- import * as builders from './index.js';
3
- describe('Style Builders', () => {
4
- const styles = [
5
- { name: 'Colorful', builder: builders.colorful },
6
- { name: 'Graybeard', builder: builders.graybeard },
7
- { name: 'Neutrino', builder: builders.neutrino },
8
- ];
9
- styles.forEach(({ name, builder }) => {
2
+ import { guessStyle, styles } from './index.js';
3
+ describe('styles', () => {
4
+ it('should be all styles', () => {
5
+ expect(Array.from(Object.keys(styles)).sort())
6
+ .toStrictEqual(['colorful', 'graybeard', 'neutrino']);
7
+ });
8
+ Object.entries(styles).forEach(([name, builder]) => {
10
9
  it(`should create and test an instance of ${name}`, () => {
11
10
  expect(typeof builder).toBe('function');
12
11
  const style = builder({ baseUrl: 'https://example.org' });
13
12
  expect(JSON.stringify(style).length).toBeGreaterThan(50000);
14
- expect(style.name).toBe('versatiles-' + name.toLowerCase());
13
+ expect(style.name).toBe('versatiles-' + name);
15
14
  expect(style.glyphs).toBe('https://example.org/assets/fonts/{fontstack}/{range}.pbf');
16
15
  expect(style.sprite).toBe('https://example.org/assets/sprites/sprites');
17
16
  expect(Object.keys(style.sources).join(',')).toBe('versatiles-shortbread');
@@ -20,7 +19,7 @@ describe('Style Builders', () => {
20
19
  });
21
20
  });
22
21
  describe('Colorful', () => {
23
- const style = builders.colorful({
22
+ const style = styles.colorful({
24
23
  baseUrl: 'https://dev.null',
25
24
  colors: { commercial: '#f00' },
26
25
  });
@@ -38,7 +37,7 @@ describe('guessStyle', () => {
38
37
  const tiles = ['https://fancy.map/tiles/{z}/{x}/{y}'];
39
38
  const vectorLayers = [{ id: 'hallo', fields: { label: 'String' } }];
40
39
  it('should build raster styles', () => {
41
- const style = builders.guessStyle({
40
+ const style = guessStyle({
42
41
  tiles,
43
42
  format: 'png',
44
43
  });
@@ -49,7 +48,7 @@ describe('guessStyle', () => {
49
48
  });
50
49
  });
51
50
  it('should build vector styles', () => {
52
- const style = builders.guessStyle({
51
+ const style = guessStyle({
53
52
  tiles,
54
53
  format: 'pbf',
55
54
  vectorLayers,
@@ -1,6 +1,6 @@
1
1
  /* eslint-disable @typescript-eslint/naming-convention */
2
2
  import Color from 'color';
3
- import StyleBuilder from './style_builder.js';
3
+ import StyleBuilder from './build_style.js';
4
4
  // Mock class for abstract class StyleBuilder
5
5
  class MockStyleBuilder extends StyleBuilder {
6
6
  name = 'mock';
@@ -1,6 +1,6 @@
1
1
  /* eslint-disable @typescript-eslint/naming-convention */
2
2
  import getTemplate from './shortbread/template.js';
3
- import guessStyle from './style_guesser.js';
3
+ import guessStyle from './guess_style.js';
4
4
  describe('guessStyle', () => {
5
5
  const tiles = ['https://example.com/tiles/{z}/{x}/{y}'];
6
6
  const vectorLayersSomething = [{ id: 'geometry', fields: { label: 'String', height: 'Number' } }];
@@ -1,4 +1,4 @@
1
1
  import type { RecolorOptions, StylemakerColors } from './types.js';
2
- import type StyleBuilder from './style_builder.ts';
2
+ import type StyleBuilder from './build_style.ts';
3
3
  export declare function getDefaultRecolorFlags(): RecolorOptions;
4
4
  export declare function recolor<Subclass extends StyleBuilder<Subclass>>(colors: StylemakerColors<Subclass>, opt?: RecolorOptions): void;
@@ -1,5 +1,5 @@
1
1
  import type { StyleRules, StyleRulesOptions } from './types.js';
2
- import StyleBuilder from './style_builder.js';
2
+ import StyleBuilder from './build_style.js';
3
3
  export default class TestStyle extends StyleBuilder<TestStyle> {
4
4
  readonly name: string;
5
5
  defaultFonts: {};
@@ -1,5 +1,5 @@
1
1
  import { getDefaultRecolorFlags, recolor } from './recolor.js';
2
- import StyleBuilder from './style_builder.js';
2
+ import StyleBuilder from './build_style.js';
3
3
  describe('colorTransformer', () => {
4
4
  describe('getDefaultRecolorFlags', () => {
5
5
  it('should return the default color transformer flags', () => {
@@ -1,6 +1,6 @@
1
1
  import type { BackgroundLayerSpecification, FillLayerSpecification, FilterSpecification, LineLayerSpecification, StyleSpecification, SymbolLayerSpecification } from '@maplibre/maplibre-gl-style-spec';
2
2
  import type Color from 'color';
3
- import type StyleBuilder from './style_builder.ts';
3
+ import type StyleBuilder from './build_style.ts';
4
4
  /** Represents the available tile formats. */
5
5
  export type TileFormat = 'avif' | 'bin' | 'geojson' | 'jpg' | 'json' | 'pbf' | 'png' | 'svg' | 'topojson' | 'webp';
6
6
  /** Type for Maplibre layers, including background, fill, line, and symbol specifications. */
@@ -1,4 +1,4 @@
1
- import StyleBuilder from '../lib/style_builder.js';
1
+ import StyleBuilder from '../lib/build_style.js';
2
2
  import type { StyleRules, StyleRulesOptions } from '../lib/types.js';
3
3
  export default class Colorful extends StyleBuilder<Colorful> {
4
4
  readonly name: string;
@@ -1,5 +1,5 @@
1
1
  /* eslint-disable @typescript-eslint/naming-convention */
2
- import StyleBuilder from '../lib/style_builder.js';
2
+ import StyleBuilder from '../lib/build_style.js';
3
3
  export default class Colorful extends StyleBuilder {
4
4
  name = 'Colorful';
5
5
  defaultFonts = {
@@ -672,37 +672,37 @@ export default class Colorful extends StyleBuilder {
672
672
  },
673
673
  'symbol-transit-airport': {
674
674
  minzoom: 12,
675
- image: 'icon-airport-22',
675
+ image: 'icon-airport',
676
676
  iconSize: { 12: 0.5, 14: 1 },
677
677
  },
678
678
  'symbol-transit-airfield': {
679
679
  minzoom: 13,
680
- image: 'icon-airfield-22',
680
+ image: 'icon-airfield',
681
681
  iconSize: { 13: 0.5, 15: 1 },
682
682
  },
683
683
  'symbol-transit-station': {
684
684
  minzoom: 13,
685
- image: 'icon-rail-22',
685
+ image: 'icon-rail',
686
686
  iconSize: { 13: 0.5, 15: 1 },
687
687
  },
688
688
  'symbol-transit-lightrail': {
689
689
  minzoom: 14,
690
- image: 'icon-rail-light-22',
690
+ image: 'icon-rail-light',
691
691
  iconSize: { 14: 0.5, 16: 1 },
692
692
  },
693
693
  'symbol-transit-subway': {
694
694
  minzoom: 14,
695
- image: 'icon-rail-metro-22',
695
+ image: 'icon-rail-metro',
696
696
  iconSize: { 14: 0.5, 16: 1 },
697
697
  },
698
698
  'symbol-transit-tram': {
699
699
  minzoom: 15,
700
- image: 'transport-tram-22',
700
+ image: 'transport-tram',
701
701
  iconSize: { 15: 0.5, 17: 1 },
702
702
  },
703
703
  'symbol-transit-bus': {
704
704
  minzoom: 16,
705
- image: 'icon-bus-22',
705
+ image: 'icon-bus',
706
706
  iconSize: { 16: 0.5, 18: 1 },
707
707
  },
708
708
  // TODO: localized symbols? depends on shortbread
@@ -719,175 +719,175 @@ export default class Colorful extends StyleBuilder {
719
719
  'poi-amenity': {
720
720
  image: ['match',
721
721
  ['get', 'amenity'],
722
- 'arts_centre', 'icon-art_gallery-22',
723
- 'atm', 'icon-atm-22',
724
- 'bank', 'icon-bank-22',
725
- 'bar', 'icon-bar-22',
726
- 'bench', 'icon-bench-22',
727
- 'bicycle_rental', 'icon-bicycle_share-22',
728
- 'biergarten', 'icon-beergarden-22',
729
- 'cafe', 'icon-cafe-22',
730
- 'car_rental', 'icon-car_rental-22',
731
- 'car_sharing', 'icon-car_rental-22',
732
- 'car_wash', 'icon-car_wash-22',
733
- 'cinema', 'icon-cinema-22',
734
- //'clinic', 'icon-clinic-22',
735
- 'college', 'icon-college-22',
736
- 'community_centre', 'icon-community-22',
737
- //'courthouse', 'icon-courthouse-22',
738
- 'dentist', 'icon-dentist-22',
739
- 'doctors', 'icon-doctor-22',
740
- 'dog_park', 'icon-dog_park-22',
741
- 'drinking_water', 'icon-drinking_water-22',
742
- 'embassy', 'icon-embassy-22',
743
- 'fast_food', 'icon-fast_food-22',
744
- 'fire_station', 'icon-fire_station-22',
745
- //'food_court', 'icon-food_court-22',
746
- 'fountain', 'icon-fountain-22',
747
- 'grave_yard', 'icon-cemetery-22',
748
- 'hospital', 'icon-hospital-22',
749
- 'hunting_stand', 'icon-huntingstand-22',
750
- 'library', 'icon-library-22',
751
- 'marketplace', 'icon-marketplace-22',
752
- 'nightclub', 'icon-nightclub-22',
753
- 'nursing_home', 'icon-nursinghome-22',
754
- 'pharmacy', 'icon-pharmacy-22',
755
- 'place_of_worship', 'icon-place_of_worship-22',
756
- 'playground', 'icon-playground-22',
757
- 'police', 'icon-police-22',
758
- 'post_box', 'icon-post_box-22',
759
- 'post_office', 'icon-post-22',
760
- 'prison', 'icon-prison-22',
761
- 'pub', 'icon-beer-22',
762
- //'public_building', 'icon-public_building-22',
763
- 'recycling', 'icon-recycling-22',
764
- 'restaurant', 'icon-restaurant-22',
765
- 'school', 'icon-school-22',
766
- 'shelter', 'icon-shelter-22',
767
- 'telephone', 'icon-telephone-22',
768
- 'theatre', 'icon-theatre-22',
769
- 'toilets', 'icon-toilet-22',
770
- 'townhall', 'icon-town_hall-22',
771
- //'university', 'icon-university-22',
772
- 'vending_machine', 'icon-vendingmachine-22',
773
- 'veterinary', 'icon-veterinary-22',
774
- 'waste_basket', 'icon-waste_basket-22',
722
+ 'arts_centre', 'icon-art_gallery',
723
+ 'atm', 'icon-atm',
724
+ 'bank', 'icon-bank',
725
+ 'bar', 'icon-bar',
726
+ 'bench', 'icon-bench',
727
+ 'bicycle_rental', 'icon-bicycle_share',
728
+ 'biergarten', 'icon-beergarden',
729
+ 'cafe', 'icon-cafe',
730
+ 'car_rental', 'icon-car_rental',
731
+ 'car_sharing', 'icon-car_rental',
732
+ 'car_wash', 'icon-car_wash',
733
+ 'cinema', 'icon-cinema',
734
+ //'clinic', 'icon-clinic',
735
+ 'college', 'icon-college',
736
+ 'community_centre', 'icon-community',
737
+ //'courthouse', 'icon-courthouse',
738
+ 'dentist', 'icon-dentist',
739
+ 'doctors', 'icon-doctor',
740
+ 'dog_park', 'icon-dog_park',
741
+ 'drinking_water', 'icon-drinking_water',
742
+ 'embassy', 'icon-embassy',
743
+ 'fast_food', 'icon-fast_food',
744
+ 'fire_station', 'icon-fire_station',
745
+ //'food_court', 'icon-food_court',
746
+ 'fountain', 'icon-fountain',
747
+ 'grave_yard', 'icon-cemetery',
748
+ 'hospital', 'icon-hospital',
749
+ 'hunting_stand', 'icon-huntingstand',
750
+ 'library', 'icon-library',
751
+ 'marketplace', 'icon-marketplace',
752
+ 'nightclub', 'icon-nightclub',
753
+ 'nursing_home', 'icon-nursinghome',
754
+ 'pharmacy', 'icon-pharmacy',
755
+ 'place_of_worship', 'icon-place_of_worship',
756
+ 'playground', 'icon-playground',
757
+ 'police', 'icon-police',
758
+ 'post_box', 'icon-post_box',
759
+ 'post_office', 'icon-post',
760
+ 'prison', 'icon-prison',
761
+ 'pub', 'icon-beer',
762
+ //'public_building', 'icon-public_building',
763
+ 'recycling', 'icon-recycling',
764
+ 'restaurant', 'icon-restaurant',
765
+ 'school', 'icon-school',
766
+ 'shelter', 'icon-shelter',
767
+ 'telephone', 'icon-telephone',
768
+ 'theatre', 'icon-theatre',
769
+ 'toilets', 'icon-toilet',
770
+ 'townhall', 'icon-town_hall',
771
+ //'university', 'icon-university',
772
+ 'vending_machine', 'icon-vendingmachine',
773
+ 'veterinary', 'icon-veterinary',
774
+ 'waste_basket', 'icon-waste_basket',
775
775
  'UNDEFINED',
776
776
  ],
777
777
  },
778
778
  'poi-leisure': {
779
779
  image: ['match',
780
780
  ['get', 'leisure'],
781
- 'golf_course', 'icon-golf-22',
782
- 'ice_rink', 'icon-icerink-22',
783
- 'pitch', 'icon-pitch-22',
784
- //'sports_centre', 'icon-sports_centre-22',
785
- 'stadium', 'icon-stadium-22',
786
- 'swimming_pool', 'icon-swimming-22',
787
- 'water_park', 'icon-waterpark-22',
788
- 'icon-sports-22',
781
+ 'golf_course', 'icon-golf',
782
+ 'ice_rink', 'icon-icerink',
783
+ 'pitch', 'icon-pitch',
784
+ //'sports_centre', 'icon-sports_centre',
785
+ 'stadium', 'icon-stadium',
786
+ 'swimming_pool', 'icon-swimming',
787
+ 'water_park', 'icon-waterpark',
788
+ 'icon-sports',
789
789
  ],
790
790
  },
791
791
  'poi-tourism': {
792
792
  image: ['match',
793
793
  ['get', 'tourism'],
794
- //'alpine_hut', 'icon-alpine_hut-22',
795
- //'bed_and_breakfast', 'icon-bed_and_breakfast-22',
796
- //'camp_site', 'icon-camp_site-22',
797
- //'caravan_site', 'icon-caravan_site-22',
798
- 'chalet', 'icon-chalet-22',
799
- //'guest_house', 'icon-guest_house-22',
800
- //'hostel', 'icon-hostel-22',
801
- //'hotel', 'icon-hotel-22',
802
- 'information', 'transport-information-22',
803
- //'motel', 'icon-motel-22',
804
- 'picnic_site', 'icon-picnic_site-22',
805
- //'theme_park', 'icon-theme_park-22',
806
- 'viewpoint', 'icon-viewpoint-22',
807
- 'zoo', 'icon-zoo-22',
794
+ //'alpine_hut', 'icon-alpine_hut',
795
+ //'bed_and_breakfast', 'icon-bed_and_breakfast',
796
+ //'camp_site', 'icon-camp_site',
797
+ //'caravan_site', 'icon-caravan_site',
798
+ 'chalet', 'icon-chalet',
799
+ //'guest_house', 'icon-guest_house',
800
+ //'hostel', 'icon-hostel',
801
+ //'hotel', 'icon-hotel',
802
+ 'information', 'transport-information',
803
+ //'motel', 'icon-motel',
804
+ 'picnic_site', 'icon-picnic_site',
805
+ //'theme_park', 'icon-theme_park',
806
+ 'viewpoint', 'icon-viewpoint',
807
+ 'zoo', 'icon-zoo',
808
808
  'UNDEFINED',
809
809
  ],
810
810
  },
811
811
  'poi-shop': {
812
812
  image: ['match',
813
813
  ['get', 'shop'],
814
- 'alcohol', 'icon-alcohol_shop-22',
815
- 'bakery', 'icon-bakery-22',
816
- 'beauty', 'icon-beauty-22',
817
- 'beverages', 'icon-beverages-22',
818
- //'bicycle', 'icon-bicycle-22',
819
- 'books', 'icon-books-22',
820
- 'butcher', 'icon-butcher-22',
821
- //'car', 'icon-car-22',
822
- 'chemist', 'icon-chemist-22',
823
- 'clothes', 'icon-clothes-22',
824
- //'computer', 'icon-computer-22',
825
- //'convinience', 'icon-convinience-22',
826
- //'department_store', 'icon-department_store-22',
827
- 'doityourself', 'icon-doityourself-22',
828
- 'dry_cleaning', 'icon-drycleaning-22',
829
- 'florist', 'icon-florist-22',
830
- 'furniture', 'icon-furniture-22',
831
- 'garden_centre', 'icon-garden_centre-22',
832
- 'general', 'icon-shop-22',
833
- 'gift', 'icon-gift-22',
834
- 'greengrocer', 'icon-greengrocer-22',
835
- 'hairdresser', 'icon-hairdresser-22',
836
- 'hardware', 'icon-hardware-22',
837
- 'jewelry', 'icon-jewelry_store-22',
838
- 'kiosk', 'icon-kiosk-22',
839
- 'laundry', 'icon-laundry-22',
840
- //'mall', 'icon-mall-22',
841
- //'mobile_phone', 'icon-mobile_phone-22',
842
- 'newsagent', 'icon-newsagent-22',
843
- 'optican', 'icon-optician-22',
844
- 'outdoor', 'icon-outdoor-22',
845
- 'shoes', 'icon-shoes-22',
846
- 'sports', 'icon-sports-22',
847
- 'stationery', 'icon-stationery-22',
848
- //'supermarket', 'icon-supermarket-22',
849
- 'toys', 'icon-toys-22',
850
- 'travel_agency', 'icon-travel_agent-22',
851
- 'video', 'icon-video-22',
852
- 'icon-shop-22',
814
+ 'alcohol', 'icon-alcohol_shop',
815
+ 'bakery', 'icon-bakery',
816
+ 'beauty', 'icon-beauty',
817
+ 'beverages', 'icon-beverages',
818
+ //'bicycle', 'icon-bicycle',
819
+ 'books', 'icon-books',
820
+ 'butcher', 'icon-butcher',
821
+ //'car', 'icon-car',
822
+ 'chemist', 'icon-chemist',
823
+ 'clothes', 'icon-clothes',
824
+ //'computer', 'icon-computer',
825
+ //'convinience', 'icon-convinience',
826
+ //'department_store', 'icon-department_store',
827
+ 'doityourself', 'icon-doityourself',
828
+ 'dry_cleaning', 'icon-drycleaning',
829
+ 'florist', 'icon-florist',
830
+ 'furniture', 'icon-furniture',
831
+ 'garden_centre', 'icon-garden_centre',
832
+ 'general', 'icon-shop',
833
+ 'gift', 'icon-gift',
834
+ 'greengrocer', 'icon-greengrocer',
835
+ 'hairdresser', 'icon-hairdresser',
836
+ 'hardware', 'icon-hardware',
837
+ 'jewelry', 'icon-jewelry_store',
838
+ 'kiosk', 'icon-kiosk',
839
+ 'laundry', 'icon-laundry',
840
+ //'mall', 'icon-mall',
841
+ //'mobile_phone', 'icon-mobile_phone',
842
+ 'newsagent', 'icon-newsagent',
843
+ 'optican', 'icon-optician',
844
+ 'outdoor', 'icon-outdoor',
845
+ 'shoes', 'icon-shoes',
846
+ 'sports', 'icon-sports',
847
+ 'stationery', 'icon-stationery',
848
+ //'supermarket', 'icon-supermarket',
849
+ 'toys', 'icon-toys',
850
+ 'travel_agency', 'icon-travel_agent',
851
+ 'video', 'icon-video',
852
+ 'icon-shop',
853
853
  ],
854
854
  },
855
855
  'poi-man_made': {
856
856
  image: ['match',
857
857
  ['get', 'man_made'],
858
- 'lighthouse', 'icon-lighthouse-22',
859
- 'surveillance', 'icon-surveillance-22',
860
- 'tower', 'icon-observation_tower-22',
861
- //'wastewater_plant', 'icon-wastewater_plant-22',
862
- //'water_well', 'icon-water_well-22',
863
- //'water_works', 'icon-water_works-22',
864
- 'watermill', 'icon-watermill-22',
865
- 'windmill', 'icon-windmill-22',
858
+ 'lighthouse', 'icon-lighthouse',
859
+ 'surveillance', 'icon-surveillance',
860
+ 'tower', 'icon-observation_tower',
861
+ //'wastewater_plant', 'icon-wastewater_plant',
862
+ //'water_well', 'icon-water_well',
863
+ //'water_works', 'icon-water_works',
864
+ 'watermill', 'icon-watermill',
865
+ 'windmill', 'icon-windmill',
866
866
  'UNDEFINED',
867
867
  ],
868
868
  },
869
869
  'poi-historic': {
870
870
  image: ['match',
871
871
  ['get', 'historic'],
872
- //'archaelogical_site', 'icon-archaelogical_site-22',
873
- 'artwork', 'icon-artwork-22',
874
- //'battlefield', 'icon-battlefield-22',
875
- 'castle', 'icon-castle-22',
876
- //'fort', 'icon-fort-22',
877
- //'memorial', 'icon-memorial-22',
878
- 'monument', 'icon-monument-22',
879
- //'ruins', 'icon-ruins-22',
880
- //'wayside_cross', 'icon-wayside_cross-22',
881
- 'wayside_shrine', 'icon-shrine-22',
882
- 'icon-historic-22',
872
+ //'archaelogical_site', 'icon-archaelogical_site',
873
+ 'artwork', 'icon-artwork',
874
+ //'battlefield', 'icon-battlefield',
875
+ 'castle', 'icon-castle',
876
+ //'fort', 'icon-fort',
877
+ //'memorial', 'icon-memorial',
878
+ 'monument', 'icon-monument',
879
+ //'ruins', 'icon-ruins',
880
+ //'wayside_cross', 'icon-wayside_cross',
881
+ 'wayside_shrine', 'icon-shrine',
882
+ 'icon-historic',
883
883
  ],
884
884
  },
885
885
  'poi-emergency': {
886
886
  image: ['match',
887
887
  ['get', 'emergency'],
888
- 'defibrillator', 'icon-defibrillator-22',
889
- 'fire_hydrant', 'icon-hydrant-22',
890
- 'phone', 'icon-emergency_phone-22',
888
+ 'defibrillator', 'icon-defibrillator',
889
+ 'fire_hydrant', 'icon-hydrant',
890
+ 'phone', 'icon-emergency_phone',
891
891
  'UNDEFINED',
892
892
  ],
893
893
  },
@@ -895,14 +895,14 @@ export default class Colorful extends StyleBuilder {
895
895
  'poi-highway': {
896
896
  image: ['match',
897
897
  ['get', 'highway'],
898
- //'emergency_access_point', 'icon-emergency_access_point-22',
898
+ //'emergency_access_point', 'icon-emergency_access_point',
899
899
  'UNDEFINED'
900
900
  ]
901
901
  },
902
902
  'poi-office': {
903
903
  image: ['match',
904
904
  ['get', 'office'],
905
- //'diplomatic', 'icon-diplomatic-22',
905
+ //'diplomatic', 'icon-diplomatic',
906
906
  'UNDEFINED'
907
907
  ]
908
908
  },
@@ -1,4 +1,4 @@
1
- import StyleBuilder from '../lib/style_builder.js';
1
+ import StyleBuilder from '../lib/build_style.js';
2
2
  import type { StyleRules, StyleRulesOptions } from '../lib/types.js';
3
3
  export default class Neutrino extends StyleBuilder<Neutrino> {
4
4
  readonly name: string;
@@ -1,5 +1,5 @@
1
1
  /* eslint-disable @typescript-eslint/naming-convention */
2
- import StyleBuilder from '../lib/style_builder.js';
2
+ import StyleBuilder from '../lib/build_style.js';
3
3
  export default class Neutrino extends StyleBuilder {
4
4
  name = 'Neutrino';
5
5
  defaultFonts = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@versatiles/style",
3
- "version": "3.8.2",
3
+ "version": "4.0.1",
4
4
  "description": "Generate StyleJSON for MapLibre",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -45,7 +45,7 @@
45
45
  "@types/brace-expansion": "^1.1.2",
46
46
  "@types/inquirer": "^9.0.7",
47
47
  "@types/jest": "^29.5.12",
48
- "@types/node": "^20.11.17",
48
+ "@types/node": "^20.11.19",
49
49
  "@typescript-eslint/eslint-plugin": "^7.0.1",
50
50
  "@typescript-eslint/parser": "^7.0.1",
51
51
  "@versatiles/release-tool": "^1.2.1",
@@ -55,7 +55,7 @@
55
55
  "jest-environment-jsdom": "^29.7.0",
56
56
  "jest-ts-webcompat-resolver": "^1.0.0",
57
57
  "npm-check-updates": "^16.14.15",
58
- "rollup": "^4.10.0",
58
+ "rollup": "^4.11.0",
59
59
  "rollup-plugin-dts": "^6.1.0",
60
60
  "ts-jest": "^29.1.2",
61
61
  "ts-node": "^10.9.2",
File without changes
File without changes