mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
Merge pull request #17212 from overleaf/jpa-writefull-promo-spacing
[web] fix spacing of notifications on the project dashboard GitOrigin-RevId: 565159334d92c6f73da4c6a7174536cd0a3c5616
This commit is contained in:
parent
06c839a230
commit
23281255a1
2 changed files with 10 additions and 9 deletions
|
@ -16,6 +16,7 @@ type NotificationProps = {
|
|||
action?: React.ReactElement
|
||||
onDismiss?: AlertProps['onDismiss']
|
||||
className?: string
|
||||
newNotificationStyle?: boolean
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -35,12 +36,12 @@ function Notification({
|
|||
className,
|
||||
body,
|
||||
action,
|
||||
newNotificationStyle,
|
||||
...props
|
||||
}: NotificationProps) {
|
||||
const newNotificationStyle = getMeta(
|
||||
'ol-newNotificationStyle',
|
||||
false
|
||||
) as boolean
|
||||
newNotificationStyle =
|
||||
newNotificationStyle ??
|
||||
(getMeta('ol-newNotificationStyle', false) as boolean)
|
||||
|
||||
const [show, setShow] = useState(true)
|
||||
|
||||
|
@ -61,7 +62,7 @@ function Notification({
|
|||
bsStyle === 'danger' ? 'error' : bsStyle
|
||||
) as NotificationType
|
||||
return (
|
||||
<li>
|
||||
<li className={classnames('notification-entry', className)}>
|
||||
<NewNotification
|
||||
type={newNotificationType}
|
||||
isDismissible={onDismiss != null}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { memo, useCallback } from 'react'
|
||||
import Notification from '@/shared/components/notification'
|
||||
import Notification from './notification'
|
||||
import { sendMB } from '@/infrastructure/event-tracking'
|
||||
import customLocalStorage from '@/infrastructure/local-storage'
|
||||
import WritefullLogo from '@/shared/svgs/writefull-logo'
|
||||
|
@ -32,10 +32,10 @@ function WritefullPremiumPromoBanner({
|
|||
|
||||
return (
|
||||
<Notification
|
||||
type="info"
|
||||
isDismissible
|
||||
bsStyle="info"
|
||||
newNotificationStyle
|
||||
onDismiss={handleClose}
|
||||
content={
|
||||
body={
|
||||
<>
|
||||
Enjoying Writefull? Get <strong>10% off Writefull Premium</strong>,
|
||||
giving you access to TeXGPT—AI assistance to generate LaTeX code. Use{' '}
|
||||
|
|
Loading…
Reference in a new issue