@rescui/button 0.24.1 → 0.24.2-RUI-296-Build-docs-md-files-for-each-docs-section-b138dd5bf.15

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 CHANGED
@@ -1,3 +1,5 @@
1
1
  # Button
2
2
 
3
- * [Usage examples](./docs/demo.md)
3
+ ## LLM
4
+
5
+ To get the docs for the LLM, check out [this index](./llm/index.md).
@@ -1,15 +1,15 @@
1
1
  var styles = {
2
- "icon": "_icon_sn3810_4",
3
- "sizeXS": "_sizeXS_sn3810_14",
4
- "sizeS": "_sizeS_sn3810_18",
5
- "sizeM": "_sizeM_sn3810_22",
6
- "sizeL": "_sizeL_sn3810_26",
7
- "light": "_light_sn3810_30",
8
- "dark": "_dark_sn3810_34",
9
- "allVariants": "_allVariants_sn3810_48",
10
- "variant16": "_variant16_sn3810_53",
11
- "variant20": "_variant20_sn3810_54",
12
- "variant24": "_variant24_sn3810_55",
13
- "variant28": "_variant28_sn3810_58"
2
+ "icon": "_icon_1wzcoos_4",
3
+ "sizeXS": "_sizeXS_1wzcoos_14",
4
+ "sizeS": "_sizeS_1wzcoos_18",
5
+ "sizeM": "_sizeM_1wzcoos_22",
6
+ "sizeL": "_sizeL_1wzcoos_26",
7
+ "light": "_light_1wzcoos_30",
8
+ "dark": "_dark_1wzcoos_34",
9
+ "allVariants": "_allVariants_1wzcoos_48",
10
+ "variant16": "_variant16_1wzcoos_53",
11
+ "variant20": "_variant20_1wzcoos_54",
12
+ "variant24": "_variant24_1wzcoos_55",
13
+ "variant28": "_variant28_1wzcoos_58"
14
14
  };
15
15
  export { styles as default };
