Fixed some minor formatting issues

no issue

- indented conditional template code
- grouped tracked properties together
This commit is contained in:
Kevin Ansfield 2022-11-22 13:15:08 +00:00
parent f25cc00236
commit 3a9209b6a8
2 changed files with 32 additions and 31 deletions

View File

@ -167,37 +167,38 @@
</div>
</div>
</div>
{{#if @payload.productButtonEnabled}}
<div class="kg-settings-panel-control">
<label class="kg-settings-panel-control-label" for="product-button-input">Button text</label>
<div class="kg-settings-panel-control-input">
<input
type="text"
class="gh-input"
id="product-button-input"
name="product-button"
value={{@payload.productButton}}
placeholder="Add button text"
{{on "input" this.setProductButton}}
{{on-key "Enter" (fn this.focusElement "#product-button-input")}}
>
<div class="kg-settings-panel-control">
<label class="kg-settings-panel-control-label" for="product-button-input">Button text</label>
<div class="kg-settings-panel-control-input">
<input
type="text"
class="gh-input"
id="product-button-input"
name="product-button"
value={{@payload.productButton}}
placeholder="Add button text"
{{on "input" this.setProductButton}}
{{on-key "Enter" (fn this.focusElement "#product-button-input")}}
>
</div>
</div>
</div>
<div class="kg-settings-panel-control">
<label class="kg-settings-panel-control-label" for="product-url-input">Button URL</label>
<div class="kg-settings-panel-control-input">
<input
type="text"
class="gh-input"
id="product-url-input"
name="product-url"
value={{@payload.productUrl}}
placeholder="Add URL"
{{on "input" this.setProductUrl}}
{{on-key "Enter" (fn this.focusElement "#product-url-input")}}
>
<div class="kg-settings-panel-control">
<label class="kg-settings-panel-control-label" for="product-url-input">Button URL</label>
<div class="kg-settings-panel-control-input">
<input
type="text"
class="gh-input"
id="product-url-input"
name="product-url"
value={{@payload.productUrl}}
placeholder="Add URL"
{{on "input" this.setProductUrl}}
{{on-key "Enter" (fn this.focusElement "#product-url-input")}}
>
</div>
</div>
</div>
{{/if}}
</KoenigSettingsPanel>

View File

@ -21,12 +21,12 @@ export default class KoenigCardProductComponent extends Component {
@inject config;
@tracked files = null;
imageExtensions = IMAGE_EXTENSIONS;
imageMimeTypes = IMAGE_MIME_TYPES;
@tracked previewSrc = null;
@tracked isDraggedOver = false;
imageExtensions = IMAGE_EXTENSIONS;
imageMimeTypes = IMAGE_MIME_TYPES;
handlesDragDrop = true;
get isButtonIncomplete() {