4.4.5 • Published 8 months ago

@tntd/tooltip-select v4.4.5

Weekly downloads
-
License
ISC
Repository
-
Last release
8 months ago

4.x版本基于tntd2.x

@tntd/ant3-virtual-select

基于 ant3 实现带悬浮显示的下拉列表

安装

npm i @tntd/tooltip-select

用法

所有 API 同 ant3 Select

props 参数:

参数类型默认值是否必填说明
setTitlefunction(e)非必填自定义 tooltip 的 title 节点
isVirtualBooleanfalse非必填列表是否采用虚拟滚动
placementStringtop非必填tooltip位置
isMemoBooleanfalse非必填列表是否采用监听值及children控制渲染

示例

import { useState } from "react";
import TooltipSelect from "@tntd/tooltip-select";
import { Select, Tooltip } from "antd";
const Option = Select.Option;

export default (props) => {
  const [title, setTitle] = useState();
  const aTitle = (title) => {
    return <a>{title}</a>;
  };
  return (
    <TooltipSelect
      setTitle={(value) => {
        return aTitle(value);
      }}
      placeholder="66"
      value={title}
      onChange={(value) => {
        setTitle(value);
      }}
      dropdownMatchSelectWidth={false}
    >
      <Option value={1}>1+1</Option>
      <Option value={2}>2+2</Option>
    </TooltipSelect>
  );
};
4.4.5

8 months ago

4.4.4

8 months ago

4.4.3

10 months ago

4.3.9

10 months ago

4.4.1-beta.0

10 months ago

4.4.1-beta.1

10 months ago

4.4.1-beta.2

10 months ago

4.3.8

10 months ago

4.3.7

10 months ago

4.4.1

10 months ago

4.4.0

10 months ago

4.4.2

10 months ago

4.3.6

11 months ago

4.3.5

11 months ago

4.3.4

11 months ago

4.3.3

11 months ago

4.1.8

2 years ago

4.1.7

2 years ago

4.1.9

2 years ago

4.3.2

2 years ago

4.1.4

2 years ago

4.3.1

2 years ago

4.2.2

2 years ago

4.1.3

2 years ago

4.1.6

2 years ago

4.1.5

2 years ago

4.3.0

2 years ago

4.2.1

2 years ago

4.2.0

2 years ago

4.1.2

2 years ago

3.0.8

3 years ago

4.1.0

3 years ago

4.1.1

3 years ago

3.0.4

3 years ago

3.0.3

3 years ago

3.0.2

3 years ago

3.0.1

3 years ago

3.0.7

3 years ago

3.0.6

3 years ago

3.0.5

3 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago