Ver código fonte

chore: ignore proto files

appflowy 2 anos atrás
pai
commit
5345c668bb
26 arquivos alterados com 1 adições e 381 exclusões
  1. 1 0
      frontend/rust-lib/.gitignore
  2. 0 9
      frontend/rust-lib/dart-notify/resources/proto/subject.proto
  3. 0 6
      frontend/rust-lib/flowy-error/resources/proto/errors.proto
  4. 0 18
      frontend/rust-lib/flowy-folder/resources/proto/dart_notification.proto
  5. 0 29
      frontend/rust-lib/flowy-folder/resources/proto/event_map.proto
  6. 0 12
      frontend/rust-lib/flowy-grid/resources/proto/cell_entities.proto
  7. 0 5
      frontend/rust-lib/flowy-grid/resources/proto/checkbox_type_option.proto
  8. 0 11
      frontend/rust-lib/flowy-grid/resources/proto/dart_notification.proto
  9. 0 28
      frontend/rust-lib/flowy-grid/resources/proto/date_type_option.proto
  10. 0 27
      frontend/rust-lib/flowy-grid/resources/proto/event_map.proto
  11. 0 6
      frontend/rust-lib/flowy-grid/resources/proto/field_entities.proto
  12. 0 40
      frontend/rust-lib/flowy-grid/resources/proto/format.proto
  13. 0 10
      frontend/rust-lib/flowy-grid/resources/proto/number_type_option.proto
  14. 0 6
      frontend/rust-lib/flowy-grid/resources/proto/row_entities.proto
  15. 0 43
      frontend/rust-lib/flowy-grid/resources/proto/selection_type_option.proto
  16. 0 5
      frontend/rust-lib/flowy-grid/resources/proto/text_type_option.proto
  17. 0 9
      frontend/rust-lib/flowy-grid/resources/proto/url_type_option.proto
  18. 0 5
      frontend/rust-lib/flowy-net/resources/proto/event_map.proto
  19. 0 11
      frontend/rust-lib/flowy-net/resources/proto/network_state.proto
  20. 0 15
      frontend/rust-lib/flowy-text-block/resources/proto/entities.proto
  21. 0 7
      frontend/rust-lib/flowy-text-block/resources/proto/event_map.proto
  22. 0 9
      frontend/rust-lib/flowy-user/resources/proto/dart_notification.proto
  23. 0 13
      frontend/rust-lib/flowy-user/resources/proto/event_map.proto
  24. 0 4
      shared-lib/flowy-error-code/.proto/mod.rs
  25. 0 5
      shared-lib/flowy-error-code/.proto/model/mod.rs
  26. 0 48
      shared-lib/flowy-error-code/.proto/proto/code.proto

+ 1 - 0
frontend/rust-lib/.gitignore

@@ -11,4 +11,5 @@
 **/**/temp
 bin/
 **/src/protobuf
+**/resources/proto
 .idea/

+ 0 - 9
frontend/rust-lib/dart-notify/resources/proto/subject.proto

@@ -1,9 +0,0 @@
-syntax = "proto3";
-
-message SubscribeObject {
-    string source = 1;
-    int32 ty = 2;
-    string id = 3;
-    oneof one_of_payload { bytes payload = 4; };
-    oneof one_of_error { bytes error = 5; };
-}

+ 0 - 6
frontend/rust-lib/flowy-error/resources/proto/errors.proto

@@ -1,6 +0,0 @@
-syntax = "proto3";
-
-message FlowyError {
-    int32 code = 1;
-    string msg = 2;
-}

+ 0 - 18
frontend/rust-lib/flowy-folder/resources/proto/dart_notification.proto

@@ -1,18 +0,0 @@
-syntax = "proto3";
-
-enum FolderNotification {
-    Unknown = 0;
-    UserCreateWorkspace = 10;
-    UserDeleteWorkspace = 11;
-    WorkspaceUpdated = 12;
-    WorkspaceListUpdated = 13;
-    WorkspaceAppsChanged = 14;
-    WorkspaceSetting = 15;
-    AppUpdated = 21;
-    AppViewsChanged = 24;
-    ViewUpdated = 31;
-    ViewDeleted = 32;
-    ViewRestored = 33;
-    UserUnauthorized = 100;
-    TrashUpdated = 1000;
-}

+ 0 - 29
frontend/rust-lib/flowy-folder/resources/proto/event_map.proto

