react-responsive-tools 2.3.22 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.MD +3 -3
- package/dist/index.scss +4 -4
- package/dist/scripts/generateSCSS.mjs +1 -1
- package/dist/scss/_horizontal-breakpoints.scss +1 -1
- package/dist/scss/_horizontal.scss +1 -1
- package/dist/scss/_vertical-breakpoints.scss +1 -1
- package/dist/scss/_vertical.scss +1 -1
- package/index.scss +4 -4
- package/package.json +1 -1
package/README.MD
CHANGED
@@ -29,7 +29,7 @@ npm install react-responsive-tools
|
|
29
29
|
To use the generated SCSS files, import the main SCSS file from the library:
|
30
30
|
|
31
31
|
```scss
|
32
|
-
@
|
32
|
+
@use 'react-responsive-tools' as *;
|
33
33
|
```
|
34
34
|
|
35
35
|
### Import JavaScript
|
@@ -306,7 +306,7 @@ After re-generating the files, the following SCSS mixins will be available:
|
|
306
306
|
#### Horizontal Breakpoints
|
307
307
|
|
308
308
|
```scss
|
309
|
-
@
|
309
|
+
@use "_custom-breakpoints" as *;
|
310
310
|
|
311
311
|
@mixin mob-first($breakpoint) {
|
312
312
|
@media (min-width: map-get($horizontal-breakpoints, $breakpoint)) {
|
@@ -445,7 +445,7 @@ After re-generating the files, the following SCSS mixins will be available:
|
|
445
445
|
#### Vertical Breakpoints
|
446
446
|
|
447
447
|
```scss
|
448
|
-
@
|
448
|
+
@use "_custom-breakpoints" as *;
|
449
449
|
|
450
450
|
@mixin v-mob-first($breakpoint) {
|
451
451
|
@media (min-height: map-get($vertical-breakpoints, $breakpoint)) {
|
package/dist/index.scss
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
@
|
2
|
-
@
|
3
|
-
@
|
4
|
-
@
|
1
|
+
@use "./scss/vertical" as *;
|
2
|
+
@use "./scss/horizontal" as *;
|
3
|
+
@use "./scss/horizontal-breakpoints" as *;
|
4
|
+
@use "./scss/vertical-breakpoints" as *;
|
@@ -1 +1 @@
|
|
1
|
-
import n from"fs";import e from"path";import{fileURLToPath as i}from"url";import{HORIZONTAL_BREAKPOINTS as
|
1
|
+
import n from"fs";import e from"path";import{fileURLToPath as i}from"url";import{HORIZONTAL_BREAKPOINTS as s,VERTICAL_BREAKPOINTS as r}from"../breakpoints.config.js";const o=i(import.meta.url),t=e.dirname(o),l=(c=s,`\n@use "horizontal" as *;\n\n${Object.keys(c).map((n=>`\n/**\n * @mixin for-${n}\n * @description Mixin for applying styles for screens greater than or equal to ${c[n]}px.\n * @example\n * @include for-${n} {\n * // your styles here\n * }\n */\n@mixin for-${n}() {\n @include mob-first(${n}) {\n @content;\n }\n}`)).join("\n")}\n\n${Object.keys(c).map((n=>`\n/**\n * @mixin before-${n}\n * @description Mixin for applying styles for screens less than ${c[n]}px.\n * @example\n * @include before-${n} {\n * // your styles here\n * }\n */\n@mixin before-${n}() {\n @include desk-first(${n}) {\n @content;\n }\n}`)).join("\n")}\n`);var c;const a=(n=>`\n@use "vertical" as *;\n\n${Object.keys(n).map((e=>`\n/**\n * @mixin v-for-${e}\n * @description Mixin for applying styles for screens with height greater than or equal to ${n[e]}px.\n * @example\n * @include v-for-${e} {\n * // your styles here\n * }\n */\n@mixin v-for-${e}() {\n @include v-mob-first(${e}) {\n @content;\n }\n}`)).join("\n")}\n\n${Object.keys(n).map((e=>`\n/**\n * @mixin v-before-${e}\n * @description Mixin for applying styles for screens with height less than ${n[e]}px.\n * @example\n * @include v-before-${e} {\n * // your styles here\n * }\n */\n@mixin v-before-${e}() {\n @include v-desk-first(${e}) {\n @content;\n }\n}`)).join("\n")}\n`)(r);n.writeFileSync(e.resolve(t,"../scss/_horizontal-breakpoints.scss"),l),n.writeFileSync(e.resolve(t,"../scss/_vertical-breakpoints.scss"),a),console.log("SCSS files have been generated successfully.");
|
package/dist/scss/_vertical.scss
CHANGED
package/index.scss
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
@
|
2
|
-
@
|
3
|
-
@
|
4
|
-
@
|
1
|
+
@forward "./dist/scss/vertical";
|
2
|
+
@forward "./dist/scss/horizontal";
|
3
|
+
@forward "./dist/scss/horizontal-breakpoints";
|
4
|
+
@forward "./dist/scss/vertical-breakpoints";
|