Skip to content

resolved exervises - js-dom-elements#148

Open
marrcelp wants to merge 6 commits intodevmentor-pl:masterfrom
marrcelp:master
Open

resolved exervises - js-dom-elements#148
marrcelp wants to merge 6 commits intodevmentor-pl:masterfrom
marrcelp:master

Conversation

@marrcelp
Copy link
Copy Markdown

No description provided.

Copy link
Copy Markdown
Owner

@devmentor-pl devmentor-pl left a comment

Choose a reason for hiding this comment

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

Marcelu,

Tutaj wszystko ok 👍 , z jedną drobną uwagą - szczegóły w komentarzu.


} else {
console.log(`Nie znaleziono elementu o podanej klasie`);
}
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

👍

linksWithUrl.forEach((element) => {
const elementUrl = element.getAttribute('data-url');
element.setAttribute('href', elementUrl)
}) No newline at end of file
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

👍

newButton.textContent = buttonSettings.text;

const element = document.querySelector('.parent-for-button');
element.appendChild(newButton); No newline at end of file
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

👍

aElement.setAttribute('href', el.url)
navElement.appendChild(liElement);
liElement.appendChild(aElement);
})) No newline at end of file
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

👍

05/app.js Outdated
Comment on lines +12 to +13
const currSiblings = Array.from(currParent.children);
currSiblings.forEach(el => el.classList.add('siblings'));
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Powinieneś wykluczyć element curr - on sam dla siebie nie jest rodzeństwem :)

Copy link
Copy Markdown
Owner

@devmentor-pl devmentor-pl left a comment

Choose a reason for hiding this comment

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

Super, o to chodziło! :)

// 2
const currSiblings = Array.from(currParent.children);
currSiblings.forEach(el => el.classList.add('siblings'));
currSiblings.filter((el) => !el.classList.contains('js-curr')).forEach(el => el.classList.add('siblings'));
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

👍

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.

2 participants