File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1163,6 +1163,12 @@ td a {
11631163 color : # aeb9c8 ;
11641164}
11651165
1166+ .footer-repositories {
1167+ display : flex;
1168+ flex-direction : column;
1169+ gap : 10px ;
1170+ }
1171+
11661172.footer-links {
11671173 display : flex;
11681174 align-items : center;
Original file line number Diff line number Diff line change 5959 < strong > FunASR</ strong >
6060 < p > {{ '面向生产部署的开源语音基础设施。' if language == 'zh' else 'Open speech infrastructure for production deployment.' }}</ p >
6161 </ div >
62+ < nav class ="footer-repositories " data-footer-repositories aria-label ="{{ '官方仓库' if language == 'zh' else 'Official repositories' }} ">
63+ < strong > {{ '官方仓库' if language == 'zh' else 'Official repositories' }}</ strong >
64+ < div class ="footer-links ">
65+ < a href ="/go/fun-asr "> Fun-ASR</ a >
66+ < a href ="/go/sensevoice "> SenseVoice</ a >
67+ < a href ="/go/funclip "> FunClip</ a >
68+ </ div >
69+ </ nav >
6270 < div class ="footer-links ">
6371 < a href ="{{ '/deploy/' if language == 'zh' else '/en/deploy/' }} "> {{ '部署' if language == 'zh' else 'Deploy' }}</ a >
6472 < a href ="{{ docs_url }} "> {{ '文档' if language == 'zh' else 'Docs' }}</ a >
Original file line number Diff line number Diff line change 1111SITE_ROOT = Path (__file__ ).resolve ().parents [1 ]
1212sys .path .insert (0 , str (SITE_ROOT ))
1313
14- from build import build # noqa: E402
14+ from build import build , route_path # noqa: E402
1515
1616
1717def read_soup (path : Path ) -> BeautifulSoup :
@@ -95,6 +95,26 @@ def test_visible_repository_links_use_fixed_conversion_routes(tmp_path):
9595 assert json_ld ['codeRepository' ] == 'https://github.com/modelscope/FunASR'
9696
9797
98+ def test_every_product_page_footer_surfaces_official_repositories (tmp_path ):
99+ manifest = build (tmp_path )
100+
101+ for page in manifest ['pages' ]:
102+ soup = read_soup (route_path (tmp_path , page ['route' ]))
103+ repositories = soup .select_one ('[data-footer-repositories]' )
104+ expected_heading = '官方仓库' if page ['language' ] == 'zh' else 'Official repositories'
105+
106+ assert repositories
107+ assert repositories .strong .get_text (strip = True ) == expected_heading
108+ assert {
109+ link .get ('href' ): link .get_text (strip = True )
110+ for link in repositories .select ('a[href]' )
111+ } == {
112+ '/go/fun-asr' : 'Fun-ASR' ,
113+ '/go/sensevoice' : 'SenseVoice' ,
114+ '/go/funclip' : 'FunClip' ,
115+ }
116+
117+
98118def test_home_surfaces_attributed_ecosystem_repositories (tmp_path ):
99119 build (tmp_path )
100120
You can’t perform that action at this time.
0 commit comments