fix: Remove d2l-offscreen-sizeless flag - #7247
Conversation
|
Thanks for the PR! 🎉 We've deployed an automatic preview for this PR - you can see your changes here:
Note The build needs to finish before your changes are deployed. |
| import { css } from 'lit'; | ||
| import { getFlag } from '../../helpers/flags.js'; | ||
|
|
||
| const OffSCREEN_SIZELESS = getFlag('d2l-offscreen-sizeless', true); |
There was a problem hiding this comment.
Please correct me if I'm wrong but this should be deleted in December 2026 (this year) according to the flag's definition. Also the jira ticket this PR is linked to says the same so, just wanted to double check if this is something intended. Thank you
There was a problem hiding this comment.
So 6 months is the default when creating a new flag and hence why this is set in December, but usually we have 3-release lifespans for Gaudi flags(that would be September). Nothing has been raised around this so it's safe to remove it now
| */ | ||
| export const _offscreenStyleDeclarations = css` | ||
| direction: var(--d2l-document-direction, ${ !HAS_DOCUMENT ? css`unset` : (document.dir === 'rtl' ? css`rtl` : css`ltr`)}); /* stylelint-disable-line @stylistic/string-quotes */ | ||
| height: ${HAS_DOCUMENT && OffSCREEN_SIZELESS ? 0 : 1}px; /* The HAS_DOCUMENT check can be removed once the d2l-offscreen-sizeless flag is removed and set to 0px */ |
There was a problem hiding this comment.
I know I reviewed the PR that changed this, but now I am wondering what the backstory is on why we are changing the dimension from 1px to 0. IIRC, a long long time ago we discovered that screen readers would not announce elements with zero dimensions. I'm assuming that must have changed since I don't think we'd change this without testing with a screenreader.
NTNGL-5576