From fcda1b28480b9b441c70f5da6aee051fa8feaf51 Mon Sep 17 00:00:00 2001 From: everestmcarthur Date: Sun, 2 Aug 2026 03:03:52 +0000 Subject: [PATCH] deploy: 58f97d2c27b477272954be49a14d6b5a05334a3b --- plugins-data.json | 2 +- you-bar-plus/install/index.js | 2 +- you-bar-plus/install/manifest.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins-data.json b/plugins-data.json index 68a05c4..c8b2479 100644 --- a/plugins-data.json +++ b/plugins-data.json @@ -195,7 +195,7 @@ { "id": "you-bar-plus", "name": "YouBar+", - "description": "Adds floating DM/Settings buttons near the bottom of the screen, rendered independently rather than inside the native YouBar row for reliability.", + "description": "Adds Settings and DM buttons to the YouBar. (May require a restart after enabling.)", "authors": [ "everestmcarthur", "Purple_Ξye™" diff --git a/you-bar-plus/install/index.js b/you-bar-plus/install/index.js index 61ec9e8..0f10abd 100644 --- a/you-bar-plus/install/index.js +++ b/you-bar-plus/install/index.js @@ -1 +1 @@ -(function(l,h,n,f,e,R,b,u,p,E){"use strict";function S(t,a,r=100){let i=!1,o;const s=t();return s?(a(s),{cancel(){}}):(o=setInterval(function(){if(i)return;const B=t();B&&(i=!0,clearInterval(o),a(B))},r),{cancel(){i=!0,o&&clearInterval(o)}})}function I(t,a=!0){const r=window?.modules;if(r)for(const i in r){const o=r[i];if(o?.__filePath!==t)continue;if(!o.isInitialized)return;const s=o.publicModule?.exports;return s?a?s.default??s:s:void 0}}const{View:m,TouchableOpacity:y,Image:w}=e.ReactNative,D="modules/toast/native/ToastContainer.tsx";function M(){let t=function(){};const a=S(function(){return I(D,!0)},function(r){t=R.after("type",r,function(i,o){return e.React.createElement(e.React.Fragment,null,o,e.React.createElement(P,null))}),p.showToast("YouBar+ ready",u.getAssetIDByName("CheckmarkIcon"))});return function(){a.cancel(),t()}}function P(){if(b.useProxy(n.storage),!n.storage.showDMButton&&!n.storage.showSettingsButton)return null;const t=f.findByProps("openUserSettings"),a=f.findByProps("transitionToGuild"),r=u.getAssetIDByName("ChatIcon"),i=u.getAssetIDByName("SettingsIcon");return e.React.createElement(m,{pointerEvents:"box-none",style:c.container},n.storage.showDMButton&&e.React.createElement(y,{accessibilityLabel:"Direct Messages",onPress:function(){return a?.transitionToGuild?.("@me")},style:c.button},e.React.createElement(w,{source:r,style:c.icon})),n.storage.showSettingsButton&&e.React.createElement(y,{accessibilityLabel:"Settings",onPress:function(){return t?.openUserSettings?.()},style:c.button},e.React.createElement(w,{source:i,style:c.icon})))}const d=40,c={container:{position:"absolute",right:12,bottom:90,flexDirection:"row",alignItems:"center",gap:10,zIndex:999,elevation:999},button:{width:d,height:d,borderRadius:d/2,backgroundColor:"rgba(30,30,35,0.85)",alignItems:"center",justifyContent:"center"},icon:{width:20,height:20,tintColor:"white"}},{ScrollView:x,View:C}=e.ReactNative;function F({children:t}){return e.React.createElement(x,{style:{flex:1}},t,e.React.createElement(C,{style:{height:24}}))}const{View:T,Text:V}=e.ReactNative;function N({children:t,style:a}){return e.React.createElement(T,{style:[{marginHorizontal:16,marginVertical:8,padding:10,borderRadius:8,borderWidth:1,borderColor:"rgba(128,128,128,0.25)"},a]},e.React.createElement(V,{style:{fontSize:12.5,lineHeight:18,opacity:.75}},t))}const{FormSection:Y,FormSwitchRow:v}=E.Forms;function $(){return b.useProxy(n.storage),React.createElement(F,null,React.createElement(N,null,"Fork of Purple-EyeZ's YouBar+, rebuilt from scratch after the original approach (patching YouBar's own notification button directly) turned out to be unreliable on current Discord builds. These buttons now render as an independent floating overlay near the bottom-right of the screen instead of natively inside the YouBar row itself - not pixel-identical placement, but should appear reliably and update instantly when toggled, without needing a restart."),React.createElement(Y,{title:"Buttons"},React.createElement(v,{label:"Direct Messages button",subLabel:"Show a floating DM button",value:!!n.storage.showDMButton,onValueChange:function(t){n.storage.showDMButton=t}}),React.createElement(v,{label:"Settings button",subLabel:"Show a floating Settings button",value:!!n.storage.showSettingsButton,onValueChange:function(t){n.storage.showSettingsButton=t}})))}const L="youbar-plus-v2-toast-anchor";let g=function(){};var k={onLoad:function(){n.storage.showDMButton??=!1,n.storage.showSettingsButton??=!0,h.logger.log(`[YouBar+] loading (${L})`);try{g=M()}catch(t){h.logger.error(`[YouBar+] Failed to apply patches, buttons will not appear: ${t}`),g=function(){}}},onUnload:function(){return g()},settings:$};return l.default=k,Object.defineProperty(l,"__esModule",{value:!0}),l})({},vendetta,vendetta.plugin,vendetta.metro,vendetta.metro.common,vendetta.patcher,vendetta.storage,vendetta.ui.assets,vendetta.ui.toasts,vendetta.ui.components); +(function(l,B,n,d,t,R,h,b,v){"use strict";function w(e,r,o,i){try{return o()}catch(a){return i.error(`[${e}] Failed to apply the "${r}" patch, that surface will be skipped: ${a}`),function(){}}}function E(e,r,o){const i=Object.entries(o).map(function([a,f]){return w(e,a,f,r)});return function(){return i.forEach(function(a){return a()})}}let u=function(){};function S(){const e=d.findByTypeName("YouBarNotificationsButton"),r=d.findByProps("openUserSettings"),o=d.findByProps("transitionToGuild"),i=h.getAssetIDByName("SettingsIcon"),a=h.getAssetIDByName("ChatIcon");return e?R.instead("type",e,function(f,$){const[,C]=t.React.useReducer(function(L){return~L},0);u=function(){return C()};const s=$(...f);if(!s?.props?.children)return s;const y=s.props.children.type,c=s.props.children.props;return t.React.createElement(t.React.Fragment,null,n.storage.showDMButton&&t.React.createElement(y,{variant:c?.variant||"tertiary",size:c?.size||"sm",icon:a,onPress:function(){o?.transitionToGuild?.("@me")}}),n.storage.showSettingsButton&&t.React.createElement(y,{variant:c?.variant||"tertiary",size:c?.size||"sm",icon:i,onPress:function(){r?.openUserSettings?.()}}),s)}):function(){}}const{ScrollView:P,View:D}=t.ReactNative;function Y({children:e}){return t.React.createElement(P,{style:{flex:1}},e,t.React.createElement(D,{style:{height:24}}))}const{View:M,Text:V}=t.ReactNative;function z({children:e,style:r}){return t.React.createElement(M,{style:[{marginHorizontal:16,marginVertical:8,padding:10,borderRadius:8,borderWidth:1,borderColor:"rgba(128,128,128,0.25)"},r]},t.React.createElement(V,{style:{fontSize:12.5,lineHeight:18,opacity:.75}},e))}const{FormSection:F,FormSwitchRow:g}=v.Forms;function N(){return b.useProxy(n.storage),t.React.useEffect(function(){return function(){return u()}},[]),t.React.createElement(Y,null,t.React.createElement(z,null,"Fork of Purple-EyeZ's YouBar+, ported to Revenge's Vendetta-compat API. Like the original, this patches the YouBar the moment it loads - if you enable it while Discord's already running, you may need to restart once for the buttons to appear."),t.React.createElement(F,{title:"Buttons"},t.React.createElement(g,{label:"Direct Messages button",subLabel:"Show the DM button in the YouBar",value:!!n.storage.showDMButton,onValueChange:function(e){n.storage.showDMButton=e,u()}}),t.React.createElement(g,{label:"Settings button",subLabel:"Show the Settings button in the YouBar",value:!!n.storage.showSettingsButton,onValueChange:function(e){n.storage.showSettingsButton=e,u()}})))}let p=function(){};var I={onLoad:function(){n.storage.showDMButton??=!1,n.storage.showSettingsButton??=!0,p=E("YouBar+",B.logger,{"YouBar buttons":S})},onUnload:function(){return p()},settings:N};return l.default=I,Object.defineProperty(l,"__esModule",{value:!0}),l})({},vendetta,vendetta.plugin,vendetta.metro,vendetta.metro.common,vendetta.patcher,vendetta.ui.assets,vendetta.storage,vendetta.ui.components); diff --git a/you-bar-plus/install/manifest.json b/you-bar-plus/install/manifest.json index 4c24c86..93818ab 100644 --- a/you-bar-plus/install/manifest.json +++ b/you-bar-plus/install/manifest.json @@ -1 +1 @@ -{"name":"YouBar+","description":"Adds floating DM/Settings buttons near the bottom of the screen, rendered independently rather than inside the native YouBar row for reliability.","authors":[{"name":"everestmcarthur"},{"name":"Purple_Ξye™"}],"main":"index.js","hash":"c16ef7f4b259a8b74c88961ed72fa0c81a6ae90f0b2a84daab4e49d156f56d8e"} \ No newline at end of file +{"name":"YouBar+","description":"Adds Settings and DM buttons to the YouBar. (May require a restart after enabling.)","authors":[{"name":"everestmcarthur"},{"name":"Purple_Ξye™"}],"main":"index.js","hash":"7dc56dabb979819b5940681e8812fd01c092a9c717e10268201bc86486b7c905"} \ No newline at end of file