test: lint

This commit is contained in:
MadCcc 2022-05-09 22:20:07 +08:00
parent 1f5e271eb6
commit 24773d5796
58 changed files with 150 additions and 273 deletions

View File

@ -1,18 +1,20 @@
import React from 'react';
import { CSSInterpolation, Theme, useCacheToken, useStyleRegister } from '@ant-design/cssinjs';
import type { CSSInterpolation } from '@ant-design/cssinjs';
import { Theme, useCacheToken, useStyleRegister } from '@ant-design/cssinjs';
import genComponentStyleHook from './util/genComponentStyleHook';
import defaultSeedToken, { derivative as defaultDerivative } from './themes/default';
import version from '../../version';
import { resetComponent, resetIcon, clearFix, roundedArrow, operationUnit } from './util';
import formatToken from './util/alias';
import statisticToken, { merge as mergeToken, statistic } from './util/statistic';
import { GlobalToken, PresetColors } from './interface';
import { PresetColors } from './interface';
import type {
SeedToken,
DerivativeToken,
AliasToken,
OverrideToken,
PresetColorType,
GlobalToken,
} from './interface';
import type { FullToken } from './util/genComponentStyleHook';

View File

@ -1,8 +1,10 @@
/* eslint-disable no-redeclare */
import { CSSInterpolation, useStyleRegister } from '@ant-design/cssinjs';
import type { CSSInterpolation } from '@ant-design/cssinjs';
import { useStyleRegister } from '@ant-design/cssinjs';
import { useContext } from 'react';
import { GlobalToken, OverrideToken } from '../interface';
import { mergeToken, statisticToken, UseComponentStyleResult, useToken } from '../index';
import type { GlobalToken, OverrideToken } from '../interface';
import type { UseComponentStyleResult } from '../index';
import { mergeToken, statisticToken, useToken } from '../index';
import { ConfigContext } from '../../../config-provider';
export type OverrideTokenWithoutDerivative = Omit<OverrideToken, 'derivative'>;

View File

@ -1,5 +1,5 @@
/* eslint-disable import/prefer-default-export */
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import type { DerivativeToken } from '..';
export { operationUnit } from './operationUnit';

View File

