From 894cebb5c4875a93bf85dba5c43deb97248f9e3e Mon Sep 17 00:00:00 2001 From: Ovramenko Andrii Date: Mon, 27 Jan 2025 17:44:03 +0200 Subject: [PATCH] split css file --- src/style.css | 40 ------------------------------------- src/styles/blocks/page.css | 3 +++ src/styles/blocks/stars.css | 36 +++++++++++++++++++++++++++++++++ src/styles/style.css | 2 ++ 4 files changed, 41 insertions(+), 40 deletions(-) delete mode 100644 src/style.css create mode 100644 src/styles/blocks/page.css create mode 100644 src/styles/blocks/stars.css create mode 100644 src/styles/style.css diff --git a/src/style.css b/src/style.css deleted file mode 100644 index 9d904feeb6..0000000000 --- a/src/style.css +++ /dev/null @@ -1,40 +0,0 @@ -body { - margin: 0; -} - -.stars { - display: flex; -} - -.stars__star { - height: 16px; - width: 16px; - margin-right: 4px; - background-repeat: no-repeat; - background-position: center; - background-image: url(images/star.svg); -} - -.stars--0 > .stars__star { - background-image: url(images/star.svg); -} - -.stars--1 :nth-child(-n + 1) { - background-image: url(images/star-active.svg); -} - -.stars--2 :nth-child(-n + 2) { - background-image: url(images/star-active.svg); -} - -.stars--3 :nth-child(-n + 3) { - background-image: url(images/star-active.svg); -} - -.stars--4 :nth-child(-n + 4) { - background-image: url(images/star-active.svg); -} - -.stars--5 > .stars__star { - background-image: url(images/star-active.svg); -} diff --git a/src/styles/blocks/page.css b/src/styles/blocks/page.css new file mode 100644 index 0000000000..293d3b1f13 --- /dev/null +++ b/src/styles/blocks/page.css @@ -0,0 +1,3 @@ +body { + margin: 0; +} diff --git a/src/styles/blocks/stars.css b/src/styles/blocks/stars.css new file mode 100644 index 0000000000..41a375d515 --- /dev/null +++ b/src/styles/blocks/stars.css @@ -0,0 +1,36 @@ +.stars { + display: flex; +} + +.stars__star { + height: 16px; + width: 16px; + margin-right: 4px; + background-repeat: no-repeat; + background-position: center; + background-image: url(../../images/star.svg); +} + +.stars--0 > .stars__star { + background-image: url(../../images/star.svg); +} + +.stars--1 > :nth-child(-n + 1) { + background-image: url(../../images/star-active.svg); +} + +.stars--2 > :nth-child(-n + 2) { + background-image: url(../../images/star-active.svg); +} + +.stars--3 > :nth-child(-n + 3) { + background-image: url(../../images/star-active.svg); +} + +.stars--4 > :nth-child(-n + 4) { + background-image: url(../../images/star-active.svg); +} + +.stars--5 > .stars__star { + background-image: url(../../images/star-active.svg); +} diff --git a/src/styles/style.css b/src/styles/style.css new file mode 100644 index 0000000000..def8cdf249 --- /dev/null +++ b/src/styles/style.css @@ -0,0 +1,2 @@ +@import 'blocks/stars.css'; +@import 'blocks/page.css';