mirror of
https://github.com/Equicord/Equicord.git
synced 2025-01-30 19:23:29 -05:00
fix(MoreStickers): MoreSticker button (#128)
This commit is contained in:
parent
de1b74f6c7
commit
2d3032330f
1 changed files with 3 additions and 3 deletions
|
@ -32,7 +32,7 @@ export default definePlugin({
|
||||||
|
|
||||||
patches: [
|
patches: [
|
||||||
{
|
{
|
||||||
find: "#{intl::STICKER_BUTTON_LABEL}",
|
find: "ChannelStickerPickerButton",
|
||||||
replacement: [{
|
replacement: [{
|
||||||
match: /(children:\(0,\i\.jsx\)\()([\w.]+?)(,{innerClassName.{10,30}\.stickerButton)/,
|
match: /(children:\(0,\i\.jsx\)\()([\w.]+?)(,{innerClassName.{10,30}\.stickerButton)/,
|
||||||
replace: (_, head, button, tail) => {
|
replace: (_, head, button, tail) => {
|
||||||
|
@ -56,7 +56,7 @@ export default definePlugin({
|
||||||
{
|
{
|
||||||
find: ".gifts)",
|
find: ".gifts)",
|
||||||
replacement: {
|
replacement: {
|
||||||
match: /\(null===\(\i=\i\.stickers\).*?(\i)\.push\((\(0,\i\.jsx\))\((.+?),{disabled:\w,type:(\i)},"sticker"\)\)/,
|
match: /,.{0,5}\(null===\(\w=\w\.stickers\)\|\|void 0.*?(\w)\.push\((\(0,\w\.jsx\))\((.+?),{disabled:\w,type:(\w)},"sticker"\)\)\)/,
|
||||||
replace: (m, _, jsx, compo, type) => {
|
replace: (m, _, jsx, compo, type) => {
|
||||||
const c = "arguments[0].type";
|
const c = "arguments[0].type";
|
||||||
return `${m},${c}?.submit?.button&&${_}.push(${jsx}(${compo},{disabled:!${c}?.submit?.button,type:${type},stickersType:"stickers+"},"stickers+"))`;
|
return `${m},${c}?.submit?.button&&${_}.push(${jsx}(${compo},{disabled:!${c}?.submit?.button,type:${type},stickersType:"stickers+"},"stickers+"))`;
|
||||||
|
@ -64,7 +64,7 @@ export default definePlugin({
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
find: "role:\"tablist\",\"aria-label\":",
|
find: `role:"tablist","aria-label":`,
|
||||||
replacement: {
|
replacement: {
|
||||||
match: /role:"tablist",.*?,?"aria-label":.+?\),children:(\[.*?\)\]}\)}\):null,)(.*?closePopout:\w.*?:null)/s,
|
match: /role:"tablist",.*?,?"aria-label":.+?\),children:(\[.*?\)\]}\)}\):null,)(.*?closePopout:\w.*?:null)/s,
|
||||||
replace: m => {
|
replace: m => {
|
||||||
|
|
Loading…
Reference in a new issue