@homebound/beam 3.0.4 → 3.0.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.
- package/dist/index.cjs +5 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -3
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -8234,7 +8234,7 @@ function TextFieldBase(props) {
|
|
|
8234
8234
|
maybeTooltip({
|
|
8235
8235
|
title: tooltip,
|
|
8236
8236
|
placement: "top",
|
|
8237
|
-
children: inputProps.readOnly ? /* @__PURE__ */ jsxs18("div", { ...
|
|
8237
|
+
children: inputProps.readOnly ? /* @__PURE__ */ jsxs18("div", { ...trussProps20({
|
|
8238
8238
|
// Use input wrapper to get common styles, but then we need to override some
|
|
8239
8239
|
...fieldStyles.inputWrapperReadOnly,
|
|
8240
8240
|
...multiline ? {
|
|
@@ -8242,7 +8242,7 @@ function TextFieldBase(props) {
|
|
|
8242
8242
|
alignItems: "aifs",
|
|
8243
8243
|
gap: "gap2"
|
|
8244
8244
|
} : {
|
|
8245
|
-
|
|
8245
|
+
...!wrap ? {
|
|
8246
8246
|
whiteSpace: "wsnw",
|
|
8247
8247
|
overflow: "oh",
|
|
8248
8248
|
textOverflow: "to_ellipsis"
|
|
@@ -12591,6 +12591,7 @@ function NumberField(props) {
|
|
|
12591
12591
|
wip: false
|
|
12592
12592
|
});
|
|
12593
12593
|
const lastSentRef = useRef27(void 0);
|
|
12594
|
+
const focusValueRef = useRef27(void 0);
|
|
12594
12595
|
const [, forceRender] = useState23(0);
|
|
12595
12596
|
const propValue = value === void 0 ? Number.NaN : value / factor;
|
|
12596
12597
|
if (valueRef.current.wip && !Object.is(valueRef.current.value, propValue)) {
|
|
@@ -12606,7 +12607,7 @@ function NumberField(props) {
|
|
|
12606
12607
|
// // This is called on blur with the final/committed value.
|
|
12607
12608
|
onChange: (value2) => {
|
|
12608
12609
|
const formatted = formatValue(value2, factor, numFractionDigits, numIntegerDigits, positiveOnly);
|
|
12609
|
-
if (formatted !== lastSentRef.current) return;
|
|
12610
|
+
if (formatted !== lastSentRef.current && formatted === focusValueRef.current) return;
|
|
12610
12611
|
onChange(formatted);
|
|
12611
12612
|
},
|
|
12612
12613
|
onFocus: () => {
|
|
@@ -12615,6 +12616,7 @@ function NumberField(props) {
|
|
|
12615
12616
|
value: value === void 0 ? Number.NaN : value / factor
|
|
12616
12617
|
};
|
|
12617
12618
|
lastSentRef.current = value;
|
|
12619
|
+
focusValueRef.current = value;
|
|
12618
12620
|
},
|
|
12619
12621
|
onBlur: () => {
|
|
12620
12622
|
valueRef.current = {
|