Skip to content

Bug - Block and Inline exercises: 02-margin-and-padding-2 solution/desired outcome doesn't match the self check #728

@vorpalbullet

Description

@vorpalbullet

Complete the following REQUIRED checkboxes:

  • I have thoroughly read and understand The Odin Project Contributing Guide
  • The title of this issue follows the Bug - location of bug: brief description of bug format, e.g. Bug - Grid exercises: CSS not properly linked to HTML files

The following checkbox is OPTIONAL:

  • I would like to be assigned this issue to work on it

1. Description of the Bug:

The Self Check suggests that there should be "8px between the edge of the card and its content". However, the desired-outcome.png shows a larger gap at the top of the card than at the sides and bottom. The solution.css also causes this larger gap at the top.

Since solution.css doesn't set the top margin of .title, it retains the h1 default margin-block-start: 0.67em resulting in a gap of 18.72px instead of 8px.

2. How To Reproduce:

3. Expected Behavior:

4. Desktop/Device:

  • Device: Laptop 1366 x 768
  • OS: Linux Mint 22
  • Browser: chrome and firefox
  • Version: chrome 140, firefox 143

5. Additional Information:

If you set margin-top: 0 the output matches the Self Check.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: Needs ReviewThis issue/PR needs an initial or additional reviewType: BugInvolves something that isn't working as intended

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions