@factorialco/f0-react 2.32.1 → 2.33.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.
@@ -122549,7 +122549,7 @@ const BW1 = ({ text: e }) => /* @__PURE__ */ a(
122549
122549
  type: "error",
122550
122550
  message: typeof c == "string" ? c : void 0
122551
122551
  }), r || console.error(
122552
- "InputField: label is required for accessibility reasons. If you don't want to show a label, set hideLabel to true."
122552
+ "F0InputField: label is required for accessibility reasons. If you don't want to show a label, set hideLabel to true."
122553
122553
  ), A2(() => {
122554
122554
  f2(
122555
122555
  E && v && k(v) > E ? v?.substring(0, E) : v
@@ -122817,7 +122817,7 @@ const BW1 = ({ text: e }) => /* @__PURE__ */ a(
122817
122817
  );
122818
122818
  }
122819
122819
  );
122820
- Xk.displayName = "InputField";
122820
+ Xk.displayName = "F0InputField";
122821
122821
  const M8 = H.forwardRef(
122822
122822
  ({
122823
122823
  className: e,
@@ -128615,7 +128615,10 @@ const Nq1 = (e, t) => !e || "from" in e && !e.from && t.schema.options.mode ===
128615
128615
  "search-input"
128616
128616
  );
128617
128617
  }
128618
- ), r22 = f3("F1SearchBox", Iq1);
128618
+ ), r22 = f3(
128619
+ "F0SearchInput",
128620
+ Iq1
128621
+ );
128619
128622
  function jq1({
128620
128623
  option: e,
128621
128624
  isSelected: t,
@@ -131457,7 +131460,7 @@ const mG1 = ({
131457
131460
  return i;
131458
131461
  }, e);
131459
131462
  return /* @__PURE__ */ a(u22, { ...t });
131460
- }, UQ1 = f3("Input", wG1);
131463
+ }, UQ1 = f3("F0TextInput", wG1);
131461
131464
  function MG1(e) {
131462
131465
  if (typeof e != "string")
131463
131466
  throw new TypeError("Expected a string");
@@ -135106,7 +135109,7 @@ export {
135106
135109
  fa as f7,
135107
135110
  yQ1 as f8,
135108
135111
  Y4 as f9,
135109
- Db as fA,
135112
+ tQ1 as fA,
135110
135113
  wD2 as fB,
135111
135114
  kD2 as fC,
135112
135115
  xD2 as fD,
@@ -135153,12 +135156,12 @@ export {
135153
135156
  M8 as fr,
135154
135157
  gI1 as fs,
135155
135158
  Ls as ft,
135156
- Pz as fu,
135157
- nQ1 as fv,
135158
- oQ1 as fw,
135159
- hb2 as fx,
135160
- mb2 as fy,
135161
- tQ1 as fz,
135159
+ Db as fu,
135160
+ Pz as fv,
135161
+ nQ1 as fw,
135162
+ oQ1 as fx,
135163
+ hb2 as fy,
135164
+ mb2 as fz,
135162
135165
  ea as g,
135163
135166
  CG1 as g0,
135164
135167
  bJ as g1,
package/dist/ai.js CHANGED
@@ -1,6 +1,6 @@
1
- import { D as e, F as r, a as t, e as o, f as i, c as n, d as F, I as C, P as A, b as l, u as d } from "./F0CanvasPanel-CxrYr5OJ.js";
1
+ import { D as e, F as r, a as t, e as o, f as i, c as n, d as F, I as C, P as A, b as l, u as d } from "./F0CanvasPanel-EblUp6hE.js";
2
2
  import { defaultTranslations as m } from "./i18n-provider-defaults.js";
3
- import { A as c, C as I, h as P, t as v, v as f, x as p, n as T, j as g, r as y, y as S, q as x, s as H, k as V, e as b, g as k, l as w, F as M, i as O, a as D, p as j, m as q, o as z, b as B, f as E, w as L, c as R, d as G, u as J } from "./useChatHistory-CqUmb2mH.js";
3
+ import { A as c, C as I, h as P, t as v, v as f, x as p, n as T, j as g, r as y, y as S, q as x, s as H, k as V, e as b, g as k, l as w, F as M, i as O, a as D, p as j, m as q, o as z, b as B, f as E, w as L, c as R, d as G, u as J } from "./useChatHistory-BhrZJXVe.js";
4
4
  export {
5
5
  c as AiChatTranslationsProvider,
6
6
  I as ChatSpinner,
@@ -37,6 +37,7 @@ import { DotTagCellValue as DotTagCellValue_2 } from './experimental';
37
37
  import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
38
38
  import { Editor } from '@tiptap/react';
39
39
  import { EmployeeItemProps } from './types';
40
+ import { F0NumberInputProps as F0NumberInputProps_2 } from './F0NumberInput';
40
41
  import { F0SegmentedControlProps as F0SegmentedControlProps_2 } from './types';
41
42
  import { F0SelectProps as F0SelectProps_2 } from './types';
42
43
  import { F0TagBalanceProps as F0TagBalanceProps_2 } from './types';
@@ -44,6 +45,8 @@ import { F0TagCompanyProps } from './types';
44
45
  import { F0TagPersonProps } from './types';
45
46
  import { F0TagRawProps as F0TagRawProps_2 } from './types';
46
47
  import { F0TagTeamProps } from './types';
48
+ import { F0TextAreaInputProps as F0TextAreaInputProps_2 } from './F0TextAreaInput';
49
+ import { F0TextInputProps as F0TextInputProps_2 } from './F0TextInput';
47
50
  import { f1Colors } from '@factorialco/f0-core';
48
51
  import { FC } from 'react';
49
52
  import { FileCellValue } from './types/file';
@@ -58,6 +61,7 @@ import { HTMLAttributes } from 'react';
58
61
  import { HTMLInputTypeAttribute } from 'react';
59
62
  import { IconCellValue } from './types/icon';
60
63
  import { InFilterOptions } from './InFilter/types';
64
+ import { InputFieldProps as InputFieldProps_2 } from './experimental';
61
65
  import { ItemProps } from './types';
62
66
  import { JSONContent } from '@tiptap/react';
63
67
  import { JSONContent as JSONContent_2 } from '@tiptap/core';
@@ -4376,6 +4380,38 @@ declare type F0Message = {
4376
4380
  [key: string]: any;
4377
4381
  };
4378
4382
 
4383
+ /**
4384
+ * @experimental This is an experimental component, use it at your own risk.
4385
+ *
4386
+ * F0NumberInput is the writable numeric field for forms — a box where the
4387
+ * user types a number. For arbitrary text use F0TextInput; for durations
4388
+ * (hours/minutes) use F0DurationInput.
4389
+ */
4390
+ export declare const F0NumberInput: (props: F0NumberInputProps) => JSX_2.Element;
4391
+
4392
+ export declare type F0NumberInputProps = Omit<NumberInputInternalProps, (typeof privateProps_4)[number]>;
4393
+
4394
+ /**
4395
+ * @experimental This is an experimental component, use it at your own risk.
4396
+ *
4397
+ * F0SearchInput is the writable search field — a single-line text input
4398
+ * pre-configured with a search icon, `role="searchbox"`, debouncing, and
4399
+ * an optional minimum-length threshold before emitting changes.
4400
+ */
4401
+ export declare const F0SearchInput: ForwardRefExoticComponent< {
4402
+ value?: string;
4403
+ threshold?: number;
4404
+ debounceTime?: number;
4405
+ autoFocus?: boolean;
4406
+ } & Pick<InputFieldProps<string>, "onChange" | "name" | "size" | "onFocus" | "onBlur" | "loading" | "disabled" | "placeholder" | "clearable"> & RefAttributes<HTMLInputElement>>;
4407
+
4408
+ export declare type F0SearchInputProps = {
4409
+ value?: string;
4410
+ threshold?: number;
4411
+ debounceTime?: number;
4412
+ autoFocus?: boolean;
4413
+ } & Pick<InputFieldProps<string>, "size" | "loading" | "clearable" | "placeholder" | "disabled" | "onBlur" | "onFocus" | "onChange" | "name">;
4414
+
4379
4415
  /**
4380
4416
  * @experimental This is an experimental component, use it at your own risk.
4381
4417
  */
@@ -4662,6 +4698,29 @@ declare interface F0TagStatusProps {
4662
4698
 
4663
4699
  declare const F0TagTeam: WithDataTestIdReturnType_5<ForwardRefExoticComponent<F0TagTeamProps & RefAttributes<HTMLDivElement>>>;
4664
4700
 
4701
+ /**
4702
+ * @experimental This is an experimental component, use it at your own risk.
4703
+ *
4704
+ * F0TextAreaInput is the writable multi-line text field for forms — a box
4705
+ * where the user types longer text spanning multiple lines. For a single
4706
+ * line of text use F0TextInput.
4707
+ */
4708
+ export declare const F0TextAreaInput: FC<F0TextAreaInputProps>;
4709
+
4710
+ 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">;
4711
+
4712
+ /**
4713
+ * @experimental This is an experimental component, use it at your own risk.
4714
+ *
4715
+ * F0TextInput is the writable text field for forms — a box where the user
4716
+ * types text, numbers (as text), passwords, emails, etc. It is the canonical
4717
+ * "text input" of F0. For numeric or duration data prefer F0NumberInput or
4718
+ * F0DurationInput respectively.
4719
+ */
4720
+ export declare const F0TextInput: <T extends string>(props: F0TextInputProps<T>) => JSX_2.Element;
4721
+
4722
+ export declare type F0TextInputProps<T extends string> = Omit<InputInternalProps<T>, (typeof privateProps_3)[number]>;
4723
+
4665
4724
  /**
4666
4725
  * Loose message shape used inside f0. Mirrors the CopilotKit `Message`
4667
4726
  * shape so adapters (factorial, mock runtime) can map back and forth
@@ -4692,14 +4751,22 @@ export declare interface F0VersionHistoryProps {
4692
4751
  }
4693
4752
 
4694
4753
  /**
4695
- * @experimental This is an experimental component use it at your own risk
4754
+ * @deprecated Renamed to `F0SearchInput` to match the F0 input vocabulary
4755
+ * (any component where the user types in a box has the `Input` suffix and
4756
+ * lives under the `Inputs/` group). The `F1` prefix was also legacy. Will
4757
+ * be removed once consumers have migrated.
4758
+ *
4759
+ * - import { F1SearchBox } from "@factorialco/f0-react"
4760
+ * + import { F0SearchInput } from "@factorialco/f0-react"
4761
+ *
4762
+ * @removeIn 2.0.0
4696
4763
  */
4697
4764
  export declare const F1SearchBox: ForwardRefExoticComponent< {
4698
4765
  value?: string;
4699
4766
  threshold?: number;
4700
4767
  debounceTime?: number;
4701
4768
  autoFocus?: boolean;
4702
- } & Pick<InputFieldProps<string>, "onChange" | "name" | "size" | "onFocus" | "onBlur" | "loading" | "disabled" | "placeholder" | "clearable"> & RefAttributes<HTMLInputElement>>;
4769
+ } & Pick<InputFieldProps_2<string>, "onChange" | "name" | "size" | "onFocus" | "onBlur" | "loading" | "disabled" | "placeholder" | "clearable"> & RefAttributes<HTMLInputElement>>;
4703
4770
 
4704
4771
  declare type FavoriteMenuItem = ({
4705
4772
  type: "icon";
@@ -5300,9 +5367,17 @@ export declare type InfiniteScrollPaginatedResponse<TRecord> = BasePaginatedResp
5300
5367
  };
5301
5368
 
5302
5369
  /**
5303
- * @experimental This is an experimental component use it at your own risk
5370
+ * @deprecated Renamed to `F0TextInput` to match the F0 input vocabulary
5371
+ * (any component where the user types text in a box has the `Input` suffix
5372
+ * and lives under the `Inputs/` group). Will be removed once consumers have
5373
+ * migrated. Update your imports:
5374
+ *
5375
+ * - import { Input } from "@factorialco/f0-react"
5376
+ * + import { F0TextInput } from "@factorialco/f0-react"
5377
+ *
5378
+ * @removeIn 2.0.0
5304
5379
  */
5305
- export declare const Input: <T extends string>(props: InputProps<T>) => JSX_2.Element;
5380
+ export declare const Input: <T extends string>(props: F0TextInputProps_2<T>) => JSX_2.Element;
5306
5381
 
5307
5382
  declare const Input_2: React_2.ForwardRefExoticComponent<Omit<React_2.InputHTMLAttributes<HTMLInputElement>, "onChange" | "size"> & Pick<InputFieldProps<string>, "label" | "onChange" | "size" | "icon" | "role" | "onFocus" | "onBlur" | "transparent" | "status" | "loading" | "disabled" | "maxLength" | "required" | "error" | "append" | "hideLabel" | "hint" | "labelIcon" | "onClickContent" | "readonly" | "clearable" | "autocomplete" | "onClear" | "isEmpty" | "emptyValue" | "hideMaxLength" | "appendTag" | "lengthProvider" | "buttonToggle"> & React_2.RefAttributes<HTMLInputElement>>;
5308
5383
 
@@ -5400,7 +5475,11 @@ declare type InputInternalProps<T extends string> = Pick<ComponentProps<typeof I
5400
5475
  onPressEnter?: () => void;
5401
5476
  };
5402
5477
 
5403
- export declare type InputProps<T extends string> = Omit<InputInternalProps<T>, (typeof privateProps_3)[number]>;
5478
+ /**
5479
+ * @deprecated Renamed to `F0TextInputProps`. See the `Input` deprecation note.
5480
+ * @removeIn 2.0.0
5481
+ */
5482
+ export declare type InputProps<T extends string> = F0TextInputProps_2<T>;
5404
5483
 
5405
5484
  declare interface InsertAfterNotesTextEditorPageDocumentPatch {
5406
5485
  type: "insert_after";
@@ -5981,7 +6060,18 @@ declare type NumberFilterValue = {
5981
6060
  };
5982
6061
  } | undefined;
5983
6062
 
5984
- export declare const NumberInput: (props: NumberInputProps) => JSX_2.Element;
6063
+ /**
6064
+ * @deprecated Renamed to `F0NumberInput` to match the F0 input vocabulary
6065
+ * (any component where the user types in a box has the `Input` suffix and
6066
+ * lives under the `Inputs/` group). Will be removed once consumers have
6067
+ * migrated.
6068
+ *
6069
+ * - import { NumberInput } from "@factorialco/f0-react"
6070
+ * + import { F0NumberInput } from "@factorialco/f0-react"
6071
+ *
6072
+ * @removeIn 2.0.0
6073
+ */
6074
+ export declare const NumberInput: (props: F0NumberInputProps_2) => JSX_2.Element;
5985
6075
 
5986
6076
  declare type NumberInputInternalProps = Omit<InputInternalProps<string>, "value" | "type" | "onChange"> & {
5987
6077
  locale: string;
@@ -6012,7 +6102,12 @@ export declare interface NumberInputPopoverConfig {
6012
6102
  };
6013
6103
  }
6014
6104
 
6015
- export declare type NumberInputProps = Omit<NumberInputInternalProps, (typeof privateProps_4)[number]>;
6105
+ /**
6106
+ * @deprecated Renamed to `F0NumberInputProps`. See the `NumberInput`
6107
+ * deprecation note.
6108
+ * @removeIn 2.0.0
6109
+ */
6110
+ export declare type NumberInputProps = F0NumberInputProps_2;
6016
6111
 
6017
6112
  declare type Numeric = NumericValue | number | undefined | null;
6018
6113
 
@@ -7799,9 +7894,17 @@ declare type TeamAvatarVariant = Extract<AvatarVariant, {
7799
7894
  declare type TeamTagProps = ComponentProps<typeof F0TagTeam>;
7800
7895
 
7801
7896
  /**
7802
- * @experimental This is an experimental component use it at your own risk
7897
+ * @deprecated Renamed to `F0TextAreaInput` to match the F0 input vocabulary
7898
+ * (any component where the user types in a box has the `Input` suffix and
7899
+ * lives under the `Inputs/` group). Will be removed once consumers have
7900
+ * migrated.
7901
+ *
7902
+ * - import { Textarea } from "@factorialco/f0-react"
7903
+ * + import { F0TextAreaInput } from "@factorialco/f0-react"
7904
+ *
7905
+ * @removeIn 2.0.0
7803
7906
  */
7804
- export declare const Textarea: FC<TextareaProps>;
7907
+ export declare const Textarea: FC<F0TextAreaInputProps_2>;
7805
7908
 
7806
7909
  declare const Textarea_2: ForwardRefExoticComponent<Omit<TextareaHTMLAttributes<HTMLTextAreaElement>, "value" | "onChange" | "onFocus" | "onBlur"> & {
7807
7910
  value?: string;
@@ -7809,7 +7912,12 @@ value?: string;
7809
7912
  maxHeight?: number;
7810
7913
  } & Pick<InputFieldProps<string>, "label" | "value" | "onChange" | "size" | "icon" | "onFocus" | "onBlur" | "onKeyDown" | "status" | "loading" | "maxLength" | "placeholder" | "required" | "error" | "hideLabel" | "hint" | "labelIcon" | "clearable" | "onClear"> & RefAttributes<HTMLTextAreaElement>>;
7811
7914
 
7812
- export declare type TextareaProps = 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">;
7915
+ /**
7916
+ * @deprecated Renamed to `F0TextAreaInputProps`. See the `Textarea`
7917
+ * deprecation note.
7918
+ * @removeIn 2.0.0
7919
+ */
7920
+ export declare type TextareaProps = F0TextAreaInputProps_2;
7813
7921
 
7814
7922
  export declare type TOCItem<Depth extends 1 | 2 | 3 | 4 = 1> = BaseTOCItem & {
7815
7923
  children?: NextDepth<Depth> extends never ? never : TOCItem<NextDepth<Depth>>[];