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: 🎸 Expose isToolActiveForElement #1080

Merged
merged 1 commit into from
Sep 18, 2019

Conversation

JamesAPetts
Copy link
Member

Renamed isToolActive to isToolActiveForElement and expose it as top
level API.

Renamed isToolActive to isToolActiveForElement and expose it as top
level API.
@codecov
Copy link

codecov bot commented Sep 18, 2019

Codecov Report

Merging #1080 into master will not change coverage.
The diff coverage is 0%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1080   +/-   ##
=======================================
  Coverage   17.32%   17.32%           
=======================================
  Files         271      271           
  Lines        8302     8302           
  Branches     1405     1405           
=======================================
  Hits         1438     1438           
  Misses       5706     5706           
  Partials     1158     1158
Impacted Files Coverage Δ
src/store/isToolActiveForElement.js 0% <ø> (ø)
src/tools/base/BaseBrushTool.js 1.21% <0%> (ø) ⬆️

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 a9b2493...73d1d41. Read the comment docs.

@JamesAPetts JamesAPetts merged commit 2d68545 into cornerstonejs:master Sep 18, 2019
@dannyrb
Copy link
Member

dannyrb commented Sep 18, 2019

🎉 This PR is included in version 4.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@jlopes90
Copy link
Contributor

What do you think?

function isToolModeForElement(element, toolName, mode) {
	const tool = getToolForElement(element, toolName);
	
	return tool.mode === mode;
}

@dannyrb
Copy link
Member

dannyrb commented Sep 26, 2019

@jlopes90, is this something you think you would use? Are there other convenience methods you feel like we're missing?

@dannyrb
Copy link
Member

dannyrb commented Sep 26, 2019

Also, almost always better to discuss in a new issue. It's hard to keep track of topics like this on anything closed/merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants