@arcblock/result-html-pages 2.9.13 → 2.9.14
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/lib/icons.js +2 -4
- package/lib/index.js +4 -4
- package/lib/template.js +2 -3
- package/lib/translations.js +2 -3
- package/package.json +2 -2
package/lib/icons.js
CHANGED
|
@@ -4,7 +4,5 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.InfoIcon = exports.ErrorIcon = void 0;
|
|
7
|
-
const ErrorIcon = '<svg focusable="false" viewBox="0 0 24 24" aria-hidden="true" style="color: rgb(241, 110, 110); font-size: 72px;"><path d="M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm4.3 14.3c-.39.39-1.02.39-1.41 0L12 13.41 9.11 16.3c-.39.39-1.02.39-1.41 0a.9959.9959 0 010-1.41L10.59 12 7.7 9.11a.9959.9959 0 010-1.41c.39-.39 1.02-.39 1.41 0L12 10.59l2.89-2.89c.39-.39 1.02-.39 1.41 0 .39.39.39 1.02 0 1.41L13.41 12l2.89 2.89c.38.38.38 1.02 0 1.41z"></path></svg>';
|
|
8
|
-
exports.
|
|
9
|
-
const InfoIcon = '<svg focusable="false" viewBox="0 0 24 24" aria-hidden="true" style="color: rgb(7, 117, 248); font-size: 72px;"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"></path></svg>';
|
|
10
|
-
exports.InfoIcon = InfoIcon;
|
|
7
|
+
const ErrorIcon = exports.ErrorIcon = '<svg focusable="false" viewBox="0 0 24 24" aria-hidden="true" style="color: rgb(241, 110, 110); font-size: 72px;"><path d="M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm4.3 14.3c-.39.39-1.02.39-1.41 0L12 13.41 9.11 16.3c-.39.39-1.02.39-1.41 0a.9959.9959 0 010-1.41L10.59 12 7.7 9.11a.9959.9959 0 010-1.41c.39-.39 1.02-.39 1.41 0L12 10.59l2.89-2.89c.39-.39 1.02-.39 1.41 0 .39.39.39 1.02 0 1.41L13.41 12l2.89 2.89c.38.38.38 1.02 0 1.41z"></path></svg>';
|
|
8
|
+
const InfoIcon = exports.InfoIcon = '<svg focusable="false" viewBox="0 0 24 24" aria-hidden="true" style="color: rgb(7, 117, 248); font-size: 72px;"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"></path></svg>';
|
package/lib/index.js
CHANGED
|
@@ -17,11 +17,11 @@ const _excluded = ["type", "locale", "icon"],
|
|
|
17
17
|
_excluded8 = ["locale"],
|
|
18
18
|
_excluded9 = ["status", "locale"];
|
|
19
19
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
20
|
-
function ownKeys(
|
|
21
|
-
function _objectSpread(
|
|
20
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
21
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
22
22
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
23
|
-
function _toPropertyKey(
|
|
24
|
-
function _toPrimitive(
|
|
23
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : String(i); }
|
|
24
|
+
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
25
25
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
26
26
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
27
27
|
const renderHandler = _ref => {
|
package/lib/template.js
CHANGED
|
@@ -20,7 +20,6 @@ function render(_ref) {
|
|
|
20
20
|
pageTitle = pageTitle || "".concat(title, " - Blocklet Server");
|
|
21
21
|
return "\n <!DOCTYPE html>\n <html lang=\"en\">\n <head>\n <meta charset=\"UTF-8\">\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n <title>".concat(pageTitle, "</title>\n <style>\n html {\n box-sizing: border-box;\n font-size: 16px;\n }\n *, *::before, *::after {\n box-sizing: inherit;\n }\n html, body {\n height: 100%;\n }\n body {\n margin: 0;\n }\n .container {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 100%;\n padding: 16px;\n background-color: #f7f8fb;\n }\n .svg-wrapper > * {\n fill: currentColor;\n width: 1em;\n height: 1em;\n display: inline-block;\n }\n .title {\n margin-top: 24px;\n font-size: 22px;\n font-weight: 400;\n color: #47494E;\n text-align: center;\n }\n .description {\n margin-top: 8px;\n font-size: 14px;\n color: #7F828B;\n text-align: center;\n }\n .extra {\n margin-top: 24px;\n }\n </style>\n </head>\n <body>\n <div class=\"container\">\n ").concat(icon ? "<span class=\"svg-wrapper\">".concat(icon, "</span>") : '', "\n <div class=\"title\">\n ").concat(title, "\n </div>\n ").concat(description ? "<div class=\"description\">".concat(description, "</div>") : '', "\n ").concat(extra ? "<div class=\"extra\">".concat(extra, "</div>") : '', "\n ").concat(hiddenText ? "<div style=\"display:none;\">".concat(hiddenText, "</div>") : '', "\n </div>\n </body>\n </html>");
|
|
22
22
|
}
|
|
23
|
-
var _default = {
|
|
23
|
+
var _default = exports.default = {
|
|
24
24
|
render
|
|
25
|
-
};
|
|
26
|
-
exports.default = _default;
|
|
25
|
+
};
|
package/lib/translations.js
CHANGED
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
-
var _default = {
|
|
7
|
+
var _default = exports.default = {
|
|
8
8
|
en: {
|
|
9
9
|
404: {
|
|
10
10
|
title: '404 - Page Not Found',
|
|
@@ -65,5 +65,4 @@ var _default = {
|
|
|
65
65
|
description: '我们的网站正在建设中。我们很快就会在这里推出我们的新网站。'
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
|
-
};
|
|
69
|
-
exports.default = _default;
|
|
68
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@arcblock/result-html-pages",
|
|
3
|
-
"version": "2.9.
|
|
3
|
+
"version": "2.9.14",
|
|
4
4
|
"description": "This package provide a function that generates html code for common error pages such as 404, 500, etc.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"arcblock",
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"eslint-plugin-react-hooks": "^4.6.0",
|
|
41
41
|
"jest": "^28.1.3"
|
|
42
42
|
},
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "7570827021dde66a0099a84256dfceaec07fd6b3"
|
|
44
44
|
}
|