Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
canifa_note
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vũ Hoàng Anh
canifa_note
Commits
f4d66753
Commit
f4d66753
authored
Aug 19, 2024
by
Steven
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
chore: add enable memo comment setting
parent
3c5aa41a
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
116 additions
and
69 deletions
+116
-69
apidocs.swagger.yaml
docs/apidocs.swagger.yaml
+3
-0
workspace_setting_service.proto
proto/api/v1/workspace_setting_service.proto
+2
-0
workspace_setting_service.pb.go
proto/gen/api/v1/workspace_setting_service.pb.go
+55
-43
workspace_setting.pb.go
proto/gen/store/workspace_setting.pb.go
+31
-20
workspace_setting.proto
proto/store/workspace_setting.proto
+2
-0
workspace_setting_service.go
server/router/api/v1/workspace_setting_service.go
+2
-0
MemoView.tsx
web/src/components/MemoView.tsx
+1
-1
MemoRelatedSettings.tsx
web/src/components/Settings/MemoRelatedSettings.tsx
+7
-0
MemoDetail.tsx
web/src/pages/MemoDetail.tsx
+13
-5
No files found.
docs/apidocs.swagger.yaml
View file @
f4d66753
...
@@ -2104,6 +2104,9 @@ definitions:
...
@@ -2104,6 +2104,9 @@ definitions:
enableLinkPreview
:
enableLinkPreview
:
type
:
boolean
type
:
boolean
description
:
enable_link_preview enables links preview.
description
:
enable_link_preview enables links preview.
enableComment
:
type
:
boolean
description
:
enable_comment enables comment.
apiv1WorkspaceSetting
:
apiv1WorkspaceSetting
:
type
:
object
type
:
object
properties
:
properties
:
...
...
proto/api/v1/workspace_setting_service.proto
View file @
f4d66753
...
@@ -98,6 +98,8 @@ message WorkspaceMemoRelatedSetting {
...
@@ -98,6 +98,8 @@ message WorkspaceMemoRelatedSetting {
bool
enable_double_click_edit
=
5
;
bool
enable_double_click_edit
=
5
;
// enable_link_preview enables links preview.
// enable_link_preview enables links preview.
bool
enable_link_preview
=
6
;
bool
enable_link_preview
=
6
;
// enable_comment enables comment.
bool
enable_comment
=
7
;
}
}
message
GetWorkspaceSettingRequest
{
message
GetWorkspaceSettingRequest
{
...
...
proto/gen/api/v1/workspace_setting_service.pb.go
View file @
f4d66753
...
@@ -430,6 +430,8 @@ type WorkspaceMemoRelatedSetting struct {
...
@@ -430,6 +430,8 @@ type WorkspaceMemoRelatedSetting struct {
EnableDoubleClickEdit
bool
`protobuf:"varint,5,opt,name=enable_double_click_edit,json=enableDoubleClickEdit,proto3" json:"enable_double_click_edit,omitempty"`
EnableDoubleClickEdit
bool
`protobuf:"varint,5,opt,name=enable_double_click_edit,json=enableDoubleClickEdit,proto3" json:"enable_double_click_edit,omitempty"`
// enable_link_preview enables links preview.
// enable_link_preview enables links preview.
EnableLinkPreview
bool
`protobuf:"varint,6,opt,name=enable_link_preview,json=enableLinkPreview,proto3" json:"enable_link_preview,omitempty"`
EnableLinkPreview
bool
`protobuf:"varint,6,opt,name=enable_link_preview,json=enableLinkPreview,proto3" json:"enable_link_preview,omitempty"`
// enable_comment enables comment.
EnableComment
bool
`protobuf:"varint,7,opt,name=enable_comment,json=enableComment,proto3" json:"enable_comment,omitempty"`
}
}
func
(
x
*
WorkspaceMemoRelatedSetting
)
Reset
()
{
func
(
x
*
WorkspaceMemoRelatedSetting
)
Reset
()
{
...
@@ -506,6 +508,13 @@ func (x *WorkspaceMemoRelatedSetting) GetEnableLinkPreview() bool {
...
@@ -506,6 +508,13 @@ func (x *WorkspaceMemoRelatedSetting) GetEnableLinkPreview() bool {
return
false
return
false
}
}
func
(
x
*
WorkspaceMemoRelatedSetting
)
GetEnableComment
()
bool
{
if
x
!=
nil
{
return
x
.
EnableComment
}
return
false
}
type
GetWorkspaceSettingRequest
struct
{
type
GetWorkspaceSettingRequest
struct
{
state
protoimpl
.
MessageState
state
protoimpl
.
MessageState
sizeCache
protoimpl
.
SizeCache
sizeCache
protoimpl
.
SizeCache
...
@@ -773,7 +782,7 @@ var file_api_v1_workspace_setting_service_proto_rawDesc = []byte{
...
@@ -773,7 +782,7 @@ var file_api_v1_workspace_setting_service_proto_rawDesc = []byte{
0x50
,
0x45
,
0x5f
,
0x55
,
0x4e
,
0x53
,
0x50
,
0x45
,
0x43
,
0x49
,
0x46
,
0x49
,
0x45
,
0x44
,
0x10
,
0x00
,
0x50
,
0x45
,
0x5f
,
0x55
,
0x4e
,
0x53
,
0x50
,
0x45
,
0x43
,
0x49
,
0x46
,
0x49
,
0x45
,
0x44
,
0x10
,
0x00
,
0x12
,
0x0c
,
0x0a
,
0x08
,
0x44
,
0x41
,
0x54
,
0x41
,
0x42
,
0x41
,
0x53
,
0x45
,
0x10
,
0x01
,
0x12
,
0x09
,
0x12
,
0x0c
,
0x0a
,
0x08
,
0x44
,
0x41
,
0x54
,
0x41
,
0x42
,
0x41
,
0x53
,
0x45
,
0x10
,
0x01
,
0x12
,
0x09
,
0x0a
,
0x05
,
0x4c
,
0x4f
,
0x43
,
0x41
,
0x4c
,
0x10
,
0x02
,
0x12
,
0x06
,
0x0a
,
0x02
,
0x53
,
0x33
,
0x10
,
0x0a
,
0x05
,
0x4c
,
0x4f
,
0x43
,
0x41
,
0x4c
,
0x10
,
0x02
,
0x12
,
0x06
,
0x0a
,
0x02
,
0x53
,
0x33
,
0x10
,
0x03
,
0x22
,
0x
df
,
0x02
,
0x0a
,
0x1b
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x4d
,
0x03
,
0x22
,
0x
86
,
0x03
,
0x0a
,
0x1b
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x52
,
0x65
,
0x6c
,
0x61
,
0x74
,
0x65
,
0x64
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x65
,
0x6d
,
0x6f
,
0x52
,
0x65
,
0x6c
,
0x61
,
0x74
,
0x65
,
0x64
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x12
,
0x3c
,
0x0a
,
0x1a
,
0x64
,
0x69
,
0x73
,
0x61
,
0x6c
,
0x6c
,
0x6f
,
0x77
,
0x5f
,
0x70
,
0x75
,
0x67
,
0x12
,
0x3c
,
0x0a
,
0x1a
,
0x64
,
0x69
,
0x73
,
0x61
,
0x6c
,
0x6c
,
0x6f
,
0x77
,
0x5f
,
0x70
,
0x75
,
0x62
,
0x6c
,
0x69
,
0x63
,
0x5f
,
0x76
,
0x69
,
0x73
,
0x69
,
0x62
,
0x69
,
0x6c
,
0x69
,
0x74
,
0x79
,
0x18
,
0x62
,
0x6c
,
0x69
,
0x63
,
0x5f
,
0x76
,
0x69
,
0x73
,
0x69
,
0x62
,
0x69
,
0x6c
,
0x69
,
0x74
,
0x79
,
0x18
,
...
@@ -795,49 +804,52 @@ var file_api_v1_workspace_setting_service_proto_rawDesc = []byte{
...
@@ -795,49 +804,52 @@ var file_api_v1_workspace_setting_service_proto_rawDesc = []byte{
0x64
,
0x69
,
0x74
,
0x12
,
0x2e
,
0x0a
,
0x13
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x5f
,
0x6c
,
0x69
,
0x64
,
0x69
,
0x74
,
0x12
,
0x2e
,
0x0a
,
0x13
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x5f
,
0x6c
,
0x69
,
0x6e
,
0x6b
,
0x5f
,
0x70
,
0x72
,
0x65
,
0x76
,
0x69
,
0x65
,
0x77
,
0x18
,
0x06
,
0x20
,
0x01
,
0x28
,
0x08
,
0x6e
,
0x6b
,
0x5f
,
0x70
,
0x72
,
0x65
,
0x76
,
0x69
,
0x65
,
0x77
,
0x18
,
0x06
,
0x20
,
0x01
,
0x28
,
0x08
,
0x52
,
0x11
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x4c
,
0x69
,
0x6e
,
0x6b
,
0x50
,
0x72
,
0x65
,
0x76
,
0x52
,
0x11
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x4c
,
0x69
,
0x6e
,
0x6b
,
0x50
,
0x72
,
0x65
,
0x76
,
0x69
,
0x65
,
0x77
,
0x22
,
0x36
,
0x0a
,
0x1a
,
0x47
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x69
,
0x65
,
0x77
,
0x12
,
0x25
,
0x0a
,
0x0e
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x5f
,
0x63
,
0x6f
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x6d
,
0x6d
,
0x65
,
0x6e
,
0x74
,
0x18
,
0x07
,
0x20
,
0x01
,
0x28
,
0x08
,
0x52
,
0x0d
,
0x65
,
0x6e
,
0x61
,
0x74
,
0x12
,
0x18
,
0x0a
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x42
,
0x62
,
0x6c
,
0x65
,
0x43
,
0x6f
,
0x6d
,
0x6d
,
0x65
,
0x6e
,
0x74
,
0x22
,
0x36
,
0x0a
,
0x1a
,
0x47
,
0x65
,
0x04
,
0xe2
,
0x41
,
0x01
,
0x02
,
0x52
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x22
,
0x56
,
0x0a
,
0x1a
,
0x53
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x67
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x18
,
0x0a
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x6e
,
0x67
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x38
,
0x0a
,
0x07
,
0x73
,
0x65
,
0x74
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x42
,
0x04
,
0xe2
,
0x41
,
0x01
,
0x02
,
0x52
,
0x04
,
0x6e
,
0x61
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x0b
,
0x32
,
0x1e
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6d
,
0x65
,
0x22
,
0x56
,
0x0a
,
0x1a
,
0x53
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x52
,
0x07
,
0x73
,
0x65
,
0x74
,
0x74
,
0x12
,
0x38
,
0x0a
,
0x07
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x69
,
0x6e
,
0x67
,
0x32
,
0xd9
,
0x02
,
0x0a
,
0x17
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x0b
,
0x32
,
0x1e
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x53
,
0x65
,
0x72
,
0x76
,
0x69
,
0x63
,
0x65
,
0x12
,
0x93
,
0x01
,
0x0a
,
0x13
,
0x47
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x12
,
0x28
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x47
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x1e
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x2e
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x22
,
0x32
,
0xda
,
0x41
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x25
,
0x67
,
0x52
,
0x07
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x32
,
0xd9
,
0x02
,
0x0a
,
0x17
,
0x57
,
0x12
,
0x23
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x77
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x53
,
0x61
,
0x63
,
0x65
,
0x2f
,
0x7b
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x65
,
0x72
,
0x76
,
0x69
,
0x63
,
0x65
,
0x12
,
0x93
,
0x01
,
0x0a
,
0x13
,
0x47
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x67
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x12
,
0xa7
,
0x01
,
0x0a
,
0x13
,
0x53
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x12
,
0x28
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x12
,
0x28
,
0x2e
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x47
,
0x65
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x53
,
0x65
,
0x74
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x67
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x1e
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x1e
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x22
,
0x32
,
0xda
,
0x41
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x22
,
0x46
,
0xda
,
0x41
,
0x07
,
0x73
,
0x65
,
0x74
,
0x74
,
0x65
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x25
,
0x12
,
0x23
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x69
,
0x6e
,
0x67
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x36
,
0x3a
,
0x07
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x2f
,
0x77
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x2f
,
0x7b
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x6e
,
0x67
,
0x32
,
0x2b
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x77
,
0x6f
,
0x72
,
0x6b
,
0x3d
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x12
,
0xa7
,
0x01
,
0x0a
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x2f
,
0x7b
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x2e
,
0x6e
,
0x13
,
0x53
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x42
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x12
,
0x28
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0xb4
,
0x01
,
0x0a
,
0x10
,
0x63
,
0x6f
,
0x6d
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x53
,
0x65
,
0x74
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x42
,
0x1c
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x1e
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x53
,
0x65
,
0x72
,
0x76
,
0x69
,
0x63
,
0x65
,
0x50
,
0x72
,
0x6f
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x57
,
0x6f
,
0x74
,
0x6f
,
0x50
,
0x01
,
0x5a
,
0x30
,
0x67
,
0x69
,
0x74
,
0x68
,
0x75
,
0x62
,
0x2e
,
0x63
,
0x6f
,
0x6d
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x22
,
0x46
,
0x2f
,
0x75
,
0x73
,
0x65
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0xda
,
0x41
,
0x07
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x36
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x2f
,
0x67
,
0x65
,
0x6e
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x3a
,
0x07
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x32
,
0x2b
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x3b
,
0x61
,
0x70
,
0x69
,
0x76
,
0x31
,
0xa2
,
0x02
,
0x03
,
0x4d
,
0x41
,
0x58
,
0xaa
,
0x02
,
0x0c
,
0x4d
,
0x76
,
0x31
,
0x2f
,
0x77
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x2f
,
0x7b
,
0x73
,
0x65
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x41
,
0x70
,
0x69
,
0x2e
,
0x56
,
0x31
,
0xca
,
0x02
,
0x0c
,
0x4d
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x2e
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x73
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x41
,
0x70
,
0x69
,
0x5c
,
0x56
,
0x31
,
0xe2
,
0x02
,
0x18
,
0x4d
,
0x65
,
0x6d
,
0x6e
,
0x67
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x42
,
0xb4
,
0x01
,
0x0a
,
0x10
,
0x63
,
0x6f
,
0x6d
,
0x2e
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x41
,
0x70
,
0x69
,
0x5c
,
0x56
,
0x31
,
0x5c
,
0x47
,
0x50
,
0x42
,
0x4d
,
0x65
,
0x74
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x42
,
0x1c
,
0x57
,
0x6f
,
0x72
,
0x61
,
0x64
,
0x61
,
0x74
,
0x61
,
0xea
,
0x02
,
0x0e
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x3a
,
0x3a
,
0x41
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x53
,
0x65
,
0x72
,
0x70
,
0x69
,
0x3a
,
0x3a
,
0x56
,
0x31
,
0x62
,
0x06
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x33
,
0x76
,
0x69
,
0x63
,
0x65
,
0x50
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x50
,
0x01
,
0x5a
,
0x30
,
0x67
,
0x69
,
0x74
,
0x68
,
0x75
,
0x62
,
0x2e
,
0x63
,
0x6f
,
0x6d
,
0x2f
,
0x75
,
0x73
,
0x65
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x2f
,
0x67
,
0x65
,
0x6e
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x3b
,
0x61
,
0x70
,
0x69
,
0x76
,
0x31
,
0xa2
,
0x02
,
0x03
,
0x4d
,
0x41
,
0x58
,
0xaa
,
0x02
,
0x0c
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x41
,
0x70
,
0x69
,
0x2e
,
0x56
,
0x31
,
0xca
,
0x02
,
0x0c
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x41
,
0x70
,
0x69
,
0x5c
,
0x56
,
0x31
,
0xe2
,
0x02
,
0x18
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x41
,
0x70
,
0x69
,
0x5c
,
0x56
,
0x31
,
0x5c
,
0x47
,
0x50
,
0x42
,
0x4d
,
0x65
,
0x74
,
0x61
,
0x64
,
0x61
,
0x74
,
0x61
,
0xea
,
0x02
,
0x0e
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x3a
,
0x3a
,
0x41
,
0x70
,
0x69
,
0x3a
,
0x3a
,
0x56
,
0x31
,
0x62
,
0x06
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x33
,
}
}
var
(
var
(
...
...
proto/gen/store/workspace_setting.pb.go
View file @
f4d66753
...
@@ -627,6 +627,8 @@ type WorkspaceMemoRelatedSetting struct {
...
@@ -627,6 +627,8 @@ type WorkspaceMemoRelatedSetting struct {
EnableDoubleClickEdit
bool
`protobuf:"varint,5,opt,name=enable_double_click_edit,json=enableDoubleClickEdit,proto3" json:"enable_double_click_edit,omitempty"`
EnableDoubleClickEdit
bool
`protobuf:"varint,5,opt,name=enable_double_click_edit,json=enableDoubleClickEdit,proto3" json:"enable_double_click_edit,omitempty"`
// enable_link_preview enables links preview.
// enable_link_preview enables links preview.
EnableLinkPreview
bool
`protobuf:"varint,6,opt,name=enable_link_preview,json=enableLinkPreview,proto3" json:"enable_link_preview,omitempty"`
EnableLinkPreview
bool
`protobuf:"varint,6,opt,name=enable_link_preview,json=enableLinkPreview,proto3" json:"enable_link_preview,omitempty"`
// enable_comment enables comment.
EnableComment
bool
`protobuf:"varint,7,opt,name=enable_comment,json=enableComment,proto3" json:"enable_comment,omitempty"`
}
}
func
(
x
*
WorkspaceMemoRelatedSetting
)
Reset
()
{
func
(
x
*
WorkspaceMemoRelatedSetting
)
Reset
()
{
...
@@ -703,6 +705,13 @@ func (x *WorkspaceMemoRelatedSetting) GetEnableLinkPreview() bool {
...
@@ -703,6 +705,13 @@ func (x *WorkspaceMemoRelatedSetting) GetEnableLinkPreview() bool {
return
false
return
false
}
}
func
(
x
*
WorkspaceMemoRelatedSetting
)
GetEnableComment
()
bool
{
if
x
!=
nil
{
return
x
.
EnableComment
}
return
false
}
var
File_store_workspace_setting_proto
protoreflect
.
FileDescriptor
var
File_store_workspace_setting_proto
protoreflect
.
FileDescriptor
var
file_store_workspace_setting_proto_rawDesc
=
[]
byte
{
var
file_store_workspace_setting_proto_rawDesc
=
[]
byte
{
...
@@ -796,7 +805,7 @@ var file_store_workspace_setting_proto_rawDesc = []byte{
...
@@ -796,7 +805,7 @@ var file_store_workspace_setting_proto_rawDesc = []byte{
0x6e
,
0x74
,
0x12
,
0x16
,
0x0a
,
0x06
,
0x72
,
0x65
,
0x67
,
0x69
,
0x6f
,
0x6e
,
0x18
,
0x04
,
0x20
,
0x01
,
0x6e
,
0x74
,
0x12
,
0x16
,
0x0a
,
0x06
,
0x72
,
0x65
,
0x67
,
0x69
,
0x6f
,
0x6e
,
0x18
,
0x04
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x06
,
0x72
,
0x65
,
0x67
,
0x69
,
0x6f
,
0x6e
,
0x12
,
0x16
,
0x0a
,
0x06
,
0x62
,
0x75
,
0x28
,
0x09
,
0x52
,
0x06
,
0x72
,
0x65
,
0x67
,
0x69
,
0x6f
,
0x6e
,
0x12
,
0x16
,
0x0a
,
0x06
,
0x62
,
0x75
,
0x63
,
0x6b
,
0x65
,
0x74
,
0x18
,
0x05
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x06
,
0x62
,
0x75
,
0x63
,
0x6b
,
0x63
,
0x6b
,
0x65
,
0x74
,
0x18
,
0x05
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x06
,
0x62
,
0x75
,
0x63
,
0x6b
,
0x65
,
0x74
,
0x22
,
0x
df
,
0x02
,
0x0a
,
0x1b
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x65
,
0x74
,
0x22
,
0x
86
,
0x03
,
0x0a
,
0x1b
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x52
,
0x65
,
0x6c
,
0x61
,
0x74
,
0x65
,
0x64
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x52
,
0x65
,
0x6c
,
0x61
,
0x74
,
0x65
,
0x64
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x12
,
0x3c
,
0x0a
,
0x1a
,
0x64
,
0x69
,
0x73
,
0x61
,
0x6c
,
0x6c
,
0x6f
,
0x77
,
0x5f
,
0x70
,
0x6e
,
0x67
,
0x12
,
0x3c
,
0x0a
,
0x1a
,
0x64
,
0x69
,
0x73
,
0x61
,
0x6c
,
0x6c
,
0x6f
,
0x77
,
0x5f
,
0x70
,
0x75
,
0x62
,
0x6c
,
0x69
,
0x63
,
0x5f
,
0x76
,
0x69
,
0x73
,
0x69
,
0x62
,
0x69
,
0x6c
,
0x69
,
0x74
,
0x79
,
0x75
,
0x62
,
0x6c
,
0x69
,
0x63
,
0x5f
,
0x76
,
0x69
,
0x73
,
0x69
,
0x62
,
0x69
,
0x6c
,
0x69
,
0x74
,
0x79
,
...
@@ -818,25 +827,27 @@ var file_store_workspace_setting_proto_rawDesc = []byte{
...
@@ -818,25 +827,27 @@ var file_store_workspace_setting_proto_rawDesc = []byte{
0x45
,
0x64
,
0x69
,
0x74
,
0x12
,
0x2e
,
0x0a
,
0x13
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x5f
,
0x6c
,
0x45
,
0x64
,
0x69
,
0x74
,
0x12
,
0x2e
,
0x0a
,
0x13
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x5f
,
0x6c
,
0x69
,
0x6e
,
0x6b
,
0x5f
,
0x70
,
0x72
,
0x65
,
0x76
,
0x69
,
0x65
,
0x77
,
0x18
,
0x06
,
0x20
,
0x01
,
0x28
,
0x69
,
0x6e
,
0x6b
,
0x5f
,
0x70
,
0x72
,
0x65
,
0x76
,
0x69
,
0x65
,
0x77
,
0x18
,
0x06
,
0x20
,
0x01
,
0x28
,
0x08
,
0x52
,
0x11
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x4c
,
0x69
,
0x6e
,
0x6b
,
0x50
,
0x72
,
0x65
,
0x08
,
0x52
,
0x11
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x4c
,
0x69
,
0x6e
,
0x6b
,
0x50
,
0x72
,
0x65
,
0x76
,
0x69
,
0x65
,
0x77
,
0x2a
,
0x73
,
0x0a
,
0x13
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x76
,
0x69
,
0x65
,
0x77
,
0x12
,
0x25
,
0x0a
,
0x0e
,
0x65
,
0x6e
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x5f
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x4b
,
0x65
,
0x79
,
0x12
,
0x25
,
0x0a
,
0x21
,
0x57
,
0x6f
,
0x6d
,
0x6d
,
0x65
,
0x6e
,
0x74
,
0x18
,
0x07
,
0x20
,
0x01
,
0x28
,
0x08
,
0x52
,
0x0d
,
0x65
,
0x6e
,
0x4f
,
0x52
,
0x4b
,
0x53
,
0x50
,
0x41
,
0x43
,
0x45
,
0x5f
,
0x53
,
0x45
,
0x54
,
0x54
,
0x49
,
0x4e
,
0x47
,
0x61
,
0x62
,
0x6c
,
0x65
,
0x43
,
0x6f
,
0x6d
,
0x6d
,
0x65
,
0x6e
,
0x74
,
0x2a
,
0x73
,
0x0a
,
0x13
,
0x57
,
0x5f
,
0x4b
,
0x45
,
0x59
,
0x5f
,
0x55
,
0x4e
,
0x53
,
0x50
,
0x45
,
0x43
,
0x49
,
0x46
,
0x49
,
0x45
,
0x44
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x4b
,
0x10
,
0x00
,
0x12
,
0x09
,
0x0a
,
0x05
,
0x42
,
0x41
,
0x53
,
0x49
,
0x43
,
0x10
,
0x01
,
0x12
,
0x0b
,
0x0a
,
0x65
,
0x79
,
0x12
,
0x25
,
0x0a
,
0x21
,
0x57
,
0x4f
,
0x52
,
0x4b
,
0x53
,
0x50
,
0x41
,
0x43
,
0x45
,
0x5f
,
0x07
,
0x47
,
0x45
,
0x4e
,
0x45
,
0x52
,
0x41
,
0x4c
,
0x10
,
0x02
,
0x12
,
0x0b
,
0x0a
,
0x07
,
0x53
,
0x54
,
0x53
,
0x45
,
0x54
,
0x54
,
0x49
,
0x4e
,
0x47
,
0x5f
,
0x4b
,
0x45
,
0x59
,
0x5f
,
0x55
,
0x4e
,
0x53
,
0x50
,
0x4f
,
0x52
,
0x41
,
0x47
,
0x45
,
0x10
,
0x03
,
0x12
,
0x10
,
0x0a
,
0x0c
,
0x4d
,
0x45
,
0x4d
,
0x4f
,
0x5f
,
0x45
,
0x43
,
0x49
,
0x46
,
0x49
,
0x45
,
0x44
,
0x10
,
0x00
,
0x12
,
0x09
,
0x0a
,
0x05
,
0x42
,
0x41
,
0x53
,
0x52
,
0x45
,
0x4c
,
0x41
,
0x54
,
0x45
,
0x44
,
0x10
,
0x04
,
0x42
,
0xa0
,
0x01
,
0x0a
,
0x0f
,
0x63
,
0x6f
,
0x49
,
0x43
,
0x10
,
0x01
,
0x12
,
0x0b
,
0x0a
,
0x07
,
0x47
,
0x45
,
0x4e
,
0x45
,
0x52
,
0x41
,
0x4c
,
0x10
,
0x6d
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x73
,
0x74
,
0x6f
,
0x72
,
0x65
,
0x42
,
0x15
,
0x57
,
0x02
,
0x12
,
0x0b
,
0x0a
,
0x07
,
0x53
,
0x54
,
0x4f
,
0x52
,
0x41
,
0x47
,
0x45
,
0x10
,
0x03
,
0x12
,
0x10
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x50
,
0x0a
,
0x0c
,
0x4d
,
0x45
,
0x4d
,
0x4f
,
0x5f
,
0x52
,
0x45
,
0x4c
,
0x41
,
0x54
,
0x45
,
0x44
,
0x10
,
0x04
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x50
,
0x01
,
0x5a
,
0x29
,
0x67
,
0x69
,
0x74
,
0x68
,
0x75
,
0x62
,
0x2e
,
0x63
,
0x42
,
0xa0
,
0x01
,
0x0a
,
0x0f
,
0x63
,
0x6f
,
0x6d
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x73
,
0x6f
,
0x6d
,
0x2f
,
0x75
,
0x73
,
0x65
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x74
,
0x6f
,
0x72
,
0x65
,
0x42
,
0x15
,
0x57
,
0x6f
,
0x72
,
0x6b
,
0x73
,
0x70
,
0x61
,
0x63
,
0x65
,
0x53
,
0x73
,
0x2f
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x2f
,
0x67
,
0x65
,
0x6e
,
0x2f
,
0x73
,
0x74
,
0x6f
,
0x72
,
0x65
,
0x74
,
0x74
,
0x69
,
0x6e
,
0x67
,
0x50
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x50
,
0x01
,
0x5a
,
0x29
,
0x67
,
0x65
,
0xa2
,
0x02
,
0x03
,
0x4d
,
0x53
,
0x58
,
0xaa
,
0x02
,
0x0b
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x69
,
0x74
,
0x68
,
0x75
,
0x62
,
0x2e
,
0x63
,
0x6f
,
0x6d
,
0x2f
,
0x75
,
0x73
,
0x65
,
0x6d
,
0x65
,
0x6d
,
0x53
,
0x74
,
0x6f
,
0x72
,
0x65
,
0xca
,
0x02
,
0x0b
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x53
,
0x74
,
0x6f
,
0x73
,
0x2f
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x2f
,
0x67
,
0x6f
,
0x72
,
0x65
,
0xe2
,
0x02
,
0x17
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x53
,
0x74
,
0x6f
,
0x72
,
0x65
,
0x6e
,
0x2f
,
0x73
,
0x74
,
0x6f
,
0x72
,
0x65
,
0xa2
,
0x02
,
0x03
,
0x4d
,
0x53
,
0x58
,
0xaa
,
0x02
,
0x65
,
0x5c
,
0x47
,
0x50
,
0x42
,
0x4d
,
0x65
,
0x74
,
0x61
,
0x64
,
0x61
,
0x74
,
0x61
,
0xea
,
0x02
,
0x0c
,
0x0b
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x53
,
0x74
,
0x6f
,
0x72
,
0x65
,
0xca
,
0x02
,
0x0b
,
0x4d
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x3a
,
0x3a
,
0x53
,
0x74
,
0x6f
,
0x72
,
0x65
,
0x62
,
0x06
,
0x70
,
0x72
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x53
,
0x74
,
0x6f
,
0x72
,
0x65
,
0xe2
,
0x02
,
0x17
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x74
,
0x6f
,
0x33
,
0x6f
,
0x73
,
0x5c
,
0x53
,
0x74
,
0x6f
,
0x72
,
0x65
,
0x5c
,
0x47
,
0x50
,
0x42
,
0x4d
,
0x65
,
0x74
,
0x61
,
0x64
,
0x61
,
0x74
,
0x61
,
0xea
,
0x02
,
0x0c
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x3a
,
0x3a
,
0x53
,
0x74
,
0x6f
,
0x72
,
0x65
,
0x62
,
0x06
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x33
,
}
}
var
(
var
(
...
...
proto/store/workspace_setting.proto
View file @
f4d66753
...
@@ -94,4 +94,6 @@ message WorkspaceMemoRelatedSetting {
...
@@ -94,4 +94,6 @@ message WorkspaceMemoRelatedSetting {
bool
enable_double_click_edit
=
5
;
bool
enable_double_click_edit
=
5
;
// enable_link_preview enables links preview.
// enable_link_preview enables links preview.
bool
enable_link_preview
=
6
;
bool
enable_link_preview
=
6
;
// enable_comment enables comment.
bool
enable_comment
=
7
;
}
}
server/router/api/v1/workspace_setting_service.go
View file @
f4d66753
...
@@ -222,6 +222,7 @@ func convertWorkspaceMemoRelatedSettingFromStore(setting *storepb.WorkspaceMemoR
...
@@ -222,6 +222,7 @@ func convertWorkspaceMemoRelatedSettingFromStore(setting *storepb.WorkspaceMemoR
EnableAutoCompact
:
setting
.
EnableAutoCompact
,
EnableAutoCompact
:
setting
.
EnableAutoCompact
,
EnableDoubleClickEdit
:
setting
.
EnableDoubleClickEdit
,
EnableDoubleClickEdit
:
setting
.
EnableDoubleClickEdit
,
EnableLinkPreview
:
setting
.
EnableLinkPreview
,
EnableLinkPreview
:
setting
.
EnableLinkPreview
,
EnableComment
:
setting
.
EnableComment
,
}
}
}
}
...
@@ -236,5 +237,6 @@ func convertWorkspaceMemoRelatedSettingToStore(setting *v1pb.WorkspaceMemoRelate
...
@@ -236,5 +237,6 @@ func convertWorkspaceMemoRelatedSettingToStore(setting *v1pb.WorkspaceMemoRelate
EnableAutoCompact
:
setting
.
EnableAutoCompact
,
EnableAutoCompact
:
setting
.
EnableAutoCompact
,
EnableDoubleClickEdit
:
setting
.
EnableDoubleClickEdit
,
EnableDoubleClickEdit
:
setting
.
EnableDoubleClickEdit
,
EnableLinkPreview
:
setting
.
EnableLinkPreview
,
EnableLinkPreview
:
setting
.
EnableLinkPreview
,
EnableComment
:
setting
.
EnableComment
,
}
}
}
}
web/src/components/MemoView.tsx
View file @
f4d66753
...
@@ -160,7 +160,7 @@ const MemoView: React.FC<Props> = (props: Props) => {
...
@@ -160,7 +160,7 @@ const MemoView: React.FC<Props> = (props: Props) => {
)
}
)
}
{
currentUser
&&
<
ReactionSelector
className=
"border-none w-auto h-auto"
memo=
{
memo
}
/>
}
{
currentUser
&&
<
ReactionSelector
className=
"border-none w-auto h-auto"
memo=
{
memo
}
/>
}
</
div
>
</
div
>
{
!
isInMemoDetailPage
&&
(
{
!
isInMemoDetailPage
&&
(
workspaceMemoRelatedSetting
.
enableComment
||
commentAmount
>
0
)
&&
(
<
Link
<
Link
className=
{
clsx
(
className=
{
clsx
(
"flex flex-row justify-start items-center hover:opacity-70"
,
"flex flex-row justify-start items-center hover:opacity-70"
,
...
...
web/src/components/Settings/MemoRelatedSettings.tsx
View file @
f4d66753
...
@@ -60,6 +60,13 @@ const MemoRelatedSettings = () => {
...
@@ -60,6 +60,13 @@ const MemoRelatedSettings = () => {
onChange=
{
(
event
)
=>
updatePartialSetting
({
enableLinkPreview
:
event
.
target
.
checked
})
}
onChange=
{
(
event
)
=>
updatePartialSetting
({
enableLinkPreview
:
event
.
target
.
checked
})
}
/>
/>
</
div
>
</
div
>
<
div
className=
"w-full flex flex-row justify-between items-center"
>
<
span
>
Enable memo comments
</
span
>
<
Switch
checked=
{
memoRelatedSetting
.
enableComment
}
onChange=
{
(
event
)
=>
updatePartialSetting
({
enableComment
:
event
.
target
.
checked
})
}
/>
</
div
>
<
div
className=
"w-full flex flex-row justify-between items-center"
>
<
div
className=
"w-full flex flex-row justify-between items-center"
>
<
span
>
{
t
(
"setting.system-section.enable-double-click-to-edit"
)
}
</
span
>
<
span
>
{
t
(
"setting.system-section.enable-double-click-to-edit"
)
}
</
span
>
<
Switch
<
Switch
...
...
web/src/pages/MemoDetail.tsx
View file @
f4d66753
...
@@ -12,9 +12,10 @@ import MobileHeader from "@/components/MobileHeader";
...
@@ -12,9 +12,10 @@ import MobileHeader from "@/components/MobileHeader";
import
useCurrentUser
from
"@/hooks/useCurrentUser"
;
import
useCurrentUser
from
"@/hooks/useCurrentUser"
;
import
useNavigateTo
from
"@/hooks/useNavigateTo"
;
import
useNavigateTo
from
"@/hooks/useNavigateTo"
;
import
useResponsiveWidth
from
"@/hooks/useResponsiveWidth"
;
import
useResponsiveWidth
from
"@/hooks/useResponsiveWidth"
;
import
{
useMemoStore
}
from
"@/store/v1"
;
import
{
useMemoStore
,
useWorkspaceSettingStore
}
from
"@/store/v1"
;
import
{
MemoRelation_Type
}
from
"@/types/proto/api/v1/memo_relation_service"
;
import
{
MemoRelation_Type
}
from
"@/types/proto/api/v1/memo_relation_service"
;
import
{
Memo
}
from
"@/types/proto/api/v1/memo_service"
;
import
{
Memo
}
from
"@/types/proto/api/v1/memo_service"
;
import
{
WorkspaceMemoRelatedSetting
,
WorkspaceSettingKey
}
from
"@/types/proto/store/workspace_setting"
;
import
{
useTranslate
}
from
"@/utils/i18n"
;
import
{
useTranslate
}
from
"@/utils/i18n"
;
const
MemoDetail
=
()
=>
{
const
MemoDetail
=
()
=>
{
...
@@ -22,15 +23,20 @@ const MemoDetail = () => {
...
@@ -22,15 +23,20 @@ const MemoDetail = () => {
const
{
md
}
=
useResponsiveWidth
();
const
{
md
}
=
useResponsiveWidth
();
const
params
=
useParams
();
const
params
=
useParams
();
const
navigateTo
=
useNavigateTo
();
const
navigateTo
=
useNavigateTo
();
const
workspaceSettingStore
=
useWorkspaceSettingStore
();
const
currentUser
=
useCurrentUser
();
const
currentUser
=
useCurrentUser
();
const
memoStore
=
useMemoStore
();
const
memoStore
=
useMemoStore
();
const
uid
=
params
.
uid
;
const
uid
=
params
.
uid
;
const
memo
=
memoStore
.
getMemoByUid
(
uid
||
""
);
const
memo
=
memoStore
.
getMemoByUid
(
uid
||
""
);
const
workspaceMemoRelatedSetting
=
WorkspaceMemoRelatedSetting
.
fromPartial
(
workspaceSettingStore
.
getWorkspaceSettingByKey
(
WorkspaceSettingKey
.
MEMO_RELATED
)?.
memoRelatedSetting
||
{},
);
const
[
parentMemo
,
setParentMemo
]
=
useState
<
Memo
|
undefined
>
(
undefined
);
const
[
parentMemo
,
setParentMemo
]
=
useState
<
Memo
|
undefined
>
(
undefined
);
const
[
showCommentEditor
,
setShowCommentEditor
]
=
useState
(
false
);
const
[
showCommentEditor
,
setShowCommentEditor
]
=
useState
(
false
);
const
commentRelations
=
const
commentRelations
=
memo
?.
relations
.
filter
((
relation
)
=>
relation
.
relatedMemo
===
memo
.
name
&&
relation
.
type
===
MemoRelation_Type
.
COMMENT
)
||
[];
memo
?.
relations
.
filter
((
relation
)
=>
relation
.
relatedMemo
===
memo
.
name
&&
relation
.
type
===
MemoRelation_Type
.
COMMENT
)
||
[];
const
comments
=
commentRelations
.
map
((
relation
)
=>
memoStore
.
getMemoByName
(
relation
.
memo
)).
filter
((
memo
)
=>
memo
)
as
any
as
Memo
[];
const
comments
=
commentRelations
.
map
((
relation
)
=>
memoStore
.
getMemoByName
(
relation
.
memo
)).
filter
((
memo
)
=>
memo
)
as
any
as
Memo
[];
const
showCreateCommentButton
=
workspaceMemoRelatedSetting
.
enableComment
&&
currentUser
;
// Prepare memo.
// Prepare memo.
useEffect
(()
=>
{
useEffect
(()
=>
{
...
@@ -112,7 +118,7 @@ const MemoDetail = () => {
...
@@ -112,7 +118,7 @@ const MemoDetail = () => {
</
h2
>
</
h2
>
<
div
className=
"relative mx-auto flex-grow w-full min-h-full flex flex-col justify-start items-start gap-y-1"
>
<
div
className=
"relative mx-auto flex-grow w-full min-h-full flex flex-col justify-start items-start gap-y-1"
>
{
comments
.
length
===
0
?
(
{
comments
.
length
===
0
?
(
currentUser
&&
(
showCreateCommentButton
&&
(
<
div
className=
"w-full flex flex-row justify-center items-center py-6"
>
<
div
className=
"w-full flex flex-row justify-center items-center py-6"
>
<
Button
<
Button
variant=
"plain"
variant=
"plain"
...
@@ -132,9 +138,11 @@ const MemoDetail = () => {
...
@@ -132,9 +138,11 @@ const MemoDetail = () => {
<
span
className=
"text-gray-400 text-sm"
>
{
t
(
"memo.comment.self"
)
}
</
span
>
<
span
className=
"text-gray-400 text-sm"
>
{
t
(
"memo.comment.self"
)
}
</
span
>
<
span
className=
"text-gray-400 text-sm ml-1"
>
(
{
comments
.
length
}
)
</
span
>
<
span
className=
"text-gray-400 text-sm ml-1"
>
(
{
comments
.
length
}
)
</
span
>
</
div
>
</
div
>
<
Button
variant=
"plain"
color=
"neutral"
onClick=
{
handleShowCommentEditor
}
>
{
showCreateCommentButton
&&
(
<
span
className=
"font-normal text-gray-500"
>
{
t
(
"memo.comment.write-a-comment"
)
}
</
span
>
<
Button
variant=
"plain"
color=
"neutral"
onClick=
{
handleShowCommentEditor
}
>
</
Button
>
<
span
className=
"font-normal text-gray-500"
>
{
t
(
"memo.comment.write-a-comment"
)
}
</
span
>
</
Button
>
)
}
</
div
>
</
div
>
{
comments
.
map
((
comment
)
=>
(
{
comments
.
map
((
comment
)
=>
(
<
MemoView
key=
{
`${comment.name}-${comment.displayTime}`
}
memo=
{
comment
}
showCreator
compact
/>
<
MemoView
key=
{
`${comment.name}-${comment.displayTime}`
}
memo=
{
comment
}
showCreator
compact
/>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment