Browse Source

fix: ref type and removed unwanted logic

pull/6463/head
sreehari jayaraj 1 year ago
parent
commit
6d2e413150
  1. 2
      packages/nc-gui/components/dlg/share-and-collaborate/View.vue
  2. 5
      packages/nc-gui/components/workspace/InviteSection.vue

2
packages/nc-gui/components/dlg/share-and-collaborate/View.vue

@ -15,7 +15,7 @@ const { project } = storeToRefs(projectStore)
const { navigateToProjectPage } = projectStore
const { activeView } = storeToRefs(useViewsStore())
let view: globalThis.Ref<ViewType | undefined>
let view: Ref<ViewType | undefined>
if (isViewToolbar) {
try {
const store = useSmartsheetStoreOrThrow()

5
packages/nc-gui/components/workspace/InviteSection.vue

@ -132,12 +132,15 @@ onKeyStroke('Backspace', () => {
// when bulk email is pasted
const onPaste = (e: ClipboardEvent) => {
const pastedText = e.clipboardData?.getData('text')
const inputArray = pastedText?.split(',') || pastedText?.split(' ') || pastedText?.split('')
const inputArray = pastedText?.split(',') || pastedText?.split(' ')
// if data is pasted to a already existing text in input
// we add existingInput + pasted data
if (inputArray?.length === 1 && inviteData.email.length) {
inputArray[0] = inviteData.email += inputArray[0]
}
inputArray?.forEach((el) => {
const isEmailIsValid = emailInputValidation(el)

Loading…
Cancel
Save