shared-ritm 1.1.13 → 1.1.15

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.
@@ -21,7 +21,8 @@ import useAuthService from '@/api/services/AuthService';
21
21
  import ApiService from '@/api/settings/ApiService';
22
22
  export { AppButton, AppCheckbox, AppDatePicker, AppInput, AppInputSearch, AppLayout, AppLayoutHeader, AppLoader, AppSelect, AppSheet, AppSidebar, AppToggle, AppWrapper, };
23
23
  export { ApiService, useAuthService, useGanttService, useMetricsService, useProjectsService, useRepairsService, useTasksService, };
24
- export { default as notification } from './utils/notification';
24
+ export type { NotificationType } from './utils/notification';
25
+ export { notificationSettings } from './utils/notification';
25
26
  export * from './api/types/Api_Tasks';
26
27
  export * from './api/types/Api_Repairs';
27
28
  export * from './api/types/Api_Projects';
@@ -1,2 +1,6 @@
1
1
  export type NotificationType = 'danger' | 'success' | 'warning' | 'info' | 'default';
2
- export default function notification(type: NotificationType, message: string): void;
2
+ export declare const notificationSettings: (type: NotificationType, message: string) => {
3
+ message: string;
4
+ color: string;
5
+ position: string;
6
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shared-ritm",
3
- "version": "1.1.13",
3
+ "version": "1.1.15",
4
4
  "private": false,
5
5
  "files": [
6
6
  "dist",
package/src/index.ts CHANGED
@@ -47,7 +47,8 @@ export {
47
47
  useTasksService,
48
48
  }
49
49
 
50
- export { default as notification } from './utils/notification'
50
+ export type { NotificationType } from './utils/notification'
51
+ export { notificationSettings } from './utils/notification'
51
52
 
52
53
  export * from './api/types/Api_Tasks'
53
54
  export * from './api/types/Api_Repairs'
@@ -1,13 +1,12 @@
1
- import { useQuasar } from 'quasar'
2
-
3
- const $q = useQuasar()
4
-
5
1
  export type NotificationType = 'danger' | 'success' | 'warning' | 'info' | 'default'
6
2
 
7
- export default function notification(type: NotificationType, message: string): void {
8
- $q.notify({
3
+ export const notificationSettings = (
4
+ type: NotificationType,
5
+ message: string,
6
+ ): { message: string; color: string; position: string } => {
7
+ return {
9
8
  message,
10
9
  color: type === 'danger' ? 'red' : type === 'success' ? 'green' : type === 'warning' ? 'orange' : 'white',
11
10
  position: 'top-right',
12
- })
11
+ }
13
12
  }