All Projects → HelKyle → antd-multi-cascader

HelKyle / antd-multi-cascader

Licence: MIT license
A multiple cascader component for antd

Programming Languages

typescript
32286 projects
Less
1899 projects
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to antd-multi-cascader

antdCascaderDate
202104最新更新,对于antd Cascader 内中国省市区数据的补充,数据基于 2020月12月中华人民共和国县以上行政区划代码,生成此数据的方法:https://github.com/heerey525/antdCascaderDateMethod
Stars: ✭ 158 (+95.06%)
Mutual labels:  antd, cascader
react-jsonschema-formbuilder
No description or website provided.
Stars: ✭ 45 (-44.44%)
Mutual labels:  antd
react-project-tpl
react project template
Stars: ✭ 32 (-60.49%)
Mutual labels:  antd
api-server
OpenSCRM是一套基于Go和React的高质量企业微信私域流量管理系统 。遵守Apache2.0协议,全网唯一免费商用。企业微信、私域流量、SCRM。
Stars: ✭ 981 (+1111.11%)
Mutual labels:  antd
nextjs-antd-dva-template
最优的nextjs antd dva 服务端解决方案
Stars: ✭ 15 (-81.48%)
Mutual labels:  antd
rncms
🔥 Rncms 是基于 Koa2 + Webpack4 + Reactjs 结构简单 Cms 易于开发企业站和文档系统【已废弃】
Stars: ✭ 52 (-35.8%)
Mutual labels:  antd
Demeter
Nodejs/ES6/Rxjs/MySQL/Express/Webpack/React/Redux/AntD
Stars: ✭ 43 (-46.91%)
Mutual labels:  antd
fable-ant-design
Ant Design bindings for Fable Elmish
Stars: ✭ 23 (-71.6%)
Mutual labels:  antd
CodeSignal-Practice Solutions
No description or website provided.
Stars: ✭ 28 (-65.43%)
Mutual labels:  antd
ui-nuclear-mobile
A configurable Mobile UI based on Antd Mobile and Vue
Stars: ✭ 61 (-24.69%)
Mutual labels:  antd
antd-prompt
An ant.design helper that auto create a Modal with an optional message prompting the user to input some text.
Stars: ✭ 13 (-83.95%)
Mutual labels:  antd
tiny-qiniu-request
tiny-qiniu for rc-upload or antd upload component `customRequest` property
Stars: ✭ 13 (-83.95%)
Mutual labels:  antd
virtualized-table-for-antd
the virtualized table component for ant design
Stars: ✭ 193 (+138.27%)
Mutual labels:  antd
picker
📅 All Date Pickers you need.
Stars: ✭ 185 (+128.4%)
Mutual labels:  antd
sunrise
The rise of a new project with React, Redux-Saga and React-Router
Stars: ✭ 13 (-83.95%)
Mutual labels:  antd
Min-Admin
基于dva框架+antd的React后台模板
Stars: ✭ 17 (-79.01%)
Mutual labels:  antd
react-antd-admin
react-antd-admin 是一个后台集成解决方案,它基于 react 和 antd; 内置了动态路由,标签页缓存,权限验证、切换功能
Stars: ✭ 42 (-48.15%)
Mutual labels:  antd
hotlist
今日热榜(前端)
Stars: ✭ 51 (-37.04%)
Mutual labels:  antd
react-quizzes
A React.js solution that offers a UI for creating surveys, forms and quizzes.
Stars: ✭ 25 (-69.14%)
Mutual labels:  antd
bank-client
Frontend Application using React.js with Hooks, Redux, Saga, Ant Design, styled-components and Jest
Stars: ✭ 57 (-29.63%)
Mutual labels:  antd

🎉🎉🎉 News

[email protected] has supported multiple cascader features. Should consider it first.

antd-multi-cascader

Test PRs Welcome MIT license Codecov Coverage Storybook npm

A multiple cascader component for antd

antd-multi-cascader

Online DemoHow it works?

demo

How to use?

npm install antd-multi-cascader or yarn add antd-multi-cascader
const [value, setValue] = React.useState<string[]>([]);

return (
  <MultiCascader
    value={value}
    onChange={setValue}
    data={options}
    placeholder="Select Cities"
  />
)

Props

🚨 Please install 1.3.0 version or set popupTransitionName=slide-up manually if your antd version below 4.13.0
🚨 如果你使用的 antd 版本小于 4.13.0,请安装 1.3.0 的版本,或手动设置 popupTransitionName=slide-up

Props Type Description
value string[] Selected value
data TreeNode[] Cascader options TreeNode { title: string, value: string, children?: TreeNode, isLeaf?: boolean }
allowClear boolean Whether allow clear
placeholder string The input placeholder
onChange (newVal) => void Callback when finishing value select
selectAll boolean Whether allow select all
className string The additional css class
style React.CSSProperties The additional style
disabled boolean Whether disabled select
okText string The text of the Confirm button
cancelText string The text of the Cancel button
selectAllText string The text of the SelectAll radio
onCascaderChange (node: TreeNode, operations: { add: (children: TreeNode[]) => TreeNode[] }) => void Trigger when click a menu item
popupTransitionName string Should set 'slide-up' manually if antd version below 4.13.0
getPopupContainer (props: any) => HTMLElement Parent Node which the selector should be rendered to. Default to body. When position issues happen, try to modify it into scrollable content and position it relative
maxTagCount Max tag count to show. responsive will cost render performance number | responsive

Async Data Example

const [asyncOptions, setAsyncOptions] = React.useState([
  {
    value: 'ParentNode1',
    title: 'ParentNode1',
    // tell component this node is not a leaf node
    isLeaf: false,
  },
  {
    value: 'ParentNode2',
    title: 'ParentNode2',
  },
])

const handleCascaderChange = React.useCallback((node, { add }) => {
  // call add function to append children nodes
  if (node.value === 'ParentNode1' && !node.children) {
    setTimeout(() => {
      setAsyncOptions(
        add([
          {
            value: 'ParentNode1-1',
            title: 'ParentNode1-1',
          },
        ])
      )
    }, 1000)
  }
}, [])

<MultiCascader
  selectAll
  data={asyncOptions}
  onCascaderChange={handleCascaderChange}
  placeholder="Async Data"
/>
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].