Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(n-cascader): provide all top Key values in callback function #1298

Merged
merged 3 commits into from
Oct 9, 2021

Conversation

LYErin
Copy link
Contributor

@LYErin LYErin commented Oct 8, 2021

close #1235

@vercel
Copy link

vercel bot commented Oct 8, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/tusimple/naive-ui/5LMHZqAV4taVUms7U2PKPUoaDNRo
✅ Preview: https://naive-ui-git-fork-lyerin-show-checked-items-in-5ced63-tusimple.vercel.app

@codecov
Copy link

codecov bot commented Oct 8, 2021

Codecov Report

Merging #1298 (c879df7) into main (3363200) will increase coverage by 0.06%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1298      +/-   ##
==========================================
+ Coverage   51.90%   51.96%   +0.06%     
==========================================
  Files         529      529              
  Lines       13109    13116       +7     
  Branches     3737     3737              
==========================================
+ Hits         6804     6816      +12     
- Misses       5179     5182       +3     
+ Partials     1126     1118       -8     
Impacted Files Coverage Δ
src/cascader/src/Cascader.tsx 34.92% <0.00%> (-0.80%) ⬇️
src/layout/src/Layout.tsx 66.66% <0.00%> (ø)
src/layout/src/LayoutSider.tsx 39.70% <0.00%> (ø)
src/_internal/slot-machine/src/SlotMachine.tsx 67.74% <0.00%> (ø)
...c/_internal/slot-machine/src/SlotMachineNumber.tsx 37.50% <0.00%> (ø)
src/data-table/src/TableParts/Body.tsx 58.75% <0.00%> (+0.56%) ⬆️
src/anchor/src/BaseAnchor.tsx 46.15% <0.00%> (+0.76%) ⬆️
src/data-table/src/use-group-header.ts 66.66% <0.00%> (+1.96%) ⬆️
src/data-table/src/TableParts/Header.tsx 80.55% <0.00%> (+11.11%) ⬆️
src/data-table/src/TableParts/Cell.tsx 100.00% <0.00%> (+41.66%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3363200...c879df7. Read the comment docs.

src/cascader/src/Cascader.tsx Show resolved Hide resolved
src/cascader/src/Cascader.tsx Show resolved Hide resolved
src/cascader/src/Cascader.tsx Outdated Show resolved Hide resolved
Comment on lines 361 to 363
checkedKeys.map((checkedKey) =>
getPath(checkedKey).treeNodePath.map((v) => v.rawNode)
)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

注意 null,是有可能的

src/cascader/src/Cascader.tsx Outdated Show resolved Hide resolved
src/cascader/src/Cascader.tsx Outdated Show resolved Hide resolved
@07akioni 07akioni merged commit a6298ca into tusen-ai:main Oct 9, 2021
@LYErin LYErin deleted the show-checked-Items-in-cascader branch November 4, 2021 06:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

cascader目前仅返回了最后一级的值,能返回相关的父级值吗?
3 participants