Skip to content

Conversation

@sftim
Copy link
Contributor

@sftim sftim commented Oct 15, 2024

Redo the custom theme to be closer to vanilla Docsy.

Here's a preview

Helps with issue #41171

/area web-development


This PR is too large to merge as-is.

/hold
until it is small enough to be reviewable as a single change (eg size/XL or smaller)

I will carve off smaller PRs that are reviewable.

@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. area/web-development Issues or PRs related to the kubernetes.io's infrastructure, design, or build processes cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Oct 15, 2024
@k8s-ci-robot k8s-ci-robot added language/en Issues or PRs related to English language sig/docs Categorizes an issue or PR as relevant to SIG Docs. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Oct 15, 2024
@netlify
Copy link

netlify bot commented Oct 15, 2024

Pull request preview available for checking

Built without sensitive environment variables

Name Link
🔨 Latest commit 3e51135
🔍 Latest deploy log https://app.netlify.com/sites/kubernetes-io-main-staging/deploys/67e54e28033413000876aaca
😎 Deploy Preview https://deploy-preview-48363--kubernetes-io-main-staging.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from e690c92 to ba2190e Compare October 19, 2024 10:25
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 19, 2024
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from ba2190e to a6de947 Compare October 19, 2024 15:35
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 19, 2024
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch 4 times, most recently from c6f85e1 to 65a6340 Compare October 23, 2024 19:15
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 26, 2024
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from 65a6340 to 1116c85 Compare October 26, 2024 20:29
@k8s-ci-robot k8s-ci-robot added needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Oct 26, 2024
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from 1116c85 to ec2586b Compare October 27, 2024 15:32
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 27, 2024
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from ec2586b to c6f85e1 Compare October 27, 2024 16:12
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 27, 2024
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from c6f85e1 to ec2586b Compare October 27, 2024 16:20
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 27, 2024
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch 2 times, most recently from b959c4c to 792471e Compare November 2, 2024 19:54
@seokho-son
Copy link
Member

Sharing a comment on #41171 about the menu display issue. 🙂
(Korean localization)

#41171 (comment)

@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from a63a2a2 to c05c31e Compare February 18, 2025 12:18
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Feb 20, 2025
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from c05c31e to 38c3ffa Compare February 21, 2025 10:07
@k8s-ci-robot k8s-ci-robot added needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Feb 21, 2025
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from 38c3ffa to 0cf140d Compare February 25, 2025 20:25
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Feb 25, 2025
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch 2 times, most recently from 5bf5894 to 0c45173 Compare February 27, 2025 20:07
@sftim sftim requested a review from Copilot March 14, 2025 12:17
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR updates the site's theme to more closely align with the vanilla Docsy theme while adding and adjusting search functionality and minor UI behaviors. Key changes include:

  • Introducing a new search script (search-google.js) for handling Google search.
  • Enhancing search.js with both Google and Pagefind search fallbacks plus additional DOM manipulations.
  • Modifying hugo.toml to update search-related configuration.
  • Adjusting banner dismissal behavior in banner-dismiss.js via a jQuery refactor.

Reviewed Changes

Copilot reviewed 74 out of 74 changed files in this pull request and generated 2 comments.

File Description
assets/js/search-google.js New search script added to support Google search integration.
assets/js/search.js Refactored search behavior with added handling for fallback search methods.
hugo.toml Updated configuration for search UI and theme parameters.
assets/js/banner-dismiss.js Switched to jQuery methods for announcement dismissal with minor logic change.

sidebarSearch.remove();
}
document.getElementById('search').style.display = 'block';
pagefind = new PagefindUI({ element: "#search", showImages: false });
Copy link

Copilot AI Mar 14, 2025

Choose a reason for hiding this comment

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

The 'pagefind' variable is assigned without declaration, which can lead to unintended global variable creation. Consider declaring it with 'let' or 'const'.

Suggested change
pagefind = new PagefindUI({ element: "#search", showImages: false });
let pagefind = new PagefindUI({ element: "#search", showImages: false });

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Member

Choose a reason for hiding this comment

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

Nice find, I have updated #49724 with let or const as needed.

}
else {
announcement.classList.add('display-announcement') // Display the announcement if the cookie is not set
announcement.removeClass('announcement-shown').addClass('announcement-shown'); // Display the announcement if the cookie is not set
Copy link

Copilot AI Mar 14, 2025

Choose a reason for hiding this comment

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

Removing and then immediately re-adding the same 'announcement-shown' class seems redundant; review the intended behavior for displaying the announcement.

Suggested change
announcement.removeClass('announcement-shown').addClass('announcement-shown'); // Display the announcement if the cookie is not set
announcement.addClass('announcement-shown'); // Display the announcement if the cookie is not set

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think the idea is to make sure the class is only asserted once. Not sure.

@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from 0c45173 to 69d9bd0 Compare March 14, 2025 12:38
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 18, 2025
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from 69d9bd0 to b0d845d Compare March 22, 2025 16:04
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 22, 2025
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from b0d845d to bf8fc73 Compare March 27, 2025 12:57
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 27, 2025
Redo the custom theme to be closer to vanilla Docsy.
@sftim sftim force-pushed the 20241015_align_style_to_docsy branch from bf8fc73 to 3e51135 Compare March 27, 2025 13:09
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 27, 2025
@k8s-ci-robot
Copy link
Contributor

PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Apr 17, 2025
@lmktfy
Copy link
Member

lmktfy commented Apr 24, 2025

Superseded by PR #50665

/close

@lmktfy lmktfy closed this Apr 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/web-development Issues or PRs related to the kubernetes.io's infrastructure, design, or build processes cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. language/en Issues or PRs related to English language needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. sig/docs Categorizes an issue or PR as relevant to SIG Docs. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants