Skip to content

Commit

Permalink
'Unknown Color' Error with Transparent Background
Browse files Browse the repository at this point in the history
  • Loading branch information
maurofmferrao committed Mar 5, 2024
1 parent 7778cff commit 7a66aba
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions ui/src/core/forms.js
Original file line number Diff line number Diff line change
Expand Up @@ -1758,6 +1758,9 @@ window.forms = {
$(el).colorpicker({
container: $(el).find('.picker-container'),
align: 'left',
format: ($(el).data('colorFormat') !== undefined) ?
$(el).data('colorFormat') :
false,
});

const $inputElement = $(el).find('input');
Expand Down
1 change: 1 addition & 0 deletions ui/src/templates/forms/inputs/color.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
{{#if visibility}}data-visibility="{{visibility}}"{{/if}}
{{#if dependsOn}}data-depends-on="{{dependsOn}}"{{/if}}
{{#if isRequired}}data-is-required="{{isRequired}}"{{/if}}
{{#if colorFormat}}data-color-format="{{colorFormat}}"{{/if}}
>
{{#if title}}
<label for="input_{{id}}" class="control-label"><strong>{{title}}</strong></label>
Expand Down
2 changes: 1 addition & 1 deletion ui/src/templates/forms/layout.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<form id="layoutFormEdit" class="XiboForm">
<div class="tab-content">
<div class="tab-pane active" id="generalTab">
{{> inputs/color value=layout.backgroundColor id="backgroundColor" title=trans.layout.backgroundColor helpText=trans.layout.backgroundColorHelpText }}
{{> inputs/color value=layout.backgroundColor id="backgroundColor" colorFormat="rgb" title=trans.layout.backgroundColor helpText=trans.layout.backgroundColorHelpText }}

<div class="form-group">
<label class="control-label">
Expand Down

0 comments on commit 7a66aba

Please sign in to comment.