Skip to content
This repository has been archived by the owner on Dec 6, 2021. It is now read-only.

Commit

Permalink
fix(input): placeholderClass should be string rather than object
Browse files Browse the repository at this point in the history
  • Loading branch information
b2nil committed Jan 19, 2021
1 parent 3e5c1ef commit 5d852b3
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/components/input/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -149,10 +149,11 @@ const AtInput = defineComponent({
'at-input__overlay--hidden': !inputProps.value.disabled
}))

const placeholderClasses = computed(() => ({
'placeholder': true,
[`${props.placeholderClass}`]: Boolean(props.placeholderClass)
}))
const placeholderClasses = computed(() =>
Boolean(props.placeholderClass)
? `placeholder ${props.placeholderClass}`
: 'placeholder'
)

const titleClasses = computed(() => ({
'at-input__title': true,
Expand Down

0 comments on commit 5d852b3

Please sign in to comment.