@tailor-platform/app-shell 1.7.0 → 1.9.0
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/dist/app-shell-core.css +1 -1
- package/dist/app-shell.d.ts +787 -9
- package/dist/app-shell.js +5913 -3812
- package/package.json +4 -2
- package/skills/app-shell-patterns/SKILL.md +32 -20
- package/skills/app-shell-patterns/references/fundamental/components.md +125 -25
- package/skills/app-shell-patterns/references/fundamental/design-system.md +24 -0
- package/skills/app-shell-patterns/references/fundamental/graphql.md +1 -1
- package/skills/app-shell-patterns/references/patterns/detail-hero-with-actions.md +51 -7
- package/skills/app-shell-patterns/references/patterns/list-dense-scan.md +49 -14
package/dist/app-shell.d.ts
CHANGED
|
@@ -2,9 +2,12 @@ import { AuthClient } from '@tailor-platform/auth-public-client';
|
|
|
2
2
|
import { Autocomplete as Autocomplete_2 } from '@base-ui/react/autocomplete';
|
|
3
3
|
import { AutocompleteRootProps } from '@base-ui/react/autocomplete';
|
|
4
4
|
import { Avatar as Avatar_2 } from '@base-ui/react/avatar';
|
|
5
|
+
import { CalendarDate } from '@internationalized/date';
|
|
6
|
+
import { CalendarDateTime } from '@internationalized/date';
|
|
5
7
|
import { ClassProp } from 'class-variance-authority/types';
|
|
6
8
|
import { Combobox as Combobox_2 } from '@base-ui/react/combobox';
|
|
7
9
|
import { CSSProperties } from 'react';
|
|
10
|
+
import { DateValue } from '@internationalized/date';
|
|
8
11
|
import { Dialog as Dialog_2 } from '@base-ui/react/dialog';
|
|
9
12
|
import { Drawer } from '@base-ui/react/drawer';
|
|
10
13
|
import { FC } from 'react';
|
|
@@ -12,15 +15,22 @@ import { Field as Field_2 } from '@base-ui/react/field';
|
|
|
12
15
|
import { Fieldset as Fieldset_2 } from '@base-ui/react/fieldset';
|
|
13
16
|
import { Form as Form_2 } from '@base-ui/react/form';
|
|
14
17
|
import { getFilter } from '@base-ui/react/internals/filter';
|
|
18
|
+
import { getLocalTimeZone } from '@internationalized/date';
|
|
15
19
|
import { JSX } from 'react/jsx-runtime';
|
|
16
20
|
import { Link } from 'react-router';
|
|
17
21
|
import { LoaderFunctionArgs } from 'react-router';
|
|
18
22
|
import { Menu as Menu_2 } from '@base-ui/react/menu';
|
|
23
|
+
import { parseAbsolute } from '@internationalized/date';
|
|
24
|
+
import { parseDate } from '@internationalized/date';
|
|
25
|
+
import { parseDateTime } from '@internationalized/date';
|
|
26
|
+
import { parseZonedDateTime } from '@internationalized/date';
|
|
19
27
|
import * as React_2 from 'react';
|
|
20
28
|
import { ReactNode } from 'react';
|
|
29
|
+
import { RefObject } from 'react';
|
|
21
30
|
import { Select as Select_2 } from '@base-ui/react/select';
|
|
22
31
|
import { StandardSchemaV1 } from '@standard-schema/spec';
|
|
23
32
|
import { Tabs as Tabs_2 } from '@base-ui/react/tabs';
|
|
33
|
+
import { Time } from '@internationalized/date';
|
|
24
34
|
import { toast } from 'sonner';
|
|
25
35
|
import { Tooltip as Tooltip_2 } from '@base-ui/react/tooltip';
|
|
26
36
|
import { useLocation } from 'react-router';
|
|
@@ -29,6 +39,7 @@ import { useParams } from 'react-router';
|
|
|
29
39
|
import { useRouteError } from 'react-router';
|
|
30
40
|
import { useSearchParams } from 'react-router';
|
|
31
41
|
import { VariantProps } from 'class-variance-authority';
|
|
42
|
+
import { ZonedDateTime } from '@internationalized/date';
|
|
32
43
|
|
|
33
44
|
/**
|
|
34
45
|
* A single action row in the ActionPanel (icon + label, triggered by onClick).
|
|
@@ -215,7 +226,6 @@ export declare type AIGatewayChatMessage = {
|
|
|
215
226
|
export declare interface AIGatewayChatRequest {
|
|
216
227
|
model: string;
|
|
217
228
|
messages: AIGatewayChatMessage[];
|
|
218
|
-
stream?: boolean;
|
|
219
229
|
signal?: AbortSignal;
|
|
220
230
|
}
|
|
221
231
|
|
|
@@ -238,6 +248,8 @@ export declare const alertVariants: (props?: ({
|
|
|
238
248
|
variant?: "error" | "neutral" | "success" | "warning" | "info" | null | undefined;
|
|
239
249
|
} & ClassProp) | undefined) => string;
|
|
240
250
|
|
|
251
|
+
declare type Anchor = "start" | "center" | "end";
|
|
252
|
+
|
|
241
253
|
/**
|
|
242
254
|
* Appearance menu. The end-user controls **color theme** (light / dark / system);
|
|
243
255
|
* the color palette/brand is a developer configuration, so it is not shown here.
|
|
@@ -786,7 +798,7 @@ export declare const Avatar: {
|
|
|
786
798
|
export declare type AvatarProps = React_2.ComponentProps<typeof Avatar_2.Root> & VariantProps<typeof avatarVariants>;
|
|
787
799
|
|
|
788
800
|
export declare const avatarVariants: (props?: ({
|
|
789
|
-
size?: "default" | "sm" | "lg" | null | undefined;
|
|
801
|
+
size?: "default" | "xs" | "sm" | "lg" | null | undefined;
|
|
790
802
|
} & ClassProp) | undefined) => string;
|
|
791
803
|
|
|
792
804
|
export declare function Badge({ className, variant, children, ...props }: BadgeProps): JSX.Element;
|
|
@@ -876,6 +888,49 @@ export declare const buttonVariants: (props?: ({
|
|
|
876
888
|
size?: "default" | "xs" | "sm" | "lg" | "icon" | null | undefined;
|
|
877
889
|
} & ClassProp) | undefined) => string;
|
|
878
890
|
|
|
891
|
+
/**
|
|
892
|
+
* A standalone inline calendar — no popover, suitable for reporting filters
|
|
893
|
+
* or date selection within a larger layout.
|
|
894
|
+
*
|
|
895
|
+
* @example
|
|
896
|
+
* ```tsx
|
|
897
|
+
* import { Calendar } from "@tailor-platform/app-shell";
|
|
898
|
+
*
|
|
899
|
+
* <Calendar aria-label="Select date" value={value} onChange={setValue} />
|
|
900
|
+
* ```
|
|
901
|
+
*/
|
|
902
|
+
export declare function Calendar<T extends DateValue = DateValue>({ value, defaultValue, onChange, minValue, maxValue, isDateUnavailable, isDisabled, isReadOnly, focusedValue, defaultFocusedValue, onFocusChange, firstDayOfWeek, timeZone: timeZoneProp, locale: localeProp, className, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, }: CalendarProps<T>): JSX.Element;
|
|
903
|
+
|
|
904
|
+
export { CalendarDate }
|
|
905
|
+
|
|
906
|
+
export { CalendarDateTime }
|
|
907
|
+
|
|
908
|
+
/**
|
|
909
|
+
* Public, closed-API standalone calendar — the @internationalized/date + Base UI
|
|
910
|
+
* implementation. Same surface as the react-aria variant; only the internals
|
|
911
|
+
* differ. Consumers never see Base UI or the calendar engine.
|
|
912
|
+
*/
|
|
913
|
+
export declare interface CalendarProps<T extends DateValue = DateValue> {
|
|
914
|
+
value?: T | null;
|
|
915
|
+
defaultValue?: T | null;
|
|
916
|
+
onChange?: (value: T) => void;
|
|
917
|
+
minValue?: DateValue;
|
|
918
|
+
maxValue?: DateValue;
|
|
919
|
+
isDateUnavailable?: (date: DateValue) => boolean;
|
|
920
|
+
isDisabled?: boolean;
|
|
921
|
+
isReadOnly?: boolean;
|
|
922
|
+
focusedValue?: DateValue;
|
|
923
|
+
defaultFocusedValue?: DateValue;
|
|
924
|
+
onFocusChange?: (date: CalendarDate) => void;
|
|
925
|
+
firstDayOfWeek?: FirstDayOfWeek;
|
|
926
|
+
"aria-label"?: string;
|
|
927
|
+
"aria-labelledby"?: string;
|
|
928
|
+
timeZone?: string;
|
|
929
|
+
className?: string;
|
|
930
|
+
/** BCP-47 locale override; defaults to the AppShell formatting locale. */
|
|
931
|
+
locale?: string;
|
|
932
|
+
}
|
|
933
|
+
|
|
879
934
|
/**
|
|
880
935
|
* Internal type for tracking OAuth callback handling status.
|
|
881
936
|
*/
|
|
@@ -1636,8 +1691,9 @@ declare namespace Content_4 {
|
|
|
1636
1691
|
}
|
|
1637
1692
|
|
|
1638
1693
|
/** The tooltip popup that displays additional information. */
|
|
1639
|
-
declare function Content_5({ className, position, side: _side, align: _align, sideOffset: _sideOffset, children, ...restProps }: React_2.ComponentProps<typeof Tooltip_2.Popup> & {
|
|
1694
|
+
declare function Content_5({ className, position, side: _side, align: _align, sideOffset: _sideOffset, noArrow, children, ...restProps }: React_2.ComponentProps<typeof Tooltip_2.Popup> & {
|
|
1640
1695
|
position?: PositionProps;
|
|
1696
|
+
noArrow?: boolean;
|
|
1641
1697
|
/** @deprecated Use `position={{ side }}` instead. */
|
|
1642
1698
|
side?: PositionProps["side"];
|
|
1643
1699
|
/** @deprecated Use `position={{ align }}` instead. */
|
|
@@ -2091,6 +2147,34 @@ declare namespace DataTableToolbar {
|
|
|
2091
2147
|
var displayName: string;
|
|
2092
2148
|
}
|
|
2093
2149
|
|
|
2150
|
+
declare interface DateBehaviorProps<T extends DateValue> {
|
|
2151
|
+
value?: T | null;
|
|
2152
|
+
defaultValue?: T | null;
|
|
2153
|
+
onChange?: (value: T | null) => void;
|
|
2154
|
+
granularity?: Granularity;
|
|
2155
|
+
minValue?: DateValue;
|
|
2156
|
+
maxValue?: DateValue;
|
|
2157
|
+
isDateUnavailable?: (date: DateValue) => boolean;
|
|
2158
|
+
isDisabled?: boolean;
|
|
2159
|
+
isReadOnly?: boolean;
|
|
2160
|
+
isRequired?: boolean;
|
|
2161
|
+
isInvalid?: boolean;
|
|
2162
|
+
autoFocus?: boolean;
|
|
2163
|
+
hourCycle?: HourCycle;
|
|
2164
|
+
hideTimeZone?: boolean;
|
|
2165
|
+
placeholderValue?: DateValue;
|
|
2166
|
+
/**
|
|
2167
|
+
* First day of the week (0 = Sunday … 6 = Saturday); defaults to the locale.
|
|
2168
|
+
* Only affects the `w`/`k` (start/end of week) keyboard shortcuts here.
|
|
2169
|
+
*/
|
|
2170
|
+
firstDayOfWeek?: FirstDayOfWeek;
|
|
2171
|
+
name?: string;
|
|
2172
|
+
/** Accessible name when no visible `label` is provided (e.g. a compact filter input). */
|
|
2173
|
+
"aria-label"?: string;
|
|
2174
|
+
/** BCP-47 locale override; defaults to the AppShell formatting locale. */
|
|
2175
|
+
locale?: string;
|
|
2176
|
+
}
|
|
2177
|
+
|
|
2094
2178
|
/** Options for `type: "date"` cells. */
|
|
2095
2179
|
declare interface DateCellOptions {
|
|
2096
2180
|
/**
|
|
@@ -2102,11 +2186,106 @@ declare interface DateCellOptions {
|
|
|
2102
2186
|
locale?: string;
|
|
2103
2187
|
}
|
|
2104
2188
|
|
|
2189
|
+
/**
|
|
2190
|
+
* A segmented date/time input field with no popover.
|
|
2191
|
+
*
|
|
2192
|
+
* @example
|
|
2193
|
+
* ```tsx
|
|
2194
|
+
* import { DateField } from "@tailor-platform/app-shell";
|
|
2195
|
+
*
|
|
2196
|
+
* <DateField label="Invoice date" />
|
|
2197
|
+
* <DateField label="Created at" granularity="minute" />
|
|
2198
|
+
* ```
|
|
2199
|
+
*/
|
|
2200
|
+
export declare function DateField<T extends DateValue = DateValue>({ label, description, errorMessage, className, locale: localeProp, value, defaultValue, onChange, granularity, hourCycle, placeholderValue, minValue, maxValue, isDateUnavailable, isDisabled, isReadOnly, isInvalid, isRequired, autoFocus, firstDayOfWeek, name, "aria-label": ariaLabel, }: DateFieldProps<T>): JSX.Element;
|
|
2201
|
+
|
|
2202
|
+
declare interface DateFieldMetaProps {
|
|
2203
|
+
label?: LocalizedString;
|
|
2204
|
+
description?: LocalizedString;
|
|
2205
|
+
errorMessage?: LocalizedString;
|
|
2206
|
+
className?: string;
|
|
2207
|
+
}
|
|
2208
|
+
|
|
2209
|
+
export declare type DateFieldProps<T extends DateValue = DateValue> = DateFieldMetaProps & DateBehaviorProps<T>;
|
|
2210
|
+
|
|
2105
2211
|
/**
|
|
2106
2212
|
* Date format options
|
|
2107
2213
|
*/
|
|
2108
2214
|
declare type DateFormat = "short" | "medium" | "long" | "relative";
|
|
2109
2215
|
|
|
2216
|
+
/**
|
|
2217
|
+
* A date/time input with a popover calendar.
|
|
2218
|
+
*
|
|
2219
|
+
* Value type is driven by `granularity`:
|
|
2220
|
+
* - `"day"` (default) → `CalendarDate`
|
|
2221
|
+
* - `"hour" | "minute" | "second"` → `CalendarDateTime` (or `ZonedDateTime` when a `timeZone` is set)
|
|
2222
|
+
*
|
|
2223
|
+
* @example
|
|
2224
|
+
* ```tsx
|
|
2225
|
+
* import { DatePicker, today, getLocalTimeZone, type CalendarDate } from "@tailor-platform/app-shell";
|
|
2226
|
+
*
|
|
2227
|
+
* const [date, setDate] = useState<CalendarDate | null>(null);
|
|
2228
|
+
* <DatePicker label="Ship date" value={date} onChange={setDate} />
|
|
2229
|
+
* ```
|
|
2230
|
+
*/
|
|
2231
|
+
export declare function DatePicker<T extends DateValue = DateValue>({ label, description, errorMessage, className, locale: localeProp, timeZone: timeZoneProp, value, defaultValue, onChange, granularity, hourCycle, placeholderValue, minValue, maxValue, isDateUnavailable, isDisabled, isReadOnly, isInvalid, isRequired, autoFocus, firstDayOfWeek, name, "aria-label": ariaLabel, }: DatePickerProps<T>): JSX.Element;
|
|
2232
|
+
|
|
2233
|
+
export declare type DatePickerProps<T extends DateValue = DateValue> = DateFieldProps<T> & {
|
|
2234
|
+
/** IANA timezone; defaults to the AppShell `timeZone`. */
|
|
2235
|
+
timeZone?: string;
|
|
2236
|
+
};
|
|
2237
|
+
|
|
2238
|
+
export { DateValue }
|
|
2239
|
+
|
|
2240
|
+
/**
|
|
2241
|
+
* DefaultHeader — the built-in `SidebarLayout` top bar.
|
|
2242
|
+
*
|
|
2243
|
+
* Renders the sidebar trigger and breadcrumb trail on the left, and the
|
|
2244
|
+
* `actions` cluster (defaulting to the appearance switcher) on the right.
|
|
2245
|
+
*
|
|
2246
|
+
* Use it via the `SidebarLayout.DefaultHeader` namespace to slightly extend the
|
|
2247
|
+
* built-in header without reconstructing it:
|
|
2248
|
+
*
|
|
2249
|
+
* @example
|
|
2250
|
+
* ```tsx
|
|
2251
|
+
* <SidebarLayout
|
|
2252
|
+
* header={
|
|
2253
|
+
* <SidebarLayout.DefaultHeader
|
|
2254
|
+
* actions={[<NotificationBell key="bell" />, <AppearanceSwitcher key="appearance" />]}
|
|
2255
|
+
* />
|
|
2256
|
+
* }
|
|
2257
|
+
* />
|
|
2258
|
+
* ```
|
|
2259
|
+
*/
|
|
2260
|
+
export declare const DefaultHeader: {
|
|
2261
|
+
({ actions }: DefaultHeaderProps): JSX.Element;
|
|
2262
|
+
displayName: string;
|
|
2263
|
+
};
|
|
2264
|
+
|
|
2265
|
+
export declare type DefaultHeaderProps = {
|
|
2266
|
+
/**
|
|
2267
|
+
* The right-hand cluster of the header. Rendered in a horizontal,
|
|
2268
|
+
* vertically-centered row with consistent spacing — you don't wrap it
|
|
2269
|
+
* yourself. Accepts a single node or an array of nodes.
|
|
2270
|
+
*
|
|
2271
|
+
* **`actions` replaces the entire right-hand cluster, including the
|
|
2272
|
+
* appearance switcher.** When omitted, it defaults to just the
|
|
2273
|
+
* `<AppearanceSwitcher />`. If you pass your own actions and still want the
|
|
2274
|
+
* switcher, include `<AppearanceSwitcher />` in the array (it is a public
|
|
2275
|
+
* export). Passing `actions={[]}` renders an empty right side.
|
|
2276
|
+
*
|
|
2277
|
+
* @default [<AppearanceSwitcher />]
|
|
2278
|
+
* @example
|
|
2279
|
+
* ```tsx
|
|
2280
|
+
* // Add a notification bell, keeping the appearance switcher:
|
|
2281
|
+
* <SidebarLayout.DefaultHeader
|
|
2282
|
+
* actions={[<NotificationBell key="bell" />, <AppearanceSwitcher key="appearance" />]}
|
|
2283
|
+
* />
|
|
2284
|
+
* ```
|
|
2285
|
+
*/
|
|
2286
|
+
actions?: React.ReactNode | React.ReactNode[];
|
|
2287
|
+
};
|
|
2288
|
+
|
|
2110
2289
|
/**
|
|
2111
2290
|
* Default sidebar component with auto-generated navigation items.
|
|
2112
2291
|
*
|
|
@@ -2914,6 +3093,13 @@ declare type FilterInputForFieldType<TFilterConfigType extends FilterConfig["typ
|
|
|
2914
3093
|
*/
|
|
2915
3094
|
export declare type FilterOperator = OperatorForFilterType[FilterConfig["type"]];
|
|
2916
3095
|
|
|
3096
|
+
/**
|
|
3097
|
+
* Week-start override for the `weekStart`/`weekEnd` shortcuts (and the calendar
|
|
3098
|
+
* grid). Defined here — with the resolver that consumes it — so the field and
|
|
3099
|
+
* calendar engines share one source of truth.
|
|
3100
|
+
*/
|
|
3101
|
+
declare type FirstDayOfWeek = "sun" | "mon" | "tue" | "wed" | "thu" | "fri" | "sat";
|
|
3102
|
+
|
|
2917
3103
|
/** The table footer section (`<tfoot>`). */
|
|
2918
3104
|
declare function Footer({ className, ...props }: React_2.ComponentProps<"tfoot">): JSX.Element;
|
|
2919
3105
|
|
|
@@ -3025,6 +3211,20 @@ export declare type FormProps<FormValues extends Record<string, any> = Record<st
|
|
|
3025
3211
|
|
|
3026
3212
|
declare type FormSubmitEventDetails = NonNullable<React_2.ComponentProps<typeof Form_2>["onFormSubmit"]> extends (values: any, details: infer D) => any ? D : never;
|
|
3027
3213
|
|
|
3214
|
+
export { getLocalTimeZone }
|
|
3215
|
+
|
|
3216
|
+
/**
|
|
3217
|
+
* Hand-rolled segmented-date-field state.
|
|
3218
|
+
*
|
|
3219
|
+
* This is the logic react-aria's `useDateFieldState` would otherwise provide.
|
|
3220
|
+
* We own it here: locale-driven segment ordering (via `DateFormatter`), per-
|
|
3221
|
+
* segment spinbutton semantics (increment/decrement with context-aware limits),
|
|
3222
|
+
* numeric type-to-fill with auto-advance, and value-type discrimination by
|
|
3223
|
+
* `granularity`. No `Date` ever escapes — `onChange` emits `@internationalized/date`
|
|
3224
|
+
* values (or `null`).
|
|
3225
|
+
*/
|
|
3226
|
+
declare type Granularity = "day" | "hour" | "minute" | "second";
|
|
3227
|
+
|
|
3028
3228
|
export declare const Grid: React_2.ForwardRefExoticComponent<Omit<GridProps, "ref"> & React_2.RefAttributes<HTMLDivElement>> & {
|
|
3029
3229
|
Item: React_2.ForwardRefExoticComponent<Omit<GridItemProps, "ref"> & React_2.RefAttributes<HTMLDivElement>>;
|
|
3030
3230
|
};
|
|
@@ -3237,6 +3437,8 @@ declare type HeadProps = React_2.ComponentProps<"th"> & {
|
|
|
3237
3437
|
*/
|
|
3238
3438
|
export declare const hidden: () => GuardResult;
|
|
3239
3439
|
|
|
3440
|
+
declare type HourCycle = 12 | 24;
|
|
3441
|
+
|
|
3240
3442
|
export declare type I18nLabels<Def extends Record<string, LabelValue> = Record<string, LabelValue>, L extends string = never> = {
|
|
3241
3443
|
en: Def;
|
|
3242
3444
|
} & {
|
|
@@ -3286,6 +3488,15 @@ export declare function Input({ className, type, ...props }: InputProps): JSX.El
|
|
|
3286
3488
|
|
|
3287
3489
|
export declare type InputProps = React_2.ComponentProps<"input">;
|
|
3288
3490
|
|
|
3491
|
+
/**
|
|
3492
|
+
* Positions content across a time range inside a row.
|
|
3493
|
+
*/
|
|
3494
|
+
declare function Interval({ start, end, children, id, insetY, className, style, }: TimelineIntervalProps): JSX.Element;
|
|
3495
|
+
|
|
3496
|
+
declare namespace Interval {
|
|
3497
|
+
var displayName: string;
|
|
3498
|
+
}
|
|
3499
|
+
|
|
3289
3500
|
/**
|
|
3290
3501
|
* Check if an object type has no keys.
|
|
3291
3502
|
*/
|
|
@@ -3388,7 +3599,7 @@ declare type LabelValue = string | ((props: any) => string);
|
|
|
3388
3599
|
* </Layout>
|
|
3389
3600
|
* ```
|
|
3390
3601
|
*/
|
|
3391
|
-
export declare function Layout({ columns, className, style, gap, title, actions, children }: LayoutProps): JSX.Element;
|
|
3602
|
+
export declare function Layout({ columns, className, style, gap, title, actions, fill, children, }: LayoutProps): JSX.Element;
|
|
3392
3603
|
|
|
3393
3604
|
export declare namespace Layout {
|
|
3394
3605
|
var Column: React_2.ForwardRefExoticComponent<ColumnProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
@@ -3439,6 +3650,24 @@ export declare interface LayoutProps {
|
|
|
3439
3650
|
* @deprecated Use `<Layout.Header actions={...}>` instead.
|
|
3440
3651
|
*/
|
|
3441
3652
|
actions?: ReactNode[];
|
|
3653
|
+
/**
|
|
3654
|
+
* Fill the available height instead of growing with content.
|
|
3655
|
+
*
|
|
3656
|
+
* When set, the layout stretches to the height of its container
|
|
3657
|
+
* (`flex-1 min-h-0`) and bounds its column row (`minmax(0, 1fr)`), so
|
|
3658
|
+
* children such as `DataTable` can scroll internally while the
|
|
3659
|
+
* `Layout.Header` stays pinned. Without it, the layout grows naturally
|
|
3660
|
+
* and the surrounding content area scrolls.
|
|
3661
|
+
*
|
|
3662
|
+
* Intended for single-row (one `Layout.Column` per breakpoint row) pages;
|
|
3663
|
+
* on stacked mobile layouts with multiple columns the content area
|
|
3664
|
+
* scrolls as usual.
|
|
3665
|
+
*
|
|
3666
|
+
* A `fill` layout also renders a `data-layout-fill` attribute on its root,
|
|
3667
|
+
* which the AppShell content area targets via `:has([data-layout-fill])` to
|
|
3668
|
+
* disable its own scrolling (the fill layout bounds everything internally).
|
|
3669
|
+
*/
|
|
3670
|
+
fill?: boolean;
|
|
3442
3671
|
/** Child elements - Layout.Header and/or Layout.Column components */
|
|
3443
3672
|
children: ReactNode;
|
|
3444
3673
|
}
|
|
@@ -3452,6 +3681,17 @@ declare namespace Legend {
|
|
|
3452
3681
|
|
|
3453
3682
|
export { Link }
|
|
3454
3683
|
|
|
3684
|
+
/**
|
|
3685
|
+
* Draws an orthogonal connector between two row items.
|
|
3686
|
+
*
|
|
3687
|
+
* If either referenced `Timeline.Interval` id is unresolved, nothing is rendered.
|
|
3688
|
+
*/
|
|
3689
|
+
declare function Link_2({ from, to, fromAnchor, toAnchor, arrow, gap, className, style, strokeWidth, }: TimelineLinkProps): React_2.ReactPortal | null;
|
|
3690
|
+
|
|
3691
|
+
declare namespace Link_2 {
|
|
3692
|
+
var displayName: string;
|
|
3693
|
+
}
|
|
3694
|
+
|
|
3455
3695
|
/** Options for `type: "link"` cells. `href` is required. */
|
|
3456
3696
|
declare interface LinkCellOptions<TRow extends Record<string, unknown>> {
|
|
3457
3697
|
/**
|
|
@@ -3643,6 +3883,11 @@ declare interface NumberCellOptions {
|
|
|
3643
3883
|
locale?: string;
|
|
3644
3884
|
}
|
|
3645
3885
|
|
|
3886
|
+
export declare type OpenCommandPaletteOptions = {
|
|
3887
|
+
/** Optional initial text to prefill into the palette input. */
|
|
3888
|
+
search?: string;
|
|
3889
|
+
};
|
|
3890
|
+
|
|
3646
3891
|
/**
|
|
3647
3892
|
* Resolve the operator union for a specific field within a filter type.
|
|
3648
3893
|
*/
|
|
@@ -3740,6 +3985,12 @@ declare namespace Panel {
|
|
|
3740
3985
|
var displayName: string;
|
|
3741
3986
|
}
|
|
3742
3987
|
|
|
3988
|
+
export { parseAbsolute }
|
|
3989
|
+
|
|
3990
|
+
export { parseDate }
|
|
3991
|
+
|
|
3992
|
+
export { parseDateTime }
|
|
3993
|
+
|
|
3743
3994
|
/** The row data passed to `onValidate`, after transforms have been applied. */
|
|
3744
3995
|
export declare type ParsedRow = {
|
|
3745
3996
|
/** 0-based row index, stable across edits. */
|
|
@@ -3748,6 +3999,8 @@ export declare type ParsedRow = {
|
|
|
3748
3999
|
data: Record<string, unknown>;
|
|
3749
4000
|
};
|
|
3750
4001
|
|
|
4002
|
+
export { parseZonedDateTime }
|
|
4003
|
+
|
|
3751
4004
|
/**
|
|
3752
4005
|
* Allow access to the route. Continue to next guard or render component.
|
|
3753
4006
|
*
|
|
@@ -3916,7 +4169,7 @@ declare namespace Root_10 {
|
|
|
3916
4169
|
* </Tabs.Root>
|
|
3917
4170
|
* ```
|
|
3918
4171
|
*/
|
|
3919
|
-
declare function Root_11({ className, children, variant, ...props }: RootProps_3): JSX.Element;
|
|
4172
|
+
declare function Root_11({ className, children, variant, size, ...props }: RootProps_3): JSX.Element;
|
|
3920
4173
|
|
|
3921
4174
|
declare namespace Root_11 {
|
|
3922
4175
|
var displayName: string;
|
|
@@ -3941,6 +4194,26 @@ declare namespace Root_12 {
|
|
|
3941
4194
|
var displayName: string;
|
|
3942
4195
|
}
|
|
3943
4196
|
|
|
4197
|
+
/**
|
|
4198
|
+
* Provides the shared time range used by all timeline primitives.
|
|
4199
|
+
*
|
|
4200
|
+
* Example:
|
|
4201
|
+
* ```tsx
|
|
4202
|
+
* <Timeline.Root start={projectStart} end={projectEnd}>
|
|
4203
|
+
* <Timeline.Viewport axis={axis}>
|
|
4204
|
+
* <Timeline.Row height={40}>
|
|
4205
|
+
* <Timeline.Interval start={task.start} end={task.end}>…</Timeline.Interval>
|
|
4206
|
+
* </Timeline.Row>
|
|
4207
|
+
* </Timeline.Viewport>
|
|
4208
|
+
* </Timeline.Root>
|
|
4209
|
+
* ```
|
|
4210
|
+
*/
|
|
4211
|
+
declare function Root_13({ start, end, children, className, style }: TimelineRootProps): JSX.Element;
|
|
4212
|
+
|
|
4213
|
+
declare namespace Root_13 {
|
|
4214
|
+
var displayName: string;
|
|
4215
|
+
}
|
|
4216
|
+
|
|
3944
4217
|
declare function Root_2<T extends ActivityCardBaseItem>({ items, title, maxVisible, overflowLabel, groupBy, className, children, }: ActivityCardRootProps<T>): JSX.Element;
|
|
3945
4218
|
|
|
3946
4219
|
declare namespace Root_2 {
|
|
@@ -4116,6 +4389,10 @@ declare type RootConfiguration = {
|
|
|
4116
4389
|
basePath?: string;
|
|
4117
4390
|
errorBoundary: ErrorBoundaryComponent;
|
|
4118
4391
|
locale: string;
|
|
4392
|
+
/** Full BCP-47 tag (e.g. "en-GB") for Intl / date formatting. Falls back to `locale`. */
|
|
4393
|
+
resolvedLocale?: string;
|
|
4394
|
+
/** IANA timezone (e.g. "America/Los_Angeles"). Used by date/time components. */
|
|
4395
|
+
timeZone?: string;
|
|
4119
4396
|
};
|
|
4120
4397
|
|
|
4121
4398
|
declare type RootProps = React_2.ComponentProps<"div"> & VariantProps<typeof alertVariants> & {
|
|
@@ -4133,6 +4410,12 @@ declare type RootProps_3 = Pick<React_2.ComponentProps<typeof Tabs_2.Root>, "def
|
|
|
4133
4410
|
children: React_2.ReactNode;
|
|
4134
4411
|
className?: string;
|
|
4135
4412
|
variant?: TabsVariant;
|
|
4413
|
+
/**
|
|
4414
|
+
* Minimum size of the tabs, mirroring Button's height tiers. Only affects the
|
|
4415
|
+
* `capsule` variant, keeping its track aligned with a sibling Button and its
|
|
4416
|
+
* icon-only tabs square.
|
|
4417
|
+
*/
|
|
4418
|
+
size?: TabsSize;
|
|
4136
4419
|
};
|
|
4137
4420
|
|
|
4138
4421
|
/**
|
|
@@ -4151,6 +4434,25 @@ declare namespace Row {
|
|
|
4151
4434
|
var displayName: string;
|
|
4152
4435
|
}
|
|
4153
4436
|
|
|
4437
|
+
/**
|
|
4438
|
+
* A single body row.
|
|
4439
|
+
*
|
|
4440
|
+
* Rows control vertical sizing and can optionally provide a background layer:
|
|
4441
|
+
* ```tsx
|
|
4442
|
+
* <Timeline.Row
|
|
4443
|
+
* height={40}
|
|
4444
|
+
* background={{ style: { background: "var(--muted)" } }}
|
|
4445
|
+
* >
|
|
4446
|
+
* <Timeline.Interval start={task.start} end={task.end}>…</Timeline.Interval>
|
|
4447
|
+
* </Timeline.Row>
|
|
4448
|
+
* ```
|
|
4449
|
+
*/
|
|
4450
|
+
declare function Row_2({ children, className, style, height, background }: TimelineRowProps): JSX.Element;
|
|
4451
|
+
|
|
4452
|
+
declare namespace Row_2 {
|
|
4453
|
+
var displayName: string;
|
|
4454
|
+
}
|
|
4455
|
+
|
|
4154
4456
|
/**
|
|
4155
4457
|
* A single row action definition for the actions column.
|
|
4156
4458
|
*/
|
|
@@ -4470,6 +4772,13 @@ declare type SharedAppShellProps = React.PropsWithChildren<{
|
|
|
4470
4772
|
* No browser locale information avilable, "en" used as default.
|
|
4471
4773
|
*/
|
|
4472
4774
|
locale?: string;
|
|
4775
|
+
/**
|
|
4776
|
+
* IANA timezone (e.g. "America/Los_Angeles") used by date/time components
|
|
4777
|
+
* as the default for resolving "today" and for `ZonedDateTime` values.
|
|
4778
|
+
*
|
|
4779
|
+
* If not provided, date/time components fall back to the user's local timezone.
|
|
4780
|
+
*/
|
|
4781
|
+
timeZone?: string;
|
|
4473
4782
|
/**
|
|
4474
4783
|
* Global error boundary component applied to all routes.
|
|
4475
4784
|
*
|
|
@@ -4728,7 +5037,15 @@ declare type SidebarItemRenderProps = {
|
|
|
4728
5037
|
isActive: boolean;
|
|
4729
5038
|
};
|
|
4730
5039
|
|
|
4731
|
-
export declare
|
|
5040
|
+
export declare function SidebarLayout(props: SidebarLayoutProps): JSX.Element;
|
|
5041
|
+
|
|
5042
|
+
export declare namespace SidebarLayout {
|
|
5043
|
+
var DefaultSidebar: (props: DefaultSidebarProps) => JSX.Element;
|
|
5044
|
+
var DefaultHeader: {
|
|
5045
|
+
({ actions }: DefaultHeaderProps): JSX.Element;
|
|
5046
|
+
displayName: string;
|
|
5047
|
+
};
|
|
5048
|
+
}
|
|
4732
5049
|
|
|
4733
5050
|
export declare type SidebarLayoutProps = {
|
|
4734
5051
|
/**
|
|
@@ -4751,15 +5068,39 @@ export declare type SidebarLayoutProps = {
|
|
|
4751
5068
|
Outlet: () => React.ReactNode;
|
|
4752
5069
|
}) => React.ReactNode;
|
|
4753
5070
|
/**
|
|
4754
|
-
* Custom sidebar content.
|
|
5071
|
+
* Custom sidebar content. Replaces the whole sidebar region.
|
|
4755
5072
|
*
|
|
4756
|
-
* @default DefaultSidebar
|
|
5073
|
+
* @default <SidebarLayout.DefaultSidebar />
|
|
4757
5074
|
* @example
|
|
4758
5075
|
* ```tsx
|
|
4759
5076
|
* <SidebarLayout sidebar={<MyCustomSidebar />} />
|
|
4760
5077
|
* ```
|
|
4761
5078
|
*/
|
|
4762
5079
|
sidebar?: React.ReactNode;
|
|
5080
|
+
/**
|
|
5081
|
+
* Custom header content. Replaces the whole top-bar region.
|
|
5082
|
+
*
|
|
5083
|
+
* Omit it for the built-in header. To slightly extend the built-in header
|
|
5084
|
+
* (e.g. add a notification bell), pass `<SidebarLayout.DefaultHeader />` with
|
|
5085
|
+
* its `actions` slot rather than reconstructing the header from scratch.
|
|
5086
|
+
*
|
|
5087
|
+
* @default <SidebarLayout.DefaultHeader />
|
|
5088
|
+
* @example
|
|
5089
|
+
* ```tsx
|
|
5090
|
+
* // Extend the built-in header:
|
|
5091
|
+
* <SidebarLayout
|
|
5092
|
+
* header={
|
|
5093
|
+
* <SidebarLayout.DefaultHeader
|
|
5094
|
+
* actions={[<NotificationBell key="bell" />, <AppearanceSwitcher key="appearance" />]}
|
|
5095
|
+
* />
|
|
5096
|
+
* }
|
|
5097
|
+
* />
|
|
5098
|
+
*
|
|
5099
|
+
* // Or replace it entirely:
|
|
5100
|
+
* <SidebarLayout header={<MyCustomHeader />} />
|
|
5101
|
+
* ```
|
|
5102
|
+
*/
|
|
5103
|
+
header?: React.ReactNode;
|
|
4763
5104
|
/**
|
|
4764
5105
|
* Whether the sidebar is open by default on desktop.
|
|
4765
5106
|
*
|
|
@@ -4914,8 +5255,362 @@ export declare const Tabs: {
|
|
|
4914
5255
|
Panel: typeof Panel;
|
|
4915
5256
|
};
|
|
4916
5257
|
|
|
5258
|
+
declare type TabsSize = "xs" | "sm" | "default" | "lg";
|
|
5259
|
+
|
|
4917
5260
|
declare type TabsVariant = "default" | "line" | "capsule";
|
|
4918
5261
|
|
|
5262
|
+
export { Time }
|
|
5263
|
+
|
|
5264
|
+
/**
|
|
5265
|
+
* Timeline primitives for building app-specific schedule, trace, and dependency UIs.
|
|
5266
|
+
*
|
|
5267
|
+
* Typical usage:
|
|
5268
|
+
* ```tsx
|
|
5269
|
+
* <Timeline.Root start={start} end={end}>
|
|
5270
|
+
* <Timeline.Viewport axis={axis} decorations={decorations}>
|
|
5271
|
+
* <Timeline.Row height={40} background={{ style: { background: "var(--muted)" } }}>
|
|
5272
|
+
* <Timeline.Interval id="task-1" start={task.start} end={task.end}>…</Timeline.Interval>
|
|
5273
|
+
* </Timeline.Row>
|
|
5274
|
+
* <Timeline.Link from="task-1" to="task-2" />
|
|
5275
|
+
* </Timeline.Viewport>
|
|
5276
|
+
* </Timeline.Root>
|
|
5277
|
+
* ```
|
|
5278
|
+
*/
|
|
5279
|
+
export declare const Timeline: {
|
|
5280
|
+
Root: typeof Root_13;
|
|
5281
|
+
Viewport: typeof Viewport;
|
|
5282
|
+
Row: typeof Row_2;
|
|
5283
|
+
Interval: typeof Interval;
|
|
5284
|
+
Link: typeof Link_2;
|
|
5285
|
+
};
|
|
5286
|
+
|
|
5287
|
+
/**
|
|
5288
|
+
* Axis configuration owned by `Timeline.Viewport`.
|
|
5289
|
+
*
|
|
5290
|
+
* Example:
|
|
5291
|
+
* ```tsx
|
|
5292
|
+
* axis={{
|
|
5293
|
+
* guides: boundaries.map((at) => ({
|
|
5294
|
+
* at,
|
|
5295
|
+
* axisStyle: { background: "var(--border)" },
|
|
5296
|
+
* bodyStyle: { background: "var(--border)" },
|
|
5297
|
+
* })),
|
|
5298
|
+
* levels: [
|
|
5299
|
+
* {
|
|
5300
|
+
* kind: "spans",
|
|
5301
|
+
* items: timeboxes,
|
|
5302
|
+
* },
|
|
5303
|
+
* ],
|
|
5304
|
+
* }}
|
|
5305
|
+
* ```
|
|
5306
|
+
*/
|
|
5307
|
+
export declare interface TimelineAxis {
|
|
5308
|
+
/** Boundary lines rendered in the axis and/or body. */
|
|
5309
|
+
guides?: TimelineGuide[];
|
|
5310
|
+
/** Stacked header levels rendered above the body. Defaults to `[]` when omitted. */
|
|
5311
|
+
levels?: TimelineAxisLevel[];
|
|
5312
|
+
/** Optional class applied to the axis container. */
|
|
5313
|
+
className?: string;
|
|
5314
|
+
}
|
|
5315
|
+
|
|
5316
|
+
/**
|
|
5317
|
+
* One stacked axis level.
|
|
5318
|
+
*
|
|
5319
|
+
* Levels let an app compose multi-level headers such as year → month or a
|
|
5320
|
+
* single timebox row such as half-hour slots.
|
|
5321
|
+
*/
|
|
5322
|
+
export declare type TimelineAxisLevel = (TimelineAxisLevelBase & {
|
|
5323
|
+
/** Interval labels rendered across a time range. */
|
|
5324
|
+
kind: "spans";
|
|
5325
|
+
/** Span items to render in this level. */
|
|
5326
|
+
items: TimelineAxisSpan[];
|
|
5327
|
+
/** Optional class applied to every span in the level. */
|
|
5328
|
+
itemClassName?: string;
|
|
5329
|
+
/** Optional style applied to every span in the level. */
|
|
5330
|
+
itemStyle?: React_2.CSSProperties;
|
|
5331
|
+
}) | (TimelineAxisLevelBase & {
|
|
5332
|
+
/** Point labels rendered at specific times. */
|
|
5333
|
+
kind: "ticks";
|
|
5334
|
+
/** Tick items to render in this level. */
|
|
5335
|
+
items: TimelineAxisTick[];
|
|
5336
|
+
/** Horizontal anchor used when placing each tick label. */
|
|
5337
|
+
labelAlign?: Anchor;
|
|
5338
|
+
});
|
|
5339
|
+
|
|
5340
|
+
declare type TimelineAxisLevelBase = {
|
|
5341
|
+
/** Height of this axis level in pixels. Defaults to `28`. */
|
|
5342
|
+
height?: number;
|
|
5343
|
+
/** Optional class applied to the level container. */
|
|
5344
|
+
className?: string;
|
|
5345
|
+
};
|
|
5346
|
+
|
|
5347
|
+
/**
|
|
5348
|
+
* A labeled time range rendered inside an axis level.
|
|
5349
|
+
*
|
|
5350
|
+
* Use spans for "timeboxes" such as months, half-hours, sprints, or any
|
|
5351
|
+
* other interval that should be labeled between boundary guides.
|
|
5352
|
+
*/
|
|
5353
|
+
export declare interface TimelineAxisSpan {
|
|
5354
|
+
/** Stable React key. Falls back to a start/end-based key when omitted. */
|
|
5355
|
+
key?: React_2.Key;
|
|
5356
|
+
/** Start of the timebox. Accepts a `Date` or a millisecond timestamp. */
|
|
5357
|
+
start: TimeValue;
|
|
5358
|
+
/** End of the timebox. Accepts a `Date` or a millisecond timestamp. */
|
|
5359
|
+
end: TimeValue;
|
|
5360
|
+
/** Label rendered inside the span. */
|
|
5361
|
+
label?: React_2.ReactNode;
|
|
5362
|
+
/** Optional class applied to the positioned span element. */
|
|
5363
|
+
className?: string;
|
|
5364
|
+
/** Optional inline style applied to the positioned span element. */
|
|
5365
|
+
style?: React_2.CSSProperties;
|
|
5366
|
+
}
|
|
5367
|
+
|
|
5368
|
+
/**
|
|
5369
|
+
* A labeled point in an axis level.
|
|
5370
|
+
*
|
|
5371
|
+
* Ticks are useful for point-in-time labels such as milestones or specific
|
|
5372
|
+
* timestamps. For boxed labels between boundaries, prefer `TimelineAxisSpan`.
|
|
5373
|
+
*/
|
|
5374
|
+
export declare interface TimelineAxisTick {
|
|
5375
|
+
/** Stable React key. Falls back to an `at`-based key when omitted. */
|
|
5376
|
+
key?: React_2.Key;
|
|
5377
|
+
/** Point in time represented by this tick. */
|
|
5378
|
+
at: TimeValue;
|
|
5379
|
+
/** Label rendered for the tick. */
|
|
5380
|
+
label?: React_2.ReactNode;
|
|
5381
|
+
/**
|
|
5382
|
+
* Optional custom label position.
|
|
5383
|
+
*
|
|
5384
|
+
* Defaults to `at`. Use this when the tick represents one time but its label
|
|
5385
|
+
* should be positioned elsewhere.
|
|
5386
|
+
*/
|
|
5387
|
+
labelAt?: TimeValue;
|
|
5388
|
+
/** Optional class applied to the tick container. */
|
|
5389
|
+
className?: string;
|
|
5390
|
+
/** Optional inline style applied to the tick container. */
|
|
5391
|
+
style?: React_2.CSSProperties;
|
|
5392
|
+
}
|
|
5393
|
+
|
|
5394
|
+
/**
|
|
5395
|
+
* A decorative band rendered behind the timeline body.
|
|
5396
|
+
*
|
|
5397
|
+
* Useful for blackout windows, maintenance ranges, release freezes, or any
|
|
5398
|
+
* other highlighted interval.
|
|
5399
|
+
*/
|
|
5400
|
+
export declare interface TimelineBand {
|
|
5401
|
+
/** Stable React key. Falls back to a start/end-based key when omitted. */
|
|
5402
|
+
key?: React_2.Key;
|
|
5403
|
+
/** Start of the band. */
|
|
5404
|
+
start: TimeValue;
|
|
5405
|
+
/** End of the band. */
|
|
5406
|
+
end: TimeValue;
|
|
5407
|
+
/** Optional background color convenience prop. */
|
|
5408
|
+
color?: string;
|
|
5409
|
+
/** Optional class applied to the band element. */
|
|
5410
|
+
className?: string;
|
|
5411
|
+
/** Optional inline style applied to the band element. */
|
|
5412
|
+
style?: React_2.CSSProperties;
|
|
5413
|
+
}
|
|
5414
|
+
|
|
5415
|
+
/**
|
|
5416
|
+
* Decorative layers rendered by `Timeline.Viewport`.
|
|
5417
|
+
*/
|
|
5418
|
+
export declare interface TimelineDecorations {
|
|
5419
|
+
/** Background range highlights rendered behind rows. */
|
|
5420
|
+
bands?: TimelineBand[];
|
|
5421
|
+
/** Vertical markers rendered in the axis and/or body. */
|
|
5422
|
+
markers?: TimelineMarker[];
|
|
5423
|
+
}
|
|
5424
|
+
|
|
5425
|
+
/**
|
|
5426
|
+
* A vertical guide line projected onto the axis and/or the timeline body.
|
|
5427
|
+
*
|
|
5428
|
+
* Guides are the timeline's "boundaries". Apps usually derive them from their
|
|
5429
|
+
* own scale logic, then pair them with axis spans to label the ranges between
|
|
5430
|
+
* those boundaries.
|
|
5431
|
+
*/
|
|
5432
|
+
export declare interface TimelineGuide {
|
|
5433
|
+
/** Stable React key. Falls back to an `at`-based key when omitted. */
|
|
5434
|
+
key?: React_2.Key;
|
|
5435
|
+
/** Time position for the guide line. */
|
|
5436
|
+
at: TimeValue;
|
|
5437
|
+
/** Optional class applied to the guide inside the axis area. */
|
|
5438
|
+
axisClassName?: string;
|
|
5439
|
+
/** Optional inline style applied to the guide inside the axis area. */
|
|
5440
|
+
axisStyle?: React_2.CSSProperties;
|
|
5441
|
+
/** Optional class applied to the guide inside the body area. */
|
|
5442
|
+
bodyClassName?: string;
|
|
5443
|
+
/** Optional inline style applied to the guide inside the body area. */
|
|
5444
|
+
bodyStyle?: React_2.CSSProperties;
|
|
5445
|
+
}
|
|
5446
|
+
|
|
5447
|
+
export declare type TimelineIntervalProps = {
|
|
5448
|
+
/** Start of the interval. */
|
|
5449
|
+
start: TimeValue;
|
|
5450
|
+
/** End of the interval. */
|
|
5451
|
+
end: TimeValue;
|
|
5452
|
+
/** Rendered content for the interval. */
|
|
5453
|
+
children: React_2.ReactNode;
|
|
5454
|
+
/** Optional stable id used by `Timeline.Link`. */
|
|
5455
|
+
id?: string;
|
|
5456
|
+
/** Top and bottom inset in pixels within the row. Defaults to `0`. */
|
|
5457
|
+
insetY?: number;
|
|
5458
|
+
/** Optional class applied to the positioned interval container. */
|
|
5459
|
+
className?: string;
|
|
5460
|
+
/** Optional inline style applied to the positioned interval container. */
|
|
5461
|
+
style?: React_2.CSSProperties;
|
|
5462
|
+
};
|
|
5463
|
+
|
|
5464
|
+
/**
|
|
5465
|
+
* Shared defaults for `Timeline.Link` instances inside one viewport.
|
|
5466
|
+
*/
|
|
5467
|
+
export declare interface TimelineLinkDefaults {
|
|
5468
|
+
/** Link routing strategy. Only orthogonal routing is currently supported. */
|
|
5469
|
+
routing?: "orthogonal";
|
|
5470
|
+
/** Whether links end with an arrow marker. Defaults to `true`. */
|
|
5471
|
+
arrow?: boolean;
|
|
5472
|
+
/** Horizontal gap used when routing out of and into items. Defaults to `16`. */
|
|
5473
|
+
gap?: number;
|
|
5474
|
+
/** Optional class applied to each link SVG when the link does not override it. */
|
|
5475
|
+
className?: string;
|
|
5476
|
+
/**
|
|
5477
|
+
* Optional inline style applied to each link SVG when the link does not override it.
|
|
5478
|
+
*
|
|
5479
|
+
* Prefer an opaque `color` here over alpha-based text colors when overlapping links
|
|
5480
|
+
* should not appear darker.
|
|
5481
|
+
*/
|
|
5482
|
+
style?: React_2.CSSProperties;
|
|
5483
|
+
/** Optional stroke width used by each link when the link does not override it. */
|
|
5484
|
+
strokeWidth?: number;
|
|
5485
|
+
}
|
|
5486
|
+
|
|
5487
|
+
export declare type TimelineLinkProps = {
|
|
5488
|
+
/** Source `Timeline.Interval` id. */
|
|
5489
|
+
from: string;
|
|
5490
|
+
/** Target `Timeline.Interval` id. */
|
|
5491
|
+
to: string;
|
|
5492
|
+
/** Source anchor used for routing. Defaults to `"end"`. */
|
|
5493
|
+
fromAnchor?: Anchor;
|
|
5494
|
+
/** Target anchor used for routing. Defaults to `"start"`. */
|
|
5495
|
+
toAnchor?: Anchor;
|
|
5496
|
+
/** Overrides the viewport default arrow visibility. */
|
|
5497
|
+
arrow?: boolean;
|
|
5498
|
+
/** Overrides the viewport default routing gap. */
|
|
5499
|
+
gap?: number;
|
|
5500
|
+
/** Optional class applied to the link SVG. */
|
|
5501
|
+
className?: string;
|
|
5502
|
+
/** Optional inline style applied to the link SVG. */
|
|
5503
|
+
style?: React_2.CSSProperties;
|
|
5504
|
+
/** Optional stroke width for the link path. */
|
|
5505
|
+
strokeWidth?: number;
|
|
5506
|
+
};
|
|
5507
|
+
|
|
5508
|
+
/**
|
|
5509
|
+
* A decorative vertical marker rendered in the axis and/or body.
|
|
5510
|
+
*/
|
|
5511
|
+
export declare interface TimelineMarker {
|
|
5512
|
+
/** Stable React key. Falls back to an `at`-based key when omitted. */
|
|
5513
|
+
key?: React_2.Key;
|
|
5514
|
+
/** Time position for the marker. */
|
|
5515
|
+
at: TimeValue;
|
|
5516
|
+
/** Optional line color convenience prop. */
|
|
5517
|
+
color?: string;
|
|
5518
|
+
/** Optional marker label. */
|
|
5519
|
+
label?: React_2.ReactNode;
|
|
5520
|
+
/** Optional class applied to the outer marker wrapper. */
|
|
5521
|
+
className?: string;
|
|
5522
|
+
/** Optional inline style applied to the outer marker wrapper. */
|
|
5523
|
+
style?: React_2.CSSProperties;
|
|
5524
|
+
/** Optional class applied to the marker line. */
|
|
5525
|
+
lineClassName?: string;
|
|
5526
|
+
/** Optional inline style applied to the marker line. */
|
|
5527
|
+
lineStyle?: React_2.CSSProperties;
|
|
5528
|
+
/** Optional class applied to the marker label. */
|
|
5529
|
+
labelClassName?: string;
|
|
5530
|
+
/** Optional inline style applied to the marker label. */
|
|
5531
|
+
labelStyle?: React_2.CSSProperties;
|
|
5532
|
+
/** Controls where the marker is rendered. Defaults to `"body"`. */
|
|
5533
|
+
placement?: "axis" | "body" | "both";
|
|
5534
|
+
}
|
|
5535
|
+
|
|
5536
|
+
export declare type TimelineRootProps = {
|
|
5537
|
+
/** Inclusive start of the overall timeline range. */
|
|
5538
|
+
start: TimeValue;
|
|
5539
|
+
/** Inclusive end of the overall timeline range. */
|
|
5540
|
+
end: TimeValue;
|
|
5541
|
+
/** Timeline subtree. Usually contains one `Timeline.Viewport`. */
|
|
5542
|
+
children: React_2.ReactNode;
|
|
5543
|
+
/** Optional class applied to the root container. */
|
|
5544
|
+
className?: string;
|
|
5545
|
+
/** Optional inline style applied to the root container. */
|
|
5546
|
+
style?: React_2.CSSProperties;
|
|
5547
|
+
};
|
|
5548
|
+
|
|
5549
|
+
/**
|
|
5550
|
+
* Background content rendered for a `Timeline.Row` in a dedicated layer.
|
|
5551
|
+
*
|
|
5552
|
+
* Use this when a row background should sit behind guides but in front of body
|
|
5553
|
+
* bands. This is different from `Timeline.Row`'s own `style`, which affects the
|
|
5554
|
+
* row content container itself.
|
|
5555
|
+
*/
|
|
5556
|
+
export declare interface TimelineRowBackground {
|
|
5557
|
+
/** Optional class applied to the background layer element. */
|
|
5558
|
+
className?: string;
|
|
5559
|
+
/** Optional inline style applied to the background layer element. */
|
|
5560
|
+
style?: React_2.CSSProperties;
|
|
5561
|
+
}
|
|
5562
|
+
|
|
5563
|
+
export declare type TimelineRowProps = {
|
|
5564
|
+
/** Row contents, typically intervals. */
|
|
5565
|
+
children: React_2.ReactNode;
|
|
5566
|
+
/** Optional class applied to the row content container. */
|
|
5567
|
+
className?: string;
|
|
5568
|
+
/** Optional inline style applied to the row content container. */
|
|
5569
|
+
style?: React_2.CSSProperties;
|
|
5570
|
+
/** Row height in pixels. Defaults to `32`. */
|
|
5571
|
+
height?: number;
|
|
5572
|
+
/**
|
|
5573
|
+
* Optional background rendered in a dedicated layer.
|
|
5574
|
+
*
|
|
5575
|
+
* Use this instead of `style.background` when guides should remain visible in
|
|
5576
|
+
* front of the row background.
|
|
5577
|
+
*/
|
|
5578
|
+
background?: TimelineRowBackground | null;
|
|
5579
|
+
};
|
|
5580
|
+
|
|
5581
|
+
export declare type TimelineViewportProps = {
|
|
5582
|
+
/** Timeline content. Rows and links can be passed in any order. */
|
|
5583
|
+
children: React_2.ReactNode;
|
|
5584
|
+
/** Optional fixed canvas width in pixels for horizontally scrollable timelines. */
|
|
5585
|
+
canvasWidth?: number;
|
|
5586
|
+
/** Keeps the axis pinned to the top of the viewport when scrolling vertically. */
|
|
5587
|
+
stickyAxis?: boolean;
|
|
5588
|
+
/** Axis configuration for guides and header levels. */
|
|
5589
|
+
axis?: TimelineAxis;
|
|
5590
|
+
/** Decorative layers such as bands and markers. */
|
|
5591
|
+
decorations?: TimelineDecorations;
|
|
5592
|
+
/** Shared defaults applied to `Timeline.Link` nodes inside this viewport. */
|
|
5593
|
+
linkDefaults?: TimelineLinkDefaults;
|
|
5594
|
+
/** Optional class applied to the scroll viewport. */
|
|
5595
|
+
className?: string;
|
|
5596
|
+
/** Optional inline style applied to the scroll viewport. */
|
|
5597
|
+
style?: React_2.CSSProperties;
|
|
5598
|
+
};
|
|
5599
|
+
|
|
5600
|
+
declare type TimeValue = Date | number;
|
|
5601
|
+
|
|
5602
|
+
/**
|
|
5603
|
+
* Resolved timezone object with helpers bound to the configured timezone.
|
|
5604
|
+
*/
|
|
5605
|
+
export declare interface TimeZone {
|
|
5606
|
+
/** Raw IANA timezone string (e.g. "America/Los_Angeles"). */
|
|
5607
|
+
value: string;
|
|
5608
|
+
/** Today's date in this timezone. */
|
|
5609
|
+
today: () => CalendarDate;
|
|
5610
|
+
/** Current instant in this timezone. */
|
|
5611
|
+
now: () => ZonedDateTime;
|
|
5612
|
+
}
|
|
5613
|
+
|
|
4919
5614
|
declare function Title({ className, ...props }: React_2.ComponentProps<"div">): JSX.Element;
|
|
4920
5615
|
|
|
4921
5616
|
declare namespace Title {
|
|
@@ -5018,7 +5713,6 @@ declare type TypedPaths<TRoutes extends Record<string, Record<string, string>>>
|
|
|
5018
5713
|
export declare function useAIChat(config: {
|
|
5019
5714
|
client: AIGatewayClient;
|
|
5020
5715
|
model: string;
|
|
5021
|
-
stream?: boolean;
|
|
5022
5716
|
}): {
|
|
5023
5717
|
messages: AIChatMessage[];
|
|
5024
5718
|
status: AIChatStatus;
|
|
@@ -5056,6 +5750,41 @@ export declare const useAppShellConfig: () => AppShellConfigContextType;
|
|
|
5056
5750
|
*/
|
|
5057
5751
|
export declare const useAppShellData: () => AppShellDataContextType;
|
|
5058
5752
|
|
|
5753
|
+
/**
|
|
5754
|
+
* Ref to the AppShell **content scroll container** — the element that owns
|
|
5755
|
+
* vertical scrolling for page content.
|
|
5756
|
+
*
|
|
5757
|
+
* The shell is viewport-bounded (`h-svh`), so the document itself no longer
|
|
5758
|
+
* scrolls; the content area does. Use this wherever you would previously have
|
|
5759
|
+
* reached for `window`/document scroll — reading `scrollTop`, calling
|
|
5760
|
+
* `scrollTo`, attaching a `scroll` listener, or passing `root` to an
|
|
5761
|
+
* `IntersectionObserver`:
|
|
5762
|
+
*
|
|
5763
|
+
* ```tsx
|
|
5764
|
+
* const scrollRef = useAppShellScrollContainer();
|
|
5765
|
+
* useEffect(() => {
|
|
5766
|
+
* const el = scrollRef.current;
|
|
5767
|
+
* if (!el) return;
|
|
5768
|
+
* const onScroll = () =>
|
|
5769
|
+
* setProgress(el.scrollTop / (el.scrollHeight - el.clientHeight));
|
|
5770
|
+
* el.addEventListener("scroll", onScroll, { passive: true });
|
|
5771
|
+
* return () => el.removeEventListener("scroll", onScroll);
|
|
5772
|
+
* }, [scrollRef]);
|
|
5773
|
+
* ```
|
|
5774
|
+
*
|
|
5775
|
+
* The element mounts with the layout, above your page, so read `ref.current`
|
|
5776
|
+
* inside an effect (it is populated by the time effects run), not during
|
|
5777
|
+
* render.
|
|
5778
|
+
*
|
|
5779
|
+
* Notes:
|
|
5780
|
+
* - On a `<Layout fill>` page this element does not scroll — its children
|
|
5781
|
+
* (e.g. a `DataTable`) manage their own scrolling.
|
|
5782
|
+
* - Outside a `SidebarLayout` the returned ref's `current` is always `null`.
|
|
5783
|
+
* - The same element carries a `data-appshell-scroll-container` attribute for
|
|
5784
|
+
* non-React access (CSS, tests, `document.querySelector`).
|
|
5785
|
+
*/
|
|
5786
|
+
export declare function useAppShellScrollContainer(): RefObject<HTMLElement | null>;
|
|
5787
|
+
|
|
5059
5788
|
/**
|
|
5060
5789
|
* Hook that encapsulates the async select pattern — fetching on open,
|
|
5061
5790
|
* request cancellation via `AbortController`, and loading/error state.
|
|
@@ -5769,6 +6498,14 @@ export { useLocation }
|
|
|
5769
6498
|
|
|
5770
6499
|
export { useNavigate }
|
|
5771
6500
|
|
|
6501
|
+
/**
|
|
6502
|
+
* Returns a function that opens the CommandPalette.
|
|
6503
|
+
*
|
|
6504
|
+
* Optionally accepts an initial search string, including prefix-activated
|
|
6505
|
+
* search modes such as `PO: alice`.
|
|
6506
|
+
*/
|
|
6507
|
+
export declare function useOpenCommandPalette(): (options?: OpenCommandPaletteOptions) => void;
|
|
6508
|
+
|
|
5772
6509
|
/**
|
|
5773
6510
|
* Override the breadcrumb title for the current page.
|
|
5774
6511
|
*
|
|
@@ -5829,6 +6566,17 @@ export { useParams }
|
|
|
5829
6566
|
*/
|
|
5830
6567
|
export declare function useRegisterCommandPaletteActions(group: string, actions: CommandPaletteAction[]): void;
|
|
5831
6568
|
|
|
6569
|
+
/**
|
|
6570
|
+
* Returns the full BCP-47 locale (e.g. "en-GB") for Intl / date formatting.
|
|
6571
|
+
* Also returns the language code (e.g. "en") used for label resolution.
|
|
6572
|
+
*
|
|
6573
|
+
* Falls back to browser detection when used outside an AppShell.
|
|
6574
|
+
*/
|
|
6575
|
+
export declare const useResolvedLocale: () => {
|
|
6576
|
+
locale: string;
|
|
6577
|
+
language: string;
|
|
6578
|
+
};
|
|
6579
|
+
|
|
5832
6580
|
export { useRouteError }
|
|
5833
6581
|
|
|
5834
6582
|
export { useSearchParams }
|
|
@@ -5856,6 +6604,12 @@ export declare const useTheme: () => {
|
|
|
5856
6604
|
setTheme: (colorTheme: ColorTheme) => void;
|
|
5857
6605
|
};
|
|
5858
6606
|
|
|
6607
|
+
/**
|
|
6608
|
+
* Returns the configured timezone with bound `today()` and `now()` helpers.
|
|
6609
|
+
* Falls back to the user's local timezone when not configured.
|
|
6610
|
+
*/
|
|
6611
|
+
export declare const useTimeZone: () => TimeZone;
|
|
6612
|
+
|
|
5859
6613
|
export declare const useToast: () => typeof toast;
|
|
5860
6614
|
|
|
5861
6615
|
/**
|
|
@@ -5940,6 +6694,28 @@ declare namespace Validity {
|
|
|
5940
6694
|
var displayName: string;
|
|
5941
6695
|
}
|
|
5942
6696
|
|
|
6697
|
+
/**
|
|
6698
|
+
* Owns scrolling, axis rendering, decoration layers, and link layering.
|
|
6699
|
+
*
|
|
6700
|
+
* Example:
|
|
6701
|
+
* ```tsx
|
|
6702
|
+
* <Timeline.Viewport
|
|
6703
|
+
* canvasWidth={1200}
|
|
6704
|
+
* axis={{ guides, levels }}
|
|
6705
|
+
* decorations={{ bands }}
|
|
6706
|
+
* linkDefaults={{ style: { color: "var(--muted-foreground)" }, strokeWidth: 1.5 }}
|
|
6707
|
+
* >
|
|
6708
|
+
* {rows}
|
|
6709
|
+
* {links}
|
|
6710
|
+
* </Timeline.Viewport>
|
|
6711
|
+
* ```
|
|
6712
|
+
*/
|
|
6713
|
+
declare function Viewport({ children, canvasWidth, stickyAxis, axis, decorations, linkDefaults, className, style, }: TimelineViewportProps): JSX.Element;
|
|
6714
|
+
|
|
6715
|
+
declare namespace Viewport {
|
|
6716
|
+
var displayName: string;
|
|
6717
|
+
}
|
|
6718
|
+
|
|
5943
6719
|
/**
|
|
5944
6720
|
* Conditionally render children based on guard evaluation.
|
|
5945
6721
|
*
|
|
@@ -6019,4 +6795,6 @@ export declare function withURLCollectionState(options: UseCollectionOptions & {
|
|
|
6019
6795
|
tableMetadata?: never;
|
|
6020
6796
|
}, [searchParams, setSearchParams]: SearchParamsBinding): UseCollectionOptions;
|
|
6021
6797
|
|
|
6798
|
+
export { ZonedDateTime }
|
|
6799
|
+
|
|
6022
6800
|
export { }
|