@agilekit/ui 0.1.0-alpha.32 → 0.1.0-alpha.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,11 +1,16 @@
1
1
  import React from 'react';
2
- interface TagProps {
2
+ type NamedTagColor = 'standard' | 'neutral' | 'blue' | 'green' | 'red' | 'purple' | 'yellow' | 'orange';
3
+ export interface TagProps {
3
4
  label: string;
4
- color?: 'standard' | 'blue' | 'green' | 'red' | 'purple' | string;
5
- onClick?: any;
6
- onRemove?: any;
7
- size?: 'medium' | 'small';
5
+ color?: NamedTagColor | string;
6
+ onClick?: React.MouseEventHandler<HTMLDivElement>;
7
+ onRemove?: React.MouseEventHandler<HTMLButtonElement>;
8
+ size?: 'medium' | 'small' | 'xs';
8
9
  appearence?: 'bullet' | 'solid';
10
+ hasAction?: boolean;
11
+ actionIcon?: React.ReactNode;
12
+ onAction?: React.MouseEventHandler<HTMLButtonElement>;
13
+ actionAriaLabel?: string;
9
14
  }
10
15
  declare const Tag: React.FC<TagProps>;
11
16
  export default Tag;
@@ -1 +1,2 @@
1
1
  export { default as Tag } from './Tag';
2
+ export type { TagProps } from './Tag';
@@ -0,0 +1 @@
1
+ export {};
@@ -65,7 +65,7 @@ export { default as TableListHead } from './components/TableList/components/Tabl
65
65
  export { default as TableListRow } from './components/TableList/components/TableListRow/TableListRow';
66
66
  export { default as TopBar } from './components/TopBar/TopBar';
67
67
  export { default as Tabs } from './components/Tabs/Tabs';
68
- export { default as Tag } from './components/Tag/Tag';
68
+ export { default as Tag, type TagProps } from './components/Tag/Tag';
69
69
  export { default as TextField } from './components/TextField';
70
70
  export { default as UnstyledLink } from './components/UnstyledLink/UnstyledLink';
71
71
  export { default as SpinnerCube } from './components/SpinnerCube/SpinnerCube';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agilekit/ui",
3
- "version": "0.1.0-alpha.32",
3
+ "version": "0.1.0-alpha.33",
4
4
  "description": "Agile's product component library",
5
5
  "author": "Michael de Lima Alves <michaelalves@outlook.com>",
6
6
  "license": "MIT",
@@ -1,2 +0,0 @@
1
- declare const useStyles: (props?: any) => import("@material-ui/styles").ClassNameMap<"button" | "color" | "blue" | "green" | "orange" | "purple" | "red" | "solid" | "label" | "root" | "close" | "standard" | "rootClose" | "rootClick" | "rootSmall">;
2
- export default useStyles;