TSK-1089: Proper Recruit Archive (#2952)

Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
Andrey Sobolev
2023-04-12 09:26:53 +07:00
committed by GitHub
parent 751a65f37e
commit ac0eac5eff
4 changed files with 35 additions and 11 deletions
@@ -13,7 +13,7 @@
// limitations under the License.
-->
<script lang="ts">
import { navigate, parseLocation } from '@hcengineering/ui'
import { closePopup, closeTooltip, navigate, parseLocation } from '@hcengineering/ui'
export let href: string | undefined
export let disableClick = false
@@ -24,12 +24,17 @@
function clickHandler (e: MouseEvent) {
if (disableClick) return
if (onClick) {
e.preventDefault()
e.stopPropagation()
onClick(e)
} else if (href !== undefined) {
if (e.metaKey || e.ctrlKey) return
// we need to close popups and tooltips
closePopup()
closeTooltip()
try {
const url = new URL(href)