@overmap-ai/blocks 0.0.10-alpha.5 → 0.0.12-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/dist/DropdownMenu/DropdownMenu.d.ts +9 -18
- package/dist/DropdownMenu/index.d.ts +1 -1
- package/dist/DropdownMenu/typings.d.ts +42 -0
- package/dist/Input/typings.d.ts +2 -3
- package/dist/TextArea/typings.d.ts +1 -2
- package/dist/Toast/typings.d.ts +0 -1
- package/dist/blocks.js +979 -1018
- package/dist/blocks.js.map +1 -1
- package/dist/blocks.umd.cjs +4 -4
- package/dist/blocks.umd.cjs.map +1 -1
- package/dist/index.d.ts +0 -1
- package/dist/style.css +1 -1
- package/dist/typings.d.ts +1 -1
- package/package.json +98 -98
- package/dist/IconColorUtility/IconColorUtility.d.ts +0 -17
- package/dist/IconColorUtility/index.d.ts +0 -1
package/README.md
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
# overmap-ai blocks
|
|
2
|
-
|
|
3
|
-
Contains basic components used by overmap-ai libraries.
|
|
1
|
+
# overmap-ai blocks
|
|
2
|
+
|
|
3
|
+
Contains basic components used by overmap-ai libraries.
|
|
@@ -1,21 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { Severity } from "../typings.ts";
|
|
4
|
-
export interface DropdownMenuItemProps extends Omit<ComponentProps<typeof RadixDropdownMenu.Item>, "textValue" | "asChild" | "children" | "color" | "content"> {
|
|
5
|
-
content: ReactNode;
|
|
6
|
-
closeOnSelect?: boolean;
|
|
7
|
-
separator?: boolean;
|
|
8
|
-
}
|
|
9
|
-
export interface DropdownMenuProps extends Omit<ComponentProps<typeof RadixDropdownMenu.Content>, "asChild" | "color" | "children"> {
|
|
10
|
-
severity?: Severity;
|
|
11
|
-
disabled?: boolean;
|
|
12
|
-
label?: string;
|
|
13
|
-
trigger: ReactElement;
|
|
14
|
-
items: DropdownMenuItemProps[];
|
|
15
|
-
modal?: boolean;
|
|
16
|
-
closeOnSelect?: boolean;
|
|
17
|
-
}
|
|
1
|
+
import { FC } from "react";
|
|
2
|
+
import { DropdownMenuItemGroupProps, DropdownMenuItemProps, DropdownMenuProps, DropdownSubMenuProps } from "./typings.ts";
|
|
18
3
|
/** The DropdownMenu component is a user interface element that provides a list of options for the user to choose from.
|
|
19
4
|
* It is commonly used in web applications to present a set of related choices in a compact and organized manner.
|
|
20
5
|
* This DropdownMenu component is a wrapper around the Radix-UI DropdownMenu component that can be found here https://www.radix-ui.com/themes/docs/components/dropdown-menu */
|
|
21
|
-
export declare const
|
|
6
|
+
export declare const Root: FC<DropdownMenuProps>;
|
|
7
|
+
export declare const DropdownMenu: {
|
|
8
|
+
Root: FC<DropdownMenuProps>;
|
|
9
|
+
ItemGroup: FC<DropdownMenuItemGroupProps>;
|
|
10
|
+
Item: FC<DropdownMenuItemProps>;
|
|
11
|
+
SubMenu: FC<DropdownSubMenuProps>;
|
|
12
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { DropdownMenu } from "./DropdownMenu";
|
|
2
|
-
export
|
|
2
|
+
export * from "./typings.ts";
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { DropdownMenu as RadixDropdownMenu } from "@radix-ui/themes";
|
|
2
|
+
import { ComponentProps, ReactNode } from "react";
|
|
3
|
+
import { Severity } from "../typings.ts";
|
|
4
|
+
type RadixDropdownMenuRootProps = ComponentProps<typeof RadixDropdownMenu.Root>;
|
|
5
|
+
type RadixDropdownMenuSubProps = ComponentProps<typeof RadixDropdownMenu.Sub>;
|
|
6
|
+
export interface DropdownMenuItemProps extends Omit<ComponentProps<typeof RadixDropdownMenu.Item>, "textValue"> {
|
|
7
|
+
/** content to be displayed within the DropdownMenuItem */
|
|
8
|
+
itemContent: ReactNode;
|
|
9
|
+
/** severity of the DropdownMenuItem, will overwrite any severity passed into DropdownMenu.Root */
|
|
10
|
+
severity?: Severity;
|
|
11
|
+
/** Determines if the DropdownMenu will close upon clicking the DropdownMenuItem
|
|
12
|
+
* @default true
|
|
13
|
+
* */
|
|
14
|
+
closeOnSelect?: boolean;
|
|
15
|
+
}
|
|
16
|
+
export interface DropdownMenuItemGroupProps extends Omit<ComponentProps<typeof RadixDropdownMenu.Group>, "asChild"> {
|
|
17
|
+
/** will render a separator within the DropdownMenu popover above the ItemGroup
|
|
18
|
+
* @default false
|
|
19
|
+
* */
|
|
20
|
+
separatorAbove?: boolean;
|
|
21
|
+
/** will render a separator within the DropdownMenu popover below the ItemGroup
|
|
22
|
+
* @default false
|
|
23
|
+
* */
|
|
24
|
+
separatorBelow?: boolean;
|
|
25
|
+
}
|
|
26
|
+
export interface DropdownMenuProps extends Omit<ComponentProps<typeof RadixDropdownMenu.Content>, "asChild" | "color"> {
|
|
27
|
+
defaultOpen?: RadixDropdownMenuRootProps["defaultOpen"];
|
|
28
|
+
open?: RadixDropdownMenuRootProps["open"];
|
|
29
|
+
onOpenChange?: RadixDropdownMenuRootProps["onOpenChange"];
|
|
30
|
+
modal?: RadixDropdownMenuRootProps["modal"];
|
|
31
|
+
severity?: Severity;
|
|
32
|
+
trigger: ReactNode;
|
|
33
|
+
label?: ReactNode;
|
|
34
|
+
disabled?: boolean;
|
|
35
|
+
}
|
|
36
|
+
export interface DropdownSubMenuProps extends Omit<ComponentProps<typeof RadixDropdownMenu.SubContent>, "asChild" | "color"> {
|
|
37
|
+
defaultOpen?: RadixDropdownMenuSubProps["defaultOpen"];
|
|
38
|
+
open?: RadixDropdownMenuSubProps["open"];
|
|
39
|
+
onOpenChange?: RadixDropdownMenuSubProps["onOpenChange"];
|
|
40
|
+
trigger: ReactNode;
|
|
41
|
+
}
|
|
42
|
+
export {};
|
package/dist/Input/typings.d.ts
CHANGED
|
@@ -3,12 +3,11 @@ import { Responsive, TextField as RadixTextField } from "@radix-ui/themes";
|
|
|
3
3
|
import { Severity, Size } from "../typings.ts";
|
|
4
4
|
import { MarginProps } from "@radix-ui/themes";
|
|
5
5
|
type TextFieldInputProps = React.ComponentProps<typeof RadixTextField.Input>;
|
|
6
|
-
export interface InputProps extends Omit<TextFieldInputProps, "size" | "color" | "radius" |
|
|
6
|
+
export interface InputProps extends Omit<TextFieldInputProps, "size" | "color" | "radius" | keyof MarginProps> {
|
|
7
7
|
leftSlot?: React.ReactNode;
|
|
8
8
|
rightSlot?: React.ReactNode;
|
|
9
9
|
size?: Responsive<Size>;
|
|
10
|
-
severity?: Severity
|
|
10
|
+
severity?: Exclude<Severity, "success" | "info">;
|
|
11
11
|
showInputLength?: boolean;
|
|
12
|
-
variant?: TextFieldInputProps["variant"] | "ghost";
|
|
13
12
|
}
|
|
14
13
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ComponentProps } from "react";
|
|
2
2
|
import { TextArea as RadixTextArea, MarginProps } from "@radix-ui/themes";
|
|
3
3
|
import { Severity } from "../typings.ts";
|
|
4
|
-
export interface TextAreaProps extends Omit<ComponentProps<typeof RadixTextArea>, keyof MarginProps | "color"
|
|
4
|
+
export interface TextAreaProps extends Omit<ComponentProps<typeof RadixTextArea>, keyof MarginProps | "color"> {
|
|
5
5
|
/** used to set the severity of the TextArea, supports all 5 global severities
|
|
6
6
|
* @default "primary"
|
|
7
7
|
* */
|
|
@@ -12,5 +12,4 @@ export interface TextAreaProps extends Omit<ComponentProps<typeof RadixTextArea>
|
|
|
12
12
|
showInputLength?: boolean;
|
|
13
13
|
resize: "vertical" | "horizontal" | "both";
|
|
14
14
|
inputLengthTemplate?: string;
|
|
15
|
-
variant?: ComponentProps<typeof RadixTextArea>["variant"] | "ghost";
|
|
16
15
|
}
|
package/dist/Toast/typings.d.ts
CHANGED
|
@@ -47,5 +47,4 @@ export interface IToastContext {
|
|
|
47
47
|
showSuccess: (simpleMessage: SimpleToastProps) => void;
|
|
48
48
|
showInfo: (simpleMessage: SimpleToastProps) => void;
|
|
49
49
|
showError: (simpleMessage: SimpleToastProps) => void;
|
|
50
|
-
showWarning: (simpleMessage: SimpleToastProps) => void;
|
|
51
50
|
}
|