aboutsummaryrefslogtreecommitdiff
path: root/src/services/style_setter/style_setter.js
diff options
context:
space:
mode:
authorHJ <30-hj@users.noreply.git.pleroma.social>2021-04-07 17:40:07 +0000
committerHJ <30-hj@users.noreply.git.pleroma.social>2021-04-07 17:40:07 +0000
commit8b96ea93776fd1eb462a7c54822d4f8ad6a9e776 (patch)
tree002a88cdb6e25ea3177b712bc3cdc05a085f19e5 /src/services/style_setter/style_setter.js
parent4e3c4ec1dbbf88b09a84a80519f4ccced5a4dc2c (diff)
parent5c064ccf553ffcd3286ad1b3305633c5c4c4c0c4 (diff)
Merge branch 'settings-import-export' into 'develop'
Settings backup/restore + small fixes See merge request pleroma/pleroma-fe!1372
Diffstat (limited to 'src/services/style_setter/style_setter.js')
-rw-r--r--src/services/style_setter/style_setter.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/services/style_setter/style_setter.js b/src/services/style_setter/style_setter.js
index a2bba67b..f75e6916 100644
--- a/src/services/style_setter/style_setter.js
+++ b/src/services/style_setter/style_setter.js
@@ -380,7 +380,7 @@ export const colors2to3 = (colors) => {
*/
export const shadows2to3 = (shadows, opacity) => {
return Object.entries(shadows).reduce((shadowsAcc, [slotName, shadowDefs]) => {
- const isDynamic = ({ color }) => color.startsWith('--')
+ const isDynamic = ({ color = '#000000' }) => color.startsWith('--')
const getOpacity = ({ color }) => opacity[getOpacitySlot(color.substring(2).split(',')[0])]
const newShadow = shadowDefs.reduce((shadowAcc, def) => [
...shadowAcc,