@tager/admin-blog 1.0.3 → 1.0.4

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.
Files changed (39) hide show
  1. package/dist/dev/App.vue.d.ts +4 -3
  2. package/dist/hooks/useFetchCategories.d.ts +2 -2
  3. package/dist/hooks/useFetchCategory.d.ts +3 -3
  4. package/dist/hooks/useFetchModuleConfig.d.ts +2 -2
  5. package/dist/hooks/useFetchPosts.d.ts +2 -2
  6. package/dist/index.mjs +1402 -1637
  7. package/dist/services/requests.d.ts +4 -4
  8. package/dist/style.css +1 -1
  9. package/dist/typings/common.d.ts +1 -1
  10. package/dist/typings/model.d.ts +3 -3
  11. package/dist/views/Categories/CategoryForm/CategoryForm.helpers.d.ts +4 -4
  12. package/dist/views/Categories/CategoryForm/CategoryForm.vue.d.ts +5 -4
  13. package/dist/views/Categories/CategoryList/CategoryList.helpers.d.ts +4 -4
  14. package/dist/views/Categories/CategoryList/CategoryList.vue.d.ts +5 -4
  15. package/dist/views/Categories/CategoryList/hooks/useAdvancedSearch.d.ts +5 -5
  16. package/dist/views/Posts/PostForm/PostForm.helpers.d.ts +6 -6
  17. package/dist/views/Posts/PostForm/PostForm.vue.d.ts +1853 -372
  18. package/dist/views/Posts/PostList/PostList.helpers.d.ts +4 -4
  19. package/dist/views/Posts/PostList/PostList.vue.d.ts +6 -5
  20. package/dist/views/Posts/PostList/hooks/useAdvancedSearch.d.ts +5 -5
  21. package/package.json +20 -24
  22. package/src/dev/App.vue +1 -1
  23. package/src/dev/env.ts +11 -11
  24. package/src/hooks/useFetchCategories.ts +2 -2
  25. package/src/hooks/useFetchCategory.ts +3 -3
  26. package/src/hooks/useFetchModuleConfig.ts +2 -2
  27. package/src/hooks/useFetchPosts.ts +2 -2
  28. package/src/services/requests.ts +7 -7
  29. package/src/typings/model.ts +7 -7
  30. package/src/views/Categories/CategoryForm/CategoryForm.helpers.ts +6 -6
  31. package/src/views/Categories/CategoryForm/CategoryForm.vue +7 -7
  32. package/src/views/Categories/CategoryList/CategoryList.helpers.ts +4 -4
  33. package/src/views/Categories/CategoryList/CategoryList.vue +1 -1
  34. package/src/views/Categories/CategoryList/hooks/useAdvancedSearch.ts +6 -6
  35. package/src/views/Posts/PostForm/PostForm.helpers.ts +8 -8
  36. package/src/views/Posts/PostForm/PostForm.vue +12 -12
  37. package/src/views/Posts/PostList/PostList.helpers.ts +7 -7
  38. package/src/views/Posts/PostList/PostList.vue +7 -7
  39. package/src/views/Posts/PostList/hooks/useAdvancedSearch.ts +6 -6
@@ -1,6 +1,6 @@
1
- import { Nullable, ResponseBody } from '@tager/admin-services';
2
- import { FieldShortType, OutgoingValueUnion } from '@tager/admin-dynamic-field';
3
- import { Category, ModuleConfig, PostShort, PostFull, CategoryPayload } from '../typings/model';
1
+ import { type Nullable, type ResponseBody } from '@tager/admin-services';
2
+ import { type FieldShortType, type OutgoingValueUnion } from '@tager/admin-dynamic-field';
3
+ import { type Category, type ModuleConfig, type PostShort, type PostFull, type CategoryPayload } from '../typings/model';
4
4
  /** Blog Posts */
