dotCMS / core

Headless/Hybrid Content Management System for Enterprises
http://dotcms.com
Other
851 stars 467 forks source link

SDK: Improve HTML structure in dotCMS React SDK #30137

Open fmontes opened 1 week ago

fmontes commented 1 week ago

Parent Issue

No response

Task

Task description

As a developer working with the dotCMS React SDK, I want to update the @dotcms/react package to include an extra container div in the rows and improve the HTML structure within the <DotcmsLayout /> component. This will give developers more control over the layout and styling of the components.

### Acceptance Criteria
- [ ] The `@dotcms/react` package is updated to include an additional container div within the rows.
- [ ] The HTML structure within the `<DotcmsLayout />` component is improved for better developer control.
- [ ] Developers can easily customize the layout and styling of components using the updated SDK.
fmontes commented 1 day ago

Note to QA

Before this change, the row HTML looked like this:

<div class="row-module custom-row-classes">
    <div class="column-module custom-column-classes">
        <!-- HERE GOES THE CONTENT -->
    </div>
</div>

After these changes, it should look like this:

<div class="custom-rows-classes">
    <div class="container">
        <div class="row-module">
            <div class="column-module">
                <div class="custom-column-classes">
                    <!-- HERE GOES THE CONTENT -->
                </div>
            </div>
        </div>
    </div>
</div>

The custom-rows-classes and custom-column-classes are the classes users can add from the template editor:

CleanShot 2024-10-01 at 09 31 57@2x