@madie/madie-design-system 1.2.4 → 1.2.6

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.
@@ -35,7 +35,7 @@ const Label = ({ required, disabled, error, ...rest }) => {
35
35
  },
36
36
  },
37
37
  disabled && {
38
- color: "rgba(0,0,0,0.6)",
38
+ color: "#333333 !important",
39
39
  },
40
40
  error && {
41
41
  color: "#AE1C1C !important",
@@ -1,5 +1,7 @@
1
1
  import React from "react";
2
- import { FormControl, TextField as MUITextField } from "@mui/material";
2
+ import { FormControl, TextField as MUITextField,
3
+ FormHelperText,
4
+ } from "@mui/material";
3
5
  import InputLabel from "../InputLabel";
4
6
  import PropTypes from "prop-types";
5
7
 
@@ -23,6 +25,26 @@ const ReadOnlyTextField = ({
23
25
  >
24
26
  {label}
25
27
  </InputLabel>
28
+ {helperText && (
29
+ <FormHelperText
30
+ tabIndex={0}
31
+ aria-live="polite"
32
+ id={`${id}-helper-text`}
33
+ data-testid={`${id}-helper-text`}
34
+ sx={[
35
+ {
36
+ margin: "4px 0px 0px 0px",
37
+ color: "#515151",
38
+ lineHeight: 1,
39
+ },
40
+ error && {
41
+ color: "#AE1C1C !important",
42
+ },
43
+ ]}
44
+ >
45
+ {helperText}
46
+ </FormHelperText>
47
+ )}
26
48
  <MUITextField
27
49
  sx={{
28
50
  height: 40, //there's a .13 coming from somewhere.
@@ -39,8 +61,10 @@ const ReadOnlyTextField = ({
39
61
  disableUnderline: true,
40
62
  fontSize: 16,
41
63
  padding: "9px 0px",
64
+ color: "#333",
42
65
  "&::placeholder": {
43
- opacity: 0.6,
66
+ opacity: 1,
67
+ color: "#333",
44
68
  },
45
69
  "&:focus": {
46
70
  border: "none",
@@ -59,7 +83,6 @@ const ReadOnlyTextField = ({
59
83
  id={id}
60
84
  {...rest}
61
85
  />
62
- {helperText && helperText}
63
86
  </FormControl>
64
87
  );
65
88
  };
@@ -53,13 +53,12 @@ export const Disabled = () => (
53
53
  <Wrapper>
54
54
  <TextField
55
55
  placeholder="Placeholder"
56
- label="Text Label"
56
+ label="Disabled Text Label"
57
57
  id="measureName"
58
58
  inputProps={{ "data-testid": "measure-name-input" }}
59
59
  data-testid="measure-name-text-field"
60
60
  size="small"
61
61
  disabled
62
- required
63
62
  />
64
63
  </Wrapper>
65
64
  );