You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

21 lines
447 B

import type { CSSProperties } from 'vue'
import type { ClipBehavior } from '../types'
export function clip(clip: ClipBehavior | undefined): CSSProperties | undefined {
switch (clip) {
case 'autoX':
return {
overflowX: 'auto',
overflowY: 'hidden',
}
case 'autoY':
return {
overflowX: 'hidden',
overflowY: 'auto',
}
default:
return {
overflow: clip,
}
}
}