superset icon indicating copy to clipboard operation
superset copied to clipboard

🐛 Problems creating rows and columns in the superset.

Open LucasSantosGuedes opened this issue 1 year ago • 1 comments

Bug description

🐛 I'm having trouble trying to create divisions on the screen. The superset appears to have limitations in this regard. I can't, for example, create a column and add the number of elements and their divisions. It always breaks. can you help me?

LucasSantosGuedes avatar May 24 '24 14:05 LucasSantosGuedes

Hello @LucasSantosGuedes! I'm here to help you with your Superset issue. I'm a bot designed to assist with bug solving, answering questions, and guiding contributors. Let's tackle this together!

To create rows and columns in Apache Superset without encountering layout issues when adding elements and their divisions, you can follow these key practices:

  1. Use Flexbox for Layout: Utilize the GridContent and GridRow components, which use flexbox to manage the layout of rows and columns. This ensures proper alignment and spacing of elements.

  2. Handle Component Drop Properly: Implement the handleComponentDrop function correctly to manage the addition of new components without breaking the layout.

  3. Use Droppable Areas: Define areas where new components can be dropped using the Droppable component. This helps maintain the layout structure.

  4. Use Resizable Containers: Ensure elements can be resized without breaking the layout by using the ResizableContainer component.

  5. Implement Row and Column Components Properly: Handle the layout of children in Row and Column components, including managing empty states and drop targets.

Here are some code snippets to illustrate these practices:

const GridContent = styled.div`
  display: flex;
  flex-direction: column;
  /* Additional styles */
`;

const GridRow = styled.div`
  display: flex;
  flex-direction: row;
  /* Additional styles */
`;

handleTopDropTargetDrop(dropResult) {
  if (dropResult) {
    this.props.handleComponentDrop({
      ...dropResult,
      destination: {
        ...dropResult.destination,
        index: 0,
      },
    });
  }
}

By following these practices, you can create stable rows and columns in Apache Superset without encountering layout issues [1][2][3][4].

Details

About Dosu This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.

Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.

To continue the conversation, mention @dosu.

dosubot[bot] avatar May 24 '24 14:05 dosubot[bot]

Do you mean in the dashboard editor, like you're not able to drag and drop the layout elements for rows or columns?

image

rusackas avatar May 29 '24 20:05 rusackas

mismo problema, no deja diseñar correctamente, sería util poder ordenarlo

max-dicson-cf avatar Sep 17 '24 03:09 max-dicson-cf

This has been silent for more than 200 days, and I never heard back about my last question, so I'll close it as not-planned. Holler if you're still facing this, and perhaps it'll be more fitting for a Help Discussion.

rusackas avatar Apr 14 '25 18:04 rusackas