Skip to content

Commit

Permalink
fix: unwanted re-rendering of dashboard items (#2247)
Browse files Browse the repository at this point in the history
* fix: solve most unwanted re-renders of dashboard items

This is basically reverting a change I added to solve a DV Highchart's
cutoff issue.
I think I found another approach for that issue which does not require
to pass style to the plugin, which is a problem because of course it
changes any time the dashboard item container changes size (window
resize, resize of other dashboard items, interpretation panel toggle,
etc...).

* chore: bump cli-app-scripts to solve no-service-worker issue
  • Loading branch information
edoardo authored and jenniferarnesen committed Mar 22, 2023
1 parent 964e007 commit b5d97df
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 25 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"cy:capture": "cypress_dhis2_api_stub_mode=CAPTURE yarn d2-utils-cypress run --appStart 'yarn cypress:start'"
},
"devDependencies": {
"@dhis2/cli-app-scripts": "^10.2.3",
"@dhis2/cli-app-scripts": "^10.3.3",
"@dhis2/cli-style": "^10.4.1",
"@dhis2/cli-utils-cypress": "^7.0.1",
"@dhis2/cypress-commands": "^7.0.1",
Expand All @@ -69,4 +69,4 @@
"^.+\\.(css|sass|scss)$": "identity-obj-proxy"
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ const IframePlugin = ({
forDashboard: true,
displayProperty: userSettings.displayProperty,
visualization,
style,
onError,

// For caching: ---
Expand All @@ -65,7 +64,6 @@ const IframePlugin = ({
itemId,
isCached,
recordOnNextLoad,
style,
]
)

Expand Down
42 changes: 21 additions & 21 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2167,12 +2167,12 @@
react-beautiful-dnd "^10.1.1"
resize-observer-polyfill "^1.5.1"

"@dhis2/app-adapter@10.2.3":
version "10.2.3"
resolved "https://registry.yarnpkg.com/@dhis2/app-adapter/-/app-adapter-10.2.3.tgz#15753bb665be92d1058c36f8f060ff65ddedf5c8"
integrity sha512-Qk73M8yJJ2vWhbO0elAhXJrk/P9gk5jBYSQ/2BNukdJv6QwdNJu6WWRqkE9qCgnE5AR6pXXjv5DkT6lf/4phQg==
"@dhis2/app-adapter@10.3.3":
version "10.3.3"
resolved "https://registry.yarnpkg.com/@dhis2/app-adapter/-/app-adapter-10.3.3.tgz#d9c2574778b18a5ed556c50a391300eed20a7467"
integrity sha512-jm6L4+GUCfvkIIlM5G1SvLgnzVRQCdOz8x7hBqBcNyZPvo4NRc1Q6iy0HmsGni4H6+pG7UcEE3vJSWoEc8zykA==
dependencies:
"@dhis2/pwa" "10.2.3"
"@dhis2/pwa" "10.3.3"
moment "^2.24.0"

"@dhis2/app-runtime-adapter-d2@^1.1.0":
Expand Down Expand Up @@ -2216,15 +2216,15 @@
dependencies:
lodash "^4.17.21"

"@dhis2/app-shell@10.2.3":
version "10.2.3"
resolved "https://registry.yarnpkg.com/@dhis2/app-shell/-/app-shell-10.2.3.tgz#b2b9907b8c3fa22de26ba739ccfcdd85929c0345"
integrity sha512-hvFOFz6YtGLGYyHrcGxYAz9XdT19EH//dIBnqhCQIBv/d7q5uqQ8yue3XaUq1wOi2JQKsVH3mhRjruetlBkdAg==
"@dhis2/app-shell@10.3.3":
version "10.3.3"
resolved "https://registry.yarnpkg.com/@dhis2/app-shell/-/app-shell-10.3.3.tgz#a8832526af56bb3348c9f2e91695469416c6e774"
integrity sha512-3/8K/jZuOPaFEtrz1lmpA8eK6pqpxAdGKsrLa0zdggNHjwemei6vqcxj+PaiIIPCbqwFD1T6mXbDFn9ds9CQPA==
dependencies:
"@dhis2/app-adapter" "10.2.3"
"@dhis2/app-runtime" "^3.6.1"
"@dhis2/app-adapter" "10.3.3"
"@dhis2/app-runtime" "^3.9.0"
"@dhis2/d2-i18n" "^1.1.1"
"@dhis2/pwa" "10.2.3"
"@dhis2/pwa" "10.3.3"
"@dhis2/ui" "^8.6.2"
classnames "^2.2.6"
moment "^2.29.1"
Expand All @@ -2237,10 +2237,10 @@
typeface-roboto "^0.0.75"
typescript "^3.6.3"

"@dhis2/cli-app-scripts@^10.2.3":
version "10.2.3"
resolved "https://registry.yarnpkg.com/@dhis2/cli-app-scripts/-/cli-app-scripts-10.2.3.tgz#be4a91cfddaa7ffc7c65404433b21f9b0b254cce"
integrity sha512-jjNAjJlUJVhThyjWb6hl2gOYba6i+Rqxbehsk85feeTSgwQQtDW7klX0Xi9X/I60xA8gyDnU6xJRZqE3y+rsFw==
"@dhis2/cli-app-scripts@^10.3.3":
version "10.3.3"
resolved "https://registry.yarnpkg.com/@dhis2/cli-app-scripts/-/cli-app-scripts-10.3.3.tgz#26d722bc6fdea6fd92d96546c6e0d11968b6ea4a"
integrity sha512-cZtrz/wnL0NWpe/P9+ys+94KLQLpleQtAnYo53yepnfyGBvKz97oEfdP0dGxxTUQn8ReaOgCnpDPaJ3yI0C5rQ==
dependencies:
"@babel/core" "^7.6.2"
"@babel/plugin-proposal-class-properties" "^7.8.3"
Expand All @@ -2249,7 +2249,7 @@
"@babel/preset-env" "^7.14.7"
"@babel/preset-react" "^7.0.0"
"@babel/preset-typescript" "^7.6.0"
"@dhis2/app-shell" "10.2.3"
"@dhis2/app-shell" "10.3.3"
"@dhis2/cli-helpers-engine" "^3.2.0"
"@jest/core" "^27.0.6"
"@pmmmwh/react-refresh-webpack-plugin" "^0.5.4"
Expand Down Expand Up @@ -2457,10 +2457,10 @@
resolved "https://registry.yarnpkg.com/@dhis2/prop-types/-/prop-types-3.1.2.tgz#65b8ad2da8cd2f72bc8b951049a6c9d1b97af3e9"
integrity sha512-eM0jjLOWvtXWqSFp5YC4DHFpkP8Y1D2eUwGV7MBWjni+o27oesVan+oT7WHeOeLdlAd4acRJrnaaAyB4Ck1wGQ==

"@dhis2/pwa@10.2.3":
version "10.2.3"
resolved "https://registry.yarnpkg.com/@dhis2/pwa/-/pwa-10.2.3.tgz#679ddad035053ed216398cd8f27c6f21eecb287d"
integrity sha512-0ylXklRLnDEJr+7EJ8lzTbRntxiRWN+Rdu8C0w+8TgXQD6Axx0hHfjt6EW6hwtVEEZckakKVw867aQCf5HwDsg==
"@dhis2/pwa@10.3.3":
version "10.3.3"
resolved "https://registry.yarnpkg.com/@dhis2/pwa/-/pwa-10.3.3.tgz#dc728fae35edc082f8f4096700bbeec4ce323e31"
integrity sha512-3hxjJ9GKTjaTsntXzCtJuZiy69IHtG4ca2+SMdFyuQPYFj1rELx8rMns9fvvUH7vEyNJVYbnXf1vlohMmobydQ==
dependencies:
idb "^6.0.0"
workbox-core "^6.1.5"
Expand Down

0 comments on commit b5d97df

Please sign in to comment.