padding to powered by and svg fixes
This commit is contained in:
		
							parent
							
								
									d562e83c9e
								
							
						
					
					
						commit
						b263970b4f
					
				
					 8 changed files with 260 additions and 109 deletions
				
			
		|  | @ -14,7 +14,6 @@ const AvailableTimes = ({ | |||
|   timeFormat, | ||||
|   user, | ||||
|   organizerTimeZone, | ||||
|   height, | ||||
| }) => { | ||||
|   const router = useRouter(); | ||||
|   const { rescheduleUid } = router.query; | ||||
|  | @ -28,11 +27,9 @@ const AvailableTimes = ({ | |||
|   }); | ||||
| 
 | ||||
|   return ( | ||||
|     <div | ||||
|       className="sm:pl-4 mt-16 pt-4 pr-6 bg-neutral-50 dark:bg-neutral-800 rounded-r-sm border border-l-0 border-neutral-300 dark:border-neutral-700 text-center h-full overflow-y-auto" | ||||
|       style={{ maxHeight: height }}> | ||||
|       <div className="font-semibold mb-4 text-left border-b border-neutral-200 pb-4"> | ||||
|         <span className="w-1/2 dark:text-white text-primary-500">{date.format("dddd DD MMMM YYYY")}</span> | ||||
|     <div className="sm:pl-4 mt-8 sm:mt-0 text-center sm:w-1/3 md:max-h-97 overflow-y-auto"> | ||||
|       <div className="text-gray-600 font-light text-xl mb-4 text-left"> | ||||
|         <span className="w-1/2 dark:text-white text-gray-600">{date.format("dddd DD MMMM YYYY")}</span> | ||||
|       </div> | ||||
|       {slots.length > 0 && | ||||
|         slots.map((slot) => ( | ||||
|  | @ -42,7 +39,7 @@ const AvailableTimes = ({ | |||
|                 `/${user.username}/book?date=${slot.utc().format()}&type=${eventTypeId}` + | ||||
|                 (rescheduleUid ? "&rescheduleUid=" + rescheduleUid : "") | ||||
|               }> | ||||
|               <a className="block font-medium mb-4 bg-white dark:bg-neutral-700 text-primary-500 dark:text-neutral-200 border border-primary-500 dark:border-neutral-600 rounded hover:text-white hover:bg-primary-500 dark:hover:bg-primary-500 dark:hover:border-primary-500 py-4"> | ||||
|               <a className="block font-medium mb-4 bg-white dark:bg-neutral-900 text-primary-500 dark:text-neutral-200 border border-primary-500 dark:border-black rounded hover:text-white hover:bg-primary-500 dark:hover:border-black py-4 dark:hover:bg-black"> | ||||
|                 {slot.format(timeFormat)} | ||||
|               </a> | ||||
|             </Link> | ||||
|  |  | |||
|  | @ -1,4 +1,4 @@ | |||
| import { ChevronLeftIcon, ChevronRightIcon } from "@heroicons/react/outline"; | ||||
| import { ChevronLeftIcon, ChevronRightIcon } from "@heroicons/react/solid"; | ||||
| import { useEffect, useState } from "react"; | ||||
| import dayjs, { Dayjs } from "dayjs"; | ||||
| import utc from "dayjs/plugin/utc"; | ||||
|  | @ -24,7 +24,6 @@ const DatePicker = ({ | |||
|   periodDays, | ||||
|   periodCountCalendarDays, | ||||
|   minimumBookingNotice, | ||||
|   setHeight, | ||||
| }) => { | ||||
|   const [calendar, setCalendar] = useState([]); | ||||
|   const [selectedMonth, setSelectedMonth] = useState<number>(); | ||||
|  | @ -148,14 +147,14 @@ const DatePicker = ({ | |||
|           onClick={() => setSelectedDate(inviteeDate.date(day))} | ||||
|           disabled={isDisabled(day)} | ||||
|           className={ | ||||
|             "w-36 mx-auto h-28 mx-auto p-3 text-left flex self-start" + | ||||
|             "text-center w-10 h-10 mx-auto" + | ||||
|             (isDisabled(day) | ||||
|               ? " text-neutral-400 font-light" | ||||
|               : " text-neutral-900 dark:text-neutral-200 font-medium") + | ||||
|               ? " text-gray-400 font-light" | ||||
|               : " dark:text-white text-primary-500 font-medium") + | ||||
|             (selectedDate && selectedDate.isSame(inviteeDate.date(day), "day") | ||||
|               ? " bg-neutral-100 dark:bg-neutral-700 border border-neutral-900 dark:border-neutral-600 dark:text-white" | ||||
|               ? " bg-black text-white-important" | ||||
|               : !isDisabled(day) | ||||
|               ? " bg-neutral-100 dark:bg-neutral-700 dark:bg-opacity-30" | ||||
|               ? " bg-gray-100 dark:bg-black dark:bg-opacity-30" | ||||
|               : "") | ||||
|           }> | ||||
|           {day} | ||||
|  | @ -165,44 +164,35 @@ const DatePicker = ({ | |||
|   }, [selectedMonth, inviteeTimeZone, selectedDate]); | ||||
| 
 | ||||
|   return selectedMonth ? ( | ||||
|     <div className="mt-8 sm:mt-0"> | ||||
|       <div className="flex text-gray-600 text-xl mb-8"> | ||||
|         <div className="w-1/2 text-2xl"> | ||||
|           <span className="font-semibold text-neutral-900 dark:text-white"> | ||||
|             {dayjs().month(selectedMonth).format("MMMM")} | ||||
|           </span> | ||||
|             | ||||
|           <span className="text-neutral-400">{dayjs().month(selectedMonth).format("YYYY")}</span> | ||||
|         </div> | ||||
|     <div | ||||
|       className={ | ||||
|         "mt-8 sm:mt-0 " + | ||||
|         (selectedDate ? "sm:w-1/3 sm:border-r sm:dark:border-black sm:px-4" : "sm:w-1/2 sm:pl-4") | ||||
|       }> | ||||
|       <div className="flex text-gray-600 font-light text-xl mb-4 ml-2"> | ||||
|         <span className="w-1/2 text-gray-600 dark:text-white"> | ||||
|           {dayjs().month(selectedMonth).format("MMMM YYYY")} | ||||
|         </span> | ||||
|         <div className="w-1/2 text-right text-gray-600 dark:text-gray-400"> | ||||
|           <button | ||||
|             onClick={decrementMonth} | ||||
|             className={ | ||||
|               "p-1 bg-white dark:bg-neutral-800 dark:border-neutral-700 dark:text-white rounded-sm border border-neutral-300 text-black mr-4 " + | ||||
|               (selectedMonth <= dayjs().tz(inviteeTimeZone).month() && "opacity-50") | ||||
|               "mr-4 " + | ||||
|               (selectedMonth <= dayjs().tz(inviteeTimeZone).month() && "text-gray-400 dark:text-gray-600") | ||||
|             } | ||||
|             disabled={selectedMonth <= dayjs().tz(inviteeTimeZone).month()}> | ||||
|             <ChevronLeftIcon className="w-5 h-5" /> | ||||
|           </button> | ||||
|           <button | ||||
|             className="p-1 bg-white dark:bg-neutral-800 dark:border-neutral-700 dark:text-white rounded-sm border border-neutral-300" | ||||
|             onClick={incrementMonth}> | ||||
|           <button onClick={incrementMonth}> | ||||
|             <ChevronRightIcon className="w-5 h-5" /> | ||||
|           </button> | ||||
|         </div> | ||||
|       </div> | ||||
|       <div | ||||
|         className="bg-white dark:bg-neutral-800 p-6 rounded-l-sm border border-neutral-300 dark:border-neutral-700 grid grid-cols-7 gap-y-4" | ||||
|         ref={(el) => { | ||||
|           if (!el) return; | ||||
|           setHeight(el.getBoundingClientRect().height); | ||||
|         }}> | ||||
|       <div className="grid grid-cols-7 gap-y-4 text-center"> | ||||
|         {["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"] | ||||
|           .sort((a, b) => (weekStart.startsWith(a) ? -1 : weekStart.startsWith(b) ? 1 : 0)) | ||||
|           .map((weekDay) => ( | ||||
|             <div | ||||
|               key={weekDay} | ||||
|               className="uppercase text-neutral-600 text-xs tracking-widest border-b border-neutral-200 dark:border-neutral-700 pb-4"> | ||||
|             <div key={weekDay} className="uppercase text-gray-400 text-xs tracking-widest"> | ||||
|               {weekDay} | ||||
|             </div> | ||||
|           ))} | ||||
|  |  | |||
|  | @ -25,7 +25,7 @@ const TimeOptions = (props) => { | |||
| 
 | ||||
|   return ( | ||||
|     selectedTimeZone !== "" && ( | ||||
|       <div className="w-full rounded shadow border dark:bg-gray-700 dark:border-0 bg-white px-4 py-2"> | ||||
|       <div className="absolute w-full max-w-80 rounded-sm border border-gray-200 dark:bg-gray-700 dark:border-0 bg-white px-4 py-2"> | ||||
|         <div className="flex mb-4"> | ||||
|           <div className="w-1/2 dark:text-white text-gray-600 font-medium">Time Options</div> | ||||
|           <div className="w-1/2"> | ||||
|  | @ -37,7 +37,7 @@ const TimeOptions = (props) => { | |||
|                 checked={is24hClock} | ||||
|                 onChange={setIs24hClock} | ||||
|                 className={classNames( | ||||
|                   is24hClock ? "bg-blue-600" : "dark:bg-gray-600 bg-gray-200", | ||||
|                   is24hClock ? "bg-black" : "dark:bg-gray-600 bg-gray-200", | ||||
|                   "relative inline-flex flex-shrink-0 h-5 w-8 border-2 border-transparent rounded-full cursor-pointer transition-colors ease-in-out duration-200 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-black" | ||||
|                 )}> | ||||
|                 <span className="sr-only">Use setting</span> | ||||
|  |  | |||
|  | @ -1,7 +1,7 @@ | |||
| import Link from "next/link"; | ||||
| 
 | ||||
| const PoweredByCalendso = () => ( | ||||
|   <div className="text-xs text-center sm:text-right pt-1"> | ||||
|   <div className="text-xs text-center sm:text-right p-1"> | ||||
|     <Link href={`https://calendso.com?utm_source=embed&utm_medium=powered-by-button`}> | ||||
|       <a target="_blank" className="dark:text-white text-gray-500 opacity-50 hover:opacity-100"> | ||||
|         powered by{" "} | ||||
|  |  | |||
							
								
								
									
										161
									
								
								pages/404.tsx
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										161
									
								
								pages/404.tsx
									
									
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,161 @@ | |||
| import { ChevronRightIcon } from "@heroicons/react/solid"; | ||||
| import { DocumentTextIcon, BookOpenIcon, CodeIcon, CheckIcon } from "@heroicons/react/outline"; | ||||
| import { useRouter } from "next/router"; | ||||
| import React from "react"; | ||||
| import Link from "next/link"; | ||||
| import Head from "next/head"; | ||||
| 
 | ||||
| const links = [ | ||||
|   { | ||||
|     title: "Documentation", | ||||
|     description: "Learn how to integrate our tools with your app", | ||||
|     icon: DocumentTextIcon, | ||||
|     href: "https://docs.calendso.com", | ||||
|   }, | ||||
|   { | ||||
|     title: "API Reference", | ||||
|     description: "A complete API reference for our libraries", | ||||
|     icon: CodeIcon, | ||||
|     href: "https://api.docs.calendso.com", | ||||
|   }, | ||||
|   { | ||||
|     title: "Blog", | ||||
|     description: "Read our latest news and articles", | ||||
|     icon: BookOpenIcon, | ||||
|     href: "https://calendso.com/blog", | ||||
|   }, | ||||
| ]; | ||||
| 
 | ||||
| export default function Custom404() { | ||||
|   const router = useRouter(); | ||||
|   const username = router.asPath.replace("%20", "-"); | ||||
| 
 | ||||
|   return ( | ||||
|     <> | ||||
|       <Head> | ||||
|         <title>404: This page could not be found.</title> | ||||
|       </Head> | ||||
|       <div className="bg-white"> | ||||
|         <main className="max-w-7xl w-full mx-auto px-4 sm:px-6 lg:px-8"> | ||||
|           <div className="max-w-xl mx-auto py-16 sm:py-24"> | ||||
|             <div className="text-center"> | ||||
|               <p className="text-sm font-semibold text-black uppercase tracking-wide">404 error</p> | ||||
|               <h1 className="mt-2 text-4xl font-extrabold text-gray-900 tracking-tight sm:text-5xl"> | ||||
|                 This page does not exist. | ||||
|               </h1> | ||||
|               <a href="https://checkout.calendso.com" className="inline-block mt-2 text-lg "> | ||||
|                 The username <strong className="text-blue-500">calendso.com{username}</strong> is still | ||||
|                 available. <span className="text-blue-500">Register now</span>. | ||||
|               </a> | ||||
|             </div> | ||||
|             <div className="mt-12"> | ||||
|               <h2 className="text-sm font-semibold text-gray-500 tracking-wide uppercase">Popular pages</h2> | ||||
| 
 | ||||
|               <ul role="list" className="mt-4"> | ||||
|                 <li className="border-2 border-green-500 px-4 py-2"> | ||||
|                   <a | ||||
|                     href="https://checkout.calendso.com" | ||||
|                     className="relative py-6 flex items-start space-x-4"> | ||||
|                     <div className="flex-shrink-0"> | ||||
|                       <span className="flex items-center justify-center h-12 w-12 rounded-lg bg-green-50"> | ||||
|                         <CheckIcon className="h-6 w-6 text-green-500" aria-hidden="true" /> | ||||
|                       </span> | ||||
|                     </div> | ||||
|                     <div className="min-w-0 flex-1"> | ||||
|                       <h3 className="text-base font-medium text-gray-900"> | ||||
|                         <span className="rounded-sm focus-within:ring-2 focus-within:ring-offset-2 focus-within:ring-gray-500"> | ||||
|                           <span className="focus:outline-none"> | ||||
|                             <span className="absolute inset-0" aria-hidden="true" /> | ||||
|                             Register <strong className="text-green-500">{username}</strong> | ||||
|                           </span> | ||||
|                         </span> | ||||
|                       </h3> | ||||
|                       <p className="text-base text-gray-500">Claim your username and schedule events</p> | ||||
|                     </div> | ||||
|                     <div className="flex-shrink-0 self-center"> | ||||
|                       <ChevronRightIcon className="h-5 w-5 text-gray-400" aria-hidden="true" /> | ||||
|                     </div> | ||||
|                   </a> | ||||
|                 </li> | ||||
|               </ul> | ||||
| 
 | ||||
|               <ul role="list" className="mt-4 border-gray-200 divide-y divide-gray-200"> | ||||
|                 {links.map((link, linkIdx) => ( | ||||
|                   <li key={linkIdx} className="px-4 py-2"> | ||||
|                     <Link href={link.href}> | ||||
|                       <a className="relative py-6 flex items-start space-x-4"> | ||||
|                         <div className="flex-shrink-0"> | ||||
|                           <span className="flex items-center justify-center h-12 w-12 rounded-lg bg-gray-50"> | ||||
|                             <link.icon className="h-6 w-6 text-gray-700" aria-hidden="true" /> | ||||
|                           </span> | ||||
|                         </div> | ||||
|                         <div className="min-w-0 flex-1"> | ||||
|                           <h3 className="text-base font-medium text-gray-900"> | ||||
|                             <span className="rounded-sm focus-within:ring-2 focus-within:ring-offset-2 focus-within:ring-gray-500"> | ||||
|                               <span className="absolute inset-0" aria-hidden="true" /> | ||||
|                               {link.title} | ||||
|                             </span> | ||||
|                           </h3> | ||||
|                           <p className="text-base text-gray-500">{link.description}</p> | ||||
|                         </div> | ||||
|                         <div className="flex-shrink-0 self-center"> | ||||
|                           <ChevronRightIcon className="h-5 w-5 text-gray-400" aria-hidden="true" /> | ||||
|                         </div> | ||||
|                       </a> | ||||
|                     </Link> | ||||
|                   </li> | ||||
|                 ))} | ||||
|                 <li className="px-4 py-2"> | ||||
|                   <a href="https://calendso.com/slack" className="relative py-6 flex items-start space-x-4"> | ||||
|                     <div className="flex-shrink-0"> | ||||
|                       <span className="flex items-center justify-center h-12 w-12 rounded-lg bg-gray-50"> | ||||
|                         <svg | ||||
|                           viewBox="0 0 2447.6 2452.5" | ||||
|                           className="h-6 w-6" | ||||
|                           xmlns="http://www.w3.org/2000/svg"> | ||||
|                           <g clipRule="evenodd" fillRule="evenodd"> | ||||
|                             <path | ||||
|                               d="m897.4 0c-135.3.1-244.8 109.9-244.7 245.2-.1 135.3 109.5 245.1 244.8 245.2h244.8v-245.1c.1-135.3-109.5-245.1-244.9-245.3.1 0 .1 0 0 0m0 654h-652.6c-135.3.1-244.9 109.9-244.8 245.2-.2 135.3 109.4 245.1 244.7 245.3h652.7c135.3-.1 244.9-109.9 244.8-245.2.1-135.4-109.5-245.2-244.8-245.3z" | ||||
|                               fill="rgba(55, 65, 81)"></path> | ||||
|                             <path | ||||
|                               d="m2447.6 899.2c.1-135.3-109.5-245.1-244.8-245.2-135.3.1-244.9 109.9-244.8 245.2v245.3h244.8c135.3-.1 244.9-109.9 244.8-245.3zm-652.7 0v-654c.1-135.2-109.4-245-244.7-245.2-135.3.1-244.9 109.9-244.8 245.2v654c-.2 135.3 109.4 245.1 244.7 245.3 135.3-.1 244.9-109.9 244.8-245.3z" | ||||
|                               fill="rgba(55, 65, 81)"></path> | ||||
|                             <path | ||||
|                               d="m1550.1 2452.5c135.3-.1 244.9-109.9 244.8-245.2.1-135.3-109.5-245.1-244.8-245.2h-244.8v245.2c-.1 135.2 109.5 245 244.8 245.2zm0-654.1h652.7c135.3-.1 244.9-109.9 244.8-245.2.2-135.3-109.4-245.1-244.7-245.3h-652.7c-135.3.1-244.9 109.9-244.8 245.2-.1 135.4 109.4 245.2 244.7 245.3z" | ||||
|                               fill="rgba(55, 65, 81)"></path> | ||||
|                             <path | ||||
|                               d="m0 1553.2c-.1 135.3 109.5 245.1 244.8 245.2 135.3-.1 244.9-109.9 244.8-245.2v-245.2h-244.8c-135.3.1-244.9 109.9-244.8 245.2zm652.7 0v654c-.2 135.3 109.4 245.1 244.7 245.3 135.3-.1 244.9-109.9 244.8-245.2v-653.9c.2-135.3-109.4-245.1-244.7-245.3-135.4 0-244.9 109.8-244.8 245.1 0 0 0 .1 0 0" | ||||
|                               fill="rgba(55, 65, 81)"></path> | ||||
|                           </g> | ||||
|                         </svg> | ||||
|                       </span> | ||||
|                     </div> | ||||
|                     <div className="min-w-0 flex-1"> | ||||
|                       <h3 className="text-base font-medium text-gray-900"> | ||||
|                         <span className="rounded-sm focus-within:ring-2 focus-within:ring-offset-2 focus-within:ring-gray-500"> | ||||
|                           <span className="absolute inset-0" aria-hidden="true" /> | ||||
|                           Slack | ||||
|                         </span> | ||||
|                       </h3> | ||||
|                       <p className="text-base text-gray-500">Join our community</p> | ||||
|                     </div> | ||||
|                     <div className="flex-shrink-0 self-center"> | ||||
|                       <ChevronRightIcon className="h-5 w-5 text-gray-400" aria-hidden="true" /> | ||||
|                     </div> | ||||
|                   </a> | ||||
|                 </li> | ||||
|               </ul> | ||||
|               <div className="mt-8"> | ||||
|                 <Link href="/"> | ||||
|                   <a className="text-base font-medium text-black hover:text-gray-500"> | ||||
|                     Or go back home<span aria-hidden="true"> →</span> | ||||
|                   </a> | ||||
|                 </Link> | ||||
|               </div> | ||||
|             </div> | ||||
|           </div> | ||||
|         </main> | ||||
|       </div> | ||||
|     </> | ||||
|   ); | ||||
| } | ||||
|  | @ -1,7 +1,7 @@ | |||
| import { useEffect, useState } from "react"; | ||||
| import { GetServerSideProps, GetServerSidePropsContext } from "next"; | ||||
| import Head from "next/head"; | ||||
| import { ChevronDownIcon, ClockIcon, GlobeIcon, InformationCircleIcon } from "@heroicons/react/solid"; | ||||
| import { ChevronDownIcon, ChevronUpIcon, ClockIcon, GlobeIcon } from "@heroicons/react/solid"; | ||||
| import { useRouter } from "next/router"; | ||||
| import dayjs, { Dayjs } from "dayjs"; | ||||
| import * as Collapsible from "@radix-ui/react-collapsible"; | ||||
|  | @ -30,8 +30,6 @@ export default function Type(props): Type { | |||
|   const [timeFormat, setTimeFormat] = useState("h:mma"); | ||||
|   const telemetry = useTelemetry(); | ||||
| 
 | ||||
|   const [calHeight, setCalHeight] = useState(0); | ||||
| 
 | ||||
|   useEffect(() => { | ||||
|     handleToggle24hClock(localStorage.getItem("timeOption.is24hClock") === "true"); | ||||
|     telemetry.withJitsu((jitsu) => jitsu.track(telemetryEventTypes.pageView, collectPageParameters())); | ||||
|  | @ -81,7 +79,7 @@ export default function Type(props): Type { | |||
| 
 | ||||
|   return ( | ||||
|     isReady && ( | ||||
|       <div className="bg-neutral-50 dark:bg-neutral-900 h-screen"> | ||||
|       <div> | ||||
|         <Head> | ||||
|           <title> | ||||
|             {rescheduleUid && "Reschedule"} {props.eventType.title} | {props.user.name || props.user.username}{" "} | ||||
|  | @ -128,72 +126,77 @@ export default function Type(props): Type { | |||
|             } | ||||
|           /> | ||||
|         </Head> | ||||
|         <main className={"flex sm:py-12 w-11/12 mx-auto"}> | ||||
|           <div className="w-2/12 md:pt-32"> | ||||
|             <Avatar user={props.user} className="w-12 h-12 rounded-full mb-4" /> | ||||
|             <h1 className="text-xl font-semibold dark:text-neutral-100 text-neutral-900 mb-2"> | ||||
|               {props.user.name} | ||||
|             </h1> | ||||
|             <p className="text-neutral-500 mb-1 px-2 py-1 -ml-2"> | ||||
|               <InformationCircleIcon className="inline-block w-4 h-4 mr-1 -mt-1" /> | ||||
|               {props.eventType.title} | ||||
|             </p> | ||||
|             <p className="text-neutral-500 mb-1 px-2 py-1 -ml-2"> | ||||
|               <ClockIcon className="inline-block w-4 h-4 mr-1 -mt-1" /> | ||||
|               {props.eventType.length} minutes | ||||
|             </p> | ||||
|             <Collapsible.Root open={isTimeOptionsOpen} onOpenChange={setIsTimeOptionsOpen}> | ||||
|               <Collapsible.Trigger className="text-neutral-500 mb-1 px-2 py-1 -ml-2"> | ||||
|                 <GlobeIcon className="inline-block w-4 h-4 mr-1 -mt-1" /> | ||||
|                 {timeZone()} | ||||
|                 <ChevronDownIcon className="inline-block w-4 h-4 ml-1 -mt-1" /> | ||||
|               </Collapsible.Trigger> | ||||
|               <Collapsible.Content> | ||||
|                 <TimeOptions | ||||
|                   onSelectTimeZone={handleSelectTimeZone} | ||||
|                   onToggle24hClock={handleToggle24hClock} | ||||
|                 /> | ||||
|               </Collapsible.Content> | ||||
|             </Collapsible.Root> | ||||
|           </div> | ||||
|           <div className="w-8/12"> | ||||
|             <DatePicker | ||||
|               date={selectedDate} | ||||
|               periodType={props.eventType?.periodType} | ||||
|               periodStartDate={props.eventType?.periodStartDate} | ||||
|               periodEndDate={props.eventType?.periodEndDate} | ||||
|               periodDays={props.eventType?.periodDays} | ||||
|               periodCountCalendarDays={props.eventType?.periodCountCalendarDays} | ||||
|               weekStart={props.user.weekStart} | ||||
|               onDatePicked={changeDate} | ||||
|               workingHours={props.workingHours} | ||||
|               organizerTimeZone={props.eventType.timeZone || props.user.timeZone} | ||||
|               inviteeTimeZone={timeZone()} | ||||
|               eventLength={props.eventType.length} | ||||
|               minimumBookingNotice={props.eventType.minimumBookingNotice} | ||||
|               setHeight={setCalHeight} | ||||
|             /> | ||||
|           </div> | ||||
|           <div className="w-2/12"> | ||||
|             {selectedDate && ( | ||||
|               <AvailableTimes | ||||
|                 workingHours={props.workingHours} | ||||
|                 timeFormat={timeFormat} | ||||
|                 organizerTimeZone={props.eventType.timeZone || props.user.timeZone} | ||||
|                 minimumBookingNotice={props.eventType.minimumBookingNotice} | ||||
|                 eventTypeId={props.eventType.id} | ||||
|                 eventLength={props.eventType.length} | ||||
|         <main | ||||
|           className={ | ||||
|             "mx-auto my-0 sm:my-24 transition-max-width ease-in-out duration-500 " + | ||||
|             (selectedDate ? "max-w-6xl" : "max-w-3xl") | ||||
|           }> | ||||
|           <div className="dark:bg-neutral-900 bg-white border border-gray-200 rounded-sm dark:border-0"> | ||||
|             <div className="sm:flex px-4 py-5 sm:p-4"> | ||||
|               <div | ||||
|                 className={ | ||||
|                   "pr-8 sm:border-r sm:dark:border-black " + (selectedDate ? "sm:w-1/3" : "sm:w-1/2") | ||||
|                 }> | ||||
|                 <Avatar user={props.user} className="w-16 h-16 rounded-full mb-4" /> | ||||
|                 <h2 className="font-medium dark:text-gray-300 text-gray-500">{props.user.name}</h2> | ||||
|                 <h1 className="text-3xl font-semibold dark:text-white text-gray-800 mb-4"> | ||||
|                   {props.eventType.title} | ||||
|                 </h1> | ||||
|                 <p className="text-gray-500 mb-1 px-2 py-1 -ml-2"> | ||||
|                   <ClockIcon className="inline-block w-4 h-4 mr-1 -mt-1" /> | ||||
|                   {props.eventType.length} minutes | ||||
|                 </p> | ||||
| 
 | ||||
|                 <Collapsible.Root open={isTimeOptionsOpen} onOpenChange={setIsTimeOptionsOpen}> | ||||
|                   <Collapsible.Trigger className="text-gray-500 mb-1 px-2 py-1 -ml-2"> | ||||
|                     <GlobeIcon className="inline-block w-4 h-4 mr-1 -mt-1" /> | ||||
|                     {timeZone()} | ||||
|                     {isTimeOptionsOpen ? ( | ||||
|                       <ChevronUpIcon className="inline-block w-4 h-4 ml-1 -mt-1" /> | ||||
|                     ) : ( | ||||
|                       <ChevronDownIcon className="inline-block w-4 h-4 ml-1 -mt-1" /> | ||||
|                     )} | ||||
|                   </Collapsible.Trigger> | ||||
|                   <Collapsible.Content> | ||||
|                     <TimeOptions | ||||
|                       onSelectTimeZone={handleSelectTimeZone} | ||||
|                       onToggle24hClock={handleToggle24hClock} | ||||
|                     /> | ||||
|                   </Collapsible.Content> | ||||
|                 </Collapsible.Root> | ||||
| 
 | ||||
|                 <p className="dark:text-gray-200 text-gray-600 mt-3 mb-8">{props.eventType.description}</p> | ||||
|               </div> | ||||
|               <DatePicker | ||||
|                 date={selectedDate} | ||||
|                 user={props.user} | ||||
|                 height={calHeight} | ||||
|                 periodType={props.eventType?.periodType} | ||||
|                 periodStartDate={props.eventType?.periodStartDate} | ||||
|                 periodEndDate={props.eventType?.periodEndDate} | ||||
|                 periodDays={props.eventType?.periodDays} | ||||
|                 periodCountCalendarDays={props.eventType?.periodCountCalendarDays} | ||||
|                 weekStart={props.user.weekStart} | ||||
|                 onDatePicked={changeDate} | ||||
|                 workingHours={props.workingHours} | ||||
|                 organizerTimeZone={props.eventType.timeZone || props.user.timeZone} | ||||
|                 inviteeTimeZone={timeZone()} | ||||
|                 eventLength={props.eventType.length} | ||||
|                 minimumBookingNotice={props.eventType.minimumBookingNotice} | ||||
|               /> | ||||
|             )} | ||||
|           </div> | ||||
|           {!props.user.hideBranding && ( | ||||
|             <div className="absolute top-4 right-4"> | ||||
|               <PoweredByCalendso /> | ||||
|               {selectedDate && ( | ||||
|                 <AvailableTimes | ||||
|                   workingHours={props.workingHours} | ||||
|                   timeFormat={timeFormat} | ||||
|                   organizerTimeZone={props.eventType.timeZone || props.user.timeZone} | ||||
|                   minimumBookingNotice={props.eventType.minimumBookingNotice} | ||||
|                   eventTypeId={props.eventType.id} | ||||
|                   eventLength={props.eventType.length} | ||||
|                   date={selectedDate} | ||||
|                   user={props.user} | ||||
|                 /> | ||||
|               )} | ||||
|             </div> | ||||
|           )} | ||||
|           </div> | ||||
|           {!props.user.hideBranding && <PoweredByCalendso />} | ||||
|         </main> | ||||
|       </div> | ||||
|     ) | ||||
|  |  | |||
|  | @ -18,7 +18,7 @@ class MyDocument extends Document { | |||
|           <meta name="msapplication-TileColor" content="#ff0000" /> | ||||
|           <meta name="theme-color" content="#ffffff" /> | ||||
|         </Head> | ||||
|         <body className="dark:bg-neutral-900 bg-white"> | ||||
|         <body className="dark:bg-black bg-gray-100"> | ||||
|           <Main /> | ||||
|           <NextScript /> | ||||
|         </body> | ||||
|  |  | |||
|  | @ -3,7 +3,7 @@ | |||
| <svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" | ||||
| 	 viewBox="0 0 427 97.5" style="enable-background:new 0 0 427 97.5;" xml:space="preserve"> | ||||
| <style type="text/css"> | ||||
| 	.st0{fill-rule:evenodd;clip-rule:evenodd;fill:#104D86;} | ||||
| 	.st0{fillRule:evenodd;clipRule:evenodd;fill:#104D86;} | ||||
| </style> | ||||
| <path class="st0" d="M27.5,88.2c-4.9,0-9.7-1.2-14-3.6c-4.2-2.4-7.6-5.8-9.9-10c-4.8-8.8-4.8-19.4,0-28.2c2.3-4.2,5.8-7.7,10-10 | ||||
| 	c4.3-2.4,9.1-3.7,14-3.6c6-0.1,11.8,1.7,16.5,5.3s8,8.7,9.9,15.4H42.8c-1.3-3-3.4-5.5-6.2-7.2c-2.6-1.6-5.6-2.5-8.7-2.5 | ||||
|  |  | |||
| Before Width: | Height: | Size: 4.2 KiB After Width: | Height: | Size: 4.2 KiB | 
		Loading…
	
		Reference in a new issue
	
	 Peer Richelsen
						Peer Richelsen