-
Notifications
You must be signed in to change notification settings - Fork 273
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: ConnectButton custom theme + customized component in playground (#…
- Loading branch information
1 parent
a9ce10f
commit 2d7ebe2
Showing
4 changed files
with
106 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"thirdweb": patch | ||
--- | ||
|
||
Fix ConnectButton theming prop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
"use client"; | ||
import { ConnectButton } from "thirdweb/react"; | ||
import { darkTheme, lightTheme } from "thirdweb/react"; | ||
import { THIRDWEB_CLIENT } from "../../lib/client"; | ||
|
||
export const CustomizedConnect = () => { | ||
return ( | ||
<ConnectButton | ||
client={THIRDWEB_CLIENT} | ||
connectButton={{ | ||
label: "Custom Connect Button", | ||
}} | ||
showAllWallets={false} | ||
connectModal={{ | ||
title: "Custom Connect Modal", | ||
size: "compact", | ||
}} | ||
theme={darkTheme({ | ||
colors: { | ||
modalBg: "#281866", | ||
accentButtonBg: "#281866", | ||
connectedButtonBgHover: "#281866", | ||
borderColor: "rgba(256, 256,256, 0.1)", | ||
accentText: "rgba(256, 256,256, 0.1)", | ||
connectedButtonBg: "#281866", | ||
tertiaryBg: "rgba(256, 256,256, 0.1)", | ||
primaryButtonBg: "#281866", | ||
secondaryButtonBg: "rgba(256, 256,256, 0.1)", | ||
primaryButtonText: "#E7E8E9", | ||
primaryText: "#E7E8E9", | ||
separatorLine: "rgba(256, 256,256, 0.1)", | ||
}, | ||
})} | ||
/> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters