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

Can't align timelineContent #431

Open
brmbi opened this issue Oct 17, 2023 · 3 comments
Open

Can't align timelineContent #431

brmbi opened this issue Oct 17, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@brmbi
Copy link

brmbi commented Oct 17, 2023

Describe the bug
Div wraps my custom component and has align-items: center. It has one more div inside, and then my component. I can't set up full width unless I hardcode width value..

To Reproduce
Steps to reproduce the behavior:

  1. Create Chrono component
  2. For items return array of object only containing {timelineContent: }

Expected behavior
I would expect to be able to modify these simple things.

Screenshots
image

Desktop (please complete the following information):

  • OS: Windows 11 Pro
  • Browser Chrome
  • Version 117.0.5938.134
@prabhuignoto prabhuignoto added the bug Something isn't working label Oct 18, 2023
@prabhuignoto
Copy link
Owner

@brmbi can you share the complete code that you are using to setup the timeline

@sashaaldrick
Copy link

sashaaldrick commented Oct 24, 2023

I have this exact same problem! Here is my code @prabhuignoto:

        title: "November 2023",
        cardTitle: "Test Test",
        cardSubtitle: "Stable Release",
        timelineContent: 
        <div className="justify-start"> 
        <ul>
            <li>Test</li>
            <li>Test</li>
            <li>Test</li>
        </ul>
        </div>
    },

@brmbi
Copy link
Author

brmbi commented Oct 26, 2023

You can resolve the issue by adding a class with:

.customContent {
  justify-content: flex-start !important;
  align-items: stretch !important;
} 

And assigning it to the cardText in Chrono component.
So classNames in Chrono component will look like this:

<Chrono
   ... rest of properties,
   classNames={{
                  cardText: styles.customContent,
                }}
 />

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants