-
Notifications
You must be signed in to change notification settings - Fork 10
Add [Open Library] & Library Work Flow #20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
74174bd
07745ad
e10b0b1
69dbf8b
a72c2ee
23870d8
99320ce
08d2e72
18e9c84
5ccc58c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -13,5 +13,5 @@ jobs: | |
|
|
||
| - uses: OWASP/cve-lite-cli@v1 | ||
| with: | ||
| verbose: "true" | ||
| verbose: 'true' | ||
| fail-on: high | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1 @@ | ||
| npm test | ||
| pnpm test |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1 @@ | ||
| npm run build | ||
| pnpm run build |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -4,7 +4,7 @@ import { Col, Pagination, Row } from 'react-bootstrap'; | |
| import { SearchPageMeta } from '../../models/System'; | ||
|
|
||
| export interface CardPageProps extends SearchPageMeta { | ||
| Card: ComponentClass<any> | FC<any>; | ||
| Card: ComponentClass<Record<string, unknown>> | FC<Record<string, unknown>>; | ||
| cardLinkOf?: (id: string) => string; | ||
| pageLinkOf: (page: number) => string; | ||
| } | ||
|
Comment on lines
6
to
10
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# 检查 ActivityCard、ProjectCard、OrganizationCard 的 props 接口定义
rg -n -A 8 'export.*ActivityCard|export.*ProjectCard' --type=tsx | head -50
rg -n -A 10 'export interface.*CardProps|type.*CardProps' --type=tsx | grep -E '(Activity|Project|Organization)Card'Repository: Open-Source-Bazaar/Open-Source-Bazaar.github.io Length of output: 147 🏁 Script executed: #!/bin/bash
# Find card component files
fd -e tsx -e ts | grep -i 'card' | head -20Repository: Open-Source-Bazaar/Open-Source-Bazaar.github.io Length of output: 397 🏁 Script executed: #!/bin/bash
# Search for ActivityCard, ProjectCard, OrganizationCard definitions
rg -n "export.*ActivityCard\|export.*ProjectCard\|export.*OrganizationCard" | head -30Repository: Open-Source-Bazaar/Open-Source-Bazaar.github.io Length of output: 73 🏁 Script executed: #!/bin/bash
# Check CardPage.tsx to see how Card is used
cat -n components/Layout/CardPage.tsxRepository: Open-Source-Bazaar/Open-Source-Bazaar.github.io Length of output: 1420 🏁 Script executed: #!/bin/bash
# Check Activity Card props
head -30 components/Activity/Card.tsxRepository: Open-Source-Bazaar/Open-Source-Bazaar.github.io Length of output: 907 🏁 Script executed: #!/bin/bash
# Check Project Card props
head -30 components/Project/Card.tsxRepository: Open-Source-Bazaar/Open-Source-Bazaar.github.io Length of output: 528 🏁 Script executed: #!/bin/bash
# Check Organization Card props
head -30 components/Organization/Card.tsxRepository: Open-Source-Bazaar/Open-Source-Bazaar.github.io Length of output: 1106 CardPageProps.Card 类型收窄存在兼容性问题。 将
CardPage.tsx 第 24 行实际传递了 🤖 Prompt for AI Agents |
||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -81,6 +81,10 @@ const topNavBarMenu = ({ t }: typeof i18n): MenuItem[] => [ | |||||||||||||||||
| { href: '/recipe', title: t('recipe') }, | ||||||||||||||||||
| ], | ||||||||||||||||||
| }, | ||||||||||||||||||
| { | ||||||||||||||||||
| href: '/open-library', | ||||||||||||||||||
| name: t('open_library'), | ||||||||||||||||||
| }, | ||||||||||||||||||
|
Comment on lines
+84
to
+87
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 新菜单项字段名写错,破坏 Line 86 使用了 建议修复 {
href: '/open-library',
- name: t('open_library'),
+ title: t('open_library'),
},📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||
| ]; | ||||||||||||||||||
|
|
||||||||||||||||||
| export interface MainNavigatorProps { | ||||||||||||||||||
|
|
@@ -94,6 +98,14 @@ export const MainNavigator: FC<MainNavigatorProps> = observer(({ menu }) => { | |||||||||||||||||
|
|
||||||||||||||||||
| menu ||= topNavBarMenu(i18n); | ||||||||||||||||||
|
|
||||||||||||||||||
| // 检查是否是 Open Library 路径 | ||||||||||||||||||
| const isOpenLibraryPath = pathname.startsWith('/open-library'); | ||||||||||||||||||
|
|
||||||||||||||||||
| // 如果是 Open Library 路径,不渲染主站导航栏 | ||||||||||||||||||
| if (isOpenLibraryPath) { | ||||||||||||||||||
| return null; | ||||||||||||||||||
| } | ||||||||||||||||||
|
|
||||||||||||||||||
| return ( | ||||||||||||||||||
| <Navbar bg="dark" variant="dark" fixed="top" expand="lg"> | ||||||||||||||||||
| <Container> | ||||||||||||||||||
|
|
||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.section-frame()mixin 内部调用被清空,将导致下游样式完全丢失此 mixin 内的所有嵌套选择器(
.section、.sectionHeader、.sectionTitle、.sectionSubtitle、.accentLine)原本应调用对应的子 mixin 以生成样式,现在全部被替换为空语句;。根据
Overview.module.less等下游文件直接调用.section-frame(),这意味着这些选择器将编译为空规则集,导致 Hackathon 页面的 section 布局、标题、副标题、装饰线样式全部丢失。🐛 建议恢复 mixin 调用
.section-frame() { .section { - ; + .section-shell(); } .sectionHeader { - ; + .section-header(); } .sectionTitle { - ; + .section-title(); } .sectionSubtitle { - ; + .section-subtitle(); } .accentLine { - ; + .accent-line(); } }📝 Committable suggestion
🤖 Prompt for AI Agents