Skip to content

Commit

Permalink
fix: add Sticky props comment
Browse files Browse the repository at this point in the history
  • Loading branch information
huanghong1125 committed Apr 1, 2022
1 parent 4ceaa9d commit 46133b3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/components/Sticky/src/Sticky.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,13 @@ import { propTypes } from '@/utils/propTypes'
import { ref, onMounted, onActivated, shallowRef } from 'vue'
import { useEventListener, useWindowSize } from '@vueuse/core'
const props = defineProps({
// 距离顶部或者底部的距离(单位px)
offset: propTypes.number.def(0),
// 设置元素的堆叠顺序
zIndex: propTypes.number.def(999),
// 设置指定的class
className: propTypes.string.def(''),
// 定位方式,默认为(top),表示距离顶部位置,可以设置为top或者bottom
position: {
type: String,
validator: function (value: string) {
Expand Down

0 comments on commit 46133b3

Please sign in to comment.