@charcoal-ui/react 4.0.0-beta.7 → 4.0.0-beta.8

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.
Files changed (75) hide show
  1. package/dist/components/DropdownSelector/Divider/index.d.ts +3 -0
  2. package/dist/components/DropdownSelector/Divider/index.d.ts.map +1 -0
  3. package/dist/components/DropdownSelector/DropdownMenuItem/index.d.ts +8 -0
  4. package/dist/components/DropdownSelector/DropdownMenuItem/index.d.ts.map +1 -0
  5. package/dist/components/DropdownSelector/DropdownPopover.d.ts.map +1 -1
  6. package/dist/components/DropdownSelector/ListItem/index.d.ts +5 -13
  7. package/dist/components/DropdownSelector/ListItem/index.d.ts.map +1 -1
  8. package/dist/components/DropdownSelector/MenuItem/index.d.ts +10 -3
  9. package/dist/components/DropdownSelector/MenuItem/index.d.ts.map +1 -1
  10. package/dist/components/DropdownSelector/MenuItem/internals/useMenuItemHandleKeyDown.d.ts +1 -1
  11. package/dist/components/DropdownSelector/MenuItem/internals/useMenuItemHandleKeyDown.d.ts.map +1 -1
  12. package/dist/components/DropdownSelector/MenuItemGroup/index.d.ts +1 -3
  13. package/dist/components/DropdownSelector/MenuItemGroup/index.d.ts.map +1 -1
  14. package/dist/components/DropdownSelector/MenuList/index.d.ts +1 -4
  15. package/dist/components/DropdownSelector/MenuList/index.d.ts.map +1 -1
  16. package/dist/components/DropdownSelector/Popover/index.d.ts +1 -0
  17. package/dist/components/DropdownSelector/Popover/index.d.ts.map +1 -1
  18. package/dist/components/DropdownSelector/index.d.ts +3 -1
  19. package/dist/components/DropdownSelector/index.d.ts.map +1 -1
  20. package/dist/components/Radio/RadioGroup/index.d.ts +20 -0
  21. package/dist/components/Radio/RadioGroup/index.d.ts.map +1 -0
  22. package/dist/components/Radio/RadioGroupContext.d.ts +11 -0
  23. package/dist/components/Radio/RadioGroupContext.d.ts.map +1 -0
  24. package/dist/components/Radio/RadioInput/index.d.ts +10 -0
  25. package/dist/components/Radio/RadioInput/index.d.ts.map +1 -0
  26. package/dist/components/Radio/index.d.ts +1 -12
  27. package/dist/components/Radio/index.d.ts.map +1 -1
  28. package/dist/index.cjs.js +285 -294
  29. package/dist/index.cjs.js.map +1 -1
  30. package/dist/index.css +174 -22
  31. package/dist/index.css.map +1 -1
  32. package/dist/index.d.ts +2 -1
  33. package/dist/index.d.ts.map +1 -1
  34. package/dist/index.esm.js +230 -239
  35. package/dist/index.esm.js.map +1 -1
  36. package/package.json +8 -8
  37. package/src/components/DropdownSelector/Divider/index.css +11 -0
  38. package/src/components/DropdownSelector/Divider/index.tsx +5 -0
  39. package/src/components/DropdownSelector/DropdownMenuItem/index.css +20 -0
  40. package/src/components/DropdownSelector/DropdownMenuItem/index.tsx +34 -0
  41. package/src/components/DropdownSelector/DropdownPopover.tsx +16 -9
  42. package/src/components/DropdownSelector/ListItem/__snapshots__/index.story.storyshot +35 -94
  43. package/src/components/DropdownSelector/ListItem/index.css +24 -0
  44. package/src/components/DropdownSelector/ListItem/index.tsx +14 -53
  45. package/src/components/DropdownSelector/MenuItem/index.tsx +17 -12
  46. package/src/components/DropdownSelector/MenuItem/internals/useMenuItemHandleKeyDown.tsx +2 -2
  47. package/src/components/DropdownSelector/MenuItemGroup/index.css +19 -0
  48. package/src/components/DropdownSelector/MenuItemGroup/index.tsx +6 -28
  49. package/src/components/DropdownSelector/MenuList/__snapshots__/index.story.storyshot +159 -413
  50. package/src/components/DropdownSelector/MenuList/index.css +4 -0
  51. package/src/components/DropdownSelector/MenuList/index.tsx +4 -12
  52. package/src/components/DropdownSelector/Popover/index.css +11 -0
  53. package/src/components/DropdownSelector/Popover/index.tsx +6 -15
  54. package/src/components/DropdownSelector/__snapshots__/index.story.storyshot +389 -1167
  55. package/src/components/DropdownSelector/index.css +84 -0
  56. package/src/components/DropdownSelector/index.story.tsx +0 -4
  57. package/src/components/DropdownSelector/index.tsx +40 -102
  58. package/src/components/Modal/__snapshots__/index.story.storyshot +16 -176
  59. package/src/components/Radio/RadioGroup/index.css +5 -0
  60. package/src/components/Radio/RadioGroup/index.tsx +80 -0
  61. package/src/components/Radio/RadioGroupContext.ts +23 -0
  62. package/src/components/Radio/RadioInput/index.css +82 -0
  63. package/src/components/Radio/RadioInput/index.tsx +41 -0
  64. package/src/components/Radio/__snapshots__/index.story.storyshot +36 -30
  65. package/src/components/Radio/index.css +2 -81
  66. package/src/components/Radio/index.story.tsx +16 -6
  67. package/src/components/Radio/index.test.tsx +2 -1
  68. package/src/components/Radio/index.tsx +7 -89
  69. package/src/index.ts +2 -6
  70. package/dist/components/DropdownSelector/Divider.d.ts +0 -7
  71. package/dist/components/DropdownSelector/Divider.d.ts.map +0 -1
  72. package/dist/components/DropdownSelector/DropdownMenuItem.d.ts +0 -7
  73. package/dist/components/DropdownSelector/DropdownMenuItem.d.ts.map +0 -1
  74. package/src/components/DropdownSelector/Divider.tsx +0 -16
  75. package/src/components/DropdownSelector/DropdownMenuItem.tsx +0 -43
