feat: api

This commit is contained in:
lisonge 2024-02-01 21:01:49 +08:00
parent 3fa5314932
commit a7e25f4d1f
30 changed files with 1610 additions and 2840 deletions

View File

@ -22,15 +22,16 @@ jobs:
- run: pnpm install
- run: pnpm exec tsx ./.vitepress/scripts/updateVersion.ts
- run: pnpm run docs:build-mirror
- run: pnpm -F @gkd-kit/docs exec tsx ./.vitepress/scripts/updateVersion.ts
- run: pnpm -F @gkd-kit/api run predocs:dev
- run: pnpm -F @gkd-kit/docs run docs:build-mirror
- name: Publish package
run: |
pnpm config set //registry.npmjs.org/:_authToken ${{ secrets.NPM_TOKEN }}
pnpm publish --no-git-checks
pnpm -F @gkd-kit/docs publish --no-git-checks
- run: git checkout .
- run: curl -X PUT 'https://registry-direct.npmmirror.com/@gkd-kit/docs/sync'
- uses: cloudflare/pages-action@v1
@ -38,4 +39,4 @@ jobs:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: gkd-docs
directory: ./.vitepress/dist
directory: ./docs/.vitepress/dist

6
.gitignore vendored
View File

@ -18,5 +18,7 @@ node_modules
*.sln
*.sw?
.eslintcache
.vitepress/dist
.vitepress/cache
docs/.vitepress/dist
docs/.vitepress/cache
/docs/api

View File

