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

Calendar #3989

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Calendar #3989

wants to merge 2 commits into from

Conversation

TaniaP26
Copy link

@TaniaP26 TaniaP26 commented Dec 3, 2024

Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job on meeting the task requirements! 🎉 The code is well-structured and follows the specified guidelines. Just make sure to update the stylesheet link to point to the compiled .css file instead of the .scss file to ensure proper styling in the browser. Keep up the excellent work! 😊

✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨

@@ -9,10 +9,43 @@
<title>Calendar</title>
<link
rel="stylesheet"
href="styles/index.scss"
href="styles/main.scss"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The href attribute is linking to a .scss file (styles/main.scss). Browsers cannot directly interpret SCSS files. You should link to the compiled CSS file instead, such as styles/main.css.

@@ -0,0 +1,61 @@
@import './utils/variables';

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure that the file ./utils/variables exists and contains the necessary variable definitions, such as $width-calendar, $width-square, $week-day, and $month-length. Without these definitions, the SCSS will not compile correctly.

display: flex;
flex-wrap: wrap;
gap: 1px;
width: $width-calendar;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The variable $width-calendar is used here. Make sure it is defined in the imported variables file, otherwise, this will cause a compilation error.

width: $width-calendar;
margin: auto;

@each $name, $number in $week-day {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The loop uses $week-day. Ensure that $week-day is a map or list defined in the variables file, as it is used to dynamically generate styles.

text-align: center;
line-height: $width-square;

@for $i from 1 through $month-length {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The loop uses $month-length. Ensure that $month-length is defined in the variables file, as it is used to dynamically generate styles for each day of the month.

@@ -0,0 +1,7 @@
.calendar {
@each $name, $number in $week-day {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure that the variable $week-day is defined and accessible in this context. It should be a map or list that provides the necessary data for the @each loop to function correctly.

.calendar {
@each $name, $number in $week-day {
&--start-day--#{name} {
margin-left: (($number - 1) * $width-square) + ($number - 1);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The variable $width-square is used here. Make sure it is defined and accessible in this context, otherwise, this will cause a compilation error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants