@factorialco/f0-react 7.29.0 → 7.31.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/{ChatPdfThumbnail-DLKxKCu9.js → ChatPdfThumbnail-Cg2_Torf.js} +1 -1
- package/dist/{ChatPostComposerDialog-CWiUXeu3.js → ChatPostComposerDialog-D9vt19Do.js} +3 -3
- package/dist/{DocumentToolbar-D2Kg_cdA.js → DocumentToolbar-VcjNLI2W.js} +2 -2
- package/dist/{DocxViewer-DnvZCWyw.js → DocxViewer-B_vuIwqx.js} +2 -2
- package/dist/{F0AiProcessingOverlay-B_DKkEwd.js → F0AiProcessingOverlay-DT4-88F7.js} +1 -1
- package/dist/{F0CanvasPanel-k-vYqK31.js → F0CanvasPanel-BWGjNwSC.js} +23320 -23082
- package/dist/{F0Map-Dmh0i-K5.js → F0Map-BAGn-Pbt.js} +4 -4
- package/dist/{F0VideoPlayer-DzMNzdCj.js → F0VideoPlayer-BiPN02OV.js} +1 -1
- package/dist/{MapProvider-BI0NI6rb.js → MapProvider-DC2FAppw.js} +22726 -21020
- package/dist/{SheetViewer-CoUh18x7.js → SheetViewer-CW5aD1Gh.js} +2 -2
- package/dist/{TextViewer-DgA--ki7.js → TextViewer-BoRCHEug.js} +2 -2
- package/dist/ai.d.ts +16 -0
- package/dist/ai.js +2 -2
- package/dist/component-status.js +39 -39
- package/dist/{experimental-C7W8k5dA.js → experimental-BqvlI_rl.js} +7 -7
- package/dist/experimental.d.ts +62 -2
- package/dist/experimental.js +79 -78
- package/dist/f0.d.ts +305 -16
- package/dist/f0.js +3456 -3416
- package/dist/i18n-provider-defaults.d.ts +16 -0
- package/dist/i18n-provider-defaults.js +17 -1
- package/dist/{index-Cc344DGQ.js → index-C63g3BaC.js} +3 -3
- package/dist/{index-CgAb2PL4.js → index-CqgzgxRb.js} +2 -2
- package/dist/{index-_argGI8H.js → index-DFjMggw2.js} +3 -3
- package/dist/{index-C0K8hZup.js → index-DgYKKlh1.js} +1 -1
- package/dist/index-U6-zZZzn.js +4 -0
- package/dist/{pdfWorker-CSF_iAuE.js → pdfWorker-BM17l5Gd.js} +2 -2
- package/dist/styles.css +1 -1
- package/package.json +2 -2
- package/dist/index-Bflr_UDM.js +0 -4
package/dist/f0.d.ts
CHANGED
|
@@ -4775,6 +4775,8 @@ export declare type DatePeriodsDefinition = {
|
|
|
4775
4775
|
|
|
4776
4776
|
declare type DatePickerCompareTo = Partial<Record<NavigationGranularityKey, CompareToDef[]>>;
|
|
4777
4777
|
|
|
4778
|
+
export declare const datePickerInlineDismissReasons: readonly ["blur", "escape", "commit", "popupClose"];
|
|
4779
|
+
|
|
4778
4780
|
declare interface DatePickerPopupProps {
|
|
4779
4781
|
onSelect?: (value: DatePickerValue_2 | undefined) => void;
|
|
4780
4782
|
value?: DatePickerValue_2;
|
|
@@ -5375,6 +5377,9 @@ export declare const defaultTranslations: {
|
|
|
5375
5377
|
};
|
|
5376
5378
|
readonly toc: {
|
|
5377
5379
|
readonly search: "Search...";
|
|
5380
|
+
readonly noResults: "No matches.";
|
|
5381
|
+
readonly moreResults: "+{{count}} more";
|
|
5382
|
+
readonly resultsCount: "{{count}} results";
|
|
5378
5383
|
};
|
|
5379
5384
|
readonly collections: {
|
|
5380
5385
|
readonly sorting: {
|
|
@@ -6239,6 +6244,19 @@ export declare const defaultTranslations: {
|
|
|
6239
6244
|
readonly other: "{{count}} issues";
|
|
6240
6245
|
};
|
|
6241
6246
|
};
|
|
6247
|
+
readonly sections: {
|
|
6248
|
+
readonly search: {
|
|
6249
|
+
readonly placeholder: "Search this record";
|
|
6250
|
+
readonly noResults: "No field matches.";
|
|
6251
|
+
readonly moreResults: "+{{count}} more";
|
|
6252
|
+
readonly resultsCount: "{{count}} fields";
|
|
6253
|
+
};
|
|
6254
|
+
};
|
|
6255
|
+
readonly inline: {
|
|
6256
|
+
readonly edit: "Edit {{label}}";
|
|
6257
|
+
readonly copy: "Copy {{label}}";
|
|
6258
|
+
readonly copied: "Copied {{label}}";
|
|
6259
|
+
};
|
|
6242
6260
|
readonly file: {
|
|
6243
6261
|
readonly dropzone: "Drag and drop a file, or click to select";
|
|
6244
6262
|
readonly dropzoneActive: "Drop the file here";
|
|
@@ -6647,6 +6665,8 @@ export declare type DisplayToken = "block" | "flex" | "inline" | "inline-flex" |
|
|
|
6647
6665
|
*/
|
|
6648
6666
|
declare type DistributiveOmit<T, K extends PropertyKey> = T extends unknown ? Omit<T, K> : never;
|
|
6649
6667
|
|
|
6668
|
+
declare type DistributiveOmit_2<T, K extends PropertyKey> = T extends unknown ? Omit<T, K> : never;
|
|
6669
|
+
|
|
6650
6670
|
/** Divider direction */
|
|
6651
6671
|
export declare type DividerToken = "x" | "y";
|
|
6652
6672
|
|
|
@@ -8328,6 +8348,8 @@ export declare interface F0AnalyticsDashboardProps<Filters extends FiltersDefini
|
|
|
8328
8348
|
navigationFilters?: NavigationFiltersDefinition;
|
|
8329
8349
|
}
|
|
8330
8350
|
|
|
8351
|
+
export declare type F0AnySectionConfig = F0PerSectionSectionConfig | F0ContentSectionConfig;
|
|
8352
|
+
|
|
8331
8353
|
/**
|
|
8332
8354
|
* Config for array fields (multi-select or multi-file)
|
|
8333
8355
|
* @typeParam T - The value type (string or number)
|
|
@@ -8855,6 +8877,17 @@ export declare interface F0BaseConfig {
|
|
|
8855
8877
|
* field-specific configuration (e.g. data source, options) or a custom component.
|
|
8856
8878
|
*/
|
|
8857
8879
|
customFieldName?: string;
|
|
8880
|
+
/**
|
|
8881
|
+
* Allow editing in inline mode. Resolve viewer permissions when building the
|
|
8882
|
+
* schema.
|
|
8883
|
+
* @default true
|
|
8884
|
+
*/
|
|
8885
|
+
editable?: boolean;
|
|
8886
|
+
/**
|
|
8887
|
+
* Add a plain-text copy action in inline mode.
|
|
8888
|
+
* @default false
|
|
8889
|
+
*/
|
|
8890
|
+
copyable?: boolean;
|
|
8858
8891
|
}
|
|
8859
8892
|
|
|
8860
8893
|
/**
|
|
@@ -8904,6 +8937,16 @@ export declare interface F0BaseField {
|
|
|
8904
8937
|
* Used with the form-level `renderCustomField` callback.
|
|
8905
8938
|
*/
|
|
8906
8939
|
customFieldName?: string;
|
|
8940
|
+
/**
|
|
8941
|
+
* Allow editing in inline mode.
|
|
8942
|
+
* @default true
|
|
8943
|
+
*/
|
|
8944
|
+
editable?: boolean;
|
|
8945
|
+
/**
|
|
8946
|
+
* Add a plain-text copy action in inline mode.
|
|
8947
|
+
* @default false
|
|
8948
|
+
*/
|
|
8949
|
+
copyable?: boolean;
|
|
8907
8950
|
}
|
|
8908
8951
|
|
|
8909
8952
|
/**
|
|
@@ -9437,6 +9480,16 @@ declare interface F0ClarifyingPanelProps {
|
|
|
9437
9480
|
isSubmitDisabled?: boolean;
|
|
9438
9481
|
}
|
|
9439
9482
|
|
|
9483
|
+
/**
|
|
9484
|
+
* A section with content instead of fields: a `sections` key with no match in
|
|
9485
|
+
* `schema`. It gets a heading and rail entry but no validation or dirty state.
|
|
9486
|
+
*/
|
|
9487
|
+
export declare interface F0ContentSectionConfig extends F0SectionConfig {
|
|
9488
|
+
/** Rendered under the section heading. */
|
|
9489
|
+
render: () => React.ReactNode;
|
|
9490
|
+
submitConfig?: never;
|
|
9491
|
+
}
|
|
9492
|
+
|
|
9440
9493
|
/**
|
|
9441
9494
|
* F0 config options specific to custom fields
|
|
9442
9495
|
*
|
|
@@ -10369,6 +10422,21 @@ export declare const F0DatePicker: WithDataTestIdReturnType_3<typeof F0DatePicke
|
|
|
10369
10422
|
|
|
10370
10423
|
declare function F0DatePicker_2({ onChange, value, presets, granularities, minDate, maxDate, open, showIcon, displayFormat, selectOnCellOnly, ...inputProps }: F0DatePickerProps): JSX_2.Element;
|
|
10371
10424
|
|
|
10425
|
+
export declare const F0DatePickerInline: WithDataTestIdReturnType_3<typeof F0DatePickerInline_2>;
|
|
10426
|
+
|
|
10427
|
+
/** Renders the date as text at rest and the public date picker while editing. */
|
|
10428
|
+
declare function F0DatePickerInline_2({ editing, onDismiss, ...props }: F0DatePickerInlineProps): JSX_2.Element;
|
|
10429
|
+
|
|
10430
|
+
export declare type F0DatePickerInlineDismissReason = (typeof datePickerInlineDismissReasons)[number];
|
|
10431
|
+
|
|
10432
|
+
export declare interface F0DatePickerInlineProps extends Omit<F0DatePickerProps, "open" | "onOpenChange"> {
|
|
10433
|
+
/** Mounts F0DatePicker with its calendar initially open. */
|
|
10434
|
+
editing?: boolean;
|
|
10435
|
+
onDismiss?: (reason: F0DatePickerInlineDismissReason) => void;
|
|
10436
|
+
open?: never;
|
|
10437
|
+
onOpenChange?: never;
|
|
10438
|
+
}
|
|
10439
|
+
|
|
10372
10440
|
export declare type F0DatePickerProps = Pick<DatePickerPopupProps, "minDate" | "maxDate" | "presets" | "open" | "onOpenChange" | "selectOnCellOnly"> & {
|
|
10373
10441
|
/** The picker has no `periods` prop, so it can only offer the calendar granularities. */
|
|
10374
10442
|
granularities?: GranularityDefinitionKey[];
|
|
@@ -11303,7 +11371,8 @@ export declare interface F0FormDefinitionPerSection<T extends F0PerSectionSchema
|
|
|
11303
11371
|
/** Module associated with this form (for avatar display in canvas cards) */
|
|
11304
11372
|
module?: ModuleId;
|
|
11305
11373
|
schema: T;
|
|
11306
|
-
|
|
11374
|
+
/** Keyed by section ID. A key with no schema entry is a content section. */
|
|
11375
|
+
sections?: F0PerSectionSections<T>;
|
|
11307
11376
|
defaultValues?: {
|
|
11308
11377
|
[K in keyof T]?: Partial<z.infer<T[K]>>;
|
|
11309
11378
|
};
|
|
@@ -11390,7 +11459,7 @@ export declare type F0FormErrorTriggerMode = "on-blur" | "on-change" | "on-submi
|
|
|
11390
11459
|
* duration, select, checkbox, switch, date, time, datetime, daterange, richtext, custom,
|
|
11391
11460
|
* and file.
|
|
11392
11461
|
*/
|
|
11393
|
-
export declare function F0FormField({ field, value, onChange, onBlur, error, errorMessage, status, loading, required, disabled, hideLabel: hideLabelProp, initialFiles, }: F0FormFieldProps): JSX_2.Element;
|
|
11462
|
+
export declare function F0FormField({ field, value, onChange, onBlur, error, errorMessage, status, loading, required, disabled, hideLabel: hideLabelProp, initialFiles, inline, }: F0FormFieldProps): JSX_2.Element;
|
|
11394
11463
|
|
|
11395
11464
|
export declare namespace F0FormField {
|
|
11396
11465
|
var displayName: string;
|
|
@@ -11796,6 +11865,12 @@ declare interface F0FormFieldCommonProps {
|
|
|
11796
11865
|
disabled?: boolean;
|
|
11797
11866
|
/** Whether to hide the label (useful when label is rendered externally) */
|
|
11798
11867
|
hideLabel?: boolean;
|
|
11868
|
+
/**
|
|
11869
|
+
* Render an editable detail row. The row owns the label; edits still call
|
|
11870
|
+
* onChange.
|
|
11871
|
+
* @default false
|
|
11872
|
+
*/
|
|
11873
|
+
inline?: boolean;
|
|
11799
11874
|
}
|
|
11800
11875
|
|
|
11801
11876
|
declare interface F0FormFieldFileProps extends F0FormFieldCommonProps {
|
|
@@ -11876,6 +11951,11 @@ declare interface F0FormPropsWithDefinition {
|
|
|
11876
11951
|
* instead of replacing the entire form with skeleton placeholders.
|
|
11877
11952
|
*/
|
|
11878
11953
|
isLoading?: boolean;
|
|
11954
|
+
/**
|
|
11955
|
+
* Render editable detail rows using the existing save action bar.
|
|
11956
|
+
* @default false
|
|
11957
|
+
*/
|
|
11958
|
+
inline?: boolean;
|
|
11879
11959
|
}
|
|
11880
11960
|
|
|
11881
11961
|
/**
|
|
@@ -11902,6 +11982,11 @@ export declare interface F0FormPropsWithPerSectionDefinition<T extends F0PerSect
|
|
|
11902
11982
|
* instead of replacing the entire form with skeleton placeholders.
|
|
11903
11983
|
*/
|
|
11904
11984
|
isLoading?: boolean;
|
|
11985
|
+
/**
|
|
11986
|
+
* Render editable detail rows. One action bar saves every dirty section.
|
|
11987
|
+
* @default false
|
|
11988
|
+
*/
|
|
11989
|
+
inline?: boolean;
|
|
11905
11990
|
}
|
|
11906
11991
|
|
|
11907
11992
|
/**
|
|
@@ -11914,16 +11999,22 @@ export declare interface F0FormPropsWithPerSectionSchema<T extends F0PerSectionS
|
|
|
11914
11999
|
name: string;
|
|
11915
12000
|
/** Record mapping section IDs to their Zod schemas. Each section is independently validated and submitted. */
|
|
11916
12001
|
schema: T;
|
|
11917
|
-
/**
|
|
11918
|
-
|
|
12002
|
+
/**
|
|
12003
|
+
* Section configurations keyed by section ID. A key not in `schema` is a
|
|
12004
|
+
* content section.
|
|
12005
|
+
*/
|
|
12006
|
+
sections?: F0PerSectionSections<T>;
|
|
11919
12007
|
/** Default values for each section, keyed by section ID */
|
|
11920
12008
|
defaultValues?: {
|
|
11921
12009
|
[K in keyof T]?: Partial<z.infer<T[K]>>;
|
|
11922
12010
|
};
|
|
11923
12011
|
/** Callback when a section is submitted. Receives the section ID and its validated data, both correctly typed. */
|
|
11924
12012
|
onSubmit: PerSectionSubmitHandler<T>;
|
|
11925
|
-
/**
|
|
11926
|
-
|
|
12013
|
+
/**
|
|
12014
|
+
* Global submit config applied to all sections (overridable per section).
|
|
12015
|
+
* With `inline`, pass an action-bar config; section overrides are ignored.
|
|
12016
|
+
*/
|
|
12017
|
+
submitConfig?: F0PerSectionSubmitConfig | F0FormActionBarSubmitConfig;
|
|
11927
12018
|
/** Additional class name for the form container */
|
|
11928
12019
|
className?: string;
|
|
11929
12020
|
/**
|
|
@@ -11965,6 +12056,11 @@ export declare interface F0FormPropsWithPerSectionSchema<T extends F0PerSectionS
|
|
|
11965
12056
|
* instead of replacing the entire form with skeleton placeholders.
|
|
11966
12057
|
*/
|
|
11967
12058
|
isLoading?: boolean;
|
|
12059
|
+
/**
|
|
12060
|
+
* Render editable detail rows. One action bar saves every dirty section.
|
|
12061
|
+
* @default false
|
|
12062
|
+
*/
|
|
12063
|
+
inline?: boolean;
|
|
11968
12064
|
}
|
|
11969
12065
|
|
|
11970
12066
|
/**
|
|
@@ -12002,6 +12098,11 @@ export declare interface F0FormPropsWithSingleSchema<TSchema extends F0FormSchem
|
|
|
12002
12098
|
* Controls section sidebar visibility and box wrapping.
|
|
12003
12099
|
*/
|
|
12004
12100
|
styling?: F0FormStylingConfig;
|
|
12101
|
+
/**
|
|
12102
|
+
* Render editable detail rows using the existing save action bar.
|
|
12103
|
+
* @default false
|
|
12104
|
+
*/
|
|
12105
|
+
inline?: boolean;
|
|
12005
12106
|
/**
|
|
12006
12107
|
* Ref to control the form programmatically from outside.
|
|
12007
12108
|
* Use with the `useF0Form` hook to get a ref and submit/reset functions.
|
|
@@ -12064,6 +12165,11 @@ export declare interface F0FormPropsWithSingleSchemaDefinition<TSchema extends F
|
|
|
12064
12165
|
* When a field has `customFieldName`, this function is called instead of the inline `render`.
|
|
12065
12166
|
*/
|
|
12066
12167
|
renderCustomField?: RenderCustomFieldFunction;
|
|
12168
|
+
/**
|
|
12169
|
+
* Render editable detail rows using the existing save action bar.
|
|
12170
|
+
* @default false
|
|
12171
|
+
*/
|
|
12172
|
+
inline?: boolean;
|
|
12067
12173
|
}
|
|
12068
12174
|
|
|
12069
12175
|
/**
|
|
@@ -12077,19 +12183,23 @@ export declare interface F0FormRef {
|
|
|
12077
12183
|
*/
|
|
12078
12184
|
submit: () => Promise<void>;
|
|
12079
12185
|
/**
|
|
12080
|
-
* Reset the form to its default values
|
|
12186
|
+
* Reset the form to its default values.
|
|
12187
|
+
* In inline per-section mode, resets every dirty section.
|
|
12081
12188
|
*/
|
|
12082
12189
|
reset: () => void;
|
|
12083
12190
|
/**
|
|
12084
|
-
* Check if the form has unsaved changes
|
|
12191
|
+
* Check if the form has unsaved changes.
|
|
12192
|
+
* In inline per-section mode, true while any visible section is dirty.
|
|
12085
12193
|
*/
|
|
12086
12194
|
isDirty: () => boolean;
|
|
12087
12195
|
/**
|
|
12088
|
-
* Get the current form values (including unsaved changes)
|
|
12196
|
+
* Get the current form values (including unsaved changes).
|
|
12197
|
+
* In inline per-section mode, keyed by section id.
|
|
12089
12198
|
*/
|
|
12090
12199
|
getValues: () => Record<string, unknown>;
|
|
12091
12200
|
/**
|
|
12092
|
-
* Set a single field value programmatically
|
|
12201
|
+
* Set a single field value programmatically.
|
|
12202
|
+
* In inline per-section mode, the field is looked up in every section.
|
|
12093
12203
|
*/
|
|
12094
12204
|
setValue: (fieldName: string, value: unknown, options?: F0FormSetValueOptions) => void;
|
|
12095
12205
|
/**
|
|
@@ -12102,15 +12212,20 @@ export declare interface F0FormRef {
|
|
|
12102
12212
|
*/
|
|
12103
12213
|
trigger: (fieldName?: string) => Promise<boolean>;
|
|
12104
12214
|
/**
|
|
12105
|
-
* Get current validation errors as a map of field name to error message
|
|
12215
|
+
* Get current validation errors as a map of field name to error message.
|
|
12216
|
+
* In inline per-section mode, the errors of every visible section.
|
|
12106
12217
|
*/
|
|
12107
12218
|
getErrors: () => Record<string, string>;
|
|
12108
12219
|
/**
|
|
12109
|
-
* Get the list of field names in the form
|
|
12220
|
+
* Get the list of field names in the form.
|
|
12221
|
+
* In inline per-section mode, the field names of every visible section.
|
|
12110
12222
|
*/
|
|
12111
12223
|
getFieldNames: () => string[];
|
|
12112
12224
|
/**
|
|
12113
|
-
* Access the action bar imperatively
|
|
12225
|
+
* Access the action bar imperatively, e.g. `actionBar.wiggle()` when
|
|
12226
|
+
* navigation is blocked by unsaved changes. No-op when no bar is shown.
|
|
12227
|
+
* `{ errorHighlight: true }` adds error styling only when there are
|
|
12228
|
+
* validation errors.
|
|
12114
12229
|
*/
|
|
12115
12230
|
actionBar: F0ActionBarRef;
|
|
12116
12231
|
/* Excluded from this release type: _setStateCallback */
|
|
@@ -12150,11 +12265,23 @@ export declare interface F0FormStylingConfig {
|
|
|
12150
12265
|
* @default false
|
|
12151
12266
|
*/
|
|
12152
12267
|
showSectionsSidepanel?: boolean;
|
|
12268
|
+
/**
|
|
12269
|
+
* Pixels between the pinned sections rail and the top of the scroll area,
|
|
12270
|
+
* to clear a sticky header. Inline forms only.
|
|
12271
|
+
* @default 0
|
|
12272
|
+
*/
|
|
12273
|
+
sectionsSidepanelOffset?: number;
|
|
12153
12274
|
/**
|
|
12154
12275
|
* Removes the default padding around the form content.
|
|
12155
12276
|
* @default false
|
|
12156
12277
|
*/
|
|
12157
12278
|
noPadding?: boolean;
|
|
12279
|
+
/**
|
|
12280
|
+
* Adds a search box to the sections rail that filters sections and fields by
|
|
12281
|
+
* label. Requires `showSectionsSidepanel`.
|
|
12282
|
+
* @default false
|
|
12283
|
+
*/
|
|
12284
|
+
sectionsSearch?: boolean;
|
|
12158
12285
|
}
|
|
12159
12286
|
|
|
12160
12287
|
/**
|
|
@@ -12990,8 +13117,18 @@ declare type F0PerSectionSchema_2 = Record<string, F0FormSchema_2>;
|
|
|
12990
13117
|
export declare interface F0PerSectionSectionConfig extends F0SectionConfig {
|
|
12991
13118
|
/** Override submit config for this specific section */
|
|
12992
13119
|
submitConfig?: F0PerSectionSubmitConfig;
|
|
13120
|
+
/** Only content sections (no schema key) take `render`. */
|
|
13121
|
+
render?: never;
|
|
12993
13122
|
}
|
|
12994
13123
|
|
|
13124
|
+
/**
|
|
13125
|
+
* The `sections` record of a per-section form. The plain-record branch lets
|
|
13126
|
+
* forms typed against a generic schema compile, as their keys can't be proven.
|
|
13127
|
+
*/
|
|
13128
|
+
export declare type F0PerSectionSections<T extends F0PerSectionSchema> = ({
|
|
13129
|
+
[K in keyof T & string]?: F0PerSectionSectionConfig;
|
|
13130
|
+
} & Record<string, F0AnySectionConfig>) | Record<string, F0PerSectionSectionConfig>;
|
|
13131
|
+
|
|
12995
13132
|
/**
|
|
12996
13133
|
* Per-section submit configuration, extending the base submit config
|
|
12997
13134
|
* with an optional per-section label override.
|
|
@@ -13489,7 +13626,40 @@ declare type F0SelectFieldProps<T extends string, R = unknown> = F0SelectPopupPr
|
|
|
13489
13626
|
hideArrow?: boolean;
|
|
13490
13627
|
} & Pick<InputFieldProps<T>, "required" | "loading" | "hideLabel" | "labelIcon" | "size" | "label" | "icon" | "placeholder" | "disabled" | "name" | "error" | "status" | "hint">;
|
|
13491
13628
|
|
|
13492
|
-
declare type
|
|
13629
|
+
declare type F0SelectFieldVariantProps<T extends string, R> = Extract<F0SelectProps<T, R>, {
|
|
13630
|
+
variant?: "field";
|
|
13631
|
+
}>;
|
|
13632
|
+
|
|
13633
|
+
/**
|
|
13634
|
+
* @experimental This is an experimental component use it at your own risk
|
|
13635
|
+
*/
|
|
13636
|
+
export declare const F0SelectInline: typeof F0SelectInline_2;
|
|
13637
|
+
|
|
13638
|
+
/** The detail-row select owns its static reading and mounts F0Select for editing. */
|
|
13639
|
+
declare function F0SelectInline_2<T extends string = string, R = unknown>({ editing, onDismiss, ...props }: F0SelectInlineProps<T, R>): JSX_2.Element;
|
|
13640
|
+
|
|
13641
|
+
export declare type F0SelectInlineDismissReason = (typeof selectInlineDismissReasons)[number];
|
|
13642
|
+
|
|
13643
|
+
/** Field props that F0SelectInline draws or controls itself. */
|
|
13644
|
+
declare type F0SelectInlineOmittedProp = "variant" | "open" | "onOpenChange" | "children" | "className" | "asList" | "hideArrow" | "size" | "icon" | "labelIcon" | "required" | "name" | "error" | "status" | "hint";
|
|
13645
|
+
|
|
13646
|
+
export declare type F0SelectInlineProps<T extends string = string, R = unknown> = WithClearableOnChange<DistributiveOmit_2<F0SelectFieldVariantProps<T, R>, F0SelectInlineOmittedProp>, T, R> & {
|
|
13647
|
+
/**
|
|
13648
|
+
* The parent owns the mode. While true, F0Select is mounted with its list
|
|
13649
|
+
* initially open; F0Select then manages that list's open state. `disabled`
|
|
13650
|
+
* wins and keeps the value at rest.
|
|
13651
|
+
*/
|
|
13652
|
+
editing?: boolean;
|
|
13653
|
+
/**
|
|
13654
|
+
* Called once per gesture that ends the edit, on the next frame and after any
|
|
13655
|
+
* `onChange` it caused. The parent sets the mode and restores focus.
|
|
13656
|
+
*/
|
|
13657
|
+
onDismiss?: (reason: F0SelectInlineDismissReason) => void;
|
|
13658
|
+
} & {
|
|
13659
|
+
[K in F0SelectInlineOmittedProp]?: never;
|
|
13660
|
+
};
|
|
13661
|
+
|
|
13662
|
+
declare type F0SelectInlineProps_2<T extends string, R = unknown> = F0SelectPopupProps<T, R> & F0SelectSingleSelectionProps<T, R> & Pick<InputFieldProps<T>, "label" | "placeholder" | "disabled"> & {
|
|
13493
13663
|
/**
|
|
13494
13664
|
* Compact borderless presentation for single-value controls embedded in rows.
|
|
13495
13665
|
* The required label is used as the accessible name and is not shown visually.
|
|
@@ -13645,7 +13815,7 @@ declare type F0SelectPopupProps<T extends string, R = unknown> = {
|
|
|
13645
13815
|
* @template T - The type of the emitted value
|
|
13646
13816
|
* @template R - The type of the record/item data (used with data source)
|
|
13647
13817
|
*/
|
|
13648
|
-
export declare type F0SelectProps<T extends string, R = unknown> = (F0SelectFieldProps<T, R> |
|
|
13818
|
+
export declare type F0SelectProps<T extends string, R = unknown> = (F0SelectFieldProps<T, R> | F0SelectInlineProps_2<T, R>) & F0SelectDataProps<T, R>;
|
|
13649
13819
|
|
|
13650
13820
|
declare type F0SelectSelectionProps<T extends string, R = unknown> = F0SelectSingleSelectionProps<T, R> | {
|
|
13651
13821
|
clearable: true;
|
|
@@ -13929,6 +14099,16 @@ export declare type F0TextareaField = F0BaseField & F0TextareaConfig & {
|
|
|
13929
14099
|
*/
|
|
13930
14100
|
export declare const F0TextAreaInput: React.FC<F0TextAreaInputProps>;
|
|
13931
14101
|
|
|
14102
|
+
/** Wrapped text at rest; the standard textarea while the parent enables editing. */
|
|
14103
|
+
export declare const F0TextAreaInputInline: ForwardRefExoticComponent<F0TextAreaInputInlineProps & RefAttributes<HTMLTextAreaElement>>;
|
|
14104
|
+
|
|
14105
|
+
export declare interface F0TextAreaInputInlineProps extends F0TextAreaInputProps {
|
|
14106
|
+
/** Focuses the textarea when it opens. Defaults to true. */
|
|
14107
|
+
autoFocus?: boolean;
|
|
14108
|
+
editing?: boolean;
|
|
14109
|
+
onDismiss?: (reason: InlineDismissReason) => void;
|
|
14110
|
+
}
|
|
14111
|
+
|
|
13932
14112
|
export declare type F0TextAreaInputProps = Pick<ComponentProps<typeof Textarea_2>, "disabled" | "onChange" | "value" | "placeholder" | "rows" | "cols" | "label" | "labelIcon" | "icon" | "hideLabel" | "maxLength" | "clearable" | "onBlur" | "onFocus" | "name" | "status" | "hint" | "error" | "size" | "loading" | "required" | "maxHeight">;
|
|
13933
14113
|
|
|
13934
14114
|
/**
|
|
@@ -15858,6 +16038,64 @@ declare type InlineDismissReason = (typeof inlineDismissReasons)[number];
|
|
|
15858
16038
|
|
|
15859
16039
|
declare const inlineDismissReasons: readonly ["blur", "escape", "commit"];
|
|
15860
16040
|
|
|
16041
|
+
/** Presentation-only row. The forwarded ref targets the activator for focus restoration. */
|
|
16042
|
+
export declare const InlineFieldRow: ForwardRefExoticComponent<InlineFieldRowProps & RefAttributes<HTMLDivElement>>;
|
|
16043
|
+
|
|
16044
|
+
export declare type InlineFieldRowAction = {
|
|
16045
|
+
key: string;
|
|
16046
|
+
icon: IconType;
|
|
16047
|
+
label: string;
|
|
16048
|
+
onClick: () => void;
|
|
16049
|
+
/** Draws the glyph in the positive token, for a state the row is confirming. */
|
|
16050
|
+
positive?: boolean;
|
|
16051
|
+
};
|
|
16052
|
+
|
|
16053
|
+
/**
|
|
16054
|
+
* Alert props the row renders with `F0Alert`, so every row gets the same
|
|
16055
|
+
* chrome.
|
|
16056
|
+
*/
|
|
16057
|
+
export declare type InlineFieldRowAlert = Omit<F0AlertProps, "variant"> & {
|
|
16058
|
+
/** @default "info" */
|
|
16059
|
+
variant?: F0AlertProps["variant"];
|
|
16060
|
+
};
|
|
16061
|
+
|
|
16062
|
+
export declare const InlineFieldRowList: ({ children }: {
|
|
16063
|
+
children: ReactNode;
|
|
16064
|
+
}) => JSX_2.Element;
|
|
16065
|
+
|
|
16066
|
+
export declare type InlineFieldRowProps = {
|
|
16067
|
+
/** Anchor the row so section navigation and error scrolling can reach it. */
|
|
16068
|
+
anchorId?: string;
|
|
16069
|
+
label: string;
|
|
16070
|
+
/** Marks the label with a star. */
|
|
16071
|
+
required?: boolean;
|
|
16072
|
+
/** Hint shown beside the label. */
|
|
16073
|
+
hint?: string;
|
|
16074
|
+
value: ReactNode;
|
|
16075
|
+
/** Fixed order, closest to the value first. Copy is appended after it. */
|
|
16076
|
+
actions: InlineFieldRowAction[];
|
|
16077
|
+
/** When set, the row appends a copy action that writes exactly this string. */
|
|
16078
|
+
copyValue?: string;
|
|
16079
|
+
/** Omit to disable activation. */
|
|
16080
|
+
onActivate?: () => void;
|
|
16081
|
+
/** Use a caret for text editors and a pointer for popup editors. */
|
|
16082
|
+
activatorCursor?: "caret" | "pointer";
|
|
16083
|
+
/**
|
|
16084
|
+
* `"fixed"` pins the value box to 40px; `"auto"` grows from 40px with its
|
|
16085
|
+
* content.
|
|
16086
|
+
* @default "fixed"
|
|
16087
|
+
*/
|
|
16088
|
+
valueHeight?: "fixed" | "auto";
|
|
16089
|
+
editing: boolean;
|
|
16090
|
+
/** Validation copy below the value; also marks the value box as critical. */
|
|
16091
|
+
message?: string;
|
|
16092
|
+
/**
|
|
16093
|
+
* Contextual alert below the value in both modes; does not affect validity
|
|
16094
|
+
* styling.
|
|
16095
|
+
*/
|
|
16096
|
+
alert?: InlineFieldRowAlert;
|
|
16097
|
+
};
|
|
16098
|
+
|
|
15861
16099
|
/**
|
|
15862
16100
|
* @deprecated Renamed to `F0TextInput` to match the F0 input vocabulary
|
|
15863
16101
|
* (any component where the user types text in a box has the `Input` suffix
|
|
@@ -19086,6 +19324,12 @@ export declare type SelectedState = {
|
|
|
19086
19324
|
*/
|
|
19087
19325
|
declare type SelectFieldRenderIf = SelectRenderIfCondition | CommonRenderIfCondition | F0BaseFieldRenderIfFunction;
|
|
19088
19326
|
|
|
19327
|
+
/**
|
|
19328
|
+
* What ends an inline select edit. Any close of the list other than a pick or
|
|
19329
|
+
* Escape is `"popupClose"`. There is no `"blur"`: focus stays in the list.
|
|
19330
|
+
*/
|
|
19331
|
+
export declare const selectInlineDismissReasons: readonly ["escape", "commit", "popupClose"];
|
|
19332
|
+
|
|
19089
19333
|
export declare type SelectionId = number | string;
|
|
19090
19334
|
|
|
19091
19335
|
export declare type SelectionMeta<R extends RecordType> = {
|
|
@@ -19248,6 +19492,13 @@ export declare const StandardLayout: WithDataTestIdReturnType_2<ForwardRefExotic
|
|
|
19248
19492
|
|
|
19249
19493
|
export declare interface StandardLayoutProps extends VariantProps<typeof layoutVariants> {
|
|
19250
19494
|
children?: default_2.ReactNode;
|
|
19495
|
+
/**
|
|
19496
|
+
* Whether the layout is its own scroll container. Set `false` when the host
|
|
19497
|
+
* scrolls the page, so sticky descendants pin against the host's scroller.
|
|
19498
|
+
* An overflow box is a sticky scrollport even when it never scrolls.
|
|
19499
|
+
* @default true
|
|
19500
|
+
*/
|
|
19501
|
+
scrollable?: boolean;
|
|
19251
19502
|
}
|
|
19252
19503
|
|
|
19253
19504
|
export declare type Status = (typeof statuses_2)[number];
|
|
@@ -20375,7 +20626,37 @@ declare interface TOCProps {
|
|
|
20375
20626
|
sortable?: boolean;
|
|
20376
20627
|
onReorder?: (reorderedIds: IdStructure[]) => void;
|
|
20377
20628
|
showSearchBox?: boolean;
|
|
20629
|
+
/**
|
|
20630
|
+
* @experimental
|
|
20631
|
+
* Makes the search box a combobox whose results the arrow keys walk and Enter
|
|
20632
|
+
* picks. Matching ignores accents and case and needs every term; a matching
|
|
20633
|
+
* parent keeps its subtree; Escape clears. Has no effect without
|
|
20634
|
+
* `showSearchBox`.
|
|
20635
|
+
* @default false
|
|
20636
|
+
*/
|
|
20637
|
+
navigableSearch?: boolean;
|
|
20378
20638
|
searchPlaceholder?: string;
|
|
20639
|
+
/**
|
|
20640
|
+
* Results shown before the list is cut, with a line counting the rest.
|
|
20641
|
+
* @default Infinity
|
|
20642
|
+
*/
|
|
20643
|
+
searchResultLimit?: number;
|
|
20644
|
+
/** Called with the query on every change. */
|
|
20645
|
+
onSearchChange?: (query: string) => void;
|
|
20646
|
+
/**
|
|
20647
|
+
* Copy for a search that matches nothing. Defaults to `i18n.toc.noResults`.
|
|
20648
|
+
*/
|
|
20649
|
+
searchEmptyLabel?: string;
|
|
20650
|
+
/**
|
|
20651
|
+
* Copy under a cut list; `{{count}}` is the hidden results. Defaults to
|
|
20652
|
+
* `i18n.toc.moreResults`.
|
|
20653
|
+
*/
|
|
20654
|
+
searchMoreResultsLabel?: string;
|
|
20655
|
+
/**
|
|
20656
|
+
* Copy announced when results change; `{{count}}` is the shown results.
|
|
20657
|
+
* Defaults to `i18n.toc.resultsCount`.
|
|
20658
|
+
*/
|
|
20659
|
+
searchResultsCountLabel?: string;
|
|
20379
20660
|
hideChildrenCounter?: boolean;
|
|
20380
20661
|
/** Enable vertical scrolling when content overflows (default: true) */
|
|
20381
20662
|
scrollable?: boolean;
|
|
@@ -21737,10 +22018,18 @@ export declare type WelcomeSuggestionClickEvent = {
|
|
|
21737
22018
|
prompt: string;
|
|
21738
22019
|
};
|
|
21739
22020
|
|
|
21740
|
-
declare interface WiggleOptions {
|
|
22021
|
+
export declare interface WiggleOptions {
|
|
21741
22022
|
errorHighlight?: boolean;
|
|
21742
22023
|
}
|
|
21743
22024
|
|
|
22025
|
+
/** Clear hands a clearable single selection's `onChange` `undefined`. */
|
|
22026
|
+
declare type WithClearableOnChange<P, T extends string, R> = P extends {
|
|
22027
|
+
clearable: true;
|
|
22028
|
+
multiple?: false;
|
|
22029
|
+
} ? Omit<P, "onChange"> & {
|
|
22030
|
+
onChange?: (value: T | undefined, originalItem?: ResolvedRecordType<R>, option?: F0SelectItemObject<T, ResolvedRecordType<R>>) => void;
|
|
22031
|
+
} : P;
|
|
22032
|
+
|
|
21744
22033
|
export declare const withDataTestId: <T extends default_2.ComponentType<any>>(component: T) => WithDataTestIdReturnType<T>;
|
|
21745
22034
|
|
|
21746
22035
|
export declare type WithDataTestIdProps = {
|