@oipage/cli 0.2.1 → 0.3.0-alpha.2

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.
Files changed (73) hide show
  1. package/.github/FUNDING.yml +11 -11
  2. package/AUTHORS.txt +6 -6
  3. package/CHANGELOG +40 -21
  4. package/LICENSE +20 -20
  5. package/README.md +132 -132
  6. package/bin/WebSocket/decodeWsFrame.js +43 -43
  7. package/bin/WebSocket/encodeWsFrame.js +28 -28
  8. package/bin/WebSocket/headersToJSON.js +26 -26
  9. package/bin/WebSocket/index.js +106 -83
  10. package/bin/data/mineTypes.json +104 -104
  11. package/bin/disk.js +42 -42
  12. package/bin/help.js +53 -50
  13. package/bin/intercept.js +15 -15
  14. package/bin/network.js +21 -21
  15. package/bin/notebook/index.js +9 -0
  16. package/bin/proxy.js +82 -75
  17. package/bin/run +142 -134
  18. package/bin/serve.js +245 -195
  19. package/bin/template/404.html +184 -184
  20. package/bin/tools/deleteEmptyFolder.js +33 -33
  21. package/bin/tools/format.js +75 -75
  22. package/bin/tools/network.js +42 -42
  23. package/bin/tools/openBrowser.js +34 -25
  24. package/bin/tools/resolve404.js +98 -83
  25. package/bin/tools/resolveImport.js +89 -88
  26. package/bin/website-htmls/components/ui-select-file/index.html +8 -8
  27. package/bin/website-htmls/components/ui-select-file/index.js +42 -42
  28. package/bin/website-htmls/components/ui-select-file/index.scss +44 -44
  29. package/bin/website-htmls/dialogs/imageSize/index.html +54 -54
  30. package/bin/website-htmls/dialogs/imageSize/index.js +53 -53
  31. package/bin/website-htmls/dialogs/imageSize/index.scss +140 -140
  32. package/bin/website-htmls/dialogs/index.js +52 -52
  33. package/bin/website-htmls/images/addFile.svg +1 -1
  34. package/bin/website-htmls/images/img-to-pdf.svg +1 -1
  35. package/bin/website-htmls/index.html +17 -17
  36. package/bin/website-htmls/main.js +13 -13
  37. package/bin/website-htmls/pages/App/index.html +6 -6
  38. package/bin/website-htmls/pages/App/index.js +22 -22
  39. package/bin/website-htmls/pages/App/index.scss +43 -43
  40. package/bin/website-htmls/pages/appStore/index.html +7 -7
  41. package/bin/website-htmls/pages/appStore/index.js +19 -19
  42. package/bin/website-htmls/pages/appStore/index.scss +54 -54
  43. package/bin/website-htmls/pages/chart/index.html +8 -8
  44. package/bin/website-htmls/pages/chart/index.js +72 -72
  45. package/bin/website-htmls/pages/chart/index.scss +71 -71
  46. package/bin/website-htmls/pages/home/index.html +19 -19
  47. package/bin/website-htmls/pages/home/index.js +19 -19
  48. package/bin/website-htmls/pages/home/index.scss +87 -87
  49. package/bin/website-htmls/pages/image-editor/index.html +27 -27
  50. package/bin/website-htmls/pages/image-editor/index.js +106 -106
  51. package/bin/website-htmls/pages/image-editor/index.scss +69 -69
  52. package/bin/website-htmls/pages/img-to-pdf/index.html +3 -3
  53. package/bin/website-htmls/pages/img-to-pdf/index.js +44 -44
  54. package/bin/website-htmls/pages/img-to-pdf/index.scss +9 -9
  55. package/bin/website-htmls/pages/recorder-screen/index.html +15 -15
  56. package/bin/website-htmls/pages/recorder-screen/index.js +227 -227
  57. package/bin/website-htmls/pages/recorder-screen/index.scss +52 -52
  58. package/bin/website-htmls/router.config.js +29 -29
  59. package/bin/website-htmls/styles/common.css +44 -44
  60. package/bin/website-htmls/styles/normalize.css +94 -94
  61. package/bin/website-plugins/intercept/chart.js +33 -33
  62. package/bin/website-plugins/intercept/getPackage.js +17 -17
  63. package/bin/website-plugins/intercept/head.js +8 -8
  64. package/bin/website-plugins/intercept/index.js +8 -8
  65. package/bin/website-plugins/intercept/oipage-vislite-intercept.js +55 -55
  66. package/bin/website-plugins/intercept/oipage-zipaper-intercept.js +36 -36
  67. package/bin/website-plugins/loader/index.js +11 -11
  68. package/bin/website-plugins/loader/oipage-html-loader.js +7 -7
  69. package/bin/website-plugins/loader/oipage-scss-loader.js +149 -149
  70. package/docs/config.md +84 -84
  71. package/package.json +42 -42
  72. package/src/index.js +28 -28
  73. package/types/serve.d.ts +76 -76
