groundfloor-react-ui 1.0.11 → 1.0.14
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 +6 -1
- package/assets/icons/default.svg +1 -0
- package/components/Button/PrimaryButton.js +1 -0
- package/components/Button/SecondaryButton.js +1 -0
- package/components/Button/TinyButton.js +1 -0
- package/components/Form/FormComponent.js +6 -1
- package/components/Form/HeaderComponent.js +3 -3
- package/components/GroupButtons/ButtonPopup.js +0 -1
- package/components/Icon/Icon.js +2 -0
- package/components/Inputs/DateSelect.js +212 -213
- package/components/Inputs/PasswordInput.js +6 -3
- package/components/Inputs/TextInput.js +12 -0
- package/components/Modal/ModalComp.js +1 -1
- package/components/Overlay/Overlay.js +0 -1
- package/components/Tooltip/Tooltip.js +0 -1
- package/dist/index.es.js +131 -122
- package/dist/index.js +69 -60
- package/package.json +1 -1
|
@@ -32,6 +32,8 @@ const TextWrapper = styled.div`
|
|
|
32
32
|
|
|
33
33
|
// custom styles
|
|
34
34
|
${({ textBoxStyle }) => textBoxStyle}
|
|
35
|
+
|
|
36
|
+
background-color: ${({ isDisabled }) => isDisabled ? defaultThemeColor.variant['neutral-5'] : defaultThemeColor.bgColor}
|
|
35
37
|
`;
|
|
36
38
|
|
|
37
39
|
const Input = styled.input`
|
|
@@ -47,6 +49,7 @@ const Input = styled.input`
|
|
|
47
49
|
.sc-furwcr bxRAoq {
|
|
48
50
|
color: ${defaultThemeColor.variant['neutral-3']};
|
|
49
51
|
}
|
|
52
|
+
background-color: ${({ isDisabled }) => isDisabled ? defaultThemeColor.variant['neutral-5'] : defaultThemeColor.bgColor}
|
|
50
53
|
`;
|
|
51
54
|
|
|
52
55
|
const inline = css`
|
|
@@ -81,6 +84,7 @@ export const TextInput = ({
|
|
|
81
84
|
iconAfter,
|
|
82
85
|
isValid,
|
|
83
86
|
type,
|
|
87
|
+
isDisabled,
|
|
84
88
|
...props
|
|
85
89
|
}) => {
|
|
86
90
|
return (
|
|
@@ -113,6 +117,7 @@ export const TextInput = ({
|
|
|
113
117
|
<TextWrapper
|
|
114
118
|
required={required}
|
|
115
119
|
themeColor={defaultThemeColor}
|
|
120
|
+
isDisabled={isDisabled}
|
|
116
121
|
textBoxStyle={textBoxStyle}
|
|
117
122
|
isValid={isValid}
|
|
118
123
|
theme={defaultStyles}
|
|
@@ -124,6 +129,8 @@ export const TextInput = ({
|
|
|
124
129
|
inputStyle={inputStyle}
|
|
125
130
|
type={type}
|
|
126
131
|
defaultInputStyle={'input-wrapper'}
|
|
132
|
+
isDisabled={isDisabled}
|
|
133
|
+
disabled={isDisabled}
|
|
127
134
|
{...props}
|
|
128
135
|
/>
|
|
129
136
|
<div className='input-icon'>{iconAfter}</div>
|
|
@@ -182,6 +189,10 @@ TextInput.propTypes = {
|
|
|
182
189
|
* input type i.e:- text, password
|
|
183
190
|
*/
|
|
184
191
|
type: PropTypes.string,
|
|
192
|
+
/**
|
|
193
|
+
* input field disabled or not
|
|
194
|
+
*/
|
|
195
|
+
isDisabled: PropTypes.bool,
|
|
185
196
|
};
|
|
186
197
|
|
|
187
198
|
TextInput.defaultProps = {
|
|
@@ -198,4 +209,5 @@ TextInput.defaultProps = {
|
|
|
198
209
|
labelStyle: {},
|
|
199
210
|
inputStyle: {},
|
|
200
211
|
type: 'text',
|
|
212
|
+
isDisabled: false
|
|
201
213
|
};
|
|
@@ -3,7 +3,6 @@ import PropTypes from 'prop-types';
|
|
|
3
3
|
import styled from 'styled-components';
|
|
4
4
|
import defaultStyles from '../constants/defaultStyle';
|
|
5
5
|
import { usePopperTooltip } from 'react-popper-tooltip';
|
|
6
|
-
// import 'react-popper-tooltip/dist/styles.css';
|
|
7
6
|
|
|
8
7
|
/**
|
|
9
8
|
* Primary UI component for user interaction
|
|
@@ -3,7 +3,6 @@ import PropTypes from 'prop-types';
|
|
|
3
3
|
import styled from 'styled-components';
|
|
4
4
|
import defaultStyles from '../constants/defaultStyle';
|
|
5
5
|
import { usePopperTooltip } from 'react-popper-tooltip';
|
|
6
|
-
// import 'react-popper-tooltip/dist/styles.css';
|
|
7
6
|
|
|
8
7
|
/**
|
|
9
8
|
* Primary UI component for user interaction
|