mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-16 01:26:16 -08:00
12 lines
282 B
JavaScript
12 lines
282 B
JavaScript
import { def } from '../utils';
|
|
|
|
export default function durationMix(art) {
|
|
def(art, 'duration', {
|
|
get: () => {
|
|
const { duration } = art.template.$video;
|
|
if (duration === Infinity) return 0;
|
|
return duration || 0;
|
|
},
|
|
});
|
|
}
|