2018-08-23 21:30:00 -04:00
|
|
|
<div class="themes-list-header">
|
2022-10-07 19:06:20 -04:00
|
|
|
<DButton
|
2023-08-31 05:49:35 -04:00
|
|
|
@action={{fn this.changeView this.THEMES}}
|
2022-10-07 19:06:20 -04:00
|
|
|
@label="admin.customize.theme.title"
|
2023-08-31 05:49:35 -04:00
|
|
|
class={{concat-class "themes-tab" "tab" (if this.themesTabActive "active")}}
|
2022-10-07 19:06:20 -04:00
|
|
|
/>
|
|
|
|
<DButton
|
2023-08-31 05:49:35 -04:00
|
|
|
@action={{fn this.changeView this.COMPONENTS}}
|
2022-10-07 19:06:20 -04:00
|
|
|
@label="admin.customize.theme.components"
|
|
|
|
@icon="puzzle-piece"
|
2023-08-31 05:49:35 -04:00
|
|
|
class={{concat-class
|
|
|
|
"components-tab"
|
|
|
|
"tab"
|
|
|
|
(if this.componentsTabActive "active")
|
|
|
|
}}
|
2022-10-07 19:06:20 -04:00
|
|
|
/>
|
2018-08-23 21:30:00 -04:00
|
|
|
</div>
|
|
|
|
|
2024-01-10 18:38:08 -05:00
|
|
|
{{#if this.showSearchAndFilter}}
|
2024-01-04 00:00:25 -05:00
|
|
|
<div class="themes-list-search">
|
|
|
|
<Input
|
|
|
|
class="themes-list-search__input"
|
|
|
|
placeholder={{i18n "admin.customize.theme.search_placeholder"}}
|
|
|
|
autocomplete="off"
|
|
|
|
@type="search"
|
|
|
|
@value={{mut this.searchTerm}}
|
2024-01-03 22:29:08 -05:00
|
|
|
/>
|
2024-01-04 00:00:25 -05:00
|
|
|
{{d-icon "search"}}
|
|
|
|
</div>
|
2024-01-10 18:38:08 -05:00
|
|
|
<div class="themes-list-filter">
|
|
|
|
<div class="themes-list-filter__label">
|
|
|
|
{{i18n "admin.customize.theme.filter_by"}}
|
|
|
|
</div>
|
|
|
|
<ComboBox
|
|
|
|
@content={{this.selectableFilters}}
|
|
|
|
@value={{this.filter}}
|
|
|
|
class="themes-list-filter__input"
|
|
|
|
/>
|
2024-01-03 22:29:08 -05:00
|
|
|
</div>
|
2024-01-10 18:38:08 -05:00
|
|
|
{{/if}}
|
2024-01-04 00:00:25 -05:00
|
|
|
<div class="themes-list-container">
|
2022-07-05 13:41:31 -04:00
|
|
|
{{#if this.hasThemes}}
|
2024-01-03 22:29:08 -05:00
|
|
|
{{#if (and this.hasActiveThemes (not this.inactiveFilter))}}
|
2022-07-05 13:41:31 -04:00
|
|
|
{{#each this.activeThemes as |theme|}}
|
2022-06-30 06:30:50 -04:00
|
|
|
<ThemesListItem
|
|
|
|
@theme={{theme}}
|
2023-11-13 07:29:20 -05:00
|
|
|
@navigateToTheme={{fn this.navigateToTheme theme}}
|
2022-06-30 06:30:50 -04:00
|
|
|
/>
|
2018-08-30 15:23:15 -04:00
|
|
|
{{/each}}
|
|
|
|
|
2024-01-03 22:29:08 -05:00
|
|
|
{{#if (and this.hasInactiveThemes (not this.activeFilter))}}
|
|
|
|
<div class="themes-list-container__item inactive-indicator">
|
2019-01-23 04:20:13 -05:00
|
|
|
<span class="empty">
|
2023-10-08 17:35:53 -04:00
|
|
|
<div class="info">
|
|
|
|
{{#if this.selectInactiveMode}}
|
|
|
|
<Input
|
|
|
|
@type="checkbox"
|
2023-11-28 04:35:36 -05:00
|
|
|
@checked={{or
|
2023-10-08 17:35:53 -04:00
|
|
|
(eq this.allInactiveSelected true)
|
|
|
|
(eq this.someInactiveSelected true)
|
2023-11-28 04:35:36 -05:00
|
|
|
}}
|
2023-10-08 17:35:53 -04:00
|
|
|
class="toggle-all-inactive"
|
|
|
|
indeterminate={{this.someInactiveSelected}}
|
|
|
|
{{on "click" this.toggleAllInactive}}
|
|
|
|
/>
|
|
|
|
{{else}}
|
|
|
|
<DButton
|
2024-02-29 05:47:07 -05:00
|
|
|
class="btn-transparent select-inactive-mode"
|
2023-10-08 17:35:53 -04:00
|
|
|
@action={{this.toggleInactiveMode}}
|
|
|
|
>
|
|
|
|
{{d-icon "list"}}
|
|
|
|
</DButton>
|
|
|
|
{{/if}}
|
|
|
|
{{#if this.selectInactiveMode}}
|
|
|
|
<span class="select-inactive-mode-label">
|
|
|
|
{{i18n
|
|
|
|
"admin.customize.theme.selected"
|
|
|
|
count=this.selectedCount
|
|
|
|
}}
|
|
|
|
</span>
|
|
|
|
{{else if this.themesTabActive}}
|
|
|
|
<span class="header">
|
|
|
|
{{i18n "admin.customize.theme.inactive_themes"}}
|
|
|
|
</span>
|
|
|
|
{{else}}
|
|
|
|
<span class="header">
|
|
|
|
{{i18n "admin.customize.theme.inactive_components"}}
|
|
|
|
</span>
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
{{#if this.selectInactiveMode}}
|
|
|
|
<a
|
|
|
|
href
|
|
|
|
{{on "click" this.toggleInactiveMode}}
|
|
|
|
class="cancel-select-inactive-mode"
|
|
|
|
>
|
|
|
|
{{i18n "admin.customize.theme.cancel"}}
|
|
|
|
</a>
|
|
|
|
<DButton
|
|
|
|
class="btn btn-delete"
|
|
|
|
@action={{this.deleteConfirmation}}
|
2023-11-28 04:35:36 -05:00
|
|
|
@disabled={{eq this.selectedCount 0}}
|
2023-10-08 17:35:53 -04:00
|
|
|
>
|
|
|
|
{{d-icon "trash-alt"}}
|
|
|
|
Delete
|
|
|
|
</DButton>
|
|
|
|
{{/if}}
|
|
|
|
</div>
|
2019-01-23 04:20:13 -05:00
|
|
|
</span>
|
|
|
|
</div>
|
2018-08-30 15:23:15 -04:00
|
|
|
{{/if}}
|
|
|
|
{{/if}}
|
2019-01-23 04:20:13 -05:00
|
|
|
|
2024-01-03 22:29:08 -05:00
|
|
|
{{#if (and this.hasInactiveThemes (not this.activeFilter))}}
|
2022-07-05 13:41:31 -04:00
|
|
|
{{#each this.inactiveThemes as |theme|}}
|
2022-06-30 06:30:50 -04:00
|
|
|
<ThemesListItem
|
2023-03-10 15:15:31 -05:00
|
|
|
@classNames="inactive-theme"
|
2022-06-30 06:30:50 -04:00
|
|
|
@theme={{theme}}
|
2023-11-13 07:29:20 -05:00
|
|
|
@navigateToTheme={{fn this.navigateToTheme theme}}
|
2023-10-08 17:35:53 -04:00
|
|
|
@selectInactiveMode={{this.selectInactiveMode}}
|
2022-06-30 06:30:50 -04:00
|
|
|
/>
|
2019-01-23 04:20:13 -05:00
|
|
|
{{/each}}
|
|
|
|
{{/if}}
|
2018-08-23 21:30:00 -04:00
|
|
|
{{else}}
|
2024-01-03 22:29:08 -05:00
|
|
|
<div class="themes-list-container__item">
|
2020-03-11 04:23:10 -04:00
|
|
|
<span class="empty">{{i18n "admin.customize.theme.empty"}}</span>
|
2018-08-23 21:30:00 -04:00
|
|
|
</div>
|
|
|
|
{{/if}}
|
2019-02-07 22:27:35 -05:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="create-actions">
|
2022-07-05 13:41:31 -04:00
|
|
|
<DButton
|
|
|
|
@action={{this.installModal}}
|
|
|
|
@icon="upload"
|
|
|
|
@label="admin.customize.install"
|
2023-08-31 05:49:35 -04:00
|
|
|
class="btn-primary"
|
2022-07-05 13:41:31 -04:00
|
|
|
/>
|
2019-02-07 22:27:35 -05:00
|
|
|
</div>
|