@@ -1,29 +0,0 @@
-syntax = "proto3";
-
-enum FolderEvent {
-    CreateWorkspace = 0;
-    ReadCurWorkspace = 1;
-    ReadWorkspaces = 2;
-    DeleteWorkspace = 3;
-    OpenWorkspace = 4;
-    ReadWorkspaceApps = 5;
-    CreateApp = 101;
-    DeleteApp = 102;
-    ReadApp = 103;
-    UpdateApp = 104;
-    CreateView = 201;
-    ReadView = 202;
-    UpdateView = 203;
-    DeleteView = 204;
-    DuplicateView = 205;
-    CloseView = 206;
-    ReadViewInfo = 207;
-    CopyLink = 220;
-    SetLatestView = 221;
-    MoveFolderItem = 230;
-    ReadTrash = 300;
-    PutbackTrash = 301;
-    DeleteTrash = 302;
-    RestoreAllTrash = 303;
-    DeleteAllTrash = 304;
-}

+ 0 - 12
frontend/rust-lib/flowy-grid/resources/proto/cell_entities.proto

@@ -1,12 +0,0 @@
-syntax = "proto3";
-
-import "field_entities.proto";
-message CreateSelectOptionPayload {
-    FieldIdentifierPayload field_identifier = 1;
-    string option_name = 2;
-}
-message CellIdentifierPayload {
-    string grid_id = 1;
-    string field_id = 2;
-    string row_id = 3;
-}

+ 0 - 5
frontend/rust-lib/flowy-grid/resources/proto/checkbox_type_option.proto

@@ -1,5 +0,0 @@
-syntax = "proto3";
-
-message CheckboxTypeOption {
-    bool is_selected = 1;
-}

+ 0 - 11
frontend/rust-lib/flowy-grid/resources/proto/dart_notification.proto

@@ -1,11 +0,0 @@
-syntax = "proto3";
-
-enum GridNotification {
-    Unknown = 0;
-    DidCreateBlock = 11;
-    DidUpdateGridRow = 20;
-    DidUpdateGridField = 21;
-    DidUpdateRow = 30;
-    DidUpdateCell = 40;
-    DidUpdateField = 50;
-}

+ 0 - 28
frontend/rust-lib/flowy-grid/resources/proto/date_type_option.proto

@@ -1,28 +0,0 @@
-syntax = "proto3";
-
-import "cell_entities.proto";
-message DateTypeOption {
-    DateFormat date_format = 1;
-    TimeFormat time_format = 2;
-    bool include_time = 3;
-}
-message DateCellData {
-    string date = 1;
-    string time = 2;
-    int64 timestamp = 3;
-}
-message DateChangesetPayload {
-    CellIdentifierPayload cell_identifier = 1;
-    oneof one_of_date { string date = 2; };
-    oneof one_of_time { string time = 3; };
-}
-enum DateFormat {
-    Local = 0;
-    US = 1;
-    ISO = 2;
-    Friendly = 3;
-}
-enum TimeFormat {
-    TwelveHour = 0;
-    TwentyFourHour = 1;
-}

+ 0 - 27
frontend/rust-lib/flowy-grid/resources/proto/event_map.proto

@@ -1,27 +0,0 @@
-syntax = "proto3";
-
-enum GridEvent {
-    GetGridData = 0;
-    GetGridBlocks = 1;
-    GetFields = 10;
-    UpdateField = 11;
-    UpdateFieldTypeOption = 12;
-    InsertField = 13;
-    DeleteField = 14;
-    SwitchToField = 20;
-    DuplicateField = 21;
-    MoveItem = 22;
-    GetFieldTypeOption = 23;
-    CreateFieldTypeOption = 24;
-    NewSelectOption = 30;
-    GetSelectOptionCellData = 31;
-    UpdateSelectOption = 32;
-    CreateRow = 50;
-    GetRow = 51;
-    DeleteRow = 52;
-    DuplicateRow = 53;
-    GetCell = 70;
-    UpdateCell = 71;
-    UpdateSelectOptionCell = 72;
-    UpdateDateCell = 80;
-}

+ 0 - 6
frontend/rust-lib/flowy-grid/resources/proto/field_entities.proto

@@ -1,6 +0,0 @@
-syntax = "proto3";
-
-message FieldIdentifierPayload {
-    string field_id = 1;
-    string grid_id = 2;
-}

+ 0 - 40
frontend/rust-lib/flowy-grid/resources/proto/format.proto

