@baton8/general-components 3.1.0-alpha.1 → 3.1.0-alpha.3
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/components/atoms/button/button.d.ts +1 -1
- package/dist/components/atoms/iconButton/iconButton.d.ts +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/components/modules/card/cardButton.d.ts +1 -1
- package/dist/components/modules/dialog/dialog.d.ts +0 -1
- package/dist/components/modules/dialog/dialogButton.d.ts +1 -1
- package/dist/components/modules/drawer/drawer.d.ts +2 -0
- package/dist/components/modules/drawer/drawerButton.d.ts +1 -1
- package/dist/components/modules/drawer/drawerCloseButton.d.ts +13 -0
- package/dist/components/modules/drawer/drawerFooter.d.ts +0 -3
- package/dist/components/modules/drawer/index.d.ts +2 -0
- package/dist/components/modules/menu/menu.d.ts +5 -0
- package/dist/components/modules/popover/index.d.ts +1 -0
- package/dist/components/modules/popover/popover.d.ts +38 -0
- package/dist/index.js +131 -87
- package/dist/index.js.map +1 -1
- package/dist/stories/modules/drawer/drawer.stories.d.ts +2 -0
- package/dist/stories/modules/popover/popover.stories.d.ts +33 -0
- package/package.json +1 -1
|
@@ -46,7 +46,7 @@ export declare const Button: import("react").ForwardRefExoticComponent<import(".
|
|
|
46
46
|
* HTML と違ってデフォルト値が `"button"` になっているので、フォームの送信ボタンとして使う場合は明示的に `"submit"` を指定してください。
|
|
47
47
|
* @defaultValue `"button"`
|
|
48
48
|
*/
|
|
49
|
-
type?: "button" | "
|
|
49
|
+
type?: "button" | "reset" | "submit" | undefined;
|
|
50
50
|
/**
|
|
51
51
|
* 無効にするかどうか。
|
|
52
52
|
*/
|
|
@@ -38,7 +38,7 @@ export declare const IconButton: import("react").ForwardRefExoticComponent<impor
|
|
|
38
38
|
* HTML と違ってデフォルト値が `"button"` になっているので、フォームの送信ボタンとして使う場合は明示的に `"submit"` を指定してください。
|
|
39
39
|
* @defaultValue `"button"`
|
|
40
40
|
*/
|
|
41
|
-
type?: "button" | "
|
|
41
|
+
type?: "button" | "reset" | "submit" | undefined;
|
|
42
42
|
/**
|
|
43
43
|
* 無効にするかどうか。
|
|
44
44
|
*/
|
|
@@ -45,6 +45,7 @@ export * from "./modules/fractionView";
|
|
|
45
45
|
export * from "./modules/header";
|
|
46
46
|
export * from "./modules/menu";
|
|
47
47
|
export * from "./modules/pagination";
|
|
48
|
+
export * from "./modules/popover";
|
|
48
49
|
export * from "./modules/rankView";
|
|
49
50
|
export * from "./modules/stepper";
|
|
50
51
|
export * from "./modules/tabList";
|
|
@@ -26,7 +26,7 @@ export declare const CardButton: import("react").ForwardRefExoticComponent<impor
|
|
|
26
26
|
* `onClick` に文字列値が指定されていてリンクとして表示される際は、これは無視されます。
|
|
27
27
|
* @defaultValue `"button"`
|
|
28
28
|
*/
|
|
29
|
-
type?: "button" | "
|
|
29
|
+
type?: "button" | "reset" | "submit" | undefined;
|
|
30
30
|
/**
|
|
31
31
|
* ボタンを縦に伸ばすかどうか。
|
|
32
32
|
* 設定ボタン等は伸ばさない方が自然です。
|
|
@@ -40,7 +40,6 @@ type DialogProps = {
|
|
|
40
40
|
* - [`DialogTitle`](/docs/modules-Dialog-DialogTitle--ドキュメント) (任意)
|
|
41
41
|
* - [`DialogBody`](/docs/modules-Dialog-DialogBody--ドキュメント)
|
|
42
42
|
* - [`DialogFooter`](/docs/modules-Dialog-DialogFooter--ドキュメント) (任意)
|
|
43
|
-
* - [`DialogFooterButton`](/docs/modules-Dialog-DialogFooterButton--ドキュメント) (2 個まで任意)
|
|
44
43
|
*
|
|
45
44
|
* #### 使い方
|
|
46
45
|
* 非制御と制御の 2 種類の使い方があります。
|
|
@@ -15,7 +15,7 @@ export declare const DialogButton: import("react").ForwardRefExoticComponent<imp
|
|
|
15
15
|
variant?: "solid" | "light" | "underline" | "simple" | "unstyledUnderline" | "unstyledSimple" | undefined;
|
|
16
16
|
size?: "small" | "medium" | "large" | undefined;
|
|
17
17
|
isCompact?: boolean | undefined;
|
|
18
|
-
type?: "button" | "
|
|
18
|
+
type?: "button" | "reset" | "submit" | undefined;
|
|
19
19
|
isDisabled?: boolean | undefined;
|
|
20
20
|
isLoading?: boolean | undefined;
|
|
21
21
|
onClick?: ((event: import("react").MouseEvent<HTMLButtonElement, MouseEvent>) => unknown) | undefined;
|
|
@@ -30,12 +30,14 @@ type DrawerProps = CommonProps & {
|
|
|
30
30
|
* #### 構成
|
|
31
31
|
* 以下のようなコンポーネント構成で利用してください。
|
|
32
32
|
* - **`Drawer`**
|
|
33
|
+
* - [`DrawerCloseButton`](/docs/modules-Drawer-DrawerCloseButton--ドキュメント)
|
|
33
34
|
* - [`DrawerHeader`](/docs/modules-Drawer-DrawerHeader--ドキュメント) (任意)
|
|
34
35
|
* - [`DrawerHeaderLeft`](/docs/modules-Drawer-DrawerHeaderLeft--ドキュメント)
|
|
35
36
|
* - [`DrawerHeaderTitle`](/docs/modules-Drawer-DrawerHeaderTitle--ドキュメント)
|
|
36
37
|
* - [`DrawerHeaderCaption`](/docs/modules-Drawer-DrawerHeaderCaption--ドキュメント) (任意)
|
|
37
38
|
* - [`DrawerHeaderRight`](/docs/modules-Drawer-DrawerHeaderRight--ドキュメント)
|
|
38
39
|
* - [`DrawerBody`](/docs/modules-Drawer-DrawerBody--ドキュメント)
|
|
40
|
+
* - [`DrawerFooter`](/docs/modules-Drawer-DrawerFooter--ドキュメント) (任意)
|
|
39
41
|
*
|
|
40
42
|
* @group React コンポーネント
|
|
41
43
|
* @category React コンポーネント
|
|
@@ -15,7 +15,7 @@ export declare const DrawerButton: import("react").ForwardRefExoticComponent<imp
|
|
|
15
15
|
variant?: "solid" | "light" | "underline" | "simple" | "unstyledUnderline" | "unstyledSimple" | undefined;
|
|
16
16
|
size?: "small" | "medium" | "large" | undefined;
|
|
17
17
|
isCompact?: boolean | undefined;
|
|
18
|
-
type?: "button" | "
|
|
18
|
+
type?: "button" | "reset" | "submit" | undefined;
|
|
19
19
|
isDisabled?: boolean | undefined;
|
|
20
20
|
isLoading?: boolean | undefined;
|
|
21
21
|
onClick?: ((event: import("react").MouseEvent<HTMLButtonElement, MouseEvent>) => unknown) | undefined;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* @group React コンポーネント
|
|
4
|
+
* @category React コンポーネント
|
|
5
|
+
*/
|
|
6
|
+
export declare const DrawerCloseButton: import("react").ForwardRefExoticComponent<import("../../../modules/data").DataProps<string> & {
|
|
7
|
+
className?: string | undefined;
|
|
8
|
+
id?: string | undefined;
|
|
9
|
+
style?: import("react").CSSProperties | undefined;
|
|
10
|
+
} & {
|
|
11
|
+
/** */
|
|
12
|
+
className?: string | undefined;
|
|
13
|
+
} & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -2,6 +2,8 @@ export * from "./drawer";
|
|
|
2
2
|
export * from "./drawerBody";
|
|
3
3
|
export * from "./drawerButton";
|
|
4
4
|
export * from "./drawerCaption";
|
|
5
|
+
export * from "./drawerCloseButton";
|
|
6
|
+
export * from "./drawerFooter";
|
|
5
7
|
export * from "./drawerHeader";
|
|
6
8
|
export * from "./drawerHeaderLeft";
|
|
7
9
|
export * from "./drawerHeaderRight";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./popover";
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { Placement } from "@floating-ui/react";
|
|
2
|
+
import { FunctionComponent, ReactElement, ReactNode } from "react";
|
|
3
|
+
type PopoverProps = {
|
|
4
|
+
/**
|
|
5
|
+
* トリガーとなる要素。
|
|
6
|
+
* ここに要素を指定すると、そこにインタラクションがあったときにポップオーバーが表示されるようになります。
|
|
7
|
+
*/
|
|
8
|
+
trigger?: ReactElement;
|
|
9
|
+
/**
|
|
10
|
+
* トリガーの種類。
|
|
11
|
+
* @defaultValue `"click"`
|
|
12
|
+
*/
|
|
13
|
+
triggerType?: "click" | "focus" | "hover";
|
|
14
|
+
/**
|
|
15
|
+
* トリガーの持続時間 (ミリ秒単位)。
|
|
16
|
+
* @defaultValue `null`
|
|
17
|
+
*/
|
|
18
|
+
triggerRest?: number | null;
|
|
19
|
+
/**
|
|
20
|
+
* @defaultValue `false`
|
|
21
|
+
*/
|
|
22
|
+
isInline?: boolean;
|
|
23
|
+
/**
|
|
24
|
+
* ポップオーバーの位置。
|
|
25
|
+
* @defaultValue `"bottom-start"`
|
|
26
|
+
*/
|
|
27
|
+
placement?: Placement;
|
|
28
|
+
/** */
|
|
29
|
+
className?: string;
|
|
30
|
+
/** */
|
|
31
|
+
children?: ReactNode;
|
|
32
|
+
};
|
|
33
|
+
/**
|
|
34
|
+
* @group React コンポーネント
|
|
35
|
+
* @category React コンポーネント
|
|
36
|
+
*/
|
|
37
|
+
export declare const Popover: FunctionComponent<PopoverProps>;
|
|
38
|
+
export {};
|