5
5
  export declare function getPosts(params?: {
6
6
  query?: string;
@@ -35,7 +35,7 @@ export interface PostCreationPayload {
35
35
  publishAt: Nullable<string>;
36
36
  }
37
37
  export declare function createBlogPost(payload: PostCreationPayload): Promise<ResponseBody<PostFull>>;
38
- export declare type PostUpdatePayload = PostCreationPayload & {
38
+ export type PostUpdatePayload = PostCreationPayload & {
39
39
  urlAlias: string;
40
40
  };
41
41
  export declare function updateBlogPost(postId: number | string, payload: PostUpdatePayload): Promise<ResponseBody<PostFull>>;
package/dist/style.css CHANGED
@@ -1 +1 @@
1
- .filters[data-v-02162423]{margin-bottom:1rem;width:100%;display:grid;gap:1rem;grid-template-columns:1fr 1fr}.filters[data-v-02162423]:not(:first-child){margin-top:1rem}.status span[data-v-02162423]{display:block}.status span[data-v-02162423]:nth-child(2){display:block;margin-top:5px;font-size:.8rem}.status span:nth-child(2) i[data-v-02162423]{display:block}.status[data-v-15dc5eec]{display:flex;align-items:flex-end}.status-value[data-v-15dc5eec]{flex-basis:50%}.status-checkbox[data-v-15dc5eec]{margin-left:20px;padding-bottom:8px}.status-date[data-v-15dc5eec]{margin-left:20px;flex:1 1 1px}
1
+ .filters[data-v-7b6e97da]{margin-bottom:1rem;width:100%;display:grid;gap:1rem;grid-template-columns:1fr 1fr}.filters[data-v-7b6e97da]:not(:first-child){margin-top:1rem}.status span[data-v-7b6e97da]{display:block}.status span[data-v-7b6e97da]:nth-child(2){display:block;margin-top:5px;font-size:.8rem}.status span:nth-child(2) i[data-v-7b6e97da]{display:block}.status[data-v-be9f92cf]{display:flex;align-items:flex-end}.status-value[data-v-be9f92cf]{flex-basis:50%}.status-checkbox[data-v-be9f92cf]{margin-left:20px;padding-bottom:8px}.status-date[data-v-be9f92cf]{margin-left:20px;flex:1 1 1px}
@@ -1 +1 @@
1
- export declare type Values<T> = T[keyof T];
1
+ export type Values<T> = T[keyof T];
@@ -1,6 +1,6 @@
1
- import { Nullable, FileType } from '@tager/admin-services';
2
- import { FieldConfigUnion, FieldShortType, IncomingValueUnion } from '@tager/admin-dynamic-field';
3
- import { OptionType, ShortCodeItemType, SingleFileInputValueType } from '@tager/admin-ui';
1
+ import { type Nullable, type FileType } from '@tager/admin-services';
2
+ import { type FieldConfigUnion, type FieldShortType, type IncomingValueUnion } from '@tager/admin-dynamic-field';
3
+ import { type OptionType, type ShortCodeItemType, type SingleFileInputValueType } from '@tager/admin-ui';
4
4
  export interface SeoInfo {
5
5
  readonly pageTitle: Nullable<string>;
6
6
  readonly pageDescription: Nullable<string>;
@@ -1,7 +1,7 @@
1
- import { TFunction } from 'i18next';
2
- import { Nullable } from '@tager/admin-services';
3
- import { OptionType } from '@tager/admin-ui';
4
- import { Category, CategoryFormValues, CategoryPayload } from '../../../typings/model';
1
+ import { type TFunction } from 'i18next';
2
+ import { type Nullable } from '@tager/admin-services';
3
+ import { type OptionType } from '@tager/admin-ui';
4
+ import { type Category, type CategoryFormValues, type CategoryPayload } from '../../../typings/model';
5
5
  export declare function convertCategoryToFormValues(category: Nullable<Category>, languageOptionList: OptionType[], t: TFunction): CategoryFormValues;
6
6
  export declare function convertCategoryFormValuesToPayload(values: CategoryFormValues): CategoryPayload;
7
7
  export declare function convertCategoryListToOptions(categoryList: Category[], languageId: Nullable<string>, t: TFunction): OptionType<Nullable<number>>[];
@@ -1,6 +1,8 @@
1
- import { Nullable } from '@tager/admin-services';
2
- import { OptionType, TagerFormSubmitEvent, SeoChangeEvent, TabType } from '@tager/admin-ui';
3
- declare const _default: import("vue").DefineComponent<{}, {
1
+ import { type Nullable } from '@tager/admin-services';
2
+ import { type OptionType, type TagerFormSubmitEvent, type SeoChangeEvent, type TabType } from '@tager/admin-ui';
3
+ declare const _default: typeof __VLS_export;
4
+ export default _default;
5
+ declare const __VLS_export: import("vue").DefineComponent<{}, {
4
6
  isCreation: import("vue").ComputedRef<boolean>;
5
7
  isContentLoading: import("vue").ComputedRef<boolean>;
6
8
  values: import("vue").Ref<{
@@ -50,4 +52,3 @@ declare const _default: import("vue").DefineComponent<{}, {
50
52
  tabList: import("vue").ComputedRef<TabType[]>;
51
53
  selectedTabId: import("vue").Ref<string>;
52
54
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
53
- export default _default;
@@ -1,7 +1,7 @@
1
- import { TFunction } from 'i18next';
2
- import { Nullable } from '@tager/admin-services';
3
- import { ColumnDefinition } from '@tager/admin-ui';
4
- import { Category, Language, ModuleConfig } from '../../../typings/model';
1
+ import { type TFunction } from 'i18next';
2
+ import { type Nullable } from '@tager/admin-services';
3
+ import { type ColumnDefinition } from '@tager/admin-ui';
4
+ import { type Category, type Language, type ModuleConfig } from '../../../typings/model';
5
5
  export declare function convertCategoryList(categoryList: Category[], languages: Language[]): Category[];
6
6
  export declare function getCategoryTableColumnDefs(moduleConfig: Nullable<ModuleConfig>, t: TFunction): ColumnDefinition<Category>[];
7
7
  export declare function getLinkToPostsByCategory(categoryId: number): string;
@@ -1,7 +1,9 @@
1
1
  import { getBlogCategoryFormUrl } from '../../../utils/paths';
2
- import { Category } from '../../../typings/model';
2
+ import { type Category } from '../../../typings/model';
3
3
  import { getLinkToPostsByCategory } from './CategoryList.helpers';
4
- declare const _default: import("vue").DefineComponent<{}, {
4
+ declare const _default: typeof __VLS_export;
5
+ export default _default;
6
+ declare const __VLS_export: import("vue").DefineComponent<{}, {
5
7
  columnDefs: import("vue").ComputedRef<import("@tager/admin-ui").ColumnDefinition<Category>[]>;
6
8
  rowData: import("vue").ComputedRef<Category[]>;
7
9
  isRowDataLoading: import("vue").ComputedRef<boolean>;
@@ -11,7 +13,7 @@ declare const _default: import("vue").DefineComponent<{}, {
11
13
  isDeleting: (entityId: string | number) => boolean;
12
14
  getBlogCategoryFormUrl: typeof getBlogCategoryFormUrl;
13
15
  getLinkToPostsByCategory: typeof getLinkToPostsByCategory;
14
- startMoveCategory: (categoryId: number, direction: 'up' | 'down') => void;
16
+ startMoveCategory: (categoryId: number, direction: "up" | "down") => void;
15
17
  isCategoryMoving: import("vue").Ref<boolean>;
16
18
  searchQuery: import("vue").Ref<string>;
17
19
  handleChange: (event: import("@tager/admin-ui/dist/components/DataTable/DataTable.types").TableChangeEvent) => void;
@@ -23,4 +25,3 @@ declare const _default: import("vue").DefineComponent<{}, {
23
25
  tags: import("vue").ComputedRef<import("@tager/admin-ui").FilterTagType[]>;
24
26
  tagRemovalHandler: (event: import("@tager/admin-ui").FilterTagType) => void;
25
27
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
26
- export default _default;
@@ -1,8 +1,8 @@
1
- import { ComputedRef, Ref } from 'vue';
2
- import { RouteLocationNormalizedLoaded } from 'vue-router';
3
- import { TFunction } from 'i18next';
4
- import { FilterTagType, OptionType } from '@tager/admin-ui';
5
- import { Language } from '../../../../typings/model';
1
+ import { type ComputedRef, type Ref } from 'vue';
2
+ import { type RouteLocationNormalizedLoaded } from 'vue-router';
3
+ import { type TFunction } from 'i18next';
4
+ import { type FilterTagType, type OptionType } from '@tager/admin-ui';
5
+ import { type Language } from '../../../../typings/model';
6
6
  interface Params {
7
7
  t: TFunction;
8
8
  languageList: ComputedRef<Language[]>;
@@ -1,9 +1,9 @@
1
- import { TFunction } from 'i18next';
2
- import { Nullable } from '@tager/admin-services';
3
- import { OptionType, SingleFileInputValueType } from '@tager/admin-ui';
4
- import { FieldConfigUnion, FieldUnion } from '@tager/admin-dynamic-field';
5
- import { PostCreationPayload, PostUpdatePayload } from '../../../services/requests';
6
- import { Category, PostFull } from '../../../typings/model';
1
+ import { type TFunction } from 'i18next';
2
+ import { type Nullable } from '@tager/admin-services';
3
+ import { type OptionType, type SingleFileInputValueType } from '@tager/admin-ui';
4
+ import { type FieldConfigUnion, type FieldUnion } from '@tager/admin-dynamic-field';
5
+ import { type PostCreationPayload, type PostUpdatePayload } from '../../../services/requests';
6
+ import { type Category, type PostFull } from '../../../typings/model';
7
7
  export declare const getStatusOptions: (t: TFunction) => OptionType[];
8
8
  export interface FormValues {
9
9
  title: string;