dn-react-router-toolkit 0.2.7 → 0.3.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.
- package/dist/api/create_handler.d.mts +13 -0
- package/dist/api/create_handler.d.ts +13 -0
- package/dist/api/create_handler.js +276 -0
- package/dist/api/create_handler.mjs +282 -0
- package/dist/api/index.d.mts +4 -0
- package/dist/api/index.d.ts +4 -0
- package/dist/api/index.js +276 -0
- package/dist/api/index.mjs +282 -0
- package/dist/auth/client/index.d.mts +3 -0
- package/dist/auth/client/index.d.ts +3 -0
- package/dist/{date.js → auth/client/index.js} +25 -32
- package/dist/auth/client/index.mjs +21 -0
- package/dist/auth/client/redirect_page.d.mts +1 -0
- package/dist/auth/client/redirect_page.d.ts +1 -0
- package/dist/auth/index.d.mts +4 -0
- package/dist/auth/index.d.ts +4 -0
- package/dist/auth/index.js +116 -0
- package/dist/auth/index.mjs +89 -0
- package/dist/auth/server/index.d.mts +1 -0
- package/dist/auth/server/index.d.ts +1 -0
- package/dist/{slug.js → auth/server/index.js} +6 -14
- package/dist/auth/server/index.mjs +2 -0
- package/dist/auth/with_auth.d.mts +2 -6
- package/dist/auth/with_auth.d.ts +2 -6
- package/dist/auth/with_auth.js +3 -0
- package/dist/auth/with_auth.mjs +3 -0
- package/dist/{components → client}/client_env.d.mts +1 -1
- package/dist/{components → client}/client_env.d.ts +1 -1
- package/dist/{components → client}/client_env.js +6 -2
- package/dist/{components → client}/client_env.mjs +2 -2
- package/dist/client/index.d.mts +3 -0
- package/dist/client/index.d.ts +3 -0
- package/dist/{auth/client/google_login_button.js → client/index.js} +30 -33
- package/dist/client/index.mjs +31 -0
- package/dist/client/use_user_agent.d.mts +8 -0
- package/dist/client/use_user_agent.d.ts +8 -0
- package/dist/{file/client/format_size.js → client/use_user_agent.js} +14 -14
- package/dist/client/use_user_agent.mjs +13 -0
- package/dist/file/client/index.d.mts +1 -0
- package/dist/file/client/index.d.ts +1 -0
- package/dist/file/{cdn.js → client/index.js} +6 -16
- package/dist/file/client/index.mjs +2 -0
- package/dist/file/index.d.mts +1 -0
- package/dist/file/index.d.ts +1 -0
- package/dist/{cn.js → file/index.js} +6 -14
- package/dist/file/index.mjs +2 -0
- package/dist/file/server/index.d.mts +1 -0
- package/dist/file/server/index.d.ts +1 -0
- package/dist/file/server/index.js +24 -0
- package/dist/file/server/index.mjs +2 -0
- package/dist/http/index.d.mts +1 -1
- package/dist/http/index.d.ts +1 -1
- package/dist/http/index.js +3 -90
- package/dist/http/index.mjs +2 -68
- package/dist/index.d.mts +8 -6
- package/dist/index.d.ts +8 -6
- package/dist/index.js +3 -79
- package/dist/index.mjs +2 -58
- package/dist/modal/index.d.mts +1 -0
- package/dist/modal/index.d.ts +1 -0
- package/dist/{sleep.js → modal/index.js} +6 -14
- package/dist/modal/index.mjs +2 -0
- package/dist/seo/index.d.mts +4 -0
- package/dist/seo/index.d.ts +4 -0
- package/dist/seo/index.js +304 -0
- package/dist/seo/index.mjs +267 -0
- package/dist/text_editor/index.d.mts +1 -0
- package/dist/text_editor/index.d.ts +1 -0
- package/dist/text_editor/index.js +24 -0
- package/dist/text_editor/index.mjs +2 -0
- package/package.json +58 -32
- package/dist/auth/apple_auth.d.mts +0 -38
- package/dist/auth/apple_auth.d.ts +0 -38
- package/dist/auth/apple_auth.js +0 -88
- package/dist/auth/apple_auth.mjs +0 -63
- package/dist/auth/auth_repository.d.mts +0 -41
- package/dist/auth/auth_repository.d.ts +0 -41
- package/dist/auth/auth_repository.js +0 -18
- package/dist/auth/auth_repository.mjs +0 -0
- package/dist/auth/auth_service.d.mts +0 -63
- package/dist/auth/auth_service.d.ts +0 -63
- package/dist/auth/auth_service.js +0 -210
- package/dist/auth/auth_service.mjs +0 -171
- package/dist/auth/client/google_login_button.d.mts +0 -7
- package/dist/auth/client/google_login_button.d.ts +0 -7
- package/dist/auth/client/google_login_button.mjs +0 -37
- package/dist/auth/client/provider.d.mts +0 -24
- package/dist/auth/client/provider.d.ts +0 -24
- package/dist/auth/client/provider.js +0 -154
- package/dist/auth/client/provider.mjs +0 -118
- package/dist/auth/google_auth.d.mts +0 -33
- package/dist/auth/google_auth.d.ts +0 -33
- package/dist/auth/google_auth.js +0 -135
- package/dist/auth/google_auth.mjs +0 -108
- package/dist/auth/handlers/find_auth.d.mts +0 -13
- package/dist/auth/handlers/find_auth.d.ts +0 -13
- package/dist/auth/handlers/find_auth.js +0 -82
- package/dist/auth/handlers/find_auth.mjs +0 -55
- package/dist/auth/handlers/login.d.mts +0 -13
- package/dist/auth/handlers/login.d.ts +0 -13
- package/dist/auth/handlers/login.js +0 -107
- package/dist/auth/handlers/login.mjs +0 -80
- package/dist/auth/handlers/login_with_thirdparty.d.mts +0 -15
- package/dist/auth/handlers/login_with_thirdparty.d.ts +0 -15
- package/dist/auth/handlers/login_with_thirdparty.js +0 -98
- package/dist/auth/handlers/login_with_thirdparty.mjs +0 -71
- package/dist/auth/handlers/logout.d.mts +0 -13
- package/dist/auth/handlers/logout.d.ts +0 -13
- package/dist/auth/handlers/logout.js +0 -102
- package/dist/auth/handlers/logout.mjs +0 -75
- package/dist/auth/handlers/refresh.d.mts +0 -13
- package/dist/auth/handlers/refresh.d.ts +0 -13
- package/dist/auth/handlers/refresh.js +0 -92
- package/dist/auth/handlers/refresh.mjs +0 -65
- package/dist/auth/handlers/request_password_reset.d.mts +0 -10
- package/dist/auth/handlers/request_password_reset.d.ts +0 -10
- package/dist/auth/handlers/request_password_reset.js +0 -87
- package/dist/auth/handlers/request_password_reset.mjs +0 -60
- package/dist/auth/handlers/reset_password.d.mts +0 -10
- package/dist/auth/handlers/reset_password.d.ts +0 -10
- package/dist/auth/handlers/reset_password.js +0 -88
- package/dist/auth/handlers/reset_password.mjs +0 -61
- package/dist/auth/handlers/signup.d.mts +0 -15
- package/dist/auth/handlers/signup.d.ts +0 -15
- package/dist/auth/handlers/signup.js +0 -147
- package/dist/auth/handlers/signup.mjs +0 -112
- package/dist/auth/handlers/signup_with_thirdparty.d.mts +0 -17
- package/dist/auth/handlers/signup_with_thirdparty.d.ts +0 -17
- package/dist/auth/handlers/signup_with_thirdparty.js +0 -123
- package/dist/auth/handlers/signup_with_thirdparty.mjs +0 -98
- package/dist/auth/handlers/thirdparty_auth_callback.d.mts +0 -16
- package/dist/auth/handlers/thirdparty_auth_callback.d.ts +0 -16
- package/dist/auth/handlers/thirdparty_auth_callback.js +0 -129
- package/dist/auth/handlers/thirdparty_auth_callback.mjs +0 -102
- package/dist/auth/jwt_manager.d.mts +0 -38
- package/dist/auth/jwt_manager.d.ts +0 -38
- package/dist/auth/jwt_manager.js +0 -90
- package/dist/auth/jwt_manager.mjs +0 -65
- package/dist/auth/kakao_auth.d.mts +0 -27
- package/dist/auth/kakao_auth.d.ts +0 -27
- package/dist/auth/kakao_auth.js +0 -56
- package/dist/auth/kakao_auth.mjs +0 -31
- package/dist/auth/password_recovery.d.mts +0 -34
- package/dist/auth/password_recovery.d.ts +0 -34
- package/dist/auth/password_recovery.js +0 -169
- package/dist/auth/password_recovery.mjs +0 -134
- package/dist/auth/thirdparty_auth.d.mts +0 -41
- package/dist/auth/thirdparty_auth.d.ts +0 -41
- package/dist/auth/thirdparty_auth.js +0 -113
- package/dist/auth/thirdparty_auth.mjs +0 -86
- package/dist/cn.d.mts +0 -3
- package/dist/cn.d.ts +0 -3
- package/dist/cn.mjs +0 -7
- package/dist/components/index.d.mts +0 -5
- package/dist/components/index.d.ts +0 -5
- package/dist/components/index.js +0 -261
- package/dist/components/index.mjs +0 -219
- package/dist/components/modal/fullscreen_container.d.mts +0 -7
- package/dist/components/modal/fullscreen_container.d.ts +0 -7
- package/dist/components/modal/fullscreen_container.js +0 -102
- package/dist/components/modal/fullscreen_container.mjs +0 -68
- package/dist/components/modal/hooks.d.mts +0 -18
- package/dist/components/modal/hooks.d.ts +0 -18
- package/dist/components/modal/hooks.js +0 -236
- package/dist/components/modal/hooks.mjs +0 -204
- package/dist/components/modal/index.d.mts +0 -4
- package/dist/components/modal/index.d.ts +0 -4
- package/dist/components/modal/index.js +0 -238
- package/dist/components/modal/index.mjs +0 -203
- package/dist/components/modal/modal.d.mts +0 -13
- package/dist/components/modal/modal.d.ts +0 -13
- package/dist/components/modal/modal.js +0 -155
- package/dist/components/modal/modal.mjs +0 -130
- package/dist/components/styles.d.mts +0 -9
- package/dist/components/styles.d.ts +0 -9
- package/dist/components/styles.js +0 -48
- package/dist/components/styles.mjs +0 -17
- package/dist/date.d.mts +0 -5
- package/dist/date.d.ts +0 -5
- package/dist/date.mjs +0 -29
- package/dist/file/cdn.d.mts +0 -6
- package/dist/file/cdn.d.ts +0 -6
- package/dist/file/cdn.mjs +0 -9
- package/dist/file/client/drop_file_input.d.mts +0 -36
- package/dist/file/client/drop_file_input.d.ts +0 -36
- package/dist/file/client/drop_file_input.js +0 -323
- package/dist/file/client/drop_file_input.mjs +0 -294
- package/dist/file/client/file_upload_button.d.mts +0 -10
- package/dist/file/client/file_upload_button.d.ts +0 -10
- package/dist/file/client/file_upload_button.js +0 -89
- package/dist/file/client/file_upload_button.mjs +0 -58
- package/dist/file/client/file_uploader.d.mts +0 -13
- package/dist/file/client/file_uploader.d.ts +0 -13
- package/dist/file/client/file_uploader.js +0 -163
- package/dist/file/client/file_uploader.mjs +0 -136
- package/dist/file/client/format_size.d.mts +0 -3
- package/dist/file/client/format_size.d.ts +0 -3
- package/dist/file/client/format_size.mjs +0 -13
- package/dist/file/client/metadata.d.mts +0 -7
- package/dist/file/client/metadata.d.ts +0 -7
- package/dist/file/client/metadata.js +0 -85
- package/dist/file/client/metadata.mjs +0 -60
- package/dist/file/file_repository.d.mts +0 -16
- package/dist/file/file_repository.d.ts +0 -16
- package/dist/file/file_repository.js +0 -18
- package/dist/file/file_repository.mjs +0 -0
- package/dist/file/file_service.d.mts +0 -32
- package/dist/file/file_service.d.ts +0 -32
- package/dist/file/file_service.js +0 -66
- package/dist/file/file_service.mjs +0 -41
- package/dist/file/handlers/delete_file.d.mts +0 -17
- package/dist/file/handlers/delete_file.d.ts +0 -17
- package/dist/file/handlers/delete_file.js +0 -99
- package/dist/file/handlers/delete_file.mjs +0 -72
- package/dist/file/handlers/upload_file.d.mts +0 -16
- package/dist/file/handlers/upload_file.d.ts +0 -16
- package/dist/file/handlers/upload_file.js +0 -106
- package/dist/file/handlers/upload_file.mjs +0 -79
- package/dist/file/object_storage.d.mts +0 -20
- package/dist/file/object_storage.d.ts +0 -20
- package/dist/file/object_storage.js +0 -90
- package/dist/file/object_storage.mjs +0 -70
- package/dist/file/responsive_image.d.mts +0 -20
- package/dist/file/responsive_image.d.ts +0 -20
- package/dist/file/responsive_image.js +0 -132
- package/dist/file/responsive_image.mjs +0 -96
- package/dist/http/response.d.mts +0 -19
- package/dist/http/response.d.ts +0 -19
- package/dist/http/response.js +0 -109
- package/dist/http/response.mjs +0 -68
- package/dist/route/api.d.mts +0 -21
- package/dist/route/api.d.ts +0 -21
- package/dist/route/api.js +0 -584
- package/dist/route/api.mjs +0 -547
- package/dist/singleton.d.mts +0 -3
- package/dist/singleton.d.ts +0 -3
- package/dist/singleton.js +0 -37
- package/dist/singleton.mjs +0 -12
- package/dist/sleep.d.mts +0 -3
- package/dist/sleep.d.ts +0 -3
- package/dist/sleep.mjs +0 -7
- package/dist/slug.d.mts +0 -3
- package/dist/slug.d.ts +0 -3
- package/dist/slug.mjs +0 -7
- package/dist/text_editor/attach_media.d.mts +0 -16
- package/dist/text_editor/attach_media.d.ts +0 -16
- package/dist/text_editor/attach_media.js +0 -237
- package/dist/text_editor/attach_media.mjs +0 -210
- package/dist/text_editor/plugins/drag_and_drop.d.mts +0 -13
- package/dist/text_editor/plugins/drag_and_drop.d.ts +0 -13
- package/dist/text_editor/plugins/drag_and_drop.js +0 -59
- package/dist/text_editor/plugins/drag_and_drop.mjs +0 -34
- package/dist/text_editor/plugins/keymap.d.mts +0 -5
- package/dist/text_editor/plugins/keymap.d.ts +0 -5
- package/dist/text_editor/plugins/keymap.js +0 -40
- package/dist/text_editor/plugins/keymap.mjs +0 -15
- package/dist/text_editor/plugins/placehoder.d.mts +0 -5
- package/dist/text_editor/plugins/placehoder.d.ts +0 -5
- package/dist/text_editor/plugins/placehoder.js +0 -112
- package/dist/text_editor/plugins/placehoder.mjs +0 -87
- package/dist/text_editor/plugins/trailing_paragraph.d.mts +0 -5
- package/dist/text_editor/plugins/trailing_paragraph.d.ts +0 -5
- package/dist/text_editor/plugins/trailing_paragraph.js +0 -46
- package/dist/text_editor/plugins/trailing_paragraph.mjs +0 -21
- package/dist/text_editor/plugins/upload_placeholder.d.mts +0 -7
- package/dist/text_editor/plugins/upload_placeholder.d.ts +0 -7
- package/dist/text_editor/plugins/upload_placeholder.js +0 -94
- package/dist/text_editor/plugins/upload_placeholder.mjs +0 -68
- package/dist/text_editor/schema.d.mts +0 -9
- package/dist/text_editor/schema.d.ts +0 -9
- package/dist/text_editor/schema.js +0 -354
- package/dist/text_editor/schema.mjs +0 -319
- package/dist/text_editor/text_editor.d.mts +0 -45
- package/dist/text_editor/text_editor.d.ts +0 -45
- package/dist/text_editor/text_editor.js +0 -834
- package/dist/text_editor/text_editor.mjs +0 -806
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from 'dn-react-toolkit/file/server';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from 'dn-react-toolkit/file/server';
|
|
@@ -0,0 +1,24 @@
|
|
|
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 __copyProps = (to, from, except, desc) => {
|
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
+
for (let key of __getOwnPropNames(from))
|
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
+
}
|
|
12
|
+
return to;
|
|
13
|
+
};
|
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
15
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
16
|
+
|
|
17
|
+
// src/file/server/index.ts
|
|
18
|
+
var server_exports = {};
|
|
19
|
+
module.exports = __toCommonJS(server_exports);
|
|
20
|
+
__reExport(server_exports, require("dn-react-toolkit/file/server"), module.exports);
|
|
21
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
22
|
+
0 && (module.exports = {
|
|
23
|
+
...require("dn-react-toolkit/file/server")
|
|
24
|
+
});
|
package/dist/http/index.d.mts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from 'dn-react-toolkit/http';
|
package/dist/http/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from 'dn-react-toolkit/http';
|
package/dist/http/index.js
CHANGED
|
@@ -3,10 +3,6 @@ var __defProp = Object.defineProperty;
|
|
|
3
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
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
6
|
var __copyProps = (to, from, except, desc) => {
|
|
11
7
|
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
8
|
for (let key of __getOwnPropNames(from))
|
|
@@ -15,97 +11,14 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
15
11
|
}
|
|
16
12
|
return to;
|
|
17
13
|
};
|
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
18
15
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
16
|
|
|
20
17
|
// src/http/index.ts
|
|
21
18
|
var http_exports = {};
|
|
22
|
-
__export(http_exports, {
|
|
23
|
-
ACCEPTED: () => ACCEPTED,
|
|
24
|
-
BAD_REQUEST: () => BAD_REQUEST,
|
|
25
|
-
CONFLICT: () => CONFLICT,
|
|
26
|
-
CREATED: () => CREATED,
|
|
27
|
-
FORBIDDEN: () => FORBIDDEN,
|
|
28
|
-
INTERNAL_SERVER_ERROR: () => INTERNAL_SERVER_ERROR,
|
|
29
|
-
METHOD_NOT_ALLOWED: () => METHOD_NOT_ALLOWED,
|
|
30
|
-
NOT_ACCEPTABLE: () => NOT_ACCEPTABLE,
|
|
31
|
-
NOT_FOUND: () => NOT_FOUND,
|
|
32
|
-
NO_CONTENT: () => NO_CONTENT,
|
|
33
|
-
OK: () => OK,
|
|
34
|
-
REQUEST_TIMEOUT: () => REQUEST_TIMEOUT,
|
|
35
|
-
TOO_MANY_REQUESTS: () => TOO_MANY_REQUESTS,
|
|
36
|
-
UNAUTHORIZED: () => UNAUTHORIZED,
|
|
37
|
-
UNPROCESSABLE_ENTITY: () => UNPROCESSABLE_ENTITY,
|
|
38
|
-
createException: () => createException,
|
|
39
|
-
createJsonResponse: () => createJsonResponse
|
|
40
|
-
});
|
|
41
19
|
module.exports = __toCommonJS(http_exports);
|
|
42
|
-
|
|
43
|
-
// src/http/response.ts
|
|
44
|
-
var createJsonResponse = (status) => {
|
|
45
|
-
return (data = {}, init) => {
|
|
46
|
-
return Response.json(data, { status, ...init });
|
|
47
|
-
};
|
|
48
|
-
};
|
|
49
|
-
var OK = createJsonResponse(200);
|
|
50
|
-
var CREATED = createJsonResponse(201);
|
|
51
|
-
var ACCEPTED = createJsonResponse(202);
|
|
52
|
-
var NO_CONTENT = (init) => {
|
|
53
|
-
return new Response(null, {
|
|
54
|
-
...init,
|
|
55
|
-
status: 204
|
|
56
|
-
});
|
|
57
|
-
};
|
|
58
|
-
var createException = (status, defaultMessage = "\uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4.") => {
|
|
59
|
-
return (message = defaultMessage, init) => {
|
|
60
|
-
return createJsonResponse(status)({ message }, init);
|
|
61
|
-
};
|
|
62
|
-
};
|
|
63
|
-
var BAD_REQUEST = createException(400, "\uC694\uCCAD\uC774 \uC62C\uBC14\uB974\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4.");
|
|
64
|
-
var UNAUTHORIZED = createException(401, "\uC778\uC99D\uC774 \uD544\uC694\uD569\uB2C8\uB2E4.");
|
|
65
|
-
var FORBIDDEN = createException(403, "\uAD8C\uD55C\uC774 \uC5C6\uC2B5\uB2C8\uB2E4.");
|
|
66
|
-
var NOT_FOUND = createException(
|
|
67
|
-
404,
|
|
68
|
-
"\uC694\uCCAD\uD55C \uB9AC\uC18C\uC2A4\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."
|
|
69
|
-
);
|
|
70
|
-
var METHOD_NOT_ALLOWED = createException(
|
|
71
|
-
405,
|
|
72
|
-
"\uBA54\uC11C\uB4DC\uB97C \uC0AC\uC6A9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."
|
|
73
|
-
);
|
|
74
|
-
var NOT_ACCEPTABLE = createException(
|
|
75
|
-
406,
|
|
76
|
-
"\uC694\uCCAD\uD55C \uD615\uC2DD\uC744 \uC0AC\uC6A9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."
|
|
77
|
-
);
|
|
78
|
-
var REQUEST_TIMEOUT = createException(
|
|
79
|
-
408,
|
|
80
|
-
"\uC694\uCCAD \uC2DC\uAC04\uC774 \uCD08\uACFC\uB418\uC5C8\uC2B5\uB2C8\uB2E4."
|
|
81
|
-
);
|
|
82
|
-
var CONFLICT = createException(409, "\uC694\uCCAD\uC774 \uCDA9\uB3CC\uD588\uC2B5\uB2C8\uB2E4.");
|
|
83
|
-
var UNPROCESSABLE_ENTITY = createException(
|
|
84
|
-
422,
|
|
85
|
-
"\uCC98\uB9AC\uD560 \uC218 \uC5C6\uB294 \uC5D4\uD2F0\uD2F0\uC785\uB2C8\uB2E4."
|
|
86
|
-
);
|
|
87
|
-
var TOO_MANY_REQUESTS = createException(429, "\uC694\uCCAD\uC774 \uB108\uBB34 \uB9CE\uC2B5\uB2C8\uB2E4.");
|
|
88
|
-
var INTERNAL_SERVER_ERROR = createException(
|
|
89
|
-
500,
|
|
90
|
-
"\uC608\uAE30\uCE58 \uBABB\uD55C \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4."
|
|
91
|
-
);
|
|
20
|
+
__reExport(http_exports, require("dn-react-toolkit/http"), module.exports);
|
|
92
21
|
// Annotate the CommonJS export names for ESM import in node:
|
|
93
22
|
0 && (module.exports = {
|
|
94
|
-
|
|
95
|
-
BAD_REQUEST,
|
|
96
|
-
CONFLICT,
|
|
97
|
-
CREATED,
|
|
98
|
-
FORBIDDEN,
|
|
99
|
-
INTERNAL_SERVER_ERROR,
|
|
100
|
-
METHOD_NOT_ALLOWED,
|
|
101
|
-
NOT_ACCEPTABLE,
|
|
102
|
-
NOT_FOUND,
|
|
103
|
-
NO_CONTENT,
|
|
104
|
-
OK,
|
|
105
|
-
REQUEST_TIMEOUT,
|
|
106
|
-
TOO_MANY_REQUESTS,
|
|
107
|
-
UNAUTHORIZED,
|
|
108
|
-
UNPROCESSABLE_ENTITY,
|
|
109
|
-
createException,
|
|
110
|
-
createJsonResponse
|
|
23
|
+
...require("dn-react-toolkit/http")
|
|
111
24
|
});
|
package/dist/http/index.mjs
CHANGED
|
@@ -1,68 +1,2 @@
|
|
|
1
|
-
// src/http/
|
|
2
|
-
|
|
3
|
-
return (data = {}, init) => {
|
|
4
|
-
return Response.json(data, { status, ...init });
|
|
5
|
-
};
|
|
6
|
-
};
|
|
7
|
-
var OK = createJsonResponse(200);
|
|
8
|
-
var CREATED = createJsonResponse(201);
|
|
9
|
-
var ACCEPTED = createJsonResponse(202);
|
|
10
|
-
var NO_CONTENT = (init) => {
|
|
11
|
-
return new Response(null, {
|
|
12
|
-
...init,
|
|
13
|
-
status: 204
|
|
14
|
-
});
|
|
15
|
-
};
|
|
16
|
-
var createException = (status, defaultMessage = "\uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4.") => {
|
|
17
|
-
return (message = defaultMessage, init) => {
|
|
18
|
-
return createJsonResponse(status)({ message }, init);
|
|
19
|
-
};
|
|
20
|
-
};
|
|
21
|
-
var BAD_REQUEST = createException(400, "\uC694\uCCAD\uC774 \uC62C\uBC14\uB974\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4.");
|
|
22
|
-
var UNAUTHORIZED = createException(401, "\uC778\uC99D\uC774 \uD544\uC694\uD569\uB2C8\uB2E4.");
|
|
23
|
-
var FORBIDDEN = createException(403, "\uAD8C\uD55C\uC774 \uC5C6\uC2B5\uB2C8\uB2E4.");
|
|
24
|
-
var NOT_FOUND = createException(
|
|
25
|
-
404,
|
|
26
|
-
"\uC694\uCCAD\uD55C \uB9AC\uC18C\uC2A4\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."
|
|
27
|
-
);
|
|
28
|
-
var METHOD_NOT_ALLOWED = createException(
|
|
29
|
-
405,
|
|
30
|
-
"\uBA54\uC11C\uB4DC\uB97C \uC0AC\uC6A9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."
|
|
31
|
-
);
|
|
32
|
-
var NOT_ACCEPTABLE = createException(
|
|
33
|
-
406,
|
|
34
|
-
"\uC694\uCCAD\uD55C \uD615\uC2DD\uC744 \uC0AC\uC6A9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."
|
|
35
|
-
);
|
|
36
|
-
var REQUEST_TIMEOUT = createException(
|
|
37
|
-
408,
|
|
38
|
-
"\uC694\uCCAD \uC2DC\uAC04\uC774 \uCD08\uACFC\uB418\uC5C8\uC2B5\uB2C8\uB2E4."
|
|
39
|
-
);
|
|
40
|
-
var CONFLICT = createException(409, "\uC694\uCCAD\uC774 \uCDA9\uB3CC\uD588\uC2B5\uB2C8\uB2E4.");
|
|
41
|
-
var UNPROCESSABLE_ENTITY = createException(
|
|
42
|
-
422,
|
|
43
|
-
"\uCC98\uB9AC\uD560 \uC218 \uC5C6\uB294 \uC5D4\uD2F0\uD2F0\uC785\uB2C8\uB2E4."
|
|
44
|
-
);
|
|
45
|
-
var TOO_MANY_REQUESTS = createException(429, "\uC694\uCCAD\uC774 \uB108\uBB34 \uB9CE\uC2B5\uB2C8\uB2E4.");
|
|
46
|
-
var INTERNAL_SERVER_ERROR = createException(
|
|
47
|
-
500,
|
|
48
|
-
"\uC608\uAE30\uCE58 \uBABB\uD55C \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4."
|
|
49
|
-
);
|
|
50
|
-
export {
|
|
51
|
-
ACCEPTED,
|
|
52
|
-
BAD_REQUEST,
|
|
53
|
-
CONFLICT,
|
|
54
|
-
CREATED,
|
|
55
|
-
FORBIDDEN,
|
|
56
|
-
INTERNAL_SERVER_ERROR,
|
|
57
|
-
METHOD_NOT_ALLOWED,
|
|
58
|
-
NOT_ACCEPTABLE,
|
|
59
|
-
NOT_FOUND,
|
|
60
|
-
NO_CONTENT,
|
|
61
|
-
OK,
|
|
62
|
-
REQUEST_TIMEOUT,
|
|
63
|
-
TOO_MANY_REQUESTS,
|
|
64
|
-
UNAUTHORIZED,
|
|
65
|
-
UNPROCESSABLE_ENTITY,
|
|
66
|
-
createException,
|
|
67
|
-
createJsonResponse
|
|
68
|
-
};
|
|
1
|
+
// src/http/index.ts
|
|
2
|
+
export * from "dn-react-toolkit/http";
|
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
export
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
export * from 'dn-react-toolkit';
|
|
2
|
+
import 'dn-react-toolkit/file';
|
|
3
|
+
import 'dn-react-toolkit/http';
|
|
4
|
+
import 'dn-react-toolkit/modal';
|
|
5
|
+
import 'dn-react-toolkit/text_editor';
|
|
6
|
+
import 'dn-react-toolkit/file/client';
|
|
7
|
+
import 'dn-react-toolkit/auth/server';
|
|
8
|
+
import 'dn-react-toolkit/file/server';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
export
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
export * from 'dn-react-toolkit';
|
|
2
|
+
import 'dn-react-toolkit/file';
|
|
3
|
+
import 'dn-react-toolkit/http';
|
|
4
|
+
import 'dn-react-toolkit/modal';
|
|
5
|
+
import 'dn-react-toolkit/text_editor';
|
|
6
|
+
import 'dn-react-toolkit/file/client';
|
|
7
|
+
import 'dn-react-toolkit/auth/server';
|
|
8
|
+
import 'dn-react-toolkit/file/server';
|
package/dist/index.js
CHANGED
|
@@ -1,14 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
2
|
var __defProp = Object.defineProperty;
|
|
4
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
6
|
var __copyProps = (to, from, except, desc) => {
|
|
13
7
|
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
8
|
for (let key of __getOwnPropNames(from))
|
|
@@ -17,84 +11,14 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
11
|
}
|
|
18
12
|
return to;
|
|
19
13
|
};
|
|
20
|
-
var
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
28
15
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
16
|
|
|
30
17
|
// src/index.ts
|
|
31
18
|
var index_exports = {};
|
|
32
|
-
__export(index_exports, {
|
|
33
|
-
cn: () => cn,
|
|
34
|
-
formatHumanDateTime: () => formatHumanDateTime,
|
|
35
|
-
moment: () => import_moment_timezone.default,
|
|
36
|
-
singleton: () => singleton,
|
|
37
|
-
sleep: () => sleep,
|
|
38
|
-
toSlug: () => toSlug
|
|
39
|
-
});
|
|
40
19
|
module.exports = __toCommonJS(index_exports);
|
|
41
|
-
|
|
42
|
-
// src/cn.ts
|
|
43
|
-
function cn(...classes) {
|
|
44
|
-
return classes.filter(Boolean).join(" ").trim();
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
// src/date.ts
|
|
48
|
-
var import_moment_timezone = __toESM(require("moment-timezone"));
|
|
49
|
-
var formatHumanDateTime = (value) => {
|
|
50
|
-
const date = (0, import_moment_timezone.default)(value).tz("Asia/Seoul");
|
|
51
|
-
const now = (0, import_moment_timezone.default)().tz("Asia/Seoul");
|
|
52
|
-
if (date.isAfter(now.clone().subtract(1, "minute"))) {
|
|
53
|
-
return "\uBC29\uAE08 \uC804";
|
|
54
|
-
}
|
|
55
|
-
if (date.isAfter(now.clone().subtract(1, "hour"))) {
|
|
56
|
-
const diff = now.diff(date, "minute");
|
|
57
|
-
return `${diff}\uBD84 \uC804`;
|
|
58
|
-
}
|
|
59
|
-
if (date.isAfter(now.clone().subtract(6, "hours"))) {
|
|
60
|
-
const diff = now.diff(date, "hour");
|
|
61
|
-
return `${diff}\uC2DC\uAC04 \uC804`;
|
|
62
|
-
}
|
|
63
|
-
if (date.isAfter(now.clone().subtract(1, "week"))) {
|
|
64
|
-
const diff = now.diff(date, "day");
|
|
65
|
-
return `${diff}\uC77C \uC804`;
|
|
66
|
-
}
|
|
67
|
-
if (date.isSame(now, "year")) {
|
|
68
|
-
return date.format("M\uC6D4 D\uC77C");
|
|
69
|
-
}
|
|
70
|
-
return date.format("YYYY\uB144 M\uC6D4 D\uC77C");
|
|
71
|
-
};
|
|
72
|
-
|
|
73
|
-
// src/singleton.ts
|
|
74
|
-
function singleton(name, fn) {
|
|
75
|
-
const globalAny = globalThis;
|
|
76
|
-
globalAny.__singletons = globalAny.__singletons || {};
|
|
77
|
-
if (!globalAny.__singletons[name]) {
|
|
78
|
-
globalAny.__singletons[name] = fn();
|
|
79
|
-
}
|
|
80
|
-
return globalAny.__singletons[name];
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
// src/slug.ts
|
|
84
|
-
var toSlug = (str) => {
|
|
85
|
-
return str.toLowerCase().replace(/[^a-zA-Z0-9가-힣ㄱ-ㅎㅏ-ㅣ]+/g, "-").replace(/^-|-$/g, "");
|
|
86
|
-
};
|
|
87
|
-
|
|
88
|
-
// src/sleep.ts
|
|
89
|
-
var sleep = (ms) => {
|
|
90
|
-
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
91
|
-
};
|
|
20
|
+
__reExport(index_exports, require("dn-react-toolkit"), module.exports);
|
|
92
21
|
// Annotate the CommonJS export names for ESM import in node:
|
|
93
22
|
0 && (module.exports = {
|
|
94
|
-
|
|
95
|
-
formatHumanDateTime,
|
|
96
|
-
moment,
|
|
97
|
-
singleton,
|
|
98
|
-
sleep,
|
|
99
|
-
toSlug
|
|
23
|
+
...require("dn-react-toolkit")
|
|
100
24
|
});
|
package/dist/index.mjs
CHANGED
|
@@ -1,58 +1,2 @@
|
|
|
1
|
-
// src/
|
|
2
|
-
|
|
3
|
-
return classes.filter(Boolean).join(" ").trim();
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
// src/date.ts
|
|
7
|
-
import moment from "moment-timezone";
|
|
8
|
-
var formatHumanDateTime = (value) => {
|
|
9
|
-
const date = moment(value).tz("Asia/Seoul");
|
|
10
|
-
const now = moment().tz("Asia/Seoul");
|
|
11
|
-
if (date.isAfter(now.clone().subtract(1, "minute"))) {
|
|
12
|
-
return "\uBC29\uAE08 \uC804";
|
|
13
|
-
}
|
|
14
|
-
if (date.isAfter(now.clone().subtract(1, "hour"))) {
|
|
15
|
-
const diff = now.diff(date, "minute");
|
|
16
|
-
return `${diff}\uBD84 \uC804`;
|
|
17
|
-
}
|
|
18
|
-
if (date.isAfter(now.clone().subtract(6, "hours"))) {
|
|
19
|
-
const diff = now.diff(date, "hour");
|
|
20
|
-
return `${diff}\uC2DC\uAC04 \uC804`;
|
|
21
|
-
}
|
|
22
|
-
if (date.isAfter(now.clone().subtract(1, "week"))) {
|
|
23
|
-
const diff = now.diff(date, "day");
|
|
24
|
-
return `${diff}\uC77C \uC804`;
|
|
25
|
-
}
|
|
26
|
-
if (date.isSame(now, "year")) {
|
|
27
|
-
return date.format("M\uC6D4 D\uC77C");
|
|
28
|
-
}
|
|
29
|
-
return date.format("YYYY\uB144 M\uC6D4 D\uC77C");
|
|
30
|
-
};
|
|
31
|
-
|
|
32
|
-
// src/singleton.ts
|
|
33
|
-
function singleton(name, fn) {
|
|
34
|
-
const globalAny = globalThis;
|
|
35
|
-
globalAny.__singletons = globalAny.__singletons || {};
|
|
36
|
-
if (!globalAny.__singletons[name]) {
|
|
37
|
-
globalAny.__singletons[name] = fn();
|
|
38
|
-
}
|
|
39
|
-
return globalAny.__singletons[name];
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
// src/slug.ts
|
|
43
|
-
var toSlug = (str) => {
|
|
44
|
-
return str.toLowerCase().replace(/[^a-zA-Z0-9가-힣ㄱ-ㅎㅏ-ㅣ]+/g, "-").replace(/^-|-$/g, "");
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
// src/sleep.ts
|
|
48
|
-
var sleep = (ms) => {
|
|
49
|
-
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
50
|
-
};
|
|
51
|
-
export {
|
|
52
|
-
cn,
|
|
53
|
-
formatHumanDateTime,
|
|
54
|
-
moment,
|
|
55
|
-
singleton,
|
|
56
|
-
sleep,
|
|
57
|
-
toSlug
|
|
58
|
-
};
|
|
1
|
+
// src/index.ts
|
|
2
|
+
export * from "dn-react-toolkit";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from 'dn-react-toolkit/modal';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from 'dn-react-toolkit/modal';
|
|
@@ -3,10 +3,6 @@ var __defProp = Object.defineProperty;
|
|
|
3
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
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
6
|
var __copyProps = (to, from, except, desc) => {
|
|
11
7
|
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
8
|
for (let key of __getOwnPropNames(from))
|
|
@@ -15,18 +11,14 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
15
11
|
}
|
|
16
12
|
return to;
|
|
17
13
|
};
|
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
18
15
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
16
|
|
|
20
|
-
// src/
|
|
21
|
-
var
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
});
|
|
25
|
-
module.exports = __toCommonJS(sleep_exports);
|
|
26
|
-
var sleep = (ms) => {
|
|
27
|
-
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
28
|
-
};
|
|
17
|
+
// src/modal/index.ts
|
|
18
|
+
var modal_exports = {};
|
|
19
|
+
module.exports = __toCommonJS(modal_exports);
|
|
20
|
+
__reExport(modal_exports, require("dn-react-toolkit/modal"), module.exports);
|
|
29
21
|
// Annotate the CommonJS export names for ESM import in node:
|
|
30
22
|
0 && (module.exports = {
|
|
31
|
-
|
|
23
|
+
...require("dn-react-toolkit/modal")
|
|
32
24
|
});
|