@@ -1,40 +0,0 @@
-syntax = "proto3";
-
-enum NumberFormat {
-    Number = 0;
-    USD = 1;
-    CanadianDollar = 2;
-    EUR = 4;
-    Pound = 5;
-    Yen = 6;
-    Ruble = 7;
-    Rupee = 8;
-    Won = 9;
-    Yuan = 10;
-    Real = 11;
-    Lira = 12;
-    Rupiah = 13;
-    Franc = 14;
-    HongKongDollar = 15;
-    NewZealandDollar = 16;
-    Krona = 17;
-    NorwegianKrone = 18;
-    MexicanPeso = 19;
-    Rand = 20;
-    NewTaiwanDollar = 21;
-    DanishKrone = 22;
-    Baht = 23;
-    Forint = 24;
-    Koruna = 25;
-    Shekel = 26;
-    ChileanPeso = 27;
-    PhilippinePeso = 28;
-    Dirham = 29;
-    ColombianPeso = 30;
-    Riyal = 31;
-    Ringgit = 32;
-    Leu = 33;
-    ArgentinePeso = 34;
-    UruguayanPeso = 35;
-    Percent = 36;
-}

+ 0 - 10
frontend/rust-lib/flowy-grid/resources/proto/number_type_option.proto

@@ -1,10 +0,0 @@
-syntax = "proto3";
-
-import "format.proto";
-message NumberTypeOption {
-    NumberFormat format = 1;
-    uint32 scale = 2;
-    string symbol = 3;
-    bool sign_positive = 4;
-    string name = 5;
-}

+ 0 - 6
frontend/rust-lib/flowy-grid/resources/proto/row_entities.proto

@@ -1,6 +0,0 @@
-syntax = "proto3";
-
-message RowIdentifierPayload {
-    string grid_id = 1;
-    string row_id = 3;
-}

+ 0 - 43
frontend/rust-lib/flowy-grid/resources/proto/selection_type_option.proto

@@ -1,43 +0,0 @@
-syntax = "proto3";
-
-import "cell_entities.proto";
-import "cell_entities.proto";
-message SingleSelectTypeOption {
-    repeated SelectOption options = 1;
-    bool disable_color = 2;
-}
-message MultiSelectTypeOption {
-    repeated SelectOption options = 1;
-    bool disable_color = 2;
-}
-message SelectOption {
-    string id = 1;
-    string name = 2;
-    SelectOptionColor color = 3;
-}
-message SelectOptionChangesetPayload {
-    CellIdentifierPayload cell_identifier = 1;
-    oneof one_of_insert_option { SelectOption insert_option = 2; };
-    oneof one_of_update_option { SelectOption update_option = 3; };
-    oneof one_of_delete_option { SelectOption delete_option = 4; };
-}
-message SelectOptionCellChangesetPayload {
-    CellIdentifierPayload cell_identifier = 1;
-    oneof one_of_insert_option_id { string insert_option_id = 2; };
-    oneof one_of_delete_option_id { string delete_option_id = 3; };
-}
-message SelectOptionCellData {
-    repeated SelectOption options = 1;
-    repeated SelectOption select_options = 2;
-}
-enum SelectOptionColor {
-    Purple = 0;
-    Pink = 1;
-    LightPink = 2;
-    Orange = 3;
-    Yellow = 4;
-    Lime = 5;
-    Green = 6;
-    Aqua = 7;
-    Blue = 8;
-}

+ 0 - 5
frontend/rust-lib/flowy-grid/resources/proto/text_type_option.proto

@@ -1,5 +0,0 @@
-syntax = "proto3";
-
-message RichTextTypeOption {
-    string data = 1;
-}

+ 0 - 9
frontend/rust-lib/flowy-grid/resources/proto/url_type_option.proto

@@ -1,9 +0,0 @@
-syntax = "proto3";
-
-message URLTypeOption {
-    string data = 1;
-}
-message URLCellData {
-    string url = 1;
-    string content = 2;
-}

+ 0 - 5
frontend/rust-lib/flowy-net/resources/proto/event_map.proto

@@ -1,5 +0,0 @@
-syntax = "proto3";
-
-enum NetworkEvent {
-    UpdateNetworkType = 0;
-}

+ 0 - 11
frontend/rust-lib/flowy-net/resources/proto/network_state.proto

@@ -1,11 +0,0 @@
-syntax = "proto3";
-
-message NetworkState {
-    NetworkType ty = 1;
-}
-enum NetworkType {
-    UnknownNetworkType = 0;
-    Wifi = 1;
-    Cell = 2;
-    Ethernet = 3;
-}

