@dhis2-ui/input 9.11.2 → 9.11.4
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.
|
@@ -7,9 +7,9 @@ exports.InputFieldProps = exports.InputField = void 0;
|
|
|
7
7
|
var _uiConstants = require("@dhis2/ui-constants");
|
|
8
8
|
var _box = require("@dhis2-ui/box");
|
|
9
9
|
var _field = require("@dhis2-ui/field");
|
|
10
|
-
var _input = require("@dhis2-ui/input");
|
|
11
10
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
12
11
|
var _react = _interopRequireDefault(require("react"));
|
|
12
|
+
var _index = require("../input/index.js");
|
|
13
13
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
14
14
|
class InputField extends _react.default.Component {
|
|
15
15
|
render() {
|
|
@@ -58,7 +58,7 @@ class InputField extends _react.default.Component {
|
|
|
58
58
|
}, /*#__PURE__*/_react.default.createElement(_box.Box, {
|
|
59
59
|
width: inputWidth,
|
|
60
60
|
minWidth: "72px"
|
|
61
|
-
}, /*#__PURE__*/_react.default.createElement(
|
|
61
|
+
}, /*#__PURE__*/_react.default.createElement(_index.Input, {
|
|
62
62
|
onFocus: onFocus,
|
|
63
63
|
onKeyDown: onKeyDown,
|
|
64
64
|
onBlur: onBlur,
|
|
@@ -124,7 +124,7 @@ const InputFieldProps = exports.InputFieldProps = {
|
|
|
124
124
|
step: _propTypes.default.string,
|
|
125
125
|
tabIndex: _propTypes.default.string,
|
|
126
126
|
/** Type of input */
|
|
127
|
-
type:
|
|
127
|
+
type: _index.Input.propTypes.type,
|
|
128
128
|
/** Applies 'valid' appearance for validation feedback. Mutually exclusive with `error` and `warning` props */
|
|
129
129
|
valid: _uiConstants.sharedPropTypes.statusPropType,
|
|
130
130
|
/** Text below input for validation feedback. Receives styles depending on validation status */
|
|
@@ -142,11 +142,11 @@ Dense.args = {
|
|
|
142
142
|
};
|
|
143
143
|
const InputWidth = args => /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_index.InputField, _extends({}, args, {
|
|
144
144
|
name: "input1",
|
|
145
|
-
label: "My
|
|
145
|
+
label: "My inputField has a width of 100px",
|
|
146
146
|
inputWidth: "100px"
|
|
147
147
|
})), /*#__PURE__*/_react.default.createElement(_index.InputField, _extends({}, args, {
|
|
148
148
|
name: "input2",
|
|
149
|
-
label: "My
|
|
149
|
+
label: "My inputField has a width of 220px",
|
|
150
150
|
inputWidth: "220px"
|
|
151
151
|
})));
|
|
152
152
|
exports.InputWidth = InputWidth;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { sharedPropTypes } from '@dhis2/ui-constants';
|
|
2
2
|
import { Box } from '@dhis2-ui/box';
|
|
3
3
|
import { Field } from '@dhis2-ui/field';
|
|
4
|
-
import { Input } from '@dhis2-ui/input';
|
|
5
4
|
import PropTypes from 'prop-types';
|
|
6
5
|
import React from 'react';
|
|
6
|
+
import { Input } from '../input/index.js';
|
|
7
7
|
class InputField extends React.Component {
|
|
8
8
|
render() {
|
|
9
9
|
const {
|
|
@@ -135,11 +135,11 @@ Dense.args = {
|
|
|
135
135
|
};
|
|
136
136
|
export const InputWidth = args => /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(InputField, _extends({}, args, {
|
|
137
137
|
name: "input1",
|
|
138
|
-
label: "My
|
|
138
|
+
label: "My inputField has a width of 100px",
|
|
139
139
|
inputWidth: "100px"
|
|
140
140
|
})), /*#__PURE__*/React.createElement(InputField, _extends({}, args, {
|
|
141
141
|
name: "input2",
|
|
142
|
-
label: "My
|
|
142
|
+
label: "My inputField has a width of 220px",
|
|
143
143
|
inputWidth: "220px"
|
|
144
144
|
})));
|
|
145
145
|
export const LabelTextOverflow = Template.bind({});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dhis2-ui/input",
|
|
3
|
-
"version": "9.11.
|
|
3
|
+
"version": "9.11.4",
|
|
4
4
|
"description": "UI Input",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -33,13 +33,13 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@dhis2/prop-types": "^3.1.2",
|
|
36
|
-
"@dhis2-ui/box": "9.11.
|
|
37
|
-
"@dhis2-ui/field": "9.11.
|
|
38
|
-
"@dhis2-ui/input": "9.11.
|
|
39
|
-
"@dhis2-ui/loader": "9.11.
|
|
40
|
-
"@dhis2-ui/status-icon": "9.11.
|
|
41
|
-
"@dhis2/ui-constants": "9.11.
|
|
42
|
-
"@dhis2/ui-icons": "9.11.
|
|
36
|
+
"@dhis2-ui/box": "9.11.4",
|
|
37
|
+
"@dhis2-ui/field": "9.11.4",
|
|
38
|
+
"@dhis2-ui/input": "9.11.4",
|
|
39
|
+
"@dhis2-ui/loader": "9.11.4",
|
|
40
|
+
"@dhis2-ui/status-icon": "9.11.4",
|
|
41
|
+
"@dhis2/ui-constants": "9.11.4",
|
|
42
|
+
"@dhis2/ui-icons": "9.11.4",
|
|
43
43
|
"classnames": "^2.3.1",
|
|
44
44
|
"prop-types": "^15.7.2"
|
|
45
45
|
},
|