This commit resolves the issue with the `:active` pseudo-class not
activating in mobile Safari on iOS devices. It introduces a workaround
specifically for mobile Safari on iOS/iPadOS to enable the `:active`
pseudo-class. This ensures a consistent and responsive user interface
in response to touch states on mobile Safari.
Other supporting changes:
- Introduce new test utility functions such as `createWindowEventSpies`
and `formatAssertionMessage` to improve code reusability and
maintainability.
- Improve browser detection:
- Add detection for iPadOS and Windows 10 Mobile.
- Add touch support detection to correctly determine iPadOS vs macOS.
- Fix misidentification of some Windows 10 Mobile platforms as Windows
Phone.
- Improve test coverage and refactor tests.
38 lines
797 B
TypeScript
38 lines
797 B
TypeScript
export enum OperatingSystem {
|
|
macOS,
|
|
Windows,
|
|
Linux,
|
|
KaiOS,
|
|
ChromeOS,
|
|
Android,
|
|
iOS,
|
|
iPadOS,
|
|
|
|
/**
|
|
* Legacy: Released in 1999, discontinued in 2013, succeeded by BlackBerry10.
|
|
*/
|
|
BlackBerryOS,
|
|
|
|
/**
|
|
* Legacy: Released in 2013, discontinued in 2015, succeeded by {@link OperatingSystem.Android}.
|
|
*/
|
|
BlackBerry10,
|
|
|
|
/**
|
|
* Legacy: Released in 2010, discontinued in 2017,
|
|
* succeeded by {@link OperatingSystem.Windows10Mobile}.
|
|
*/
|
|
WindowsPhone,
|
|
|
|
/**
|
|
* Legacy: Released in 2015, discontinued in 2017, succeeded by {@link OperatingSystem.Android}.
|
|
*/
|
|
Windows10Mobile,
|
|
|
|
/**
|
|
* Also known as "BlackBerry PlayBook OS"
|
|
* Legacy: Released in 2011, discontinued in 2014, succeeded by {@link OperatingSystem.Android}.
|
|
*/
|
|
BlackBerryTabletOS,
|
|
}
|