diff --git a/src/components/BaselayerHistoryNavigation.tsx b/src/components/BaselayerHistoryNavigation.tsx index 3d7258d..e7cb3a0 100644 --- a/src/components/BaselayerHistoryNavigation.tsx +++ b/src/components/BaselayerHistoryNavigation.tsx @@ -1,20 +1,22 @@ import { LeftArrowIcon } from './icons/LeftArrowIcon'; import { RightArrowIcon } from './icons/RightArrowIcon'; +export type BaselayerHistoryNavigationProps = { + disableGoBack: boolean; + disableGoForward: boolean; + goBack: () => void; + goForward: () => void; +}; + export function BaselayerHistoryNavigation({ disableGoBack, disableGoForward, goBack, goForward, -}: { - disableGoBack: boolean; - disableGoForward: boolean; - goBack: () => void; - goForward: () => void; -}) { +}: BaselayerHistoryNavigationProps) { return ( <> -
+
-
+
+
diff --git a/src/components/OpenLayersMap.tsx b/src/components/OpenLayersMap.tsx index 8226b49..91b7741 100644 --- a/src/components/OpenLayersMap.tsx +++ b/src/components/OpenLayersMap.tsx @@ -43,7 +43,6 @@ import { transformGraticuleCoords, } from '../utils/layerUtils'; import { ToggleSwitch } from './ToggleSwitch'; -import { BaselayerHistoryNavigation } from './BaselayerHistoryNavigation'; export type MapProps = { baselayersState: BaselayersState; @@ -495,12 +494,6 @@ export function OpenLayersMap({
- {coordinates && ( diff --git a/src/components/icons/LockClosedIcon.tsx b/src/components/icons/LockClosedIcon.tsx new file mode 100644 index 0000000..5793fbc --- /dev/null +++ b/src/components/icons/LockClosedIcon.tsx @@ -0,0 +1,19 @@ +export function LockClosedIcon() { + return ( + + + + + ); +} diff --git a/src/components/icons/LockOpenIcon.tsx b/src/components/icons/LockOpenIcon.tsx new file mode 100644 index 0000000..d694d04 --- /dev/null +++ b/src/components/icons/LockOpenIcon.tsx @@ -0,0 +1,19 @@ +export function LockOpenIcon() { + return ( + + + + + ); +} diff --git a/src/components/styles/layer-selector.css b/src/components/styles/layer-selector.css index 2a363c0..fedab13 100644 --- a/src/components/styles/layer-selector.css +++ b/src/components/styles/layer-selector.css @@ -1,6 +1,6 @@ .layer-selector-container { position: absolute; - top: 38px; + top: 8px; right: 1em; z-index: 1000; background-color: #fff; @@ -8,8 +8,45 @@ border: 1px solid rgba(0, 0, 0, 0.2); } +.layer-selector-header { + display: flex; + align-items: center; + column-gap: 1em; + padding: 0 2px; +} + +.layer-selector-header > h3 { + margin: 0; +} + +.lock-menu-btn { + margin-right: auto; + background: none; + color: #666666; + border: 1px solid white; + border-radius: 4px; + display: flex; + align-items: center; + padding: 2px; + box-sizing: border-box; +} + +.lock-menu-btn:hover { + border: 1px solid black; + color: black; +} + +.lock-icon { + height: 0.9em; + width: 0.9em; +} + +.locked > svg { + color: #479f76; +} + .layer-selector-container > fieldset { - padding-top: 0; + padding: 0.25em 0.5em; } .layer-selector-container.btn { @@ -20,7 +57,7 @@ } .layer-selector-container.menu { - padding: 0.25em 0.5em 0.75em 0.5em; + padding: 0.5em; } .input-container { @@ -57,3 +94,9 @@ input[type='radio']:disabled { .lock-menu-container > input { height: 12px; } + +.left-arrow-icon, +.right-arrow-icon { + height: 1em; + width: 1em; +} diff --git a/src/index.css b/src/index.css index 1f6dff7..5f15de2 100644 --- a/src/index.css +++ b/src/index.css @@ -143,23 +143,3 @@ body { background-color: #921925 !important; color: white !important; } - -.bl-nav-btn-container { - position: absolute; - top: 10px; - z-index: 1000; -} - -.back-btn-container { - right: 40px; -} - -.fwd-btn-container { - right: 12px; -} - -.left-arrow-icon, -.right-arrow-icon { - height: 1.25em; - width: 1.25em; -}