How to use terra-responsive-element - 2 common examples

To help you get started, we’ve selected a few terra-responsive-element examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github cerner / terra-clinical / packages / terra-clinical-modal-manager / src / ModalManager.jsx View on Github external
updateFullscreenState() {
    const previousFullscreenState = this.forceFullscreenModal;

    this.forceFullscreenModal = window.innerWidth < getBreakpoints().small;

    // Only update the modal if it's minimized, open, and changing states.
    if (!this.props.isMaximized && this.props.isOpen && previousFullscreenState !== this.forceFullscreenModal) {
      this.forceUpdate();
    }
  }
github cerner / terra-core / packages / terra-modal-manager / src / ModalManager.jsx View on Github external
updateFullscreenState() {
    const previousFullscreenState = this.forceFullscreenModal;

    this.forceFullscreenModal = window.innerWidth < breakpoints.small;

    // Only update the modal if it's minimized, open, and changing states.
    if (!this.props.isMaximized && this.props.isOpen && previousFullscreenState !== this.forceFullscreenModal) {
      this.forceUpdate();
    }
  }

terra-responsive-element

The terra-responsive-element conditionally renders components based on viewport size

Apache-2.0
Latest version published 7 months ago

Package Health Score

57 / 100
Full package analysis