@ -1,7 +1,5 @@
# @gkd-kit/docs
# 说明
GKD 文档(尚未开发完毕), 基于 [vitepress](https://vitepress.dev/zh/) 构建, 可前往 [gkd.li](https://gkd.li/) 预览
GKD 文档(尚未开发完毕), 基于 [vitepress](https://vitepress.dev/zh/) 构建
- 使用 `pnpm i` 安装项目依赖
- 使用 `pnpm docs:dev` 启动开发服务器
- 实时修改 markdown 文件并预览站点
可前往 [gkd.li](https://gkd.li/) 预览

16
api/package.json Normal file
View File

@ -0,0 +1,16 @@
{
"name": "@gkd-kit/api",
"version": "0.0.0",
"description": "a typescript kit for gkd",
"type": "module",
"main": "./src/index.ts",
"publishConfig": {
"registry": "https://registry.npmjs.org/"
},
"scripts": {
"predocs:dev": "typedoc"
},
"volta": {
"extends": "../package.json"
}
}

386
api/pnpm-lock.yaml Normal file
View File

@ -0,0 +1,386 @@
lockfileVersion: '6.0'
settings:
autoInstallPeers: false
excludeLinksFromLockfile: false
importers:
.:
devDependencies:
'@types/node':
specifier: ^20.11.14
version: 20.11.14
prettier:
specifier: ^3.2.4
version: 3.2.4
tsx:
specifier: ^4.7.0
version: 4.7.0
typedoc:
specifier: ^0.25.7
version: 0.25.7(typescript@5.3.3)
typescript:
specifier: ^5.3.3
version: 5.3.3
examples: {}
gkd-kit: {}
packages:
/@esbuild/aix-ppc64@0.19.12:
resolution: {integrity: sha512-bmoCYyWdEL3wDQIVbcyzRyeKLgk2WtWLTWz1ZIAZF/EGbNOwSA6ew3PftJ1PqMiOOGu0OyFMzG53L0zqIpPeNA==}
engines: {node: '>=12'}
cpu: [ppc64]
os: [aix]
requiresBuild: true
dev: true
optional: true
/@esbuild/android-arm64@0.19.12:
resolution: {integrity: sha512-P0UVNGIienjZv3f5zq0DP3Nt2IE/3plFzuaS96vihvD0Hd6H/q4WXUGpCxD/E8YrSXfNyRPbpTq+T8ZQioSuPA==}
engines: {node: '>=12'}
cpu: [arm64]
os: [android]
requiresBuild: true
dev: true
optional: true
/@esbuild/android-arm@0.19.12:
resolution: {integrity: sha512-qg/Lj1mu3CdQlDEEiWrlC4eaPZ1KztwGJ9B6J+/6G+/4ewxJg7gqj8eVYWvao1bXrqGiW2rsBZFSX3q2lcW05w==}
engines: {node: '>=12'}
cpu: [arm]
os: [android]
requiresBuild: true
dev: true
optional: true
/@esbuild/android-x64@0.19.12:
resolution: {integrity: sha512-3k7ZoUW6Q6YqhdhIaq/WZ7HwBpnFBlW905Fa4s4qWJyiNOgT1dOqDiVAQFwBH7gBRZr17gLrlFCRzF6jFh7Kew==}
engines: {node: '>=12'}
cpu: [x64]
os: [android]
requiresBuild: true
dev: true
optional: true
/@esbuild/darwin-arm64@0.19.12:
resolution: {integrity: sha512-B6IeSgZgtEzGC42jsI+YYu9Z3HKRxp8ZT3cqhvliEHovq8HSX2YX8lNocDn79gCKJXOSaEot9MVYky7AKjCs8g==}
engines: {node: '>=12'}
cpu: [arm64]
os: [darwin]
requiresBuild: true
dev: true
optional: true
/@esbuild/darwin-x64@0.19.12:
resolution: {integrity: sha512-hKoVkKzFiToTgn+41qGhsUJXFlIjxI/jSYeZf3ugemDYZldIXIxhvwN6erJGlX4t5h417iFuheZ7l+YVn05N3A==}
engines: {node: '>=12'}
cpu: [x64]
os: [darwin]
requiresBuild: true
dev: true
optional: true
/@esbuild/freebsd-arm64@0.19.12:
resolution: {integrity: sha512-4aRvFIXmwAcDBw9AueDQ2YnGmz5L6obe5kmPT8Vd+/+x/JMVKCgdcRwH6APrbpNXsPz+K653Qg8HB/oXvXVukA==}
engines: {node: '>=12'}
cpu: [arm64]
os: [freebsd]
requiresBuild: true
dev: true
optional: true
/@esbuild/freebsd-x64@0.19.12:
resolution: {integrity: sha512-EYoXZ4d8xtBoVN7CEwWY2IN4ho76xjYXqSXMNccFSx2lgqOG/1TBPW0yPx1bJZk94qu3tX0fycJeeQsKovA8gg==}
engines: {node: '>=12'}
cpu: [x64]
os: [freebsd]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-arm64@0.19.12:
resolution: {integrity: sha512-EoTjyYyLuVPfdPLsGVVVC8a0p1BFFvtpQDB/YLEhaXyf/5bczaGeN15QkR+O4S5LeJ92Tqotve7i1jn35qwvdA==}
engines: {node: '>=12'}
cpu: [arm64]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-arm@0.19.12:
resolution: {integrity: sha512-J5jPms//KhSNv+LO1S1TX1UWp1ucM6N6XuL6ITdKWElCu8wXP72l9MM0zDTzzeikVyqFE6U8YAV9/tFyj0ti+w==}
engines: {node: '>=12'}
cpu: [arm]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-ia32@0.19.12:
resolution: {integrity: sha512-Thsa42rrP1+UIGaWz47uydHSBOgTUnwBwNq59khgIwktK6x60Hivfbux9iNR0eHCHzOLjLMLfUMLCypBkZXMHA==}
engines: {node: '>=12'}
cpu: [ia32]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-loong64@0.19.12:
resolution: {integrity: sha512-LiXdXA0s3IqRRjm6rV6XaWATScKAXjI4R4LoDlvO7+yQqFdlr1Bax62sRwkVvRIrwXxvtYEHHI4dm50jAXkuAA==}
engines: {node: '>=12'}
cpu: [loong64]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-mips64el@0.19.12:
resolution: {integrity: sha512-fEnAuj5VGTanfJ07ff0gOA6IPsvrVHLVb6Lyd1g2/ed67oU1eFzL0r9WL7ZzscD+/N6i3dWumGE1Un4f7Amf+w==}
engines: {node: '>=12'}
cpu: [mips64el]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-ppc64@0.19.12:
resolution: {integrity: sha512-nYJA2/QPimDQOh1rKWedNOe3Gfc8PabU7HT3iXWtNUbRzXS9+vgB0Fjaqr//XNbd82mCxHzik2qotuI89cfixg==}
engines: {node: '>=12'}
cpu: [ppc64]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-riscv64@0.19.12:
resolution: {integrity: sha512-2MueBrlPQCw5dVJJpQdUYgeqIzDQgw3QtiAHUC4RBz9FXPrskyyU3VI1hw7C0BSKB9OduwSJ79FTCqtGMWqJHg==}
engines: {node: '>=12'}
cpu: [riscv64]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-s390x@0.19.12:
resolution: {integrity: sha512-+Pil1Nv3Umes4m3AZKqA2anfhJiVmNCYkPchwFJNEJN5QxmTs1uzyy4TvmDrCRNT2ApwSari7ZIgrPeUx4UZDg==}
engines: {node: '>=12'}
cpu: [s390x]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/linux-x64@0.19.12:
resolution: {integrity: sha512-B71g1QpxfwBvNrfyJdVDexenDIt1CiDN1TIXLbhOw0KhJzE78KIFGX6OJ9MrtC0oOqMWf+0xop4qEU8JrJTwCg==}
engines: {node: '>=12'}
cpu: [x64]
os: [linux]
requiresBuild: true
dev: true
optional: true
/@esbuild/netbsd-x64@0.19.12:
resolution: {integrity: sha512-3ltjQ7n1owJgFbuC61Oj++XhtzmymoCihNFgT84UAmJnxJfm4sYCiSLTXZtE00VWYpPMYc+ZQmB6xbSdVh0JWA==}
engines: {node: '>=12'}
cpu: [x64]
os: [netbsd]
requiresBuild: true
dev: true
optional: true
/@esbuild/openbsd-x64@0.19.12:
resolution: {integrity: sha512-RbrfTB9SWsr0kWmb9srfF+L933uMDdu9BIzdA7os2t0TXhCRjrQyCeOt6wVxr79CKD4c+p+YhCj31HBkYcXebw==}
engines: {node: '>=12'}
cpu: [x64]
os: [openbsd]
requiresBuild: true
dev: true
optional: true
/@esbuild/sunos-x64@0.19.12:
resolution: {integrity: sha512-HKjJwRrW8uWtCQnQOz9qcU3mUZhTUQvi56Q8DPTLLB+DawoiQdjsYq+j+D3s9I8VFtDr+F9CjgXKKC4ss89IeA==}
engines: {node: '>=12'}
cpu: [x64]
os: [sunos]
requiresBuild: true
dev: true
optional: true
/@esbuild/win32-arm64@0.19.12:
resolution: {integrity: sha512-URgtR1dJnmGvX864pn1B2YUYNzjmXkuJOIqG2HdU62MVS4EHpU2946OZoTMnRUHklGtJdJZ33QfzdjGACXhn1A==}
engines: {node: '>=12'}
cpu: [arm64]
os: [win32]
requiresBuild: true
dev: true
optional: true
/@esbuild/win32-ia32@0.19.12:
resolution: {integrity: sha512-+ZOE6pUkMOJfmxmBZElNOx72NKpIa/HFOMGzu8fqzQJ5kgf6aTGrcJaFsNiVMH4JKpMipyK+7k0n2UXN7a8YKQ==}
engines: {node: '>=12'}
cpu: [ia32]
os: [win32]
requiresBuild: true
dev: true
optional: true
/@esbuild/win32-x64@0.19.12:
resolution: {integrity: sha512-T1QyPSDCyMXaO3pzBkF96E8xMkiRYbUEZADd29SyPGabqxMViNoii+NcK7eWJAEoU6RZyEm5lVSIjTmcdoB9HA==}
engines: {node: '>=12'}
cpu: [x64]
os: [win32]
requiresBuild: true
dev: true
optional: true
/@types/node@20.11.14:
resolution: {integrity: sha512-w3yWCcwULefjP9DmDDsgUskrMoOy5Z8MiwKHr1FvqGPtx7CvJzQvxD7eKpxNtklQxLruxSXWddyeRtyud0RcXQ==}
dependencies:
undici-types: 5.26.5
dev: true
/ansi-sequence-parser@1.1.1:
resolution: {integrity: sha512-vJXt3yiaUL4UU546s3rPXlsry/RnM730G1+HkpKE012AN0sx1eOrxSu95oKDIonskeLTijMgqWZ3uDEe3NFvyg==}
dev: true
/balanced-match@1.0.2:
resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==}
dev: true
/brace-expansion@2.0.1:
resolution: {integrity: sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==}
dependencies:
balanced-match: 1.0.2
dev: true
/esbuild@0.19.12:
resolution: {integrity: sha512-aARqgq8roFBj054KvQr5f1sFu0D65G+miZRCuJyJ0G13Zwx7vRar5Zhn2tkQNzIXcBrNVsv/8stehpj+GAjgbg==}
engines: {node: '>=12'}
hasBin: true
requiresBuild: true
optionalDependencies:
'@esbuild/aix-ppc64': 0.19.12
'@esbuild/android-arm': 0.19.12
'@esbuild/android-arm64': 0.19.12
'@esbuild/android-x64': 0.19.12
'@esbuild/darwin-arm64': 0.19.12
'@esbuild/darwin-x64': 0.19.12
'@esbuild/freebsd-arm64': 0.19.12
'@esbuild/freebsd-x64': 0.19.12
'@esbuild/linux-arm': 0.19.12
'@esbuild/linux-arm64': 0.19.12
'@esbuild/linux-ia32': 0.19.12
'@esbuild/linux-loong64': 0.19.12
'@esbuild/linux-mips64el': 0.19.12
'@esbuild/linux-ppc64': 0.19.12
'@esbuild/linux-riscv64': 0.19.12
'@esbuild/linux-s390x': 0.19.12
'@esbuild/linux-x64': 0.19.12
'@esbuild/netbsd-x64': 0.19.12
'@esbuild/openbsd-x64': 0.19.12
'@esbuild/sunos-x64': 0.19.12
'@esbuild/win32-arm64': 0.19.12
'@esbuild/win32-ia32': 0.19.12
'@esbuild/win32-x64': 0.19.12
dev: true
/fsevents@2.3.3:
resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==}
engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0}
os: [darwin]
requiresBuild: true
dev: true
optional: true
/get-tsconfig@4.7.2:
resolution: {integrity: sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A==}
dependencies:
resolve-pkg-maps: 1.0.0
dev: true
/jsonc-parser@3.2.1:
resolution: {integrity: sha512-AilxAyFOAcK5wA1+LeaySVBrHsGQvUFCDWXKpZjzaL0PqW+xfBOttn8GNtWKFWqneyMZj41MWF9Kl6iPWLwgOA==}
dev: true
/lunr@2.3.9:
resolution: {integrity: sha512-zTU3DaZaF3Rt9rhN3uBMGQD3dD2/vFQqnvZCDv4dl5iOzq2IZQqTxu90r4E5J+nP70J3ilqVCrbho2eWaeW8Ow==}
dev: true
/marked@4.3.0:
resolution: {integrity: sha512-PRsaiG84bK+AMvxziE/lCFss8juXjNaWzVbN5tXAm4XjeaS9NAHhop+PjQxz2A9h8Q4M/xGmzP8vqNwy6JeK0A==}
engines: {node: '>= 12'}
hasBin: true
dev: true
/minimatch@9.0.3:
resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==}
engines: {node: '>=16 || 14 >=14.17'}
dependencies:
brace-expansion: 2.0.1
dev: true
/prettier@3.2.4:
resolution: {integrity: sha512-FWu1oLHKCrtpO1ypU6J0SbK2d9Ckwysq6bHj/uaCP26DxrPpppCLQRGVuqAxSTvhF00AcvDRyYrLNW7ocBhFFQ==}
engines: {node: '>=14'}
hasBin: true
dev: true
/resolve-pkg-maps@1.0.0:
resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==}
dev: true
/shiki@0.14.7:
resolution: {integrity: sha512-dNPAPrxSc87ua2sKJ3H5dQ/6ZaY8RNnaAqK+t0eG7p0Soi2ydiqbGOTaZCqaYvA/uZYfS1LJnemt3Q+mSfcPCg==}
dependencies:
ansi-sequence-parser: 1.1.1
jsonc-parser: 3.2.1
vscode-oniguruma: 1.7.0
vscode-textmate: 8.0.0
dev: true
/tsx@4.7.0:
resolution: {integrity: sha512-I+t79RYPlEYlHn9a+KzwrvEwhJg35h/1zHsLC2JXvhC2mdynMv6Zxzvhv5EMV6VF5qJlLlkSnMVvdZV3PSIGcg==}
engines: {node: '>=18.0.0'}
hasBin: true
dependencies:
esbuild: 0.19.12
get-tsconfig: 4.7.2
optionalDependencies:
fsevents: 2.3.3
dev: true
/typedoc@0.25.7(typescript@5.3.3):
resolution: {integrity: sha512-m6A6JjQRg39p2ZVRIN3NKXgrN8vzlHhOS+r9ymUYtcUP/TIQPvWSq7YgE5ZjASfv5Vd5BW5xrir6Gm2XNNcOow==}
engines: {node: '>= 16'}
hasBin: true
peerDependencies:
typescript: 4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x
dependencies:
lunr: 2.3.9
marked: 4.3.0
minimatch: 9.0.3
shiki: 0.14.7
typescript: 5.3.3
dev: true
/typescript@5.3.3:
resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==}
engines: {node: '>=14.17'}
hasBin: true
dev: true
/undici-types@5.26.5:
resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==}
dev: true
/vscode-oniguruma@1.7.0:
resolution: {integrity: sha512-L9WMGRfrjOhgHSdOYgCt/yRMsXzLDJSL7BPrOZt73gU0iWO4mpqzqQzOz5srxqTvMBaR0XZTSrVWo4j55Rc6cA==}
dev: true
/vscode-textmate@8.0.0:
resolution: {integrity: sha512-AFbieoL7a5LMqcnOF04ji+rpXadgOXnZsxQr//r83kLPr7biP7am3g9zbaZIaBGwBRWeSvoMD4mgPdX3e4NWBg==}
dev: true

504
api/src/index.ts Normal file
View File

@ -0,0 +1,504 @@
/**
*
*/
export type IArray<T> = T | T[];
/**
* ()()
*/
export type RawCommonProps = {
/**
* 单位: 毫秒
*
* , action
*
* @default 1000
*/
actionCd?: number;
/**
* 单位: 毫秒
*
* 延迟执行: 查询到节点->-> action
*
*/
actionDelay?: number;
/**
*
* , `末尾属性选择器``第一个属性选择表达式` 使
*
* - [id='abc']
* - [vid='abc']
* - [text='abc']
* - [text^='abc']
* - [text*='abc']
* - [text$='abc']
*
* `A > B + C[id='x'][childCount=2]` , `A > B + C[childCount=2][id='x']`
*
* [findAccessibilityNodeInfosByViewId](https://developer.android.google.cn/reference/android/view/accessibility/AccessibilityNodeInfo#findAccessibilityNodeInfosByViewId(java.lang.String)) / [findAccessibilityNodeInfosByText](https://developer.android.google.cn/reference/android/view/accessibility/AccessibilityNodeInfo#findAccessibilityNodeInfosByText(java.lang.String)) 得到可匹配节点
*
* , , 使,
*
* [Image < &#64;View + View >2 [text*='广告']](https://github.com/gkd-kit/subscription/blob/1ae87452d287b558f58f9c4e4448a3190e212ca1/src/apps/com.zidongdianji.ts#L26) 虽然符合快速查询的条件但是使用 `findAccessibilityNodeInfosByText("广告")` 并不能查询到节点
*
* , ,
*
* 广 1-2s, [gkd-kit/gkd#60](https://github.com/gkd-kit/gkd/issues/60) 的原因
*
* ---
*
* v1.4.1 quickFind, , quickFind
*
* [![image](https://github.com/gkd-kit/subscription/assets/38517192/80cdbad1-fa8d-4415-81a1-cecaa7d69e33)](https://i.gkd.li/import/13316168)
*
*/
quickFind?: boolean;
/**
* 单位: 毫秒
*
*
*
* /, , 使
*
*/
matchDelay?: number;
/**
* 单位: 毫秒
*
* , , ,
*
* 广 activityId /广, 广,
*
*/
matchTime?: number;
/**
*
*
* action , ,
*
* matchTime, 适用于只需要执行一次的: 开屏广告//
*
* /,
*
*/
actionMaximum?: number;
/**
* matchTime/actionMaximum ,
*
* @default 'activity'
*
* @example
* 'activity'
* // 当 activity 刷新时, 唤醒规则
* // 刷新 activity 并不代表 activityId 变化
* // 如 哔哩哔哩视频播放页 底部点击推荐视频 进入另一个 视频播放页, 进入了新 activity 但是 activityId 并没有变化
*
* @example
* 'app'
* // 重新进入 app 时, 唤醒规则
*/
resetMatch?: 'activity' | 'app';
/**
* key rule cd
*
* 广 rule , rule , rule
*
* key rule actionCd=3000, rule rule , 3000 rule cd
*/
actionCdKey?: number;
/**
* key rule
*
* 广 rule , rule , rule
*
* key rule actionMaximum=1, rule rule , rule
*/
actionMaximumKey?: number;
/**
* ,
*
* order , groups , app global
*
* ,
*
* @default 0
*
*/
order?: number;
/**
* / ,
*/
snapshotUrls?: IArray<string>;
/**
* / , jpg/png/webp/gif
*
* , , -- 广 gif
*/
exampleUrls?: IArray<string>;
};
/**
*
*/
export type RawRuleProps = RawCommonProps & {
/**
*
*
* key ,
*
* ,
*/
key?: number;
/**
*
*/
name?: string;
/**
* key
*
* --, key 1,2,3, preKeys [],[1],[2]
*
* ,
*
* , , 广
*
*/
preKeys?: IArray<number>;
/**
* @example
* `click`
* // 为默认值, 如果目标节点是 clickable 的, 则使用 `clickNode`, 反之使用 `clickCenter`
* // 并且当 `clickNode` 事件没有被应用接收时, 则使用 `clickCenter`
*
* @example
* `clickNode`
* // 向系统发起一个点击无障碍节点事件. 即使节点在屏幕外部/或者被其它节点遮挡,也依然能够正确触发点击目标节点
* // 但是如果目标节点不是 clickable 的, 目标应用通常不响应这个点击事件, 也就是点击无效果
* // 在极少数情况下, 即使节点是 clickable 的,应用显示接收但是不响应节点点击事件, 此时需要手动设置 `clickCenter`
*
* @example
* `clickCenter`
* // 计算出此控件的中心的坐标并且如果这个坐标在屏幕内部,那么就向系统发起一个点击屏幕坐标事件
* // 如果这个坐标不在屏幕内部, 当作未匹配
* // 另外如果目标节点的位置被其它节点遮挡覆盖, 则会点击触发最上层的节点(可能不是目标节点)
*
* @example
* `back`
* // 向系统发起一个返回事件, 相当于按下返回键
*
* @example
* `longClick`
* // 如果目标节点是 longClickable 的, 则使用 `longClickNode`, 反之使用 `longClickCenter`
* // 并且当 `longClickNode` 事件没有被应用接收时, 则使用 `longClickCenter`
*
* @example
* `longClickNode`
* // 向系统发起一个长按无障碍节点事件,与 clickNode 类似
*
* @example
* `longClickCenter`
* // 与 clickCenter 类似, 长按时间为 400 毫秒
*/
action?:
| 'click'
| 'clickNode'
| 'clickCenter'
| 'back'
| 'longClick'
| 'longClickNode'
| 'longClickCenter';
/**
* GKD , ,
*/
matches?: IArray<string>;
/**
* GKD , ,
*/
excludeMatches?: IArray<string>;
};
/**
*
*/
export type RawGroupProps = RawCommonProps & {
/**
*
*
* /
*
* , /
*
* key ,
*/
key: number;
/**
*
*/
name: string;
/**
*
*/
desc?: string;
/**
*
*
* @default true
*/
enable?: boolean;
/**
* group key, rule
*
* group1{key=1} rule1{key=11}, group2{key=2} rule2{key=22}, rule3{key=23}
*
* group1 scopeKeys=[2] group2 , rule1 preKeys/actionCdKey/actionMaximumKey 11/22/23
*
* key rule, 使 rule, scopeKeys rule
*
*/
scopeKeys?: IArray<number>;
// rules: RawRuleProps[];
};
/**
* ()
*/
export type RawAppRuleProps = {
/**
* Id startWith activityIds ,
*
* : `undefined` () `[]` (使)
*/
activityIds?: IArray<string>;
/**
* Id startWith excludeActivityIds ,
*
* activityIds
*/
excludeActivityIds?: IArray<string>;
};
// <--全局规则相关--
/**
*
*/
export type RawGlobalApp = RawAppRuleProps & {
/**
*
*/
id: string;
/**
* /
*
* @default true
*/
enable?: boolean;
};
/**
*
*/
export type RawGlobalRuleProps = {
/**
* true =>
*
* false => apps
*
* @default true
*/
matchAnyApp?: boolean;
/**
* ,
*
* , GKD
*
* @default false
*/
matchLauncher?: boolean;
/**
* ,
*
* @default false
*/
matchSystemApp?: boolean;
/**
* ,
*/
apps?: RawGlobalApp[];
};
/**
*
*/
export type RawGlobalRule = RawRuleProps & RawGlobalRuleProps;
/**
*
*/
export type RawGlobalGroup = RawGroupProps &
RawGlobalRuleProps & {
rules: RawGlobalRule[];
};
// --全局规则相关-->
// <--APP规则相关--
/**
*
*/
export type RawCategory = {
/**
*
*
* /
*/
key: number;
/**
*
*
* , name ,
*
* : `开屏广告` `开屏广告-1` `开屏广告-2` `开屏广告-233`
*/
name: string;
/**
* null => enable
*
* true =>
*
* false =>
*/
enable?: boolean;
};
/**
*
*/
export type RawAppRule = RawRuleProps & RawAppRuleProps;
/**
*
*/
export type RawAppGroup = RawGroupProps &
RawAppRuleProps & {
/**
* string => { matches: string }
*
* string[] => { matches: string }[]
*/
rules: IArray<RawAppRule | string>;
};
/**
*
*/
export type RawApp = {
/**
*
*/
id: string;
/**
* , 使
*/
name?: string;
/**
*
*/
groups: RawAppGroup[];
};
// --APP规则相关-->
/**
*
*/
export type RawSubscription = {
/**
* , id不一致则更新失败\
* : `[0, Number.MAX_SAFE_INTEGER]`\
* : `new Date().getTime()`
*
* GKD默认订阅是 0, id 使, id
*
* 使, -2, -1
*/
id: number;
/**
*
*/
name: string;
/**
* ,
*
* version version
*/
version: number;
author?: string;
/**
* GKD , version version ,
*
* , 使
*/
updateUrl?: string;
/**
* uri , [],
*
* , uri
*/
supportUri?: string;
/**
* id version json , , , id version , updateUrl
*
*
*/
checkUpdateUrl?: string;
/**
*
*/
globalGroups?: RawGlobalGroup[];
/**
*
*/
categories?: RawCategory[];
/**
*
*/
apps?: RawApp[];
};

18
api/tsconfig.json Normal file
View File

@ -0,0 +1,18 @@
{
"compilerOptions": {
"target": "ESNext",
"lib": ["ESNext"],
"module": "ESNext",
"moduleResolution": "Bundler",
"resolveJsonModule": true,
"declaration": true,
"declarationMap": true,
"sourceMap": true,
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"strict": true,
"skipLibCheck": true,
"isolatedModules": true,
},
"include": ["./src/**/*.ts", "./tests/**/*.ts"],
}

16
api/typedoc.json Normal file
View File

@ -0,0 +1,16 @@
{
"entryPoints": ["../api/src/index.ts"],
"plugin": ["typedoc-plugin-markdown", "typedoc-vitepress-theme"],
"githubPages": false,
"readme": "none",
"indexFormat": "table",
// "useCodeBlocks": true,
"disableSources": true,
"textContentMappings": {
"title.indexPage": "API Reference",
"title.memberPage": "{name}"
},
"out": "../docs/api",
"docsRoot": "../docs",
"hideBreadcrumbs": true,
}

View File

@ -1,5 +1,8 @@
import { defineConfig } from 'vitepress';
import { mirror, transformHtml } from './plugins';
import typedocSidebar from '../api/typedoc-sidebar.json';
const logoUrl = 'https://registry.npmmirror.com/@gkd-kit/docs/0.0.1706371840771/files/.vitepress/dist/logo.svg'
// https://vitepress.dev/reference/site-config
export default defineConfig({
@ -11,15 +14,18 @@ export default defineConfig({
{
rel: 'icon',
type: 'image/svg+xml',
href: '/logo.svg',
href: logoUrl,
},
],
],
lastUpdated: true,
themeConfig: {
// https://vitepress.dev/reference/default-theme-config
logo: '/logo.svg',
nav: [{ text: '首页', link: '/' }],
logo: logoUrl,
nav: [
{ text: '首页', link: '/' },
{ text: 'API', link: '/api/' },
],
sidebar: [
{
text: '指引',
@ -30,6 +36,15 @@ export default defineConfig({
{ text: '疑难解答', link: '/faq/' },
],
},
{
text: 'API',
link: '/api/',
collapsed: true,
items: typedocSidebar.map((s) => ({
...s,
link: s.link.replace('/..\\docs\\api/', '/api/'),
})),
},
],
outline: { label: '页面导航' },
editLink: {

View File

@ -84,11 +84,7 @@ export const transformHtml = (code: string) => {
});
const links = DomUtils.findAll((e) => {
const href = e.attribs.href;
return (
e.name === 'link' &&
!!href &&
(href.startsWith('/assets/') || href.startsWith('/logo.svg'))
);
return e.name === 'link' && !!href && href.startsWith('/assets/');
}, doc.children);
links.forEach((e) => {
e.attribs.href = mirrorBaseUrl + e.attribs.href;

22
docs/package.json Normal file
View File

@ -0,0 +1,22 @@
{
"name": "@gkd-kit/docs",
"author": "lisonge",
"version": "0.0.0",
"type": "module",
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org/"
},
"files": [
"./.vitepress/dist"
],
"scripts": {
"docs:dev": "vitepress dev",
"docs:build": "vitepress build",
"docs:preview": "vitepress preview",
"docs:build-mirror": "cross-env MIRROR=ON vitepress build"
},
"volta": {
"extends": "../package.json"
}
}

428
docs/scription/api.ts Normal file
View File

@ -0,0 +1,428 @@
export type IArray<T> = T | T[];
export type RawCommonProps = {
/**
* 单位: 毫秒
*
* , action
*
* @default 1000
*/
actionCd?: number;
/**
* 单位: 毫秒
*
* 延迟执行: 查询到节点->-> action
*
*/
actionDelay?: number;
/**
*
* , `末尾属性选择器``第一个属性选择表达式` 使
*
* - [id='abc']
* - [vid='abc']
* - [text='abc']
* - [text^='abc']
* - [text*='abc']
* - [text$='abc']
*
* `A > B + C[id='x'][childCount=2]` , `A > B + C[childCount=2][id='x']`
*
* [findAccessibilityNodeInfosByViewId](https://developer.android.google.cn/reference/android/view/accessibility/AccessibilityNodeInfo#findAccessibilityNodeInfosByViewId(java.lang.String)) / [findAccessibilityNodeInfosByText](https://developer.android.google.cn/reference/android/view/accessibility/AccessibilityNodeInfo#findAccessibilityNodeInfosByText(java.lang.String)) 得到可匹配节点
*
* , , 使,
*
* [Image < &#64;View + View >2 [text*='广告']](https://github.com/gkd-kit/subscription/blob/1ae87452d287b558f58f9c4e4448a3190e212ca1/src/apps/com.zidongdianji.ts#L26) 虽然符合快速查询的条件但是使用 `findAccessibilityNodeInfosByText("广告")` 并不能查询到节点
*
* , ,
*
* 广 1-2s, [gkd-kit/gkd#60](https://github.com/gkd-kit/gkd/issues/60) 的原因
*
* ---
*
* v1.4.1 quickFind,
*
* [![image](https://github.com/gkd-kit/subscription/assets/38517192/80cdbad1-fa8d-4415-81a1-cecaa7d69e33)](https://i.gkd.li/import/13316168)
*
*/
quickFind?: boolean;
/**
* 单位: 毫秒
*
*
*
* /, , 使
*
*/
matchDelay?: number;
/**
* 单位: 毫秒
*
* , , ,
*
* 广 activityId /广, 广,
*
*/
matchTime?: number;
/**
*
*
* action , ,
*
* matchTime, 适用于只需要执行一次的: 开屏广告//
*
* /,
*
*/
actionMaximum?: number;
/**
* matchTime/actionMaximum ,
*
* @default 'activity'
*
* @example
* 'activity'
* // 当 activity 刷新时, 唤醒规则
* // 刷新 activity 并不代表 activityId 变化
* // 如 哔哩哔哩视频播放页 底部点击推荐视频 进入另一个 视频播放页, 进入了新 activity 但是 activityId 并没有变化
*
* @example
* 'app'
* // 重新进入 app 时, 唤醒规则
*/
resetMatch?: 'activity' | 'app';
/**
* key rule cd
*
* 广 rule , rule , rule
*
* key rule actionCd=3000, rule rule , 3000 rule cd
*/
actionCdKey?: number;
/**
* key rule
*
* 广 rule , rule , rule
*
* key rule actionMaximum=1, rule rule , rule
*/
actionMaximumKey?: number;
/**
* ,
*
* order , groups , app global
*
* ,
*
* @default 0
*
*/
order?: number;
/**
* / ,
*/
snapshotUrls?: IArray<string>;
/**
* / , jpg/png/webp/gif
*
* , , -- 广 gif
*/
exampleUrls?: IArray<string>;
};
export type RawRuleProps = RawCommonProps & {
/**
*
*
* key ,
*
* ,
*/
key?: number;
name?: string;
/**
* key
*
* --, key 1,2,3, preKeys [],[1],[2]
*
* ,
*
* , , 广
*
*/
preKeys?: IArray<number>;
/**
* @example
* `click`
* // 为默认值, 如果目标节点是 clickable 的, 则使用 `clickNode`, 反之使用 `clickCenter`
* // 并且当 `clickNode` 事件没有被应用接收时, 则使用 `clickCenter`
*
* @example
* `clickNode`
* // 向系统发起一个点击无障碍节点事件. 即使节点在屏幕外部/或者被其它节点遮挡,也依然能够正确触发点击目标节点
* // 但是如果目标节点不是 clickable 的, 目标 APP 通常不响应这个点击事件, 也就是点击无效果
* // 在极少数情况下, 即使节点是 clickable 的, APP 显示接收但是不响应节点点击事件, 此时需要手动设置 `clickCenter`
*
* @example
* `clickCenter`
* // 计算出此控件的中心的坐标并且如果这个坐标在屏幕内部,那么就向系统发起一个点击屏幕坐标事件
* // 如果这个坐标不在屏幕内部, 当作未匹配
* // 另外如果目标节点的位置被其它节点遮挡覆盖, 则会点击触发最上层的节点(可能不是目标节点)
*
* @example
* `back`
* // 向系统发起一个返回事件, 相当于按下返回键
*
* @example
* `longClick`
* // 如果目标节点是 longClickable 的, 则使用 `longClickNode`, 反之使用 `longClickCenter`
* // 并且当 `longClickNode` 事件没有被应用接收时, 则使用 `longClickCenter`
*
* @example
* `longClickNode`
* // 向系统发起一个长按无障碍节点事件,与 clickNode 类似
*
* @example
* `longClickCenter`
* // 与 clickCenter 类似, 长按时间为 400 毫秒
*/
action?:
| 'click'
| 'clickNode'
| 'clickCenter'
| 'back'
| 'longClick'
| 'longClickNode'
| 'longClickCenter';
/**
* GKD , ,
*/
matches?: IArray<string>;
/**
* GKD , ,
*/
excludeMatches?: IArray<string>;
};
export type RawGroupProps = RawCommonProps & {
/**
*
*
* /
*
* , /
*
* key ,
*/
key: number;
name: string;
desc?: string;
/**
* ,
*
* , 广,
*/
enable?: boolean;
/**
* group key, rule
*
* group1{key=1} rule1{key=11}, group2{key=2} rule2{key=22}, rule3{key=23}
*
* group1 scopeKeys=[2] group2 , rule1 preKeys/actionCdKey/actionMaximumKey 11/22/23
*
* key rule, 使 rule, scopeKeys rule
*
*/
scopeKeys?: IArray<number>;
// rules: RawRuleProps[];
};
export type RawAppRuleProps = {
/**
* Id startWith activityIds ,
*
* : `undefined` () `[]` (使)
*/
activityIds?: IArray<string>;
/**
* Id startWith excludeActivityIds ,
*
* activityIds
*/
excludeActivityIds?: IArray<string>;
};
// <--全局规则相关--
export type RawGlobalApp = RawAppRuleProps & {
id: string;
/**
* : `true`
*
* true => APP
*
* false => APP
*/
enable?: boolean;
};
export type RawGlobalRuleProps = {
/**
* : `true`
*
* true => APP
*
* false => apps app
*/
matchAnyApp?: boolean;
/**
* : `false`
*
* ,
*
* , GKD
*/
matchLauncher?: boolean;
/**
* : `false`
*
* ,
*/
matchSystemApp?: boolean;
apps?: RawGlobalApp[];
};
export type RawGlobalRule = RawRuleProps & RawGlobalRuleProps;
export type RawGlobalGroup = RawGroupProps &
RawGlobalRuleProps & {
apps?: RawGlobalApp[];
rules: RawGlobalRule[];
};
// --全局规则相关-->
// <--APP规则相关--
export type RawCategory = {
/**
*
*
* /
*/
key: number;
/**
*
*
* , name APP ,
*
* : `开屏广告` `开屏广告-1` `开屏广告-2` `开屏广告-233` APP
*/
name: string;
/**
* null => enable
*
* true =>
*
* false =>
*/
enable?: boolean;
};
export type RawAppRule = RawRuleProps & RawAppRuleProps;
export type RawAppGroup = RawGroupProps &
RawAppRuleProps & {
/**
* string => { matches: string }
*
* string[] => { matches: string }[]
*/
rules: IArray<RawAppRule | string>;
};
export type RawApp = {
id: string;
/**
* APP, 使 name
*/
name?: string;
groups: RawAppGroup[];
};
// --APP规则相关-->
export type RawSubscription = {
/**
* , id不一致则更新失败\
* : `[0, Number.MAX_SAFE_INTEGER]`\
* : `new Date().getTime()`
*
* GKD默认订阅是 0, id APP 使, APP id
*
* APP 使, -2, -1
*/
id: number;
/**
*
*/
name: string;
/**
* ,
*
* version version
*/
version: number;
author?: string;
/**
* GKD , version APP version ,
*
* , 使
*/
updateUrl?: string;
/**
* uri , [],
*
* , APP uri
*/
supportUri?: string;
/**
* id version json , , , id version , updateUrl
*
*
*/
checkUpdateUrl?: string;
globalGroups?: RawGlobalGroup[];
categories?: RawCategory[];
apps?: RawApp[];
};

View File

@ -1,40 +1,30 @@
{
"name": "@gkd-kit/docs",
"author": "lisonge",
"version": "0.0.0",
"name": "gkd-monorepo",
"private": true,
"type": "module",
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org/"
},
"files": [
"./.vitepress/dist"
],
"scripts": {
"docs:dev": "vitepress dev",
"docs:build": "vitepress build",
"docs:preview": "vitepress preview",
"docs:build-mirror": "cross-env MIRROR=ON vitepress build",
"format": "prettier --cache --write --ignore-unknown ."
},
"dependencies": {
"@gkd-kit/selector": "0.0.18",
"@types/node": "^20.11.5",
"@types/qrcode": "^1.5.5",
"acorn-walk": "^8.3.2",
"cross-env": "^7.0.3",
"dom-serializer": "^2.0.0",
"htmlparser2": "^9.1.0",
"magic-string": "^0.30.5",
"magic-string": "^0.30.6",
"medium-zoom": "^1.1.0",
"prettier": "^3.2.4",
"qrcode": "^1.5.3",
"typedoc": "^0.25.7",
"typedoc-plugin-markdown": "^4.0.0-next.47",
"typedoc-vitepress-theme": "^1.0.0-next.8",
"vitepress": "^1.0.0-rc.40",
"@gkd-kit/selector": "0.0.20",
"@types/node": "^20.11.15",
"prettier": "^3.2.4",
"tsx": "^4.7.0",
"typescript": "^5.3.3",
"vitepress": "^1.0.0-rc.39"
"typescript": "^5.3.3"
},
"volta": {
"node": "20.10.0"
},
"packageManager": "pnpm@8.11.0"
}
"node": "20.11.0"
}
}

View File

@ -4,49 +4,65 @@ settings:
autoInstallPeers: false
excludeLinksFromLockfile: false
dependencies:
'@gkd-kit/selector':
specifier: 0.0.18
version: 0.0.18
'@types/node':
specifier: ^20.11.5
version: 20.11.5
'@types/qrcode':
specifier: ^1.5.5
version: 1.5.5
acorn-walk:
specifier: ^8.3.2
version: 8.3.2
cross-env:
specifier: ^7.0.3
version: 7.0.3
dom-serializer:
specifier: ^2.0.0
version: 2.0.0
htmlparser2:
specifier: ^9.1.0
version: 9.1.0
magic-string:
specifier: ^0.30.5
version: 0.30.5
medium-zoom:
specifier: ^1.1.0
version: 1.1.0
prettier:
specifier: ^3.2.4
version: 3.2.4
qrcode:
specifier: ^1.5.3
version: 1.5.3
tsx:
specifier: ^4.7.0
version: 4.7.0
typescript:
specifier: ^5.3.3
version: 5.3.3
vitepress:
specifier: ^1.0.0-rc.39
version: 1.0.0-rc.39(@types/node@20.11.5)(qrcode@1.5.3)(typescript@5.3.3)
importers:
.:
dependencies:
'@gkd-kit/selector':
specifier: 0.0.20
version: 0.0.20
'@types/node':
specifier: ^20.11.15
version: 20.11.15
'@types/qrcode':
specifier: ^1.5.5
version: 1.5.5
acorn-walk:
specifier: ^8.3.2
version: 8.3.2
cross-env:
specifier: ^7.0.3
version: 7.0.3
dom-serializer:
specifier: ^2.0.0
version: 2.0.0
htmlparser2:
specifier: ^9.1.0
version: 9.1.0
magic-string:
specifier: ^0.30.6
version: 0.30.6
medium-zoom:
specifier: ^1.1.0
version: 1.1.0
prettier:
specifier: ^3.2.4
version: 3.2.4
qrcode:
specifier: ^1.5.3
version: 1.5.3
tsx:
specifier: ^4.7.0
version: 4.7.0
typedoc:
specifier: ^0.25.7
version: 0.25.7(typescript@5.3.3)
typedoc-plugin-markdown:
specifier: ^4.0.0-next.47
version: 4.0.0-next.47(typedoc@0.25.7)
typedoc-vitepress-theme:
specifier: ^1.0.0-next.8
version: 1.0.0-next.8(typedoc-plugin-markdown@4.0.0-next.47)
typescript:
specifier: ^5.3.3
version: 5.3.3
vitepress:
specifier: ^1.0.0-rc.40
version: 1.0.0-rc.40(@types/node@20.11.15)(qrcode@1.5.3)(typescript@5.3.3)
api: {}
docs: {}
packages:
@ -457,8 +473,8 @@ packages:
dev: false
optional: true
/@gkd-kit/selector@0.0.18:
resolution: {integrity: sha512-5aDHh45pkRLd82d+TLE5vbaz64PkcYZABOuqCXhsEQW8PtNMT05sTTW6WQeM+RH/IjGvULz/p9Hl8vpVm2bPCg==}
/@gkd-kit/selector@0.0.20:
resolution: {integrity: sha512-dnuEF8r0GmlC7G3AKYwQp8su0QbStjz2M2j7E/rvZ5IGr+txXxkBe69jezmZeCflRX6S0P3eWJMrZLoJNHNb3g==}
dev: false
/@jridgewell/sourcemap-codec@1.4.15:
@ -576,8 +592,8 @@ packages:
resolution: {integrity: sha512-T5k6kTXak79gwmIOaDF2UUQXFbnBE0zBUzF20pz7wDYu0RQMzWg+Ml/Pz50214NsFHBITkoi5VtdjFZnJ2ijjA==}
dev: false
/@types/node@20.11.5:
resolution: {integrity: sha512-g557vgQjUUfN76MZAN/dt1z3dzcUsimuysco0KeluHgrPdJXkP/XdAURgyO2W9fZWHRtRBiVKzKn8vyOAwlG+w==}
/@types/node@20.11.15:
resolution: {integrity: sha512-gscmuADZfvNULx1eyirVbr3kVOVZtpQtzKMCZpeSZcN6MfbkRXAR4s9/gsQ4CzxLHw6EStDtKLNtSDL3vbq05A==}
dependencies:
undici-types: 5.26.5
dev: false
@ -585,21 +601,21 @@ packages:
/@types/qrcode@1.5.5:
resolution: {integrity: sha512-CdfBi/e3Qk+3Z/fXYShipBT13OJ2fDO2Q2w5CIP5anLTLIndQG9z6P1cnm+8zCWSpm5dnxMFd/uREtb0EXuQzg==}
dependencies:
'@types/node': 20.11.5
'@types/node': 20.11.15
dev: false
/@types/web-bluetooth@0.0.20:
resolution: {integrity: sha512-g9gZnnXVq7gM7v3tJCWV/qw7w+KeOlSHAhgF9RytFyifW6AF61hdT2ucrYhPq9hLs5JIryeupHV3qGk95dH9ow==}
dev: false
/@vitejs/plugin-vue@5.0.3(vite@5.0.11)(vue@3.4.15):
/@vitejs/plugin-vue@5.0.3(vite@5.0.12)(vue@3.4.15):
resolution: {integrity: sha512-b8S5dVS40rgHdDrw+DQi/xOM9ed+kSRZzfm1T74bMmBDCd8XO87NKlFYInzCtwvtWwXZvo1QxE2OSspTATWrbA==}
engines: {node: ^18.0.0 || >=20.0.0}
peerDependencies:
vite: ^5.0.0
vue: ^3.2.25
dependencies:
vite: 5.0.11(@types/node@20.11.5)
vite: 5.0.12(@types/node@20.11.15)
vue: 3.4.15(typescript@5.3.3)
dev: false
@ -629,7 +645,7 @@ packages:
'@vue/compiler-ssr': 3.4.15
'@vue/shared': 3.4.15
estree-walker: 2.0.2
magic-string: 0.30.5
magic-string: 0.30.6
postcss: 8.4.33
source-map-js: 1.0.2
dev: false
@ -785,6 +801,10 @@ packages:
engines: {node: '>=8'}
dev: false
/ansi-sequence-parser@1.1.1:
resolution: {integrity: sha512-vJXt3yiaUL4UU546s3rPXlsry/RnM730G1+HkpKE012AN0sx1eOrxSu95oKDIonskeLTijMgqWZ3uDEe3NFvyg==}
dev: false
/ansi-styles@4.3.0:
resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==}
engines: {node: '>=8'}
@ -792,6 +812,16 @@ packages:
color-convert: 2.0.1
dev: false
/balanced-match@1.0.2:
resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==}
dev: false
/brace-expansion@2.0.1:
resolution: {integrity: sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==}
dependencies:
balanced-match: 1.0.2
dev: false
/camelcase@5.3.1:
resolution: {integrity: sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==}
engines: {node: '>=6'}
@ -972,6 +1002,10 @@ packages:
resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==}
dev: false
/jsonc-parser@3.2.1:
resolution: {integrity: sha512-AilxAyFOAcK5wA1+LeaySVBrHsGQvUFCDWXKpZjzaL0PqW+xfBOttn8GNtWKFWqneyMZj41MWF9Kl6iPWLwgOA==}
dev: false
/locate-path@5.0.0:
resolution: {integrity: sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==}
engines: {node: '>=8'}
@ -979,8 +1013,12 @@ packages:
p-locate: 4.1.0
dev: false
/magic-string@0.30.5:
resolution: {integrity: sha512-7xlpfBaQaP/T6Vh8MO/EqXSW5En6INHEvEXQiuff7Gku0PWjU3uf6w/j9o7O+SpB5fOAkrI5HeoNgwjEO0pFsA==}
/lunr@2.3.9:
resolution: {integrity: sha512-zTU3DaZaF3Rt9rhN3uBMGQD3dD2/vFQqnvZCDv4dl5iOzq2IZQqTxu90r4E5J+nP70J3ilqVCrbho2eWaeW8Ow==}
dev: false
/magic-string@0.30.6:
resolution: {integrity: sha512-n62qCLbPjNjyo+owKtveQxZFZTBm+Ms6YoGD23Wew6Vw337PElFNifQpknPruVRQV57kVShPnLGo9vWxVhpPvA==}
engines: {node: '>=12'}
dependencies:
'@jridgewell/sourcemap-codec': 1.4.15
@ -990,10 +1028,23 @@ packages:
resolution: {integrity: sha512-1I+1qpDt4idfgLQG+BNWmrqku+7/2bi5nLf4YwF8y8zXvmfiTBY3PV3ZibfrjBueCByROpuBjLLFCajqkgYoLQ==}
dev: false
/marked@4.3.0:
resolution: {integrity: sha512-PRsaiG84bK+AMvxziE/lCFss8juXjNaWzVbN5tXAm4XjeaS9NAHhop+PjQxz2A9h8Q4M/xGmzP8vqNwy6JeK0A==}
engines: {node: '>= 12'}
hasBin: true
dev: false
/medium-zoom@1.1.0:
resolution: {integrity: sha512-ewyDsp7k4InCUp3jRmwHBRFGyjBimKps/AJLjRSox+2q/2H4p/PNpQf+pwONWlJiOudkBXtbdmVbFjqyybfTmQ==}
dev: false
/minimatch@9.0.3:
resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==}
engines: {node: '>=16 || 14 >=14.17'}
dependencies:
brace-expansion: 2.0.1
dev: false
/minisearch@6.3.0:
resolution: {integrity: sha512-ihFnidEeU8iXzcVHy74dhkxh/dn8Dc08ERl0xwoMMGqp4+LvRSCgicb+zGqWthVokQKvCSxITlh3P08OzdTYCQ==}
dev: false
@ -1042,15 +1093,6 @@ packages:
engines: {node: '>=10.13.0'}
dev: false
/postcss@8.4.32:
resolution: {integrity: sha512-D/kj5JNu6oo2EIy+XL/26JEDTlIbB8hw85G8StOE6L74RQAVVP5rej6wxCNqyMbR4RkPfqvezVbPw81Ngd6Kcw==}
engines: {node: ^10 || ^12 || >=14}
dependencies:
nanoid: 3.3.7
picocolors: 1.0.0
source-map-js: 1.0.2
dev: false
/postcss@8.4.33:
resolution: {integrity: sha512-Kkpbhhdjw2qQs2O2DGX+8m5OVqEcbB9HRBvuYM9pgrjEFUg30A9LmXNlTAUj4S9kgtGyrMbTzVjH7E+s5Re2yg==}
engines: {node: ^10 || ^12 || >=14}
@ -1130,20 +1172,29 @@ packages:
engines: {node: '>=8'}
dev: false
/shikiji-core@0.9.19:
resolution: {integrity: sha512-AFJu/vcNT21t0e6YrfadZ+9q86gvPum6iywRyt1OtIPjPFe25RQnYJyxHQPMLKCCWA992TPxmEmbNcOZCAJclw==}
/shiki@0.14.7:
resolution: {integrity: sha512-dNPAPrxSc87ua2sKJ3H5dQ/6ZaY8RNnaAqK+t0eG7p0Soi2ydiqbGOTaZCqaYvA/uZYfS1LJnemt3Q+mSfcPCg==}
dependencies:
ansi-sequence-parser: 1.1.1
jsonc-parser: 3.2.1
vscode-oniguruma: 1.7.0
vscode-textmate: 8.0.0
dev: false
/shikiji-transformers@0.9.19:
resolution: {integrity: sha512-lGLI7Z8frQrIBbhZ74/eiJtxMoCQRbpaHEB+gcfvdIy+ZFaAtXncJGnc52932/UET+Y4GyKtwwC/vjWUCp+c/Q==}
dependencies:
shikiji: 0.9.19
/shikiji-core@0.10.2:
resolution: {integrity: sha512-9Of8HMlF96usXJHmCL3Gd0Fcf0EcyJUF9m8EoAKKd98mHXi0La2AZl1h6PegSFGtiYcBDK/fLuKbDa1l16r1fA==}
dev: false
/shikiji@0.9.19:
resolution: {integrity: sha512-Kw2NHWktdcdypCj1GkKpXH4o6Vxz8B8TykPlPuLHOGSV8VkhoCLcFOH4k19K4LXAQYRQmxg+0X/eM+m2sLhAkg==}
/shikiji-transformers@0.10.2:
resolution: {integrity: sha512-7IVTwl1af205ywYEq5bOAYOTOFW4V1dVX1EablP0nWKErqZeD1o93VMytxmtJomqS+YwbB8doY8SE3MFMn0aPQ==}
dependencies:
shikiji-core: 0.9.19
shikiji: 0.10.2
dev: false
/shikiji@0.10.2:
resolution: {integrity: sha512-wtZg3T0vtYV2PnqusWQs3mDaJBdCPWxFDrBM/SE5LfrX92gjUvfEMlc+vJnoKY6Z/S44OWaCRzNIsdBRWcTAiw==}
dependencies:
shikiji-core: 0.10.2
dev: false
/source-map-js@1.0.2:
@ -1187,6 +1238,36 @@ packages:
fsevents: 2.3.3
dev: false
/typedoc-plugin-markdown@4.0.0-next.47(typedoc@0.25.7):
resolution: {integrity: sha512-PkDUqxbXZuYBSR9rtxhu6PCbJyAQYwCf6ypA6/shcdCLY8vt08dHsT3W3dFY9AZ9Y4Ya9zbIs0tQufUtUzbsxw==}
peerDependencies:
typedoc: 0.25.x
dependencies:
typedoc: 0.25.7(typescript@5.3.3)
dev: false
/typedoc-vitepress-theme@1.0.0-next.8(typedoc-plugin-markdown@4.0.0-next.47):
resolution: {integrity: sha512-t7U+1rDEOCDbv1l2id2I94ylCvbo2jJayRJ1sq4Dbnt0vzxT7LAzTFdXhT5+/2WiAGnsHnVndb3ywRgEVKa8BQ==}
peerDependencies:
typedoc-plugin-markdown: '>=4.0.0-next.44'
dependencies:
typedoc-plugin-markdown: 4.0.0-next.47(typedoc@0.25.7)
dev: false
/typedoc@0.25.7(typescript@5.3.3):
resolution: {integrity: sha512-m6A6JjQRg39p2ZVRIN3NKXgrN8vzlHhOS+r9ymUYtcUP/TIQPvWSq7YgE5ZjASfv5Vd5BW5xrir6Gm2XNNcOow==}
engines: {node: '>= 16'}
hasBin: true
peerDependencies:
typescript: 4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x
dependencies:
lunr: 2.3.9
marked: 4.3.0
minimatch: 9.0.3
shiki: 0.14.7
typescript: 5.3.3
dev: false
/typescript@5.3.3:
resolution: {integrity: sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==}
engines: {node: '>=14.17'}
@ -1197,8 +1278,8 @@ packages:
resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==}
dev: false
/vite@5.0.11(@types/node@20.11.5):
resolution: {integrity: sha512-XBMnDjZcNAw/G1gEiskiM1v6yzM4GE5aMGvhWTlHAYYhxb7S3/V1s3m2LDHa8Vh6yIWYYB0iJwsEaS523c4oYA==}
/vite@5.0.12(@types/node@20.11.15):
resolution: {integrity: sha512-4hsnEkG3q0N4Tzf1+t6NdN9dg/L3BM+q8SWgbSPnJvrgH2kgdyzfVJwbR1ic69/4uMJJ/3dqDZZE5/WwqW8U1w==}
engines: {node: ^18.0.0 || >=20.0.0}
hasBin: true
peerDependencies:
@ -1225,16 +1306,16 @@ packages:
terser:
optional: true
dependencies:
'@types/node': 20.11.5
'@types/node': 20.11.15
esbuild: 0.19.11
postcss: 8.4.32
postcss: 8.4.33
rollup: 4.6.1
optionalDependencies:
fsevents: 2.3.3
dev: false
/vitepress@1.0.0-rc.39(@types/node@20.11.5)(qrcode@1.5.3)(typescript@5.3.3):
resolution: {integrity: sha512-EcgoRlAAp37WOxUOYv45oxyhLrcy3Upey+mKpqW3ldsg6Ol4trPndRBk2GO0QiSvEKlb9BMerk49D/bFICN6kg==}
/vitepress@1.0.0-rc.40(@types/node@20.11.15)(qrcode@1.5.3)(typescript@5.3.3):
resolution: {integrity: sha512-1x9PCrcsJwqhpccyTR93uD6jpiPDeRC98CBCAQLLBb44a3VSXYBPzhCahi+2kwAYylu49p0XhseMPVM4IVcWcw==}
hasBin: true
peerDependencies:
markdown-it-mathjax3: ^4.3.2
@ -1248,17 +1329,17 @@ packages:
'@docsearch/css': 3.5.2
'@docsearch/js': 3.5.2
'@types/markdown-it': 13.0.7
'@vitejs/plugin-vue': 5.0.3(vite@5.0.11)(vue@3.4.15)
'@vitejs/plugin-vue': 5.0.3(vite@5.0.12)(vue@3.4.15)
'@vue/devtools-api': 6.5.1
'@vueuse/core': 10.7.2(vue@3.4.15)
'@vueuse/integrations': 10.7.2(focus-trap@7.5.4)(qrcode@1.5.3)(vue@3.4.15)
focus-trap: 7.5.4
mark.js: 8.11.1
minisearch: 6.3.0
shikiji: 0.9.19
shikiji-core: 0.9.19
shikiji-transformers: 0.9.19
vite: 5.0.11(@types/node@20.11.5)
shikiji: 0.10.2
shikiji-core: 0.10.2
shikiji-transformers: 0.10.2
vite: 5.0.12(@types/node@20.11.15)
vue: 3.4.15(typescript@5.3.3)
transitivePeerDependencies:
- '@algolia/client-search'
@ -1288,6 +1369,14 @@ packages:
- universal-cookie
dev: false
/vscode-oniguruma@1.7.0:
resolution: {integrity: sha512-L9WMGRfrjOhgHSdOYgCt/yRMsXzLDJSL7BPrOZt73gU0iWO4mpqzqQzOz5srxqTvMBaR0XZTSrVWo4j55Rc6cA==}
dev: false
/vscode-textmate@8.0.0:
resolution: {integrity: sha512-AFbieoL7a5LMqcnOF04ji+rpXadgOXnZsxQr//r83kLPr7biP7am3g9zbaZIaBGwBRWeSvoMD4mgPdX3e4NWBg==}
dev: false
/vue-demi@0.14.6(vue@3.4.15):
resolution: {integrity: sha512-8QA7wrYSHKaYgUxDA5ZC24w+eHm3sYCbp0EzcDwKqN3p6HqtTCGR/GVsPyZW92unff4UlcSh++lmqDWN3ZIq4w==}
engines: {node: '>=12'}

3
pnpm-workspace.yaml Normal file
View File

@ -0,0 +1,3 @@
packages:
- 'docs'
- 'api'

View File

View File

@ -1 +0,0 @@
gkd.li

File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 83 KiB