@councilbox/councilbox-ui 0.0.9 → 0.0.12
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.js +13 -6
- package/dist/components/InputPassword/InputPassword.css +11 -9
- package/dist/components/InputPassword/InputPassword.js +0 -4
- package/dist/components/InputText/InputText.css +0 -1
- package/dist/components/InputText/InputText.js +5 -5
- package/package.json +1 -1
|
@@ -17,7 +17,9 @@ require("./button.css");
|
|
|
17
17
|
|
|
18
18
|
var _CircularProgress = _interopRequireDefault(require("@mui/material/CircularProgress"));
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _Typography = _interopRequireDefault(require("../Typography/Typography"));
|
|
21
|
+
|
|
22
|
+
var _excluded = ["id", "text", "onClick", "disabled", "loading", "variant", "fullWidth", "icon", "variantText"];
|
|
21
23
|
|
|
22
24
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
23
25
|
|
|
@@ -42,6 +44,7 @@ var Button = function Button(_ref) {
|
|
|
42
44
|
variant = _ref.variant,
|
|
43
45
|
fullWidth = _ref.fullWidth,
|
|
44
46
|
icon = _ref.icon,
|
|
47
|
+
variantText = _ref.variantText,
|
|
45
48
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
46
49
|
|
|
47
50
|
var buttonVariant;
|
|
@@ -83,7 +86,8 @@ var Button = function Button(_ref) {
|
|
|
83
86
|
minWidth: !isSecondaryOrTernary(variant) ? '140px' : '100px',
|
|
84
87
|
minHeight: '48px',
|
|
85
88
|
boxShadow: 'none',
|
|
86
|
-
letterSpacing: '1px'
|
|
89
|
+
letterSpacing: '1px',
|
|
90
|
+
lineHeight: 'normal'
|
|
87
91
|
},
|
|
88
92
|
className: "cbx-button ".concat(isSecondaryOrTernary(variant) && disabled ? 'cbx-button-outlined-disabled' : '', " ").concat(buttonVariant, " ").concat(icon ? 'cbx-button-with-icon' : '', " ").concat(!isSecondaryOrTernary(variant) && "cbx-button-hoverAndAnimation".concat(fullWidth ? '-fullWidth' : '')),
|
|
89
93
|
disabled: loading || disabled,
|
|
@@ -101,8 +105,9 @@ var Button = function Button(_ref) {
|
|
|
101
105
|
startIcon: icon && icon === 'arrow' ? /*#__PURE__*/_react.default.createElement("i", {
|
|
102
106
|
className: "ri-arrow-left-s-line"
|
|
103
107
|
}) : icon
|
|
104
|
-
}, props), /*#__PURE__*/_react.default.createElement(
|
|
105
|
-
|
|
108
|
+
}, props), /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
109
|
+
color: buttonColor,
|
|
110
|
+
variant: variantText
|
|
106
111
|
}, text), buttonVariant === 'contained' && !loading && /*#__PURE__*/_react.default.createElement("span", {
|
|
107
112
|
className: "cbx-button-containerArrow"
|
|
108
113
|
}, /*#__PURE__*/_react.default.createElement("i", {
|
|
@@ -129,7 +134,8 @@ Button.propTypes = {
|
|
|
129
134
|
loading: _propTypes.default.bool,
|
|
130
135
|
variant: _propTypes.default.string,
|
|
131
136
|
fullWidth: _propTypes.default.bool,
|
|
132
|
-
icon: _propTypes.default.node
|
|
137
|
+
icon: _propTypes.default.node,
|
|
138
|
+
variantText: _propTypes.default.string
|
|
133
139
|
};
|
|
134
140
|
Button.defaultProps = {
|
|
135
141
|
backgroundColor: null,
|
|
@@ -139,7 +145,8 @@ Button.defaultProps = {
|
|
|
139
145
|
loading: false,
|
|
140
146
|
variant: 'primary',
|
|
141
147
|
fullWidth: false,
|
|
142
|
-
icon: null
|
|
148
|
+
icon: null,
|
|
149
|
+
variantText: ''
|
|
143
150
|
};
|
|
144
151
|
var _default = Button;
|
|
145
152
|
exports.default = _default;
|
|
@@ -7,20 +7,22 @@
|
|
|
7
7
|
margin-bottom: var(--spacing4);
|
|
8
8
|
|
|
9
9
|
}
|
|
10
|
+
|
|
10
11
|
.cbx-inputPassword-validation > div {
|
|
11
12
|
height: var(--spacing8);
|
|
12
13
|
border-radius: 20px;
|
|
13
14
|
transition: all .5s;
|
|
14
15
|
}
|
|
15
16
|
|
|
16
|
-
|
|
17
|
-
.cbx-inputPassword-icon-button {
|
|
18
|
-
outline: none;
|
|
19
|
-
width: var(--spacing24);
|
|
20
|
-
height: var(--spacing24);
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
.cbx-inputPassword-icon-size {
|
|
17
|
+
.cbx-inputPassword-icon-button, .cbx-inputPassword-icon-size {
|
|
24
18
|
width: var(--spacing24);
|
|
25
19
|
height: var(--spacing24);
|
|
26
|
-
|
|
20
|
+
border: none!important;
|
|
21
|
+
outline: none!important;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.cbx-inputPassword-icon-button:focus, .cbx-inputPassword-icon-size:focus {
|
|
25
|
+
border: none!important;
|
|
26
|
+
outline: none!important;
|
|
27
|
+
}
|
|
28
|
+
|
|
@@ -157,7 +157,7 @@ var InputText = function InputText(_ref2) {
|
|
|
157
157
|
id: id,
|
|
158
158
|
className: className,
|
|
159
159
|
sx: {
|
|
160
|
-
|
|
160
|
+
minWidth: width || '240px',
|
|
161
161
|
height: '48px'
|
|
162
162
|
},
|
|
163
163
|
label: label,
|
|
@@ -165,10 +165,11 @@ var InputText = function InputText(_ref2) {
|
|
|
165
165
|
onChange: onChange,
|
|
166
166
|
disabled: disabled,
|
|
167
167
|
error: error,
|
|
168
|
-
helperText: /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, helperText
|
|
168
|
+
helperText: /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, helperText, error ? /*#__PURE__*/_react.default.createElement("div", {
|
|
169
169
|
className: "cbx-inputText-items-center"
|
|
170
170
|
}, /*#__PURE__*/_react.default.createElement("i", {
|
|
171
|
-
className: 'cbx-inputText-infoBtn ri-information-line'
|
|
171
|
+
className: 'cbx-inputText-infoBtn ri-information-line',
|
|
172
|
+
color: 'var(--error600)'
|
|
172
173
|
}), /*#__PURE__*/_react.default.createElement(_Typography.default, {
|
|
173
174
|
variant: "XS",
|
|
174
175
|
color: 'var(--error600)'
|
|
@@ -208,8 +209,7 @@ InputText.defaultProps = {
|
|
|
208
209
|
className: '',
|
|
209
210
|
onChange: undefined,
|
|
210
211
|
disabled: false,
|
|
211
|
-
error: ''
|
|
212
|
-
success: false
|
|
212
|
+
error: ''
|
|
213
213
|
};
|
|
214
214
|
var _default = InputText;
|
|
215
215
|
exports.default = _default;
|