0.0.4 • Published 2 years ago

@truework/true-command v0.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

@truework/TrueCommand

Command bar for creating app shortcuts

npm i @truework/true-command

Example

To open the command palette press Cmd/Ctrl + k

import { CommandPalette } from '@truework/true-command';
// needed to use default command palette styles
import '@truework/true-command/dist/styles.css';

export function CommandBar() {
  return (
    <CommandPalette
      commands={[
        {
          name: 'Start verification',
          action: () => {
            console.log('Start verification action');
          },
          shortcutKey: {
            key: 'N',
            specialKey: 'shift'
          }
        },
        {
          name: 'Open settings',
          description: 'Opens the settings page',
          action: () => {
            console.log('Open settings action');
          }
        }
      ]}
    />
  );
}
0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1-beta.6

2 years ago

0.0.1-beta.5

2 years ago

0.0.1-beta.4

2 years ago

0.0.1-beta.3

2 years ago

0.0.1-beta.2

2 years ago

0.0.1-beta.1

2 years ago

0.0.1-beta.0

2 years ago