How to use the @patternfly/patternfly/components/OptionsMenu/options-menu.css.optionsMenuToggleText function in @patternfly/patternfly

To help you get started, we’ve selected a few @patternfly/patternfly 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 patternfly / patternfly-react / packages / patternfly-4 / react-core / src / components / OptionsMenu / OptionsMenuToggleWithText.js View on Github external
isHovered,
  isActive,
  isFocused,
  'aria-label': ariaLabel
}) => (
  <div>
    <span>{toggleText}</span>
    <button aria-expanded="{isOpen}" aria-label="{ariaLabel}" aria-haspopup="listbox" id="{`${parentId}-toggle`}">
      {toggleButtonContents}
    </button>
  </div>
);
github patternfly / patternfly-react / packages / patternfly-4 / react-core / src / components / OptionsMenu / OptionsMenuToggle.js View on Github external
className={css(
        styles.optionsMenuToggle,
        isPlain &amp;&amp; getModifier(styles, 'plain'),
        isHovered &amp;&amp; getModifier(styles, 'hover'),
        isActive &amp;&amp; getModifier(styles, 'active'),
        isFocused &amp;&amp; getModifier(styles, 'focus')
      )}
      id={`${parentId}-toggle`}
      aria-haspopup="listbox"
      aria-label={ariaLabel}
      aria-expanded={isOpen}
      onClick={onToggle}
    &gt;
      {ToggleTemplate &amp;&amp;
        (!isPlain ? (
          <span>{template}</span>
        ) : (
          {template}
        ))}
      {!hideCaret &amp;&amp; }
    
  );
};