-
Notifications
You must be signed in to change notification settings - Fork 328
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds Mendable floating button. Closes #4765
- Loading branch information
1 parent
edb1171
commit 686e8b9
Showing
7 changed files
with
3,204 additions
and
5,294 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
Large diffs are not rendered by default.
Oops, something went wrong.
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
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,25 @@ | ||
import React from "react"; | ||
import { MendableFloatingButton } from "@mendable/search"; | ||
import useDocusaurusContext from "@docusaurus/useDocusaurusContext"; | ||
|
||
export default function SearchBarWrapper(): JSX.Element { | ||
const { | ||
siteConfig: { customFields } | ||
} = useDocusaurusContext(); | ||
|
||
const style = { darkMode: false, accentColor: "#ef5552" }; | ||
|
||
const floatingButtonStyle = { | ||
color: "#fff", | ||
backgroundColor: "#ef5552" | ||
}; | ||
|
||
return ( | ||
<div className="mendable-search"> | ||
<MendableFloatingButton | ||
anon_key={customFields.mendableAnonKey} | ||
style={style} | ||
floatingButtonStyle={floatingButtonStyle} /> | ||
</div> | ||
); | ||
} |
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