qumra-engine 2.0.167 → 2.0.169
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/controllers/localize/search.controller.d.ts +2 -0
- package/dist/controllers/localize/search.controller.js +17 -0
- package/dist/extensions/html/form.js +2 -0
- package/dist/filters/index.js +4 -0
- package/dist/filters/logic/customer/customer_login_link.js +3 -1
- package/dist/filters/logic/customer/customer_logout_link.js +3 -1
- package/dist/filters/logic/math/float.d.ts +1 -0
- package/dist/filters/logic/math/float.js +9 -0
- package/dist/filters/logic/math/to_fixed.d.ts +1 -0
- package/dist/filters/logic/math/to_fixed.js +12 -0
- package/dist/functions/render-handler.js +5 -5
- package/dist/middleware.js +0 -1
- package/dist/pages/404.d.ts +1 -1
- package/dist/pages/404.js +337 -48
- package/dist/routers/production/localize/index.js +2 -0
- package/dist/routers/production/localize/search/index.d.ts +2 -0
- package/dist/routers/production/localize/search/index.js +7 -0
- package/package.json +1 -1
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.searchController = void 0;
|
|
4
|
+
const searchController = async (req, res) => {
|
|
5
|
+
try {
|
|
6
|
+
const { q } = req.body;
|
|
7
|
+
if (!q || typeof q !== "string" || !q.trim()) {
|
|
8
|
+
return res.status(400).json({ error: "Missing or invalid search query" });
|
|
9
|
+
}
|
|
10
|
+
const searchUrl = `/search?q=${encodeURIComponent(q)}`;
|
|
11
|
+
res.redirect(searchUrl);
|
|
12
|
+
}
|
|
13
|
+
catch (err) {
|
|
14
|
+
return res.status(500).json({ error: "Internal Server Error" });
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
exports.searchController = searchController;
|
package/dist/filters/index.js
CHANGED
|
@@ -88,6 +88,8 @@ const modulo_1 = __importDefault(require("./logic/math/modulo"));
|
|
|
88
88
|
const plus_1 = __importDefault(require("./logic/math/plus"));
|
|
89
89
|
const round_1 = __importDefault(require("./logic/math/round"));
|
|
90
90
|
const times_1 = __importDefault(require("./logic/math/times"));
|
|
91
|
+
const float_1 = __importDefault(require("./logic/math/float"));
|
|
92
|
+
const to_fixed_1 = __importDefault(require("./logic/math/to_fixed"));
|
|
91
93
|
const upcase_1 = __importDefault(require("./logic/strings/upcase"));
|
|
92
94
|
const capitalize_1 = __importDefault(require("./logic/strings/capitalize"));
|
|
93
95
|
const remove_1 = __importDefault(require("./logic/strings/remove"));
|
|
@@ -176,6 +178,8 @@ exports.filters = [
|
|
|
176
178
|
{ fn: plus_1.default, name: 'plus', async: false },
|
|
177
179
|
{ fn: round_1.default, name: 'round', async: false },
|
|
178
180
|
{ fn: times_1.default, name: 'times', async: false },
|
|
181
|
+
{ fn: float_1.default, name: 'float', async: false },
|
|
182
|
+
{ fn: to_fixed_1.default, name: 'to_Fixed', async: false },
|
|
179
183
|
{ fn: upcase_1.default, name: 'upcase', async: false },
|
|
180
184
|
{ fn: capitalize_1.default, name: 'capitalize', async: false },
|
|
181
185
|
{ fn: remove_1.default, name: 'remove', async: false },
|
|
@@ -5,6 +5,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.default = customer_login_link;
|
|
7
7
|
const nunjucks_1 = __importDefault(require("nunjucks"));
|
|
8
|
+
const globals_1 = require("../../../store/globals");
|
|
8
9
|
function customer_login_link(text) {
|
|
9
|
-
|
|
10
|
+
const redirect = (0, globals_1.getGlobal)("app")?.url || "/";
|
|
11
|
+
return new nunjucks_1.default.runtime.SafeString(`<a href="/customer/auth/login?redirect=${encodeURIComponent(redirect)}" id="customer_login_link">${text}</a>`);
|
|
10
12
|
}
|
|
@@ -5,6 +5,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.default = customer_logout_link;
|
|
7
7
|
const nunjucks_1 = __importDefault(require("nunjucks"));
|
|
8
|
+
const globals_1 = require("../../../store/globals");
|
|
8
9
|
function customer_logout_link(text) {
|
|
9
|
-
|
|
10
|
+
const redirect = (0, globals_1.getGlobal)("app")?.url || "/";
|
|
11
|
+
return new nunjucks_1.default.runtime.SafeString(`<a href="/customer/auth/logout?redirect=${encodeURIComponent(redirect)}" id="customer_logout_link">${text}</a>`);
|
|
10
12
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function float(input: any): number;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function to_fixed(input: any): number;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.default = to_fixed;
|
|
4
|
+
function to_fixed(input) {
|
|
5
|
+
const num = Number(input);
|
|
6
|
+
if (isNaN(num))
|
|
7
|
+
return 0;
|
|
8
|
+
if (Number.isInteger(num)) {
|
|
9
|
+
return Number(num.toFixed(1));
|
|
10
|
+
}
|
|
11
|
+
return num;
|
|
12
|
+
}
|
|
@@ -10,9 +10,9 @@ function renderHandler(locals) {
|
|
|
10
10
|
const render = locals?.render;
|
|
11
11
|
const settings = locals?.env?.getGlobal("settings");
|
|
12
12
|
const lang = locals?.lang;
|
|
13
|
-
const market = locals?.render?.market;
|
|
14
|
-
const currency = market?.
|
|
15
|
-
const localesPath = locals?.
|
|
13
|
+
const market = locals?.render?.globals?.market || locals?.market;
|
|
14
|
+
const currency = market?.currency;
|
|
15
|
+
const localesPath = locals?.localesPath;
|
|
16
16
|
let languages = [];
|
|
17
17
|
if (localesPath && fs_1.default.existsSync(localesPath)) {
|
|
18
18
|
languages = fs_1.default.readdirSync(localesPath).map(lang => path_1.default.basename(lang, '.json'));
|
|
@@ -20,8 +20,6 @@ function renderHandler(locals) {
|
|
|
20
20
|
const objectsData = {};
|
|
21
21
|
if (render?.globals?.customer)
|
|
22
22
|
objectsData.customer = render.globals?.customer;
|
|
23
|
-
if (lang)
|
|
24
|
-
objectsData.local = lang;
|
|
25
23
|
if (render?.context?.product_options_value)
|
|
26
24
|
objectsData.product_options_value = render?.context?.product.options.map((item) => item);
|
|
27
25
|
objectsData.currency = currency;
|
|
@@ -85,5 +83,7 @@ function renderHandler(locals) {
|
|
|
85
83
|
objectsData.market = market;
|
|
86
84
|
if (market || lang || currency)
|
|
87
85
|
objectsData.localization = { market, lang, currency, languages };
|
|
86
|
+
if (lang)
|
|
87
|
+
objectsData.local = lang;
|
|
88
88
|
return objectsData;
|
|
89
89
|
}
|
package/dist/middleware.js
CHANGED
|
@@ -90,7 +90,6 @@ const startEngine = async ({ renderApi, mode, getRender, setRender, port = 3000,
|
|
|
90
90
|
const path = res.locals.parsedUrl?.pathname || req.path;
|
|
91
91
|
const result = (0, isPathAllowedToRender_1.validatePathForRender)(path);
|
|
92
92
|
if (!result.allowed) {
|
|
93
|
-
console.log("🚀 ~ startEngine ~ notFoundPagePath:", _404_1.notFoundPage);
|
|
94
93
|
// return res.status(result.status).json({
|
|
95
94
|
// success: false,
|
|
96
95
|
// message: result.reason,
|
package/dist/pages/404.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const notFoundPage = "\n<!DOCTYPE html>\n<html lang=\"ar\" dir=\"rtl\">\n<head>\n <meta charset=\"UTF-8\" />\n <title>\u0627\u0644\u0635\u0641\u062D\u0629 \u063A\u064A\u0631 \u0645\u0648\u062C\u0648\u062F\u0629</title>\n\n <!-- \u0627\u0633\u062A\u062F\u0639\u0627\u0621 \u062E\u0637 Inter \u0627\u0644\u0639\u0635\u0631\u064A -->\n <link href=\"https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700;800&display=swap\" rel=\"stylesheet\">\n\n <style>\n * {\n box-sizing: border-box;\n }\n\n body {\n margin: 0;\n padding: 0;\n background-color: #001d20;\n font-family: 'Inter', sans-serif;\n display: flex;\n justify-content: center;\n align-items: center;\n min-height: 100vh;\n color: #ffffff;\n text-align: center;\n letter-spacing: -0.3px;\n }\n\n .wrapper {\n padding: 24px;\n }\n\n .card {\n max-width: 420px;\n background: rgba(255, 255, 255, 0.03);\n backdrop-filter: blur(6px);\n border-radius: 16px;\n padding: 40px 28px;\n border: 1px solid rgba(255, 255, 255, 0.07);\n animation: fadeIn 0.5s ease;\n }\n\n h1 {\n font-size: 88px;\n margin: 0;\n font-weight: 800;\n color: #4ed5c5;\n letter-spacing: -2px;\n }\n\n h2 {\n font-size: 26px;\n margin-top: 8px;\n margin-bottom: 12px;\n font-weight: 600;\n color: #e9fffb;\n }\n\n p {\n color: #c3e9e4;\n font-size: 15px;\n margin: 0 auto 28px;\n line-height: 1.7;\n }\n\n a {\n display: inline-block;\n padding: 12px 30px;\n background-color: #4ed5c5;\n color: #001d20;\n font-weight: 700;\n text-decoration: none;\n border-radius: 10px;\n font-size: 15px;\n transition: 0.2s ease-in-out;\n letter-spacing: -0.2px;\n }\n\n a:hover {\n background-color: #3bbcad;\n transform: translateY(-2px);\n }\n\n @keyframes fadeIn {\n from { opacity: 0; transform: translateY(8px); }\n to { opacity: 1; transform: translateY(0); }\n }\n </style>\n</head>\n\n<body>\n <div class=\"wrapper\">\n <div class=\"card\">\n <h1>404</h1>\n <h2>\u0627\u0644\u0635\u0641\u062D\u0629 \u063A\u064A\u0631 \u0645\u0648\u062C\u0648\u062F\u0629</h2>\n <p>\n \u064A\u0628\u062F\u0648 \u0623\u0646\u0643 \u062A\u062D\u0627\u0648\u0644 \u0627\u0644\u0648\u0635\u0648\u0644 \u0625\u0644\u0649 \u0635\u0641\u062D\u0629 \u063A\u064A\u0631 \u0635\u062D\u064A\u062D\u0629 \u0623\u0648 \u063A\u064A\u0631 \u0645\u062A\u0627\u062D\u0629 \u062D\u0627\u0644\u064A\u064B\u0627.<br />\n \u0645\u0646 \u0641\u0636\u0644\u0643 \u062A\u0623\u0643\u062F \u0645\u0646 \u0627\u0644\u0631\u0627\u0628\u0637 \u0623\u0648 \u0639\u062F \u0644\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u0631\u0626\u064A\u0633\u064A\u0629.\n </p>\n <a href=\"/\">\u0627\u0644\u0639\u0648\u062F\u0629 \u0625\u0644\u0649 \u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u0631\u0626\u064A\u0633\u064A\u0629</a>\n </div>\n </div>\n</body>\n</html>\n";
|
|
1
|
+
export declare const notFoundPage = "\n<!DOCTYPE html>\n<html lang=\"ar\" dir=\"rtl\">\n<head>\n <meta charset=\"UTF-8\" />\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\" />\n <title>\u0627\u0644\u0635\u0641\u062D\u0629 \u063A\u064A\u0631 \u0645\u0648\u062C\u0648\u062F\u0629</title>\n\n <link href=\"https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700;800;900&display=swap\" rel=\"stylesheet\">\n\n <style>\n * {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n }\n\n body {\n background: linear-gradient(135deg, #001d20 0%, #002a2e 50%, #001d20 100%);\n font-family: 'Inter', sans-serif;\n display: flex;\n justify-content: center;\n align-items: center;\n min-height: 100vh;\n color: #ffffff;\n overflow: hidden;\n position: relative;\n }\n\n /* \u062E\u0644\u0641\u064A\u0629 \u0645\u062A\u062D\u0631\u0643\u0629 \u0641\u0627\u062E\u0631\u0629 */\n body::before {\n content: '';\n position: absolute;\n width: 150%;\n height: 150%;\n background: radial-gradient(circle at 20% 50%, rgba(78, 213, 197, 0.15) 0%, transparent 50%),\n radial-gradient(circle at 80% 80%, rgba(78, 213, 197, 0.1) 0%, transparent 50%);\n animation: float 20s ease-in-out infinite;\n z-index: 0;\n }\n\n @keyframes float {\n 0%, 100% { transform: translate(0, 0) rotate(0deg); }\n 33% { transform: translate(30px, -30px) rotate(120deg); }\n 66% { transform: translate(-20px, 20px) rotate(240deg); }\n }\n\n .wrapper {\n padding: 20px;\n position: relative;\n z-index: 1;\n width: 100%;\n max-width: 1200px;\n }\n\n .container {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 60px;\n align-items: center;\n animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);\n }\n\n @keyframes slideUp {\n from { \n opacity: 0; \n transform: translateY(30px); \n }\n to { \n opacity: 1; \n transform: translateY(0); \n }\n }\n\n /* \u0627\u0644\u0642\u0633\u0645 \u0627\u0644\u0623\u064A\u0633\u0631 - \u0627\u0644\u0631\u0642\u0645 404 */\n .left-section {\n position: relative;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n\n .glitch-wrapper {\n position: relative;\n }\n\n .glitch-number {\n font-size: clamp(120px, 20vw, 280px);\n font-weight: 900;\n line-height: 1;\n background: linear-gradient(135deg, #4ed5c5 0%, #3bbcad 50%, #4ed5c5 100%);\n -webkit-background-clip: text;\n -webkit-text-fill-color: transparent;\n background-clip: text;\n position: relative;\n filter: drop-shadow(0 0 40px rgba(78, 213, 197, 0.4));\n animation: pulse 3s ease-in-out infinite;\n }\n\n @keyframes pulse {\n 0%, 100% { \n filter: drop-shadow(0 0 40px rgba(78, 213, 197, 0.4));\n transform: scale(1);\n }\n 50% { \n filter: drop-shadow(0 0 60px rgba(78, 213, 197, 0.6));\n transform: scale(1.02);\n }\n }\n\n /* \u062F\u0648\u0627\u0626\u0631 \u062F\u064A\u0643\u0648\u0631 \u0645\u062A\u062D\u0631\u0643\u0629 */\n .circle {\n position: absolute;\n border-radius: 50%;\n border: 2px solid rgba(78, 213, 197, 0.2);\n animation: rotate 20s linear infinite;\n }\n\n .circle-1 {\n width: 300px;\n height: 300px;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n }\n\n .circle-2 {\n width: 400px;\n height: 400px;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n animation-direction: reverse;\n animation-duration: 25s;\n }\n\n @keyframes rotate {\n from { transform: translate(-50%, -50%) rotate(0deg); }\n to { transform: translate(-50%, -50%) rotate(360deg); }\n }\n\n /* \u0627\u0644\u0642\u0633\u0645 \u0627\u0644\u0623\u064A\u0645\u0646 - \u0627\u0644\u0645\u062D\u062A\u0648\u0649 */\n .right-section {\n text-align: right;\n }\n\n .content-card {\n background: rgba(255, 255, 255, 0.04);\n backdrop-filter: blur(20px);\n border-radius: 24px;\n padding: clamp(32px, 5vw, 50px);\n border: 1px solid rgba(78, 213, 197, 0.15);\n position: relative;\n overflow: hidden;\n }\n\n .content-card::before {\n content: '';\n position: absolute;\n top: 0;\n right: 0;\n width: 100%;\n height: 3px;\n background: linear-gradient(90deg, #4ed5c5, transparent);\n animation: shimmer 3s ease-in-out infinite;\n }\n\n @keyframes shimmer {\n 0%, 100% { transform: translateX(100%); opacity: 0; }\n 50% { transform: translateX(-100%); opacity: 1; }\n }\n\n .badge {\n display: inline-block;\n padding: 8px 16px;\n background: rgba(78, 213, 197, 0.15);\n border: 1px solid rgba(78, 213, 197, 0.3);\n border-radius: 20px;\n font-size: 13px;\n font-weight: 600;\n color: #4ed5c5;\n margin-bottom: 20px;\n letter-spacing: 0.5px;\n }\n\n h2 {\n font-size: clamp(28px, 4vw, 42px);\n margin-bottom: 16px;\n font-weight: 800;\n color: #e9fffb;\n letter-spacing: -1px;\n line-height: 1.2;\n }\n\n p {\n color: #c3e9e4;\n font-size: clamp(15px, 2vw, 17px);\n margin-bottom: 32px;\n line-height: 1.8;\n opacity: 0.9;\n }\n\n .btn-group {\n display: flex;\n gap: 16px;\n flex-wrap: wrap;\n justify-content: flex-end;\n }\n\n .btn {\n display: inline-flex;\n align-items: center;\n gap: 8px;\n padding: 14px 28px;\n font-weight: 700;\n text-decoration: none;\n border-radius: 12px;\n font-size: 15px;\n transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);\n letter-spacing: -0.2px;\n position: relative;\n overflow: hidden;\n }\n\n .btn-primary {\n background: linear-gradient(135deg, #4ed5c5 0%, #3bbcad 100%);\n color: #001d20;\n box-shadow: 0 10px 30px rgba(78, 213, 197, 0.3);\n }\n\n .btn-primary::before {\n content: '';\n position: absolute;\n top: 0;\n left: -100%;\n width: 100%;\n height: 100%;\n background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);\n transition: left 0.5s;\n }\n\n .btn-primary:hover::before {\n left: 100%;\n }\n\n .btn-primary:hover {\n transform: translateY(-3px);\n box-shadow: 0 15px 40px rgba(78, 213, 197, 0.4);\n }\n\n .btn-secondary {\n background: rgba(255, 255, 255, 0.05);\n color: #4ed5c5;\n border: 1px solid rgba(78, 213, 197, 0.3);\n }\n\n .btn-secondary:hover {\n background: rgba(78, 213, 197, 0.1);\n border-color: rgba(78, 213, 197, 0.5);\n transform: translateY(-2px);\n }\n\n /* \u0623\u064A\u0642\u0648\u0646\u0627\u062A */\n .icon {\n width: 20px;\n height: 20px;\n display: inline-block;\n }\n\n /* \u0631\u064A\u0633\u0628\u0648\u0646\u0633\u064A\u0641 \u0644\u0644\u0645\u0648\u0628\u0627\u064A\u0644 */\n @media (max-width: 968px) {\n .container {\n grid-template-columns: 1fr;\n gap: 40px;\n text-align: center;\n }\n\n .right-section {\n text-align: center;\n }\n\n .btn-group {\n justify-content: center;\n }\n\n .circle-1,\n .circle-2 {\n display: none;\n }\n\n .glitch-number {\n font-size: clamp(100px, 25vw, 180px);\n }\n }\n\n @media (max-width: 480px) {\n .wrapper {\n padding: 16px;\n }\n\n .content-card {\n padding: 28px 20px;\n }\n\n .btn {\n width: 100%;\n justify-content: center;\n }\n\n .btn-group {\n flex-direction: column;\n }\n }\n\n /* \u062A\u0623\u062B\u064A\u0631 \u0627\u0644\u062C\u0632\u064A\u0626\u0627\u062A \u0627\u0644\u0639\u0627\u0626\u0645\u0629 */\n .particle {\n position: absolute;\n width: 4px;\n height: 4px;\n background: #4ed5c5;\n border-radius: 50%;\n opacity: 0;\n animation: particleFloat 4s ease-in-out infinite;\n }\n\n @keyframes particleFloat {\n 0% {\n transform: translateY(0) translateX(0);\n opacity: 0;\n }\n 50% {\n opacity: 0.8;\n }\n 100% {\n transform: translateY(-100px) translateX(50px);\n opacity: 0;\n }\n }\n\n .particle:nth-child(1) { left: 20%; animation-delay: 0s; }\n .particle:nth-child(2) { left: 40%; animation-delay: 1s; }\n .particle:nth-child(3) { left: 60%; animation-delay: 2s; }\n .particle:nth-child(4) { left: 80%; animation-delay: 3s; }\n </style>\n</head>\n\n<body>\n <div class=\"particle\"></div>\n <div class=\"particle\"></div>\n <div class=\"particle\"></div>\n <div class=\"particle\"></div>\n\n <div class=\"wrapper\">\n <div class=\"container\">\n \n <!-- \u0627\u0644\u0642\u0633\u0645 \u0627\u0644\u0623\u064A\u0633\u0631 -->\n <div class=\"left-section\">\n <div class=\"glitch-wrapper\">\n <div class=\"circle circle-1\"></div>\n <div class=\"circle circle-2\"></div>\n <div class=\"glitch-number\">404</div>\n </div>\n </div>\n\n <!-- \u0627\u0644\u0642\u0633\u0645 \u0627\u0644\u0623\u064A\u0645\u0646 -->\n <div class=\"right-section\">\n <div class=\"content-card\">\n <span class=\"badge\">\u062E\u0637\u0623 \u0641\u064A \u0627\u0644\u0635\u0641\u062D\u0629</span>\n <h2>\u0644\u0644\u0623\u0633\u0641\u060C \u0647\u0630\u0647 \u0627\u0644\u0635\u0641\u062D\u0629 \u063A\u064A\u0631 \u0645\u0648\u062C\u0648\u062F\u0629</h2>\n <p>\n \u064A\u0628\u062F\u0648 \u0623\u0646 \u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u062A\u064A \u062A\u0628\u062D\u062B \u0639\u0646\u0647\u0627 \u063A\u064A\u0631 \u0645\u062A\u0627\u062D\u0629 \u0623\u0648 \u062A\u0645 \u0646\u0642\u0644\u0647\u0627 \u0625\u0644\u0649 \u0645\u0643\u0627\u0646 \u0622\u062E\u0631.\n \u0644\u0627 \u062A\u0642\u0644\u0642\u060C \u064A\u0645\u0643\u0646\u0643 \u0627\u0644\u0639\u0648\u062F\u0629 \u0625\u0644\u0649 \u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u0631\u0626\u064A\u0633\u064A\u0629 \u0623\u0648 \u062A\u0635\u0641\u062D \u0627\u0644\u0623\u0642\u0633\u0627\u0645 \u0627\u0644\u0623\u062E\u0631\u0649.\n </p>\n <div class=\"btn-group\">\n <a href=\"/\" class=\"btn btn-primary\">\n <svg class=\"icon\" fill=\"currentColor\" viewBox=\"0 0 20 20\">\n <path d=\"M10.707 2.293a1 1 0 00-1.414 0l-7 7a1 1 0 001.414 1.414L4 10.414V17a1 1 0 001 1h2a1 1 0 001-1v-2a1 1 0 011-1h2a1 1 0 011 1v2a1 1 0 001 1h2a1 1 0 001-1v-6.586l.293.293a1 1 0 001.414-1.414l-7-7z\"/>\n </svg>\n \u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u0631\u0626\u064A\u0633\u064A\u0629\n </a>\n <a href=\"javascript:history.back()\" class=\"btn btn-secondary\">\n <svg class=\"icon\" fill=\"currentColor\" viewBox=\"0 0 20 20\">\n <path fill-rule=\"evenodd\" d=\"M7.707 14.707a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414l4-4a1 1 0 011.414 1.414L5.414 9H17a1 1 0 110 2H5.414l2.293 2.293a1 1 0 010 1.414z\" clip-rule=\"evenodd\"/>\n </svg>\n \u0627\u0644\u0639\u0648\u062F\u0629 \u0644\u0644\u062E\u0644\u0641\n </a>\n </div>\n </div>\n </div>\n\n </div>\n </div>\n</body>\n</html>\n";
|
package/dist/pages/404.js
CHANGED
|
@@ -6,102 +6,391 @@ exports.notFoundPage = `
|
|
|
6
6
|
<html lang="ar" dir="rtl">
|
|
7
7
|
<head>
|
|
8
8
|
<meta charset="UTF-8" />
|
|
9
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
9
10
|
<title>الصفحة غير موجودة</title>
|
|
10
11
|
|
|
11
|
-
|
|
12
|
-
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700;800&display=swap" rel="stylesheet">
|
|
12
|
+
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700;800;900&display=swap" rel="stylesheet">
|
|
13
13
|
|
|
14
14
|
<style>
|
|
15
15
|
* {
|
|
16
16
|
box-sizing: border-box;
|
|
17
|
+
margin: 0;
|
|
18
|
+
padding: 0;
|
|
17
19
|
}
|
|
18
20
|
|
|
19
21
|
body {
|
|
20
|
-
|
|
21
|
-
padding: 0;
|
|
22
|
-
background-color: #001d20;
|
|
22
|
+
background: linear-gradient(135deg, #001d20 0%, #002a2e 50%, #001d20 100%);
|
|
23
23
|
font-family: 'Inter', sans-serif;
|
|
24
24
|
display: flex;
|
|
25
25
|
justify-content: center;
|
|
26
26
|
align-items: center;
|
|
27
27
|
min-height: 100vh;
|
|
28
28
|
color: #ffffff;
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
overflow: hidden;
|
|
30
|
+
position: relative;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/* خلفية متحركة فاخرة */
|
|
34
|
+
body::before {
|
|
35
|
+
content: '';
|
|
36
|
+
position: absolute;
|
|
37
|
+
width: 150%;
|
|
38
|
+
height: 150%;
|
|
39
|
+
background: radial-gradient(circle at 20% 50%, rgba(78, 213, 197, 0.15) 0%, transparent 50%),
|
|
40
|
+
radial-gradient(circle at 80% 80%, rgba(78, 213, 197, 0.1) 0%, transparent 50%);
|
|
41
|
+
animation: float 20s ease-in-out infinite;
|
|
42
|
+
z-index: 0;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
@keyframes float {
|
|
46
|
+
0%, 100% { transform: translate(0, 0) rotate(0deg); }
|
|
47
|
+
33% { transform: translate(30px, -30px) rotate(120deg); }
|
|
48
|
+
66% { transform: translate(-20px, 20px) rotate(240deg); }
|
|
31
49
|
}
|
|
32
50
|
|
|
33
51
|
.wrapper {
|
|
34
|
-
padding:
|
|
52
|
+
padding: 20px;
|
|
53
|
+
position: relative;
|
|
54
|
+
z-index: 1;
|
|
55
|
+
width: 100%;
|
|
56
|
+
max-width: 1200px;
|
|
35
57
|
}
|
|
36
58
|
|
|
37
|
-
.
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
border: 1px solid rgba(255, 255, 255, 0.07);
|
|
44
|
-
animation: fadeIn 0.5s ease;
|
|
59
|
+
.container {
|
|
60
|
+
display: grid;
|
|
61
|
+
grid-template-columns: 1fr 1fr;
|
|
62
|
+
gap: 60px;
|
|
63
|
+
align-items: center;
|
|
64
|
+
animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);
|
|
45
65
|
}
|
|
46
66
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
67
|
+
@keyframes slideUp {
|
|
68
|
+
from {
|
|
69
|
+
opacity: 0;
|
|
70
|
+
transform: translateY(30px);
|
|
71
|
+
}
|
|
72
|
+
to {
|
|
73
|
+
opacity: 1;
|
|
74
|
+
transform: translateY(0);
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
/* القسم الأيسر - الرقم 404 */
|
|
79
|
+
.left-section {
|
|
80
|
+
position: relative;
|
|
81
|
+
display: flex;
|
|
82
|
+
justify-content: center;
|
|
83
|
+
align-items: center;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.glitch-wrapper {
|
|
87
|
+
position: relative;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.glitch-number {
|
|
91
|
+
font-size: clamp(120px, 20vw, 280px);
|
|
92
|
+
font-weight: 900;
|
|
93
|
+
line-height: 1;
|
|
94
|
+
background: linear-gradient(135deg, #4ed5c5 0%, #3bbcad 50%, #4ed5c5 100%);
|
|
95
|
+
-webkit-background-clip: text;
|
|
96
|
+
-webkit-text-fill-color: transparent;
|
|
97
|
+
background-clip: text;
|
|
98
|
+
position: relative;
|
|
99
|
+
filter: drop-shadow(0 0 40px rgba(78, 213, 197, 0.4));
|
|
100
|
+
animation: pulse 3s ease-in-out infinite;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
@keyframes pulse {
|
|
104
|
+
0%, 100% {
|
|
105
|
+
filter: drop-shadow(0 0 40px rgba(78, 213, 197, 0.4));
|
|
106
|
+
transform: scale(1);
|
|
107
|
+
}
|
|
108
|
+
50% {
|
|
109
|
+
filter: drop-shadow(0 0 60px rgba(78, 213, 197, 0.6));
|
|
110
|
+
transform: scale(1.02);
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
/* دوائر ديكور متحركة */
|
|
115
|
+
.circle {
|
|
116
|
+
position: absolute;
|
|
117
|
+
border-radius: 50%;
|
|
118
|
+
border: 2px solid rgba(78, 213, 197, 0.2);
|
|
119
|
+
animation: rotate 20s linear infinite;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.circle-1 {
|
|
123
|
+
width: 300px;
|
|
124
|
+
height: 300px;
|
|
125
|
+
top: 50%;
|
|
126
|
+
left: 50%;
|
|
127
|
+
transform: translate(-50%, -50%);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.circle-2 {
|
|
131
|
+
width: 400px;
|
|
132
|
+
height: 400px;
|
|
133
|
+
top: 50%;
|
|
134
|
+
left: 50%;
|
|
135
|
+
transform: translate(-50%, -50%);
|
|
136
|
+
animation-direction: reverse;
|
|
137
|
+
animation-duration: 25s;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
@keyframes rotate {
|
|
141
|
+
from { transform: translate(-50%, -50%) rotate(0deg); }
|
|
142
|
+
to { transform: translate(-50%, -50%) rotate(360deg); }
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
/* القسم الأيمن - المحتوى */
|
|
146
|
+
.right-section {
|
|
147
|
+
text-align: right;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.content-card {
|
|
151
|
+
background: rgba(255, 255, 255, 0.04);
|
|
152
|
+
backdrop-filter: blur(20px);
|
|
153
|
+
border-radius: 24px;
|
|
154
|
+
padding: clamp(32px, 5vw, 50px);
|
|
155
|
+
border: 1px solid rgba(78, 213, 197, 0.15);
|
|
156
|
+
position: relative;
|
|
157
|
+
overflow: hidden;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.content-card::before {
|
|
161
|
+
content: '';
|
|
162
|
+
position: absolute;
|
|
163
|
+
top: 0;
|
|
164
|
+
right: 0;
|
|
165
|
+
width: 100%;
|
|
166
|
+
height: 3px;
|
|
167
|
+
background: linear-gradient(90deg, #4ed5c5, transparent);
|
|
168
|
+
animation: shimmer 3s ease-in-out infinite;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
@keyframes shimmer {
|
|
172
|
+
0%, 100% { transform: translateX(100%); opacity: 0; }
|
|
173
|
+
50% { transform: translateX(-100%); opacity: 1; }
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.badge {
|
|
177
|
+
display: inline-block;
|
|
178
|
+
padding: 8px 16px;
|
|
179
|
+
background: rgba(78, 213, 197, 0.15);
|
|
180
|
+
border: 1px solid rgba(78, 213, 197, 0.3);
|
|
181
|
+
border-radius: 20px;
|
|
182
|
+
font-size: 13px;
|
|
183
|
+
font-weight: 600;
|
|
51
184
|
color: #4ed5c5;
|
|
52
|
-
|
|
185
|
+
margin-bottom: 20px;
|
|
186
|
+
letter-spacing: 0.5px;
|
|
53
187
|
}
|
|
54
188
|
|
|
55
189
|
h2 {
|
|
56
|
-
font-size:
|
|
57
|
-
margin-
|
|
58
|
-
|
|
59
|
-
font-weight: 600;
|
|
190
|
+
font-size: clamp(28px, 4vw, 42px);
|
|
191
|
+
margin-bottom: 16px;
|
|
192
|
+
font-weight: 800;
|
|
60
193
|
color: #e9fffb;
|
|
194
|
+
letter-spacing: -1px;
|
|
195
|
+
line-height: 1.2;
|
|
61
196
|
}
|
|
62
197
|
|
|
63
198
|
p {
|
|
64
199
|
color: #c3e9e4;
|
|
65
|
-
font-size: 15px;
|
|
66
|
-
margin:
|
|
67
|
-
line-height: 1.
|
|
200
|
+
font-size: clamp(15px, 2vw, 17px);
|
|
201
|
+
margin-bottom: 32px;
|
|
202
|
+
line-height: 1.8;
|
|
203
|
+
opacity: 0.9;
|
|
68
204
|
}
|
|
69
205
|
|
|
70
|
-
|
|
71
|
-
display:
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
206
|
+
.btn-group {
|
|
207
|
+
display: flex;
|
|
208
|
+
gap: 16px;
|
|
209
|
+
flex-wrap: wrap;
|
|
210
|
+
justify-content: flex-end;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.btn {
|
|
214
|
+
display: inline-flex;
|
|
215
|
+
align-items: center;
|
|
216
|
+
gap: 8px;
|
|
217
|
+
padding: 14px 28px;
|
|
75
218
|
font-weight: 700;
|
|
76
219
|
text-decoration: none;
|
|
77
|
-
border-radius:
|
|
220
|
+
border-radius: 12px;
|
|
78
221
|
font-size: 15px;
|
|
79
|
-
transition: 0.
|
|
222
|
+
transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
|
|
80
223
|
letter-spacing: -0.2px;
|
|
224
|
+
position: relative;
|
|
225
|
+
overflow: hidden;
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
.btn-primary {
|
|
229
|
+
background: linear-gradient(135deg, #4ed5c5 0%, #3bbcad 100%);
|
|
230
|
+
color: #001d20;
|
|
231
|
+
box-shadow: 0 10px 30px rgba(78, 213, 197, 0.3);
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
.btn-primary::before {
|
|
235
|
+
content: '';
|
|
236
|
+
position: absolute;
|
|
237
|
+
top: 0;
|
|
238
|
+
left: -100%;
|
|
239
|
+
width: 100%;
|
|
240
|
+
height: 100%;
|
|
241
|
+
background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
|
|
242
|
+
transition: left 0.5s;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
.btn-primary:hover::before {
|
|
246
|
+
left: 100%;
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
.btn-primary:hover {
|
|
250
|
+
transform: translateY(-3px);
|
|
251
|
+
box-shadow: 0 15px 40px rgba(78, 213, 197, 0.4);
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
.btn-secondary {
|
|
255
|
+
background: rgba(255, 255, 255, 0.05);
|
|
256
|
+
color: #4ed5c5;
|
|
257
|
+
border: 1px solid rgba(78, 213, 197, 0.3);
|
|
81
258
|
}
|
|
82
259
|
|
|
83
|
-
|
|
84
|
-
background
|
|
260
|
+
.btn-secondary:hover {
|
|
261
|
+
background: rgba(78, 213, 197, 0.1);
|
|
262
|
+
border-color: rgba(78, 213, 197, 0.5);
|
|
85
263
|
transform: translateY(-2px);
|
|
86
264
|
}
|
|
87
265
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
266
|
+
/* أيقونات */
|
|
267
|
+
.icon {
|
|
268
|
+
width: 20px;
|
|
269
|
+
height: 20px;
|
|
270
|
+
display: inline-block;
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
/* ريسبونسيف للموبايل */
|
|
274
|
+
@media (max-width: 968px) {
|
|
275
|
+
.container {
|
|
276
|
+
grid-template-columns: 1fr;
|
|
277
|
+
gap: 40px;
|
|
278
|
+
text-align: center;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
.right-section {
|
|
282
|
+
text-align: center;
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
.btn-group {
|
|
286
|
+
justify-content: center;
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
.circle-1,
|
|
290
|
+
.circle-2 {
|
|
291
|
+
display: none;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
.glitch-number {
|
|
295
|
+
font-size: clamp(100px, 25vw, 180px);
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
@media (max-width: 480px) {
|
|
300
|
+
.wrapper {
|
|
301
|
+
padding: 16px;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
.content-card {
|
|
305
|
+
padding: 28px 20px;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
.btn {
|
|
309
|
+
width: 100%;
|
|
310
|
+
justify-content: center;
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
.btn-group {
|
|
314
|
+
flex-direction: column;
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
/* تأثير الجزيئات العائمة */
|
|
319
|
+
.particle {
|
|
320
|
+
position: absolute;
|
|
321
|
+
width: 4px;
|
|
322
|
+
height: 4px;
|
|
323
|
+
background: #4ed5c5;
|
|
324
|
+
border-radius: 50%;
|
|
325
|
+
opacity: 0;
|
|
326
|
+
animation: particleFloat 4s ease-in-out infinite;
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
@keyframes particleFloat {
|
|
330
|
+
0% {
|
|
331
|
+
transform: translateY(0) translateX(0);
|
|
332
|
+
opacity: 0;
|
|
333
|
+
}
|
|
334
|
+
50% {
|
|
335
|
+
opacity: 0.8;
|
|
336
|
+
}
|
|
337
|
+
100% {
|
|
338
|
+
transform: translateY(-100px) translateX(50px);
|
|
339
|
+
opacity: 0;
|
|
340
|
+
}
|
|
91
341
|
}
|
|
342
|
+
|
|
343
|
+
.particle:nth-child(1) { left: 20%; animation-delay: 0s; }
|
|
344
|
+
.particle:nth-child(2) { left: 40%; animation-delay: 1s; }
|
|
345
|
+
.particle:nth-child(3) { left: 60%; animation-delay: 2s; }
|
|
346
|
+
.particle:nth-child(4) { left: 80%; animation-delay: 3s; }
|
|
92
347
|
</style>
|
|
93
348
|
</head>
|
|
94
349
|
|
|
95
350
|
<body>
|
|
351
|
+
<div class="particle"></div>
|
|
352
|
+
<div class="particle"></div>
|
|
353
|
+
<div class="particle"></div>
|
|
354
|
+
<div class="particle"></div>
|
|
355
|
+
|
|
96
356
|
<div class="wrapper">
|
|
97
|
-
<div class="
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
<
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
357
|
+
<div class="container">
|
|
358
|
+
|
|
359
|
+
<!-- القسم الأيسر -->
|
|
360
|
+
<div class="left-section">
|
|
361
|
+
<div class="glitch-wrapper">
|
|
362
|
+
<div class="circle circle-1"></div>
|
|
363
|
+
<div class="circle circle-2"></div>
|
|
364
|
+
<div class="glitch-number">404</div>
|
|
365
|
+
</div>
|
|
366
|
+
</div>
|
|
367
|
+
|
|
368
|
+
<!-- القسم الأيمن -->
|
|
369
|
+
<div class="right-section">
|
|
370
|
+
<div class="content-card">
|
|
371
|
+
<span class="badge">خطأ في الصفحة</span>
|
|
372
|
+
<h2>للأسف، هذه الصفحة غير موجودة</h2>
|
|
373
|
+
<p>
|
|
374
|
+
يبدو أن الصفحة التي تبحث عنها غير متاحة أو تم نقلها إلى مكان آخر.
|
|
375
|
+
لا تقلق، يمكنك العودة إلى الصفحة الرئيسية أو تصفح الأقسام الأخرى.
|
|
376
|
+
</p>
|
|
377
|
+
<div class="btn-group">
|
|
378
|
+
<a href="/" class="btn btn-primary">
|
|
379
|
+
<svg class="icon" fill="currentColor" viewBox="0 0 20 20">
|
|
380
|
+
<path d="M10.707 2.293a1 1 0 00-1.414 0l-7 7a1 1 0 001.414 1.414L4 10.414V17a1 1 0 001 1h2a1 1 0 001-1v-2a1 1 0 011-1h2a1 1 0 011 1v2a1 1 0 001 1h2a1 1 0 001-1v-6.586l.293.293a1 1 0 001.414-1.414l-7-7z"/>
|
|
381
|
+
</svg>
|
|
382
|
+
الصفحة الرئيسية
|
|
383
|
+
</a>
|
|
384
|
+
<a href="javascript:history.back()" class="btn btn-secondary">
|
|
385
|
+
<svg class="icon" fill="currentColor" viewBox="0 0 20 20">
|
|
386
|
+
<path fill-rule="evenodd" d="M7.707 14.707a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414l4-4a1 1 0 011.414 1.414L5.414 9H17a1 1 0 110 2H5.414l2.293 2.293a1 1 0 010 1.414z" clip-rule="evenodd"/>
|
|
387
|
+
</svg>
|
|
388
|
+
العودة للخلف
|
|
389
|
+
</a>
|
|
390
|
+
</div>
|
|
391
|
+
</div>
|
|
392
|
+
</div>
|
|
393
|
+
|
|
105
394
|
</div>
|
|
106
395
|
</div>
|
|
107
396
|
</body>
|
|
@@ -7,8 +7,10 @@ const express_1 = require("express");
|
|
|
7
7
|
const currency_1 = __importDefault(require("./currency"));
|
|
8
8
|
const market_1 = __importDefault(require("./market"));
|
|
9
9
|
const lang_1 = __importDefault(require("./lang"));
|
|
10
|
+
const search_1 = __importDefault(require("./search"));
|
|
10
11
|
const router = (0, express_1.Router)();
|
|
11
12
|
router.use('/lang', lang_1.default);
|
|
12
13
|
router.use('/market', market_1.default);
|
|
13
14
|
router.use('/currency', currency_1.default);
|
|
15
|
+
router.use('/search', search_1.default);
|
|
14
16
|
exports.default = router;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const express_1 = require("express");
|
|
4
|
+
const search_controller_1 = require("../../../../controllers/localize/search.controller");
|
|
5
|
+
const router = (0, express_1.Router)();
|
|
6
|
+
router.route('/').post(search_controller_1.searchController);
|
|
7
|
+
exports.default = router;
|