+ 0 - 15
frontend/rust-lib/flowy-text-block/resources/proto/entities.proto

@@ -1,15 +0,0 @@
-syntax = "proto3";
-
-message ExportPayload {
-    string view_id = 1;
-    ExportType export_type = 2;
-}
-message ExportData {
-    string data = 1;
-    ExportType export_type = 2;
-}
-enum ExportType {
-    Text = 0;
-    Markdown = 1;
-    Link = 2;
-}

+ 0 - 7
frontend/rust-lib/flowy-text-block/resources/proto/event_map.proto

@@ -1,7 +0,0 @@
-syntax = "proto3";
-
-enum TextBlockEvent {
-    GetBlockData = 0;
-    ApplyDelta = 1;
-    ExportDocument = 2;
-}

+ 0 - 9
frontend/rust-lib/flowy-user/resources/proto/dart_notification.proto

@@ -1,9 +0,0 @@
-syntax = "proto3";
-
-enum UserNotification {
-    Unknown = 0;
-    UserAuthChanged = 1;
-    UserProfileUpdated = 2;
-    UserUnauthorized = 3;
-    UserWsConnectStateChanged = 4;
-}

+ 0 - 13
frontend/rust-lib/flowy-user/resources/proto/event_map.proto

@@ -1,13 +0,0 @@
-syntax = "proto3";
-
-enum UserEvent {
-    InitUser = 0;
-    SignIn = 1;
-    SignUp = 2;
-    SignOut = 3;
-    UpdateUser = 4;
-    GetUserProfile = 5;
-    CheckUser = 6;
-    SetAppearanceSetting = 7;
-    GetAppearanceSetting = 8;
-}

+ 0 - 4
shared-lib/flowy-error-code/.proto/mod.rs

@@ -1,4 +0,0 @@
-#![cfg_attr(rustfmt, rustfmt::skip)]
-// Auto-generated, do not edit
-mod model;
-pub use model::*;

+ 0 - 5
shared-lib/flowy-error-code/.proto/model/mod.rs

@@ -1,5 +0,0 @@
-#![cfg_attr(rustfmt, rustfmt::skip)]
-// Auto-generated, do not edit
-
-mod code;
-pub use code::*;

+ 0 - 48
shared-lib/flowy-error-code/.proto/proto/code.proto

@@ -1,48 +0,0 @@
-syntax = "proto3";
-enum ErrorCode {
-    Internal = 0;
-    UserUnauthorized = 2;
-    RecordNotFound = 3;
-    UserIdIsEmpty = 4;
-    WorkspaceNameInvalid = 100;
-    WorkspaceIdInvalid = 101;
-    AppColorStyleInvalid = 102;
-    WorkspaceDescTooLong = 103;
-    WorkspaceNameTooLong = 104;
-    AppIdInvalid = 110;
-    AppNameInvalid = 111;
-    ViewNameInvalid = 120;
-    ViewThumbnailInvalid = 121;
-    ViewIdInvalid = 122;
-    ViewDescTooLong = 123;
-    ViewDataInvalid = 124;
-    ViewNameTooLong = 125;
-    ConnectError = 200;
-    EmailIsEmpty = 300;
-    EmailFormatInvalid = 301;
-    EmailAlreadyExists = 302;
-    PasswordIsEmpty = 303;
-    PasswordTooLong = 304;
-    PasswordContainsForbidCharacters = 305;
-    PasswordFormatInvalid = 306;
-    PasswordNotMatch = 307;
-    UserNameTooLong = 308;
-    UserNameContainForbiddenCharacters = 309;
-    UserNameIsEmpty = 310;
-    UserIdInvalid = 311;
-    UserNotExist = 312;
-    TextTooLong = 400;
-    GridIdIsEmpty = 410;
-    BlockIdIsEmpty = 420;
-    RowIdIsEmpty = 430;
-    OptionIdIsEmpty = 431;
-    FieldIdIsEmpty = 440;
-    FieldDoesNotExist = 441;
-    SelectOptionNameIsEmpty = 442;
-    FieldNotExists = 443;
-    FieldInvalidOperation = 444;
-    TypeOptionDataIsEmpty = 450;
-    InvalidDateTimeFormat = 500;
-    UnexpectedEmptyString = 999;
-    InvalidData = 1000;
-}