Skip to content

Commit

Permalink
Merge pull request #19 from chasegiunta/master
Browse files Browse the repository at this point in the history
Adds possibility for predefined palettes
  • Loading branch information
Rias committed Feb 22, 2019
2 parents 9e0f478 + 4454a02 commit 980ef4f
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/fields/ColourSwatches.php
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,20 @@ public function getSettingsHtml()
],
'rows' => $rows,
];

$paletteOptions = [];
$paletteOptions[] = [
'label' => null,
'value' => null,
];
foreach (array_keys((array) Plugin::$plugin->settings->palettes) as $palette) {
$paletteOptions[] = [
'label' => $palette,
'value' => $palette,
];
}

$currentPalette = $this->palette;

$paletteOptions = [];
$paletteOptions[] = [
Expand Down

0 comments on commit 980ef4f

Please sign in to comment.