-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: show the placeholder if there are no selection options in the s…
…election
- Loading branch information
1 parent
bf8d511
commit ea12d9d
Showing
4 changed files
with
52 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"unify-ui": patch | ||
--- | ||
|
||
Show the placeholder if there are no selection options in the selection |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<script setup lang="ts"> | ||
import { ref } from "vue"; | ||
import { UniSelect, UniSelectOption } from "@/components"; | ||
const options: { label: string; value: string }[] = []; | ||
const value = ref<string>(); | ||
</script> | ||
|
||
<template> | ||
<div class="container"> | ||
<UniSelect v-model="value"> | ||
<UniSelectOption | ||
v-for="item in options" | ||
:key="item.value" | ||
:label="item.label" | ||
:value="item.value" | ||
></UniSelectOption> | ||
</UniSelect> | ||
</div> | ||
</template> | ||
|
||
<style scoped> | ||
.container { | ||
width: 500px; | ||
height: 500px; | ||
padding: 20px; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters