Chore: corrects syntax for type only imports (#1716)
* chore: removes replaces 'import type xxx from 'xxx'' with 'import { type xxx} from 'xxx'''
* chore: remove typed imports
* chore: remove typed imports
* chore: cleanup
---------
Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
This commit is contained in:
@ -1,10 +1,10 @@
|
||||
import { v4 } from 'uuid';
|
||||
|
||||
import type {
|
||||
import {
|
||||
Errors,
|
||||
Meta,
|
||||
} from '@/spreadsheet-import/steps/components/ValidationStep/types';
|
||||
import type {
|
||||
import {
|
||||
Data,
|
||||
Fields,
|
||||
Info,
|
||||
|
||||
@ -1,9 +1,6 @@
|
||||
import type XLSX from 'xlsx-ugnis';
|
||||
import { WorkSheet } from 'xlsx-ugnis';
|
||||
|
||||
export const exceedsMaxRecords = (
|
||||
workSheet: XLSX.WorkSheet,
|
||||
maxRecords: number,
|
||||
) => {
|
||||
export const exceedsMaxRecords = (workSheet: WorkSheet, maxRecords: number) => {
|
||||
const [top, bottom] =
|
||||
workSheet['!ref']
|
||||
?.split(':')
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import lavenstein from 'js-levenshtein';
|
||||
|
||||
import type { Fields } from '@/spreadsheet-import/types';
|
||||
import { Fields } from '@/spreadsheet-import/types';
|
||||
|
||||
type AutoMatchAccumulator<T> = {
|
||||
distance: number;
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import type { Columns } from '@/spreadsheet-import/steps/components/MatchColumnsStep/MatchColumnsStep';
|
||||
import type { Fields } from '@/spreadsheet-import/types';
|
||||
import { Columns } from '@/spreadsheet-import/steps/components/MatchColumnsStep/MatchColumnsStep';
|
||||
import { Fields } from '@/spreadsheet-import/types';
|
||||
|
||||
export const findUnmatchedRequiredFields = <T extends string>(
|
||||
fields: Fields<T>,
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import type { Field, Fields } from '@/spreadsheet-import/types';
|
||||
import { Field, Fields } from '@/spreadsheet-import/types';
|
||||
|
||||
const titleMap: Record<Field<string>['fieldType']['type'], string> = {
|
||||
checkbox: 'Boolean',
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import type { Fields } from '@/spreadsheet-import/types';
|
||||
import { Fields } from '@/spreadsheet-import/types';
|
||||
|
||||
export const getFieldOptions = <T extends string>(
|
||||
fields: Fields<T>,
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
import lavenstein from 'js-levenshtein';
|
||||
|
||||
import type {
|
||||
import {
|
||||
Column,
|
||||
Columns,
|
||||
MatchColumnsProps,
|
||||
} from '@/spreadsheet-import/steps/components/MatchColumnsStep/MatchColumnsStep';
|
||||
import type { Field, Fields } from '@/spreadsheet-import/types';
|
||||
import { Field, Fields } from '@/spreadsheet-import/types';
|
||||
|
||||
import { findMatch } from './findMatch';
|
||||
import { setColumn } from './setColumn';
|
||||
|
||||
@ -2,7 +2,7 @@ import {
|
||||
Columns,
|
||||
ColumnType,
|
||||
} from '@/spreadsheet-import/steps/components/MatchColumnsStep/MatchColumnsStep';
|
||||
import type { Data, Fields, RawData } from '@/spreadsheet-import/types';
|
||||
import { Data, Fields, RawData } from '@/spreadsheet-import/types';
|
||||
|
||||
import { normalizeCheckboxValue } from './normalizeCheckboxValue';
|
||||
|
||||
|
||||
@ -3,7 +3,7 @@ import {
|
||||
ColumnType,
|
||||
MatchColumnsProps,
|
||||
} from '@/spreadsheet-import/steps/components/MatchColumnsStep/MatchColumnsStep';
|
||||
import type { Field } from '@/spreadsheet-import/types';
|
||||
import { Field } from '@/spreadsheet-import/types';
|
||||
|
||||
import { uniqueEntries } from './uniqueEntries';
|
||||
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import uniqBy from 'lodash/uniqBy';
|
||||
|
||||
import type {
|
||||
import {
|
||||
MatchColumnsProps,
|
||||
MatchedOptions,
|
||||
} from '@/spreadsheet-import/steps/components/MatchColumnsStep/MatchColumnsStep';
|
||||
|
||||
Reference in New Issue
Block a user