@onehat/ui 0.3.161 → 0.3.163

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onehat/ui",
3
- "version": "0.3.161",
3
+ "version": "0.3.163",
4
4
  "description": "Base UI for OneHat apps",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
@@ -56,13 +56,11 @@ function NumberElement(props) {
56
56
  }
57
57
  },
58
58
  onChangeText = (value) => {
59
- if (value.match(/\.$/)) { // if value ends with a decimal point
60
- setLocalValue(value);
61
- return;
62
- }
63
59
 
64
60
  if (value === '') {
65
61
  value = null; // empty string makes value null
62
+ } else if (value.match(/\.$/)) { // value ends with a decimal point
63
+ // don't parseFloat, otherwise we'll lose the decimal point
66
64
  } else {
67
65
  value = parseFloat(value, 10);
68
66
  }
@@ -7,6 +7,8 @@ const
7
7
 
8
8
  const defaults = {
9
9
  ATTACHMENTS_MAX_FILESIZE: 1024 * 1024 * 5, // 5MB
10
+ DEFAULT_WINDOW_WIDTH: 1000,
11
+ DEFAULT_WINDOW_HEIGHT: 800,
10
12
  FILTER_LABEL_FONTSIZE: DEFAULT_FONTSIZE,
11
13
  FORM_ANCILLARY_TITLE_FONTSIZE: 22,
12
14
  FORM_ANCILLARY_DESCRIPTION_FONTSIZE: 16,