fix(ui/components/ErrorBoundaryScreen): minor misspelling & update branding (#57)
Co-authored-by: PalmDevs <git@palmdevs.me> Co-authored-by: semantic-release-bot <semantic-release-bot@martynus.net>
This commit is contained in:
parent
e0cea529f9
commit
a71dd7d0eb
3 changed files with 12 additions and 1 deletions
|
|
@ -1,3 +1,8 @@
|
||||||
|
## [1.5.3](https://github.com/revenge-mod/revenge-bundle/compare/v1.5.2...v1.5.3) (2024-12-05)
|
||||||
|
|
||||||
|
|
||||||
|
* backport iOS invalid element type crash fix ([afacfa0](https://github.com/revenge-mod/revenge-bundle/commit/afacfa06480f60d461840a211c09abb363dc8546))
|
||||||
|
|
||||||
## [1.5.3-dev.1](https://github.com/revenge-mod/revenge-bundle/compare/v1.5.2...v1.5.3-dev.1) (2024-11-24)
|
## [1.5.3-dev.1](https://github.com/revenge-mod/revenge-bundle/compare/v1.5.2...v1.5.3-dev.1) (2024-11-24)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ export default function ErrorBoundaryScreen(props: {
|
||||||
<SafeAreaView style={styles.container}>
|
<SafeAreaView style={styles.container}>
|
||||||
<View style={{ gap: 4 }}>
|
<View style={{ gap: 4 }}>
|
||||||
<Text variant="display-lg">Uh oh.</Text>
|
<Text variant="display-lg">Uh oh.</Text>
|
||||||
<Text variant="text-md/normal">A crash occured while rendering a component. This could be caused by a plugin, Bunny or Discord itself.</Text>
|
<Text variant="text-md/normal">A crash occurred while rendering a component. This could be caused by a plugin, Revenge or Discord itself.</Text>
|
||||||
<Text variant="text-sm/normal" color="text-muted">{debugInfo.os.name}; {debugInfo.discord.build} ({debugInfo.discord.version}); {debugInfo.bunny.version}</Text>
|
<Text variant="text-sm/normal" color="text-muted">{debugInfo.os.name}; {debugInfo.discord.build} ({debugInfo.discord.version}); {debugInfo.bunny.version}</Text>
|
||||||
</View>
|
</View>
|
||||||
<ScrollView fadingEdgeLength={64} contentContainerStyle={{ gap: 12 }}>
|
<ScrollView fadingEdgeLength={64} contentContainerStyle={{ gap: 12 }}>
|
||||||
|
|
|
||||||
|
|
@ -23,6 +23,12 @@ export function deleteJsxCreate(Component: string, callback: Callback) {
|
||||||
*/
|
*/
|
||||||
export function patchJsx() {
|
export function patchJsx() {
|
||||||
const callback = ([Component]: unknown[], ret: JSX.Element) => {
|
const callback = ([Component]: unknown[], ret: JSX.Element) => {
|
||||||
|
// Band-aid fix for iOS invalid element type crashes
|
||||||
|
if (typeof ret.type === 'undefined') {
|
||||||
|
ret.type = 'RCTView'
|
||||||
|
return ret
|
||||||
|
}
|
||||||
|
|
||||||
// The check could be more complex, but this is fine for now to avoid overhead
|
// The check could be more complex, but this is fine for now to avoid overhead
|
||||||
if (typeof Component === "function" && callbacks.has(Component.name)) {
|
if (typeof Component === "function" && callbacks.has(Component.name)) {
|
||||||
const cbs = callbacks.get(Component.name)!;
|
const cbs = callbacks.get(Component.name)!;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue