mirror of
https://github.com/qlik-oss/nebula.js.git
synced 2025-12-19 17:58:43 -05:00
fix: guard against bad theme (#1701)
This commit is contained in:
@@ -56,13 +56,13 @@ export default function theme(resolvedTheme) {
|
||||
uiPalettes() {
|
||||
const pals = [];
|
||||
resolvedTheme.palettes.ui.forEach((s) => {
|
||||
const colors = s.colors[0] !== 'none' ? ['none', ...s.colors] : s.colors;
|
||||
const colors = s.colors && s.colors[0] !== 'none' ? ['none', ...s.colors] : s.colors;
|
||||
pals.push({
|
||||
key: 'ui',
|
||||
name: s.name,
|
||||
translation: s.translation,
|
||||
type: 'row',
|
||||
colors,
|
||||
colors: colors || [],
|
||||
});
|
||||
});
|
||||
return pals;
|
||||
|
||||
Reference in New Issue
Block a user