mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-18 19:01:20 -08:00
18 lines
442 B
JavaScript
18 lines
442 B
JavaScript
import { append, tooltip } from '../utils';
|
|
import icons from '../icons';
|
|
|
|
export default class Screenshot {
|
|
constructor(option) {
|
|
this.option = option;
|
|
}
|
|
|
|
apply(art, $control) {
|
|
const { events: { proxy }, i18n, player } = art;
|
|
this.$screenshot = append($control, icons.screenshot);
|
|
tooltip(this.$screenshot, i18n.get('Screenshot'));
|
|
proxy(this.$screenshot, 'click', () => {
|
|
player.screenshot();
|
|
});
|
|
}
|
|
}
|