Typography: Scale the font size according to screen size
Use viewport width units to scale the font size between 100% and 125%.
This commit is contained in:
		
							parent
							
								
									1ffbee8850
								
							
						
					
					
						commit
						1fd1eb9bfd
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -25,7 +25,7 @@
 | 
			
		|||
  --font-family-body: var(--font-family-sans);
 | 
			
		||||
  --font-family-heading: var(--font-family-monospace);
 | 
			
		||||
 | 
			
		||||
  --text-base-size: 125%;
 | 
			
		||||
  --text-base-size: clamp(100%, 3vw, 125%);
 | 
			
		||||
  --text-base: {{ $base }}{{ $unit }};
 | 
			
		||||
  {{ range $scale -}}
 | 
			
		||||
    --text-{{ .Name }}: calc(var(--text-base) * pow({{ $factor }}, {{ .Value }}));
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue