Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Victoria League <[email protected]>
  • Loading branch information
willmartian and vleague2 authored Jan 13, 2025
1 parent 3ba57b1 commit 039db5a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions libs/components/src/drawer/drawer.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
import { DrawerHostDirective } from "./drawer-host.directive";

/**
* A drawer is a panel of supplmentary content that is adjacement to the page's main content.
* A drawer is a panel of supplementary content that is adjacent to the page's main content.
*
* Drawers render in `bit-layout`. Drawers must be a descendant of `bit-layout`, but they do not need to be a direct descendant.
*/
Expand All @@ -39,12 +39,12 @@ export class DrawerComponent {
/**
* The ARIA role of the drawer.
*
* - [complimentary](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/complementary_role)
* - For drawers that contain content that is complimentary to the page's main content. (default)
* - [complementary](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/complementary_role)
* - For drawers that contain content that is complementary to the page's main content. (default)
* - [navigation](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/navigation_role)
* - For drawers that primary contain links to other content.
*/
role = input<"complimentary" | "navigation">("complimentary");
role = input<"complementary" | "navigation">("complementary");

constructor() {
effect(
Expand Down
10 changes: 5 additions & 5 deletions libs/components/src/drawer/drawer.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { DrawerComponent } from "@bitwarden/components";

# Drawer

A drawer is a panel of supplmentary content that is adjacement to the page's main content.
A drawer is a panel of supplementary content that is adjacent to the page's main content.

<Primary />

Expand Down Expand Up @@ -42,7 +42,7 @@ components, respectively.
A title can be passed to the header by input:
`<bit-drawer-header title="Foobar"></bit-drawer-header>`

Custom content can be rederend before the title with the header's `start` slot:
Custom content can be rendered before the title with the header's `start` slot:

```html
<bit-drawer-header title="Foobar">
Expand All @@ -65,7 +65,7 @@ state that is bound to `open`:
<button (click)="myDrawer.toggle()"></button> <bit-drawer #myDrawer>...</bit-drawer>
```

For convience, close buttons can be created _inside_ the drawer with the `bitDrawerClose` directive:
For convenience, close buttons can be created _inside_ the drawer with the `bitDrawerClose` directive:

```html
<bit-drawer>
Expand Down Expand Up @@ -104,9 +104,9 @@ Omitting `bit-drawer-header` and `bit-drawer-body` allows for fully customizable
```

- The ARIA role of the drawer can be set with the `role` attribute:
- [complimentary](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/complementary_role)
- [complementary](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/complementary_role)
(default)
- For drawers that contain content that is complimentary to the page's main content.
- For drawers that contain content that is complementary to the page's main content.
- [navigation](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/navigation_role)
- For drawers that primary contain links to other content.

Expand Down

0 comments on commit 039db5a

Please sign in to comment.