Removed classcat and reworked class types from string to ClassValue
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
<script lang="ts">
|
||||
import cc from 'classcat';
|
||||
import type { PanelProps } from './types';
|
||||
import { useStore } from '$lib/store';
|
||||
|
||||
@@ -17,7 +16,7 @@
|
||||
</script>
|
||||
|
||||
<div
|
||||
class={cc(['svelte-flow__panel', className, ...positionClasses])}
|
||||
class={['svelte-flow__panel', className, ...positionClasses]}
|
||||
{style}
|
||||
style:pointer-events={store.selectionRectMode ? 'none' : ''}
|
||||
{...restProps}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import type { PanelPosition } from '@xyflow/system';
|
||||
import type { HTMLAttributes } from 'svelte/elements';
|
||||
import type { ClassValue, HTMLAttributes } from 'svelte/elements';
|
||||
|
||||
export type PanelProps = HTMLAttributes<HTMLDivElement> & {
|
||||
'data-testid'?: string;
|
||||
@@ -9,5 +9,5 @@ export type PanelProps = HTMLAttributes<HTMLDivElement> & {
|
||||
*/
|
||||
position?: PanelPosition;
|
||||
style?: string;
|
||||
class?: string;
|
||||
class?: ClassValue;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user