From d737e9355cdd96bc579b2122f71773a18eac2d78 Mon Sep 17 00:00:00 2001 From: Walidoux Date: Thu, 17 Feb 2022 15:43:21 +0100 Subject: [PATCH] feat: new feats (button, transition, config) --- next.config.js | 5 ++++- package.json | 3 ++- styles/abstracts/_variables.scss | 1 + styles/base/_helpers.scss | 10 ++++++++++ styles/base/_root.scss | 8 ++++++++ 5 files changed, 25 insertions(+), 2 deletions(-) diff --git a/next.config.js b/next.config.js index dfa6174..db17b40 100644 --- a/next.config.js +++ b/next.config.js @@ -4,6 +4,9 @@ const path = require("path"); module.exports = { reactStrictMode: true, sassOptions: { - includePaths: [path.join(__dirname, "styles/abstracts")], + includePaths: [ + path.join(__dirname, "styles/abstracts"), + path.join(__dirname, "styles/base"), + ], }, }; diff --git a/package.json b/package.json index 7fca180..cac698a 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,8 @@ "dev": "next dev", "build": "next build", "start": "next start", - "lint": "next lint" + "lint:next": "next lint", + "lint:scss": "npx stylelint \"**/*.scss\" --fix" }, "dependencies": { "next": "12.0.10", diff --git a/styles/abstracts/_variables.scss b/styles/abstracts/_variables.scss index 17942f8..df53156 100644 --- a/styles/abstracts/_variables.scss +++ b/styles/abstracts/_variables.scss @@ -1,3 +1,4 @@ +$default-transition: 0.3s ease; $breakpoints: ( small: 320px, medium: 768px, diff --git a/styles/base/_helpers.scss b/styles/base/_helpers.scss index fe4c30d..71a143b 100644 --- a/styles/base/_helpers.scss +++ b/styles/base/_helpers.scss @@ -1,3 +1,5 @@ +@import "variables"; + %content { position: absolute; content: ""; @@ -27,3 +29,11 @@ left: 50%; transform: translate(-50%, -50%); } + +%button { + outline: none; + border: none; + background: none; + cursor: pointer; + transition: $default-transition; +} diff --git a/styles/base/_root.scss b/styles/base/_root.scss index 1d5abe7..37a0025 100644 --- a/styles/base/_root.scss +++ b/styles/base/_root.scss @@ -7,3 +7,11 @@ } } } + +*, +*::after, +*::before { + margin: 0; + padding: 0; + box-sizing: border-box; +}