How to use the @react-md/tree.useTreeItemSelection function in @react-md/tree

To help you get started, we’ve selected a few @react-md/tree 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 mlaursen / react-md / packages / documentation / components / Demos / Tree / MultiSelectTree.tsx View on Github external
const MultiSelectTree: FC = () => {
  const selection = useTreeItemSelection([], true);
  const expansion = useTreeItemExpansion([]);

  return (
    }
    />
  );
};
github mlaursen / react-md / packages / documentation / src / components / Demos / Tree / MultiSelectTree.tsx View on Github external
const MultiSelectTree: FC = () => {
  const selection = useTreeItemSelection([], true);
  const expansion = useTreeItemExpansion([]);

  return (
    
  );
};
github mlaursen / react-md / packages / documentation / components / Demos / Tree / SingleSelectTree.tsx View on Github external
const SingleSelectTree: FC = () => {
  const selection = useTreeItemSelection([], false);
  const expansion = useTreeItemExpansion([]);

  return (
    }
    />
  );
};
github mlaursen / react-md / packages / documentation / src / components / Demos / Tree / SingleSelectTree.tsx View on Github external
const SingleSelectTree: FC = () => {
  const selection = useTreeItemSelection([], false);
  const expansion = useTreeItemExpansion([]);

  return (
    
  );
};
github mlaursen / react-md / packages / documentation / components / Demos / Tree / CustomizingTreeItems.tsx View on Github external
const CustomizingTreeItems: FC = () => {
  const selection = useTreeItemSelection([demo.itemId], false);
  const expansion = useTreeItemExpansion([
    srcFolder.itemId,
    publicFolder.itemId,
  ]);

  return (
    
  );

@react-md/tree

A package for creating an accessible tree component following the tree role.

MIT
Latest version published 1 year ago

Package Health Score

60 / 100
Full package analysis