Repository navigation
Replies: 3 comments
|
Hello there any update in here? |
0 replies
|
Hey, I'm open for PRs. Currently, I can't find the capacity to implement this but I'm willing to review PRs |
0 replies
|
@dilipmer Why do you want to do that ? What is your use case ? Short example displaying the currently edited value beneath the spreadsheet: const App = () => {
const [data, setData] = useState<Matrix<CellBase>>([
[{ value: "Vanilla" }, { value: "Chocolate" }],
[{ value: "Strawberry" }, { value: "Cookies" }],
]);
const [currentActive, setCurrentActive] = useState<Point | undefined>();
return (
<div>
<div>
<Spreadsheet
data={data}
onChange={setData}
onActivate={setCurrentActive}
/>
</div>
<div>
<pre>{JSON.stringify(data)}</pre>
<pre>{JSON.stringify(currentActive)}</pre>
<pre>Currently edited value:
{JSON.stringify(
data[currentActive?.row || 0][currentActive?.column || 0]
)}
</pre>
</div>
</div>
);
}; |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Currently onChage event only return updated matrices. it should also provide more details on what has changed. like provide coords of cell which is changed.
onCellCommit doesn't work properly it just keeps once I make a change.
All reactions