This commit is contained in:
2025-03-26 08:53:40 -05:00
parent 10c83ac965
commit 407916e30c
3 changed files with 120 additions and 111 deletions

View File

@@ -20,6 +20,14 @@ def display_keypad(icons_array: np.ndarray, props_per_key: int) -> str:
icons += "\n"
return icons
def display_md_keypad(icons_array: np.ndarray, props_per_key: int) -> str:
icons = ""
for idx, row in enumerate(icons_array.reshape(-1, props_per_key)):
icons += f"Key {idx}: "
icons += str(row)
icons += "<br/>"
return icons
if __name__ == "__main__":
api = NKodeAPI()
@@ -100,6 +108,7 @@ if __name__ == "__main__":
"mask": mask,
"selected_keys": selected_keys_login,
"login_keypad": display_keypad(login_keypad, keypad_size.props_per_key),
"login_keypad_md": display_md_keypad(login_keypad, keypad_size.props_per_key),
"ordered_keys": login_keypad.reshape(-1, keypad_size.props_per_key)[selected_keys_login],
"old_props": old_props,
"new_props": new_props,