Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(searchbar): move to script setup #3087

Open
wants to merge 1 commit into
base: v4
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -336,6 +336,7 @@
"name": "Searchbar",
"cName": "搜索栏",
"desc": "搜索栏",
"setup": true,
"author": "zongyue3"
},
{
Expand Down Expand Up @@ -932,4 +933,4 @@
]
}
]
}
}
13 changes: 13 additions & 0 deletions src/packages/__VUE/searchbar/doc.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,19 @@ app.use(Searchbar)
| rightin | right icon in the input box |
| rightout | right icon outside the input box |

### Types version

The component exports the following type definitions:

```js
import type {
SearchbarProps,
SearchbarInstance,
SearchbarInputAlign,
SearchbarShape,
} from '@nutui/nutui';
```

## Theming

### CSS Variables
Expand Down
13 changes: 13 additions & 0 deletions src/packages/__VUE/searchbar/doc.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,19 @@ app.use(Searchbar)
| rightin | 输入框内 右 icon |
| rightout | 输入框外 右 icon |

### 类型定义 version

组件导出以下类型定义:

```js
import type {
SearchbarProps,
SearchbarInstance,
SearchbarInputAlign,
SearchbarShape,
} from '@nutui/nutui';
```

## 主题定制

### 样式变量
Expand Down
14 changes: 14 additions & 0 deletions src/packages/__VUE/searchbar/doc.taro.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,20 @@ app.use(Searchbar)
| rightin | 输入框内 右 icon |
| rightout | 输入框外 右 icon |

### 类型定义 version

组件导出以下类型定义:

```js
import type {
SearchbarProps,
SearchbarInstance,
SearchbarInputAlign,
SearchbarConfirmType,
SearchbarShape,
} from '@nutui/nutui-taro';
```

## 主题定制

### 样式变量
Expand Down
13 changes: 13 additions & 0 deletions src/packages/__VUE/searchbar/index.taro.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import Searchbar from './searchbar.taro.vue'
import type { ComponentPublicInstance } from 'vue'
import { withInstall } from '@/packages/utils'

withInstall(Searchbar)

export type { SearchbarProps } from './searchbar.taro.vue'

export type { SearchbarInputAlign, SearchbarConfirmType, SearchbarShape } from './types'

export type SearchbarInstance = ComponentPublicInstance & InstanceType<typeof Searchbar>

export { Searchbar, Searchbar as default }
258 changes: 0 additions & 258 deletions src/packages/__VUE/searchbar/index.taro.vue

This file was deleted.

13 changes: 13 additions & 0 deletions src/packages/__VUE/searchbar/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import Searchbar from './searchbar.vue'
import type { ComponentPublicInstance } from 'vue'
import { withInstall } from '@/packages/utils'

withInstall(Searchbar)

export type { SearchbarProps } from './searchbar.vue'

export type { SearchbarInputAlign, SearchbarShape } from './types'

export type SearchbarInstance = ComponentPublicInstance & InstanceType<typeof Searchbar>

export { Searchbar, Searchbar as default }
Loading