@@ -0,0 +1,3 @@
1
+ import './index.css';
2
+ export declare function Divider(): JSX.Element;
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/Divider/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAEpB,wBAAgB,OAAO,gBAEtB"}
@@ -0,0 +1,8 @@
1
+ import './index.css';
2
+ import { MenuItemProps } from '../MenuItem';
3
+ export type DropdownMenuItemProps = Omit<MenuItemProps, 'as'>;
4
+ /**
5
+ * DropdownSelectorの選択肢として使うMenuItem
6
+ */
7
+ export default function DropdownMenuItem(props: DropdownMenuItemProps): JSX.Element;
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/DropdownMenuItem/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAEpB,OAAiB,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAKrD,MAAM,MAAM,qBAAqB,GAAG,IAAI,CAAC,aAAa,EAAE,IAAI,CAAC,CAAA;AAE7D;;GAEG;AACH,MAAM,CAAC,OAAO,UAAU,gBAAgB,CAAC,KAAK,EAAE,qBAAqB,eAqBpE"}
@@ -1 +1 @@
1
- {"version":3,"file":"DropdownPopover.d.ts","sourceRoot":"","sources":["../../../src/components/DropdownSelector/DropdownPopover.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAqB,MAAM,OAAO,CAAA;AAC9C,OAAgB,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAEjD,KAAK,oBAAoB,GAAG,YAAY,GAAG;IACzC,KAAK,CAAC,EAAE,GAAG,CAAA;CACZ,CAAA;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,oBAAoB,eA+B3E"}
1
+ {"version":3,"file":"DropdownPopover.d.ts","sourceRoot":"","sources":["../../../src/components/DropdownSelector/DropdownPopover.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAqB,MAAM,OAAO,CAAA;AAC9C,OAAgB,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAEjD,KAAK,oBAAoB,GAAG,YAAY,GAAG;IACzC,KAAK,CAAC,EAAE,GAAG,CAAA;CACZ,CAAA;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,oBAAoB,eAsC3E"}
@@ -1,18 +1,10 @@
1
+ import './index.css';
1
2
  import { ReactNode } from 'react';
2
3
  export type CustomJSXElement = keyof JSX.IntrinsicElements | React.JSXElementConstructor<any>;
3
- export type ListItemProps<T extends CustomJSXElement = 'div'> = {
4
+ export type ListItemProps<T extends React.ElementType = 'li'> = {
4
5
  children?: ReactNode;
5
6
  as?: T;
6
- } & Omit<React.ComponentProps<T>, 'children'>;
7
- /**
8
- * リストのある要素を示すコンポーネント
9
- *
10
- * asを用いて拡張することができる
11
- * @example
12
- * ```
13
- * <ListItem as="a" href="#">Link</ListItem>
14
- * <ListItem as={NextLink} href="#">NextLink</ListItem>
15
- * ```
16
- */
17
- export default function ListItem<T extends CustomJSXElement = 'div'>(props: ListItemProps<T>): JSX.Element;
7
+ } & Omit<React.ComponentPropsWithRef<T>, 'children' | 'as'>;
8
+ declare const ListItem: <T extends import("react").ElementType<any> = "li">(p: ListItemProps<T>) => JSX.Element;
9
+ export default ListItem;
18
10
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/ListItem/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGjC,MAAM,MAAM,gBAAgB,GACxB,MAAM,GAAG,CAAC,iBAAiB,GAE3B,KAAK,CAAC,qBAAqB,CAAC,GAAG,CAAC,CAAA;AAEpC,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,gBAAgB,GAAG,KAAK,IAAI;IAC9D,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,EAAE,CAAC,EAAE,CAAC,CAAA;CACP,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,EAAE,UAAU,CAAC,CAAA;AAE7C;;;;;;;;;GASG;AACH,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,CAAC,SAAS,gBAAgB,GAAG,KAAK,EACjE,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,eAQxB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/ListItem/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAEpB,OAAO,EAA4B,SAAS,EAAW,MAAM,OAAO,CAAA;AAGpE,MAAM,MAAM,gBAAgB,GACxB,MAAM,GAAG,CAAC,iBAAiB,GAE3B,KAAK,CAAC,qBAAqB,CAAC,GAAG,CAAC,CAAA;AAEpC,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,KAAK,CAAC,WAAW,GAAG,IAAI,IAAI;IAC9D,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,EAAE,CAAC,EAAE,CAAC,CAAA;CACP,GAAG,IAAI,CAAC,KAAK,CAAC,qBAAqB,CAAC,CAAC,CAAC,EAAE,UAAU,GAAG,IAAI,CAAC,CAAA;AAE3D,QAAA,MAAM,QAAQ,8EAOqD,WAAW,CAAA;AAE9E,eAAe,QAAQ,CAAA"}
@@ -1,5 +1,5 @@
1
- import { CustomJSXElement, ListItemProps } from '../ListItem';
2
- export type MenuItemProps<T extends CustomJSXElement = never> = {
1
+ import { ListItemProps } from '../ListItem';
2
+ export type MenuItemProps<T extends React.ElementType = 'li'> = {
3
3
  value?: string;
4
4
  disabled?: boolean;
5
5
  } & ListItemProps<T>;
@@ -7,5 +7,12 @@ export type MenuItemProps<T extends CustomJSXElement = never> = {
7
7
  * 上下キーでフォーカス移動でき、エンターキーで選択できるリストの項目
8
8
  * 基本的に`<MenuList>`, `<MenuGroup>`と合わせて使用する
9
9
  */
10
- export default function MenuItem<T extends CustomJSXElement>(props: MenuItemProps<T>): JSX.Element;
10
+ declare const MenuItem: import("react").ForwardRefExoticComponent<Pick<{
11
+ value?: string | undefined;
12
+ disabled?: boolean | undefined;
13
+ } & {
14
+ children?: import("react").ReactNode;
15
+ as?: import("react").ElementType<any> | undefined;
16
+ } & Omit<any, "children" | "as">, string | number | symbol> & import("react").RefAttributes<HTMLLIElement>>;
17
+ export default MenuItem;
11
18
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/MenuItem/index.tsx"],"names":[],"mappings":"AAAA,OAAiB,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAGvE,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,gBAAgB,GAAG,KAAK,IAAI;IAC9D,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,GAAG,aAAa,CAAC,CAAC,CAAC,CAAA;AAEpB;;;GAGG;AACH,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,CAAC,SAAS,gBAAgB,EACzD,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,eAiBxB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/MenuItem/index.tsx"],"names":[],"mappings":"AACA,OAAiB,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAGrD,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,KAAK,CAAC,WAAW,GAAG,IAAI,IAAI;IAC9D,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,GAAG,aAAa,CAAC,CAAC,CAAC,CAAA;AAEpB;;;GAGG;AACH,QAAA,MAAM,QAAQ;;;;;;2GAqBZ,CAAA;AACF,eAAe,QAAQ,CAAA"}
@@ -5,5 +5,5 @@
5
5
  * @param value
6
6
  * @returns
7
7
  */
8
- export declare function useMenuItemHandleKeyDown(value?: string): [(e: React.KeyboardEvent<HTMLDivElement>) => void, () => void];
8
+ export declare function useMenuItemHandleKeyDown(value?: string): [(e: React.KeyboardEvent<HTMLElement>) => void, () => void];
9
9
  //# sourceMappingURL=useMenuItemHandleKeyDown.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useMenuItemHandleKeyDown.d.ts","sourceRoot":"","sources":["../../../../../src/components/DropdownSelector/MenuItem/internals/useMenuItemHandleKeyDown.tsx"],"names":[],"mappings":"AAIA;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,CAAC,EAAE,MAAM,GACb,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC,cAAc,CAAC,KAAK,IAAI,EAAE,MAAM,IAAI,CAAC,CAoDhE"}
1
+ {"version":3,"file":"useMenuItemHandleKeyDown.d.ts","sourceRoot":"","sources":["../../../../../src/components/DropdownSelector/MenuItem/internals/useMenuItemHandleKeyDown.tsx"],"names":[],"mappings":"AAIA;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,CAAC,EAAE,MAAM,GACb,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC,WAAW,CAAC,KAAK,IAAI,EAAE,MAAM,IAAI,CAAC,CAoD7D"}
@@ -1,3 +1,4 @@
1
+ import './index.css';
1
2
  import MenuItem from '../MenuItem';
2
3
  import { Divider } from '../Divider';
3
4
  type MenuItemGroupChild = React.ReactElement<typeof MenuItem | typeof Divider>;
@@ -5,9 +6,6 @@ export type MenuItemGroupProps = {
5
6
  text: string;
6
7
  children: MenuItemGroupChild | MenuItemGroupChild[];
7
8
  };
8
- /**
9
- * 項目のリストを分類する見出しをつけるコンテナ要素
10
- */
11
9
  export default function MenuItemGroup(props: MenuItemGroupProps): JSX.Element;
12
10
  export {};
13
11
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/MenuItemGroup/index.tsx"],"names":[],"mappings":"AACA,OAAO,QAAQ,MAAM,aAAa,CAAA;AAClC,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAA;AAEpC,KAAK,kBAAkB,GAAG,KAAK,CAAC,YAAY,CAAC,OAAO,QAAQ,GAAG,OAAO,OAAO,CAAC,CAAA;AAE9E,MAAM,MAAM,kBAAkB,GAAG;IAC/B,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,EAAE,kBAAkB,GAAG,kBAAkB,EAAE,CAAA;CACpD,CAAA;AAED;;GAEG;AACH,MAAM,CAAC,OAAO,UAAU,aAAa,CAAC,KAAK,EAAE,kBAAkB,eAO9D"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/MenuItemGroup/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAEpB,OAAO,QAAQ,MAAM,aAAa,CAAA;AAClC,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAA;AAEpC,KAAK,kBAAkB,GAAG,KAAK,CAAC,YAAY,CAAC,OAAO,QAAQ,GAAG,OAAO,OAAO,CAAC,CAAA;AAE9E,MAAM,MAAM,kBAAkB,GAAG;IAC/B,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,EAAE,kBAAkB,GAAG,kBAAkB,EAAE,CAAA;CACpD,CAAA;AAED,MAAM,CAAC,OAAO,UAAU,aAAa,CAAC,KAAK,EAAE,kBAAkB,eAO9D"}
@@ -1,3 +1,4 @@
1
+ import './index.css';
1
2
  import MenuItem from '../MenuItem';
2
3
  import { Divider } from '../Divider';
3
4
  import MenuItemGroup from '../MenuItemGroup';
@@ -8,10 +9,6 @@ export type MenuListProps = {
8
9
  value?: string;
9
10
  onChange?: (v: string) => void;
10
11
  };
11
- /**
12
- * 上下キーでフォーカス移動でき、エンターキーで選択できるリストの項目
13
- * 基本的に`<MenuItem>`, `<MenuGroup>`と合わせて使用する
14
- */
15
12
  export default function MenuList(props: MenuListProps): JSX.Element;
16
13
  export {};
17
14
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/MenuList/index.tsx"],"names":[],"mappings":"AAIA,OAAO,QAAQ,MAAM,aAAa,CAAA;AAClC,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAA;AACpC,OAAO,aAAa,MAAM,kBAAkB,CAAA;AAE5C,KAAK,aAAa,GAAG,KAAK,CAAC,YAAY,CACrC,OAAO,QAAQ,GAAG,OAAO,aAAa,GAAG,OAAO,OAAO,CACxD,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG,aAAa,GAAG,aAAa,EAAE,CAAA;AAE9D,MAAM,MAAM,aAAa,GAAG;IAC1B,QAAQ,EAAE,gBAAgB,CAAA;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;CAC/B,CAAA;AAED;;;GAGG;AACH,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,KAAK,EAAE,aAAa,eAuBpD"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/MenuList/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAKpB,OAAO,QAAQ,MAAM,aAAa,CAAA;AAClC,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAA;AACpC,OAAO,aAAa,MAAM,kBAAkB,CAAA;AAE5C,KAAK,aAAa,GAAG,KAAK,CAAC,YAAY,CACrC,OAAO,QAAQ,GAAG,OAAO,aAAa,GAAG,OAAO,OAAO,CACxD,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG,aAAa,GAAG,aAAa,EAAE,CAAA;AAE9D,MAAM,MAAM,aAAa,GAAG;IAC1B,QAAQ,EAAE,gBAAgB,CAAA;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;CAC/B,CAAA;AAED,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,KAAK,EAAE,aAAa,eAuBpD"}
@@ -1,3 +1,4 @@
1
+ import './index.css';
1
2
  import { RefObject, ReactNode } from 'react';
2
3
  export type PopoverProps = {
3
4
  isOpen: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/Popover/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAsB,SAAS,EAAE,MAAM,OAAO,CAAA;AAMhE,MAAM,MAAM,YAAY,GAAG;IACzB,MAAM,EAAE,OAAO,CAAA;IACf,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,QAAQ,EAAE,SAAS,CAAA;IACnB,UAAU,EAAE,SAAS,CAAC,OAAO,CAAC,CAAA;IAC9B,UAAU,CAAC,EAAE,SAAS,CAAC,cAAc,CAAC,CAAA;CACvC,CAAA;AAID;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,OAAO,CAAC,KAAK,EAAE,YAAY,sBA6ClD"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/DropdownSelector/Popover/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAEpB,OAAO,EAAE,SAAS,EAAsB,SAAS,EAAE,MAAM,OAAO,CAAA;AAKhE,MAAM,MAAM,YAAY,GAAG;IACzB,MAAM,EAAE,OAAO,CAAA;IACf,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,QAAQ,EAAE,SAAS,CAAA;IACnB,UAAU,EAAE,SAAS,CAAC,OAAO,CAAC,CAAA;IAC9B,UAAU,CAAC,EAAE,SAAS,CAAC,cAAc,CAAC,CAAA;CACvC,CAAA;AAID;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,OAAO,CAAC,KAAK,EAAE,YAAY,sBA+ClD"}
@@ -1,3 +1,4 @@
1
+ import './index.css';
1
2
  import { ReactNode } from 'react';
2
3
  import { MenuListChildren } from './MenuList';
3
4
  export type DropdownSelectorProps = {
@@ -17,6 +18,7 @@ export type DropdownSelectorProps = {
17
18
  name?: string;
18
19
  children: MenuListChildren;
19
20
  onChange: (value: string) => void;
21
+ className?: string;
20
22
  };
21
- export default function DropdownSelector({ onChange, ...props }: DropdownSelectorProps): JSX.Element;
23
+ export default function DropdownSelector({ onChange, showLabel, ...props }: DropdownSelectorProps): JSX.Element;
22
24
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/DropdownSelector/index.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,SAAS,EAA0C,MAAM,OAAO,CAAA;AAOhF,OAAiB,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAA;AAMvD,MAAM,MAAM,qBAAqB,GAAG;IAClC,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,gBAAgB,CAAA;IAC1B,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;CAClC,CAAA;AAID,MAAM,CAAC,OAAO,UAAU,gBAAgB,CAAC,EACvC,QAAQ,EACR,GAAG,KAAK,EACT,EAAE,qBAAqB,eA4FvB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/DropdownSelector/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAEpB,OAAc,EAAE,SAAS,EAA0C,MAAM,OAAO,CAAA;AAKhF,OAAiB,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAA;AAOvD,MAAM,MAAM,qBAAqB,GAAG;IAClC,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,gBAAgB,CAAA;IAC1B,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACjC,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAED,MAAM,CAAC,OAAO,UAAU,gBAAgB,CAAC,EACvC,QAAQ,EACR,SAAiB,EACjB,GAAG,KAAK,EACT,EAAE,qBAAqB,eA4GvB"}
@@ -0,0 +1,20 @@
1
+ import './index.css';
2
+ import * as React from 'react';
3
+ export type RadioGroupProps<Value extends string = string> = React.PropsWithChildren<{
4
+ className?: string;
5
+ value?: Value;
6
+ /**
7
+ * aria-label of RadioGroup
8
+ */
9
+ label?: string;
10
+ name: string;
11
+ onChange(next: Value): void;
12
+ disabled?: boolean;
13
+ readonly?: boolean;
14
+ invalid?: boolean;
15
+ ref?: React.Ref<HTMLDivElement>;
16
+ 'aria-labelledby'?: React.ComponentProps<'div'>['aria-labelledby'];
17
+ 'aria-orientation'?: React.ComponentProps<'div'>['aria-orientation'];
18
+ }>;
19
+ export declare const RadioGroup: <Value extends string>(props: RadioGroupProps<Value>) => JSX.Element;
20
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Radio/RadioGroup/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAGpB,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,MAAM,MAAM,eAAe,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,IACvD,KAAK,CAAC,iBAAiB,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,CAAC,EAAE,KAAK,CAAA;IACb;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,CAAC,IAAI,EAAE,KAAK,GAAG,IAAI,CAAA;IAC3B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,cAAc,CAAC,CAAA;IAC/B,iBAAiB,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,iBAAiB,CAAC,CAAA;IAClE,kBAAkB,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,kBAAkB,CAAC,CAAA;CACrE,CAAC,CAAA;AAEJ,eAAO,MAAM,UAAU,2DAsDuC,WAAW,CAAA"}
@@ -0,0 +1,11 @@
1
+ import * as React from 'react';
2
+ export interface RadioGroupContext {
3
+ name: string;
4
+ selected?: string;
5
+ disabled: boolean;
6
+ readonly: boolean;
7
+ invalid: boolean;
8
+ onChange: (next: string) => void;
9
+ }
10
+ export declare const RadioGroupContext: React.Context<RadioGroupContext>;
11
+ //# sourceMappingURL=RadioGroupContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RadioGroupContext.d.ts","sourceRoot":"","sources":["../../../src/components/Radio/RadioGroupContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,QAAQ,EAAE,OAAO,CAAA;IACjB,QAAQ,EAAE,OAAO,CAAA;IACjB,OAAO,EAAE,OAAO,CAAA;IAChB,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;CACjC;AAED,eAAO,MAAM,iBAAiB,kCAW5B,CAAA"}
@@ -0,0 +1,10 @@
1
+ import './index.css';
2
+ type CharcoalRadioInputProps = {
3
+ invalid?: boolean;
4
+ onChange?: (value: string) => void;
5
+ };
6
+ type InputProps = React.HTMLProps<HTMLInputElement>;
7
+ export type RadioInputProps = CharcoalRadioInputProps & Omit<InputProps, keyof CharcoalRadioInputProps | 'ref'>;
8
+ declare const _default: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<CharcoalRadioInputProps & Omit<InputProps, "ref" | keyof CharcoalRadioInputProps> & import("react").RefAttributes<HTMLInputElement>>>;
9
+ export default _default;
10
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Radio/RadioInput/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAKpB,KAAK,uBAAuB,GAAG;IAC7B,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;CACnC,CAAA;AAED,KAAK,UAAU,GAAG,KAAK,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAA;AAEnD,MAAM,MAAM,eAAe,GAAG,uBAAuB,GACnD,IAAI,CAAC,UAAU,EAAE,MAAM,uBAAuB,GAAG,KAAK,CAAC,CAAA;;AA2BzD,wBAA+B"}
@@ -1,5 +1,5 @@
1
- import * as React from 'react';
2
1
  import './index.css';
2
+ import * as React from 'react';
3
3
  export type RadioProps = React.PropsWithChildren<{
4
4
  value: string;
5
5
  disabled?: boolean;
@@ -13,15 +13,4 @@ declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponen
13
13
  children?: React.ReactNode;
14
14
  } & React.RefAttributes<HTMLInputElement>>>;
15
15
  export default _default;
16
- export type RadioGroupProps<Value extends string = string> = React.PropsWithChildren<{
17
- className?: string;
18
- value?: Value;
19
- name: string;
20
- onChange(next: Value): void;
21
- disabled?: boolean;
22
- readonly?: boolean;
23
- invalid?: boolean;
24
- ref?: React.Ref<HTMLDivElement>;
25
- }>;
26
- export declare const RadioGroup: <Value extends string>(props: RadioGroupProps<Value>) => JSX.Element;
27
16
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Radio/index.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,OAAO,aAAa,CAAA;AAEpB,MAAM,MAAM,UAAU,GAAG,KAAK,CAAC,iBAAiB,CAAC;IAC/C,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAC,CAAA;;;;;;;;AAsDF,wBAA0B;AAE1B,MAAM,MAAM,eAAe,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,IACvD,KAAK,CAAC,iBAAiB,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,CAAC,EAAE,KAAK,CAAA;IACb,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,CAAC,IAAI,EAAE,KAAK,GAAG,IAAI,CAAA;IAC3B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,cAAc,CAAC,CAAA;CAChC,CAAC,CAAA;AAwBJ,eAAO,MAAM,UAAU,2DAwCuC,WAAW,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Radio/index.tsx"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAA;AAGpB,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAO9B,MAAM,MAAM,UAAU,GAAG,KAAK,CAAC,iBAAiB,CAAC;IAC/C,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAC,CAAA;;;;;;;;AA6CF,wBAA0B"}