@firecms/core 3.0.0-canary.129 → 3.0.0-canary.130

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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@firecms/core",
3
3
  "type": "module",
4
- "version": "3.0.0-canary.129",
4
+ "version": "3.0.0-canary.130",
5
5
  "description": "Awesome Firebase/Firestore-based headless open-source CMS",
6
6
  "funding": {
7
7
  "url": "https://github.com/sponsors/firecmsco"
@@ -46,9 +46,9 @@
46
46
  "./package.json": "./package.json"
47
47
  },
48
48
  "dependencies": {
49
- "@firecms/editor": "^3.0.0-canary.129",
50
- "@firecms/formex": "^3.0.0-canary.129",
51
- "@firecms/ui": "^3.0.0-canary.129",
49
+ "@firecms/editor": "^3.0.0-canary.130",
50
+ "@firecms/formex": "^3.0.0-canary.130",
51
+ "@firecms/ui": "^3.0.0-canary.130",
52
52
  "@hello-pangea/dnd": "^16.6.0",
53
53
  "@radix-ui/react-portal": "^1.1.1",
54
54
  "clsx": "^2.1.1",
@@ -100,7 +100,7 @@
100
100
  "dist",
101
101
  "src"
102
102
  ],
103
- "gitHead": "576f01afd4b2e604c7505e3317ab178b33916068",
103
+ "gitHead": "be19fe9ddedd3af96fe7593373f62fe5fe55a4c6",
104
104
  "publishConfig": {
105
105
  "access": "public"
106
106
  },
@@ -63,10 +63,10 @@ const innerElementType = forwardRef<HTMLDivElement, InnerElementProps>(({
63
63
 
64
64
  {customView && <div style={{
65
65
  position: "sticky",
66
- top: "56px",
66
+ top: "48px",
67
67
  flexGrow: 1,
68
- height: "calc(100% - 56px)",
69
- marginTop: "calc(56px - 100vh)",
68
+ height: "calc(100% - 48px)",
69
+ marginTop: "calc(48px - 100vh)",
70
70
  left: 0
71
71
  }}>{customView}</div>}
72
72
 
@@ -248,17 +248,7 @@ export const VirtualTable = React.memo<VirtualTableProps<any>>(
248
248
  if (onFilterUpdate) onFilterUpdate(newFilterValue);
249
249
  }, [checkFilterCombination, currentSort, onFilterUpdate, sortByProperty]);
250
250
 
251
- const buildEmptyView = useCallback(() => {
252
- if (loading)
253
- return <CircularProgressCenter/>;
254
- return <div
255
- className="flex flex-col overflow-auto items-center justify-center p-2 gap-2 h-full">
256
- <AssignmentIcon/>
257
- {emptyComponent}
258
- </div>;
259
- }, [emptyComponent, loading]);
260
-
261
- const empty = data?.length ?? 0 === 0;
251
+ const empty = !loading && (data?.length ?? 0) === 0;
262
252
  const customView = error
263
253
  ? <CenteredView maxWidth={"2xl"}
264
254
  className="flex flex-col gap-2">
@@ -270,7 +260,15 @@ export const VirtualTable = React.memo<VirtualTableProps<any>>(
270
260
  {error?.message && <SafeLinkRenderer text={error.message}/>}
271
261
 
272
262
  </CenteredView>
273
- : (empty ? buildEmptyView() : undefined);
263
+ : (empty
264
+ ? (loading
265
+ ? <CircularProgressCenter/>
266
+ : <div
267
+ className="flex flex-col overflow-auto items-center justify-center p-2 gap-2 h-full">
268
+ <AssignmentIcon/>
269
+ {emptyComponent}
270
+ </div>)
271
+ : undefined);
274
272
 
275
273
  const virtualListController = {
276
274
  data,
@@ -129,6 +129,8 @@ export function FireCMS<UserType extends User, EC extends EntityCollection>(prop
129
129
  );
130
130
  }
131
131
 
132
+ console.log("FireCMS render");
133
+
132
134
  return (
133
135
  <AnalyticsContext.Provider value={analyticsController}>
134
136
  <CustomizationControllerContext.Provider value={customizationController}>