Skip to content

Commit b2ae1cd

Browse files
committed
fix(core): typedef issue of JSX events binding(#28)
1 parent a3f70b0 commit b2ae1cd

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/core/src/styled.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import domElements, { type SupportedHTMLElements } from '@/src/constants/domElem
1515
import { type ExpressionType, generateClassName, generateComponentName, insertExpressions, injectStyle, removeStyle } from '@/src/utils'
1616
import { isStyledComponent, isValidElementType, isVueComponent } from '@/src/helper'
1717
import type { DefaultTheme } from './providers/theme'
18+
import { JSX } from 'vue/jsx-runtime'
1819

1920
type Attrs = Record<string, any>
2021

@@ -32,7 +33,7 @@ interface StyledComponent<T extends object> {
3233
| ExpressionType<BaseContext<P & ExtractPropTypes<PropsDefinition<T>>>>
3334
| ExpressionType<BaseContext<P & ExtractPropTypes<PropsDefinition<T>>>>[]
3435
)[]
35-
): DefineSetupFnComponent<{ as?: string; props?: P } & ExtractPropTypes<PropsDefinition<T>>>
36+
): DefineSetupFnComponent<{ as?: string; props?: P } & ExtractPropTypes<PropsDefinition<T>> & JSX.IntrinsicElements['div']>
3637

3738
attrs<A extends Attrs = Record<string, any>>(attrs: A): StyledComponent<T>
3839
}

0 commit comments

Comments
 (0)