package/lib/button.d.ts CHANGED
@@ -1,81 +1,81 @@
1
- import React from 'react';
2
- import { Theme } from '@rescui/ui-contexts';
3
- export declare type ButtonShiftedSide = 'right' | 'left' | 'top' | 'bottom';
4
- export declare type ButtonSize = 'l' | 'm' | 's' | 'xs';
5
- export declare type ButtonModeGeneric = 'classic' | 'rock' | 'transparent' | 'outline';
6
- export declare type ButtonModeClear = 'clear';
7
- export declare type ButtonType = 'button' | 'submit' | 'reset';
8
- export declare type ButtonIconPosition = 'left' | 'left-edge' | 'right' | 'right-edge';
9
- export declare type ButtonFlat = 'left' | 'right';
10
- export declare type ButtonShifted = 'all' | ButtonShiftedSide | ButtonShiftedSide[];
11
- declare type ButtonIntrinsicProps = {
12
- /** Additional class-name */
13
- className?: string;
14
- /** Child element */
15
- children?: React.ReactNode;
16
- /** Disabled state */
17
- disabled?: boolean;
18
- /** Button size */
19
- size?: ButtonSize;
20
- /** Appearance theme */
21
- theme?: Theme;
22
- /** Shows loading icon, use when some action related to button is in progress */
23
- busy?: boolean;
24
- /** @ignore */
25
- highlighted?: boolean;
26
- /** @ignore */
27
- flat?: ButtonFlat;
28
- /**
29
- * Allow wrapping inside the button.
30
- * Do not allow a multiline Button to be placed next to another Button on the same line.
31
- * */
32
- allowMultiline?: boolean;
33
- /**
34
- * Multiline default state. Use for optimising rerenders of always multiline buttons.
35
- * @ignore
36
- * */
37
- defaultMultiline?: boolean;
38
- tabIndex?: number;
39
- title?: string;
40
- /** Button appearance */
41
- mode?: ButtonModeGeneric | ButtonModeClear;
42
- /** **Works only with `mode="clear"`.** Offsets a clear button to one or more sides before the text. Button's background then extends beyond its container. */
43
- shifted?: ButtonShifted;
44
- /** Additional icon */
45
- icon?: React.ReactNode;
46
- /**
47
- * **Works only if the `icon` is present.**
48
- * Additional icon position.
49
- * `-edge` variants are useful for aligning icons between multiple buttons in a column (some of which may be multiline).
50
- * @see [RUI-228](https://youtrack.jetbrains.com/issue/RUI-228/Fix-button-icon-size-and-position)
51
- * */
52
- iconPosition?: ButtonIconPosition;
53
- /** Url path for using component as a link. **Transform a Button into a link (`a` element).** */
54
- href?: string;
55
- /** [Link target](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). **Works only for the link Button.** */
56
- target?: '_blank' | '_self' | '_parent' | '_top';
57
- /** [Link rel](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#rel). **Works only for the link Button.** */
58
- rel?: string;
59
- /**
60
- * Completely removes focus ability.
61
- * We use separate property instead of tabIndex
62
- * because tabIndex doesn't remove all of the controls behavior.
63
- * For example, 'space' button press support remains active.
64
- * We can fix this with a special property.
65
- * **Transform a Button into a `div` element. Do not use with link props (`href`, `rel`, `target`, etc).**
66
- * @ignore
67
- * */
68
- notFocusable?: boolean;
69
- /**
70
- * [More about button types](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#attr-type)
71
- * @type "button" | "submit" | "reset"
72
- * */
73
- type?: ButtonType | string;
74
- /** Click event handler */
75
- onClick?: React.MouseEventHandler<HTMLButtonElement> | React.MouseEventHandler<HTMLAnchorElement> | React.MouseEventHandler<HTMLDivElement>;
76
- };
77
- declare type NativeProps = React.ButtonHTMLAttributes<HTMLButtonElement> | React.AnchorHTMLAttributes<HTMLAnchorElement> | React.BaseHTMLAttributes<HTMLDivElement>;
78
- export declare type ButtonProps = Omit<NativeProps, keyof ButtonIntrinsicProps> & ButtonIntrinsicProps;
79
- declare type ButtonPossibleHTMLType = HTMLAnchorElement | HTMLButtonElement | HTMLDivElement;
80
- export declare const Button: React.ForwardRefExoticComponent<Omit<NativeProps, keyof ButtonIntrinsicProps> & ButtonIntrinsicProps & React.RefAttributes<ButtonPossibleHTMLType>>;
81
- export default Button;
1
+ import React from 'react';
2
+ import { Theme } from '@rescui/ui-contexts';
3
+ export type ButtonShiftedSide = 'right' | 'left' | 'top' | 'bottom';
4
+ export type ButtonSize = 'l' | 'm' | 's' | 'xs';
5
+ export type ButtonModeGeneric = 'classic' | 'rock' | 'transparent' | 'outline';
6
+ export type ButtonModeClear = 'clear';
7
+ export type ButtonType = 'button' | 'submit' | 'reset';
8
+ export type ButtonIconPosition = 'left' | 'left-edge' | 'right' | 'right-edge';
9
+ export type ButtonFlat = 'left' | 'right';
10
+ export type ButtonShifted = 'all' | ButtonShiftedSide | ButtonShiftedSide[];
11
+ type ButtonIntrinsicProps = {
12
+ /** Additional class-name */
13
+ className?: string;
14
+ /** Child element */
15
+ children?: React.ReactNode;
16
+ /** Disabled state */
17
+ disabled?: boolean;
18
+ /** Button size */
19
+ size?: ButtonSize;
20
+ /** Appearance theme */
21
+ theme?: Theme;
22
+ /** Shows loading icon, use when some action related to button is in progress */
23
+ busy?: boolean;
24
+ /** @ignore */
25
+ highlighted?: boolean;
26
+ /** @ignore */
27
+ flat?: ButtonFlat;
28
+ /**
29
+ * Allow wrapping inside the button.
30
+ * Do not allow a multiline Button to be placed next to another Button on the same line.
31
+ * */
32
+ allowMultiline?: boolean;
33
+ /**
34
+ * Multiline default state. Use for optimising rerenders of always multiline buttons.
35
+ * @ignore
36
+ * */
37
+ defaultMultiline?: boolean;
38
+ tabIndex?: number;
39
+ title?: string;
40
+ /** Button appearance */
41
+ mode?: ButtonModeGeneric | ButtonModeClear;
42
+ /** **Works only with `mode="clear"`.** Offsets a clear button to one or more sides before the text. Button's background then extends beyond its container. */
43
+ shifted?: ButtonShifted;
44
+ /** Additional icon */
45
+ icon?: React.ReactNode;
46
+ /**
47
+ * **Works only if the `icon` is present.**
48
+ * Additional icon position.
49
+ * `-edge` variants are useful for aligning icons between multiple buttons in a column (some of which may be multiline).
50
+ * @see [RUI-228](https://youtrack.jetbrains.com/issue/RUI-228/Fix-button-icon-size-and-position)
51
+ * */
52
+ iconPosition?: ButtonIconPosition;
53
+ /** Url path for using component as a link. **Transform a Button into a link (`a` element).** */
54
+ href?: string;
55
+ /** [Link target](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). **Works only for the link Button.** */
56
+ target?: '_blank' | '_self' | '_parent' | '_top';
57
+ /** [Link rel](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#rel). **Works only for the link Button.** */
58
+ rel?: string;
59
+ /**
60
+ * Completely removes focus ability.
61
+ * We use separate property instead of tabIndex
62
+ * because tabIndex doesn't remove all of the controls behavior.
63
+ * For example, 'space' button press support remains active.
64
+ * We can fix this with a special property.
65
+ * **Transform a Button into a `div` element. Do not use with link props (`href`, `rel`, `target`, etc).**
66
+ * @ignore
67
+ * */
68
+ notFocusable?: boolean;
69
+ /**
70
+ * [More about button types](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#attr-type)
71
+ * @type "button" | "submit" | "reset"
72
+ * */
73
+ type?: ButtonType | string;
74
+ /** Click event handler */
75
+ onClick?: React.MouseEventHandler<HTMLButtonElement> | React.MouseEventHandler<HTMLAnchorElement> | React.MouseEventHandler<HTMLDivElement>;
76
+ };
77
+ type NativeProps = React.ButtonHTMLAttributes<HTMLButtonElement> | React.AnchorHTMLAttributes<HTMLAnchorElement> | React.BaseHTMLAttributes<HTMLDivElement>;
78
+ export type ButtonProps = Omit<NativeProps, keyof ButtonIntrinsicProps> & ButtonIntrinsicProps;
79
+ type ButtonPossibleHTMLType = HTMLAnchorElement | HTMLButtonElement | HTMLDivElement;
80
+ export declare const Button: React.ForwardRefExoticComponent<Omit<NativeProps, keyof ButtonIntrinsicProps> & ButtonIntrinsicProps & React.RefAttributes<ButtonPossibleHTMLType>>;
81
+ export default Button;
@@ -1,34 +1,34 @@
1
1
  var styles = {
2
- "light": "_light_1k0trtg_6",
3
- "dark": "_dark_1k0trtg_9",
4
- "flatRight": "_flatRight_1k0trtg_13",
5
- "flatLeft": "_flatLeft_1k0trtg_16",
6
- "sizeXs": "_sizeXs_1k0trtg_20",
7
- "sizeS": "_sizeS_1k0trtg_23",
8
- "sizeM": "_sizeM_1k0trtg_26",
9
- "sizeL": "_sizeL_1k0trtg_29",
10
- "modeClassic": "_modeClassic_1k0trtg_33",
11
- "modeRock": "_modeRock_1k0trtg_36",
12
- "modeTransparent": "_modeTransparent_1k0trtg_39",
13
- "modeOutline": "_modeOutline_1k0trtg_42",
14
- "modeClear": "_modeClear_1k0trtg_45",
15
- "alignIconLeft": "_alignIconLeft_1k0trtg_49",
16
- "alignIconLeftEdge": "_alignIconLeftEdge_1k0trtg_52",
17
- "alignIconRight": "_alignIconRight_1k0trtg_55",
18
- "alignIconRightEdge": "_alignIconRightEdge_1k0trtg_58",
19
- "main": "_main_1k0trtg_62",
20
- "disabled": "_disabled_1k0trtg_139",
21
- "busy": "_busy_1k0trtg_149",
22
- "busyOverlay": "_busyOverlay_1k0trtg_153",
23
- "icon": "_icon_1k0trtg_188",
24
- "allowMultiline": "_allowMultiline_1k0trtg_203",
25
- "content": "_content_1k0trtg_207",
26
- "multiline": "_multiline_1k0trtg_213",
27
- "withoutText": "_withoutText_1k0trtg_217",
28
- "busyIcon": "_busyIcon_1k0trtg_222",
29
- "shiftedLeft": "_shiftedLeft_1k0trtg_243",
30
- "shiftedRight": "_shiftedRight_1k0trtg_246",
31
- "shiftedTop": "_shiftedTop_1k0trtg_249",
32
- "shiftedBottom": "_shiftedBottom_1k0trtg_252"
2
+ "light": "_light_1m4v3po_6",
3
+ "dark": "_dark_1m4v3po_9",
4
+ "flatRight": "_flatRight_1m4v3po_13",
5
+ "flatLeft": "_flatLeft_1m4v3po_16",
6
+ "sizeXs": "_sizeXs_1m4v3po_20",
7
+ "sizeS": "_sizeS_1m4v3po_23",
8
+ "sizeM": "_sizeM_1m4v3po_26",
9
+ "sizeL": "_sizeL_1m4v3po_29",
10
+ "modeClassic": "_modeClassic_1m4v3po_33",
11
+ "modeRock": "_modeRock_1m4v3po_36",
12
+ "modeTransparent": "_modeTransparent_1m4v3po_39",
13
+ "modeOutline": "_modeOutline_1m4v3po_42",
14
+ "modeClear": "_modeClear_1m4v3po_45",
15
+ "alignIconLeft": "_alignIconLeft_1m4v3po_49",
16
+ "alignIconLeftEdge": "_alignIconLeftEdge_1m4v3po_52",
17
+ "alignIconRight": "_alignIconRight_1m4v3po_55",
18
+ "alignIconRightEdge": "_alignIconRightEdge_1m4v3po_58",
19
+ "main": "_main_1m4v3po_62",
20
+ "disabled": "_disabled_1m4v3po_139",
21
+ "busy": "_busy_1m4v3po_149",
22
+ "busyOverlay": "_busyOverlay_1m4v3po_153",
23
+ "icon": "_icon_1m4v3po_188",
24
+ "allowMultiline": "_allowMultiline_1m4v3po_203",
25
+ "content": "_content_1m4v3po_207",
26
+ "multiline": "_multiline_1m4v3po_213",
27
+ "withoutText": "_withoutText_1m4v3po_217",
28
+ "busyIcon": "_busyIcon_1m4v3po_222",
29
+ "shiftedLeft": "_shiftedLeft_1m4v3po_243",
30
+ "shiftedRight": "_shiftedRight_1m4v3po_246",
31
+ "shiftedTop": "_shiftedTop_1m4v3po_249",
32
+ "shiftedBottom": "_shiftedBottom_1m4v3po_252"
33
33
  };
34
34
  export { styles as default };