@nocobase/plugin-graph-collection-manager 0.11.1-alpha.4 → 0.12.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (100) hide show
  1. package/client.d.ts +2 -3
  2. package/client.js +1 -1
  3. package/dist/client/index.js +65917 -0
  4. package/{lib → dist}/client/utils.d.ts +4 -3
  5. package/{lib → dist}/index.d.ts +1 -0
  6. package/dist/index.js +18 -0
  7. package/dist/locale/en-US.js +19 -0
  8. package/dist/locale/es-ES.js +19 -0
  9. package/dist/locale/fr-FR.js +19 -0
  10. package/dist/locale/ja-JP.js +17 -0
  11. package/dist/locale/pt-BR.js +19 -0
  12. package/dist/locale/zh-CN.js +20 -0
  13. package/dist/server/collections/graphPositions.js +26 -0
  14. package/dist/server/index.js +23 -0
  15. package/package.json +17 -28
  16. package/server.d.ts +2 -3
  17. package/server.js +1 -1
  18. package/lib/client/GraphCollectionProvider.js +0 -51
  19. package/lib/client/GraphCollectionShortcut.js +0 -169
  20. package/lib/client/GraphDrawPage.js +0 -1546
  21. package/lib/client/action-hooks.js +0 -318
  22. package/lib/client/components/AddCollectionAction.js +0 -58
  23. package/lib/client/components/AddFieldAction.js +0 -69
  24. package/lib/client/components/CollectionNodeProvder.js +0 -34
  25. package/lib/client/components/EditCollectionAction.js +0 -47
  26. package/lib/client/components/EditFieldAction.js +0 -63
  27. package/lib/client/components/Entity.js +0 -529
  28. package/lib/client/components/FieldSummary.js +0 -69
  29. package/lib/client/components/OverrideFieldAction.js +0 -64
  30. package/lib/client/components/ViewFieldAction.js +0 -45
  31. package/lib/client/components/ViewNode.js +0 -33
  32. package/lib/client/index.js +0 -27
  33. package/lib/client/locale/index.js +0 -4
  34. package/lib/client/style.js +0 -233
  35. package/lib/client/utils.js +0 -540
  36. package/lib/index.js +0 -13
  37. package/lib/locale/en-US.js +0 -22
  38. package/lib/locale/es-ES.js +0 -22
  39. package/lib/locale/fr-FR.js +0 -22
  40. package/lib/locale/ja-JP.js +0 -20
  41. package/lib/locale/pt-BR.js +0 -22
  42. package/lib/locale/zh-CN.js +0 -23
  43. package/lib/server/collections/graphPositions.js +0 -30
  44. package/lib/server/index.js +0 -37
  45. package/src/client/GraphCollectionProvider.tsx +0 -33
  46. package/src/client/GraphCollectionShortcut.tsx +0 -141
  47. package/src/client/GraphDrawPage.tsx +0 -1382
  48. package/src/client/action-hooks.tsx +0 -237
  49. package/src/client/components/AddCollectionAction.tsx +0 -28
  50. package/src/client/components/AddFieldAction.tsx +0 -37
  51. package/src/client/components/CollectionNodeProvder.tsx +0 -28
  52. package/src/client/components/EditCollectionAction.tsx +0 -21
  53. package/src/client/components/EditFieldAction.tsx +0 -30
  54. package/src/client/components/Entity.tsx +0 -495
  55. package/src/client/components/FieldSummary.tsx +0 -42
  56. package/src/client/components/OverrideFieldAction.tsx +0 -30
  57. package/src/client/components/ViewFieldAction.tsx +0 -12
  58. package/src/client/components/ViewNode.tsx +0 -22
  59. package/src/client/index.tsx +0 -10
  60. package/src/client/locale/index.ts +0 -3
  61. package/src/client/style.tsx +0 -227
  62. package/src/client/utils.tsx +0 -548
  63. package/src/index.ts +0 -1
  64. package/src/locale/en-US.ts +0 -15
  65. package/src/locale/es-ES.ts +0 -15
  66. package/src/locale/fr-FR.ts +0 -15
  67. package/src/locale/ja-JP.ts +0 -13
  68. package/src/locale/pt-BR.ts +0 -15
  69. package/src/locale/zh-CN.ts +0 -16
  70. package/src/server/actions/.gitkeep +0 -0
  71. package/src/server/collections/.gitkeep +0 -0
  72. package/src/server/collections/graphPositions.ts +0 -22
  73. package/src/server/index.ts +0 -13
  74. package/src/server/models/.gitkeep +0 -0
  75. package/src/server/repositories/.gitkeep +0 -0
  76. /package/{lib → dist}/client/GraphCollectionProvider.d.ts +0 -0
  77. /package/{lib → dist}/client/GraphCollectionShortcut.d.ts +0 -0
  78. /package/{lib → dist}/client/GraphDrawPage.d.ts +0 -0
  79. /package/{lib → dist}/client/action-hooks.d.ts +0 -0
  80. /package/{lib → dist}/client/components/AddCollectionAction.d.ts +0 -0
  81. /package/{lib → dist}/client/components/AddFieldAction.d.ts +0 -0
  82. /package/{lib → dist}/client/components/CollectionNodeProvder.d.ts +0 -0
  83. /package/{lib → dist}/client/components/EditCollectionAction.d.ts +0 -0
  84. /package/{lib → dist}/client/components/EditFieldAction.d.ts +0 -0
  85. /package/{lib → dist}/client/components/Entity.d.ts +0 -0
  86. /package/{lib → dist}/client/components/FieldSummary.d.ts +0 -0
  87. /package/{lib → dist}/client/components/OverrideFieldAction.d.ts +0 -0
  88. /package/{lib → dist}/client/components/ViewFieldAction.d.ts +0 -0
  89. /package/{lib → dist}/client/components/ViewNode.d.ts +0 -0
  90. /package/{lib → dist}/client/index.d.ts +0 -0
  91. /package/{lib → dist}/client/locale/index.d.ts +0 -0
  92. /package/{lib → dist}/client/style.d.ts +0 -0
  93. /package/{lib → dist}/locale/en-US.d.ts +0 -0
  94. /package/{lib → dist}/locale/es-ES.d.ts +0 -0
  95. /package/{lib → dist}/locale/fr-FR.d.ts +0 -0
  96. /package/{lib → dist}/locale/ja-JP.d.ts +0 -0
  97. /package/{lib → dist}/locale/pt-BR.d.ts +0 -0
  98. /package/{lib → dist}/locale/zh-CN.d.ts +0 -0
  99. /package/{lib → dist}/server/collections/graphPositions.d.ts +0 -0
  100. /package/{lib → dist}/server/index.d.ts +0 -0
