@theroutingcompany/components 0.0.101 → 0.0.103

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@theroutingcompany/components",
3
- "version": "0.0.101",
3
+ "version": "0.0.103",
4
4
  "description": "The Routing Company Components",
5
5
  "main": "./dist/trc-components.umd.js",
6
6
  "module": "./dist/trc-components.es.js",
@@ -77,7 +77,7 @@
77
77
  "@react-aria/listbox": "^3.9.1",
78
78
  "@react-aria/menu": "^3.9.1",
79
79
  "@react-aria/numberfield": "^3.5.1",
80
- "@react-aria/overlays": "^3.14.1",
80
+ "@react-aria/overlays": "^3.23.1",
81
81
  "@react-aria/progress": "^3.4.2",
82
82
  "@react-aria/radio": "^3.6.1",
83
83
  "@react-aria/searchfield": "^3.5.2",
@@ -107,14 +107,16 @@
107
107
  "@styled-system/prop-types": "^5.1.2",
108
108
  "@styled-system/props": "^5.1.5",
109
109
  "@tanstack/react-table": "^8.9.1",
110
- "@theroutingcompany/design-tokens": "^0.0.9",
110
+ "@theroutingcompany/design-tokens": "0.0.14",
111
111
  "@types/styled-system": "^5.1.16",
112
112
  "csstype": "^3.1.2",
113
113
  "react-focus-lock": "^2.9.4",
114
+ "react-google-autocomplete": "^2.7.3",
114
115
  "react-scrolllock": "^5.0.1",
115
116
  "react-transition-group": "^4.4.5",
116
117
  "styled-components": "^5.3.9",
117
- "styled-system": "^5.1.5"
118
+ "styled-system": "^5.1.5",
119
+ "usehooks-ts": "^3.1.0"
118
120
  },
119
121
  "peerDependencies": {
120
122
  "@material-ui/icons": "^4.11.3",
@@ -138,6 +140,7 @@
138
140
  "@storybook/react-vite": "^7.0.3",
139
141
  "@storybook/testing-library": "^0.1.0",
140
142
  "@types/eslint": "^8.37.0",
143
+ "@types/google.maps": "^3.55.11",
141
144
  "@types/prettier": "^2.7.2",
142
145
  "@types/react": "^18.0.34",
143
146
  "@types/react-dom": "^18.0.11",
@@ -1,6 +1,6 @@
1
1
  import * as AccordionPrimitive from '@radix-ui/react-accordion';
2
- import { AccordionItemProps } from '@radix-ui/react-accordion';
3
- import { CSSProperties, type ReactNode } from 'react';
2
+ import { type AccordionItemProps } from '@radix-ui/react-accordion';
3
+ import { type CSSProperties, type ReactNode } from 'react';
4
4
  export declare const SectionTitle: import("styled-components").StyledComponent<"span", any, {}, never>;
5
5
  export interface SectionHeaderProps extends AccordionPrimitive.AccordionHeaderProps {
6
6
  children: ReactNode;
@@ -11,5 +11,6 @@ interface BoxPopoverProps extends Omit<AriaPopoverProps, 'popoverRef'> {
11
11
  export declare function BoxPopover(props: Omit<BoxPopoverProps, 'triggerRef'> & {
12
12
  targetRef: React.RefObject<HTMLElement>;
13
13
  disableFocusManagement?: boolean;
14
+ className?: string;
14
15
  }): import("react/jsx-runtime").JSX.Element;
15
16
  export {};
@@ -0,0 +1,36 @@
1
+ /// <reference types="google.maps" />
2
+ import { type ReactNode } from 'react';
3
+ declare const PlaceResult: import("styled-components").StyledComponent<import("components/Text/Text").PolymorphicText, any, {}, never>;
4
+ export declare const getSelectedName: (selected: google.maps.places.PlaceResult) => string | undefined;
5
+ export type GoogleInputProps = {
6
+ googleApiKey: string;
7
+ placeholder?: string;
8
+ options?: Omit<google.maps.places.AutocompletionRequest, 'input'>;
9
+ libraries?: string[];
10
+ googleMapsScriptBaseUrl?: string;
11
+ debounce?: number;
12
+ defaultValue?: string;
13
+ value?: string;
14
+ onChange?: (value: google.maps.places.PlaceResult) => void;
15
+ disabled?: boolean;
16
+ isInvalid?: boolean;
17
+ id?: string;
18
+ 'data-id'?: string;
19
+ label?: ReactNode;
20
+ boldLabel?: boolean;
21
+ hideLabel?: boolean;
22
+ labelId?: string;
23
+ inputId?: string;
24
+ tooltipContent?: React.ReactNode;
25
+ autoFocus?: boolean;
26
+ errorMessage?: string;
27
+ extraMenuActions?: {
28
+ label: ReactNode;
29
+ id: string;
30
+ onClick: () => void;
31
+ }[];
32
+ showExtraActionsWithResults?: boolean;
33
+ };
34
+ declare const GoogleInput: ({ googleApiKey, placeholder, options, libraries, googleMapsScriptBaseUrl, debounce, defaultValue, value, onChange, disabled, isInvalid, label, labelId, inputId, hideLabel, boldLabel, autoFocus, extraMenuActions, showExtraActionsWithResults, ...props }: GoogleInputProps) => import("react/jsx-runtime").JSX.Element;
35
+ export default GoogleInput;
36
+ export { GoogleInput };
@@ -0,0 +1 @@
1
+ export * from './GoogleInput';
@@ -1,7 +1,7 @@
1
1
  import type { CollectionChildren } from '@react-types/shared';
2
2
  import React from 'react';
3
3
  import { useMultiSelectState } from './useMultiSelectState';
4
- export { Item as MultiSelectItem, Section as MultiSelectSection, } from '@react-stately/collections';
4
+ export { Item as MultiSelectItem, Section as MultiSelectSection } from '@react-stately/collections';
5
5
  export type OptionItem = {
6
6
  children?: never;
7
7
  id: string;
@@ -1,8 +1,8 @@
1
1
  import type { AriaSelectProps } from '@react-types/select';
2
2
  import type { CollectionChildren } from '@react-types/shared';
3
3
  import * as React from 'react';
4
+ export { Item as SingleSelectItem, Section as SingleSelectSection } from '@react-stately/collections';
4
5
  export { CollectionChildren as SingleSelectChildren };
5
- export { Item as SingleSelectItem, Section as SingleSelectSection, } from '@react-stately/collections';
6
6
  type SingleSelectProps<T> = Omit<AriaSelectProps<T>, 'children'> & {
7
7
  placeholder?: string;
8
8
  tooltipIcon?: string;
@@ -18,6 +18,7 @@ export * from './DropdownMenu/DropdownMenu';
18
18
  export * from './Fieldset/Fieldset';
19
19
  export * from './FileUpload/FileUpload';
20
20
  export * from './Flex/Flex';
21
+ export * from './GoogleInput';
21
22
  export * from './FormControl/FormControl';
22
23
  export * from './IconButton/IconButton';
23
24
  export * from './Input/InputBase';
@@ -1,3 +1,3 @@
1
1
  export * from './useWindowEvent';
2
- export * from './useOutsideClick';
2
+ export * from './useOnEscapeKey';
3
3
  export * from './usePrevious';
@@ -0,0 +1,2 @@
1
+ declare const useOnEscapeKey: (handler: () => void) => void;
2
+ export default useOnEscapeKey;
@@ -1 +0,0 @@
1
- export declare const useOutsideClick: (ref: React.RefObject<HTMLElement>, onOutsideClick: () => void) => void;