CatsJuice
03104cd8b1
fix(component): ui storybook's doc page can not scroll ( #6909 )
2024-05-20 01:26:37 +00:00
CatsJuice
d412635f6b
feat(component): new hook to open confirm modal ( #6342 )
...
new exports from `@affine/component`:
```ts
import { ConfirmModalProvider, useConfirmModal } from "@affine/component"
```
Open confirm modal with hook:
```ts
const Component = () => {
const { openConfirmModal } = useConformModal();
const open = () => {
openConfirmModal({
// props of ConfirmModal
/**
* will show loading state when confirm clicked, and close after onConfirm finished
*/
onConfirm: async () => {
await new Promise((r) => setTimeout(r, 2000));
},
});
}
return <Button onClick={open}>Open</Button>
}
```
2024-03-27 13:30:30 +00:00
pengx17
3c6983ee49
fix(core): storybook build issue ( #6274 )
...
1. es2022 is required and should be set separately in storybook.
2. @blocksuite/icons versions are not consistent across packages.
2024-03-23 06:33:25 +00:00
LongYinan
332cd3b380
refactor(core): split web entry from core ( #6082 )
...
This pr is trying to split `web` and `electron` entries from `core`. It allows more platform-related optimization to be addressed in each entry.
We should remove all browser/electron only codes from `core` eventually, this is the very first step for that.
2024-03-19 07:48:56 +00:00
Peng Xiao
752c8580ae
fix: remove vite-tsconfig-paths ( #5960 )
...
It will cause storybook from running.
related to https://github.com/aleclarson/vite-tsconfig-paths/issues/132
We are not actually using `vite-tsconfig-paths` now because we rely on package.json's export field to do path mapping.
2024-02-29 07:58:41 +00:00
Cats Juice
45cc75a814
ci(component): deploy ui storybook ( #5655 )
2024-01-22 10:25:33 +00:00
Cats Juice
2db3c933fa
refactor(component): move date-picker to ui, add story, support responsive ( #5468 )
...
- move to `component/ui`
- add `AFFiNEDatePicker` & `BlocksuiteDatePicker` story
- inline mode support
- responsive support
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/toeverything/AFFiNE/assets/39363750/320bef49-380f-40a2-b3b2-4b74dd2d8da4 ">
<img alt="" src="https://github.com/toeverything/AFFiNE/assets/39363750/fc9e7808-02fe-49a1-aa78-aea254fb1f9d ">
</picture>
2024-01-17 09:16:46 +00:00
Cats Juice
d911d21d1c
feat(component): add storybook ( #5079 )
2023-12-04 08:32:19 +00:00