fix: pass application to options component in overflow menu
This commit is contained in:
@@ -3,19 +3,21 @@ import { toDirective } from './utils';
|
|||||||
import NotesIcon from '../../icons/il-notes.svg';
|
import NotesIcon from '../../icons/il-notes.svg';
|
||||||
import { observer } from 'mobx-react-lite';
|
import { observer } from 'mobx-react-lite';
|
||||||
import { NotesOptionsPanel } from './NotesOptionsPanel';
|
import { NotesOptionsPanel } from './NotesOptionsPanel';
|
||||||
|
import { WebApplication } from '@/ui_models/application';
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
|
application: WebApplication;
|
||||||
appState: AppState;
|
appState: AppState;
|
||||||
};
|
};
|
||||||
|
|
||||||
const MultipleSelectedNotes = observer(({ appState }: Props) => {
|
const MultipleSelectedNotes = observer(({ application, appState }: Props) => {
|
||||||
const count = appState.notes.selectedNotesCount;
|
const count = appState.notes.selectedNotesCount;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="flex flex-col h-full items-center">
|
<div className="flex flex-col h-full items-center">
|
||||||
<div className="flex items-center justify-between p-4 w-full">
|
<div className="flex items-center justify-between p-4 w-full">
|
||||||
<h1 className="sk-h1 font-bold m-0">{count} selected notes</h1>
|
<h1 className="sk-h1 font-bold m-0">{count} selected notes</h1>
|
||||||
<NotesOptionsPanel appState={appState} />
|
<NotesOptionsPanel application={application} appState={appState} />
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-grow flex flex-col justify-center items-center w-full max-w-md">
|
<div className="flex-grow flex flex-col justify-center items-center w-full max-w-md">
|
||||||
<NotesIcon className="block" />
|
<NotesIcon className="block" />
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
.h-full
|
.h-full
|
||||||
multiple-selected-notes-panel.h-full(
|
multiple-selected-notes-panel.h-full(
|
||||||
|
application='self.application'
|
||||||
app-state='self.appState'
|
app-state='self.appState'
|
||||||
ng-if='self.state.showMultipleSelectedNotes'
|
ng-if='self.state.showMultipleSelectedNotes'
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user