Skip to content
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

Translations: add issue report banner to translation pages #3486

Merged
merged 18 commits into from
Mar 13, 2025

Conversation

Blargian
Copy link
Member

Summary

Checklist

Copy link

vercel bot commented Mar 11, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
clickhouse-docs-ru ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 12, 2025 1:09pm
clickhouse-docs-zh ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 12, 2025 1:09pm

Copy link

vercel bot commented Mar 11, 2025

@Blargian is attempting to deploy a commit to the ClickHouse Team on Vercel.

A member of the Team first needs to authorize it.

@Blargian Blargian changed the title add announcement bars for translations Translations: add issue report banner to translation pages Mar 12, 2025
@Blargian Blargian marked this pull request as ready for review March 12, 2025 12:08
@Blargian Blargian requested a review from a team as a code owner March 12, 2025 12:08

const locales = ['/ru/', '/jp/', '/zh/']
let isEnglish = true;
console.log(location.pathname)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove

export default function DocItemLayout({children}) {
const docTOC = useDocTOC();
const {metadata} = useDoc();
const {editUrl} = metadata;

const location = useLocation();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this can all be done much simpler, use the getDocusarusContext and you can get the locale. Just check its not en

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes pushed. The check with useLocation() is needed because we don't want to display it on this page, at least not until the mess of styling on this page is cleaned up.

Screenshot 2025-03-12 at 14 03 48

@gingerwizard gingerwizard merged commit c60997a into ClickHouse:main Mar 13, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants