Browse Source

fix: tab navigation and focus outline issue

pull/7298/head
Ramesh Mane 11 months ago
parent
commit
e8424afcdc
  1. 2
      packages/nc-gui/components/cell/Checkbox.vue
  2. 12
      packages/nc-gui/components/cell/GeoData.vue
  3. 3
      packages/nc-gui/components/cell/RichText.vue
  4. 2
      packages/nc-gui/components/smartsheet/column/DefaultValue.vue

2
packages/nc-gui/components/cell/Checkbox.vue

@ -84,7 +84,7 @@ useSelectedCellKeyupListener(active, (e) => {
<template> <template>
<div <div
class="flex cursor-pointer w-full h-full items-center focus:outline-transparent" class="flex cursor-pointer w-full h-full items-center focus:outline-none"
:class="{ :class="{
'w-full flex-start pl-2': isForm || isGallery || isExpandedFormOpen, 'w-full flex-start pl-2': isForm || isGallery || isExpandedFormOpen,
'w-full justify-center': !isForm && !isGallery && !isExpandedFormOpen, 'w-full justify-center': !isForm && !isGallery && !isExpandedFormOpen,

12
packages/nc-gui/components/cell/GeoData.vue

@ -86,7 +86,8 @@ const openInOSM = () => {
<a-dropdown :is="isExpanded ? AModal : 'div'" v-model:visible="isExpanded" :trigger="['click']"> <a-dropdown :is="isExpanded ? AModal : 'div'" v-model:visible="isExpanded" :trigger="['click']">
<div <div
v-if="!isLocationSet" v-if="!isLocationSet"
class="group cursor-pointer flex gap-1 items-center mx-auto max-w-64 justify-center active:(ring ring-accent ring-opacity-100) rounded border-1 p-1 shadow-sm hover:(bg-primary bg-opacity-10) dark:(!bg-slate-500)" class="group cursor-pointer flex gap-1 items-center mx-auto max-w-64 justify-center active:(ring ring-accent ring-opacity-100) rounded border-1 p-1 shadow-sm hover:(bg-primary bg-opacity-10) dark:(!bg-slate-500) my-1"
tabindex="0"
> >
<div class="flex items-center gap-2" data-testid="nc-geo-data-set-location-button"> <div class="flex items-center gap-2" data-testid="nc-geo-data-set-location-button">
<component <component
@ -98,7 +99,14 @@ const openInOSM = () => {
</div> </div>
</div> </div>
</div> </div>
<div v-else data-testid="nc-geo-data-lat-long-set">{{ latLongStr }}</div> <div
v-else
data-testid="nc-geo-data-lat-long-set"
tabindex="0"
class="focus-visible:!outline-none h-full w-full flex items-center"
>
{{ latLongStr }}
</div>
<template #overlay> <template #overlay>
<a-form :model="formState" class="flex flex-col w-max-64 border-1 border-gray-200" @finish="handleFinish"> <a-form :model="formState" class="flex flex-col w-max-64 border-1 border-gray-200" @finish="handleFinish">
<a-form-item> <a-form-item>

3
packages/nc-gui/components/cell/RichText.vue

@ -156,11 +156,12 @@ watch(editorDom, () => {
<template> <template>
<div <div
class="h-full" class="h-full focus-visible:!outline-none"
:class="{ :class="{
'flex flex-col flex-grow nc-rich-text-full': props.fullMode, 'flex flex-col flex-grow nc-rich-text-full': props.fullMode,
'nc-rich-text-embed flex flex-col pl-1 w-full': !props.fullMode, 'nc-rich-text-embed flex flex-col pl-1 w-full': !props.fullMode,
}" }"
tabindex="0"
> >
<div v-if="props.showMenu" class="absolute top-0 right-0.5"> <div v-if="props.showMenu" class="absolute top-0 right-0.5">
<CellRichTextSelectedBubbleMenu v-if="editor" :editor="editor" embed-mode /> <CellRichTextSelectedBubbleMenu v-if="editor" :editor="editor" embed-mode />

2
packages/nc-gui/components/smartsheet/column/DefaultValue.vue

@ -47,7 +47,7 @@ watch(
<div class="!my-3 text-xs">{{ $t('placeholder.defaultValue') }}</div> <div class="!my-3 text-xs">{{ $t('placeholder.defaultValue') }}</div>
<div class="flex flex-row gap-2"> <div class="flex flex-row gap-2">
<div <div
class="border-1 flex items-center w-full px-3 my-[-4px] border-gray-300 rounded-md" class="border-1 flex items-center w-full px-3 my-[-4px] border-gray-300 rounded-md sm:min-h-[32px] flex items-center focus-within:(border-brand-500 shadow-none ring-0)"
:class="{ :class="{
'!border-brand-500': editEnabled, '!border-brand-500': editEnabled,
}" }"

Loading…
Cancel
Save