Commit Graph

4390 Commits

Author SHA1 Message Date
Joey Perrott 6575ade81a chore: use computed radius size for checkbox ripple during 2018 material spec update transition (#13038) 2018-09-11 12:33:28 -07:00
Kristiyan Kostadinov 948e563ed9 fix(ripple): ripples not being cleared if touch sequence is canceled (#12936)
If the browser's touch sequence gets canceled by something, the `touchend` event won't fire which means that the ripples won't be cleared from the ripple container. These changes add an extra handler to make sure that they are.
2018-09-11 10:58:50 -07:00
Kristiyan Kostadinov cfb83a0ebc fix(grid-list): better handling of negative columns (#12939)
Currently if, by any chance, assigns a negative number to the `cols` of a grid list, they'll get a cryptic error like `Invalid array length`, because down-the-line we use that number to create an array. These changes ensure that the value is always a positive number.
2018-09-11 10:58:08 -07:00
Daniel Schuba e24f24a6a0 fix(tree): theming nested notes (#12938)
changes nested-tree-nodes to be styled the same as tree-nodes
2018-09-11 10:57:46 -07:00
Paul Gschwendtner 722dfb3633 fix(tooltip): not showing up on touch devices (#12940)
* Currently if someone long presses a tooltip trigger on a touch device, the tooltip will not show up. This is because the `longpress` event does reset immediately and not fire if a `slide` event is being recognized. The `slide` event most likely fires most of the time because of a `threshold = 0` (for smooth sliding)

Fixes #12917
2018-09-11 10:45:03 -07:00
Paul Gschwendtner 0389d12309 fix(tooltip): text fields not editable if tooltip is applied in safari (#12959)
Applying `matTooltip` directly on a `<input>` or `<textarea>` element causes HammerJS to add a `user-select: none` inline style. This prevents users from typing into the text fields in Safari.

Since the `user-select: none` is not needed for the `longpress` event, we can just **always reset** the `user-select` if a tooltip is applied on a text-field because we want to avoid such issues.

Fixes #12953
2018-09-11 10:43:40 -07:00
Kristiyan Kostadinov be510149e8 refactor(list): remove redundant focus logic (#12965)
Currently both the regular list and the selection list have focus and blur handlers whose job it is to toggle a focused class. This is redundant, because the same can be achieved with a `:focus` selector, without having to go through change detection.
2018-09-11 10:43:22 -07:00
Kristiyan Kostadinov cbfbaded96 fix(form-field): don't set up mutation observer on non-outline appearances (#12976)
Currently we use a `MutationObserver` to update the label gap when the label content changes. This is unnecessary on any appearance aside from `outline`.
2018-09-11 10:42:59 -07:00
Kristiyan Kostadinov 62136c16c4 refactor(focus-monitor): accept ElementRef in focusVia (#12978)
Looks like something that was missed in #12712. For consistency with `monitor` and `stopMonitoring`, accepts an `ElementRef` in `focusVia`.
2018-09-11 10:42:19 -07:00
Kristiyan Kostadinov f39e0911ca fix(portal): remove dependency on deprecated parentInjector (#12986)
The `ViewContainerRef.parentInjector` property is deprecated. These changes remove our dependency on it.
2018-09-11 10:41:40 -07:00
vivian-hu 69fa76236a feat(list): add new '<mat-action-list>' (#12415)
An action-list is a list where each list item is a native '<button>' element, meant to be used in cases where each list item has a single action with no sub-action, navigation or selection.
2018-09-11 10:41:20 -07:00
Kristiyan Kostadinov 8ee5fb66c6 fix(drag-drop): text selection not disabled on safari if user drags out of the viewport (#12864)
Currently we disable text selection on all draggable elements and their handles, however that doesn't seem to be enough on Safari, because moving your cursor towards the end of the viewport causes the entire body text to be marked. These changes also disable text marking on the entire body while the user is dragging.
2018-09-11 10:40:20 -07:00
Kristiyan Kostadinov ec0de52b68 fix(drag-drop): dragging class not being applied on drop container (#12921)
Fixes the `cdk-drop-dragging` class not being applied to the drop container after 5d0ec23b1d. The introduction of the `onStable` call caused the event to be bound outside the `NgZone`.
2018-09-11 10:39:42 -07:00
Kristiyan Kostadinov fb7bf900c0 fix(drag-drop): DOM element not being returned to initial container on drop (#12948)
Currently when an item is dropped, we return it to its initial position in the DOM so Angular can take over and re-render it if necessary, however this breaks down if the item is the only child of the drop container and we weren't able to grab a reference element that we can use to restore its position. These changes address the issue by using the initial drop container as a reference.

Fixes #12944.
2018-09-11 10:39:27 -07:00
Kristiyan Kostadinov d1c27ae1c4 refactor(drag-drop): expose delta in moved event (#12952)
Since we now have the delta of the movement easily available, we can expose it via the `cdkDragMoved` event.
2018-09-11 10:39:11 -07:00
Kristiyan Kostadinov 951add921d fix(drag-drop): incorrectly picking up transitions on non-transform properties (#12966)
Currently we wait for the transition on a dropped item to end before completing the sequence or timing it out. Our current approach works for a single property transition (e.g. `transition: transform 300ms`), but will break down for multi-property ones (`transition: opacity 300ms, transform: 600ms`) or ones that don't target `transform` at all. The following changes rework the logic to handle the extra cases.
2018-09-11 10:38:51 -07:00
Jeremy Elbourn 5718975b57 Revert "feat(button): align with 2018 material design spec (#12537)" (#13080)
This reverts commit 4ddbde93ea.
2018-09-11 10:31:05 -07:00
Joey Perrott 1908b3e8eb chore(dialog): update dialog animations for 2018 material spec update (#13059) 2018-09-11 10:21:38 -07:00
Paul Gschwendtner 041a41d4a7 build(dashboard): switch to new @angular/fire package (#13051)
Switches the dashboard to the new scoped name for the `angularfire2` package.
2018-09-10 16:09:29 -07:00
Paul Gschwendtner e1b040d0e1 build(docs): fix directive metadata not showing up in docs (#13057)
* Due to the recent update to TypeScript 3.0.0, the new TS version conflicts with the internal TypeScript version from `dgeni-packages`. This causes the selector, exported-as to not show up in the docs.
* Removes the selector blacklist and `md-`prefix filter. All of the blacklisted selectors have been removed (except the autosize selector; but the whole class has been deprecated now)
2018-09-10 16:06:35 -07:00
Paul Gschwendtner 05563d95f8 chore(schematics): add missing constructor checks data (#13052)
Adds the constructor signature check data for https://github.com/angular/material2/pull/11706 which is already published in `7.0.0-beta.0`.
2018-09-10 16:03:24 -07:00
Paul Gschwendtner d74f94c335 build: run publish sanity checks before building (#13060)
Runs the publish sanity checks before building the release output of Angular Material. Building the release output is very time consuming, and therefore the sanity checks should run before.

Closes #12918
2018-09-10 15:54:25 -07:00
Ben Lesh 0a25fca2d7 fix(typings): update typings to support more strict typings in RxJS 6.3.2 (#12979) 2018-09-10 13:23:27 -07:00
Paul Gschwendtner 9886b1b198 refactor(schematics): avoid typescript version conflicts (#12989)
The Angular Material schematics parse TypeScript sources files and pass the AST to the `@schematics/angular` package which defined an explicit dependency on `typescript`. Since we currently just always require the flattened `typescript` dependency (`node_modules/typescript`), there could be either no TypeScript version or a different TypeScript version that causes the AST operations of the `@schematics/angular` utility functions to not work properly (e.g. different `SyntaxKind` ids)

We should primarily try to load the same TypeScript version that has been shipped with the `@schematics/angular`. If that one couldn't be found, fall back to the top level `typescript` version.

Includes workaround for Bazel ts module resolution
2018-09-10 07:20:16 -07:00
Paul Gschwendtner c54c89769c refactor(schematics): constructor checks should respect assignability (#13050)
Reworks the constructor signature check rule to take advantage of the TypeScript pre-emit diagnostics. This is necessary because there is no public API to check the relation of two types (e.g. checking if the super-call arguments are assignable to the actual constructor parameter signature)

This now means that the constructor checks respect type assignability (e.g. it won't throw incorrectly if a developer does something like:

```ts
class ExtendedPlatform extends Platform {}

new NativeDateAdapter(a, new ExtendedPlatform(...))`
```
2018-09-10 07:19:26 -07:00
Kristiyan Kostadinov 7c4fa66d53 build: don't allow trailing whitespace in CSS files (#13014)
Similar to TS files, doesn't allow trailing whitespace in CSS.
2018-09-06 15:14:43 -07:00
Paul Gschwendtner 098f25a2fd refactor(schematics): enable strict null checks (#12983)
* Enables strict null checks for the schematics and fixes a few potential unsafe accesses.
* Supports specifying a project for `ng-add`.
2018-09-06 13:53:21 -07:00
Paul Gschwendtner e124418d07 refactor(ng-update): better check for updated constructor signatures (#12970)
Instead of just checking the length of the constructor arguments, we now check the types of the constructor or super call. This means that we can *way* better report invalid signatures for constructor changes like for the `MatCalendar` (https://github.com/angular/material2/pull/9775). Just relying on the length of arguments means that *order*  is being ignored.

This also makes maintaining the constructor signature changes easier (there are a lot of instances for V7).
2018-09-05 16:31:24 -07:00
Kristiyan Kostadinov 86be1dcb19 docs(overlay): add note about pre-built styles (#12993)
Adds a note about the pre-built overlay styles since we have not mention of them anywhere else in the docs.

Fixes #8717.
2018-09-05 13:39:26 -07:00
Paul Gschwendtner 5d9ab9eeb2 refactor(schematics): re-add disabled aliases (#12982)
* Due to a devkit issue, we temporarily had to remove the schematic aliases in order to be able to run the tests. Since this issue has been fixed a long time ago, we can re-add the aliases.
* Also adds more aliases to other schematics for consistency.
* Locks the devkit and schematics version because there is an ongoing type definition bug within the devkit (https://unpkg.com/@angular-devkit/core@0.7.5/src/virtual-fs/host/test.d.ts).
2018-09-05 10:39:14 -07:00
Paul Gschwendtner fe642115de fix(ng-update): do not throw if imports without named bindings are used (#12866) (#12984)
Currently if someone uses a namespace import or an import without named bindings in an Angular application, the `ng-update` schematics from Angular Material will fail due to missing safety checks before casting.

Fixes #11571
2018-09-05 10:29:55 -07:00
Kristiyan Kostadinov 4ddbde93ea feat(button): align with 2018 material design spec (#12537)
Aligns the button component with the latest Material design spec.
2018-09-05 08:03:11 -07:00
Paul Gschwendtner dc6688df04 build: skip duplicate commit entries in changelog (#12943)
Ensures that commits are not showing up multiple times in the changelog.

Commits can show up multiple times, if a changelog has been generated on a publish branch and has been copied over to "master". In that case, the changelog will already contain the commits that have been cherry-picked into the publish branch. These shouldn't be added twice.

Closes #12915
2018-09-04 15:12:17 -07:00
Paul Gschwendtner cfb4f58eda refactor(schematics): split up upgrade data for target version (#12951) 2018-09-04 11:54:08 -07:00
Paul Gschwendtner da95e34ef6 build: update dgeni packages (#12956)
* Upgrades to the latest Dgeni packages version that includes a fix which ensures that the docs for the `Platform` show up properly.

See: https://github.com/angular/dgeni-packages/commit/ab957d1234b49624fb999e321479a8b7493a114a
2018-09-04 11:50:26 -07:00
Paul Gschwendtner be691cb869 build: suppress bazel schematic tsconfig warnings (#12957)
* Since the schematics are also built through Gulp, we need to specify the `exclude` option in the `tsconfig`. Bazel warns because those options will be ignored. Similarly to all other tsconfig files, we should suppress the warnings.
2018-09-04 11:49:52 -07:00
Paul Gschwendtner b884295641 refactor(schematics): resolve rule directories automatically (#12958)
* Instead of hard-coding the rule directories and potentially forgetting about adding directories if new rules have been created, we automatically resolve the directories through `glob`. Glob is already used in various schematic parts, and can be used here as well.
2018-09-04 11:48:54 -07:00
Kristiyan Kostadinov 0ab720a69d build: rework breaking changes tooling (#12950)
* Reworks the breaking change tslint rule to remove the logic that checks that there are no expired breaking changes.
* Adds a new script that can be used to get an overview of the pending and expired breaking changes.
2018-09-04 11:46:26 -07:00
Paul Gschwendtner c618f03a34 build: upgrade dashboard dependencies (#12960)
Upgrades the dashboard to V7 beta. This also fixes some vulnerabilities with the `hoek` transitive dependency.
2018-09-04 11:44:24 -07:00
Jeremy Elbourn 193c2d0c00 docs: mention beta docs in changelog (#12919) 2018-08-31 08:26:42 -07:00
Kristiyan Kostadinov 42f98a596f docs(drag-drop): text blending in with card on dark theme (#12922)
Fixes the text inside the drag&drop boxes blending in on a dark theme.
2018-08-31 08:25:30 -07:00
Paul Gschwendtner fbee9c7d8a refactor(schematics): table schematic not inlining style file (#12905)
This is not a bug fix because the styleext file is basically empty. But in case we add styles to the styleext template file, we should automatically properly inline the styles if `--inlineStyle` is specified.
2018-08-30 18:21:24 -07:00
Kristiyan Kostadinov c812268ac3 feat(menu): align with 2018 material design spec (#12331)
Aligns the menu component with the latest version of the Material design spec. Includes making `overlapTrigger` false by default.
2018-08-30 17:28:20 -07:00
Jeremy Elbourn 2433b82067 chore: bump to 7.0.0-beta.0 w/ TS 3.0 and changelog (#12916) 2018-08-30 15:38:58 -07:00
Kristiyan Kostadinov b2ae3f4a9d build: clean up build workaround for ts 2.9 (#12912)
Removes a workaround that was initially introduced to get #12182 through. The root issue has been resolved in #12876.
2018-08-30 14:35:29 -07:00
Kristiyan Kostadinov b2d74e163e refactor(drag-drop): remove usages of findIndex (#12913)
Removes uses of `Array.prototype.findIndex` from `cdk/drag-drop`.
2018-08-30 14:34:05 -07:00
Jeremy Elbourn 4576863b17 chore: make publish version+branch check support minor and patch (#12910) 2018-08-30 13:05:03 -07:00
Jeremy Elbourn 59f401dc55 chore: add 6.4.7 changelog notes to master (#12900) 2018-08-30 13:04:23 -07:00
Kristiyan Kostadinov 86ed40c871 chore: fix compilation error in form field (#12907)
Fixes a compilation error in the `matNativeControl` directive.
2018-08-30 12:00:11 -07:00
Kristiyan Kostadinov ac8ed31d36 fix(expansion-panel): elevation transition not working (#12860)
Fixes the elevation transition being applied to the expansion panel and then being overridden immediately by the margin transition.
2018-08-30 07:07:13 -07:00