mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-22 10:21:36 +03:00
57 lines
2.2 KiB
Handlebars
57 lines
2.2 KiB
Handlebars
<div class="gh-dashboard5-minichart gh-dashboard5-mix {{if this.isChartTiers 'is-tiers'}}">
|
|
<div class="gh-dashboard5-content">
|
|
<div class="gh-dashboard5-data">
|
|
<Dashboard::v5::Parts::Metric
|
|
@label="Paid mix" />
|
|
|
|
{{#if this.isChartCadence}}
|
|
<div class="gh-dashboard5-legend">
|
|
<div class="gh-dashboard5-legend-item">Monthly</div>
|
|
<div class="gh-dashboard5-legend-item">Annual</div>
|
|
</div>
|
|
{{/if}}
|
|
</div>
|
|
<div class="gh-dashboard5-chart {{if this.isChartCadence "narrow"}}" {{did-insert this.loadCharts}}>
|
|
{{#if this.loading}}
|
|
<div class="gh-dashboard5-chart-loading">
|
|
<div class="gh-loading-spinner"></div>
|
|
</div>
|
|
{{else}}
|
|
<div class="gh-dashboard5-chart-container">
|
|
<div class="gh-dashboard5-chart-box">
|
|
<EmberChart
|
|
@type={{this.chartType}}
|
|
@data={{this.chartData}}
|
|
@options={{this.chartOptions}}
|
|
@height={{110}} />
|
|
</div>
|
|
|
|
<div id="gh-dashboard5-mix-tooltip" class="gh-dashboard5-tooltip">
|
|
<div class="gh-dashboard5-tooltip-value">
|
|
-
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{{/if}}
|
|
</div>
|
|
</div>
|
|
|
|
{{#if this.hasMultipleTiers }}
|
|
<div class="gh-dashboard5-select">
|
|
<PowerSelect
|
|
@selected={{this.selectedModeOption}}
|
|
@options={{this.modeOptions}}
|
|
@searchEnabled={{false}}
|
|
@onChange={{this.onSwitchMode}}
|
|
@triggerComponent="gh-power-select/trigger"
|
|
@triggerClass="gh-contentfilter-menu-trigger"
|
|
@dropdownClass="gh-contentfilter-menu-dropdown is-narrow"
|
|
@matchTriggerWidth={{false}}
|
|
as |option|
|
|
>
|
|
{{#if option.name}}{{option.name}}{{else}}<span class="red">Unknown option</span>{{/if}}
|
|
</PowerSelect>
|
|
</div>
|
|
{{/if}}
|
|
</div>
|