dn-react-router-toolkit 0.3.2 → 0.3.4
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/README.md +1 -1
- package/dist/client/env.d.mts +3 -0
- package/dist/client/env.d.ts +3 -0
- package/dist/client/env.js +35 -0
- package/dist/client/env.mjs +10 -0
- package/dist/client/env_loader.d.mts +7 -0
- package/dist/client/env_loader.d.ts +7 -0
- package/dist/client/{client_env.js → env_loader.js} +13 -12
- package/dist/client/env_loader.mjs +20 -0
- package/dist/client/index.d.mts +2 -1
- package/dist/client/index.d.ts +2 -1
- package/dist/client/index.js +20 -9
- package/dist/client/index.mjs +18 -8
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/package.json +123 -123
- package/tsup.config.ts +9 -9
- package/dist/client/client_env.d.mts +0 -7
- package/dist/client/client_env.d.ts +0 -7
- package/dist/client/client_env.mjs +0 -19
package/README.md
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
# Dndnsoft React Router Toolkit
|
|
1
|
+
# Dndnsoft React Router Toolkit
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/client/env.ts
|
|
21
|
+
var env_exports = {};
|
|
22
|
+
__export(env_exports, {
|
|
23
|
+
env: () => env
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(env_exports);
|
|
26
|
+
function env(key) {
|
|
27
|
+
if (typeof window === "undefined") {
|
|
28
|
+
return process.env[key] || "";
|
|
29
|
+
}
|
|
30
|
+
return window.ENV?.[key] || "";
|
|
31
|
+
}
|
|
32
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
33
|
+
0 && (module.exports = {
|
|
34
|
+
env
|
|
35
|
+
});
|
|
@@ -27,28 +27,29 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
27
27
|
));
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
29
|
|
|
30
|
-
// src/client/
|
|
31
|
-
var
|
|
32
|
-
__export(
|
|
33
|
-
|
|
30
|
+
// src/client/env_loader.tsx
|
|
31
|
+
var env_loader_exports = {};
|
|
32
|
+
__export(env_loader_exports, {
|
|
33
|
+
EnvLoader: () => EnvLoader
|
|
34
34
|
});
|
|
35
|
-
module.exports = __toCommonJS(
|
|
35
|
+
module.exports = __toCommonJS(env_loader_exports);
|
|
36
36
|
var import_react = __toESM(require("react"));
|
|
37
37
|
var import_react_router = require("react-router");
|
|
38
|
-
function
|
|
38
|
+
function EnvLoader({ dataKey = "ENV" }) {
|
|
39
39
|
const data = (0, import_react_router.useRouteLoaderData)("root");
|
|
40
|
-
|
|
40
|
+
if (!data) {
|
|
41
|
+
return;
|
|
42
|
+
}
|
|
43
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
41
44
|
"script",
|
|
42
45
|
{
|
|
43
46
|
dangerouslySetInnerHTML: {
|
|
44
|
-
__html: `window.
|
|
45
|
-
env: data?.[dataKey]
|
|
46
|
-
})}`
|
|
47
|
+
__html: `window.ENV = ${JSON.stringify(data[dataKey])};`
|
|
47
48
|
}
|
|
48
49
|
}
|
|
49
|
-
)
|
|
50
|
+
);
|
|
50
51
|
}
|
|
51
52
|
// Annotate the CommonJS export names for ESM import in node:
|
|
52
53
|
0 && (module.exports = {
|
|
53
|
-
|
|
54
|
+
EnvLoader
|
|
54
55
|
});
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
// src/client/env_loader.tsx
|
|
2
|
+
import React from "react";
|
|
3
|
+
import { useRouteLoaderData } from "react-router";
|
|
4
|
+
function EnvLoader({ dataKey = "ENV" }) {
|
|
5
|
+
const data = useRouteLoaderData("root");
|
|
6
|
+
if (!data) {
|
|
7
|
+
return;
|
|
8
|
+
}
|
|
9
|
+
return /* @__PURE__ */ React.createElement(
|
|
10
|
+
"script",
|
|
11
|
+
{
|
|
12
|
+
dangerouslySetInnerHTML: {
|
|
13
|
+
__html: `window.ENV = ${JSON.stringify(data[dataKey])};`
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
);
|
|
17
|
+
}
|
|
18
|
+
export {
|
|
19
|
+
EnvLoader
|
|
20
|
+
};
|
package/dist/client/index.d.mts
CHANGED
package/dist/client/index.d.ts
CHANGED
package/dist/client/index.js
CHANGED
|
@@ -30,26 +30,36 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
30
30
|
// src/client/index.ts
|
|
31
31
|
var client_exports = {};
|
|
32
32
|
__export(client_exports, {
|
|
33
|
-
|
|
33
|
+
EnvLoader: () => EnvLoader,
|
|
34
|
+
env: () => env,
|
|
34
35
|
useUserAgent: () => useUserAgent
|
|
35
36
|
});
|
|
36
37
|
module.exports = __toCommonJS(client_exports);
|
|
37
38
|
|
|
38
|
-
// src/client/
|
|
39
|
+
// src/client/env.ts
|
|
40
|
+
function env(key) {
|
|
41
|
+
if (typeof window === "undefined") {
|
|
42
|
+
return process.env[key] || "";
|
|
43
|
+
}
|
|
44
|
+
return window.ENV?.[key] || "";
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
// src/client/env_loader.tsx
|
|
39
48
|
var import_react = __toESM(require("react"));
|
|
40
49
|
var import_react_router = require("react-router");
|
|
41
|
-
function
|
|
50
|
+
function EnvLoader({ dataKey = "ENV" }) {
|
|
42
51
|
const data = (0, import_react_router.useRouteLoaderData)("root");
|
|
43
|
-
|
|
52
|
+
if (!data) {
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
44
56
|
"script",
|
|
45
57
|
{
|
|
46
58
|
dangerouslySetInnerHTML: {
|
|
47
|
-
__html: `window.
|
|
48
|
-
env: data?.[dataKey]
|
|
49
|
-
})}`
|
|
59
|
+
__html: `window.ENV = ${JSON.stringify(data[dataKey])};`
|
|
50
60
|
}
|
|
51
61
|
}
|
|
52
|
-
)
|
|
62
|
+
);
|
|
53
63
|
}
|
|
54
64
|
|
|
55
65
|
// src/client/use_user_agent.tsx
|
|
@@ -64,6 +74,7 @@ function useUserAgent() {
|
|
|
64
74
|
}
|
|
65
75
|
// Annotate the CommonJS export names for ESM import in node:
|
|
66
76
|
0 && (module.exports = {
|
|
67
|
-
|
|
77
|
+
EnvLoader,
|
|
78
|
+
env,
|
|
68
79
|
useUserAgent
|
|
69
80
|
});
|
package/dist/client/index.mjs
CHANGED
|
@@ -1,18 +1,27 @@
|
|
|
1
|
-
// src/client/
|
|
1
|
+
// src/client/env.ts
|
|
2
|
+
function env(key) {
|
|
3
|
+
if (typeof window === "undefined") {
|
|
4
|
+
return process.env[key] || "";
|
|
5
|
+
}
|
|
6
|
+
return window.ENV?.[key] || "";
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
// src/client/env_loader.tsx
|
|
2
10
|
import React from "react";
|
|
3
11
|
import { useRouteLoaderData } from "react-router";
|
|
4
|
-
function
|
|
12
|
+
function EnvLoader({ dataKey = "ENV" }) {
|
|
5
13
|
const data = useRouteLoaderData("root");
|
|
6
|
-
|
|
14
|
+
if (!data) {
|
|
15
|
+
return;
|
|
16
|
+
}
|
|
17
|
+
return /* @__PURE__ */ React.createElement(
|
|
7
18
|
"script",
|
|
8
19
|
{
|
|
9
20
|
dangerouslySetInnerHTML: {
|
|
10
|
-
__html: `window.
|
|
11
|
-
env: data?.[dataKey]
|
|
12
|
-
})}`
|
|
21
|
+
__html: `window.ENV = ${JSON.stringify(data[dataKey])};`
|
|
13
22
|
}
|
|
14
23
|
}
|
|
15
|
-
)
|
|
24
|
+
);
|
|
16
25
|
}
|
|
17
26
|
|
|
18
27
|
// src/client/use_user_agent.tsx
|
|
@@ -26,6 +35,7 @@ function useUserAgent() {
|
|
|
26
35
|
return { userAgent, isMobile, isTablet, isDesktop };
|
|
27
36
|
}
|
|
28
37
|
export {
|
|
29
|
-
|
|
38
|
+
EnvLoader,
|
|
39
|
+
env,
|
|
30
40
|
useUserAgent
|
|
31
41
|
};
|
package/dist/index.d.mts
CHANGED
|
@@ -3,6 +3,6 @@ import 'dn-react-toolkit/file';
|
|
|
3
3
|
import 'dn-react-toolkit/http';
|
|
4
4
|
import 'dn-react-toolkit/modal';
|
|
5
5
|
import 'dn-react-toolkit/text_editor';
|
|
6
|
-
import 'dn-react-toolkit/file/server';
|
|
7
6
|
import 'dn-react-toolkit/auth/server';
|
|
8
7
|
import 'dn-react-toolkit/file/client';
|
|
8
|
+
import 'dn-react-toolkit/file/server';
|
package/dist/index.d.ts
CHANGED
|
@@ -3,6 +3,6 @@ import 'dn-react-toolkit/file';
|
|
|
3
3
|
import 'dn-react-toolkit/http';
|
|
4
4
|
import 'dn-react-toolkit/modal';
|
|
5
5
|
import 'dn-react-toolkit/text_editor';
|
|
6
|
-
import 'dn-react-toolkit/file/server';
|
|
7
6
|
import 'dn-react-toolkit/auth/server';
|
|
8
7
|
import 'dn-react-toolkit/file/client';
|
|
8
|
+
import 'dn-react-toolkit/file/server';
|
package/package.json
CHANGED
|
@@ -1,123 +1,123 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "dn-react-router-toolkit",
|
|
3
|
-
"version": "0.3.
|
|
4
|
-
"types": "./dist/index.d.ts",
|
|
5
|
-
"main": "./dist/index.mjs",
|
|
6
|
-
"module": "./dist/index.js",
|
|
7
|
-
"exports": {
|
|
8
|
-
".": {
|
|
9
|
-
"types": "./dist/index.d.ts",
|
|
10
|
-
"import": "./dist/index.mjs",
|
|
11
|
-
"require": "./dist/index.js"
|
|
12
|
-
},
|
|
13
|
-
"./auth": {
|
|
14
|
-
"types": "./dist/auth/index.d.ts",
|
|
15
|
-
"import": "./dist/auth/index.mjs",
|
|
16
|
-
"require": "./dist/auth/index.js"
|
|
17
|
-
},
|
|
18
|
-
"./auth/server": {
|
|
19
|
-
"types": "./dist/auth/server/index.d.ts",
|
|
20
|
-
"import": "./dist/auth/server/index.mjs",
|
|
21
|
-
"require": "./dist/auth/server/index.js"
|
|
22
|
-
},
|
|
23
|
-
"./auth/client": {
|
|
24
|
-
"types": "./dist/auth/client/index.d.ts",
|
|
25
|
-
"import": "./dist/auth/client/index.mjs",
|
|
26
|
-
"require": "./dist/auth/client/index.js"
|
|
27
|
-
},
|
|
28
|
-
"./file": {
|
|
29
|
-
"types": "./dist/file/index.d.ts",
|
|
30
|
-
"import": "./dist/file/index.mjs",
|
|
31
|
-
"require": "./dist/file/index.js"
|
|
32
|
-
},
|
|
33
|
-
"./file/server": {
|
|
34
|
-
"types": "./dist/file/server/index.d.ts",
|
|
35
|
-
"import": "./dist/file/server/index.mjs",
|
|
36
|
-
"require": "./dist/file/server/index.js"
|
|
37
|
-
},
|
|
38
|
-
"./file/client": {
|
|
39
|
-
"types": "./dist/file/client/index.d.ts",
|
|
40
|
-
"import": "./dist/file/client/index.mjs",
|
|
41
|
-
"require": "./dist/file/client/index.js"
|
|
42
|
-
},
|
|
43
|
-
"./api": {
|
|
44
|
-
"types": "./dist/api/index.d.ts",
|
|
45
|
-
"import": "./dist/api/index.mjs",
|
|
46
|
-
"require": "./dist/api/index.js"
|
|
47
|
-
},
|
|
48
|
-
"./client": {
|
|
49
|
-
"types": "./dist/client/index.d.ts",
|
|
50
|
-
"import": "./dist/client/index.mjs",
|
|
51
|
-
"require": "./dist/client/index.js"
|
|
52
|
-
},
|
|
53
|
-
"./modal": {
|
|
54
|
-
"types": "./dist/modal/index.d.ts",
|
|
55
|
-
"import": "./dist/modal/index.mjs",
|
|
56
|
-
"require": "./dist/modal/index.js"
|
|
57
|
-
},
|
|
58
|
-
"./http": {
|
|
59
|
-
"types": "./dist/http/index.d.ts",
|
|
60
|
-
"import": "./dist/http/index.mjs",
|
|
61
|
-
"require": "./dist/http/index.js"
|
|
62
|
-
},
|
|
63
|
-
"./seo": {
|
|
64
|
-
"types": "./dist/seo/index.d.ts",
|
|
65
|
-
"import": "./dist/seo/index.mjs",
|
|
66
|
-
"require": "./dist/seo/index.js"
|
|
67
|
-
},
|
|
68
|
-
"./text_editor": {
|
|
69
|
-
"types": "./dist/text_editor/index.d.ts",
|
|
70
|
-
"import": "./dist/text_editor/index.mjs",
|
|
71
|
-
"require": "./dist/text_editor/index.js"
|
|
72
|
-
}
|
|
73
|
-
},
|
|
74
|
-
"scripts": {
|
|
75
|
-
"build": "tsup",
|
|
76
|
-
"dev": "tsup --watch"
|
|
77
|
-
},
|
|
78
|
-
"repository": {
|
|
79
|
-
"type": "git",
|
|
80
|
-
"url": "git+https://github.com/dndnsoft/dn-react-router-toolkit.git"
|
|
81
|
-
},
|
|
82
|
-
"author": "",
|
|
83
|
-
"license": "MIT",
|
|
84
|
-
"bugs": {
|
|
85
|
-
"url": "https://github.com/dndnsoft/dn-react-router-toolkit/issues"
|
|
86
|
-
},
|
|
87
|
-
"homepage": "https://github.com/dndnsoft/dn-react-router-toolkit#readme",
|
|
88
|
-
"description": "",
|
|
89
|
-
"devDependencies": {
|
|
90
|
-
"@types/node": "^24.10.1",
|
|
91
|
-
"@types/nodemailer": "^7.0.4",
|
|
92
|
-
"@types/react": "^19",
|
|
93
|
-
"@types/react-dom": "^19",
|
|
94
|
-
"rimraf": "^6.0.1",
|
|
95
|
-
"schema-dts": "^1.1.5",
|
|
96
|
-
"tsup": "^8.5.1",
|
|
97
|
-
"typescript": "^5.7.3"
|
|
98
|
-
},
|
|
99
|
-
"dependencies": {
|
|
100
|
-
"@aws-sdk/client-s3": "^3.940.0",
|
|
101
|
-
"@aws-sdk/s3-request-presigner": "^3.940.0",
|
|
102
|
-
"bcryptjs": "^3.0.3",
|
|
103
|
-
"dn-react-toolkit": "0.2.
|
|
104
|
-
"jose": "^6.1.2",
|
|
105
|
-
"moment-timezone": "^0.6.0",
|
|
106
|
-
"nodemailer": "^7.0.11",
|
|
107
|
-
"prosemirror-commands": "^1.7.1",
|
|
108
|
-
"prosemirror-history": "^1.5.0",
|
|
109
|
-
"prosemirror-keymap": "^1.2.3",
|
|
110
|
-
"prosemirror-model": "^1.25.4",
|
|
111
|
-
"prosemirror-schema-list": "^1.5.1",
|
|
112
|
-
"prosemirror-state": "^1.4.4",
|
|
113
|
-
"prosemirror-view": "^1.41.3",
|
|
114
|
-
"react-icons": "^5.5.0",
|
|
115
|
-
"uuid": "^13.0.0"
|
|
116
|
-
},
|
|
117
|
-
"peerDependencies": {
|
|
118
|
-
"drizzle-orm": "^0.44",
|
|
119
|
-
"react": "^19",
|
|
120
|
-
"react-dom": "^19",
|
|
121
|
-
"react-router": "^7"
|
|
122
|
-
}
|
|
123
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "dn-react-router-toolkit",
|
|
3
|
+
"version": "0.3.4",
|
|
4
|
+
"types": "./dist/index.d.ts",
|
|
5
|
+
"main": "./dist/index.mjs",
|
|
6
|
+
"module": "./dist/index.js",
|
|
7
|
+
"exports": {
|
|
8
|
+
".": {
|
|
9
|
+
"types": "./dist/index.d.ts",
|
|
10
|
+
"import": "./dist/index.mjs",
|
|
11
|
+
"require": "./dist/index.js"
|
|
12
|
+
},
|
|
13
|
+
"./auth": {
|
|
14
|
+
"types": "./dist/auth/index.d.ts",
|
|
15
|
+
"import": "./dist/auth/index.mjs",
|
|
16
|
+
"require": "./dist/auth/index.js"
|
|
17
|
+
},
|
|
18
|
+
"./auth/server": {
|
|
19
|
+
"types": "./dist/auth/server/index.d.ts",
|
|
20
|
+
"import": "./dist/auth/server/index.mjs",
|
|
21
|
+
"require": "./dist/auth/server/index.js"
|
|
22
|
+
},
|
|
23
|
+
"./auth/client": {
|
|
24
|
+
"types": "./dist/auth/client/index.d.ts",
|
|
25
|
+
"import": "./dist/auth/client/index.mjs",
|
|
26
|
+
"require": "./dist/auth/client/index.js"
|
|
27
|
+
},
|
|
28
|
+
"./file": {
|
|
29
|
+
"types": "./dist/file/index.d.ts",
|
|
30
|
+
"import": "./dist/file/index.mjs",
|
|
31
|
+
"require": "./dist/file/index.js"
|
|
32
|
+
},
|
|
33
|
+
"./file/server": {
|
|
34
|
+
"types": "./dist/file/server/index.d.ts",
|
|
35
|
+
"import": "./dist/file/server/index.mjs",
|
|
36
|
+
"require": "./dist/file/server/index.js"
|
|
37
|
+
},
|
|
38
|
+
"./file/client": {
|
|
39
|
+
"types": "./dist/file/client/index.d.ts",
|
|
40
|
+
"import": "./dist/file/client/index.mjs",
|
|
41
|
+
"require": "./dist/file/client/index.js"
|
|
42
|
+
},
|
|
43
|
+
"./api": {
|
|
44
|
+
"types": "./dist/api/index.d.ts",
|
|
45
|
+
"import": "./dist/api/index.mjs",
|
|
46
|
+
"require": "./dist/api/index.js"
|
|
47
|
+
},
|
|
48
|
+
"./client": {
|
|
49
|
+
"types": "./dist/client/index.d.ts",
|
|
50
|
+
"import": "./dist/client/index.mjs",
|
|
51
|
+
"require": "./dist/client/index.js"
|
|
52
|
+
},
|
|
53
|
+
"./modal": {
|
|
54
|
+
"types": "./dist/modal/index.d.ts",
|
|
55
|
+
"import": "./dist/modal/index.mjs",
|
|
56
|
+
"require": "./dist/modal/index.js"
|
|
57
|
+
},
|
|
58
|
+
"./http": {
|
|
59
|
+
"types": "./dist/http/index.d.ts",
|
|
60
|
+
"import": "./dist/http/index.mjs",
|
|
61
|
+
"require": "./dist/http/index.js"
|
|
62
|
+
},
|
|
63
|
+
"./seo": {
|
|
64
|
+
"types": "./dist/seo/index.d.ts",
|
|
65
|
+
"import": "./dist/seo/index.mjs",
|
|
66
|
+
"require": "./dist/seo/index.js"
|
|
67
|
+
},
|
|
68
|
+
"./text_editor": {
|
|
69
|
+
"types": "./dist/text_editor/index.d.ts",
|
|
70
|
+
"import": "./dist/text_editor/index.mjs",
|
|
71
|
+
"require": "./dist/text_editor/index.js"
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
"scripts": {
|
|
75
|
+
"build": "tsup",
|
|
76
|
+
"dev": "tsup --watch"
|
|
77
|
+
},
|
|
78
|
+
"repository": {
|
|
79
|
+
"type": "git",
|
|
80
|
+
"url": "git+https://github.com/dndnsoft/dn-react-router-toolkit.git"
|
|
81
|
+
},
|
|
82
|
+
"author": "",
|
|
83
|
+
"license": "MIT",
|
|
84
|
+
"bugs": {
|
|
85
|
+
"url": "https://github.com/dndnsoft/dn-react-router-toolkit/issues"
|
|
86
|
+
},
|
|
87
|
+
"homepage": "https://github.com/dndnsoft/dn-react-router-toolkit#readme",
|
|
88
|
+
"description": "",
|
|
89
|
+
"devDependencies": {
|
|
90
|
+
"@types/node": "^24.10.1",
|
|
91
|
+
"@types/nodemailer": "^7.0.4",
|
|
92
|
+
"@types/react": "^19",
|
|
93
|
+
"@types/react-dom": "^19",
|
|
94
|
+
"rimraf": "^6.0.1",
|
|
95
|
+
"schema-dts": "^1.1.5",
|
|
96
|
+
"tsup": "^8.5.1",
|
|
97
|
+
"typescript": "^5.7.3"
|
|
98
|
+
},
|
|
99
|
+
"dependencies": {
|
|
100
|
+
"@aws-sdk/client-s3": "^3.940.0",
|
|
101
|
+
"@aws-sdk/s3-request-presigner": "^3.940.0",
|
|
102
|
+
"bcryptjs": "^3.0.3",
|
|
103
|
+
"dn-react-toolkit": "0.2.1",
|
|
104
|
+
"jose": "^6.1.2",
|
|
105
|
+
"moment-timezone": "^0.6.0",
|
|
106
|
+
"nodemailer": "^7.0.11",
|
|
107
|
+
"prosemirror-commands": "^1.7.1",
|
|
108
|
+
"prosemirror-history": "^1.5.0",
|
|
109
|
+
"prosemirror-keymap": "^1.2.3",
|
|
110
|
+
"prosemirror-model": "^1.25.4",
|
|
111
|
+
"prosemirror-schema-list": "^1.5.1",
|
|
112
|
+
"prosemirror-state": "^1.4.4",
|
|
113
|
+
"prosemirror-view": "^1.41.3",
|
|
114
|
+
"react-icons": "^5.5.0",
|
|
115
|
+
"uuid": "^13.0.0"
|
|
116
|
+
},
|
|
117
|
+
"peerDependencies": {
|
|
118
|
+
"drizzle-orm": "^0.44",
|
|
119
|
+
"react": "^19",
|
|
120
|
+
"react-dom": "^19",
|
|
121
|
+
"react-router": "^7"
|
|
122
|
+
}
|
|
123
|
+
}
|
package/tsup.config.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineConfig } from "tsup";
|
|
2
|
-
|
|
3
|
-
export default defineConfig({
|
|
4
|
-
entry: ["src/**/*.ts", "src/**/*.tsx"], // Your entry file(s)
|
|
5
|
-
format: ["cjs", "esm"], // Output both CommonJS (.cjs) and ESM (.js/.mjs)
|
|
6
|
-
dts: true, // Generate .d.ts files for both formats
|
|
7
|
-
splitting: false,
|
|
8
|
-
clean: true, // Clean dist folder before build
|
|
9
|
-
});
|
|
1
|
+
import { defineConfig } from "tsup";
|
|
2
|
+
|
|
3
|
+
export default defineConfig({
|
|
4
|
+
entry: ["src/**/*.ts", "src/**/*.tsx"], // Your entry file(s)
|
|
5
|
+
format: ["cjs", "esm"], // Output both CommonJS (.cjs) and ESM (.js/.mjs)
|
|
6
|
+
dts: true, // Generate .d.ts files for both formats
|
|
7
|
+
splitting: false,
|
|
8
|
+
clean: true, // Clean dist folder before build
|
|
9
|
+
});
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
// src/client/client_env.tsx
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { useRouteLoaderData } from "react-router";
|
|
4
|
-
function ClientEnv({ dataKey = "ENV" }) {
|
|
5
|
-
const data = useRouteLoaderData("root");
|
|
6
|
-
return /* @__PURE__ */ React.createElement(React.Fragment, null, data && /* @__PURE__ */ React.createElement(
|
|
7
|
-
"script",
|
|
8
|
-
{
|
|
9
|
-
dangerouslySetInnerHTML: {
|
|
10
|
-
__html: `window.process = ${JSON.stringify({
|
|
11
|
-
env: data?.[dataKey]
|
|
12
|
-
})}`
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
));
|
|
16
|
-
}
|
|
17
|
-
export {
|
|
18
|
-
ClientEnv
|
|
19
|
-
};
|