lijianan
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
4 additions and
4 deletions
-
components/button/buttonHelpers.tsx
-
components/input/Input.tsx
-
components/table/demo/dynamic-settings.tsx
|
|
@ -8,7 +8,7 @@ export function isString(str: any) { |
|
|
|
return typeof str === 'string'; |
|
|
|
} |
|
|
|
|
|
|
|
export function isUnBorderedButtonType(type: ButtonType | undefined) { |
|
|
|
export function isUnBorderedButtonType(type?: ButtonType) { |
|
|
|
return type === 'text' || type === 'link'; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
@ -39,7 +39,7 @@ export function resolveOnChange<E extends HTMLInputElement | HTMLTextAreaElement |
|
|
|
| React.ChangeEvent<E> |
|
|
|
| React.MouseEvent<HTMLElement, MouseEvent> |
|
|
|
| React.CompositionEvent<HTMLElement>, |
|
|
|
onChange: undefined | ((event: React.ChangeEvent<E>) => void), |
|
|
|
onChange?: (event: React.ChangeEvent<E>) => void, |
|
|
|
targetValue?: string, |
|
|
|
) { |
|
|
|
if (!onChange) { |
|
|
|
|
|
@ -92,12 +92,12 @@ const App: React.FC = () => { |
|
|
|
const [showfooter, setShowFooter] = useState(true); |
|
|
|
const [rowSelection, setRowSelection] = useState<TableRowSelection<DataType> | undefined>({}); |
|
|
|
const [hasData, setHasData] = useState(true); |
|
|
|
const [tableLayout, setTableLayout] = useState(undefined); |
|
|
|
const [tableLayout, setTableLayout] = useState(); |
|
|
|
const [top, setTop] = useState<TablePaginationPosition | 'none'>('none'); |
|
|
|
const [bottom, setBottom] = useState<TablePaginationPosition>('bottomRight'); |
|
|
|
const [ellipsis, setEllipsis] = useState(false); |
|
|
|
const [yScroll, setYScroll] = useState(false); |
|
|
|
const [xScroll, setXScroll] = useState<string | undefined>(undefined); |
|
|
|
const [xScroll, setXScroll] = useState<string>(); |
|
|
|
|
|
|
|
const handleBorderChange = (enable: boolean) => { |
|
|
|
setBordered(enable); |
|
|
|