Skip to content

feat(PdfReader): update style for pdf property dialog#853

Merged
ArgoZhang merged 2 commits intomasterfrom
fix-pdf
Dec 21, 2025
Merged

feat(PdfReader): update style for pdf property dialog#853
ArgoZhang merged 2 commits intomasterfrom
fix-pdf

Conversation

@ArgoZhang
Copy link
Copy Markdown
Member

@ArgoZhang ArgoZhang commented Dec 21, 2025

Link issues

fixes #852

Summary By Copilot

Regression?

  • Yes
  • No

Risk

  • High
  • Medium
  • Low

Verification

  • Manual (required)
  • Automated

Packaging changes reviewed?

  • Yes
  • No
  • N/A

☑️ Self Check before Merge

⚠️ Please check all items below before review. ⚠️

  • Doc is updated/provided or not needed
  • Demo is updated/provided or not needed
  • Merge the latest code from the main branch

Summary by Sourcery

Enhancements:

  • Update PDF property dialog item styling so the value container flexes and shrinks properly within the dialog layout.

Copilot AI review requested due to automatic review settings December 21, 2025 11:42
@bb-auto bb-auto Bot added the enhancement New feature or request label Dec 21, 2025
@bb-auto bb-auto Bot added this to the v9.2.0 milestone Dec 21, 2025
@sourcery-ai
Copy link
Copy Markdown

sourcery-ai Bot commented Dec 21, 2025

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Adjusts layout behavior of the PDF property dialog items to improve flexbox sizing and content wrapping within the PdfReader component.

Flow diagram for bb_view_pdf_dialog_item layout structure change

flowchart TD
  A[bb_view_pdf_dialog_item_container] --> B[first_child_div]
  A --> C[last_child_div]

  subgraph Before_change
    B
    C
  end

  subgraph After_change
    D[first_child_div]
    E[last_child_div_with_new_styles]
  end

  C -->|becomes| E

  E --> F[flex_1]
  E --> G[width_1_percent]
  E --> H[min_width_0]
Loading

File-Level Changes

Change Details Files
Refine flexbox sizing behavior for the pdf property dialog value container to prevent overflow and allow proper shrinking/wrapping.
  • Add a selector targeting the last child div of .bb-view-pdf-dialog-item to act as the flex item containing the value content.
  • Set flex: 1 so the value container takes remaining space within the row.
  • Constrain width with width: 1% and min-width: 0 to allow flexbox to shrink the content properly without overflow.
src/components/BootstrapBlazor.PdfReader/wwwroot/css/pdf_reader.css

Assessment against linked issues

Issue Objective Addressed Explanation
#852 Update the styling of the PDF property dialog in the PdfReader component.

Possibly linked issues


Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@ArgoZhang ArgoZhang merged commit 6fb0e57 into master Dec 21, 2025
5 of 6 checks passed
@ArgoZhang ArgoZhang deleted the fix-pdf branch December 21, 2025 11:42
Copy link
Copy Markdown

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

  • The selector .bb-view-pdf-dialog-item > div:last-child is a bit fragile; consider targeting a more specific class on the value container instead of relying on div:last-child to avoid layout regressions if the DOM structure changes.
  • The combination of flex: 1, width: 1%, and min-width: 0 is quite specific; adding a brief code comment or aligning this pattern with existing flexbox utilities in the project would make the intent clearer for future maintainers.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- The selector `.bb-view-pdf-dialog-item > div:last-child` is a bit fragile; consider targeting a more specific class on the value container instead of relying on `div:last-child` to avoid layout regressions if the DOM structure changes.
- The combination of `flex: 1`, `width: 1%`, and `min-width: 0` is quite specific; adding a brief code comment or aligning this pattern with existing flexbox utilities in the project would make the intent clearer for future maintainers.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Copy link
Copy Markdown

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 styling for the PDF property dialog to improve the layout and text overflow handling of property values. The changes ensure that long property values (like filenames or titles) are properly constrained and can be truncated within the fixed-width dialog.

  • Added CSS flexbox styling to the value container in PDF dialog items for better overflow handling
  • Incremented package version from 10.0.22 to 10.0.23

Reviewed changes

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

File Description
src/components/BootstrapBlazor.PdfReader/wwwroot/css/pdf_reader.css Added flexbox styling to .bb-view-pdf-dialog-item > div:last-child for proper text overflow handling in property values
src/components/BootstrapBlazor.PdfReader/BootstrapBlazor.PdfReader.csproj Bumped package version to 10.0.23 for the style update release

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(PdfReader): update style for pdf property dialog

2 participants