@vicinae/api 0.16.5 → 0.16.6

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.
Files changed (69) hide show
  1. package/README.md +1 -1
  2. package/dist/api/ai.d.ts +4 -1
  3. package/dist/api/ai.js +3 -0
  4. package/dist/api/alert.d.ts +6 -0
  5. package/dist/api/alert.js +18 -11
  6. package/dist/api/bus.d.ts +5 -0
  7. package/dist/api/bus.js +2 -0
  8. package/dist/api/cache.d.ts +5 -0
  9. package/dist/api/cache.js +2 -0
  10. package/dist/api/clipboard.d.ts +5 -0
  11. package/dist/api/clipboard.js +5 -0
  12. package/dist/api/color.d.ts +9 -0
  13. package/dist/api/color.js +3 -0
  14. package/dist/api/components/action-pannel.d.ts +32 -20
  15. package/dist/api/components/action-pannel.js +3 -0
  16. package/dist/api/components/actions.d.ts +76 -47
  17. package/dist/api/components/actions.js +3 -0
  18. package/dist/api/components/detail.d.ts +33 -8
  19. package/dist/api/components/detail.js +3 -0
  20. package/dist/api/components/form.d.ts +33 -28
  21. package/dist/api/components/form.js +3 -0
  22. package/dist/api/components/grid.d.ts +55 -0
  23. package/dist/api/components/grid.js +12 -0
  24. package/dist/api/components/index.d.ts +1 -1
  25. package/dist/api/components/index.js +3 -1
  26. package/dist/api/components/list.d.ts +159 -16
  27. package/dist/api/components/list.js +5 -2
  28. package/dist/api/components/menu-bar.d.ts +3 -0
  29. package/dist/api/components/menu-bar.js +3 -0
  30. package/dist/api/components/metadata.d.ts +5 -1
  31. package/dist/api/components/metadata.js +13 -1
  32. package/dist/api/context/navigation-provider.d.ts +3 -0
  33. package/dist/api/context/navigation-provider.js +3 -0
  34. package/dist/api/controls.d.ts +14 -0
  35. package/dist/api/controls.js +14 -1
  36. package/dist/api/environment.d.ts +11 -0
  37. package/dist/api/environment.js +11 -0
  38. package/dist/api/file-search.d.ts +1 -0
  39. package/dist/api/file-search.js +1 -0
  40. package/dist/api/hooks/index.d.ts +0 -1
  41. package/dist/api/hooks/index.js +0 -1
  42. package/dist/api/hooks/use-imperative-form-handle.d.ts +3 -3
  43. package/dist/api/hooks/use-imperative-form-handle.js +2 -2
  44. package/dist/api/hooks/use-navigation.d.ts +6 -0
  45. package/dist/api/hooks/use-navigation.js +6 -0
  46. package/dist/api/icon.d.ts +3 -0
  47. package/dist/api/icon.js +3 -0
  48. package/dist/api/image.d.ts +11 -1
  49. package/dist/api/image.js +3 -0
  50. package/dist/api/index.d.ts +2 -2
  51. package/dist/api/index.js +5 -2
  52. package/dist/api/keyboard.d.ts +9 -0
  53. package/dist/api/keyboard.js +3 -0
  54. package/dist/api/local-storage.d.ts +8 -7
  55. package/dist/api/local-storage.js +17 -8
  56. package/dist/api/oauth.d.ts +11 -9
  57. package/dist/api/oauth.js +19 -0
  58. package/dist/api/preference.d.ts +8 -0
  59. package/dist/api/preference.js +8 -0
  60. package/dist/api/toast.d.ts +8 -0
  61. package/dist/api/toast.js +8 -0
  62. package/dist/api/utils.d.ts +24 -2
  63. package/dist/api/utils.js +21 -2
  64. package/dist/api/window-management.d.ts +1 -1
  65. package/dist/api/window-management.js +1 -1
  66. package/package.json +3 -3
  67. package/types/jsx.d.ts +1 -1
  68. package/dist/api/hooks/use-applications.d.ts +0 -2
  69. package/dist/api/hooks/use-applications.js +0 -19
