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.
 
 
 
 

17 lines
351 B

import type { CSSProperties } from 'vue'
import { unit } from './unit'
export function gap(gap: number | [number, number] | undefined): CSSProperties | undefined {
if (!gap) {
return undefined
}
if (Array.isArray(gap)) {
return {
rowGap: unit(gap[0]),
columnGap: unit(gap[1]),
}
}
return {
gap: unit(gap),
}
}