diff --git a/src/ui/settings/components/AssetBrowser.tsx b/src/ui/settings/components/AssetBrowser.tsx index 2487afb..77f736c 100644 --- a/src/ui/settings/components/AssetBrowser.tsx +++ b/src/ui/settings/components/AssetBrowser.tsx @@ -16,7 +16,7 @@ export default function AssetBrowser() { title="SEARCH" /> a.name.startsWith(searchName))} + data={Object.values(all).filter(a => a.name.includes(searchName))} renderItem={({ item }) => ( )} diff --git a/src/ui/settings/components/AssetDisplay.tsx b/src/ui/settings/components/AssetDisplay.tsx index 4a65b0e..51b9ad1 100644 --- a/src/ui/settings/components/AssetDisplay.tsx +++ b/src/ui/settings/components/AssetDisplay.tsx @@ -1,6 +1,9 @@ import { Asset } from "@types"; import { React, ReactNative as RN } from "@metro/common"; +import { showToast } from "@ui/toasts"; +import { getAssetIDByName } from "@ui/assets"; import { Forms } from "@ui/components"; +import copyText from "@lib/utils/copyText"; interface AssetDisplayProps { asset: Asset; @@ -20,6 +23,10 @@ export default function AssetDisplay({ asset }: AssetDisplayProps) { } + onPress={() => { + copyText(asset.name); + showToast("Copied asset name to clipboard.", getAssetIDByName("toast_copy_link")) + }} /> ) } \ No newline at end of file