package/README.md CHANGED
@@ -7,7 +7,7 @@ This package lets you extend the [Vicinae](https://docs.vicinae.com/) launcher u
7
7
 
8
8
  The recommend way to start developing a new extension is to [read the docs](https://docs.vicinae.com/extensions/introduction).
9
9
 
10
- The full API reference (expect breaking changes) can be found [here](./docs/README.md).
10
+ The full API reference (expect breaking changes) can be found [here](https://api-reference.vicinae.com).
11
11
 
12
12
  # Installation
13
13
 
package/dist/api/ai.d.ts CHANGED
@@ -1,4 +1,7 @@
1
- import { ImageLike } from "./image";
1
+ import type { ImageLike } from "./image";
2
+ /**
3
+ @ignore - we don't support AI yet
4
+ */
2
5
  export declare namespace AI {
3
6
  /**
4
7
  * Returns a prompt completion.
package/dist/api/ai.js CHANGED
@@ -1,6 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AI = void 0;
4
+ /**
5
+ @ignore - we don't support AI yet
6
+ */
4
7
  var AI;
5
8
  (function (AI) {
6
9
  /**
@@ -1,4 +1,7 @@
1
1
  import { Image } from "./image";
2
+ /**
3
+ * @category Alert
4
+ */
2
5
  export declare namespace Alert {
3
6
  type Options = {
4
7
  title: string;
@@ -19,4 +22,7 @@ export declare namespace Alert {
19
22
  onAction?: () => void;
20
23
  };
21
24
  }
25
+ /**
26
+ * @category Alert
27
+ */
22
28
  export declare const confirmAlert: (options: Alert.Options) => Promise<boolean>;
package/dist/api/alert.js CHANGED
@@ -4,6 +4,9 @@ exports.confirmAlert = exports.Alert = void 0;
4
4
  const bus_1 = require("./bus");
5
5
  const image_1 = require("./image");
6
6
  const ui_1 = require("./proto/ui");
7
+ /**
8
+ * @category Alert
9
+ */
7
10
  var Alert;
8
11
  (function (Alert) {
9
12
  let ActionStyle;
@@ -18,8 +21,11 @@ const styleMap = {
18
21
  [Alert.ActionStyle.Destructive]: ui_1.ConfirmAlertActionStyle.Destructive,
19
22
  [Alert.ActionStyle.Cancel]: ui_1.ConfirmAlertActionStyle.Cancel,
20
23
  };
24
+ /**
25
+ * @category Alert
26
+ */
21
27
  const confirmAlert = async (options) => {
22
- return new Promise(async (resolve) => {
28
+ return new Promise((resolve) => {
23
29
  const req = ui_1.ConfirmAlertRequest.create({
24
30
  title: options.title,
25
31
  description: options.message ?? "Are you sure?",
@@ -34,16 +40,17 @@ const confirmAlert = async (options) => {
34
40
  style: styleMap[options.dismissAction?.style ?? Alert.ActionStyle.Cancel],
35
41
  },
36
42
  });
37
- const res = await bus_1.bus.turboRequest("ui.confirmAlert", req);
38
- if (!res.ok)
39
- return false;
40
- if (res.value.confirmed) {
41
- options.primaryAction?.onAction?.();
42
- }
43
- else {
44
- options.dismissAction?.onAction?.();
45
- }
46
- resolve(res.value.confirmed);
43
+ bus_1.bus.turboRequest("ui.confirmAlert", req).then((res) => {
44
+ if (!res.ok)
45
+ return false;
46
+ if (res.value.confirmed) {
47
+ options.primaryAction?.onAction?.();
48
+ }
49
+ else {
50
+ options.dismissAction?.onAction?.();
51
+ }
52
+ resolve(res.value.confirmed);
53
+ });
47
54
  });
48
55
  };
49
56
  exports.confirmAlert = confirmAlert;
package/dist/api/bus.d.ts CHANGED
@@ -2,6 +2,9 @@ import { MessagePort } from "worker_threads";
2
2
  import * as ipc from "./proto/ipc";
3
3
  import * as extension from "./proto/extension";
4
4
  import { Result } from "./lib/result";
5
+ /**
6
+ * @ignore
7
+ */
5
8
  export type Message<T = Record<string, any>> = {
6
9
  envelope: {
7
10
  id: string;
@@ -108,6 +111,8 @@ declare class Bus {
108
111
  private request2;
109
112
  }
110
113
  /**
114
+ * @ignore
115
+ *
111
116
  * IPC bus to communicate with the extension manager.
112
117
  * If you are using this from inside your extension, you are WRONG and you should stop.
113
118
  */
package/dist/api/bus.js CHANGED
@@ -183,6 +183,8 @@ class Bus {
183
183
  }
184
184
  }
185
185
  /**
186
+ * @ignore
187
+ *
186
188
  * IPC bus to communicate with the extension manager.
187
189
  * If you are using this from inside your extension, you are WRONG and you should stop.
188
190
  */
@@ -1,3 +1,6 @@
1
+ /**
2
+ * @category Cache
3
+ */
1
4
  export declare namespace Cache {
2
5
  /**
3
6
  * The options for creating a new {@link Cache}.
@@ -28,6 +31,8 @@ export declare namespace Cache {
28
31
  * No calls to internal Vicinae APIs are required, hence why all methods in this class are synchronous.
29
32
  * Another major difference is that cache data is not encrypted, so it's not suitable to store secrets.
30
33
  * (local storage currently isn't either, but that will change in the future)
34
+ *
35
+ * @category Cache
31
36
  */
32
37
  export declare class Cache {
33
38
  constructor(options?: Cache.Options);
package/dist/api/cache.js CHANGED
@@ -18,6 +18,8 @@ const environment_1 = require("./environment");
18
18
  * No calls to internal Vicinae APIs are required, hence why all methods in this class are synchronous.
19
19
  * Another major difference is that cache data is not encrypted, so it's not suitable to store secrets.
20
20
  * (local storage currently isn't either, but that will change in the future)
21
+ *
22
+ * @category Cache
21
23
  */
22
24
  class Cache {
23
25
  constructor(options) {
@@ -1,4 +1,9 @@
1
1
  import { PathLike } from "fs";
2
+ /**
3
+ * Access system clipboard and clipboard history features.
4
+ *
5
+ * @category Clipboard
6
+ */
2
7
  export declare namespace Clipboard {
3
8
  type Content = {
4
9
  text: string;
@@ -3,6 +3,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Clipboard = void 0;
4
4
  const bus_1 = require("./bus");
5
5
  const clipboard_1 = require("./proto/clipboard");
6
+ /**
7
+ * Access system clipboard and clipboard history features.
8
+ *
9
+ * @category Clipboard
10
+ */
6
11
  var Clipboard;
7
12
  (function (Clipboard) {
8
13
  function mapContent(content) {
@@ -4,10 +4,16 @@ type DynamicColor = {
4
4
  light: string;
5
5
  adjustContrast?: boolean;
6
6
  };
7
+ /**
8
+ * @category Colors
9
+ */
7
10
  export declare namespace Color {
8
11
  type Dynamic = DynamicColor;
9
12
  type Raw = string;
10
13
  }
14
+ /**
15
+ * @category Colors
16
+ */
11
17
  export declare enum Color {
12
18
  Blue = "blue",
13
19
  Green = "green",
@@ -19,6 +25,9 @@ export declare enum Color {
19
25
  PrimaryText = "primary-text",
20
26
  SecondaryText = "secondary-text"
21
27
  }
28
+ /**
29
+ * @category Colors
30
+ */
22
31
  export type ColorLike = Color.Dynamic | Color.Raw | Color;
23
32
  export type SerializedColorLike = ui.ColorLike;
24
33
  export declare const serializeColorLike: (color: ColorLike) => SerializedColorLike;
package/dist/api/color.js CHANGED
@@ -35,6 +35,9 @@ var __importStar = (this && this.__importStar) || (function () {
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.serializeColorLike = exports.Color = void 0;
37
37
  const ui = __importStar(require("./proto/ui"));
38
+ /**
39
+ * @category Colors
40
+ */
38
41
  var Color;
39
42
  (function (Color) {
40
43
  Color["Blue"] = "blue";
@@ -1,23 +1,35 @@
1
1
  import type { ReactNode } from "react";
2
- import { type Image } from "../image";
3
2
  import type { Keyboard } from "../keyboard";
4
- export type ActionPanelProps = {
5
- title?: string;
6
- children?: ReactNode;
7
- };
8
- export type ActionPanelSectionProps = {
9
- title?: string;
10
- children?: ReactNode;
11
- };
12
- export type ActionPanelSubmenuProps = {
13
- title: string;
14
- icon?: Image.ImageLike;
15
- shortcut?: Keyboard.Shortcut;
16
- onOpen?: () => void;
17
- onSearchTextChange?: (text: string) => void;
18
- children: ReactNode;
19
- };
20
- export declare const ActionPanel: import("react").FC<ActionPanelProps> & {
21
- Section: import("react").FC<import("react").PropsWithChildren<ActionPanelSectionProps>>;
22
- Submenu: import("react").FC<ActionPanelSubmenuProps>;
3
+ import { type Image } from "../image";
4
+ /**
5
+ * @category Actions
6
+ */
7
+ export declare namespace ActionPanel {
8
+ type Props = {
9
+ title?: string;
10
+ children?: ReactNode;
11
+ };
12
+ namespace Section {
13
+ type Props = {
14
+ title?: string;
15
+ children?: ReactNode;
16
+ };
17
+ }
18
+ namespace Submenu {
19
+ type Props = {
20
+ title: string;
21
+ icon?: Image.ImageLike;
22
+ shortcut?: Keyboard.Shortcut;
23
+ onOpen?: () => void;
24
+ onSearchTextChange?: (text: string) => void;
25
+ children: ReactNode;
26
+ };
27
+ }
28
+ }
29
+ /**
30
+ * @category Actions
31
+ */
32
+ export declare const ActionPanel: import("react").FC<ActionPanel.Props> & {
33
+ Section: import("react").FC<import("react").PropsWithChildren<ActionPanel.Section.Props>>;
34
+ Submenu: import("react").FC<ActionPanel.Submenu.Props>;
23
35
  };
@@ -17,6 +17,9 @@ const ActionPannelSubmenu = ({ children, icon, ...props }) => {
17
17
  const serializedIcon = icon ? (0, image_1.serializeProtoImage)(icon) : icon;
18
18
  return ((0, jsx_runtime_1.jsx)("action-panel-submenu", { ...props, icon: serializedIcon, children: children }));
19
19
  };
20
+ /**
21
+ * @category Actions
22
+ */
20
23
  exports.ActionPanel = Object.assign(ActionPanelRoot, {
21
24
  Section: ActionPanelSection,
22
25
  Submenu: ActionPannelSubmenu,
@@ -2,11 +2,11 @@ import React, { ReactNode } from "react";
2
2
  import type { PathLike } from "node:fs";
3
3
  import { Clipboard } from "../clipboard";
4
4
  import { type ImageLike } from "../image";
5
- import { Keyboard } from "../keyboard";
5
+ import type { Keyboard } from "../keyboard";
6
6
  import { Application } from "../utils";
7
- import { Form } from "./form";
7
+ import type { Form } from "./form";
8
8
  import { Icon } from "../icon";
9
- export type BaseActionProps = {
9
+ type BaseActionProps = {
10
10
  title: string;
11
11
  icon?: ImageLike;
12
12
  /**
@@ -18,61 +18,90 @@ export type BaseActionProps = {
18
18
  autoFocus?: boolean;
19
19
  style?: "regular" | "destructive";
20
20
  };
21
- export type ActionProps = BaseActionProps & {
21
+ type ActionProps = BaseActionProps & {
22
22
  onAction: () => void;
23
23
  };
24
- export type CopyToClipboardProps = Omit<BaseActionProps, "title"> & {
25
- content: string;
26
- concealed?: boolean;
27
- onCopy?: (content: string | number | Clipboard.Content) => void;
28
- title?: string;
29
- };
30
- export type ActionPushProps = BaseActionProps & {
31
- target: ReactNode;
32
- };
33
- export type ActionOpenProps = BaseActionProps & {
34
- target: string;
35
- app?: Application;
36
- };
37
- export type ActionPasteProps = BaseActionProps & {
38
- content: string;
39
- onPaste?: (content: string | number | Clipboard.Content) => void;
40
- };
41
- export type ActionOpenInBrowserProps = BaseActionProps & {
42
- url: string;
43
- };
44
- export type ActionShowInFinderProps = {
45
- path: PathLike;
46
- icon?: ImageLike;
47
- onShow?: (path: PathLike) => void;
48
- shortcut?: Keyboard.Shortcut;
49
- title?: string;
50
- };
51
- export type ActionSubmitFormProps = Omit<BaseActionProps, "title"> & {
52
- onSubmit: (input: Form.Values) => boolean | void | Promise<boolean | void>;
53
- title?: string;
54
- };
24
+ /**
25
+ * Actions that can be used as part of an {@link ActionPanel}
26
+ *
27
+ * Most actions are just simple wrappers around the base {@link Action}. For any custom need, use that.
28
+ *
29
+ * @category Actions
30
+ */
31
+ export declare namespace Action {
32
+ namespace CopyToClipboard {
33
+ type Props = Omit<BaseActionProps, "title"> & {
34
+ content: string;
35
+ concealed?: boolean;
36
+ onCopy?: (content: string | number | Clipboard.Content) => void;
37
+ title?: string;
38
+ };
39
+ }
40
+ namespace Push {
41
+ type Props = BaseActionProps & {
42
+ target: ReactNode;
43
+ };
44
+ }
45
+ namespace Open {
46
+ type Props = BaseActionProps & {
47
+ target: string;
48
+ app?: Application;
49
+ };
50
+ }
51
+ namespace Paste {
52
+ type Props = BaseActionProps & {
53
+ content: string;
54
+ onPaste?: (content: string | number | Clipboard.Content) => void;
55
+ };
56
+ }
57
+ namespace OpenInBrowser {
58
+ type Props = BaseActionProps & {
59
+ url: string;
60
+ };
61
+ }
62
+ namespace ShowInFinderProps {
63
+ type Props = {
64
+ path: PathLike;
65
+ icon?: ImageLike;
66
+ onShow?: (path: PathLike) => void;
67
+ shortcut?: Keyboard.Shortcut;
68
+ title?: string;
69
+ };
70
+ }
71
+ namespace SubmitForm {
72
+ type Props = Omit<BaseActionProps, "title"> & {
73
+ onSubmit: (input: Form.Values) => boolean | void | Promise<boolean | void>;
74
+ title?: string;
75
+ };
76
+ }
77
+ namespace CreateQuicklink {
78
+ type Props = Omit<BaseActionProps, "title"> & {
79
+ title?: string;
80
+ quicklink: Quicklink;
81
+ };
82
+ }
83
+ }
55
84
  export type Quicklink = {
56
85
  name?: string;
57
86
  link: string;
58
87
  application?: string | Application;
59
88
  icon?: Icon;
60
89
  };
61
- export type ActionCreateQuicklinkProps = Omit<BaseActionProps, "title"> & {
62
- title?: string;
63
- quicklink: Quicklink;
64
- };
90
+ /**
91
+ * @category Actions
92
+ */
65
93
  export declare const Action: React.FC<ActionProps> & {
66
- CopyToClipboard: React.FC<CopyToClipboardProps>;
67
- Push: React.FC<ActionPushProps>;
68
- Open: React.FC<ActionOpenProps>;
69
- Paste: React.FC<ActionPasteProps>;
70
- SubmitForm: React.FC<ActionSubmitFormProps>;
71
- OpenInBrowser: React.FC<ActionOpenInBrowserProps>;
72
- ShowInFinder: React.FC<ActionShowInFinderProps>;
73
- CreateQuicklink: React.FC<ActionCreateQuicklinkProps>;
94
+ CopyToClipboard: React.FC<Action.CopyToClipboard.Props>;
95
+ Push: React.FC<Action.Push.Props>;
96
+ Open: React.FC<Action.Open.Props>;
97
+ Paste: React.FC<Action.Paste.Props>;
98
+ SubmitForm: React.FC<Action.SubmitForm.Props>;
99
+ OpenInBrowser: React.FC<Action.OpenInBrowser.Props>;
100
+ ShowInFinder: React.FC<Action.ShowInFinderProps.Props>;
101
+ CreateQuicklink: React.FC<Action.CreateQuicklink.Props>;
74
102
  Style: {
75
103
  Regular: "regular";
76
104
  Destructive: "destructive";
77
105
  };
78
106
  };
107
+ export {};
@@ -77,6 +77,9 @@ const CreateQuicklink = ({ title = "Create Quicklink", quicklink, ...props }) =>
77
77
  };
78
78
  return (0, jsx_runtime_1.jsx)("action", { ...nativeProps });
79
79
  };
80
+ /**
81
+ * @category Actions
82
+ */
80
83
  exports.Action = Object.assign(ActionRoot, {
81
84
  CopyToClipboard,
82
85
  Push,
@@ -1,11 +1,36 @@
1
- import { ReactNode } from "react";
2
- export type DetailProps = {
3
- navigationTitle?: string;
4
- metadata?: ReactNode;
5
- markdown: string;
6
- actions?: ReactNode;
7
- };
8
- export declare const Detail: import("react").FC<DetailProps> & {
1
+ import type { ReactNode } from "react";
2
+ /**
3
+ * ![](../../../assets/detail.png)
4
+ *
5
+ * A Detail component is commonly used to render markdown with an optional metadata side panel on the right.
6
+ *
7
+ * @remarks
8
+ * The markdown renderer is currently very bare bones and does not have good support for most fancy markdown features. This is actively being worked on.
9
+ *
10
+ * @example
11
+ * ```typescript
12
+ * import { Detail } from '@vicinae/api';
13
+ *
14
+ * export default function MyCommand() {
15
+ * return <Detail markdown={'# Hello world!'} />;
16
+ * }
17
+ * ```
18
+ *
19
+ * @category UI Components
20
+ * @public
21
+ */
22
+ export declare namespace Detail {
23
+ type Props = {
24
+ navigationTitle?: string;
25
+ metadata?: ReactNode;
26
+ markdown: string;
27
+ actions?: ReactNode;
28
+ };
29
+ }
30
+ /**
31
+ * @category UI Components
32
+ */
33
+ export declare const Detail: import("react").FC<Detail.Props> & {
9
34
  Metadata: import("react").FC<import("./metadata").MetadataProps> & {
10
35
  Label: import("react").FC<import("./metadata").ListItemDetailMetadataLabelProps>;
11
36
  Separator: import("react").FC<{}>;
@@ -7,6 +7,9 @@ const DetailRoot = ({ metadata, actions, ...props }) => {
7
7
  const nativeProps = props;
8
8
  return ((0, jsx_runtime_1.jsxs)("detail", { ...nativeProps, children: [actions, metadata] }));
9
9
  };
10
+ /**
11
+ * @category UI Components
12
+ */
10
13
  exports.Detail = Object.assign(DetailRoot, {
11
14
  Metadata: metadata_1.Metadata,
12
15
  });
@@ -1,14 +1,33 @@
1
- import { ReactNode, Ref } from "react";
1
+ import type { ReactNode, Ref } from "react";
2
2
  import { type ImageLike } from "../image";
3
- type FormProps = {
4
- actions?: React.ReactNode;
5
- children?: React.ReactNode;
6
- enableDrafts?: boolean;
7
- isLoading?: boolean;
8
- navigationTitle?: string;
9
- searchBarAccessory?: React.ReactNode;
10
- };
11
- export type FormItemRef = {
3
+ /**
4
+ * @category UI Components
5
+ */
6
+ export declare namespace Form {
7
+ type Props = {
8
+ actions?: React.ReactNode;
9
+ children?: React.ReactNode;
10
+ enableDrafts?: boolean;
11
+ isLoading?: boolean;
12
+ navigationTitle?: string;
13
+ searchBarAccessory?: React.ReactNode;
14
+ };
15
+ type TextField = FormItemRef;
16
+ type PasswordField = FormItemRef;
17
+ type TextArea = FormItemRef;
18
+ type Checkbox = FormItemRef;
19
+ type DatePicker = FormItemRef;
20
+ type Dropdown = FormItemRef;
21
+ type TagPicker = FormItemRef;
22
+ type FilePicker = FormItemRef;
23
+ type ItemReference = FormItemRef;
24
+ type ItemProps<T extends Value> = FormItemProps<T>;
25
+ type Value = string | number | boolean | string[] | number[] | Date | null;
26
+ type Values = {
27
+ [itemId: string]: Value;
28
+ };
29
+ }
30
+ type FormItemRef = {
12
31
  focus: () => void;
13
32
  reset: () => void;
14
33
  };
@@ -33,23 +52,6 @@ interface FormEvent<T extends Form.Value> {
33
52
  type: FormEventType;
34
53
  }
35
54
  type FormEventType = "focus" | "blur";
36
- export declare namespace Form {
37
- type Props = FormProps;
38
- type TextField = FormItemRef;
39
- type PasswordField = FormItemRef;
40
- type TextArea = FormItemRef;
41
- type Checkbox = FormItemRef;
42
- type DatePicker = FormItemRef;
43
- type Dropdown = FormItemRef;
44
- type TagPicker = FormItemRef;
45
- type FilePicker = FormItemRef;
46
- type ItemReference = FormItemRef;
47
- type ItemProps<T extends Value> = FormItemProps<T>;
48
- type Value = string | number | boolean | string[] | number[] | Date | null;
49
- type Values = {
50
- [itemId: string]: Value;
51
- };
52
- }
53
55
  interface WithFormRef<T> {
54
56
  ref?: Ref<T>;
55
57
  }
@@ -93,7 +95,10 @@ type DescriptionProps = {
93
95
  text: string;
94
96
  title?: string;
95
97
  };
96
- export declare const Form: import("react").FC<FormProps> & {
98
+ /**
99
+ * @category UI Components
100
+ */
101
+ export declare const Form: import("react").FC<Form.Props> & {
97
102
  TextField: import("react").FC<TextFieldProps>;
98
103
  PasswordField: import("react").FC<PasswordFieldProps>;
99
104
  DatePicker: import("react").FC<DatePickerProps> & {
@@ -99,6 +99,9 @@ const FilePicker = ({ ref, ...props }) => {
99
99
  const Description = (props) => {
100
100
  return (0, jsx_runtime_1.jsx)("form-description", { ...props });
101
101
  };
102
+ /**
103
+ * @category UI Components
104
+ */
102
105
  exports.Form = Object.assign(FormRoot, {
103
106
  TextField,
104
107
  PasswordField,