This commit is contained in:
oneao committed 2025-09-11 17:31:55 +08:00
1 parent b24015fbae
commit 6d4f1ee402
19 files changed
+782 -108

No files matched your search

+2 -20
View File
@@ -7,7 +7,7 @@ const notification = useNotification()
function showCustomMessage() {
notification.success({
title: '自定义消息',
content: () =>
message: () =>
h('div', { style: { color: 'red', position: 'relative' } }, [
h('p', {}, '这里是自定义内容,可以是任意 VNode'),
h('strong', {}, '加粗文本'),
@@ -23,29 +23,11 @@ function showCustomMessage() {
gap: '4px',
},
},
[
h(
'button',
{
style: { fontSize: '12px', padding: '2px 6px' },
onClick: () => alert('Button A clicked'),
},
'A',
),
h(
'button',
{
style: { fontSize: '12px', padding: '2px 6px' },
onClick: () => alert('Button B clicked'),
},
'B',
),
],
),
]),
type: 'success',
duration: 0,
showClose: true,
duration: 0,
})
}
</script>