ember-inspector 4.6.3 → 4.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/README.md +4 -29
  3. package/app/components/object-inspector/accordion.js +19 -11
  4. package/app/components/object-inspector/property-field.js +1 -1
  5. package/app/components/object-inspector/sort-properties.js +4 -6
  6. package/app/components/promise-item.js +43 -43
  7. package/app/components/route-cell-name.js +5 -7
  8. package/config/ember-cli-update.json +1 -1
  9. package/config/ember-try.js +0 -17
  10. package/config/environment.js +1 -8
  11. package/dist/bookmarklet/panes-3-4-0/assets/chunk.131.94e9295903c351885e48.js +643 -0
  12. package/dist/bookmarklet/panes-3-4-0/assets/chunk.131.94e9295903c351885e48.js.LICENSE.txt +24 -0
  13. package/dist/bookmarklet/panes-3-4-0/assets/chunk.143.2f2438030067e3bf00af.js +22 -0
  14. package/dist/{firefox/panes-3-4-0/assets/chunk.178.f1881efc1b50e51edd7a.js → bookmarklet/panes-3-4-0/assets/chunk.178.1ff4120323a040a98ed0.js} +3 -3
  15. package/dist/bookmarklet/panes-3-4-0/assets/ember-inspector.js +74 -79
  16. package/dist/bookmarklet/panes-3-4-0/assets/vendor.js +2224 -2268
  17. package/dist/bookmarklet/panes-3-4-0/ember_debug.js +2 -2
  18. package/dist/bookmarklet/panes-3-4-0/index.html +3 -1
  19. package/dist/chrome/manifest.json +1 -1
  20. package/dist/chrome/panes-3-4-0/assets/chunk.131.94e9295903c351885e48.js +643 -0
  21. package/dist/chrome/panes-3-4-0/assets/chunk.131.94e9295903c351885e48.js.LICENSE.txt +24 -0
  22. package/dist/chrome/panes-3-4-0/assets/chunk.143.2f2438030067e3bf00af.js +22 -0
  23. package/dist/{bookmarklet/panes-3-4-0/assets/chunk.178.f1881efc1b50e51edd7a.js → chrome/panes-3-4-0/assets/chunk.178.1ff4120323a040a98ed0.js} +3 -3
  24. package/dist/chrome/panes-3-4-0/assets/ember-inspector.js +74 -79
  25. package/dist/chrome/panes-3-4-0/assets/vendor.js +2224 -2268
  26. package/dist/chrome/panes-3-4-0/ember_debug.js +2 -2
  27. package/dist/chrome/panes-3-4-0/index.html +3 -1
  28. package/dist/firefox/manifest.json +1 -1
  29. package/dist/firefox/panes-3-4-0/assets/chunk.131.94e9295903c351885e48.js +643 -0
  30. package/dist/firefox/panes-3-4-0/assets/chunk.131.94e9295903c351885e48.js.LICENSE.txt +24 -0
  31. package/dist/firefox/panes-3-4-0/assets/chunk.143.2f2438030067e3bf00af.js +22 -0
  32. package/dist/{websocket/assets/chunk.178.f1881efc1b50e51edd7a.js → firefox/panes-3-4-0/assets/chunk.178.1ff4120323a040a98ed0.js} +3 -3
  33. package/dist/firefox/panes-3-4-0/assets/ember-inspector.js +74 -79
  34. package/dist/firefox/panes-3-4-0/assets/vendor.js +2224 -2268
  35. package/dist/firefox/panes-3-4-0/ember_debug.js +2 -2
  36. package/dist/firefox/panes-3-4-0/index.html +3 -1
  37. package/dist/websocket/assets/chunk.131.94e9295903c351885e48.js +643 -0
  38. package/dist/websocket/assets/chunk.131.94e9295903c351885e48.js.LICENSE.txt +24 -0
  39. package/dist/websocket/assets/chunk.143.2f2438030067e3bf00af.js +22 -0
  40. package/dist/{chrome/panes-3-4-0/assets/chunk.178.f1881efc1b50e51edd7a.js → websocket/assets/chunk.178.1ff4120323a040a98ed0.js} +3 -3
  41. package/dist/websocket/assets/ember-inspector.js +74 -79
  42. package/dist/websocket/assets/vendor.js +2224 -2268
  43. package/dist/websocket/ember_debug.js +2 -2
  44. package/dist/websocket/index.html +3 -1
  45. package/ember_debug/object-inspector.js +3 -2
  46. package/package.json +19 -20
  47. package/dist/bookmarklet/panes-3-4-0/assets/chunk.143.850e58b11c9944ced15c.js +0 -9
  48. package/dist/chrome/panes-3-4-0/assets/chunk.143.850e58b11c9944ced15c.js +0 -9
  49. package/dist/firefox/panes-3-4-0/assets/chunk.143.850e58b11c9944ced15c.js +0 -9
  50. package/dist/websocket/assets/chunk.143.850e58b11c9944ced15c.js +0 -9