@@ -1,26 +1,35 @@
1
- const { exec } = require('child_process');
2
- const os = require('os');
3
-
4
- module.exports = function (url) {
5
- const platform = os.platform();
6
- let command;
7
-
8
- switch (platform) {
9
- case 'win32': // Windows
10
- command = `start ${url}`;
11
- break;
12
- case 'darwin': // macOS
13
- command = `open ${url}`;
14
- break;
15
- default: // Linux及其他
16
- command = `xdg-open ${url}`;
17
- }
18
-
19
- exec(command, (error) => {
20
- if (error) {
21
- console.error(`无法打开浏览器: ${error}`);
22
- } else {
23
- // todo
24
- }
25
- });
1
+ const { exec } = require('child_process');
2
+ const os = require('os');
3
+
4
+ module.exports = function (url) {
5
+
6
+ // 防止命令注入
7
+ // 对 URL 进行严格校验(仅允许 http:// 或 https:// 开头,拒绝特殊字符)
8
+ // 2026年8月9日 于南宁
9
+ if (/^http:\/\//.test(url) || /^https:\/\//.test(url)) {
10
+
11
+ const platform = os.platform();
12
+ let command;
13
+
14
+ switch (platform) {
15
+ case 'win32': // Windows
16
+ command = `start ${url}`;
17
+ break;
18
+ case 'darwin': // macOS
19
+ command = `open ${url}`;
20
+ break;
21
+ default: // Linux及其他
22
+ command = `xdg-open ${url}`;
23
+ }
24
+
25
+ exec(command, (error) => {
26
+ if (error) {
27
+ console.error(`无法打开浏览器: ${error}`);
28
+ } else {
29
+ // todo
30
+ }
31
+ });
32
+ } else {
33
+ console.error('请输入正确的url');
34
+ }
26
35
  }
@@ -1,84 +1,99 @@
1
- const { readdirSync, lstatSync, readFileSync, statSync } = require("fs");
2
- const { join } = require("path");
3
- const { formatByte, formatTime } = require("./format");
4
- const mineTypes = require("../data/mineTypes.json");
5
-
6
- const img_folder = "data:image/png;base64," + readFileSync(join(__dirname, "../images/folder.png")).toString('base64');
7
- const img_file = "data:image/png;base64," + readFileSync(join(__dirname, "../images/file.png")).toString('base64');
8
-
9
- const template_404 = readFileSync(join(__dirname, "../template/404.html"), {
10
- encoding: "utf8"
11
- })
12
- .replace("${img_folder}", img_folder)
13
- .replace("${img_file}", img_file);
14
-
15
- module.exports = function (filePath, url, website, name) {
16
-
17
- let subItems = [];
18
-
19
- try {
20
- subItems = readdirSync(filePath);
21
- console.log("<i> \x1b[1m\x1b[32m[" + name + "-http-server] Read Folder: " + url + '\x1b[0m ' + new Date().toLocaleString());
22
- } catch (e) {
23
- console.log("<i> \x1b[1m\x1b[32m[" + name + "-http-server] Read " + (/\/$/.test(url) ? "Folder" : "File") + ": \x1b[35m" + url + ' 404 Not Found\x1b[0m ' + new Date().toLocaleString());
24
- try {
25
- if (!/\/$/.test(url) || url === "/") {
26
- filePath = join(filePath, "../");
27
- subItems = readdirSync(filePath);
28
- }
29
- } catch (e) { }
30
- }
31
-
32
- let template = "";
33
- for (let i in subItems) {
34
- let isDirectory = lstatSync(join(filePath, subItems[i])).isDirectory();
35
- let statObj = statSync(join(filePath, subItems[i]));
36
-
37
- // 文件夹
38
- if (isDirectory) {
39
- template += `<tr class="folder">
40
- <th class="name">
41
- <a href='./${subItems[i]}/'>${subItems[i]}</a>
42
- </th>
43
- <th>
44
- ${formatTime(statObj.mtime)}
45
- </th>
46
- <th>
47
- 文件夹
48
- </th>
49
- <th>
50
- -
51
- </th>
52
- <th>
53
- <a href='./${subItems[i]}/' class="btn">打开</a>
54
- </th>
55
- </tr>`;
56
- }
57
-
58
- // 文件
59
- else {
60
- let dotName = /\./.test(subItems[i]) ? subItems[i].match(/\.([^.]+)$/)[1] : "";
61
-
62
- template += `<tr class="file">
63
- <th class="name">
64
- <a href='./${subItems[i]}'>${subItems[i]}</a>
65
- </th>
66
- <th>
67
- ${formatTime(statObj.mtime)}
68
- </th>
69
- <th>
70
- ${mineTypes[dotName] || "text/plain"}
71
- </th>
72
- <th>
73
- ${formatByte(statObj.size)}
74
- </th>
75
- <th>
76
- <a href='./${subItems[i]}' class="btn">访问</a>
77
- <a href='./${subItems[i]}?download' class="btn" download='${subItems[i]}'>下载</a>
78
- </th>
79
- </tr>`;
80
- }
81
- }
82
-
83
- return template_404.replace("${website}", website ? '<a class="website-link" href="/_oipage_cli_website_/index.html">打开应用市场</a>' : '').replace("${current}", filePath).replace("${template}", template);
1
+ const { readdirSync, lstatSync, readFileSync, statSync } = require("fs");
2
+ const { join } = require("path");
3
+ const { formatByte, formatTime } = require("./format");
4
+ const mineTypes = require("../data/mineTypes.json");
5
+
6
+ // HTML 实体转义,防止 XSS
7
+ function escapeHtml(str) {
8
+ return String(str)
9
+ .replace(/&/g, "&amp;")
10
+ .replace(/</g, "&lt;")
11
+ .replace(/>/g, "&gt;")
12
+ .replace(/"/g, "&quot;")
13
+ .replace(/'/g, "&#39;");
14
+ }
15
+
16
+ // URL 路径编码,防止 href 属性注入
17
+ function encodePath(str) {
18
+ return encodeURIComponent(str);
19
+ }
20
+
21
+ const img_folder = "data:image/png;base64," + readFileSync(join(__dirname, "../images/folder.png")).toString('base64');
22
+ const img_file = "data:image/png;base64," + readFileSync(join(__dirname, "../images/file.png")).toString('base64');
23
+
24
+ const template_404 = readFileSync(join(__dirname, "../template/404.html"), {
25
+ encoding: "utf8"
26
+ })
27
+ .replace("${img_folder}", img_folder)
28
+ .replace("${img_file}", img_file);
29
+
30
+ module.exports = function (filePath, url, website, name, rawIp) {
31
+
32
+ let subItems = [];
33
+
34
+ try {
35
+ subItems = readdirSync(filePath);
36
+ console.log("<i> \x1b[1m\x1b[32m[" + name + "-http-server] Read Folder: " + url + '\x1b[0m ' + new Date().toLocaleString() + " " + rawIp);
37
+ } catch (e) {
38
+ console.log("<i> \x1b[1m\x1b[32m[" + name + "-http-server] Read " + (/\/$/.test(url) ? "Folder" : "File") + ": \x1b[35m" + url + ' 404 Not Found\x1b[0m ' + new Date().toLocaleString() + " " + rawIp);
39
+ try {
40
+ if (!/\/$/.test(url) || url === "/") {
41
+ filePath = join(filePath, "../");
42
+ subItems = readdirSync(filePath);
43
+ }
44
+ } catch (e) { }
45
+ }
46
+
47
+ let template = "";
48
+ for (let i in subItems) {
49
+ let isDirectory = lstatSync(join(filePath, subItems[i])).isDirectory();
50
+ let statObj = statSync(join(filePath, subItems[i]));
51
+
52
+ // 文件夹
53
+ if (isDirectory) {
54
+ template += `<tr class="folder">
55
+ <th class="name">
56
+ <a href='./${encodePath(subItems[i])}/'>${escapeHtml(subItems[i])}</a>
57
+ </th>
58
+ <th>
59
+ ${formatTime(statObj.mtime)}
60
+ </th>
61
+ <th>
62
+ 文件夹
63
+ </th>
64
+ <th>
65
+ -
66
+ </th>
67
+ <th>
68
+ <a href='./${encodePath(subItems[i])}/' class="btn">打开</a>
69
+ </th>
70
+ </tr>`;
71
+ }
72
+
73
+ // 文件
74
+ else {
75
+ let dotName = (subItems[i].match(/\.([^.]+)$/) || [])[1] || "";
76
+
77
+ template += `<tr class="file">
78
+ <th class="name">
79
+ <a href='./${encodePath(subItems[i])}'>${escapeHtml(subItems[i])}</a>
80
+ </th>
81
+ <th>
82
+ ${formatTime(statObj.mtime)}
83
+ </th>
84
+ <th>
85
+ ${mineTypes[dotName] || "text/plain"}
86
+ </th>
87
+ <th>
88
+ ${formatByte(statObj.size)}
89
+ </th>
90
+ <th>
91
+ <a href='./${encodePath(subItems[i])}' class="btn">访问</a>
92
+ <a href='./${encodePath(subItems[i])}?download' class="btn" download='${escapeHtml(subItems[i])}'>下载</a>
93
+ </th>
94
+ </tr>`;
95
+ }
96
+ }
97
+
98
+ return template_404.replace("${website}", website ? '<a class="website-link" href="/@website/index.html">打开应用市场</a>' : '').replace("${current}", escapeHtml(filePath)).replace("${template}", template);
84
99
  };
@@ -1,89 +1,90 @@
1
- const { readFileSync, existsSync, lstatSync } = require("fs");
2
- const { join } = require("path");
3
- const { testIntercept } = require("../intercept.js");
4
-
5
- module.exports = function (basePath, filePath, entry, intercept, isDownload, isWebsite) {
6
- basePath = join(basePath, "./");
7
-
8
- let source = readFileSync(filePath);
9
- let resolveImport = content => content;
10
-
11
- let __resolveImport = function (content) {
12
- return content.replace(/import [^'"]* from (['"])([^'"]*)['"]/sg, function (_importCode, _, _importUrl) {
13
- if (/^[./]/.test(_importUrl)) {
14
- return _importCode;
15
- } else {
16
- return _importCode.replace(_importUrl, _importUrl.replace(/([^/])+/s, function (npmName) {
17
-
18
- if (testIntercept(npmName, intercept)) {
19
- return (isWebsite ? "/_oipage_cli_website_/@modules/" : "/@modules/") + npmName;
20
- } else {
21
-
22
- let node_modulesRootPath = join(filePath, "../");
23
- let prePath = "";
24
- while (true) {
25
- let npmBundlePath = join(node_modulesRootPath, "./node_modules/", npmName);
26
-
27
- // 如果存在
28
- if (existsSync(npmBundlePath) && lstatSync(npmBundlePath).isDirectory()) {
29
- let npmNameValue = npmName;
30
-
31
- // 对于类似 import VISLite from "vislite"
32
- // 需要把包名解析成具体的文件
33
- if (!/\//.test(_importUrl)) {
34
- let bundlePackage = require(join(npmBundlePath, "./package.json"));
35
- npmNameValue = npmName + "/" + bundlePackage.main;
36
- }
37
-
38
- return (prePath ? prePath : "./") + "node_modules/" + npmNameValue;
39
- }
40
-
41
- if (node_modulesRootPath === basePath) {
42
-
43
- // 如果命令行根目录是一个项目
44
- let packagePath = join(basePath, "./package.json");
45
- if (existsSync(packagePath) && !lstatSync(packagePath).isDirectory()) {
46
- let bundlePackage = require(packagePath);
47
- if (!/\//.test(_importUrl)) {
48
- return "/" + bundlePackage.main;
49
- } else {
50
- return "/"
51
- }
52
- }
53
-
54
- return "/@modules/" + npmName;
55
- } else {
56
- node_modulesRootPath = join(node_modulesRootPath, "../");
57
- prePath = "../" + prePath;
58
- }
59
- }
60
-
61
- }
62
- }));
63
- }
64
- });
65
- };
66
-
67
- // 如果是下载
68
- if (isDownload) {
69
- // todo
70
- }
71
-
72
- // 如果不是直接访问的
73
- else if (!entry) {
74
- source += "";
75
- resolveImport = (content, notResolve) => notResolve ? content : __resolveImport(content);
76
- }
77
-
78
- // 如果是.html或.htm结尾
79
- else if (/\.html{0,1}$/.test(filePath)) {
80
- source = (source + "").replace(/<script type="module">(.*)<\/script>/sg, function (_, _matchCode) {
81
- return `<script type="module">${__resolveImport(_matchCode)}</script>`;
82
- });
83
- }
84
-
85
- return {
86
- source,
87
- resolveImport
88
- };
1
+ const { readFileSync, existsSync, lstatSync } = require("fs");
2
+ const { join } = require("path");
3
+ const { testIntercept } = require("../intercept.js");
4
+
5
+ module.exports = function (basePath, filePath, entry, intercept, isDownload, isWebsite) {
6
+ basePath = join(basePath, "./");
7
+
8
+ if (lstatSync(filePath).isDirectory()) { return { source: "", resolveImport: content => content }; }
9
+ let source = readFileSync(filePath);
10
+ let resolveImport = content => content;
11
+
12
+ let __resolveImport = function (content) {
13
+ return content.replace(/import [^'"]* from (['"])([^'"]*)['"]/sg, function (_importCode, _, _importUrl) {
14
+ if (/^[./]/.test(_importUrl)) {
15
+ return _importCode;
16
+ } else {
17
+ return _importCode.replace(_importUrl, _importUrl.replace(/([^/])+/s, function (npmName) {
18
+
19
+ if (testIntercept(npmName, intercept)) {
20
+ return (isWebsite ? "/@website/@modules/" : "/@modules/") + npmName;
21
+ } else {
22
+
23
+ let node_modulesRootPath = join(filePath, "../");
24
+ let prePath = "";
25
+ while (true) {
26
+ let npmBundlePath = join(node_modulesRootPath, "./node_modules/", npmName);
27
+
28
+ // 如果存在
29
+ if (existsSync(npmBundlePath) && lstatSync(npmBundlePath).isDirectory()) {
30
+ let npmNameValue = npmName;
31
+
32
+ // 对于类似 import VISLite from "vislite"
33
+ // 需要把包名解析成具体的文件
34
+ if (!/\//.test(_importUrl)) {
35
+ let bundlePackage = require(join(npmBundlePath, "./package.json"));
36
+ npmNameValue = npmName + "/" + bundlePackage.main;
37
+ }
38
+
39
+ return (prePath ? prePath : "./") + "node_modules/" + npmNameValue;
40
+ }
41
+
42
+ if (node_modulesRootPath === basePath) {
43
+
44
+ // 如果命令行根目录是一个项目
45
+ let packagePath = join(basePath, "./package.json");
46
+ if (existsSync(packagePath) && !lstatSync(packagePath).isDirectory()) {
47
+ let bundlePackage = require(packagePath);
48
+ if (!/\//.test(_importUrl)) {
49
+ return "/" + bundlePackage.main;
50
+ } else {
51
+ return "/"
52
+ }
53
+ }
54
+
55
+ return "/@modules/" + npmName;
56
+ } else {
57
+ node_modulesRootPath = join(node_modulesRootPath, "../");
58
+ prePath = "../" + prePath;
59
+ }
60
+ }
61
+
62
+ }
63
+ }));
64
+ }
65
+ });
66
+ };
67
+
68
+ // 如果是下载
69
+ if (isDownload) {
70
+ // todo
71
+ }
72
+
73
+ // 如果不是直接访问的
74
+ else if (!entry) {
75
+ source += "";
76
+ resolveImport = (content, notResolve) => notResolve ? content : __resolveImport(content);
77
+ }
78
+
79
+ // 如果是.html或.htm结尾
80
+ else if (/\.html{0,1}$/.test(filePath)) {
81
+ source = (source + "").replace(/<script type="module">(.*)<\/script>/sg, function (_, _matchCode) {
82
+ return `<script type="module">${__resolveImport(_matchCode)}</script>`;
83
+ });
84
+ }
85
+
86
+ return {
87
+ source,
88
+ resolveImport
89
+ };
89
90
  };
@@ -1,9 +1,9 @@
1
- <div class="ui-select-file-view">
2
- <h2 class="title" z-bind="_props.title"></h2>
3
- <div class="tips" z-bind="_props.tips"></div>
4
- <div class="file">
5
- <input type="file" :multiple="_props.multiple?'multiple':'none'" id="input" z-on:change.stop="doChange"
6
- z-bind:accept="accept" />
7
- <label for="input" z-bind="'选择'+_props.type+'文件'"></label>
8
- </div>
1
+ <div class="ui-select-file-view">
2
+ <h2 class="title" z-bind="_props.title"></h2>
3
+ <div class="tips" z-bind="_props.tips"></div>
4
+ <div class="file">
5
+ <input type="file" :multiple="_props.multiple?'multiple':'none'" id="input" z-on:change.stop="doChange"
6
+ z-bind:accept="accept" />
7
+ <label for="input" z-bind="'选择'+_props.type+'文件'"></label>
8
+ </div>
9
9
  </div>
@@ -1,43 +1,43 @@
1
- import { defineElement } from "zipaper";
2
- import template from "./index.html";
3
- import style from "./index.scss";
4
-
5
- export default defineElement({
6
- template,
7
- emits: ["change"],
8
- props: {
9
- title: {
10
- type: String,
11
- required: true,
12
- },
13
- tips: {
14
- type: String,
15
- required: true,
16
- },
17
- type: {
18
- type: String,
19
- required: true,
20
- },
21
- multiple: {
22
- type: Boolean,
23
- default: true
24
- }
25
- },
26
- data() {
27
- return {
28
- accept: {
29
- pdf: "application/pdf",
30
- image: "image/*",
31
- video: "video/*",
32
- }[this._props.type]
33
- };
34
- },
35
- methods: {
36
- doChange(event, target) {
37
- this.$emit("change", target.files);
38
- }
39
- },
40
- style: {
41
- content: style
42
- }
1
+ import { defineElement } from "zipaper";
2
+ import template from "./index.html";
3
+ import style from "./index.scss";
4
+
5
+ export default defineElement({
6
+ template,
7
+ emits: ["change"],
8
+ props: {
9
+ title: {
10
+ type: String,
11
+ required: true,
12
+ },
13
+ tips: {
14
+ type: String,
15
+ required: true,
16
+ },
17
+ type: {
18
+ type: String,
19
+ required: true,
20
+ },
21
+ multiple: {
22
+ type: Boolean,
23
+ default: true
24
+ }
25
+ },
26
+ data() {
27
+ return {
28
+ accept: {
29
+ pdf: "application/pdf",
30
+ image: "image/*",
31
+ video: "video/*",
32
+ }[this._props.type]
33
+ };
34
+ },
35
+ methods: {
36
+ doChange(event, target) {
37
+ this.$emit("change", target.files);
38
+ }
39
+ },
40
+ style: {
41
+ content: style
42
+ }
43
43
  });
@@ -1,45 +1,45 @@
1
- .ui-select-file-view{
2
- &>.title {
3
- text-align: center;
4
- font-weight: 700;
5
- color: rgb(26, 26, 26);
6
- font-size: 36px;
7
- line-height: 48px;
8
- padding-top: 30px;
9
- }
10
-
11
- &>.tips {
12
- text-align: center;
13
- line-height: 30px;
14
- font-size: 22px;
15
- color: rgb(26, 26, 26);
16
- font-weight: 300;
17
- }
18
-
19
- &>.file {
20
- text-align: center;
21
- margin-top: 30px;
22
-
23
- input {
24
- display: none;
25
- }
26
-
27
- label {
28
- line-height: 50px;
29
- display: inline-block;
30
- border: 1px solid gray;
31
- background-image: url("./images/addFile.svg");
32
- background-repeat: no-repeat;
33
- background-position: 5px center;
34
- background-size: auto 70%;
35
- padding-left: 40px;
36
- padding-right: 10px;
37
- border-radius: 5px;
38
-
39
- &:hover {
40
- text-decoration: underline;
41
- cursor: pointer;
42
- }
43
- }
44
- }
1
+ .ui-select-file-view{
2
+ &>.title {
3
+ text-align: center;
4
+ font-weight: 700;
5
+ color: rgb(26, 26, 26);
6
+ font-size: 36px;
7
+ line-height: 48px;
8
+ padding-top: 30px;
9
+ }
10
+
11
+ &>.tips {
12
+ text-align: center;
13
+ line-height: 30px;
14
+ font-size: 22px;
15
+ color: rgb(26, 26, 26);
16
+ font-weight: 300;
17
+ }
18
+
19
+ &>.file {
20
+ text-align: center;
21
+ margin-top: 30px;
22
+
23
+ input {
24
+ display: none;
25
+ }
26
+
27
+ label {
28
+ line-height: 50px;
29
+ display: inline-block;
30
+ border: 1px solid gray;
31
+ background-image: url("./images/addFile.svg");
32
+ background-repeat: no-repeat;
33
+ background-position: 5px center;
34
+ background-size: auto 70%;
35
+ padding-left: 40px;
36
+ padding-right: 10px;
37
+ border-radius: 5px;
38
+
39
+ &:hover {
40
+ text-decoration: underline;
41
+ cursor: pointer;
42
+ }
43
+ }
44
+ }
45
45
  }