/* eslint-disable max-len  */
import {
  SET_BASEMAP
} from 'basemap/basemapActions';

const initialState = {
  activeBasemap: 'hybrid',
  basemaps: [
    {
      title: 'hybrid',
      label: 'Satellite',
      description: 'The default satellite image view',
      type: 'GoogleBasemap'
    },
    {
      title: 'Deep Blue',
      label: 'Deep Blue',
      description: 'Custom basemap that highlights the data about fishing activity',
      type: 'Basemap',
      url: 'https://api.mapbox.com/styles/v1/enriquetuya/cj3vr6qy802b72so7jvennfkg/tiles/256/{z}/{x}/{y}?access_token=pk.eyJ1IjoiZW5yaXF1ZXR1eWEiLCJhIjoiY2loNmFwYjJuMDlzZnR4bHh3NnRyNmQxcCJ9.vf_v5i6RWNz5Q7rglf35pQ'
    },
    {
      title: 'North Star',
      label: 'North Star',
      description: 'Custom basemap showing bathymetry, parallels and ports',
      type: 'Basemap',
      url: 'https://api.mapbox.com/styles/v1/danielcaso/cj49xom6535sn2spado3w5to6/tiles/256/{z}/{x}/{y}?access_token=pk.eyJ1IjoiZGFuaWVsY2FzbyIsImEiOiJjaXVvYXB6M2gwMDF4MnRtd2c1b3lqdmh4In0.-qcuYFkQVE6U-TyfFswH9g'
    },
    {
      title: 'High Contrast',
      label: 'High Contrast',
      description: 'High contrast basemap, that highlights borders and shore. Ideal for usage with projectors',
      type: 'Basemap',
      url: 'https://api.mapbox.com/styles/v1/enriquetuya/cj3vr7wzg02cy2rpcx1kteotc/tiles/256/{z}/{x}/{y}?access_token=pk.eyJ1IjoiZW5yaXF1ZXR1eWEiLCJhIjoiY2loNmFwYjJuMDlzZnR4bHh3NnRyNmQxcCJ9.vf_v5i6RWNz5Q7rglf35pQ'
    }
  ]
};

export default function (state = initialState, action) {
  switch (action.type) {
    case SET_BASEMAP:
      return Object.assign({}, state, { activeBasemap: action.payload || state.activeBasemap });
    default:
      return state;
  }
}

@@ -309,25 +309,26 @@
 title: '
-Deep Blue
+North Star
 ',%0A     
@@ -340,17 +340,18 @@
 l: '
-Deep Blue
+North Star
 ',%0A 
@@ -388,55 +388,47 @@
 map 
-that highlights the data about fishing activity
+showing bathymetry, parallels and ports
 ',%0A 
@@ -512,31 +512,31 @@
 a/cj
-3vr6qy802b72so7jvennfkg
+6dnii820sxe2rlpl7y238fb
 /til
@@ -686,34 +686,33 @@
     title: '
-North Star
+Deep Blue
 ',%0A      lab
@@ -712,34 +712,33 @@
     label: '
-North Star
+Deep Blue
 ',%0A      des
@@ -767,47 +767,55 @@
 map 
-showing bathymetry, parallels and ports
+that highlights the data about fishing activity
 ',%0A 
@@ -885,44 +885,45 @@
 /v1/
-danielcaso/cj49xom6535sn2spado3w5to6
+enriquetuya/cj3vr6qy802b72so7jvennfkg
 /til
@@ -970,89 +970,90 @@
 joiZ
-GFuaWVsY2FzbyIsImEiOiJjaXVvYXB6M2gwMDF4MnRtd2c1b3lqdmh4In0.-qcuYFkQVE6U-TyfFswH9g
+W5yaXF1ZXR1eWEiLCJhIjoiY2loNmFwYjJuMDlzZnR4bHh3NnRyNmQxcCJ9.vf_v5i6RWNz5Q7rglf35pQ
 '%0A  

Update North Star basemap URL