What this family solves
Canonical transient-feedback family with a Toast component, adapter-owned delivery layers, and thin purpose-toast wrappers for common message intent.
Marwes documentation
Canonical transient-feedback family with a Toast component, adapter-owned delivery layers, and thin purpose-toast wrappers for common message intent.
Canonical transient-feedback family with a Toast component, adapter-owned delivery layers, and thin purpose-toast wrappers for common message intent.
Choose a semantic toast intent so transient status messages remain consistent and understandable.
Persistent informational toast messaging
Confirmation of a completed outcome
Important caution before a problem occurs
Actionable failure messaging with assertive urgency
Choose an adapter in the verified examples. The inventory below reflects each framework package exactly.
@marwes-ui/reactErrorToast, InfoToast, SuccessToast, Toast, ToastContainer, ToastProvider, WarningToast
ErrorToastProps, InfoToastProps, ManagedToast, ShowToastOptions, SuccessToastProps, ToastContainerProps, ToastController, ToastProps, ToastProviderProps, WarningToastProps
useToast
@marwes-ui/vueErrorToast, InfoToast, SuccessToast, Toast, ToastContainer, ToastProvider, WarningToast
ErrorToastProps, InfoToastProps, ManagedToast, ShowToastOptions, SuccessToastProps, ToastContainerProps, ToastController, ToastProps, ToastProviderProps, WarningToastProps
useToast
@marwes-ui/svelteErrorToast, InfoToast, SuccessToast, Toast, ToastContainer, ToastProvider, WarningToast
ErrorToastProps, InfoToastProps, ManagedToast, ShowToastOptions, SuccessToastProps, ToastContainerProps, ToastController, ToastProps, ToastProviderProps, WarningToastProps
useToast
These examples come from the same fixtures verified by the repository checks.
import { ErrorToast, InfoToast, SuccessToast, Toast, WarningToast } from "@marwes-ui/react"
import { useState } from "react"
export function Example() {
const [dismissed, setDismissed] = useState<Set<string>>(new Set())
const dismiss = (id: string) => setDismissed((prev) => new Set([...prev, id]))
return (
<>
{!dismissed.has("neutral") && (
<Toast variant="subtle" onDismiss={() => dismiss("neutral")}>
Neutral message
</Toast>
)}
{!dismissed.has("info") && (
<InfoToast variant="subtle" onDismiss={() => dismiss("info")}>
Meeting starts in 10 min
</InfoToast>
)}
{!dismissed.has("success") && (
<SuccessToast variant="subtle" onDismiss={() => dismiss("success")}>
Your email is verified
</SuccessToast>
)}
{!dismissed.has("warning") && (
<WarningToast variant="subtle" onDismiss={() => dismiss("warning")}>
Connection unstable
</WarningToast>
)}
{!dismissed.has("error") && (
<ErrorToast variant="subtle" onDismiss={() => dismiss("error")}>
Something went wrong
</ErrorToast>
)}
</>
)
}<script setup lang="ts">
import { ref } from "vue"
import { ErrorToast, InfoToast, SuccessToast, Toast, WarningToast } from "@marwes-ui/vue"
const dismissed = ref<Set<string>>(new Set())
const dismiss = (id: string) => (dismissed.value = new Set([...dismissed.value, id]))
</script>
<template>
<Toast v-if="!dismissed.has('neutral')" variant="subtle" @dismiss="dismiss('neutral')">
Neutral message
</Toast>
<InfoToast v-if="!dismissed.has('info')" variant="subtle" @dismiss="dismiss('info')">
Meeting starts in 10 min
</InfoToast>
<SuccessToast v-if="!dismissed.has('success')" variant="subtle" @dismiss="dismiss('success')">
Your email is verified
</SuccessToast>
<WarningToast v-if="!dismissed.has('warning')" variant="subtle" @dismiss="dismiss('warning')">
Connection unstable
</WarningToast>
<ErrorToast v-if="!dismissed.has('error')" variant="subtle" @dismiss="dismiss('error')">
Something went wrong
</ErrorToast>
</template><script lang="ts">
import { ErrorToast, InfoToast, SuccessToast, Toast, WarningToast } from "@marwes-ui/svelte"
let dismissed = $state<Set<string>>(new Set())
const dismiss = (id: string) => (dismissed = new Set([...dismissed, id]))
</script>
{#if !dismissed.has("neutral")}
<Toast variant="subtle" ondismiss={() => dismiss("neutral")}>Neutral message</Toast>
{/if}
{#if !dismissed.has("info")}
<InfoToast variant="subtle" ondismiss={() => dismiss("info")}>Meeting starts in 10 min</InfoToast>
{/if}
{#if !dismissed.has("success")}
<SuccessToast variant="subtle" ondismiss={() => dismiss("success")}>Your email is verified</SuccessToast>
{/if}
{#if !dismissed.has("warning")}
<WarningToast variant="subtle" ondismiss={() => dismiss("warning")}>Connection unstable</WarningToast>
{/if}
{#if !dismissed.has("error")}
<ErrorToast variant="subtle" ondismiss={() => dismiss("error")}>Something went wrong</ErrorToast>
{/if}Toast uses Marwes preset CSS and theme variables. Customize it through the theme passed to MarwesProvider; do not add a second component stylesheet. See the theming guide for configuration and token details.