Code Monkey home page Code Monkey logo

Comments (6)

MBilalShafi avatar MBilalShafi commented on September 27, 2024 1

@AlexCarlston Just in case the rows you don't want to be dragged are always on top or bottom of the other rows, you could use row pinning, which disallows reordering for the rows that are pinned to top or bottom.

Here's an example: https://codesandbox.io/s/amazing-lovelace-swdghy?file=/Demo.tsx

Could that satisfy your use case by any chance?

from mui-x.

cherniavskii avatar cherniavskii commented on September 27, 2024

Hi @AlexCarlston
Currently, it's not possible out of the box.

In most use cases reordering one row impacts the order of other rows, even if they cannot be reordered directly.
Could you provide more details about your use case?

from mui-x.

AlexCarlston avatar AlexCarlston commented on September 27, 2024

Sorry for the rough diagram, the below picture is the use case.

Screenshot 2023-09-18 at 11 58 23 AM

from mui-x.

cherniavskii avatar cherniavskii commented on September 27, 2024

Could you clarify your expectations regarding rows that have reordering disabled?
Imagine that row 2 has reordering disabled, while rows 1 and 3 can be reordered:

What do you expect to happen when the user reorders row 3 and puts it between row 1 and row 2?

from mui-x.

AlexCarlston avatar AlexCarlston commented on September 27, 2024

@cherniavskii I expect it to be impossible to swap with row 1 and 2. Instead of being a row, I would code it to return dynamic data on an object, to act as a column. In our use case we won't show property from an object, but instead map an object to the column object (in which we show 3 properties of).

from mui-x.

AlexCarlston avatar AlexCarlston commented on September 27, 2024

And in this example the icon would be removed for row 1 and 2

from mui-x.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.