110 changed files with 1937 additions and 732 deletions
@ -1,19 +1,19 @@ |
|||||
#!/usr/bin/env node
|
#!/usr/bin/env node
|
||||
|
|
||||
"use strict"; |
'use strict'; |
||||
|
|
||||
const sync = require("./sync"); |
const sync = require('./sync.js'); |
||||
const create = require("./create"); |
const create = require('./create.js'); |
||||
|
|
||||
if(process.argv[2]=='create'){ |
if (process.argv[2] == 'create') { |
||||
create(); |
create(); |
||||
}else if(process.argv[2]=='sync'){ |
} else if (process.argv[2] == 'sync') { |
||||
sync(); |
sync(); |
||||
}else{ |
} else { |
||||
console.info(` |
console.info(` |
||||
用法: npx platform [-options] |
用法: npx platform [-options] |
||||
其中选项包括: |
其中选项包括: |
||||
create 创建模版工程 |
create 创建模版工程 |
||||
sync 同步工程配置文件 |
sync 同步工程配置文件 |
||||
`);
|
`);
|
||||
} |
} |
||||
|
@ -1,14 +1,15 @@ |
|||||
{ |
{ |
||||
"menu.testcase": "Test Case", |
"menu.testcase": "Test Case", |
||||
|
"menu.testcase.openUrl": "Open At New Tab", |
||||
"menu.testcase.openNoMenuRoute": "Open No Menu Route", |
"menu.testcase.openNoMenuRoute": "Open No Menu Route", |
||||
"menu.testcase.mathEditor": "Math Formual Editor", |
"menu.testcase.mathEditor": "Math Formual Editor", |
||||
"menu.testcase.mathEditorForm": "Math Formual Editor(Form)", |
"menu.testcase.mathEditorForm": "Math Formual Editor(Form)", |
||||
"menu.testcase.form":"Form Element", |
"menu.testcase.form": "Form Element", |
||||
"menu.testcase.codemirror":"Code Mirror", |
"menu.testcase.codemirror": "Code Mirror", |
||||
"menu.testcase.loading":"Loading", |
"menu.testcase.loading": "Loading", |
||||
"menu.testcase.excel": "Excel", |
"menu.testcase.excel": "Excel", |
||||
"menu.testcase.word": "Word", |
"menu.testcase.word": "Word", |
||||
"menu.testcase.maxgraph": "Graph Editor", |
"menu.testcase.maxgraph": "Graph Editor", |
||||
|
|
||||
"route.testcase.noMenuRoute":"No Menu Route" |
"route.testcase.noMenuRoute": "No Menu Route" |
||||
} |
} |
||||
|
@ -1,14 +1,15 @@ |
|||||
{ |
{ |
||||
"menu.testcase": "測試用例", |
"menu.testcase": "測試用例", |
||||
|
"menu.testcase.openUrl": "在新標籤頁打開", |
||||
"menu.testcase.openNoMenuRoute": "打開無關聯菜單的路由", |
"menu.testcase.openNoMenuRoute": "打開無關聯菜單的路由", |
||||
"menu.testcase.mathEditor": "數學公式編輯器", |
"menu.testcase.mathEditor": "數學公式編輯器", |
||||
"menu.testcase.mathEditorForm": "數學公式編輯器(表單)", |
"menu.testcase.mathEditorForm": "數學公式編輯器(表單)", |
||||
"menu.testcase.form":"表單元素", |
"menu.testcase.form": "表單元素", |
||||
"menu.testcase.codemirror":"代碼編輯器", |
"menu.testcase.codemirror": "代碼編輯器", |
||||
"menu.testcase.loading":"正在加載", |
"menu.testcase.loading": "正在加載", |
||||
"menu.testcase.excel": "Excel", |
"menu.testcase.excel": "Excel", |
||||
"menu.testcase.word": "Word", |
"menu.testcase.word": "Word", |
||||
"menu.testcase.maxgraph": "图形编辑器", |
"menu.testcase.maxgraph": "图形编辑器", |
||||
|
|
||||
"route.testcase.noMenuRoute":"無關聯菜單路由" |
"route.testcase.noMenuRoute": "無關聯菜單路由" |
||||
} |
} |
||||
|
@ -1,14 +1,15 @@ |
|||||
{ |
{ |
||||
"menu.testcase": "测试用例", |
"menu.testcase": "测试用例", |
||||
|
"menu.testcase.openUrl": "在新标签页打开", |
||||
"menu.testcase.openNoMenuRoute": "打开无关联菜单的路由示例", |
"menu.testcase.openNoMenuRoute": "打开无关联菜单的路由示例", |
||||
"menu.testcase.mathEditor": "数学公式编辑器", |
"menu.testcase.mathEditor": "数学公式编辑器", |
||||
"menu.testcase.mathEditorForm": "数学公式编辑器(表单)", |
"menu.testcase.mathEditorForm": "数学公式编辑器(表单)", |
||||
"menu.testcase.form":"表单元素", |
"menu.testcase.form": "表单元素", |
||||
"menu.testcase.codemirror":"代码编辑器", |
"menu.testcase.codemirror": "代码编辑器", |
||||
"menu.testcase.loading":"正在加載", |
"menu.testcase.loading": "正在加載", |
||||
"menu.testcase.excel": "Excel", |
"menu.testcase.excel": "Excel", |
||||
"menu.testcase.word": "Word", |
"menu.testcase.word": "Word", |
||||
"menu.testcase.maxgraph": "图形编辑器", |
"menu.testcase.maxgraph": "图形编辑器", |
||||
|
|
||||
"route.testcase.noMenuRoute":"无关联菜单路由" |
"route.testcase.noMenuRoute": "无关联菜单路由" |
||||
} |
} |
||||
|
@ -1,14 +1,15 @@ |
|||||
{ |
{ |
||||
"menu.testcase": "Test Case", |
"menu.testcase": "Test Case", |
||||
|
"menu.testcase.openUrl": "Open At New Tab", |
||||
"menu.testcase.openNoMenuRoute": "Open No Menu Route", |
"menu.testcase.openNoMenuRoute": "Open No Menu Route", |
||||
"menu.testcase.mathEditor": "Math Formual Editor", |
"menu.testcase.mathEditor": "Math Formual Editor", |
||||
"menu.testcase.mathEditorForm": "Math Formual Editor(Form)", |
"menu.testcase.mathEditorForm": "Math Formual Editor(Form)", |
||||
"menu.testcase.form":"Form Element", |
"menu.testcase.form": "Form Element", |
||||
"menu.testcase.codemirror":"Code Mirror", |
"menu.testcase.codemirror": "Code Mirror", |
||||
"menu.testcase.loading":"Loading", |
"menu.testcase.loading": "Loading", |
||||
"menu.testcase.excel": "Excel", |
"menu.testcase.excel": "Excel", |
||||
"menu.testcase.word": "Word", |
"menu.testcase.word": "Word", |
||||
"menu.testcase.maxgraph": "Graph Editor", |
"menu.testcase.maxgraph": "Graph Editor", |
||||
|
|
||||
"route.testcase.noMenuRoute":"No Menu Route" |
"route.testcase.noMenuRoute": "No Menu Route" |
||||
} |
} |
||||
|
@ -1,14 +1,15 @@ |
|||||
{ |
{ |
||||
"menu.testcase": "測試用例", |
"menu.testcase": "測試用例", |
||||
|
"menu.testcase.openUrl": "在新標籤頁打開", |
||||
"menu.testcase.openNoMenuRoute": "打開無關聯菜單的路由", |
"menu.testcase.openNoMenuRoute": "打開無關聯菜單的路由", |
||||
"menu.testcase.mathEditor": "數學公式編輯器", |
"menu.testcase.mathEditor": "數學公式編輯器", |
||||
"menu.testcase.mathEditorForm": "數學公式編輯器(表單)", |
"menu.testcase.mathEditorForm": "數學公式編輯器(表單)", |
||||
"menu.testcase.form":"表單元素", |
"menu.testcase.form": "表單元素", |
||||
"menu.testcase.codemirror":"代碼編輯器", |
"menu.testcase.codemirror": "代碼編輯器", |
||||
"menu.testcase.loading":"正在加載", |
"menu.testcase.loading": "正在加載", |
||||
"menu.testcase.excel": "Excel", |
"menu.testcase.excel": "Excel", |
||||
"menu.testcase.word": "Word", |
"menu.testcase.word": "Word", |
||||
"menu.testcase.maxgraph": "图形编辑器", |
"menu.testcase.maxgraph": "图形编辑器", |
||||
|
|
||||
"route.testcase.noMenuRoute":"無關聯菜單路由" |
"route.testcase.noMenuRoute": "無關聯菜單路由" |
||||
} |
} |
||||
|
@ -1,14 +1,15 @@ |
|||||
{ |
{ |
||||
"menu.testcase": "测试用例", |
"menu.testcase": "测试用例", |
||||
|
"menu.testcase.openUrl": "在新标签页打开", |
||||
"menu.testcase.openNoMenuRoute": "打开无关联菜单的路由示例", |
"menu.testcase.openNoMenuRoute": "打开无关联菜单的路由示例", |
||||
"menu.testcase.mathEditor": "数学公式编辑器", |
"menu.testcase.mathEditor": "数学公式编辑器", |
||||
"menu.testcase.mathEditorForm": "数学公式编辑器(表单)", |
"menu.testcase.mathEditorForm": "数学公式编辑器(表单)", |
||||
"menu.testcase.form":"表单元素", |
"menu.testcase.form": "表单元素", |
||||
"menu.testcase.codemirror":"代码编辑器", |
"menu.testcase.codemirror": "代码编辑器", |
||||
"menu.testcase.loading":"正在加載", |
"menu.testcase.loading": "正在加載", |
||||
"menu.testcase.excel": "Excel", |
"menu.testcase.excel": "Excel", |
||||
"menu.testcase.word": "Word", |
"menu.testcase.word": "Word", |
||||
"menu.testcase.maxgraph": "图形编辑器", |
"menu.testcase.maxgraph": "图形编辑器", |
||||
|
|
||||
"route.testcase.noMenuRoute":"无关联菜单路由" |
"route.testcase.noMenuRoute": "无关联菜单路由" |
||||
} |
} |
||||
|
@ -0,0 +1,40 @@ |
|||||
|
import { onMounted } from 'vue'; |
||||
|
import { defineClientConfig } from 'vuepress/client'; |
||||
|
import 'platform-core/dist/css/platform-core.css'; |
||||
|
|
||||
|
export default defineClientConfig({ |
||||
|
async enhance({ app, router, siteData }) { |
||||
|
if (!__VUEPRESS_SSR__) { |
||||
|
// 在浏览器 window 对象中新建名为 APP 的容器变量, 用于存放平台的全局变量
|
||||
|
window.APP = { |
||||
|
configure: { |
||||
|
webContextPath: '/', |
||||
|
apiContextPaths: { |
||||
|
DEFAULT: 'http://localhost:8080/', |
||||
|
}, |
||||
|
}, |
||||
|
}; |
||||
|
|
||||
|
// 初始化 platform
|
||||
|
const platform = await import('platform-core'); |
||||
|
platform.installForVuePress(app); |
||||
|
|
||||
|
// 初始化 vue-i18n
|
||||
|
const vueI18n = await import('vue-i18n'); |
||||
|
const i18n = vueI18n.createI18n({ |
||||
|
legacy: false, |
||||
|
availableLocales: ['en', 'zh_CN', 'tw_CN'], |
||||
|
locale: 'zh_CN', |
||||
|
fallbackLocale: 'en', |
||||
|
missingWarn: false, |
||||
|
fallbackWarn: false, |
||||
|
}); |
||||
|
app.use(i18n); |
||||
|
} |
||||
|
}, |
||||
|
setup() { |
||||
|
onMounted(() => { |
||||
|
document.querySelector('#app'); |
||||
|
}); |
||||
|
}, |
||||
|
}); |
@ -0,0 +1,61 @@ |
|||||
|
import { webpackBundler } from '@vuepress/bundler-webpack'; |
||||
|
import { defaultTheme } from '@vuepress/theme-default'; |
||||
|
import { defineUserConfig } from 'vuepress'; |
||||
|
|
||||
|
export default defineUserConfig({ |
||||
|
bundler: webpackBundler({ |
||||
|
// 自定义 webpack 配置
|
||||
|
configureWebpack: (config, isServer, isBuild) => { |
||||
|
return { |
||||
|
module: { |
||||
|
// 解决 @maxgraph/core 的问题, 避免出现以下错误:
|
||||
|
// ERROR in ./node_modules/.pnpm/@maxgraph+core@0.13.0/node_modules/@maxgraph/core/dist/index.js 175:0-24
|
||||
|
// Module not found: Error: Can't resolve './types' in '/Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend/node_modules/.pnpm/@maxgraph+core@0.13.0/node_modules/@maxgraph/core/dist'
|
||||
|
// Did you mean 'types.js'?
|
||||
|
// BREAKING CHANGE: The request './types' failed to resolve only because it was resolved as fully specified
|
||||
|
// (probably because the origin is strict EcmaScript Module, e. g. a module with javascript mimetype, a '*.mjs' file, or a '*.js' file where the package.json contains '"type": "module"').
|
||||
|
// The extension in the request is mandatory for it to be fully specified.
|
||||
|
rules: [ |
||||
|
{ |
||||
|
test: /\.js$/, |
||||
|
include: /[\/\\]@maxgraph[\/\\]core/, |
||||
|
resolve: { |
||||
|
fullySpecified: false, |
||||
|
}, |
||||
|
}, |
||||
|
], |
||||
|
}, |
||||
|
// 解决 @maxgraph/core 的问题, 避免出现以下错误:
|
||||
|
// ERROR in ./node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/platform-core/dist/platform-core.js 3:428-453
|
||||
|
// Module not found: Error: Package path . is not exported from package /Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend.doc/node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/@maxgraph/core (see exports field in /Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend.doc/node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/@maxgraph/core/package.json)
|
||||
|
// 同时解决 quasar 默认加载 /dist/quasar.server.prod.cjs 文件出现错误
|
||||
|
resolve: { |
||||
|
// 以下配置使得在 node_modules 目录下的模块加载入口文件采用模块 package.json 的 exports 部分采用 import 配置加载优先
|
||||
|
modules: ['node_modules'], |
||||
|
conditionNames: ['import'], |
||||
|
}, |
||||
|
}; |
||||
|
}, |
||||
|
}), |
||||
|
|
||||
|
// 网站根
|
||||
|
base: '${base}', |
||||
|
|
||||
|
// 默认主题
|
||||
|
theme: defaultTheme(), |
||||
|
|
||||
|
// 打包目录
|
||||
|
dest: '${dest}', |
||||
|
|
||||
|
// 缓存目录
|
||||
|
cache: './.vuepress/.cache', |
||||
|
|
||||
|
// 临时目录
|
||||
|
temp: './.vuepress/.temp', |
||||
|
|
||||
|
// 服务端口
|
||||
|
port: 3000, |
||||
|
|
||||
|
// public 目录
|
||||
|
public: './public', |
||||
|
}); |
@ -0,0 +1,40 @@ |
|||||
|
import { onMounted } from 'vue'; |
||||
|
import { defineClientConfig } from 'vuepress/client'; |
||||
|
import 'platform-core/dist/css/platform-core.css'; |
||||
|
|
||||
|
export default defineClientConfig({ |
||||
|
async enhance({ app, router, siteData }) { |
||||
|
if (!__VUEPRESS_SSR__) { |
||||
|
// 在浏览器 window 对象中新建名为 APP 的容器变量, 用于存放平台的全局变量
|
||||
|
window.APP = { |
||||
|
configure: { |
||||
|
webContextPath: '/', |
||||
|
apiContextPaths: { |
||||
|
DEFAULT: 'http://localhost:8080/', |
||||
|
}, |
||||
|
}, |
||||
|
}; |
||||
|
|
||||
|
// 初始化 platform
|
||||
|
const platform = await import('platform-core'); |
||||
|
platform.installForVuePress(app); |
||||
|
|
||||
|
// 初始化 vue-i18n
|
||||
|
const vueI18n = await import('vue-i18n'); |
||||
|
const i18n = vueI18n.createI18n({ |
||||
|
legacy: false, |
||||
|
availableLocales: ['en', 'zh_CN', 'tw_CN'], |
||||
|
locale: 'zh_CN', |
||||
|
fallbackLocale: 'en', |
||||
|
missingWarn: false, |
||||
|
fallbackWarn: false, |
||||
|
}); |
||||
|
app.use(i18n); |
||||
|
} |
||||
|
}, |
||||
|
setup() { |
||||
|
onMounted(() => { |
||||
|
document.querySelector('#app'); |
||||
|
}); |
||||
|
}, |
||||
|
}); |
@ -0,0 +1,61 @@ |
|||||
|
import { webpackBundler } from '@vuepress/bundler-webpack'; |
||||
|
import { defaultTheme } from '@vuepress/theme-default'; |
||||
|
import { defineUserConfig } from 'vuepress'; |
||||
|
|
||||
|
export default defineUserConfig({ |
||||
|
bundler: webpackBundler({ |
||||
|
// 自定义 webpack 配置
|
||||
|
configureWebpack: (config, isServer, isBuild) => { |
||||
|
return { |
||||
|
module: { |
||||
|
// 解决 @maxgraph/core 的问题, 避免出现以下错误:
|
||||
|
// ERROR in ./node_modules/.pnpm/@maxgraph+core@0.13.0/node_modules/@maxgraph/core/dist/index.js 175:0-24
|
||||
|
// Module not found: Error: Can't resolve './types' in '/Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend/node_modules/.pnpm/@maxgraph+core@0.13.0/node_modules/@maxgraph/core/dist'
|
||||
|
// Did you mean 'types.js'?
|
||||
|
// BREAKING CHANGE: The request './types' failed to resolve only because it was resolved as fully specified
|
||||
|
// (probably because the origin is strict EcmaScript Module, e. g. a module with javascript mimetype, a '*.mjs' file, or a '*.js' file where the package.json contains '"type": "module"').
|
||||
|
// The extension in the request is mandatory for it to be fully specified.
|
||||
|
rules: [ |
||||
|
{ |
||||
|
test: /\.js$/, |
||||
|
include: /[\/\\]@maxgraph[\/\\]core/, |
||||
|
resolve: { |
||||
|
fullySpecified: false, |
||||
|
}, |
||||
|
}, |
||||
|
], |
||||
|
}, |
||||
|
// 解决 @maxgraph/core 的问题, 避免出现以下错误:
|
||||
|
// ERROR in ./node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/platform-core/dist/platform-core.js 3:428-453
|
||||
|
// Module not found: Error: Package path . is not exported from package /Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend.doc/node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/@maxgraph/core (see exports field in /Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend.doc/node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/@maxgraph/core/package.json)
|
||||
|
// 同时解决 quasar 默认加载 /dist/quasar.server.prod.cjs 文件出现错误
|
||||
|
resolve: { |
||||
|
// 以下配置使得在 node_modules 目录下的模块加载入口文件采用模块 package.json 的 exports 部分采用 import 配置加载优先
|
||||
|
modules: ['node_modules'], |
||||
|
conditionNames: ['import'], |
||||
|
}, |
||||
|
}; |
||||
|
}, |
||||
|
}), |
||||
|
|
||||
|
// 网站根
|
||||
|
base: '${base}', |
||||
|
|
||||
|
// 默认主题
|
||||
|
theme: defaultTheme(), |
||||
|
|
||||
|
// 打包目录
|
||||
|
dest: '${dest}', |
||||
|
|
||||
|
// 缓存目录
|
||||
|
cache: './.vuepress/.cache', |
||||
|
|
||||
|
// 临时目录
|
||||
|
temp: './.vuepress/.temp', |
||||
|
|
||||
|
// 服务端口
|
||||
|
port: 3000, |
||||
|
|
||||
|
// public 目录
|
||||
|
public: './public', |
||||
|
}); |
@ -0,0 +1,5 @@ |
|||||
|
chrome >=89 |
||||
|
edge >=88 |
||||
|
firefox >=89 |
||||
|
safari >=15 |
||||
|
ios_saf >=15 |
@ -0,0 +1,15 @@ |
|||||
|
################################################################# |
||||
|
# 强制对使用该基本代码的所有人实施一致的编码样式 |
||||
|
################################################################# |
||||
|
|
||||
|
# 顶级配置(即不集成父配置) |
||||
|
root = true |
||||
|
|
||||
|
# 针对所有文件 |
||||
|
[*] |
||||
|
charset = utf-8 # 字符集: utf-8 |
||||
|
indent_size = 2 # 缩进大小: 2 |
||||
|
indent_style = space # 缩进风格: 空格 |
||||
|
end_of_line = lf # 行结束符: 换行符 |
||||
|
insert_final_newline = true # 是否在文件的最后插入一个空行 |
||||
|
trim_trailing_whitespace = true # 是否删除行尾的空格 |
@ -0,0 +1,32 @@ |
|||||
|
# Logs |
||||
|
logs |
||||
|
*.log |
||||
|
npm-debug.log* |
||||
|
yarn-debug.log* |
||||
|
yarn-error.log* |
||||
|
pnpm-debug.log* |
||||
|
lerna-debug.log* |
||||
|
|
||||
|
node_modules |
||||
|
.DS_Store |
||||
|
dist |
||||
|
dist-ssr |
||||
|
coverage |
||||
|
*.local |
||||
|
|
||||
|
/cypress/videos/ |
||||
|
/cypress/screenshots/ |
||||
|
|
||||
|
# Editor directories and files |
||||
|
.vscode/* |
||||
|
!.vscode/extensions.json |
||||
|
.idea |
||||
|
*.suo |
||||
|
*.ntvs* |
||||
|
*.njsproj |
||||
|
*.sln |
||||
|
*.sw? |
||||
|
.vuepress |
||||
|
|
||||
|
test-results/ |
||||
|
playwright-report/ |
@ -0,0 +1,13 @@ |
|||||
|
# npm 仓库地址, 在 npm install 时使用 |
||||
|
registry=http://nexus.sc.io:8000/repository/npm-public/ |
||||
|
|
||||
|
# 用户邮箱 |
||||
|
email= |
||||
|
# publish 时无需先进行 git 代码同步检查, 可避免 publish 时使用 --no-git-checks 选项 |
||||
|
git-checks=false |
||||
|
|
||||
|
# 注意: 以下 // 不是注释,不能去掉哦 |
||||
|
# 登录 npm 仓库的用户认证信息, 在 npm publish 时使用, publish 的 npm registry 在 package.json 文件中 publishConfig 部分配置 |
||||
|
# _authToken 可通过以下命令获取 |
||||
|
# curl -X PUT -H "Content-Type:application/json" -d '{"_id":"org.couchdb.user:admin","name":"admin","password":"admin"}' http://nexus.sc.io:8000/repository/npm-releases/-/user/org.couchdb.user:admin |
||||
|
//nexus.sc.io:8000/repository/npm-releases/:_authToken=NpmToken.67c99588-56a6-3ce1-9bea-a9a6164f8090 |
@ -1,3 +0,0 @@ |
|||||
= 项目介绍 |
|
||||
|
|
||||
|
|
@ -0,0 +1,34 @@ |
|||||
|
{ |
||||
|
"name": "io.sc.platform.developer.doc", |
||||
|
"version": "8.1.49", |
||||
|
"description": "", |
||||
|
"main": "index.js", |
||||
|
"scripts": { |
||||
|
"clean": "rm -rf ./node_modules && rm -rf pnpm-lock.yaml && rm -rf .vuepress && rm -rf dist", |
||||
|
"sync": "platform sync", |
||||
|
"serve": "vuepress dev vuepress-src", |
||||
|
"build": "vuepress build vuepress-src && rm -rf dist/public/io.sc.platform.developer.doc && mv dist/public/site/ dist/public/io.sc.platform.developer.doc/", |
||||
|
"prod": "vuepress build vuepress-src && rm -rf dist/public/io.sc.platform.developer.doc && mv dist/public/site/ dist/public/io.sc.platform.developer.doc/" |
||||
|
}, |
||||
|
"keywords": [], |
||||
|
"author": "", |
||||
|
"license": "ISC", |
||||
|
"engines": { |
||||
|
"node": ">=18.19.0", |
||||
|
"pnpm": ">=7" |
||||
|
}, |
||||
|
"devDependencies": { |
||||
|
"sass": "1.79.4", |
||||
|
"sass-loader": "16.0.2", |
||||
|
"vue-loader": "17.4.2", |
||||
|
"@vuepress/bundler-webpack": "2.0.0-rc.15", |
||||
|
"@vuepress/theme-default": "2.0.0-rc.49", |
||||
|
"vuepress": "2.0.0-rc.15" |
||||
|
}, |
||||
|
"dependencies": { |
||||
|
"platform-core": "8.1.391", |
||||
|
"quasar": "2.17.0", |
||||
|
"vue": "3.5.10", |
||||
|
"vue-i18n": "10.0.3" |
||||
|
} |
||||
|
} |
After Width: | Height: | Size: 1.2 KiB |
@ -0,0 +1,12 @@ |
|||||
|
<!doctype html> |
||||
|
<html lang="en"> |
||||
|
<head> |
||||
|
<meta charset="UTF-8" /> |
||||
|
<meta http-equiv="X-UA-Compatible" content="IE=edge" /> |
||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> |
||||
|
<!-- <script src="./webjars/tailwindcss/3.4.5/tailwind.css.js"></script> --> |
||||
|
</head> |
||||
|
<body> |
||||
|
<div id="app"></div> |
||||
|
</body> |
||||
|
</html> |
After Width: | Height: | Size: 7.8 KiB |
File diff suppressed because one or more lines are too long
@ -1,5 +1,6 @@ |
|||||
{ |
{ |
||||
"permitPatterns":[ |
"permitPatterns": [ |
||||
"/help/io.sc.platform.developer.doc/**/*" |
"/help/io.sc.platform.developer.doc/**/*", |
||||
] |
"/io.sc.platform.developer.doc/**/*" |
||||
} |
] |
||||
|
} |
||||
|
@ -0,0 +1,24 @@ |
|||||
|
# 快速开始 |
||||
|
|
||||
|
<span> |
||||
|
<a class="route-link" href="/io.sc.platform.developer.doc/"> |
||||
|
<img class="vp-site-logo" src="/io.sc.platform.developer.doc/logo.svg" alt="开发者帮助文档"/> |
||||
|
<span class="vp-site-name vp-hide-mobile" aria-hidden="true">开发者帮助文档</span> |
||||
|
</a> |
||||
|
</span> |
||||
|
|
||||
|
```ts title=".vuepress/config.ts" |
||||
|
import { defaultTheme } from '@vuepress/theme-default' |
||||
|
import { defineUserConfig } from 'vuepress' |
||||
|
|
||||
|
export default defineUserConfig({ |
||||
|
title: '你好, VuePress', |
||||
|
|
||||
|
theme: defaultTheme({ |
||||
|
logo: 'https://vuejs.org/images/logo.png', |
||||
|
}), |
||||
|
}) |
||||
|
``` |
||||
|
|
||||
|
VuePress 2 已经发布 :tada: ! |
||||
|
<w-grid :auto-fetch-data="false"/> |
@ -0,0 +1,33 @@ |
|||||
|
--- |
||||
|
home: true |
||||
|
description: 页面的描述 |
||||
|
lang: zh-CN |
||||
|
heroText: 开发者帮助文档 |
||||
|
tagline: |
||||
|
heroImage: /hero.svg |
||||
|
heroHeight: 48 |
||||
|
date: 2024-09-27 |
||||
|
navbar: true |
||||
|
actions: |
||||
|
- text: 系统演示 |
||||
|
link: /zh/guide/introduction.html |
||||
|
type: secondary |
||||
|
- text: 前端 |
||||
|
link: /zh/guide/introduction.html |
||||
|
type: secondary |
||||
|
- text: 后端 |
||||
|
link: /zh/guide/introduction.html |
||||
|
type: secondary |
||||
|
features: |
||||
|
- title: 内部评级 |
||||
|
details: 以 Markdown 为中心的项目结构,以最少的配置帮助你专注于写作。 |
||||
|
link: /zh/guide/introduction.html |
||||
|
- title: 智能风控 |
||||
|
details: 享受 Vue 的开发体验,可以在 Markdown 中使用 Vue 组件,又可以使用 Vue 来开发自定义主题。 |
||||
|
- title: 风险预警 |
||||
|
details: VuePress 会为每个页面预渲染生成静态的 HTML,同时,每个页面被加载的时候,将作为 SPA 运行。 |
||||
|
- title: 风险计量 |
||||
|
details: VuePress 会为每个页面预渲染生成静态的 HTML,同时,每个页面被加载的时候,将作为 SPA 运行。 |
||||
|
- title: 全面风险 |
||||
|
details: VuePress 会为每个页面预渲染生成静态的 HTML,同时,每个页面被加载的时候,将作为 SPA 运行。 |
||||
|
--- |
@ -0,0 +1,40 @@ |
|||||
|
import { onMounted } from 'vue'; |
||||
|
import { defineClientConfig } from 'vuepress/client'; |
||||
|
import 'platform-core/dist/css/platform-core.css'; |
||||
|
|
||||
|
export default defineClientConfig({ |
||||
|
async enhance({ app, router, siteData }) { |
||||
|
if (!__VUEPRESS_SSR__) { |
||||
|
// 在浏览器 window 对象中新建名为 APP 的容器变量, 用于存放平台的全局变量
|
||||
|
window.APP = { |
||||
|
configure: { |
||||
|
webContextPath: '/', |
||||
|
apiContextPaths: { |
||||
|
DEFAULT: 'http://localhost:8080/', |
||||
|
}, |
||||
|
}, |
||||
|
}; |
||||
|
|
||||
|
// 初始化 platform
|
||||
|
const platform = await import('platform-core'); |
||||
|
platform.installForVuePress(app); |
||||
|
|
||||
|
// 初始化 vue-i18n
|
||||
|
const vueI18n = await import('vue-i18n'); |
||||
|
const i18n = vueI18n.createI18n({ |
||||
|
legacy: false, |
||||
|
availableLocales: ['en', 'zh_CN', 'tw_CN'], |
||||
|
locale: 'zh_CN', |
||||
|
fallbackLocale: 'en', |
||||
|
missingWarn: false, |
||||
|
fallbackWarn: false, |
||||
|
}); |
||||
|
app.use(i18n); |
||||
|
} |
||||
|
}, |
||||
|
setup() { |
||||
|
onMounted(() => { |
||||
|
document.querySelector('#app'); |
||||
|
}); |
||||
|
}, |
||||
|
}); |
@ -0,0 +1,61 @@ |
|||||
|
import { webpackBundler } from '@vuepress/bundler-webpack'; |
||||
|
import { defaultTheme } from '@vuepress/theme-default'; |
||||
|
import { defineUserConfig } from 'vuepress'; |
||||
|
|
||||
|
export default defineUserConfig({ |
||||
|
bundler: webpackBundler({ |
||||
|
// 自定义 webpack 配置
|
||||
|
configureWebpack: (config, isServer, isBuild) => { |
||||
|
return { |
||||
|
module: { |
||||
|
// 解决 @maxgraph/core 的问题, 避免出现以下错误:
|
||||
|
// ERROR in ./node_modules/.pnpm/@maxgraph+core@0.13.0/node_modules/@maxgraph/core/dist/index.js 175:0-24
|
||||
|
// Module not found: Error: Can't resolve './types' in '/Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend/node_modules/.pnpm/@maxgraph+core@0.13.0/node_modules/@maxgraph/core/dist'
|
||||
|
// Did you mean 'types.js'?
|
||||
|
// BREAKING CHANGE: The request './types' failed to resolve only because it was resolved as fully specified
|
||||
|
// (probably because the origin is strict EcmaScript Module, e. g. a module with javascript mimetype, a '*.mjs' file, or a '*.js' file where the package.json contains '"type": "module"').
|
||||
|
// The extension in the request is mandatory for it to be fully specified.
|
||||
|
rules: [ |
||||
|
{ |
||||
|
test: /\.js$/, |
||||
|
include: /[\/\\]@maxgraph[\/\\]core/, |
||||
|
resolve: { |
||||
|
fullySpecified: false, |
||||
|
}, |
||||
|
}, |
||||
|
], |
||||
|
}, |
||||
|
// 解决 @maxgraph/core 的问题, 避免出现以下错误:
|
||||
|
// ERROR in ./node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/platform-core/dist/platform-core.js 3:428-453
|
||||
|
// Module not found: Error: Package path . is not exported from package /Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend.doc/node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/@maxgraph/core (see exports field in /Users/wangshaoping/wspsc/workspace/wangshaoping/v8/platform/io.sc.platform.core.frontend.doc/node_modules/.pnpm/platform-core@8.1.372_rglpzkkg4umhmrchez7aoyu2m4/node_modules/@maxgraph/core/package.json)
|
||||
|
// 同时解决 quasar 默认加载 /dist/quasar.server.prod.cjs 文件出现错误
|
||||
|
resolve: { |
||||
|
// 以下配置使得在 node_modules 目录下的模块加载入口文件采用模块 package.json 的 exports 部分采用 import 配置加载优先
|
||||
|
modules: ['node_modules'], |
||||
|
conditionNames: ['import'], |
||||
|
}, |
||||
|
}; |
||||
|
}, |
||||
|
}), |
||||
|
|
||||
|
// 网站根
|
||||
|
base: '/io.sc.platform.developer.doc/', |
||||
|
|
||||
|
// 默认主题
|
||||
|
theme: defaultTheme(), |
||||
|
|
||||
|
// 打包目录
|
||||
|
dest: 'dist/public/site/', |
||||
|
|
||||
|
// 缓存目录
|
||||
|
cache: './.vuepress/.cache', |
||||
|
|
||||
|
// 临时目录
|
||||
|
temp: './.vuepress/.temp', |
||||
|
|
||||
|
// 服务端口
|
||||
|
port: 3000, |
||||
|
|
||||
|
// public 目录
|
||||
|
public: './public', |
||||
|
}); |
@ -0,0 +1,24 @@ |
|||||
|
export default { |
||||
|
// 网站标题(位于网页导航栏的左边)
|
||||
|
navigatorTitle: "开发者帮助文档", |
||||
|
// 网站 Logo 图标
|
||||
|
//logo: "/logo.svg",
|
||||
|
// 是否开启切换颜色
|
||||
|
colorModeSwitch: true, |
||||
|
|
||||
|
// 默认主题配置
|
||||
|
navbar: [ |
||||
|
{ |
||||
|
text: "首页", |
||||
|
link: "/", |
||||
|
}, |
||||
|
{ |
||||
|
text: "前端", |
||||
|
link: "/frontend", |
||||
|
}, |
||||
|
{ |
||||
|
text: "后端", |
||||
|
link: "/backend", |
||||
|
}, |
||||
|
], |
||||
|
}; |
@ -0,0 +1,5 @@ |
|||||
|
chrome >=89 |
||||
|
edge >=88 |
||||
|
firefox >=89 |
||||
|
safari >=15 |
||||
|
ios_saf >=15 |
@ -0,0 +1,15 @@ |
|||||
|
################################################################# |
||||
|
# 强制对使用该基本代码的所有人实施一致的编码样式 |
||||
|
################################################################# |
||||
|
|
||||
|
# 顶级配置(即不集成父配置) |
||||
|
root = true |
||||
|
|
||||
|
# 针对所有文件 |
||||
|
[*] |
||||
|
charset = utf-8 # 字符集: utf-8 |
||||
|
indent_size = 2 # 缩进大小: 2 |
||||
|
indent_style = space # 缩进风格: 空格 |
||||
|
end_of_line = lf # 行结束符: 换行符 |
||||
|
insert_final_newline = true # 是否在文件的最后插入一个空行 |
||||
|
trim_trailing_whitespace = true # 是否删除行尾的空格 |
@ -0,0 +1,32 @@ |
|||||
|
# Logs |
||||
|
logs |
||||
|
*.log |
||||
|
npm-debug.log* |
||||
|
yarn-debug.log* |
||||
|
yarn-error.log* |
||||
|
pnpm-debug.log* |
||||
|
lerna-debug.log* |
||||
|
|
||||
|
node_modules |
||||
|
.DS_Store |
||||
|
dist |
||||
|
dist-ssr |
||||
|
coverage |
||||
|
*.local |
||||
|
|
||||
|
/cypress/videos/ |
||||
|
/cypress/screenshots/ |
||||
|
|
||||
|
# Editor directories and files |
||||
|
.vscode/* |
||||
|
!.vscode/extensions.json |
||||
|
.idea |
||||
|
*.suo |
||||
|
*.ntvs* |
||||
|
*.njsproj |
||||
|
*.sln |
||||
|
*.sw? |
||||
|
.vuepress |
||||
|
|
||||
|
test-results/ |
||||
|
playwright-report/ |
@ -0,0 +1,13 @@ |
|||||
|
# npm 仓库地址, 在 npm install 时使用 |
||||
|
registry=http://nexus.sc.io:8000/repository/npm-public/ |
||||
|
|
||||
|
# 用户邮箱 |
||||
|
email= |
||||
|
# publish 时无需先进行 git 代码同步检查, 可避免 publish 时使用 --no-git-checks 选项 |
||||
|
git-checks=false |
||||
|
|
||||
|
# 注意: 以下 // 不是注释,不能去掉哦 |
||||
|
# 登录 npm 仓库的用户认证信息, 在 npm publish 时使用, publish 的 npm registry 在 package.json 文件中 publishConfig 部分配置 |
||||
|
# _authToken 可通过以下命令获取 |
||||
|
# curl -X PUT -H "Content-Type:application/json" -d '{"_id":"org.couchdb.user:admin","name":"admin","password":"admin"}' http://nexus.sc.io:8000/repository/npm-releases/-/user/org.couchdb.user:admin |
||||
|
//nexus.sc.io:8000/repository/npm-releases/:_authToken=NpmToken.67c99588-56a6-3ce1-9bea-a9a6164f8090 |
@ -0,0 +1,33 @@ |
|||||
|
{ |
||||
|
"name": "io.sc.website", |
||||
|
"version": "8.1.49", |
||||
|
"description": "", |
||||
|
"main": "index.js", |
||||
|
"scripts": { |
||||
|
"clean": "rm -rf ./node_modules && rm -rf pnpm-lock.yaml && rm -rf .vuepress && rm -rf dist", |
||||
|
"sync": "platform sync", |
||||
|
"serve": "vuepress dev vuepress-src", |
||||
|
"build": "vuepress build vuepress-src", |
||||
|
"prod": "vuepress build vuepress-src" |
||||
|
}, |
||||
|
"keywords": [], |
||||
|
"author": "", |
||||
|
"license": "ISC", |
||||
|
"engines": { |
||||
|
"node": ">=18.19.0", |
||||
|
"pnpm": ">=7" |
||||
|
}, |
||||
|
"devDependencies": { |
||||
|
"sass": "1.79.4", |
||||
|
"sass-loader": "16.0.2", |
||||
|
"vue-loader": "17.4.2", |
||||
|
"platform-core": "8.1.385", |
||||
|
"@vuepress/bundler-webpack": "2.0.0-rc.15", |
||||
|
"@vuepress/theme-default": "2.0.0-rc.49", |
||||
|
"vuepress": "2.0.0-rc.15" |
||||
|
}, |
||||
|
"dependencies": { |
||||
|
"vue": "3.5.10", |
||||
|
"platform-core": "8.1.391" |
||||
|
} |
||||
|
} |
After Width: | Height: | Size: 1.2 KiB |
Some files were not shown because too many files changed in this diff
Loading…
Reference in new issue