@kjaniec-dev/ui 0.9.0 → 0.9.2
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/README.md +2 -0
- package/dist/index.cjs +427 -22
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +128 -2
- package/dist/index.d.ts +128 -2
- package/dist/index.js +426 -23
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ClassValue } from 'clsx';
|
|
2
2
|
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
3
|
import * as React from 'react';
|
|
4
|
+
import React__default from 'react';
|
|
4
5
|
import { VariantProps } from 'class-variance-authority';
|
|
5
6
|
|
|
6
7
|
/**
|
|
@@ -790,6 +791,8 @@ interface RangeCalendarProps {
|
|
|
790
791
|
min?: Date;
|
|
791
792
|
max?: Date;
|
|
792
793
|
disabledDates?: (date: Date) => boolean;
|
|
794
|
+
/** Force rendering 1 month instead of 2 side-by-side. */
|
|
795
|
+
singleMonth?: boolean;
|
|
793
796
|
className?: string;
|
|
794
797
|
}
|
|
795
798
|
declare const RangeCalendar: React.ForwardRefExoticComponent<RangeCalendarProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -936,6 +939,7 @@ interface StepperProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
936
939
|
defaultValue?: number;
|
|
937
940
|
onValueChange?: (value: number) => void;
|
|
938
941
|
orientation?: StepperOrientation;
|
|
942
|
+
responsive?: boolean;
|
|
939
943
|
linear?: boolean;
|
|
940
944
|
}
|
|
941
945
|
declare const Stepper: React.ForwardRefExoticComponent<StepperProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -971,6 +975,7 @@ interface AppShellProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
971
975
|
headerVariant?: "glass" | "solid" | "transparent";
|
|
972
976
|
paddedContent?: boolean;
|
|
973
977
|
mobileNav?: React.ReactNode;
|
|
978
|
+
bottomNav?: React.ReactNode;
|
|
974
979
|
}
|
|
975
980
|
interface AppShellBannerProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
976
981
|
variant?: "primary" | "accent" | "muted";
|
|
@@ -1193,11 +1198,12 @@ interface InboxContentProps {
|
|
|
1193
1198
|
viewAllHref?: string;
|
|
1194
1199
|
viewAllLabel?: string;
|
|
1195
1200
|
emptyState?: React.ReactNode;
|
|
1201
|
+
align?: "auto" | "start" | "end";
|
|
1196
1202
|
width?: number | string;
|
|
1197
1203
|
maxHeight?: number | string;
|
|
1198
1204
|
className?: string;
|
|
1199
1205
|
}
|
|
1200
|
-
declare function InboxContent({ items, onMarkAllRead, onDismiss, viewAllHref, viewAllLabel, emptyState, width, maxHeight, className, }: InboxContentProps): React.JSX.Element | null;
|
|
1206
|
+
declare function InboxContent({ items, onMarkAllRead, onDismiss, viewAllHref, viewAllLabel, emptyState, align, width, maxHeight, className, }: InboxContentProps): React.JSX.Element | null;
|
|
1201
1207
|
|
|
1202
1208
|
declare const DEFAULT_COLOR_SWATCHES: readonly ["#EF4444", "#F97316", "#F59E0B", "#10B981", "#14B8A6", "#06B6D4", "#3B82F6", "#6366F1", "#8B5CF6", "#EC4899", "#64748B", "#1E293B"];
|
|
1203
1209
|
declare function isValidHex(hex: string): boolean;
|
|
@@ -1258,4 +1264,124 @@ interface ImageGalleryProps {
|
|
|
1258
1264
|
}
|
|
1259
1265
|
declare function ImageGallery({ images, columns, aspectRatio, maxVisible, className, thumbnailClassName, lightboxClassName, onImageClick, }: ImageGalleryProps): React.JSX.Element;
|
|
1260
1266
|
|
|
1261
|
-
|
|
1267
|
+
/** Props for the inline InPost GeoWidget map component. */
|
|
1268
|
+
interface InPostGeowidgetProps {
|
|
1269
|
+
/** InPost API Token generated in InPost Manager for your domain. Required for production map. */
|
|
1270
|
+
token?: string;
|
|
1271
|
+
/** Widget language ('pl', 'en', 'uk', 'de', 'it', 'fr'). Default 'pl'. */
|
|
1272
|
+
language?: InPostLanguage;
|
|
1273
|
+
/** Widget configuration type ('parcelCollect', 'parcelCollectPayment', 'international', 'postBuy'). Default 'parcelCollect'. */
|
|
1274
|
+
config?: InPostConfigType;
|
|
1275
|
+
/** Enable sandbox environment. Default false. */
|
|
1276
|
+
sandbox?: boolean;
|
|
1277
|
+
/** Callback triggered when user selects a parcel locker or pick-up point on the map. */
|
|
1278
|
+
onPointSelect?: (point: InPostPoint) => void;
|
|
1279
|
+
/** Callback triggered when GeoWidget finishes loading. */
|
|
1280
|
+
onReady?: () => void;
|
|
1281
|
+
/** Callback triggered on script load error. */
|
|
1282
|
+
onError?: (error: Error) => void;
|
|
1283
|
+
/** Outer container CSS class name. */
|
|
1284
|
+
className?: string;
|
|
1285
|
+
/** Inline container styles. */
|
|
1286
|
+
style?: React__default.CSSProperties;
|
|
1287
|
+
/** Custom SDK JavaScript URL. */
|
|
1288
|
+
customScriptUrl?: string;
|
|
1289
|
+
/** Custom SDK CSS URL. */
|
|
1290
|
+
customCssUrl?: string;
|
|
1291
|
+
}
|
|
1292
|
+
declare global {
|
|
1293
|
+
namespace JSX {
|
|
1294
|
+
interface IntrinsicElements {
|
|
1295
|
+
'inpost-geowidget': React__default.DetailedHTMLProps<React__default.HTMLAttributes<HTMLElement> & {
|
|
1296
|
+
token?: string;
|
|
1297
|
+
language?: string;
|
|
1298
|
+
config?: string;
|
|
1299
|
+
sandbox?: string | boolean;
|
|
1300
|
+
onpointselect?: string;
|
|
1301
|
+
}, HTMLElement>;
|
|
1302
|
+
}
|
|
1303
|
+
}
|
|
1304
|
+
}
|
|
1305
|
+
declare const InPostGeowidget: React__default.FC<InPostGeowidgetProps>;
|
|
1306
|
+
|
|
1307
|
+
/** Props for the InPost GeoWidget Modal checkout component. */
|
|
1308
|
+
interface InPostGeowidgetModalProps {
|
|
1309
|
+
/** Currently selected point object or point code string (e.g. 'WAW01M'). */
|
|
1310
|
+
value?: InPostPoint | string | null;
|
|
1311
|
+
/** Callback triggered when point is selected on the map. */
|
|
1312
|
+
onSelect?: (point: InPostPoint) => void;
|
|
1313
|
+
/** Trigger button label. Default 'Wybierz Paczkomat®'. */
|
|
1314
|
+
triggerText?: string;
|
|
1315
|
+
/** Modal header title. Default 'Wybierz punkt odbioru InPost'. */
|
|
1316
|
+
modalTitle?: string;
|
|
1317
|
+
/** Disable trigger button. Default false. */
|
|
1318
|
+
disabled?: boolean;
|
|
1319
|
+
/** Controlled open state of the modal. */
|
|
1320
|
+
open?: boolean;
|
|
1321
|
+
/** Callback when open state changes. */
|
|
1322
|
+
onOpenChange?: (open: boolean) => void;
|
|
1323
|
+
/** Show selected point badge under trigger button. Default true. */
|
|
1324
|
+
showSelectedBadge?: boolean;
|
|
1325
|
+
/** Outer container CSS class name. */
|
|
1326
|
+
className?: string;
|
|
1327
|
+
/** Trigger button style variant ('primary', 'secondary', 'outline', 'ghost', 'danger'). Default 'outline'. */
|
|
1328
|
+
buttonVariant?: 'primary' | 'secondary' | 'outline' | 'ghost' | 'danger';
|
|
1329
|
+
/** Trigger button size ('sm', 'md', 'lg'). Default 'md'. */
|
|
1330
|
+
buttonSize?: 'sm' | 'md' | 'lg';
|
|
1331
|
+
/** InPost API Token (optional for sandbox). */
|
|
1332
|
+
token?: string;
|
|
1333
|
+
/** Widget language ('pl', 'en', 'uk', 'de', 'it', 'fr'). Default 'pl'. */
|
|
1334
|
+
language?: InPostLanguage;
|
|
1335
|
+
/** Widget configuration type ('parcelCollect', 'parcelCollectPayment', 'international', 'postBuy'). Default 'parcelCollect'. */
|
|
1336
|
+
config?: InPostConfigType;
|
|
1337
|
+
/** Enable sandbox environment. Default false. */
|
|
1338
|
+
sandbox?: boolean;
|
|
1339
|
+
/** Custom SDK JavaScript URL. */
|
|
1340
|
+
customScriptUrl?: string;
|
|
1341
|
+
/** Custom SDK CSS URL. */
|
|
1342
|
+
customCssUrl?: string;
|
|
1343
|
+
}
|
|
1344
|
+
declare const InPostGeowidgetModal: React__default.FC<InPostGeowidgetModalProps>;
|
|
1345
|
+
|
|
1346
|
+
interface InPostAddressDetails {
|
|
1347
|
+
city: string;
|
|
1348
|
+
street: string;
|
|
1349
|
+
building_number: string;
|
|
1350
|
+
post_code: string;
|
|
1351
|
+
province?: string;
|
|
1352
|
+
}
|
|
1353
|
+
interface InPostLocation {
|
|
1354
|
+
latitude: number;
|
|
1355
|
+
longitude: number;
|
|
1356
|
+
}
|
|
1357
|
+
interface InPostPoint {
|
|
1358
|
+
name: string;
|
|
1359
|
+
address: {
|
|
1360
|
+
line1: string;
|
|
1361
|
+
line2: string;
|
|
1362
|
+
};
|
|
1363
|
+
address_details: InPostAddressDetails;
|
|
1364
|
+
location: InPostLocation;
|
|
1365
|
+
type: string[] | string;
|
|
1366
|
+
status: string;
|
|
1367
|
+
location_description?: string;
|
|
1368
|
+
opening_hours?: string;
|
|
1369
|
+
payment_point_descr?: string;
|
|
1370
|
+
functions?: string[];
|
|
1371
|
+
[key: string]: unknown;
|
|
1372
|
+
}
|
|
1373
|
+
type InPostLanguage = 'pl' | 'en' | 'uk' | 'de' | 'it' | 'fr';
|
|
1374
|
+
type InPostConfigType = 'parcelCollect' | 'parcelCollectPayment' | 'international' | 'postBuy' | string;
|
|
1375
|
+
interface UseInPostScriptOptions {
|
|
1376
|
+
sandbox?: boolean;
|
|
1377
|
+
customScriptUrl?: string;
|
|
1378
|
+
customCssUrl?: string;
|
|
1379
|
+
}
|
|
1380
|
+
interface UseInPostScriptResult {
|
|
1381
|
+
isLoaded: boolean;
|
|
1382
|
+
error: Error | null;
|
|
1383
|
+
}
|
|
1384
|
+
|
|
1385
|
+
declare function useInPostScript(options?: UseInPostScriptOptions): UseInPostScriptResult;
|
|
1386
|
+
|
|
1387
|
+
export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, type AccordionProps, AccordionTrigger, Alert, type AlertProps, AppShell, AppShellBanner, type AppShellBannerProps, AppShellFooter, type AppShellFooterProps, AppShellHeader, type AppShellHeaderProps, AppShellMain, type AppShellMainProps, type AppShellProps, Avatar, AvatarGroup, type AvatarProps, Badge, type BadgeProps, BlogCard, type BlogCardAuthor, type BlogCardProps, BottomNavigation, type BottomNavigationItem, type BottomNavigationProps, BottomSheet, BottomSheetContent, BottomSheetDescription, BottomSheetFooter, BottomSheetHeader, type BottomSheetProps, BottomSheetTitle, Breadcrumb, BreadcrumbItem, type BreadcrumbItemProps, BreadcrumbSeparator, Button, type ButtonProps, Calendar, type CalendarProps, Card, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardTitle, Checkbox, CheckboxField, type CheckboxFieldProps, type CheckboxProps, CodeBlock, type CodeBlockProps, ColorPicker, ColorPickerField, type ColorPickerFieldProps, type ColorPickerProps, ColorPickerSwatch, type ColorPickerSwatchProps, Combobox, ComboboxField, type ComboboxFieldProps, type ComboboxOption, type ComboboxProps, CommandPalette, type CommandPaletteItem, type CommandPaletteProps, ConfirmDialog, type ConfirmDialogProps, DEFAULT_COLOR_SWATCHES, DashboardShell, type DashboardShellProps, DataTable, type DataTableColumn, type DataTableProps, DatePicker, DatePickerField, type DatePickerFieldProps, type DatePickerProps, type DateRange, DateRangePicker, DateRangePickerField, type DateRangePickerFieldProps, type DateRangePickerProps, DetailPageLayout, type DetailPageLayoutProps, Drawer, type DrawerProps, DropdownMenu, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuItem, type DropdownMenuItemProps, DropdownMenuSeparator, DropdownMenuTrigger, Dropzone, type DropzoneProps, EmptyState, type EmptyStateProps, ErrorState, type ErrorStateProps, Fab, type FabProps, Field, type FileRejection, FileUpload, FileUploadField, type FileUploadFieldProps, type FileUploadProps, FormField, type FormFieldProps, type GalleryImage, Hint, type HintProps, ImageGallery, type ImageGalleryProps, InPostGeowidget, InPostGeowidgetModal, type InPostGeowidgetModalProps, type InPostGeowidgetProps, type InPostPoint, InboxContent, type InboxContentProps, InboxPopover, type InboxPopoverProps, type InboxStateReturn, InboxTrigger, type InboxTriggerProps, Input, type InputProps, Kbd, type KbdProps, Label, type LabelProps, MetricCard, type MetricCardProps, Modal, ModalActions, ModalDescription, type ModalProps, ModalTitle, NotificationItem, type NotificationItemData, type NotificationItemProps, PageHeader, type PageHeaderProps, Pagination, type PaginationProps, Popover, PopoverContent, type PopoverContentProps, type PopoverProps, PopoverTrigger, PricingCard, type PricingCardProps, type PricingFeatureItem, Progress, type ProgressProps, ProgressRing, ProgressRingField, type ProgressRingFieldProps, type ProgressRingProps, type ProgressRingSize, type ProgressRingTone, ProjectCard, type ProjectCardMetric, type ProjectCardProps, type ProjectCardStatus, Radio, type RadioProps, RangeCalendar, type RangeCalendarProps, Rating, type RatingDistributionItem, RatingField, type RatingFieldProps, type RatingIconType, type RatingProps, type RatingSize, RatingSummary, type RatingSummaryProps, SectionHeader, type SectionHeaderActionsProps, type SectionHeaderAlign, type SectionHeaderDescriptionProps, type SectionHeaderHeadingLevel, type SectionHeaderKickerProps, type SectionHeaderProps, type SectionHeaderTitleProps, Segmented, type SegmentedOption, type SegmentedProps, Select, SelectField, type SelectFieldProps, type SelectProps, Separator, type SeparatorProps, SettingsLayout, type SettingsLayoutProps, SidebarNav, type SidebarNavGroup, type SidebarNavItem, type SidebarNavProps, Skeleton, type SkeletonProps, Slider, type SliderProps, Spinner, type SpinnerProps, Stat, type StatProps, Stepper, StepperContent, type StepperContentProps, StepperDescription, type StepperDescriptionProps, StepperIndicator, type StepperIndicatorProps, StepperItem, type StepperItemProps, StepperList, type StepperListProps, type StepperOrientation, type StepperProps, StepperSeparator, type StepperSeparatorProps, StepperTitle, type StepperTitleProps, StepperTrigger, type StepperTriggerProps, Switch, type SwitchProps, Table, TableBody, TableCell, type TableCellProps, TableHead, TableHeader, TableRow, TableToolbar, type TableToolbarProps, TableWrap, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsProps, TabsTrigger, type TabsTriggerProps, TextField, type TextFieldProps, Textarea, type TextareaProps, Timeline, type TimelineAlign, TimelineConnector, type TimelineConnectorProps, TimelineContent, type TimelineContentProps, TimelineDot, type TimelineDotProps, type TimelineDotSize, type TimelineDotVariant, TimelineItem, type TimelineItemProps, type TimelineProps, TimelineSeparator, type TimelineSeparatorProps, TimelineTime, TimelineTitle, type ToastOptions, ToastProvider, type ToastTone, ToggleGroup, type ToggleGroupOption, type ToggleGroupProps, Tooltip, type TooltipProps, type UploadItem, type UploadStatus, type UseStepperOptions, type UseStepperReturn, badgeVariants, buttonVariants, cn, formatRelativeTime, hexToHsl, hslToHex, isValidHex, normalizeHex, sliderThumbCSS, useInPostScript, useInboxState, useStepper, useToast };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ClassValue } from 'clsx';
|
|
2
2
|
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
3
|
import * as React from 'react';
|
|
4
|
+
import React__default from 'react';
|
|
4
5
|
import { VariantProps } from 'class-variance-authority';
|
|
5
6
|
|
|
6
7
|
/**
|
|
@@ -790,6 +791,8 @@ interface RangeCalendarProps {
|
|
|
790
791
|
min?: Date;
|
|
791
792
|
max?: Date;
|
|
792
793
|
disabledDates?: (date: Date) => boolean;
|
|
794
|
+
/** Force rendering 1 month instead of 2 side-by-side. */
|
|
795
|
+
singleMonth?: boolean;
|
|
793
796
|
className?: string;
|
|
794
797
|
}
|
|
795
798
|
declare const RangeCalendar: React.ForwardRefExoticComponent<RangeCalendarProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -936,6 +939,7 @@ interface StepperProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
936
939
|
defaultValue?: number;
|
|
937
940
|
onValueChange?: (value: number) => void;
|
|
938
941
|
orientation?: StepperOrientation;
|
|
942
|
+
responsive?: boolean;
|
|
939
943
|
linear?: boolean;
|
|
940
944
|
}
|
|
941
945
|
declare const Stepper: React.ForwardRefExoticComponent<StepperProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -971,6 +975,7 @@ interface AppShellProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
971
975
|
headerVariant?: "glass" | "solid" | "transparent";
|
|
972
976
|
paddedContent?: boolean;
|
|
973
977
|
mobileNav?: React.ReactNode;
|
|
978
|
+
bottomNav?: React.ReactNode;
|
|
974
979
|
}
|
|
975
980
|
interface AppShellBannerProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
976
981
|
variant?: "primary" | "accent" | "muted";
|
|
@@ -1193,11 +1198,12 @@ interface InboxContentProps {
|
|
|
1193
1198
|
viewAllHref?: string;
|
|
1194
1199
|
viewAllLabel?: string;
|
|
1195
1200
|
emptyState?: React.ReactNode;
|
|
1201
|
+
align?: "auto" | "start" | "end";
|
|
1196
1202
|
width?: number | string;
|
|
1197
1203
|
maxHeight?: number | string;
|
|
1198
1204
|
className?: string;
|
|
1199
1205
|
}
|
|
1200
|
-
declare function InboxContent({ items, onMarkAllRead, onDismiss, viewAllHref, viewAllLabel, emptyState, width, maxHeight, className, }: InboxContentProps): React.JSX.Element | null;
|
|
1206
|
+
declare function InboxContent({ items, onMarkAllRead, onDismiss, viewAllHref, viewAllLabel, emptyState, align, width, maxHeight, className, }: InboxContentProps): React.JSX.Element | null;
|
|
1201
1207
|
|
|
1202
1208
|
declare const DEFAULT_COLOR_SWATCHES: readonly ["#EF4444", "#F97316", "#F59E0B", "#10B981", "#14B8A6", "#06B6D4", "#3B82F6", "#6366F1", "#8B5CF6", "#EC4899", "#64748B", "#1E293B"];
|
|
1203
1209
|
declare function isValidHex(hex: string): boolean;
|
|
@@ -1258,4 +1264,124 @@ interface ImageGalleryProps {
|
|
|
1258
1264
|
}
|
|
1259
1265
|
declare function ImageGallery({ images, columns, aspectRatio, maxVisible, className, thumbnailClassName, lightboxClassName, onImageClick, }: ImageGalleryProps): React.JSX.Element;
|
|
1260
1266
|
|
|
1261
|
-
|
|
1267
|
+
/** Props for the inline InPost GeoWidget map component. */
|
|
1268
|
+
interface InPostGeowidgetProps {
|
|
1269
|
+
/** InPost API Token generated in InPost Manager for your domain. Required for production map. */
|
|
1270
|
+
token?: string;
|
|
1271
|
+
/** Widget language ('pl', 'en', 'uk', 'de', 'it', 'fr'). Default 'pl'. */
|
|
1272
|
+
language?: InPostLanguage;
|
|
1273
|
+
/** Widget configuration type ('parcelCollect', 'parcelCollectPayment', 'international', 'postBuy'). Default 'parcelCollect'. */
|
|
1274
|
+
config?: InPostConfigType;
|
|
1275
|
+
/** Enable sandbox environment. Default false. */
|
|
1276
|
+
sandbox?: boolean;
|
|
1277
|
+
/** Callback triggered when user selects a parcel locker or pick-up point on the map. */
|
|
1278
|
+
onPointSelect?: (point: InPostPoint) => void;
|
|
1279
|
+
/** Callback triggered when GeoWidget finishes loading. */
|
|
1280
|
+
onReady?: () => void;
|
|
1281
|
+
/** Callback triggered on script load error. */
|
|
1282
|
+
onError?: (error: Error) => void;
|
|
1283
|
+
/** Outer container CSS class name. */
|
|
1284
|
+
className?: string;
|
|
1285
|
+
/** Inline container styles. */
|
|
1286
|
+
style?: React__default.CSSProperties;
|
|
1287
|
+
/** Custom SDK JavaScript URL. */
|
|
1288
|
+
customScriptUrl?: string;
|
|
1289
|
+
/** Custom SDK CSS URL. */
|
|
1290
|
+
customCssUrl?: string;
|
|
1291
|
+
}
|
|
1292
|
+
declare global {
|
|
1293
|
+
namespace JSX {
|
|
1294
|
+
interface IntrinsicElements {
|
|
1295
|
+
'inpost-geowidget': React__default.DetailedHTMLProps<React__default.HTMLAttributes<HTMLElement> & {
|
|
1296
|
+
token?: string;
|
|
1297
|
+
language?: string;
|
|
1298
|
+
config?: string;
|
|
1299
|
+
sandbox?: string | boolean;
|
|
1300
|
+
onpointselect?: string;
|
|
1301
|
+
}, HTMLElement>;
|
|
1302
|
+
}
|
|
1303
|
+
}
|
|
1304
|
+
}
|
|
1305
|
+
declare const InPostGeowidget: React__default.FC<InPostGeowidgetProps>;
|
|
1306
|
+
|
|
1307
|
+
/** Props for the InPost GeoWidget Modal checkout component. */
|
|
1308
|
+
interface InPostGeowidgetModalProps {
|
|
1309
|
+
/** Currently selected point object or point code string (e.g. 'WAW01M'). */
|
|
1310
|
+
value?: InPostPoint | string | null;
|
|
1311
|
+
/** Callback triggered when point is selected on the map. */
|
|
1312
|
+
onSelect?: (point: InPostPoint) => void;
|
|
1313
|
+
/** Trigger button label. Default 'Wybierz Paczkomat®'. */
|
|
1314
|
+
triggerText?: string;
|
|
1315
|
+
/** Modal header title. Default 'Wybierz punkt odbioru InPost'. */
|
|
1316
|
+
modalTitle?: string;
|
|
1317
|
+
/** Disable trigger button. Default false. */
|
|
1318
|
+
disabled?: boolean;
|
|
1319
|
+
/** Controlled open state of the modal. */
|
|
1320
|
+
open?: boolean;
|
|
1321
|
+
/** Callback when open state changes. */
|
|
1322
|
+
onOpenChange?: (open: boolean) => void;
|
|
1323
|
+
/** Show selected point badge under trigger button. Default true. */
|
|
1324
|
+
showSelectedBadge?: boolean;
|
|
1325
|
+
/** Outer container CSS class name. */
|
|
1326
|
+
className?: string;
|
|
1327
|
+
/** Trigger button style variant ('primary', 'secondary', 'outline', 'ghost', 'danger'). Default 'outline'. */
|
|
1328
|
+
buttonVariant?: 'primary' | 'secondary' | 'outline' | 'ghost' | 'danger';
|
|
1329
|
+
/** Trigger button size ('sm', 'md', 'lg'). Default 'md'. */
|
|
1330
|
+
buttonSize?: 'sm' | 'md' | 'lg';
|
|
1331
|
+
/** InPost API Token (optional for sandbox). */
|
|
1332
|
+
token?: string;
|
|
1333
|
+
/** Widget language ('pl', 'en', 'uk', 'de', 'it', 'fr'). Default 'pl'. */
|
|
1334
|
+
language?: InPostLanguage;
|
|
1335
|
+
/** Widget configuration type ('parcelCollect', 'parcelCollectPayment', 'international', 'postBuy'). Default 'parcelCollect'. */
|
|
1336
|
+
config?: InPostConfigType;
|
|
1337
|
+
/** Enable sandbox environment. Default false. */
|
|
1338
|
+
sandbox?: boolean;
|
|
1339
|
+
/** Custom SDK JavaScript URL. */
|
|
1340
|
+
customScriptUrl?: string;
|
|
1341
|
+
/** Custom SDK CSS URL. */
|
|
1342
|
+
customCssUrl?: string;
|
|
1343
|
+
}
|
|
1344
|
+
declare const InPostGeowidgetModal: React__default.FC<InPostGeowidgetModalProps>;
|
|
1345
|
+
|
|
1346
|
+
interface InPostAddressDetails {
|
|
1347
|
+
city: string;
|
|
1348
|
+
street: string;
|
|
1349
|
+
building_number: string;
|
|
1350
|
+
post_code: string;
|
|
1351
|
+
province?: string;
|
|
1352
|
+
}
|
|
1353
|
+
interface InPostLocation {
|
|
1354
|
+
latitude: number;
|
|
1355
|
+
longitude: number;
|
|
1356
|
+
}
|
|
1357
|
+
interface InPostPoint {
|
|
1358
|
+
name: string;
|
|
1359
|
+
address: {
|
|
1360
|
+
line1: string;
|
|
1361
|
+
line2: string;
|
|
1362
|
+
};
|
|
1363
|
+
address_details: InPostAddressDetails;
|
|
1364
|
+
location: InPostLocation;
|
|
1365
|
+
type: string[] | string;
|
|
1366
|
+
status: string;
|
|
1367
|
+
location_description?: string;
|
|
1368
|
+
opening_hours?: string;
|
|
1369
|
+
payment_point_descr?: string;
|
|
1370
|
+
functions?: string[];
|
|
1371
|
+
[key: string]: unknown;
|
|
1372
|
+
}
|
|
1373
|
+
type InPostLanguage = 'pl' | 'en' | 'uk' | 'de' | 'it' | 'fr';
|
|
1374
|
+
type InPostConfigType = 'parcelCollect' | 'parcelCollectPayment' | 'international' | 'postBuy' | string;
|
|
1375
|
+
interface UseInPostScriptOptions {
|
|
1376
|
+
sandbox?: boolean;
|
|
1377
|
+
customScriptUrl?: string;
|
|
1378
|
+
customCssUrl?: string;
|
|
1379
|
+
}
|
|
1380
|
+
interface UseInPostScriptResult {
|
|
1381
|
+
isLoaded: boolean;
|
|
1382
|
+
error: Error | null;
|
|
1383
|
+
}
|
|
1384
|
+
|
|
1385
|
+
declare function useInPostScript(options?: UseInPostScriptOptions): UseInPostScriptResult;
|
|
1386
|
+
|
|
1387
|
+
export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, type AccordionProps, AccordionTrigger, Alert, type AlertProps, AppShell, AppShellBanner, type AppShellBannerProps, AppShellFooter, type AppShellFooterProps, AppShellHeader, type AppShellHeaderProps, AppShellMain, type AppShellMainProps, type AppShellProps, Avatar, AvatarGroup, type AvatarProps, Badge, type BadgeProps, BlogCard, type BlogCardAuthor, type BlogCardProps, BottomNavigation, type BottomNavigationItem, type BottomNavigationProps, BottomSheet, BottomSheetContent, BottomSheetDescription, BottomSheetFooter, BottomSheetHeader, type BottomSheetProps, BottomSheetTitle, Breadcrumb, BreadcrumbItem, type BreadcrumbItemProps, BreadcrumbSeparator, Button, type ButtonProps, Calendar, type CalendarProps, Card, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardTitle, Checkbox, CheckboxField, type CheckboxFieldProps, type CheckboxProps, CodeBlock, type CodeBlockProps, ColorPicker, ColorPickerField, type ColorPickerFieldProps, type ColorPickerProps, ColorPickerSwatch, type ColorPickerSwatchProps, Combobox, ComboboxField, type ComboboxFieldProps, type ComboboxOption, type ComboboxProps, CommandPalette, type CommandPaletteItem, type CommandPaletteProps, ConfirmDialog, type ConfirmDialogProps, DEFAULT_COLOR_SWATCHES, DashboardShell, type DashboardShellProps, DataTable, type DataTableColumn, type DataTableProps, DatePicker, DatePickerField, type DatePickerFieldProps, type DatePickerProps, type DateRange, DateRangePicker, DateRangePickerField, type DateRangePickerFieldProps, type DateRangePickerProps, DetailPageLayout, type DetailPageLayoutProps, Drawer, type DrawerProps, DropdownMenu, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuItem, type DropdownMenuItemProps, DropdownMenuSeparator, DropdownMenuTrigger, Dropzone, type DropzoneProps, EmptyState, type EmptyStateProps, ErrorState, type ErrorStateProps, Fab, type FabProps, Field, type FileRejection, FileUpload, FileUploadField, type FileUploadFieldProps, type FileUploadProps, FormField, type FormFieldProps, type GalleryImage, Hint, type HintProps, ImageGallery, type ImageGalleryProps, InPostGeowidget, InPostGeowidgetModal, type InPostGeowidgetModalProps, type InPostGeowidgetProps, type InPostPoint, InboxContent, type InboxContentProps, InboxPopover, type InboxPopoverProps, type InboxStateReturn, InboxTrigger, type InboxTriggerProps, Input, type InputProps, Kbd, type KbdProps, Label, type LabelProps, MetricCard, type MetricCardProps, Modal, ModalActions, ModalDescription, type ModalProps, ModalTitle, NotificationItem, type NotificationItemData, type NotificationItemProps, PageHeader, type PageHeaderProps, Pagination, type PaginationProps, Popover, PopoverContent, type PopoverContentProps, type PopoverProps, PopoverTrigger, PricingCard, type PricingCardProps, type PricingFeatureItem, Progress, type ProgressProps, ProgressRing, ProgressRingField, type ProgressRingFieldProps, type ProgressRingProps, type ProgressRingSize, type ProgressRingTone, ProjectCard, type ProjectCardMetric, type ProjectCardProps, type ProjectCardStatus, Radio, type RadioProps, RangeCalendar, type RangeCalendarProps, Rating, type RatingDistributionItem, RatingField, type RatingFieldProps, type RatingIconType, type RatingProps, type RatingSize, RatingSummary, type RatingSummaryProps, SectionHeader, type SectionHeaderActionsProps, type SectionHeaderAlign, type SectionHeaderDescriptionProps, type SectionHeaderHeadingLevel, type SectionHeaderKickerProps, type SectionHeaderProps, type SectionHeaderTitleProps, Segmented, type SegmentedOption, type SegmentedProps, Select, SelectField, type SelectFieldProps, type SelectProps, Separator, type SeparatorProps, SettingsLayout, type SettingsLayoutProps, SidebarNav, type SidebarNavGroup, type SidebarNavItem, type SidebarNavProps, Skeleton, type SkeletonProps, Slider, type SliderProps, Spinner, type SpinnerProps, Stat, type StatProps, Stepper, StepperContent, type StepperContentProps, StepperDescription, type StepperDescriptionProps, StepperIndicator, type StepperIndicatorProps, StepperItem, type StepperItemProps, StepperList, type StepperListProps, type StepperOrientation, type StepperProps, StepperSeparator, type StepperSeparatorProps, StepperTitle, type StepperTitleProps, StepperTrigger, type StepperTriggerProps, Switch, type SwitchProps, Table, TableBody, TableCell, type TableCellProps, TableHead, TableHeader, TableRow, TableToolbar, type TableToolbarProps, TableWrap, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsProps, TabsTrigger, type TabsTriggerProps, TextField, type TextFieldProps, Textarea, type TextareaProps, Timeline, type TimelineAlign, TimelineConnector, type TimelineConnectorProps, TimelineContent, type TimelineContentProps, TimelineDot, type TimelineDotProps, type TimelineDotSize, type TimelineDotVariant, TimelineItem, type TimelineItemProps, type TimelineProps, TimelineSeparator, type TimelineSeparatorProps, TimelineTime, TimelineTitle, type ToastOptions, ToastProvider, type ToastTone, ToggleGroup, type ToggleGroupOption, type ToggleGroupProps, Tooltip, type TooltipProps, type UploadItem, type UploadStatus, type UseStepperOptions, type UseStepperReturn, badgeVariants, buttonVariants, cn, formatRelativeTime, hexToHsl, hslToHex, isValidHex, normalizeHex, sliderThumbCSS, useInPostScript, useInboxState, useStepper, useToast };
|