* Change placeholder color and design fixes for show page / sidebar * Replace hardcoded border radiuses * Improve border display for middle of button group * Editor styling * Editor font size * Comment Bar positioning and remove scrollbar for 1px * Add Comments section title * Nit: match css style --------- Co-authored-by: Emilien <emilien.chauvet.enpc@gmail.com>
37 lines
1.3 KiB
TypeScript
37 lines
1.3 KiB
TypeScript
import { useRecoilState } from 'recoil';
|
|
|
|
import { commentableEntityArrayState } from '@/comments/states/commentableEntityArrayState';
|
|
import { useHotkeysScopeOnMountOnly } from '@/hotkeys/hooks/useHotkeysScopeOnMountOnly';
|
|
import { InternalHotkeysScope } from '@/hotkeys/types/internal/InternalHotkeysScope';
|
|
import { RightDrawerBody } from '@/ui/layout/right-drawer/components/RightDrawerBody';
|
|
import { RightDrawerPage } from '@/ui/layout/right-drawer/components/RightDrawerPage';
|
|
import { RightDrawerTopBar } from '@/ui/layout/right-drawer/components/RightDrawerTopBar';
|
|
|
|
import { Timeline } from '../timeline/Timeline';
|
|
|
|
export function RightDrawerTimeline() {
|
|
const [commentableEntityArray] = useRecoilState(commentableEntityArrayState);
|
|
|
|
useHotkeysScopeOnMountOnly({
|
|
scope: InternalHotkeysScope.RightDrawer,
|
|
customScopes: { goto: false, 'command-menu': true },
|
|
});
|
|
|
|
return (
|
|
<RightDrawerPage>
|
|
<RightDrawerTopBar />
|
|
<RightDrawerBody>
|
|
{commentableEntityArray.map((commentableEntity) => (
|
|
<Timeline
|
|
key={commentableEntity.id}
|
|
entity={{
|
|
id: commentableEntity?.id ?? '',
|
|
type: commentableEntity.type,
|
|
}}
|
|
/>
|
|
))}
|
|
</RightDrawerBody>
|
|
</RightDrawerPage>
|
|
);
|
|
}
|