mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-18 10:41:20 -08:00
Refactor code structure for improved readability and maintainability
This commit is contained in:
1 parent
1374d530a4
commit
e2e8e83e63
10 files changed
+17
-17
No files matched your search
@@ -2431,7 +2431,7 @@ function miniMix(art) {
|
||||
const $mini = createMini();
|
||||
const top = storage.get('top');
|
||||
const left = storage.get('left');
|
||||
if (top && left) {
|
||||
if (typeof top === 'number' && typeof left === 'number') {
|
||||
(0, _utils.setStyle)($mini, 'top', `${top}px`);
|
||||
(0, _utils.setStyle)($mini, 'left', `${left}px`);
|
||||
if (!(0, _utils.isInViewport)($mini)) initMini();
|
||||
@@ -4661,7 +4661,7 @@ class Setting extends (0, _componentDefault.default) {
|
||||
for(let index = 0; index < option.length; index++){
|
||||
const item = option[index];
|
||||
if (item?.name) {
|
||||
(0, _utils.errorHandle)(!names.includes(item.name), `The [${item.name}] is already exist in [setting]`);
|
||||
(0, _utils.errorHandle)(!names.includes(item.name), `The [${item.name}] already exists in [setting]`);
|
||||
names.push(item.name);
|
||||
} else item.name = `setting-${this.id++}`;
|
||||
if (!item.$formatted) {
|
||||
|
||||
Reference in new issue
Block a user