From 2df7c953c7b7034a29911e667678d32128920b02 Mon Sep 17 00:00:00 2001 From: Rafiafrzl Date: Fri, 17 Oct 2025 15:39:34 +0700 Subject: [PATCH] feat: remove unused activeTab state and related props from ListBrandDevice component --- .../master/brandDevice/IndexBrandDevice.jsx | 3 - .../brandDevice/component/ListBrandDevice.jsx | 193 +++++++----------- 2 files changed, 76 insertions(+), 120 deletions(-) diff --git a/src/pages/master/brandDevice/IndexBrandDevice.jsx b/src/pages/master/brandDevice/IndexBrandDevice.jsx index d79041c..53042c1 100644 --- a/src/pages/master/brandDevice/IndexBrandDevice.jsx +++ b/src/pages/master/brandDevice/IndexBrandDevice.jsx @@ -12,7 +12,6 @@ const IndexBrandDevice = memo(function IndexBrandDevice() { const navigate = useNavigate(); const { setBreadcrumbItems } = useBreadcrumb(); - const [activeTab, setActiveTab] = useState('brandDevice'); const [actionMode, setActionMode] = useState('list'); const [selectedData, setSelectedData] = useState(null); const [readOnly, setReadOnly] = useState(false); @@ -62,8 +61,6 @@ const IndexBrandDevice = memo(function IndexBrandDevice() { selectedData={selectedData} setSelectedData={setSelectedData} readOnly={readOnly} - activeTab={activeTab} - setActiveTab={setActiveTab} /> - - - - {props.activeTab === 'brandDevice' && ( - - - - - { - const value = e.target.value; - setSearchValue(value); - // Auto search when clearing by backspace/delete - if (value === '') { - setFormDataFilter({ search: '' }); - setTrigerFilter((prev) => !prev); - } - }} - onSearch={handleSearch} - allowClear={{ - clearIcon: , - }} - enterButton={ - + + + + + { + const value = e.target.value; + setSearchValue(value); + // Auto search when clearing by backspace/delete + if (value === '') { + setFormDataFilter({ search: '' }); + setTrigerFilter((prev) => !prev); } - size="large" - /> - - - - ✕, + }} + enterButton={ + - - - - - - - - - - )} - {props.activeTab === 'errorMaster' && ( - - )} + Search + + } + size="large" + /> + + + + + + + + + + + + + + );