diff --git a/packages/web/components/elements/ModalPrimitives.tsx b/packages/web/components/elements/ModalPrimitives.tsx
index 2790897e9..a9c0975c3 100644
--- a/packages/web/components/elements/ModalPrimitives.tsx
+++ b/packages/web/components/elements/ModalPrimitives.tsx
@@ -29,7 +29,7 @@ const Modal = styled(Content, {
boxShadow: theme.shadows.cardBoxShadow.toString(),
position: 'fixed',
'&:focus': { outline: 'none' },
- zIndex:'1',
+ zIndex: '1',
})
export const ModalContent = styled(Modal, {
@@ -43,6 +43,7 @@ export const ModalContent = styled(Modal, {
maxWidth: '95%',
width: '95%',
},
+ zIndex: '10',
})
export type ModalTitleBarProps = {
@@ -57,9 +58,7 @@ export const ModalTitleBar = (props: ModalTitleBarProps) => {
alignment="center"
css={{ height: '68px', width: '100%' }}
>
-
- {props.title}
-
+ {props.title}
)
@@ -98,7 +94,10 @@ export const ModalButtonBar = (props: ModalButtonBarProps) => {
},
}}
>
-
- props.articleActionHandler('showHighlights')}>
- props.articleActionHandler('showHighlights')}
>
-
-
-
+
+
+
+
-
+
- {
- props.articleActionHandler('delete')
- }}
- >
- {
+ props.articleActionHandler('delete')
+ }}
>
-
-
-
+
+
+
+
- {!props.article?.isArchived ? (
+ {!props.article?.isArchived ? (
props.articleActionHandler('archive')}
@@ -184,27 +234,26 @@ export function ArticleActionsMenu(props: ArticleActionsMenuProps): JSX.Element
tooltipContent="Unarchive"
tooltipSide={props.layout == 'side' ? 'right' : 'bottom'}
>
-
+
)}
- {/*
+ {/*
*/}
-
- {readerSettings.showEditDisplaySettingsModal && (
- readerSettings.setShowEditDisplaySettingsModal(false)}
- />
- )}
+
+ {readerSettings.showEditDisplaySettingsModal && (
+
+ readerSettings.setShowEditDisplaySettingsModal(false)
+ }
+ />
+ )}
>
)
}
diff --git a/packages/web/components/templates/article/HighlightsModal.tsx b/packages/web/components/templates/article/HighlightsModal.tsx
index 8e5fa0607..8336472c4 100644
--- a/packages/web/components/templates/article/HighlightsModal.tsx
+++ b/packages/web/components/templates/article/HighlightsModal.tsx
@@ -42,7 +42,7 @@ export function HighlightsModal(props: HighlightsModalProps): JSX.Element {
event.preventDefault()
props.onOpenChange(false)
}}
- css={{ overflow: 'auto', px: '24px', zIndex: '10' }}
+ css={{ overflow: 'auto', px: '24px' }}
>
diff --git a/packages/web/components/templates/article/SetLabelsControl.tsx b/packages/web/components/templates/article/SetLabelsControl.tsx
index 2afb1e06e..cb364a65a 100644
--- a/packages/web/components/templates/article/SetLabelsControl.tsx
+++ b/packages/web/components/templates/article/SetLabelsControl.tsx
@@ -9,18 +9,19 @@ import { Label } from '../../../lib/networking/fragments/labelFragment'
import { useGetLabelsQuery } from '../../../lib/networking/queries/useGetLabelsQuery'
import { Check, Circle, PencilSimple, Plus } from 'phosphor-react'
import { isTouchScreenDevice } from '../../../lib/deviceType'
-import { setLabelsMutation } from '../../../lib/networking/mutations/setLabelsMutation'
import { createLabelMutation } from '../../../lib/networking/mutations/createLabelMutation'
import { showErrorToast, showSuccessToast } from '../../../lib/toastHelpers'
import { randomLabelColorHex } from '../../../utils/settings-page/labels/labelColorObjects'
import { useRouter } from 'next/router'
-import { ArticleAttributes } from '../../../lib/networking/queries/useGetArticleQuery'
+
+export interface LabelsProvider {
+ labels?: Label[]
+}
type SetLabelsControlProps = {
- linkId: string
- labels: Label[] | undefined
- article?: ArticleAttributes
- articleActionHandler: (action: string, arg?: unknown) => void
+ provider?: LabelsProvider
+ onSave: (labels: Label[] | undefined) => void
+ save: (labels: Label[]) => Promise