Skip to content

Commit f1c075c

Browse files
iampopovichaguspe
andauthored
[rb] Add macOS key mappings for Options and Function keys (#15959)
* Add macOS key mappings for Options and Function keys * Fix macOS key mapping for Options key to match correct value * Add numpad key mappings to Selenium WebDriver Keys according to the standard https://w3c.github.io/webdriver/#keyboard-actions --------- Co-authored-by: Augustin Gottlieb <[email protected]>
1 parent c4bf5eb commit f1c075c

File tree

1 file changed

+9
-0
lines changed
  • rb/lib/selenium/webdriver/common

1 file changed

+9
-0
lines changed

rb/lib/selenium/webdriver/common/keys.rb

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,13 @@ module Keys
7575
subtract: "\ue027",
7676
decimal: "\ue028",
7777
divide: "\ue029",
78+
numpad_multiply: "\ue024",
79+
numpad_add: "\ue025",
80+
numpad_comma: "\ue026",
81+
numpad_subtract: "\ue027",
82+
numpad_decimal: "\ue028",
83+
numpad_divide: "\ue029",
84+
numpad_enter: "\ue007",
7885
f1: "\ue031",
7986
f2: "\ue032",
8087
f3: "\ue033",
@@ -95,6 +102,8 @@ module Keys
95102
right_control: "\ue051",
96103
right_alt: "\ue052",
97104
right_meta: "\ue053",
105+
options: "\ue052",
106+
function: "\ue051", # macOS Function key, same as right_control
98107
numpad_page_up: "\ue054",
99108
numpad_page_down: "\ue055",
100109
numpad_end: "\ue056",

0 commit comments

Comments
 (0)