Skip to content

Commit

Permalink
Merge branch 'develop' into fix/bugbash-lite-peach
Browse files Browse the repository at this point in the history
  • Loading branch information
evilpeach authored Jun 19, 2024
2 parents 8ff2ad4 + 89c8817 commit d1561b5
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 6 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Bug fixes

- [#976](https://github.com/alleslabs/celatone-frontend/pull/976) Support save accounts in lite version
- [#944](https://github.com/alleslabs/celatone-frontend/pull/944) Fix asset input selector
- [#979](https://github.com/alleslabs/celatone-frontend/pull/979) Fix txs detail receiver overflow screen
- [#980](https://github.com/alleslabs/celatone-frontend/pull/980) Pass through block in search in lite
- [#981](https://github.com/alleslabs/celatone-frontend/pull/981) Fix useAccountData
Expand Down
2 changes: 1 addition & 1 deletion src/lib/components/forms/AssetInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ interface AssetInputProps {
setCurrencyValue: (newVal: string) => void;
amountInput: JSX.Element;
assetOptions: AssetOptions[];
initialSelected: string;
initialSelected?: string;
labelBgColor?: string;
}

Expand Down
8 changes: 5 additions & 3 deletions src/lib/components/forms/SelectInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ interface SelectInputProps<T extends string> {
}[];
onChange: (newVal: T) => void;
placeholder?: string;
initialSelected: string;
initialSelected?: string;
hasDivider?: boolean;
helperTextComponent?: ReactNode;
labelBgColor?: string;
Expand Down Expand Up @@ -81,9 +81,10 @@ export const SelectInput = <T extends string>({
const selectedOption = options.find((item) => item.label === selected);

useEffect(() => {
if (!initialSelected) return;

setSelected(
options.find((item) => !item.disabled && item.value === initialSelected)
?.label ?? ""
options.find((item) => item.value === initialSelected)?.label ?? ""
);
}, [initialSelected, options]);

Expand Down Expand Up @@ -162,6 +163,7 @@ export const SelectInput = <T extends string>({
borderBottomColor: hasDivider && "gray.700",
},
}}
overflow="scroll"
>
{options.map(({ label, value, disabled, icon, iconColor, image }) => (
<SelectItem
Expand Down
4 changes: 2 additions & 2 deletions src/lib/pages/interact-contract/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Flex, Heading } from "@chakra-ui/react";
import { isUndefined } from "lodash";
import { capitalize, isUndefined } from "lodash";
import { useRouter } from "next/router";
import { useCallback, useEffect, useState } from "react";

Expand Down Expand Up @@ -137,7 +137,7 @@ const InteractContractBody = ({
/>
<Flex gap={4} align="center" mt={8} mb={4}>
<Heading variant="h6" as="h6" minW={40} mr={2}>
{selectedType} Message
{capitalize(selectedType)} Message
</Heading>
{!isMobile && (
<InteractionTypeSwitch
Expand Down

0 comments on commit d1561b5

Please sign in to comment.