mirror of
https://github.com/flarum/core.git
synced 2025-08-06 16:36:47 +02:00
Bundled output for commit 76788efaba
Includes transpiled JS/TS, and Typescript declaration files (typings). [skip ci]
This commit is contained in:
6
extensions/statistics/js/dist-typings/components/StatisticsWidget.d.ts
generated
vendored
6
extensions/statistics/js/dist-typings/components/StatisticsWidget.d.ts
generated
vendored
@@ -1,4 +1,5 @@
|
|||||||
import DashboardWidget, { IDashboardWidgetAttrs } from 'flarum/admin/components/DashboardWidget';
|
import DashboardWidget, { IDashboardWidgetAttrs } from 'flarum/admin/components/DashboardWidget';
|
||||||
|
import { IDateSelection } from './StatisticsWidgetDateSelectionModal';
|
||||||
import type Mithril from 'mithril';
|
import type Mithril from 'mithril';
|
||||||
interface IPeriodDeclaration {
|
interface IPeriodDeclaration {
|
||||||
start: number;
|
start: number;
|
||||||
@@ -9,10 +10,14 @@ export default class StatisticsWidget extends DashboardWidget {
|
|||||||
entities: string[];
|
entities: string[];
|
||||||
periods: undefined | Record<string, IPeriodDeclaration>;
|
periods: undefined | Record<string, IPeriodDeclaration>;
|
||||||
chart: any;
|
chart: any;
|
||||||
|
customPeriod: IDateSelection | null;
|
||||||
timedData: Record<string, undefined | any>;
|
timedData: Record<string, undefined | any>;
|
||||||
lifetimeData: any;
|
lifetimeData: any;
|
||||||
|
customPeriodData: Record<string, undefined | any>;
|
||||||
|
noData: boolean;
|
||||||
loadingLifetime: boolean;
|
loadingLifetime: boolean;
|
||||||
loadingTimed: Record<string, 'unloaded' | 'loading' | 'loaded' | 'fail'>;
|
loadingTimed: Record<string, 'unloaded' | 'loading' | 'loaded' | 'fail'>;
|
||||||
|
loadingCustom: Record<string, 'unloaded' | 'loading' | 'loaded' | 'fail'>;
|
||||||
selectedEntity: string;
|
selectedEntity: string;
|
||||||
selectedPeriod: undefined | string;
|
selectedPeriod: undefined | string;
|
||||||
chartEntity?: string;
|
chartEntity?: string;
|
||||||
@@ -20,6 +25,7 @@ export default class StatisticsWidget extends DashboardWidget {
|
|||||||
oncreate(vnode: Mithril.VnodeDOM<IDashboardWidgetAttrs, this>): void;
|
oncreate(vnode: Mithril.VnodeDOM<IDashboardWidgetAttrs, this>): void;
|
||||||
loadLifetimeData(): Promise<void>;
|
loadLifetimeData(): Promise<void>;
|
||||||
loadTimedData(model: string): Promise<void>;
|
loadTimedData(model: string): Promise<void>;
|
||||||
|
loadCustomRangeData(model: string): Promise<void>;
|
||||||
className(): string;
|
className(): string;
|
||||||
content(): JSX.Element;
|
content(): JSX.Element;
|
||||||
drawChart(vnode: Mithril.VnodeDOM<any, any>): void;
|
drawChart(vnode: Mithril.VnodeDOM<any, any>): void;
|
||||||
|
39
extensions/statistics/js/dist-typings/components/StatisticsWidgetDateSelectionModal.d.ts
generated
vendored
Normal file
39
extensions/statistics/js/dist-typings/components/StatisticsWidgetDateSelectionModal.d.ts
generated
vendored
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
import ItemList from 'flarum/common/utils/ItemList';
|
||||||
|
import Modal, { IInternalModalAttrs } from 'flarum/common/components/Modal';
|
||||||
|
import Mithril from 'mithril';
|
||||||
|
export interface IDateSelection {
|
||||||
|
/**
|
||||||
|
* Timestamp (seconds, not ms) for start date
|
||||||
|
*/
|
||||||
|
start: number;
|
||||||
|
/**
|
||||||
|
* Timestamp (seconds, not ms) for end date
|
||||||
|
*/
|
||||||
|
end: number;
|
||||||
|
}
|
||||||
|
export interface IStatisticsWidgetDateSelectionModalAttrs extends IInternalModalAttrs {
|
||||||
|
onModalSubmit: (dates: IDateSelection) => void;
|
||||||
|
value?: IDateSelection;
|
||||||
|
}
|
||||||
|
interface IStatisticsWidgetDateSelectionModalState {
|
||||||
|
inputs: {
|
||||||
|
startDateVal: string;
|
||||||
|
endDateVal: string;
|
||||||
|
};
|
||||||
|
ids: {
|
||||||
|
startDate: string;
|
||||||
|
endDate: string;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
export default class StatisticsWidgetDateSelectionModal extends Modal<IStatisticsWidgetDateSelectionModalAttrs> {
|
||||||
|
state: IStatisticsWidgetDateSelectionModalState;
|
||||||
|
oninit(vnode: Mithril.Vnode<IStatisticsWidgetDateSelectionModalAttrs, this>): void;
|
||||||
|
className(): string;
|
||||||
|
title(): Mithril.Children;
|
||||||
|
content(): Mithril.Children;
|
||||||
|
items(): ItemList<Mithril.Children>;
|
||||||
|
updateState(field: keyof IStatisticsWidgetDateSelectionModalState['inputs']): (e: InputEvent) => void;
|
||||||
|
submitData(): IDateSelection;
|
||||||
|
onsubmit(e: SubmitEvent): void;
|
||||||
|
}
|
||||||
|
export {};
|
2
extensions/statistics/js/dist/admin.js
generated
vendored
2
extensions/statistics/js/dist/admin.js
generated
vendored
File diff suppressed because one or more lines are too long
2
extensions/statistics/js/dist/admin.js.map
generated
vendored
2
extensions/statistics/js/dist/admin.js.map
generated
vendored
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user