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

Privacy mode: instead of blurring, use an illegible font (#3376) #3377

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

olets
Copy link

@olets olets commented Sep 6, 2024

Instead of blurring, uses the font Redacted Script https://github.com/christiannaths/redacted-font#redacted-script.

The good: much more private

Edit: the following limitation no longer applies (see #3377 (review))

The touchy: this font's sizing isn't identical to the non-private font. In some cases there's a minor layout shift on hover, and/or when toggling between modes.

The implementation support per-element line-height customization, and could easily be extended to support per-element letter-spacing. I haven't gone deep down that rabbit hole, only customizing line height on the two large font size numbers, where the difference is more significant.

screenshotimage
screencap, updated
actual-privacy-mode-redacted-font-2.mov
OLD outdated screencapture, for posterity
actual-privacy-mode-redacted-font.mov

Summary by CodeRabbit

  • New Features

    • Introduced a new font option for improved visual presentation in the desktop client.
    • Enhanced privacy mode by replacing blurring effects with an illegible font for sensitive information.
  • Bug Fixes

    • Simplified the PrivacyFilter component, improving user interaction and visual effects.
  • Documentation

    • Added notes regarding the new privacy mode enhancement in the release notes.

@actual-github-bot actual-github-bot bot changed the title Privacy mode: instead of blurring, use an illegible font (#3376) [WIP] Privacy mode: instead of blurring, use an illegible font (#3376) Sep 6, 2024
Copy link

netlify bot commented Sep 6, 2024

Deploy Preview for actualbudget ready!

Name Link
🔨 Latest commit c9beb9a
🔍 Latest deploy log https://app.netlify.com/sites/actualbudget/deploys/66e9bfedba87220008eca050
😎 Deploy Preview https://deploy-preview-3377.demo.actualbudget.org
📱 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.

@olets olets force-pushed the 3376-decrease-privacy-mode-legibility branch from a78736f to 49b25c0 Compare September 6, 2024 01:17
Copy link
Contributor

github-actions bot commented Sep 6, 2024

Bundle Stats — desktop-client

Hey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle.

As this PR is updated, I'll keep you updated on how the bundle size is impacted.

Total

Files count Total bundle size % Changed
9 5.18 MB → 5.18 MB (-3.53 kB) -0.07%
Changeset
File Δ Size
src/components/PrivacyFilter.tsx 📈 +282 B (+8.85%) 3.11 kB → 3.39 kB
src/components/budget/rollover/budgetsummary/ToBudgetAmount.tsx 📈 +40 B (+1.82%) 2.15 kB → 2.19 kB
package.json 📈 +43 B (+1.40%) 3 kB → 3.04 kB
src/components/budget/report/ReportComponents.tsx 📈 +48 B (+0.36%) 12.9 kB → 12.95 kB
src/components/reports/reports/CustomReport.tsx 📉 -48 B (-0.21%) 22.36 kB → 22.32 kB
src/components/table.tsx 📉 -100 B (-0.40%) 24.33 kB → 24.23 kB
src/components/reports/reports/NetWorth.jsx 📉 -36 B (-0.60%) 5.9 kB → 5.87 kB
src/components/accounts/Balance.jsx 📉 -42 B (-0.76%) 5.41 kB → 5.37 kB
home/runner/work/actual/actual/packages/loot-core/src/shared/rules.ts 📉 -73 B (-1.10%) 6.48 kB → 6.41 kB
src/components/budget/report/budgetsummary/Saved.tsx 📉 -30 B (-1.13%) 2.6 kB → 2.57 kB
src/components/reports/reports/Spending.tsx 📉 -208 B (-1.14%) 17.8 kB → 17.6 kB
src/components/reports/ReportSummary.tsx 📉 -64 B (-1.60%) 3.9 kB → 3.84 kB
src/components/budget/rollover/RolloverComponents.tsx 📉 -250 B (-1.77%) 13.76 kB → 13.52 kB
src/components/modals/EditRuleModal.jsx 📉 -1.67 kB (-4.29%) 38.94 kB → 37.27 kB
src/components/settings/Experimental.tsx 📉 -233 B (-4.80%) 4.74 kB → 4.51 kB
src/hooks/useFeatureFlag.ts 📉 -27 B (-7.28%) 371 B → 344 B
src/components/rules/ActionExpression.tsx 📉 -375 B (-9.12%) 4.01 kB → 3.65 kB
src/icons/v1/Code.tsx 🔥 -448 B (-100%) 448 B → 0 B
src/icons/v1/AlignLeft.tsx 🔥 -387 B (-100%) 387 B → 0 B
View detailed bundle breakdown

Added

No assets were added

Removed

No assets were removed

Bigger

No assets were bigger

Smaller

Asset File Size % Changed
static/js/index.js 3.21 MB → 3.21 MB (-3.14 kB) -0.10%
static/js/ReportRouter.js 1.5 MB → 1.5 MB (-356 B) -0.02%
static/js/wide.js 225.21 kB → 225.17 kB (-42 B) -0.02%

Unchanged

Asset File Size % Changed
static/js/indexeddb-main-thread-worker-e59fee74.js 13.5 kB 0%
static/js/AppliedFilters.js 20.97 kB 0%
static/js/BackgroundImage.js 122.29 kB 0%
static/js/narrow.js 80.62 kB 0%
static/js/usePreviewTransactions.js 1.59 kB 0%
static/js/resize-observer.js 18.37 kB 0%

Copy link
Contributor

github-actions bot commented Sep 6, 2024

Bundle Stats — loot-core

Hey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle.

As this PR is updated, I'll keep you updated on how the bundle size is impacted.

Total

Files count Total bundle size % Changed
1 1.26 MB → 1.19 MB (-74.56 kB) -5.77%
Changeset
File Δ Size
packages/loot-core/src/shared/rules.ts 📉 -83 B (-0.92%) 8.8 kB → 8.72 kB
packages/loot-core/src/server/accounts/rules.ts 📉 -2.85 kB (-8.45%) 33.74 kB → 30.88 kB
node_modules/handlebars/dist/cjs/handlebars/compiler/parser.js 🔥 -200.84 kB (-100%) 200.84 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/compiler/javascript-compiler.js 🔥 -118.53 kB (-100%) 118.53 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/compiler/compiler.js 🔥 -56.75 kB (-100%) 56.75 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/runtime.js 🔥 -43.72 kB (-100%) 43.72 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/compiler/whitespace-control.js 🔥 -22.62 kB (-100%) 22.62 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/compiler/helpers.js 🔥 -18.76 kB (-100%) 18.76 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/compiler/code-gen.js 🔥 -15.51 kB (-100%) 15.51 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/compiler/visitor.js 🔥 -12.33 kB (-100%) 12.33 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/utils.js 🔥 -10.07 kB (-100%) 10.07 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/helpers/each.js 🔥 -9.64 kB (-100%) 9.64 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/base.js 🔥 -9.41 kB (-100%) 9.41 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/internal/proto-access.js 🔥 -8.29 kB (-100%) 8.29 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/exception.js 🔥 -5.81 kB (-100%) 5.81 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars.js 🔥 -4.79 kB (-100%) 4.79 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars.runtime.js 🔥 -4.5 kB (-100%) 4.5 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/helpers/if.js 🔥 -4.35 kB (-100%) 4.35 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/compiler/base.js 🔥 -3.83 kB (-100%) 3.83 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/helpers.js 🔥 -3.82 kB (-100%) 3.82 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/logger.js 🔥 -3.79 kB (-100%) 3.79 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/helpers/block-helper-missing.js 🔥 -3.74 kB (-100%) 3.74 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/helpers/with.js 🔥 -3.67 kB (-100%) 3.67 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/compiler/ast.js 🔥 -3.34 kB (-100%) 3.34 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/decorators/inline.js 🔥 -2.63 kB (-100%) 2.63 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/helpers/log.js 🔥 -2.45 kB (-100%) 2.45 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/no-conflict.js 🔥 -2.45 kB (-100%) 2.45 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/internal/wrapHelper.js 🔥 -2.14 kB (-100%) 2.14 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/helpers/helper-missing.js 🔥 -1.97 kB (-100%) 1.97 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/internal/create-new-lookup-object.js 🔥 -1.74 kB (-100%) 1.74 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/helpers/lookup.js 🔥 -1.21 kB (-100%) 1.21 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/safe-string.js 🔥 -1.14 kB (-100%) 1.14 kB → 0 B
node_modules/handlebars/dist/cjs/handlebars/decorators.js 🔥 -1000 B (-100%) 1000 B → 0 B
View detailed bundle breakdown

Added

No assets were added

Removed

No assets were removed

Bigger

No assets were bigger

Smaller

Asset File Size % Changed
kcab.worker.js 1.26 MB → 1.19 MB (-74.56 kB) -5.77%

Unchanged

No assets were unchanged

@olets olets force-pushed the 3376-decrease-privacy-mode-legibility branch from 49b25c0 to 7f01cd7 Compare September 6, 2024 01:24
@joel-jeremy
Copy link
Contributor

This looks cool :) I wonder if moving the privacy filter to wrap the text instead of the entire component would fix the shifting

Copy link
Author

@olets olets left a comment

Choose a reason for hiding this comment

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

Found the convention for using classes. I thought Actual was inline style only 😅 That opened doors. The layout shift is gone.

actual-privacy-mode-redacted-font-2.mov

Comment on lines -200 to -204
style: {
position: 'absolute',
width: '100%',
height: '100%',
},
Copy link
Author

@olets olets Sep 6, 2024

Choose a reason for hiding this comment

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

This appears to be safe to remove. But I'm also not sure why it's in current master. So I may be missing some edge case not covered by the visual tests, and this might need to be reverted.

@@ -175,6 +175,7 @@ export const GroupMonth = memo(function GroupMonth({
valueProps={{
binding: reportBudget.groupBalance(id),
type: 'financial',
// TODO: may no longer be unnecessary
Copy link
Author

Choose a reason for hiding this comment

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

Haven't found where this appears in the UI. Can someone point me to it?

[
{
display: 'inline-flex',
position: 'relative',
Copy link
Author

@olets olets Sep 6, 2024

Choose a reason for hiding this comment

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

Potentially breaking. I didn't notice any instances where PrivacyFilter content is positioned relative to something higher up the DOM. Doesn't break the visual tests, but I don't know how completely those cover the app. If someone else knows that this will be a problem, lmk

@olets olets force-pushed the 3376-decrease-privacy-mode-legibility branch 2 times, most recently from cbd9de3 to f8e0530 Compare September 6, 2024 20:42
@olets
Copy link
Author

olets commented Sep 6, 2024

For the breaking test I'd like help from someone more experienced with this project.

"Budget › transfer funds to another category" fails for this PR in GitHub Actions but passes for me locally.

Fwiw, locally I've seen "Onboarding > creates a new empty budget file" and "Accounts › Budgeted Accounts > creates a transfer from two existing transactions" be flaky.

Per https://github.com/actualbudget/actual/blob/master/packages/desktop-client/README.md#visual-regression, to run the tests locally I'm doing HTTPS=true yarn start and then, in another terminal, yarn vrt:docker.

@olets olets force-pushed the 3376-decrease-privacy-mode-legibility branch from f8e0530 to b21f57f Compare September 6, 2024 21:05
@joel-jeremy
Copy link
Contributor

joel-jeremy commented Sep 7, 2024

For the breaking test I'd like help from someone more experienced with this project.

"Budget › transfer funds to another category" fails for this PR in GitHub Actions but passes for me locally.

Fwiw, locally I've seen "Onboarding > creates a new empty budget file" and "Accounts › Budgeted Accounts > creates a transfer from two existing transactions" be flaky.

Per https://github.com/actualbudget/actual/blob/master/packages/desktop-client/README.md#visual-regression, to run the tests locally I'm doing HTTPS=true yarn start and then, in another terminal, yarn vrt:docker.

Have you tried yarn vrt:docker --update-snapshots?

@olets
Copy link
Author

olets commented Sep 7, 2024

Okay I did

git checkout [branch]
yarn install
HTTPS=true yarn start

and then in another terminal yarn vrt:docker --update-snapshots

once on master and once for this PR's branch. Those results, plus the GitHub Actions result or comparison:

Test master, olets' local this PR's branch, olets' local this PR's branch, GitHub Actions
Onboarding › creates a new budget file by importing nYNAB budget 🔴 Fail 🔴 Fail 🟢 Pass
Onboarding › creates a new empty budget file 🟢 Pass 🟡 Flaky 🟢 Pass
Accounts › Budgeted Accounts › creates a transfer from two existing transactions 🔴 Fail 🟢 Pass 🟢 Pass
Mobile › opens individual account page and checks that filtering is working 🔴 Fail 🔴 Fail 🟢 Pass
Reports › loads net worth and cash flow reports 🟡 Flaky 🟡 Flaky 🟢 Pass
Budget › transfer funds to another category 🟢 Pass 🟢 Pass 🔴 Fail

@joel-jeremy
Copy link
Contributor

We're getting there :) You need to push the new screenshots that were updated due to the --update-screenshots flag.

Copy link
Contributor

👋 Hi! It looks like this PR has not had any changes for a week now. Would you like someone to review this PR? If so - please remove the "[WIP]" prefix from the PR title. That will let the community know that this PR is open for a review.

@github-actions github-actions bot added the Stale label Sep 16, 2024
@olets olets force-pushed the 3376-decrease-privacy-mode-legibility branch from b21f57f to 1a774d4 Compare September 16, 2024 19:13
@olets olets changed the title [WIP] Privacy mode: instead of blurring, use an illegible font (#3376) Privacy mode: instead of blurring, use an illegible font (#3376) Sep 16, 2024
@joel-jeremy joel-jeremy removed the Stale label Sep 16, 2024
@joel-jeremy
Copy link
Contributor

That's odd. @MatissJanis Any idea why would the screenshots show up as added instead of modified?

@olets
Copy link
Author

olets commented Sep 16, 2024

Heh that's why I hadn't added them before. Note that none of them include private mode text either.

@MatissJanis
Copy link
Member

That's odd. @MatissJanis Any idea why would the screenshots show up as added instead of modified?

I'm guessing the VRT command got ran outside the docker container (on a local machine). Please remove them and re-run the VRT tests inside docker. Here are the instructions: https://github.com/actualbudget/actual/blob/master/packages/desktop-client/README.md

@olets
Copy link
Author

olets commented Sep 16, 2024

@MatissJanis I ran yarn vrt:docker --update-snapshots. Details of what all I ran are further up in this thread.

@MatissJanis
Copy link
Member

Perfect. Then undo all the screenshot changes you did here and re-run that command once more. The output will be updates to screenshots.

@MikesGlitch
Copy link
Contributor

MikesGlitch commented Sep 17, 2024

@coderabbitai full review

Copy link

coderabbitai bot commented Sep 17, 2024

@MikesGlitch: Understood, I will perform a full review of the pull request.

Actions performed

Full review triggered.

Copy link

coderabbitai bot commented Sep 17, 2024

Walkthrough

The changes involve the addition of a new font dependency, @fontsource/redacted-script, and significant refactoring of the PrivacyFilter component across multiple files. The blurIntensity prop has been removed in favor of a more structured approach to privacy filtering, which now utilizes an illegible font instead of a blurring effect. This update also includes minor adjustments in various components to streamline the handling of privacy features and enhance overall code maintainability.

Changes

Files Change Summary
packages/desktop-client/package.json Added @fontsource/redacted-script to devDependencies.
packages/desktop-client/src/components/PrivacyFilter.tsx Refactored PrivacyFilter; removed blurIntensity prop; introduced PrivacyOverlay for hover effects.
packages/desktop-client/src/components/accounts/Balance.jsx Modified privacyFilter prop from an object to a boolean.
packages/desktop-client/src/components/budget/report/ReportComponents.tsx Added comment indicating potential removal of privacyFilter.
packages/desktop-client/src/components/budget/report/budgetsummary/Saved.tsx Removed blurIntensity from PrivacyFilter usage.
packages/desktop-client/src/components/budget/rollover/RolloverComponents.tsx Removed privacyFilter property from valueProps in ExpenseGroupMonth and IncomeGroupMonth.
packages/desktop-client/src/components/budget/rollover/budgetsummary/ToBudgetAmount.tsx Added style prop to PrivacyFilter for text alignment.
packages/desktop-client/src/components/reports/ReportSummary.tsx Removed blurIntensity from PrivacyFilter for balance and average amounts.
packages/desktop-client/src/components/reports/reports/CustomReport.tsx Removed blurIntensity from PrivacyFilter usage.
packages/desktop-client/src/components/reports/reports/NetWorth.jsx Removed blurIntensity from PrivacyFilter for net worth display.
packages/desktop-client/src/components/reports/reports/Spending.tsx Removed blurIntensity from PrivacyFilter usage.
packages/desktop-client/src/components/table.tsx Removed inline styles from privacyFilter property in Cell component.
packages/desktop-client/src/fonts.scss Added import statement for @fontsource/redacted-script.
upcoming-release-notes/3377.md Introduced enhancement description for privacy mode feature, switching to an illegible font for privacy.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant PrivacyFilter
    participant PrivacyOverlay
    participant Component

    User->>Component: Interacts with component
    Component->>PrivacyFilter: Render without blurIntensity
    PrivacyFilter->>PrivacyOverlay: Manage hover state
    PrivacyOverlay->>User: Show/hide content based on hover
Loading

🐰 "In a world of fonts and styles,
The rabbit hops with joyful smiles.
No more blur, just clear delight,
With redacted scripts, our future's bright!
Privacy's charm, a whimsical dance,
In code we trust, let's take a chance!" 🐇✨


Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 96f9885 and c9beb9a.

Files selected for processing (1)
  • packages/desktop-client/src/components/reports/reports/Spending.tsx (4 hunks)
Files skipped from review as they are similar to previous changes (1)
  • packages/desktop-client/src/components/reports/reports/Spending.tsx

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    -- I pushed a fix in commit <commit_id>, please review it.
    -- Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    -- @coderabbitai generate unit testing code for this file.
    -- @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    -- @coderabbitai generate interesting stats about this repository and render them as a table.
    -- @coderabbitai read src/utils.ts and generate unit testing code.
    -- @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    -- @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@olets olets force-pushed the 3376-decrease-privacy-mode-legibility branch from 96f9885 to c9beb9a Compare September 17, 2024 17:44
@olets
Copy link
Author

olets commented Sep 17, 2024

Removed the snapshot updates, reran tests, no snapshot files were generated, and everything passes 🎉 Thanks for the assistance.

This is the first time in dozens of local runs that I've seen this branch pass. It's the first time in seven GitHub Actions runs that its results have matched my local for this branch. Fwiw the "Mobile › opens individual account page and checks that filtering is working" test is failing for me locally on the master branch. Either it's untrustworthy or there's some confound not covered in the test workflow docs. But I do trust the current pass given this branch's changes.

@joel-jeremy
Copy link
Contributor

Nice! We're nearly there. I think there is one remaining item. The budget cell seem to have shrunk:
image

Once that's addressed I think we're good to go! :)

@Jonathan-Fang
Copy link

Really excited for this feature!

@olets
Copy link
Author

olets commented Sep 18, 2024

@joel-jeremy good catch.

While I'm in here: now that PrivacyFilter uses glamor, is there still a reason to use JS state for hover rather than CSS :hover? Were you accounting for some edge case or can I safely make the switch? Using :hover would make it easier to debug the cell height.

@joel-jeremy
Copy link
Contributor

joel-jeremy commented Sep 18, 2024

@joel-jeremy good catch.

While I'm in here: now that PrivacyFilter uses glamor, is there still a reason to use JS state for hover rather than CSS :hover? Were you accounting for some edge case or can I safely make the switch? Using :hover would make it easier to debug the cell height.

Feel free to use :hover as long as it's functionally the same :) I just avoided glamor early on because I was also attempting to migrate to a different CSS library at the time. So I tried to minimize usage of glamor but realized there's no point doing that. It's easier to use className + glamor then replace glamor later on than doing inline styles now then migrating.

@youngcw youngcw added this to the v24.10.0 milestone Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants