-
Notifications
You must be signed in to change notification settings - Fork 33
fix: Remove d2l-offscreen-sizeless flag #7247
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,20 +1,18 @@ | ||
| import { css } from 'lit'; | ||
| import { getFlag } from '../../helpers/flags.js'; | ||
|
|
||
| const OffSCREEN_SIZELESS = getFlag('d2l-offscreen-sizeless', true); | ||
| const HAS_DOCUMENT = globalThis.document !== undefined; | ||
|
|
||
| /** | ||
| * A private helper declarations that should not be used by general consumers | ||
| */ | ||
| 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 */ | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 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 |
||
| height: 0; | ||
| inset-inline-start: -10000px; | ||
| overflow: hidden; | ||
| position: absolute !important; | ||
| white-space: nowrap; | ||
| width: ${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 */ | ||
| width: 0; | ||
| `; | ||
|
|
||
| export const offscreenStyles = css` | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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