Skip to content

Commit

Permalink
feat: Allow native div props on InlineNotification (#5070)
Browse files Browse the repository at this point in the history
  • Loading branch information
dougmacknz authored Sep 20, 2024
1 parent 218f3d0 commit 9160155
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .changeset/silver-cougars-explain.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@kaizen/components": minor
---

Allow native div props on InlineNotification
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React from "react"
import React, { HTMLAttributes } from "react"
import classnames from "classnames"
import { HeadingProps } from "~components/Heading"
import { OverrideClassName } from "~components/types/OverrideClassName"
Expand All @@ -9,7 +9,7 @@ import {
} from "../subcomponents/GenericNotification"
import styles from "../subcomponents/GenericNotification/GenericNotification.module.scss"

export type InlineNotificationBase = OverrideClassName<{
export type InlineNotificationBase = {
children?: React.ReactNode
/** @default false */
persistent?: boolean
Expand All @@ -20,7 +20,8 @@ export type InlineNotificationBase = OverrideClassName<{
forceMultiline?: boolean
headingProps?: HeadingProps
isSubtle?: boolean
}>
} & Omit<OverrideClassName<HTMLAttributes<HTMLDivElement>>, "style">
// Omitted `style` above because GenericNotification has its own `style` prop

export type InlineNotificationProps = InlineNotificationBase &
(GenericNotificationType | GenericNotificationVariant)
Expand Down

0 comments on commit 9160155

Please sign in to comment.