ingred-ui 25.2.0 → 25.3.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/components/Button/Button.d.ts +12 -0
- package/dist/components/Button/Button.stories.d.ts +1 -0
- package/dist/index.es.js +205 -205
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +203 -203
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -44,6 +44,18 @@ type baseProps = {
|
|
|
44
44
|
icon?: React.ReactNode;
|
|
45
45
|
size?: ButtonSize;
|
|
46
46
|
onClick?: (event: React.MouseEvent<Element, MouseEvent>) => void;
|
|
47
|
+
/**
|
|
48
|
+
* ローディング状態を表示するかどうか。文字列を指定した場合はそれがローディングテキストとして使用されます。
|
|
49
|
+
* - `true`: デフォルトの"Loading..."テキストを使用
|
|
50
|
+
* - `string`: 指定した文字列をローディングテキストとして使用
|
|
51
|
+
* - `false` または `undefined`: ローディング状態を表示しない
|
|
52
|
+
*
|
|
53
|
+
* ボタンの内容に応じた動作:
|
|
54
|
+
* - アイコンのみ: スピナーのみを表示(ローディングテキストは無視)
|
|
55
|
+
* - テキストのみ: ローディングテキストのみを表示(`true`の場合はデフォルトで"Loading...")
|
|
56
|
+
* - アイコン + テキスト: スピナー + ローディングテキストを表示(`true`の場合はデフォルトで"Loading...")
|
|
57
|
+
*/
|
|
58
|
+
loading?: boolean | string;
|
|
47
59
|
} & React.ComponentPropsWithoutRef<"button">;
|
|
48
60
|
type AnchorProps = Omit<baseProps, "onClick"> & {
|
|
49
61
|
/**
|
|
@@ -30,3 +30,4 @@ export declare const Disabled: StoryObj<ButtonProps>;
|
|
|
30
30
|
export declare const UseHrefProps: StoryObj<ButtonProps>;
|
|
31
31
|
export declare const CustomTextColor: StoryObj<ButtonProps>;
|
|
32
32
|
export declare const DesignSamples: StoryObj;
|
|
33
|
+
export declare const WithLoading: StoryObj<ButtonProps>;
|