@pie-lib/config-ui 11.2.2 → 11.3.1-next.2

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.
Files changed (42) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/lib/checkbox.js +2 -2
  3. package/lib/checkbox.js.map +1 -1
  4. package/lib/choice-configuration/feedback-menu.js.map +1 -1
  5. package/lib/choice-configuration/index.js +5 -5
  6. package/lib/choice-configuration/index.js.map +1 -1
  7. package/lib/feedback-config/feedback-selector.js +2 -2
  8. package/lib/feedback-config/feedback-selector.js.map +1 -1
  9. package/lib/feedback-config/group.js +2 -2
  10. package/lib/feedback-config/group.js.map +1 -1
  11. package/lib/help.js +7 -5
  12. package/lib/help.js.map +1 -1
  13. package/lib/inputs.js +11 -9
  14. package/lib/inputs.js.map +1 -1
  15. package/lib/langs.js.map +1 -1
  16. package/lib/layout/config-layout.js +17 -10
  17. package/lib/layout/config-layout.js.map +1 -1
  18. package/lib/layout/settings-box.js +3 -3
  19. package/lib/layout/settings-box.js.map +1 -1
  20. package/lib/settings/panel.js +49 -43
  21. package/lib/settings/panel.js.map +1 -1
  22. package/lib/settings/settings-radio-label.js +9 -7
  23. package/lib/settings/settings-radio-label.js.map +1 -1
  24. package/lib/settings/toggle.js +1 -1
  25. package/lib/settings/toggle.js.map +1 -1
  26. package/lib/tags-input/index.js +2 -2
  27. package/lib/tags-input/index.js.map +1 -1
  28. package/package.json +3 -3
  29. package/src/checkbox.jsx +2 -2
  30. package/src/choice-configuration/feedback-menu.jsx +0 -3
  31. package/src/choice-configuration/index.jsx +5 -5
  32. package/src/feedback-config/feedback-selector.jsx +2 -2
  33. package/src/feedback-config/group.jsx +2 -2
  34. package/src/help.jsx +3 -3
  35. package/src/inputs.jsx +5 -5
  36. package/src/langs.jsx +4 -0
  37. package/src/layout/config-layout.jsx +4 -1
  38. package/src/layout/settings-box.jsx +3 -3
  39. package/src/settings/panel.jsx +21 -21
  40. package/src/settings/settings-radio-label.jsx +3 -3
  41. package/src/settings/toggle.jsx +1 -1
  42. package/src/tags-input/index.jsx +2 -2
