@idkwebsites/components 0.1.17 → 0.1.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/BOOKING-WIDGET.md +340 -0
- package/dist/index.cjs +899 -20
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +32 -4
- package/dist/index.d.ts +32 -4
- package/dist/index.js +905 -21
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1410 -0
- package/dist/styles.css.map +1 -1
- package/package.json +25 -9
package/dist/index.d.cts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { ReactNode } from 'react';
|
|
2
|
+
import { ReactNode, ComponentType } from 'react';
|
|
3
3
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
4
4
|
import { DehydratedState, DefaultOptions, QueryClient } from '@tanstack/react-query';
|
|
5
|
+
import { Scissors } from 'lucide-react';
|
|
5
6
|
|
|
6
7
|
interface PlatformProviderProps {
|
|
7
8
|
apiKey: string;
|
|
@@ -402,7 +403,7 @@ interface ContactFormProps {
|
|
|
402
403
|
}
|
|
403
404
|
declare function ContactForm({ fields, formType, submitLabel, className, onSuccess, onError, }: ContactFormProps): react_jsx_runtime.JSX.Element;
|
|
404
405
|
|
|
405
|
-
interface BookingWidgetProps {
|
|
406
|
+
interface BookingWidgetProps$1 {
|
|
406
407
|
className?: string;
|
|
407
408
|
showStaffSelection?: boolean;
|
|
408
409
|
onSuccess?: (booking: unknown) => void;
|
|
@@ -439,7 +440,34 @@ interface BookingWidgetProps {
|
|
|
439
440
|
disabledWeekdays?: number[];
|
|
440
441
|
showFullyBookedLabel?: boolean;
|
|
441
442
|
}
|
|
442
|
-
declare function BookingWidget({ className, title, subtitle, serviceSearchPlaceholder, categoryLabel, serviceListMaxHeight, serviceLayout, serviceColumns, showServicePagination, staffLayout, staffColumns, showStaffPagination, timeLayout, showFullyBookedLabel, calendarVariant, enableServiceSearch, enableCategoryFilter, enableDatePaging, disabledWeekdays, ...hookProps }: BookingWidgetProps): react_jsx_runtime.JSX.Element;
|
|
443
|
+
declare function BookingWidget({ className, title, subtitle, serviceSearchPlaceholder, categoryLabel, serviceListMaxHeight, serviceLayout, serviceColumns, showServicePagination, staffLayout, staffColumns, showStaffPagination, timeLayout, showFullyBookedLabel, calendarVariant, enableServiceSearch, enableCategoryFilter, enableDatePaging, disabledWeekdays, ...hookProps }: BookingWidgetProps$1): react_jsx_runtime.JSX.Element;
|
|
444
|
+
|
|
445
|
+
interface BookingWidgetProps {
|
|
446
|
+
/** Navigation links shown in the mobile menu overlay. Omit to hide hamburger. */
|
|
447
|
+
navLinks?: {
|
|
448
|
+
label: string;
|
|
449
|
+
href: string;
|
|
450
|
+
}[];
|
|
451
|
+
/** Custom icon for the mobile menu open button (default: lucide Menu) */
|
|
452
|
+
menuIcon?: ReactNode;
|
|
453
|
+
/** Custom icon for the mobile menu close button (default: lucide X) */
|
|
454
|
+
closeIcon?: ReactNode;
|
|
455
|
+
/** Override the category → icon mapping (keyword → React component) */
|
|
456
|
+
categoryIcons?: Record<string, typeof Scissors>;
|
|
457
|
+
/** Override step titles for mobile flow */
|
|
458
|
+
stepTitles?: [string, string, string, string];
|
|
459
|
+
/**
|
|
460
|
+
* Link component for mobile nav. Defaults to a plain `<a>` tag.
|
|
461
|
+
* Next.js sites should pass `Link` from `next/link` for client-side navigation.
|
|
462
|
+
*/
|
|
463
|
+
linkComponent?: ComponentType<{
|
|
464
|
+
href: string;
|
|
465
|
+
className?: string;
|
|
466
|
+
onClick?: () => void;
|
|
467
|
+
children: ReactNode;
|
|
468
|
+
}>;
|
|
469
|
+
}
|
|
470
|
+
declare function BookingWidgetPanel({ navLinks, menuIcon, closeIcon, categoryIcons, stepTitles, linkComponent: LinkComp, }?: BookingWidgetProps): react_jsx_runtime.JSX.Element;
|
|
443
471
|
|
|
444
472
|
interface AvailabilityPickerProps {
|
|
445
473
|
serviceId: string;
|
|
@@ -487,4 +515,4 @@ interface TimePickerProps {
|
|
|
487
515
|
}
|
|
488
516
|
declare function TimePicker({ slots, selectedTime, onSelect, className, }: TimePickerProps): react_jsx_runtime.JSX.Element;
|
|
489
517
|
|
|
490
|
-
export { AvailabilityPicker, type AvailabilityResult, type BookingCancelInput, type BookingCreateInput, type BookingLookup, BookingWidget, ContactForm, type ContactSubmissionInput, DatePicker, PlatformProvider, type Service, ServiceCard, ServicePicker, ServicesList, type ServicesQueryParams, type StaffMember, StaffPicker, TeamGrid, TeamMember, type TeamQueryParams, type TenantInfo, TimePicker, type UseBookingWidgetOptions, type UseBookingWidgetReturn, useAvailability, useBookingLookup, useBookingWidget, useCancelBooking, useCreateBooking, useServices, useTeam, useTenant };
|
|
518
|
+
export { AvailabilityPicker, type AvailabilityResult, type BookingCancelInput, type BookingCreateInput, type BookingLookup, BookingWidget, BookingWidgetPanel, type BookingWidgetProps, ContactForm, type ContactSubmissionInput, DatePicker, PlatformProvider, type Service, ServiceCard, ServicePicker, ServicesList, type ServicesQueryParams, type StaffMember, StaffPicker, TeamGrid, TeamMember, type TeamQueryParams, type TenantInfo, TimePicker, type UseBookingWidgetOptions, type UseBookingWidgetReturn, useAvailability, useBookingLookup, useBookingWidget, useCancelBooking, useCreateBooking, useServices, useTeam, useTenant };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { ReactNode } from 'react';
|
|
2
|
+
import { ReactNode, ComponentType } from 'react';
|
|
3
3
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
4
4
|
import { DehydratedState, DefaultOptions, QueryClient } from '@tanstack/react-query';
|
|
5
|
+
import { Scissors } from 'lucide-react';
|
|
5
6
|
|
|
6
7
|
interface PlatformProviderProps {
|
|
7
8
|
apiKey: string;
|
|
@@ -402,7 +403,7 @@ interface ContactFormProps {
|
|
|
402
403
|
}
|
|
403
404
|
declare function ContactForm({ fields, formType, submitLabel, className, onSuccess, onError, }: ContactFormProps): react_jsx_runtime.JSX.Element;
|
|
404
405
|
|
|
405
|
-
interface BookingWidgetProps {
|
|
406
|
+
interface BookingWidgetProps$1 {
|
|
406
407
|
className?: string;
|
|
407
408
|
showStaffSelection?: boolean;
|
|
408
409
|
onSuccess?: (booking: unknown) => void;
|
|
@@ -439,7 +440,34 @@ interface BookingWidgetProps {
|
|
|
439
440
|
disabledWeekdays?: number[];
|
|
440
441
|
showFullyBookedLabel?: boolean;
|
|
441
442
|
}
|
|
442
|
-
declare function BookingWidget({ className, title, subtitle, serviceSearchPlaceholder, categoryLabel, serviceListMaxHeight, serviceLayout, serviceColumns, showServicePagination, staffLayout, staffColumns, showStaffPagination, timeLayout, showFullyBookedLabel, calendarVariant, enableServiceSearch, enableCategoryFilter, enableDatePaging, disabledWeekdays, ...hookProps }: BookingWidgetProps): react_jsx_runtime.JSX.Element;
|
|
443
|
+
declare function BookingWidget({ className, title, subtitle, serviceSearchPlaceholder, categoryLabel, serviceListMaxHeight, serviceLayout, serviceColumns, showServicePagination, staffLayout, staffColumns, showStaffPagination, timeLayout, showFullyBookedLabel, calendarVariant, enableServiceSearch, enableCategoryFilter, enableDatePaging, disabledWeekdays, ...hookProps }: BookingWidgetProps$1): react_jsx_runtime.JSX.Element;
|
|
444
|
+
|
|
445
|
+
interface BookingWidgetProps {
|
|
446
|
+
/** Navigation links shown in the mobile menu overlay. Omit to hide hamburger. */
|
|
447
|
+
navLinks?: {
|
|
448
|
+
label: string;
|
|
449
|
+
href: string;
|
|
450
|
+
}[];
|
|
451
|
+
/** Custom icon for the mobile menu open button (default: lucide Menu) */
|
|
452
|
+
menuIcon?: ReactNode;
|
|
453
|
+
/** Custom icon for the mobile menu close button (default: lucide X) */
|
|
454
|
+
closeIcon?: ReactNode;
|
|
455
|
+
/** Override the category → icon mapping (keyword → React component) */
|
|
456
|
+
categoryIcons?: Record<string, typeof Scissors>;
|
|
457
|
+
/** Override step titles for mobile flow */
|
|
458
|
+
stepTitles?: [string, string, string, string];
|
|
459
|
+
/**
|
|
460
|
+
* Link component for mobile nav. Defaults to a plain `<a>` tag.
|
|
461
|
+
* Next.js sites should pass `Link` from `next/link` for client-side navigation.
|
|
462
|
+
*/
|
|
463
|
+
linkComponent?: ComponentType<{
|
|
464
|
+
href: string;
|
|
465
|
+
className?: string;
|
|
466
|
+
onClick?: () => void;
|
|
467
|
+
children: ReactNode;
|
|
468
|
+
}>;
|
|
469
|
+
}
|
|
470
|
+
declare function BookingWidgetPanel({ navLinks, menuIcon, closeIcon, categoryIcons, stepTitles, linkComponent: LinkComp, }?: BookingWidgetProps): react_jsx_runtime.JSX.Element;
|
|
443
471
|
|
|
444
472
|
interface AvailabilityPickerProps {
|
|
445
473
|
serviceId: string;
|
|
@@ -487,4 +515,4 @@ interface TimePickerProps {
|
|
|
487
515
|
}
|
|
488
516
|
declare function TimePicker({ slots, selectedTime, onSelect, className, }: TimePickerProps): react_jsx_runtime.JSX.Element;
|
|
489
517
|
|
|
490
|
-
export { AvailabilityPicker, type AvailabilityResult, type BookingCancelInput, type BookingCreateInput, type BookingLookup, BookingWidget, ContactForm, type ContactSubmissionInput, DatePicker, PlatformProvider, type Service, ServiceCard, ServicePicker, ServicesList, type ServicesQueryParams, type StaffMember, StaffPicker, TeamGrid, TeamMember, type TeamQueryParams, type TenantInfo, TimePicker, type UseBookingWidgetOptions, type UseBookingWidgetReturn, useAvailability, useBookingLookup, useBookingWidget, useCancelBooking, useCreateBooking, useServices, useTeam, useTenant };
|
|
518
|
+
export { AvailabilityPicker, type AvailabilityResult, type BookingCancelInput, type BookingCreateInput, type BookingLookup, BookingWidget, BookingWidgetPanel, type BookingWidgetProps, ContactForm, type ContactSubmissionInput, DatePicker, PlatformProvider, type Service, ServiceCard, ServicePicker, ServicesList, type ServicesQueryParams, type StaffMember, StaffPicker, TeamGrid, TeamMember, type TeamQueryParams, type TenantInfo, TimePicker, type UseBookingWidgetOptions, type UseBookingWidgetReturn, useAvailability, useBookingLookup, useBookingWidget, useCancelBooking, useCreateBooking, useServices, useTeam, useTenant };
|