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

fix: key and value text should be selectable #217

Merged
merged 1 commit into from
Jan 26, 2023

Conversation

pionxzh
Copy link
Collaborator

@pionxzh pionxzh commented Jan 24, 2023

closes #93

Problem

The text was selectable in V1 but not in V2.
This is because we didn't noticed that userselect: none was introduced by MUI accidentally.

Solution

Add back userselect: text CSS.
And we also improved the selectable range to only the content, which is different from react-json-view. (Check the #screenshots)

Screenshots

@textea/json-viewer

react-json-view

image

@netlify
Copy link

netlify bot commented Jan 24, 2023

Deploy Preview for any-viewer ready!

Name Link
🔨 Latest commit 6aa02b2
🔍 Latest deploy log https://app.netlify.com/sites/any-viewer/deploys/63cf8b7c47c8b20008ddbda3
😎 Deploy Preview https://deploy-preview-217--any-viewer.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 settings.

@codecov
Copy link

codecov bot commented Jan 24, 2023

Codecov Report

Base: 87.40% // Head: 87.36% // Decreases project coverage by -0.05% ⚠️

Coverage data is based on head (6aa02b2) compared to base (7884a29).
Patch coverage: 73.33% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #217      +/-   ##
==========================================
- Coverage   87.40%   87.36%   -0.05%     
==========================================
  Files          18       18              
  Lines        1969     1978       +9     
  Branches      349      349              
==========================================
+ Hits         1721     1728       +7     
- Misses        248      250       +2     
Impacted Files Coverage Δ
src/components/DataTypes/Object.tsx 86.34% <60.00%> (-0.50%) ⬇️
src/components/DataKeyPair.tsx 69.01% <100.00%> (+0.33%) ⬆️
src/components/DataTypeLabel.tsx 92.85% <100.00%> (+0.26%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

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.

Text not selectable
1 participant