This reverts commit 480e34ce99.
Reason for revert: `button, .button` is not specific enough, has too low of precedence, resulting in edit link buttons getting the wrong color. Will reland as `button, .button, a.button`. Thanks CSS :)
Original change's description:
> [nnbd_migration] Fix two popup style bugs
>
> Due to a z-index bug, regions are showing up on top of the popup. Fixed.
>
> A regression during a previous a.button/.button change that meant that
> the close button wasn't rendered as a button.
>
> Change-Id: I2c8b84655bd8afdbc0163f5dd810bca84c3db8b2
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148642
> Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
> Commit-Queue: Paul Berry <paulberry@google.com>
> Auto-Submit: Mike Fairhurst <mfairhurst@google.com>
> Reviewed-by: Paul Berry <paulberry@google.com>
TBR=paulberry@google.com,mfairhurst@google.com,srawlins@google.com
Change-Id: I29f92aaa79c6285e2822866660e1b5f77b1f43ae
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148644
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
These interfaces acted as a temporary bridge to allow analysis server
core classes to provide services needed by nnbd_migration without
forcing analysis_server to depend on nnbd_migration; that in turn
allowed the analysis server to provide migration services to dartfix.
Now that we no longer use the analysis server nor dartfix for
migration, these interface classes are no longer needed.
As of this commit, the nnbd_migration package no longer depends on
analysis_server.
Change-Id: Ia923d91dd59c9a612000da8b0c9ead8a68686d89
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148560
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
Previously we re-used pages.dart from the analysis server. This paves
the way for making nnbd_migration independent of the analysis server,
which will allow it to be published on pub.
Note that only the portions of pages.dart that are actually used by
nnbd_migration are retained.
Change-Id: I48db228a3bf372cf918f2d2719f8f5415ddfc193
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148511
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
This code was necessary when the NNBD migration engine was part of the
analysis server, to allow migration to be run in-process. Now that
it's been separated to its own library, it always runs in process, so
this code is not needed anymore.
Change-Id: Id9e497dca6700ad804f2410cb3b20107be3a4bd2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148503
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
Change `handleInsertion` to use a `SourceEdit` instead, and update
`PreviewSite` to use it, but otherwise do not change `PreviewSite`. That
can be tested later when we have new `HintAction`s that allow us to
exercise this new code.
Change-Id: Idd6d782e003d4d643abb5770daa9055685f2e76a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148186
Reviewed-by: Paul Berry <paulberry@google.com>
This existed solely to have a centralized location for the analysis
server's dependencies on nnbd_migration. Now that nnbd_migration
doesn't depend on the analysis server, there's no need for it anymore.
Change-Id: I24b231337b1f724840b4533afef1672241b0af4b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148181
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Janice Collins <jcollins@google.com>
We no longer use the analysis server or dartfix for migration.
This should unblock removing migration integration from dartfix, which
will unblock publishing dartfix.
It should also pave the way for future changes that will allow us to
publish the NNBD migration tool on pub, which in turn will allow us to
provide updates and bug fixes to the migration tool without having to
publish a new Dart or Flutter SDK.
Change-Id: I9f128b61a2983befc5ef686867dab3db87fd6855
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148020
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
This is a step toward integrating the new migration CLI with dartdev.
It's necessary because dartdev handles arg parsing.
Change-Id: Ie50a69c434fd4d8873616e72b8274545cf0277d8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148007
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
In the future this could change to simply be a `Set<HintActionKind>`, so
that the `AtomicEdit`s can be calculated lazily. However, for the first
pass, they are calculated eagerly. This model lets us do that.
Change-Id: I07108ae0876d5e0efe7b35559cedb4cbd1c13605
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/147624
Reviewed-by: Paul Berry <paulberry@google.com>
The progress bar fills the width of the user's terminal, and computes
progress strictly based on files and phases, not weighing any file or
phase as greater than another.
Change-Id: Ic9840b3b66789512e0973160b3e0f069b714a4f8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/147421
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Janice Collins <jcollins@google.com>
Based on suggestions from
https://dart-review.googlesource.com/c/sdk/+/146442. Specifically,
the `_Output` class hierarchy has been moved to a new file so that the
classes in it are together, and the remaining classes (in the
DiffStyle hierarchy) are together in source_edit_diff_formatter.dart.
This required making a bunch of things public, so I split `DiffStyle`
into an interface and and impl class to make it easier to see which
method is intended to be used (DiffStyle.formatDiff). Also, moved the
logic that was previously in _Output._processEdits to
DiffStyleImpl.formatDiff.
Change-Id: Iad448f16233e6752e7b20d1e0cee4eb5c033f498
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/146821
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
This should help ensure that descriptions of nullabilities that show
up in the stack trace refer to parts of the program the user is
familiar with, rather than simply saying "explicit type".
Change-Id: If53198cc45077a664e44859c7c0770ec9831c765
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/146964
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
This was the original behavior, and it persists in some tests because
it's more trouble than it's worth to rewrite them. But it's not the
behavior we want to ship to users.
Change-Id: Ibf1df628f62b01e934d05336bfe43a5a61268f93
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/147042
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
In the dartfix-based implementation, the only significant effect of
supplying `--debug` was to enable the analysis server's
instrumentation log. Since we don't have an analysis server layer in
the new CLI, there's no need for this command line option right now.
If we decide we need a `--debug` flag later we can always add it.
Change-Id: Ib729c5793044456ef460cfa7f823c48f5af9e898
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/146445
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>