mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-12 08:03:06 -04:00
fix(SpotifyControls): sync with external shuffle toggles (#2767)
Co-authored-by: v <vendicated@riseup.net>
This commit is contained in:
parent
87e6fa8647
commit
1a712e75a6
2 changed files with 13 additions and 12 deletions
|
@ -70,21 +70,20 @@ export default definePlugin({
|
|||
replace: "false",
|
||||
}]
|
||||
},
|
||||
// Discord doesn't give you the repeat kind, only a boolean
|
||||
{
|
||||
find: 'repeat:"off"!==',
|
||||
replacement: {
|
||||
match: /repeat:"off"!==(.{1,3}),/,
|
||||
replace: "actual_repeat:$1,$&"
|
||||
}
|
||||
replacement: [
|
||||
{
|
||||
// Discord doesn't give you shuffle state and the repeat kind, only a boolean
|
||||
match: /repeat:"off"!==(\i),/,
|
||||
replace: "shuffle:arguments[2]?.shuffle_state??false,actual_repeat:$1,$&"
|
||||
},
|
||||
{
|
||||
match: /(?<=artists.filter\(\i=>).{0,10}\i\.id\)&&/,
|
||||
replace: ""
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
find: "artists.filter",
|
||||
replacement: {
|
||||
match: /(?<=artists.filter\(\i=>).{0,10}\i\.id\)&&/,
|
||||
replace: ""
|
||||
}
|
||||
}
|
||||
],
|
||||
|
||||
start: () => toggleHoverControls(Settings.plugins.SpotifyControls.hoverControls),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue