Skip to content

Commit

Permalink
docs(notification): export internal bq-icon shadow parts
Browse files Browse the repository at this point in the history
  • Loading branch information
dgonzalezr committed Jun 29, 2023
1 parent 156e13c commit 44bcd39
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,17 @@ import { debounce, hasSlotContent, TDebounce, validatePropValue } from '../../sh
const notificationPortal = Object.assign(document.createElement('div'), { className: 'bq-notification-portal' });

/**
* @part base - The wrapper container `<div>` of the element inside the shadow DOM
* @part base - The `<div>` container of the predefined bq-icon component.
* @part body - The conatiner `<div>` that wraps the notification description content
* @part btn-close - The `bq-button` used to close the notification
* @part content - The conatiner `<div>` that wraps all the notification content (title, description, footer)
* @part footer - The conatiner `<div>` that wraps the notification footer content
* @part icon - The `<bq-icon>` element used to render a predefined icon based on the notification type
* @part icon-outline - The conatiner `<div>` that wraps the icon element
* @part main - The conatiner `<div>` that wraps the notification main content (title, description)
* @part svg - The `<svg>` element of the predefined bq-icon component.
* @part title - The conatiner `<div>` that wraps the notification title content
* @part wrapper - The wrapper container `<div>` of the element inside the shadow DOM
*/

@Component({
Expand Down Expand Up @@ -210,7 +212,7 @@ export class BqNotification {
render() {
return (
<Host aria-hidden={!this.isOpen ? 'true' : 'false'} hidden={!this.isOpen ? 'true' : 'false'} role="alert">
<div class="bq-notification" part="base">
<div class="bq-notification" part="wrapper">
{/* CLOSE BUTTON */}
{!this.disableClose && (
<bq-button
Expand All @@ -233,7 +235,7 @@ export class BqNotification {
part="icon-outline"
>
<slot name="icon">
<bq-icon name={this.iconName} part="icon" />
<bq-icon name={this.iconName} part="icon" exportparts="base,svg" />
</slot>
</div>
{/* MAIN */}
Expand Down
4 changes: 3 additions & 1 deletion packages/bee-q/src/components/notification/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,15 +62,17 @@ Type: `Promise<void>`

| Part | Description |
| ---------------- | ------------------------------------------------------------------------------------------ |
| `"base"` | The wrapper container `<div>` of the element inside the shadow DOM |
| `"base"` | The `<div>` container of the predefined bq-icon component. |
| `"body"` | The conatiner `<div>` that wraps the notification description content |
| `"btn-close"` | The `bq-button` used to close the notification |
| `"content"` | The conatiner `<div>` that wraps all the notification content (title, description, footer) |
| `"footer"` | The conatiner `<div>` that wraps the notification footer content |
| `"icon"` | The `<bq-icon>` element used to render a predefined icon based on the notification type |
| `"icon-outline"` | The conatiner `<div>` that wraps the icon element |
| `"main"` | The conatiner `<div>` that wraps the notification main content (title, description) |
| `"svg"` | The `<svg>` element of the predefined bq-icon component. |
| `"title"` | The conatiner `<div>` that wraps the notification title content |
| `"wrapper"` | The wrapper container `<div>` of the element inside the shadow DOM |


## Dependencies
Expand Down

0 comments on commit 44bcd39

Please sign in to comment.