From 0eedac46820a37c032e5f08a9796e2504818dca8 Mon Sep 17 00:00:00 2001 From: Pouya Date: Wed, 3 Mar 2021 14:15:29 +0330 Subject: [PATCH] feat: add webkit-tap-highlight-color basy style --- index.js | 7 ++++++- src/tailwind/tailwind.config.js | 5 ++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 74c8651211f..f0853d3a6e4 100644 --- a/index.js +++ b/index.js @@ -4,7 +4,7 @@ const baseRtl = require("./dist/base.rtl.js") const styled = require("./dist/styled.js") const styledRtl = require("./dist/styled.rtl.js") -module.exports = ({ addComponents, addUtilities, config }) => { +module.exports = ({ addBase, addComponents, addUtilities, config }) => { // because rollupjs doesn't supprt dynamic require let file = styled if (config('daisyui.styled') === false && config('daisyui.rtl') === false) { @@ -17,6 +17,11 @@ module.exports = ({ addComponents, addUtilities, config }) => { file = styledRtl } addComponents(file) + if (config('daisyui.base') !== false) { + addBase({ + 'html': { '-WebkitTapHighlightColor': 'transparent' }, + }) + } if (config('daisyui.themes') === true) { addComponents(themes) } diff --git a/src/tailwind/tailwind.config.js b/src/tailwind/tailwind.config.js index 4f415319305..daac7635f0d 100644 --- a/src/tailwind/tailwind.config.js +++ b/src/tailwind/tailwind.config.js @@ -6,7 +6,10 @@ module.exports = { }, }, plugins: [ - plugin(function({ addUtilities }) { + plugin(function({ addBase, addUtilities }) { + addBase({ + 'html': { '-WebkitTapHighlightColor': 'transparent' }, + }) addUtilities(require('./utilities/variables'),{ variants: ['responsive'] }) addUtilities(require('./utilities/minHeight'),{ variants: ['responsive'] }) addUtilities(require('./utilities/fontSize'),{ variants: ['responsive'] })