@ -1,5 +1,5 @@
import type { CSSObject } from '@ant-design/cssinjs';
import { DerivativeToken } from '..';
import type { DerivativeToken } from '..';
// eslint-disable-next-line import/prefer-default-export
export const operationUnit = (token: DerivativeToken): CSSObject => ({

View File

@ -1,5 +1,5 @@
/* eslint-disable import/prefer-default-export */
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import seedToken from '../themes/default';
export const roundedArrow = (width: number, outerRadius: number, bgColor: string): CSSObject => {

View File

@ -1,6 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import { GenerateStyle, genComponentStyleHook, FullToken, mergeToken } from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { genComponentStyleHook, mergeToken } from '../../_util/theme';
interface AffixToken extends FullToken<'Affix'> {
zIndexAffix: number;

View File

@ -2,15 +2,10 @@
// import './index.less';
// deps-lint-skip-all
import { CSSInterpolation, CSSObject } from '@ant-design/cssinjs';
import type { CSSInterpolation, CSSObject } from '@ant-design/cssinjs';
import {
resetComponent,
GenerateStyle,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
// FIXME: missing token
type AlertToken = FullToken<'Alert'> & {

View File

@ -1,5 +1,5 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { genComponentStyleHook, mergeToken, resetComponent } from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';

View File

@ -6,14 +6,9 @@
// import '../../popover/style';
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
GenerateStyle,
resetComponent,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
type AvatarToken = FullToken<'Avatar'> & {
avatarBg: string;

View File

@ -1,12 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
resetComponent,
genComponentStyleHook,
GenerateStyle,
FullToken,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
/** Component only token. Which will handle additional calculation of alias token */
export interface ComponentToken {}

View File

@ -1,14 +1,8 @@
// deps-lint-skip-all
import { CSSObject, Keyframes } from '@ant-design/cssinjs';
import {
resetComponent,
GenerateStyle,
PresetColors,
PresetColorType,
genComponentStyleHook,
FullToken,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import { Keyframes } from '@ant-design/cssinjs';
import type { GenerateStyle, PresetColorType, FullToken } from '../../_util/theme';
import { resetComponent, PresetColors, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface BadgeToken extends FullToken<'Badge'> {
badgeZIndex: number | string;

View File

@ -1,5 +1,5 @@
// deps-lint-skip-all
import { CSSInterpolation, CSSObject } from '@ant-design/cssinjs';
import type { CSSInterpolation, CSSObject } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import { mergeToken, genComponentStyleHook } from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';

View File

@ -7,17 +7,12 @@
// import '../../col/style';
// deps-lint-skip-all
import { CSSObject, Keyframes } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { Keyframes } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import {
resetComponent,
GenerateStyle,
genComponentStyleHook,
FullToken,
mergeToken,
clearFix,
} from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken, clearFix } from '../../_util/theme';
interface CardToken extends FullToken<'Card'> {
rootPrefixCls: string;

View File

@ -1,12 +1,7 @@
// deps-lint-skip-all
import { Keyframes } from '@ant-design/cssinjs';
import {
resetComponent,
GenerateStyle,
genComponentStyleHook,
FullToken,
mergeToken,
} from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface CheckboxToken extends FullToken<'Checkbox'> {
checkboxCls: string;

View File

@ -2,14 +2,9 @@
// import './index.less';
// deps-lint-skip-all
import { CSSInterpolation } from '@ant-design/cssinjs';
import {
GenerateStyle,
resetComponent,
genComponentStyleHook,
mergeToken,
FullToken,
} from '../../_util/theme';
import type { CSSInterpolation } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
type CollapseToken = FullToken<'Collapse'> & {
collapseContentBg: string;

View File

@ -78,6 +78,7 @@ Please make sure you set moment locale or that you don't have two different vers
```js
import 'moment/locale/zh-cn';
moment.locale('zh-cn');
```

View File

@ -79,6 +79,7 @@ ConfigProvider.config({
```js
import 'moment/locale/zh-cn';
moment.locale('zh-cn');
```

View File

@ -1,21 +1,15 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import {
FullToken,
genComponentStyleHook,
GenerateStyle,
mergeToken,
resetComponent,
roundedArrow,
} from '../../_util/theme';
import type { FullToken, GenerateStyle } from '../../_util/theme';
import { genComponentStyleHook, mergeToken, resetComponent, roundedArrow } from '../../_util/theme';
import { slideDownIn, slideDownOut, slideUpIn, slideUpOut } from '../../style/motion';
import type { InputToken } from '../../input/style';
import {
genActiveStyle,
genBasicInputStyle,
genHoverStyle,
initInputToken,
InputToken,
} from '../../input/style';
// FIXME: need full token check

View File

@ -1,12 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
FullToken,
genComponentStyleHook,
GenerateStyle,
mergeToken,
resetComponent,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { FullToken, GenerateStyle } from '../../_util/theme';
import { genComponentStyleHook, mergeToken, resetComponent } from '../../_util/theme';
interface DescriptionsToken extends FullToken<'Descriptions'> {
descriptionsTitleMarginBottom: number;

View File

@ -1,12 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
resetComponent,
GenerateStyle,
genComponentStyleHook,
FullToken,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
/** Component only token. Which will handle additional calculation of alias token */
export interface ComponentToken {

View File

@ -1,7 +1,9 @@
// deps-lint-skip-all
import { CSSObject, Keyframes } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { Keyframes } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import { FullToken, genComponentStyleHook, GenerateStyle, mergeToken } from '../../_util/theme';
import type { FullToken, GenerateStyle } from '../../_util/theme';
import { genComponentStyleHook, mergeToken } from '../../_util/theme';
export interface DrawerToken extends FullToken<'Drawer'> {
drawerHeaderCloseSize: number;

View File

@ -1,12 +1,6 @@
// deps-lint-skip-all
import {
GenerateStyle,
resetComponent,
FullToken,
genComponentStyleHook,
mergeToken,
roundedArrow,
} from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken, roundedArrow } from '../../_util/theme';
import {
initSlideMotion,
slideUpIn,

View File

@ -1,14 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
DerivativeToken,
useStyleRegister,
useToken,
UseComponentStyleResult,
GenerateStyle,
mergeToken,
statisticToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { DerivativeToken, UseComponentStyleResult, GenerateStyle } from '../../_util/theme';
import { useStyleRegister, useToken, mergeToken, statisticToken } from '../../_util/theme';
/** Component only token. Which will handle additional calculation of alias token */
export interface ComponentToken {}

View File

@ -2,8 +2,9 @@
// import './index.less';
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import { GenerateStyle, FullToken, genComponentStyleHook, mergeToken } from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { genComponentStyleHook, mergeToken } from '../../_util/theme';
interface GridRowToken extends FullToken<'Grid'> {}

View File

@ -1,13 +1,8 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import {
FullToken,
genComponentStyleHook,
GenerateStyle,
mergeToken,
resetComponent,
} from '../../_util/theme';
import type { FullToken, GenerateStyle } from '../../_util/theme';
import { genComponentStyleHook, mergeToken, resetComponent } from '../../_util/theme';
export interface ImageToken extends FullToken<'Image'> {
previewPrefixCls: string;

View File

@ -1,13 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
clearFix,
genComponentStyleHook,
GenerateStyle,
mergeToken,
resetComponent,
} from '../../_util/theme';
import type { FullToken } from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import { clearFix, genComponentStyleHook, mergeToken, resetComponent } from '../../_util/theme';
import type { FullToken, GenerateStyle } from '../../_util/theme';
import type { GlobalToken } from '../../_util/theme/interface';
export type InputToken<T extends GlobalToken = FullToken<'Input'>> = T & {

View File

@ -1,14 +1,8 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import {
GenerateStyle,
resetComponent,
FullToken,
genComponentStyleHook,
mergeToken,
DerivativeToken,
} from '../../_util/theme';
import type { GenerateStyle, FullToken, DerivativeToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface ListToken extends FullToken<'List'> {
minHeight: number;

View File

@ -1,5 +1,7 @@
// deps-lint-skip-all
import { FullToken, genComponentStyleHook, GenerateStyle, resetComponent } from '../../_util/theme';
import type { FullToken, GenerateStyle } from '../../_util/theme';
import { genComponentStyleHook, resetComponent } from '../../_util/theme';
import type { InputToken } from '../../input/style';
import {
genActiveStyle,
genBasicInputStyle,
@ -7,7 +9,6 @@ import {
genPlaceholderStyle,
genStatusStyle,
initInputToken,
InputToken,
} from '../../input/style';
export interface ComponentToken {

View File

@ -1,14 +1,8 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import {
genComponentStyleHook,
resetComponent,
clearFix,
mergeToken,
UseComponentStyleResult,
} from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { genComponentStyleHook, resetComponent, clearFix, mergeToken } from '../../_util/theme';
import type { GenerateStyle, FullToken, UseComponentStyleResult } from '../../_util/theme';
/** Component only token. Which will handle additional calculation of alias token */
export interface ComponentToken {}

View File

@ -1,15 +1,9 @@
// deps-lint-skip-all
import React from 'react';
import { CSSObject } from '@ant-design/cssinjs';
import type React from 'react';
import type { CSSObject } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import {
genComponentStyleHook,
GenerateStyle,
mergeToken,
resetComponent,
clearFix,
} from '../../_util/theme';
import type { FullToken } from '../../_util/theme';
import { genComponentStyleHook, mergeToken, resetComponent, clearFix } from '../../_util/theme';
import type { FullToken, GenerateStyle } from '../../_util/theme';
/** Component only token. Which will handle additional calculation of alias token */
export interface ComponentToken {

View File

@ -1,6 +1,6 @@
// deps-lint-skip-all
import { TinyColor } from '@ctrl/tinycolor';
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import {
initInputToken,
genBasicInputStyle,

View File

@ -6,14 +6,12 @@
// deps-lint-skip-all
import { TinyColor } from '@ctrl/tinycolor';
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import type { PresetColorType, GenerateStyle, FullToken } from '../../_util/theme';
import {
PresetColors,
PresetColorType,
GenerateStyle,
resetComponent,
roundedArrow,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';

View File

@ -1,14 +1,10 @@
// deps-lint-skip-all
import { CSSInterpolation, Keyframes } from '@ant-design/cssinjs';
import type { CSSInterpolation } from '@ant-design/cssinjs';
import { Keyframes } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import {
DerivativeToken,
useStyleRegister,
useToken,
resetComponent,
UseComponentStyleResult,
} from '../../_util/theme';
import { GlobalToken } from '../../_util/theme/interface';
import type { DerivativeToken, UseComponentStyleResult } from '../../_util/theme';
import { useStyleRegister, useToken, resetComponent } from '../../_util/theme';
import type { GlobalToken } from '../../_util/theme/interface';
// ============================== Tokens ==============================
interface RadioToken extends DerivativeToken {

View File

@ -1,12 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
resetComponent,
GenerateStyle,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface RateToken extends FullToken<'Rate'> {
rateStarColor: string;

View File

@ -1,6 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import { GenerateStyle, genComponentStyleHook, FullToken, mergeToken } from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { genComponentStyleHook, mergeToken } from '../../_util/theme';
interface ResultToken extends FullToken<'Result'> {
resultTitleFontSize: number;

View File

@ -1,5 +1,6 @@
import { CSSObject } from '@ant-design/cssinjs';
import { resetComponent, GenerateStyle } from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle } from '../../_util/theme';
import { resetComponent } from '../../_util/theme';
import {
initSlideMotion,
slideUpIn,

View File

@ -5,15 +5,9 @@
import '../../empty/style';
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
resetComponent,
resetIcon,
GenerateStyle,
genComponentStyleHook,
FullToken,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, resetIcon, genComponentStyleHook, mergeToken } from '../../_util/theme';
import genSingleStyle from './single';
import genMultipleStyle from './multiple';
import genDropdownStyle from './dropdown';

View File

@ -1,4 +1,4 @@
import { CSSObject, CSSInterpolation } from '@ant-design/cssinjs';
import type { CSSObject, CSSInterpolation } from '@ant-design/cssinjs';
import type { SelectToken } from '.';
import { mergeToken, resetIcon } from '../../_util/theme';

View File

@ -1,4 +1,4 @@
import { CSSInterpolation, CSSObject } from '@ant-design/cssinjs';
import type { CSSInterpolation, CSSObject } from '@ant-design/cssinjs';
import { mergeToken } from '../../_util/theme';
import type { SelectToken } from '.';

View File

@ -1,7 +1,9 @@
// deps-lint-skip-all
import { CSSObject, Keyframes } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { Keyframes } from '@ant-design/cssinjs';
import { GenerateStyle, FullToken, genComponentStyleHook, mergeToken } from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { genComponentStyleHook, mergeToken } from '../../_util/theme';
const skeletonClsLoading = new Keyframes(`ant-skeleton-loading`, {
'0%': {

View File

@ -5,15 +5,10 @@
// import '../../tooltip/style';
// deps-lint-skip-all
import * as React from 'react';
import { CSSObject } from '@ant-design/cssinjs';
import {
GenerateStyle,
resetComponent,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type * as React from 'react';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
// Direction naming standard:
// Horizontal base:

View File

@ -1,12 +1,8 @@
// deps-lint-skip-all
import { CSSObject, Keyframes } from '@ant-design/cssinjs';
import {
resetComponent,
GenerateStyle,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import { Keyframes } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface SpinToken extends FullToken<'Spin'> {
spinDotDefault: string;

View File

@ -1,12 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import {
resetComponent,
GenerateStyle,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface StatisticToken extends FullToken<'Statistic'> {
statisticTitleFontSize: number;

View File

@ -1,5 +1,5 @@
/* eslint-disable import/prefer-default-export */
import { CSSObject, Keyframes } from '@ant-design/cssinjs';
import type { CSSObject, Keyframes } from '@ant-design/cssinjs';
const initMotionCommon = (duration: string): CSSObject => ({
animationDuration: duration,

View File

@ -1,4 +1,5 @@
import { CSSInterpolation, Keyframes } from '@ant-design/cssinjs';
import type { CSSInterpolation } from '@ant-design/cssinjs';
import { Keyframes } from '@ant-design/cssinjs';
import type { DerivativeToken } from '../../_util/theme';
import { initMotion } from './motion';

View File

@ -1,13 +1,8 @@
// deps-lint-skip-all
import { TinyColor } from '@ctrl/tinycolor';
import { CSSObject } from '@ant-design/cssinjs';
import {
resetComponent,
GenerateStyle,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface SwitchToken extends FullToken<'Switch'> {
switchMinWidth: number;

View File

@ -236,7 +236,7 @@ Properties for row selection.
```tsx
import { Table } from 'antd';
import { ColumnsType } from 'antd/es/table';
import type { ColumnsType } from 'antd/es/table';
interface User {
key: number;

View File

@ -238,7 +238,7 @@ const columns = [
```tsx
import { Table } from 'antd';
import { ColumnsType } from 'antd/es/table';
import type { ColumnsType } from 'antd/es/table';
interface User {
key: number;

View File

@ -1,14 +1,9 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { TinyColor } from '@ctrl/tinycolor';
import {
resetComponent,
GenerateStyle,
genComponentStyleHook,
FullToken,
mergeToken,
} from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface TabsToken extends FullToken<'Tabs'> {
tabsCardHorizontalPadding: string;

View File

@ -1,14 +1,8 @@
// deps-lint-skip-all
import { CSSInterpolation, CSSObject } from '@ant-design/cssinjs';
import type { CSSInterpolation, CSSObject } from '@ant-design/cssinjs';
import capitalize from '../../_util/capitalize';
import {
PresetColorType,
resetComponent,
PresetColors,
FullToken,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type { PresetColorType, FullToken } from '../../_util/theme';
import { resetComponent, PresetColors, genComponentStyleHook, mergeToken } from '../../_util/theme';
interface TagToken extends FullToken<'Tag'> {
tagFontSize: number;

View File

@ -1,6 +1,7 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import { FullToken, genComponentStyleHook, GenerateStyle, resetComponent } from '../../_util/theme';
import type { CSSObject } from '@ant-design/cssinjs';
import type { FullToken, GenerateStyle } from '../../_util/theme';
import { genComponentStyleHook, resetComponent } from '../../_util/theme';
export interface ComponentToken {}

View File

@ -7,7 +7,8 @@
// import '../../empty/style';
// deps-lint-skip-all
import { GenerateStyle, genComponentStyleHook, FullToken, mergeToken } from '../../_util/theme';
import type { GenerateStyle, FullToken } from '../../_util/theme';
import { genComponentStyleHook, mergeToken } from '../../_util/theme';
import { getStyle as getCheckboxStyle } from '../../checkbox/style';
import { genTreeStyle } from '../../tree/style';

View File

@ -2,13 +2,10 @@
// import './index.less';
// deps-lint-skip-all
import { CSSObject, CSSInterpolation, Keyframes } from '@ant-design/cssinjs';
import {
DerivativeToken,
resetComponent,
genComponentStyleHook,
mergeToken,
} from '../../_util/theme';
import type { CSSObject, CSSInterpolation } from '@ant-design/cssinjs';
import { Keyframes } from '@ant-design/cssinjs';
import type { DerivativeToken } from '../../_util/theme';
import { resetComponent, genComponentStyleHook, mergeToken } from '../../_util/theme';
import { getStyle as getCheckboxStyle } from '../../checkbox/style';
// ============================ Keyframes =============================

View File

@ -1,5 +1,5 @@
// deps-lint-skip-all
import { CSSObject } from '@ant-design/cssinjs';
import type { CSSObject } from '@ant-design/cssinjs';
import { genComponentStyleHook, resetComponent } from '../../_util/theme';
import genDraggerStyle from './dragger';
import genListStyle from './list';

View File

@ -1,4 +1,5 @@
import React, { FC } from 'react';
import type { FC } from 'react';
import React from 'react';
type DiffProps = {
show: boolean;

View File

@ -4,7 +4,8 @@ import hljs from 'highlight.js';
import css from 'highlight.js/lib/languages/css';
import 'highlight.js/styles/github.css';
import { Drawer, Typography, Alert, Space, Tabs } from 'antd';
import getValidateStatus, { STATUS, PASS } from './validateCheck';
import type { STATUS } from './validateCheck';
import getValidateStatus, { PASS } from './validateCheck';
import Token from './Token';
hljs.registerLanguage('css', css);

View File

@ -1,6 +1,7 @@
/* eslint-disable react/no-array-index-key */
import * as React from 'react';
import { Table, Space, TableProps, ConfigProvider, Select, Row, Col, Alert } from 'antd';
import type { TableProps } from 'antd';
import { Table, Space, ConfigProvider, Select, Row, Col, Alert } from 'antd';
import { statistic } from '../../../../../components/_util/theme';
const columns: TableProps<{ name: string; value: any }>['columns'] = [

View File

@ -4,7 +4,7 @@ import { Drawer, Form, Input, Button, InputNumber, Checkbox, Space } from 'antd'
import { useIntl } from 'react-intl';
import { BugOutlined, EyeOutlined } from '@ant-design/icons';
import { useState } from 'react';
import { SeedToken } from '../../../../../components/_util/theme';
import type { SeedToken } from '../../../../../components/_util/theme';
import defaultSeedToken from '../../../../../components/_util/theme/themes/default';
import { PresetColors } from '../../../../../components/_util/theme/interface';
import Preview from './Preview';