Repository navigation
Conversation
…high zoom When the viewport is narrower than 300 px (browser zoom > ~330 %), clock pickers are replaced by numeric inputs and the mode-toggle button is hidden. The AM/PM SegmentedButton is displayed correctly in the inputs view by giving the TimeSelectionInputs host a definite width so that flex-basis:100% on the AM/PM cell resolves and wraps to its own row instead of overflowing the popup.
👋 Heads-up: dev close is in effectThanks for the contribution! This repository is currently in dev close ahead of release This PR appears to introduce public-API changes (detected by diffing the Custom Elements Manifest against the latest published version on npm):
Could you please hold off on merging into If this change must ship in the current release, please request a review from one or two members of @UI5/ui5-team-webc so the team can sign off explicitly.
Posted automatically by the Dev Close Notice workflow. |
|
🚀 Deployed on https://pr-14282--ui5-webcomponents-preview.netlify.app |
| } | ||
|
|
||
| _handleResize() { | ||
| this._highZoom = document.body.offsetWidth < HIGH_ZOOM_BREAKPOINT; |
There was a problem hiding this comment.
This is duplicated logic so I would suggest to extract a util in base package (packages/base/src/util/HighZoomUtil.ts) whiich will be reused
| _dateTimeSwitchChange(e: CustomEvent<SegmentedButtonSelectionChangeEventDetail>) { // Note: fix when SegmentedButton is implemented in TS | ||
| const selectedItem = e.detail.selectedItems[0]; | ||
| this._showTimeView = selectedItem.getAttribute("data-ui5-key") === "Time"; | ||
| this._useTimeInputs = false; |
There was a problem hiding this comment.
I dont think that here we should reset _useTimeInputs, it should be reset when the popover is closed or date & time is selected
| id={`${this._id}-mode-toggle`} | ||
| slot="endContent" | ||
| design="Transparent" | ||
| icon={this._effectiveUseInputs ? timeEntryRequest : keyboardAndMouse} |
There was a problem hiding this comment.
should be _useInputs instead of _effectiveUseInputs
| }); | ||
| }); | ||
|
|
||
| describe("TimePicker at high zoom (viewport < 300 px)", () => { |
There was a problem hiding this comment.
High zoom on desktop (no ui5SimulateDevice) — the actual target scenario is missing
When the viewport is narrower than 300 px, clock pickers are replaced by numeric inputs and the mode-toggle button is hidden