@capillarytech/blaze-ui 0.1.6-alpha.49 → 0.1.6-alpha.5
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/CapHeading/CapHeading.js +71 -0
- package/CapHeading/index.js +1 -0
- package/CapHeading/styles.js +125 -0
- package/CapInfoNote/CapInfoNote.js +54 -0
- package/CapInfoNote/index.js +1 -0
- package/CapInfoNote/styles.js +63 -0
- package/CapInput/CapInput.js +1 -1
- package/CapInput/Number.js +1 -1
- package/CapInput/Search.js +1 -1
- package/CapInput/TextArea.js +1 -1
- package/CapInput/loadable.js +9 -0
- package/CapLabel/CapLabel.js +81 -101
- package/CapLabel/index.js +1 -3
- package/CapLabel/styles.js +212 -250
- package/CapRow/CapRow.js +10 -111
- package/CapRow/index.js +1 -3
- package/CapRow/styles.js +6 -47
- package/CapTable/loadable.js +4 -4
- package/CapTable/styles.js +1 -1
- package/CapTooltip/CapTooltip.js +25 -87
- package/CapTooltip/index.js +1 -3
- package/CapTooltip/styles.js +27 -19
- package/CapUnifiedSelect/CapUnifiedSelect.js +66 -308
- package/CapUnifiedSelect/index.js +4 -1
- package/CapUnifiedSelect/loadable.js +3 -0
- package/CapUnifiedSelect/styles.js +151 -255
- package/dist/235.index.js +2 -0
- package/dist/235.index.js.LICENSE.txt +29 -0
- package/dist/603.index.js +1 -0
- package/dist/CapInput/CapInput.js +66 -0
- package/dist/CapInput/Number.js +42 -0
- package/dist/CapInput/Search.js +35 -0
- package/dist/CapInput/TextArea.js +42 -0
- package/dist/CapInput/index.js +15 -0
- package/dist/CapInput/messages.js +32 -0
- package/dist/CapInput/styles.js +11 -0
- package/dist/CapTable/CapTable.js +148 -0
- package/dist/CapTable/index.js +9 -0
- package/dist/CapTable/loadable.js +23 -0
- package/dist/CapTable/styles.js +26 -0
- package/dist/LocaleHoc/index.js +40 -0
- package/dist/esm/CapHeading/CapHeading.js +41 -0
- package/dist/esm/CapHeading/index.js +1 -0
- package/dist/esm/CapHeading/styles.js +123 -0
- package/dist/esm/CapInfoNote/CapInfoNote.js +62 -0
- package/dist/esm/CapInfoNote/index.js +1 -0
- package/dist/esm/CapInfoNote/styles.js +6 -0
- package/dist/esm/CapInput/CapInput.js +57 -0
- package/dist/esm/CapInput/Number.js +35 -0
- package/dist/esm/CapInput/Search.js +28 -0
- package/dist/esm/CapInput/TextArea.js +35 -0
- package/dist/esm/CapInput/index.js +8 -0
- package/dist/esm/CapInput/loadable.js +9 -0
- package/dist/esm/CapInput/messages.js +25 -0
- package/dist/esm/CapInput/styles.js +3 -0
- package/dist/esm/CapLabel/CapLabel.js +50 -0
- package/dist/esm/CapLabel/index.js +1 -0
- package/dist/esm/CapLabel/styles.js +219 -0
- package/dist/esm/CapRow/CapRow.js +22 -0
- package/dist/esm/CapRow/index.js +1 -0
- package/dist/esm/CapRow/styles.js +5 -0
- package/dist/esm/CapTable/CapTable.js +140 -0
- package/dist/esm/CapTable/index.js +2 -0
- package/dist/esm/CapTable/loadable.js +12 -0
- package/dist/esm/CapTable/styles.js +17 -0
- package/dist/esm/CapTooltip/CapTooltip.js +34 -0
- package/dist/esm/CapTooltip/index.js +1 -0
- package/dist/esm/CapTooltip/styles.js +6 -0
- package/dist/esm/CapUnifiedSelect/CapUnifiedSelect.js +101 -0
- package/dist/esm/CapUnifiedSelect/index.js +3 -0
- package/dist/esm/CapUnifiedSelect/loadable.js +4 -0
- package/dist/esm/CapUnifiedSelect/messages.js +23 -0
- package/dist/esm/CapUnifiedSelect/styles.js +15 -0
- package/dist/esm/LocaleHoc/index.js +31 -0
- package/dist/esm/index.js +11 -0
- package/dist/esm/styled/index.js +5 -0
- package/dist/esm/styled/variables.js +88 -0
- package/dist/esm/translations/en.js +329 -0
- package/dist/index.js +39 -0
- package/dist/index.js.LICENSE.txt +7 -0
- package/dist/styled/index.js +22 -0
- package/dist/styled/variables.js +94 -0
- package/dist/translations/en.js +335 -0
- package/index.js +1 -12
- package/package.json +11 -5
- package/.DS_Store +0 -0
- package/CapIcon/CapIcon.js +0 -183
- package/CapIcon/index.js +0 -3
- package/CapIcon/styles.js +0 -76
- package/CapSkeleton/CapSkeleton.js +0 -17
- package/CapSkeleton/index.js +0 -1
- package/CapSpin/CapSpin.js +0 -23
- package/CapSpin/index.js +0 -1
- package/CapTestSelect/CapTestSelect.js +0 -47
- package/CapTestSelect/index.js +0 -1
- package/CapTooltipWithInfo/CapTooltipWithInfo.js +0 -82
- package/CapTooltipWithInfo/index.js +0 -3
- package/CapTooltipWithInfo/styles.js +0 -22
- package/assets/upload.svg +0 -3
- package/utils/index.js +0 -1
- package/utils/withStyles.js +0 -24
package/CapSpin/CapSpin.js
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CapSpin - Migrated to Ant Design v5
|
|
3
|
-
*/
|
|
4
|
-
import React from 'react';
|
|
5
|
-
import PropTypes from 'prop-types';
|
|
6
|
-
import { Spin } from 'antd-v5';
|
|
7
|
-
|
|
8
|
-
const CapSpin = ({ className, ...rest }) => (
|
|
9
|
-
<Spin className={className} {...rest} />
|
|
10
|
-
);
|
|
11
|
-
|
|
12
|
-
CapSpin.propTypes = {
|
|
13
|
-
className: PropTypes.string,
|
|
14
|
-
size: PropTypes.oneOf(['small', 'default', 'large']),
|
|
15
|
-
spinning: PropTypes.bool,
|
|
16
|
-
tip: PropTypes.string,
|
|
17
|
-
delay: PropTypes.number,
|
|
18
|
-
indicator: PropTypes.node,
|
|
19
|
-
fullscreen: PropTypes.bool,
|
|
20
|
-
wrapperClassName: PropTypes.string
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
export default CapSpin;
|
package/CapSpin/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './CapSpin';
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import PropTypes from 'prop-types';
|
|
3
|
-
import { Select } from 'antd-v5';
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Test component to verify Ant Design v5 Select integration
|
|
7
|
-
* This is a simple wrapper for testing purposes only
|
|
8
|
-
*/
|
|
9
|
-
const CapTestSelect = (props) => {
|
|
10
|
-
return <Select {...props} />;
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
CapTestSelect.propTypes = {
|
|
14
|
-
// Common Select props from antd
|
|
15
|
-
allowClear: PropTypes.bool,
|
|
16
|
-
defaultValue: PropTypes.oneOfType([
|
|
17
|
-
PropTypes.string,
|
|
18
|
-
PropTypes.number,
|
|
19
|
-
PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number]))
|
|
20
|
-
]),
|
|
21
|
-
disabled: PropTypes.bool,
|
|
22
|
-
loading: PropTypes.bool,
|
|
23
|
-
mode: PropTypes.oneOf(['multiple', 'tags']),
|
|
24
|
-
placeholder: PropTypes.string,
|
|
25
|
-
showSearch: PropTypes.bool,
|
|
26
|
-
value: PropTypes.oneOfType([
|
|
27
|
-
PropTypes.string,
|
|
28
|
-
PropTypes.number,
|
|
29
|
-
PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number]))
|
|
30
|
-
]),
|
|
31
|
-
options: PropTypes.arrayOf(
|
|
32
|
-
PropTypes.shape({
|
|
33
|
-
label: PropTypes.node,
|
|
34
|
-
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
|
|
35
|
-
disabled: PropTypes.bool
|
|
36
|
-
})
|
|
37
|
-
)
|
|
38
|
-
};
|
|
39
|
-
|
|
40
|
-
CapTestSelect.defaultProps = {
|
|
41
|
-
allowClear: false,
|
|
42
|
-
disabled: false,
|
|
43
|
-
loading: false,
|
|
44
|
-
showSearch: false
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
export default CapTestSelect;
|
package/CapTestSelect/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './CapTestSelect';
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import PropTypes from 'prop-types';
|
|
3
|
-
import classnames from 'classnames';
|
|
4
|
-
import { CapTooltip, CapIcon } from '../';
|
|
5
|
-
import withStyles from '../utils/withStyles';
|
|
6
|
-
import { tooltipWithInfoStyles } from './styles';
|
|
7
|
-
|
|
8
|
-
/**
|
|
9
|
-
* CapTooltipWithInfo - A component that combines an info icon with a tooltip
|
|
10
|
-
* for displaying additional information on hover or other trigger events.
|
|
11
|
-
*/
|
|
12
|
-
const CapTooltipWithInfo = ({
|
|
13
|
-
title,
|
|
14
|
-
iconSize = 's',
|
|
15
|
-
iconType = 'info-circle',
|
|
16
|
-
placement = 'top',
|
|
17
|
-
trigger = 'hover',
|
|
18
|
-
className = '',
|
|
19
|
-
tooltipProps = {},
|
|
20
|
-
iconProps = {},
|
|
21
|
-
...rest
|
|
22
|
-
}) => {
|
|
23
|
-
return (
|
|
24
|
-
<span
|
|
25
|
-
className={classnames('cap-tooltip-with-info', className)}
|
|
26
|
-
{...rest}
|
|
27
|
-
>
|
|
28
|
-
<CapTooltip
|
|
29
|
-
title={title}
|
|
30
|
-
placement={placement}
|
|
31
|
-
trigger={trigger}
|
|
32
|
-
{...tooltipProps}
|
|
33
|
-
>
|
|
34
|
-
<span className="cap-tooltip-with-info-icon">
|
|
35
|
-
<CapIcon
|
|
36
|
-
type={iconType}
|
|
37
|
-
size={iconSize}
|
|
38
|
-
{...iconProps}
|
|
39
|
-
/>
|
|
40
|
-
</span>
|
|
41
|
-
</CapTooltip>
|
|
42
|
-
</span>
|
|
43
|
-
);
|
|
44
|
-
};
|
|
45
|
-
|
|
46
|
-
CapTooltipWithInfo.propTypes = {
|
|
47
|
-
/** Content to display in the tooltip */
|
|
48
|
-
title: PropTypes.oneOfType([PropTypes.string, PropTypes.node]).isRequired,
|
|
49
|
-
/** Size of the info icon */
|
|
50
|
-
iconSize: PropTypes.oneOf(['xs', 's', 'm', 'l']),
|
|
51
|
-
/** Type of icon to display */
|
|
52
|
-
iconType: PropTypes.string,
|
|
53
|
-
/** Placement of the tooltip relative to the icon */
|
|
54
|
-
placement: PropTypes.oneOf([
|
|
55
|
-
'top', 'left', 'right', 'bottom',
|
|
56
|
-
'topLeft', 'topRight', 'bottomLeft', 'bottomRight',
|
|
57
|
-
'leftTop', 'leftBottom', 'rightTop', 'rightBottom',
|
|
58
|
-
]),
|
|
59
|
-
/** How the tooltip is triggered */
|
|
60
|
-
trigger: PropTypes.oneOfType([
|
|
61
|
-
PropTypes.string,
|
|
62
|
-
PropTypes.arrayOf(PropTypes.string),
|
|
63
|
-
]),
|
|
64
|
-
/** Additional class name */
|
|
65
|
-
className: PropTypes.string,
|
|
66
|
-
/** Additional props passed to the CapTooltip component */
|
|
67
|
-
tooltipProps: PropTypes.object,
|
|
68
|
-
/** Additional props passed to the CapIcon component */
|
|
69
|
-
iconProps: PropTypes.object,
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
CapTooltipWithInfo.defaultProps = {
|
|
73
|
-
iconSize: 's',
|
|
74
|
-
iconType: 'info-circle',
|
|
75
|
-
placement: 'top',
|
|
76
|
-
trigger: 'hover',
|
|
77
|
-
className: '',
|
|
78
|
-
tooltipProps: {},
|
|
79
|
-
iconProps: {},
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
export default withStyles(CapTooltipWithInfo, tooltipWithInfoStyles);
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { css } from 'styled-components';
|
|
2
|
-
import * as styledVars from '../styled/variables';
|
|
3
|
-
|
|
4
|
-
export const tooltipWithInfoStyles = css`
|
|
5
|
-
&.cap-tooltip-with-info {
|
|
6
|
-
display: inline-flex;
|
|
7
|
-
align-items: center;
|
|
8
|
-
cursor: default;
|
|
9
|
-
|
|
10
|
-
.cap-tooltip-with-info-icon {
|
|
11
|
-
color: ${styledVars.CAP_G06};
|
|
12
|
-
margin-left: 4px;
|
|
13
|
-
cursor: help;
|
|
14
|
-
|
|
15
|
-
&:hover {
|
|
16
|
-
color: ${styledVars.CAP_G07};
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
`;
|
|
21
|
-
|
|
22
|
-
export default tooltipWithInfoStyles;
|
package/assets/upload.svg
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
<svg width="16" height="18" viewBox="0 0 16 18" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
-
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.00031 13.0631V3.79511L4.46431 6.33111C4.07431 6.72111 3.44131 6.72111 3.05031 6.33111C2.65931 5.94011 2.65931 5.30711 3.05031 4.91611L7.29331 0.674109C7.68331 0.283109 8.31631 0.283109 8.70731 0.674109L12.9493 4.91611C13.3403 5.30711 13.3403 5.94011 12.9493 6.33111C12.5593 6.72111 11.9263 6.72111 11.5353 6.33111L9.00031 3.79511V13.0631C9.00031 13.5761 8.55231 13.9911 8.00031 13.9911C7.44731 13.9911 7.00031 13.5761 7.00031 13.0631ZM14.9975 12.9942C15.5495 12.9942 15.9975 13.4412 15.9975 13.9942V16.9302C15.9985 16.9502 15.9995 16.9712 15.9995 16.9912C15.9995 17.0342 15.9965 17.0772 15.9895 17.1192C15.9285 17.6122 15.5075 17.9942 14.9975 17.9942C14.9565 17.9942 14.9175 17.9922 14.8785 17.9872C14.8405 17.9902 14.8015 17.9912 14.7625 17.9912H1.23751C1.21394 17.9912 1.19217 17.9861 1.1704 17.981C1.15245 17.9768 1.13449 17.9726 1.11551 17.9712C1.10076 17.9725 1.0868 17.9767 1.07275 17.9809C1.05538 17.986 1.03786 17.9912 1.01851 17.9912C0.606512 17.9912 0.253512 17.7412 0.101512 17.3852C0.0365117 17.2642 -0.000488281 17.1312 -0.000488281 16.9912C-0.000488281 16.9769 0.00426292 16.9638 0.00903728 16.9506C0.013294 16.9388 0.017569 16.9269 0.0185117 16.9142V13.9912C0.0185117 13.4382 0.466512 12.9912 1.01851 12.9912C1.57151 12.9912 2.01851 13.4382 2.01851 13.9912V15.9912H13.9975V13.9942C13.9975 13.4412 14.4455 12.9942 14.9975 12.9942Z" fill="#2466EA"/>
|
|
3
|
-
</svg>
|
package/utils/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as withStyles } from './withStyles';
|
package/utils/withStyles.js
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import styled from 'styled-components';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Enhances a React component with additional styles using styled-components.
|
|
5
|
-
* @param {React.ComponentType} WrappedComponent - The React component to enhance.
|
|
6
|
-
* @param {TemplateStringsArray} styles - CSS styles as a TemplateStringsArray.
|
|
7
|
-
* @returns {React.ComponentType} Returns the enhanced styled component.
|
|
8
|
-
*/
|
|
9
|
-
const withStyledComponent = (WrappedComponent, styles) => {
|
|
10
|
-
/**
|
|
11
|
-
* A styled component generated by combining WrappedComponent with additional styles.
|
|
12
|
-
* @type {React.ComponentType}
|
|
13
|
-
*/
|
|
14
|
-
const StyledComponent = styled(WrappedComponent)`
|
|
15
|
-
${styles};
|
|
16
|
-
`;
|
|
17
|
-
|
|
18
|
-
// Set default props from the original component to the styled component
|
|
19
|
-
StyledComponent.defaultProps = WrappedComponent.defaultProps;
|
|
20
|
-
|
|
21
|
-
return StyledComponent;
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
export default withStyledComponent;
|