mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Merge pull request #3191 from omnivore-app/hide-auto-add-to-library
hide auto add to library button on web because we are only releasing following features on iOS for now
This commit is contained in:
commit
f09f60d0bf
1 changed files with 26 additions and 52 deletions
|
|
@ -1,7 +1,6 @@
|
|||
import { useRouter } from 'next/router'
|
||||
import { FloppyDisk, Pencil, XCircle } from 'phosphor-react'
|
||||
import { useMemo, useState } from 'react'
|
||||
import CheckboxComponent from '../../../components/elements/Checkbox'
|
||||
import { FormInput } from '../../../components/elements/FormElements'
|
||||
import { HStack, SpanBox } from '../../../components/elements/LayoutPrimitives'
|
||||
import { ConfirmationModal } from '../../../components/patterns/ConfirmationModal'
|
||||
|
|
@ -199,14 +198,7 @@ export default function Rss(): JSX.Element {
|
|||
console.log('onDelete triggered: ', subscription.id)
|
||||
setOnDeleteId(subscription.id)
|
||||
}}
|
||||
// onEdit={() => {
|
||||
// setOnEditStatus(
|
||||
// subscription.status == 'ACTIVE' ? 'UNSUBSCRIBED' : 'ACTIVE'
|
||||
// )
|
||||
// setOnPauseId(subscription.id)
|
||||
// }}
|
||||
deleteTitle="Unsubscribe"
|
||||
// editTitle={subscription.status === 'ACTIVE' ? 'Pause' : 'Resume'}
|
||||
sublineElement={
|
||||
<SpanBox
|
||||
css={{
|
||||
|
|
@ -222,54 +214,36 @@ export default function Rss(): JSX.Element {
|
|||
}`}
|
||||
</SpanBox>
|
||||
}
|
||||
// onClick={() => {
|
||||
// router.push(`/home?q=in:inbox rss:"${subscription.url}"`)
|
||||
// }}
|
||||
extraElement={
|
||||
<HStack
|
||||
distribution="start"
|
||||
alignment="center"
|
||||
css={{
|
||||
padding: '0 5px',
|
||||
}}
|
||||
>
|
||||
<CheckboxComponent
|
||||
checked={!!subscription.autoAddToLibrary}
|
||||
setChecked={async (checked) => {
|
||||
await updateSubscriptionMutation({
|
||||
id: subscription.id,
|
||||
autoAddToLibrary: checked,
|
||||
})
|
||||
revalidate()
|
||||
}}
|
||||
/>
|
||||
<SpanBox
|
||||
css={{
|
||||
padding: '0 5px',
|
||||
fontSize: '12px',
|
||||
}}
|
||||
>
|
||||
Auto add to library
|
||||
</SpanBox>
|
||||
</HStack>
|
||||
|
||||
// onChange={() => {
|
||||
// setOnEditStatus(
|
||||
// subscription.status == 'ACTIVE'
|
||||
// ? 'UNSUBSCRIBED'
|
||||
// : 'ACTIVE'
|
||||
// )
|
||||
// setOnPauseId(subscription.id)
|
||||
// }}
|
||||
}
|
||||
onClick={() => {
|
||||
router.push(`/home?q=in:inbox rss:"${subscription.url}"`)
|
||||
}}
|
||||
// extraElement={
|
||||
// <SpanBox
|
||||
// <HStack
|
||||
// distribution="start"
|
||||
// alignment="center"
|
||||
// css={{
|
||||
// fontSize: '12px',
|
||||
// padding: '0 5px',
|
||||
// }}
|
||||
// >
|
||||
// {subscription.status === 'ACTIVE' ? 'Active' : 'Paused'}
|
||||
// </SpanBox>
|
||||
// <CheckboxComponent
|
||||
// checked={!!subscription.autoAddToLibrary}
|
||||
// setChecked={async (checked) => {
|
||||
// await updateSubscriptionMutation({
|
||||
// id: subscription.id,
|
||||
// autoAddToLibrary: checked,
|
||||
// })
|
||||
// revalidate()
|
||||
// }}
|
||||
// />
|
||||
// <SpanBox
|
||||
// css={{
|
||||
// padding: '0 5px',
|
||||
// fontSize: '12px',
|
||||
// }}
|
||||
// >
|
||||
// Auto add to library
|
||||
// </SpanBox>
|
||||
// </HStack>
|
||||
// }
|
||||
/>
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue