react-asc 18.9.1 → 18.9.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/components/IconButton/IconButton.d.ts +0 -1
- package/components/Link/Link.d.ts +2 -7
- package/index.es.js +3 -4
- package/index.es.js.map +1 -1
- package/index.js +3 -4
- package/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -2,7 +2,6 @@ import React from 'react';
|
|
|
2
2
|
import { COLOR, SIZE, VARIANT } from '../component.enums';
|
|
3
3
|
export interface IIconButtonProps extends React.ComponentProps<"button"> {
|
|
4
4
|
icon?: React.SVGProps<SVGSVGElement>;
|
|
5
|
-
label?: string;
|
|
6
5
|
color?: COLOR;
|
|
7
6
|
size?: SIZE;
|
|
8
7
|
isActive?: boolean;
|
|
@@ -1,7 +1,2 @@
|
|
|
1
|
-
import React
|
|
2
|
-
export
|
|
3
|
-
url?: string;
|
|
4
|
-
children?: ReactNode;
|
|
5
|
-
target?: string;
|
|
6
|
-
}
|
|
7
|
-
export declare const Link: (props: ILinkProps) => JSX.Element;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare const Link: (props: React.ComponentProps<"a">) => JSX.Element;
|
package/index.es.js
CHANGED
|
@@ -624,7 +624,7 @@ var styles$y = {"iconButton":"IconButton-module_iconButton__1xqrL","shadow":"Ico
|
|
|
624
624
|
styleInject(css_248z$y);
|
|
625
625
|
|
|
626
626
|
const IconButton = (props) => {
|
|
627
|
-
const { children, icon,
|
|
627
|
+
const { children, icon, variant = VARIANT.text, color = COLOR.dark, size = SIZE.md, isActive, disabled, className, shadow } = props, rest = __rest(props, ["children", "icon", "variant", "color", "size", "isActive", "disabled", "className", "shadow"]);
|
|
628
628
|
const getCssClasses = () => {
|
|
629
629
|
const cssClasses = [];
|
|
630
630
|
cssClasses.push(styles$y[color]);
|
|
@@ -1542,11 +1542,10 @@ const Row = (props) => {
|
|
|
1542
1542
|
};
|
|
1543
1543
|
|
|
1544
1544
|
const Link = (props) => {
|
|
1545
|
-
const {
|
|
1545
|
+
const { href, className, target, children } = props;
|
|
1546
1546
|
const [status, setStatus] = useState(STATUS.NORMAL);
|
|
1547
1547
|
const getCssClasses = () => {
|
|
1548
1548
|
const cssClasses = [];
|
|
1549
|
-
// cssClasses.push(styles.badgeContainer);
|
|
1550
1549
|
className && cssClasses.push(className);
|
|
1551
1550
|
status !== STATUS.NORMAL && cssClasses.push(status);
|
|
1552
1551
|
return cssClasses.filter(css => css).join(' ');
|
|
@@ -1557,7 +1556,7 @@ const Link = (props) => {
|
|
|
1557
1556
|
const onMouseLeave = () => {
|
|
1558
1557
|
setStatus(STATUS.NORMAL);
|
|
1559
1558
|
};
|
|
1560
|
-
return (React.createElement("a", { className: getCssClasses(), href:
|
|
1559
|
+
return (React.createElement("a", { className: getCssClasses(), href: href || '#', target: target, onMouseEnter: onMouseEnter, onMouseLeave: onMouseLeave }, children));
|
|
1561
1560
|
};
|
|
1562
1561
|
|
|
1563
1562
|
var css_248z$i = ".LoadingIndicator-module_loadingIndicatorContainer__3e1-3 {\n position: fixed;\n top: 0;\n left: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n width: 100%; }\n\n.LoadingIndicator-module_loadingIndicator__tvp5i {\n animation-name: LoadingIndicator-module_spinAnimation__PKRNn;\n animation-duration: 5000ms;\n animation-iteration-count: infinite;\n animation-timing-function: linear;\n width: 24px;\n height: 24px; }\n\n@keyframes LoadingIndicator-module_spinAnimation__PKRNn {\n from {\n transform: rotate(0deg); }\n to {\n transform: rotate(360deg); } }\n";
|