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/custom onDropHandler for viewportGrid #4641

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Jaseel-trenser
Copy link
Contributor

Context

  • An option has been implemented to allow custom onDropHandler in viewort grid. This enhancement enables users for handling of additional functionalities during the onDrop event to the viewport.
  • This PR has been incorporated by FlyWheel.io.

Changes & Results

  • Introduced a custom onDropHandler to handle additional functionalities during the onDrop to the viewpor

Testing

Checklist

PR

  • My Pull Request title is descriptive, accurate and follows the
    semantic-release format and guidelines.

Code

  • My code has been well-documented (function documentation, inline comments,
    etc.)

Public Documentation Updates

  • The documentation page has been updated as necessary for any public API
    additions or removals.

Tested Environment

  • OS: Windows 11
  • Node version: 18.20.3
  • Browser: Chrome

Copy link

netlify bot commented Jan 3, 2025

Deploy Preview for ohif-dev ready!

Name Link
🔨 Latest commit 061aa1f
🔍 Latest deploy log https://app.netlify.com/sites/ohif-dev/deploys/67937dd799e2d60008fa5054
😎 Deploy Preview https://deploy-preview-4641--ohif-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Jan 3, 2025

Deploy Preview for ohif-platform-docs canceled.

Name Link
🔨 Latest commit 061aa1f
🔍 Latest deploy log https://app.netlify.com/sites/ohif-platform-docs/deploys/67937dd75de786000889c145

@sedghi
Copy link
Member

sedghi commented Jan 23, 2025

Can you rebase on top of the new customization service and follow what's done there please? Sorry for the inconvenience

@Jaseel-trenser Jaseel-trenser force-pushed the feat/custom-onDropHandler-for-viewportGrid branch from 651d7f7 to 6196ac2 Compare January 24, 2025 05:53
@Jaseel-trenser
Copy link
Contributor Author

Can you rebase on top of the new customization service and follow what's done there please? Sorry for the inconvenience

@sedghi I’ve rebased and updated the changes based on the new customization service.

const updatedViewports = _getUpdatedViewports(viewportId, displaySetInstanceUID);
viewportGridService.setDisplaySetsForViewports(updatedViewports);
let dropHandlerPromise = Promise.resolve({ handled: false });
const customOnDropHandler = customizationService.getCustomization('customOnDropHandler');
Copy link
Member

Choose a reason for hiding this comment

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

you need to provide a default null in the customizations folder in the extension. Also document it in here https://docs.ohif.org/platform/services/customization-service/customizationService#customizable-parts-of-ohif

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.

2 participants