mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-08-23 21:06:22 +08:00
refactor(core): favorite adapter (#6285)
1. abstraction over favourites that supports different type of resources 2. sorting abstraction
This commit is contained in:
@@ -43,11 +43,12 @@ export const AffineOperationCell: StoryFn<PageOperationCellProps> = ({
|
||||
}) => <PageOperationCell {...props} />;
|
||||
|
||||
AffineOperationCell.args = {
|
||||
favorite: false,
|
||||
isPublic: true,
|
||||
onToggleFavoritePage: () => toast('Toggle favorite page'),
|
||||
onDisablePublicSharing: () => toast('Disable public sharing'),
|
||||
onRemoveToTrash: () => toast('Remove to trash'),
|
||||
page: {
|
||||
id: '123',
|
||||
title: 'Test Page Title',
|
||||
tags: ['tag1', 'tag2'],
|
||||
createDate: new Date('2021-01-01').getTime(),
|
||||
},
|
||||
};
|
||||
AffineOperationCell.parameters = {
|
||||
reactRouter: reactRouterParameters({
|
||||
|
||||
Reference in New Issue
Block a user