umaki 0.9.1 → 0.9.2
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/libs/control/bg-scroll-stop.test.d.ts +1 -0
- package/dist/libs/control/video-play-control.cjs.js +1 -1
- package/dist/libs/control/video-play-control.es.js +1 -1
- package/dist/libs/get/get-event-paths.test.d.ts +1 -0
- package/dist/libs/is/is-ipad.cjs.js +1 -1
- package/dist/libs/is/is-ipad.d.ts +3 -1
- package/dist/libs/is/is-ipad.es.js +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -5,6 +5,6 @@ const getUaData = require("../get/get-ua-data.cjs.js");
|
|
|
5
5
|
const isIpad = (orientation = "portrait") => {
|
|
6
6
|
const clientData = getUaData.getUaData();
|
|
7
7
|
if (!clientData.touchSupport) return false;
|
|
8
|
-
return clientData.type === "laptop" && clientData.osName === "mac-os" && clientData.browserName === "safari" &&
|
|
8
|
+
return clientData.type === "laptop" && clientData.osName === "mac-os" && clientData.browserName === "safari" && getOrientation.getOrientation() === orientation;
|
|
9
9
|
};
|
|
10
10
|
exports.isIpad = isIpad;
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
type Orientation = 'portrait' | 'landscape';
|
|
1
2
|
/**
|
|
2
3
|
* Determines if the device is an iPad.
|
|
3
4
|
*
|
|
4
5
|
* @param orientation - The desired screen orientation ('portrait' or 'landscape'). Defaults to 'portrait'.
|
|
5
6
|
* @returns `true` if the device is an iPad with the specified orientation, otherwise `false`.
|
|
6
7
|
*/
|
|
7
|
-
export declare const isIpad: (orientation?:
|
|
8
|
+
export declare const isIpad: (orientation?: Orientation) => boolean;
|
|
9
|
+
export {};
|
|
@@ -3,7 +3,7 @@ import { getUaData } from "../get/get-ua-data.es.js";
|
|
|
3
3
|
const isIpad = (orientation = "portrait") => {
|
|
4
4
|
const clientData = getUaData();
|
|
5
5
|
if (!clientData.touchSupport) return false;
|
|
6
|
-
return clientData.type === "laptop" && clientData.osName === "mac-os" && clientData.browserName === "safari" &&
|
|
6
|
+
return clientData.type === "laptop" && clientData.osName === "mac-os" && clientData.browserName === "safari" && getOrientation() === orientation;
|
|
7
7
|
};
|
|
8
8
|
export {
|
|
9
9
|
isIpad
|