pm fix
This commit is contained in:
parent
151d9767b2
commit
2ad74f1a06
1 changed files with 1 additions and 19 deletions
|
@ -119,7 +119,7 @@ const getCssShadowFilter = (input) => {
|
||||||
|
|
||||||
return input
|
return input
|
||||||
// drop-shadow doesn't support inset or spread
|
// drop-shadow doesn't support inset or spread
|
||||||
.filter((shad) => console.log(shad) || !shad.inset && Number(shad.spread) === 0)
|
.filter((shad) => !shad.inset && Number(shad.spread) === 0)
|
||||||
.map((shad) => [
|
.map((shad) => [
|
||||||
shad.x,
|
shad.x,
|
||||||
shad.y,
|
shad.y,
|
||||||
|
@ -132,24 +132,6 @@ const getCssShadowFilter = (input) => {
|
||||||
.join(' ')
|
.join(' ')
|
||||||
}
|
}
|
||||||
|
|
||||||
const getCssShadowFilter = (input) => {
|
|
||||||
if (input.length === 0) {
|
|
||||||
return 'none'
|
|
||||||
}
|
|
||||||
|
|
||||||
return input
|
|
||||||
// drop-shadow doesn't support inset or spread
|
|
||||||
.filter((shad) => console.log(shad) || !shad.inset && Number(shad.spread) === 0)
|
|
||||||
.map((shad) => [
|
|
||||||
shad.x,
|
|
||||||
shad.y,
|
|
||||||
// drop-shadow's blur is twice as strong compared to box-shadow
|
|
||||||
shad.blur / 2
|
|
||||||
].map(_ => _ + 'px').concat([
|
|
||||||
getCssColor(shad.color, shad.alpha)
|
|
||||||
]).join(' ')).join(', ')
|
|
||||||
}
|
|
||||||
|
|
||||||
const getCssColor = (input, a) => {
|
const getCssColor = (input, a) => {
|
||||||
let rgb = {}
|
let rgb = {}
|
||||||
if (typeof input === 'object') {
|
if (typeof input === 'object') {
|
||||||
|
|
Loading…
Add table
Reference in a new issue