Fix 404 error when editing default availability & create new availability from event type page (#5085)
* Edit/create new availability * Connect new schedule to event type * Remove comment * Shell back button executes window.history.back * Fix default schedule * Add default badge * Fix type error
This commit is contained in:
1 parent
16eb516a9b
commit
317909d20a
6 files changed
+68
-6
No files matched your search
@@ -170,7 +170,7 @@ type LayoutProps = {
|
||||
TopNavContainer?: ReactNode;
|
||||
drawerState?: DrawerState;
|
||||
HeadingLeftIcon?: ReactNode;
|
||||
backPath?: string; // renders back button to specified path
|
||||
backPath?: string | boolean; // renders back button to specified path
|
||||
// use when content needs to expand with flex
|
||||
flexChildrenContainer?: boolean;
|
||||
isPublic?: boolean;
|
||||
@@ -773,7 +773,9 @@ export function ShellMain(props: LayoutProps) {
|
||||
<Button
|
||||
size="icon"
|
||||
color="minimal"
|
||||
onClick={() => router.push(props.backPath as string)}
|
||||
onClick={() =>
|
||||
typeof props.backPath === "string" ? router.push(props.backPath as string) : router.back()
|
||||
}
|
||||
StartIcon={Icon.FiArrowLeft}
|
||||
aria-label="Go Back"
|
||||
className="ltr:mr-2 rtl:ml-2"
|
||||
|
||||
@@ -71,7 +71,24 @@ const Select = <
|
||||
return getReactSelectProps<Option, IsMulti, Group>({ className, components: components || {} });
|
||||
}, [className, components]);
|
||||
|
||||
return <ReactSelect {...reactSelectProps} {...props} />;
|
||||
return (
|
||||
<ReactSelect
|
||||
{...reactSelectProps}
|
||||
{...props}
|
||||
styles={{
|
||||
option: (defaultStyles, state) => ({
|
||||
...defaultStyles,
|
||||
backgroundColor: state.isSelected
|
||||
? state.isFocused
|
||||
? "var(--brand-color)"
|
||||
: "var(--brand-color)"
|
||||
: state.isFocused
|
||||
? "var(--brand-color-dark-mode)"
|
||||
: "var(--brand-text-color)",
|
||||
}),
|
||||
}}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
||||
export const SelectField = function SelectField<
|
||||
|
||||
Reference in new issue
Block a user