@@ -61,10 +61,10 @@ const Radio = ({ classes, label, value, onChange, choices }) => {
61
61
 
62
62
  Radio.propTypes = { ...baseTypes, choices: PropTypes.arrayOf(PropTypes.shape(labelValue)) };
63
63
 
64
- const StyledRadio = withStyles({
64
+ const StyledRadio = withStyles((theme) => ({
65
65
  radioSettings: {
66
- marginTop: '4px',
67
- paddingBottom: '4px',
66
+ marginTop: theme.spacing.unit / 2,
67
+ paddingBottom: theme.spacing.unit / 2,
68
68
  width: '100%',
69
69
  '& > label': {
70
70
  color: 'rgba(0, 0, 0, 0.89)',
@@ -72,26 +72,26 @@ const StyledRadio = withStyles({
72
72
  fontSize: '14px',
73
73
  },
74
74
  '& > div': {
75
- marginTop: '20px',
75
+ marginTop: theme.spacing.unit * 2.5,
76
76
  },
77
77
  },
78
78
  label: {
79
79
  display: 'none',
80
80
  },
81
- })(Radio);
81
+ }))(Radio);
82
82
 
83
- const Dropdown = withStyles({
83
+ const Dropdown = withStyles((theme) => ({
84
84
  label: {
85
85
  margin: 0,
86
- fontSize: '14px',
86
+ fontSize: theme.typography.fontSize,
87
87
  },
88
88
  wrapper: {
89
- marginTop: '4px',
89
+ marginTop: theme.spacing.unit / 2,
90
90
  border: '2px solid lightgrey',
91
91
  borderRadius: '4px',
92
- padding: '0 8px',
92
+ padding: `0 ${theme.spacing.unit}px`,
93
93
  },
94
- })(({ classes, label, value, onChange, choices = [] }) => {
94
+ }))(({ classes, label, value, onChange, choices = [] }) => {
95
95
  return (
96
96
  <div>
97
97
  {label && <p className={classes.label}>{label}</p>}
@@ -114,19 +114,19 @@ const Dropdown = withStyles({
114
114
 
115
115
  Dropdown.propTypes = { ...baseTypes, choices: PropTypes.arrayOf(PropTypes.string) };
116
116
 
117
- const NumberField = withStyles({
117
+ const NumberField = withStyles((theme) => ({
118
118
  field: {
119
119
  width: '35%',
120
- marginRight: '24px',
121
- marginTop: '8px',
120
+ marginRight: theme.spacing.unit * 3,
121
+ marginTop: theme.spacing.unit,
122
122
  },
123
123
  wrapper: {
124
- marginTop: '4px',
124
+ marginTop: theme.spacing.unit / 2,
125
125
  border: '2px solid lightgrey',
126
126
  borderRadius: '4px',
127
- padding: '0 8px',
127
+ padding: `0 ${theme.spacing.unit}px`,
128
128
  },
129
- })(({ classes, label, value, onChange = () => {}, suffix, min, max }) => {
129
+ }))(({ classes, label, value, onChange = () => {}, suffix, min, max }) => {
130
130
  return (
131
131
  <NumberTextField
132
132
  label={label || 'Label'}
@@ -164,18 +164,18 @@ const tagMap = {
164
164
  checkbox: CheckboxChoice,
165
165
  };
166
166
 
167
- const Group = withStyles(() => ({
167
+ const Group = withStyles((theme) => ({
168
168
  group: {
169
- margin: '0 0 16px 0',
169
+ margin: `0 0 ${theme.spacing.unit * 2}px 0`,
170
170
  },
171
171
  groupHeader: {
172
172
  color: '#495B8F',
173
- fontSize: '16px',
173
+ fontSize: theme.typography.fontSize + 2,
174
174
  fontWeight: 600,
175
- marginBottom: '8px',
175
+ marginBottom: theme.spacing.unit,
176
176
  },
177
177
  numberFields: {
178
- fontSize: '0.85rem',
178
+ fontSize: theme.typography.fontSize,
179
179
  marginBottom: 0,
180
180
  },
181
181
  }))((props) => {
@@ -3,14 +3,14 @@ import Radio from '@material-ui/core/Radio';
3
3
  import React from 'react';
4
4
  import { withStyles } from '@material-ui/core/styles';
5
5
 
6
- export default withStyles({
6
+ export default withStyles((theme) => ({
7
7
  label: {
8
8
  color: 'rgba(0, 0, 0, 0.89)',
9
- fontSize: '12px',
9
+ fontSize: theme.typography.fontSize - 2,
10
10
  left: '-5px',
11
11
  position: 'relative',
12
12
  },
13
- })(({ label, value, checked, onChange, classes }) => (
13
+ }))(({ label, value, checked, onChange, classes }) => (
14
14
  <FormControlLabel
15
15
  value={value}
16
16
  classes={classes}
@@ -12,7 +12,7 @@ const Toggle = withStyles((theme) => ({
12
12
  },
13
13
  label: {
14
14
  color: 'rgba(0, 0, 0, 0.89)',
15
- fontSize: '14px',
15
+ fontSize: theme.typography.fontSize,
16
16
  paddingTop: theme.spacing.unit * 2,
17
17
  },
18
18
  }))(({ checked, label, toggle, classes }) => (
@@ -95,7 +95,7 @@ export class TagsInput extends React.Component {
95
95
 
96
96
  const styles = (theme) => ({
97
97
  tagsInput: {
98
- border: 'solid 0px white',
98
+ border: `0px solid ${theme.palette.background.paper}`,
99
99
  display: 'flex',
100
100
  flexWrap: 'wrap',
101
101
  },
@@ -105,7 +105,7 @@ const styles = (theme) => ({
105
105
  minWidth: '30px',
106
106
  width: '100%',
107
107
  flex: '1',
108
- border: 'solid 0px white',
108
+ border: `0px solid ${theme.palette.background.paper}`,
109
109
  height: '28px',
110
110
  fontSize: theme.typography.fontSize,
111
111
  fontFamily: theme.typography.fontFamily,