@@ -30,7 +30,7 @@ export interface PermalinkStateInference extends PermalinkState {
3030
3131export interface PermalinkStateGlobal extends PermalinkState {
3232 threshold : number
33- fieldBoundariesOpacity : number
33+ opacity : number
3434 downloads : boolean
3535}
3636
@@ -39,7 +39,7 @@ export function buildGlobalPermalinkParts(settings: Settings): string[] {
3939 if ( settings . year ) {
4040 hashParts . push ( `year:${ settings . year } ` )
4141 }
42- hashParts . push ( `opacity:${ settings . fieldBoundariesOpacity } ` )
42+ hashParts . push ( `opacity:${ settings . opacity } ` )
4343 hashParts . push ( `downloads:${ settings . downloads ? 1 : 0 } ` )
4444 return hashParts
4545}
@@ -64,7 +64,7 @@ export function parsePermalinkHash(
6464 center : [ 0 , 0 ] ,
6565 year : 2025 ,
6666 threshold : 0.4 ,
67- fieldBoundariesOpacity : 90 ,
67+ opacity : 90 ,
6868 downloads : false ,
6969 }
7070
@@ -169,7 +169,7 @@ export function parsePermalinkHash(
169169 zoom,
170170 center,
171171 threshold : defaultGlobalState . threshold ,
172- fieldBoundariesOpacity : defaultGlobalState . fieldBoundariesOpacity ,
172+ opacity : defaultGlobalState . opacity ,
173173 downloads : defaultGlobalState . downloads ,
174174 }
175175
@@ -182,7 +182,7 @@ export function parsePermalinkHash(
182182 if ( ! isNaN ( year ) ) result . year = year
183183 } else if ( part . startsWith ( 'opacity:' ) ) {
184184 const opacity = parseInt ( part . substring ( 8 ) , 10 )
185- result . fieldBoundariesOpacity = isNaN ( opacity ) ? 90 : opacity
185+ result . opacity = isNaN ( opacity ) ? 90 : opacity
186186 } else if ( part . startsWith ( 'downloads:' ) ) {
187187 result . downloads = part . substring ( 10 ) === '1'
188188 }
@@ -313,7 +313,7 @@ export default function usePermalink() {
313313 center,
314314 threshold : settings . value . threshold ,
315315 year : settings . value . year ,
316- fieldBoundariesOpacity : settings . value . fieldBoundariesOpacity ,
316+ opacity : settings . value . opacity ,
317317 downloads : settings . value . downloads ,
318318 }
319319 }
@@ -351,7 +351,7 @@ export default function usePermalink() {
351351
352352 function restoreGlobalState ( state : PermalinkStateGlobal ) {
353353 settings . value . threshold = state . threshold
354- settings . value . fieldBoundariesOpacity = state . fieldBoundariesOpacity
354+ settings . value . opacity = state . opacity
355355 settings . value . downloads = state . downloads
356356 if ( state . year ) {
357357 settings . value . year = state . year
@@ -384,7 +384,7 @@ export default function usePermalink() {
384384 settings . value . areaCoverage ,
385385 settings . value . buffer ,
386386 settings . value . threshold ,
387- settings . value . fieldBoundariesOpacity ,
387+ settings . value . opacity ,
388388 settings . value . downloads ,
389389 ] ,
390390 ( ) => {
0 commit comments