Commit graph

958 commits

Author SHA1 Message Date
vsxd
389604e866 fix(web): fix skill detail page issues
- Fixed double @ in namespace display (@@global -> @global)
- Added download button functionality to download skill package
- Download button is disabled when no version is available
- Cleaned namespace parameter before constructing download URL
2026-03-13 13:31:12 +08:00
vsxd
8d01cc0976 feat(web): add role-based menu item visibility
- Added platformRoles to User interface in UserMenu
- Implemented role checks for menu items:
  - Reviews: SKILL_ADMIN, NAMESPACE_ADMIN, SUPER_ADMIN
  - Promotions: SKILL_ADMIN, SUPER_ADMIN
  - User Management: USER_ADMIN, SUPER_ADMIN
  - Audit Log: AUDITOR, SUPER_ADMIN
- Added translations for new menu items
- Menu items now only show for users with appropriate permissions
2026-03-13 13:29:02 +08:00
vsxd
9905763f6b fix(web): correct terminology for reviews menu item
Changed "我的评论" to "审核管理" to accurately reflect that this
is the review management page, not comments page.
2026-03-13 13:26:19 +08:00
vsxd
e525e381d8 fix(web): correct route path parameters for namespace and skill detail
- Changed route paths from @$namespace to /$namespace to match TanStack Router syntax
- Added @ prefix stripping in API calls to match backend expectations
- Fixed useParams from parameter to match new route paths
- URL format remains /@namespace/slug but route captures @namespace as parameter
2026-03-13 13:25:37 +08:00
yun-zhi-ztl
cab3bc3f8c Merge branch 'main' into feature/project-review 2026-03-13 13:21:51 +08:00
vsxd
969464afba feat(web): implement i18n and user menu
- Added i18next for internationalization support
- Created language switcher component with zh/en support
- Refactored user navigation into dropdown menu
- Moved Dashboard, Security, and Account settings into user menu
- Added translation files for Chinese and English
- Updated layout to use i18n for all text content
2026-03-13 13:21:05 +08:00
yun-zhi-ztl
644fc6aa43 fix 2026-03-13 13:20:58 +08:00
vsxd
ebd72bc422 fix(web): ensure all page navigation uses 0-based index
Fixed remaining instances in landing.tsx and layout.tsx where
page was still set to 1 instead of 0.
2026-03-13 13:16:35 +08:00
vsxd
9811540141 fix(web): 修复路由导航参数替换问题
TanStack Router 的 to 路径不会自动替换 $param,需要用模板字符串手动拼接。
修复所有 navigate 调用,避免 URL 中出现字面量 @$namespace。

涉及: home, search, namespace, my-skills, my-namespaces, stars, reviews
2026-03-13 13:06:04 +08:00
vsxd
303c27bca7 fix(web): 统一前端分页为0-based page index
与后端 Spring Data 的 0-based 分页对齐,修复首页数据不显示的问题。
涉及: router, search, home, landing, pagination 组件
2026-03-13 12:58:28 +08:00
vsxd
763c908f74 Revert "fix(api): 统一所有分页接口为1-based page"
This reverts commit 3706e920df.
2026-03-13 12:56:29 +08:00
vsxd
3706e920df fix(api): 统一所有分页接口为1-based page
前端传 page=1 表示第一页,后端原来是 0-based 导致首页数据丢失。
涉及: SkillSearch, SkillController, ReviewController,
PromotionController, UserManagement, AuditLog
2026-03-13 12:56:23 +08:00
yun-zhi-ztl
447a34a1d1 merge(main): sync latest origin/main into feature/project-review 2026-03-13 12:49:12 +08:00
vsxd
a85a9c3177 fix(publish): 放宽技能包上传校验
- application.yml 补齐缺失的文件扩展名白名单(.js,.ts,.png,.jpg,.svg)
- version 为空时自动生成时间戳版本号,不再强制报错
2026-03-13 12:47:34 +08:00
vsxd
ac32fce08f fix(auth): preserve return target across oauth login 2026-03-13 11:59:17 +08:00
yun-zhi-ztl
9021ba754e fix(web): clear lint gate and split route bundles
Remove the markdown renderer ts-ignore workaround by applying prose styling at the container level, which clears the remaining lint failure without changing rendered behavior.

Convert top-level pages to route-level lazy imports with a shared suspense fallback so the main bundle is no longer forced to include every page upfront. Verified with pnpm run lint, pnpm run typecheck, and pnpm run build; the entry chunk dropped from roughly 770 kB to 338.77 kB after the split.
2026-03-13 11:54:47 +08:00
yun-zhi-ztl
556d556724 fix(token): align revoke endpoint with 204 contract
Change DELETE /api/v1/tokens/{id} to return HTTP 204 No Content so the backend matches the existing OpenAPI contract and the frontend delete flow no longer rejects successful revocations.

Add a controller regression test that verifies the endpoint returns 204 with an empty body and still delegates the revoke call to ApiTokenService. Verified with the targeted TokenControllerTest plus full server mvn test.
2026-03-13 11:49:57 +08:00
vsxd
45e96be179 fix(ci): install pnpm before setup-node cache 2026-03-13 11:48:44 +08:00
yun-zhi-ztl
383bc1edae fix(admin): replace compat and admin placeholders with real queries
Implement compat search through SkillSearchAppService instead of returning an empty placeholder list, and map search results back to canonical slugs for the compatibility API.

Replace hard-coded admin user and audit-log payloads with repository-backed application services. User management now supports paged search and status filters, validates managed statuses and role codes, prevents USER_ADMIN from assigning SUPER_ADMIN, and persists role/status changes against the real repositories. Audit logs now read from the audit_log table through a dedicated query repository/service with filterable pagination.

