Availability uiux improvements (#7466)
* Delete modal + button on [schedule] * Update to V2 component * Default Icon --------- Co-authored-by: Alex van Andel <[email protected]>
This commit is contained in:
1 parent
e8acc3e500
commit
f4c3ab6431
4 files changed
+52
-17
No files matched your search
@@ -12,6 +12,7 @@ import {
|
||||
DialogFooter,
|
||||
DialogTrigger,
|
||||
Form,
|
||||
InputField,
|
||||
showToast,
|
||||
} from "@calcom/ui";
|
||||
import { FiPlus } from "@calcom/ui/components/icon";
|
||||
@@ -68,21 +69,14 @@ export function NewScheduleButton({ name = "new-schedule" }: { name?: string })
|
||||
handleSubmit={(values) => {
|
||||
createMutation.mutate(values);
|
||||
}}>
|
||||
<div className="space-y-2">
|
||||
<label htmlFor="label" className="block text-sm font-medium text-gray-700">
|
||||
{t("name")}
|
||||
</label>
|
||||
<div className="mt-1">
|
||||
<input
|
||||
type="text"
|
||||
id="name"
|
||||
required
|
||||
className="block w-full rounded-sm border-gray-300 text-sm"
|
||||
placeholder={t("default_schedule_name")}
|
||||
{...register("name")}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<InputField
|
||||
label={t("name")}
|
||||
type="text"
|
||||
id="name"
|
||||
required
|
||||
placeholder={t("default_schedule_name")}
|
||||
{...register("name")}
|
||||
/>
|
||||
<DialogFooter>
|
||||
<DialogClose />
|
||||
<Button type="submit" loading={createMutation.isLoading}>
|
||||
|
||||
@@ -14,7 +14,7 @@ import {
|
||||
DropdownItem,
|
||||
DropdownMenuTrigger,
|
||||
} from "@calcom/ui";
|
||||
import { FiGlobe, FiMoreHorizontal, FiTrash } from "@calcom/ui/components/icon";
|
||||
import { FiGlobe, FiMoreHorizontal, FiTrash, FiClock } from "@calcom/ui/components/icon";
|
||||
|
||||
export function ScheduleListItem({
|
||||
schedule,
|
||||
@@ -87,6 +87,7 @@ export function ScheduleListItem({
|
||||
{!schedule.isDefault && (
|
||||
<DropdownItem
|
||||
type="button"
|
||||
StartIcon={FiClock}
|
||||
onClick={() => {
|
||||
updateDefault({
|
||||
scheduleId: schedule.id,
|
||||
|
||||
Reference in new issue
Block a user