primevue-mirror/components/lib/textarea/BaseTextarea.vue

46 lines
862 B
Vue
Raw Normal View History

2023-05-24 14:15:21 +00:00
<script>
import BaseComponent from 'primevue/basecomponent';
import { useStyle } from 'primevue/usestyle';
const styles = `
.p-inputtextarea-resizable {
overflow: hidden;
resize: none;
}
.p-fluid .p-inputtextarea {
width: 100%;
}
`;
const classes = {
root: ({ instance, props }) => [
'p-inputtextarea p-inputtext p-component',
{
'p-filled': instance.filled,
'p-inputtextarea-resizable ': props.autoResize
}
]
};
const { load: loadStyle } = useStyle(styles, { name: 'textarea', manual: true });
2023-05-24 14:15:21 +00:00
export default {
name: 'BaseTextarea',
extends: BaseComponent,
props: {
modelValue: null,
autoResize: Boolean
},
css: {
classes,
loadStyle
2023-05-24 14:15:21 +00:00
},
provide() {
return {
$parentInstance: this
};
2023-05-24 14:15:21 +00:00
}
};
</script>