@orderingstack/front-hooks 6.9.0 → 6.10.0-beta.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/index.cjs.js +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +1538 -1366
- package/dist/index.es.js.map +1 -1
- package/dist/types/index.d.ts +2 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/utils/menu.d.ts +20 -0
- package/dist/types/utils/menu.d.ts.map +1 -0
- package/package.json +2 -2
package/dist/types/index.d.ts
CHANGED
|
@@ -7,7 +7,8 @@ export * from './useOnClickOutside';
|
|
|
7
7
|
export * from './useChannelAvailability';
|
|
8
8
|
export * from './useMediaUrl';
|
|
9
9
|
export * from './utils';
|
|
10
|
-
export
|
|
10
|
+
export * from './utils/menu';
|
|
11
|
+
export { filterTimeAvailabilityOfProducts, isProductAvailable, filterTimeAvailabilityOfItems, } from './utils/timeAvailabilityFilter';
|
|
11
12
|
export { isChannelOpen } from './utils/timeAvailabilityFilter';
|
|
12
13
|
export * from './utils/cms';
|
|
13
14
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,UAAU,CAAC;AACzB,cAAc,qBAAqB,CAAC;AACpC,cAAc,0BAA0B,CAAC;AACzC,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC;AACxB,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,UAAU,CAAC;AACzB,cAAc,qBAAqB,CAAC;AACpC,cAAc,0BAA0B,CAAC;AACzC,cAAc,eAAe,CAAC;AAC9B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,OAAO,EACL,gCAAgC,EAChC,kBAAkB,EAClB,6BAA6B,GAC9B,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAC/D,cAAc,aAAa,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { IMenuLock, IProduct } from '@orderingstack/ordering-types';
|
|
2
|
+
|
|
3
|
+
export declare const MenuUtils: {
|
|
4
|
+
isLocked: (product: IProduct, locks: IMenuLock[]) => boolean;
|
|
5
|
+
isProduct: (product: IProduct) => boolean;
|
|
6
|
+
isOptionGroup: (product: IProduct) => boolean;
|
|
7
|
+
isVitalOptionGroup: (product: IProduct) => boolean;
|
|
8
|
+
findGroupBySelCtxInProductItems: (selCtx: string, items: IProduct[]) => IProduct | null;
|
|
9
|
+
findProductInProductItems: (id: string, menu: IProduct[]) => IProduct | null;
|
|
10
|
+
getMenuProductWithReplacedLockedProducts: (item: IProduct) => IProduct;
|
|
11
|
+
processLocks: (product: IProduct, locks: IMenuLock[], nestedLvl?: number, isMenuProduct?: boolean) => {
|
|
12
|
+
modified: boolean;
|
|
13
|
+
product: IProduct | null;
|
|
14
|
+
};
|
|
15
|
+
getMenuItemsWithProcessLocks: (items: IProduct[], locks?: IMenuLock[]) => IProduct[];
|
|
16
|
+
getMenuWithProperLiterals: (items: IProduct[], lang: string) => IProduct[];
|
|
17
|
+
getProductWithProperLiterals: (product: IProduct, lang: string) => IProduct;
|
|
18
|
+
extractLiteralsByLanguage: (product: IProduct, lang: string) => void;
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=menu.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"menu.d.ts","sourceRoot":"","sources":["../../../../../src/utils/menu.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,SAAS,EACT,QAAQ,EACT,MAAM,+BAA+B,CAAC;AAIvC,eAAO,MAAM,SAAS;wBACA,QAAQ,SAAS,SAAS,EAAE;yBAM3B,QAAQ;6BAGJ,QAAQ;kCAGH,QAAQ;8CAI5B,MAAM,SACP,QAAQ,EAAE,KAChB,QAAQ,GAAG,IAAI;oCAmBZ,MAAM,QACJ,QAAQ,EAAE,KACf,QAAQ,GAAG,IAAI;qDAe+B,QAAQ,KAAG,QAAQ;4BA6EzD,QAAQ,SACV,SAAS,EAAE,sCAEF,OAAO,KACtB;QAAE,QAAQ,EAAE,OAAO,CAAC;QAAC,OAAO,EAAE,QAAQ,GAAG,IAAI,CAAA;KAAE;0CA+CzC,QAAQ,EAAE,UACT,SAAS,EAAE,KAClB,QAAQ,EAAE;uCAasB,QAAQ,EAAE,QAAQ,MAAM,KAAG,QAAQ,EAAE;4CAOhC,QAAQ,QAAQ,MAAM,KAAG,QAAQ;yCAMpC,QAAQ,QAAQ,MAAM;CAwC5D,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@orderingstack/front-hooks",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.10.0-beta.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"packageManager": "pnpm@9.12.2",
|
|
6
6
|
"main": "dist/index.cjs.js",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@orderingstack/ordering-core-react": "^3.3.2",
|
|
33
|
-
"@orderingstack/ordering-types": "^1.
|
|
33
|
+
"@orderingstack/ordering-types": "^1.39.0",
|
|
34
34
|
"@testing-library/react-hooks": "^8.0.1",
|
|
35
35
|
"@types/node": "^20.12.7",
|
|
36
36
|
"@types/react": "^17.0.38",
|