-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3630 from omnivore-app/fix/web-keyboard-shortcut-…
…fixes Open links in new tab
- Loading branch information
Showing
2 changed files
with
121 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
import { isAndroid } from '../../lib/deviceType' | ||
import { styled, theme } from '../tokens/stitches.config' | ||
import { Button } from '../elements/Button' | ||
import { HStack, Box } from '../elements/LayoutPrimitives' | ||
import { Circle, CheckCircle } from 'phosphor-react' | ||
import { LabelIcon } from '../elements/icons/LabelIcon' | ||
import { NotebookIcon } from '../elements/icons/NotebookIcon' | ||
import { highlightColor, highlightColors } from '../../lib/themeUpdater' | ||
import { useState } from 'react' | ||
import { CopyIcon } from '../elements/icons/CopyIcon' | ||
|
||
type PageCoordinates = { | ||
pageX: number | ||
pageY: number | ||
} | ||
|
||
type LinkHoverBarProps = { | ||
anchorCoordinates: PageCoordinates | ||
handleButtonClick: () => void | ||
} | ||
|
||
export function LinkHoverBar(props: LinkHoverBarProps): JSX.Element { | ||
console.log('settingh link hover, ', props) | ||
return ( | ||
<Box | ||
css={{ | ||
// width: '295px', | ||
// height: '50px', | ||
position: 'absolute', | ||
background: '$thBackground2', | ||
borderRadius: '5px', | ||
border: '1px solid $thHighlightBar', | ||
boxShadow: `0px 4px 4px 0px rgba(0, 0, 0, 0.15)`, | ||
padding: '10px', | ||
|
||
// ...(props.displayAtBottom && { | ||
// bottom: 'calc(38px + env(safe-area-inset-bottom, 40px))', | ||
// }), | ||
// ...(props.displayAtBottom && { | ||
// '@smDown': { | ||
// maxWidth: '90vw', | ||
// bottom: `calc(28px + ${ | ||
// isAndroid() ? 30 : 0 | ||
// }px + env(safe-area-inset-bottom, 40px))`, | ||
// }, | ||
// }), | ||
left: props.anchorCoordinates.pageX, | ||
top: props.anchorCoordinates.pageY, | ||
}} | ||
> | ||
<Box>Save to Omnivore</Box> | ||
</Box> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters