Skip to content

Commit 2668879

Browse files
committed
Added the prop to the textfield api
1 parent 41da913 commit 2668879

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/incubator/TextField/__tests__/index.spec.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,13 +97,13 @@ describe('TextField', () => {
9797
const text = label.children[0];
9898
expect(text).toEqual('Label*');
9999
});
100-
it('Should not show mandatory star indication - 3', () => {
100+
it('Should not show mandatory star indication - 1', () => {
101101
const renderTree = render(<TestCase testID={'field'} validate={['email', 'required']} label={'Label'}/>);
102102
const label = renderTree.getByTestId('field.label');
103103
const text = label.children[0];
104104
expect(text).not.toEqual('Label*');
105105
});
106-
it('Should not show mandatory star indication - 3', () => {
106+
it('Should not show mandatory star indication - 2', () => {
107107
const renderTree = render(<TestCase testID={'field'} validate={['email']} label={'Label'} showMandatoryIndication/>);
108108
const label = renderTree.getByTestId('field.label');
109109
const text = label.children[0];

src/incubator/TextField/textField.api.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,8 @@
115115
"type": "boolean",
116116
"description": "A UI preset for read only state"
117117
},
118-
{"name": "recorderTag", "type": "'mask' | 'unmask'", "description": "Recorder Tag"}
118+
{"name": "recorderTag", "type": "'mask' | 'unmask'", "description": "Recorder Tag"},
119+
{"name": "showMandatoryIndication", "type": "boolean", "description": "Whether this field should show a mandatory field indication"}
119120
],
120121
"snippet": [
121122
"<TextField",

0 commit comments

Comments
 (0)