ember-inspector 4.13.1 → 4.15.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/.ember-cli +1 -9
- package/.github/workflows/build.yml +33 -112
- package/.github/workflows/plan-release.yml +26 -48
- package/.github/workflows/publish.yml +129 -31
- package/.prettierignore +2 -13
- package/.prettierrc.js +10 -4
- package/.release-plan.json +13 -4
- package/.stylelintignore +8 -0
- package/.stylelintrc.js +10 -1
- package/.template-lintrc.js +2 -1
- package/.tool-versions +2 -2
- package/.watchmanconfig +1 -1
- package/CHANGELOG.md +137 -0
- package/DEVELOPMENT.md +50 -0
- package/PRIVACY.md +3 -0
- package/README.md +14 -50
- package/RELEASE.md +15 -50
- package/app/components/app-picker.hbs +2 -2
- package/app/components/component-tree-item.hbs +14 -14
- package/app/components/component-tree-toolbar.hbs +17 -3
- package/app/components/{date-property-field.js → date-property-field.ts} +6 -5
- package/app/components/deprecation-item-source.hbs +1 -1
- package/app/components/deprecation-item.hbs +1 -1
- package/app/components/deprecations-toolbar.hbs +1 -1
- package/app/components/item-types.hbs +7 -7
- package/app/components/list-cell.hbs +3 -3
- package/app/components/list-content.hbs +4 -3
- package/app/components/list-content.ts +96 -0
- package/app/components/list.hbs +3 -3
- package/app/components/list.js +7 -7
- package/app/components/model-types-toolbar.hbs +3 -3
- package/app/components/object-inspector/component-parents.hbs +33 -0
- package/app/components/object-inspector/component-parents.js +43 -0
- package/app/components/object-inspector/dependent-keys.hbs +4 -4
- package/app/components/object-inspector/errors.hbs +4 -4
- package/app/components/object-inspector/properties-all.hbs +1 -1
- package/app/components/object-inspector/properties-base.js +2 -0
- package/app/components/object-inspector/properties-grouped.hbs +5 -5
- package/app/components/object-inspector/property.hbs +36 -34
- package/app/components/object-inspector/property.ts +34 -17
- package/app/components/object-inspector/sort-properties.js +12 -4
- package/app/components/object-inspector/toggle.hbs +9 -0
- package/app/components/object-inspector/toggle.js +6 -0
- package/app/components/object-inspector.hbs +11 -9
- package/app/components/object-inspector.js +1 -1
- package/app/components/promise-item.hbs +11 -11
- package/app/components/promise-item.js +8 -6
- package/app/components/promise-tree-toolbar.hbs +5 -5
- package/app/components/records-toolbar.hbs +2 -2
- package/app/components/render-item.hbs +4 -4
- package/app/components/render-item.ts +12 -9
- package/app/components/render-tree-toolbar.hbs +1 -1
- package/app/components/route-cell-name.hbs +1 -1
- package/app/components/route-cell-name.js +3 -2
- package/app/components/route-tree-toolbar.hbs +2 -2
- package/app/components/scroll-container.js +2 -0
- package/app/components/side-nav.hbs +5 -5
- package/app/components/side-nav.js +1 -1
- package/{lib/ui/addon/components → app/components/ui}/drag-handle.hbs +4 -4
- package/{lib/ui/addon/components → app/components/ui}/drag-handle.js +3 -1
- package/{lib/ui/addon/components → app/components/ui}/empty-message.hbs +1 -1
- package/{lib/ui/addon/components → app/components/ui}/error-page.hbs +3 -3
- package/{lib/ui/addon/components → app/components/ui}/resizable-column.js +1 -1
- package/{lib/ui/addon/components → app/components/ui}/toolbar-clear-button.hbs +1 -1
- package/{lib/ui/addon/components → app/components/ui}/toolbar-reload-button.hbs +1 -1
- package/{lib/ui/addon/components → app/components/ui}/toolbar-search-field.hbs +2 -2
- package/app/computed/{debounce.js → debounce.ts} +7 -5
- package/app/config/environment.d.ts +5 -2
- package/app/controllers/app-config.js +1 -0
- package/app/controllers/application.js +36 -71
- package/app/controllers/component-tree.js +26 -7
- package/app/controllers/container-type.js +2 -1
- package/app/controllers/container-types/{index.js → index.ts} +5 -2
- package/app/controllers/container-types.js +3 -6
- package/app/controllers/deprecations.js +16 -11
- package/app/controllers/libraries.js +1 -0
- package/app/controllers/model-types.js +7 -13
- package/app/controllers/promise-tree.ts +149 -0
- package/app/controllers/records.js +18 -26
- package/app/controllers/{render-tree.js → render-tree.ts} +54 -45
- package/app/controllers/route-tree.js +7 -5
- package/app/helpers/build-style.js +1 -1
- package/app/index.html +1 -19
- package/app/initializers/setup.js +1 -1
- package/app/libs/promise-assembler.ts +249 -0
- package/app/libs/resizable-columns.js +10 -10
- package/app/models/{promise.js → promise.ts} +72 -69
- package/app/{router.js → router.ts} +1 -1
- package/app/routes/app-detected.js +3 -5
- package/app/routes/application.js +9 -13
- package/app/routes/deprecations.js +7 -16
- package/app/routes/launch.js +2 -1
- package/app/routes/libraries.js +2 -1
- package/app/routes/model-type.js +2 -3
- package/app/routes/model-types.ts +57 -0
- package/app/routes/promise-tree.ts +63 -0
- package/app/routes/records.ts +78 -0
- package/app/routes/render-tree.ts +93 -0
- package/app/routes/route-tree.js +0 -1
- package/app/routes/{tab.js → tab.ts} +9 -2
- package/app/routes/whats-new.js +6 -4
- package/app/services/adapters/{basic.js → basic.ts} +36 -30
- package/app/services/adapters/{bookmarklet.js → bookmarklet.ts} +17 -24
- package/app/services/adapters/{chrome.js → chrome.ts} +1 -2
- package/app/services/adapters/{web-extension.js → web-extension.ts} +46 -46
- package/app/services/adapters/websocket.ts +40 -0
- package/app/services/layout.ts +124 -0
- package/app/services/port.ts +195 -0
- package/app/services/storage/{local.js → local.ts} +7 -20
- package/app/services/storage/{memory.js → memory.ts} +6 -21
- package/app/services/{storage.js → storage.ts} +25 -23
- package/app/styles/app.scss +1 -0
- package/app/styles/base.scss +6 -2
- package/app/styles/colors.scss +33 -31
- package/app/styles/component_tree.scss +56 -51
- package/app/styles/dropdown.scss +2 -2
- package/app/styles/ember-table.scss +3 -3
- package/app/styles/mixin.scss +26 -26
- package/app/styles/object_inspector.scss +30 -21
- package/{lib/ui/addon/styles → app/styles/ui}/_disclosure-triangle.scss +3 -1
- package/{lib/ui/addon/styles → app/styles/ui}/_drag-handle.scss +7 -7
- package/{lib/ui/addon/styles → app/styles/ui}/_empty-message.scss +1 -1
- package/{lib/ui/addon/styles → app/styles/ui}/_error-page.scss +8 -7
- package/{lib/ui/addon/styles → app/styles/ui}/_list.scss +46 -45
- package/{lib/ui/addon/styles → app/styles/ui}/_nav.scss +29 -27
- package/app/styles/ui/_object-inspector-toggle.scss +4 -0
- package/{lib/ui/addon/styles → app/styles/ui}/_pill.scss +4 -4
- package/{lib/ui/addon/styles → app/styles/ui}/_send-to-console.scss +1 -1
- package/{lib/ui/addon/styles → app/styles/ui}/_split.scss +26 -20
- package/app/styles/ui/_ui.scss +13 -0
- package/{lib/ui/addon/styles → app/styles/ui}/toolbar/_checkbox.scss +5 -5
- package/app/styles/ui/toolbar/_icon-button.scss +80 -0
- package/{lib/ui/addon/styles → app/styles/ui}/toolbar/_index.scss +6 -5
- package/{lib/ui/addon/styles → app/styles/ui}/toolbar/_radio.scss +10 -10
- package/{lib/ui/addon/styles → app/styles/ui}/toolbar/_search.scss +5 -3
- package/app/styles/utils.scss +408 -122
- package/app/templates/application.hbs +22 -19
- package/app/templates/component-tree.hbs +4 -1
- package/app/templates/deprecations.hbs +2 -3
- package/app/templates/info.hbs +10 -10
- package/app/templates/promise-tree.hbs +1 -1
- package/app/templates/render-tree.hbs +1 -1
- package/app/templates/route-tree.hbs +1 -1
- package/app/utils/escape-reg-exp.ts +3 -2
- package/app/utils/nullish.ts +7 -0
- package/app/utils/parse-text.ts +4 -5
- package/app/utils/truncate.js +0 -1
- package/config/ember-cli-update.json +5 -3
- package/config/ember-try.js +117 -72
- package/config/environment.js +1 -1
- package/config/optional-features.json +2 -1
- package/dist/bookmarklet/load_inspector.js +31 -11
- package/dist/bookmarklet/panes-3-16-0/assets/chunk.443.86a005e528b587663b78.js +1135 -0
- package/dist/bookmarklet/panes-3-16-0/assets/chunk.443.86a005e528b587663b78.js.LICENSE.txt +18 -0
- package/dist/bookmarklet/panes-3-16-0/assets/chunk.524.aca67dc376e8cd35b522.js +40 -0
- package/dist/bookmarklet/panes-3-16-0/assets/chunk.582.d3d80e94c4f59dc3b65d.js +42 -0
- package/dist/bookmarklet/panes-3-16-0/assets/ember-inspector.css +997 -156
- package/dist/bookmarklet/panes-3-16-0/assets/ember-inspector.js +560 -613
- package/dist/bookmarklet/panes-3-16-0/assets/svg/ellipsis.svg +3 -3
- package/dist/bookmarklet/panes-3-16-0/assets/svg/focus-point-round.svg +9 -0
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-bug.svg +1 -1
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-components.svg +2 -2
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-container.svg +1 -1
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-data.svg +1 -1
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-deprecations.svg +3 -3
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-info.svg +3 -3
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-promises.svg +2 -2
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-render-performance.svg +2 -2
- package/dist/bookmarklet/panes-3-16-0/assets/svg/nav-route-tree.svg +7 -7
- package/dist/bookmarklet/panes-3-16-0/assets/svg/sidebar-toggle-trailing.svg +9 -0
- package/dist/bookmarklet/panes-3-16-0/assets/vendor.css +4 -841
- package/dist/bookmarklet/panes-3-16-0/assets/vendor.js +4277 -5152
- package/dist/bookmarklet/panes-3-16-0/base-object-HAEdWjmg.js +59 -0
- package/dist/bookmarklet/panes-3-16-0/basic-B1dkgN3d.js +149 -0
- package/dist/bookmarklet/panes-3-16-0/basic-debug.js +10 -0
- package/dist/bookmarklet/panes-3-16-0/bookmarklet-BZWtwuX-.js +32 -0
- package/dist/bookmarklet/panes-3-16-0/bookmarklet-debug.js +10 -0
- package/dist/bookmarklet/panes-3-16-0/chrome-P6FSEUf1.js +10 -0
- package/dist/bookmarklet/panes-3-16-0/chrome-debug.js +10 -0
- package/dist/bookmarklet/panes-3-16-0/ember.js +166 -0
- package/dist/bookmarklet/panes-3-16-0/ember_debug.js +7 -11018
- package/dist/bookmarklet/panes-3-16-0/evented-BCTya3yE.js +62 -0
- package/dist/bookmarklet/panes-3-16-0/firefox-8F84zphP.js +30 -0
- package/dist/bookmarklet/panes-3-16-0/firefox-debug.js +10 -0
- package/dist/bookmarklet/panes-3-16-0/index.html +4 -23
- package/dist/bookmarklet/panes-3-16-0/internals-CRmXMEzb.js +12 -0
- package/dist/bookmarklet/panes-3-16-0/load-ember-debug-in-webpage-DCWcJhQm.js +29 -0
- package/dist/bookmarklet/panes-3-16-0/main.js +7669 -0
- package/dist/bookmarklet/panes-3-16-0/port.js +108 -0
- package/dist/bookmarklet/panes-3-16-0/profile-node.js +60 -0
- package/dist/bookmarklet/panes-3-16-0/promise-assembler.js +218 -0
- package/dist/bookmarklet/panes-3-16-0/runloop-6_0lpzTA.js +1138 -0
- package/dist/bookmarklet/panes-3-16-0/start-inspector-BIYQArZn.js +334 -0
- package/dist/bookmarklet/panes-3-16-0/type-check.js +119 -0
- package/dist/bookmarklet/panes-3-16-0/version.js +90 -0
- package/dist/bookmarklet/panes-3-16-0/versions.js +4 -0
- package/dist/bookmarklet/panes-3-16-0/web-extension-OWnXJ_XK.js +144 -0
- package/dist/bookmarklet/panes-3-16-0/websocket-BSUvUqER.js +58 -0
- package/dist/bookmarklet/panes-3-16-0/websocket-debug.js +10 -0
- package/dist/chrome/background.js +26 -21
- package/dist/chrome/boot.js +1 -1
- package/dist/chrome/content-script.js +12 -11
- package/dist/chrome/devtools.js +12 -3
- package/dist/chrome/manifest.json +4 -2
- package/dist/chrome/options.js +17 -12
- package/dist/chrome/panes-3-16-0/assets/chunk.443.86a005e528b587663b78.js +1135 -0
- package/dist/chrome/panes-3-16-0/assets/chunk.443.86a005e528b587663b78.js.LICENSE.txt +18 -0
- package/dist/chrome/panes-3-16-0/assets/chunk.524.aca67dc376e8cd35b522.js +40 -0
- package/dist/chrome/panes-3-16-0/assets/chunk.582.d3d80e94c4f59dc3b65d.js +42 -0
- package/dist/chrome/panes-3-16-0/assets/ember-inspector.css +997 -156
- package/dist/chrome/panes-3-16-0/assets/ember-inspector.js +560 -613
- package/dist/chrome/panes-3-16-0/assets/svg/ellipsis.svg +3 -3
- package/dist/chrome/panes-3-16-0/assets/svg/focus-point-round.svg +9 -0
- package/dist/chrome/panes-3-16-0/assets/svg/nav-bug.svg +1 -1
- package/dist/chrome/panes-3-16-0/assets/svg/nav-components.svg +2 -2
- package/dist/chrome/panes-3-16-0/assets/svg/nav-container.svg +1 -1
- package/dist/chrome/panes-3-16-0/assets/svg/nav-data.svg +1 -1
- package/dist/chrome/panes-3-16-0/assets/svg/nav-deprecations.svg +3 -3
- package/dist/chrome/panes-3-16-0/assets/svg/nav-info.svg +3 -3
- package/dist/chrome/panes-3-16-0/assets/svg/nav-promises.svg +2 -2
- package/dist/chrome/panes-3-16-0/assets/svg/nav-render-performance.svg +2 -2
- package/dist/chrome/panes-3-16-0/assets/svg/nav-route-tree.svg +7 -7
- package/dist/chrome/panes-3-16-0/assets/svg/sidebar-toggle-trailing.svg +9 -0
- package/dist/chrome/panes-3-16-0/assets/vendor.css +4 -841
- package/dist/chrome/panes-3-16-0/assets/vendor.js +4277 -5152
- package/dist/chrome/panes-3-16-0/base-object-HAEdWjmg.js +59 -0
- package/dist/chrome/panes-3-16-0/basic-B1dkgN3d.js +149 -0
- package/dist/chrome/panes-3-16-0/basic-debug.js +10 -0
- package/dist/chrome/panes-3-16-0/bookmarklet-BZWtwuX-.js +32 -0
- package/dist/chrome/panes-3-16-0/bookmarklet-debug.js +10 -0
- package/dist/chrome/panes-3-16-0/chrome-P6FSEUf1.js +10 -0
- package/dist/chrome/panes-3-16-0/chrome-debug.js +10 -0
- package/dist/chrome/panes-3-16-0/ember.js +166 -0
- package/dist/chrome/panes-3-16-0/ember_debug.js +7 -11018
- package/dist/chrome/panes-3-16-0/evented-BCTya3yE.js +62 -0
- package/dist/chrome/panes-3-16-0/firefox-8F84zphP.js +30 -0
- package/dist/chrome/panes-3-16-0/firefox-debug.js +10 -0
- package/dist/chrome/panes-3-16-0/index.html +4 -23
- package/dist/chrome/panes-3-16-0/internals-CRmXMEzb.js +12 -0
- package/dist/chrome/panes-3-16-0/load-ember-debug-in-webpage-DCWcJhQm.js +29 -0
- package/dist/chrome/panes-3-16-0/main.js +7669 -0
- package/dist/chrome/panes-3-16-0/port.js +108 -0
- package/dist/chrome/panes-3-16-0/profile-node.js +60 -0
- package/dist/chrome/panes-3-16-0/promise-assembler.js +218 -0
- package/dist/chrome/panes-3-16-0/runloop-6_0lpzTA.js +1138 -0
- package/dist/chrome/panes-3-16-0/start-inspector-BIYQArZn.js +334 -0
- package/dist/chrome/panes-3-16-0/type-check.js +119 -0
- package/dist/chrome/panes-3-16-0/version.js +90 -0
- package/dist/chrome/panes-3-16-0/versions.js +4 -0
- package/dist/chrome/panes-3-16-0/web-extension-OWnXJ_XK.js +144 -0
- package/dist/chrome/panes-3-16-0/websocket-BSUvUqER.js +58 -0
- package/dist/chrome/panes-3-16-0/websocket-debug.js +10 -0
- package/dist/chrome/scripts/in-page-script.js +19 -13
- package/dist/firefox/background.js +26 -21
- package/dist/firefox/boot.js +1 -1
- package/dist/firefox/content-script.js +12 -11
- package/dist/firefox/devtools.js +12 -3
- package/dist/firefox/manifest.json +4 -2
- package/dist/firefox/options.js +17 -12
- package/dist/firefox/panes-3-16-0/assets/chunk.443.86a005e528b587663b78.js +1135 -0
- package/dist/firefox/panes-3-16-0/assets/chunk.443.86a005e528b587663b78.js.LICENSE.txt +18 -0
- package/dist/firefox/panes-3-16-0/assets/chunk.524.aca67dc376e8cd35b522.js +40 -0
- package/dist/firefox/panes-3-16-0/assets/chunk.582.d3d80e94c4f59dc3b65d.js +42 -0
- package/dist/firefox/panes-3-16-0/assets/ember-inspector.css +997 -156
- package/dist/firefox/panes-3-16-0/assets/ember-inspector.js +560 -613
- package/dist/firefox/panes-3-16-0/assets/svg/ellipsis.svg +3 -3
- package/dist/firefox/panes-3-16-0/assets/svg/focus-point-round.svg +9 -0
- package/dist/firefox/panes-3-16-0/assets/svg/nav-bug.svg +1 -1
- package/dist/firefox/panes-3-16-0/assets/svg/nav-components.svg +2 -2
- package/dist/firefox/panes-3-16-0/assets/svg/nav-container.svg +1 -1
- package/dist/firefox/panes-3-16-0/assets/svg/nav-data.svg +1 -1
- package/dist/firefox/panes-3-16-0/assets/svg/nav-deprecations.svg +3 -3
- package/dist/firefox/panes-3-16-0/assets/svg/nav-info.svg +3 -3
- package/dist/firefox/panes-3-16-0/assets/svg/nav-promises.svg +2 -2
- package/dist/firefox/panes-3-16-0/assets/svg/nav-render-performance.svg +2 -2
- package/dist/firefox/panes-3-16-0/assets/svg/nav-route-tree.svg +7 -7
- package/dist/firefox/panes-3-16-0/assets/svg/sidebar-toggle-trailing.svg +9 -0
- package/dist/firefox/panes-3-16-0/assets/vendor.css +4 -841
- package/dist/firefox/panes-3-16-0/assets/vendor.js +4277 -5152
- package/dist/firefox/panes-3-16-0/base-object-HAEdWjmg.js +59 -0
- package/dist/firefox/panes-3-16-0/basic-B1dkgN3d.js +149 -0
- package/dist/firefox/panes-3-16-0/basic-debug.js +10 -0
- package/dist/firefox/panes-3-16-0/bookmarklet-BZWtwuX-.js +32 -0
- package/dist/firefox/panes-3-16-0/bookmarklet-debug.js +10 -0
- package/dist/firefox/panes-3-16-0/chrome-P6FSEUf1.js +10 -0
- package/dist/firefox/panes-3-16-0/chrome-debug.js +10 -0
- package/dist/firefox/panes-3-16-0/ember.js +166 -0
- package/dist/firefox/panes-3-16-0/ember_debug.js +7 -11018
- package/dist/firefox/panes-3-16-0/evented-BCTya3yE.js +62 -0
- package/dist/firefox/panes-3-16-0/firefox-8F84zphP.js +30 -0
- package/dist/firefox/panes-3-16-0/firefox-debug.js +10 -0
- package/dist/firefox/panes-3-16-0/index.html +4 -23
- package/dist/firefox/panes-3-16-0/internals-CRmXMEzb.js +12 -0
- package/dist/firefox/panes-3-16-0/load-ember-debug-in-webpage-DCWcJhQm.js +29 -0
- package/dist/firefox/panes-3-16-0/main.js +7669 -0
- package/dist/firefox/panes-3-16-0/port.js +108 -0
- package/dist/firefox/panes-3-16-0/profile-node.js +60 -0
- package/dist/firefox/panes-3-16-0/promise-assembler.js +218 -0
- package/dist/firefox/panes-3-16-0/runloop-6_0lpzTA.js +1138 -0
- package/dist/firefox/panes-3-16-0/start-inspector-BIYQArZn.js +334 -0
- package/dist/firefox/panes-3-16-0/type-check.js +119 -0
- package/dist/firefox/panes-3-16-0/version.js +90 -0
- package/dist/firefox/panes-3-16-0/versions.js +4 -0
- package/dist/firefox/panes-3-16-0/web-extension-OWnXJ_XK.js +144 -0
- package/dist/firefox/panes-3-16-0/websocket-BSUvUqER.js +58 -0
- package/dist/firefox/panes-3-16-0/websocket-debug.js +10 -0
- package/dist/firefox/scripts/in-page-script.js +19 -13
- package/dist/websocket/assets/chunk.443.86a005e528b587663b78.js +1135 -0
- package/dist/websocket/assets/chunk.443.86a005e528b587663b78.js.LICENSE.txt +18 -0
- package/dist/websocket/assets/chunk.524.aca67dc376e8cd35b522.js +40 -0
- package/dist/websocket/assets/chunk.582.d3d80e94c4f59dc3b65d.js +42 -0
- package/dist/websocket/assets/ember-inspector.css +997 -156
- package/dist/websocket/assets/ember-inspector.js +560 -613
- package/dist/websocket/assets/svg/ellipsis.svg +3 -3
- package/dist/websocket/assets/svg/focus-point-round.svg +9 -0
- package/dist/websocket/assets/svg/nav-bug.svg +1 -1
- package/dist/websocket/assets/svg/nav-components.svg +2 -2
- package/dist/websocket/assets/svg/nav-container.svg +1 -1
- package/dist/websocket/assets/svg/nav-data.svg +1 -1
- package/dist/websocket/assets/svg/nav-deprecations.svg +3 -3
- package/dist/websocket/assets/svg/nav-info.svg +3 -3
- package/dist/websocket/assets/svg/nav-promises.svg +2 -2
- package/dist/websocket/assets/svg/nav-render-performance.svg +2 -2
- package/dist/websocket/assets/svg/nav-route-tree.svg +7 -7
- package/dist/websocket/assets/svg/sidebar-toggle-trailing.svg +9 -0
- package/dist/websocket/assets/vendor.css +4 -841
- package/dist/websocket/assets/vendor.js +4277 -5152
- package/dist/websocket/base-object-HAEdWjmg.js +59 -0
- package/dist/websocket/basic-B1dkgN3d.js +149 -0
- package/dist/websocket/basic-debug.js +10 -0
- package/dist/websocket/bookmarklet-BZWtwuX-.js +32 -0
- package/dist/websocket/bookmarklet-debug.js +10 -0
- package/dist/websocket/chrome-P6FSEUf1.js +10 -0
- package/dist/websocket/chrome-debug.js +10 -0
- package/dist/websocket/ember.js +166 -0
- package/dist/websocket/ember_debug.js +7 -11018
- package/dist/websocket/evented-BCTya3yE.js +62 -0
- package/dist/websocket/firefox-8F84zphP.js +30 -0
- package/dist/websocket/firefox-debug.js +10 -0
- package/dist/websocket/index.html +4 -23
- package/dist/websocket/internals-CRmXMEzb.js +12 -0
- package/dist/websocket/load-ember-debug-in-webpage-DCWcJhQm.js +29 -0
- package/dist/websocket/main.js +7669 -0
- package/dist/websocket/port.js +108 -0
- package/dist/websocket/profile-node.js +60 -0
- package/dist/websocket/promise-assembler.js +218 -0
- package/dist/websocket/runloop-6_0lpzTA.js +1138 -0
- package/dist/websocket/start-inspector-BIYQArZn.js +334 -0
- package/dist/websocket/type-check.js +119 -0
- package/dist/websocket/version.js +90 -0
- package/dist/websocket/versions.js +4 -0
- package/dist/websocket/web-extension-OWnXJ_XK.js +144 -0
- package/dist/websocket/websocket-BSUvUqER.js +58 -0
- package/dist/websocket/websocket-debug.js +10 -0
- package/ember-cli-build.js +31 -140
- package/ember_debug/adapters/basic.js +10 -29
- package/ember_debug/adapters/bookmarklet.js +1 -0
- package/ember_debug/adapters/firefox.js +3 -3
- package/ember_debug/adapters/web-extension.js +6 -5
- package/ember_debug/adapters/websocket.js +2 -2
- package/ember_debug/babel.config.cjs +11 -0
- package/ember_debug/container-debug.js +1 -1
- package/ember_debug/data-debug.js +7 -8
- package/ember_debug/debug-port.js +1 -1
- package/ember_debug/deprecation-debug.js +14 -14
- package/ember_debug/entrypoints/basic-debug.js +10 -0
- package/ember_debug/entrypoints/bookmarklet-debug.js +10 -0
- package/ember_debug/entrypoints/chrome-debug.js +10 -0
- package/ember_debug/entrypoints/firefox-debug.js +10 -0
- package/ember_debug/entrypoints/websocket-debug.js +10 -0
- package/ember_debug/general-debug.js +4 -4
- package/ember_debug/lib/boot-ember-inspector.js +9 -0
- package/ember_debug/lib/get-applications.js +28 -0
- package/ember_debug/lib/load-ember-debug-in-webpage.js +32 -0
- package/ember_debug/lib/send-apps.js +14 -0
- package/ember_debug/lib/send-version-miss.js +38 -0
- package/ember_debug/lib/setup-instance-initializer.js +17 -0
- package/ember_debug/lib/start-inspector.js +195 -0
- package/ember_debug/lib/version-test.js +73 -0
- package/ember_debug/lib/versions.js +3 -0
- package/ember_debug/libs/capture-render-tree.js +1 -2
- package/ember_debug/libs/promise-assembler.js +5 -4
- package/ember_debug/libs/render-tree.js +37 -44
- package/ember_debug/libs/source-map.js +7 -6
- package/ember_debug/libs/view-inspection.js +25 -17
- package/ember_debug/main.js +18 -21
- package/ember_debug/models/profile-manager.js +6 -6
- package/ember_debug/models/profile-node.js +1 -1
- package/ember_debug/models/promise.js +2 -2
- package/ember_debug/object-inspector.js +74 -65
- package/ember_debug/package.json +27 -0
- package/ember_debug/port.js +5 -4
- package/ember_debug/promise-debug.js +5 -5
- package/ember_debug/render-debug.js +5 -5
- package/ember_debug/rollup.config.js +24 -0
- package/ember_debug/route-debug.js +10 -9
- package/ember_debug/services/session.js +2 -2
- package/ember_debug/utils/classify.js +1 -1
- package/ember_debug/utils/ember/object/internals.js +1 -11
- package/ember_debug/utils/ember/own-runloop.js +1 -1
- package/ember_debug/utils/ember/runloop.js +7 -10
- package/ember_debug/utils/ember-object-names.js +11 -9
- package/ember_debug/utils/ember.js +222 -40
- package/ember_debug/utils/evented.js +1 -1
- package/ember_debug/utils/get-object-name.js +3 -3
- package/ember_debug/utils/type-check.js +9 -5
- package/ember_debug/view-debug.js +12 -6
- package/eslint.config.mjs +173 -0
- package/gulpfile.js +1 -1
- package/package.json +97 -95
- package/patches/ember-cli-inject-live-reload.patch +16 -0
- package/pnpm-workspace.yaml +3 -0
- package/public/assets/svg/ellipsis.svg +3 -3
- package/public/assets/svg/focus-point-round.svg +9 -0
- package/public/assets/svg/nav-bug.svg +1 -1
- package/public/assets/svg/nav-components.svg +2 -2
- package/public/assets/svg/nav-container.svg +1 -1
- package/public/assets/svg/nav-data.svg +1 -1
- package/public/assets/svg/nav-deprecations.svg +3 -3
- package/public/assets/svg/nav-info.svg +3 -3
- package/public/assets/svg/nav-promises.svg +2 -2
- package/public/assets/svg/nav-render-performance.svg +2 -2
- package/public/assets/svg/nav-route-tree.svg +7 -7
- package/public/assets/svg/sidebar-toggle-trailing.svg +9 -0
- package/scripts/download-panes.js +1 -1
- package/skeletons/bookmarklet/load_inspector.js +31 -11
- package/skeletons/web-extension/background.js +26 -21
- package/skeletons/web-extension/boot.js +1 -1
- package/skeletons/web-extension/content-script.js +12 -11
- package/skeletons/web-extension/devtools.js +12 -3
- package/skeletons/web-extension/manifest.json +3 -1
- package/skeletons/web-extension/options.js +17 -12
- package/skeletons/web-extension/scripts/in-page-script.js +19 -13
- package/testem.js +0 -1
- package/tests/acceptance/app-picker-test.js +4 -4
- package/tests/acceptance/component-tree-test.js +96 -57
- package/tests/acceptance/container-test.js +0 -2
- package/tests/acceptance/data-test.js +14 -11
- package/tests/acceptance/deprecation-test.js +8 -12
- package/tests/acceptance/info-test.js +2 -2
- package/tests/acceptance/object-inspector-test.js +62 -110
- package/tests/acceptance/promise-test.js +1 -11
- package/tests/acceptance/render-tree-test.js +2 -2
- package/tests/acceptance/route-tree-test.js +12 -14
- package/tests/acceptance/whats-new-test.js +11 -11
- package/tests/ember_debug/container-debug-test.js +5 -14
- package/tests/ember_debug/deprecation-debug-test.js +15 -6
- package/tests/ember_debug/ember-data-test.js +7 -1
- package/tests/ember_debug/ember-debug-test.js +13 -13
- package/tests/ember_debug/object-inspector-test.js +115 -50
- package/tests/ember_debug/profile-manager-test.js +153 -170
- package/tests/ember_debug/profile-node-test.js +9 -5
- package/tests/ember_debug/promise-assembler-test.js +18 -10
- package/tests/ember_debug/promise-debug-test.js +19 -15
- package/tests/ember_debug/render-debug-test.js +8 -1
- package/tests/ember_debug/route-debug-test.js +14 -8
- package/tests/ember_debug/view-debug-test.js +267 -183
- package/tests/helpers/{index.js → index.ts} +6 -5
- package/tests/helpers/setup-ember-debug-test.js +22 -2
- package/tests/index.html +1 -2
- package/tests/integration/injection-test.js +37 -81
- package/tests/test-adapter.js +15 -15
- package/tests/test-helper.js +6 -4
- package/tests/unit/check-current-route-test.js +0 -4
- package/tests/unit/resizable-columns-test.js +53 -51
- package/tests/unit/utils/parse-text-test.js +3 -3
- package/tests/unit/utils/search-match-test.js +5 -5
- package/tests/unit/utils/type-check-test.js +27 -0
- package/tsconfig.json +3 -1
- package/types/ember-inspector/index.d.ts +2 -1
- package/types/global.d.ts +1 -7
- package/.eslintignore +0 -33
- package/.eslintrc.js +0 -86
- package/app/components/list-content.js +0 -130
- package/app/controllers/promise-tree.js +0 -130
- package/app/libs/promise-assembler.js +0 -169
- package/app/routes/model-types.js +0 -47
- package/app/routes/promise-tree.js +0 -48
- package/app/routes/records.js +0 -55
- package/app/routes/render-tree.js +0 -66
- package/app/services/adapters/websocket.js +0 -31
- package/app/services/layout.js +0 -39
- package/app/services/port.js +0 -90
- package/dist/bookmarklet/panes-3-16-0/assets/chunk.143.76a242242ec46a377266.js +0 -28
- package/dist/bookmarklet/panes-3-16-0/assets/chunk.178.b6064b368cf24cc346ec.js +0 -9
- package/dist/bookmarklet/panes-3-16-0/assets/chunk.359.0be5d21f60d2b5d6d423.js +0 -2620
- package/dist/bookmarklet/panes-3-16-0/assets/chunk.359.0be5d21f60d2b5d6d423.js.LICENSE.txt +0 -67
- package/dist/bookmarklet/panes-3-16-0/assets/fonts/Inter-Bold.woff +0 -0
- package/dist/bookmarklet/panes-3-16-0/assets/fonts/Inter-Bold.woff2 +0 -0
- package/dist/bookmarklet/panes-3-16-0/assets/fonts/Inter-Regular.woff +0 -0
- package/dist/bookmarklet/panes-3-16-0/assets/fonts/Inter-Regular.woff2 +0 -0
- package/dist/chrome/panes-3-16-0/assets/chunk.143.76a242242ec46a377266.js +0 -28
- package/dist/chrome/panes-3-16-0/assets/chunk.178.b6064b368cf24cc346ec.js +0 -9
- package/dist/chrome/panes-3-16-0/assets/chunk.359.0be5d21f60d2b5d6d423.js +0 -2620
- package/dist/chrome/panes-3-16-0/assets/chunk.359.0be5d21f60d2b5d6d423.js.LICENSE.txt +0 -67
- package/dist/chrome/panes-3-16-0/assets/fonts/Inter-Bold.woff +0 -0
- package/dist/chrome/panes-3-16-0/assets/fonts/Inter-Bold.woff2 +0 -0
- package/dist/chrome/panes-3-16-0/assets/fonts/Inter-Regular.woff +0 -0
- package/dist/chrome/panes-3-16-0/assets/fonts/Inter-Regular.woff2 +0 -0
- package/dist/firefox/panes-3-16-0/assets/chunk.143.76a242242ec46a377266.js +0 -28
- package/dist/firefox/panes-3-16-0/assets/chunk.178.b6064b368cf24cc346ec.js +0 -9
- package/dist/firefox/panes-3-16-0/assets/chunk.359.0be5d21f60d2b5d6d423.js +0 -2620
- package/dist/firefox/panes-3-16-0/assets/chunk.359.0be5d21f60d2b5d6d423.js.LICENSE.txt +0 -67
- package/dist/firefox/panes-3-16-0/assets/fonts/Inter-Bold.woff +0 -0
- package/dist/firefox/panes-3-16-0/assets/fonts/Inter-Bold.woff2 +0 -0
- package/dist/firefox/panes-3-16-0/assets/fonts/Inter-Regular.woff +0 -0
- package/dist/firefox/panes-3-16-0/assets/fonts/Inter-Regular.woff2 +0 -0
- package/dist/websocket/assets/chunk.143.76a242242ec46a377266.js +0 -28
- package/dist/websocket/assets/chunk.178.b6064b368cf24cc346ec.js +0 -9
- package/dist/websocket/assets/chunk.359.0be5d21f60d2b5d6d423.js +0 -2620
- package/dist/websocket/assets/chunk.359.0be5d21f60d2b5d6d423.js.LICENSE.txt +0 -67
- package/dist/websocket/assets/fonts/Inter-Bold.woff +0 -0
- package/dist/websocket/assets/fonts/Inter-Bold.woff2 +0 -0
- package/dist/websocket/assets/fonts/Inter-Regular.woff +0 -0
- package/dist/websocket/assets/fonts/Inter-Regular.woff2 +0 -0
- package/ember_debug/.eslintrc.js +0 -13
- package/ember_debug/utils/ember/debug.js +0 -20
- package/ember_debug/utils/ember/instrumentation.js +0 -11
- package/ember_debug/utils/ember/loader.js +0 -22
- package/ember_debug/utils/rsvp.js +0 -20
- package/ember_debug/vendor/loader.js +0 -54
- package/ember_debug/vendor/startup-wrapper.js +0 -399
- package/lib/ui/addon/styles/_object-inspector-toggle.scss +0 -12
- package/lib/ui/addon/styles/addon.scss +0 -13
- package/lib/ui/addon/styles/toolbar/_icon-button.scss +0 -61
- package/lib/ui/app/components/ui/disclosure-triangle.js +0 -1
- package/lib/ui/app/components/ui/disclosure.js +0 -1
- package/lib/ui/app/components/ui/drag-handle.js +0 -1
- package/lib/ui/app/components/ui/draggable-column.js +0 -1
- package/lib/ui/app/components/ui/empty-message.js +0 -1
- package/lib/ui/app/components/ui/error-page.js +0 -1
- package/lib/ui/app/components/ui/open-links-in-new-window.js +0 -1
- package/lib/ui/app/components/ui/resizable-column.js +0 -1
- package/lib/ui/app/components/ui/send-to-console.js +0 -1
- package/lib/ui/app/components/ui/toolbar-clear-button.js +0 -1
- package/lib/ui/app/components/ui/toolbar-divider.js +0 -1
- package/lib/ui/app/components/ui/toolbar-reload-button.js +0 -1
- package/lib/ui/app/components/ui/toolbar-search-field.js +0 -1
- package/lib/ui/app/components/ui/warning-message.js +0 -1
- package/lib/ui/index.js +0 -34
- package/lib/ui/package.json +0 -13
- package/public/assets/fonts/Inter-Bold.woff +0 -0
- package/public/assets/fonts/Inter-Bold.woff2 +0 -0
- package/public/assets/fonts/Inter-Regular.woff +0 -0
- package/public/assets/fonts/Inter-Regular.woff2 +0 -0
- package/tests/helpers/trigger-port.js +0 -6
- /package/app/{app.js → app.ts} +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/disclosure-triangle.hbs +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/disclosure.hbs +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/disclosure.js +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/draggable-column.hbs +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/draggable-column.js +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/open-links-in-new-window.hbs +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/open-links-in-new-window.js +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/resizable-column.hbs +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/send-to-console.hbs +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/toolbar-divider.hbs +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/toolbar-search-field.js +0 -0
- /package/{lib/ui/addon/components → app/components/ui}/warning-message.hbs +0 -0
- /package/app/controllers/{info.js → info.ts} +0 -0
- /package/app/services/adapters/{firefox.js → firefox.ts} +0 -0
- /package/{lib/ui/addon/styles → app/styles/ui}/_goto-source.scss +0 -0
- /package/{lib/ui/addon/styles → app/styles/ui}/_warning.scss +0 -0
- /package/{lib/ui/addon/styles → app/styles/ui}/toolbar/_divider.scss +0 -0
|
@@ -1,17 +1,22 @@
|
|
|
1
1
|
import { isEmpty } from '@ember/utils';
|
|
2
|
-
import { action,
|
|
2
|
+
import { action, get, set } from '@ember/object';
|
|
3
3
|
import Controller, { inject as controller } from '@ember/controller';
|
|
4
4
|
import { inject as service } from '@ember/service';
|
|
5
|
-
import
|
|
5
|
+
import { tracked } from '@glimmer/tracking';
|
|
6
|
+
|
|
7
|
+
import escapeRegExp from '../utils/escape-reg-exp';
|
|
6
8
|
|
|
7
9
|
export default class RecordsController extends Controller {
|
|
10
|
+
queryParams = ['filterValue', 'searchValue'];
|
|
11
|
+
|
|
8
12
|
@controller application;
|
|
9
13
|
@service port;
|
|
10
14
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
+
@tracked filterValue = null;
|
|
16
|
+
@tracked filters = [];
|
|
17
|
+
@tracked modelType;
|
|
18
|
+
@tracked searchValue = '';
|
|
19
|
+
@tracked sorts = undefined;
|
|
15
20
|
|
|
16
21
|
recordToString(record) {
|
|
17
22
|
return (record.searchKeywords || []).join(' ').toLowerCase();
|
|
@@ -32,22 +37,16 @@ export default class RecordsController extends Controller {
|
|
|
32
37
|
* @property schema
|
|
33
38
|
* @type {Object}
|
|
34
39
|
*/
|
|
35
|
-
@computed('modelType.columns')
|
|
36
40
|
get columns() {
|
|
37
|
-
return this.
|
|
41
|
+
return this.modelType.columns.map(({ desc, name }) => ({
|
|
38
42
|
valuePath: `columnValues.${name}`,
|
|
39
43
|
name: desc,
|
|
40
44
|
}));
|
|
41
45
|
}
|
|
42
46
|
|
|
43
|
-
@computed(
|
|
44
|
-
'searchValue',
|
|
45
|
-
'model.@each.{columnValues,filterValues}',
|
|
46
|
-
'filterValue'
|
|
47
|
-
)
|
|
48
47
|
get filteredRecords() {
|
|
49
|
-
|
|
50
|
-
|
|
48
|
+
const search = this.searchValue;
|
|
49
|
+
const filter = this.filterValue;
|
|
51
50
|
|
|
52
51
|
return this.model.filter((item) => {
|
|
53
52
|
// check filters
|
|
@@ -59,34 +58,27 @@ export default class RecordsController extends Controller {
|
|
|
59
58
|
if (!isEmpty(search)) {
|
|
60
59
|
let searchString = this.recordToString(item);
|
|
61
60
|
return !!searchString.match(
|
|
62
|
-
new RegExp(`.*${escapeRegExp(search.toLowerCase())}.*`)
|
|
61
|
+
new RegExp(`.*${escapeRegExp(search.toLowerCase())}.*`),
|
|
63
62
|
);
|
|
64
63
|
}
|
|
65
64
|
return true;
|
|
66
65
|
});
|
|
67
66
|
}
|
|
68
67
|
|
|
69
|
-
constructor() {
|
|
70
|
-
super(...arguments);
|
|
71
|
-
|
|
72
|
-
this.filters = [];
|
|
73
|
-
this.sorts = undefined;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
68
|
@action
|
|
77
69
|
setFilter(val) {
|
|
78
70
|
val = val || null;
|
|
79
|
-
this.
|
|
71
|
+
this.filterValue = val;
|
|
80
72
|
}
|
|
81
73
|
|
|
82
74
|
@action
|
|
83
75
|
inspectModel([record]) {
|
|
84
|
-
|
|
76
|
+
set(this, 'selection', record);
|
|
85
77
|
this.port.send('data:inspectModel', { objectId: record.objectId });
|
|
86
78
|
}
|
|
87
79
|
|
|
88
80
|
@action
|
|
89
81
|
updateSorts(newSorts) {
|
|
90
|
-
this.
|
|
82
|
+
this.sorts = newSorts;
|
|
91
83
|
}
|
|
92
84
|
}
|
|
@@ -1,65 +1,71 @@
|
|
|
1
|
+
/* eslint-disable ember/no-computed-properties-in-native-classes */
|
|
1
2
|
import { action, computed } from '@ember/object';
|
|
2
3
|
import { tracked } from '@glimmer/tracking';
|
|
3
|
-
import { isEmpty } from '@ember/utils';
|
|
4
4
|
import Controller from '@ember/controller';
|
|
5
5
|
import { inject as service } from '@ember/service';
|
|
6
|
-
|
|
7
|
-
import
|
|
8
|
-
import
|
|
6
|
+
|
|
7
|
+
import escapeRegExp from '../utils/escape-reg-exp';
|
|
8
|
+
import debounceComputed from '../computed/debounce';
|
|
9
|
+
import type WebExtension from '../services/adapters/web-extension';
|
|
10
|
+
import type PortService from '../services/port';
|
|
11
|
+
import type StorageService from '../services/storage';
|
|
12
|
+
import type { RenderTreeModel } from '../routes/render-tree';
|
|
13
|
+
import { isNullish } from '../utils/nullish';
|
|
9
14
|
|
|
10
15
|
export default class RenderTreeController extends Controller {
|
|
11
|
-
@service adapter;
|
|
12
|
-
@service port;
|
|
16
|
+
@service declare adapter: WebExtension;
|
|
17
|
+
@service declare port: PortService;
|
|
13
18
|
/**
|
|
14
19
|
* Storage is needed for remembering if the user closed the warning
|
|
15
|
-
*
|
|
16
|
-
* @property storage
|
|
17
|
-
* @type {Service}
|
|
18
20
|
*/
|
|
19
|
-
@service storage;
|
|
21
|
+
@service declare storage: StorageService;
|
|
22
|
+
|
|
23
|
+
declare model: RenderTreeModel;
|
|
20
24
|
|
|
21
|
-
initialEmpty = false;
|
|
25
|
+
@tracked initialEmpty = false;
|
|
22
26
|
@tracked shouldHighlightRender = false;
|
|
23
27
|
@tracked search = '';
|
|
24
28
|
|
|
25
|
-
|
|
26
|
-
|
|
29
|
+
get escapedSearch() {
|
|
30
|
+
return escapeRegExp(this.search?.toLowerCase());
|
|
31
|
+
}
|
|
27
32
|
|
|
28
|
-
|
|
29
|
-
|
|
33
|
+
/**
|
|
34
|
+
* Indicate the table's header's height in pixels.
|
|
35
|
+
*
|
|
36
|
+
* @property headerHeight
|
|
37
|
+
* @type {Number}
|
|
38
|
+
*/
|
|
39
|
+
get headerHeight() {
|
|
40
|
+
return this.isWarningClosed ? 31 : 56;
|
|
41
|
+
}
|
|
30
42
|
|
|
31
43
|
/**
|
|
32
44
|
* Checks if the user previously closed the warning by referencing localStorage
|
|
33
|
-
*
|
|
34
|
-
* @property isWarningClosed
|
|
35
|
-
* @type {Boolean}
|
|
36
45
|
*/
|
|
37
46
|
get isWarningClosed() {
|
|
38
|
-
return !!this.storage.getItem(
|
|
47
|
+
return !!this.storage.getItem(
|
|
48
|
+
'is-render-tree-warning-closed' as keyof object,
|
|
49
|
+
);
|
|
39
50
|
}
|
|
40
51
|
|
|
41
52
|
set isWarningClosed(value) {
|
|
53
|
+
// @ts-expect-error Ignore this boolean/string mismatch for now.
|
|
42
54
|
this.storage.setItem('is-render-tree-warning-closed', value);
|
|
43
55
|
}
|
|
44
56
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
get headerHeight() {
|
|
52
|
-
return this.isWarningClosed ? 31 : 56;
|
|
57
|
+
get modelEmpty() {
|
|
58
|
+
return this.model.profiles.length === 0;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
get showEmpty() {
|
|
62
|
+
return this.initialEmpty && this.modelEmpty;
|
|
53
63
|
}
|
|
54
64
|
|
|
55
65
|
// bound to the input field, updates the `search` property
|
|
56
66
|
// 300ms after changing
|
|
57
67
|
@debounceComputed('search', 300)
|
|
58
|
-
searchValue;
|
|
59
|
-
|
|
60
|
-
get escapedSearch() {
|
|
61
|
-
return escapeRegExp(this.search?.toLowerCase());
|
|
62
|
-
}
|
|
68
|
+
declare searchValue: string;
|
|
63
69
|
|
|
64
70
|
@computed('model.isHighlightSupported')
|
|
65
71
|
get isHighlightEnabled() {
|
|
@@ -68,14 +74,16 @@ export default class RenderTreeController extends Controller {
|
|
|
68
74
|
|
|
69
75
|
@computed('escapedSearch', 'model.profiles.@each.name', 'search')
|
|
70
76
|
get filtered() {
|
|
71
|
-
if (
|
|
77
|
+
if (isNullish(this.escapedSearch)) {
|
|
72
78
|
return this.model.profiles;
|
|
73
79
|
}
|
|
74
80
|
|
|
75
|
-
return this.model.profiles.filter(
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
81
|
+
return this.model.profiles.filter(
|
|
82
|
+
(item: RenderTreeModel['profiles'][number]) => {
|
|
83
|
+
const regExp = new RegExp(this.escapedSearch as string);
|
|
84
|
+
return recursiveMatch(item, regExp);
|
|
85
|
+
},
|
|
86
|
+
);
|
|
79
87
|
}
|
|
80
88
|
|
|
81
89
|
@action
|
|
@@ -85,7 +93,7 @@ export default class RenderTreeController extends Controller {
|
|
|
85
93
|
|
|
86
94
|
@action
|
|
87
95
|
closeWarning() {
|
|
88
|
-
this.
|
|
96
|
+
this.isWarningClosed = true;
|
|
89
97
|
}
|
|
90
98
|
|
|
91
99
|
@action
|
|
@@ -98,18 +106,19 @@ export default class RenderTreeController extends Controller {
|
|
|
98
106
|
}
|
|
99
107
|
}
|
|
100
108
|
|
|
101
|
-
function recursiveMatch(
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
109
|
+
function recursiveMatch(
|
|
110
|
+
item: RenderTreeModel['profiles'][number],
|
|
111
|
+
regExp: string | RegExp,
|
|
112
|
+
) {
|
|
113
|
+
if (item.name.toLowerCase().match(regExp)) {
|
|
105
114
|
return true;
|
|
106
115
|
}
|
|
107
|
-
|
|
108
|
-
for (
|
|
109
|
-
child = children[i];
|
|
116
|
+
|
|
117
|
+
for (const child of item.children) {
|
|
110
118
|
if (recursiveMatch(child, regExp)) {
|
|
111
119
|
return true;
|
|
112
120
|
}
|
|
113
121
|
}
|
|
122
|
+
|
|
114
123
|
return false;
|
|
115
124
|
}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
// eslint-disable-next-line ember/no-computed-properties-in-native-classes
|
|
1
2
|
import { alias } from '@ember/object/computed';
|
|
3
|
+
// eslint-disable-next-line ember/no-computed-properties-in-native-classes
|
|
2
4
|
import { action, computed, set } from '@ember/object';
|
|
3
5
|
import Controller, { inject as controller } from '@ember/controller';
|
|
4
6
|
import { inject as service } from '@ember/service';
|
|
@@ -22,7 +24,7 @@ export default class RouteTreeController extends Controller {
|
|
|
22
24
|
'model.[]',
|
|
23
25
|
'options.{hideRoutes,hideSubstates}',
|
|
24
26
|
'currentRoute.{name,url}',
|
|
25
|
-
'searchValue'
|
|
27
|
+
'searchValue',
|
|
26
28
|
)
|
|
27
29
|
get filtered() {
|
|
28
30
|
if (!Array.isArray(this.model)) {
|
|
@@ -30,8 +32,8 @@ export default class RouteTreeController extends Controller {
|
|
|
30
32
|
}
|
|
31
33
|
return this.model.filter((routeItem) => {
|
|
32
34
|
let currentRoute = this.currentRoute;
|
|
33
|
-
let hideRoutes = this.
|
|
34
|
-
let hideSubstates = this.
|
|
35
|
+
let hideRoutes = this.options.hideRoutes;
|
|
36
|
+
let hideSubstates = this.options.hideSubstates;
|
|
35
37
|
|
|
36
38
|
if (hideRoutes && currentRoute) {
|
|
37
39
|
return checkCurrentRoute(currentRoute, routeItem.value);
|
|
@@ -60,8 +62,8 @@ export default class RouteTreeController extends Controller {
|
|
|
60
62
|
});
|
|
61
63
|
}
|
|
62
64
|
|
|
63
|
-
|
|
64
|
-
super
|
|
65
|
+
constructor() {
|
|
66
|
+
super(...arguments);
|
|
65
67
|
|
|
66
68
|
set(this, 'model', []);
|
|
67
69
|
set(this, 'options', {
|
|
@@ -15,7 +15,7 @@ const { keys } = Object;
|
|
|
15
15
|
|
|
16
16
|
export function buildStyle(_, options) {
|
|
17
17
|
return htmlSafe(
|
|
18
|
-
keys(options).reduce((style, key) => `${style}${key}:${options[key]};`, '')
|
|
18
|
+
keys(options).reduce((style, key) => `${style}${key}:${options[key]};`, ''),
|
|
19
19
|
);
|
|
20
20
|
}
|
|
21
21
|
|
package/app/index.html
CHANGED
|
@@ -8,30 +8,12 @@
|
|
|
8
8
|
|
|
9
9
|
{{content-for "head"}}
|
|
10
10
|
|
|
11
|
-
<style type="text/css">
|
|
12
|
-
@font-face {
|
|
13
|
-
font-display: swap;
|
|
14
|
-
font-family: 'Inter';
|
|
15
|
-
font-style: normal;
|
|
16
|
-
font-weight: 400;
|
|
17
|
-
src: url("{{rootURL}}assets/fonts/Inter-Regular.woff2?v=3.12") format("woff2"), url("{{rootURL}}assets/fonts/Inter-Regular.woff?v=3.12") format("woff");
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
@font-face {
|
|
21
|
-
font-display: swap;
|
|
22
|
-
font-family: 'Inter';
|
|
23
|
-
font-style: normal;
|
|
24
|
-
font-weight: 700;
|
|
25
|
-
src: url("{{rootURL}}assets/fonts/Inter-Bold.woff2?v=3.12") format("woff2"), url("{{rootURL}}assets/fonts/Inter-Bold.woff?v=3.12") format("woff");
|
|
26
|
-
}
|
|
27
|
-
</style>
|
|
28
|
-
|
|
29
11
|
<link integrity="" rel="stylesheet" href="{{rootURL}}assets/vendor.css">
|
|
30
12
|
<link integrity="" rel="stylesheet" href="{{rootURL}}assets/ember-inspector.css">
|
|
31
13
|
|
|
32
14
|
{{content-for "head-footer"}}
|
|
33
15
|
</head>
|
|
34
|
-
<body class="theme
|
|
16
|
+
<body class="theme-light">
|
|
35
17
|
{{content-for "body"}}
|
|
36
18
|
|
|
37
19
|
<script src="{{rootURL}}assets/vendor.js"></script>
|
|
@@ -5,7 +5,7 @@ export default {
|
|
|
5
5
|
initialize(instance) {
|
|
6
6
|
// {{EMBER_DIST}} is replaced by the build process (basic, chrome, etc)
|
|
7
7
|
let Adapter = instance.resolveRegistration(
|
|
8
|
-
`service:adapters/{{EMBER_DIST}}
|
|
8
|
+
`service:adapters/{{EMBER_DIST}}`,
|
|
9
9
|
);
|
|
10
10
|
|
|
11
11
|
// register the adapter service
|
|
@@ -0,0 +1,249 @@
|
|
|
1
|
+
/* eslint-disable @typescript-eslint/no-unsafe-argument */
|
|
2
|
+
import { assert } from '@ember/debug';
|
|
3
|
+
import { later } from '@ember/runloop';
|
|
4
|
+
import EmberObject, { action, setProperties } from '@ember/object';
|
|
5
|
+
import { addListener, removeListener, sendEvent } from '@ember/object/events';
|
|
6
|
+
import type { AnyFn } from '@ember/-internals/utility-types';
|
|
7
|
+
|
|
8
|
+
import { TrackedArray, TrackedObject } from 'tracked-built-ins';
|
|
9
|
+
import { tracked } from '@glimmer/tracking';
|
|
10
|
+
|
|
11
|
+
import PromiseModel from '../models/promise';
|
|
12
|
+
import type PortService from '../services/port';
|
|
13
|
+
|
|
14
|
+
interface SerializedPromise {
|
|
15
|
+
children?: Array<string>;
|
|
16
|
+
guid: string;
|
|
17
|
+
label: string;
|
|
18
|
+
parent?: string;
|
|
19
|
+
reason: string;
|
|
20
|
+
state: string;
|
|
21
|
+
value: string;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export default class PromiseAssembler extends EmberObject {
|
|
25
|
+
declare port: PortService;
|
|
26
|
+
// Used to track whether current message received
|
|
27
|
+
// is the first in the request
|
|
28
|
+
// Mainly helps in triggering 'firstMessageReceived' event
|
|
29
|
+
@tracked firstMessageReceived = false;
|
|
30
|
+
|
|
31
|
+
all = new TrackedArray<PromiseModel>([]);
|
|
32
|
+
promiseIndex = new TrackedObject<Record<string, number>>({});
|
|
33
|
+
topSort = new TrackedArray<PromiseModel>([]);
|
|
34
|
+
topSortMeta = new TrackedObject<Record<string, { hasParent?: boolean }>>({});
|
|
35
|
+
|
|
36
|
+
start() {
|
|
37
|
+
this.port.on('promise:promisesUpdated', this, this.addOrUpdatePromises);
|
|
38
|
+
this.port.send('promise:getAndObservePromises');
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
stop() {
|
|
42
|
+
this.port.off('promise:promisesUpdated', this, this.addOrUpdatePromises);
|
|
43
|
+
this.port.send('promise:releasePromises');
|
|
44
|
+
this.reset();
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
reset() {
|
|
48
|
+
this.topSortMeta = new TrackedObject<
|
|
49
|
+
Record<string, { hasParent?: boolean }>
|
|
50
|
+
>({});
|
|
51
|
+
this.promiseIndex = new TrackedObject<Record<string, number>>({});
|
|
52
|
+
this.topSort.splice(0, this.topSort.length);
|
|
53
|
+
|
|
54
|
+
this.firstMessageReceived = false;
|
|
55
|
+
const all = this.all;
|
|
56
|
+
// Lazily destroy promises
|
|
57
|
+
// Allows for a smooth transition on deactivate,
|
|
58
|
+
// and thus providing the illusion of better perf
|
|
59
|
+
// eslint-disable-next-line ember/no-runloop
|
|
60
|
+
later(
|
|
61
|
+
this,
|
|
62
|
+
function () {
|
|
63
|
+
this.destroyPromises(all);
|
|
64
|
+
},
|
|
65
|
+
500,
|
|
66
|
+
);
|
|
67
|
+
this.all = new TrackedArray([]);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
destroyPromises(promises: Array<EmberObject>) {
|
|
71
|
+
promises.forEach(function (item) {
|
|
72
|
+
item.destroy();
|
|
73
|
+
});
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
addOrUpdatePromises = (message: { promises: Array<SerializedPromise> }) => {
|
|
77
|
+
this.rebuildPromises(message.promises);
|
|
78
|
+
|
|
79
|
+
if (!this.firstMessageReceived) {
|
|
80
|
+
this.firstMessageReceived = true;
|
|
81
|
+
this.trigger('firstMessageReceived');
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
rebuildPromises = (promises: Array<SerializedPromise | PromiseModel>) => {
|
|
86
|
+
promises.forEach((props) => {
|
|
87
|
+
props = Object.assign({}, props);
|
|
88
|
+
const childrenIds = props.children;
|
|
89
|
+
const parentId = props.parent;
|
|
90
|
+
delete props.children;
|
|
91
|
+
delete props.parent;
|
|
92
|
+
if (parentId && parentId !== props.guid) {
|
|
93
|
+
props.parent = this.updateOrCreate({ guid: parentId });
|
|
94
|
+
}
|
|
95
|
+
const promise = this.updateOrCreate(props);
|
|
96
|
+
if (childrenIds) {
|
|
97
|
+
childrenIds.forEach((childId) => {
|
|
98
|
+
// avoid infinite recursion
|
|
99
|
+
if (childId === props.guid) {
|
|
100
|
+
return;
|
|
101
|
+
}
|
|
102
|
+
const child = this.updateOrCreate({ guid: childId, parent: promise });
|
|
103
|
+
promise.children.push(child);
|
|
104
|
+
});
|
|
105
|
+
}
|
|
106
|
+
});
|
|
107
|
+
};
|
|
108
|
+
|
|
109
|
+
updateTopSort = (promise: PromiseModel) => {
|
|
110
|
+
const topSortMeta = this.topSortMeta;
|
|
111
|
+
const guid = promise.guid;
|
|
112
|
+
let meta = topSortMeta[guid] ?? {};
|
|
113
|
+
const isNew = !meta;
|
|
114
|
+
let hadParent: boolean | undefined = false;
|
|
115
|
+
const hasParent = !!promise.parent;
|
|
116
|
+
const topSort = this.topSort;
|
|
117
|
+
let parentChanged = isNew;
|
|
118
|
+
|
|
119
|
+
if (isNew) {
|
|
120
|
+
meta = topSortMeta[guid] = {};
|
|
121
|
+
} else {
|
|
122
|
+
hadParent = meta.hasParent;
|
|
123
|
+
}
|
|
124
|
+
if (!isNew && hasParent !== hadParent) {
|
|
125
|
+
// todo: implement recursion to reposition children
|
|
126
|
+
const index = topSort.indexOf(promise);
|
|
127
|
+
if (index !== -1) {
|
|
128
|
+
topSort.splice(index, 1);
|
|
129
|
+
}
|
|
130
|
+
parentChanged = true;
|
|
131
|
+
}
|
|
132
|
+
meta.hasParent = hasParent;
|
|
133
|
+
if (parentChanged) {
|
|
134
|
+
this.insertInTopSort(promise);
|
|
135
|
+
}
|
|
136
|
+
};
|
|
137
|
+
|
|
138
|
+
insertInTopSort = (promise: PromiseModel) => {
|
|
139
|
+
const topSort = this.topSort;
|
|
140
|
+
if (promise.parent) {
|
|
141
|
+
const parentIndex = topSort.indexOf(promise.parent);
|
|
142
|
+
topSort.splice(parentIndex + 1, 0, promise);
|
|
143
|
+
} else {
|
|
144
|
+
this.topSort.push(promise);
|
|
145
|
+
}
|
|
146
|
+
promise.children.forEach((child) => {
|
|
147
|
+
const index = topSort.indexOf(child);
|
|
148
|
+
if (index !== -1) {
|
|
149
|
+
topSort.splice(index, 1);
|
|
150
|
+
}
|
|
151
|
+
this.insertInTopSort(child);
|
|
152
|
+
});
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
156
|
+
updateOrCreate = (props: any) => {
|
|
157
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-member-access
|
|
158
|
+
const guid = props.guid;
|
|
159
|
+
const promise = this.findOrCreate(guid);
|
|
160
|
+
|
|
161
|
+
setProperties(promise, props);
|
|
162
|
+
|
|
163
|
+
this.updateTopSort(promise);
|
|
164
|
+
|
|
165
|
+
return promise;
|
|
166
|
+
};
|
|
167
|
+
|
|
168
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
169
|
+
createPromise(props: any): PromiseModel {
|
|
170
|
+
const promise = PromiseModel.create(props) as PromiseModel;
|
|
171
|
+
const index = this.all.length;
|
|
172
|
+
|
|
173
|
+
this.all.push(promise);
|
|
174
|
+
this.promiseIndex[promise.guid as keyof object] = index;
|
|
175
|
+
return promise;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
find(guid?: string) {
|
|
179
|
+
if (guid) {
|
|
180
|
+
const index = this.promiseIndex[guid as keyof object];
|
|
181
|
+
if (index !== undefined) {
|
|
182
|
+
return this.all.at(index);
|
|
183
|
+
}
|
|
184
|
+
} else {
|
|
185
|
+
return this.all;
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
findOrCreate(guid?: string) {
|
|
190
|
+
if (!guid) {
|
|
191
|
+
assert('You have tried to findOrCreate without a guid');
|
|
192
|
+
}
|
|
193
|
+
return (this.find(guid) as PromiseModel) || this.createPromise({ guid });
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
// Manually implement Evented functionality, so we can move away from the mixin
|
|
197
|
+
|
|
198
|
+
on(eventName: string, method: AnyFn): void;
|
|
199
|
+
on(eventName: string, target: unknown, method: AnyFn): void;
|
|
200
|
+
|
|
201
|
+
@action
|
|
202
|
+
// eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
|
|
203
|
+
on(eventName: string, targetOrMethod: unknown | AnyFn, method?: AnyFn): void {
|
|
204
|
+
if (typeof targetOrMethod === 'function') {
|
|
205
|
+
// If we did not pass a target, default to `this`
|
|
206
|
+
addListener(this, eventName, this, targetOrMethod as AnyFn);
|
|
207
|
+
} else {
|
|
208
|
+
addListener(this, eventName, targetOrMethod as object, method);
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
one(eventName: string, method: AnyFn): void;
|
|
213
|
+
one(eventName: string, target: unknown, method: AnyFn): void;
|
|
214
|
+
|
|
215
|
+
@action
|
|
216
|
+
// eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
|
|
217
|
+
one(eventName: string, targetOrMethod: unknown | AnyFn, method?: AnyFn) {
|
|
218
|
+
if (typeof targetOrMethod === 'function') {
|
|
219
|
+
// If we did not pass a target, default to `this`
|
|
220
|
+
addListener(this, eventName, this, targetOrMethod as AnyFn, true);
|
|
221
|
+
} else {
|
|
222
|
+
addListener(this, eventName, targetOrMethod as object, method, true);
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
off(eventName: string, method: AnyFn): void;
|
|
227
|
+
off(eventName: string, target: unknown, method: AnyFn): void;
|
|
228
|
+
|
|
229
|
+
@action
|
|
230
|
+
// eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
|
|
231
|
+
off(eventName: string, targetOrMethod: unknown | AnyFn, method?: AnyFn) {
|
|
232
|
+
try {
|
|
233
|
+
if (typeof targetOrMethod === 'function') {
|
|
234
|
+
// If we did not pass a target, default to `this`
|
|
235
|
+
removeListener(this, eventName, this, targetOrMethod as AnyFn);
|
|
236
|
+
} else {
|
|
237
|
+
removeListener(this, eventName, targetOrMethod as object, method);
|
|
238
|
+
}
|
|
239
|
+
} catch (e) {
|
|
240
|
+
console.error(e);
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
@action
|
|
245
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
246
|
+
trigger(eventName: string, ...args: Array<any>) {
|
|
247
|
+
sendEvent(this, eventName, args);
|
|
248
|
+
}
|
|
249
|
+
}
|
|
@@ -81,7 +81,7 @@ export default class {
|
|
|
81
81
|
let saved = this.storage.getItem(this.getStorageKey());
|
|
82
82
|
if (saved && saved.columnVisibility) {
|
|
83
83
|
let savedIds = keys(saved.columnVisibility).sort();
|
|
84
|
-
let schemaIds = this.columnSchema.
|
|
84
|
+
let schemaIds = this.columnSchema.map((col) => col.id).sort();
|
|
85
85
|
if (!compareArrays(savedIds, schemaIds)) {
|
|
86
86
|
// Clear saved items
|
|
87
87
|
this.storage.removeItem(this.getStorageKey());
|
|
@@ -165,7 +165,7 @@ export default class {
|
|
|
165
165
|
if (saved.columnVisibility && !isNone(saved.columnVisibility[id])) {
|
|
166
166
|
return saved.columnVisibility[id];
|
|
167
167
|
}
|
|
168
|
-
return this.columnSchema.
|
|
168
|
+
return this.columnSchema.find((x) => x.id === id).visible;
|
|
169
169
|
}
|
|
170
170
|
|
|
171
171
|
/**
|
|
@@ -195,7 +195,7 @@ export default class {
|
|
|
195
195
|
this._columnVisibility = this.columnSchema.map((column) =>
|
|
196
196
|
Object.assign({}, column, {
|
|
197
197
|
visible: this.isColumnVisible(column.id),
|
|
198
|
-
})
|
|
198
|
+
}),
|
|
199
199
|
);
|
|
200
200
|
}
|
|
201
201
|
|
|
@@ -221,8 +221,8 @@ export default class {
|
|
|
221
221
|
let diff = this.tableWidth - totalWidth;
|
|
222
222
|
while (diff > 0) {
|
|
223
223
|
columns
|
|
224
|
-
.
|
|
225
|
-
.
|
|
224
|
+
.filter((col) => !!col.visible)
|
|
225
|
+
.sort((a, b) => a.width - b.width)
|
|
226
226
|
.forEach((column) => {
|
|
227
227
|
if (diff > 0) {
|
|
228
228
|
column.width++;
|
|
@@ -245,7 +245,7 @@ export default class {
|
|
|
245
245
|
* @param {Number} width The column's new width
|
|
246
246
|
*/
|
|
247
247
|
updateColumnWidth(id, width) {
|
|
248
|
-
let column = this._columns.
|
|
248
|
+
let column = this._columns.find((x) => x.id === id);
|
|
249
249
|
let previousWidth = column.width;
|
|
250
250
|
column.width = width;
|
|
251
251
|
let last = this._columns[this._columns.length - 1];
|
|
@@ -265,9 +265,9 @@ export default class {
|
|
|
265
265
|
* @param {String} id
|
|
266
266
|
*/
|
|
267
267
|
toggleVisibility(id) {
|
|
268
|
-
let column = this._columnVisibility.
|
|
268
|
+
let column = this._columnVisibility.find((x) => x.id === id);
|
|
269
269
|
column.visible = !column.visible;
|
|
270
|
-
if (!this._columnVisibility.
|
|
270
|
+
if (!this._columnVisibility.some((col) => col.visible)) {
|
|
271
271
|
// If this column was the last visible column
|
|
272
272
|
// cancel toggling and set back to `true`.
|
|
273
273
|
column.visible = true;
|
|
@@ -317,7 +317,7 @@ export default class {
|
|
|
317
317
|
obj[id] = visible;
|
|
318
318
|
return obj;
|
|
319
319
|
},
|
|
320
|
-
{}
|
|
320
|
+
{},
|
|
321
321
|
);
|
|
322
322
|
this.storage.setItem(this.getStorageKey(), saved);
|
|
323
323
|
}
|
|
@@ -362,7 +362,7 @@ export default class {
|
|
|
362
362
|
* @method getStorageKey
|
|
363
363
|
*/
|
|
364
364
|
getStorageKey() {
|
|
365
|
-
return `
|
|
365
|
+
return `list-${this.key}`;
|
|
366
366
|
}
|
|
367
367
|
|
|
368
368
|
/**
|