8000 Removes withOpacity helper · engageinteractive/laravel@a214821 · GitHub
[go: up one dir, main page]

8000
Skip to content

Commit a214821

Browse files
committed
Removes withOpacity helper
CSS vars with opacity supported in TW 3.1
1 parent e59e0d7 commit a214821

File tree

2 files changed

+1
-11
lines changed

2 files changed

+1
-11
lines changed

resources/assets/css/helpers.js

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,5 @@ module.exports = {
55
ratio: (x, y) => `${y / x * 100}%`,
66
relative: (px, unit = 'rem', base = variables['browser-default-font-size']) =>
77
`${px / base}${unit}`,
8-
withOpacity: (variableName) => {
9-
return ({ opacityValue }) => {
10-
if (opacityValue !== undefined) {
11-
return `rgba(var(${variableName}), ${opacityValue})`;
12-
}
13-
14-
return `rgba(var(${variableName}))`;
15-
};
16-
},
178
variables,
189
};

resources/assets/css/tailwind.config.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
const { src } = require('../../../build/helpers');
2-
const { relative, variables, withOpacity } = require('./helpers');
2+
const { relative, variables } = require('./helpers');
33

44
// tailwind settings
55
module.exports = {
@@ -32,7 +32,6 @@ module.exports = {
3232
green: '#22c55e',
3333
red: '#ef4444',
3434
focus: '#3b82f6',
35-
sample: withOpacity('--sample'),
3635
},
3736
fontFamily: {
3837
body: ['custom-body', 'Helvetica', 'sans-serif'],

0 commit comments

Comments
 (0)
0