mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-25 08:01:20 -08:00
chore: Update font size range for danmuku plugin
This commit is contained in:
1 parent
24e51b96e2
commit
27284099d7
3 files changed
+11
-13
No files matched your search
@@ -410,19 +410,18 @@ export default class Setting {
|
||||
});
|
||||
|
||||
this.slider.fontSize = this.createSlider({
|
||||
min: 1,
|
||||
max: 25,
|
||||
min: 12,
|
||||
max: 120,
|
||||
steps: [],
|
||||
container: this.template.$fontSizeSlider,
|
||||
findIndex: () => {
|
||||
const { clientHeight } = this.art.template.$player;
|
||||
return Math.round((this.danmuku.fontSize / clientHeight) * 100);
|
||||
return Math.round(this.danmuku.fontSize);
|
||||
},
|
||||
onChange: (index) => {
|
||||
const { $fontSizeValue } = this.template;
|
||||
$fontSizeValue.textContent = `${index}%`;
|
||||
$fontSizeValue.textContent = `${index}px`;
|
||||
this.danmuku.config({
|
||||
fontSize: `${index}%`,
|
||||
fontSize: index,
|
||||
});
|
||||
},
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user