sprof 0.9.7 → 0.9.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,7 +6,6 @@ import { default as DropList } from './DropList.vue';
6
6
  import { default as FilterCheckbox } from './FilterCheckbox.vue';
7
7
  import { default as FiltersButtonsSelect } from './FiltersButtonsSelect.vue';
8
8
  import { default as FilterSelect } from './FilterSelect.vue';
9
- import { default as FTSPPanel } from './FTSPPanel.vue';
10
9
  import { default as GeneralItem } from './GeneralItem.vue';
11
10
  import { default as GridContainer } from './GridContainer.vue';
12
11
  import { default as InfoItem } from './InfoItem.vue';
@@ -30,4 +29,4 @@ import { default as TopSliderContainer } from './TopSliderContainer.vue';
30
29
  export default function install(app: {
31
30
  component: (a: string, b: unknown) => void;
32
31
  }): void;
33
- export { AdaptiveContainer, AdaptiveContainerHorizontal, CarouselImages, ContextWindow, DropList, FilterCheckbox, FiltersButtonsSelect, FilterSelect, FTSPPanel, GeneralItem, GridContainer, InfoItem, InfoItemSelectButtons, LeftRightContainer, PageNotFound, PAutocomplete, PhoneForm, PPagination, RemoteSearch, ResearcheContainer, RightSliderContainer, RightTabsContainer, SelectValueType, SortList, SortSelect, Switch3Pos, ThemeWrapper, ToggleInfoItem, TopSliderContainer, };
32
+ export { AdaptiveContainer, AdaptiveContainerHorizontal, CarouselImages, ContextWindow, DropList, FilterCheckbox, FiltersButtonsSelect, FilterSelect, GeneralItem, GridContainer, InfoItem, InfoItemSelectButtons, LeftRightContainer, PageNotFound, PAutocomplete, PhoneForm, PPagination, RemoteSearch, ResearcheContainer, RightSliderContainer, RightTabsContainer, SelectValueType, SortList, SortSelect, Switch3Pos, ThemeWrapper, ToggleInfoItem, TopSliderContainer, };
@@ -1,5 +1,4 @@
1
1
  import { ComputedRef } from 'vue';
2
- import { default as FilterModelV2 } from '../ftsp/f/FilterModelV2';
3
2
  import { default as FilterModel } from '../ftsp/FilterModel';
4
3
  import { default as FTSP } from '../ftsp/FTSP';
5
4
  export interface UseFiltersReturn {
@@ -9,8 +8,6 @@ export interface UseFiltersReturn {
9
8
  count: ComputedRef<number>;
10
9
  /** Добавить фильтр (ftsp.setF) */
11
10
  add(model: FilterModel): void;
12
- /** Добавить фильтр v2 (ftsp.setF2) */
13
- addV2(model: FilterModelV2): void;
14
11
  /** Заменить фильтр: убрать prev, добавить cur (ftsp.replaceF) */
15
12
  replace(current?: FilterModel, previous?: FilterModel): void;
16
13
  /** Удалить фильтр по eq (ftsp.removeF) */
@@ -33,8 +33,9 @@ export interface UsePaginationReturn {
33
33
  /**
34
34
  * Композабл пагинации (бэклог 0.4.0): удобная обёртка над FTSP.p.
35
35
  *
36
- * Важно: у FTSP.p.page — это СМЕЩЕНИЕ (offset), а page из композабла —
37
- * 1-based номер страницы (как в UI). Смена rowsPerPage сбрасывает на 1-ю.
36
+ * Важно: `ftsp.p.offset` — СМЕЩЕНИЕ (0, rowsPerPage, 2*rowsPerPage…),
37
+ * а `page` из композабла — 1-based номер страницы (как в UI).
38
+ * Смена rowsPerPage сбрасывает на 1-ю.
38
39
  *
39
40
  * ```ts
40
41
  * const { page, rowsPerPage, next, prev, reset } = usePagination();
@@ -1,4 +1,3 @@
1
- import { default as FilterModelV2 } from './f/FilterModelV2';
2
1
  import { default as FilterModel } from './FilterModel';
3
2
  import { default as Pagination } from './Pagination';
4
3
  import { default as SortModel } from './SortModel';
@@ -7,7 +6,6 @@ export default class FTSP {
7
6
  private static instance;
8
7
  id?: string;
9
8
  f: FilterModel[];
10
- f2: FilterModelV2[];
11
9
  s: SortModel[];
12
10
  p: Pagination;
13
11
  t: TreeModel;
@@ -29,7 +27,6 @@ export default class FTSP {
29
27
  setSortModel(sortModel?: SortModel): void;
30
28
  setS(sortModel: SortModel): void;
31
29
  setF(model: FilterModel): void;
32
- setF2(model: FilterModelV2): void;
33
30
  replaceF(curF?: FilterModel, prevF?: FilterModel): void;
34
31
  removeF(model?: FilterModel): void;
35
32
  reset(): void;
@@ -1,6 +1,14 @@
1
1
  import { default as Cursor } from './Cursor';
2
2
  export default class Pagination {
3
- page: number;
3
+ /**
4
+ * Смещение от начала списка (НЕ номер страницы!).
5
+ *
6
+ * ⚠️ До 0.9.8 поле называлось `page`, и это регулярно путало: `page = 25`
7
+ * выглядит как «страница 25», а означает вторую страницу (offset 25).
8
+ * Номер страницы (1-based) даёт композабл `usePagination` — не считайте его
9
+ * здесь вручную.
10
+ */
11
+ offset: number;
4
12
  rowsPerPage: number;
5
13
  rowsNumber: number;
6
14
  cursor: Cursor;
@@ -1,10 +1,8 @@
1
- import { default as FilterModelV2 } from './f/FilterModelV2';
2
1
  import { default as FilterModel } from './FilterModel';
3
2
  import { default as FTSP } from './FTSP';
4
3
  import { default as SortModel } from './SortModel';
5
4
  export default abstract class F {
6
5
  static SortModel: typeof SortModel;
7
6
  static FilterModel: typeof FilterModel;
8
- static FilterModelV2: typeof FilterModelV2;
9
7
  static FTSP: typeof FTSP;
10
8
  }
@@ -89,7 +89,7 @@ declare class S {
89
89
  label: string;
90
90
  }[];
91
91
  pagination: {
92
- page: number;
92
+ offset: number;
93
93
  rowsPerPage: number;
94
94
  rowsNumber: number;
95
95
  cursor: {
@@ -40,7 +40,6 @@ declare module 'vue' {
40
40
  CarouselImages: typeof Components.CarouselImages;
41
41
  ContextWindow: typeof Components.ContextWindow;
42
42
  DropList: typeof Components.DropList;
43
- FTSPPanel: typeof Components.FTSPPanel;
44
43
  FilterCheckbox: typeof Components.FilterCheckbox;
45
44
  FilterSelect: typeof Components.FilterSelect;
46
45
  FiltersButtonsSelect: typeof Components.FiltersButtonsSelect;