2023-10-16 15:09:13 +08:00
|
|
|
import { VueTypeValidableDef, VueTypesInterface, createTypes, toValidableType } from 'vue-types'
|
2023-02-11 00:44:00 +08:00
|
|
|
import { CSSProperties } from 'vue'
|
|
|
|
|
|
|
|
type PropTypes = VueTypesInterface & {
|
|
|
|
readonly style: VueTypeValidableDef<CSSProperties>
|
|
|
|
}
|
2023-10-16 15:09:13 +08:00
|
|
|
const newPropTypes = createTypes({
|
2023-02-11 00:44:00 +08:00
|
|
|
func: undefined,
|
|
|
|
bool: undefined,
|
|
|
|
string: undefined,
|
|
|
|
number: undefined,
|
|
|
|
object: undefined,
|
|
|
|
integer: undefined
|
|
|
|
}) as PropTypes
|
|
|
|
|
2023-10-16 15:09:13 +08:00
|
|
|
class propTypes extends newPropTypes {
|
|
|
|
static get style() {
|
|
|
|
return toValidableType('style', {
|
|
|
|
type: [String, Object]
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-02-11 00:44:00 +08:00
|
|
|
export { propTypes }
|