Bladeren bron

81100 rename

SULLEY\ryo-h 4 jaren geleden
bovenliggende
commit
67fa8b61aa

+ 2 - 2
packages/app/src/components/SearchPage.jsx

@@ -227,8 +227,8 @@ class SearchPage extends React.Component {
         searchResultCount={this.state.searchResultCount}
         activePage={this.state.activePage}
         pagingLimit={this.state.pagingLimit}
-        onClickInvoked={this.selectPage}
-        onClickCheckboxInvoked={this.toggleCheckBox}
+        onClickSearchResultItem={this.selectPage}
+        onClickCheckbox={this.toggleCheckBox}
         onPagingNumberChanged={this.onPagingNumberChanged}
       />
     );

+ 2 - 2
packages/app/src/components/SearchPage/SearchResultList.tsx

@@ -16,7 +16,7 @@ type Props = {
   pages: ISearchedPage[],
   selectedPagesIdList: Set<string>
   onClickSearchResultItem?: (pageId: string) => void,
-  onClickCheckboxInvoked?: (page: string) => void,
+  onClickCheckbox?: (page: string) => void,
   searchResultCount?: number,
   activePage?: number,
   pagingLimit?: number,
@@ -37,7 +37,7 @@ const SearchResultList: FC<Props> = (props:Props) => {
             key={page._id}
             page={page}
             onClickSearchResultItem={props.onClickSearchResultItem}
-            onClickCheckboxInvoked={props.onClickCheckboxInvoked}
+            onClickCheckbox={props.onClickCheckbox}
             isSelected={page._id === focusedPageId || false}
             isChecked={isChecked}
           />

+ 4 - 4
packages/app/src/components/SearchPage/SearchResultListItem.tsx

@@ -70,14 +70,14 @@ type Props = {
   page: ISearchedPage,
   isSelected: boolean,
   isChecked: boolean,
-  onClickCheckboxInvoked?: (page: string) => void,
+  onClickCheckbox?: (page: string) => void,
   onClickSearchResultItem?: (pageId: string) => void,
 }
 
 const SearchResultListItem: FC<Props> = (props:Props) => {
   const {
     // todo: refactoring variable name to clear what changed
-    page, isSelected, onClickSearchResultItem, onClickCheckboxInvoked, isChecked,
+    page, isSelected, onClickSearchResultItem, onClickCheckbox, isChecked,
   } = props;
 
   // Add prefix 'id_' in pageId, because scrollspy of bootstrap doesn't work when the first letter of id attr of target component is numeral.
@@ -105,8 +105,8 @@ const SearchResultListItem: FC<Props> = (props:Props) => {
               type="checkbox"
               id="flexCheckDefault"
               onClick={() => {
-                if (onClickCheckboxInvoked != null) {
-                  onClickCheckboxInvoked(page._id);
+                if (onClickCheckbox != null) {
+                  onClickCheckbox(page._id);
                 }
               }}
               checked={isChecked}