Merge remote-tracking branch 'origin/feat/tauri-kanban' into feat/tauri-kanban

This commit is contained in:
ascarbek 2023-03-21 11:22:53 +06:00
commit 07b183aef2
20 changed files with 30 additions and 35 deletions

View File

@ -9,7 +9,7 @@ import {
NumberFormat, NumberFormat,
SingleSelectTypeOptionPB, SingleSelectTypeOptionPB,
TimeFormat, TimeFormat,
} from '../../../../services/backend'; } from '@/services/backend';
import { import {
makeChecklistTypeOptionContext, makeChecklistTypeOptionContext,
makeDateTypeOptionContext, makeDateTypeOptionContext,

View File

@ -1,5 +1,5 @@
import { nanoid } from 'nanoid'; import { nanoid } from 'nanoid';
import { FieldType } from '../../../../services/backend/models/flowy-database/field_entities'; import { FieldType } from '@/services/backend/models/flowy-database/field_entities';
import { gridActions } from '../../../stores/reducers/grid/slice'; import { gridActions } from '../../../stores/reducers/grid/slice';
import { useAppDispatch, useAppSelector } from '../../../stores/store'; import { useAppDispatch, useAppSelector } from '../../../stores/store';

View File

@ -7,7 +7,7 @@ import { SingleSelectTypeSvg } from '../../_shared/svg/SingleSelectTypeSvg';
import { MultiSelectTypeSvg } from '../../_shared/svg/MultiSelectTypeSvg'; import { MultiSelectTypeSvg } from '../../_shared/svg/MultiSelectTypeSvg';
import { ChecklistTypeSvg } from '../../_shared/svg/ChecklistTypeSvg'; import { ChecklistTypeSvg } from '../../_shared/svg/ChecklistTypeSvg';
import { UrlTypeSvg } from '../../_shared/svg/UrlTypeSvg'; import { UrlTypeSvg } from '../../_shared/svg/UrlTypeSvg';
import { FieldType } from '../../../../services/backend/models/flowy-database/field_entities'; import { FieldType } from '@/services/backend/models/flowy-database/field_entities';
export const GridTableHeader = () => { export const GridTableHeader = () => {
const { fields, onAddField } = useGridTableHeaderHooks(); const { fields, onAddField } = useGridTableHeaderHooks();

View File

@ -2,7 +2,7 @@ import { foldersActions, IFolder } from '../../../stores/reducers/folders/slice'
import { useEffect, useState } from 'react'; import { useEffect, useState } from 'react';
import { useAppDispatch, useAppSelector } from '../../../stores/store'; import { useAppDispatch, useAppSelector } from '../../../stores/store';
import { IPage, pagesActions } from '../../../stores/reducers/pages/slice'; import { IPage, pagesActions } from '../../../stores/reducers/pages/slice';
import { AppPB, ViewLayoutTypePB } from '../../../../services/backend'; import { AppPB, ViewLayoutTypePB } from '@/services/backend';
import { AppBackendService } from '../../../stores/effects/folder/app/app_bd_svc'; import { AppBackendService } from '../../../stores/effects/folder/app/app_bd_svc';
import { WorkspaceBackendService } from '../../../stores/effects/folder/workspace/workspace_bd_svc'; import { WorkspaceBackendService } from '../../../stores/effects/folder/workspace/workspace_bd_svc';
import { useError } from '../../error/Error.hooks'; import { useError } from '../../error/Error.hooks';

View File

@ -1,7 +1,7 @@
import { useAppSelector } from '../../../stores/store'; import { useAppSelector } from '../../../stores/store';
import { useNavigate } from 'react-router-dom'; import { useNavigate } from 'react-router-dom';
import { IPage } from '../../../stores/reducers/pages/slice'; import { IPage } from '../../../stores/reducers/pages/slice';
import { ViewLayoutTypePB } from '../../../../services/backend'; import { ViewLayoutTypePB } from '@/services/backend';
import { useState } from 'react'; import { useState } from 'react';
export const useNavigationPanelHooks = function () { export const useNavigationPanelHooks = function () {

View File

@ -7,7 +7,7 @@ import { IPage } from '../../../stores/reducers/pages/slice';
import { Button } from '../../_shared/Button'; import { Button } from '../../_shared/Button';
import { usePageEvents } from './PageItem.hooks'; import { usePageEvents } from './PageItem.hooks';
import { RenamePopup } from './RenamePopup'; import { RenamePopup } from './RenamePopup';
import { ViewLayoutTypePB } from '../../../../services/backend'; import { ViewLayoutTypePB } from '@/services/backend';
import { useEffect, useRef, useState } from 'react'; import { useEffect, useRef, useState } from 'react';
import { PAGE_ITEM_HEIGHT } from '../../_shared/constants'; import { PAGE_ITEM_HEIGHT } from '../../_shared/constants';

View File

@ -1,5 +1,5 @@
import { FlowyError, UserNotification } from '../../../../../services/backend'; import { FlowyError, UserNotification } from '@/services/backend';
import { NotificationParser, OnNotificationError } from '../../../../../services/backend/notifications'; import { NotificationParser, OnNotificationError } from '@/services/backend/notifications';
import { Result } from 'ts-results'; import { Result } from 'ts-results';
declare type UserNotificationCallback = (ty: UserNotification, payload: Result<Uint8Array, FlowyError>) => void; declare type UserNotificationCallback = (ty: UserNotification, payload: Result<Uint8Array, FlowyError>) => void;

View File

@ -1,5 +1,5 @@
import { FlowyError, UserNotification, UserProfilePB } from '../../../../../services/backend'; import { FlowyError, UserNotification, UserProfilePB } from '@/services/backend';
import { AFNotificationObserver, OnNotificationError } from '../../../../../services/backend/notifications'; import { AFNotificationObserver, OnNotificationError } from '@/services/backend/notifications';
import { UserNotificationParser } from './parser'; import { UserNotificationParser } from './parser';
import { Ok, Result } from 'ts-results'; import { Ok, Result } from 'ts-results';

View File

@ -1,6 +1,5 @@
import { DatabaseEventGetCell, DatabaseEventUpdateCell } from '../../../../../services/backend/events/flowy-database'; import { DatabaseEventGetCell, DatabaseEventUpdateCell } from '@/services/backend/events/flowy-database';
import { CellChangesetPB, CellIdPB } from '../../../../../services/backend/models/flowy-database/cell_entities'; import { CellChangesetPB, CellIdPB, FieldType } from '@/services/backend';
import { FieldType } from '../../../../../services/backend/models/flowy-database/field_entities';
class CellIdentifier { class CellIdentifier {
constructor( constructor(

View File

@ -1,7 +1,7 @@
import { Ok, Result } from 'ts-results'; import { Ok, Result } from 'ts-results';
import { ChangeNotifier } from '../../../../utils/change_notifier'; import { ChangeNotifier } from '$app/utils/change_notifier';
import { DatabaseNotificationObserver } from '../notifications/observer'; import { DatabaseNotificationObserver } from '../notifications/observer';
import { DatabaseNotification, FlowyError } from '../../../../../services/backend'; import { DatabaseNotification, FlowyError } from '@/services/backend';
type UpdateCellNotifiedValue = Result<void, FlowyError>; type UpdateCellNotifiedValue = Result<void, FlowyError>;

View File

@ -1,4 +1,4 @@
import { DateCellDataPB, FieldType, SelectOptionCellDataPB, URLCellDataPB } from '../../../../../services/backend'; import { DateCellDataPB, FieldType, SelectOptionCellDataPB, URLCellDataPB } from '@/services/backend';
import { CellIdentifier } from './cell_bd_svc'; import { CellIdentifier } from './cell_bd_svc';
import { CellController } from './cell_controller'; import { CellController } from './cell_controller';
import { import {

View File

@ -1,10 +1,8 @@
import utf8 from 'utf8'; import utf8 from 'utf8';
import { CellBackendService, CellIdentifier } from './cell_bd_svc'; import { CellBackendService, CellIdentifier } from './cell_bd_svc';
import { DateCellDataPB } from '../../../../../services/backend/models/flowy-database/date_type_option_entities'; import { SelectOptionCellDataPB, URLCellDataPB, DateCellDataPB } from '@/services/backend';
import { SelectOptionCellDataPB } from '../../../../../services/backend/models/flowy-database/select_type_option';
import { URLCellDataPB } from '../../../../../services/backend/models/flowy-database/url_type_option_entities';
import { Err, None, Ok, Option, Some } from 'ts-results'; import { Err, None, Ok, Option, Some } from 'ts-results';
import { Log } from '../../../../utils/log'; import { Log } from '$app/utils/log';
abstract class CellDataParser<T> { abstract class CellDataParser<T> {
abstract parserData(data: Uint8Array): Option<T>; abstract parserData(data: Uint8Array): Option<T>;

View File

@ -1,10 +1,8 @@
import { Result } from 'ts-results'; import { Result } from 'ts-results';
import { FlowyError } from '../../../../../services/backend/models/flowy-error';
import { CellBackendService, CellIdentifier } from './cell_bd_svc'; import { CellBackendService, CellIdentifier } from './cell_bd_svc';
import { CalendarData } from './controller_builder'; import { CalendarData } from './controller_builder';
import { DateChangesetPB } from '../../../../../services/backend/models/flowy-database/date_type_option_entities'; import { DateChangesetPB, FlowyError, CellIdPB } from '@/services/backend';
import { CellIdPB } from '../../../../../services/backend/models/flowy-database/cell_entities'; import { DatabaseEventUpdateDateCell } from '@/services/backend/events/flowy-database';
import { DatabaseEventUpdateDateCell } from '../../../../../services/backend/events/flowy-database';
export abstract class CellDataPersistence<D> { export abstract class CellDataPersistence<D> {
abstract save(data: D): Promise<Result<void, FlowyError>>; abstract save(data: D): Promise<Result<void, FlowyError>>;

View File

@ -5,13 +5,13 @@ import {
SelectOptionCellChangesetPB, SelectOptionCellChangesetPB,
SelectOptionChangesetPB, SelectOptionChangesetPB,
SelectOptionPB, SelectOptionPB,
} from '../../../../../services/backend'; } from '@/services/backend';
import { import {
DatabaseEventCreateSelectOption, DatabaseEventCreateSelectOption,
DatabaseEventGetSelectOptionCellData, DatabaseEventGetSelectOptionCellData,
DatabaseEventUpdateSelectOption, DatabaseEventUpdateSelectOption,
DatabaseEventUpdateSelectOptionCell, DatabaseEventUpdateSelectOptionCell,
} from '../../../../../services/backend/events/flowy-database'; } from '@/services/backend/events/flowy-database';
export class SelectOptionBackendService { export class SelectOptionBackendService {
constructor(public readonly viewId: string, public readonly fieldId: string) {} constructor(public readonly viewId: string, public readonly fieldId: string) {}

View File

@ -6,8 +6,8 @@ import {
ReorderSingleRowPB, ReorderSingleRowPB,
RowsChangesetPB, RowsChangesetPB,
RowsVisibilityChangesetPB, RowsVisibilityChangesetPB,
} from '../../../../../services/backend'; } from '@/services/backend';
import { ChangeNotifier } from '../../../../utils/change_notifier'; import { ChangeNotifier } from '$app/utils/change_notifier';
import { DatabaseNotificationObserver } from '../notifications/observer'; import { DatabaseNotificationObserver } from '../notifications/observer';
export type RowsVisibilityNotifyValue = Result<RowsVisibilityChangesetPB, FlowyError>; export type RowsVisibilityNotifyValue = Result<RowsVisibilityChangesetPB, FlowyError>;

View File

@ -1,6 +1,6 @@
import { createSlice, PayloadAction } from '@reduxjs/toolkit'; import { createSlice, PayloadAction } from '@reduxjs/toolkit';
import { nanoid } from 'nanoid'; import { nanoid } from 'nanoid';
import { WorkspaceSettingPB } from '../../../../services/backend/models/flowy-folder/workspace'; import { WorkspaceSettingPB } from '@/services/backend/models/flowy-folder/workspace';
export interface ICurrentUser { export interface ICurrentUser {
id?: string; id?: string;

View File

@ -1,6 +1,6 @@
import { createSlice, PayloadAction } from '@reduxjs/toolkit'; import { createSlice, PayloadAction } from '@reduxjs/toolkit';
import { FieldType } from '../../../../services/backend/models/flowy-database/field_entities'; import { FieldType } from '@/services/backend/models/flowy-database/field_entities';
import { DateFormat, NumberFormat, SelectOptionColorPB, TimeFormat } from '../../../../services/backend'; import { DateFormat, NumberFormat, SelectOptionColorPB, TimeFormat } from '@/services/backend';
export interface ISelectOption { export interface ISelectOption {
selectOptionId: string; selectOptionId: string;

View File

@ -1,5 +1,5 @@
import { FlowyError, FolderNotification } from '../../../../../services/backend'; import { FlowyError, FolderNotification } from '@/services/backend';
import { NotificationParser, OnNotificationError } from '../../../../../services/backend/notifications'; import { NotificationParser, OnNotificationError } from '@/services/backend/notifications';
import { Result } from 'ts-results'; import { Result } from 'ts-results';
declare type FolderNotificationCallback = (ty: FolderNotification, payload: Result<Uint8Array, FlowyError>) => void; declare type FolderNotificationCallback = (ty: FolderNotification, payload: Result<Uint8Array, FlowyError>) => void;

View File

@ -1,6 +1,6 @@
import { createSlice, PayloadAction } from '@reduxjs/toolkit'; import { createSlice, PayloadAction } from '@reduxjs/toolkit';
import { nanoid } from 'nanoid'; import { nanoid } from 'nanoid';
import { FieldType } from '../../../../services/backend/models/flowy-database/field_entities'; import { FieldType } from '@/services/backend/models/flowy-database/field_entities';
const initialState = { const initialState = {
title: 'My plans on the week', title: 'My plans on the week',

View File

@ -1,5 +1,5 @@
import { createSlice, PayloadAction } from '@reduxjs/toolkit'; import { createSlice, PayloadAction } from '@reduxjs/toolkit';
import { ViewLayoutTypePB } from '../../../../services/backend'; import { ViewLayoutTypePB } from '@/services/backend';
export interface IPage { export interface IPage {
id: string; id: string;