Title: SettingActivity: add 'note' field for inline informational text by bitcoin3us · Pull Request #155 · MicroPythonOS/MicroPythonOS · GitHub
Open Graph Title: SettingActivity: add 'note' field for inline informational text by bitcoin3us · Pull Request #155 · MicroPythonOS/MicroPythonOS
X Title: SettingActivity: add 'note' field for inline informational text by bitcoin3us · Pull Request #155 · MicroPythonOS/MicroPythonOS
Description: Summary Adds an optional `note` field to settings dicts. When present, `SettingActivity` renders it as a wrapping, muted-grey, 12 pt label between the input widget and the Cancel / Save row. ```python self.settings = [ {"title": "Wallet Type", "ui": "radiobuttons", "ui_options": [("On-chain (xpub or Bitcoin address)", "onchain")], "note": "Tip: an xpub is more private than reusing a single address. " "With an xpub, the wallet derives a fresh receive address per " "payment so the people paying you can't see your full balance " "or each other's amounts; with a single address, every payment " "shares the same on-chain record."}, ... ] ``` Optional — settings without a `note` field render exactly as before. Use case Lightning Piggy's on-chain wallet (in 0.5.0) is gaining a single-address mode as an alternative to xpub: see LightningPiggy/LightningPiggyApp#45. Picking the single-address shape works but trades away on-chain privacy. Surfacing that trade-off on the same page as the choice helps users make an informed call without burying it in docs. Generalising to a first-class `note` field rather than baking the wording into LP keeps the convention reusable — any setting elsewhere with a similar "why would I pick this" gotcha can opt in by adding a single dict key. Implementation Fifteen lines in `internal_filesystem/lib/mpos/ui/setting_activity.py`, right after the input-widget branches and before the Cancel/Save button container: Plain `lv.label` parented on the existing `settings_screen_detail`. `LONG_MODE.WRAP` so multi-line notes flow naturally to the screen width. `set_width(lv.pct(95))` to match the textarea / radio container width and stay clear of the scroll bar. `font_montserrat_12` + grey `0x999999` so it reads as supporting text without competing with the title above or the value below. `DisplayMetrics.pct_of_width(3)` top padding so it sits a comfortable distance below the input. Compatibility Apps: pure additive change. Existing settings dicts behave identically. Themes: uses `lv.color_hex(0x999999)` directly rather than a theme-aware token, matching the style of the existing slider value label (`font_montserrat_24`) and Cancel button opacity (`OPA._70`). If the project gains a theme-aware muted-text token in the future, this label is a one-line swap. Test plan Setting WITH `note` field renders the wrapped grey label below the input on the desktop build Setting WITHOUT `note` field is byte-identical to pre-PR layout Long notes wrap across multiple lines without overlapping the Cancel/Save buttons (the buttons sit in their own flex container below) On-device verification pending a firmware build (will follow up in this PR once tested on Waveshare ESP32-S3-Touch-LCD-2)
Open Graph Description: Summary Adds an optional `note` field to settings dicts. When present, `SettingActivity` renders it as a wrapping, muted-grey, 12 pt label between the input widget and the Cancel / Save row. ```pyt...
X Description: Summary Adds an optional `note` field to settings dicts. When present, `SettingActivity` renders it as a wrapping, muted-grey, 12 pt label between the input widget and the Cancel / Save row. ```pyt...
Opengraph URL: https://github.com/MicroPythonOS/MicroPythonOS/pull/155
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:c0544297-3822-eeb7-eb65-b570b38b1af5 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | DA3E:F7EDB:303898:419175:6A514196 |
| html-safe-nonce | 538bb4c34d1bf05a34cbf80aa6b5eaceffa6019673457e37f97933dd0eb49ef0 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEQTNFOkY3RURCOjMwMzg5ODo0MTkxNzU6NkE1MTQxOTYiLCJ2aXNpdG9yX2lkIjoiNTkwOTk0NDQwMzQ1NjI0NjE2NiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | bf25390d081f44bfea8a599af7b5f79222825967d59a08956526d166d2455be5 |
| hovercard-subject-tag | pull_request:3797939492 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/MicroPythonOS/MicroPythonOS/pull/155/files |
| twitter:image | https://avatars.githubusercontent.com/u/115934595?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/115934595?s=400&v=4 |
| og:image:alt | Summary Adds an optional `note` field to settings dicts. When present, `SettingActivity` renders it as a wrapping, muted-grey, 12 pt label between the input widget and the Cancel / Save row. ```pyt... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | e840f405b2718e8f2d55aafa9ff27dbce17e29d0c253011d05ea0fea3c78baff |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/MicroPythonOS/MicroPythonOS git https://github.com/MicroPythonOS/MicroPythonOS.git |
| octolytics-dimension-user_id | 213598128 |
| octolytics-dimension-user_login | MicroPythonOS |
| octolytics-dimension-repository_id | 975472483 |
| octolytics-dimension-repository_nwo | MicroPythonOS/MicroPythonOS |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 975472483 |
| octolytics-dimension-repository_network_root_nwo | MicroPythonOS/MicroPythonOS |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | e876f00c5723f6080b9d294e4958fd4d506e6faf |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width