Last fixes
This commit is contained in:
@@ -25,8 +25,8 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@ant-design/icons": "^5.5.1",
|
"@ant-design/icons": "^5.5.1",
|
||||||
"@ant-design/v5-patch-for-react-19": "^1.0.3",
|
"@ant-design/v5-patch-for-react-19": "^1.0.3",
|
||||||
"@ng-org/orm": "0.1.2-alpha.19",
|
"@ng-org/orm": "0.1.2-alpha.21",
|
||||||
"@ng-org/web": "0.1.2-alpha.13",
|
"@ng-org/web": "0.1.2-alpha.14",
|
||||||
"@ng-org/refine-providers": "workspace:*",
|
"@ng-org/refine-providers": "workspace:*",
|
||||||
"@refinedev/antd": "^6.0.3",
|
"@refinedev/antd": "^6.0.3",
|
||||||
"@refinedev/cli": "^2.16.52",
|
"@refinedev/cli": "^2.16.52",
|
||||||
@@ -39,7 +39,7 @@
|
|||||||
"react-router": "^7.0.2"
|
"react-router": "^7.0.2"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@ng-org/shex-orm": "0.1.2-alpha.8",
|
"@ng-org/shex-orm": "0.1.2-alpha.9",
|
||||||
"@types/node": "^20",
|
"@types/node": "^20",
|
||||||
"@types/react": "^19.1.0",
|
"@types/react": "^19.1.0",
|
||||||
"@types/react-dom": "^19.1.0",
|
"@types/react-dom": "^19.1.0",
|
||||||
|
|||||||
@@ -29,8 +29,8 @@ export const PostList = () => {
|
|||||||
})}
|
})}
|
||||||
>
|
>
|
||||||
<Table.Column dataIndex="@graph" title="ID" render={shortenNuri} />
|
<Table.Column dataIndex="@graph" title="ID" render={shortenNuri} />
|
||||||
<Table.Column dataIndex="title" title="Title" />
|
<Table.Column dataIndex="title" sorter title="Title" />
|
||||||
<Table.Column dataIndex="content" title="Content" />
|
<Table.Column dataIndex="content" sorter title="Content" />
|
||||||
<Table.Column<Note>
|
<Table.Column<Note>
|
||||||
title="Actions"
|
title="Actions"
|
||||||
dataIndex="actions"
|
dataIndex="actions"
|
||||||
|
|||||||
+2
-2
@@ -96,13 +96,13 @@
|
|||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@refinedev/core": "^5.0.12",
|
"@refinedev/core": "^5.0.12",
|
||||||
"@ng-org/alien-deepsignals": "0.1.2-alpha.13",
|
"@ng-org/alien-deepsignals": "0.1.2-alpha.13",
|
||||||
"@ng-org/orm": "0.1.2-alpha.20",
|
"@ng-org/orm": "0.1.2-alpha.21",
|
||||||
"@ng-org/shex-orm": "0.1.2-alpha.9",
|
"@ng-org/shex-orm": "0.1.2-alpha.9",
|
||||||
"@ng-org/web": "0.1.2-alpha.14"
|
"@ng-org/web": "0.1.2-alpha.14"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@ng-org/alien-deepsignals": "0.1.2-alpha.13",
|
"@ng-org/alien-deepsignals": "0.1.2-alpha.13",
|
||||||
"@ng-org/orm": "0.1.2-alpha.20",
|
"@ng-org/orm": "0.1.2-alpha.21",
|
||||||
"@ng-org/shex-orm": "0.1.2-alpha.9",
|
"@ng-org/shex-orm": "0.1.2-alpha.9",
|
||||||
"@ng-org/web": "0.1.2-alpha.14",
|
"@ng-org/web": "0.1.2-alpha.14",
|
||||||
"@refinedev/core": "^5.0.12",
|
"@refinedev/core": "^5.0.12",
|
||||||
|
|||||||
Generated
+11
-80
@@ -12,8 +12,8 @@ importers:
|
|||||||
specifier: 0.1.2-alpha.13
|
specifier: 0.1.2-alpha.13
|
||||||
version: 0.1.2-alpha.13(react@19.2.7)
|
version: 0.1.2-alpha.13(react@19.2.7)
|
||||||
'@ng-org/orm':
|
'@ng-org/orm':
|
||||||
specifier: 0.1.2-alpha.20
|
specifier: 0.1.2-alpha.21
|
||||||
version: 0.1.2-alpha.20(react@19.2.7)
|
version: 0.1.2-alpha.21(react@19.2.7)
|
||||||
'@ng-org/shex-orm':
|
'@ng-org/shex-orm':
|
||||||
specifier: 0.1.2-alpha.9
|
specifier: 0.1.2-alpha.9
|
||||||
version: 0.1.2-alpha.9(typescript@5.9.3)
|
version: 0.1.2-alpha.9(typescript@5.9.3)
|
||||||
@@ -42,14 +42,14 @@ importers:
|
|||||||
specifier: ^1.0.3
|
specifier: ^1.0.3
|
||||||
version: 1.0.3(antd@5.29.3(react-dom@19.2.7(react@19.2.7))(react@19.2.7))(react-dom@19.2.7(react@19.2.7))(react@19.2.7)
|
version: 1.0.3(antd@5.29.3(react-dom@19.2.7(react@19.2.7))(react@19.2.7))(react-dom@19.2.7(react@19.2.7))(react@19.2.7)
|
||||||
'@ng-org/orm':
|
'@ng-org/orm':
|
||||||
specifier: 0.1.2-alpha.19
|
specifier: 0.1.2-alpha.21
|
||||||
version: 0.1.2-alpha.19(react@19.2.7)
|
version: 0.1.2-alpha.21(react@19.2.7)
|
||||||
'@ng-org/refine-providers':
|
'@ng-org/refine-providers':
|
||||||
specifier: workspace:*
|
specifier: workspace:*
|
||||||
version: link:../..
|
version: link:../..
|
||||||
'@ng-org/web':
|
'@ng-org/web':
|
||||||
specifier: 0.1.2-alpha.13
|
specifier: 0.1.2-alpha.14
|
||||||
version: 0.1.2-alpha.13
|
version: 0.1.2-alpha.14
|
||||||
'@refinedev/antd':
|
'@refinedev/antd':
|
||||||
specifier: ^6.0.3
|
specifier: ^6.0.3
|
||||||
version: 6.0.3(@refinedev/core@5.0.12(@tanstack/react-query@5.101.2(react@19.2.7))(@types/react-dom@19.2.3(@types/react@19.2.17))(@types/react@19.2.17)(react-dom@19.2.7(react@19.2.7))(react@19.2.7))(@types/react-dom@19.2.3(@types/react@19.2.17))(@types/react@19.2.17)(antd@5.29.3(react-dom@19.2.7(react@19.2.7))(react@19.2.7))(dayjs@1.11.21)(react-dom@19.2.7(react@19.2.7))(react@19.2.7)
|
version: 6.0.3(@refinedev/core@5.0.12(@tanstack/react-query@5.101.2(react@19.2.7))(@types/react-dom@19.2.3(@types/react@19.2.17))(@types/react@19.2.17)(react-dom@19.2.7(react@19.2.7))(react@19.2.7))(@types/react-dom@19.2.3(@types/react@19.2.17))(@types/react@19.2.17)(antd@5.29.3(react-dom@19.2.7(react@19.2.7))(react@19.2.7))(dayjs@1.11.21)(react-dom@19.2.7(react@19.2.7))(react@19.2.7)
|
||||||
@@ -79,8 +79,8 @@ importers:
|
|||||||
version: 7.18.1(react-dom@19.2.7(react@19.2.7))(react@19.2.7)
|
version: 7.18.1(react-dom@19.2.7(react@19.2.7))(react@19.2.7)
|
||||||
devDependencies:
|
devDependencies:
|
||||||
'@ng-org/shex-orm':
|
'@ng-org/shex-orm':
|
||||||
specifier: 0.1.2-alpha.8
|
specifier: 0.1.2-alpha.9
|
||||||
version: 0.1.2-alpha.8(typescript@5.9.3)
|
version: 0.1.2-alpha.9(typescript@5.9.3)
|
||||||
'@types/node':
|
'@types/node':
|
||||||
specifier: ^20
|
specifier: ^20
|
||||||
version: 20.19.43
|
version: 20.19.43
|
||||||
@@ -615,20 +615,6 @@ packages:
|
|||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [win32]
|
os: [win32]
|
||||||
|
|
||||||
'@ng-org/alien-deepsignals@0.1.2-alpha.12':
|
|
||||||
resolution: {integrity: sha512-STIfMLJvwNDnAIdi/wFToLtnZDjbf0PaeYfshfMal2HbYirSPFEBue393nlYKv9rLlCrqjYOBNeSBK9FO7/Qng==}
|
|
||||||
peerDependencies:
|
|
||||||
react: ^19.0.0 || ^18.0.0
|
|
||||||
svelte: ^5.0.0 || ^4.0.0
|
|
||||||
vue: ^3.0.0
|
|
||||||
peerDependenciesMeta:
|
|
||||||
react:
|
|
||||||
optional: true
|
|
||||||
svelte:
|
|
||||||
optional: true
|
|
||||||
vue:
|
|
||||||
optional: true
|
|
||||||
|
|
||||||
'@ng-org/alien-deepsignals@0.1.2-alpha.13':
|
'@ng-org/alien-deepsignals@0.1.2-alpha.13':
|
||||||
resolution: {integrity: sha512-yOEh/J+9IrCo8WDXTdZLxRcO9IHAczrUA4pjSD4BaZzmWhnCFE/amy/0PsAdh/yePurBrtQj3tG/y+hReM15Ew==}
|
resolution: {integrity: sha512-yOEh/J+9IrCo8WDXTdZLxRcO9IHAczrUA4pjSD4BaZzmWhnCFE/amy/0PsAdh/yePurBrtQj3tG/y+hReM15Ew==}
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
@@ -643,8 +629,8 @@ packages:
|
|||||||
vue:
|
vue:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@ng-org/orm@0.1.2-alpha.19':
|
'@ng-org/orm@0.1.2-alpha.21':
|
||||||
resolution: {integrity: sha512-wPDQ0OEitpoEKrvj4IJKIRxeTHr3X5+rApvZJOh54CNV1Q1b5MaT2XvyJ9YDvlgyUX2CxNkcmumV4k4ASmBXNA==}
|
resolution: {integrity: sha512-+Dtt9jEa+277wonExxqC1BHqVwvWhXeXM51zcGg2w+Mc6C1F74qaXMGYZT3CcWCQISGEMOWV3n2movP3yQ8xJA==}
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
react: ^19.0.0 || ^18.0.0
|
react: ^19.0.0 || ^18.0.0
|
||||||
svelte: ^5.0.0 || ^4.0.0
|
svelte: ^5.0.0 || ^4.0.0
|
||||||
@@ -657,35 +643,12 @@ packages:
|
|||||||
vue:
|
vue:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@ng-org/orm@0.1.2-alpha.20':
|
|
||||||
resolution: {integrity: sha512-T7lzAi2QRI0WWHMXab63zqvP7x6hCwQYzYWvZxfMWLYuwJVycLgnHP97gemPrBwXg+GEa2KZ9LqzLMR2bA3oVw==}
|
|
||||||
peerDependencies:
|
|
||||||
react: ^19.0.0 || ^18.0.0
|
|
||||||
svelte: ^5.0.0 || ^4.0.0
|
|
||||||
vue: ^3.0.0
|
|
||||||
peerDependenciesMeta:
|
|
||||||
react:
|
|
||||||
optional: true
|
|
||||||
svelte:
|
|
||||||
optional: true
|
|
||||||
vue:
|
|
||||||
optional: true
|
|
||||||
|
|
||||||
'@ng-org/shex-orm@0.1.2-alpha.8':
|
|
||||||
resolution: {integrity: sha512-jogxiLfUtI3WkuF5O3PPwRBRWylpapk/JlvElGUqZnEavXXlEMmEGbK3VwqMUsbp1pweNA0sEKIFLIk3Lzt2Gg==}
|
|
||||||
hasBin: true
|
|
||||||
peerDependencies:
|
|
||||||
typescript: ^4.9.0 || ^5.0.0 || ^6.0.0
|
|
||||||
|
|
||||||
'@ng-org/shex-orm@0.1.2-alpha.9':
|
'@ng-org/shex-orm@0.1.2-alpha.9':
|
||||||
resolution: {integrity: sha512-M69oIHrcjl24xKXIaiZjZ64rJvispAPIqn73asLPR73GWpEMvbiot/EN0vDkcfrbRy3cMEql36A9e1Nwv2csOA==}
|
resolution: {integrity: sha512-M69oIHrcjl24xKXIaiZjZ64rJvispAPIqn73asLPR73GWpEMvbiot/EN0vDkcfrbRy3cMEql36A9e1Nwv2csOA==}
|
||||||
hasBin: true
|
hasBin: true
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
typescript: ^4.9.0 || ^5.0.0 || ^6.0.0
|
typescript: ^4.9.0 || ^5.0.0 || ^6.0.0
|
||||||
|
|
||||||
'@ng-org/web@0.1.2-alpha.13':
|
|
||||||
resolution: {integrity: sha512-/xO0c+3NTphnws5Do2LDqgZWmAf+aNnYdChJKdU0dnp1U1iVSgi/y3yb8AYryf0v9sooj0aYJxt08B6DpirFMQ==}
|
|
||||||
|
|
||||||
'@ng-org/web@0.1.2-alpha.14':
|
'@ng-org/web@0.1.2-alpha.14':
|
||||||
resolution: {integrity: sha512-FPQ7kyngMhAXK/WJtZ6pkoEJwGcau6GaBH2nhjjYorMq7OG//I+zwghat90FsIeMrfYsps0+5Y0UrRqfxNdUXA==}
|
resolution: {integrity: sha512-FPQ7kyngMhAXK/WJtZ6pkoEJwGcau6GaBH2nhjjYorMq7OG//I+zwghat90FsIeMrfYsps0+5Y0UrRqfxNdUXA==}
|
||||||
|
|
||||||
@@ -4904,46 +4867,18 @@ snapshots:
|
|||||||
'@msgpackr-extract/msgpackr-extract-win32-x64@3.0.4':
|
'@msgpackr-extract/msgpackr-extract-win32-x64@3.0.4':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@ng-org/alien-deepsignals@0.1.2-alpha.12(react@19.2.7)':
|
|
||||||
dependencies:
|
|
||||||
alien-signals: 2.0.8
|
|
||||||
optionalDependencies:
|
|
||||||
react: 19.2.7
|
|
||||||
|
|
||||||
'@ng-org/alien-deepsignals@0.1.2-alpha.13(react@19.2.7)':
|
'@ng-org/alien-deepsignals@0.1.2-alpha.13(react@19.2.7)':
|
||||||
dependencies:
|
dependencies:
|
||||||
alien-signals: 2.0.8
|
alien-signals: 2.0.8
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
react: 19.2.7
|
react: 19.2.7
|
||||||
|
|
||||||
'@ng-org/orm@0.1.2-alpha.19(react@19.2.7)':
|
'@ng-org/orm@0.1.2-alpha.21(react@19.2.7)':
|
||||||
dependencies:
|
|
||||||
'@ng-org/alien-deepsignals': 0.1.2-alpha.12(react@19.2.7)
|
|
||||||
optionalDependencies:
|
|
||||||
react: 19.2.7
|
|
||||||
|
|
||||||
'@ng-org/orm@0.1.2-alpha.20(react@19.2.7)':
|
|
||||||
dependencies:
|
dependencies:
|
||||||
'@ng-org/alien-deepsignals': 0.1.2-alpha.13(react@19.2.7)
|
'@ng-org/alien-deepsignals': 0.1.2-alpha.13(react@19.2.7)
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
react: 19.2.7
|
react: 19.2.7
|
||||||
|
|
||||||
'@ng-org/shex-orm@0.1.2-alpha.8(typescript@5.9.3)':
|
|
||||||
dependencies:
|
|
||||||
'@ldo/traverser-shexj': 1.0.0-alpha.28
|
|
||||||
'@ldo/type-traverser': 1.0.0-alpha.28
|
|
||||||
'@shexjs/parser': 1.0.0-alpha.28
|
|
||||||
commander: 14.0.3
|
|
||||||
dts-dom: 3.6.0
|
|
||||||
ejs: 3.1.10
|
|
||||||
fs-extra: 10.1.0
|
|
||||||
jsonld2graphobject: 0.0.5
|
|
||||||
loading-cli: 1.1.2
|
|
||||||
prettier: 3.9.5
|
|
||||||
typescript: 5.9.3
|
|
||||||
transitivePeerDependencies:
|
|
||||||
- encoding
|
|
||||||
|
|
||||||
'@ng-org/shex-orm@0.1.2-alpha.9(typescript@5.9.3)':
|
'@ng-org/shex-orm@0.1.2-alpha.9(typescript@5.9.3)':
|
||||||
dependencies:
|
dependencies:
|
||||||
'@ldo/traverser-shexj': 1.0.0-alpha.28
|
'@ldo/traverser-shexj': 1.0.0-alpha.28
|
||||||
@@ -4960,10 +4895,6 @@ snapshots:
|
|||||||
transitivePeerDependencies:
|
transitivePeerDependencies:
|
||||||
- encoding
|
- encoding
|
||||||
|
|
||||||
'@ng-org/web@0.1.2-alpha.13':
|
|
||||||
dependencies:
|
|
||||||
async-proxy: 0.4.1
|
|
||||||
|
|
||||||
'@ng-org/web@0.1.2-alpha.14':
|
'@ng-org/web@0.1.2-alpha.14':
|
||||||
dependencies:
|
dependencies:
|
||||||
async-proxy: 0.4.1
|
async-proxy: 0.4.1
|
||||||
|
|||||||
@@ -1,10 +1,9 @@
|
|||||||
import { DataProvider } from "@refinedev/core";
|
import { DataProvider } from "@refinedev/core";
|
||||||
import { ng } from "@ng-org/web";
|
import { ng } from "@ng-org/web";
|
||||||
import { addIdToObject, isGraphKey, getSignalObject } from "./utils";
|
import { addIdToObject, isGraphKey, getSignalObject } from "./utils";
|
||||||
import { getObjects } from "./getObjects";
|
import { getObjects } from "@ng-org/orm";
|
||||||
import { DataProviderConfig } from "./types";
|
import { DataProviderConfig } from "./types";
|
||||||
|
|
||||||
|
|
||||||
const dataProvider = ({ shapeTypes, authProvider }: DataProviderConfig) : DataProvider => ({
|
const dataProvider = ({ shapeTypes, authProvider }: DataProviderConfig) : DataProvider => ({
|
||||||
// Note: the `pagination` parameter is not used, because the ORM handle currently handle pagination within the ORM objects.
|
// Note: the `pagination` parameter is not used, because the ORM handle currently handle pagination within the ORM objects.
|
||||||
// In the future, it may use offset-based or cursor-based pagination, which would work with this stateless data provider.
|
// In the future, it may use offset-based or cursor-based pagination, which would work with this stateless data provider.
|
||||||
@@ -29,9 +28,11 @@ const dataProvider = ({ shapeTypes, authProvider }: DataProviderConfig) : DataPr
|
|||||||
: undefined
|
: undefined
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const objectsArray = [...objects];
|
||||||
|
|
||||||
return {
|
return {
|
||||||
data: [...objects].map(addIdToObject) as any,
|
data: objectsArray.map(addIdToObject) as any,
|
||||||
total: objects.size,
|
total: objectsArray.length,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
create: async ({ resource, variables, meta }) => {
|
create: async ({ resource, variables, meta }) => {
|
||||||
|
|||||||
@@ -1,26 +0,0 @@
|
|||||||
import type { BaseType, ShapeType } from "@ng-org/shex-orm";
|
|
||||||
import { RdfOrmSubscription, normalizeConf } from "@ng-org/orm";
|
|
||||||
import type { RdfOrmConfig } from "@ng-org/orm/all";
|
|
||||||
import { RAW_KEY } from "@ng-org/alien-deepsignals";
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Local copy of `@ng-org/orm`'s `getObjects` until the fix is released
|
|
||||||
* https://git.nextgraph.org/NextGraph/nextgraph-rs/commit/02cb531f53dfb7a64014917e9b38cd5134efcdd8
|
|
||||||
*/
|
|
||||||
export async function getObjects<T extends BaseType>(
|
|
||||||
shapeType: ShapeType<T>,
|
|
||||||
config: Omit<RdfOrmConfig<T>, "pageSize" | "maxActivePages">
|
|
||||||
) {
|
|
||||||
const connection = RdfOrmSubscription.getOrCreate(
|
|
||||||
shapeType,
|
|
||||||
normalizeConf(config) as any
|
|
||||||
);
|
|
||||||
await connection.readyPromise;
|
|
||||||
|
|
||||||
setTimeout(() => {
|
|
||||||
connection.close();
|
|
||||||
}, 1_000);
|
|
||||||
|
|
||||||
return structuredClone(connection.signalObject[RAW_KEY]);
|
|
||||||
}
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user