From 3625006c8734337683957f76a9daf2f926fa5a21 Mon Sep 17 00:00:00 2001 From: Julien Calixte Date: Tue, 8 Apr 2025 21:53:09 +0200 Subject: [PATCH] fix: notyf style --- src/styles/app.css | 14 +++++++++++--- src/utils/notif.ts | 9 ++++++--- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/src/styles/app.css b/src/styles/app.css index 9b78e11..4a1a277 100644 --- a/src/styles/app.css +++ b/src/styles/app.css @@ -88,9 +88,17 @@ a { } } -.notyf__wrapper { - padding-top: 0; - padding-bottom: 0; +.notyf__toast { + border-radius: revert-layer; + border: none; +} + +.alert-success .notyf__message { + color: var(--color-success-content); +} + +.alert-error .notyf__message { + color: var(--color-error-content); } .alert { diff --git a/src/utils/notif.ts b/src/utils/notif.ts index a056d16..ee369b5 100644 --- a/src/utils/notif.ts +++ b/src/utils/notif.ts @@ -3,11 +3,11 @@ import { Notyf } from 'notyf' const notif = new Notyf({ types: [ { - className: 'prose alert alert-success', + className: 'alert alert-success', type: 'confirm' }, { - className: 'prose alert alert-error', + className: 'alert alert-error', type: 'error' } ] @@ -20,4 +20,7 @@ export const confirmMessage = (message: string) => }) export const errorMessage = (message: string) => - notif.open({ type: 'error', message }) + notif.open({ + type: 'error', + message + })