Align admin response DTOs with the frontend contract, add domain not-found handling for localized 404 responses, and cover the new behavior with controller and service regression tests. Verified with targeted skillhub-app tests plus full server mvn test.
2026-03-13 11:46:21 +08:00
vsxd
84dd08503d merge: bring feature/project-init into main for beta3
# Conflicts:
#	scripts/smoke-test.sh
2026-03-13 11:45:56 +08:00
vsxd
c499571408 fix(web): redirect unauthenticated users back after login 2026-03-13 11:43:14 +08:00
vsxd
f16885a39d fix(web): normalize protected route matching 2026-03-13 11:41:02 +08:00
vsxd
8171a190a7 fix(web): prevent landing page from matching nested routes 2026-03-13 11:37:22 +08:00
vsxd
68af8047b8 Complete phase 3 and 4 frontend flows 2026-03-13 11:36:39 +08:00
vsxd
6a9e0845d4 Complete phase 3 and 4 backend workflows 2026-03-13 11:36:34 +08:00
vsxd
76808ca794 test(auth): align auth module tests with current flows 2026-03-13 11:32:50 +08:00
vsxd
5bb2eb0d98 fix(auth): grant global membership to new users 2026-03-13 11:29:01 +08:00
vsxd
0c5e4200cb fix(dev): provide explicit skill repository bean 2026-03-13 11:21:32 +08:00
yun-zhi-ztl
ad8bb9c6fd fix(security): whitelist only public skill GET routes
- require authentication for skill star and rating GET endpoints before the public skill-read rules

- keep documented public skill detail, version, download, resolve, and tag listing endpoints readable anonymously

- add regression coverage for anonymous star and rating access denial plus public tag listing
2026-03-13 11:12:18 +08:00
vsxd
c8d155e23f chore(git): ignore python cache files 2026-03-13 11:10:02 +08:00
vsxd
ec9341a6da fix(dev): harden local process startup checks 2026-03-13 11:09:02 +08:00
vsxd
56aeb424af fix(web): landing page no longer nested inside Layout header/footer
When pathname is '/', Layout now renders only the Outlet without its
own header/footer chrome, so the landing page's self-contained layout
displays correctly.
2026-03-13 11:08:35 +08:00
vsxd
f7df348a5a Add OpenAPI drift validation and docs updates 2026-03-13 11:06:55 +08:00
yun-zhi-ztl
ec8f7ec838 fix(auth): enforce api token scopes and active-user checks
- parse stored api token scopes and attach SCOPE authorities during authentication

- reject disabled users from establishing api token sessions and stop touching last-used for inactive accounts

- add an api-token-only scope filter that limits tokens to documented publish and token-management endpoints
2026-03-13 11:04:52 +08:00
vsxd
3cee8fbb5a fix(phase4): harden smoke checks and metrics access 2026-03-13 10:56:28 +08:00
vsxd
2c8c7fd272 merge: bring feature/project-init into main
# Conflicts:
#	README.md
2026-03-13 10:38:30 +08:00
vsxd
0ca38e73ba merge: bring phase4 worktree implementation into feature/project-init
# Conflicts:
#	server/skillhub-app/src/main/java/com/iflytek/skillhub/controller/cli/CliPublishController.java
#	server/skillhub-app/src/main/java/com/iflytek/skillhub/controller/portal/SkillPublishController.java
#	server/skillhub-storage/src/main/java/com/iflytek/skillhub/storage/LocalFileStorageService.java
#	web/src/app/router.tsx
2026-03-13 10:35:42 +08:00
vsxd
2b7968c71c docs(repo): add contribution and community templates 2026-03-13 10:34:12 +08:00
vsxd
72784c238a test(ops): expand local smoke coverage for auth sessions 2026-03-13 10:28:17 +08:00
vsxd
6285a32c09 docs: add curl quick start command 2026-03-13 10:27:55 +08:00
vsxd
b982011614 fix(ops): align smoke test with csrf and metrics access 2026-03-13 10:23:46 +08:00
yun-zhi-ztl
ddbf92435f fix(upload): harden package extraction and storage boundaries
- add shared package safety policy for path normalization and size limits

- stream zip extraction for cli check and publish flows to reject traversal and oversized entries

- confine local storage keys to the configured base path and add regression coverage
2026-03-13 10:20:34 +08:00
vsxd
07ea0fa822 merge: bring phase4 worktree implementation into main
# Conflicts:
#	server/skillhub-app/src/main/java/com/iflytek/skillhub/controller/cli/CliPublishController.java
#	server/skillhub-app/src/main/java/com/iflytek/skillhub/controller/portal/SkillPublishController.java
#	server/skillhub-storage/src/main/java/com/iflytek/skillhub/storage/LocalFileStorageService.java
#	web/src/app/router.tsx
2026-03-13 10:20:19 +08:00
vsxd
33c44fb9cc feat(phase4): complete auth, governance, observability, and ops polish 2026-03-13 10:17:48 +08:00
vsxd
62d9d88546 chore(release): cut v0.1.0-beta.2 2026-03-13 10:13:50 +08:00
vsxd
a8f5b98947 Merge branch 'feature/project-init' 2026-03-13 10:12:34 +08:00
vsxd
537765d68e fix: remove top-level name from compose file for docker-compose v1 compatibility 2026-03-13 10:09:35 +08:00
vsxd
d4deb2fb74 fix: address review-reported auth and publish issues 2026-03-13 10:06:25 +08:00
vsxd
f7798dddc5 Revert "merge: bring review fixes into feature/project-init"
This reverts commit 92f63f8b89, reversing
changes made to 78e16f0fe7.
2026-03-13 10:06:14 +08:00
vsxd
1a5bc12fb7 Merge branch 'feature/homepage-redesign' into feature/project-init 2026-03-13 10:05:39 +08:00