Comments (4)
The colors are just different font sizes being rescaled. For example:
.title {
@include font-size(40px);
}
This is the green line. A font size of 40px
stays 40px
in viewports with a size larger than 1200px
. Below 1200px
, the font size is rescaled and at viewport of 360px
, the font size is about 27px
. Note that every font size is generated in a combination of rem
and vw
units, but the I've mapped this to px
in the graph to make it easier to understand.
The factor is a configuration variable. You don't have to understand how the factor works to make use of RFS. The higher the factor, the less difference there is between font sizes on small screens (on the graph, the lines would lay closer to each other). The lower the factor, the less influence RFS has, which results in bigger font sizes for small screens.
Did this help you a bit or did it just confuse you more, @nettiopsu?
from rfs.
Ah yeah I see now. Then in fact "Base font size" is "Base font sizeS", because there are multiple fonts. In addition, my focus point was somehow concentrated in breakpoint 0, where font-sizes are not marked for the lines, however it should be in fact in the breakpoint 1200. Maybe this breakpoint could be somehow marked with another color for example?
It would be nice if you could copy your explanations to README.MD if someone like me will try to understand how does it work :) It would be great
from rfs.
Hi
I am trying to overwrite the $rfs-breakpoint: 1200px !default; with 1024px.
body {
$rfs-breakpoint: 1024px;
}
but it doesn't work.
from rfs.
How to calculate the factor value and base font-size correctly? I have website layout designed with 18px
paragraphs font-size on 1280px
artboard and 16px
paragraphs font-size on 375px
mobile artboard. How deal if designer's headings and other font styles has different factor?
from rfs.
Related Issues (20)
- Error while running less - Potentially unhandled rejection [2] Could not parse call arguments or missing ')' on line 120 HOT 5
- Error with custom values HOT 1
- rfs() doens't work inside calc()
- PostCSS 8 compatibility HOT 2
- Strange values generated in Bootstrap 4.6 HOT 1
- Unclear doc concerning rfs-base-value or bug
- Use Sass Modules (dart-sass) HOT 18
- RFS + Less + css variables warning HOT 3
- Is RFS installed and enabled as part of Bootstrap 5? HOT 5
- Variation in size range seems too small HOT 1
- Migrate to postcss 8.x HOT 1
- rfs not working with $variable list ? HOT 1
- Minimum font size. HOT 2
- Feature Request - add overloads for shorthand mixins HOT 2
- rem and px have incompatible units in rfs-breakpoint HOT 2
- $rfs-base-value with rem breaks
- How to it this with tailwind ? HOT 4
- Sass ABS deprecation warning HOT 2
- using rfs() in SCSS with PostCSS syntax doesnt work HOT 1
- How to use it with react ? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rfs.