Skip to content

Commit

Permalink
Rename LGIDS_DRAWER to LGIDs
Browse files Browse the repository at this point in the history
  • Loading branch information
stephl3 committed Feb 12, 2025
1 parent 50b5b59 commit 981361c
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion packages/drawer/src/Drawer/Drawer.constants.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const LGID_ROOT = 'lg-drawer';

export const LGIDS_DRAWER = {
export const LGIDs = {
root: LGID_ROOT,
} as const;

Expand Down
4 changes: 2 additions & 2 deletions packages/drawer/src/Drawer/Drawer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import LeafyGreenProvider, {
import { BaseFontSize } from '@leafygreen-ui/tokens';
import { Body } from '@leafygreen-ui/typography';

import { LGIDS_DRAWER } from './Drawer.constants';
import { LGIDs } from './Drawer.constants';
import { getDrawerStyles, getHeaderStyles } from './Drawer.styles';
import { DrawerProps } from './Drawer.types';

Expand All @@ -18,7 +18,7 @@ export const Drawer = forwardRef<HTMLDivElement, DrawerProps>(
{
children,
className,
'data-lgid': dataLgId = LGIDS_DRAWER.root,
'data-lgid': dataLgId = LGIDs.root,
id: idProp,
open = false,
setOpen,
Expand Down
2 changes: 1 addition & 1 deletion packages/drawer/src/Drawer/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
export { Drawer } from './Drawer';
export { LGIDS_DRAWER } from './Drawer.constants';
export { LGIDs } from './Drawer.constants';
export { type DrawerProps } from './Drawer.types';
2 changes: 1 addition & 1 deletion packages/drawer/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
export { Drawer, type DrawerProps, LGIDS_DRAWER } from './Drawer';
export { Drawer, type DrawerProps, LGIDs } from './Drawer';
export { getTestUtils } from './utils';
4 changes: 2 additions & 2 deletions packages/drawer/src/utils/getTestUtils.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { getByLgId } from '@lg-tools/test-harnesses';

import { LGIDS_DRAWER } from '../Drawer';
import { LGIDs } from '../Drawer';

import { GetTestUtilsReturnType } from './getTestUtils.types';

export const getTestUtils = <T extends HTMLElement = HTMLElement>(
lgId: string = LGIDS_DRAWER.root,
lgId: string = LGIDs.root,
): GetTestUtilsReturnType<T> => {
/**
* Queries the DOM for the element using the `data-lgid` data attribute.
Expand Down

0 comments on commit 981361c

Please sign in to comment.