@ibiliaze/global-vars 1.124.0 → 1.125.0
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.
- package/dist/flows.d.ts +2 -2
- package/dist/flows.js +4 -4
- package/package.json +2 -2
package/dist/flows.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ export declare const flows: readonly ["Online", "Offline", "Special link", "Seas
|
|
|
3
3
|
export declare const idsEqual: <Id>(a: Id | null | undefined, b: Id | null | undefined) => boolean;
|
|
4
4
|
export declare const arrayHasId: <Id>(list: readonly (Id | null | undefined)[] | null | undefined, target: Id | null | undefined) => boolean;
|
|
5
5
|
export declare function makeSaleLogic<Id, TDate>(): SaleLogic<Id, TDate>;
|
|
6
|
-
export type
|
|
6
|
+
export type Channel = '' | 'link' | 'pos' | 'seasonal';
|
|
7
7
|
export type Who = 'guest' | 'root' | 'cashier';
|
|
8
8
|
export type SeatsByCat<Id> = {
|
|
9
9
|
categoryName: string;
|
|
@@ -58,7 +58,7 @@ export interface GetCategoryArgs<Id, TDate> {
|
|
|
58
58
|
sectionCategory: FixtureCategoryOf<Id> | undefined;
|
|
59
59
|
}
|
|
60
60
|
export interface SaleLogic<Id, TDate> {
|
|
61
|
-
whereAmI(
|
|
61
|
+
whereAmI(channel: Channel): WhereOf<Id, TDate>;
|
|
62
62
|
canISeeSection(args: CanISeeSectionArgs<Id, TDate>): boolean;
|
|
63
63
|
canISeeSeat(args: CanISeeSeatArgs<Id, TDate>): boolean;
|
|
64
64
|
getSectorCategory(args: GetSectorCategoryArgs<Id>): FixtureCategoryOf<Id> | undefined;
|
package/dist/flows.js
CHANGED
|
@@ -19,13 +19,13 @@ function makeSaleLogic() {
|
|
|
19
19
|
function whereAmI(path) {
|
|
20
20
|
try {
|
|
21
21
|
switch (path) {
|
|
22
|
-
case '
|
|
22
|
+
case '':
|
|
23
23
|
return 'Online';
|
|
24
|
-
case '
|
|
24
|
+
case 'link':
|
|
25
25
|
return 'Special link';
|
|
26
|
-
case '
|
|
26
|
+
case 'pos':
|
|
27
27
|
return 'Offline';
|
|
28
|
-
case '
|
|
28
|
+
case 'seasonal':
|
|
29
29
|
return 'Seasonal ticket';
|
|
30
30
|
default:
|
|
31
31
|
return 'Online';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ibiliaze/global-vars",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.125.0",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"scripts": {
|
|
23
23
|
"build": "tsc",
|
|
24
24
|
"pub": "npm publish --access public",
|
|
25
|
-
"git": "git add .; git commit -m 'changes'; git tag -a v1.
|
|
25
|
+
"git": "git add .; git commit -m 'changes'; git tag -a v1.125.0 -m 'v1.125.0'; git push origin v1.125.0; git push",
|
|
26
26
|
"push": "npm run build; npm run git; npm run pub"
|
|
27
27
|
},
|
|
28
28
|
"author": "Ibi Hasanli",
|