@easypost/easy-ui 1.0.0-alpha.5 → 1.0.0-alpha.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.
- package/Badge/index.js +16 -16
- package/Badge/index.mjs +14 -14
- package/Banner/index.js +7 -7
- package/Banner/index.mjs +5 -5
- package/Button/Button.d.ts +61 -0
- package/Button/Button.d.ts.map +1 -1
- package/Button/index.js +23 -23
- package/Button/index.mjs +20 -20
- package/CHANGELOG.md +8 -0
- package/Card/index.js +84 -5
- package/Card/index.mjs +84 -5
- package/Checkbox/index.js +26 -26
- package/Checkbox/index.mjs +24 -24
- package/CodeBlock/index.js +4 -4
- package/CodeBlock/index.mjs +4 -4
- package/DropdownButton/DropdownButton.d.ts +48 -0
- package/DropdownButton/DropdownButton.d.ts.map +1 -1
- package/DropdownButton/index.js +17 -17
- package/DropdownButton/index.mjs +15 -15
- package/HorizontalGrid/index.js +1 -1
- package/HorizontalGrid/index.mjs +1 -1
- package/HorizontalStack/index.js +48 -4
- package/HorizontalStack/index.mjs +48 -4
- package/Icon/Icon.d.ts +51 -0
- package/Icon/Icon.d.ts.map +1 -1
- package/Icon/index.js +38 -4
- package/Icon/index.mjs +38 -4
- package/IconButton/IconButton.d.ts +62 -0
- package/IconButton/IconButton.d.ts.map +1 -1
- package/IconButton/index.js +18 -18
- package/IconButton/index.mjs +15 -15
- package/InputField/index.js +282 -11
- package/InputField/index.mjs +266 -11
- package/Menu/index.js +57 -15
- package/Menu/index.mjs +58 -16
- package/Notification/index.js +1534 -14
- package/Notification/index.mjs +1518 -14
- package/Provider/index.js +8 -8
- package/Provider/index.mjs +8 -8
- package/RadioGroup/index.js +24 -24
- package/RadioGroup/index.mjs +22 -22
- package/Select/index.js +71 -29
- package/Select/index.mjs +71 -29
- package/SelectorErrorTooltip/index.js +99 -8
- package/SelectorErrorTooltip/index.mjs +85 -10
- package/Text/index.js +85 -4
- package/Text/index.mjs +85 -4
- package/TextField/index.js +7 -7
- package/TextField/index.mjs +8 -8
- package/Textarea/index.js +7 -7
- package/Textarea/index.mjs +8 -8
- package/Theme/index.js +145 -9
- package/Theme/index.mjs +145 -9
- package/Toggle/index.js +14 -14
- package/Toggle/index.mjs +14 -14
- package/Tooltip/index.js +297 -8
- package/Tooltip/index.mjs +298 -9
- package/UnstyledButton/index.js +3 -3
- package/UnstyledButton/index.mjs +3 -3
- package/VerticalStack/index.js +3 -3
- package/VerticalStack/index.mjs +3 -3
- package/__chunks__/{InputIcon-4a8e5243.mjs → InputIcon-2317befd.mjs} +26 -26
- package/__chunks__/{InputIcon-70dad3e5.js → InputIcon-d3963cf8.js} +29 -29
- package/__chunks__/{import-9c958e32.mjs → import-0561e1ba.mjs} +2 -2
- package/__chunks__/{import-fbe7cc7e.mjs → import-19bc38ac.mjs} +26 -26
- package/__chunks__/{import-d2e79ac1.mjs → import-29af6941.mjs} +3 -3
- package/__chunks__/{import-9581a2dc.js → import-2b302763.js} +43 -1
- package/__chunks__/{import-a6cadfe8.mjs → import-3d962a94.mjs} +57 -15
- package/__chunks__/{import-d52cd5cf.js → import-8b6c0bc7.js} +1 -1
- package/__chunks__/{import-87c465c9.js → import-a2023d8f.js} +1 -1
- package/__chunks__/{import-29edaaea.mjs → import-f1f4792a.mjs} +9 -9
- package/__chunks__/{UnstyledButton-981cd9af.mjs → index-29d7bca9.mjs} +2 -2
- package/__chunks__/{UnstyledButton-5bbb3c5e.js → index-3985350a.js} +1 -1
- package/__chunks__/{overlayscrollbars-react.es-c8369a03.mjs → overlayscrollbars-react.es-7f332a3b.mjs} +4 -4
- package/__chunks__/{overlayscrollbars-react.es-20563393.js → overlayscrollbars-react.es-f2a0bcff.js} +4 -4
- package/__chunks__/{real-module-2f165429.mjs → real-module-515df21d.mjs} +4 -4
- package/__chunks__/{useTriggerWidth-9528009c.js → useTriggerWidth-156b038a.js} +48 -6
- package/__chunks__/{useTriggerWidth-29becc21.mjs → useTriggerWidth-addcd1d6.mjs} +71 -29
- package/package.json +6 -6
- package/style.css +1437 -1436
- package/__chunks__/Card-2bd533c4.js +0 -85
- package/__chunks__/Card-4ad318ba.mjs +0 -86
- package/__chunks__/HorizontalStack-65adb570.mjs +0 -50
- package/__chunks__/HorizontalStack-f331bfc7.js +0 -49
- package/__chunks__/Icon-1a25dcae.js +0 -39
- package/__chunks__/Icon-6eb724b4.mjs +0 -40
- package/__chunks__/InputField-cc829736.mjs +0 -268
- package/__chunks__/InputField-f5072e37.js +0 -283
- package/__chunks__/Notification-8d749bd1.mjs +0 -1533
- package/__chunks__/Notification-b7a2c277.js +0 -1548
- package/__chunks__/SelectorErrorTooltip-4d820c45.mjs +0 -83
- package/__chunks__/SelectorErrorTooltip-b7bb5b9d.js +0 -98
- package/__chunks__/Text-2efbe1fe.js +0 -86
- package/__chunks__/Text-ec2b8d8a.mjs +0 -87
- package/__chunks__/Theme-123ba2c3.mjs +0 -147
- package/__chunks__/Theme-57f8311c.js +0 -146
- package/__chunks__/Tooltip-b4e23b78.mjs +0 -299
- package/__chunks__/Tooltip-c5076ca7.js +0 -298
package/Checkbox/index.mjs
CHANGED
|
@@ -19,18 +19,18 @@ var __spreadValues = (a, b) => {
|
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
import * as React from "react";
|
|
21
21
|
import React__default, { useEffect } from "react";
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
22
|
+
import { Icon } from "../Icon/index.mjs";
|
|
23
|
+
import { SelectorErrorTooltip } from "../SelectorErrorTooltip/index.mjs";
|
|
24
|
+
import { Text } from "../Text/index.mjs";
|
|
25
25
|
import { classNames, variationName } from "../utilities/css.mjs";
|
|
26
|
-
import { $ as $d2c8e2b0480f3f34$export$cbe85ee05b554577, a as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../__chunks__/import-
|
|
27
|
-
import {
|
|
28
|
-
import "../
|
|
29
|
-
import "../__chunks__/import-
|
|
30
|
-
import "../__chunks__/import-
|
|
26
|
+
import { $ as $d2c8e2b0480f3f34$export$cbe85ee05b554577, a as $3017fa7ffdddec74$export$8042c6c013fd5226 } from "../__chunks__/import-0561e1ba.mjs";
|
|
27
|
+
import { e as $f7dceffc5ad7768b$export$4e328f61c538687f, f as $6179b936705e76d3$export$ae780daf29e6d456 } from "../__chunks__/import-3d962a94.mjs";
|
|
28
|
+
import "../Tooltip/index.mjs";
|
|
29
|
+
import "../__chunks__/import-f1f4792a.mjs";
|
|
30
|
+
import "../__chunks__/import-19bc38ac.mjs";
|
|
31
31
|
import "react-dom";
|
|
32
32
|
import "../__chunks__/import-6a831ca1.mjs";
|
|
33
|
-
import "../__chunks__/real-module-
|
|
33
|
+
import "../__chunks__/real-module-515df21d.mjs";
|
|
34
34
|
function $406796ff087fe49b$export$e375f10ce42261c5(props, state, inputRef) {
|
|
35
35
|
let { inputProps, isSelected, isPressed, isDisabled, isReadOnly } = $d2c8e2b0480f3f34$export$cbe85ee05b554577(props, state, inputRef);
|
|
36
36
|
let { isIndeterminate } = props;
|
|
@@ -138,21 +138,21 @@ const Remove600 = (_a) => {
|
|
|
138
138
|
d: "M190.391-440.391v-79.218h579.218v79.218H190.391Z"
|
|
139
139
|
}));
|
|
140
140
|
};
|
|
141
|
-
const Checkbox$1 = "
|
|
142
|
-
const label = "
|
|
143
|
-
const box = "
|
|
144
|
-
const check = "
|
|
145
|
-
const focusVisible = "
|
|
146
|
-
const text = "
|
|
147
|
-
const indeterminateSvg = "
|
|
148
|
-
const nested = "
|
|
149
|
-
const sizeLg = "
|
|
150
|
-
const invalid = "
|
|
151
|
-
const disabled = "
|
|
152
|
-
const indeterminate = "
|
|
153
|
-
const selected = "
|
|
154
|
-
const hovered = "
|
|
155
|
-
const readOnly = "
|
|
141
|
+
const Checkbox$1 = "_Checkbox_1r930_5";
|
|
142
|
+
const label = "_label_1r930_17";
|
|
143
|
+
const box = "_box_1r930_40";
|
|
144
|
+
const check = "_check_1r930_41";
|
|
145
|
+
const focusVisible = "_focusVisible_1r930_56";
|
|
146
|
+
const text = "_text_1r930_72";
|
|
147
|
+
const indeterminateSvg = "_indeterminateSvg_1r930_77";
|
|
148
|
+
const nested = "_nested_1r930_81";
|
|
149
|
+
const sizeLg = "_sizeLg_1r930_85";
|
|
150
|
+
const invalid = "_invalid_1r930_91";
|
|
151
|
+
const disabled = "_disabled_1r930_95";
|
|
152
|
+
const indeterminate = "_indeterminate_1r930_77";
|
|
153
|
+
const selected = "_selected_1r930_100";
|
|
154
|
+
const hovered = "_hovered_1r930_116";
|
|
155
|
+
const readOnly = "_readOnly_1r930_116";
|
|
156
156
|
const styles = {
|
|
157
157
|
Checkbox: Checkbox$1,
|
|
158
158
|
label,
|
package/CodeBlock/index.js
CHANGED
|
@@ -21,11 +21,11 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
|
21
21
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
22
22
|
const _import = require("../__chunks__/import-a1e0f814.js");
|
|
23
23
|
const React = require("react");
|
|
24
|
-
const
|
|
24
|
+
const Card_index = require("../Card/index.js");
|
|
25
25
|
const omit = require("../__chunks__/omit-fca26542.js");
|
|
26
26
|
const tokens = require("../__chunks__/tokens-e696ca96.js");
|
|
27
27
|
const utilities_css = require("../utilities/css.js");
|
|
28
|
-
const overlayscrollbarsReact_es = require("../__chunks__/overlayscrollbars-react.es-
|
|
28
|
+
const overlayscrollbarsReact_es = require("../__chunks__/overlayscrollbars-react.es-f2a0bcff.js");
|
|
29
29
|
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
30
30
|
if (source == null)
|
|
31
31
|
return {};
|
|
@@ -5371,7 +5371,7 @@ function useScrollbar(codeBlockRef) {
|
|
|
5371
5371
|
}
|
|
5372
5372
|
}, [initialize, codeBlockRef]);
|
|
5373
5373
|
}
|
|
5374
|
-
const CodeBlock$1 = "
|
|
5374
|
+
const CodeBlock$1 = "_CodeBlock_1f5ii_5";
|
|
5375
5375
|
const styles = {
|
|
5376
5376
|
CodeBlock: CodeBlock$1
|
|
5377
5377
|
};
|
|
@@ -5380,7 +5380,7 @@ const CodeBlock = React.forwardRef((props, ref) => {
|
|
|
5380
5380
|
const codeBlockRef = React.useRef(null);
|
|
5381
5381
|
const syntaxTheme = useEasyUiSyntaxHighlighterTheme(maxLines);
|
|
5382
5382
|
useScrollbar(codeBlockRef);
|
|
5383
|
-
return React.createElement(
|
|
5383
|
+
return React.createElement(Card_index.Card, {
|
|
5384
5384
|
background: "primary"
|
|
5385
5385
|
}, React.createElement("div", {
|
|
5386
5386
|
className: styles.CodeBlock,
|
package/CodeBlock/index.mjs
CHANGED
|
@@ -17,13 +17,13 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import {
|
|
20
|
+
import { z as $5dc95899b306f630$export$c9058316764c140e } from "../__chunks__/import-19bc38ac.mjs";
|
|
21
21
|
import React__default, { useMemo, useEffect, forwardRef, useRef } from "react";
|
|
22
|
-
import {
|
|
22
|
+
import { Card } from "../Card/index.mjs";
|
|
23
23
|
import { c as commonjsGlobal, g as getDefaultExportFromCjs } from "../__chunks__/omit-f17deb8f.mjs";
|
|
24
24
|
import { e as ezuiTokens } from "../__chunks__/tokens-6be8e137.mjs";
|
|
25
25
|
import { pxToRem } from "../utilities/css.mjs";
|
|
26
|
-
import { S } from "../__chunks__/overlayscrollbars-react.es-
|
|
26
|
+
import { S } from "../__chunks__/overlayscrollbars-react.es-7f332a3b.mjs";
|
|
27
27
|
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
28
28
|
if (source == null)
|
|
29
29
|
return {};
|
|
@@ -5369,7 +5369,7 @@ function useScrollbar(codeBlockRef) {
|
|
|
5369
5369
|
}
|
|
5370
5370
|
}, [initialize, codeBlockRef]);
|
|
5371
5371
|
}
|
|
5372
|
-
const CodeBlock$1 = "
|
|
5372
|
+
const CodeBlock$1 = "_CodeBlock_1f5ii_5";
|
|
5373
5373
|
const styles = {
|
|
5374
5374
|
CodeBlock: CodeBlock$1
|
|
5375
5375
|
};
|
|
@@ -12,6 +12,54 @@ export type DropdownButtonProps = AriaButtonProps & {
|
|
|
12
12
|
/** Content inside button */
|
|
13
13
|
children?: ReactNode;
|
|
14
14
|
};
|
|
15
|
+
/**
|
|
16
|
+
* Typically used as a trigger to display a set of options for
|
|
17
|
+
* the user to choose from.
|
|
18
|
+
*
|
|
19
|
+
* @remarks
|
|
20
|
+
* Can be used alongside Easy UI's `<Menu />` as the trigger element.
|
|
21
|
+
* Comes pre-styled with separator and right-aligned arrow icon. Supports
|
|
22
|
+
* multiple colors and an outlined variant. Underlying element is a button.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* _Default:_
|
|
26
|
+
* ```tsx
|
|
27
|
+
* import { DropdownButton } from "@easypost/easy-ui/DropdownButton";
|
|
28
|
+
*
|
|
29
|
+
* export function Component() {
|
|
30
|
+
* return (
|
|
31
|
+
* <DropdownButton onPress={() => alert("clicked")}>Button</DropdownButton>
|
|
32
|
+
* );
|
|
33
|
+
* }
|
|
34
|
+
* ```
|
|
35
|
+
*
|
|
36
|
+
* @example
|
|
37
|
+
* _Outlined variant:_
|
|
38
|
+
* ```tsx
|
|
39
|
+
* import { DropdownButton } from "@easypost/easy-ui/DropdownButton";
|
|
40
|
+
*
|
|
41
|
+
* export function Component() {
|
|
42
|
+
* return (
|
|
43
|
+
* <DropdownButton onPress={() => alert("clicked")} variant="outlined">
|
|
44
|
+
* Button
|
|
45
|
+
* </DropdownButton>
|
|
46
|
+
* );
|
|
47
|
+
* }
|
|
48
|
+
* ```
|
|
49
|
+
* @example
|
|
50
|
+
* _Success color:_
|
|
51
|
+
* ```tsx
|
|
52
|
+
* import { DropdownButton } from "@easypost/easy-ui/DropdownButton";
|
|
53
|
+
*
|
|
54
|
+
* export function Component() {
|
|
55
|
+
* return (
|
|
56
|
+
* <DropdownButton onPress={() => alert("clicked")} color="success">
|
|
57
|
+
* Button
|
|
58
|
+
* </DropdownButton>
|
|
59
|
+
* );
|
|
60
|
+
* }
|
|
61
|
+
* ```
|
|
62
|
+
*/
|
|
15
63
|
export declare const DropdownButton: React.ForwardRefExoticComponent<AriaButtonProps<"button"> & {
|
|
16
64
|
/** Button color */
|
|
17
65
|
color?: ButtonColor | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropdownButton.d.ts","sourceRoot":"","sources":["../../src/DropdownButton/DropdownButton.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAc,MAAM,OAAO,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAOxC,MAAM,MAAM,qBAAqB,GAAG,QAAQ,GAAG,UAAU,CAAC;AAE1D,MAAM,MAAM,mBAAmB,GAAG,eAAe,GAAG;IAClD,mBAAmB;IACnB,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,qBAAqB;IACrB,OAAO,CAAC,EAAE,qBAAqB,CAAC;IAChC,sBAAsB;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,6BAA6B;IAC7B,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,CAAC;AAEF,eAAO,MAAM,cAAc;
|
|
1
|
+
{"version":3,"file":"DropdownButton.d.ts","sourceRoot":"","sources":["../../src/DropdownButton/DropdownButton.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAc,MAAM,OAAO,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAOxC,MAAM,MAAM,qBAAqB,GAAG,QAAQ,GAAG,UAAU,CAAC;AAE1D,MAAM,MAAM,mBAAmB,GAAG,eAAe,GAAG;IAClD,mBAAmB;IACnB,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,qBAAqB;IACrB,OAAO,CAAC,EAAE,qBAAqB,CAAC;IAChC,sBAAsB;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,6BAA6B;IAC7B,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+CG;AACH,eAAO,MAAM,cAAc;IA1DzB,mBAAmB;;IAEnB,qBAAqB;;IAErB,sBAAsB;;IAEtB,6BAA6B;eAClB,SAAS;8BAgFrB,CAAC"}
|
package/DropdownButton/index.js
CHANGED
|
@@ -30,23 +30,23 @@ var __objRest = (source, exclude) => {
|
|
|
30
30
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
31
31
|
const ExpandMore400 = require("../__chunks__/ExpandMore400-92646971.js");
|
|
32
32
|
const React = require("react");
|
|
33
|
-
const
|
|
34
|
-
const
|
|
33
|
+
const UnstyledButton_index = require("../__chunks__/index-3985350a.js");
|
|
34
|
+
const Icon_index = require("../Icon/index.js");
|
|
35
35
|
const utilities_css = require("../utilities/css.js");
|
|
36
36
|
require("../__chunks__/import-a1e0f814.js");
|
|
37
37
|
require("../__chunks__/omit-fca26542.js");
|
|
38
|
-
require("../__chunks__/import-
|
|
39
|
-
const DropdownButton$1 = "
|
|
40
|
-
const colorPrimary = "
|
|
41
|
-
const colorSecondary = "
|
|
42
|
-
const colorSuccess = "
|
|
43
|
-
const colorWarning = "
|
|
44
|
-
const colorNeutral = "
|
|
45
|
-
const colorSupport = "
|
|
46
|
-
const colorInverse = "
|
|
47
|
-
const variantOutlined = "
|
|
48
|
-
const variantFilled = "
|
|
49
|
-
const pipeSeparator = "
|
|
38
|
+
require("../__chunks__/import-2b302763.js");
|
|
39
|
+
const DropdownButton$1 = "_DropdownButton_1ynin_5";
|
|
40
|
+
const colorPrimary = "_colorPrimary_1ynin_26";
|
|
41
|
+
const colorSecondary = "_colorSecondary_1ynin_34";
|
|
42
|
+
const colorSuccess = "_colorSuccess_1ynin_42";
|
|
43
|
+
const colorWarning = "_colorWarning_1ynin_50";
|
|
44
|
+
const colorNeutral = "_colorNeutral_1ynin_58";
|
|
45
|
+
const colorSupport = "_colorSupport_1ynin_66";
|
|
46
|
+
const colorInverse = "_colorInverse_1ynin_72";
|
|
47
|
+
const variantOutlined = "_variantOutlined_1ynin_78";
|
|
48
|
+
const variantFilled = "_variantFilled_1ynin_109";
|
|
49
|
+
const pipeSeparator = "_pipeSeparator_1ynin_136";
|
|
50
50
|
const styles = {
|
|
51
51
|
DropdownButton: DropdownButton$1,
|
|
52
52
|
colorPrimary,
|
|
@@ -62,14 +62,14 @@ const styles = {
|
|
|
62
62
|
};
|
|
63
63
|
const DropdownButton = React.forwardRef((props, inRef) => {
|
|
64
64
|
const _a = props, { color = "primary", variant = "filled", isDisabled = false, children = "Button" } = _a, restProps = __objRest(_a, ["color", "variant", "isDisabled", "children"]);
|
|
65
|
-
|
|
66
|
-
return React.createElement(
|
|
65
|
+
UnstyledButton_index.logWarningIfInvalidColorVariantCombination(color, variant);
|
|
66
|
+
return React.createElement(UnstyledButton_index.UnstyledButton, __spreadValues({
|
|
67
67
|
isDisabled,
|
|
68
68
|
ref: inRef,
|
|
69
69
|
className: utilities_css.classNames(styles.DropdownButton, styles[utilities_css.variationName("variant", variant)], styles[utilities_css.variationName("color", color)])
|
|
70
70
|
}, restProps), React.createElement("span", null, children), React.createElement("span", {
|
|
71
71
|
className: utilities_css.classNames(styles.pipeSeparator)
|
|
72
|
-
}), React.createElement(
|
|
72
|
+
}), React.createElement(Icon_index.Icon, {
|
|
73
73
|
symbol: ExpandMore400.ExpandMore400
|
|
74
74
|
}));
|
|
75
75
|
});
|
package/DropdownButton/index.mjs
CHANGED
|
@@ -28,23 +28,23 @@ var __objRest = (source, exclude) => {
|
|
|
28
28
|
};
|
|
29
29
|
import { E as ExpandMore400 } from "../__chunks__/ExpandMore400-7c5263a4.mjs";
|
|
30
30
|
import React__default, { forwardRef } from "react";
|
|
31
|
-
import { l as logWarningIfInvalidColorVariantCombination, U as UnstyledButton } from "../__chunks__/
|
|
32
|
-
import {
|
|
31
|
+
import { l as logWarningIfInvalidColorVariantCombination, U as UnstyledButton } from "../__chunks__/index-29d7bca9.mjs";
|
|
32
|
+
import { Icon } from "../Icon/index.mjs";
|
|
33
33
|
import { classNames, variationName } from "../utilities/css.mjs";
|
|
34
|
-
import "../__chunks__/import-
|
|
34
|
+
import "../__chunks__/import-19bc38ac.mjs";
|
|
35
35
|
import "../__chunks__/omit-f17deb8f.mjs";
|
|
36
|
-
import "../__chunks__/import-
|
|
37
|
-
const DropdownButton$1 = "
|
|
38
|
-
const colorPrimary = "
|
|
39
|
-
const colorSecondary = "
|
|
40
|
-
const colorSuccess = "
|
|
41
|
-
const colorWarning = "
|
|
42
|
-
const colorNeutral = "
|
|
43
|
-
const colorSupport = "
|
|
44
|
-
const colorInverse = "
|
|
45
|
-
const variantOutlined = "
|
|
46
|
-
const variantFilled = "
|
|
47
|
-
const pipeSeparator = "
|
|
36
|
+
import "../__chunks__/import-3d962a94.mjs";
|
|
37
|
+
const DropdownButton$1 = "_DropdownButton_1ynin_5";
|
|
38
|
+
const colorPrimary = "_colorPrimary_1ynin_26";
|
|
39
|
+
const colorSecondary = "_colorSecondary_1ynin_34";
|
|
40
|
+
const colorSuccess = "_colorSuccess_1ynin_42";
|
|
41
|
+
const colorWarning = "_colorWarning_1ynin_50";
|
|
42
|
+
const colorNeutral = "_colorNeutral_1ynin_58";
|
|
43
|
+
const colorSupport = "_colorSupport_1ynin_66";
|
|
44
|
+
const colorInverse = "_colorInverse_1ynin_72";
|
|
45
|
+
const variantOutlined = "_variantOutlined_1ynin_78";
|
|
46
|
+
const variantFilled = "_variantFilled_1ynin_109";
|
|
47
|
+
const pipeSeparator = "_pipeSeparator_1ynin_136";
|
|
48
48
|
const styles = {
|
|
49
49
|
DropdownButton: DropdownButton$1,
|
|
50
50
|
colorPrimary,
|
package/HorizontalGrid/index.js
CHANGED
package/HorizontalGrid/index.mjs
CHANGED
package/HorizontalStack/index.js
CHANGED
|
@@ -1,6 +1,50 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __defProps = Object.defineProperties;
|
|
4
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
5
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
8
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
9
|
+
var __spreadValues = (a, b) => {
|
|
10
|
+
for (var prop in b || (b = {}))
|
|
11
|
+
if (__hasOwnProp.call(b, prop))
|
|
12
|
+
__defNormalProp(a, prop, b[prop]);
|
|
13
|
+
if (__getOwnPropSymbols)
|
|
14
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
15
|
+
if (__propIsEnum.call(b, prop))
|
|
16
|
+
__defNormalProp(a, prop, b[prop]);
|
|
17
|
+
}
|
|
18
|
+
return a;
|
|
19
|
+
};
|
|
20
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
21
|
+
var __objRest = (source, exclude) => {
|
|
22
|
+
var target = {};
|
|
23
|
+
for (var prop in source)
|
|
24
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
25
|
+
target[prop] = source[prop];
|
|
26
|
+
if (source != null && __getOwnPropSymbols)
|
|
27
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
28
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
29
|
+
target[prop] = source[prop];
|
|
30
|
+
}
|
|
31
|
+
return target;
|
|
32
|
+
};
|
|
2
33
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const
|
|
4
|
-
require("
|
|
5
|
-
|
|
6
|
-
|
|
34
|
+
const React = require("react");
|
|
35
|
+
const utilities_css = require("../utilities/css.js");
|
|
36
|
+
const HorizontalStack$1 = "_HorizontalStack_7gzzs_5";
|
|
37
|
+
const styles = {
|
|
38
|
+
HorizontalStack: HorizontalStack$1
|
|
39
|
+
};
|
|
40
|
+
const HorizontalStack = React.forwardRef((props, ref) => {
|
|
41
|
+
const _a = props, { as: As = "div", align, blockAlign, gap, wrap = true, children, inline } = _a, restProps = __objRest(_a, ["as", "align", "blockAlign", "gap", "wrap", "children", "inline"]);
|
|
42
|
+
const style = __spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues({}, utilities_css.getResponsiveDesignToken("horizontal-stack", "gap", "space", gap)), utilities_css.getComponentToken("horizontal-stack", "align", align)), utilities_css.getComponentToken("horizontal-stack", "block-align", blockAlign)), utilities_css.getComponentToken("horizontal-stack", "wrap", wrap ? "wrap" : "nowrap")), utilities_css.getComponentToken("horizontal-stack", "display", inline ? "inline-flex" : "flex"));
|
|
43
|
+
return React.createElement(As, __spreadProps(__spreadValues({}, restProps), {
|
|
44
|
+
className: styles.HorizontalStack,
|
|
45
|
+
style,
|
|
46
|
+
ref
|
|
47
|
+
}), children);
|
|
48
|
+
});
|
|
49
|
+
HorizontalStack.displayName = "HorizontalStack";
|
|
50
|
+
exports.HorizontalStack = HorizontalStack;
|
|
@@ -1,6 +1,50 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
+
var __spreadValues = (a, b) => {
|
|
9
|
+
for (var prop in b || (b = {}))
|
|
10
|
+
if (__hasOwnProp.call(b, prop))
|
|
11
|
+
__defNormalProp(a, prop, b[prop]);
|
|
12
|
+
if (__getOwnPropSymbols)
|
|
13
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
+
if (__propIsEnum.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
}
|
|
17
|
+
return a;
|
|
18
|
+
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
var __objRest = (source, exclude) => {
|
|
21
|
+
var target = {};
|
|
22
|
+
for (var prop in source)
|
|
23
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
24
|
+
target[prop] = source[prop];
|
|
25
|
+
if (source != null && __getOwnPropSymbols)
|
|
26
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
27
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
28
|
+
target[prop] = source[prop];
|
|
29
|
+
}
|
|
30
|
+
return target;
|
|
31
|
+
};
|
|
32
|
+
import React__default, { forwardRef } from "react";
|
|
33
|
+
import { getResponsiveDesignToken, getComponentToken } from "../utilities/css.mjs";
|
|
34
|
+
const HorizontalStack$1 = "_HorizontalStack_7gzzs_5";
|
|
35
|
+
const styles = {
|
|
36
|
+
HorizontalStack: HorizontalStack$1
|
|
37
|
+
};
|
|
38
|
+
const HorizontalStack = forwardRef((props, ref) => {
|
|
39
|
+
const _a = props, { as: As = "div", align, blockAlign, gap, wrap = true, children, inline } = _a, restProps = __objRest(_a, ["as", "align", "blockAlign", "gap", "wrap", "children", "inline"]);
|
|
40
|
+
const style = __spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues({}, getResponsiveDesignToken("horizontal-stack", "gap", "space", gap)), getComponentToken("horizontal-stack", "align", align)), getComponentToken("horizontal-stack", "block-align", blockAlign)), getComponentToken("horizontal-stack", "wrap", wrap ? "wrap" : "nowrap")), getComponentToken("horizontal-stack", "display", inline ? "inline-flex" : "flex"));
|
|
41
|
+
return React__default.createElement(As, __spreadProps(__spreadValues({}, restProps), {
|
|
42
|
+
className: styles.HorizontalStack,
|
|
43
|
+
style,
|
|
44
|
+
ref
|
|
45
|
+
}), children);
|
|
46
|
+
});
|
|
47
|
+
HorizontalStack.displayName = "HorizontalStack";
|
|
4
48
|
export {
|
|
5
|
-
|
|
49
|
+
HorizontalStack
|
|
6
50
|
};
|
package/Icon/Icon.d.ts
CHANGED
|
@@ -13,5 +13,56 @@ export type IconProps = {
|
|
|
13
13
|
/** Description of icon for informative symbols */
|
|
14
14
|
accessibilityLabel?: string;
|
|
15
15
|
};
|
|
16
|
+
/**
|
|
17
|
+
* Icons are helpful and familiar visual symbols used to communicate
|
|
18
|
+
* ideas and represent objects and actions.
|
|
19
|
+
*
|
|
20
|
+
* @remarks
|
|
21
|
+
* Can accept any Easy UI icon via `symbol` prop. Supports customizable
|
|
22
|
+
* responsive sizing, theme and design token colors, and an accessibility
|
|
23
|
+
* label for informative symbols.
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* _Default:_
|
|
27
|
+
* ```tsx
|
|
28
|
+
* import { Icon } from "@easypost/easy-ui/Icon";
|
|
29
|
+
* import AddIcon from "@easypost/easy-ui-icons/Add";
|
|
30
|
+
*
|
|
31
|
+
* export function Component() {
|
|
32
|
+
* return <Icon symbol={AddIcon} />;
|
|
33
|
+
* }
|
|
34
|
+
* ```
|
|
35
|
+
*
|
|
36
|
+
* @example
|
|
37
|
+
* _With accessibility label:_
|
|
38
|
+
* ```tsx
|
|
39
|
+
* import { Icon } from "@easypost/easy-ui/Icon";
|
|
40
|
+
* import AddIcon from "@easypost/easy-ui-icons/Add";
|
|
41
|
+
*
|
|
42
|
+
* export function Component() {
|
|
43
|
+
* return <Icon symbol={AddIcon} accessibilityLabel="Add item" />;
|
|
44
|
+
* }
|
|
45
|
+
* ```
|
|
46
|
+
* @example
|
|
47
|
+
* _With color and size:_
|
|
48
|
+
* ```tsx
|
|
49
|
+
* import { Icon } from "@easypost/easy-ui/Icon";
|
|
50
|
+
* import AddIcon from "@easypost/easy-ui-icons/Add";
|
|
51
|
+
*
|
|
52
|
+
* export function Component() {
|
|
53
|
+
* return <Icon symbol={AddIcon} color="success.inverse" size="sm" />;
|
|
54
|
+
* }
|
|
55
|
+
* ```
|
|
56
|
+
* @example
|
|
57
|
+
* _With responsive sizing:_
|
|
58
|
+
* ```tsx
|
|
59
|
+
* import { Icon } from "@easypost/easy-ui/Icon";
|
|
60
|
+
* import AddIcon from "@easypost/easy-ui-icons/Add";
|
|
61
|
+
*
|
|
62
|
+
* export function Component() {
|
|
63
|
+
* return <Icon symbol={AddIcon} size={{ sm: "sm", md: "md", lg: "lg" }} />;
|
|
64
|
+
* }
|
|
65
|
+
* ```
|
|
66
|
+
*/
|
|
16
67
|
export declare function Icon({ symbol: Symbol, size, color, accessibilityLabel, }: IconProps): React.JSX.Element;
|
|
17
68
|
//# sourceMappingURL=Icon.d.ts.map
|
package/Icon/Icon.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Icon.d.ts","sourceRoot":"","sources":["../../src/Icon/Icon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,UAAU,EACV,mBAAmB,EACnB,oBAAoB,EACrB,MAAM,UAAU,CAAC;AAClB,OAAO,EAGL,cAAc,EACf,MAAM,kBAAkB,CAAC;AAI1B,MAAM,MAAM,QAAQ,GAAG,oBAAoB,CAAC,WAAW,CAAC,CAAC;AACzD,MAAM,MAAM,SAAS,GAAG,mBAAmB,CAAC,YAAY,CAAC,CAAC;AAE1D,MAAM,MAAM,SAAS,GAAG;IACtB,0DAA0D;IAC1D,MAAM,EAAE,UAAU,CAAC;IACnB,uBAAuB;IACvB,IAAI,CAAC,EAAE,cAAc,CAAC,QAAQ,CAAC,CAAC;IAChC,wBAAwB;IACxB,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,kDAAkD;IAClD,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B,CAAC;AAEF,wBAAgB,IAAI,CAAC,EACnB,MAAM,EAAE,MAAM,EACd,IAAW,EACX,KAAK,EACL,kBAAkB,GACnB,EAAE,SAAS,qBAgBX"}
|
|
1
|
+
{"version":3,"file":"Icon.d.ts","sourceRoot":"","sources":["../../src/Icon/Icon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,UAAU,EACV,mBAAmB,EACnB,oBAAoB,EACrB,MAAM,UAAU,CAAC;AAClB,OAAO,EAGL,cAAc,EACf,MAAM,kBAAkB,CAAC;AAI1B,MAAM,MAAM,QAAQ,GAAG,oBAAoB,CAAC,WAAW,CAAC,CAAC;AACzD,MAAM,MAAM,SAAS,GAAG,mBAAmB,CAAC,YAAY,CAAC,CAAC;AAE1D,MAAM,MAAM,SAAS,GAAG;IACtB,0DAA0D;IAC1D,MAAM,EAAE,UAAU,CAAC;IACnB,uBAAuB;IACvB,IAAI,CAAC,EAAE,cAAc,CAAC,QAAQ,CAAC,CAAC;IAChC,wBAAwB;IACxB,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,kDAAkD;IAClD,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;AACH,wBAAgB,IAAI,CAAC,EACnB,MAAM,EAAE,MAAM,EACd,IAAW,EACX,KAAK,EACL,kBAAkB,GACnB,EAAE,SAAS,qBAgBX"}
|
package/Icon/index.js
CHANGED
|
@@ -1,6 +1,40 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
6
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
7
|
+
var __spreadValues = (a, b) => {
|
|
8
|
+
for (var prop in b || (b = {}))
|
|
9
|
+
if (__hasOwnProp.call(b, prop))
|
|
10
|
+
__defNormalProp(a, prop, b[prop]);
|
|
11
|
+
if (__getOwnPropSymbols)
|
|
12
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
13
|
+
if (__propIsEnum.call(b, prop))
|
|
14
|
+
__defNormalProp(a, prop, b[prop]);
|
|
15
|
+
}
|
|
16
|
+
return a;
|
|
17
|
+
};
|
|
2
18
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const
|
|
4
|
-
require("
|
|
5
|
-
|
|
6
|
-
|
|
19
|
+
const React = require("react");
|
|
20
|
+
const utilities_css = require("../utilities/css.js");
|
|
21
|
+
const Icon$1 = "_Icon_1i611_5";
|
|
22
|
+
const Svg = "_Svg_1i611_54";
|
|
23
|
+
const styles = {
|
|
24
|
+
Icon: Icon$1,
|
|
25
|
+
Svg
|
|
26
|
+
};
|
|
27
|
+
function Icon({ symbol: Symbol2, size = "md", color, accessibilityLabel }) {
|
|
28
|
+
const style = __spreadValues(__spreadValues({}, utilities_css.getComponentThemeToken("icon", "color", "color.text", color)), utilities_css.getResponsiveDesignToken("icon", "size", "size.icon", size));
|
|
29
|
+
return React.createElement("span", {
|
|
30
|
+
className: styles.Icon,
|
|
31
|
+
style
|
|
32
|
+
}, React.createElement(Symbol2, {
|
|
33
|
+
className: styles.Svg,
|
|
34
|
+
focusable: "false",
|
|
35
|
+
role: "img",
|
|
36
|
+
title: accessibilityLabel,
|
|
37
|
+
"aria-hidden": !accessibilityLabel ? "true" : void 0
|
|
38
|
+
}));
|
|
39
|
+
}
|
|
40
|
+
exports.Icon = Icon;
|
package/Icon/index.mjs
CHANGED
|
@@ -1,6 +1,40 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
6
|
+
var __spreadValues = (a, b) => {
|
|
7
|
+
for (var prop in b || (b = {}))
|
|
8
|
+
if (__hasOwnProp.call(b, prop))
|
|
9
|
+
__defNormalProp(a, prop, b[prop]);
|
|
10
|
+
if (__getOwnPropSymbols)
|
|
11
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
12
|
+
if (__propIsEnum.call(b, prop))
|
|
13
|
+
__defNormalProp(a, prop, b[prop]);
|
|
14
|
+
}
|
|
15
|
+
return a;
|
|
16
|
+
};
|
|
17
|
+
import React__default from "react";
|
|
18
|
+
import { getComponentThemeToken, getResponsiveDesignToken } from "../utilities/css.mjs";
|
|
19
|
+
const Icon$1 = "_Icon_1i611_5";
|
|
20
|
+
const Svg = "_Svg_1i611_54";
|
|
21
|
+
const styles = {
|
|
22
|
+
Icon: Icon$1,
|
|
23
|
+
Svg
|
|
24
|
+
};
|
|
25
|
+
function Icon({ symbol: Symbol2, size = "md", color, accessibilityLabel }) {
|
|
26
|
+
const style = __spreadValues(__spreadValues({}, getComponentThemeToken("icon", "color", "color.text", color)), getResponsiveDesignToken("icon", "size", "size.icon", size));
|
|
27
|
+
return React__default.createElement("span", {
|
|
28
|
+
className: styles.Icon,
|
|
29
|
+
style
|
|
30
|
+
}, React__default.createElement(Symbol2, {
|
|
31
|
+
className: styles.Svg,
|
|
32
|
+
focusable: "false",
|
|
33
|
+
role: "img",
|
|
34
|
+
title: accessibilityLabel,
|
|
35
|
+
"aria-hidden": !accessibilityLabel ? "true" : void 0
|
|
36
|
+
}));
|
|
37
|
+
}
|
|
4
38
|
export {
|
|
5
|
-
|
|
39
|
+
Icon
|
|
6
40
|
};
|
|
@@ -15,6 +15,68 @@ export type IconButtonProps = AriaButtonProps & {
|
|
|
15
15
|
/** Disables button */
|
|
16
16
|
isDisabled?: boolean;
|
|
17
17
|
};
|
|
18
|
+
/**
|
|
19
|
+
* Button element that represents its behavior with a contextually
|
|
20
|
+
* appropriate icon instead of text.
|
|
21
|
+
*
|
|
22
|
+
* @remarks
|
|
23
|
+
* Use to communicate an action the user can take in order to continue
|
|
24
|
+
* flow in the UI. Supports multiple colors, an outlined variation, and
|
|
25
|
+
* an accessibility label that describes the icon. Underlying element
|
|
26
|
+
* is a button.
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* _Default:_
|
|
30
|
+
* ```tsx
|
|
31
|
+
* import { IconButton } from "@easypost/easy-ui/IconButton";
|
|
32
|
+
* import ArrowBackIcon from "@easypost/easy-ui-icons/ArrowBack";
|
|
33
|
+
*
|
|
34
|
+
* export function Component() {
|
|
35
|
+
* return (
|
|
36
|
+
* <IconButton
|
|
37
|
+
* onPress={() => alert("clicked")}
|
|
38
|
+
* icon={ArrowBackIcon}
|
|
39
|
+
* accessibilityLabel="Back"
|
|
40
|
+
* />
|
|
41
|
+
* );
|
|
42
|
+
* }
|
|
43
|
+
* ```
|
|
44
|
+
*
|
|
45
|
+
* @example
|
|
46
|
+
* _Outlined variant:_
|
|
47
|
+
* ```tsx
|
|
48
|
+
* import { IconButton } from "@easypost/easy-ui/IconButton";
|
|
49
|
+
* import ArrowBackIcon from "@easypost/easy-ui-icons/ArrowBack";
|
|
50
|
+
*
|
|
51
|
+
* export function Component() {
|
|
52
|
+
* return (
|
|
53
|
+
* <IconButton
|
|
54
|
+
* onPress={() => alert("clicked")}
|
|
55
|
+
* icon={ArrowBackIcon}
|
|
56
|
+
* accessibilityLabel="Back"
|
|
57
|
+
* variant="outlined"
|
|
58
|
+
* />
|
|
59
|
+
* );
|
|
60
|
+
* }
|
|
61
|
+
* ```
|
|
62
|
+
* @example
|
|
63
|
+
* _Success color:_
|
|
64
|
+
* ```tsx
|
|
65
|
+
* import { IconButton } from "@easypost/easy-ui/IconButton";
|
|
66
|
+
* import ArrowBackIcon from "@easypost/easy-ui-icons/ArrowBack";
|
|
67
|
+
*
|
|
68
|
+
* export function Component() {
|
|
69
|
+
* return (
|
|
70
|
+
* <IconButton
|
|
71
|
+
* onPress={() => alert("clicked")}
|
|
72
|
+
* icon={ArrowBackIcon}
|
|
73
|
+
* accessibilityLabel="Back"
|
|
74
|
+
* color="success"
|
|
75
|
+
* />
|
|
76
|
+
* );
|
|
77
|
+
* }
|
|
78
|
+
* ```
|
|
79
|
+
*/
|
|
18
80
|
export declare const IconButton: React.ForwardRefExoticComponent<AriaButtonProps<"button"> & {
|
|
19
81
|
/** Button color */
|
|
20
82
|
color?: ButtonColor | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IconButton.d.ts","sourceRoot":"","sources":["../../src/IconButton/IconButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAC1C,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAIxC,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAKtC,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,UAAU,CAAC;AAEtD,MAAM,MAAM,eAAe,GAAG,eAAe,GAAG;IAC9C,mBAAmB;IACnB,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,qBAAqB;IACrB,OAAO,CAAC,EAAE,iBAAiB,CAAC;IAC5B,kBAAkB;IAClB,IAAI,EAAE,UAAU,CAAC;IACjB,0BAA0B;IAC1B,kBAAkB,EAAE,MAAM,CAAC;IAC3B,sBAAsB;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,CAAC;AAEF,eAAO,MAAM,UAAU;
|
|
1
|
+
{"version":3,"file":"IconButton.d.ts","sourceRoot":"","sources":["../../src/IconButton/IconButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAC1C,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAIxC,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAKtC,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,UAAU,CAAC;AAEtD,MAAM,MAAM,eAAe,GAAG,eAAe,GAAG;IAC9C,mBAAmB;IACnB,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,qBAAqB;IACrB,OAAO,CAAC,EAAE,iBAAiB,CAAC;IAC5B,kBAAkB;IAClB,IAAI,EAAE,UAAU,CAAC;IACjB,0BAA0B;IAC1B,kBAAkB,EAAE,MAAM,CAAC;IAC3B,sBAAsB;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6DG;AACH,eAAO,MAAM,UAAU;IA1ErB,mBAAmB;;IAEnB,qBAAqB;;IAErB,kBAAkB;UACZ,UAAU;IAChB,0BAA0B;wBACN,MAAM;IAC1B,sBAAsB;;8BA6FtB,CAAC"}
|