@zgfe/business-lib 1.1.60-distribute.1 → 1.1.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,7 +4,7 @@
4
4
  width: 100%;
5
5
  &-btn-del {
6
6
  color: #9aa1a9;
7
- font-size: 20px !important;
7
+ font-size: 16px !important;
8
8
  &:hover {
9
9
  color: @error-color;
10
10
  cursor: pointer;
@@ -18,7 +18,6 @@ import { ShowStatus } from '../attributeSelector/types';
18
18
  import { BuiltinIndicators } from '../constants/common';
19
19
  import BizSearchInput from '../searchInput';
20
20
  import EventListOption from './option';
21
- import { useTriggerScrollFix } from './hooks';
22
21
  var EventListPanel = function EventListPanel(props) {
23
22
  var showOverview = props.showOverview,
24
23
  defaultSelectAble = props.defaultSelectAble;
@@ -199,7 +198,13 @@ var InfiniteScrollList = function InfiniteScrollList(_ref) {
199
198
  setCanShowList(data);
200
199
  setShowList(data.slice(0, 10));
201
200
  }, [searchEventList]);
202
- useTriggerScrollFix([showList.length]);
201
+ useEffect(function () {
202
+ if (showList.length <= 10 && showList.length < canShowList.length) {
203
+ if (typeof window !== 'undefined') {
204
+ window.dispatchEvent(new CustomEvent('scroll'));
205
+ }
206
+ }
207
+ }, [showList.length]);
203
208
  var loadMoreData = function loadMoreData() {
204
209
  var moreData = canShowList.slice(showList.length, showList.length + 10);
205
210
  setShowList(function (list) {
@@ -63,7 +63,6 @@ export var panelCreateBtn = function panelCreateBtn(callback, disabled) {
63
63
  label: '取消',
64
64
  type: 'text',
65
65
  onClick: function onClick() {
66
- console.log('取消');
67
66
  callback('cancel');
68
67
  }
69
68
  }, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zgfe/business-lib",
3
- "version": "1.1.60-distribute.1",
3
+ "version": "1.1.60",
4
4
  "scripts": {
5
5
  "start": "dumi dev",
6
6
  "docs:build": "dumi build",
@@ -60,5 +60,5 @@
60
60
  "react": "^16.12.0 || ^17.0.0",
61
61
  "yorkie": "^2.0.0"
62
62
  },
63
- "gitHead": "4e16f92cef0741fad612166d2a5008cac09c7909"
63
+ "gitHead": "a691730fcbc68cc3d094e2651db65cdb51768d43"
64
64
  }
@@ -1 +0,0 @@
1
- export declare function useTriggerScrollFix(deps: number[]): void;
@@ -1,8 +0,0 @@
1
- import { useEffect } from 'react';
2
- export function useTriggerScrollFix(deps) {
3
- useEffect(function () {
4
- if (typeof window !== 'undefined') {
5
- window.dispatchEvent(new CustomEvent('scroll'));
6
- }
7
- }, deps);
8
- }