1.0.0 • Published 4 years ago

@therobot/tailwindcss-regression-values v1.0.0

Weekly downloads
1
License
ISC
Repository
-
Last release
4 years ago

Tailwind Regression Values

// tailwind.config.js
module.exports = {
  plugins: [regressionPlugin()],
  theme: {
    regression: theme => ({
      'zero-line': {
        points: [
          [0.75, 0.65],
          [6, 4.75],
        ],
        values: theme('fontSize'),
        prop: 'lineHeight',
        type: 'linear', // 'exponential', 'logarithmic', 'polynomial', 'power', 'linear'
      },
    }),
  },
}

with default fontSize values of base: '1rem', '2xl': '1.5rem', '4xl': '2.25rem'

.zero-line-base {
  line-height: 0.88rem;
}
.zero-line-lg {
  line-height: 0.99rem;
}
.zero-line-2xl {
  line-height: 1.33rem;
}
.zero-line-4xl {
  line-height: 1.97rem;
}