Hi, just act like frontend engineer who move figma's styles to css variables (project…
- User
Hi, just act like frontend engineer who move figma's styles to css variables (project bootstrap)
You have next values for font size and line heights for mobile and desktop
Text Style Font Size Desktop Line Height Desktop Font Size Mobile Line Height Mobile Button 3 12px 18px 12px 18px Button 2 14px 18px 14px 18px Button 1 16px 18px 16px 18px Caption 12px 18px 12px 18px Quote 45px 60px 35px 50px Paragraph 2 16px 28px 16px 28px Paragraph 1 18px 38px 16px 32px Subtitle 2 14px 32px 12px 20px Subtitle 1 18px 42px 16px 26px H6 20px 28px 18px 26px H5 24px 32px 22px 30px H4 24px 32px 22px 30px H3 35px 40px 30px 35px H2 45px 60px 40px 55px H1 72px 90px 50px 60px H1 CAPS 72px 80px 45px 55px Please use Paragraph 1 as base font size and line-height
I want to fetch this list as css variables for :root (mobile, tablet and desktop). I don't have exact tablet variables, but please make it smooth transitions (if desktop & mobile are the same, it should stay the same on tablet as well)
I want to use this naming example :root { // Font families --font-family-primary: 'meno-banner', serif; --font-family-secondary: 'aktiv-grotesk', sans-serif; --font-family-tertiary: 'aktiv-grotesk-extended', sans-serif;
// Font sizes --font-size-xs: 0.75rem; /* 12px / --font-size-sm: 0.875rem; / 14px / --font-size-base: 1rem; / 16px / --font-size-lg: 1.125rem; / 18px / --font-size-xl: 1.375rem; / 22px / --font-size-2xl: 1.875rem; / 30px / --font-size-3xl: 2.1875rem; / 35px / --font-size-4xl: 2.5rem; / 40px / --font-size-5xl: 2.8125rem; / 45px / --font-size-6xl: 3.125rem; / 50px */
// Line Heights --line-height-xs: 1.125rem; /* 18px / --line-height-sm: 1.25rem; / 20px / --line-height-base: 1.75rem; / 28px (base) / --line-height-md: 1.625rem; / 26px / --line-height-lg: 2rem; / 32px / --line-height-xl: 2.1875rem; / 35px / --line-height-2xl: 3.125rem; / 50px / --line-height-3xl: 3.4375rem; / 55px / --line-height-4xl: 3.75rem; / 60px */ }
// Tablet @include media-breakpoint-up(md) { :root { // Font Sizes --font-size-xs: 0.75rem; /* 12px / --font-size-sm: 0.875rem; / 14px / --font-size-base: 1rem; / 16px (base) / --font-size-md: 1.125rem; / 18px / --font-size-lg: 1.375rem; / 22px / --font-size-xl: 1.875rem; / 30px / --font-size-2xl: 2.1875rem; / 35px / --font-size-3xl: 2.5rem; / 40px / --font-size-4xl: 2.8125rem; / 45px / --font-size-5xl: 3.125rem; / 50px */
// Line Heights --line-height-xs: 1.125rem; /* 18px */ --line-height-sm: 1.25rem; /* 20px */ --line-height-base: 1.75rem; /* 28px (base) */ --line-height-md: 1.625rem; /* 26px */ --line-height-lg: 2rem; /* 32px */ --line-height-xl: 2.1875rem; /* 35px */ --line-height-2xl: 3.125rem; /* 50px */ - Assistant
Sure! Here's the updated CSS code with the CSS variables for font sizes and line heights based on the given values:
:root { /* Font families */ --font-family-primary: 'meno-banner', serif; --font-family-secondary: 'aktiv-grotesk', sans-serif; --font-family-tertiary: 'aktiv-grotesk-extended', sans-serif; /* Font sizes */ --font-size-xs: 0.75rem; /* 12px */ --font-size-sm: 0.875rem; /* 14px */ --font-size-base: 1rem; /* 16px */ --font-size-lg: 1.125rem; /* 18px */ --font-size-xl: 1.375rem; /* 22px */ --font-size-2xl: 1.875rem; /* 30px */ --font-size-3xl: 2.1875rem; /* 35px */ --font-size-4xl: 2.5rem; /* 40px */ --font-size-5xl: 2.8125rem; /* 45px */ --font-size-6xl: 3.125rem; /* 50px */ /* Line Heights */ --line-height-xs: 1.125rem; /* 18px */ --line-height-sm: 1.25rem; /* 20px */ --line-height-base: 1.75rem; /* 28px (base) */ --line-height-md: 1.625rem; /* 26px */ --line-height-lg: 2rem; /* 32px */ --line-height-xl: 2.1875rem; /* 35px */ --line-height-2xl: 3.125rem; /* 50px */ --line-height-3xl: 3.4375rem; /* 55px */ --line-height-4xl: 3.75rem; /* 60px */ } /* Tablet */ @media (min-width: 768px) { :root { /* Font Sizes */ --font-size-xs: 0.75rem; /* 12px */ --font-size-sm: 0.875rem; /* 14px */ --font-size-base: 1rem; /* 16px (base) */
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.