@@ -1,227 +0,0 @@
1
- import { createStyles } from '@nocobase/client';
2
-
3
- const useStyles = createStyles(({ token, css }) => {
4
- return {
5
- // 右下角的小画布
6
- graphMinimap: css`
7
- .x6-widget-minimap {
8
- background-color: ${token.colorBgContainer};
9
- }
10
- `,
11
-
12
- addButtonClass: css`
13
- flex-shrink: 0;
14
- padding: 2em 0;
15
- `,
16
-
17
- entityContainer: css`
18
- .btn-del {
19
- border-color: transparent;
20
- background-color: ${token.colorErrorBg};
21
- color: ${token.colorErrorText};
22
- height: 20px;
23
- width: 20px;
24
- &:hover {
25
- background-color: ${token.colorErrorBgHover};
26
- }
27
- }
28
- .btn-add {
29
- background: ${token.colorSuccessBg};
30
- border-color: transparent;
31
- color: ${token.colorSuccessText};
32
- width: 20px;
33
- &:hover {
34
- background-color: ${token.colorSuccessBgHover};
35
- }
36
- }
37
- .btn-edit {
38
- color: ${token.colorText};
39
- display: flex;
40
- &:hover {
41
- background: ${token.colorBgTextHover};
42
- }
43
- }
44
- .btn-edit-in-head {
45
- border-color: transparent;
46
- color: ${token.colorText};
47
- height: 20px;
48
- width: 22px;
49
- margin: 0px 5px 4px;
50
- line-height: 25px;
51
- &:hover {
52
- background: ${token.colorBgTextHover};
53
- }
54
- }
55
- width: 250px;
56
- height: 100%;
57
- border-radius: ${token.borderRadiusLG}px;
58
- background-color: ${token.colorBgContainer};
59
- border: 0;
60
- overflow: hidden;
61
- &:hover {
62
- box-shadow: ${token.boxShadowTertiary};
63
- }
64
- .body {
65
- width: 100%;
66
- height: 100%;
67
- background-color: ${token.colorBgContainer};
68
- cursor: pointer;
69
- .morePorts {
70
- max-height: 300px;
71
- overflow: auto;
72
- }
73
- .body-item {
74
- display: inline-table;
75
- width: 100%;
76
- max-width: 250px;
77
- height: 40px;
78
- font-size: 14px;
79
- color: ${token.colorText};
80
- border-top: 1px solid ${token.colorBorderSecondary};
81
- text-overflow: ellipsis;
82
- display: flex;
83
- flex-direction: row;
84
- align-items: center;
85
- justify-content: space-between;
86
-
87
- .field-operator {
88
- display: none;
89
- }
90
- &:hover {
91
- .field-operator {
92
- display: flex;
93
- flex-direction: row-reverse;
94
- height: 32px;
95
- line-height: 32px;
96
- z-index: 999;
97
- cursor: pointer;
98
- text-align: right;
99
- background: ${token.colorBgContainer};
100
- padding-right: 3px;
101
- span {
102
- margin: 3px;
103
- margin-left: 4px;
104
- padding: 3px;
105
- height: 20px;
106
- width: 20px;
107
- }
108
- .btn-override {
109
- border-color: transparent;
110
- width: 20px;
111
- color: ${token.colorText};
112
- &:hover {
113
- background-color: ${token.colorBgTextHover};
114
- }
115
- }
116
- .btn-view {
117
- border-color: transparent;
118
- color: ${token.colorText};
119
- width: 20px;
120
- }
121
- .btn-view:hover {
122
- background: ${token.colorBgTextHover};
123
- }
124
- }
125
- .field_type {
126
- display: none;
127
- }
128
- }
129
-
130
- .name {
131
- text-overflow: ellipsis;
132
- white-space: nowrap;
133
- overflow: hidden;
134
- margin-left: 8px;
135
- }
136
-
137
- .type {
138
- color: ${token.colorTextTertiary};
139
- margin-right: 8px;
140
- text-overflow: ellipsis;
141
- white-space: nowrap;
142
- overflow: hidden;
143
- }
144
- }
145
- }
146
- `,
147
-
148
- headClass: css`
149
- height: 50px;
150
- font-size: 14px;
151
- font-weight: 500;
152
- display: flex;
153
- flex-direction: row;
154
- justify-content: space-between;
155
- align-items: center;
156
- background: ${token.colorFillAlter};
157
- color: ${token.colorTextHeading};
158
- padding: 0 8px;
159
- `,
160
-
161
- tableNameClass: css`
162
- max-width: 80%;
163
- overflow: hidden;
164
- text-overflow: ellipsis;
165
- white-space: nowrap;
166
- font-weight: 500;
167
- `,
168
-
169
- tableBtnClass: css`
170
- display: flex;
171
- span {
172
- cursor: pointer;
173
- }
174
- `,
175
-
176
- collectionPopoverClass: css`
177
- div.field-content {
178
- font-size: 14px;
179
- color: ${token.colorTextSecondary};
180
- opacity: 0.8;
181
- display: block;
182
- .field-type {
183
- color: ${token.colorText};
184
- float: right;
185
- }
186
- }
187
- `,
188
-
189
- collectionListClass: css`
190
- float: right;
191
- position: fixed;
192
- margin-top: 24px;
193
- right: 24px;
194
- z-index: 1000;
195
- .trigger {
196
- float: right;
197
- margin: 2px 4px;
198
- font-size: 16px;
199
- }
200
- .ant-input {
201
- margin: 4px;
202
- }
203
- .ant-menu-inline {
204
- border-top: 1px solid ${token.colorBorderSecondary};
205
- }
206
- .ant-layout-sider {
207
- margin-top: 24px;
208
- }
209
- .ant-menu-item {
210
- height: 32px;
211
- }
212
- .ant-btn {
213
- border: 0;
214
- }
215
- `,
216
-
217
- graphCollectionContainerClass: css`
218
- overflow: hidden;
219
- .x6-graph-scroller {
220
- height: calc(100vh) !important;
221
- width: calc(100vw) !important;
222
- }
223
- `,
224
- };
225
- });
226
-
227
- export default useStyles;