How to use victory-brush-container - 4 common examples

To help you get started, we’ve selected a few victory-brush-container 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 FormidableLabs / victory-native / lib / components / victory-brush-container.js View on Github external
const nativeBrushMixin = (base) => class VictoryNativeSelectionContainer extends base { // eslint-disable-line max-len
  // assign native specific defaultProps over web `VictoryBrushContainer` defaultProps
  static defaultProps = {
    ...VictoryBrushContainer.defaultProps,
    brushComponent: ,
    handleComponent: 
  };

  // overrides all web events with native specific events
  static defaultEvents = (props) => {
    return [{
      target: "parent",
      eventHandlers: {
        onTouchStart: (evt, targetProps) => {
          if (props.disable) {
            return {};
          }
          BrushHelpers.onMouseMove.cancel();
          return BrushHelpers.onMouseDown(evt, targetProps);
        },
github FormidableLabs / victory-native / lib / components / victory-brush-container.js View on Github external
onTouchStart: (evt, targetProps) => {
          if (props.disable) {
            return {};
          }
          BrushHelpers.onMouseMove.cancel();
          return BrushHelpers.onMouseDown(evt, targetProps);
        },
        onTouchMove: (evt, targetProps) => {
github FormidableLabs / victory-native / lib / components / victory-brush-container.js View on Github external
onTouchMove: (evt, targetProps) => {
          return props.disable ? {} : BrushHelpers.onMouseMove(evt, targetProps);
        },
        onTouchEnd: (evt, targetProps) => {
github FormidableLabs / victory-native / lib / components / victory-brush-container.js View on Github external
onTouchEnd: (evt, targetProps) => {
          if (props.disable) {
            return {};
          }
          BrushHelpers.onMouseMove.cancel();
          return BrushHelpers.onMouseUp(evt, targetProps);
        }
      }

victory-brush-container

Interactive Brush Component for Victory

MIT
Latest version published 15 days ago

Package Health Score

98 / 100
Full package analysis