Allows a localized alt tag to be added to the logo element (for ex. in Spotlights where the logo is replaced by an image.)
Implemented similarly to the alt-tag for the onboarding illustrations; localization requires a `string_id` with an associated `.aria-label` prop.
Differential Revision: https://phabricator.services.mozilla.com/D184139
Make the main Spotlight image always lazy load, and make other
Spotlight/about:welcome images lazy load if the configured src is an
http or https URL. This is to fix a bug where slow image loading due to
network issues could cause Spotlight modals to hang while blocking
interaction with the rest of the browser.
Differential Revision: https://phabricator.services.mozilla.com/D180483
This involves opening the shadow root of the migration wizard, as the panel-list
really isn't designed to handle being embedded within a closed shadow root.
Differential Revision: https://phabricator.services.mozilla.com/D182484
This involves opening the shadow root of the migration wizard, as the panel-list
really isn't designed to handle being embedded within a closed shadow root.
Differential Revision: https://phabricator.services.mozilla.com/D182484
This involves opening the shadow root of the migration wizard, as the panel-list
really isn't designed to handle being embedded within a closed shadow root.
Differential Revision: https://phabricator.services.mozilla.com/D182484
This involves opening the shadow root of the migration wizard, as the panel-list
really isn't designed to handle being embedded within a closed shadow root.
Differential Revision: https://phabricator.services.mozilla.com/D182484
Also, because the data collection policy now allows Category 1 and 2
data collection in Private Browsing Mode, these CFRs will record
telemetry in PBM according to the existing CFR policy, which allows
Cat1-3 data for pre-release builds and experiments, and Cat1-2 data for
release builds. PBM windows will be treated in the same way that release
builds treat normal windows. When not enrolled in a CFR experiment, the
PBM window will only collect Cat1-2 data. When enrolled in a CFR
experiment, the PBM window may collect Cat3 data. This patch also adds a
new option to PopupNotifications that allows its usual interaction
probes to be recorded in PBM. That means, outside of an experiment,
pings from a PBM window will look just like pings from a release build
non-PBM window. And inside an experiment, pings from a PBM window will
look just like pings from a non-PBM window in any build. This ensures
that the PBM pings do not intrinsically confer any identifying
information, since their privateness cannot be known with certainty.
Differential Revision: https://phabricator.services.mozilla.com/D174200
Previously, when a `TemplatedMessage` was missing a required field, the error
on Experimenter would be that the message's template field was expected to be
`multi`. This happens because the `oneOf` doesn't match `TemplatedMessage` due
to required fields missing, so it infers it must be a `MultiMessage`.
Now instead of using a `oneOf` to match against either a `MultiMessage` or a
`TemplatedMessage`, we use an `if`/`then`/`else`, predicated by the `template`
key so that if `template != "multi"`, the errors will come form the
`TemplatedMessage` definition.
Differential Revision: https://phabricator.services.mozilla.com/D177914
Fix a bug where VS Code's eslint integration does not work for the
newtab project because of a conflict caused by sass-lint's eslint
dependency. Switching over to stylelint eliminates that dependency and
generally modernizes our SCSS linting. stylelint doesn't have a 1 to 1
replacement for every sass-lint rule, so a few rules have been changed.
Differential Revision: https://phabricator.services.mozilla.com/D173605
Add some properties to the migration wizard screen JSON to specify what
action to perform when CTAs inside the embedded migration wizard are
clicked. This lets us advance screens when the cancel or finish button
is clicked, and send telemetry when the start button is clicked. In
theory we could perform any special message actions too, but for now we
only need telemetry and screen navigation.
Differential Revision: https://phabricator.services.mozilla.com/D176358
This patch restores link underlines in the new tab page, particularly the settings page and discovery stream (top sites, pocket tiles, and recent activity). Only links that had underlines on hover were updated. `text-decoration: none` is added for cards to maintain original styling.
Differential Revision: https://phabricator.services.mozilla.com/D176819
Significant portions of this were written by Shane Hughes <shughes@mozilla.com> -
specifically the parts that move the Firefox Account sign-in flow for tabs into
a SpecialMessageAction, and making AboutWelcomeUtils.handleUserAction return
a Promise.
Differential Revision: https://phabricator.services.mozilla.com/D176453
Significant portions of this were written by Shane Hughes <shughes@mozilla.com> -
specifically the parts that move the Firefox Account sign-in flow for tabs into
a SpecialMessageAction, and making AboutWelcomeUtils.handleUserAction return
a Promise.
Differential Revision: https://phabricator.services.mozilla.com/D176453
about:welcome checkboxes can now set an `checkedAction` and an
`uncheckedAction`, which will occur when the checkbox is checked or unchecked,
respectively, and the primary button is clicked.
The old `action` parameter is still supported for backwards compatability, but
`checkedAction` takes precedence.
Differential Revision: https://phabricator.services.mozilla.com/D174192
This adds a card to the about:welcome defaults that embeds the new Migration Wizard
if browser.migrate.content-modal.about-welcome-behavior is set to "embedded".
This requires adding a useEmbeddedMigrationWizard targeting attribute to
ASRouterTargeting.
Differential Revision: https://phabricator.services.mozilla.com/D175945
This commit:
* Adds a `position` key to the `topsites.{impression, click}` events.
This position is zero-based, to align with `pocket_position`.
* Refactors the impression stats actions in `TelemetryFeed` to receive
the zero-based tile position, and adds one to the structured
ingestion payloads and scalar values.
* Adds a new Glean metric, `topsites.rows`, to record the number of
rows shown on the New Tab page.
Differential Revision: https://phabricator.services.mozilla.com/D172292
Add logic to apply theme colors to Feature Callout based on where it's
going to show. We can use in-content CSS properties for Firefox View and
other themed system pages, but not for PDF.js, nor for any callouts we
might show in the browser chrome in the future. For the browser chrome
in general, we can use the lightweight theme properties directly, in the
same way the chrome frontend does. But PDF.js is a special case, since
although it exists in the chrome, it's meant to appear like it's in the
PDF.js viewer. And the PDF.js viewer has its own theme totally
independent of everything else. So this dynamically applies themes from
different sources.
This also fixes the bug where the PDF.js color scheme could mismatch the
PDF.js viewer if the browser theme and system color scheme don't match,
e.g. where system color scheme is light but a dark theme is installed,
or vice versa. For PDF.js specifically, we can use the
-moz-content-prefers-color-scheme media query to follow the color scheme
as it exists in the PDF.js viewer page instead of the color scheme in
the chrome window where the Feature Callout actually exists.
It also adds or modifies some colors that were previously missing or
different from the prototype, fixes the illegibility of buttons in HCM
and forced colors mode, and makes some other minor color changes.
Differential Revision: https://phabricator.services.mozilla.com/D173088
Add logic to apply theme colors to Feature Callout based on where it's
going to show. We can use in-content CSS properties for Firefox View and
other themed system pages, but not for PDF.js, nor for any callouts we
might show in the browser chrome in the future. For the browser chrome
in general, we can use the lightweight theme properties directly, in the
same way the chrome frontend does. But PDF.js is a special case, since
although it exists in the chrome, it's meant to appear like it's in the
PDF.js viewer. And the PDF.js viewer has its own theme totally
independent of everything else. So this dynamically applies themes from
different sources.
This also fixes the bug where the PDF.js color scheme could mismatch the
PDF.js viewer if the browser theme and system color scheme don't match,
e.g. where system color scheme is light but a dark theme is installed,
or vice versa. For PDF.js specifically, we can use the
-moz-content-prefers-color-scheme media query to follow the color scheme
as it exists in the PDF.js viewer page instead of the color scheme in
the chrome window where the Feature Callout actually exists.
It also adds or modifies some colors that were previously missing or
different from the prototype, fixes the illegibility of buttons in HCM
and forced colors mode, and makes some other minor color changes.
Differential Revision: https://phabricator.services.mozilla.com/D173088
The schema still imposes the following restrictions:
- Having "template" present makes "content" and "id" required.
- Having "content" present makes "template" and "id" required.
Template and content are dependent on eachother because we do not know how to
interpret content without a template and we a template with no content to
interpret is useless.
If we have a template and content, then we also need an ID for the message
because we cannot reference the message content except by its ID.
Differential Revision: https://phabricator.services.mozilla.com/D172458
The schema still imposes the following restrictions:
- Having "template" present makes "content" and "id" required.
- Having "content" present makes "template" and "id" required.
Template and content are dependent on eachother because we do not know how to
interpret content without a template and we a template with no content to
interpret is useless.
If we have a template and content, then we also need an ID for the message
because we cannot reference the message content except by its ID.
Differential Revision: https://phabricator.services.mozilla.com/D172458
The schema still imposes the following restrictions:
- Having "template" present makes "content" and "id" required.
- Having "content" present makes "template" and "id" required.
Template and content are dependent on eachother because we do not know how to
interpret content without a template and we a template with no content to
interpret is useless.
If we have a template and content, then we also need an ID for the message
because we cannot reference the message content except by its ID.
Differential Revision: https://phabricator.services.mozilla.com/D172458
Currently, the Glean `newtab` ping and legacy scalars collect
impressions and clicks for sponsored (Pocket and Contile) tiles, but
not organic tiles from Places.
This commit adds:
* Support for recording organic impressions to the
`TopSiteImpressionWrapper` component.
* Support for recording organic clicks to the `TopSiteLink`
component.
* Instrumentation for recording organic impressions and clicks,
separate from sponsored ones, to `TelemetryFeed`.
Differential Revision: https://phabricator.services.mozilla.com/D171830
This also fixes a bug in ASRouter devtools that prevented evaluation of
expressions containing nested promises. Objects containing promises are now
correctly serialized to the ASRouter devtools and expressions evaluate
correctly.
Differential Revision: https://phabricator.services.mozilla.com/D169408
This also fixes a bug in ASRouter devtools that prevented evaluation of
expressions containing nested promises. Objects containing promises are now
correctly serialized to the ASRouter devtools and expressions evaluate
correctly.
Differential Revision: https://phabricator.services.mozilla.com/D169408
Fixes the border radius and color/style of the outline applied to
feature callouts when they are focused. Also applies the focus ring to
the callout's arrow with some CSS changes.
Differential Revision: https://phabricator.services.mozilla.com/D170524
Fixes the border radius and color/style of the outline applied to
feature callouts when they are focused. Also applies the focus ring to
the callout's arrow with some CSS changes.
Differential Revision: https://phabricator.services.mozilla.com/D170524
Remove all the transition-in and transition-out animations from the
Spotlight dismiss button, leaving the dialog-initial and dialog-last
animations, anticipating that all our messages will either have a
dismiss button on every screen or on none of the screens.
Differential Revision: https://phabricator.services.mozilla.com/D170527
This patch does two things:
1. Brings focus into the add/edit top site dialogs when they are opened.
2. Sets the `aria-haspopup=dialog` attribute on the buttons that open the dialogs. This helps assistive technologies announce that a dialog is being opened before it opens.
Differential Revision: https://phabricator.services.mozilla.com/D168564