Skip to content
This repository has been archived by the owner on Jun 4, 2024. It is now read-only.

Issue 526 - Copy/paste does not work in certain situations #728

Merged
merged 6 commits into from
Apr 14, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](http://semver.org/).

## [Unreleased]
### Fixed
- [#728](https://github.com/plotly/dash-table/pull/728) Fix copy/paste on readonly cells

## [4.6.2] - 2020-04-01
### Changed
- [#713](https://github.com/plotly/dash-table/pull/713) Update from React 16.8.6 to 16.13.0
Expand Down
1 change: 1 addition & 0 deletions src/dash-table/components/CellLabel/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ export default class CellLabel extends PureComponent<IProps> {
const el = this.refs.el as HTMLDivElement;

if (applyFocus && el && document.activeElement !== el) {
window.getSelection()?.selectAllChildren(el);
el.focus();
}
}
Expand Down
26 changes: 14 additions & 12 deletions src/dash-table/components/Table/Table.less
Original file line number Diff line number Diff line change
Expand Up @@ -173,10 +173,10 @@
&::placeholder {
color: black;
}

&:focus {
outline: none;

&::placeholder {
opacity: 0;
}
Expand All @@ -193,7 +193,7 @@

&:hover {
color: hotpink;

&:disabled {
color: graytext
}
Expand All @@ -204,7 +204,7 @@
}
}
}

.dash-spreadsheet-container {
.reset-css();
display: flex;
Expand Down Expand Up @@ -365,20 +365,22 @@
}

.dash-cell-value {
height: 100%;
width: 100%;
height: 100%;
width: 100%;

&.unfocused::selection {
background-color: transparent;
}

&.unfocused {
caret-color: transparent;
}
}

input.dash-cell-value {
position: absolute;
left: 0;
top: 0;
&.unfocused::selection {
background-color: transparent;
}
&.unfocused {
caret-color: transparent;
}
}

.cell-value-shadow {
Expand Down