ElemeFE / ElemeFE/element

[Bug Report] 组件类型丢失

Open
#22,883 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Vue
Stars
54k
Forks
14.4k
PR merge metrics
No merged PRs in 30d

Description

### Element UI version
2.15.14

### OS/Browsers version
windows / google

### Vue version
2.7.16

### Reproduction Link
https://stackblitz.com/edit/vitejs-vite-rwxhvw?file=package.json

### Steps to reproduce
使用组件时无类型提示

![image](https://github.com/ElemeFE/element/assets/67454874/2c408e7a-5252-4b0b-adbf-1251938450b5)

### What is Expected?
有正确的组件类型提示
```ts
import { ElementUIComponent, ElementUIComponentSize } from './component'

/** Button type */
export type ButtonType = 'primary' | 'success' | 'warning' | 'danger' | 'info' | 'text'

/** Same as native button's type */
export type ButtonNativeType = 'button' | 'submit' | 'reset' | 'menu'

/** Button Component */
export declare class ElButton extends ElementUIComponent {
/** Button size */
size: ElementUIComponentSize

/** Button type */
type: ButtonType

/** Determine whether it's a plain button */
plain: boolean

/** Determine whether it's a round button */
round: boolean

/** Determine whether it's loading */
loading: boolean

/** Disable the button */
disabled: boolean

/** Button icon, accepts an icon name of Element icon component */
icon: string

/** Same as native button's autofocus */
autofocus: boolean

/** Same as native button's type */
nativeType: ButtonNativeType
}
```

### What is actually happening?

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.