Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Mobile-Expensify
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,8 @@ android {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled rootProject.ext.multiDexEnabled
versionCode 1009018000
versionName "9.1.80-0"
versionCode 1009018005
versionName "9.1.80-5"
// Supported language variants must be declared here to avoid from being removed during the compilation.
// This also helps us to not include unnecessary language variants in the APK.
resConfigs "en", "es"
Expand Down
2 changes: 1 addition & 1 deletion ios/NewExpensify/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>9.1.80.0</string>
<string>9.1.80.5</string>
<key>FullStory</key>
<dict>
<key>OrgId</key>
Expand Down
2 changes: 1 addition & 1 deletion ios/NotificationServiceExtension/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<key>CFBundleShortVersionString</key>
<string>9.1.80</string>
<key>CFBundleVersion</key>
<string>9.1.80.0</string>
<string>9.1.80.5</string>
<key>NSExtension</key>
<dict>
<key>NSExtensionPointIdentifier</key>
Expand Down
2 changes: 1 addition & 1 deletion ios/ShareViewController/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<key>CFBundleShortVersionString</key>
<string>9.1.80</string>
<key>CFBundleVersion</key>
<string>9.1.80.0</string>
<string>9.1.80.5</string>
<key>NSExtension</key>
<dict>
<key>NSExtensionAttributes</key>
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "new.expensify",
"version": "9.1.80-0",
"version": "9.1.80-5",
"author": "Expensify, Inc.",
"homepage": "https://new.expensify.com",
"description": "New Expensify is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.",
Expand Down
9 changes: 4 additions & 5 deletions src/CONST/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6393,8 +6393,7 @@ const CONST = {
get FILTER_DATE_PRESETS() {
return {
// s77rt remove DEV lock
[this.SYNTAX_FILTER_KEYS.POSTED]:
(Config?.ENVIRONMENT ?? 'development') === 'development' ? [this.DATE_PRESETS.LAST_STATEMENT, this.DATE_PRESETS.LAST_MONTH] : [this.DATE_PRESETS.LAST_MONTH],
[this.SYNTAX_FILTER_KEYS.POSTED]: (Config?.ENVIRONMENT ?? 'development') === 'development' ? [this.DATE_PRESETS.LAST_STATEMENT, this.DATE_PRESETS.LAST_MONTH] : [],
[this.SYNTAX_FILTER_KEYS.EXPORTED]: [this.DATE_PRESETS.NEVER],
};
},
Expand Down Expand Up @@ -6848,9 +6847,9 @@ const CONST = {
},
LAST_PAYMENT_METHOD: {
LAST_USED: 'lastUsed',
IOU: 'iou',
EXPENSE: 'expense',
INVOICE: 'invoice',
IOU: 'Iou',
EXPENSE: 'Expense',
INVOICE: 'Invoice',
},
SKIPPABLE_COLLECTION_MEMBER_IDS: [String(DEFAULT_NUMBER_ID), '-1', 'undefined', 'null', 'NaN'] as string[],
SETUP_SPECIALIST_LOGIN: 'Setup Specialist',
Expand Down
14 changes: 1 addition & 13 deletions src/components/Button/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -310,19 +310,7 @@ function Button(
const textComponent = secondLineText ? (
<View style={[styles.alignItemsCenter, styles.flexColumn, styles.flexShrink1]}>
{primaryText}
<Text
style={[
isLoading && styles.opacity0,
styles.pointerEventsNone,
styles.fontWeightNormal,
styles.textDoubleDecker,
!!secondLineText && styles.textExtraSmallSupporting,
styles.textWhite,
styles.textBold,
]}
>
{secondLineText}
</Text>
<Text style={[isLoading && styles.opacity0, styles.pointerEventsNone, styles.fontWeightNormal, styles.textDoubleDecker]}>{secondLineText}</Text>
</View>
) : (
primaryText
Expand Down
45 changes: 8 additions & 37 deletions src/components/ButtonWithDropdownMenu/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import useTheme from '@hooks/useTheme';
import useThemeStyles from '@hooks/useThemeStyles';
import useWindowDimensions from '@hooks/useWindowDimensions';
import mergeRefs from '@libs/mergeRefs';
import variables from '@styles/variables';
import CONST from '@src/CONST';
import type {AnchorPosition} from '@src/styles';
import type {ButtonWithDropdownMenuProps} from './types';
Expand Down Expand Up @@ -51,10 +50,7 @@ function ButtonWithDropdownMenu<IValueType>({
testID,
secondLineText = '',
icon,
shouldPopoverUseScrollView = false,
containerStyles,
shouldUseModalPaddingStyle = true,
shouldUseShortForm = false,
shouldUseOptionIcon = false,
}: ButtonWithDropdownMenuProps<IValueType>) {
const theme = useTheme();
Expand All @@ -76,14 +72,9 @@ function ButtonWithDropdownMenu<IValueType>({
const areAllOptionsDisabled = options.every((option) => option.disabled);
const innerStyleDropButton = StyleUtils.getDropDownButtonHeight(buttonSize);
const isButtonSizeLarge = buttonSize === CONST.DROPDOWN_BUTTON_SIZE.LARGE;
const isButtonSizeSmall = buttonSize === CONST.DROPDOWN_BUTTON_SIZE.SMALL;
const nullCheckRef = (ref: RefObject<View | null>) => ref ?? null;
const shouldShowButtonRightIcon = !!options.at(0)?.shouldShowButtonRightIcon;

useEffect(() => {
setSelectedItemIndex(defaultSelectedIndex);
}, [defaultSelectedIndex]);

useEffect(() => {
if (!dropdownAnchor.current) {
return;
Expand Down Expand Up @@ -137,7 +128,6 @@ function ButtonWithDropdownMenu<IValueType>({
},
);
const splitButtonWrapperStyle = isSplitButton ? [styles.flexRow, styles.justifyContentBetween, styles.alignItemsCenter] : {};
const isTextTooLong = customText && customText?.length > 6;

const handlePress = useCallback(
(event?: GestureResponderEvent | KeyboardEvent) => {
Expand Down Expand Up @@ -167,13 +157,12 @@ function ButtonWithDropdownMenu<IValueType>({
large={buttonSize === CONST.DROPDOWN_BUTTON_SIZE.LARGE}
medium={buttonSize === CONST.DROPDOWN_BUTTON_SIZE.MEDIUM}
small={buttonSize === CONST.DROPDOWN_BUTTON_SIZE.SMALL}
innerStyles={[innerStyleDropButton, !isSplitButton && styles.dropDownButtonCartIconView, isTextTooLong && shouldUseShortForm && {...styles.pl2, ...styles.pr1}]}
innerStyles={[innerStyleDropButton, !isSplitButton && styles.dropDownButtonCartIconView]}
enterKeyEventListenerPriority={enterKeyEventListenerPriority}
iconRight={Expensicons.DownArrow}
shouldShowRightIcon={!isSplitButton}
isSplitButton={isSplitButton}
testID={testID}
textStyles={[isTextTooLong && shouldUseShortForm ? {...styles.textExtraSmall, ...styles.textBold} : {}]}
secondLineText={secondLineText}
icon={icon}
/>
Expand All @@ -189,25 +178,16 @@ function ButtonWithDropdownMenu<IValueType>({
large={buttonSize === CONST.DROPDOWN_BUTTON_SIZE.LARGE}
medium={buttonSize === CONST.DROPDOWN_BUTTON_SIZE.MEDIUM}
small={buttonSize === CONST.DROPDOWN_BUTTON_SIZE.SMALL}
innerStyles={[styles.dropDownButtonCartIconContainerPadding, innerStyleDropButton, isButtonSizeSmall && styles.dropDownButtonCartIcon]}
innerStyles={[styles.dropDownButtonCartIconContainerPadding, innerStyleDropButton]}
enterKeyEventListenerPriority={enterKeyEventListenerPriority}
>
<View style={[styles.dropDownButtonCartIconView, innerStyleDropButton]}>
<View style={[success ? styles.buttonSuccessDivider : styles.buttonDivider]} />
<View
style={[
isButtonSizeLarge && styles.dropDownLargeButtonArrowContain,
isButtonSizeSmall && shouldUseShortForm ? styles.dropDownSmallButtonArrowContain : styles.dropDownMediumButtonArrowContain,
]}
>
<View style={[isButtonSizeLarge ? styles.dropDownLargeButtonArrowContain : styles.dropDownMediumButtonArrowContain]}>
<Icon
medium={isButtonSizeLarge}
small={!isButtonSizeLarge && !shouldUseShortForm}
inline={shouldUseShortForm}
width={shouldUseShortForm ? variables.iconSizeExtraSmall : undefined}
height={shouldUseShortForm ? variables.iconSizeExtraSmall : undefined}
small={!isButtonSizeLarge}
src={Expensicons.DownArrow}
additionalStyles={shouldUseShortForm ? [styles.pRelative, styles.t0] : undefined}
fill={success ? theme.buttonSuccessText : theme.icon}
/>
</View>
Expand Down Expand Up @@ -257,27 +237,18 @@ function ButtonWithDropdownMenu<IValueType>({
shouldShowSelectedItemCheck={shouldShowSelectedItemCheck}
// eslint-disable-next-line react-compiler/react-compiler
anchorRef={nullCheckRef(dropdownAnchor)}
withoutOverlay
shouldUseScrollView
scrollContainerStyle={!shouldUseModalPaddingStyle && isSmallScreenWidth && styles.pv4}
anchorAlignment={anchorAlignment}
shouldUseModalPaddingStyle={shouldUseModalPaddingStyle}
anchorAlignment={anchorAlignment}
headerText={menuHeaderText}
shouldUseScrollView={shouldPopoverUseScrollView}
containerStyles={containerStyles}
menuItems={options.map((item, index) => ({
...item,
onSelected: item.onSelected
? () => {
item.onSelected?.();
if (item.shouldUpdateSelectedIndex) {
setSelectedItemIndex(index);
}
}
? () => item.onSelected?.()
: () => {
onOptionSelected?.(item);
if (item.shouldUpdateSelectedIndex === false) {
return;
}

setSelectedItemIndex(index);
},
shouldCallAfterModalHide: true,
Expand Down
11 changes: 0 additions & 11 deletions src/components/ButtonWithDropdownMenu/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ type DropdownOption<TValueType> = {
descriptionTextStyle?: StyleProp<TextStyle>;
wrapperStyle?: StyleProp<ViewStyle>;
displayInDefaultIconColor?: boolean;
/** Whether the selected index should be updated when the option is selected even if we have onSelected callback */
shouldUpdateSelectedIndex?: boolean;
subMenuItems?: PopoverMenuItem[];
backButtonText?: string;
avatarSize?: ValueOf<typeof CONST.AVATAR_SIZE>;
Expand Down Expand Up @@ -143,18 +141,9 @@ type ButtonWithDropdownMenuProps<TValueType> = {
/** Icon for main button */
icon?: IconAsset;

/** Whether the popover content should be scrollable */
shouldPopoverUseScrollView?: boolean;

/** Container style to be applied to the popover of the dropdown menu */
containerStyles?: StyleProp<ViewStyle>;

/** Whether to use modal padding style for the popover menu */
shouldUseModalPaddingStyle?: boolean;

/** Whether to use short form for the button */
shouldUseShortForm?: boolean;

/** Whether to display the option icon when only one option is available */
shouldUseOptionIcon?: boolean;
};
Expand Down
12 changes: 10 additions & 2 deletions src/components/ImportSpreadsheet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import useOnyx from '@hooks/useOnyx';
import useResponsiveLayout from '@hooks/useResponsiveLayout';
import useThemeStyles from '@hooks/useThemeStyles';
import {setSpreadsheetData} from '@libs/actions/ImportSpreadsheet';
import {setImportedSpreadsheetIsImportingMultiLevelTags} from '@libs/actions/Policy/Tag';
import {canUseTouchScreen} from '@libs/DeviceCapabilities';
import {splitExtensionFromFileName} from '@libs/fileDownload/FileUtils';
import Navigation from '@libs/Navigation/Navigation';
Expand Down Expand Up @@ -155,7 +156,9 @@ function ImportSpreadsheet({backTo, goTo}: ImportSpreadsheetProps) {
{...panResponder.panHandlers}
>
<Text style={[styles.textFileUpload, styles.mb1]}>{spreadsheet?.isImportingMultiLevelTags ? translate('spreadsheet.import') : translate('spreadsheet.upload')}</Text>
<RenderHTML html={getTextForImportModal()} />
<Text style={[styles.subTextFileUpload, styles.textSupporting]}>
<RenderHTML html={getTextForImportModal()} />
</Text>
</View>
<FilePicker acceptableFileTypes={acceptableFileTypes}>
{({openPicker}) => (
Expand Down Expand Up @@ -195,7 +198,12 @@ function ImportSpreadsheet({backTo, goTo}: ImportSpreadsheetProps) {
<View style={[styles.flex1, safeAreaPaddingBottomStyle]}>
<HeaderWithBackButton
title={translate('spreadsheet.importSpreadsheet')}
onBackButtonPress={() => Navigation.goBack(backTo)}
onBackButtonPress={() => {
if (spreadsheet?.isImportingMultiLevelTags) {
setImportedSpreadsheetIsImportingMultiLevelTags(false);
}
Navigation.goBack(backTo);
}}
/>

<View style={[styles.flex1, styles.uploadFileView(isSmallScreenWidth)]}>
Expand Down
Loading
Loading