mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-15 05:37:32 +00:00
refactor(core): move actions to footer of notification card (#11894)
This PR move all actions button to the footer of `NotificationCard`. There are some example as following: ### No Changes    ### Changes ### Before  #### After 
This commit is contained in:
@@ -35,13 +35,16 @@ function notify(std: BlockStdScope, title: string, message: string) {
|
||||
message,
|
||||
accent: 'info',
|
||||
duration: 10 * 1000,
|
||||
action: {
|
||||
label: 'Undo',
|
||||
onClick: () => {
|
||||
doc.undo();
|
||||
clear();
|
||||
actions: [
|
||||
{
|
||||
key: 'undo',
|
||||
label: 'Undo',
|
||||
onClick: () => {
|
||||
doc.undo();
|
||||
clear();
|
||||
},
|
||||
},
|
||||
},
|
||||
],
|
||||
abort: abortController.signal,
|
||||
onClose: clear,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user