package/CHANGELOG.md CHANGED
@@ -12,6 +12,19 @@
12
12
 
13
13
 
14
14
 
15
+
16
+ ## v4.7.0 (2022-08-31)
17
+
18
+ #### :house: Internal
19
+ * [#2124](https://github.com/emberjs/ember-inspector/pull/2124) Update to ember 4 ([@rwwagner90](https://github.com/rwwagner90))
20
+ * [#2122](https://github.com/emberjs/ember-inspector/pull/2122) Convert some components to glimmer ([@rwwagner90](https://github.com/rwwagner90))
21
+ * [#2123](https://github.com/emberjs/ember-inspector/pull/2123) Update ember cli ([@rwwagner90](https://github.com/rwwagner90))
22
+ * [#2121](https://github.com/emberjs/ember-inspector/pull/2121) Remove unused dep `del` ([@rwwagner90](https://github.com/rwwagner90))
23
+
24
+ #### Committers: 2
25
+ - Robert Wagner ([@rwwagner90](https://github.com/rwwagner90))
26
+ - [@patricklx](https://github.com/patricklx)
27
+
15
28
  ## v4.6.3 (2022-08-19)
16
29
 
17
30
  #### :bug: Bug Fix
package/README.md CHANGED
@@ -79,33 +79,8 @@ Run `yarn install && yarn global add ember-cli to install the required modules.
79
79
 
80
80
  ## Deploy new version:
81
81
 
82
- #### Patch versions
83
-
84
- Patch versions are only committed to the stable branch. So we need to cherry-pick the commits we need from master and bump stable to the new patch version.
85
-
86
- - `git checkout stable`
87
- - Cherry-pick the needed commits from master to stable.
88
- - Add the change log entry and commit. We use [github-changelog-generator](https://github.com/github-changelog-generator/github-changelog-generator) for this.
89
- You will want to follow the installation instructions on their README, and take note that you will need to provide a GitHub token.
90
- Once installed, and you add a token, you can run `yarn changelog` in your terminal.
91
- - `yarn version --patch`
92
- - `git push --tags`
93
- - `git push`
94
- - PR the change log entry to the master branch.
95
-
96
- #### Minor and major versions
97
-
98
- When releasing a major/minor version, master would already have this version set, so what we need to do is to merge master into stable and release.
99
-
100
- - `git checkout stable`
101
- - `git merge -X theirs master`
102
- - Add the change log entry and commit. We use [github-changelog-generator](https://github.com/github-changelog-generator/github-changelog-generator) for this.
103
- You will want to follow the installation instructions on their README, and take note that you will need to provide a GitHub token.
104
- Once installed, and you add a token, you can run `yarn changelog` in your terminal.
105
- - `yarn version` (keep the same version number)
106
- - `git push --tags`
107
- - `git push`
108
- - PR the change log entry to the master branch, as well as increment `package.json` to the next major/minor version.
82
+ See [RELEASE.md](./RELEASE.md)
83
+
109
84
 
110
85
  ### Locking a version
111
86
 
@@ -117,7 +92,7 @@ Here are the steps to lock an inspector version:
117
92
 
118
93
  - Release a new version (See "Minor and major versions") if there are unreleased commits in `master`. Skip this step if there are not new commits after the last release.
119
94
  - Makes sure you have a `config/secrets.json` file with the correct AWS credentials to push to S3. You can use `config/secrets.json.sample` as a starting point.
120
- - Create a new branch (from `stable`) named after the Ember version range that will be supported by this branch. The min version in the range is the first element in the `emberVersionsSupported` array in `package.json`. The max version in the range is the first version that will *not* be supported. For example, a branch named `ember-0.0.0-2.7.0` means it supports Ember 0.0.0 -> 2.6.0, and a branch named `ember-2.7.0-3.4.0` means it supports Ember 2.7.0 -> Ember 3.3.2.
95
+ - Create a new branch (from `master`) named after the Ember version range that will be supported by this branch. The min version in the range is the first element in the `emberVersionsSupported` array in `package.json`. The max version in the range is the first version that will *not* be supported. For example, a branch named `ember-0.0.0-2.7.0` means it supports Ember 0.0.0 -> 2.6.0, and a branch named `ember-2.7.0-3.4.0` means it supports Ember 2.7.0 -> Ember 3.3.2.
121
96
  - Update `package.json`'s `emberVersionsSupported`: add a second element that indicates the minimum Ember version the `master` branch *will not* support.
122
97
  - Commit the branch.
123
98
  - Run `yarn lock-version`. This will build, and compress the panes.
@@ -135,7 +110,7 @@ Here are the steps to lock an inspector version:
135
110
  Below is an example scenario that assumes the current `master` branch supports Ember version 2.7.0+ and we want to lock the version such that `master` will support 3.4.0+. It also assumes the last Ember Inspector version released was 3.9.0.
136
111
 
137
112
  - Release a new inspector version `3.10.0` if there are unreleased commits in `master`.
138
- - Create a new branch from `stable` called `ember-2.7.0-3.4.0`.
113
+ - Create a new branch from `master` called `ember-2.7.0-3.4.0`.
139
114
  - Update `package.json`'s `emberVersionsSupported` from `["2.7.0", ""]` to `["2.7.0", "3.4.0"]`.
140
115
  - Commit with message "Lock Ember version at 2.7.0-3.4.0" and push the branch.
141
116
  - Run `yarn lock-version`.
@@ -1,14 +1,22 @@
1
- import { action, computed } from '@ember/object';
2
- import Component from '@ember/component';
1
+ import Component from '@glimmer/component';
2
+ import { action } from '@ember/object';
3
+ import { tracked } from '@glimmer/tracking';
3
4
 
4
- export default Component.extend({
5
- tagName: '',
5
+ export default class AccordionComponent extends Component {
6
+ @tracked _isExpanded;
6
7
 
7
- isExpanded: computed('mixin.{expand,properties.length}', function () {
8
- return this.get('mixin.expand') && this.get('mixin.properties.length') > 0;
9
- }),
8
+ constructor() {
9
+ super(...arguments);
10
10
 
11
- toggle: action(function () {
12
- this.toggleProperty('mixin.expand');
13
- }),
14
- });
11
+ this._isExpanded = this.args.mixin.expand;
12
+ }
13
+
14
+ get isExpanded() {
15
+ return this._isExpanded && this.args.mixin.properties.length > 0;
16
+ }
17
+
18
+ @action
19
+ toggle() {
20
+ this._isExpanded = !this._isExpanded;
21
+ }
22
+ }
@@ -1,4 +1,4 @@
1
- import TextField from '@ember/component/text-field';
1
+ import { TextField } from '@ember/legacy-built-in-components';
2
2
 
3
3
  export default class PropertyField extends TextField {
4
4
  didInsertElement() {
@@ -1,14 +1,12 @@
1
- import { tagName } from '@ember-decorators/component';
2
1
  import { map, sort } from '@ember/object/computed';
3
- import Component from '@ember/component';
2
+ import Component from '@glimmer/component';
4
3
  import { get, set, computed } from '@ember/object';
5
4
  import { A } from '@ember/array';
6
5
 
7
- @tagName('')
8
6
  export default class SortProperties extends Component {
9
- @computed('properties')
7
+ @computed('args.properties')
10
8
  get isArray() {
11
- const props = A(this.properties || []);
9
+ const props = A(this.args.properties || []);
12
10
  return props.findBy('name', 'length') && props.findBy('name', 0);
13
11
  }
14
12
 
@@ -38,7 +36,7 @@ export default class SortProperties extends Component {
38
36
  @sort('props', 'sortProperties')
39
37
  sorted;
40
38
 
41
- @map('properties', function (p) {
39
+ @map('args.properties', function (p) {
42
40
  set(
43
41
  p,
44
42
  'isFunction',
@@ -1,7 +1,6 @@
1
- import { tagName } from '@ember-decorators/component';
2
1
  import { computed, get } from '@ember/object';
3
2
  import { equal, gt, notEmpty } from '@ember/object/computed';
4
- import Component from '@ember/component';
3
+ import Component from '@glimmer/component';
5
4
  import { htmlSafe } from '@ember/template';
6
5
  import { isEmpty } from '@ember/utils';
7
6
 
@@ -11,20 +10,16 @@ const COLOR_MAP = {
11
10
  green: '#006400',
12
11
  };
13
12
 
14
- @tagName('')
15
13
  export default class PromiseItem extends Component {
16
- filter = null;
17
- effectiveSearch = null;
18
-
19
- @equal('model.reason.type', 'type-error')
14
+ @equal('args.model.reason.type', 'type-error')
20
15
  isError;
21
16
 
22
- @computed('model.{isFulfilled,isRejected,state}')
17
+ @computed('args.model.{isFulfilled,isRejected,state}')
23
18
  get style() {
24
19
  let color = '';
25
- if (get(this, 'model.isFulfilled')) {
20
+ if (get(this, 'args.model.isFulfilled')) {
26
21
  color = 'green';
27
- } else if (get(this, 'model.isRejected')) {
22
+ } else if (get(this, 'args.model.isRejected')) {
28
23
  color = 'red';
29
24
  } else {
30
25
  color = 'blue';
@@ -33,27 +28,26 @@ export default class PromiseItem extends Component {
33
28
  }
34
29
 
35
30
  @computed(
36
- 'effectiveSearch',
37
- 'filter',
38
- 'model.{isFulfilled,isPending,isRejected,state}'
31
+ 'args.{effectiveSearch,filter}',
32
+ 'args.model.{isFulfilled,isPending,isRejected,state}'
39
33
  )
40
34
  get nodeStyle() {
41
35
  let relevant;
42
- switch (this.filter) {
36
+ switch (this.args.filter) {
43
37
  case 'pending':
44
- relevant = get(this, 'model.isPending');
38
+ relevant = get(this, 'args.model.isPending');
45
39
  break;
46
40
  case 'rejected':
47
- relevant = get(this, 'model.isRejected');
41
+ relevant = get(this, 'args.model.isRejected');
48
42
  break;
49
43
  case 'fulfilled':
50
- relevant = get(this, 'model.isFulfilled');
44
+ relevant = get(this, 'args.model.isFulfilled');
51
45
  break;
52
46
  default:
53
47
  relevant = true;
54
48
  }
55
- if (relevant && !isEmpty(this.effectiveSearch)) {
56
- relevant = this.model.matchesExactly(this.effectiveSearch);
49
+ if (relevant && !isEmpty(this.args.effectiveSearch)) {
50
+ relevant = this.args.model.matchesExactly(this.args.effectiveSearch);
57
51
  }
58
52
  if (!relevant) {
59
53
  return 'opacity: 0.3;';
@@ -62,35 +56,37 @@ export default class PromiseItem extends Component {
62
56
  }
63
57
  }
64
58
 
65
- @computed('model.level', 'nodeStyle')
59
+ @computed('args.model.level', 'nodeStyle')
66
60
  get labelStyle() {
67
61
  return htmlSafe(
68
- `padding-left: ${+get(this, 'model.level') * 20 + 5}px;${this.nodeStyle}`
62
+ `padding-left: ${+get(this, 'args.model.level') * 20 + 5}px;${
63
+ this.nodeStyle
64
+ }`
69
65
  );
70
66
  }
71
67
 
72
- @computed('hasChildren', 'model.isExpanded')
68
+ @computed('hasChildren', 'args.model.isExpanded')
73
69
  get expandedClass() {
74
70
  if (!this.hasChildren) {
75
71
  return undefined;
76
72
  }
77
73
 
78
- if (get(this, 'model.isExpanded')) {
74
+ if (get(this, 'args.model.isExpanded')) {
79
75
  return 'list__cell_arrow_expanded';
80
76
  } else {
81
77
  return 'list__cell_arrow_collapsed';
82
78
  }
83
79
  }
84
80
 
85
- @gt('model.children.length', 0)
81
+ @gt('args.model.children.length', 0)
86
82
  hasChildren;
87
83
 
88
- @computed('model.{isFulfilled,isRejected,reason,value}')
84
+ @computed('args.model.{isFulfilled,isRejected,reason,value}')
89
85
  get settledValue() {
90
- if (get(this, 'model.isFulfilled')) {
91
- return get(this, 'model.value');
92
- } else if (get(this, 'model.isRejected')) {
93
- return get(this, 'model.reason');
86
+ if (get(this, 'args.model.isFulfilled')) {
87
+ return get(this, 'args.model.value');
88
+ } else if (get(this, 'args.model.isRejected')) {
89
+ return get(this, 'args.model.reason');
94
90
  } else {
95
91
  return '--';
96
92
  }
@@ -99,32 +95,32 @@ export default class PromiseItem extends Component {
99
95
  @notEmpty('settledValue.objectId')
100
96
  isValueInspectable;
101
97
 
102
- @computed('model.isSettled', 'settledValue.type')
98
+ @computed('args.model.isSettled', 'settledValue.type')
103
99
  get hasValue() {
104
100
  return (
105
- get(this, 'model.isSettled') &&
101
+ get(this, 'args.model.isSettled') &&
106
102
  get(this, 'settledValue.type') !== 'type-undefined'
107
103
  );
108
104
  }
109
105
 
110
- @computed('model.{label,parent}')
106
+ @computed('args.model.{label,parent}')
111
107
  get label() {
112
108
  return (
113
- get(this, 'model.label') ||
114
- (!!get(this, 'model.parent') && 'Then') ||
109
+ get(this, 'args.model.label') ||
110
+ (!!get(this, 'args.model.parent') && 'Then') ||
115
111
  '<Unknown Promise>'
116
112
  );
117
113
  }
118
114
 
119
- @computed('model.{parent.isSettled,isFulfilled,isRejected,state}')
115
+ @computed('args.model.{parent.isSettled,isFulfilled,isRejected,state}')
120
116
  get state() {
121
- if (get(this, 'model.isFulfilled')) {
117
+ if (get(this, 'args.model.isFulfilled')) {
122
118
  return 'Fulfilled';
123
- } else if (get(this, 'model.isRejected')) {
119
+ } else if (get(this, 'args.model.isRejected')) {
124
120
  return 'Rejected';
125
121
  } else if (
126
- get(this, 'model.parent') &&
127
- !get(this, 'model.parent.isSettled')
122
+ get(this, 'args.model.parent') &&
123
+ !get(this, 'args.model.parent.isSettled')
128
124
  ) {
129
125
  return 'Waiting for parent';
130
126
  } else {
@@ -132,15 +128,19 @@ export default class PromiseItem extends Component {
132
128
  }
133
129
  }
134
130
 
135
- @computed('model.{createdAt,settledAt,parent.settledAt}')
131
+ @computed('args.model.{createdAt,settledAt,parent.settledAt}')
136
132
  get timeToSettle() {
137
- if (!get(this, 'model.createdAt') || !get(this, 'model.settledAt')) {
133
+ if (
134
+ !get(this, 'args.model.createdAt') ||
135
+ !get(this, 'args.model.settledAt')
136
+ ) {
138
137
  return ' -- ';
139
138
  }
140
139
  let startedAt =
141
- get(this, 'model.parent.settledAt') || get(this, 'model.createdAt');
140
+ get(this, 'args.model.parent.settledAt') ||
141
+ get(this, 'args.model.createdAt');
142
142
  let remaining =
143
- get(this, 'model.settledAt').getTime() - startedAt.getTime();
143
+ get(this, 'args.model.settledAt').getTime() - startedAt.getTime();
144
144
  return remaining;
145
145
  }
146
146
  }
@@ -1,21 +1,19 @@
1
- import { tagName } from '@ember-decorators/component';
2
1
  import { computed, get } from '@ember/object';
3
- import Component from '@ember/component';
2
+ import Component from '@glimmer/component';
4
3
  import { htmlSafe } from '@ember/template';
5
4
  import checkCurrentRoute from 'ember-inspector/utils/check-current-route';
6
5
 
7
- @tagName('')
8
6
  export default class RouteCellName extends Component {
9
- @computed('route.parentCount')
7
+ @computed('args.route.parentCount')
10
8
  get labelStyle() {
11
9
  return htmlSafe(
12
- `padding-left: ${+get(this, 'route.parentCount') * 20 + 5}px;`
10
+ `padding-left: ${+get(this, 'args.route.parentCount') * 20 + 5}px;`
13
11
  );
14
12
  }
15
13
 
16
- @computed('currentRoute.{name,url}', 'route.value.{name,url}')
14
+ @computed('args.currentRoute.{name,url}', 'args.route.value.{name,url}')
17
15
  get isCurrent() {
18
- const { currentRoute, route } = this;
16
+ const { currentRoute, route } = this.args;
19
17
 
20
18
  if (!currentRoute || !route) {
21
19
  return false;
@@ -3,7 +3,7 @@
3
3
  "packages": [
4
4
  {
5
5
  "name": "ember-cli",
6
- "version": "4.4.0",
6
+ "version": "4.6.0",
7
7
  "blueprints": [
8
8
  {
9
9
  "name": "app",
@@ -12,23 +12,6 @@ module.exports = function() {
12
12
  return {
13
13
  useYarn: true,
14
14
  scenarios: [
15
- // TODO: Figure out how to test these versions
16
- // {
17
- // name: 'ember-lts-3.4',
18
- // npm: {
19
- // devDependencies: {
20
- // 'ember-source': '~3.4.0'
21
- // }
22
- // }
23
- // },
24
- // {
25
- // name: 'ember-lts-3.8',
26
- // npm: {
27
- // devDependencies: {
28
- // 'ember-source': '~3.8.0'
29
- // }
30
- // }
31
- // },
32
15
  {
33
16
  name: 'ember-lts-3.12',
34
17
  npm: {
@@ -14,15 +14,8 @@ module.exports = function (environment) {
14
14
  EmberENV: {
15
15
  FEATURES: {
16
16
  // Here you can enable experimental features on an ember canary build
17
- // e.g. EMBER_MODULE_UNIFICATION: true
18
- EMBER_METAL_TRACKED_PROPERTIES: true,
17
+ // e.g. EMBER_NATIVE_DECORATOR_SUPPORT: true
19
18
  },
20
- EXTEND_PROTOTYPES: process.env.NO_EXTEND_PROTOTYPES
21
- ? false
22
- : {
23
- // Prevent Ember Data from overriding Date.parse.
24
- Date: false,
25
- },
26
19
  },
27
20
 
28
21
  APP: {