feat(frontend): enable Yuque datasource option with optional base_url

Flip the Yuque tile to available, add a base_url field (optional) for users
on private Yuque deployments, and populate the permission doc/page links.
Introduces an optional flag on ConnectorDef.fields so the Test Connection
validator skips empty optional fields; required fields get a visible * mark.

Also adds an optional hintKey on ConnectorDef.fields for per-field guidance
text, a Yuque-specific prereq guide, and a base_url hint explaining when to
leave it empty vs fill it for Yuque Enterprise / self-hosted deployments.
This commit is contained in:
nullkey
2026-04-21 17:29:53 +08:00
committed by lyingbug
parent 4939011b0d
commit 16792713c5
3 changed files with 43 additions and 8 deletions
+11
View File
@@ -3689,6 +3689,8 @@ export default {
appSecret: 'App Secret',
integrationToken: 'Integration Token',
apiToken: 'API Token',
baseUrl: 'Base URL (optional)',
baseUrlHint: 'Leave empty to use the Yuque public cloud (https://www.yuque.com). For Yuque Enterprise or self-hosted deployments, enter your company domain (e.g. https://your-company.yuque.com).',
},
comingSoon: 'Coming soon',
docHint: 'Get credentials at:',
@@ -3697,6 +3699,14 @@ export default {
pleaseTestFirst: 'Please test connection first',
prereqTitle: 'Complete these steps before connecting (all required)',
prereqBarText: 'First time? Click to see Feishu app setup guide',
prereqBarText_yuque: 'First time? Click to see the Yuque token setup guide',
prereqStep1Brief_yuque: 'Create a Yuque personal token',
prereqStep1Desc_yuque: 'Sign in to Yuque → avatar → Settings → Token → New Token',
prereqStep2Brief_yuque: 'Grant the token required permissions',
prereqStep2Desc_yuque: 'Check at least repo:read and doc:read (read knowledge base and document content)',
prereqStep3Brief_yuque: '(Optional) Enter Base URL for enterprise deployments',
prereqStep3Desc_yuque: 'Leave empty for public cloud; for Yuque Enterprise or self-hosted, enter your company domain.',
prereqOpenConsole_yuque: 'Open Yuque Token settings',
prereqBotBrief: 'Add "Bot" capability to your app',
prereqBotDesc: 'Open Platform > Add App Capability > Bot > create version and publish',
prereqBotLabel: '1. Add "Bot" capability to your app (otherwise the app won\'t appear in wiki member search):',
@@ -3729,6 +3739,7 @@ export default {
resourceType: {
wikiSpace: 'Wiki Space',
docCategory: 'Document Category',
book: 'Yuque Book',
},
neverSynced: 'Never synced',
justNow: 'Just now',