Commit 1a121e35 authored by Steven's avatar Steven

chore: update gitignore

parent 76ed1b5c
version: v2 version: v2
clean: true
managed: managed:
enabled: true enabled: true
disable: disable:
......
...@@ -2,8 +2,5 @@ ...@@ -2,8 +2,5 @@
version: v2 version: v2
deps: deps:
- name: buf.build/googleapis/googleapis - name: buf.build/googleapis/googleapis
commit: a86849a25cc04f4dbe9b15ddddfbc488 commit: 61b203b9a9164be9a834f58c37be6f62
digest: b5:a77a2082c596ee6800a23d8cecd021d316eb10565d6cb94532f2d7c567fe6c9a177b5bb123b51a3acb4f1f18d4f54a6da883afcb682919a137a8a37c020509a2 digest: b5:7811a98b35bd2e4ae5c3ac73c8b3d9ae429f3a790da15de188dc98fc2b77d6bb10e45711f14903af9553fa9821dff256054f2e4b7795789265bc476bec2f088c
- name: buf.build/grpc-ecosystem/grpc-gateway
commit: 3f42134f4c564983838425bc43c7a65f
digest: b5:291b947d8ac09492517557e4e72e294788cb8201afc7d0df7bda80fa10931adb60d4d669208a7696bf24f1ecb2a33a16d4c1e766e6f31809248b00343119569b
version: v2 version: v2
name: buf.build/yourselfhosted/memos
deps: deps:
- buf.build/googleapis/googleapis - buf.build/googleapis/googleapis
- buf.build/grpc-ecosystem/grpc-gateway
lint: lint:
use: use:
- BASIC - BASIC
......
...@@ -266,12 +266,12 @@ var File_api_v1_activity_service_proto protoreflect.FileDescriptor ...@@ -266,12 +266,12 @@ var File_api_v1_activity_service_proto protoreflect.FileDescriptor
const file_api_v1_activity_service_proto_rawDesc = "" + const file_api_v1_activity_service_proto_rawDesc = "" +
"\n" + "\n" +
"\x1dapi/v1/activity_service.proto\x12\fmemos.api.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xe5\x01\n" + "\x1dapi/v1/activity_service.proto\x12\fmemos.api.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xe5\x01\n" +
"\bActivity\x12\x19\n" + "\bActivity\x12\x1a\n" +
"\x04name\x18\x01 \x01(\tB\x05\xe2A\x02\x03\bR\x04name\x12\x18\n" + "\x04name\x18\x01 \x01(\tB\x06\xe0A\x03\xe0A\bR\x04name\x12\x18\n" +
"\acreator\x18\x02 \x01(\tR\acreator\x12\x12\n" + "\acreator\x18\x02 \x01(\tR\acreator\x12\x12\n" +
"\x04type\x18\x03 \x01(\tR\x04type\x12\x14\n" + "\x04type\x18\x03 \x01(\tR\x04type\x12\x14\n" +
"\x05level\x18\x04 \x01(\tR\x05level\x12A\n" + "\x05level\x18\x04 \x01(\tR\x05level\x12@\n" +
"\vcreate_time\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampB\x04\xe2A\x01\x03R\n" + "\vcreate_time\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampB\x03\xe0A\x03R\n" +
"createTime\x127\n" + "createTime\x127\n" +
"\apayload\x18\x06 \x01(\v2\x1d.memos.api.v1.ActivityPayloadR\apayload\"^\n" + "\apayload\x18\x06 \x01(\v2\x1d.memos.api.v1.ActivityPayloadR\apayload\"^\n" +
"\x0fActivityPayload\x12K\n" + "\x0fActivityPayload\x12K\n" +
......
...@@ -1666,9 +1666,9 @@ var File_api_v1_memo_service_proto protoreflect.FileDescriptor ...@@ -1666,9 +1666,9 @@ var File_api_v1_memo_service_proto protoreflect.FileDescriptor
const file_api_v1_memo_service_proto_rawDesc = "" + const file_api_v1_memo_service_proto_rawDesc = "" +
"\n" + "\n" +
"\x19api/v1/memo_service.proto\x12\fmemos.api.v1\x1a\x13api/v1/common.proto\x1a\x1dapi/v1/markdown_service.proto\x1a\x1dapi/v1/reaction_service.proto\x1a\x1dapi/v1/resource_service.proto\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xf3\a\n" + "\x19api/v1/memo_service.proto\x12\fmemos.api.v1\x1a\x13api/v1/common.proto\x1a\x1dapi/v1/markdown_service.proto\x1a\x1dapi/v1/reaction_service.proto\x1a\x1dapi/v1/resource_service.proto\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xee\a\n" +
"\x04Memo\x12\x19\n" + "\x04Memo\x12\x1a\n" +
"\x04name\x18\x01 \x01(\tB\x05\xe2A\x02\x03\bR\x04name\x12)\n" + "\x04name\x18\x01 \x01(\tB\x06\xe0A\x03\xe0A\bR\x04name\x12)\n" +
"\x05state\x18\x03 \x01(\x0e2\x13.memos.api.v1.StateR\x05state\x12\x18\n" + "\x05state\x18\x03 \x01(\x0e2\x13.memos.api.v1.StateR\x05state\x12\x18\n" +
"\acreator\x18\x04 \x01(\tR\acreator\x12;\n" + "\acreator\x18\x04 \x01(\tR\acreator\x12;\n" +
"\vcreate_time\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampR\n" + "\vcreate_time\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampR\n" +
...@@ -1676,20 +1676,20 @@ const file_api_v1_memo_service_proto_rawDesc = "" + ...@@ -1676,20 +1676,20 @@ const file_api_v1_memo_service_proto_rawDesc = "" +
"\vupdate_time\x18\x06 \x01(\v2\x1a.google.protobuf.TimestampR\n" + "\vupdate_time\x18\x06 \x01(\v2\x1a.google.protobuf.TimestampR\n" +
"updateTime\x12=\n" + "updateTime\x12=\n" +
"\fdisplay_time\x18\a \x01(\v2\x1a.google.protobuf.TimestampR\vdisplayTime\x12\x18\n" + "\fdisplay_time\x18\a \x01(\v2\x1a.google.protobuf.TimestampR\vdisplayTime\x12\x18\n" +
"\acontent\x18\b \x01(\tR\acontent\x12.\n" + "\acontent\x18\b \x01(\tR\acontent\x12-\n" +
"\x05nodes\x18\t \x03(\v2\x12.memos.api.v1.NodeB\x04\xe2A\x01\x03R\x05nodes\x128\n" + "\x05nodes\x18\t \x03(\v2\x12.memos.api.v1.NodeB\x03\xe0A\x03R\x05nodes\x128\n" +
"\n" + "\n" +
"visibility\x18\n" + "visibility\x18\n" +
" \x01(\x0e2\x18.memos.api.v1.VisibilityR\n" + " \x01(\x0e2\x18.memos.api.v1.VisibilityR\n" +
"visibility\x12\x18\n" + "visibility\x12\x17\n" +
"\x04tags\x18\v \x03(\tB\x04\xe2A\x01\x03R\x04tags\x12\x16\n" + "\x04tags\x18\v \x03(\tB\x03\xe0A\x03R\x04tags\x12\x16\n" +
"\x06pinned\x18\f \x01(\bR\x06pinned\x124\n" + "\x06pinned\x18\f \x01(\bR\x06pinned\x124\n" +
"\tresources\x18\x0e \x03(\v2\x16.memos.api.v1.ResourceR\tresources\x128\n" + "\tresources\x18\x0e \x03(\v2\x16.memos.api.v1.ResourceR\tresources\x128\n" +
"\trelations\x18\x0f \x03(\v2\x1a.memos.api.v1.MemoRelationR\trelations\x12:\n" + "\trelations\x18\x0f \x03(\v2\x1a.memos.api.v1.MemoRelationR\trelations\x129\n" +
"\treactions\x18\x10 \x03(\v2\x16.memos.api.v1.ReactionB\x04\xe2A\x01\x03R\treactions\x12=\n" + "\treactions\x18\x10 \x03(\v2\x16.memos.api.v1.ReactionB\x03\xe0A\x03R\treactions\x12<\n" +
"\bproperty\x18\x11 \x01(\v2\x1b.memos.api.v1.Memo.PropertyB\x04\xe2A\x01\x03R\bproperty\x12!\n" + "\bproperty\x18\x11 \x01(\v2\x1b.memos.api.v1.Memo.PropertyB\x03\xe0A\x03R\bproperty\x12 \n" +
"\x06parent\x18\x12 \x01(\tB\x04\xe2A\x01\x03H\x00R\x06parent\x88\x01\x01\x12\x1e\n" + "\x06parent\x18\x12 \x01(\tB\x03\xe0A\x03H\x00R\x06parent\x88\x01\x01\x12\x1d\n" +
"\asnippet\x18\x13 \x01(\tB\x04\xe2A\x01\x03R\asnippet\x127\n" + "\asnippet\x18\x13 \x01(\tB\x03\xe0A\x03R\asnippet\x127\n" +
"\blocation\x18\x14 \x01(\v2\x16.memos.api.v1.LocationH\x01R\blocation\x88\x01\x01\x1a\x96\x01\n" + "\blocation\x18\x14 \x01(\v2\x16.memos.api.v1.LocationH\x01R\blocation\x88\x01\x01\x1a\x96\x01\n" +
"\bProperty\x12\x19\n" + "\bProperty\x12\x19\n" +
"\bhas_link\x18\x01 \x01(\bR\ahasLink\x12\"\n" + "\bhas_link\x18\x01 \x01(\bR\ahasLink\x12\"\n" +
...@@ -1701,9 +1701,9 @@ const file_api_v1_memo_service_proto_rawDesc = "" + ...@@ -1701,9 +1701,9 @@ const file_api_v1_memo_service_proto_rawDesc = "" +
"\bLocation\x12 \n" + "\bLocation\x12 \n" +
"\vplaceholder\x18\x01 \x01(\tR\vplaceholder\x12\x1a\n" + "\vplaceholder\x18\x01 \x01(\tR\vplaceholder\x12\x1a\n" +
"\blatitude\x18\x02 \x01(\x01R\blatitude\x12\x1c\n" + "\blatitude\x18\x02 \x01(\x01R\blatitude\x12\x1c\n" +
"\tlongitude\x18\x03 \x01(\x01R\tlongitude\"A\n" + "\tlongitude\x18\x03 \x01(\x01R\tlongitude\"@\n" +
"\x11CreateMemoRequest\x12,\n" + "\x11CreateMemoRequest\x12+\n" +
"\x04memo\x18\x01 \x01(\v2\x12.memos.api.v1.MemoB\x04\xe2A\x01\x02R\x04memo\"\x93\x02\n" + "\x04memo\x18\x01 \x01(\v2\x12.memos.api.v1.MemoB\x03\xe0A\x02R\x04memo\"\x93\x02\n" +
"\x10ListMemosRequest\x12\x16\n" + "\x10ListMemosRequest\x12\x16\n" +
"\x06parent\x18\x01 \x01(\tR\x06parent\x12\x1b\n" + "\x06parent\x18\x01 \x01(\tR\x06parent\x12\x1b\n" +
"\tpage_size\x18\x02 \x01(\x05R\bpageSize\x12\x1d\n" + "\tpage_size\x18\x02 \x01(\x05R\bpageSize\x12\x1d\n" +
...@@ -1719,9 +1719,9 @@ const file_api_v1_memo_service_proto_rawDesc = "" + ...@@ -1719,9 +1719,9 @@ const file_api_v1_memo_service_proto_rawDesc = "" +
"\x05memos\x18\x01 \x03(\v2\x12.memos.api.v1.MemoR\x05memos\x12&\n" + "\x05memos\x18\x01 \x03(\v2\x12.memos.api.v1.MemoR\x05memos\x12&\n" +
"\x0fnext_page_token\x18\x02 \x01(\tR\rnextPageToken\"$\n" + "\x0fnext_page_token\x18\x02 \x01(\tR\rnextPageToken\"$\n" +
"\x0eGetMemoRequest\x12\x12\n" + "\x0eGetMemoRequest\x12\x12\n" +
"\x04name\x18\x01 \x01(\tR\x04name\"~\n" + "\x04name\x18\x01 \x01(\tR\x04name\"}\n" +
"\x11UpdateMemoRequest\x12,\n" + "\x11UpdateMemoRequest\x12+\n" +
"\x04memo\x18\x01 \x01(\v2\x12.memos.api.v1.MemoB\x04\xe2A\x01\x02R\x04memo\x12;\n" + "\x04memo\x18\x01 \x01(\v2\x12.memos.api.v1.MemoB\x03\xe0A\x02R\x04memo\x12;\n" +
"\vupdate_mask\x18\x02 \x01(\v2\x1a.google.protobuf.FieldMaskR\n" + "\vupdate_mask\x18\x02 \x01(\v2\x1a.google.protobuf.FieldMaskR\n" +
"updateMask\"'\n" + "updateMask\"'\n" +
"\x11DeleteMemoRequest\x12\x12\n" + "\x11DeleteMemoRequest\x12\x12\n" +
...@@ -1740,15 +1740,15 @@ const file_api_v1_memo_service_proto_rawDesc = "" + ...@@ -1740,15 +1740,15 @@ const file_api_v1_memo_service_proto_rawDesc = "" +
"\x18ListMemoResourcesRequest\x12\x12\n" + "\x18ListMemoResourcesRequest\x12\x12\n" +
"\x04name\x18\x01 \x01(\tR\x04name\"Q\n" + "\x04name\x18\x01 \x01(\tR\x04name\"Q\n" +
"\x19ListMemoResourcesResponse\x124\n" + "\x19ListMemoResourcesResponse\x124\n" +
"\tresources\x18\x01 \x03(\v2\x16.memos.api.v1.ResourceR\tresources\"\xc4\x02\n" + "\tresources\x18\x01 \x03(\v2\x16.memos.api.v1.ResourceR\tresources\"\xc3\x02\n" +
"\fMemoRelation\x123\n" + "\fMemoRelation\x123\n" +
"\x04memo\x18\x01 \x01(\v2\x1f.memos.api.v1.MemoRelation.MemoR\x04memo\x12B\n" + "\x04memo\x18\x01 \x01(\v2\x1f.memos.api.v1.MemoRelation.MemoR\x04memo\x12B\n" +
"\frelated_memo\x18\x02 \x01(\v2\x1f.memos.api.v1.MemoRelation.MemoR\vrelatedMemo\x123\n" + "\frelated_memo\x18\x02 \x01(\v2\x1f.memos.api.v1.MemoRelation.MemoR\vrelatedMemo\x123\n" +
"\x04type\x18\x03 \x01(\x0e2\x1f.memos.api.v1.MemoRelation.TypeR\x04type\x1aL\n" + "\x04type\x18\x03 \x01(\x0e2\x1f.memos.api.v1.MemoRelation.TypeR\x04type\x1aK\n" +
"\x04Memo\x12\x12\n" + "\x04Memo\x12\x12\n" +
"\x04name\x18\x01 \x01(\tR\x04name\x12\x10\n" + "\x04name\x18\x01 \x01(\tR\x04name\x12\x10\n" +
"\x03uid\x18\x02 \x01(\tR\x03uid\x12\x1e\n" + "\x03uid\x18\x02 \x01(\tR\x03uid\x12\x1d\n" +
"\asnippet\x18\x03 \x01(\tB\x04\xe2A\x01\x03R\asnippet\"8\n" + "\asnippet\x18\x03 \x01(\tB\x03\xe0A\x03R\asnippet\"8\n" +
"\x04Type\x12\x14\n" + "\x04Type\x12\x14\n" +
"\x10TYPE_UNSPECIFIED\x10\x00\x12\r\n" + "\x10TYPE_UNSPECIFIED\x10\x00\x12\r\n" +
"\tREFERENCE\x10\x01\x12\v\n" + "\tREFERENCE\x10\x01\x12\v\n" +
......
...@@ -462,13 +462,13 @@ var File_api_v1_resource_service_proto protoreflect.FileDescriptor ...@@ -462,13 +462,13 @@ var File_api_v1_resource_service_proto protoreflect.FileDescriptor
const file_api_v1_resource_service_proto_rawDesc = "" + const file_api_v1_resource_service_proto_rawDesc = "" +
"\n" + "\n" +
"\x1dapi/v1/resource_service.proto\x12\fmemos.api.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/httpbody.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\x99\x02\n" + "\x1dapi/v1/resource_service.proto\x12\fmemos.api.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/httpbody.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\x98\x02\n" +
"\bResource\x12\x19\n" + "\bResource\x12\x1a\n" +
"\x04name\x18\x01 \x01(\tB\x05\xe2A\x02\x03\bR\x04name\x12A\n" + "\x04name\x18\x01 \x01(\tB\x06\xe0A\x03\xe0A\bR\x04name\x12@\n" +
"\vcreate_time\x18\x03 \x01(\v2\x1a.google.protobuf.TimestampB\x04\xe2A\x01\x03R\n" + "\vcreate_time\x18\x03 \x01(\v2\x1a.google.protobuf.TimestampB\x03\xe0A\x03R\n" +
"createTime\x12\x1a\n" + "createTime\x12\x1a\n" +
"\bfilename\x18\x04 \x01(\tR\bfilename\x12\x1e\n" + "\bfilename\x18\x04 \x01(\tR\bfilename\x12\x1d\n" +
"\acontent\x18\x05 \x01(\fB\x04\xe2A\x01\x04R\acontent\x12#\n" + "\acontent\x18\x05 \x01(\fB\x03\xe0A\x04R\acontent\x12#\n" +
"\rexternal_link\x18\x06 \x01(\tR\fexternalLink\x12\x12\n" + "\rexternal_link\x18\x06 \x01(\tR\fexternalLink\x12\x12\n" +
"\x04type\x18\a \x01(\tR\x04type\x12\x12\n" + "\x04type\x18\a \x01(\tR\x04type\x12\x12\n" +
"\x04size\x18\b \x01(\x03R\x04size\x12\x17\n" + "\x04size\x18\b \x01(\x03R\x04size\x12\x17\n" +
......
...@@ -1623,22 +1623,22 @@ var File_api_v1_user_service_proto protoreflect.FileDescriptor ...@@ -1623,22 +1623,22 @@ var File_api_v1_user_service_proto protoreflect.FileDescriptor
const file_api_v1_user_service_proto_rawDesc = "" + const file_api_v1_user_service_proto_rawDesc = "" +
"\n" + "\n" +
"\x19api/v1/user_service.proto\x12\fmemos.api.v1\x1a\x13api/v1/common.proto\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/httpbody.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xed\x03\n" + "\x19api/v1/user_service.proto\x12\fmemos.api.v1\x1a\x13api/v1/common.proto\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/httpbody.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xeb\x03\n" +
"\x04User\x12\x19\n" + "\x04User\x12\x1a\n" +
"\x04name\x18\x01 \x01(\tB\x05\xe2A\x02\x03\bR\x04name\x12+\n" + "\x04name\x18\x01 \x01(\tB\x06\xe0A\x03\xe0A\bR\x04name\x12+\n" +
"\x04role\x18\x03 \x01(\x0e2\x17.memos.api.v1.User.RoleR\x04role\x12\x1a\n" + "\x04role\x18\x03 \x01(\x0e2\x17.memos.api.v1.User.RoleR\x04role\x12\x1a\n" +
"\busername\x18\x04 \x01(\tR\busername\x12\x14\n" + "\busername\x18\x04 \x01(\tR\busername\x12\x14\n" +
"\x05email\x18\x05 \x01(\tR\x05email\x12\x1a\n" + "\x05email\x18\x05 \x01(\tR\x05email\x12\x1a\n" +
"\bnickname\x18\x06 \x01(\tR\bnickname\x12\x1d\n" + "\bnickname\x18\x06 \x01(\tR\bnickname\x12\x1d\n" +
"\n" + "\n" +
"avatar_url\x18\a \x01(\tR\tavatarUrl\x12 \n" + "avatar_url\x18\a \x01(\tR\tavatarUrl\x12 \n" +
"\vdescription\x18\b \x01(\tR\vdescription\x12 \n" + "\vdescription\x18\b \x01(\tR\vdescription\x12\x1f\n" +
"\bpassword\x18\t \x01(\tB\x04\xe2A\x01\x04R\bpassword\x12)\n" + "\bpassword\x18\t \x01(\tB\x03\xe0A\x04R\bpassword\x12)\n" +
"\x05state\x18\n" + "\x05state\x18\n" +
" \x01(\x0e2\x13.memos.api.v1.StateR\x05state\x12A\n" + " \x01(\x0e2\x13.memos.api.v1.StateR\x05state\x12@\n" +
"\vcreate_time\x18\v \x01(\v2\x1a.google.protobuf.TimestampB\x04\xe2A\x01\x03R\n" + "\vcreate_time\x18\v \x01(\v2\x1a.google.protobuf.TimestampB\x03\xe0A\x03R\n" +
"createTime\x12A\n" + "createTime\x12@\n" +
"\vupdate_time\x18\f \x01(\v2\x1a.google.protobuf.TimestampB\x04\xe2A\x01\x03R\n" + "\vupdate_time\x18\f \x01(\v2\x1a.google.protobuf.TimestampB\x03\xe0A\x03R\n" +
"updateTime\";\n" + "updateTime\";\n" +
"\x04Role\x12\x14\n" + "\x04Role\x12\x14\n" +
"\x10ROLE_UNSPECIFIED\x10\x00\x12\b\n" + "\x10ROLE_UNSPECIFIED\x10\x00\x12\b\n" +
...@@ -1656,9 +1656,9 @@ const file_api_v1_user_service_proto_rawDesc = "" + ...@@ -1656,9 +1656,9 @@ const file_api_v1_user_service_proto_rawDesc = "" +
"\x04name\x18\x01 \x01(\tR\x04name\x121\n" + "\x04name\x18\x01 \x01(\tR\x04name\x121\n" +
"\thttp_body\x18\x02 \x01(\v2\x14.google.api.HttpBodyR\bhttpBody\";\n" + "\thttp_body\x18\x02 \x01(\v2\x14.google.api.HttpBodyR\bhttpBody\";\n" +
"\x11CreateUserRequest\x12&\n" + "\x11CreateUserRequest\x12&\n" +
"\x04user\x18\x01 \x01(\v2\x12.memos.api.v1.UserR\x04user\"~\n" + "\x04user\x18\x01 \x01(\v2\x12.memos.api.v1.UserR\x04user\"}\n" +
"\x11UpdateUserRequest\x12,\n" + "\x11UpdateUserRequest\x12+\n" +
"\x04user\x18\x01 \x01(\v2\x12.memos.api.v1.UserB\x04\xe2A\x01\x02R\x04user\x12;\n" + "\x04user\x18\x01 \x01(\v2\x12.memos.api.v1.UserB\x03\xe0A\x02R\x04user\x12;\n" +
"\vupdate_mask\x18\x02 \x01(\v2\x1a.google.protobuf.FieldMaskR\n" + "\vupdate_mask\x18\x02 \x01(\v2\x1a.google.protobuf.FieldMaskR\n" +
"updateMask\"'\n" + "updateMask\"'\n" +
"\x11DeleteUserRequest\x12\x12\n" + "\x11DeleteUserRequest\x12\x12\n" +
...@@ -1696,9 +1696,9 @@ const file_api_v1_user_service_proto_rawDesc = "" + ...@@ -1696,9 +1696,9 @@ const file_api_v1_user_service_proto_rawDesc = "" +
"appearance\x12'\n" + "appearance\x12'\n" +
"\x0fmemo_visibility\x18\x04 \x01(\tR\x0ememoVisibility\"+\n" + "\x0fmemo_visibility\x18\x04 \x01(\tR\x0ememoVisibility\"+\n" +
"\x15GetUserSettingRequest\x12\x12\n" + "\x15GetUserSettingRequest\x12\x12\n" +
"\x04name\x18\x01 \x01(\tR\x04name\"\x92\x01\n" + "\x04name\x18\x01 \x01(\tR\x04name\"\x91\x01\n" +
"\x18UpdateUserSettingRequest\x129\n" + "\x18UpdateUserSettingRequest\x128\n" +
"\asetting\x18\x01 \x01(\v2\x19.memos.api.v1.UserSettingB\x04\xe2A\x01\x02R\asetting\x12;\n" + "\asetting\x18\x01 \x01(\v2\x19.memos.api.v1.UserSettingB\x03\xe0A\x02R\asetting\x12;\n" +
"\vupdate_mask\x18\x02 \x01(\v2\x1a.google.protobuf.FieldMaskR\n" + "\vupdate_mask\x18\x02 \x01(\v2\x1a.google.protobuf.FieldMaskR\n" +
"updateMask\"\xca\x01\n" + "updateMask\"\xca\x01\n" +
"\x0fUserAccessToken\x12!\n" + "\x0fUserAccessToken\x12!\n" +
......
...@@ -812,9 +812,9 @@ const file_api_v1_workspace_setting_service_proto_rawDesc = "" + ...@@ -812,9 +812,9 @@ const file_api_v1_workspace_setting_service_proto_rawDesc = "" +
" \x03(\tR\treactions\x12<\n" + " \x03(\tR\treactions\x12<\n" +
"\x1adisable_markdown_shortcuts\x18\v \x01(\bR\x18disableMarkdownShortcuts\x127\n" + "\x1adisable_markdown_shortcuts\x18\v \x01(\bR\x18disableMarkdownShortcuts\x127\n" +
"\x18enable_blur_nsfw_content\x18\f \x01(\bR\x15enableBlurNsfwContent\x12\x1b\n" + "\x18enable_blur_nsfw_content\x18\f \x01(\bR\x15enableBlurNsfwContent\x12\x1b\n" +
"\tnsfw_tags\x18\r \x03(\tR\bnsfwTagsJ\x04\b\x04\x10\x05\"6\n" + "\tnsfw_tags\x18\r \x03(\tR\bnsfwTagsJ\x04\b\x04\x10\x05\"5\n" +
"\x1aGetWorkspaceSettingRequest\x12\x18\n" + "\x1aGetWorkspaceSettingRequest\x12\x17\n" +
"\x04name\x18\x01 \x01(\tB\x04\xe2A\x01\x02R\x04name\"V\n" + "\x04name\x18\x01 \x01(\tB\x03\xe0A\x02R\x04name\"V\n" +
"\x1aSetWorkspaceSettingRequest\x128\n" + "\x1aSetWorkspaceSettingRequest\x128\n" +
"\asetting\x18\x01 \x01(\v2\x1e.memos.api.v1.WorkspaceSettingR\asetting2\xd9\x02\n" + "\asetting\x18\x01 \x01(\v2\x1e.memos.api.v1.WorkspaceSettingR\asetting2\xd9\x02\n" +
"\x17WorkspaceSettingService\x12\x93\x01\n" + "\x17WorkspaceSettingService\x12\x93\x01\n" +
......
...@@ -4,4 +4,4 @@ node_modules ...@@ -4,4 +4,4 @@ node_modules
dist dist
dist-ssr dist-ssr
*.local *.local
src/types/proto src/types/proto/store
...@@ -4,8 +4,7 @@ ...@@ -4,8 +4,7 @@
"dev": "vite", "dev": "vite",
"build": "vite build", "build": "vite build",
"release": "vite build --mode release --outDir=../server/router/frontend/dist --emptyOutDir", "release": "vite build --mode release --outDir=../server/router/frontend/dist --emptyOutDir",
"lint": "tsc --noEmit --skipLibCheck && eslint --ext .js,.ts,.tsx, src", "lint": "tsc --noEmit --skipLibCheck && eslint --ext .js,.ts,.tsx, src"
"postinstall": "cd ../proto && buf generate"
}, },
"dependencies": { "dependencies": {
"@dnd-kit/core": "^6.3.1", "@dnd-kit/core": "^6.3.1",
...@@ -49,7 +48,6 @@ ...@@ -49,7 +48,6 @@
"zustand": "^5.0.3" "zustand": "^5.0.3"
}, },
"devDependencies": { "devDependencies": {
"@bufbuild/buf": "^1.52.1",
"@bufbuild/protobuf": "^2.2.5", "@bufbuild/protobuf": "^2.2.5",
"@eslint/js": "^9.23.0", "@eslint/js": "^9.23.0",
"@trivago/prettier-plugin-sort-imports": "^5.2.2", "@trivago/prettier-plugin-sort-imports": "^5.2.2",
...@@ -75,7 +73,6 @@ ...@@ -75,7 +73,6 @@
"nice-grpc-web": "^3.3.7", "nice-grpc-web": "^3.3.7",
"postcss": "^8.5.3", "postcss": "^8.5.3",
"prettier": "^3.5.3", "prettier": "^3.5.3",
"protobufjs": "^7.4.0",
"terser": "^5.39.0", "terser": "^5.39.0",
"typescript": "^5.8.2", "typescript": "^5.8.2",
"typescript-eslint": "^8.28.0", "typescript-eslint": "^8.28.0",
...@@ -83,7 +80,6 @@ ...@@ -83,7 +80,6 @@
}, },
"pnpm": { "pnpm": {
"onlyBuiltDependencies": [ "onlyBuiltDependencies": [
"@bufbuild/buf",
"esbuild" "esbuild"
] ]
} }
......
...@@ -126,9 +126,6 @@ importers: ...@@ -126,9 +126,6 @@ importers:
specifier: ^5.0.3 specifier: ^5.0.3
version: 5.0.3(@types/react@18.3.18)(immer@10.1.1)(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1)) version: 5.0.3(@types/react@18.3.18)(immer@10.1.1)(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1))
devDependencies: devDependencies:
'@bufbuild/buf':
specifier: ^1.52.1
version: 1.52.1
'@bufbuild/protobuf': '@bufbuild/protobuf':
specifier: ^2.2.5 specifier: ^2.2.5
version: 2.2.5 version: 2.2.5
...@@ -204,9 +201,6 @@ importers: ...@@ -204,9 +201,6 @@ importers:
prettier: prettier:
specifier: ^3.5.3 specifier: ^3.5.3
version: 3.5.3 version: 3.5.3
protobufjs:
specifier: ^7.4.0
version: 7.4.0
terser: terser:
specifier: ^5.39.0 specifier: ^5.39.0
version: 5.39.0 version: 5.39.0
...@@ -744,53 +738,6 @@ packages: ...@@ -744,53 +738,6 @@ packages:
'@braintree/sanitize-url@7.1.1': '@braintree/sanitize-url@7.1.1':
resolution: {integrity: sha512-i1L7noDNxtFyL5DmZafWy1wRVhGehQmzZaz1HiN5e7iylJMSZR7ekOV7NsIqa5qBldlLrsKv4HbgFUVlQrz8Mw==} resolution: {integrity: sha512-i1L7noDNxtFyL5DmZafWy1wRVhGehQmzZaz1HiN5e7iylJMSZR7ekOV7NsIqa5qBldlLrsKv4HbgFUVlQrz8Mw==}
'@bufbuild/buf-darwin-arm64@1.52.1':
resolution: {integrity: sha512-c2iCRSvhrQVCe91xQNKhwy4ES3AN0kWP1oXnCe+bzReOrBsLef9gVoxKbDv5Ywkv+epfqhuAVbltpN37P4s9mQ==}
engines: {node: '>=12'}
cpu: [arm64]
os: [darwin]
'@bufbuild/buf-darwin-x64@1.52.1':
resolution: {integrity: sha512-2v742rgJBCe8E1H/u8ObUH4oeev5jCMP9TKPRy3iQZBFB2lXXgvKQCmSP2Du6Sc7bC3L4QxSbLfhJRobdjUR3Q==}
engines: {node: '>=12'}
cpu: [x64]
os: [darwin]
'@bufbuild/buf-linux-aarch64@1.52.1':
resolution: {integrity: sha512-bnfDsmsnPlgNBueTzIemBuL4WxcASR7T+RIeTjur+VILN7kN6Pd8gUiNIQbZSvKwRdKGDRJXCfn404w+5Djo5A==}
engines: {node: '>=12'}
cpu: [arm64]
os: [linux]
'@bufbuild/buf-linux-armv7@1.52.1':
resolution: {integrity: sha512-+BvlP9FZu83dOoy2+fIw9/CuTq3TwDUXqfMU14b0CRDlx6eJsTbFMsYyNCQYdp9yJsLy3keEHKlBQkYdfd1wpQ==}
engines: {node: '>=12'}
cpu: [arm]
os: [linux]
'@bufbuild/buf-linux-x64@1.52.1':
resolution: {integrity: sha512-MIf62fmcV1FbBzojPfQAuE1BRspkgc6w5SDYdgimd85a9FYOrpUTkt31ZPjEz/swOuneGcDecayYtt6jWEcMGA==}
engines: {node: '>=12'}
cpu: [x64]
os: [linux]
'@bufbuild/buf-win32-arm64@1.52.1':
resolution: {integrity: sha512-QCKsJlgiEeY8bUipVO2WDQHHrSkmWUU7DAqZrw/ndHNCwg+//jhuwLYEbpbRiA1qG4Va6WzosR5/3VgOetyLuw==}
engines: {node: '>=12'}
cpu: [arm64]
os: [win32]
'@bufbuild/buf-win32-x64@1.52.1':
resolution: {integrity: sha512-VzoN16/MbZ/ozLjFp5JKhSAhs9iOEPrp0hbCpO56o/0HXFQ96KNgNEP9vYD/E90DNHWW5sgoFk74zdJLXG8wXw==}
engines: {node: '>=12'}
cpu: [x64]
os: [win32]
'@bufbuild/buf@1.52.1':
resolution: {integrity: sha512-Sflcgagb/9gu3ShUF7jjJmYgMxut+YRNajPtTk20cUq5MIG8cCZeVfA6s6kDj2TG5QuAf49u5akTHPa5ZENr0A==}
engines: {node: '>=12'}
hasBin: true
'@bufbuild/protobuf@2.2.5': '@bufbuild/protobuf@2.2.5':
resolution: {integrity: sha512-/g5EzJifw5GF8aren8wZ/G5oMuPoGeS6MQD3ca8ddcvdXR5UELUfdTZITCGNhNXynY/AYl3Z4plmxdj/tRl/hQ==} resolution: {integrity: sha512-/g5EzJifw5GF8aren8wZ/G5oMuPoGeS6MQD3ca8ddcvdXR5UELUfdTZITCGNhNXynY/AYl3Z4plmxdj/tRl/hQ==}
...@@ -1270,36 +1217,6 @@ packages: ...@@ -1270,36 +1217,6 @@ packages:
'@popperjs/core@2.11.8': '@popperjs/core@2.11.8':
resolution: {integrity: sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A==} resolution: {integrity: sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A==}
'@protobufjs/aspromise@1.1.2':
resolution: {integrity: sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ==}
'@protobufjs/base64@1.1.2':
resolution: {integrity: sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg==}
'@protobufjs/codegen@2.0.4':
resolution: {integrity: sha512-YyFaikqM5sH0ziFZCN3xDC7zeGaB/d0IUb9CATugHWbd1FRFwWwt4ld4OYMPWu5a3Xe01mGAULCdqhMlPl29Jg==}
'@protobufjs/eventemitter@1.1.0':
resolution: {integrity: sha512-j9ednRT81vYJ9OfVuXG6ERSTdEL1xVsNgqpkxMsbIabzSo3goCjDIveeGv5d03om39ML71RdmrGNjG5SReBP/Q==}
'@protobufjs/fetch@1.1.0':
resolution: {integrity: sha512-lljVXpqXebpsijW71PZaCYeIcE5on1w5DlQy5WH6GLbFryLUrBD4932W/E2BSpfRJWseIL4v/KPgBFxDOIdKpQ==}
'@protobufjs/float@1.0.2':
resolution: {integrity: sha512-Ddb+kVXlXst9d+R9PfTIxh1EdNkgoRe5tOX6t01f1lYWOvJnSPDBlG241QLzcyPdoNTsblLUdujGSE4RzrTZGQ==}
'@protobufjs/inquire@1.1.0':
resolution: {integrity: sha512-kdSefcPdruJiFMVSbn801t4vFK7KB/5gd2fYvrxhuJYg8ILrmn9SKSX2tZdV6V+ksulWqS7aXjBcRXl3wHoD9Q==}
'@protobufjs/path@1.1.2':
resolution: {integrity: sha512-6JOcJ5Tm08dOHAbdR3GrvP+yUUfkjG5ePsHYczMFLq3ZmMkAD98cDgcT2iA1lJ9NVwFd4tH/iSSoe44YWkltEA==}
'@protobufjs/pool@1.1.0':
resolution: {integrity: sha512-0kELaGSIDBKvcgS4zkjz1PeddatrjYcmMWOlAuAPwAeccUrPHdUqo/J6LiymHHEiJT5NrF1UVwxY14f+fy4WQw==}
'@protobufjs/utf8@1.1.0':
resolution: {integrity: sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==}
'@radix-ui/primitive@1.1.1': '@radix-ui/primitive@1.1.1':
resolution: {integrity: sha512-SJ31y+Q/zAyShtXJc8x83i9TYdbAfHZ++tUZnvjJJqFjzsdUnKsxPL6IEtBlxKkU7yzer//GQtZSV4GbldL3YA==} resolution: {integrity: sha512-SJ31y+Q/zAyShtXJc8x83i9TYdbAfHZ++tUZnvjJJqFjzsdUnKsxPL6IEtBlxKkU7yzer//GQtZSV4GbldL3YA==}
...@@ -3359,10 +3276,6 @@ packages: ...@@ -3359,10 +3276,6 @@ packages:
prop-types@15.8.1: prop-types@15.8.1:
resolution: {integrity: sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==} resolution: {integrity: sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==}
protobufjs@7.4.0:
resolution: {integrity: sha512-mRUWCc3KUU4w1jU8sGxICXH/gNS94DvI1gxqDvBzhj1JpcsimQkYiOJfwsPUykUI5ZaspFbSgmBLER8IrQ3tqw==}
engines: {node: '>=12.0.0'}
prr@1.0.1: prr@1.0.1:
resolution: {integrity: sha512-yPw4Sng1gWghHQWj0B3ZggWUm4qVbPwPFcRG8KyxiU7J2OHFSoEHKS+EZ3fv5l1t9CyCiop6l/ZYeWbrgoQejw==} resolution: {integrity: sha512-yPw4Sng1gWghHQWj0B3ZggWUm4qVbPwPFcRG8KyxiU7J2OHFSoEHKS+EZ3fv5l1t9CyCiop6l/ZYeWbrgoQejw==}
...@@ -4767,37 +4680,6 @@ snapshots: ...@@ -4767,37 +4680,6 @@ snapshots:
'@braintree/sanitize-url@7.1.1': {} '@braintree/sanitize-url@7.1.1': {}
'@bufbuild/buf-darwin-arm64@1.52.1':
optional: true
'@bufbuild/buf-darwin-x64@1.52.1':
optional: true
'@bufbuild/buf-linux-aarch64@1.52.1':
optional: true
'@bufbuild/buf-linux-armv7@1.52.1':
optional: true
'@bufbuild/buf-linux-x64@1.52.1':
optional: true
'@bufbuild/buf-win32-arm64@1.52.1':
optional: true
'@bufbuild/buf-win32-x64@1.52.1':
optional: true
'@bufbuild/buf@1.52.1':
optionalDependencies:
'@bufbuild/buf-darwin-arm64': 1.52.1
'@bufbuild/buf-darwin-x64': 1.52.1
'@bufbuild/buf-linux-aarch64': 1.52.1
'@bufbuild/buf-linux-armv7': 1.52.1
'@bufbuild/buf-linux-x64': 1.52.1
'@bufbuild/buf-win32-arm64': 1.52.1
'@bufbuild/buf-win32-x64': 1.52.1
'@bufbuild/protobuf@2.2.5': {} '@bufbuild/protobuf@2.2.5': {}
'@chevrotain/cst-dts-gen@11.0.3': '@chevrotain/cst-dts-gen@11.0.3':
...@@ -5243,29 +5125,6 @@ snapshots: ...@@ -5243,29 +5125,6 @@ snapshots:
'@popperjs/core@2.11.8': {} '@popperjs/core@2.11.8': {}
'@protobufjs/aspromise@1.1.2': {}
'@protobufjs/base64@1.1.2': {}
'@protobufjs/codegen@2.0.4': {}
'@protobufjs/eventemitter@1.1.0': {}
'@protobufjs/fetch@1.1.0':
dependencies:
'@protobufjs/aspromise': 1.1.2
'@protobufjs/inquire': 1.1.0
'@protobufjs/float@1.0.2': {}
'@protobufjs/inquire@1.1.0': {}
'@protobufjs/path@1.1.2': {}
'@protobufjs/pool@1.1.0': {}
'@protobufjs/utf8@1.1.0': {}
'@radix-ui/primitive@1.1.1': {} '@radix-ui/primitive@1.1.1': {}
'@radix-ui/react-arrow@1.1.2(@types/react-dom@18.3.5(@types/react@18.3.18))(@types/react@18.3.18)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': '@radix-ui/react-arrow@1.1.2(@types/react-dom@18.3.5(@types/react@18.3.18))(@types/react@18.3.18)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)':
...@@ -7540,21 +7399,6 @@ snapshots: ...@@ -7540,21 +7399,6 @@ snapshots:
object-assign: 4.1.1 object-assign: 4.1.1
react-is: 16.13.1 react-is: 16.13.1
protobufjs@7.4.0:
dependencies:
'@protobufjs/aspromise': 1.1.2
'@protobufjs/base64': 1.1.2
'@protobufjs/codegen': 2.0.4
'@protobufjs/eventemitter': 1.1.0
'@protobufjs/fetch': 1.1.0
'@protobufjs/float': 1.0.2
'@protobufjs/inquire': 1.1.0
'@protobufjs/path': 1.1.2
'@protobufjs/pool': 1.1.0
'@protobufjs/utf8': 1.1.0
'@types/node': 22.13.10
long: 5.3.1
prr@1.0.1: prr@1.0.1:
optional: true optional: true
......
...@@ -6,8 +6,8 @@ import { useState } from "react"; ...@@ -6,8 +6,8 @@ import { useState } from "react";
import { toast } from "react-hot-toast"; import { toast } from "react-hot-toast";
import { workspaceSettingNamePrefix } from "@/store/v1"; import { workspaceSettingNamePrefix } from "@/store/v1";
import { workspaceStore } from "@/store/v2"; import { workspaceStore } from "@/store/v2";
import { WorkspaceSettingKey } from "@/store/v2/workspace";
import { WorkspaceMemoRelatedSetting } from "@/types/proto/api/v1/workspace_setting_service"; import { WorkspaceMemoRelatedSetting } from "@/types/proto/api/v1/workspace_setting_service";
import { WorkspaceSettingKey } from "@/types/proto/store/workspace_setting";
import { useTranslate } from "@/utils/i18n"; import { useTranslate } from "@/utils/i18n";
const MemoRelatedSettings = () => { const MemoRelatedSettings = () => {
......
...@@ -7,12 +7,12 @@ import { toast } from "react-hot-toast"; ...@@ -7,12 +7,12 @@ import { toast } from "react-hot-toast";
import { Link } from "react-router-dom"; import { Link } from "react-router-dom";
import { workspaceSettingNamePrefix } from "@/store/v1"; import { workspaceSettingNamePrefix } from "@/store/v1";
import { workspaceStore } from "@/store/v2"; import { workspaceStore } from "@/store/v2";
import { WorkspaceSettingKey } from "@/store/v2/workspace";
import { import {
WorkspaceStorageSetting, WorkspaceStorageSetting,
WorkspaceStorageSetting_S3Config, WorkspaceStorageSetting_S3Config,
WorkspaceStorageSetting_StorageType, WorkspaceStorageSetting_StorageType,
} from "@/types/proto/api/v1/workspace_setting_service"; } from "@/types/proto/api/v1/workspace_setting_service";
import { WorkspaceSettingKey } from "@/types/proto/store/workspace_setting";
import { useTranslate } from "@/utils/i18n"; import { useTranslate } from "@/utils/i18n";
const StorageSection = () => { const StorageSection = () => {
......
...@@ -8,9 +8,9 @@ import { Link } from "react-router-dom"; ...@@ -8,9 +8,9 @@ import { Link } from "react-router-dom";
import { identityProviderServiceClient } from "@/grpcweb"; import { identityProviderServiceClient } from "@/grpcweb";
import { workspaceSettingNamePrefix } from "@/store/v1"; import { workspaceSettingNamePrefix } from "@/store/v1";
import { workspaceStore } from "@/store/v2"; import { workspaceStore } from "@/store/v2";
import { WorkspaceSettingKey } from "@/store/v2/workspace";
import { IdentityProvider } from "@/types/proto/api/v1/idp_service"; import { IdentityProvider } from "@/types/proto/api/v1/idp_service";
import { WorkspaceGeneralSetting } from "@/types/proto/api/v1/workspace_setting_service"; import { WorkspaceGeneralSetting } from "@/types/proto/api/v1/workspace_setting_service";
import { WorkspaceSettingKey } from "@/types/proto/store/workspace_setting";
import { useTranslate } from "@/utils/i18n"; import { useTranslate } from "@/utils/i18n";
import showUpdateCustomizedProfileDialog from "../UpdateCustomizedProfileDialog"; import showUpdateCustomizedProfileDialog from "../UpdateCustomizedProfileDialog";
......
...@@ -5,8 +5,8 @@ import { useState } from "react"; ...@@ -5,8 +5,8 @@ import { useState } from "react";
import { toast } from "react-hot-toast"; import { toast } from "react-hot-toast";
import { workspaceSettingNamePrefix } from "@/store/v1"; import { workspaceSettingNamePrefix } from "@/store/v1";
import { workspaceStore } from "@/store/v2"; import { workspaceStore } from "@/store/v2";
import { WorkspaceSettingKey } from "@/store/v2/workspace";
import { WorkspaceCustomProfile } from "@/types/proto/api/v1/workspace_setting_service"; import { WorkspaceCustomProfile } from "@/types/proto/api/v1/workspace_setting_service";
import { WorkspaceSettingKey } from "@/types/proto/store/workspace_setting";
import { useTranslate } from "@/utils/i18n"; import { useTranslate } from "@/utils/i18n";
import AppearanceSelect from "./AppearanceSelect"; import AppearanceSelect from "./AppearanceSelect";
import { generateDialog } from "./Dialog"; import { generateDialog } from "./Dialog";
......
...@@ -15,8 +15,8 @@ import WorkspaceSection from "@/components/Settings/WorkspaceSection"; ...@@ -15,8 +15,8 @@ import WorkspaceSection from "@/components/Settings/WorkspaceSection";
import useCurrentUser from "@/hooks/useCurrentUser"; import useCurrentUser from "@/hooks/useCurrentUser";
import useResponsiveWidth from "@/hooks/useResponsiveWidth"; import useResponsiveWidth from "@/hooks/useResponsiveWidth";
import { workspaceStore } from "@/store/v2"; import { workspaceStore } from "@/store/v2";
import { WorkspaceSettingKey } from "@/store/v2/workspace";
import { User_Role } from "@/types/proto/api/v1/user_service"; import { User_Role } from "@/types/proto/api/v1/user_service";
import { WorkspaceSettingKey } from "@/types/proto/store/workspace_setting";
import { useTranslate } from "@/utils/i18n"; import { useTranslate } from "@/utils/i18n";
type SettingSection = "my-account" | "preference" | "member" | "system" | "memo-related" | "storage" | "sso"; type SettingSection = "my-account" | "preference" | "member" | "system" | "memo-related" | "storage" | "sso";
......
...@@ -3,10 +3,20 @@ import { makeAutoObservable } from "mobx"; ...@@ -3,10 +3,20 @@ import { makeAutoObservable } from "mobx";
import { workspaceServiceClient, workspaceSettingServiceClient } from "@/grpcweb"; import { workspaceServiceClient, workspaceSettingServiceClient } from "@/grpcweb";
import { WorkspaceProfile } from "@/types/proto/api/v1/workspace_service"; import { WorkspaceProfile } from "@/types/proto/api/v1/workspace_service";
import { WorkspaceGeneralSetting, WorkspaceMemoRelatedSetting, WorkspaceSetting } from "@/types/proto/api/v1/workspace_setting_service"; import { WorkspaceGeneralSetting, WorkspaceMemoRelatedSetting, WorkspaceSetting } from "@/types/proto/api/v1/workspace_setting_service";
import { WorkspaceSettingKey } from "@/types/proto/store/workspace_setting";
import { isValidateLocale } from "@/utils/i18n"; import { isValidateLocale } from "@/utils/i18n";
import { workspaceSettingNamePrefix } from "../v1"; import { workspaceSettingNamePrefix } from "../v1";
export enum WorkspaceSettingKey {
/** BASIC - BASIC is the key for basic settings. */
BASIC = "BASIC",
/** GENERAL - GENERAL is the key for general settings. */
GENERAL = "GENERAL",
/** STORAGE - STORAGE is the key for storage settings. */
STORAGE = "STORAGE",
/** MEMO_RELATED - MEMO_RELATED is the key for memo related settings. */
MEMO_RELATED = "MEMO_RELATED",
}
class LocalState { class LocalState {
locale: string = "en"; locale: string = "en";
appearance: string = "system"; appearance: string = "system";
......
This diff is collapsed.
This diff is collapsed.
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
// versions:
// protoc-gen-ts_proto v2.6.1
// protoc unknown
// source: api/v1/common.proto
/* eslint-disable */
import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
export const protobufPackage = "memos.api.v1";
export enum State {
STATE_UNSPECIFIED = "STATE_UNSPECIFIED",
NORMAL = "NORMAL",
ARCHIVED = "ARCHIVED",
UNRECOGNIZED = "UNRECOGNIZED",
}
export function stateFromJSON(object: any): State {
switch (object) {
case 0:
case "STATE_UNSPECIFIED":
return State.STATE_UNSPECIFIED;
case 1:
case "NORMAL":
return State.NORMAL;
case 2:
case "ARCHIVED":
return State.ARCHIVED;
case -1:
case "UNRECOGNIZED":
default:
return State.UNRECOGNIZED;
}
}
export function stateToNumber(object: State): number {
switch (object) {
case State.STATE_UNSPECIFIED:
return 0;
case State.NORMAL:
return 1;
case State.ARCHIVED:
return 2;
case State.UNRECOGNIZED:
default:
return -1;
}
}
export enum Direction {
DIRECTION_UNSPECIFIED = "DIRECTION_UNSPECIFIED",
ASC = "ASC",
DESC = "DESC",
UNRECOGNIZED = "UNRECOGNIZED",
}
export function directionFromJSON(object: any): Direction {
switch (object) {
case 0:
case "DIRECTION_UNSPECIFIED":
return Direction.DIRECTION_UNSPECIFIED;
case 1:
case "ASC":
return Direction.ASC;
case 2:
case "DESC":
return Direction.DESC;
case -1:
case "UNRECOGNIZED":
default:
return Direction.UNRECOGNIZED;
}
}
export function directionToNumber(object: Direction): number {
switch (object) {
case Direction.DIRECTION_UNSPECIFIED:
return 0;
case Direction.ASC:
return 1;
case Direction.DESC:
return 2;
case Direction.UNRECOGNIZED:
default:
return -1;
}
}
/** Used internally for obfuscating the page token. */
export interface PageToken {
limit: number;
offset: number;
}
function createBasePageToken(): PageToken {
return { limit: 0, offset: 0 };
}
export const PageToken: MessageFns<PageToken> = {
encode(message: PageToken, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
if (message.limit !== 0) {
writer.uint32(8).int32(message.limit);
}
if (message.offset !== 0) {
writer.uint32(16).int32(message.offset);
}
return writer;
},
decode(input: BinaryReader | Uint8Array, length?: number): PageToken {
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
let end = length === undefined ? reader.len : reader.pos + length;
const message = createBasePageToken();
while (reader.pos < end) {
const tag = reader.uint32();
switch (tag >>> 3) {
case 1: {
if (tag !== 8) {
break;
}
message.limit = reader.int32();
continue;
}
case 2: {
if (tag !== 16) {
break;
}
message.offset = reader.int32();
continue;
}
}
if ((tag & 7) === 4 || tag === 0) {
break;
}
reader.skip(tag & 7);
}
return message;
},
create(base?: DeepPartial<PageToken>): PageToken {
return PageToken.fromPartial(base ?? {});
},
fromPartial(object: DeepPartial<PageToken>): PageToken {
const message = createBasePageToken();
message.limit = object.limit ?? 0;
message.offset = object.offset ?? 0;
return message;
},
};
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
export type DeepPartial<T> = T extends Builtin ? T
: T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>
: T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
: Partial<T>;
export interface MessageFns<T> {
encode(message: T, writer?: BinaryWriter): BinaryWriter;
decode(input: BinaryReader | Uint8Array, length?: number): T;
create(base?: DeepPartial<T>): T;
fromPartial(object: DeepPartial<T>): T;
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
// versions:
// protoc-gen-ts_proto v2.6.1
// protoc unknown
// source: api/v1/reaction_service.proto
/* eslint-disable */
import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
export const protobufPackage = "memos.api.v1";
export interface Reaction {
id: number;
/**
* The name of the creator.
* Format: users/{user}
*/
creator: string;
/**
* The content identifier.
* For memo, it should be the `Memo.name`.
*/
contentId: string;
reactionType: string;
}
function createBaseReaction(): Reaction {
return { id: 0, creator: "", contentId: "", reactionType: "" };
}
export const Reaction: MessageFns<Reaction> = {
encode(message: Reaction, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
if (message.id !== 0) {
writer.uint32(8).int32(message.id);
}
if (message.creator !== "") {
writer.uint32(18).string(message.creator);
}
if (message.contentId !== "") {
writer.uint32(26).string(message.contentId);
}
if (message.reactionType !== "") {
writer.uint32(34).string(message.reactionType);
}
return writer;
},
decode(input: BinaryReader | Uint8Array, length?: number): Reaction {
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
let end = length === undefined ? reader.len : reader.pos + length;
const message = createBaseReaction();
while (reader.pos < end) {
const tag = reader.uint32();
switch (tag >>> 3) {
case 1: {
if (tag !== 8) {
break;
}
message.id = reader.int32();
continue;
}
case 2: {
if (tag !== 18) {
break;
}
message.creator = reader.string();
continue;
}
case 3: {
if (tag !== 26) {
break;
}
message.contentId = reader.string();
continue;
}
case 4: {
if (tag !== 34) {
break;
}
message.reactionType = reader.string();
continue;
}
}
if ((tag & 7) === 4 || tag === 0) {
break;
}
reader.skip(tag & 7);
}
return message;
},
create(base?: DeepPartial<Reaction>): Reaction {
return Reaction.fromPartial(base ?? {});
},
fromPartial(object: DeepPartial<Reaction>): Reaction {
const message = createBaseReaction();
message.id = object.id ?? 0;
message.creator = object.creator ?? "";
message.contentId = object.contentId ?? "";
message.reactionType = object.reactionType ?? "";
return message;
},
};
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
export type DeepPartial<T> = T extends Builtin ? T
: T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>
: T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
: Partial<T>;
export interface MessageFns<T> {
encode(message: T, writer?: BinaryWriter): BinaryWriter;
decode(input: BinaryReader | Uint8Array, length?: number): T;
create(base?: DeepPartial<T>): T;
fromPartial(object: DeepPartial<T>): T;
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
// versions:
// protoc-gen-ts_proto v2.6.1
// protoc unknown
// source: api/v1/workspace_service.proto
/* eslint-disable */
import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
export const protobufPackage = "memos.api.v1";
export interface WorkspaceProfile {
/**
* The name of instance owner.
* Format: users/{user}
*/
owner: string;
/** version is the current version of instance */
version: string;
/** mode is the instance mode (e.g. "prod", "dev" or "demo"). */
mode: string;
/** instance_url is the URL of the instance. */
instanceUrl: string;
}
export interface GetWorkspaceProfileRequest {
}
function createBaseWorkspaceProfile(): WorkspaceProfile {
return { owner: "", version: "", mode: "", instanceUrl: "" };
}
export const WorkspaceProfile: MessageFns<WorkspaceProfile> = {
encode(message: WorkspaceProfile, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
if (message.owner !== "") {
writer.uint32(10).string(message.owner);
}
if (message.version !== "") {
writer.uint32(18).string(message.version);
}
if (message.mode !== "") {
writer.uint32(26).string(message.mode);
}
if (message.instanceUrl !== "") {
writer.uint32(50).string(message.instanceUrl);
}
return writer;
},
decode(input: BinaryReader | Uint8Array, length?: number): WorkspaceProfile {
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
let end = length === undefined ? reader.len : reader.pos + length;
const message = createBaseWorkspaceProfile();
while (reader.pos < end) {
const tag = reader.uint32();
switch (tag >>> 3) {
case 1: {
if (tag !== 10) {
break;
}
message.owner = reader.string();
continue;
}
case 2: {
if (tag !== 18) {
break;
}
message.version = reader.string();
continue;
}
case 3: {
if (tag !== 26) {
break;
}
message.mode = reader.string();
continue;
}
case 6: {
if (tag !== 50) {
break;
}
message.instanceUrl = reader.string();
continue;
}
}
if ((tag & 7) === 4 || tag === 0) {
break;
}
reader.skip(tag & 7);
}
return message;
},
create(base?: DeepPartial<WorkspaceProfile>): WorkspaceProfile {
return WorkspaceProfile.fromPartial(base ?? {});
},
fromPartial(object: DeepPartial<WorkspaceProfile>): WorkspaceProfile {
const message = createBaseWorkspaceProfile();
message.owner = object.owner ?? "";
message.version = object.version ?? "";
message.mode = object.mode ?? "";
message.instanceUrl = object.instanceUrl ?? "";
return message;
},
};
function createBaseGetWorkspaceProfileRequest(): GetWorkspaceProfileRequest {
return {};
}
export const GetWorkspaceProfileRequest: MessageFns<GetWorkspaceProfileRequest> = {
encode(_: GetWorkspaceProfileRequest, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
return writer;
},
decode(input: BinaryReader | Uint8Array, length?: number): GetWorkspaceProfileRequest {
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
let end = length === undefined ? reader.len : reader.pos + length;
const message = createBaseGetWorkspaceProfileRequest();
while (reader.pos < end) {
const tag = reader.uint32();
switch (tag >>> 3) {
}
if ((tag & 7) === 4 || tag === 0) {
break;
}
reader.skip(tag & 7);
}
return message;
},
create(base?: DeepPartial<GetWorkspaceProfileRequest>): GetWorkspaceProfileRequest {
return GetWorkspaceProfileRequest.fromPartial(base ?? {});
},
fromPartial(_: DeepPartial<GetWorkspaceProfileRequest>): GetWorkspaceProfileRequest {
const message = createBaseGetWorkspaceProfileRequest();
return message;
},
};
export type WorkspaceServiceDefinition = typeof WorkspaceServiceDefinition;
export const WorkspaceServiceDefinition = {
name: "WorkspaceService",
fullName: "memos.api.v1.WorkspaceService",
methods: {
/** GetWorkspaceProfile returns the workspace profile. */
getWorkspaceProfile: {
name: "GetWorkspaceProfile",
requestType: GetWorkspaceProfileRequest,
requestStream: false,
responseType: WorkspaceProfile,
responseStream: false,
options: {
_unknownFields: {
578365826: [
new Uint8Array([
27,
18,
25,
47,
97,
112,
105,
47,
118,
49,
47,
119,
111,
114,
107,
115,
112,
97,
99,
101,
47,
112,
114,
111,
102,
105,
108,
101,
]),
],
},
},
},
},
} as const;
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
export type DeepPartial<T> = T extends Builtin ? T
: T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>
: T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
: Partial<T>;
export interface MessageFns<T> {
encode(message: T, writer?: BinaryWriter): BinaryWriter;
decode(input: BinaryReader | Uint8Array, length?: number): T;
create(base?: DeepPartial<T>): T;
fromPartial(object: DeepPartial<T>): T;
}
This diff is collapsed.
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
// versions:
// protoc-gen-ts_proto v2.6.1
// protoc unknown
// source: google/api/annotations.proto
/* eslint-disable */
export const protobufPackage = "google.api";
This diff is collapsed.
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
// versions:
// protoc-gen-ts_proto v2.6.1
// protoc unknown
// source: google/api/field_behavior.proto
/* eslint-disable */
export const protobufPackage = "google.api";
/**
* An indicator of the behavior of a given field (for example, that a field
* is required in requests, or given as output but ignored as input).
* This **does not** change the behavior in protocol buffers itself; it only
* denotes the behavior and may affect how API tooling handles the field.
*
* Note: This enum **may** receive new values in the future.
*/
export enum FieldBehavior {
/** FIELD_BEHAVIOR_UNSPECIFIED - Conventional default for enums. Do not use this. */
FIELD_BEHAVIOR_UNSPECIFIED = "FIELD_BEHAVIOR_UNSPECIFIED",
/**
* OPTIONAL - Specifically denotes a field as optional.
* While all fields in protocol buffers are optional, this may be specified
* for emphasis if appropriate.
*/
OPTIONAL = "OPTIONAL",
/**
* REQUIRED - Denotes a field as required.
* This indicates that the field **must** be provided as part of the request,
* and failure to do so will cause an error (usually `INVALID_ARGUMENT`).
*/
REQUIRED = "REQUIRED",
/**
* OUTPUT_ONLY - Denotes a field as output only.
* This indicates that the field is provided in responses, but including the
* field in a request does nothing (the server *must* ignore it and
* *must not* throw an error as a result of the field's presence).
*/
OUTPUT_ONLY = "OUTPUT_ONLY",
/**
* INPUT_ONLY - Denotes a field as input only.
* This indicates that the field is provided in requests, and the
* corresponding field is not included in output.
*/
INPUT_ONLY = "INPUT_ONLY",
/**
* IMMUTABLE - Denotes a field as immutable.
* This indicates that the field may be set once in a request to create a
* resource, but may not be changed thereafter.
*/
IMMUTABLE = "IMMUTABLE",
/**
* UNORDERED_LIST - Denotes that a (repeated) field is an unordered list.
* This indicates that the service may provide the elements of the list
* in any arbitrary order, rather than the order the user originally
* provided. Additionally, the list's order may or may not be stable.
*/
UNORDERED_LIST = "UNORDERED_LIST",
/**
* NON_EMPTY_DEFAULT - Denotes that this field returns a non-empty default value if not set.
* This indicates that if the user provides the empty value in a request,
* a non-empty value will be returned. The user will not be aware of what
* non-empty value to expect.
*/
NON_EMPTY_DEFAULT = "NON_EMPTY_DEFAULT",
/**
* IDENTIFIER - Denotes that the field in a resource (a message annotated with
* google.api.resource) is used in the resource name to uniquely identify the
* resource. For AIP-compliant APIs, this should only be applied to the
* `name` field on the resource.
*
* This behavior should not be applied to references to other resources within
* the message.
*
* The identifier field of resources often have different field behavior
* depending on the request it is embedded in (e.g. for Create methods name
* is optional and unused, while for Update methods it is required). Instead
* of method-specific annotations, only `IDENTIFIER` is required.
*/
IDENTIFIER = "IDENTIFIER",
UNRECOGNIZED = "UNRECOGNIZED",
}
export function fieldBehaviorFromJSON(object: any): FieldBehavior {
switch (object) {
case 0:
case "FIELD_BEHAVIOR_UNSPECIFIED":
return FieldBehavior.FIELD_BEHAVIOR_UNSPECIFIED;
case 1:
case "OPTIONAL":
return FieldBehavior.OPTIONAL;
case 2:
case "REQUIRED":
return FieldBehavior.REQUIRED;
case 3:
case "OUTPUT_ONLY":
return FieldBehavior.OUTPUT_ONLY;
case 4:
case "INPUT_ONLY":
return FieldBehavior.INPUT_ONLY;
case 5:
case "IMMUTABLE":
return FieldBehavior.IMMUTABLE;
case 6:
case "UNORDERED_LIST":
return FieldBehavior.UNORDERED_LIST;
case 7:
case "NON_EMPTY_DEFAULT":
return FieldBehavior.NON_EMPTY_DEFAULT;
case 8:
case "IDENTIFIER":
return FieldBehavior.IDENTIFIER;
case -1:
case "UNRECOGNIZED":
default:
return FieldBehavior.UNRECOGNIZED;
}
}
export function fieldBehaviorToNumber(object: FieldBehavior): number {
switch (object) {
case FieldBehavior.FIELD_BEHAVIOR_UNSPECIFIED:
return 0;
case FieldBehavior.OPTIONAL:
return 1;
case FieldBehavior.REQUIRED:
return 2;
case FieldBehavior.OUTPUT_ONLY:
return 3;
case FieldBehavior.INPUT_ONLY:
return 4;
case FieldBehavior.IMMUTABLE:
return 5;
case FieldBehavior.UNORDERED_LIST:
return 6;
case FieldBehavior.NON_EMPTY_DEFAULT:
return 7;
case FieldBehavior.IDENTIFIER:
return 8;
case FieldBehavior.UNRECOGNIZED:
default:
return -1;
}
}
This diff is collapsed.
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
// versions:
// protoc-gen-ts_proto v2.6.1
// protoc unknown
// source: google/api/httpbody.proto
/* eslint-disable */
import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
import { Any } from "../protobuf/any";
export const protobufPackage = "google.api";
/**
* Message that represents an arbitrary HTTP body. It should only be used for
* payload formats that can't be represented as JSON, such as raw binary or
* an HTML page.
*
* This message can be used both in streaming and non-streaming API methods in
* the request as well as the response.
*
* It can be used as a top-level request field, which is convenient if one
* wants to extract parameters from either the URL or HTTP template into the
* request fields and also want access to the raw HTTP body.
*
* Example:
*
* message GetResourceRequest {
* // A unique request id.
* string request_id = 1;
*
* // The raw HTTP body is bound to this field.
* google.api.HttpBody http_body = 2;
*
* }
*
* service ResourceService {
* rpc GetResource(GetResourceRequest)
* returns (google.api.HttpBody);
* rpc UpdateResource(google.api.HttpBody)
* returns (google.protobuf.Empty);
*
* }
*
* Example with streaming methods:
*
* service CaldavService {
* rpc GetCalendar(stream google.api.HttpBody)
* returns (stream google.api.HttpBody);
* rpc UpdateCalendar(stream google.api.HttpBody)
* returns (stream google.api.HttpBody);
*
* }
*
* Use of this type only changes how the request and response bodies are
* handled, all other features will continue to work unchanged.
*/
export interface HttpBody {
/** The HTTP Content-Type header value specifying the content type of the body. */
contentType: string;
/** The HTTP request/response body as raw binary. */
data: Uint8Array;
/**
* Application specific response metadata. Must be set in the first response
* for streaming APIs.
*/
extensions: Any[];
}
function createBaseHttpBody(): HttpBody {
return { contentType: "", data: new Uint8Array(0), extensions: [] };
}
export const HttpBody: MessageFns<HttpBody> = {
encode(message: HttpBody, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
if (message.contentType !== "") {
writer.uint32(10).string(message.contentType);
}
if (message.data.length !== 0) {
writer.uint32(18).bytes(message.data);
}
for (const v of message.extensions) {
Any.encode(v!, writer.uint32(26).fork()).join();
}
return writer;
},
decode(input: BinaryReader | Uint8Array, length?: number): HttpBody {
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
let end = length === undefined ? reader.len : reader.pos + length;
const message = createBaseHttpBody();
while (reader.pos < end) {
const tag = reader.uint32();
switch (tag >>> 3) {
case 1: {
if (tag !== 10) {
break;
}
message.contentType = reader.string();
continue;
}
case 2: {
if (tag !== 18) {
break;
}
message.data = reader.bytes();
continue;
}
case 3: {
if (tag !== 26) {
break;
}
message.extensions.push(Any.decode(reader, reader.uint32()));
continue;
}
}
if ((tag & 7) === 4 || tag === 0) {
break;
}
reader.skip(tag & 7);
}
return message;
},
create(base?: DeepPartial<HttpBody>): HttpBody {
return HttpBody.fromPartial(base ?? {});
},
fromPartial(object: DeepPartial<HttpBody>): HttpBody {
const message = createBaseHttpBody();
message.contentType = object.contentType ?? "";
message.data = object.data ?? new Uint8Array(0);
message.extensions = object.extensions?.map((e) => Any.fromPartial(e)) || [];
return message;
},
};
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
export type DeepPartial<T> = T extends Builtin ? T
: T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>
: T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
: Partial<T>;
export interface MessageFns<T> {
encode(message: T, writer?: BinaryWriter): BinaryWriter;
decode(input: BinaryReader | Uint8Array, length?: number): T;
create(base?: DeepPartial<T>): T;
fromPartial(object: DeepPartial<T>): T;
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment