Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<div class="umb-contentpicker umb-editor" ng-controller="Our.Umbraco.EditorThemeColorPickerController">
<p ng-if="colorThemes === 0">
<localize key="themeColorPicker_noThemesCreated">No color themes created</localize>
</p>
<ul class="theme-color-picker-themes" ng-if="colorThemes.length > 0">
<!-- How to keep track of the active theme? ng-class="theme.id === model.value.id ? 'is-default':''" -->
<li class="theme-color-picker-theme edit-view" ng-class="$index === model.value.id ? 'is-default':''" ng-repeat="theme in colorThemes track by $index">
<button class="btn-select-theme" ng-click="selectTheme($index)" type="button" prevent-default title=""><!-- {{selectThemeTitle}} -->
<div class="theme-wrap" style="background-color:#{{theme.backgroundColor}}">
<p class="theme-color-picker-center-text" style="color:#{{theme.textColor}}">
{{theme.previewText}}
</p>
</div>
</button>
</li>
</ul>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment