Skip to content

Commit

Permalink
Cast expression operator to a string for now
Browse files Browse the repository at this point in the history
  • Loading branch information
HeyZoos committed Nov 16, 2024
1 parent 1949087 commit f1c6845
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/components/MapLegendControl/MapLegend.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { ExpressionName } from 'mapbox-gl';
import React, { ReactElement, Dispatch, SetStateAction } from 'react';
import { renderToStaticMarkup } from 'react-dom/server';
import { FillLayerSpecification } from 'maplibre-gl';
Expand All @@ -25,7 +24,7 @@ function parseBlocks(
if (value && Array.isArray(value) && value.length > 0) {
const [name, ...args] = value;

switch (name as ExpressionName) {
switch (name as string) {
case 'match': {
const [getter, ...paneLabels] = args;
const elements: ReactElement[] = [];
Expand Down

0 comments on commit f1c6845

Please sign in to comment.