@theroutingcompany/components 0.0.30-alpha.1 → 0.0.30-alpha.3

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.30-alpha.1",
3
+ "version": "0.0.30-alpha.3",
4
4
  "description": "The Routing Company Components",
5
5
  "main": "./dist/trc-components.umd.js",
6
6
  "module": "./dist/trc-components.es.js",
@@ -28,9 +28,10 @@ export default Drawer;
28
28
  */
29
29
  type UseDrawerProps = {
30
30
  initialOpen?: boolean;
31
+ triggerToggle?: boolean;
31
32
  id?: string;
32
33
  };
33
- export declare function useDrawer({ initialOpen, id, }?: UseDrawerProps): {
34
+ export declare function useDrawer({ initialOpen, triggerToggle, id, }?: UseDrawerProps): {
34
35
  isOpen: boolean;
35
36
  toggleDrawer: () => void;
36
37
  openDrawer: () => void;
@@ -2,6 +2,7 @@ import { type BoxProps } from '../Box';
2
2
  interface ContainerProps extends BoxProps {
3
3
  $state?: string;
4
4
  $viewportPosition?: string;
5
+ name?: string;
5
6
  }
6
7
  export declare const Container: import("styled-components").StyledComponent<import("../..").ForwardRefComponent<"div", BoxProps>, any, ContainerProps, never>;
7
8
  export {};
@@ -18,8 +18,10 @@ export interface InlineEditProps extends ButtonPropsV2 {
18
18
  onCancel?: () => void;
19
19
  disabled?: boolean;
20
20
  valid?: boolean;
21
+ label?: string | ReactNode;
22
+ labelId?: string;
21
23
  }
22
24
  export declare const InlineEdit: {
23
- ({ children, placeholder, value, editValue, hideIcon, p, onChange, onToggle, onCancel, disabled, valid, ...rest }: InlineEditProps): import("react/jsx-runtime").JSX.Element;
25
+ ({ children, placeholder, value, editValue, hideIcon, p, onChange, onToggle, onCancel, disabled, valid, label, labelId, ...rest }: InlineEditProps): import("react/jsx-runtime").JSX.Element;
24
26
  displayName: string;
25
27
  };
@@ -1,7 +1,8 @@
1
+ import { type BoxProps } from 'components/Box';
1
2
  import type { ReactNode } from 'react';
2
3
  import type { ComponentPropsWithoutStyles } from '../../helpers/typeHelpers';
3
- export interface LabelProps extends ComponentPropsWithoutStyles<'label'> {
4
- size?: 'small' | 'medium' | 'large';
4
+ export interface LabelProps extends ComponentPropsWithoutStyles<'label'>, Omit<BoxProps, 'color'> {
5
+ size?: 'xsmall' | 'small' | 'medium' | 'large' | 'xlarge';
5
6
  bold?: boolean;
6
7
  /** Screen Reader Only */
7
8
  srOnly?: boolean;
@@ -9,5 +10,6 @@ export interface LabelProps extends ComponentPropsWithoutStyles<'label'> {
9
10
  children: ReactNode;
10
11
  as?: 'legend' | 'span' | undefined;
11
12
  style?: Record<string, any>;
13
+ color?: string;
12
14
  }
13
- export declare function Label({ children, bold, size, display, srOnly, style, ...remainingProps }: LabelProps): import("react/jsx-runtime").JSX.Element;
15
+ export declare function Label({ children, bold, size, display, srOnly, style, color, ...remainingProps }: LabelProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,7 @@
1
+ import { type ReactNode } from 'react';
2
+ export interface LabeledTextProps {
3
+ label: string;
4
+ value: string | ReactNode;
5
+ }
6
+ declare const LabeledText: ({ label, value }: LabeledTextProps) => import("react/jsx-runtime").JSX.Element;
7
+ export default LabeledText;
@@ -0,0 +1,2 @@
1
+ export { default as LabeledText } from './LabeledText';
2
+ export * from './LabeledText';
@@ -4,10 +4,11 @@ interface TitleBaseProps extends BoxProps {
4
4
  weight?: 'light' | 'normal' | 'regular' | 'medium' | 'bold';
5
5
  }
6
6
  export declare const TitleBase: import("styled-components").StyledComponent<import("helpers").ForwardRefComponent<"div", BoxProps>, any, TitleBaseProps, never>;
7
- export interface TitleProps extends BoxProps {
7
+ export interface TitleProps {
8
8
  as?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'legend' | 'figcaption';
9
9
  size?: 'small' | 'medium' | 'large' | 'xsmall';
10
10
  weight?: 'light' | 'normal' | 'regular' | 'medium' | 'bold';
11
+ height?: string;
11
12
  }
12
13
  export type PolymorphicTitle = Polymorphic.ForwardRefComponent<'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6', TitleProps>;
13
14
  export declare const Title: PolymorphicTitle;
@@ -22,6 +22,7 @@ export * from './Input/TextInput/TextInput';
22
22
  export * from './Input/InlineEdit/InlineEdit';
23
23
  export * from './Input/TimeInput/TimeInput';
24
24
  export * from './Label/Label';
25
+ export * from './LabeledText';
25
26
  export * from './MultiSelect/MultiSelect';
26
27
  export * from './NavigationMenu/NavigationMenu';
27
28
  export * from './Page/Page';