ember-inspector 4.4.1 → 4.5.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.
- package/.eslintignore +1 -0
- package/.eslintrc.js +20 -12
- package/.github/workflows/build.yml +1 -0
- package/.tool-versions +1 -0
- package/CHANGELOG.md +31 -2
- package/app/{templates → components}/component-tree-toolbar.hbs +5 -5
- package/app/{templates → components}/container-type-toolbar.hbs +3 -3
- package/app/{templates/container-types/index-toolbar.hbs → components/container-types-toolbar.hbs} +2 -2
- package/app/components/date-property-field.js +4 -10
- package/app/{templates → components}/deprecations-toolbar.hbs +4 -4
- package/app/{templates → components}/libraries-toolbar.hbs +0 -0
- package/app/{templates → components}/model-types-toolbar.hbs +4 -4
- package/app/{templates → components}/promise-tree-toolbar.hbs +13 -13
- package/app/components/records-toolbar.hbs +26 -0
- package/app/components/render-tree-toolbar.hbs +33 -0
- package/app/components/route-cell-name.js +1 -1
- package/app/{templates → components}/route-tree-toolbar.hbs +3 -3
- package/app/components/scroll-container.js +3 -1
- package/app/computed/debounce.js +1 -3
- package/app/controllers/deprecations.js +1 -0
- package/app/controllers/render-tree.js +19 -4
- package/app/controllers/route-tree.js +51 -44
- package/app/initializers/setup.js +7 -18
- package/app/models/promise.js +3 -4
- package/app/routes/application.js +2 -14
- package/app/routes/component-tree.js +3 -0
- package/app/routes/deprecations.js +4 -0
- package/app/routes/launch.js +1 -0
- package/app/routes/libraries.js +1 -0
- package/app/routes/promise-tree.js +6 -0
- package/app/routes/render-tree.js +27 -10
- package/app/routes/route-tree.js +3 -2
- package/app/routes/tab.js +9 -9
- package/app/routes/whats-new.js +2 -0
- package/app/{adapters → services/adapters}/basic.js +3 -3
- package/app/{adapters → services/adapters}/bookmarklet.js +0 -0
- package/app/{adapters → services/adapters}/chrome.js +0 -0
- package/app/{adapters → services/adapters}/firefox.js +0 -0
- package/app/{adapters → services/adapters}/web-extension.js +0 -0
- package/app/{adapters → services/adapters}/websocket.js +0 -0
- package/app/services/port.js +3 -2
- package/app/templates/application.hbs +1 -1
- package/app/templates/component-tree.hbs +20 -4
- package/app/templates/container-type.hbs +10 -0
- package/app/templates/container-types/index.hbs +10 -0
- package/app/templates/deprecations.hbs +13 -10
- package/app/templates/libraries.hbs +12 -11
- package/app/templates/model-types.hbs +15 -2
- package/app/templates/promise-tree.hbs +22 -7
- package/app/templates/records.hbs +15 -7
- package/app/templates/render-tree.hbs +32 -9
- package/app/templates/route-tree.hbs +23 -14
- package/app/templates/whats-new.hbs +8 -4
- package/config/ember-cli-update.json +1 -1
- package/config/ember-try.js +8 -0
- package/config/targets.js +14 -6
- package/dist/bookmarklet/panes-3-4-0/assets/chunk.143.701794df61367d9c0beb.js +146 -0
- package/dist/bookmarklet/panes-3-4-0/assets/chunk.178.1fa501a69a8888639ff4.js +20 -0
- package/dist/bookmarklet/panes-3-4-0/assets/chunk.916.cfdae71ef87e943d7ad0.js +505 -0
- package/dist/bookmarklet/panes-3-4-0/assets/chunk.916.cfdae71ef87e943d7ad0.js.LICENSE.txt +8 -0
- package/dist/bookmarklet/panes-3-4-0/assets/ember-inspector.js +617 -1512
- package/dist/bookmarklet/panes-3-4-0/assets/vendor.css +9 -2
- package/dist/bookmarklet/panes-3-4-0/assets/vendor.js +6132 -7501
- package/dist/bookmarklet/panes-3-4-0/ember_debug.js +731 -416
- package/dist/bookmarklet/panes-3-4-0/index.html +2 -1
- package/dist/chrome/manifest.json +1 -1
- package/dist/chrome/panes-3-4-0/assets/chunk.143.701794df61367d9c0beb.js +146 -0
- package/dist/chrome/panes-3-4-0/assets/chunk.178.1fa501a69a8888639ff4.js +20 -0
- package/dist/chrome/panes-3-4-0/assets/chunk.916.cfdae71ef87e943d7ad0.js +505 -0
- package/dist/chrome/panes-3-4-0/assets/chunk.916.cfdae71ef87e943d7ad0.js.LICENSE.txt +8 -0
- package/dist/chrome/panes-3-4-0/assets/ember-inspector.js +617 -1512
- package/dist/chrome/panes-3-4-0/assets/vendor.css +9 -2
- package/dist/chrome/panes-3-4-0/assets/vendor.js +6132 -7501
- package/dist/chrome/panes-3-4-0/ember_debug.js +731 -416
- package/dist/chrome/panes-3-4-0/index.html +2 -1
- package/dist/firefox/manifest.json +1 -1
- package/dist/firefox/panes-3-4-0/assets/chunk.143.701794df61367d9c0beb.js +146 -0
- package/dist/firefox/panes-3-4-0/assets/chunk.178.1fa501a69a8888639ff4.js +20 -0
- package/dist/firefox/panes-3-4-0/assets/chunk.916.cfdae71ef87e943d7ad0.js +505 -0
- package/dist/firefox/panes-3-4-0/assets/chunk.916.cfdae71ef87e943d7ad0.js.LICENSE.txt +8 -0
- package/dist/firefox/panes-3-4-0/assets/ember-inspector.js +617 -1512
- package/dist/firefox/panes-3-4-0/assets/vendor.css +9 -2
- package/dist/firefox/panes-3-4-0/assets/vendor.js +6132 -7501
- package/dist/firefox/panes-3-4-0/ember_debug.js +731 -416
- package/dist/firefox/panes-3-4-0/index.html +2 -1
- package/dist/websocket/assets/chunk.143.701794df61367d9c0beb.js +146 -0
- package/dist/websocket/assets/chunk.178.1fa501a69a8888639ff4.js +20 -0
- package/dist/websocket/assets/chunk.916.cfdae71ef87e943d7ad0.js +505 -0
- package/dist/websocket/assets/chunk.916.cfdae71ef87e943d7ad0.js.LICENSE.txt +8 -0
- package/dist/websocket/assets/ember-inspector.js +617 -1512
- package/dist/websocket/assets/vendor.css +9 -2
- package/dist/websocket/assets/vendor.js +6132 -7501
- package/dist/websocket/ember_debug.js +731 -416
- package/dist/websocket/index.html +2 -1
- package/ember_debug/adapters/basic.js +4 -3
- package/ember_debug/adapters/web-extension.js +2 -1
- package/ember_debug/adapters/websocket.js +4 -7
- package/ember_debug/container-debug.js +2 -3
- package/ember_debug/data-debug.js +4 -3
- package/ember_debug/deprecation-debug.js +12 -15
- package/ember_debug/general-debug.js +3 -4
- package/ember_debug/libs/promise-assembler.js +12 -14
- package/ember_debug/libs/source-map.js +3 -8
- package/ember_debug/main.js +11 -11
- package/ember_debug/mixins/port-mixin.js +1 -3
- package/ember_debug/models/profile-manager.js +135 -3
- package/ember_debug/models/profile-node.js +2 -4
- package/ember_debug/models/promise.js +3 -4
- package/ember_debug/object-inspector.js +15 -19
- package/ember_debug/port.js +7 -5
- package/ember_debug/promise-debug.js +16 -17
- package/ember_debug/render-debug.js +11 -4
- package/ember_debug/route-debug.js +5 -10
- package/ember_debug/services/session.js +1 -3
- package/ember_debug/utils/ember/application.js +11 -0
- package/ember_debug/utils/ember/array/index.js +11 -0
- package/ember_debug/utils/ember/array/mutable.js +11 -0
- package/ember_debug/utils/ember/array/proxy.js +11 -0
- package/ember_debug/utils/ember/component.js +11 -0
- package/ember_debug/utils/ember/debug.js +15 -0
- package/ember_debug/utils/{ember.js → ember/index.js} +1 -0
- package/ember_debug/utils/ember/instrumentation.js +11 -0
- package/ember_debug/utils/ember/object/computed.js +11 -0
- package/ember_debug/utils/ember/object/evented.js +11 -0
- package/ember_debug/utils/ember/object/index.js +15 -0
- package/ember_debug/utils/ember/object/internals.js +11 -0
- package/ember_debug/utils/ember/object/mixin.js +11 -0
- package/ember_debug/utils/ember/object/observable.js +11 -0
- package/ember_debug/utils/ember/object/promise-proxy-mixin.js +13 -0
- package/ember_debug/utils/ember/runloop.js +17 -0
- package/ember_debug/utils/ember/utils.js +11 -0
- package/ember_debug/utils/rsvp.js +14 -0
- package/ember_debug/vendor/startup-wrapper.js +21 -12
- package/ember_debug/view-debug.js +2 -3
- package/package.json +43 -37
- package/tests/acceptance/app-picker-test.js +3 -3
- package/tests/acceptance/component-tree-test.js +17 -3
- package/tests/acceptance/container-test.js +8 -6
- package/tests/acceptance/data-test.js +2 -0
- package/tests/acceptance/deprecation-test.js +4 -0
- package/tests/acceptance/object-inspector-test.js +29 -1
- package/tests/acceptance/promise-test.js +11 -1
- package/tests/acceptance/route-tree-test.js +10 -0
- package/tests/acceptance/whats-new-test.js +1 -1
- package/tests/ember_debug/ember-debug-test.js +2 -0
- package/tests/ember_debug/object-inspector-test.js +54 -22
- package/tests/ember_debug/profile-manager-test.js +563 -6
- package/tests/ember_debug/profile-node-test.js +5 -5
- package/tests/ember_debug/promise-assembler-test.js +2 -0
- package/tests/ember_debug/promise-debug-test.js +7 -5
- package/tests/ember_debug/render-debug-test.js +1 -1
- package/tests/ember_debug/view-debug-test.js +8 -8
- package/tests/helpers/setup-ember-debug-test.js +11 -6
- package/tests/index.html +8 -1
- package/tests/integration/components/component-tree-arg-test.js +1 -1
- package/tests/test-adapter.js +1 -1
- package/tests/test-helper.js +5 -1
- package/tests/unit/check-current-route-test.js +4 -0
- package/tests/unit/is-route-substate-test.js +8 -8
- package/tests/unit/match-test.js +2 -2
- package/app/templates/records-toolbar.hbs +0 -26
- package/app/templates/render-tree-toolbar.hbs +0 -20
- package/tests/.eslintrc.js +0 -8
package/.eslintignore
CHANGED
package/.eslintrc.js
CHANGED
|
@@ -50,18 +50,17 @@ module.exports = {
|
|
|
50
50
|
// node files
|
|
51
51
|
{
|
|
52
52
|
files: [
|
|
53
|
-
'.
|
|
54
|
-
'.
|
|
55
|
-
'.
|
|
56
|
-
'.
|
|
57
|
-
'
|
|
58
|
-
'
|
|
59
|
-
'
|
|
60
|
-
'
|
|
61
|
-
'
|
|
62
|
-
'
|
|
63
|
-
'
|
|
64
|
-
'server/**/*.js',
|
|
53
|
+
'./.eslintrc.js',
|
|
54
|
+
'./.prettierrc.js',
|
|
55
|
+
'./.stylelintrc.js',
|
|
56
|
+
'./.template-lintrc.js',
|
|
57
|
+
'./ember-cli-build.js',
|
|
58
|
+
'./testem.js',
|
|
59
|
+
'./blueprints/*/index.js',
|
|
60
|
+
'./config/**/*.js',
|
|
61
|
+
'./lib/*/index.js',
|
|
62
|
+
'./scripts/**/*.js',
|
|
63
|
+
'./server/**/*.js',
|
|
65
64
|
],
|
|
66
65
|
excludedFiles: ['app/**'],
|
|
67
66
|
parserOptions: {
|
|
@@ -79,5 +78,14 @@ module.exports = {
|
|
|
79
78
|
'node/no-unpublished-require': 'off',
|
|
80
79
|
},
|
|
81
80
|
},
|
|
81
|
+
{
|
|
82
|
+
// Test files:
|
|
83
|
+
files: ['tests/**/*-test.{js,ts}'],
|
|
84
|
+
extends: ['plugin:qunit/recommended'],
|
|
85
|
+
rules: {
|
|
86
|
+
'qunit/no-conditional-assertions': 'off',
|
|
87
|
+
'qunit/no-early-return': 'off',
|
|
88
|
+
},
|
|
89
|
+
},
|
|
82
90
|
],
|
|
83
91
|
};
|
package/.tool-versions
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
nodejs 14.16.0
|
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,34 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
## v4.5.0 (2021-11-02)
|
|
5
|
+
|
|
6
|
+
#### :rocket: Enhancement
|
|
7
|
+
* [#1730](https://github.com/emberjs/ember-inspector/pull/1730) Update ember-flatpickr ([@rwwagner90](https://github.com/rwwagner90))
|
|
8
|
+
* [#1685](https://github.com/emberjs/ember-inspector/pull/1685) add highlight render option to Render Performance tab ([@michaelbdai](https://github.com/michaelbdai))
|
|
9
|
+
|
|
10
|
+
#### :bug: Bug Fix
|
|
11
|
+
* [#1760](https://github.com/emberjs/ember-inspector/pull/1760) Don't rely on Ember.EmberInspectorDebugger ([@sandstrom](https://github.com/sandstrom))
|
|
12
|
+
|
|
13
|
+
#### :house: Internal
|
|
14
|
+
* [#1759](https://github.com/emberjs/ember-inspector/pull/1759) Fix release-it-lerna-changelog ([@rwwagner90](https://github.com/rwwagner90))
|
|
15
|
+
* [#1750](https://github.com/emberjs/ember-inspector/pull/1750) fixed all the beta build test failures ([@michaelbdai](https://github.com/michaelbdai))
|
|
16
|
+
* [#1733](https://github.com/emberjs/ember-inspector/pull/1733) Recreate yarn.lock ([@rwwagner90](https://github.com/rwwagner90))
|
|
17
|
+
* [#1741](https://github.com/emberjs/ember-inspector/pull/1741) Fix build ([@chancancode](https://github.com/chancancode))
|
|
18
|
+
* [#1731](https://github.com/emberjs/ember-inspector/pull/1731) Fix deprecated use of `run.debounce` ([@chancancode](https://github.com/chancancode))
|
|
19
|
+
* [#1714](https://github.com/emberjs/ember-inspector/pull/1714) Use forks of packages ([@rwwagner90](https://github.com/rwwagner90))
|
|
20
|
+
* [#1727](https://github.com/emberjs/ember-inspector/pull/1727) Refactor legacy/bespoke injection patterns into services ([@chancancode](https://github.com/chancancode))
|
|
21
|
+
* [#1695](https://github.com/emberjs/ember-inspector/pull/1695) Update ember-test-selectors ([@rwwagner90](https://github.com/rwwagner90))
|
|
22
|
+
* [#1683](https://github.com/emberjs/ember-inspector/pull/1683) Remove toolbar outlet, remove more global Ember ([@rwwagner90](https://github.com/rwwagner90))
|
|
23
|
+
* [#1680](https://github.com/emberjs/ember-inspector/pull/1680) ember-cli 3.27, fix some lint ([@rwwagner90](https://github.com/rwwagner90))
|
|
24
|
+
* [#1619](https://github.com/emberjs/ember-inspector/pull/1619) Move changelog heading to top ([@sandstrom](https://github.com/sandstrom))
|
|
25
|
+
|
|
26
|
+
#### Committers: 4
|
|
27
|
+
- Bing Dai ([@michaelbdai](https://github.com/michaelbdai))
|
|
28
|
+
- Godfrey Chan ([@chancancode](https://github.com/chancancode))
|
|
29
|
+
- Robert Wagner ([@rwwagner90](https://github.com/rwwagner90))
|
|
30
|
+
- [@sandstrom](https://github.com/sandstrom)
|
|
31
|
+
|
|
1
32
|
## v4.4.1 (2021-05-25)
|
|
2
33
|
|
|
3
34
|
#### :bug: Bug Fix
|
|
@@ -75,8 +106,6 @@
|
|
|
75
106
|
- [@dependabot-preview[bot]](https://github.com/apps/dependabot-preview)
|
|
76
107
|
- [@patricklx](https://github.com/patricklx)
|
|
77
108
|
|
|
78
|
-
# Changelog
|
|
79
|
-
|
|
80
109
|
## [v4.1.0](https://github.com/emberjs/ember-inspector/tree/v4.1.0) (2020-05-12)
|
|
81
110
|
|
|
82
111
|
[Full Changelog](https://github.com/emberjs/ember-inspector/compare/v4.0.1...v4.1.0)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<div class="toolbar">
|
|
2
2
|
<button
|
|
3
|
-
class="{{if
|
|
4
|
-
{{on "click"
|
|
3
|
+
class="{{if @isInspecting "active"}} toolbar__icon-button"
|
|
4
|
+
{{on "click" @toggleInspect}}
|
|
5
5
|
type="button"
|
|
6
6
|
>
|
|
7
7
|
{{svg-jar "inspect" width="16px" height="17px"}}
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<button
|
|
13
13
|
class="toolbar__icon-button"
|
|
14
14
|
title="expand all"
|
|
15
|
-
{{on "click"
|
|
15
|
+
{{on "click" @expandAll}}
|
|
16
16
|
type="button"
|
|
17
17
|
>
|
|
18
18
|
{{svg-jar "chevron-down" width="16px" height="16px"}}
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
<button
|
|
22
22
|
class="toolbar__icon-button"
|
|
23
23
|
title="collapse all"
|
|
24
|
-
{{on "click"
|
|
24
|
+
{{on "click" @collapseAll}}
|
|
25
25
|
type="button"
|
|
26
26
|
>
|
|
27
27
|
{{svg-jar "chevron-right" width="16px" height="16px"}}
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
<Ui::ToolbarDivider />
|
|
31
31
|
|
|
32
32
|
<Ui::ToolbarSearchField
|
|
33
|
-
@value={{
|
|
33
|
+
@value={{@query}}
|
|
34
34
|
data-test-filter-views
|
|
35
35
|
/>
|
|
36
36
|
</div>
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
<div class="toolbar">
|
|
2
2
|
<Ui::ToolbarReloadButton
|
|
3
|
-
@action={{
|
|
3
|
+
@action={{@reload}}
|
|
4
4
|
data-test-reload-container-btn
|
|
5
5
|
/>
|
|
6
6
|
|
|
7
7
|
<Ui::ToolbarDivider />
|
|
8
8
|
|
|
9
|
-
<Ui::SendToConsole @action={{
|
|
9
|
+
<Ui::SendToConsole @action={{@sendContainerToConsole}} />
|
|
10
10
|
|
|
11
11
|
<Ui::ToolbarDivider />
|
|
12
12
|
|
|
13
13
|
<Ui::ToolbarSearchField
|
|
14
|
-
@value={{
|
|
14
|
+
@value={{@searchValue}}
|
|
15
15
|
data-test-container-instance-search
|
|
16
16
|
/>
|
|
17
17
|
</div>
|
package/app/{templates/container-types/index-toolbar.hbs → components/container-types-toolbar.hbs}
RENAMED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
<div class="toolbar">
|
|
2
2
|
<Ui::ToolbarReloadButton
|
|
3
|
-
@action={{
|
|
3
|
+
@action={{@reload}}
|
|
4
4
|
data-test-reload-container-btn
|
|
5
5
|
/>
|
|
6
6
|
|
|
7
7
|
<Ui::ToolbarDivider />
|
|
8
8
|
|
|
9
|
-
<Ui::SendToConsole @action={{
|
|
9
|
+
<Ui::SendToConsole @action={{@sendContainerToConsole}} />
|
|
10
10
|
</div>
|
|
@@ -1,21 +1,15 @@
|
|
|
1
1
|
import { scheduleOnce } from '@ember/runloop';
|
|
2
|
+
import { action } from '@ember/object';
|
|
2
3
|
import DatePicker from 'ember-inspector/components/ember-flatpickr';
|
|
3
|
-
import { KEYS } from 'ember-inspector/utils/key-codes';
|
|
4
4
|
|
|
5
5
|
export default class DatePropertyFieldComponent extends DatePicker {
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
@action
|
|
7
|
+
onInsert(element) {
|
|
8
|
+
super.onInsert(element);
|
|
8
9
|
|
|
9
10
|
scheduleOnce('afterRender', this, this._openFlatpickr);
|
|
10
11
|
}
|
|
11
12
|
|
|
12
|
-
keyUp(e) {
|
|
13
|
-
if (e.keyCode === KEYS.escape) {
|
|
14
|
-
this.flatpickrRef.close();
|
|
15
|
-
}
|
|
16
|
-
return super.keyUp(...arguments);
|
|
17
|
-
}
|
|
18
|
-
|
|
19
13
|
_openFlatpickr() {
|
|
20
14
|
this.flatpickrRef.open();
|
|
21
15
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<div class="toolbar">
|
|
2
|
-
<Ui::ToolbarClearButton @action={{
|
|
2
|
+
<Ui::ToolbarClearButton @action={{@clear}} />
|
|
3
3
|
|
|
4
4
|
<Ui::ToolbarDivider />
|
|
5
5
|
|
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
<label title="Deprecation workflow">
|
|
8
8
|
<Input
|
|
9
9
|
@type="checkbox"
|
|
10
|
-
@checked={{
|
|
11
|
-
{{on "change"
|
|
10
|
+
@checked={{@toggleDeprecationWorkflow}}
|
|
11
|
+
{{on "change" @changeDeprecationWorkflow}}
|
|
12
12
|
/>
|
|
13
13
|
Toggle for Deprecation Workflow
|
|
14
14
|
</label>
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
<Ui::ToolbarDivider />
|
|
18
18
|
|
|
19
19
|
<Ui::ToolbarSearchField
|
|
20
|
-
@value={{
|
|
20
|
+
@value={{@searchValue}}
|
|
21
21
|
data-test-deprecations-search
|
|
22
22
|
/>
|
|
23
23
|
</div>
|
|
File without changes
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<div class="toolbar">
|
|
2
2
|
<Ui::ToolbarReloadButton
|
|
3
|
-
@action={{
|
|
3
|
+
@action={{@reload}}
|
|
4
4
|
data-test-reload-container-btn
|
|
5
5
|
/>
|
|
6
6
|
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
<Input
|
|
12
12
|
data-test-options-hideEmptyModelTypes
|
|
13
13
|
@type="checkbox"
|
|
14
|
-
@checked={{
|
|
14
|
+
@checked={{@hideEmptyModelTypes}}
|
|
15
15
|
/>
|
|
16
16
|
Hide Empty Model Types
|
|
17
17
|
</label>
|
|
@@ -21,12 +21,12 @@
|
|
|
21
21
|
<Input
|
|
22
22
|
data-test-options-orderByRecordCount
|
|
23
23
|
@type="checkbox"
|
|
24
|
-
@checked={{
|
|
24
|
+
@checked={{@orderByRecordCount}}
|
|
25
25
|
/>
|
|
26
26
|
Order Models By Record Count
|
|
27
27
|
</label>
|
|
28
28
|
</div>
|
|
29
|
-
<button class="toolbar__radio js-filter" {{on "click"
|
|
29
|
+
<button class="toolbar__radio js-filter" {{on "click" @getStore}} data-test-inspect-store type="button">
|
|
30
30
|
Inspect Store
|
|
31
31
|
</button>
|
|
32
32
|
</div>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<div class="toolbar">
|
|
2
2
|
<Ui::ToolbarClearButton
|
|
3
|
-
@action={{
|
|
3
|
+
@action={{@clear}}
|
|
4
4
|
class="js-clear-promises-btn"
|
|
5
5
|
/>
|
|
6
6
|
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
{{#unless shouldRefresh}}
|
|
9
9
|
<Ui::ToolbarDivider />
|
|
10
10
|
<Ui::ToolbarReloadButton
|
|
11
|
-
@action={{
|
|
11
|
+
@action={{@refreshPage}}
|
|
12
12
|
class="js-toolbar-page-refresh-btn"
|
|
13
13
|
/>
|
|
14
14
|
{{/unless}}
|
|
@@ -16,37 +16,37 @@
|
|
|
16
16
|
<Ui::ToolbarDivider />
|
|
17
17
|
|
|
18
18
|
<Ui::ToolbarSearchField
|
|
19
|
-
@value={{
|
|
19
|
+
@value={{@searchValue}}
|
|
20
20
|
class="js-promise-search"
|
|
21
21
|
/>
|
|
22
22
|
|
|
23
23
|
<Ui::ToolbarDivider />
|
|
24
24
|
|
|
25
25
|
<button
|
|
26
|
-
class="{{if (eq
|
|
27
|
-
{{on "click" (fn
|
|
26
|
+
class="{{if (eq @filter "all") "active"}} toolbar__radio toolbar__radio--first js-filter"
|
|
27
|
+
{{on "click" (fn @setFilter "all")}}
|
|
28
28
|
type="button"
|
|
29
29
|
>
|
|
30
30
|
All
|
|
31
31
|
</button>
|
|
32
32
|
|
|
33
33
|
<button
|
|
34
|
-
class="{{if (eq
|
|
35
|
-
{{on "click" (fn
|
|
34
|
+
class="{{if (eq @filter "rejected") "active"}} toolbar__radio js-filter"
|
|
35
|
+
{{on "click" (fn @setFilter "rejected")}}
|
|
36
36
|
type="button"
|
|
37
37
|
>
|
|
38
38
|
Rejected
|
|
39
39
|
</button>
|
|
40
40
|
<button
|
|
41
|
-
class="{{if (eq
|
|
42
|
-
{{on "click" (fn
|
|
41
|
+
class="{{if (eq @filter "pending") "active"}} toolbar__radio js-filter"
|
|
42
|
+
{{on "click" (fn @setFilter "pending")}}
|
|
43
43
|
type="button"
|
|
44
44
|
>
|
|
45
45
|
Pending
|
|
46
46
|
</button>
|
|
47
47
|
<button
|
|
48
|
-
class="{{if (eq
|
|
49
|
-
{{on "click" (fn
|
|
48
|
+
class="{{if (eq @filter "fulfilled") "active"}} toolbar__radio toolbar__radio--last js-filter"
|
|
49
|
+
{{on "click" (fn @setFilter "fullfilled")}}
|
|
50
50
|
type="button"
|
|
51
51
|
>
|
|
52
52
|
Fulfilled
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
<label>
|
|
59
59
|
<Input
|
|
60
60
|
@type="checkbox"
|
|
61
|
-
@checked={{
|
|
62
|
-
{{on "change" (fn
|
|
61
|
+
@checked={{@instrumentWithStack}}
|
|
62
|
+
{{on "change" (fn @updateInstrumentWithStack (not @instrumentWithStack))}}
|
|
63
63
|
/>
|
|
64
64
|
Trace promises
|
|
65
65
|
</label>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<div class="toolbar">
|
|
2
|
+
<Ui::ToolbarSearchField
|
|
3
|
+
@value={{@searchValue}}
|
|
4
|
+
class="js-records-search"
|
|
5
|
+
/>
|
|
6
|
+
|
|
7
|
+
<Ui::ToolbarDivider />
|
|
8
|
+
|
|
9
|
+
<button
|
|
10
|
+
class="{{if (is-empty @filterValue) "active"}} toolbar__radio js-filter"
|
|
11
|
+
{{on "click" (fn @setFilter "")}}
|
|
12
|
+
type="button"
|
|
13
|
+
>
|
|
14
|
+
All
|
|
15
|
+
</button>
|
|
16
|
+
|
|
17
|
+
{{#each @filters as |filter|}}
|
|
18
|
+
<button
|
|
19
|
+
class="{{if (eq @filterValue filter.name) "active"}} toolbar__radio js-filter"
|
|
20
|
+
{{on "click" (fn @setFilter filter.name)}}
|
|
21
|
+
type="button"
|
|
22
|
+
>
|
|
23
|
+
{{filter.desc}}
|
|
24
|
+
</button>
|
|
25
|
+
{{/each}}
|
|
26
|
+
</div>
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
<div class="toolbar">
|
|
2
|
+
<Ui::ToolbarClearButton
|
|
3
|
+
@action={{@clearProfiles}}
|
|
4
|
+
/>
|
|
5
|
+
|
|
6
|
+
{{#unless @showEmpty}}
|
|
7
|
+
<Ui::ToolbarDivider />
|
|
8
|
+
<Ui::ToolbarReloadButton
|
|
9
|
+
@action={{@refreshPage}}
|
|
10
|
+
class="js-toolbar-page-refresh-btn"
|
|
11
|
+
/>
|
|
12
|
+
{{/unless}}
|
|
13
|
+
|
|
14
|
+
<Ui::ToolbarDivider />
|
|
15
|
+
|
|
16
|
+
<Ui::ToolbarSearchField
|
|
17
|
+
@value={{@searchValue}}
|
|
18
|
+
class="js-render-profiles-search"
|
|
19
|
+
/>
|
|
20
|
+
{{#if @isHighlightEnabled}}
|
|
21
|
+
<div class="toolbar__checkbox js-hightlight-render">
|
|
22
|
+
<label>
|
|
23
|
+
<Input
|
|
24
|
+
data-test-options-highlight-render
|
|
25
|
+
@type="checkbox"
|
|
26
|
+
@checked={{@shouldHighlightRender}}
|
|
27
|
+
{{on "change" @updateShouldHighlightRender}}
|
|
28
|
+
/>
|
|
29
|
+
Highlight render
|
|
30
|
+
</label>
|
|
31
|
+
</div>
|
|
32
|
+
{{/if}}
|
|
33
|
+
</div>
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
<label>
|
|
4
4
|
<Input
|
|
5
5
|
@type="checkbox"
|
|
6
|
-
@checked={{
|
|
6
|
+
@checked={{@options.hideRoutes}}
|
|
7
7
|
/>
|
|
8
8
|
Current Route only
|
|
9
9
|
</label>
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
<label title="Hide loading and error substates">
|
|
14
14
|
<Input
|
|
15
15
|
@type="checkbox"
|
|
16
|
-
@checked={{
|
|
16
|
+
@checked={{@options.hideSubstates}}
|
|
17
17
|
/>
|
|
18
18
|
Hide Substates
|
|
19
19
|
</label>
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
<Ui::ToolbarDivider />
|
|
23
23
|
|
|
24
24
|
<Ui::ToolbarSearchField
|
|
25
|
-
@value={{
|
|
25
|
+
@value={{@searchValue}}
|
|
26
26
|
data-test-filter-views
|
|
27
27
|
/>
|
|
28
28
|
</div>
|
|
@@ -45,7 +45,7 @@ export default class ScrollContainerComponent extends Component {
|
|
|
45
45
|
}
|
|
46
46
|
|
|
47
47
|
get scrollTarget() {
|
|
48
|
-
return this.element
|
|
48
|
+
return this.element?.querySelector('.scroll-target');
|
|
49
49
|
}
|
|
50
50
|
|
|
51
51
|
didRender() {
|
|
@@ -74,6 +74,8 @@ export default class ScrollContainerComponent extends Component {
|
|
|
74
74
|
}
|
|
75
75
|
|
|
76
76
|
function needsScroll(container, target) {
|
|
77
|
+
if (!container || !target) return false;
|
|
78
|
+
|
|
77
79
|
let { top: containerTop, bottom: containerBottom } =
|
|
78
80
|
container.getBoundingClientRect();
|
|
79
81
|
let { top: targetTop, bottom: targetBottom } = target.getBoundingClientRect();
|
package/app/computed/debounce.js
CHANGED
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { debounce } from '@ember/runloop';
|
|
2
2
|
import { computed } from '@ember/object';
|
|
3
3
|
|
|
4
|
-
const { debounce } = run;
|
|
5
|
-
|
|
6
4
|
// Use this if you want a property to debounce
|
|
7
5
|
// another property with a certain delay.
|
|
8
6
|
// This means that every time this prop changes,
|
|
@@ -7,9 +7,12 @@ import debounceComputed from 'ember-inspector/computed/debounce';
|
|
|
7
7
|
import { and, equal } from '@ember/object/computed';
|
|
8
8
|
|
|
9
9
|
export default Controller.extend({
|
|
10
|
+
port: service(),
|
|
11
|
+
|
|
10
12
|
initialEmpty: false,
|
|
11
|
-
modelEmpty: equal('model.length', 0),
|
|
13
|
+
modelEmpty: equal('model.profiles.length', 0),
|
|
12
14
|
showEmpty: and('initialEmpty', 'modelEmpty'),
|
|
15
|
+
shouldHighlightRender: false,
|
|
13
16
|
|
|
14
17
|
/**
|
|
15
18
|
* Storage is needed for remembering if the user closed the warning
|
|
@@ -56,16 +59,20 @@ export default Controller.extend({
|
|
|
56
59
|
return escapeRegExp(this.search.toLowerCase());
|
|
57
60
|
}),
|
|
58
61
|
|
|
62
|
+
isHighlightEnabled: computed('model.isHighlightSupported', function () {
|
|
63
|
+
return get(this.model, 'isHighlightSupported');
|
|
64
|
+
}),
|
|
65
|
+
|
|
59
66
|
filtered: computed(
|
|
60
67
|
'escapedSearch',
|
|
61
|
-
'model.@each.name',
|
|
68
|
+
'model.profiles.@each.name',
|
|
62
69
|
'search',
|
|
63
70
|
function () {
|
|
64
71
|
if (isEmpty(this.escapedSearch)) {
|
|
65
|
-
return this.model;
|
|
72
|
+
return get(this.model, 'profiles');
|
|
66
73
|
}
|
|
67
74
|
|
|
68
|
-
return this.model.filter((item) => {
|
|
75
|
+
return get(this.model, 'profiles').filter((item) => {
|
|
69
76
|
const regExp = new RegExp(this.escapedSearch);
|
|
70
77
|
return recursiveMatch(item, regExp);
|
|
71
78
|
});
|
|
@@ -75,6 +82,14 @@ export default Controller.extend({
|
|
|
75
82
|
closeWarning: action(function () {
|
|
76
83
|
this.set('isWarningClosed', true);
|
|
77
84
|
}),
|
|
85
|
+
|
|
86
|
+
updateShouldHighlightRender: action(function () {
|
|
87
|
+
const value = !this.shouldHighlightRender;
|
|
88
|
+
this.set('shouldHighlightRender', value);
|
|
89
|
+
this.port.send('render:updateShouldHighlightRender', {
|
|
90
|
+
shouldHighlightRender: value,
|
|
91
|
+
});
|
|
92
|
+
}),
|
|
78
93
|
});
|
|
79
94
|
|
|
80
95
|
function recursiveMatch(item, regExp) {
|
|
@@ -6,45 +6,48 @@ import checkCurrentRoute from 'ember-inspector/utils/check-current-route';
|
|
|
6
6
|
import searchMatch from 'ember-inspector/utils/search-match';
|
|
7
7
|
import isRouteSubstate from 'ember-inspector/utils/is-route-substate';
|
|
8
8
|
|
|
9
|
-
export default Controller
|
|
10
|
-
application
|
|
11
|
-
port
|
|
9
|
+
export default class RouteTreeController extends Controller {
|
|
10
|
+
@controller application;
|
|
11
|
+
@service port;
|
|
12
12
|
|
|
13
|
-
queryParams
|
|
13
|
+
queryParams = ['hideRoutes'];
|
|
14
14
|
|
|
15
|
-
currentRoute
|
|
16
|
-
hideRoutes: alias('options.hideRoutes'),
|
|
17
|
-
searchValue: '',
|
|
15
|
+
currentRoute = null;
|
|
18
16
|
|
|
19
|
-
|
|
17
|
+
searchValue = '';
|
|
18
|
+
|
|
19
|
+
@alias('options.hideRoutes') hideRoutes;
|
|
20
|
+
|
|
21
|
+
@computed(
|
|
20
22
|
'model.[]',
|
|
21
23
|
'options.{hideRoutes,hideSubstates}',
|
|
22
24
|
'currentRoute.{name,url}',
|
|
23
|
-
'searchValue'
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
}
|
|
45
|
-
|
|
25
|
+
'searchValue'
|
|
26
|
+
)
|
|
27
|
+
get filtered() {
|
|
28
|
+
return this.model.filter((routeItem) => {
|
|
29
|
+
let currentRoute = this.currentRoute;
|
|
30
|
+
let hideRoutes = this.get('options.hideRoutes');
|
|
31
|
+
let hideSubstates = this.get('options.hideSubstates');
|
|
32
|
+
|
|
33
|
+
if (hideRoutes && currentRoute) {
|
|
34
|
+
return checkCurrentRoute(currentRoute, routeItem.value);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
if (hideSubstates && isRouteSubstate(routeItem.value.name)) {
|
|
38
|
+
return false;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
if (!searchMatch(routeItem.value.name, this.searchValue)) {
|
|
42
|
+
return false;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
return true;
|
|
46
|
+
});
|
|
47
|
+
}
|
|
46
48
|
|
|
47
|
-
|
|
49
|
+
@computed('filtered.[]')
|
|
50
|
+
get rows() {
|
|
48
51
|
return this.filtered.map(function (route) {
|
|
49
52
|
return {
|
|
50
53
|
name: route,
|
|
@@ -52,36 +55,40 @@ export default Controller.extend({
|
|
|
52
55
|
url: route,
|
|
53
56
|
};
|
|
54
57
|
});
|
|
55
|
-
}
|
|
58
|
+
}
|
|
56
59
|
|
|
57
60
|
init() {
|
|
58
|
-
|
|
61
|
+
super.init(...arguments);
|
|
59
62
|
|
|
60
63
|
set(this, 'model', []);
|
|
61
64
|
set(this, 'options', {
|
|
62
65
|
hideRoutes: false,
|
|
63
66
|
hideSubstates: false,
|
|
64
67
|
});
|
|
65
|
-
}
|
|
68
|
+
}
|
|
66
69
|
|
|
67
|
-
|
|
70
|
+
@action
|
|
71
|
+
inspectRoute(name) {
|
|
68
72
|
this.port.send('objectInspector:inspectRoute', { name });
|
|
69
|
-
}
|
|
73
|
+
}
|
|
70
74
|
|
|
71
|
-
|
|
75
|
+
@action
|
|
76
|
+
sendRouteHandlerToConsole(name) {
|
|
72
77
|
this.port.send('objectInspector:sendRouteHandlerToConsole', { name });
|
|
73
|
-
}
|
|
78
|
+
}
|
|
74
79
|
|
|
75
|
-
|
|
80
|
+
@action
|
|
81
|
+
inspectController(controller) {
|
|
76
82
|
if (!controller.exists) {
|
|
77
83
|
return;
|
|
78
84
|
}
|
|
79
85
|
this.port.send('objectInspector:inspectController', {
|
|
80
86
|
name: controller.name,
|
|
81
87
|
});
|
|
82
|
-
}
|
|
88
|
+
}
|
|
83
89
|
|
|
84
|
-
|
|
90
|
+
@action
|
|
91
|
+
sendControllerToConsole(name) {
|
|
85
92
|
this.port.send('objectInspector:sendControllerToConsole', { name });
|
|
86
|
-
}
|
|
87
|
-
}
|
|
93
|
+
}
|
|
94
|
+
}
|