From a92c2af3ca940365766b79d6badfbb9f9fd1a2d5 Mon Sep 17 00:00:00 2001 From: meerkat Date: Fri, 22 Jul 2022 12:57:25 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20transfer=20tree=20=E5=8F=B3=E4=BE=A7?= =?UTF-8?q?=E6=97=A0=E6=B3=95=E6=BB=9A=E5=8A=A8=20=20(#4686)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/amis-ui/src/components/Transfer.tsx | 88 +++++++++++--------- 1 file changed, 48 insertions(+), 40 deletions(-) diff --git a/packages/amis-ui/src/components/Transfer.tsx b/packages/amis-ui/src/components/Transfer.tsx index 8eb3355ff..dd2ff1bc3 100644 --- a/packages/amis-ui/src/components/Transfer.tsx +++ b/packages/amis-ui/src/components/Transfer.tsx @@ -628,46 +628,54 @@ export class Transfer< const placeholder = resultSearchPlaceholder || __('Transfer.selectFromLeft'); - return resultSelectMode === 'table' ? ( - - ) : resultSelectMode === 'tree' ? ( - - ) : ( - - ); + switch (resultSelectMode) { + case 'table': + return ( + + ); + case 'tree': + return ( + + ); + default: + return ( + + ); + } } render() {