diff --git a/.dumi/theme/builtins/InlinePopover/index.tsx b/.dumi/theme/builtins/InlinePopover/index.tsx new file mode 100644 index 000000000000..d2327e8ff4c0 --- /dev/null +++ b/.dumi/theme/builtins/InlinePopover/index.tsx @@ -0,0 +1,50 @@ +import { PictureOutlined } from '@ant-design/icons'; +import { Image, Tooltip, Typography } from 'antd'; +import React from 'react'; +import useLocale from '../../../hooks/useLocale'; + +const locales = { + cn: { + tip: '预览', + }, + en: { + tip: 'Preview', + }, +}; + +export interface InlinePopoverProps { + previewURL?: string; +} + +// 鼠标悬浮弹出 Popover 组件,用于帮助用户更快看到一些属性对应的预览效果 +const InlinePopover: React.FC = (props: InlinePopoverProps) => { + const { previewURL } = props; + + const [locale] = useLocale(locales); + const [visible, setVisible] = React.useState(false); + + return ( + <> + + setVisible(true)}> + + + + + { + setVisible(value); + }, + }} + /> + + ); +}; + +export default InlinePopover; diff --git a/components/cascader/index.tsx b/components/cascader/index.tsx index ef61f2306d4c..f11cdb002e59 100644 --- a/components/cascader/index.tsx +++ b/components/cascader/index.tsx @@ -161,8 +161,7 @@ const Cascader = React.forwardRef((props: CascaderProps, ref: React.Ref, ref: React.Ref -
-
-
-
-
-
-
-
- 0 -
-
-
-
- 1 -
-
-
-
- 2 -
-
-
-
- 3 -
-
-
-
- 4 -
-
-
-
- 5 -
-
-
-
- 6 -
-
-
-
- 7 -
-
-
-
- 8 -
-
-
-
- 9 -
-
-
-
- 10 -
-
-
-
- 11 -
-
-
-
- 12 -
-
-
-
- 13 -
-
-
-
- 14 -
-
-
-
- 15 -
-
-
-
- 16 -
-
-
-
- 17 -
-
-
-
- 18 -
-
-
-
- 19 -
-
-
-
-
-
-
-