@jobber/components-native 0.95.2-JOB-141866-5052098.24 → 0.95.2-JOB-147120-dc74fc6.9

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jobber/components-native",
3
- "version": "0.95.2-JOB-141866-5052098.24+505209802",
3
+ "version": "0.95.2-JOB-147120-dc74fc6.9+dc74fc6e2",
4
4
  "license": "MIT",
5
5
  "description": "React Native implementation of Atlantis",
6
6
  "repository": {
@@ -96,5 +96,5 @@
96
96
  "react-native-safe-area-context": "^5.4.0",
97
97
  "react-native-svg": ">=12.0.0"
98
98
  },
99
- "gitHead": "5052098024ddd00b6992954ce35278a551c13ed4"
99
+ "gitHead": "dc74fc6e2f9e7c6223d3409b7927b8acb72bdc15"
100
100
  }
@@ -49,7 +49,7 @@ export function Form(_a) {
49
49
  React.createElement(ErrorMessageProvider, null, child)));
50
50
  }
51
51
  // eslint-disable-next-line max-statements
52
- function InternalForm({ children, onBeforeSubmit, onSubmit, onSubmitError, onSubmitSuccess, bannerErrors, bannerMessages, initialValues, mode = "onTouched", reValidateMode = "onChange", formRef, saveButtonLabel, renderStickySection, localCacheKey, localCacheExclude, localCacheId, secondaryActions, saveButtonOffset, showStickySaveButton = false, disableKeyboardAwareScroll = false, renderFooter, UNSAFE_allowDiscardLocalCacheWhenOffline, }) {
52
+ function InternalForm({ children, onBeforeSubmit, onSubmit, onSubmitError, onSubmitSuccess, bannerErrors, bannerMessages, initialValues, mode = "onTouched", reValidateMode = "onChange", formRef, saveButtonLabel, renderStickySection, localCacheKey, localCacheExclude, localCacheId, secondaryActions, saveButtonOffset, showStickySaveButton = false, renderFooter, UNSAFE_allowDiscardLocalCacheWhenOffline, }) {
53
53
  var _a;
54
54
  const { scrollViewRef, bottomViewRef, scrollToTop } = useFormViewRefs();
55
55
  const [saveButtonHeight, setSaveButtonHeight] = useState(0);
@@ -110,7 +110,7 @@ function InternalForm({ children, onBeforeSubmit, onSubmit, onSubmitError, onSub
110
110
  (isSubmitting || isSecondaryActionLoading) && React.createElement(FormMask, null),
111
111
  React.createElement(FormCache, { localCacheKey: localCacheKey, localCacheExclude: localCacheExclude, setLocalCache: setLocalCache }),
112
112
  React.createElement(FormBody, { keyboardHeight: calculateSaveButtonOffset(), submit: handleSubmit(internalSubmit), isFormSubmitting: isSubmitting, saveButtonLabel: saveButtonLabel, shouldRenderActionBar: saveButtonPosition === "sticky", renderStickySection: renderStickySection, secondaryActions: secondaryActions, setSecondaryActionLoading: setIsSecondaryActionLoading, setSaveButtonHeight: setSaveButtonHeight, saveButtonOffset: saveButtonOffset },
113
- React.createElement(KeyboardAwareScrollView, Object.assign({ enableResetScrollToCoords: false, enableAutomaticScroll: !disableKeyboardAwareScroll, enableOnAndroid: edgeToEdgeEnabled, keyboardOpeningTime: Platform.OS === "ios" ? tokens["timing-slowest"] : 0, keyboardShouldPersistTaps: "handled", ref: scrollViewRef }, keyboardProps, { extraHeight: headerHeight, extraScrollHeight: edgeToEdgeEnabled ? tokens["space-large"] : 0, contentContainerStyle: !keyboardHeight && styles.scrollContentContainer }),
113
+ React.createElement(KeyboardAwareScrollView, Object.assign({ enableResetScrollToCoords: false, enableAutomaticScroll: true, enableOnAndroid: edgeToEdgeEnabled, keyboardOpeningTime: Platform.OS === "ios" ? tokens["timing-slowest"] : 0, keyboardShouldPersistTaps: "handled", ref: scrollViewRef }, keyboardProps, { extraHeight: headerHeight, extraScrollHeight: edgeToEdgeEnabled ? tokens["space-large"] : 0, contentContainerStyle: !keyboardHeight && styles.scrollContentContainer }),
114
114
  React.createElement(View, { onLayout: ({ nativeEvent }) => {
115
115
  setFormContentHeight(nativeEvent.layout.height);
116
116
  } },
@@ -89,14 +89,7 @@ function InputTextInternal({ invalid, disabled, readonly = false, name, placehol
89
89
  styles.multilineWithoutMiniLabel,
90
90
  styleOverride === null || styleOverride === void 0 ? void 0 : styleOverride.inputText,
91
91
  loading && loadingType === "glimmer" && { color: "transparent" },
92
- ], readOnly: readonly, editable: !disabled, keyboardType: keyboard, value: inputTransform(internalValue), autoFocus: autoFocus, autoComplete: autoComplete, multiline: multiline,
93
- // TODO: JOB-147156 This is a HACK for multiline inputs on iOS scrolling issue.
94
- // This hack should be removed once we swap keyboard aware libraries in JOB-147156
95
- // If this is needed then we need to figure out a better solution.
96
- // Makes sure it doesn't jump to the top of the screen when the keyboard is shown and a new line is added.
97
- // This is tech debt related to an issue where keyboard aware scrollview doesn't work if `scrollEnabled` is true. However,
98
- // when `scrollEnabled` is false it causes an issue where super long text inputs will jump to the top when a new line is added to the bottom of the input.
99
- scrollEnabled: Platform.OS === "ios" && multiline, textContentType: textContentType, onChangeText: handleChangeText, onSubmitEditing: handleOnSubmitEditing, returnKeyType: returnKeyType, blurOnSubmit: shouldBlurOnSubmit, accessibilityLabel: accessibilityLabel || placeholder, accessibilityHint: accessibilityHint, accessibilityState: { busy: loading }, secureTextEntry: secureTextEntry }, androidA11yProps, { onFocus: event => {
92
+ ], readOnly: readonly, editable: !disabled, keyboardType: keyboard, value: inputTransform(internalValue), autoFocus: autoFocus, autoComplete: autoComplete, multiline: multiline, scrollEnabled: false, textContentType: textContentType, onChangeText: handleChangeText, onSubmitEditing: handleOnSubmitEditing, returnKeyType: returnKeyType, blurOnSubmit: shouldBlurOnSubmit, accessibilityLabel: accessibilityLabel || placeholder, accessibilityHint: accessibilityHint, accessibilityState: { busy: loading }, secureTextEntry: secureTextEntry }, androidA11yProps, { onFocus: event => {
100
93
  _name && setFocusedInput(_name);
101
94
  setFocused(true);
102
95
  onFocus === null || onFocus === void 0 ? void 0 : onFocus(event);