Skip to content

Commit

Permalink
fix(LayerProperties): don't show slider until view loads layer
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulHax committed Nov 8, 2024
1 parent 49edb19 commit be0d909
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/components/LayerProperties.vue
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,12 @@ export default defineComponent({
const blendConfig = computed(
() =>
// assume one 2D view has mounted
layerConfigs.value.find(({ config }) => config)!.config!.blendConfig
// may be undefined if a 2D view has not been mounted
layerConfigs.value.find(({ config }) => config)?.config?.blendConfig
);
const setBlendConfig = (key: keyof BlendConfig, value: any) => {
if (layerConfigs.value.length === 0) return;
layerConfigs.value.forEach(({ viewID }) =>
layerColoringStore.updateBlendConfig(viewID, layerID.value, {
[key]: value,
Expand Down

0 comments on commit be0d909

Please sign in to comment.