primevue-mirror/components/lib/skeleton/Skeleton.vue

19 lines
542 B
Vue
Raw Normal View History

2022-09-06 12:03:37 +00:00
<template>
2023-05-25 14:43:15 +00:00
<div :class="cx('root')" :style="[sx('root'), containerStyle]" aria-hidden="true" v-bind="ptm('root')"></div>
2022-09-06 12:03:37 +00:00
</template>
<script>
2023-05-24 10:36:51 +00:00
import BaseSkeleton from './BaseSkeleton.vue';
2023-04-24 09:43:33 +00:00
2022-09-06 12:03:37 +00:00
export default {
name: 'Skeleton',
2023-05-24 10:36:51 +00:00
extends: BaseSkeleton,
2022-09-06 12:03:37 +00:00
computed: {
containerStyle() {
2022-09-14 11:26:01 +00:00
if (this.size) return { width: this.size, height: this.size, borderRadius: this.borderRadius };
else return { width: this.width, height: this.height, borderRadius: this.borderRadius };
2022-09-06 12:03:37 +00:00
}
}
2022-09-14 11:26:01 +00:00
};
2022-09-06 12:03:37 +00:00
</script>