Embed Discord widget on the right
This commit is contained in:
		
							parent
							
								
									4191969ab1
								
							
						
					
					
						commit
						3a2598edfe
					
				|  | @ -20,6 +20,7 @@ | |||
|     "@heroicons/react": "1.0.5", | ||||
|     "@nivo/core": "0.74.0", | ||||
|     "@nivo/line": "0.74.0", | ||||
|     "@widgetbot/react-embed": "^1.4.0", | ||||
|     "clsx": "1.1.1", | ||||
|     "daisyui": "1.16.4", | ||||
|     "dayjs": "1.10.7", | ||||
|  |  | |||
|  | @ -17,6 +17,7 @@ import { html } from 'gridjs' | |||
| import dayjs from 'dayjs' | ||||
| import { useUser } from '../hooks/use-user' | ||||
| import { useState } from 'react' | ||||
| import WidgetBot from '@widgetbot/react-embed' | ||||
| 
 | ||||
| export const getStaticProps = fromPropz(getStaticPropz) | ||||
| export async function getStaticPropz() { | ||||
|  | @ -188,7 +189,7 @@ export default function Manaboards(props: { | |||
|   const [expandInfo, setExpandInfo] = useState(false) | ||||
| 
 | ||||
|   return ( | ||||
|     <Page margin> | ||||
|     <Page margin rightSidebar={<DiscordWidget />}> | ||||
|       <Title text={'🏅 Leaderboard slots, for sale!'} /> | ||||
|       {/* <div className="absolute right-[700px] top-8"> | ||||
|         <img | ||||
|  | @ -326,3 +327,13 @@ function TransactionsTable(props: { txns: Transaction[] }) { | |||
|     /> | ||||
|   ) | ||||
| } | ||||
| 
 | ||||
| function DiscordWidget() { | ||||
|   return typeof window === 'undefined' ? null : ( | ||||
|     <WidgetBot | ||||
|       className="mt-4 h-[80vh]" | ||||
|       server="915138780216823849" | ||||
|       channel="959499868089507930" | ||||
|     /> | ||||
|   ) | ||||
| } | ||||
|  |  | |||
							
								
								
									
										24
									
								
								yarn.lock
									
									
									
									
									
								
							
							
						
						
									
										24
									
								
								yarn.lock
									
									
									
									
									
								
							|  | @ -1112,6 +1112,19 @@ | |||
|     "@typescript-eslint/types" "4.33.0" | ||||
|     eslint-visitor-keys "^2.0.0" | ||||
| 
 | ||||
| "@widgetbot/embed-api@^1.1.3": | ||||
|   version "1.1.3" | ||||
|   resolved "https://registry.yarnpkg.com/@widgetbot/embed-api/-/embed-api-1.1.3.tgz#c7fd8069d7ce2ec7740d8bf4140c786c636fb3d6" | ||||
|   integrity sha1-x/2AadfOLsd0DYv0FAx4bGNvs9Y= | ||||
| 
 | ||||
| "@widgetbot/react-embed@^1.4.0": | ||||
|   version "1.4.0" | ||||
|   resolved "https://registry.yarnpkg.com/@widgetbot/react-embed/-/react-embed-1.4.0.tgz#b0b617629e0e2cd6ff7a4770db34e0c52e056a43" | ||||
|   integrity sha512-rN/zyv8ndn+I3g1fCMql2NN+2Yn04XVhwL1GHQlSKEvFWNXsqEDyXO1MaDxcvJFcG7cSQLRTcvgVWzAVe+3Fag== | ||||
|   dependencies: | ||||
|     "@widgetbot/embed-api" "^1.1.3" | ||||
|     react "^16.13.1" | ||||
| 
 | ||||
| abort-controller@^3.0.0: | ||||
|   version "3.0.0" | ||||
|   resolved "https://registry.yarnpkg.com/abort-controller/-/abort-controller-3.0.0.tgz#eaf54d53b62bae4138e809ca225c8439a6efb392" | ||||
|  | @ -4303,7 +4316,7 @@ promisify-call@^2.0.2: | |||
|   dependencies: | ||||
|     with-callback "^1.0.2" | ||||
| 
 | ||||
| prop-types@^15.5.8, prop-types@^15.7.2: | ||||
| prop-types@^15.5.8, prop-types@^15.6.2, prop-types@^15.7.2: | ||||
|   version "15.8.1" | ||||
|   resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.8.1.tgz#67d87bf1a694f48435cf332c24af10214a3140b5" | ||||
|   integrity sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg== | ||||
|  | @ -4493,6 +4506,15 @@ react@17.0.2: | |||
|     loose-envify "^1.1.0" | ||||
|     object-assign "^4.1.1" | ||||
| 
 | ||||
| react@^16.13.1: | ||||
|   version "16.14.0" | ||||
|   resolved "https://registry.yarnpkg.com/react/-/react-16.14.0.tgz#94d776ddd0aaa37da3eda8fc5b6b18a4c9a3114d" | ||||
|   integrity sha512-0X2CImDkJGApiAlcf0ODKIneSwBPhqJawOa5wCtKbu7ZECrmS26NvtSILynQ66cgkT/RJ4LidJOc3bUESwmU8g== | ||||
|   dependencies: | ||||
|     loose-envify "^1.1.0" | ||||
|     object-assign "^4.1.1" | ||||
|     prop-types "^15.6.2" | ||||
| 
 | ||||
| readable-stream@1.1.x: | ||||
|   version "1.1.14" | ||||
|   resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.1.14.tgz#7cf4c54ef648e3813084c636dd2079e166c081d9" | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user